diff --git a/configure b/configure index fe15c80de..527802d32 100755 --- a/configure +++ b/configure @@ -4028,15 +4028,22 @@ if test "$ALLOW_TCL_MFILES" = no ; then fi if test "$FAST_TCL_INTERP" = yes ; then - TCL_INCLUDE=/usr/include/tcl TCL_LIBS="-ltcl" OS=$(uname -s) if test "$OS" = Darwin ; then TCL_INCLUDE=$(xcrun --show-sdk-path) TCL_INCLUDE=${DIR}/usr/include + else + for i in "" tcl tcl8.8 tcl8.7 tcl8.6 tcl8.5; do + if test -f /usr/include/$i/tcl.h ; then + TCL_INCLUDE=/usr/include/$i + break; + fi + done fi - # Extract the first word of "pkg-config", so it can be a program name with args. + if test -z "$TCL_INCLUDE" ; then + # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } @@ -4077,15 +4084,16 @@ $as_echo "no" >&6; } fi - if ! test x$pkgConfig = "x"; then - for i in tcl tcl8.8 tcl8.7 tcl8.6 tcl8.5; do - $pkgConfig --exists $i - if test $? = 0; then - TCL_INCLUDE=`$pkgConfig --cflags $i | sed -e 's/^-I//' -e 's/ //g'` - TCL_LIBS=`$pkgConfig --libs $i` - break - fi - done + if ! test x$pkgConfig = "x"; then + for i in tcl tcl8.8 tcl8.7 tcl8.6 tcl8.5; do + $pkgConfig --exists $i + if test $? = 0; then + TCL_INCLUDE=`$pkgConfig --cflags $i | sed -e 's/^-I//' -e 's/ //g'` + TCL_LIBS=`$pkgConfig --libs $i` + break + fi + done + fi fi CPPFLAGS="-I $TCL_INCLUDE" @@ -5112,7 +5120,6 @@ fi PATH_TO_LUA=$(FOLLOW_READLINK $FIND_PATH_TO_LUA) fi -echo "2) PATH_TO_LUA: $PATH_TO_LUA" if ! command -v $PATH_TO_LUAC &>/dev/null ; then echo 'The program "'$PATH_TO_LUAC'" must be in your path' diff --git a/configure.ac b/configure.ac index 32a770376..3fa5fd8b6 100644 --- a/configure.ac +++ b/configure.ac @@ -776,7 +776,6 @@ if test ${PATH_TO_LUA:0:1} != '/' ; then AC_PATH_PROG(FIND_PATH_TO_LUA, $PATH_TO_LUA) PATH_TO_LUA=$(FOLLOW_READLINK $FIND_PATH_TO_LUA) fi -echo "2) PATH_TO_LUA: $PATH_TO_LUA" if ! command -v $PATH_TO_LUAC &>/dev/null ; then echo 'The program "'$PATH_TO_LUAC'" must be in your path'