diff options
author | Ian Lynagh <ian@well-typed.com> | 2012-12-01 23:22:48 +0000 |
---|---|---|
committer | Ian Lynagh <ian@well-typed.com> | 2012-12-01 23:22:48 +0000 |
commit | 0cb35b5514e6280ba330bd3a4acb8e6a71c300ff (patch) | |
tree | 2e54a29c75705a124d0b2295580b700b411ba1b8 /rts/posix | |
parent | fe1fce87ae08c58dff821c5d6b905cb9b600d423 (diff) | |
download | haskell-0cb35b5514e6280ba330bd3a4acb8e6a71c300ff.tar.gz |
Mac OS X 10.6 needed for pthread_threadid_np(), fixes #7356
Based on a patch from Thorkil Naur.
Diffstat (limited to 'rts/posix')
-rw-r--r-- | rts/posix/OSThreads.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/rts/posix/OSThreads.c b/rts/posix/OSThreads.c index 2fa56704cb..ae31966c1c 100644 --- a/rts/posix/OSThreads.c +++ b/rts/posix/OSThreads.c @@ -337,7 +337,8 @@ KernelThreadId kernelThreadId (void) #elif defined(freebsd_HOST_OS) && (__FreeBSD_version >= 900031) return pthread_getthreadid_np(); -#elif defined(darwin_HOST_OS) +// Check for OS X >= 10.6 (see #7356) +#elif defined(darwin_HOST_OS) && !(defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && __MAC_OS_X_VERSION_MIN_REQUIRED < 1060) uint64_t ktid; pthread_threadid_np(NULL, &ktid); return ktid; |