Add test for thread specific h_errno and, if yes, add thread libraries

to lib.
This commit is contained in:
Kurt Zeilenga 1999-06-07 05:30:05 +00:00
parent e2050a74d0
commit cc3785eaab
2 changed files with 584 additions and 545 deletions

1117
configure vendored

File diff suppressed because it is too large Load diff

View file

@ -1122,7 +1122,17 @@ if test $ol_link_threads != no ; then
[ol_cv_errno_thread_specific=no])
])
if test $ol_cv_errno_thread_specific != yes ; then
dnl The h_errno declaration may dependent upon _REENTRANT.
dnl If it does, we must link with thread support.
AC_CACHE_CHECK([for thread specific h_errno],
[ol_cv_h_errno_thread_specific], [
AC_TRY_LINK([#include <netdb.h>], [h_errno = 0;],
[ol_cv_h_errno_thread_specific=yes],
[ol_cv_h_errno_thread_specific=no])
])
if test $ol_cv_errno_thread_specific != yes \
-o $ol_cv_h_errno_thread_specific != yes ; then
LIBS="$LTHREAD_LIBS $LIBS"
LTHREAD_LIBS=""
fi