1

What is the -W option of GNU getopt() used for?

view story
linux-howto

http://stackoverflow.com – Quoted from the POSIX.1-2008 description about -W option, The -W (capital-W) option shall be reserved for vendor options. Quoted from Linux Manual page, GNU getopt handles -W option as follows: If optstring contains W followed by a semicolon ( ; ), then -W foo is treated as the long option --foo. (The -W option is reserved by POSIX.2 for implementation extensions.) Could someone explain the above sentence in a more clear way (straightforward) and explain why such an option is useful? The above statement bugs me because I think getopt (not getopt_long, getopt_long_only) only unders (HowTos)