summaryrefslogtreecommitdiff
path: root/libc/sysdeps/linux/common/bits/uClibc_local_lim.h
diff options
context:
space:
mode:
Diffstat (limited to 'libc/sysdeps/linux/common/bits/uClibc_local_lim.h')
-rw-r--r--libc/sysdeps/linux/common/bits/uClibc_local_lim.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/libc/sysdeps/linux/common/bits/uClibc_local_lim.h b/libc/sysdeps/linux/common/bits/uClibc_local_lim.h
index abfc86de5..832051cd7 100644
--- a/libc/sysdeps/linux/common/bits/uClibc_local_lim.h
+++ b/libc/sysdeps/linux/common/bits/uClibc_local_lim.h
@@ -11,14 +11,19 @@
#define _BITS_UCLIBC_LOCAL_LIM_H 1
/* This file works correctly only if local_lim.h is the NPTL version */
-#if !defined PTHREAD_KEYS_MAX || defined TIMER_MAX
+#if !defined PTHREAD_KEYS_MAX || defined TIMER_MAX || !defined SEM_VALUE_MAX
# error local_lim.h was incorrectly updated, use the NPTL version from glibc
#endif
/* This should really be moved to thread specific directories */
#if defined __UCLIBC_HAS_THREADS__ && !defined __UCLIBC_HAS_THREADS_NATIVE__
+/* glibc uses 16384 */
# define PTHREAD_THREADS_MAX 1024
# define TIMER_MAX 256
+# undef SEM_VALUE_MAX
+# undef PTHREAD_STACK_MIN
+/* glibc uses at least 16364 */
+# define PTHREAD_STACK_MIN 1024
#endif
#ifndef __UCLIBC_HAS_THREADS__
@@ -28,6 +33,7 @@
# undef PTHREAD_DESTRUCTOR_ITERATIONS
# undef PTHREAD_STACK_MIN
# undef DELAYTIMER_MAX
+# undef SEM_VALUE_MAX
#endif
#endif /* bits/uClibc_local_lim.h */