From: Ruben Kerkhof Date: Thu, 25 Dec 2014 13:24:47 +0000 (+0100) Subject: Fix a few warnings which show up with -Wundef X-Git-Tag: rec-3.7.0^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=82442a51b35dc9bc8e05632188ec72f6667d3e90;p=pdns Fix a few warnings which show up with -Wundef Also remove DARWIN, since OS X doesn't define that --- diff --git a/pdns/dns.hh b/pdns/dns.hh index 711ef1c21..63f65c7f9 100644 --- a/pdns/dns.hh +++ b/pdns/dns.hh @@ -144,7 +144,7 @@ struct EDNS0Record uint16_t Z; } GCCPACKATTRIBUTE; -#if __FreeBSD__ || __APPLE__ || __OpenBSD__ || __DragonFly__ || defined(__FreeBSD_kernel__) +#if defined(__FreeBSD__) || defined(__APPLE__) || defined(__OpenBSD__) || defined(__DragonFly__) || defined(__FreeBSD_kernel__) #include #elif __linux__ || __GNU__ # include diff --git a/pdns/unix_semaphore.cc b/pdns/unix_semaphore.cc index 50a350ebd..7064bc98d 100644 --- a/pdns/unix_semaphore.cc +++ b/pdns/unix_semaphore.cc @@ -34,7 +34,7 @@ #include -#if DARWIN || _AIX || __APPLE__ +#if defined(_AIX) || defined(__APPLE__) // Darwin 6.0 Compatible implementation, uses pthreads so it portable across more platforms. diff --git a/pdns/utility.hh b/pdns/utility.hh index 870ee2f3d..6280279c8 100644 --- a/pdns/utility.hh +++ b/pdns/utility.hh @@ -52,7 +52,7 @@ class Semaphore private: typedef int sem_value_t; -#if DARWIN || _AIX || __APPLE__ +#if defined(_AIX) || defined(__APPLE__) uint32_t m_magic; pthread_mutex_t m_lock; pthread_cond_t m_gtzero;