1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
|
#ifndef _WGETOPT_H
#define _WGETOPT_H
#include <wchar.h>
extern wchar_t *woptarg;
extern int woptind, wopterr, woptopt;
struct woption {
const wchar_t *name;
int has_arg;
int *flag;
int val;
};
#define no_argument 0
#define required_argument 1
#define optional_argument 2
int
wgetopt (int argc, wchar_t *const *argv, const wchar_t *optstring);
int
wgetopt_long(int argc, wchar_t * const *argv, const wchar_t *options,
const struct woption *long_options, int *opt_index);
int
wgetopt_long_only(int argc, wchar_t *const *argv, const wchar_t *options,
const struct woption *long_options, int *opt_index);
#endif
|