www.delorie.com/gnu/docs/glibc/libc_544.html   search  
Buy the book!

The GNU C Library

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

25.3.10 Flags for the argp_help Function

When calling argp_help (see section 25.3.9 The argp_help Function) or argp_state_help (see section Functions For Use in Argp Parsers) the exact output is determined by the flags argument. This should consist of any of the following flags, or'd together:

A unix `Usage:' message that explicitly lists all options.

A unix `Usage:' message that displays an appropriate placeholder to indicate where the options go; useful for showing the non-option argument syntax.

A `Try ... for more help' message; `...' contains the program name and `--help'.

A verbose option help message that gives each option available along with its documentation string.

The part of the argp parser doc string preceding the verbose option help.

The part of the argp parser doc string that following the verbose option help.


A message that prints where to report bugs for this program, if the argp_program_bug_address variable contains this information.

This will modify any output to reflect the ARGP_LONG_ONLY mode.

The following flags are only understood when used with argp_state_help. They control whether the function returns after printing its output, or terminates the program:

This will terminate the program with exit (argp_err_exit_status).

This will terminate the program with exit (0).

The following flags are combinations of the basic flags for printing standard messages:

Assuming that an error message for a parsing error has printed, this prints a message on how to get help, and terminates the program with an error.

This prints a standard usage message and terminates the program with an error. This is used when no other specific error messages are appropriate or available.

This prints the standard response for a `--help' option, and terminates the program successfully.

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

  webmaster     delorie software   privacy  
  Copyright 2003   by The Free Software Foundation     Updated Jun 2003