mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-23 20:05:32 +02:00
build: Support pthread builds without 'pthread_cancel' support (Android).
Reported by Sylvain Beucler <beuc@beuc.net>. * configure.ac: Check for 'pthread_cancel'. * libguile/threads.c (scm_cancel_thread): Conditionalize on !SCM_USE_PTHREAD_THREADS || defined HAVE_PTHREAD_CANCEL. * test-suite/tests/threads.test (require-cancel-thread): New procedure. ("timed joining fails if timeout exceeded", "join-thread returns timeoutval on timeout", "cancel succeeds", "handler result passed to join", "can cancel self"): Use it.
This commit is contained in:
parent
8c75d3ae01
commit
f184e887a6
3 changed files with 23 additions and 2 deletions
|
@ -1371,8 +1371,11 @@ case "$with_threads" in
|
|||
# pthread_attr_get_np - "np" meaning "non portable" says it
|
||||
# all; specific to FreeBSD
|
||||
# pthread_sigmask - not available on mingw
|
||||
# pthread_cancel - not available on Android (Bionic libc)
|
||||
#
|
||||
AC_CHECK_FUNCS(pthread_attr_getstack pthread_getattr_np pthread_get_stackaddr_np pthread_attr_get_np pthread_sigmask)
|
||||
AC_CHECK_FUNCS([pthread_attr_getstack pthread_getattr_np \
|
||||
pthread_get_stackaddr_np pthread_attr_get_np pthread_sigmask \
|
||||
pthread_cancel])
|
||||
|
||||
# On past versions of Solaris, believe 8 through 10 at least, you
|
||||
# had to write "pthread_once_t foo = { PTHREAD_ONCE_INIT };".
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue