]> granicus.if.org Git - gc/commitdiff
Fix 'USE_MUNMAP requires USE_MMAP' compilation error on Cygwin
authorIvan Maidanski <ivmai@mail.ru>
Wed, 10 Apr 2019 20:42:11 +0000 (23:42 +0300)
committerIvan Maidanski <ivmai@mail.ru>
Wed, 10 Apr 2019 20:42:11 +0000 (23:42 +0300)
(fix of commit fdb655334)

* include/private/gcconfig.h [CYGWIN32] (MMAP_SUPPORTED): Do not define
if USE_WINALLOC.

include/private/gcconfig.h

index 16ce7ab1b48ad498062a285fd644f056ac144204..c7d8e00ad923ffbacadfef10966beb3f87bf0e07 100644 (file)
@@ -3106,10 +3106,11 @@ EXTERN_C_BEGIN
 # undef USE_MMAP
 #endif
 
-#if defined(CYGWIN32) || defined(DARWIN) || defined(FREEBSD) \
-    || defined(HAIKU) || defined(IRIX5) || defined(LINUX) || defined(NETBSD) \
+#if defined(DARWIN) || defined(FREEBSD) || defined(HAIKU) \
+    || defined(IRIX5) || defined(LINUX) || defined(NETBSD) \
     || defined(OPENBSD) || defined(SOLARIS) \
-    || ((defined(USE_MMAP) || defined(USE_MUNMAP)) && !defined(USE_WINALLOC))
+    || ((defined(CYGWIN32) || defined(USE_MMAP) || defined(USE_MUNMAP)) \
+        && !defined(USE_WINALLOC))
   /* Try both sbrk and mmap, in that order.     */
 # define MMAP_SUPPORTED
 #endif