diff options
author | Ivan Maidanski <ivmai@mail.ru> | 2020-04-19 09:31:55 +0300 |
---|---|---|
committer | Ivan Maidanski <ivmai@mail.ru> | 2021-08-21 01:04:29 +0300 |
commit | fc6befdde515249ef450369b5b01462007973b8e (patch) | |
tree | 057f39fab6f4333df6a67f2f540408b76cb6f1a9 | |
parent | 28ef4eeca3eb3ad231b6b4d540b6a9a739f93293 (diff) | |
download | bdwgc-fc6befdde515249ef450369b5b01462007973b8e.tar.gz |
Eliminate 'implicit declaration of sbrk' gcc warning if -std=c11 on Cygwin
(a cherry-pick of commit b78dd64a2 from 'master')
* include/private/gc_priv.h [__CYGWIN__ && !USE_MMAP && !_GNU_SOURCE]
(_GNU_SOURCE): Define.
-rw-r--r-- | include/private/gc_priv.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/private/gc_priv.h b/include/private/gc_priv.h index 6999df71..6f515d23 100644 --- a/include/private/gc_priv.h +++ b/include/private/gc_priv.h @@ -26,7 +26,8 @@ # define GC_BUILD #endif -#if (defined(__linux__) || defined(__GLIBC__) || defined(__GNU__)) \ +#if (defined(__linux__) || defined(__GLIBC__) || defined(__GNU__) \ + || (defined(__CYGWIN__) && !defined(USE_MMAP))) \ && !defined(_GNU_SOURCE) /* Can't test LINUX, since this must be defined before other includes. */ # define _GNU_SOURCE 1 |