From e13cbdb439b801685708231b18bca6181d8c4592 Mon Sep 17 00:00:00 2001 From: Igor Sysoev Date: Tue, 14 Mar 2017 19:52:57 +0300 Subject: Solaris compatibilty. --- src/nxt_unix.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/nxt_unix.h') diff --git a/src/nxt_unix.h b/src/nxt_unix.h index 6f2e280b..8bcc8825 100644 --- a/src/nxt_unix.h +++ b/src/nxt_unix.h @@ -69,7 +69,9 @@ #define _REENTRANT /* Thread safe errno. */ #endif +#ifndef _POSIX_PTHREAD_SEMANTICS #define _POSIX_PTHREAD_SEMANTICS /* 2 arguments in sigwait(). */ +#endif /* * Solaris provides two sockets API: @@ -84,7 +86,9 @@ #define _XOPEN_SOURCE #define _XOPEN_SOURCE_EXTENDED 1 /* Enable Solaris extensions disabled by _XOPEN_SOURCE. */ +#ifndef __EXTENSIONS__ #define __EXTENSIONS__ +#endif #endif /* NXT_SOLARIS */ @@ -92,7 +96,9 @@ #if (NXT_MACOSX) #define _XOPEN_SOURCE /* ucontext(3). */ +#ifndef _DARWIN_C_SOURCE #define _DARWIN_C_SOURCE /* pthread_threadid_np(), mach_port_t. */ +#endif #include /* mach_absolute_time(). */ #include /* malloc_size(). */ -- cgit