summaryrefslogtreecommitdiff
path: root/gc.c
diff options
context:
space:
mode:
Diffstat (limited to 'gc.c')
-rw-r--r--gc.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/gc.c b/gc.c
index 11f303f449..af4f4cc5f7 100644
--- a/gc.c
+++ b/gc.c
@@ -36,9 +36,11 @@
#if defined _WIN32 || defined __CYGWIN__
#include <windows.h>
-#endif
-
-#if !defined(__MINGW32__) && !defined(_WIN32) && !defined(__CYGWIN__) &&!defined(HAVE_POSIX_MEMALIGN) &&defined(HAVE_MEMALIGN)
+#elif defined(HAVE_POSIX_MEMALIGN)
+# ifdef __linux__ /* i386 linux needs #define _XOPEN_SOURCE 600 to use posix_memalign */
+# define _XOPEN_SOURCE 600
+# endif
+#elif defined(HAVE_MEMALIGN)
#include <malloc.h>
#endif