Getopt

From dankwiki

Shell

getopt(1) diverges between Linux and FreeBSD. POSIX's getopts(1) is the portable way to do option parsing from the shell (as pointed out in BASH FAQ #035).

C