diff options
author | Alon Zakai <alonzakai@gmail.com> | 2012-09-21 18:14:43 -0700 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2012-09-21 18:14:43 -0700 |
commit | 0ca4dbb0f592a2a9db7c62fea450119407810605 (patch) | |
tree | c5a0ccafe8a5b6541271c63efa56cc3cfd9a2315 /system/include/libc | |
parent | 8d64c579f39715b078d2bed8f2e6497d2fe789d3 (diff) |
allow more pthreads header
Diffstat (limited to 'system/include/libc')
-rw-r--r-- | system/include/libc/pthread.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/system/include/libc/pthread.h b/system/include/libc/pthread.h index 1185fcc1..f99acbd6 100644 --- a/system/include/libc/pthread.h +++ b/system/include/libc/pthread.h @@ -27,7 +27,13 @@ extern "C" { #include <unistd.h> -#if defined(_POSIX_THREADS) || defined(EMSCRIPTEN) +#if EMSCRIPTEN + #define _POSIX_THREADS + #define _UNIX98_THREAD_MUTEX_ATTRIBUTES + #define _POSIX_READER_WRITER_LOCKS +#endif + +#if defined(_POSIX_THREADS) #include <sys/types.h> #include <time.h> @@ -46,7 +52,7 @@ int _EXFUN(pthread_mutexattr_getpshared, int _EXFUN(pthread_mutexattr_setpshared, (pthread_mutexattr_t *__attr, int __pshared)); -#if defined(_UNIX98_THREAD_MUTEX_ATTRIBUTES) || defined(EMSCRIPTEN) +#if defined(_UNIX98_THREAD_MUTEX_ATTRIBUTES) /* Single UNIX Specification 2 Mutex Attributes types */ |