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

Set _ALL_SOURCE for AIX, but avoid its struct list.

AIX 5.3 seems to need _ALL_SOURCE for struct addrinfo, but that introduces a struct list in grp.h. Signed-off-by: Jason Riedy <ejr@cs.berkeley.edu> Signed-off-by: Junio C Hamano <junkio@cox.net>

Jason Riedy committed Jan 15, 2007 at 17:34 UTC fb9522062c89da61f5ccbaa1d063e0754463176f
1 file changed +5 -2
git-compat-util.h
+5 -2
@@ -15,8 +15,9 @@
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
18 +#define _ALL_SOURCE 1
19 +#define _GNU_SOURCE 1
20 +#define _BSD_SOURCE 1
21
22 #include <unistd.h>
23 #include <stdio.h>
@@ -45,7 +46,9 @@
46 #include <arpa/inet.h>
47 #include <netdb.h>
48 #include <pwd.h>
49 +#undef _ALL_SOURCE /* AIX 5.3L defines a struct list with _ALL_SOURCE. */
50 #include <grp.h>
51 +#define _ALL_SOURCE 1
52
53 #ifndef NO_ICONV
54 #include <iconv.h>