summaryrefslogtreecommitdiff
path: root/gnu/usr.bin/bc/lib/getopt.c
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/usr.bin/bc/lib/getopt.c')
-rw-r--r--gnu/usr.bin/bc/lib/getopt.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gnu/usr.bin/bc/lib/getopt.c b/gnu/usr.bin/bc/lib/getopt.c
index 23ce0648b79..e838269b799 100644
--- a/gnu/usr.bin/bc/lib/getopt.c
+++ b/gnu/usr.bin/bc/lib/getopt.c
@@ -57,7 +57,7 @@ Cambridge, MA 02139, USA. */
/* This needs to come after some library #include
to get __GNU_LIBRARY__ defined. */
-#ifdef __GNU_LIBRARY__
+#if defined(__GNU_LIBRARY__) || defined(__OpenBSD__)
/* Don't include stdlib.h for non-GNU C libraries because some of them
contain conflicting prototypes for getopt. */
#include <stdlib.h>
@@ -159,7 +159,7 @@ static enum
/* Value of POSIXLY_CORRECT environment variable. */
static char *posixly_correct;
-#ifdef __GNU_LIBRARY__
+#if defined(__GNU_LIBRARY__) || defined(__OpenBSD__)
/* We want to avoid inclusion of string.h with non-GNU libraries
because there are many ways it can cause trouble.
On some systems, it contains special magic macros that don't work