[svn-r20657] Description:

Correct check for pthreads routine from pthread_join() to pthread_self()
as intended.

Tested on
        FreeBSD/32 6.3 (duty) in debug mode
        FreeBSD/64 6.3 (liberty) w/C++ & FORTRAN, in debug mode
        FreeBSD/32 8.2 (loyalty) w/gcc4.6, w/C++ & FORTRAN, in debug mode
        FreeBSD/64 8.2 (freedom) w/gcc4.6, w/C++ & FORTRAN, in debug mode
        Linux/32 2.6 (jam) w/PGI compilers, w/default API=1.8.x,
                w/C++ & FORTRAN, w/threadsafe, in debug mode
        Linux/64-amd64 2.6 (koala) w/Intel compilers, w/default API=1.6.x,
                w/C++ & FORTRAN, in production mode
        Solaris/32 2.10 (linew) w/deprecated symbols disabled, w/C++ & FORTRAN,
                w/szip filter, w/threadsafe, in production mode
        Linux/PPC 2.6 (heiwa) w/C++ & FORTRAN, w/threadsafe, in debug mode
        Linux/64-ia64 2.6 (ember) w/Intel compilers, w/C++ & FORTRAN,
                in production mode
        Linux/64-amd64 2.6 (abe) w/parallel, w/FORTRAN, in debug mode
This commit is contained in:
Quincey Koziol 2011-04-27 19:56:57 -05:00
parent 389c88e87c
commit de925f4b38
2 changed files with 36 additions and 36 deletions

64
configure vendored
View File

@ -1,5 +1,5 @@
#! /bin/sh
# From configure.in Id: configure.in 20640 2011-04-26 18:41:01Z lrknox .
# From configure.in Id: configure.in 20651 2011-04-26 21:41:41Z koziol .
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.68 for HDF5 1.9.81.
#
@ -25266,9 +25266,9 @@ fi
done
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join in -lpthread" >&5
$as_echo_n "checking for pthread_join in -lpthread... " >&6; }
if ${ac_cv_lib_pthread_pthread_join+:} false; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_self in -lpthread" >&5
$as_echo_n "checking for pthread_self in -lpthread... " >&6; }
if ${ac_cv_lib_pthread_pthread_self+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
@ -25282,7 +25282,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
#ifdef __cplusplus
extern "C"
#endif
char pthread_join ();
char pthread_self ();
#ifdef FC_DUMMY_MAIN
#ifndef FC_DUMMY_MAIN_EQ_F77
# ifdef __cplusplus
@ -25294,23 +25294,23 @@ char pthread_join ();
int
main ()
{
return pthread_join ();
return pthread_self ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_pthread_pthread_join=yes
ac_cv_lib_pthread_pthread_self=yes
else
ac_cv_lib_pthread_pthread_join=no
ac_cv_lib_pthread_pthread_self=no
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_join" >&5
$as_echo "$ac_cv_lib_pthread_pthread_join" >&6; }
if test "x$ac_cv_lib_pthread_pthread_join" = xyes; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_self" >&5
$as_echo "$ac_cv_lib_pthread_pthread_self" >&6; }
if test "x$ac_cv_lib_pthread_pthread_self" = xyes; then :
cat >>confdefs.h <<_ACEOF
#define HAVE_LIBPTHREAD 1
_ACEOF
@ -25391,9 +25391,9 @@ done
saved_AM_LDFLAGS="$AM_LDFLAGS"
LDFLAGS="$LDFLAGS -L$pthread_lib"
AM_LDFLAGS="$AM_LDFLAGS -L$pthread_lib"
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join in -lpthread" >&5
$as_echo_n "checking for pthread_join in -lpthread... " >&6; }
if ${ac_cv_lib_pthread_pthread_join+:} false; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_self in -lpthread" >&5
$as_echo_n "checking for pthread_self in -lpthread... " >&6; }
if ${ac_cv_lib_pthread_pthread_self+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
@ -25407,7 +25407,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
#ifdef __cplusplus
extern "C"
#endif
char pthread_join ();
char pthread_self ();
#ifdef FC_DUMMY_MAIN
#ifndef FC_DUMMY_MAIN_EQ_F77
# ifdef __cplusplus
@ -25419,23 +25419,23 @@ char pthread_join ();
int
main ()
{
return pthread_join ();
return pthread_self ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_pthread_pthread_join=yes
ac_cv_lib_pthread_pthread_self=yes
else
ac_cv_lib_pthread_pthread_join=no
ac_cv_lib_pthread_pthread_self=no
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_join" >&5
$as_echo "$ac_cv_lib_pthread_pthread_join" >&6; }
if test "x$ac_cv_lib_pthread_pthread_join" = xyes; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_self" >&5
$as_echo "$ac_cv_lib_pthread_pthread_self" >&6; }
if test "x$ac_cv_lib_pthread_pthread_self" = xyes; then :
cat >>confdefs.h <<_ACEOF
#define HAVE_LIBPTHREAD 1
_ACEOF
@ -25448,9 +25448,9 @@ fi
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join in -lpthread" >&5
$as_echo_n "checking for pthread_join in -lpthread... " >&6; }
if ${ac_cv_lib_pthread_pthread_join+:} false; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_self in -lpthread" >&5
$as_echo_n "checking for pthread_self in -lpthread... " >&6; }
if ${ac_cv_lib_pthread_pthread_self+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
@ -25464,7 +25464,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
#ifdef __cplusplus
extern "C"
#endif
char pthread_join ();
char pthread_self ();
#ifdef FC_DUMMY_MAIN
#ifndef FC_DUMMY_MAIN_EQ_F77
# ifdef __cplusplus
@ -25476,23 +25476,23 @@ char pthread_join ();
int
main ()
{
return pthread_join ();
return pthread_self ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_pthread_pthread_join=yes
ac_cv_lib_pthread_pthread_self=yes
else
ac_cv_lib_pthread_pthread_join=no
ac_cv_lib_pthread_pthread_self=no
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_join" >&5
$as_echo "$ac_cv_lib_pthread_pthread_join" >&6; }
if test "x$ac_cv_lib_pthread_pthread_join" = xyes; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_self" >&5
$as_echo "$ac_cv_lib_pthread_pthread_self" >&6; }
if test "x$ac_cv_lib_pthread_pthread_self" = xyes; then :
cat >>confdefs.h <<_ACEOF
#define HAVE_LIBPTHREAD 1
_ACEOF
@ -25535,7 +25535,7 @@ $as_echo "no" >&6; }
int
main ()
{
pthread_join()
pthread_self()
;
return 0;
}

