diff options
Diffstat (limited to 'include/private/gcconfig.h')
-rw-r--r-- | include/private/gcconfig.h | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/include/private/gcconfig.h b/include/private/gcconfig.h index a35f4edb..c21c38ca 100644 --- a/include/private/gcconfig.h +++ b/include/private/gcconfig.h @@ -2656,15 +2656,27 @@ #endif #if !defined(CAN_HANDLE_FORK) && !defined(NO_HANDLE_FORK) \ - && ((defined(GC_PTHREADS) && !defined(HURD) && !defined(NACL) \ - && !defined(PLATFORM_ANDROID) && !defined(GC_WIN32_PTHREADS) \ - && !defined(USE_WINALLOC)) \ + && !defined(HAVE_NO_FORK) \ + && ((defined(GC_PTHREADS) && !defined(NACL) \ + && !defined(GC_WIN32_PTHREADS) && !defined(USE_WINALLOC)) \ || (defined(DARWIN) && defined(MPROTECT_VDB)) || defined(HANDLE_FORK)) /* Attempts (where supported and requested) to make GC_malloc work in */ /* a child process fork'ed from a multi-threaded parent. */ # define CAN_HANDLE_FORK #endif +#if defined(CAN_HANDLE_FORK) && !defined(CAN_CALL_ATFORK) \ + && !defined(HURD) && !defined(PLATFORM_ANDROID) + /* Have working pthread_atfork(). */ +# define CAN_CALL_ATFORK +#endif + +#if !defined(CAN_HANDLE_FORK) && !defined(HAVE_NO_FORK) \ + && (defined(MSWIN32) || defined(MSWINCE) || defined(DOS4GW) \ + || defined(OS2) || defined(SYMBIAN) /* and probably others ... */) +# define HAVE_NO_FORK +#endif + #if !defined(USE_MARK_BITS) && !defined(USE_MARK_BYTES) \ && defined(PARALLEL_MARK) /* Minimize compare-and-swap usage. */ |