From 0312f0cd92e26d8097145d00dfad4638ed687f02 Mon Sep 17 00:00:00 2001 From: gdt Date: Wed, 10 Aug 2005 13:20:03 +0000 Subject: 2005-08-10 Greg Troxel * getopt.h: Don't declare getopt (rather than getopt_long), since quagga doesn't need it. * getopt.c (getopt): Don't define getopt. Fixes build breakage on NetBSD, and seems likely to work on most platforms since it avoids the entire issue of system getopt declarations and whether they conform to POSIX.2. Note that this change doesn't address system getopt_long declarations, but also doesn't change anything about getopt_long. --- lib/getopt.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'lib/getopt.c') diff --git a/lib/getopt.c b/lib/getopt.c index 329e9395..c784fb6c 100644 --- a/lib/getopt.c +++ b/lib/getopt.c @@ -969,6 +969,8 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only) } } +#ifdef REALLY_NEED_PLAIN_GETOPT + int getopt (argc, argv, optstring) int argc; @@ -981,6 +983,8 @@ getopt (argc, argv, optstring) 0); } +#endif /* REALLY_NEED_PLAIN_GETOPT */ + #endif /* Not ELIDE_CODE. */ #ifdef TEST -- cgit v1.2.1