* include/getopt.h: Don't define getopt_long() and friends when
included through unistd.h.
This commit is contained in:
parent
efeae9a317
commit
6d114a5dea
@ -1,3 +1,8 @@
|
|||||||
|
2001-12-17 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
|
* include/getopt.h: Don't define getopt_long() and friends when
|
||||||
|
included through unistd.h.
|
||||||
|
|
||||||
2001-12-17 Christopher Faylor <cgf@redhat.com>
|
2001-12-17 Christopher Faylor <cgf@redhat.com>
|
||||||
|
|
||||||
* dtable.cc (dtable::init_std_file_from_handle): Avoid initializing
|
* dtable.cc (dtable::init_std_file_from_handle): Avoid initializing
|
||||||
|
@ -38,13 +38,6 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
struct option {
|
|
||||||
const char *name;
|
|
||||||
int has_arg;
|
|
||||||
int *flag;
|
|
||||||
int val;
|
|
||||||
};
|
|
||||||
|
|
||||||
extern int opterr; /* if error message should be printed */
|
extern int opterr; /* if error message should be printed */
|
||||||
extern int optind; /* index into parent argv vector */
|
extern int optind; /* index into parent argv vector */
|
||||||
extern int optopt; /* character checked for validity */
|
extern int optopt; /* character checked for validity */
|
||||||
@ -53,6 +46,27 @@ extern char *optarg; /* argument associated with option */
|
|||||||
|
|
||||||
int getopt (int, char * const *, const char *);
|
int getopt (int, char * const *, const char *);
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif /* __GETOPT_H__ */
|
||||||
|
|
||||||
|
#ifndef __UNISTD_GETOPT__
|
||||||
|
#ifndef __GETOPT_LONG_H__
|
||||||
|
#define __GETOPT_LONG_H__
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C" {
|
||||||
|
#endif
|
||||||
|
|
||||||
|
struct option {
|
||||||
|
const char *name;
|
||||||
|
int has_arg;
|
||||||
|
int *flag;
|
||||||
|
int val;
|
||||||
|
};
|
||||||
|
|
||||||
int getopt_long (int, char *const *, const char *, const struct option *, int *);
|
int getopt_long (int, char *const *, const char *, const struct option *, int *);
|
||||||
#define HAVE_DECL_GETOPT 1
|
#define HAVE_DECL_GETOPT 1
|
||||||
|
|
||||||
@ -64,4 +78,5 @@ int getopt_long (int, char *const *, const char *, const struct option *, int *)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif /* __GETOPT_H__ */
|
#endif /* __GETOPT_LONG_H__ */
|
||||||
|
#endif /* __UNISTD_GETOPT__ */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user