2 @subsection @code{getopt_long_only}
3 @findex getopt_long_only
5 Gnulib module: getopt-gnu
7 Portability problems fixed by Gnulib:
10 The function @code{getopt_long_only} does not obey the combination of
11 @samp{+} and @samp{:} flags in the options string on some platforms:
14 The use of @samp{W;} in the optstring argument to does not always
15 allow @code{-W foo} to behave synonymously with @code{--foo}:
18 The function @code{getopt_long_only} does not support the @samp{+}
19 flag in the options string on some platforms:
20 Mac OS X 10.5, AIX 5.2, OSF/1 5.1, Solaris 10.
22 The value of @code{optind} after a missing required argument is wrong
26 The function @code{getopt_long_only} does not obey the @samp{-} flag
27 in the options string when @env{POSIXLY_CORRECT} is set on some platforms:
30 Some implementations fail to reset state, including re-checking
31 @env{POSIXLY_CORRECT}, when @code{optind} is set to @samp{0}:
34 The function @code{getopt_long_only} does not support options with
35 optional arguments on some platforms:
36 Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, Solaris 11 2010-11, Cygwin 1.5.x.
38 This function is missing on some platforms:
39 Mac OS X 10.3, FreeBSD 5.2.1, NetBSD 5.0, Minix 3.1.8, AIX 5.1, HP-UX 11, IRIX 6.5,
40 OSF/1 5.1, mingw, MSVC 14, Interix 3.5.
42 This function crashes if the option string includes @code{W;} but
43 there are no long options, on some platforms:
47 Portability problems not fixed by Gnulib:
50 Some implementations return success instead of reporting an ambiguity
51 if user's option is a prefix of two long options with the same outcome:
54 The GNU Coding Standards discourage the use of @code{getopt_long_only}