aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3/config.h.in
diff options
context:
space:
mode:
authorJonathan Wakely <jwakely@redhat.com>2020-11-23 17:17:09 +0000
committerJonathan Wakely <jwakely@redhat.com>2020-11-23 18:12:39 +0000
commit92b47a321e14f98c524f6e67e7ecabad5afa7886 (patch)
tree10cdaf5fed7b640620d001b92c0ed8aef9195a29 /libstdc++-v3/config.h.in
parent183ae52b226898cc34aa51d4153cf0c006212a8a (diff)
downloadgcc-92b47a321e14f98c524f6e67e7ecabad5afa7886.zip
gcc-92b47a321e14f98c524f6e67e7ecabad5afa7886.tar.gz
gcc-92b47a321e14f98c524f6e67e7ecabad5afa7886.tar.bz2
libstdc++: Add configure checks for semaphores
This moves the checks for POSIX semaphores to configure time. As well as requiring <semaphore.h> and SEM_VALUE_MAX, we also require the sem_timedwait function. That was only optional in POSIX 2001 (and is absent on Darwin). libstdc++-v3/ChangeLog: * acinclude.m4 (GLIBCXX_CHECK_GTHREADS): Check for * config.h.in: Regenerate. * configure: Regenerate. * include/bits/semaphore_base.h (_GLIBCXX_HAVE_POSIX_SEMAPHORE): Check autoconf macro instead of defining it here.
Diffstat (limited to 'libstdc++-v3/config.h.in')
-rw-r--r--libstdc++-v3/config.h.in4
1 files changed, 4 insertions, 0 deletions
diff --git a/libstdc++-v3/config.h.in b/libstdc++-v3/config.h.in
index 8ae3e0f..72faabf 100644
--- a/libstdc++-v3/config.h.in
+++ b/libstdc++-v3/config.h.in
@@ -872,6 +872,10 @@
/* Define if gthreads library is available. */
#undef _GLIBCXX_HAS_GTHREADS
+/* Define to 1 if POSIX Semaphores with sem_timedwait are available in
+ <semaphore.h>. */
+#undef _GLIBCXX_HAVE_POSIX_SEMAPHORE
+
/* Define to 1 if a full hosted library is built, or 0 if freestanding. */
#undef _GLIBCXX_HOSTED