mirror of
https://git.openldap.org/openldap/openldap.git
synced 2026-02-18 18:18:06 -05:00
Import support for -kthread from devel.
This commit is contained in:
parent
59c6327ae5
commit
ae153bedcb
2 changed files with 383 additions and 322 deletions
20
configure.in
20
configure.in
|
|
@ -393,6 +393,26 @@ if test $ol_with_threads = auto -o $ol_with_threads = yes \
|
|||
dnl Check for pthread support in current $LIBS
|
||||
AC_CHECK_FUNC(pthread_create,[ol_link_threads=yes])
|
||||
|
||||
if test $ol_link_threads = no ; then
|
||||
dnl try -kthread
|
||||
AC_CACHE_CHECK([for pthread_create with -kthread],
|
||||
[ol_cv_kthread_flag], [
|
||||
dnl save the flags
|
||||
save_LIBS="$LIBS"
|
||||
LIBS="-kthread $LIBS"
|
||||
AC_TRY_LINK([char pthread();],[
|
||||
pthread_create();
|
||||
], ol_cv_kthread_flag=yes, ol_cv_kthread_flag=no)
|
||||
dnl restore the LIBS
|
||||
LIBS="$save_LIBS"
|
||||
])
|
||||
|
||||
if test $ol_cv_kthread_flag = yes ; then
|
||||
LTHREAD_LIBS="$LTHREAD_LIBS -kthread"
|
||||
ol_link_threads=posix
|
||||
fi
|
||||
fi
|
||||
|
||||
if test $ol_link_threads = no ; then
|
||||
dnl try -pthread
|
||||
AC_CACHE_CHECK([for pthread_create with -pthread],
|
||||
|
|
|
|||
Loading…
Reference in a new issue