From 4a0f4851ab0122ade7fe841d605776170f7bb3ee Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Sun, 2 Oct 2011 00:49:52 -0400 Subject: [PATCH] Patched to compile on Mac OS X (I think). --- src/thread/pthread/SDL_systhread.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/thread/pthread/SDL_systhread.c b/src/thread/pthread/SDL_systhread.c index 472aef864..334d33abc 100644 --- a/src/thread/pthread/SDL_systhread.c +++ b/src/thread/pthread/SDL_systhread.c @@ -73,20 +73,14 @@ SDL_SYS_CreateThread(SDL_Thread * thread, void *args) return (0); } -/* make pthread_setname_np() a weak reference even without SDK support. */ -#if __MACOSX__ && (MAC_OS_X_VERSION_MAX_ALLOWED < 1060) -int pthread_setname_np(const char*) __attribute__((weak_import,visibility("default"))); -#elif __IPHONEOS__ && (__IPHONE_OS_VERSION_MAX_ALLOWED < 30200) -int pthread_setname_np(const char*) __attribute__((weak_import)); -#endif - void SDL_SYS_SetupThread(const char *name) { int i; sigset_t mask; -#if __MACOSX__ || __IPHONEOS__ +#if ( (__MACOSX__ && (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)) || \ + (__IPHONEOS__ && (__IPHONE_OS_VERSION_MAX_ALLOWED >= 30200)) ) if (pthread_setname_np != NULL) { pthread_setname_np(name); } #elif HAVE_PTHREAD_SETNAME_NP pthread_setname_np(pthread_self(), name);