From: Amos Jeffries Date: Sun, 5 Feb 2017 06:15:44 +0000 (+1300) Subject: Bug 4661: compile error 'warning: _XPG4_2 redefined' with GCC on Solaris 10 X-Git-Tag: SQUID_4_0_18~3 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c72e15877b6326f6708e556c72586d06b32311af;p=thirdparty%2Fsquid.git Bug 4661: compile error 'warning: _XPG4_2 redefined' with GCC on Solaris 10 --- diff --git a/compat/os/solaris.h b/compat/os/solaris.h index adc630fbe2..dd738b4dd1 100644 --- a/compat/os/solaris.h +++ b/compat/os/solaris.h @@ -48,10 +48,12 @@ typedef union { #include SQUIDCEXTERN int getrusage(int, struct rusage *); +#if defined(__SUNPRO_CC) // Solaris 11 needs this before to get the definition for msg_control // and possibly other type definitions we dont know about specifically #define _XPG4_2 1 #include +#endif /** * prototypes for system function missing from system includes