From 07f7c968ba1cb926a91a506e889611eaf839bfb2 Mon Sep 17 00:00:00 2001 From: Joel Brobecker Date: Fri, 29 Nov 2002 00:31:43 +0000 Subject: [PATCH] * configure.in: Check that the pthdebug library is recent enough before enabling thread support on native AiX. * configure: Regenerate. * config/powerpc/aix432.mh (NATDEPFILES): Remove aix-thread.o from the list of object files as it is now appended by configure if thread support is enabled. (NAT_CLIBS): Removed as -lpthdebug is also appended by configure if thread support is enabled. --- gdb/ChangeLog | 12 +++ gdb/config/powerpc/aix432.mh | 4 +- gdb/configure | 153 +++++++++++++++++++++-------------- gdb/configure.in | 26 ++++-- 4 files changed, 128 insertions(+), 67 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 9791ad486dc..5980d4422a9 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,15 @@ +2002-11-28 J. Brobecker + + * configure.in: Check that the pthdebug library is recent enough + before enabling thread support on native AiX. + * configure: Regenerate. + + * config/powerpc/aix432.mh (NATDEPFILES): Remove aix-thread.o + from the list of object files as it is now appended by configure + if thread support is enabled. + (NAT_CLIBS): Removed as -lpthdebug is also appended by configure + if thread support is enabled. + 2002-11-25 Daniel Jacobowitz * acconfig.h (HAVE_PREAD64): Add. diff --git a/gdb/config/powerpc/aix432.mh b/gdb/config/powerpc/aix432.mh index fc74eb73026..f69e61a2ecb 100644 --- a/gdb/config/powerpc/aix432.mh +++ b/gdb/config/powerpc/aix432.mh @@ -3,7 +3,7 @@ XM_FILE= xm-aix.h NAT_FILE= nm-aix.h -NATDEPFILES= aix-thread.o fork-child.o infptrace.o inftarg.o corelow.o \ +NATDEPFILES= fork-child.o infptrace.o inftarg.o corelow.o \ rs6000-nat.o xcoffread.o xcoffsolib.o # When compiled with cc, for debugging, this argument should be passed. @@ -15,5 +15,3 @@ NATDEPFILES= aix-thread.o fork-child.o infptrace.o inftarg.o corelow.o \ # This switch may be needed for some vendor compilers. # MH_LDFLAGS = -Wl,-bbigtoc -# pthread debugging support -NAT_CLIBS = -lpthdebug diff --git a/gdb/configure b/gdb/configure index 5f82a3f52c4..56e21f22fdf 100755 --- a/gdb/configure +++ b/gdb/configure @@ -6540,6 +6540,41 @@ EOF echo "$ac_t""no" 1>&6 fi ;; + aix*) + echo $ac_n "checking for AiX thread debugging library""... $ac_c" 1>&6 +echo "configure:6546: checking for AiX thread debugging library" >&5 + if eval "test \"`echo '$''{'gdb_cv_have_aix_thread_debug'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +int main() { +#ifndef PTHDB_VERSION_3 + #error + #endif +; return 0; } +EOF +if { (eval echo configure:6560: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + gdb_cv_have_aix_thread_debug=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + gdb_cv_have_aix_thread_debug=no +fi +rm -f conftest* +fi + + echo "$ac_t""$gdb_cv_have_aix_thread_debug" 1>&6 + if test $gdb_cv_have_aix_thread_debug = yes; then + CONFIG_SRCS="${CONFIG_SRCS} aix-thread.c" + CONFIG_LIB_OBS="${CONFIG_LIB_OBS} aix-thread.o" + CONFIG_LDFLAGS="${CONFIG_LDFLAGS} -lpthdebug" + fi + ;; esac fi @@ -6550,14 +6585,14 @@ if test $host = $target; then save_CFLAGS=$CFLAGS CFLAGS="$CFLAGS -D_BSD_SOURCE -D_XOPEN_SOURCE=500 -D_LARGEFILE64_SOURCE" cat > conftest.$ac_ext < int main() { pread64 (0, NULL, 0, 0); ; return 0; } EOF -if { (eval echo configure:6561: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6596: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ENABLE_CFLAGS="$ENABLE_CFLAGS -D_BSD_SOURCE -D_XOPEN_SOURCE=500 -D_LARGEFILE64_SOURCE" cat >> confdefs.h <<\EOF @@ -6765,7 +6800,7 @@ WERROR_CFLAGS="" if test "x${build_warnings}" != x -a "x$GCC" = xyes then echo $ac_n "checking compiler warning flags""... $ac_c" 1>&6 -echo "configure:6769: checking compiler warning flags" >&5 +echo "configure:6804: checking compiler warning flags" >&5 # Separate out the -Werror flag as some files just cannot be # compiled with it enabled. for w in ${build_warnings}; do @@ -6775,14 +6810,14 @@ echo "configure:6769: checking compiler warning flags" >&5 saved_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS $w" cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:6821: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* WARN_CFLAGS="${WARN_CFLAGS} $w" else @@ -6842,12 +6877,12 @@ fi if test $want_included_regex = false; then echo $ac_n "checking for GNU regex""... $ac_c" 1>&6 -echo "configure:6846: checking for GNU regex" >&5 +echo "configure:6881: checking for GNU regex" >&5 if eval "test \"`echo '$''{'gdb_cv_have_gnu_regex'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #include @@ -6859,7 +6894,7 @@ int main() { ; return 0; } EOF -if { (eval echo configure:6863: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:6898: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* gdb_cv_have_gnu_regex=yes else @@ -6888,12 +6923,12 @@ fi # In the Cygwin environment, we need some additional flags. echo $ac_n "checking for cygwin""... $ac_c" 1>&6 -echo "configure:6892: checking for cygwin" >&5 +echo "configure:6927: checking for cygwin" >&5 if eval "test \"`echo '$''{'gdb_cv_os_cygwin'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&6 -echo "configure:6935: checking for tgetent in -lncurses" >&5 +echo "configure:6970: checking for tgetent in -lncurses" >&5 ac_lib_var=`echo ncurses'_'tgetent | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -6939,7 +6974,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lncurses $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6989: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -6969,7 +7004,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for tgetent in -lHcurses""... $ac_c" 1>&6 -echo "configure:6973: checking for tgetent in -lHcurses" >&5 +echo "configure:7008: checking for tgetent in -lHcurses" >&5 ac_lib_var=`echo Hcurses'_'tgetent | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -6977,7 +7012,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lHcurses $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7027: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7007,7 +7042,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for tgetent in -ltermlib""... $ac_c" 1>&6 -echo "configure:7011: checking for tgetent in -ltermlib" >&5 +echo "configure:7046: checking for tgetent in -ltermlib" >&5 ac_lib_var=`echo termlib'_'tgetent | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -7015,7 +7050,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ltermlib $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7065: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7045,7 +7080,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for tgetent in -ltermcap""... $ac_c" 1>&6 -echo "configure:7049: checking for tgetent in -ltermcap" >&5 +echo "configure:7084: checking for tgetent in -ltermcap" >&5 ac_lib_var=`echo termcap'_'tgetent | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -7053,7 +7088,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ltermcap $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7103: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7083,7 +7118,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for tgetent in -lcurses""... $ac_c" 1>&6 -echo "configure:7087: checking for tgetent in -lcurses" >&5 +echo "configure:7122: checking for tgetent in -lcurses" >&5 ac_lib_var=`echo curses'_'tgetent | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -7091,7 +7126,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lcurses $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7141: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7121,7 +7156,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for tgetent in -lterminfo""... $ac_c" 1>&6 -echo "configure:7125: checking for tgetent in -lterminfo" >&5 +echo "configure:7160: checking for tgetent in -lterminfo" >&5 ac_lib_var=`echo terminfo'_'tgetent | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -7129,7 +7164,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lterminfo $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7179: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7305,7 +7340,7 @@ if test "${with_tclconfig+set}" = set; then fi echo $ac_n "checking for Tcl configuration""... $ac_c" 1>&6 -echo "configure:7309: checking for Tcl configuration" >&5 +echo "configure:7344: checking for Tcl configuration" >&5 if eval "test \"`echo '$''{'ac_cv_c_tclconfig'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7413,7 +7448,7 @@ if test "${with_tkconfig+set}" = set; then fi echo $ac_n "checking for Tk configuration""... $ac_c" 1>&6 -echo "configure:7417: checking for Tk configuration" >&5 +echo "configure:7452: checking for Tk configuration" >&5 if eval "test \"`echo '$''{'ac_cv_c_tkconfig'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7522,7 +7557,7 @@ fi no_tcl=true echo $ac_n "checking for Tcl private headers. dir=${configdir}""... $ac_c" 1>&6 -echo "configure:7526: checking for Tcl private headers. dir=${configdir}" >&5 +echo "configure:7561: checking for Tcl private headers. dir=${configdir}" >&5 # Check whether --with-tclinclude or --without-tclinclude was given. if test "${with_tclinclude+set}" = set; then withval="$with_tclinclude" @@ -7588,17 +7623,17 @@ fi if test x"${ac_cv_c_tclh}" = x ; then ac_safe=`echo "tclInt.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for tclInt.h""... $ac_c" 1>&6 -echo "configure:7592: checking for tclInt.h" >&5 +echo "configure:7627: checking for tclInt.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7602: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7637: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -7658,7 +7693,7 @@ fi # no_tk=true echo $ac_n "checking for Tk private headers""... $ac_c" 1>&6 -echo "configure:7662: checking for Tk private headers" >&5 +echo "configure:7697: checking for Tk private headers" >&5 # Check whether --with-tkinclude or --without-tkinclude was given. if test "${with_tkinclude+set}" = set; then withval="$with_tkinclude" @@ -7724,17 +7759,17 @@ fi if test x"${ac_cv_c_tkh}" = x ; then ac_safe=`echo "tk.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for tk.h""... $ac_c" 1>&6 -echo "configure:7728: checking for tk.h" >&5 +echo "configure:7763: checking for tk.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7738: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7773: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -7780,7 +7815,7 @@ fi echo $ac_n "checking for Itcl private headers. srcdir=${srcdir}""... $ac_c" 1>&6 -echo "configure:7784: checking for Itcl private headers. srcdir=${srcdir}" >&5 +echo "configure:7819: checking for Itcl private headers. srcdir=${srcdir}" >&5 if test x"${ac_cv_c_itclh}" = x ; then for i in ${srcdir}/../itcl ${srcdir}/../../itcl ${srcdir}/../../../itcl ${srcdir}/../itcl/itcl; do if test -f $i/generic/itcl.h ; then @@ -7803,7 +7838,7 @@ fi echo $ac_n "checking for Itk private headers. srcdir=${srcdir}""... $ac_c" 1>&6 -echo "configure:7807: checking for Itk private headers. srcdir=${srcdir}" >&5 +echo "configure:7842: checking for Itk private headers. srcdir=${srcdir}" >&5 if test x"${ac_cv_c_itkh}" = x ; then for i in ${srcdir}/../itcl ${srcdir}/../../itcl ${srcdir}/../../../itcl ${srcdir}/../itcl/itk; do if test -f $i/generic/itk.h ; then @@ -7826,7 +7861,7 @@ fi echo $ac_n "checking for Tix private headers. srcdir=${srcdir}""... $ac_c" 1>&6 -echo "configure:7830: checking for Tix private headers. srcdir=${srcdir}" >&5 +echo "configure:7865: checking for Tix private headers. srcdir=${srcdir}" >&5 if test x"${ac_cv_c_tixh}" = x ; then for i in ${srcdir}/../tix ${srcdir}/../../tix ${srcdir}/../../../tix ; do if test -f $i/generic/tix.h ; then @@ -7878,7 +7913,7 @@ if test "${with_itclconfig+set}" = set; then fi echo $ac_n "checking for Itcl configuration""... $ac_c" 1>&6 -echo "configure:7882: checking for Itcl configuration" >&5 +echo "configure:7917: checking for Itcl configuration" >&5 if eval "test \"`echo '$''{'ac_cv_c_itclconfig'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7981,7 +8016,7 @@ if test "${with_itkconfig+set}" = set; then fi echo $ac_n "checking for Itk configuration""... $ac_c" 1>&6 -echo "configure:7985: checking for Itk configuration" >&5 +echo "configure:8020: checking for Itk configuration" >&5 if eval "test \"`echo '$''{'ac_cv_c_itkconfig'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -8084,7 +8119,7 @@ if test "${with_tixconfig+set}" = set; then fi echo $ac_n "checking for Tix configuration""... $ac_c" 1>&6 -echo "configure:8088: checking for Tix configuration" >&5 +echo "configure:8123: checking for Tix configuration" >&5 if eval "test \"`echo '$''{'ac_cv_c_tixconfig'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -8230,7 +8265,7 @@ fi # Uses ac_ vars as temps to allow command line to override cache and checks. # --without-x overrides everything else, but does not touch the cache. echo $ac_n "checking for X""... $ac_c" 1>&6 -echo "configure:8234: checking for X" >&5 +echo "configure:8269: checking for X" >&5 # Check whether --with-x or --without-x was given. if test "${with_x+set}" = set; then @@ -8292,12 +8327,12 @@ if test "$ac_x_includes" = NO; then # First, try using that file with no special directory specified. cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:8301: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:8336: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -8366,14 +8401,14 @@ if test "$ac_x_libraries" = NO; then ac_save_LIBS="$LIBS" LIBS="-l$x_direct_test_library $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8412: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* LIBS="$ac_save_LIBS" # We can link X programs with no special library path. @@ -8665,7 +8700,7 @@ fi # ``gdbserver'' can only be built in a native configuration. if test x"${target}" = x"${host}"; then echo $ac_n "checking whether gdbserver is supported on this host""... $ac_c" 1>&6 -echo "configure:8669: checking whether gdbserver is supported on this host" >&5 +echo "configure:8704: checking whether gdbserver is supported on this host" >&5 if test x"${build_gdbserver}" = xyes ; then configdirs="${configdirs} gdbserver" SUBDIRS="${SUBDIRS} gdbserver" @@ -8727,7 +8762,7 @@ fi echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 -echo "configure:8731: checking whether ln -s works" >&5 +echo "configure:8766: checking whether ln -s works" >&5 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -8751,12 +8786,12 @@ fi echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6 -echo "configure:8755: checking for Cygwin environment" >&5 +echo "configure:8790: checking for Cygwin environment" >&5 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:8806: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_cygwin=yes else @@ -8784,19 +8819,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6 CYGWIN= test "$ac_cv_cygwin" = yes && CYGWIN=yes echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6 -echo "configure:8788: checking for mingw32 environment" >&5 +echo "configure:8823: checking for mingw32 environment" >&5 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:8835: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_mingw32=yes else @@ -8815,7 +8850,7 @@ test "$ac_cv_mingw32" = yes && MINGW32=yes echo $ac_n "checking for executable suffix""... $ac_c" 1>&6 -echo "configure:8819: checking for executable suffix" >&5 +echo "configure:8854: checking for executable suffix" >&5 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -8825,7 +8860,7 @@ else rm -f conftest* echo 'int main () { return 0; }' > conftest.$ac_ext ac_cv_exeext= - if { (eval echo configure:8829: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then + if { (eval echo configure:8864: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then for file in conftest.*; do case $file in *.c | *.o | *.obj | *.ilk | *.pdb) ;; diff --git a/gdb/configure.in b/gdb/configure.in index 61bf5e7d757..a0bcb543b6f 100644 --- a/gdb/configure.in +++ b/gdb/configure.in @@ -532,12 +532,12 @@ aix*) ;; esac -dnl See if thread_db library is around for Solaris thread debugging. Note that -dnl we must explicitly test for version 1 of the library because version 0 -dnl (present on Solaris 2.4 or earlier) doesn't have the same API. -dnl Note that we only want this if we are both native (host == target), and -dnl not doing a canadian cross build (build == host). +dnl For certain native configurations, we need to check whether thread +dnl support can be built in or not. +dnl +dnl Note that we only want this if we are both native (host == target), +dnl and not doing a canadian cross build (build == host). if test ${build} = ${host} -a ${host} = ${target} ; then case ${host_os} in @@ -596,6 +596,22 @@ if test ${build} = ${host} -a ${host} = ${target} ; then AC_MSG_RESULT(no) fi ;; + aix*) + AC_MSG_CHECKING(for AiX thread debugging library) + AC_CACHE_VAL(gdb_cv_have_aix_thread_debug, + [AC_TRY_COMPILE([#include ], + [#ifndef PTHDB_VERSION_3 + #error + #endif], + gdb_cv_have_aix_thread_debug=yes, + gdb_cv_have_aix_thread_debug=no)]) + AC_MSG_RESULT($gdb_cv_have_aix_thread_debug) + if test $gdb_cv_have_aix_thread_debug = yes; then + CONFIG_SRCS="${CONFIG_SRCS} aix-thread.c" + CONFIG_LIB_OBS="${CONFIG_LIB_OBS} aix-thread.o" + CONFIG_LDFLAGS="${CONFIG_LDFLAGS} -lpthdebug" + fi + ;; esac AC_SUBST(CONFIG_LDFLAGS) fi -- 2.47.2