Next: Argp Help, Previous: Argp Parsers, Up: Argp
argp_parseThe default behavior of argp_parse is designed to be convenient
for the most common case of parsing program command line argument. To
modify these defaults, the following flags may be or'd together in the
flags argument to argp_parse:
ARGP_PARSE_ARGV0argp_parse. Unless ARGP_NO_ERRS is set, the first element
of the argument vector is skipped for option parsing purposes, as it
corresponds to the program name in a command line.
ARGP_NO_ERRSstderr; unless
this flag is set, ARGP_PARSE_ARGV0 is ignored, as argv[0]
is used as the program name in the error messages. This flag implies
ARGP_NO_EXIT. This is based on the assumption that silent exiting
upon errors is bad behavior.
ARGP_NO_ARGSARGP_KEY_ARG, the actual
argument being the value. This flag needn't normally be set, as the
default behavior is to stop parsing as soon as an argument fails to be
parsed. See Argp Parser Functions.
ARGP_IN_ORDERARGP_NO_HELPstdout
and exit (0).
ARGP_NO_EXITARGP_LONG_ONLYARGP_SILENTARGP_NO_EXIT, ARGP_NO_ERRS, and ARGP_NO_HELP.