diff options
author | Vincent Sanders <vince@netsurf-browser.org> | 2010-04-24 15:22:17 +0000 |
---|---|---|
committer | Vincent Sanders <vince@netsurf-browser.org> | 2010-04-24 15:22:17 +0000 |
commit | 03bb3e863663a034434b000fbfce2de7e908ba24 (patch) | |
tree | 0527de17bf999b709511880217423cea13a2ad51 /utils/config.h | |
parent | fe151c135d3ffe3dff155d51f4f2680024ae8382 (diff) | |
download | netsurf-03bb3e863663a034434b000fbfce2de7e908ba24.tar.gz netsurf-03bb3e863663a034434b000fbfce2de7e908ba24.tar.bz2 |
remove _GNU_SOURCE define from everywhere.
strndup is not standard so provide an implementation.
svn path=/trunk/netsurf/; revision=10474
Diffstat (limited to 'utils/config.h')
-rw-r--r-- | utils/config.h | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/utils/config.h b/utils/config.h index ba8d8227b..ba6d9b464 100644 --- a/utils/config.h +++ b/utils/config.h @@ -23,19 +23,10 @@ /* Try to detect which features the target OS supports */ -#define HAVE_STRNDUP -#if defined(__FreeBSD__) || (defined(__SRV4) && defined(__sun)) || \ - defined(__APPLE__) || defined(__HAIKU__) || defined(__BEOS__) \ - || defined(__OpenBSD__) || defined(_WIN32) - /* FreeBSD and Solaris do not have this function, so - * we implement it ourselves in util.c - */ -#undef HAVE_STRNDUP char *strndup(const char *s, size_t n); -#endif #define HAVE_STRCASESTR -#if (!(defined(_GNU_SOURCE) || defined(__NetBSD__) || defined(__OpenBSD__)) \ +#if (!(defined(__NetBSD__) || defined(__OpenBSD__)) \ || defined(riscos) || defined(__APPLE__) || defined(_WIN32)) #undef HAVE_STRCASESTR char *strcasestr(const char *haystack, const char *needle); @@ -64,7 +55,7 @@ char *strcasestr(const char *haystack, const char *needle); #define HAVE_STRCHRNUL /* For some reason, UnixLib defines this unconditionally. * Assume we're using UnixLib if building for RISC OS. */ -#if !(defined(_GNU_SOURCE) || defined(riscos)) +#if !(defined(riscos)) #undef HAVE_STRCHRNUL char *strchrnul(const char *s, int c); #endif |