summaryrefslogtreecommitdiff
path: root/util.h
diff options
context:
space:
mode:
authorPeter Johnson <peter@tortall.net>2003-07-12 19:44:30 +0000
committerPeter Johnson <peter@tortall.net>2003-07-12 19:44:30 +0000
commit2748972397ec7adfd98b2360e54e9558bbafc0d9 (patch)
tree35f91afa128b168a43f662eeabc8c69096928371 /util.h
parent7071b20131907fb186e8bc47a33d250340b380eb (diff)
downloadyasm-2748972397ec7adfd98b2360e54e9558bbafc0d9.tar.gz
Avoid warnings in strsep due to glibc's bits/string2.h string inlining by
defining __NO_STRING_INLINES in strsep.c. Due to string.h inclusion in util.h, extra level of indirection is needed (NO_STRING_INLINES->__NO_STRING_INLINES). svn path=/trunk/yasm/; revision=1004
Diffstat (limited to 'util.h')
-rw-r--r--util.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/util.h b/util.h
index b1ac6770..f7c0968f 100644
--- a/util.h
+++ b/util.h
@@ -34,9 +34,18 @@
#include <config.h>
#endif
+#ifdef HAVE_GNU_C_LIBRARY
+
/* Work around glibc's non-defining of certain things when using gcc -ansi */
-#if defined(HAVE_GNU_C_LIBRARY) && defined(__STRICT_ANSI__)
-# undef __STRICT_ANSI__
+# ifdef __STRICT_ANSI__
+# undef __STRICT_ANSI__
+# endif
+
+/* Work around glibc's string inlines (in bits/string2.h) if needed */
+# ifdef NO_STRING_INLINES
+# define __NO_STRING_INLINES
+# endif
+
#endif
#if !defined(lint) && !defined(NDEBUG)