View File

@ -1839,7 +1839,7 @@ AC_ARG_WITH([pthread],
case "$withval" in
yes)
AC_CHECK_HEADERS([pthread.h])
AC_CHECK_LIB([pthread], [pthread_join],, [unset PTHREAD])
AC_CHECK_LIB([pthread], [pthread_self],, [unset PTHREAD])
;;
no)
AC_MSG_CHECKING([for pthread])
@ -1884,11 +1884,11 @@ case "$withval" in
saved_AM_LDFLAGS="$AM_LDFLAGS"
LDFLAGS="$LDFLAGS -L$pthread_lib"
AM_LDFLAGS="$AM_LDFLAGS -L$pthread_lib"
AC_CHECK_LIB([pthread], [pthread_join],,
AC_CHECK_LIB([pthread], [pthread_self],,
[LDFLAGS="$saved_LDFLAGS"; AM_LDFLAGS="$saved_AM_LDFLAGS"; unset PTHREAD])
else
AC_CHECK_LIB([pthread], [pthread_join],, [unset PTHREAD])
AC_CHECK_LIB([pthread], [pthread_self],, [unset PTHREAD])
fi
;;
esac
@ -1908,7 +1908,7 @@ case "X-$THREADSAFE" in
;;
X-yes)
dnl Check that we can link a simple Pthread program.
AC_TRY_LINK(, [pthread_join()],
AC_TRY_LINK(, [pthread_self()],
[AC_MSG_RESULT([yes]); THREADSAFE=yes],
[AC_MSG_ERROR([needed pthread library not available])])
;;