4 /* include files needed by this include file */
6 /* macros defined by this include file */
8 #define required_argument 1
11 /* types defined by this include file */
13 /* GETOPT_LONG_OPTION_T: The type of long option */
14 typedef struct GETOPT_LONG_OPTION_T
16 const char *name; /* the name of the long option */
17 int has_arg; /* one of the above macros */
18 int *flag; /* determines if getopt_long() returns a
19 * value for a long option; if it is
20 * non-NULL, 0 is returned as a function
21 * value and the value of val is stored in
22 * the area pointed to by flag. Otherwise,
24 int val; /* determines the value to return if flag is
26 } GETOPT_LONG_OPTION_T;
28 typedef GETOPT_LONG_OPTION_T option;
35 /* externally-defined variables */
41 /* function prototypes */
43 int getopt (int argc, char **argv, char *optstring);
45 int getopt_long (int argc, char **argv, const char *shortopts,
46 const GETOPT_LONG_OPTION_T * longopts, int *longind);
47 int getopt_long_only (int argc, char **argv, const char *shortopts,
48 const GETOPT_LONG_OPTION_T * longopts, int *longind);
57 /* END OF FILE getopt.h */