@matheusbsbs / matheus-bagliano / commits / c902c9a608
Fork 0

Fix system header problems on Mac OS X

For Mac OS X 10.4, _XOPEN_SOURCE defines _POSIX_C_SOURCE which hides many symbols from the program. Breakage noticed and initial analysis provided by Randal L. Schwartz. Signed-off-by: Junio C Hamano <junkio@cox.net>

Terje Sten Bjerkseth committed Dec 20, 2006 at 17:32 UTC c902c9a608c1b727160d6fbb04fa363d9418cd00
1 file changed +2
git-compat-util.h
+2
@@ -11,8 +11,10 @@
11
12 #define ARRAY_SIZE(x) (sizeof(x)/sizeof(x[0]))
13
14 +#ifndef __APPLE_CC__
15 #define _XOPEN_SOURCE 600 /* glibc2 and AIX 5.3L need 500, OpenBSD needs 600 for S_ISLNK() */
16 #define _XOPEN_SOURCE_EXTENDED 1 /* AIX 5.3L needs this */
17 +#endif
18 #define _GNU_SOURCE
19 #define _BSD_SOURCE
20