diff options
author | das <das> | 2006-01-10 05:37:01 (GMT) |
---|---|---|
committer | das <das> | 2006-01-10 05:37:01 (GMT) |
commit | 8eaa65820026962a38882685aa573977b5b9069a (patch) | |
tree | 0f1739b270d436e622b09a4ffa995666382bf82e | |
parent | 38ee79dc06785b01c4638025cb206a4bd275d29f (diff) | |
download | tcl-8eaa65820026962a38882685aa573977b5b9069a.zip tcl-8eaa65820026962a38882685aa573977b5b9069a.tar.gz tcl-8eaa65820026962a38882685aa573977b5b9069a.tar.bz2 |
* unix/configure: add caching, use AC_CACHE_CHECK instead of
* unix/configure.in: AC_CACHE_VAL where possible, consistent message
* unix/tcl.m4: quoting, sync relevant tclconfig/tcl.m4 and HEAD
changes and gratuitous formatting differences, fix SC_CONFIG_MANPAGES
with default argument, Darwin improvements to SC_LOAD_*CONFIG.
-rw-r--r-- | ChangeLog | 8 | ||||
-rwxr-xr-x | unix/configure | 1267 | ||||
-rw-r--r-- | unix/configure.in | 142 | ||||
-rw-r--r-- | unix/tcl.m4 | 476 |
4 files changed, 1051 insertions, 842 deletions
@@ -1,3 +1,11 @@ +2006-01-10 Daniel Steffen <das@users.sourceforge.net> + + * unix/configure: add caching, use AC_CACHE_CHECK instead of + * unix/configure.in: AC_CACHE_VAL where possible, consistent message + * unix/tcl.m4: quoting, sync relevant tclconfig/tcl.m4 and HEAD + changes and gratuitous formatting differences, fix SC_CONFIG_MANPAGES + with default argument, Darwin improvements to SC_LOAD_*CONFIG. + 2006-01-09 Don Porter <dgp@users.sourceforge.net> * generic/tclNamesp.c (NamespaceInscopeCmd): [namespace inscope] diff --git a/unix/configure b/unix/configure index 97281c5..5ce4285 100755 --- a/unix/configure +++ b/unix/configure @@ -575,8 +575,9 @@ TCL_SRC_DIR=`cd $srcdir/..; pwd` # Compress and/or soft link the manpages? #------------------------------------------------------------------------ + echo $ac_n "checking whether to use symlinks for manpages""... $ac_c" 1>&6 -echo "configure:580: checking whether to use symlinks for manpages" >&5 +echo "configure:581: checking whether to use symlinks for manpages" >&5 # Check whether --enable-man-symlinks or --disable-man-symlinks was given. if test "${enable_man_symlinks+set}" = set; then enableval="$enable_man_symlinks" @@ -588,12 +589,15 @@ fi echo "$ac_t""$enableval" 1>&6 echo $ac_n "checking whether to compress the manpages""... $ac_c" 1>&6 -echo "configure:592: checking whether to compress the manpages" >&5 +echo "configure:593: checking whether to compress the manpages" >&5 # Check whether --enable-man-compression or --disable-man-compression was given. if test "${enable_man_compression+set}" = set; then enableval="$enable_man_compression" - test "$enableval" = "yes" && { echo "configure: error: missing argument to --enable-man-compression" 1>&2; exit 1; } - test "$enableval" != "no" && MAN_FLAGS="$MAN_FLAGS --compress $enableval" + case $enableval in + yes) { echo "configure: error: missing argument to --enable-man-compression" 1>&2; exit 1; };; + no) ;; + *) MAN_FLAGS="$MAN_FLAGS --compress $enableval";; + esac else enableval="no" fi @@ -601,7 +605,7 @@ fi echo "$ac_t""$enableval" 1>&6 if test "$enableval" != "no"; then echo $ac_n "checking for compressed file suffix""... $ac_c" 1>&6 -echo "configure:605: checking for compressed file suffix" >&5 +echo "configure:609: checking for compressed file suffix" >&5 touch TeST $enableval TeST Z=`ls TeST* | sed 's/^....//'` @@ -611,12 +615,15 @@ echo "configure:605: checking for compressed file suffix" >&5 fi echo $ac_n "checking whether to add a package name suffix for the manpages""... $ac_c" 1>&6 -echo "configure:615: checking whether to add a package name suffix for the manpages" >&5 +echo "configure:619: checking whether to add a package name suffix for the manpages" >&5 # Check whether --enable-man-suffix or --disable-man-suffix was given. if test "${enable_man_suffix+set}" = set; then enableval="$enable_man_suffix" - test "$enableval" = "yes" && enableval="tcl" - test "$enableval" != "no" && MAN_FLAGS="$MAN_FLAGS --suffix $enableval" + case $enableval in + yes) enableval="tcl" MAN_FLAGS="$MAN_FLAGS --suffix $enableval";; + no) ;; + *) MAN_FLAGS="$MAN_FLAGS --suffix $enableval";; + esac else enableval="no" fi @@ -639,7 +646,7 @@ fi # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:643: checking for $ac_word" >&5 +echo "configure:650: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -669,7 +676,7 @@ if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:673: checking for $ac_word" >&5 +echo "configure:680: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -720,7 +727,7 @@ fi # Extract the first word of "cl", so it can be a program name with args. set dummy cl; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:724: checking for $ac_word" >&5 +echo "configure:731: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -752,7 +759,7 @@ fi fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 -echo "configure:756: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +echo "configure:763: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 ac_ext=c # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. @@ -763,12 +770,12 @@ cross_compiling=$ac_cv_prog_cc_cross cat > conftest.$ac_ext << EOF -#line 767 "configure" +#line 774 "configure" #include "confdefs.h" main(){return(0);} EOF -if { (eval echo configure:772: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:779: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ac_cv_prog_cc_works=yes # If we can't run a trivial program, we are probably using a cross compiler. if (./conftest; exit) 2>/dev/null; then @@ -794,12 +801,12 @@ if test $ac_cv_prog_cc_works = no; then { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 -echo "configure:798: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +echo "configure:805: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 cross_compiling=$ac_cv_prog_cc_cross echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 -echo "configure:803: checking whether we are using GNU C" >&5 +echo "configure:810: checking whether we are using GNU C" >&5 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -808,7 +815,7 @@ else yes; #endif EOF -if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:812: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then +if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:819: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then ac_cv_prog_gcc=yes else ac_cv_prog_gcc=no @@ -827,7 +834,7 @@ ac_test_CFLAGS="${CFLAGS+set}" ac_save_CFLAGS="$CFLAGS" CFLAGS= echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 -echo "configure:831: checking whether ${CC-cc} accepts -g" >&5 +echo "configure:838: checking whether ${CC-cc} accepts -g" >&5 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -860,17 +867,16 @@ fi #-------------------------------------------------------------------- -# Supply substitutes for missing POSIX header files. Special -# notes: -# - stdlib.h doesn't define strtol, strtoul, or -# strtod insome versions of SunOS -# - some versions of string.h don't declare procedures such -# as strstr +# Supply substitutes for missing POSIX header files. Special notes: +# - stdlib.h doesn't define strtol, strtoul, or +# strtod insome versions of SunOS +# - some versions of string.h don't declare procedures such +# as strstr # Do this early, otherwise an autoconf bug throws errors on configure #-------------------------------------------------------------------- echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 -echo "configure:874: checking how to run the C preprocessor" >&5 +echo "configure:880: checking how to run the C preprocessor" >&5 # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= @@ -885,13 +891,13 @@ else # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. cat > conftest.$ac_ext <<EOF -#line 889 "configure" +#line 895 "configure" #include "confdefs.h" #include <assert.h> Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:895: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:901: \"$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 : @@ -902,13 +908,13 @@ else rm -rf conftest* CPP="${CC-cc} -E -traditional-cpp" cat > conftest.$ac_ext <<EOF -#line 906 "configure" +#line 912 "configure" #include "confdefs.h" #include <assert.h> Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:912: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:918: \"$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 : @@ -919,13 +925,13 @@ else rm -rf conftest* CPP="${CC-cc} -nologo -E" cat > conftest.$ac_ext <<EOF -#line 923 "configure" +#line 929 "configure" #include "confdefs.h" #include <assert.h> Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:929: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:935: \"$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 : @@ -951,12 +957,12 @@ echo "$ac_t""$CPP" 1>&6 echo $ac_n "checking dirent.h""... $ac_c" 1>&6 -echo "configure:955: checking dirent.h" >&5 - if eval "test \"`echo '$''{'tcl_cv_dirent_h'+set}'`\" = set"; then +echo "configure:961: checking dirent.h" >&5 +if eval "test \"`echo '$''{'tcl_cv_dirent_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 960 "configure" +#line 966 "configure" #include "confdefs.h" #include <sys/types.h> #include <dirent.h> @@ -982,7 +988,7 @@ closedir(d); ; return 0; } EOF -if { (eval echo configure:986: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:992: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* tcl_cv_dirent_h=yes else @@ -994,6 +1000,7 @@ fi rm -f conftest* fi +echo "$ac_t""$tcl_cv_dirent_h" 1>&6 if test $tcl_cv_dirent_h = no; then cat >> confdefs.h <<\EOF @@ -1002,20 +1009,19 @@ EOF fi - echo "$ac_t""$tcl_ok" 1>&6 ac_safe=`echo "errno.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for errno.h""... $ac_c" 1>&6 -echo "configure:1009: checking for errno.h" >&5 +echo "configure:1015: checking for errno.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 -#line 1014 "configure" +#line 1020 "configure" #include "confdefs.h" #include <errno.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1019: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1025: \"$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* @@ -1042,17 +1048,17 @@ fi ac_safe=`echo "float.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for float.h""... $ac_c" 1>&6 -echo "configure:1046: checking for float.h" >&5 +echo "configure:1052: checking for float.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 -#line 1051 "configure" +#line 1057 "configure" #include "confdefs.h" #include <float.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1056: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1062: \"$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* @@ -1079,17 +1085,17 @@ fi ac_safe=`echo "values.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for values.h""... $ac_c" 1>&6 -echo "configure:1083: checking for values.h" >&5 +echo "configure:1089: checking for values.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 -#line 1088 "configure" +#line 1094 "configure" #include "confdefs.h" #include <values.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1093: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1099: \"$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* @@ -1116,17 +1122,17 @@ fi ac_safe=`echo "limits.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for limits.h""... $ac_c" 1>&6 -echo "configure:1120: checking for limits.h" >&5 +echo "configure:1126: checking for limits.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 -#line 1125 "configure" +#line 1131 "configure" #include "confdefs.h" #include <limits.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1130: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1136: \"$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* @@ -1156,17 +1162,17 @@ fi ac_safe=`echo "stdlib.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for stdlib.h""... $ac_c" 1>&6 -echo "configure:1160: checking for stdlib.h" >&5 +echo "configure:1166: checking for stdlib.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 -#line 1165 "configure" +#line 1171 "configure" #include "confdefs.h" #include <stdlib.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1170: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1176: \"$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* @@ -1189,7 +1195,7 @@ tcl_ok=0 fi cat > conftest.$ac_ext <<EOF -#line 1193 "configure" +#line 1199 "configure" #include "confdefs.h" #include <stdlib.h> EOF @@ -1203,7 +1209,7 @@ fi rm -f conftest* cat > conftest.$ac_ext <<EOF -#line 1207 "configure" +#line 1213 "configure" #include "confdefs.h" #include <stdlib.h> EOF @@ -1217,7 +1223,7 @@ fi rm -f conftest* cat > conftest.$ac_ext <<EOF -#line 1221 "configure" +#line 1227 "configure" #include "confdefs.h" #include <stdlib.h> EOF @@ -1238,17 +1244,17 @@ EOF fi ac_safe=`echo "string.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for string.h""... $ac_c" 1>&6 -echo "configure:1242: checking for string.h" >&5 +echo "configure:1248: checking for string.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 -#line 1247 "configure" +#line 1253 "configure" #include "confdefs.h" #include <string.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1252: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1258: \"$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* @@ -1271,7 +1277,7 @@ tcl_ok=0 fi cat > conftest.$ac_ext <<EOF -#line 1275 "configure" +#line 1281 "configure" #include "confdefs.h" #include <string.h> EOF @@ -1285,7 +1291,7 @@ fi rm -f conftest* cat > conftest.$ac_ext <<EOF -#line 1289 "configure" +#line 1295 "configure" #include "confdefs.h" #include <string.h> EOF @@ -1311,17 +1317,17 @@ EOF ac_safe=`echo "sys/wait.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for sys/wait.h""... $ac_c" 1>&6 -echo "configure:1315: checking for sys/wait.h" >&5 +echo "configure:1321: checking for sys/wait.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 -#line 1320 "configure" +#line 1326 "configure" #include "confdefs.h" #include <sys/wait.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1325: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1331: \"$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* @@ -1348,17 +1354,17 @@ fi ac_safe=`echo "dlfcn.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for dlfcn.h""... $ac_c" 1>&6 -echo "configure:1352: checking for dlfcn.h" >&5 +echo "configure:1358: checking for dlfcn.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 -#line 1357 "configure" +#line 1363 "configure" #include "confdefs.h" #include <dlfcn.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1362: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1368: \"$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* @@ -1389,17 +1395,17 @@ fi do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:1393: checking for $ac_hdr" >&5 +echo "configure:1399: checking for $ac_hdr" >&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 -#line 1398 "configure" +#line 1404 "configure" #include "confdefs.h" #include <$ac_hdr> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1403: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1409: \"$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* @@ -1435,18 +1441,18 @@ done if test -z "$no_pipe"; then if test -n "$GCC"; then echo $ac_n "checking if the compiler understands -pipe""... $ac_c" 1>&6 -echo "configure:1439: checking if the compiler understands -pipe" >&5 +echo "configure:1445: checking if the compiler understands -pipe" >&5 OLDCC="$CC" CC="$CC -pipe" cat > conftest.$ac_ext <<EOF -#line 1443 "configure" +#line 1449 "configure" #include "confdefs.h" int main() { ; return 0; } EOF -if { (eval echo configure:1450: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1456: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* echo "$ac_t""yes" 1>&6 else @@ -1465,8 +1471,6 @@ fi #------------------------------------------------------------------------ - echo $ac_n "checking for building with threads""... $ac_c" 1>&6 -echo "configure:1470: checking for building with threads" >&5 # Check whether --enable-threads or --disable-threads was given. if test "${enable_threads+set}" = set; then enableval="$enable_threads" @@ -1476,17 +1480,12 @@ else fi + if test "${TCL_THREADS}" = 1; then + tcl_threaded_core=1; + fi + if test "$tcl_ok" = "yes" -o "${TCL_THREADS}" = 1; then - if test "${TCL_THREADS}" = 1; then - echo "$ac_t""yes (threaded core)" 1>&6 - else - echo "$ac_t""yes" 1>&6 - fi TCL_THREADS=1 - cat >> confdefs.h <<\EOF -#define TCL_THREADS 1 -EOF - # USE_THREAD_ALLOC tells us to try the special thread-based # allocator that significantly reduces lock contention cat >> confdefs.h <<\EOF @@ -1508,7 +1507,7 @@ EOF EOF echo $ac_n "checking for pthread_mutex_init in -lpthread""... $ac_c" 1>&6 -echo "configure:1512: checking for pthread_mutex_init in -lpthread" >&5 +echo "configure:1511: checking for pthread_mutex_init in -lpthread" >&5 ac_lib_var=`echo pthread'_'pthread_mutex_init | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1516,7 +1515,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lpthread $LIBS" cat > conftest.$ac_ext <<EOF -#line 1520 "configure" +#line 1519 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -1527,7 +1526,7 @@ int main() { pthread_mutex_init() ; return 0; } EOF -if { (eval echo configure:1531: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1530: \"$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 @@ -1555,7 +1554,7 @@ fi # pthread.h, but that will work with libpthread really doesn't # exist, like AIX 4.2. [Bug: 4359] echo $ac_n "checking for __pthread_mutex_init in -lpthread""... $ac_c" 1>&6 -echo "configure:1559: checking for __pthread_mutex_init in -lpthread" >&5 +echo "configure:1558: checking for __pthread_mutex_init in -lpthread" >&5 ac_lib_var=`echo pthread'_'__pthread_mutex_init | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1563,7 +1562,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lpthread $LIBS" cat > conftest.$ac_ext <<EOF -#line 1567 "configure" +#line 1566 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -1574,7 +1573,7 @@ int main() { __pthread_mutex_init() ; return 0; } EOF -if { (eval echo configure:1578: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1577: \"$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 @@ -1602,7 +1601,7 @@ fi THREADS_LIBS=" -lpthread" else echo $ac_n "checking for pthread_mutex_init in -lpthreads""... $ac_c" 1>&6 -echo "configure:1606: checking for pthread_mutex_init in -lpthreads" >&5 +echo "configure:1605: checking for pthread_mutex_init in -lpthreads" >&5 ac_lib_var=`echo pthreads'_'pthread_mutex_init | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1610,7 +1609,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lpthreads $LIBS" cat > conftest.$ac_ext <<EOF -#line 1614 "configure" +#line 1613 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -1621,7 +1620,7 @@ int main() { pthread_mutex_init() ; return 0; } EOF -if { (eval echo configure:1625: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1624: \"$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 @@ -1647,7 +1646,7 @@ fi THREADS_LIBS=" -lpthreads" else echo $ac_n "checking for pthread_mutex_init in -lc""... $ac_c" 1>&6 -echo "configure:1651: checking for pthread_mutex_init in -lc" >&5 +echo "configure:1650: checking for pthread_mutex_init in -lc" >&5 ac_lib_var=`echo c'_'pthread_mutex_init | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1655,7 +1654,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lc $LIBS" cat > conftest.$ac_ext <<EOF -#line 1659 "configure" +#line 1658 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -1666,7 +1665,7 @@ int main() { pthread_mutex_init() ; return 0; } EOF -if { (eval echo configure:1670: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1669: \"$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 @@ -1687,9 +1686,9 @@ else tcl_ok=no fi - if test "$tcl_ok" = "no"; then + if test "$tcl_ok" = "no"; then echo $ac_n "checking for pthread_mutex_init in -lc_r""... $ac_c" 1>&6 -echo "configure:1693: checking for pthread_mutex_init in -lc_r" >&5 +echo "configure:1692: checking for pthread_mutex_init in -lc_r" >&5 ac_lib_var=`echo c_r'_'pthread_mutex_init | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1697,7 +1696,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lc_r $LIBS" cat > conftest.$ac_ext <<EOF -#line 1701 "configure" +#line 1700 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -1708,7 +1707,7 @@ int main() { pthread_mutex_init() ; return 0; } EOF -if { (eval echo configure:1712: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1711: \"$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 @@ -1734,9 +1733,9 @@ fi THREADS_LIBS=" -pthread" else TCL_THREADS=0 - echo "configure: warning: "Don t know how to find pthread lib on your system - you must disable thread support or edit the LIBS in the Makefile..."" 1>&2 + echo "configure: warning: Don't know how to find pthread lib on your system - you must disable thread support or edit the LIBS in the Makefile..." 1>&2 fi - fi + fi fi fi @@ -1748,12 +1747,12 @@ fi for ac_func in pthread_attr_setstacksize do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:1752: checking for $ac_func" >&5 +echo "configure:1751: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1757 "configure" +#line 1756 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -1776,7 +1775,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:1780: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1779: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -1803,12 +1802,12 @@ done for ac_func in pthread_atfork do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:1807: checking for $ac_func" >&5 +echo "configure:1806: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1812 "configure" +#line 1811 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -1831,7 +1830,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:1835: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1834: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -1858,8 +1857,24 @@ done LIBS=$ac_saved_libs else TCL_THREADS=0 + fi + # Do checking message here to not mess up interleaved configure output + echo $ac_n "checking for building with threads""... $ac_c" 1>&6 +echo "configure:1864: checking for building with threads" >&5 + if test "${TCL_THREADS}" = 1; then + cat >> confdefs.h <<\EOF +#define TCL_THREADS 1 +EOF + + if test "${tcl_threaded_core}" = 1; then + echo "$ac_t""yes (threaded core)" 1>&6 + else + echo "$ac_t""yes" 1>&6 + fi + else echo "$ac_t""no (default)" 1>&6 fi + @@ -1876,12 +1891,12 @@ done #-------------------------------------------------------------------- echo $ac_n "checking for sin""... $ac_c" 1>&6 -echo "configure:1880: checking for sin" >&5 +echo "configure:1895: checking for sin" >&5 if eval "test \"`echo '$''{'ac_cv_func_sin'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 1885 "configure" +#line 1900 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char sin(); below. */ @@ -1904,7 +1919,7 @@ sin(); ; return 0; } EOF -if { (eval echo configure:1908: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1923: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_sin=yes" else @@ -1925,7 +1940,7 @@ MATH_LIBS="-lm" fi echo $ac_n "checking for main in -lieee""... $ac_c" 1>&6 -echo "configure:1929: checking for main in -lieee" >&5 +echo "configure:1944: checking for main in -lieee" >&5 ac_lib_var=`echo ieee'_'main | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1933,14 +1948,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lieee $LIBS" cat > conftest.$ac_ext <<EOF -#line 1937 "configure" +#line 1952 "configure" #include "confdefs.h" int main() { main() ; return 0; } EOF -if { (eval echo configure:1944: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1959: \"$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 @@ -1967,7 +1982,7 @@ fi #-------------------------------------------------------------------- echo $ac_n "checking for main in -linet""... $ac_c" 1>&6 -echo "configure:1971: checking for main in -linet" >&5 +echo "configure:1986: checking for main in -linet" >&5 ac_lib_var=`echo inet'_'main | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1975,14 +1990,14 @@ else ac_save_LIBS="$LIBS" LIBS="-linet $LIBS" cat > conftest.$ac_ext <<EOF -#line 1979 "configure" +#line 1994 "configure" #include "confdefs.h" int main() { main() ; return 0; } EOF -if { (eval echo configure:1986: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2001: \"$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 @@ -2004,17 +2019,17 @@ fi ac_safe=`echo "net/errno.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for net/errno.h""... $ac_c" 1>&6 -echo "configure:2008: checking for net/errno.h" >&5 +echo "configure:2023: checking for net/errno.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 -#line 2013 "configure" +#line 2028 "configure" #include "confdefs.h" #include <net/errno.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2018: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:2033: \"$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* @@ -2059,12 +2074,12 @@ fi tcl_checkBoth=0 echo $ac_n "checking for connect""... $ac_c" 1>&6 -echo "configure:2063: checking for connect" >&5 +echo "configure:2078: checking for connect" >&5 if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2068 "configure" +#line 2083 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char connect(); below. */ @@ -2087,7 +2102,7 @@ connect(); ; return 0; } EOF -if { (eval echo configure:2091: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2106: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_connect=yes" else @@ -2109,12 +2124,12 @@ fi if test "$tcl_checkSocket" = 1; then echo $ac_n "checking for setsockopt""... $ac_c" 1>&6 -echo "configure:2113: checking for setsockopt" >&5 +echo "configure:2128: checking for setsockopt" >&5 if eval "test \"`echo '$''{'ac_cv_func_setsockopt'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2118 "configure" +#line 2133 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char setsockopt(); below. */ @@ -2137,7 +2152,7 @@ setsockopt(); ; return 0; } EOF -if { (eval echo configure:2141: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2156: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_setsockopt=yes" else @@ -2155,7 +2170,7 @@ if eval "test \"`echo '$ac_cv_func_'setsockopt`\" = yes"; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for setsockopt in -lsocket""... $ac_c" 1>&6 -echo "configure:2159: checking for setsockopt in -lsocket" >&5 +echo "configure:2174: checking for setsockopt in -lsocket" >&5 ac_lib_var=`echo socket'_'setsockopt | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2163,7 +2178,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lsocket $LIBS" cat > conftest.$ac_ext <<EOF -#line 2167 "configure" +#line 2182 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -2174,7 +2189,7 @@ int main() { setsockopt() ; return 0; } EOF -if { (eval echo configure:2178: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2193: \"$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 @@ -2202,12 +2217,12 @@ fi tk_oldLibs=$LIBS LIBS="$LIBS -lsocket -lnsl" echo $ac_n "checking for accept""... $ac_c" 1>&6 -echo "configure:2206: checking for accept" >&5 +echo "configure:2221: checking for accept" >&5 if eval "test \"`echo '$''{'ac_cv_func_accept'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2211 "configure" +#line 2226 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char accept(); below. */ @@ -2230,7 +2245,7 @@ accept(); ; return 0; } EOF -if { (eval echo configure:2234: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2249: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_accept=yes" else @@ -2252,12 +2267,12 @@ fi fi echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 -echo "configure:2256: checking for gethostbyname" >&5 +echo "configure:2271: checking for gethostbyname" >&5 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 2261 "configure" +#line 2276 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char gethostbyname(); below. */ @@ -2280,7 +2295,7 @@ gethostbyname(); ; return 0; } EOF -if { (eval echo configure:2284: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2299: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_gethostbyname=yes" else @@ -2298,7 +2313,7 @@ if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6 -echo "configure:2302: checking for gethostbyname in -lnsl" >&5 +echo "configure:2317: checking for gethostbyname in -lnsl" >&5 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2306,7 +2321,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lnsl $LIBS" cat > conftest.$ac_ext <<EOF -#line 2310 "configure" +#line 2325 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -2317,7 +2332,7 @@ int main() { gethostbyname() ; return 0; } EOF -if { (eval echo configure:2321: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2336: \"$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 @@ -2353,7 +2368,7 @@ LIBS="$LIBS$THREADS_LIBS" echo $ac_n "checking how to build libraries""... $ac_c" 1>&6 -echo "configure:2357: checking how to build libraries" >&5 +echo "configure:2372: checking how to build libraries" >&5 # Check whether --enable-shared or --disable-shared was given. if test "${enable_shared+set}" = set; then enableval="$enable_shared" @@ -2392,7 +2407,7 @@ EOF # Extract the first word of "ranlib", so it can be a program name with args. set dummy ranlib; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2396: checking for $ac_word" >&5 +echo "configure:2411: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2424,77 +2439,77 @@ fi # Step 0.a: Enable 64 bit support? echo $ac_n "checking if 64bit support is requested""... $ac_c" 1>&6 -echo "configure:2428: checking if 64bit support is requested" >&5 +echo "configure:2443: checking if 64bit support is requested" >&5 # Check whether --enable-64bit or --disable-64bit was given. if test "${enable_64bit+set}" = set; then enableval="$enable_64bit" - : + do64bit=$enableval else - enableval="no" + do64bit=no fi - - if test "$enableval" = "yes"; then - do64bit=yes - else - do64bit=no - fi echo "$ac_t""$do64bit" 1>&6 # Step 0.b: Enable Solaris 64 bit VIS support? echo $ac_n "checking if 64bit Sparc VIS support is requested""... $ac_c" 1>&6 -echo "configure:2448: checking if 64bit Sparc VIS support is requested" >&5 +echo "configure:2457: checking if 64bit Sparc VIS support is requested" >&5 # Check whether --enable-64bit-vis or --disable-64bit-vis was given. if test "${enable_64bit_vis+set}" = set; then enableval="$enable_64bit_vis" - : + do64bitVIS=$enableval else - enableval="no" + do64bitVIS=no fi + echo "$ac_t""$do64bitVIS" 1>&6 - if test "$enableval" = "yes"; then + if test "$do64bitVIS" = "yes"; then # Force 64bit on with VIS do64bit=yes - do64bitVIS=yes - else - do64bitVIS=no fi - echo "$ac_t""$do64bitVIS" 1>&6 # Step 1: set the variable "system" to hold the name and version number - # for the system. This can usually be done via the "uname" command, but - # there are a few systems, like Next, where this doesn't work. + # for the system. - echo $ac_n "checking system version (for dynamic loading)""... $ac_c" 1>&6 -echo "configure:2472: checking system version (for dynamic loading)" >&5 - if test -f /usr/lib/NextStep/software_version; then - system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version` - else - system=`uname -s`-`uname -r` - if test "$?" -ne 0 ; then - echo "$ac_t""unknown (can't find uname command)" 1>&6 - system=unknown + + echo $ac_n "checking system version""... $ac_c" 1>&6 +echo "configure:2478: checking system version" >&5 +if eval "test \"`echo '$''{'tcl_cv_sys_version'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + if test -f /usr/lib/NextStep/software_version; then + tcl_cv_sys_version=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version` else - # Special check for weird MP-RAS system (uname returns weird - # results, and the version is kept in special file). - - if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then - system=MP-RAS-`awk '{print }' /etc/.relid` - fi - if test "`uname -s`" = "AIX" ; then - system=AIX-`uname -v`.`uname -r` + tcl_cv_sys_version=`uname -s`-`uname -r` + if test "$?" -ne 0 ; then + echo "configure: warning: can't find uname command" 1>&2 + tcl_cv_sys_version=unknown + else + # Special check for weird MP-RAS system (uname returns weird + # results, and the version is kept in special file). + + if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then + tcl_cv_sys_version=MP-RAS-`awk '{print }' /etc/.relid` + fi + if test "`uname -s`" = "AIX" ; then + tcl_cv_sys_version=AIX-`uname -v`.`uname -r` + fi fi - echo "$ac_t""$system" 1>&6 fi - fi + +fi + +echo "$ac_t""$tcl_cv_sys_version" 1>&6 + system=$tcl_cv_sys_version + # Step 2: check for existence of -ldl library. This is needed because # Linux can use either -ldl or -ldld for dynamic loading. echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 -echo "configure:2498: checking for dlopen in -ldl" >&5 +echo "configure:2513: checking for dlopen in -ldl" >&5 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2502,7 +2517,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldl $LIBS" cat > conftest.$ac_ext <<EOF -#line 2506 "configure" +#line 2521 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -2513,7 +2528,7 @@ int main() { dlopen() ; return 0; } EOF -if { (eval echo configure:2517: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2532: \"$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 @@ -2561,7 +2576,7 @@ fi # Extract the first word of "ar", so it can be a program name with args. set dummy ar; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2565: checking for $ac_word" >&5 +echo "configure:2580: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2676,7 +2691,7 @@ fi # known GMT value. echo $ac_n "checking for gettimeofday in -lbsd""... $ac_c" 1>&6 -echo "configure:2680: checking for gettimeofday in -lbsd" >&5 +echo "configure:2695: checking for gettimeofday in -lbsd" >&5 ac_lib_var=`echo bsd'_'gettimeofday | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2684,7 +2699,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lbsd $LIBS" cat > conftest.$ac_ext <<EOF -#line 2688 "configure" +#line 2703 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -2695,7 +2710,7 @@ int main() { gettimeofday() ; return 0; } EOF -if { (eval echo configure:2699: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2714: \"$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 @@ -2738,7 +2753,7 @@ EOF # is always linked to, for compatibility. #----------------------------------------------------------- echo $ac_n "checking for inet_ntoa in -lbind""... $ac_c" 1>&6 -echo "configure:2742: checking for inet_ntoa in -lbind" >&5 +echo "configure:2757: checking for inet_ntoa in -lbind" >&5 ac_lib_var=`echo bind'_'inet_ntoa | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2746,7 +2761,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lbind $LIBS" cat > conftest.$ac_ext <<EOF -#line 2750 "configure" +#line 2765 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -2757,7 +2772,7 @@ int main() { inet_ntoa() ; return 0; } EOF -if { (eval echo configure:2761: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2776: \"$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 @@ -2823,7 +2838,7 @@ EOF SHLIB_SUFFIX=".sl" echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 -echo "configure:2827: checking for shl_load in -ldld" >&5 +echo "configure:2842: checking for shl_load in -ldld" >&5 ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2831,7 +2846,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldld $LIBS" cat > conftest.$ac_ext <<EOF -#line 2835 "configure" +#line 2850 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -2842,7 +2857,7 @@ int main() { shl_load() ; return 0; } EOF -if { (eval echo configure:2846: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2861: \"$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 @@ -2886,18 +2901,18 @@ fi # Check to enable 64-bit flags for compiler/linker if test "$do64bit" = "yes" ; then if test "$GCC" = "yes" ; then - hpux_arch=`gcc -dumpmachine` + hpux_arch=`${CC} -dumpmachine` case $hpux_arch in hppa64*) # 64-bit gcc in use. Fix flags for GNU ld. do64bit_ok=yes - SHLIB_LD="gcc -shared" + SHLIB_LD="${CC} -shared" SHLIB_LD_LIBS='${LIBS}' CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} ;; *) - echo "configure: warning: "64bit mode not supported with GCC on $system"" 1>&2 + echo "configure: warning: 64bit mode not supported with GCC on $system" 1>&2 ;; esac else @@ -2910,7 +2925,7 @@ fi HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*) SHLIB_SUFFIX=".sl" echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 -echo "configure:2914: checking for shl_load in -ldld" >&5 +echo "configure:2929: checking for shl_load in -ldld" >&5 ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2918,7 +2933,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldld $LIBS" cat > conftest.$ac_ext <<EOF -#line 2922 "configure" +#line 2937 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -2929,7 +2944,7 @@ int main() { shl_load() ; return 0; } EOF -if { (eval echo configure:2933: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2948: \"$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 @@ -3053,17 +3068,17 @@ fi else ac_safe=`echo "dld.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for dld.h""... $ac_c" 1>&6 -echo "configure:3057: checking for dld.h" >&5 +echo "configure:3072: checking for dld.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 -#line 3062 "configure" +#line 3077 "configure" #include "confdefs.h" #include <dld.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3067: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:3082: \"$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* @@ -3127,17 +3142,17 @@ EOF else ac_safe=`echo "dld.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for dld.h""... $ac_c" 1>&6 -echo "configure:3131: checking for dld.h" >&5 +echo "configure:3146: checking for dld.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 -#line 3136 "configure" +#line 3151 "configure" #include "confdefs.h" #include <dld.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3141: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:3156: \"$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* @@ -3205,17 +3220,17 @@ fi # Not available on all versions: check for include file. ac_safe=`echo "dlfcn.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for dlfcn.h""... $ac_c" 1>&6 -echo "configure:3209: checking for dlfcn.h" >&5 +echo "configure:3224: checking for dlfcn.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 -#line 3214 "configure" +#line 3229 "configure" #include "confdefs.h" #include <dlfcn.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3219: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:3234: \"$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* @@ -3242,29 +3257,38 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}' echo $ac_n "checking for ELF""... $ac_c" 1>&6 -echo "configure:3246: checking for ELF" >&5 - cat > conftest.$ac_ext <<EOF -#line 3248 "configure" +echo "configure:3261: checking for ELF" >&5 +if eval "test \"`echo '$''{'tcl_cv_ld_elf'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + cat > conftest.$ac_ext <<EOF +#line 3267 "configure" #include "confdefs.h" #ifdef __ELF__ yes #endif - + EOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | egrep "yes" >/dev/null 2>&1; then rm -rf conftest* - echo "$ac_t""yes" 1>&6 - SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so' + tcl_cv_ld_elf=yes else rm -rf conftest* - echo "$ac_t""no" 1>&6 - SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0' - + tcl_cv_ld_elf=no fi rm -f conftest* +fi + +echo "$ac_t""$tcl_cv_ld_elf" 1>&6 + if test $tcl_cv_ld_elf = yes; then + SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so' + else + SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0' + fi else echo "$ac_t""no" 1>&6 @@ -3318,29 +3342,38 @@ fi LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0' echo $ac_n "checking for ELF""... $ac_c" 1>&6 -echo "configure:3322: checking for ELF" >&5 - cat > conftest.$ac_ext <<EOF -#line 3324 "configure" +echo "configure:3346: checking for ELF" >&5 +if eval "test \"`echo '$''{'tcl_cv_ld_elf'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + cat > conftest.$ac_ext <<EOF +#line 3352 "configure" #include "confdefs.h" #ifdef __ELF__ yes #endif - + EOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | egrep "yes" >/dev/null 2>&1; then rm -rf conftest* - echo "$ac_t""yes" 1>&6 - LDFLAGS=-Wl,-export-dynamic + tcl_cv_ld_elf=yes else rm -rf conftest* - echo "$ac_t""no" 1>&6 - LDFLAGS="" - + tcl_cv_ld_elf=no fi rm -f conftest* +fi + +echo "$ac_t""$tcl_cv_ld_elf" 1>&6 + if test $tcl_cv_ld_elf = yes; then + LDFLAGS=-Wl,-export-dynamic + else + LDFLAGS="" + fi ;; esac @@ -3383,7 +3416,7 @@ rm -f conftest* fi SHLIB_LD='${CC} -dynamiclib ${CFLAGS} ${LDFLAGS}' echo $ac_n "checking if ld accepts -single_module flag""... $ac_c" 1>&6 -echo "configure:3387: checking if ld accepts -single_module flag" >&5 +echo "configure:3420: checking if ld accepts -single_module flag" >&5 if eval "test \"`echo '$''{'tcl_cv_ld_single_module'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -3391,14 +3424,14 @@ else hold_ldflags=$LDFLAGS LDFLAGS="$LDFLAGS -dynamiclib -Wl,-single_module" cat > conftest.$ac_ext <<EOF -#line 3395 "configure" +#line 3428 "configure" #include "confdefs.h" int main() { int i; ; return 0; } EOF -if { (eval echo configure:3402: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3435: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* tcl_cv_ld_single_module=yes else @@ -3425,7 +3458,7 @@ echo "$ac_t""$tcl_cv_ld_single_module" 1>&6 LDFLAGS="$LDFLAGS -prebind" LDFLAGS="$LDFLAGS -headerpad_max_install_names" echo $ac_n "checking if ld accepts -search_paths_first flag""... $ac_c" 1>&6 -echo "configure:3429: checking if ld accepts -search_paths_first flag" >&5 +echo "configure:3462: checking if ld accepts -search_paths_first flag" >&5 if eval "test \"`echo '$''{'tcl_cv_ld_search_paths_first'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -3433,14 +3466,14 @@ else hold_ldflags=$LDFLAGS LDFLAGS="$LDFLAGS -Wl,-search_paths_first" cat > conftest.$ac_ext <<EOF -#line 3437 "configure" +#line 3470 "configure" #include "confdefs.h" int main() { int i; ; return 0; } EOF -if { (eval echo configure:3444: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3477: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* tcl_cv_ld_search_paths_first=yes else @@ -3463,7 +3496,7 @@ echo "$ac_t""$tcl_cv_ld_search_paths_first" 1>&6 PLAT_OBJS=\$\(MAC\_OSX_OBJS\) PLAT_SRCS=\$\(MAC\_OSX_SRCS\) echo $ac_n "checking whether to use CoreFoundation""... $ac_c" 1>&6 -echo "configure:3467: checking whether to use CoreFoundation" >&5 +echo "configure:3500: checking whether to use CoreFoundation" >&5 # Check whether --enable-corefoundation or --disable-corefoundation was given. if test "${enable_corefoundation+set}" = set; then enableval="$enable_corefoundation" @@ -3475,7 +3508,7 @@ fi echo "$ac_t""$tcl_corefoundation" 1>&6 if test $tcl_corefoundation = yes; then echo $ac_n "checking for CoreFoundation.framework""... $ac_c" 1>&6 -echo "configure:3479: checking for CoreFoundation.framework" >&5 +echo "configure:3512: checking for CoreFoundation.framework" >&5 if eval "test \"`echo '$''{'tcl_cv_lib_corefoundation'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -3489,14 +3522,14 @@ else fi LIBS="$LIBS -framework CoreFoundation" cat > conftest.$ac_ext <<EOF -#line 3493 "configure" +#line 3526 "configure" #include "confdefs.h" #include <CoreFoundation/CoreFoundation.h> int main() { CFBundleRef b = CFBundleGetMainBundle(); ; return 0; } EOF -if { (eval echo configure:3500: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3533: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* tcl_cv_lib_corefoundation=yes else @@ -3522,17 +3555,17 @@ EOF do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3526: checking for $ac_hdr" >&5 +echo "configure:3559: checking for $ac_hdr" >&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 -#line 3531 "configure" +#line 3564 "configure" #include "confdefs.h" #include <$ac_hdr> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3536: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:3569: \"$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* @@ -3561,12 +3594,12 @@ done for ac_func in OSSpinLockLock do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:3565: checking for $ac_func" >&5 +echo "configure:3598: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 3570 "configure" +#line 3603 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -3589,7 +3622,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:3593: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3626: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -3617,17 +3650,17 @@ done do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3621: checking for $ac_hdr" >&5 +echo "configure:3654: checking for $ac_hdr" >&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 -#line 3626 "configure" +#line 3659 "configure" #include "confdefs.h" #include <$ac_hdr> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3631: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:3664: \"$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* @@ -3656,12 +3689,12 @@ done for ac_func in copyfile do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:3660: checking for $ac_func" >&5 +echo "configure:3693: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 3665 "configure" +#line 3698 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -3684,7 +3717,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:3688: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3721: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -3731,12 +3764,12 @@ EOF # prior to Darwin 7, realpath is not threadsafe, so don't # use it when threads are enabled, c.f. bug # 711232: echo $ac_n "checking for realpath""... $ac_c" 1>&6 -echo "configure:3735: checking for realpath" >&5 +echo "configure:3768: checking for realpath" >&5 if eval "test \"`echo '$''{'ac_cv_func_realpath'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 3740 "configure" +#line 3773 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char realpath(); below. */ @@ -3759,7 +3792,7 @@ realpath(); ; return 0; } EOF -if { (eval echo configure:3763: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3796: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_realpath=yes" else @@ -3794,11 +3827,11 @@ fi LD_SEARCH_FLAGS="" ;; OS/390-*) - CFLAGS_OPTIMIZE="" # Optimizer is buggy + CFLAGS_OPTIMIZE="" # Optimizer is buggy cat >> confdefs.h <<\EOF #define _OE_SOCKETS 1 EOF - # needed in sys/socket.h + # needed in sys/socket.h ;; OSF1-1.0|OSF1-1.1|OSF1-1.2) # OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1 @@ -4068,29 +4101,39 @@ EOF DL_LIBS="-ldl" # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers # that don't grok the -Bexport option. Test that it does. - hold_ldflags=$LDFLAGS echo $ac_n "checking for ld accepts -Bexport flag""... $ac_c" 1>&6 -echo "configure:4074: checking for ld accepts -Bexport flag" >&5 - LDFLAGS="$LDFLAGS -Wl,-Bexport" - cat > conftest.$ac_ext <<EOF -#line 4077 "configure" +echo "configure:4106: checking for ld accepts -Bexport flag" >&5 +if eval "test \"`echo '$''{'tcl_cv_ld_Bexport'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + hold_ldflags=$LDFLAGS + LDFLAGS="$LDFLAGS -Wl,-Bexport" + cat > conftest.$ac_ext <<EOF +#line 4114 "configure" #include "confdefs.h" int main() { int i; ; return 0; } EOF -if { (eval echo configure:4084: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4121: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - found=yes + tcl_cv_ld_Bexport=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - LDFLAGS=$hold_ldflags found=no + tcl_cv_ld_Bexport=no fi rm -f conftest* - echo "$ac_t""$found" 1>&6 + LDFLAGS=$hold_ldflags +fi + +echo "$ac_t""$tcl_cv_ld_Bexport" 1>&6 + if test $tcl_cv_ld_Bexport = yes; then + LDFLAGS="$LDFLAGS -Wl,-Bexport" + fi CC_SEARCH_FLAGS="" LD_SEARCH_FLAGS="" ;; @@ -4121,9 +4164,13 @@ rm -f conftest* if test "x$DL_OBJS" = "xtclLoadAout.o" ; then echo $ac_n "checking sys/exec.h""... $ac_c" 1>&6 -echo "configure:4125: checking sys/exec.h" >&5 +echo "configure:4168: checking sys/exec.h" >&5 +if eval "test \"`echo '$''{'tcl_cv_sysexec_h'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext <<EOF -#line 4127 "configure" +#line 4174 "configure" #include "confdefs.h" #include <sys/exec.h> int main() { @@ -4141,27 +4188,33 @@ int main() { ; return 0; } EOF -if { (eval echo configure:4145: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4192: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - tcl_ok=usable + tcl_cv_sysexec_h=usable else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - tcl_ok=unusable + tcl_cv_sysexec_h=unusable fi rm -f conftest* - echo "$ac_t""$tcl_ok" 1>&6 - if test $tcl_ok = usable; then +fi + +echo "$ac_t""$tcl_cv_sysexec_h" 1>&6 + if test $tcl_cv_sysexec_h = usable; then cat >> confdefs.h <<\EOF #define USE_SYS_EXEC_H 1 EOF else echo $ac_n "checking a.out.h""... $ac_c" 1>&6 -echo "configure:4163: checking a.out.h" >&5 +echo "configure:4212: checking a.out.h" >&5 +if eval "test \"`echo '$''{'tcl_cv_aout_h'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext <<EOF -#line 4165 "configure" +#line 4218 "configure" #include "confdefs.h" #include <a.out.h> int main() { @@ -4179,27 +4232,33 @@ int main() { ; return 0; } EOF -if { (eval echo configure:4183: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4236: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - tcl_ok=usable + tcl_cv_aout_h=usable else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - tcl_ok=unusable + tcl_cv_aout_h=unusable fi rm -f conftest* - echo "$ac_t""$tcl_ok" 1>&6 - if test $tcl_ok = usable; then +fi + +echo "$ac_t""$tcl_cv_aout_h" 1>&6 + if test $tcl_cv_aout_h = usable; then cat >> confdefs.h <<\EOF #define USE_A_OUT_H 1 EOF else echo $ac_n "checking sys/exec_aout.h""... $ac_c" 1>&6 -echo "configure:4201: checking sys/exec_aout.h" >&5 +echo "configure:4256: checking sys/exec_aout.h" >&5 +if eval "test \"`echo '$''{'tcl_cv_sysexecaout_h'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext <<EOF -#line 4203 "configure" +#line 4262 "configure" #include "confdefs.h" #include <sys/exec_aout.h> int main() { @@ -4217,18 +4276,20 @@ int main() { ; return 0; } EOF -if { (eval echo configure:4221: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4280: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - tcl_ok=usable + tcl_cv_sysexecaout_h=usable else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - tcl_ok=unusable + tcl_cv_sysexecaout_h=unusable fi rm -f conftest* - echo "$ac_t""$tcl_ok" 1>&6 - if test $tcl_ok = usable; then +fi + +echo "$ac_t""$tcl_cv_sysexecaout_h" 1>&6 + if test $tcl_cv_sysexecaout_h = usable; then cat >> confdefs.h <<\EOF #define USE_SYS_EXEC_AOUT_H 1 EOF @@ -4368,7 +4429,7 @@ fi echo $ac_n "checking for build with symbols""... $ac_c" 1>&6 -echo "configure:4372: checking for build with symbols" >&5 +echo "configure:4433: checking for build with symbols" >&5 # Check whether --enable-symbols or --disable-symbols was given. if test "${enable_symbols+set}" = set; then enableval="$enable_symbols" @@ -4429,21 +4490,21 @@ TCL_DBGX=${DBGX} echo $ac_n "checking for required early compiler flags""... $ac_c" 1>&6 -echo "configure:4433: checking for required early compiler flags" >&5 +echo "configure:4494: checking for required early compiler flags" >&5 tcl_flags="" if eval "test \"`echo '$''{'tcl_cv_flag__isoc99_source'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 4440 "configure" +#line 4501 "configure" #include "confdefs.h" #include <stdlib.h> int main() { char *p = (char *)strtoll; char *q = (char *)strtoull; ; return 0; } EOF -if { (eval echo configure:4447: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4508: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_flag__isoc99_source=no else @@ -4451,7 +4512,7 @@ else cat conftest.$ac_ext >&5 rm -rf conftest* cat > conftest.$ac_ext <<EOF -#line 4455 "configure" +#line 4516 "configure" #include "confdefs.h" #define _ISOC99_SOURCE 1 #include <stdlib.h> @@ -4459,7 +4520,7 @@ int main() { char *p = (char *)strtoll; char *q = (char *)strtoull; ; return 0; } EOF -if { (eval echo configure:4463: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4524: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_flag__isoc99_source=yes else @@ -4480,19 +4541,20 @@ EOF tcl_flags="$tcl_flags _ISOC99_SOURCE" fi + if eval "test \"`echo '$''{'tcl_cv_flag__largefile64_source'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 4489 "configure" +#line 4551 "configure" #include "confdefs.h" #include <sys/stat.h> int main() { struct stat64 buf; int i = stat64("/", &buf); ; return 0; } EOF -if { (eval echo configure:4496: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4558: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_flag__largefile64_source=no else @@ -4500,7 +4562,7 @@ else cat conftest.$ac_ext >&5 rm -rf conftest* cat > conftest.$ac_ext <<EOF -#line 4504 "configure" +#line 4566 "configure" #include "confdefs.h" #define _LARGEFILE64_SOURCE 1 #include <sys/stat.h> @@ -4508,7 +4570,7 @@ int main() { struct stat64 buf; int i = stat64("/", &buf); ; return 0; } EOF -if { (eval echo configure:4512: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4574: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_flag__largefile64_source=yes else @@ -4529,19 +4591,20 @@ EOF tcl_flags="$tcl_flags _LARGEFILE64_SOURCE" fi + if eval "test \"`echo '$''{'tcl_cv_flag__largefile_source64'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 4538 "configure" +#line 4601 "configure" #include "confdefs.h" #include <sys/stat.h> int main() { char *p = (char *)open64; ; return 0; } EOF -if { (eval echo configure:4545: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4608: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_flag__largefile_source64=no else @@ -4549,7 +4612,7 @@ else cat conftest.$ac_ext >&5 rm -rf conftest* cat > conftest.$ac_ext <<EOF -#line 4553 "configure" +#line 4616 "configure" #include "confdefs.h" #define _LARGEFILE_SOURCE64 1 #include <sys/stat.h> @@ -4557,7 +4620,7 @@ int main() { char *p = (char *)open64; ; return 0; } EOF -if { (eval echo configure:4561: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4624: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_flag__largefile_source64=yes else @@ -4578,6 +4641,7 @@ EOF tcl_flags="$tcl_flags _LARGEFILE_SOURCE64" fi + if test "x${tcl_flags}" = "x" ; then echo "$ac_t""none" 1>&6 else @@ -4585,8 +4649,9 @@ EOF fi + echo $ac_n "checking for 64-bit integer type""... $ac_c" 1>&6 -echo "configure:4590: checking for 64-bit integer type" >&5 +echo "configure:4655: checking for 64-bit integer type" >&5 if eval "test \"`echo '$''{'tcl_cv_type_64bit'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -4594,14 +4659,14 @@ else tcl_cv_type_64bit=none # See if the compiler knows natively about __int64 cat > conftest.$ac_ext <<EOF -#line 4598 "configure" +#line 4663 "configure" #include "confdefs.h" int main() { __int64 value = (__int64) 0; ; return 0; } EOF -if { (eval echo configure:4605: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4670: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_type_64bit=__int64 else @@ -4615,7 +4680,7 @@ rm -f conftest* # type that is our current guess for a 64-bit type inside this check # program, so it should be modified only carefully... cat > conftest.$ac_ext <<EOF -#line 4619 "configure" +#line 4684 "configure" #include "confdefs.h" int main() { @@ -4624,7 +4689,7 @@ switch (0) { } ; return 0; } EOF -if { (eval echo configure:4628: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4693: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_type_64bit=${tcl_type_64bit} else @@ -4649,13 +4714,13 @@ EOF # Now check for auxiliary declarations echo $ac_n "checking for struct dirent64""... $ac_c" 1>&6 -echo "configure:4653: checking for struct dirent64" >&5 - if eval "test \"`echo '$''{'tcl_cv_struct_dirent64'+set}'`\" = set"; then +echo "configure:4718: checking for struct dirent64" >&5 +if eval "test \"`echo '$''{'tcl_cv_struct_dirent64'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 4659 "configure" +#line 4724 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/dirent.h> @@ -4663,7 +4728,7 @@ int main() { struct dirent64 p; ; return 0; } EOF -if { (eval echo configure:4667: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4732: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_struct_dirent64=yes else @@ -4675,22 +4740,22 @@ fi rm -f conftest* fi +echo "$ac_t""$tcl_cv_struct_dirent64" 1>&6 if test "x${tcl_cv_struct_dirent64}" = "xyes" ; then cat >> confdefs.h <<\EOF #define HAVE_STRUCT_DIRENT64 1 EOF fi - echo "$ac_t""${tcl_cv_struct_dirent64}" 1>&6 echo $ac_n "checking for struct stat64""... $ac_c" 1>&6 -echo "configure:4688: checking for struct stat64" >&5 - if eval "test \"`echo '$''{'tcl_cv_struct_stat64'+set}'`\" = set"; then +echo "configure:4753: checking for struct stat64" >&5 +if eval "test \"`echo '$''{'tcl_cv_struct_stat64'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 4694 "configure" +#line 4759 "configure" #include "confdefs.h" #include <sys/stat.h> int main() { @@ -4698,7 +4763,7 @@ struct stat64 p; ; return 0; } EOF -if { (eval echo configure:4702: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4767: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_struct_stat64=yes else @@ -4710,23 +4775,23 @@ fi rm -f conftest* fi +echo "$ac_t""$tcl_cv_struct_stat64" 1>&6 if test "x${tcl_cv_struct_stat64}" = "xyes" ; then cat >> confdefs.h <<\EOF #define HAVE_STRUCT_STAT64 1 EOF fi - echo "$ac_t""${tcl_cv_struct_stat64}" 1>&6 for ac_func in open64 lseek64 do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:4725: checking for $ac_func" >&5 +echo "configure:4790: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 4730 "configure" +#line 4795 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -4749,7 +4814,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:4753: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4818: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -4774,13 +4839,13 @@ fi done echo $ac_n "checking for off64_t""... $ac_c" 1>&6 -echo "configure:4778: checking for off64_t" >&5 +echo "configure:4843: checking for off64_t" >&5 if eval "test \"`echo '$''{'tcl_cv_type_off64_t'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 4784 "configure" +#line 4849 "configure" #include "confdefs.h" #include <sys/types.h> int main() { @@ -4788,7 +4853,7 @@ off64_t offset; ; return 0; } EOF -if { (eval echo configure:4792: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4857: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_type_off64_t=yes else @@ -4813,20 +4878,21 @@ EOF fi fi + #-------------------------------------------------------------------- # Check endianness because we can optimize comparisons of # Tcl_UniChar strings to memcmp on big-endian systems. #-------------------------------------------------------------------- echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 -echo "configure:4823: checking whether byte ordering is bigendian" >&5 +echo "configure:4889: checking whether byte ordering is bigendian" >&5 if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else ac_cv_c_bigendian=unknown # See if sys/param.h defines the BYTE_ORDER macro. cat > conftest.$ac_ext <<EOF -#line 4830 "configure" +#line 4896 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/param.h> @@ -4837,11 +4903,11 @@ int main() { #endif ; return 0; } EOF -if { (eval echo configure:4841: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4907: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* # It does; now see whether it defined to BIG_ENDIAN or not. cat > conftest.$ac_ext <<EOF -#line 4845 "configure" +#line 4911 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/param.h> @@ -4852,7 +4918,7 @@ int main() { #endif ; return 0; } EOF -if { (eval echo configure:4856: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4922: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_bigendian=yes else @@ -4872,7 +4938,7 @@ if test "$cross_compiling" = yes; then { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 4876 "configure" +#line 4942 "configure" #include "confdefs.h" main () { /* Are we little or big endian? From Harbison&Steele. */ @@ -4885,7 +4951,7 @@ main () { exit (u.c[sizeof (long) - 1] == 1); } EOF -if { (eval echo configure:4889: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:4955: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_c_bigendian=no else @@ -4918,12 +4984,12 @@ fi for ac_func in getcwd do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:4922: checking for $ac_func" >&5 +echo "configure:4988: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 4927 "configure" +#line 4993 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -4946,7 +5012,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:4950: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5016: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -4980,12 +5046,12 @@ done for ac_func in opendir strstr strtol strtoll strtoull tmpnam waitpid do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:4984: checking for $ac_func" >&5 +echo "configure:5050: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 4989 "configure" +#line 5055 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -5008,7 +5074,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:5012: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5078: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -5035,12 +5101,12 @@ done echo $ac_n "checking for strerror""... $ac_c" 1>&6 -echo "configure:5039: checking for strerror" >&5 +echo "configure:5105: checking for strerror" >&5 if eval "test \"`echo '$''{'ac_cv_func_strerror'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5044 "configure" +#line 5110 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char strerror(); below. */ @@ -5063,7 +5129,7 @@ strerror(); ; return 0; } EOF -if { (eval echo configure:5067: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5133: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_strerror=yes" else @@ -5087,12 +5153,12 @@ EOF fi echo $ac_n "checking for getwd""... $ac_c" 1>&6 -echo "configure:5091: checking for getwd" >&5 +echo "configure:5157: checking for getwd" >&5 if eval "test \"`echo '$''{'ac_cv_func_getwd'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5096 "configure" +#line 5162 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char getwd(); below. */ @@ -5115,7 +5181,7 @@ getwd(); ; return 0; } EOF -if { (eval echo configure:5119: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5185: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_getwd=yes" else @@ -5139,12 +5205,12 @@ EOF fi echo $ac_n "checking for wait3""... $ac_c" 1>&6 -echo "configure:5143: checking for wait3" >&5 +echo "configure:5209: checking for wait3" >&5 if eval "test \"`echo '$''{'ac_cv_func_wait3'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5148 "configure" +#line 5214 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char wait3(); below. */ @@ -5167,7 +5233,7 @@ wait3(); ; return 0; } EOF -if { (eval echo configure:5171: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5237: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_wait3=yes" else @@ -5191,12 +5257,12 @@ EOF fi echo $ac_n "checking for uname""... $ac_c" 1>&6 -echo "configure:5195: checking for uname" >&5 +echo "configure:5261: checking for uname" >&5 if eval "test \"`echo '$''{'ac_cv_func_uname'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5200 "configure" +#line 5266 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char uname(); below. */ @@ -5219,7 +5285,7 @@ uname(); ; return 0; } EOF -if { (eval echo configure:5223: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5289: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_uname=yes" else @@ -5243,12 +5309,12 @@ EOF fi echo $ac_n "checking for realpath""... $ac_c" 1>&6 -echo "configure:5247: checking for realpath" >&5 +echo "configure:5313: checking for realpath" >&5 if eval "test \"`echo '$''{'ac_cv_func_realpath'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5252 "configure" +#line 5318 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char realpath(); below. */ @@ -5271,7 +5337,7 @@ realpath(); ; return 0; } EOF -if { (eval echo configure:5275: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5341: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_realpath=yes" else @@ -5306,17 +5372,17 @@ fi do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:5310: checking for $ac_hdr" >&5 +echo "configure:5376: checking for $ac_hdr" >&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 -#line 5315 "configure" +#line 5381 "configure" #include "confdefs.h" #include <$ac_hdr> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5320: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:5386: \"$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* @@ -5343,8 +5409,8 @@ fi done echo $ac_n "checking termios vs. termio vs. sgtty""... $ac_c" 1>&6 -echo "configure:5347: checking termios vs. termio vs. sgtty" >&5 - if eval "test \"`echo '$''{'tcl_cv_api_serial'+set}'`\" = set"; then +echo "configure:5413: checking termios vs. termio vs. sgtty" >&5 +if eval "test \"`echo '$''{'tcl_cv_api_serial'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -5352,7 +5418,7 @@ else tcl_cv_api_serial=no else cat > conftest.$ac_ext <<EOF -#line 5356 "configure" +#line 5422 "configure" #include "confdefs.h" #include <termios.h> @@ -5367,7 +5433,7 @@ int main() { return 1; } EOF -if { (eval echo configure:5371: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:5437: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then tcl_cv_api_serial=termios else @@ -5384,7 +5450,7 @@ fi tcl_cv_api_serial=no else cat > conftest.$ac_ext <<EOF -#line 5388 "configure" +#line 5454 "configure" #include "confdefs.h" #include <termio.h> @@ -5398,7 +5464,7 @@ int main() { return 1; } EOF -if { (eval echo configure:5402: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:5468: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then tcl_cv_api_serial=termio else @@ -5416,7 +5482,7 @@ fi tcl_cv_api_serial=no else cat > conftest.$ac_ext <<EOF -#line 5420 "configure" +#line 5486 "configure" #include "confdefs.h" #include <sgtty.h> @@ -5431,7 +5497,7 @@ int main() { return 1; } EOF -if { (eval echo configure:5435: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:5501: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then tcl_cv_api_serial=sgtty else @@ -5449,7 +5515,7 @@ fi tcl_cv_api_serial=no else cat > conftest.$ac_ext <<EOF -#line 5453 "configure" +#line 5519 "configure" #include "confdefs.h" #include <termios.h> @@ -5466,7 +5532,7 @@ int main() { return 1; } EOF -if { (eval echo configure:5470: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:5536: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then tcl_cv_api_serial=termios else @@ -5484,7 +5550,7 @@ fi tcl_cv_api_serial=no else cat > conftest.$ac_ext <<EOF -#line 5488 "configure" +#line 5554 "configure" #include "confdefs.h" #include <termio.h> @@ -5500,7 +5566,7 @@ int main() { return 1; } EOF -if { (eval echo configure:5504: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:5570: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then tcl_cv_api_serial=termio else @@ -5518,7 +5584,7 @@ fi tcl_cv_api_serial=none else cat > conftest.$ac_ext <<EOF -#line 5522 "configure" +#line 5588 "configure" #include "confdefs.h" #include <sgtty.h> @@ -5535,7 +5601,7 @@ int main() { return 1; } EOF -if { (eval echo configure:5539: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:5605: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then tcl_cv_api_serial=sgtty else @@ -5550,6 +5616,7 @@ fi fi fi +echo "$ac_t""$tcl_cv_api_serial" 1>&6 case $tcl_cv_api_serial in termios) cat >> confdefs.h <<\EOF #define USE_TERMIOS 1 @@ -5564,7 +5631,6 @@ EOF EOF ;; esac - echo "$ac_t""$tcl_cv_api_serial" 1>&6 #-------------------------------------------------------------------- @@ -5578,19 +5644,19 @@ EOF #-------------------------------------------------------------------- echo $ac_n "checking for fd_set in sys/types""... $ac_c" 1>&6 -echo "configure:5582: checking for fd_set in sys/types" >&5 +echo "configure:5648: checking for fd_set in sys/types" >&5 if eval "test \"`echo '$''{'tcl_cv_type_fd_set'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5587 "configure" +#line 5653 "configure" #include "confdefs.h" #include <sys/types.h> int main() { fd_set readMask, writeMask; ; return 0; } EOF -if { (eval echo configure:5594: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5660: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_type_fd_set=yes else @@ -5604,14 +5670,14 @@ fi echo "$ac_t""$tcl_cv_type_fd_set" 1>&6 tcl_ok=$tcl_cv_type_fd_set -if test $tcl_cv_type_fd_set = no; then +if test $tcl_ok = no; then echo $ac_n "checking for fd_mask in sys/select""... $ac_c" 1>&6 -echo "configure:5610: checking for fd_mask in sys/select" >&5 - if eval "test \"`echo '$''{'tcl_cv_grep_fd_mask'+set}'`\" = set"; then +echo "configure:5676: checking for fd_mask in sys/select" >&5 +if eval "test \"`echo '$''{'tcl_cv_grep_fd_mask'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5615 "configure" +#line 5681 "configure" #include "confdefs.h" #include <sys/select.h> EOF @@ -5627,7 +5693,7 @@ rm -f conftest* fi - echo "$ac_t""$tcl_cv_grep_fd_mask" 1>&6 +echo "$ac_t""$tcl_cv_grep_fd_mask" 1>&6 if test $tcl_cv_grep_fd_mask = present; then cat >> confdefs.h <<\EOF #define HAVE_SYS_SELECT_H 1 @@ -5648,12 +5714,12 @@ fi #------------------------------------------------------------------------------ echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 -echo "configure:5652: checking whether struct tm is in sys/time.h or time.h" >&5 +echo "configure:5718: checking whether struct tm is in sys/time.h or time.h" >&5 if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5657 "configure" +#line 5723 "configure" #include "confdefs.h" #include <sys/types.h> #include <time.h> @@ -5661,7 +5727,7 @@ int main() { struct tm *tp; tp->tm_sec; ; return 0; } EOF -if { (eval echo configure:5665: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5731: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_tm=time.h else @@ -5686,17 +5752,17 @@ fi do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:5690: checking for $ac_hdr" >&5 +echo "configure:5756: checking for $ac_hdr" >&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 -#line 5695 "configure" +#line 5761 "configure" #include "confdefs.h" #include <$ac_hdr> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5700: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:5766: \"$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* @@ -5723,12 +5789,12 @@ fi done echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 -echo "configure:5727: checking whether time.h and sys/time.h may both be included" >&5 +echo "configure:5793: checking whether time.h and sys/time.h may both be included" >&5 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5732 "configure" +#line 5798 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/time.h> @@ -5737,7 +5803,7 @@ int main() { struct tm *tp; ; return 0; } EOF -if { (eval echo configure:5741: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5807: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_header_time=yes else @@ -5758,12 +5824,12 @@ EOF fi echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 -echo "configure:5762: checking for tm_zone in struct tm" >&5 +echo "configure:5828: checking for tm_zone in struct tm" >&5 if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5767 "configure" +#line 5833 "configure" #include "confdefs.h" #include <sys/types.h> #include <$ac_cv_struct_tm> @@ -5771,7 +5837,7 @@ int main() { struct tm tm; tm.tm_zone; ; return 0; } EOF -if { (eval echo configure:5775: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5841: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_tm_zone=yes else @@ -5791,12 +5857,12 @@ EOF else echo $ac_n "checking for tzname""... $ac_c" 1>&6 -echo "configure:5795: checking for tzname" >&5 +echo "configure:5861: checking for tzname" >&5 if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5800 "configure" +#line 5866 "configure" #include "confdefs.h" #include <time.h> #ifndef tzname /* For SGI. */ @@ -5806,7 +5872,7 @@ int main() { atoi(*tzname); ; return 0; } EOF -if { (eval echo configure:5810: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5876: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_var_tzname=yes else @@ -5831,12 +5897,12 @@ fi for ac_func in gmtime_r localtime_r do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:5835: checking for $ac_func" >&5 +echo "configure:5901: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5840 "configure" +#line 5906 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func(); below. */ @@ -5859,7 +5925,7 @@ $ac_func(); ; return 0; } EOF -if { (eval echo configure:5863: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5929: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -5885,19 +5951,19 @@ done echo $ac_n "checking tm_tzadj in struct tm""... $ac_c" 1>&6 -echo "configure:5889: checking tm_tzadj in struct tm" >&5 - if eval "test \"`echo '$''{'tcl_cv_member_tm_tzadj'+set}'`\" = set"; then +echo "configure:5955: checking tm_tzadj in struct tm" >&5 +if eval "test \"`echo '$''{'tcl_cv_member_tm_tzadj'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5894 "configure" +#line 5960 "configure" #include "confdefs.h" #include <time.h> int main() { struct tm tm; tm.tm_tzadj; ; return 0; } EOF -if { (eval echo configure:5901: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5967: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_member_tm_tzadj=yes else @@ -5909,7 +5975,7 @@ fi rm -f conftest* fi - echo "$ac_t""$tcl_cv_member_tm_tzadj" 1>&6 +echo "$ac_t""$tcl_cv_member_tm_tzadj" 1>&6 if test $tcl_cv_member_tm_tzadj = yes ; then cat >> confdefs.h <<\EOF #define HAVE_TM_TZADJ 1 @@ -5918,19 +5984,19 @@ EOF fi echo $ac_n "checking tm_gmtoff in struct tm""... $ac_c" 1>&6 -echo "configure:5922: checking tm_gmtoff in struct tm" >&5 - if eval "test \"`echo '$''{'tcl_cv_member_tm_gmtoff'+set}'`\" = set"; then +echo "configure:5988: checking tm_gmtoff in struct tm" >&5 +if eval "test \"`echo '$''{'tcl_cv_member_tm_gmtoff'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5927 "configure" +#line 5993 "configure" #include "confdefs.h" #include <time.h> int main() { struct tm tm; tm.tm_gmtoff; ; return 0; } EOF -if { (eval echo configure:5934: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:6000: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_member_tm_gmtoff=yes else @@ -5942,7 +6008,7 @@ fi rm -f conftest* fi - echo "$ac_t""$tcl_cv_member_tm_gmtoff" 1>&6 +echo "$ac_t""$tcl_cv_member_tm_gmtoff" 1>&6 if test $tcl_cv_member_tm_gmtoff = yes ; then cat >> confdefs.h <<\EOF #define HAVE_TM_GMTOFF 1 @@ -5955,12 +6021,12 @@ EOF # (like convex) have timezone functions, etc. # echo $ac_n "checking long timezone variable""... $ac_c" 1>&6 -echo "configure:5959: checking long timezone variable" >&5 - if eval "test \"`echo '$''{'tcl_cv_timezone_long'+set}'`\" = set"; then +echo "configure:6025: checking long timezone variable" >&5 +if eval "test \"`echo '$''{'tcl_cv_timezone_long'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 5964 "configure" +#line 6030 "configure" #include "confdefs.h" #include <time.h> int main() { @@ -5969,7 +6035,7 @@ extern long timezone; exit (0); ; return 0; } EOF -if { (eval echo configure:5973: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:6039: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_timezone_long=yes else @@ -5981,7 +6047,7 @@ fi rm -f conftest* fi - echo "$ac_t""$tcl_cv_timezone_long" 1>&6 +echo "$ac_t""$tcl_cv_timezone_long" 1>&6 if test $tcl_cv_timezone_long = yes ; then cat >> confdefs.h <<\EOF #define HAVE_TIMEZONE_VAR 1 @@ -5992,12 +6058,12 @@ EOF # On some systems (eg IRIX 6.2), timezone is a time_t and not a long. # echo $ac_n "checking time_t timezone variable""... $ac_c" 1>&6 -echo "configure:5996: checking time_t timezone variable" >&5 - if eval "test \"`echo '$''{'tcl_cv_timezone_time'+set}'`\" = set"; then +echo "configure:6062: checking time_t timezone variable" >&5 +if eval "test \"`echo '$''{'tcl_cv_timezone_time'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6001 "configure" +#line 6067 "configure" #include "confdefs.h" #include <time.h> int main() { @@ -6006,7 +6072,7 @@ extern time_t timezone; exit (0); ; return 0; } EOF -if { (eval echo configure:6010: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:6076: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_timezone_time=yes else @@ -6018,7 +6084,7 @@ fi rm -f conftest* fi - echo "$ac_t""$tcl_cv_timezone_time" 1>&6 +echo "$ac_t""$tcl_cv_timezone_time" 1>&6 if test $tcl_cv_timezone_time = yes ; then cat >> confdefs.h <<\EOF #define HAVE_TIMEZONE_VAR 1 @@ -6033,12 +6099,12 @@ EOF # in struct stat. But we might be able to use fstatfs instead. #-------------------------------------------------------------------- echo $ac_n "checking for st_blksize in struct stat""... $ac_c" 1>&6 -echo "configure:6037: checking for st_blksize in struct stat" >&5 +echo "configure:6103: checking for st_blksize in struct stat" >&5 if eval "test \"`echo '$''{'ac_cv_struct_st_blksize'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6042 "configure" +#line 6108 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/stat.h> @@ -6046,7 +6112,7 @@ int main() { struct stat s; s.st_blksize; ; return 0; } EOF -if { (eval echo configure:6050: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:6116: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_st_blksize=yes else @@ -6067,12 +6133,12 @@ EOF fi echo $ac_n "checking for fstatfs""... $ac_c" 1>&6 -echo "configure:6071: checking for fstatfs" >&5 +echo "configure:6137: checking for fstatfs" >&5 if eval "test \"`echo '$''{'ac_cv_func_fstatfs'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6076 "configure" +#line 6142 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char fstatfs(); below. */ @@ -6095,7 +6161,7 @@ fstatfs(); ; return 0; } EOF -if { (eval echo configure:6099: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6165: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_fstatfs=yes" else @@ -6124,7 +6190,7 @@ fi # data, this checks it and add memcmp.o to LIBOBJS if needed #-------------------------------------------------------------------- echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6 -echo "configure:6128: checking for 8-bit clean memcmp" >&5 +echo "configure:6194: checking for 8-bit clean memcmp" >&5 if eval "test \"`echo '$''{'ac_cv_func_memcmp_clean'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -6132,7 +6198,7 @@ else ac_cv_func_memcmp_clean=no else cat > conftest.$ac_ext <<EOF -#line 6136 "configure" +#line 6202 "configure" #include "confdefs.h" main() @@ -6142,7 +6208,7 @@ main() } EOF -if { (eval echo configure:6146: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:6212: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_func_memcmp_clean=yes else @@ -6166,12 +6232,12 @@ test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.${ac_objext}" # {The replacement define is in compat/string.h} #-------------------------------------------------------------------- echo $ac_n "checking for memmove""... $ac_c" 1>&6 -echo "configure:6170: checking for memmove" >&5 +echo "configure:6236: checking for memmove" >&5 if eval "test \"`echo '$''{'ac_cv_func_memmove'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6175 "configure" +#line 6241 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char memmove(); below. */ @@ -6194,7 +6260,7 @@ memmove(); ; return 0; } EOF -if { (eval echo configure:6198: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6264: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_memmove=yes" else @@ -6227,37 +6293,40 @@ fi #-------------------------------------------------------------------- if test "x${ac_cv_func_strstr}" = "xyes"; then echo $ac_n "checking proper strstr implementation""... $ac_c" 1>&6 -echo "configure:6231: checking proper strstr implementation" >&5 - if test "$cross_compiling" = yes; then - tcl_ok=no +echo "configure:6297: checking proper strstr implementation" >&5 +if eval "test \"`echo '$''{'tcl_cv_strstr_unbroken'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + if test "$cross_compiling" = yes; then + tcl_cv_strstr_unbroken=broken else cat > conftest.$ac_ext <<EOF -#line 6236 "configure" +#line 6306 "configure" #include "confdefs.h" - extern int strstr(); - int main() - { - exit(strstr("\0test", "test") ? 1 : 0); - } - + extern int strstr(); + int main() + { + exit(strstr("\0test", "test") ? 1 : 0); + } EOF -if { (eval echo configure:6246: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:6315: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then - tcl_ok=yes + tcl_cv_strstr_unbroken=ok else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -fr conftest* - tcl_ok=no + tcl_cv_strstr_unbroken=broken fi rm -fr conftest* fi - if test $tcl_ok = yes; then - echo "$ac_t""yes" 1>&6 - else - echo "$ac_t""broken, using substitute" 1>&6 +fi + +echo "$ac_t""$tcl_cv_strstr_unbroken" 1>&6 + if test $tcl_cv_strstr_unbroken = broken; then LIBOBJS="$LIBOBJS strstr.o" fi fi @@ -6269,12 +6338,12 @@ fi #-------------------------------------------------------------------- echo $ac_n "checking for strtoul""... $ac_c" 1>&6 -echo "configure:6273: checking for strtoul" >&5 +echo "configure:6342: checking for strtoul" >&5 if eval "test \"`echo '$''{'ac_cv_func_strtoul'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6278 "configure" +#line 6347 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char strtoul(); below. */ @@ -6297,7 +6366,7 @@ strtoul(); ; return 0; } EOF -if { (eval echo configure:6301: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6370: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_strtoul=yes" else @@ -6317,40 +6386,53 @@ else tcl_ok=0 fi -if test "$cross_compiling" = yes; then - tcl_ok=0 +if test $tcl_ok = 1; then + echo $ac_n "checking proper strtoul implementation""... $ac_c" 1>&6 +echo "configure:6392: checking proper strtoul implementation" >&5 +if eval "test \"`echo '$''{'tcl_cv_strtoul_unbroken'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + if test "$cross_compiling" = yes; then + tcl_cv_strtoul_unbroken=broken else cat > conftest.$ac_ext <<EOF -#line 6325 "configure" +#line 6401 "configure" #include "confdefs.h" -extern int strtoul(); -int main() -{ - char *string = "0"; - char *term; - int value; - value = strtoul(string, &term, 0); - if ((value != 0) || (term != (string+1))) { - exit(1); - } - exit(0); -} + extern int strtoul(); + int main() + { + char *string = "0"; + char *term; + int value; + value = strtoul(string, &term, 0); + if ((value != 0) || (term != (string+1))) { + exit(1); + } + exit(0); + } EOF -if { (eval echo configure:6341: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:6417: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then - : + tcl_cv_strtoul_unbroken=ok else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -fr conftest* - tcl_ok=0 + tcl_cv_strtoul_unbroken=broken fi rm -fr conftest* fi -if test "$tcl_ok" = 0; then - test -n "$verbose" && echo " Adding strtoul.o." +fi + +echo "$ac_t""$tcl_cv_strtoul_unbroken" 1>&6 + if test $tcl_cv_strtoul_unbroken = broken; then + tcl_ok=0 + fi +fi +if test $tcl_ok = 0; then LIBOBJS="$LIBOBJS strtoul.o" fi @@ -6360,12 +6442,12 @@ fi #-------------------------------------------------------------------- echo $ac_n "checking for strtod""... $ac_c" 1>&6 -echo "configure:6364: checking for strtod" >&5 +echo "configure:6446: checking for strtod" >&5 if eval "test \"`echo '$''{'ac_cv_func_strtod'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6369 "configure" +#line 6451 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char strtod(); below. */ @@ -6388,7 +6470,7 @@ strtod(); ; return 0; } EOF -if { (eval echo configure:6392: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6474: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_strtod=yes" else @@ -6408,40 +6490,53 @@ else tcl_ok=0 fi -if test "$cross_compiling" = yes; then - tcl_ok=0 +if test $tcl_ok = 1; then + echo $ac_n "checking proper strtod implementation""... $ac_c" 1>&6 +echo "configure:6496: checking proper strtod implementation" >&5 +if eval "test \"`echo '$''{'tcl_cv_strtod_unbroken'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + if test "$cross_compiling" = yes; then + tcl_cv_strtod_unbroken=broken else cat > conftest.$ac_ext <<EOF -#line 6416 "configure" +#line 6505 "configure" #include "confdefs.h" -extern double strtod(); -int main() -{ - char *string = " +69"; - char *term; - double value; - value = strtod(string, &term); - if ((value != 69) || (term != (string+4))) { - exit(1); - } - exit(0); -} + extern double strtod(); + int main() + { + char *string = " +69"; + char *term; + double value; + value = strtod(string, &term); + if ((value != 69) || (term != (string+4))) { + exit(1); + } + exit(0); + } EOF -if { (eval echo configure:6432: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:6521: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then - : + tcl_cv_strtod_unbroken=ok else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -fr conftest* - tcl_ok=0 + tcl_cv_strtod_unbroken=broken fi rm -fr conftest* fi -if test "$tcl_ok" = 0; then - test -n "$verbose" && echo " Adding strtod.o." +fi + +echo "$ac_t""$tcl_cv_strtod_unbroken" 1>&6 + if test $tcl_cv_strtod_unbroken = broken; then + tcl_ok=0 + fi +fi +if test $tcl_ok = 0; then LIBOBJS="$LIBOBJS strtod.o" fi @@ -6454,12 +6549,12 @@ fi echo $ac_n "checking for strtod""... $ac_c" 1>&6 -echo "configure:6458: checking for strtod" >&5 +echo "configure:6553: checking for strtod" >&5 if eval "test \"`echo '$''{'ac_cv_func_strtod'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6463 "configure" +#line 6558 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char strtod(); below. */ @@ -6482,7 +6577,7 @@ strtod(); ; return 0; } EOF -if { (eval echo configure:6486: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6581: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_strtod=yes" else @@ -6504,16 +6599,16 @@ fi if test "$tcl_strtod" = 1; then echo $ac_n "checking for Solaris2.4/Tru64 strtod bugs""... $ac_c" 1>&6 -echo "configure:6508: checking for Solaris2.4/Tru64 strtod bugs" >&5 - if eval "test \"`echo '$''{'tcl_cv_strtod_buggy'+set}'`\" = set"; then +echo "configure:6603: checking for Solaris2.4/Tru64 strtod bugs" >&5 +if eval "test \"`echo '$''{'tcl_cv_strtod_buggy'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else if test "$cross_compiling" = yes; then - tcl_cv_strtod_buggy=0 + tcl_cv_strtod_buggy=buggy else cat > conftest.$ac_ext <<EOF -#line 6517 "configure" +#line 6612 "configure" #include "confdefs.h" extern double strtod(); @@ -6536,24 +6631,22 @@ else exit(0); } EOF -if { (eval echo configure:6540: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:6635: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then - tcl_cv_strtod_buggy=1 + tcl_cv_strtod_buggy=ok else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -fr conftest* - tcl_cv_strtod_buggy=0 + tcl_cv_strtod_buggy=buggy fi rm -fr conftest* fi fi - if test "$tcl_cv_strtod_buggy" = 1; then - echo "$ac_t""ok" 1>&6 - else - echo "$ac_t""buggy" 1>&6 +echo "$ac_t""$tcl_cv_strtod_buggy" 1>&6 + if test "$tcl_cv_strtod_buggy" = buggy; then LIBOBJS="$LIBOBJS fixstrtod.o" cat >> confdefs.h <<\EOF #define strtod fixstrtod @@ -6569,12 +6662,12 @@ EOF #-------------------------------------------------------------------- echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 -echo "configure:6573: checking for ANSI C header files" >&5 +echo "configure:6666: checking for ANSI C header files" >&5 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6578 "configure" +#line 6671 "configure" #include "confdefs.h" #include <stdlib.h> #include <stdarg.h> @@ -6582,7 +6675,7 @@ else #include <float.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6586: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6679: \"$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* @@ -6599,7 +6692,7 @@ rm -f conftest* if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat > conftest.$ac_ext <<EOF -#line 6603 "configure" +#line 6696 "configure" #include "confdefs.h" #include <string.h> EOF @@ -6617,7 +6710,7 @@ fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat > conftest.$ac_ext <<EOF -#line 6621 "configure" +#line 6714 "configure" #include "confdefs.h" #include <stdlib.h> EOF @@ -6638,7 +6731,7 @@ if test "$cross_compiling" = yes; then : else cat > conftest.$ac_ext <<EOF -#line 6642 "configure" +#line 6735 "configure" #include "confdefs.h" #include <ctype.h> #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') @@ -6649,7 +6742,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); exit (0); } EOF -if { (eval echo configure:6653: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:6746: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then : else @@ -6673,12 +6766,12 @@ EOF fi echo $ac_n "checking for mode_t""... $ac_c" 1>&6 -echo "configure:6677: checking for mode_t" >&5 +echo "configure:6770: checking for mode_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6682 "configure" +#line 6775 "configure" #include "confdefs.h" #include <sys/types.h> #if STDC_HEADERS @@ -6706,12 +6799,12 @@ EOF fi echo $ac_n "checking for pid_t""... $ac_c" 1>&6 -echo "configure:6710: checking for pid_t" >&5 +echo "configure:6803: checking for pid_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6715 "configure" +#line 6808 "configure" #include "confdefs.h" #include <sys/types.h> #if STDC_HEADERS @@ -6739,12 +6832,12 @@ EOF fi echo $ac_n "checking for size_t""... $ac_c" 1>&6 -echo "configure:6743: checking for size_t" >&5 +echo "configure:6836: checking for size_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6748 "configure" +#line 6841 "configure" #include "confdefs.h" #include <sys/types.h> #if STDC_HEADERS @@ -6772,12 +6865,12 @@ EOF fi echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 -echo "configure:6776: checking for uid_t in sys/types.h" >&5 +echo "configure:6869: checking for uid_t in sys/types.h" >&5 if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6781 "configure" +#line 6874 "configure" #include "confdefs.h" #include <sys/types.h> EOF @@ -6807,12 +6900,12 @@ fi echo $ac_n "checking for socklen_t""... $ac_c" 1>&6 -echo "configure:6811: checking for socklen_t" >&5 +echo "configure:6904: checking for socklen_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6816 "configure" +#line 6909 "configure" #include "confdefs.h" #include <sys/types.h> @@ -6851,12 +6944,12 @@ fi #-------------------------------------------------------------------- echo $ac_n "checking for opendir""... $ac_c" 1>&6 -echo "configure:6855: checking for opendir" >&5 +echo "configure:6948: checking for opendir" >&5 if eval "test \"`echo '$''{'ac_cv_func_opendir'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6860 "configure" +#line 6953 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char opendir(); below. */ @@ -6879,7 +6972,7 @@ opendir(); ; return 0; } EOF -if { (eval echo configure:6883: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6976: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_opendir=yes" else @@ -6912,12 +7005,12 @@ fi #-------------------------------------------------------------------- echo $ac_n "checking union wait""... $ac_c" 1>&6 -echo "configure:6916: checking union wait" >&5 +echo "configure:7009: checking union wait" >&5 if eval "test \"`echo '$''{'tcl_cv_union_wait'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6921 "configure" +#line 7014 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/wait.h> @@ -6929,7 +7022,7 @@ WIFEXITED(x); /* Generates compiler error if WIFEXITED ; return 0; } EOF -if { (eval echo configure:6933: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7026: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* tcl_cv_union_wait=yes else @@ -6956,12 +7049,12 @@ fi #-------------------------------------------------------------------- echo $ac_n "checking for strncasecmp""... $ac_c" 1>&6 -echo "configure:6960: checking for strncasecmp" >&5 +echo "configure:7053: checking for strncasecmp" >&5 if eval "test \"`echo '$''{'ac_cv_func_strncasecmp'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 6965 "configure" +#line 7058 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char strncasecmp(); below. */ @@ -6984,7 +7077,7 @@ strncasecmp(); ; return 0; } EOF -if { (eval echo configure:6988: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7081: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_strncasecmp=yes" else @@ -7006,7 +7099,7 @@ fi if test "$tcl_ok" = 0; then echo $ac_n "checking for strncasecmp in -lsocket""... $ac_c" 1>&6 -echo "configure:7010: checking for strncasecmp in -lsocket" >&5 +echo "configure:7103: checking for strncasecmp in -lsocket" >&5 ac_lib_var=`echo socket'_'strncasecmp | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -7014,7 +7107,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lsocket $LIBS" cat > conftest.$ac_ext <<EOF -#line 7018 "configure" +#line 7111 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -7025,7 +7118,7 @@ int main() { strncasecmp() ; return 0; } EOF -if { (eval echo configure:7029: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7122: \"$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 @@ -7049,7 +7142,7 @@ fi fi if test "$tcl_ok" = 0; then echo $ac_n "checking for strncasecmp in -linet""... $ac_c" 1>&6 -echo "configure:7053: checking for strncasecmp in -linet" >&5 +echo "configure:7146: checking for strncasecmp in -linet" >&5 ac_lib_var=`echo inet'_'strncasecmp | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -7057,7 +7150,7 @@ else ac_save_LIBS="$LIBS" LIBS="-linet $LIBS" cat > conftest.$ac_ext <<EOF -#line 7061 "configure" +#line 7154 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 @@ -7068,7 +7161,7 @@ int main() { strncasecmp() ; return 0; } EOF -if { (eval echo configure:7072: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7165: \"$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 @@ -7106,12 +7199,12 @@ fi #-------------------------------------------------------------------- echo $ac_n "checking for BSDgettimeofday""... $ac_c" 1>&6 -echo "configure:7110: checking for BSDgettimeofday" >&5 +echo "configure:7203: checking for BSDgettimeofday" >&5 if eval "test \"`echo '$''{'ac_cv_func_BSDgettimeofday'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 7115 "configure" +#line 7208 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char BSDgettimeofday(); below. */ @@ -7134,7 +7227,7 @@ BSDgettimeofday(); ; return 0; } EOF -if { (eval echo configure:7138: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7231: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_BSDgettimeofday=yes" else @@ -7156,12 +7249,12 @@ else echo "$ac_t""no" 1>&6 echo $ac_n "checking for gettimeofday""... $ac_c" 1>&6 -echo "configure:7160: checking for gettimeofday" >&5 +echo "configure:7253: checking for gettimeofday" >&5 if eval "test \"`echo '$''{'ac_cv_func_gettimeofday'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 7165 "configure" +#line 7258 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char gettimeofday(); below. */ @@ -7184,7 +7277,7 @@ gettimeofday(); ; return 0; } EOF -if { (eval echo configure:7188: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7281: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_gettimeofday=yes" else @@ -7211,12 +7304,12 @@ fi fi echo $ac_n "checking for gettimeofday declaration""... $ac_c" 1>&6 -echo "configure:7215: checking for gettimeofday declaration" >&5 +echo "configure:7308: checking for gettimeofday declaration" >&5 if eval "test \"`echo '$''{'tcl_cv_grep_gettimeofday'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 7220 "configure" +#line 7313 "configure" #include "confdefs.h" #include <sys/time.h> EOF @@ -7247,14 +7340,14 @@ fi #-------------------------------------------------------------------- echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6 -echo "configure:7251: checking whether char is unsigned" >&5 +echo "configure:7344: checking whether char is unsigned" >&5 if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else if test "$GCC" = yes; then # GCC predefines this symbol on systems where it applies. cat > conftest.$ac_ext <<EOF -#line 7258 "configure" +#line 7351 "configure" #include "confdefs.h" #ifdef __CHAR_UNSIGNED__ yes @@ -7276,7 +7369,7 @@ if test "$cross_compiling" = yes; then { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } else cat > conftest.$ac_ext <<EOF -#line 7280 "configure" +#line 7373 "configure" #include "confdefs.h" /* volatile prevents gcc2 from optimizing the test away on sparcs. */ #if !defined(__STDC__) || __STDC__ != 1 @@ -7286,7 +7379,7 @@ main() { volatile char c = 255; exit(c < 0); } EOF -if { (eval echo configure:7290: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:7383: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_c_char_unsigned=yes else @@ -7310,12 +7403,12 @@ EOF fi echo $ac_n "checking signed char declarations""... $ac_c" 1>&6 -echo "configure:7314: checking signed char declarations" >&5 +echo "configure:7407: checking signed char declarations" >&5 if eval "test \"`echo '$''{'tcl_cv_char_signed'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 7319 "configure" +#line 7412 "configure" #include "confdefs.h" int main() { @@ -7325,7 +7418,7 @@ int main() { ; return 0; } EOF -if { (eval echo configure:7329: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:7422: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_char_signed=yes else @@ -7350,7 +7443,7 @@ fi #-------------------------------------------------------------------- echo $ac_n "checking for a putenv() that copies the buffer""... $ac_c" 1>&6 -echo "configure:7354: checking for a putenv() that copies the buffer" >&5 +echo "configure:7447: checking for a putenv() that copies the buffer" >&5 if eval "test \"`echo '$''{'tcl_cv_putenv_copy'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7358,7 +7451,7 @@ else tcl_cv_putenv_copy=no else cat > conftest.$ac_ext <<EOF -#line 7362 "configure" +#line 7455 "configure" #include "confdefs.h" #include <stdlib.h> @@ -7380,7 +7473,7 @@ else } EOF -if { (eval echo configure:7384: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:7477: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then tcl_cv_putenv_copy=no else @@ -7421,17 +7514,17 @@ fi if test "$langinfo_ok" = "yes"; then ac_safe=`echo "langinfo.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for langinfo.h""... $ac_c" 1>&6 -echo "configure:7425: checking for langinfo.h" >&5 +echo "configure:7518: checking for langinfo.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 -#line 7430 "configure" +#line 7523 "configure" #include "confdefs.h" #include <langinfo.h> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7435: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7528: \"$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* @@ -7455,20 +7548,20 @@ fi fi echo $ac_n "checking whether to use nl_langinfo""... $ac_c" 1>&6 -echo "configure:7459: checking whether to use nl_langinfo" >&5 +echo "configure:7552: checking whether to use nl_langinfo" >&5 if test "$langinfo_ok" = "yes"; then if eval "test \"`echo '$''{'tcl_cv_langinfo_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 7465 "configure" +#line 7558 "configure" #include "confdefs.h" #include <langinfo.h> int main() { nl_langinfo(CODESET); ; return 0; } EOF -if { (eval echo configure:7472: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:7565: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* tcl_cv_langinfo_h=yes else @@ -7497,13 +7590,13 @@ EOF #-------------------------------------------------------------------- echo $ac_n "checking for fts""... $ac_c" 1>&6 -echo "configure:7501: checking for fts" >&5 +echo "configure:7594: checking for fts" >&5 if eval "test \"`echo '$''{'tcl_cv_api_fts'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <<EOF -#line 7507 "configure" +#line 7600 "configure" #include "confdefs.h" #include <sys/param.h> #include <sys/stat.h> @@ -7514,7 +7607,7 @@ char*const p[2] = {"/", NULL}; FTSENT *e = fts_read(f); fts_close(f); ; return 0; } EOF -if { (eval echo configure:7518: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7611: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* tcl_cv_api_fts=yes else @@ -7546,17 +7639,17 @@ fi do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:7550: checking for $ac_hdr" >&5 +echo "configure:7643: checking for $ac_hdr" >&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 -#line 7555 "configure" +#line 7648 "configure" #include "confdefs.h" #include <$ac_hdr> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7560: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7653: \"$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* @@ -7586,17 +7679,17 @@ done do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:7590: checking for $ac_hdr" >&5 +echo "configure:7683: checking for $ac_hdr" >&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 -#line 7595 "configure" +#line 7688 "configure" #include "confdefs.h" #include <$ac_hdr> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7600: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7693: \"$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* @@ -7622,26 +7715,40 @@ else fi done - echo $ac_n "checking FIONBIO vs. O_NONBLOCK for nonblocking I/O""... $ac_c" 1>&6 -echo "configure:7627: checking FIONBIO vs. O_NONBLOCK for nonblocking I/O" >&5 - if test -f /usr/lib/NextStep/software_version; then - system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version` - else - system=`uname -s`-`uname -r` - if test "$?" -ne 0 ; then - system=unknown + + echo $ac_n "checking system version""... $ac_c" 1>&6 +echo "configure:7721: checking system version" >&5 +if eval "test \"`echo '$''{'tcl_cv_sys_version'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + if test -f /usr/lib/NextStep/software_version; then + tcl_cv_sys_version=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version` else - # Special check for weird MP-RAS system (uname returns weird - # results, and the version is kept in special file). - - if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then - system=MP-RAS-`awk '{print }' /etc/.relid` - fi - if test "`uname -s`" = "AIX" ; then - system=AIX-`uname -v`.`uname -r` + tcl_cv_sys_version=`uname -s`-`uname -r` + if test "$?" -ne 0 ; then + echo "configure: warning: can't find uname command" 1>&2 + tcl_cv_sys_version=unknown + else + # Special check for weird MP-RAS system (uname returns weird + # results, and the version is kept in special file). + + if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then + tcl_cv_sys_version=MP-RAS-`awk '{print }' /etc/.relid` + fi + if test "`uname -s`" = "AIX" ; then + tcl_cv_sys_version=AIX-`uname -v`.`uname -r` + fi fi fi - fi + +fi + +echo "$ac_t""$tcl_cv_sys_version" 1>&6 + system=$tcl_cv_sys_version + + echo $ac_n "checking FIONBIO vs. O_NONBLOCK for nonblocking I/O""... $ac_c" 1>&6 +echo "configure:7752: checking FIONBIO vs. O_NONBLOCK for nonblocking I/O" >&5 case $system in # There used to be code here to use FIONBIO under AIX. However, it # was reported that FIONBIO doesn't work under AIX 3.2.5. Since @@ -7703,7 +7810,7 @@ HTML_DIR='$(DISTDIR)/html' if test "`uname -s`" = "Darwin" ; then echo $ac_n "checking how to package libraries""... $ac_c" 1>&6 -echo "configure:7707: checking how to package libraries" >&5 +echo "configure:7814: checking how to package libraries" >&5 # Check whether --enable-framework or --disable-framework was given. if test "${enable_framework+set}" = set; then enableval="$enable_framework" @@ -7724,11 +7831,11 @@ fi echo "$ac_t""framework" 1>&6 FRAMEWORK_BUILD=1 if test "${SHARED_BUILD}" = "0" ; then - echo "configure: warning: "Frameworks can only be built if --enable-shared is yes"" 1>&2 + echo "configure: warning: Frameworks can only be built if --enable-shared is yes" 1>&2 FRAMEWORK_BUILD=0 fi if test $tcl_corefoundation = no; then - echo "configure: warning: "Frameworks can only be used when CoreFoundation is available"" 1>&2 + echo "configure: warning: Frameworks can only be used when CoreFoundation is available" 1>&2 FRAMEWORK_BUILD=0 fi else diff --git a/unix/configure.in b/unix/configure.in index 6c0dd88..1c7918c 100644 --- a/unix/configure.in +++ b/unix/configure.in @@ -3,7 +3,7 @@ dnl This file is an input file used by the GNU "autoconf" program to dnl generate the file "configure", which is run during Tcl installation dnl to configure the system for the local environment. # -# RCS: @(#) $Id: configure.in,v 1.106.2.23 2005/12/14 02:10:21 das Exp $ +# RCS: @(#) $Id: configure.in,v 1.106.2.24 2006/01/10 05:37:06 das Exp $ AC_INIT(../generic/tcl.h) AC_PREREQ(2.13) @@ -31,6 +31,7 @@ TCL_SRC_DIR=`cd $srcdir/..; pwd` #------------------------------------------------------------------------ # Compress and/or soft link the manpages? #------------------------------------------------------------------------ + SC_CONFIG_MANPAGES([tcl]) #------------------------------------------------------------------------ @@ -46,12 +47,11 @@ fi AC_PROG_CC #-------------------------------------------------------------------- -# Supply substitutes for missing POSIX header files. Special -# notes: -# - stdlib.h doesn't define strtol, strtoul, or -# strtod insome versions of SunOS -# - some versions of string.h don't declare procedures such -# as strstr +# Supply substitutes for missing POSIX header files. Special notes: +# - stdlib.h doesn't define strtol, strtoul, or +# strtod insome versions of SunOS +# - some versions of string.h don't declare procedures such +# as strstr # Do this early, otherwise an autoconf bug throws errors on configure #-------------------------------------------------------------------- @@ -68,9 +68,9 @@ if test -n "$GCC"; then OLDCC="$CC" CC="$CC -pipe" AC_TRY_COMPILE(,, - AC_MSG_RESULT(yes), + AC_MSG_RESULT([yes]), CC="$OLDCC" - AC_MSG_RESULT(no)) + AC_MSG_RESULT([no])) fi fi @@ -153,18 +153,14 @@ SC_SERIAL_PORT # special flag. #-------------------------------------------------------------------- -AC_MSG_CHECKING([for fd_set in sys/types]) -AC_CACHE_VAL(tcl_cv_type_fd_set, +AC_CACHE_CHECK([for fd_set in sys/types], tcl_cv_type_fd_set, AC_TRY_COMPILE([#include <sys/types.h>],[fd_set readMask, writeMask;], tcl_cv_type_fd_set=yes, tcl_cv_type_fd_set=no)) -AC_MSG_RESULT($tcl_cv_type_fd_set) tcl_ok=$tcl_cv_type_fd_set -if test $tcl_cv_type_fd_set = no; then - AC_MSG_CHECKING([for fd_mask in sys/select]) - AC_CACHE_VAL(tcl_cv_grep_fd_mask, +if test $tcl_ok = no; then + AC_CACHE_CHECK([for fd_mask in sys/select], tcl_cv_grep_fd_mask, AC_EGREP_HEADER(fd_mask, sys/select.h, tcl_cv_grep_fd_mask=present, tcl_cv_grep_fd_mask=missing)) - AC_MSG_RESULT($tcl_cv_grep_fd_mask) if test $tcl_cv_grep_fd_mask = present; then AC_DEFINE(HAVE_SYS_SELECT_H) tcl_ok=yes @@ -206,18 +202,15 @@ AC_CHECK_FUNC(memmove, , [AC_DEFINE(NO_MEMMOVE) AC_DEFINE(NO_STRING_H)]) #-------------------------------------------------------------------- dnl only run if AC_REPLACE_FUNCS(strstr) hasn't already added strstr.o if test "x${ac_cv_func_strstr}" = "xyes"; then - AC_MSG_CHECKING([proper strstr implementation]) - AC_TRY_RUN([ - extern int strstr(); - int main() - { - exit(strstr("\0test", "test") ? 1 : 0); - } - ], tcl_ok=yes, tcl_ok=no, tcl_ok=no) - if test $tcl_ok = yes; then - AC_MSG_RESULT(yes) - else - AC_MSG_RESULT([broken, using substitute]) + AC_CACHE_CHECK([proper strstr implementation], tcl_cv_strstr_unbroken, [ + AC_TRY_RUN([ + extern int strstr(); + int main() + { + exit(strstr("\0test", "test") ? 1 : 0); + }], tcl_cv_strstr_unbroken=ok, tcl_cv_strstr_unbroken=broken, + tcl_cv_strstr_unbroken=broken)]) + if test $tcl_cv_strstr_unbroken = broken; then LIBOBJS="$LIBOBJS strstr.o" fi fi @@ -229,21 +222,27 @@ fi #-------------------------------------------------------------------- AC_CHECK_FUNC(strtoul, tcl_ok=1, tcl_ok=0) -AC_TRY_RUN([ -extern int strtoul(); -int main() -{ - char *string = "0"; - char *term; - int value; - value = strtoul(string, &term, 0); - if ((value != 0) || (term != (string+1))) { - exit(1); - } - exit(0); -}], , tcl_ok=0, tcl_ok=0) -if test "$tcl_ok" = 0; then - test -n "$verbose" && echo " Adding strtoul.o." +if test $tcl_ok = 1; then + AC_CACHE_CHECK([proper strtoul implementation], tcl_cv_strtoul_unbroken, [ + AC_TRY_RUN([ + extern int strtoul(); + int main() + { + char *string = "0"; + char *term; + int value; + value = strtoul(string, &term, 0); + if ((value != 0) || (term != (string+1))) { + exit(1); + } + exit(0); + }], tcl_cv_strtoul_unbroken=ok , tcl_cv_strtoul_unbroken=broken, + tcl_cv_strtoul_unbroken=broken)]) + if test $tcl_cv_strtoul_unbroken = broken; then + tcl_ok=0 + fi +fi +if test $tcl_ok = 0; then LIBOBJS="$LIBOBJS strtoul.o" fi @@ -253,21 +252,27 @@ fi #-------------------------------------------------------------------- AC_CHECK_FUNC(strtod, tcl_ok=1, tcl_ok=0) -AC_TRY_RUN([ -extern double strtod(); -int main() -{ - char *string = " +69"; - char *term; - double value; - value = strtod(string, &term); - if ((value != 69) || (term != (string+4))) { - exit(1); - } - exit(0); -}], , tcl_ok=0, tcl_ok=0) -if test "$tcl_ok" = 0; then - test -n "$verbose" && echo " Adding strtod.o." +if test $tcl_ok = 1; then + AC_CACHE_CHECK([proper strtod implementation], tcl_cv_strtod_unbroken, [ + AC_TRY_RUN([ + extern double strtod(); + int main() + { + char *string = " +69"; + char *term; + double value; + value = strtod(string, &term); + if ((value != 69) || (term != (string+4))) { + exit(1); + } + exit(0); + }], tcl_cv_strtod_unbroken=ok , tcl_cv_strtod_unbroken=broken, + tcl_cv_strtod_unbroken=broken)]) + if test $tcl_cv_strtod_unbroken = broken; then + tcl_ok=0 + fi +fi +if test $tcl_ok = 0; then LIBOBJS="$LIBOBJS strtod.o" fi @@ -290,8 +295,8 @@ AC_TYPE_PID_T AC_TYPE_SIZE_T AC_TYPE_UID_T -AC_MSG_CHECKING([for socklen_t]) -AC_CACHE_VAL(ac_cv_type_socklen_t,[AC_EGREP_CPP(changequote(<<,>>)dnl +AC_CACHE_CHECK([for socklen_t], ac_cv_type_socklen_t, + [AC_EGREP_CPP(changequote(<<,>>)dnl <<(^|[^a-zA-Z_0-9])socklen_t[^a-zA-Z_0-9]>>dnl changequote([,]),[ #include <sys/types.h> @@ -301,7 +306,6 @@ changequote([,]),[ #include <stddef.h> #endif ], ac_cv_type_socklen_t=yes, ac_cv_type_socklen_t=no)]) -AC_MSG_RESULT($ac_cv_type_socklen_t) if test $ac_cv_type_socklen_t = no; then AC_DEFINE(socklen_t, unsigned) fi @@ -323,15 +327,13 @@ AC_CHECK_FUNC(opendir, , [AC_DEFINE(USE_DIRENT2_H)]) # the trick. #-------------------------------------------------------------------- -AC_MSG_CHECKING([union wait]) -AC_CACHE_VAL(tcl_cv_union_wait, +AC_CACHE_CHECK([union wait], tcl_cv_union_wait, AC_TRY_LINK([#include <sys/types.h> #include <sys/wait.h>], [ union wait x; WIFEXITED(x); /* Generates compiler error if WIFEXITED * uses an int. */ ], tcl_cv_union_wait=yes, tcl_cv_union_wait=no)) -AC_MSG_RESULT($tcl_cv_union_wait) if test $tcl_cv_union_wait = no; then AC_DEFINE(NO_UNION_WAIT) fi @@ -368,11 +370,9 @@ AC_CHECK_FUNC(BSDgettimeofday, [AC_DEFINE(HAVE_BSDGETTIMEOFDAY)], [ AC_CHECK_FUNC(gettimeofday, , [AC_DEFINE(NO_GETTOD)]) ]) -AC_MSG_CHECKING([for gettimeofday declaration]) -AC_CACHE_VAL(tcl_cv_grep_gettimeofday, +AC_CACHE_CHECK([for gettimeofday declaration], tcl_cv_grep_gettimeofday, AC_EGREP_HEADER(gettimeofday, sys/time.h, tcl_cv_grep_gettimeofday=present, tcl_cv_grep_gettimeofday=missing)) -AC_MSG_RESULT($tcl_cv_grep_gettimeofday) if test $tcl_cv_grep_gettimeofday = missing ; then AC_DEFINE(GETTOD_NOT_DECLARED) fi @@ -384,13 +384,11 @@ fi #-------------------------------------------------------------------- AC_C_CHAR_UNSIGNED -AC_MSG_CHECKING([signed char declarations]) -AC_CACHE_VAL(tcl_cv_char_signed, +AC_CACHE_CHECK([signed char declarations], tcl_cv_char_signed, AC_TRY_COMPILE(, [ signed char *p; p = 0; ], tcl_cv_char_signed=yes, tcl_cv_char_signed=no)) -AC_MSG_RESULT($tcl_cv_char_signed) if test $tcl_cv_char_signed = yes; then AC_DEFINE(HAVE_SIGNED_CHAR) fi @@ -399,8 +397,7 @@ fi # Does putenv() copy or not? We need to know to avoid memory leaks. #-------------------------------------------------------------------- -AC_MSG_CHECKING([for a putenv() that copies the buffer]) -AC_CACHE_VAL(tcl_cv_putenv_copy, +AC_CACHE_CHECK([for a putenv() that copies the buffer], tcl_cv_putenv_copy, AC_TRY_RUN([ #include <stdlib.h> #define OURVAR "havecopy=yes" @@ -424,7 +421,6 @@ AC_CACHE_VAL(tcl_cv_putenv_copy, tcl_cv_putenv_copy=yes, tcl_cv_putenv_copy=no) ) -AC_MSG_RESULT($tcl_cv_putenv_copy) if test $tcl_cv_putenv_copy = yes; then AC_DEFINE(HAVE_PUTENV_THAT_COPIES) fi diff --git a/unix/tcl.m4 b/unix/tcl.m4 index 1c11781..9b86a7b 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 @@ -62,9 +62,25 @@ AC_DEFUN(SC_PATH_TCLCONFIG, [ done fi + # on Darwin, check in Framework installation locations + if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then + for i in `ls -d ~/Library/Frameworks 2>/dev/null` \ + `ls -d /Library/Frameworks 2>/dev/null` \ + `ls -d /Network/Library/Frameworks 2>/dev/null` \ + `ls -d /System/Library/Frameworks 2>/dev/null` \ + ; do + if test -f "$i/Tcl.framework/tclConfig.sh" ; then + ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)` + break + fi + done + fi + # check in a few common install locations if test x"${ac_cv_c_tclconfig}" = x ; then for i in `ls -d ${libdir} 2>/dev/null` \ + `ls -d ${exec_prefix}/lib 2>/dev/null` \ + `ls -d ${prefix}/lib 2>/dev/null` \ `ls -d /usr/local/lib 2>/dev/null` \ `ls -d /usr/contrib/lib 2>/dev/null` \ `ls -d /usr/lib 2>/dev/null` \ @@ -93,12 +109,12 @@ AC_DEFUN(SC_PATH_TCLCONFIG, [ if test x"${ac_cv_c_tclconfig}" = x ; then TCL_BIN_DIR="# no Tcl configs found" - AC_MSG_WARN(Can't find Tcl configuration definitions) + AC_MSG_WARN([Can't find Tcl configuration definitions]) exit 0 else no_tcl= TCL_BIN_DIR=${ac_cv_c_tclconfig} - AC_MSG_RESULT(found $TCL_BIN_DIR/tclConfig.sh) + AC_MSG_RESULT([found ${TCL_BIN_DIR}/tclConfig.sh]) fi fi ]) @@ -165,9 +181,26 @@ AC_DEFUN(SC_PATH_TKCONFIG, [ fi done fi + + # on Darwin, check in Framework installation locations + if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tkconfig}" = x ; then + for i in `ls -d ~/Library/Frameworks 2>/dev/null` \ + `ls -d /Library/Frameworks 2>/dev/null` \ + `ls -d /Network/Library/Frameworks 2>/dev/null` \ + `ls -d /System/Library/Frameworks 2>/dev/null` \ + ; do + if test -f "$i/Tk.framework/tkConfig.sh" ; then + ac_cv_c_tkconfig=`(cd $i/Tk.framework; pwd)` + break + fi + done + fi + # check in a few common install locations if test x"${ac_cv_c_tkconfig}" = x ; then for i in `ls -d ${libdir} 2>/dev/null` \ + `ls -d ${exec_prefix}/lib 2>/dev/null` \ + `ls -d ${prefix}/lib 2>/dev/null` \ `ls -d /usr/local/lib 2>/dev/null` \ `ls -d /usr/contrib/lib 2>/dev/null` \ `ls -d /usr/lib 2>/dev/null` \ @@ -192,17 +225,17 @@ AC_DEFUN(SC_PATH_TKCONFIG, [ done fi ]) + if test x"${ac_cv_c_tkconfig}" = x ; then TK_BIN_DIR="# no Tk configs found" - AC_MSG_WARN(Can't find Tk configuration definitions) + AC_MSG_WARN([Can't find Tk configuration definitions]) exit 0 else no_tk= TK_BIN_DIR=${ac_cv_c_tkconfig} - AC_MSG_RESULT(found $TK_BIN_DIR/tkConfig.sh) + AC_MSG_RESULT([found ${TK_BIN_DIR}/tkConfig.sh]) fi fi - ]) #------------------------------------------------------------------------ @@ -225,39 +258,55 @@ AC_DEFUN(SC_PATH_TKCONFIG, [ #------------------------------------------------------------------------ AC_DEFUN(SC_LOAD_TCLCONFIG, [ - AC_MSG_CHECKING([for existence of $TCL_BIN_DIR/tclConfig.sh]) + AC_MSG_CHECKING([for existence of ${TCL_BIN_DIR}/tclConfig.sh]) - if test -f "$TCL_BIN_DIR/tclConfig.sh" ; then + if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then AC_MSG_RESULT([loading]) - . $TCL_BIN_DIR/tclConfig.sh + . ${TCL_BIN_DIR}/tclConfig.sh else - AC_MSG_RESULT([file not found]) + AC_MSG_RESULT([could not find ${TCL_BIN_DIR}/tclConfig.sh]) fi - # + # eval is required to do the TCL_DBGX substitution + eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\"" + eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\"" + # If the TCL_BIN_DIR is the build directory (not the install directory), # then set the common variable name to the value of the build variables. # For example, the variable TCL_LIB_SPEC will be set to the value # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC # instead of TCL_BUILD_LIB_SPEC since it will work with both an # installed and uninstalled version of Tcl. - # - - if test -f $TCL_BIN_DIR/Makefile ; then + if test -f ${TCL_BIN_DIR}/Makefile ; then TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC} TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC} TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH} + elif test "`uname -s`" = "Darwin"; then + # If Tcl was built as a framework, attempt to use the libraries + # from the framework at the given location so that linking works + # against Tcl.framework installed in an arbitary location. + case ${TCL_DEFS} in + *TCL_FRAMEWORK*) + if test -f ${TCL_BIN_DIR}/${TCL_LIB_FILE}; then + for i in "`cd ${TCL_BIN_DIR}; pwd`" \ + "`cd ${TCL_BIN_DIR}/../..; pwd`"; do + if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then + TCL_LIB_SPEC="-F`dirname "$i"` -framework ${TCL_LIB_FILE}" + break + fi + done + fi + if test -f ${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}; then + TCL_STUB_LIB_SPEC="-L${TCL_BIN_DIR} ${TCL_STUB_LIB_FLAG}" + TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}" + fi + ;; + esac fi - # # eval is required to do the TCL_DBGX substitution - # - - eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\"" eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\"" eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\"" - - eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\"" eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\"" eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\"" @@ -291,19 +340,69 @@ AC_DEFUN(SC_LOAD_TCLCONFIG, [ #------------------------------------------------------------------------ AC_DEFUN(SC_LOAD_TKCONFIG, [ - AC_MSG_CHECKING([for existence of $TK_BIN_DIR/tkConfig.sh]) + AC_MSG_CHECKING([for existence of ${TK_BIN_DIR}/tkConfig.sh]) - if test -f "$TK_BIN_DIR/tkConfig.sh" ; then + if test -f "${TK_BIN_DIR}/tkConfig.sh" ; then AC_MSG_RESULT([loading]) - . $TK_BIN_DIR/tkConfig.sh + . ${TK_BIN_DIR}/tkConfig.sh else - AC_MSG_RESULT([could not find $TK_BIN_DIR/tkConfig.sh]) + AC_MSG_RESULT([could not find ${TK_BIN_DIR}/tkConfig.sh]) fi + # eval is required to do the TK_DBGX substitution + eval "TK_LIB_FILE=\"${TK_LIB_FILE}\"" + eval "TK_STUB_LIB_FILE=\"${TK_STUB_LIB_FILE}\"" + + # If the TK_BIN_DIR is the build directory (not the install directory), + # then set the common variable name to the value of the build variables. + # For example, the variable TK_LIB_SPEC will be set to the value + # of TK_BUILD_LIB_SPEC. An extension should make use of TK_LIB_SPEC + # instead of TK_BUILD_LIB_SPEC since it will work with both an + # installed and uninstalled version of Tcl. + if test -f ${TK_BIN_DIR}/Makefile ; then + TK_LIB_SPEC=${TK_BUILD_LIB_SPEC} + TK_STUB_LIB_SPEC=${TK_BUILD_STUB_LIB_SPEC} + TK_STUB_LIB_PATH=${TK_BUILD_STUB_LIB_PATH} + elif test "`uname -s`" = "Darwin"; then + # If Tk was built as a framework, attempt to use the libraries + # from the framework at the given location so that linking works + # against Tk.framework installed in an arbitary location. + case ${TK_DEFS} in + *TK_FRAMEWORK*) + if test -f ${TK_BIN_DIR}/${TK_LIB_FILE}; then + for i in "`cd ${TK_BIN_DIR}; pwd`" \ + "`cd ${TK_BIN_DIR}/../..; pwd`"; do + if test "`basename "$i"`" = "${TK_LIB_FILE}.framework"; then + TK_LIB_SPEC="-F`dirname "$i"` -framework ${TK_LIB_FILE}" + break + fi + done + fi + if test -f ${TK_BIN_DIR}/${TK_STUB_LIB_FILE}; then + TK_STUB_LIB_SPEC="-L${TK_BIN_DIR} ${TK_STUB_LIB_FLAG}" + TK_STUB_LIB_PATH="${TK_BIN_DIR}/${TK_STUB_LIB_FILE}" + fi + ;; + esac + fi + + # eval is required to do the TK_DBGX substitution + eval "TK_LIB_FLAG=\"${TK_LIB_FLAG}\"" + eval "TK_LIB_SPEC=\"${TK_LIB_SPEC}\"" + eval "TK_STUB_LIB_FLAG=\"${TK_STUB_LIB_FLAG}\"" + eval "TK_STUB_LIB_SPEC=\"${TK_STUB_LIB_SPEC}\"" + AC_SUBST(TK_VERSION) AC_SUBST(TK_BIN_DIR) AC_SUBST(TK_SRC_DIR) + AC_SUBST(TK_LIB_FILE) + AC_SUBST(TK_LIB_FLAG) + AC_SUBST(TK_LIB_SPEC) + + AC_SUBST(TK_STUB_LIB_FILE) + AC_SUBST(TK_STUB_LIB_FLAG) + AC_SUBST(TK_STUB_LIB_SPEC) ]) #------------------------------------------------------------------------ @@ -328,7 +427,6 @@ AC_DEFUN(SC_LOAD_TKCONFIG, [ AC_DEFUN(SC_PROG_TCLSH, [ AC_MSG_CHECKING([for tclsh]) - AC_CACHE_VAL(ac_cv_path_tclsh, [ search_path=`echo ${PATH} | sed -e 's/:/ /g'` for dir in $search_path ; do @@ -346,7 +444,7 @@ AC_DEFUN(SC_PROG_TCLSH, [ if test -f "$ac_cv_path_tclsh" ; then TCLSH_PROG="$ac_cv_path_tclsh" - AC_MSG_RESULT($TCLSH_PROG) + AC_MSG_RESULT([$TCLSH_PROG]) else # It is not an error if an installed version of Tcl can't be located. TCLSH_PROG="" @@ -375,7 +473,7 @@ AC_DEFUN(SC_PROG_TCLSH, [ AC_DEFUN(SC_BUILD_TCLSH, [ AC_MSG_CHECKING([for tclsh in Tcl build directory]) BUILD_TCLSH=${TCL_BIN_DIR}/tclsh - AC_MSG_RESULT($BUILD_TCLSH) + AC_MSG_RESULT([$BUILD_TCLSH]) AC_SUBST(BUILD_TCLSH) ]) @@ -457,11 +555,11 @@ AC_DEFUN(SC_ENABLE_FRAMEWORK, [ AC_MSG_RESULT([framework]) FRAMEWORK_BUILD=1 if test "${SHARED_BUILD}" = "0" ; then - AC_MSG_WARN("Frameworks can only be built if --enable-shared is yes") + AC_MSG_WARN([Frameworks can only be built if --enable-shared is yes]) FRAMEWORK_BUILD=0 fi if test $tcl_corefoundation = no; then - AC_MSG_WARN("Frameworks can only be used when CoreFoundation is available") + AC_MSG_WARN([Frameworks can only be used when CoreFoundation is available]) FRAMEWORK_BUILD=0 fi else @@ -496,18 +594,15 @@ AC_DEFUN(SC_ENABLE_FRAMEWORK, [ #------------------------------------------------------------------------ AC_DEFUN(SC_ENABLE_THREADS, [ - AC_MSG_CHECKING(for building with threads) AC_ARG_ENABLE(threads, [ --enable-threads build with threads], [tcl_ok=$enableval], [tcl_ok=no]) + if test "${TCL_THREADS}" = 1; then + tcl_threaded_core=1; + fi + if test "$tcl_ok" = "yes" -o "${TCL_THREADS}" = 1; then - if test "${TCL_THREADS}" = 1; then - AC_MSG_RESULT([yes (threaded core)]) - else - AC_MSG_RESULT([yes]) - fi TCL_THREADS=1 - AC_DEFINE(TCL_THREADS) # USE_THREAD_ALLOC tells us to try the special thread-based # allocator that significantly reduces lock contention AC_DEFINE(USE_THREAD_ALLOC) @@ -523,29 +618,33 @@ AC_DEFUN(SC_ENABLE_THREADS, [ # defined. We could alternatively do an AC_TRY_COMPILE with # pthread.h, but that will work with libpthread really doesn't # exist, like AIX 4.2. [Bug: 4359] - AC_CHECK_LIB(pthread,__pthread_mutex_init,tcl_ok=yes,tcl_ok=no) + AC_CHECK_LIB(pthread, __pthread_mutex_init, + tcl_ok=yes, tcl_ok=no) fi if test "$tcl_ok" = "yes"; then # The space is needed THREADS_LIBS=" -lpthread" else - AC_CHECK_LIB(pthreads,pthread_mutex_init,tcl_ok=yes,tcl_ok=no) + AC_CHECK_LIB(pthreads, pthread_mutex_init, + tcl_ok=yes, tcl_ok=no) if test "$tcl_ok" = "yes"; then # The space is needed THREADS_LIBS=" -lpthreads" else - AC_CHECK_LIB(c,pthread_mutex_init,tcl_ok=yes,tcl_ok=no) - if test "$tcl_ok" = "no"; then - AC_CHECK_LIB(c_r,pthread_mutex_init,tcl_ok=yes,tcl_ok=no) + AC_CHECK_LIB(c, pthread_mutex_init, + tcl_ok=yes, tcl_ok=no) + if test "$tcl_ok" = "no"; then + AC_CHECK_LIB(c_r, pthread_mutex_init, + tcl_ok=yes, tcl_ok=no) if test "$tcl_ok" = "yes"; then # The space is needed THREADS_LIBS=" -pthread" else TCL_THREADS=0 - AC_MSG_WARN("Don t know how to find pthread lib on your system - you must disable thread support or edit the LIBS in the Makefile...") + AC_MSG_WARN([Don't know how to find pthread lib on your system - you must disable thread support or edit the LIBS in the Makefile...]) fi - fi + fi fi fi @@ -559,8 +658,20 @@ AC_DEFUN(SC_ENABLE_THREADS, [ LIBS=$ac_saved_libs else TCL_THREADS=0 + fi + # Do checking message here to not mess up interleaved configure output + AC_MSG_CHECKING([for building with threads]) + if test "${TCL_THREADS}" = 1; then + AC_DEFINE(TCL_THREADS, 1, [Are we building with threads enabled?]) + if test "${tcl_threaded_core}" = 1; then + AC_MSG_RESULT([yes (threaded core)]) + else + AC_MSG_RESULT([yes]) + fi + else AC_MSG_RESULT([no (default)]) fi + AC_SUBST(TCL_THREADS) ]) @@ -666,7 +777,7 @@ AC_DEFUN(SC_ENABLE_LANGINFO, [ AC_CACHE_VAL(tcl_cv_langinfo_h, AC_TRY_COMPILE([#include <langinfo.h>], [nl_langinfo(CODESET);], [tcl_cv_langinfo_h=yes],[tcl_cv_langinfo_h=no])) - AC_MSG_RESULT($tcl_cv_langinfo_h) + AC_MSG_RESULT([$tcl_cv_langinfo_h]) if test $tcl_cv_langinfo_h = yes; then AC_DEFINE(HAVE_LANGINFO) fi @@ -714,8 +825,11 @@ AC_DEFUN(SC_CONFIG_MANPAGES, [ AC_ARG_ENABLE(man-compression, [ --enable-man-compression=PROG compress the manpages with PROG], - test "$enableval" = "yes" && AC_MSG_ERROR([missing argument to --enable-man-compression]) - test "$enableval" != "no" && MAN_FLAGS="$MAN_FLAGS --compress $enableval", + [case $enableval in + yes) AC_MSG_ERROR([missing argument to --enable-man-compression]);; + no) ;; + *) MAN_FLAGS="$MAN_FLAGS --compress $enableval";; + esac], enableval="no") AC_MSG_RESULT([$enableval]) if test "$enableval" != "no"; then @@ -733,8 +847,11 @@ AC_DEFUN(SC_CONFIG_MANPAGES, [ [ --enable-man-suffix=STRING use STRING as a suffix to manpage file names (default: $1)], - test "$enableval" = "yes" && enableval="$1" - test "$enableval" != "no" && MAN_FLAGS="$MAN_FLAGS --suffix $enableval", + [case $enableval in + yes) enableval="$1" MAN_FLAGS="$MAN_FLAGS --suffix $enableval";; + no) ;; + *) MAN_FLAGS="$MAN_FLAGS --suffix $enableval";; + esac], enableval="no") AC_MSG_RESULT([$enableval]) @@ -742,6 +859,49 @@ AC_DEFUN(SC_CONFIG_MANPAGES, [ ]) #-------------------------------------------------------------------- +# SC_CONFIG_SYSTEM +# +# Determine what the system is (some things cannot be easily checked +# on a feature-driven basis, alas). This can usually be done via the +# "uname" command, but there are a few systems, like Next, where +# this doesn't work. +# +# Arguments: +# none +# +# Results: +# Defines the following var: +# +# system - System/platform/version identification code. +# +#-------------------------------------------------------------------- + +AC_DEFUN(SC_CONFIG_SYSTEM, [ + AC_CACHE_CHECK([system version], tcl_cv_sys_version, [ + if test -f /usr/lib/NextStep/software_version; then + tcl_cv_sys_version=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version` + else + tcl_cv_sys_version=`uname -s`-`uname -r` + if test "$?" -ne 0 ; then + AC_MSG_WARN([can't find uname command]) + tcl_cv_sys_version=unknown + else + # Special check for weird MP-RAS system (uname returns weird + # results, and the version is kept in special file). + + if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then + tcl_cv_sys_version=MP-RAS-`awk '{print $3}' /etc/.relid` + fi + if test "`uname -s`" = "AIX" ; then + tcl_cv_sys_version=AIX-`uname -v`.`uname -r` + fi + fi + fi + ]) + system=$tcl_cv_sys_version +]) + +#-------------------------------------------------------------------- # SC_CONFIG_CFLAGS # # Try to determine the proper flags to pass to the compiler @@ -839,54 +999,26 @@ AC_DEFUN(SC_CONFIG_CFLAGS, [ # Step 0.a: Enable 64 bit support? AC_MSG_CHECKING([if 64bit support is requested]) - AC_ARG_ENABLE(64bit,[ --enable-64bit enable 64bit support (where applicable)],,enableval="no") - - if test "$enableval" = "yes"; then - do64bit=yes - else - do64bit=no - fi - AC_MSG_RESULT($do64bit) + AC_ARG_ENABLE(64bit,[ --enable-64bit enable 64bit support (where applicable)], + [do64bit=$enableval], [do64bit=no]) + AC_MSG_RESULT([$do64bit]) # Step 0.b: Enable Solaris 64 bit VIS support? AC_MSG_CHECKING([if 64bit Sparc VIS support is requested]) - AC_ARG_ENABLE(64bit-vis,[ --enable-64bit-vis enable 64bit Sparc VIS support],,enableval="no") + AC_ARG_ENABLE(64bit-vis,[ --enable-64bit-vis enable 64bit Sparc VIS support], + [do64bitVIS=$enableval], [do64bitVIS=no]) + AC_MSG_RESULT([$do64bitVIS]) - if test "$enableval" = "yes"; then + if test "$do64bitVIS" = "yes"; then # Force 64bit on with VIS do64bit=yes - do64bitVIS=yes - else - do64bitVIS=no fi - AC_MSG_RESULT($do64bitVIS) # Step 1: set the variable "system" to hold the name and version number - # for the system. This can usually be done via the "uname" command, but - # there are a few systems, like Next, where this doesn't work. + # for the system. - AC_MSG_CHECKING([system version (for dynamic loading)]) - if test -f /usr/lib/NextStep/software_version; then - system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version` - else - system=`uname -s`-`uname -r` - if test "$?" -ne 0 ; then - AC_MSG_RESULT([unknown (can't find uname command)]) - system=unknown - else - # Special check for weird MP-RAS system (uname returns weird - # results, and the version is kept in special file). - - if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then - system=MP-RAS-`awk '{print $3}' /etc/.relid` - fi - if test "`uname -s`" = "AIX" ; then - system=AIX-`uname -v`.`uname -r` - fi - AC_MSG_RESULT($system) - fi - fi + SC_CONFIG_SYSTEM # Step 2: check for existence of -ldl library. This is needed because # Linux can use either -ldl or -ldld for dynamic loading. @@ -1090,18 +1222,18 @@ dnl AC_CHECK_TOOL(AR, ar) # Check to enable 64-bit flags for compiler/linker if test "$do64bit" = "yes" ; then if test "$GCC" = "yes" ; then - hpux_arch=`gcc -dumpmachine` + hpux_arch=`${CC} -dumpmachine` case $hpux_arch in hppa64*) # 64-bit gcc in use. Fix flags for GNU ld. do64bit_ok=yes - SHLIB_LD="gcc -shared" + SHLIB_LD="${CC} -shared" SHLIB_LD_LIBS='${LIBS}' CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} ;; *) - AC_MSG_WARN("64bit mode not supported with GCC on $system") + AC_MSG_WARN([64bit mode not supported with GCC on $system]) ;; esac else @@ -1310,17 +1442,17 @@ dnl AC_CHECK_TOOL(AR, ar) DL_LIBS="" CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}' - AC_MSG_CHECKING(for ELF) - AC_EGREP_CPP(yes, [ + AC_CACHE_CHECK([for ELF], tcl_cv_ld_elf, [ + AC_EGREP_CPP(yes, [ #ifdef __ELF__ yes #endif - ], - AC_MSG_RESULT(yes) - SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so', - AC_MSG_RESULT(no) + ], tcl_cv_ld_elf=yes, tcl_cv_ld_elf=no)]) + if test $tcl_cv_ld_elf = yes; then + SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so' + else SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0' - ) + fi ], [ SHLIB_CFLAGS="" SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r" @@ -1368,17 +1500,17 @@ dnl AC_CHECK_TOOL(AR, ar) CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0' - AC_MSG_CHECKING(for ELF) - AC_EGREP_CPP(yes, [ + AC_CACHE_CHECK([for ELF], tcl_cv_ld_elf, [ + AC_EGREP_CPP(yes, [ #ifdef __ELF__ yes #endif - ], - AC_MSG_RESULT(yes) - [ LDFLAGS=-Wl,-export-dynamic ], - AC_MSG_RESULT(no) + ], tcl_cv_ld_elf=yes, tcl_cv_ld_elf=no)]) + if test $tcl_cv_ld_elf = yes; then + LDFLAGS=-Wl,-export-dynamic + else LDFLAGS="" - ) + fi ;; esac @@ -1501,8 +1633,8 @@ dnl AC_CHECK_TOOL(AR, ar) LD_SEARCH_FLAGS="" ;; OS/390-*) - CFLAGS_OPTIMIZE="" # Optimizer is buggy - AC_DEFINE(_OE_SOCKETS) # needed in sys/socket.h + CFLAGS_OPTIMIZE="" # Optimizer is buggy + AC_DEFINE(_OE_SOCKETS) # needed in sys/socket.h ;; OSF1-1.0|OSF1-1.1|OSF1-1.2) # OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1 @@ -1760,12 +1892,14 @@ dnl AC_CHECK_TOOL(AR, ar) DL_LIBS="-ldl" # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers # that don't grok the -Bexport option. Test that it does. - hold_ldflags=$LDFLAGS - AC_MSG_CHECKING(for ld accepts -Bexport flag) - LDFLAGS="$LDFLAGS -Wl,-Bexport" - AC_TRY_LINK(, [int i;], [found=yes], - [LDFLAGS=$hold_ldflags found=no]) - AC_MSG_RESULT($found) + AC_CACHE_CHECK([for ld accepts -Bexport flag], tcl_cv_ld_Bexport, [ + hold_ldflags=$LDFLAGS + LDFLAGS="$LDFLAGS -Wl,-Bexport" + AC_TRY_LINK(, [int i;], tcl_cv_ld_Bexport=yes, tcl_cv_ld_Bexport=no) + LDFLAGS=$hold_ldflags]) + if test $tcl_cv_ld_Bexport = yes; then + LDFLAGS="$LDFLAGS -Wl,-Bexport" + fi CC_SEARCH_FLAGS="" LD_SEARCH_FLAGS="" ;; @@ -1795,7 +1929,7 @@ dnl AC_CHECK_TOOL(AR, ar) # duplicates the v7 fields that are needed. if test "x$DL_OBJS" = "xtclLoadAout.o" ; then - AC_MSG_CHECKING(sys/exec.h) + AC_CACHE_CHECK([sys/exec.h], tcl_cv_sysexec_h, [ AC_TRY_COMPILE([#include <sys/exec.h>],[ struct exec foo; unsigned long seek; @@ -1807,12 +1941,11 @@ dnl AC_CHECK_TOOL(AR, ar) #endif flag = (foo.a_magic == OMAGIC); return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry; - ], tcl_ok=usable, tcl_ok=unusable) - AC_MSG_RESULT($tcl_ok) - if test $tcl_ok = usable; then + ], tcl_cv_sysexec_h=usable, tcl_cv_sysexec_h=unusable)]) + if test $tcl_cv_sysexec_h = usable; then AC_DEFINE(USE_SYS_EXEC_H) else - AC_MSG_CHECKING(a.out.h) + AC_CACHE_CHECK([a.out.h], tcl_cv_aout_h, [ AC_TRY_COMPILE([#include <a.out.h>],[ struct exec foo; unsigned long seek; @@ -1824,12 +1957,11 @@ dnl AC_CHECK_TOOL(AR, ar) #endif flag = (foo.a_magic == OMAGIC); return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry; - ], tcl_ok=usable, tcl_ok=unusable) - AC_MSG_RESULT($tcl_ok) - if test $tcl_ok = usable; then + ], tcl_cv_aout_h=usable, tcl_cv_aout_h=unusable)]) + if test $tcl_cv_aout_h = usable; then AC_DEFINE(USE_A_OUT_H) else - AC_MSG_CHECKING(sys/exec_aout.h) + AC_CACHE_CHECK([sys/exec_aout.h], tcl_cv_sysexecaout_h, [ AC_TRY_COMPILE([#include <sys/exec_aout.h>],[ struct exec foo; unsigned long seek; @@ -1841,9 +1973,8 @@ dnl AC_CHECK_TOOL(AR, ar) #endif flag = (foo.a_midmag == OMAGIC); return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry; - ], tcl_ok=usable, tcl_ok=unusable) - AC_MSG_RESULT($tcl_ok) - if test $tcl_ok = usable; then + ], tcl_cv_sysexecaout_h=usable, tcl_cv_sysexecaout_h=unusable)]) + if test $tcl_cv_sysexecaout_h = usable; then AC_DEFINE(USE_SYS_EXEC_AOUT_H) else DL_OBJS="" @@ -2009,8 +2140,7 @@ dnl esac AC_DEFUN(SC_SERIAL_PORT, [ AC_CHECK_HEADERS(sys/modem.h) - AC_MSG_CHECKING([termios vs. termio vs. sgtty]) - AC_CACHE_VAL(tcl_cv_api_serial, [ + AC_CACHE_CHECK([termios vs. termio vs. sgtty], tcl_cv_api_serial, [ AC_TRY_RUN([ #include <termios.h> @@ -2102,7 +2232,6 @@ int main() { termio) AC_DEFINE(USE_TERMIO);; sgtty) AC_DEFINE(USE_SGTTY);; esac - AC_MSG_RESULT($tcl_cv_api_serial) ]) #-------------------------------------------------------------------- @@ -2137,8 +2266,7 @@ int main() { #-------------------------------------------------------------------- AC_DEFUN(SC_MISSING_POSIX_HEADERS, [ - AC_MSG_CHECKING(dirent.h) - AC_CACHE_VAL(tcl_cv_dirent_h, + AC_CACHE_CHECK([dirent.h], tcl_cv_dirent_h, AC_TRY_LINK([#include <sys/types.h> #include <dirent.h>], [ #ifndef _POSIX_SOURCE @@ -2164,7 +2292,6 @@ closedir(d); AC_DEFINE(NO_DIRENT_H) fi - AC_MSG_RESULT($tcl_ok) AC_CHECK_HEADER(errno.h, , [AC_DEFINE(NO_ERRNO_H)]) AC_CHECK_HEADER(float.h, , [AC_DEFINE(NO_FLOAT_H)]) AC_CHECK_HEADER(values.h, , [AC_DEFINE(NO_VALUES_H)]) @@ -2229,14 +2356,14 @@ AC_DEFUN(SC_PATH_X, [ fi fi if test "$no_x" = "yes" -o "$not_really_there" = "yes"; then - AC_MSG_CHECKING(for X11 header files) + AC_MSG_CHECKING([for X11 header files]) found_xincludes="no" AC_TRY_CPP([#include <X11/Intrinsic.h>], found_xincludes="yes", found_xincludes="no") if test "$found_xincludes" = "no"; then dirs="/usr/unsupported/include /usr/local/include /usr/X386/include /usr/X11R6/include /usr/X11R5/include /usr/include/X11R5 /usr/include/X11R4 /usr/openwin/include /usr/X11/include /usr/sww/include" for i in $dirs ; do if test -r $i/X11/Intrinsic.h; then - AC_MSG_RESULT($i) + AC_MSG_RESULT([$i]) XINCLUDES=" -I$i" found_xincludes="yes" break @@ -2250,16 +2377,16 @@ AC_DEFUN(SC_PATH_X, [ fi fi if test found_xincludes = "no"; then - AC_MSG_RESULT(couldn't find any!) + AC_MSG_RESULT([couldn't find any!]) fi if test "$no_x" = yes; then - AC_MSG_CHECKING(for X11 libraries) + AC_MSG_CHECKING([for X11 libraries]) XLIBSW=nope dirs="/usr/unsupported/lib /usr/local/lib /usr/X386/lib /usr/X11R6/lib /usr/X11R5/lib /usr/lib/X11R5 /usr/lib/X11R4 /usr/openwin/lib /usr/X11/lib /usr/sww/X11/lib" for i in $dirs ; do if test -r $i/libX11.a -o -r $i/libX11.so -o -r $i/libX11.sl; then - AC_MSG_RESULT($i) + AC_MSG_RESULT([$i]) XLIBSW="-L$i -lX11" x_libraries="$i" break @@ -2276,7 +2403,7 @@ AC_DEFUN(SC_PATH_X, [ AC_CHECK_LIB(Xwindow, XCreateWindow, XLIBSW=-lXwindow) fi if test "$XLIBSW" = nope ; then - AC_MSG_RESULT(couldn't find any! Using -lX11.) + AC_MSG_RESULT([could not find any! Using -lX11.]) XLIBSW=-lX11 fi ]) @@ -2305,25 +2432,8 @@ AC_DEFUN(SC_PATH_X, [ AC_DEFUN(SC_BLOCKING_STYLE, [ AC_CHECK_HEADERS(sys/ioctl.h) AC_CHECK_HEADERS(sys/filio.h) + SC_CONFIG_SYSTEM AC_MSG_CHECKING([FIONBIO vs. O_NONBLOCK for nonblocking I/O]) - if test -f /usr/lib/NextStep/software_version; then - system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version` - else - system=`uname -s`-`uname -r` - if test "$?" -ne 0 ; then - system=unknown - else - # Special check for weird MP-RAS system (uname returns weird - # results, and the version is kept in special file). - - if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then - system=MP-RAS-`awk '{print $3}' /etc/.relid` - fi - if test "`uname -s`" = "AIX" ; then - system=AIX-`uname -v`.`uname -r` - fi - fi - fi case $system in # There used to be code here to use FIONBIO under AIX. However, it # was reported that FIONBIO doesn't work under AIX 3.2.5. Since @@ -2332,18 +2442,18 @@ AC_DEFUN(SC_BLOCKING_STYLE, [ OSF*) AC_DEFINE(USE_FIONBIO) - AC_MSG_RESULT(FIONBIO) + AC_MSG_RESULT([FIONBIO]) ;; SunOS-4*) AC_DEFINE(USE_FIONBIO) - AC_MSG_RESULT(FIONBIO) + AC_MSG_RESULT([FIONBIO]) ;; ULTRIX-4.*) AC_DEFINE(USE_FIONBIO) - AC_MSG_RESULT(FIONBIO) + AC_MSG_RESULT([FIONBIO]) ;; *) - AC_MSG_RESULT(O_NONBLOCK) + AC_MSG_RESULT([O_NONBLOCK]) ;; esac ]) @@ -2374,20 +2484,16 @@ AC_DEFUN(SC_TIME_HANDLER, [ AC_CHECK_FUNCS(gmtime_r localtime_r) - AC_MSG_CHECKING([tm_tzadj in struct tm]) - AC_CACHE_VAL(tcl_cv_member_tm_tzadj, + AC_CACHE_CHECK([tm_tzadj in struct tm], tcl_cv_member_tm_tzadj, AC_TRY_COMPILE([#include <time.h>], [struct tm tm; tm.tm_tzadj;], tcl_cv_member_tm_tzadj=yes, tcl_cv_member_tm_tzadj=no)) - AC_MSG_RESULT($tcl_cv_member_tm_tzadj) if test $tcl_cv_member_tm_tzadj = yes ; then AC_DEFINE(HAVE_TM_TZADJ) fi - AC_MSG_CHECKING([tm_gmtoff in struct tm]) - AC_CACHE_VAL(tcl_cv_member_tm_gmtoff, + AC_CACHE_CHECK([tm_gmtoff in struct tm], tcl_cv_member_tm_gmtoff, AC_TRY_COMPILE([#include <time.h>], [struct tm tm; tm.tm_gmtoff;], tcl_cv_member_tm_gmtoff=yes, tcl_cv_member_tm_gmtoff=no)) - AC_MSG_RESULT($tcl_cv_member_tm_gmtoff) if test $tcl_cv_member_tm_gmtoff = yes ; then AC_DEFINE(HAVE_TM_GMTOFF) fi @@ -2396,28 +2502,24 @@ AC_DEFUN(SC_TIME_HANDLER, [ # Its important to include time.h in this check, as some systems # (like convex) have timezone functions, etc. # - AC_MSG_CHECKING([long timezone variable]) - AC_CACHE_VAL(tcl_cv_timezone_long, + AC_CACHE_CHECK([long timezone variable], tcl_cv_timezone_long, AC_TRY_COMPILE([#include <time.h>], [extern long timezone; timezone += 1; exit (0);], tcl_cv_timezone_long=yes, tcl_cv_timezone_long=no)) - AC_MSG_RESULT($tcl_cv_timezone_long) if test $tcl_cv_timezone_long = yes ; then AC_DEFINE(HAVE_TIMEZONE_VAR) else # # On some systems (eg IRIX 6.2), timezone is a time_t and not a long. # - AC_MSG_CHECKING([time_t timezone variable]) - AC_CACHE_VAL(tcl_cv_timezone_time, + AC_CACHE_CHECK([time_t timezone variable], tcl_cv_timezone_time, AC_TRY_COMPILE([#include <time.h>], [extern time_t timezone; timezone += 1; exit (0);], tcl_cv_timezone_time=yes, tcl_cv_timezone_time=no)) - AC_MSG_RESULT($tcl_cv_timezone_time) if test $tcl_cv_timezone_time = yes ; then AC_DEFINE(HAVE_TIMEZONE_VAR) fi @@ -2447,8 +2549,7 @@ AC_DEFUN(SC_TIME_HANDLER, [ AC_DEFUN(SC_BUGGY_STRTOD, [ AC_CHECK_FUNC(strtod, tcl_strtod=1, tcl_strtod=0) if test "$tcl_strtod" = 1; then - AC_MSG_CHECKING([for Solaris2.4/Tru64 strtod bugs]) - AC_CACHE_VAL(tcl_cv_strtod_buggy,[ + AC_CACHE_CHECK([for Solaris2.4/Tru64 strtod bugs], tcl_cv_strtod_buggy,[ AC_TRY_RUN([ extern double strtod(); int main() { @@ -2468,11 +2569,9 @@ AC_DEFUN(SC_BUGGY_STRTOD, [ exit(1); } exit(0); - }], tcl_cv_strtod_buggy=1, tcl_cv_strtod_buggy=0, tcl_cv_strtod_buggy=0)]) - if test "$tcl_cv_strtod_buggy" = 1; then - AC_MSG_RESULT(ok) - else - AC_MSG_RESULT(buggy) + }], tcl_cv_strtod_buggy=ok, tcl_cv_strtod_buggy=buggy, + tcl_cv_strtod_buggy=buggy)]) + if test "$tcl_cv_strtod_buggy" = buggy; then LIBOBJS="$LIBOBJS fixstrtod.o" AC_DEFINE(strtod, fixstrtod) fi @@ -2593,7 +2692,8 @@ AC_DEFUN(SC_TCL_EARLY_FLAG,[ if test ["x${tcl_cv_flag_]translit($1,[A-Z],[a-z])[}" = "xyes"] ; then AC_DEFINE($1) tcl_flags="$tcl_flags $1" - fi]) + fi +]) AC_DEFUN(SC_TCL_EARLY_FLAGS,[ AC_MSG_CHECKING([for required early compiler flags]) @@ -2605,10 +2705,11 @@ AC_DEFUN(SC_TCL_EARLY_FLAGS,[ SC_TCL_EARLY_FLAG(_LARGEFILE_SOURCE64,[#include <sys/stat.h>], [char *p = (char *)open64;]) if test "x${tcl_flags}" = "x" ; then - AC_MSG_RESULT(none) + AC_MSG_RESULT([none]) else - AC_MSG_RESULT(${tcl_flags}) - fi]) + AC_MSG_RESULT([${tcl_flags}]) + fi +]) #-------------------------------------------------------------------- # SC_TCL_64BIT_FLAGS @@ -2644,31 +2745,27 @@ AC_DEFUN(SC_TCL_64BIT_FLAGS, [ }],tcl_cv_type_64bit=${tcl_type_64bit})]) if test "${tcl_cv_type_64bit}" = none ; then AC_DEFINE(TCL_WIDE_INT_IS_LONG) - AC_MSG_RESULT(using long) + AC_MSG_RESULT([using long]) else AC_DEFINE_UNQUOTED(TCL_WIDE_INT_TYPE,${tcl_cv_type_64bit}) - AC_MSG_RESULT(${tcl_cv_type_64bit}) + AC_MSG_RESULT([${tcl_cv_type_64bit}]) # Now check for auxiliary declarations - AC_MSG_CHECKING([for struct dirent64]) - AC_CACHE_VAL(tcl_cv_struct_dirent64,[ + AC_CACHE_CHECK([for struct dirent64], tcl_cv_struct_dirent64,[ AC_TRY_COMPILE([#include <sys/types.h> #include <sys/dirent.h>],[struct dirent64 p;], tcl_cv_struct_dirent64=yes,tcl_cv_struct_dirent64=no)]) if test "x${tcl_cv_struct_dirent64}" = "xyes" ; then AC_DEFINE(HAVE_STRUCT_DIRENT64) fi - AC_MSG_RESULT(${tcl_cv_struct_dirent64}) - AC_MSG_CHECKING([for struct stat64]) - AC_CACHE_VAL(tcl_cv_struct_stat64,[ + AC_CACHE_CHECK([for struct stat64], tcl_cv_struct_stat64,[ AC_TRY_COMPILE([#include <sys/stat.h>],[struct stat64 p; ], tcl_cv_struct_stat64=yes,tcl_cv_struct_stat64=no)]) if test "x${tcl_cv_struct_stat64}" = "xyes" ; then AC_DEFINE(HAVE_STRUCT_STAT64) fi - AC_MSG_RESULT(${tcl_cv_struct_stat64}) AC_CHECK_FUNCS(open64 lseek64) AC_MSG_CHECKING([for off64_t]) @@ -2682,8 +2779,9 @@ AC_DEFUN(SC_TCL_64BIT_FLAGS, [ test "x${ac_cv_func_lseek64}" = "xyes" && \ test "x${ac_cv_func_open64}" = "xyes" ; then AC_DEFINE(HAVE_TYPE_OFF64_T) - AC_MSG_RESULT(yes) + AC_MSG_RESULT([yes]) else - AC_MSG_RESULT(no) + AC_MSG_RESULT([no]) fi - fi]) + fi +]) |