* m4/pthread-spin.m4 (gl_PTHREAD_SPIN): Mark the pthread_spin_*
functions as nonexistent when <pthread.h> exists but does not define
the pthread_spinlock_t type.
+2019-11-21 Bruno Haible <bruno@clisp.org>
+
+ pthread-spin: Fix errors in C++ mode.
+ * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): Mark the pthread_spin_*
+ functions as nonexistent when <pthread.h> exists but does not define
+ the pthread_spinlock_t type.
+
2019-11-21 Bruno Haible <bruno@clisp.org>
pthread-mutex: Fix errors in C++ mode.
-# pthread-spin.m4 serial 1
+# pthread-spin.m4 serial 2
dnl Copyright (C) 2019 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
REPLACE_PTHREAD_SPIN_UNLOCK=1
REPLACE_PTHREAD_SPIN_DESTROY=1
else
- if test $HAVE_PTHREAD_H = 0; then
+ if test $HAVE_PTHREAD_H = 0 || test $HAVE_PTHREAD_SPINLOCK_T = 0; then
HAVE_PTHREAD_SPIN_INIT=0
HAVE_PTHREAD_SPIN_LOCK=0
HAVE_PTHREAD_SPIN_TRYLOCK=0