From 76392f8cc4f1ec559c228b3e717510eb88855a60 Mon Sep 17 00:00:00 2001 From: Bruce Momjian Date: Fri, 9 Oct 1998 00:51:50 +0000 Subject: [PATCH] Autoconf --- src/configure | 79 ++++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 68 insertions(+), 11 deletions(-) diff --git a/src/configure b/src/configure index 304b1ecf2d..d148585bfd 100755 --- a/src/configure +++ b/src/configure @@ -6112,6 +6112,30 @@ fi fi +if test "$USE_TCL"; then + echo $ac_n "checking for tclConfig.sh""... $ac_c" 1>&6 +echo "configure:6118: checking for tclConfig.sh" >&5 + library_dirs="/usr/lib $LIBRARY_DIRS" + TCL_CONFIG_SH= + for dir in $library_dirs; do + for tcl_dir in $tcl_dirs; do + if test -z "$TCL_CONFIG_SH"; then + if test -d "$dir/$tcl_dir" -a -r "$dir/$tcl_dir/tclConfig.sh"; then + TCL_CONFIG_SH=$dir/$tcl_dir/tclConfig.sh + fi + fi + done + done + if test -z "$TCL_CONFIG_SH"; then + echo "$ac_t""no" 1>&6 + echo "configure: warning: tcl support disabled; Tcl configuration script missing" 1>&2 + USE_TCL= + else + echo "$ac_t""$TCL_CONFIG_SH" 1>&6 + + fi +fi + if test "$USE_TCL" = "true" then @@ -6125,17 +6149,17 @@ then TK_INCDIR=no ac_safe=`echo "tk.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for tk.h""... $ac_c" 1>&6 -echo "configure:6129: checking for tk.h" >&5 +echo "configure:6153: checking for tk.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6139: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6163: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* @@ -6184,7 +6208,7 @@ then for tk_lib in $tk_libs; do if test -z "$TK_LIB"; then echo $ac_n "checking for main in -l$tk_lib""... $ac_c" 1>&6 -echo "configure:6188: checking for main in -l$tk_lib" >&5 +echo "configure:6212: checking for main in -l$tk_lib" >&5 ac_lib_var=`echo $tk_lib'_'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 @@ -6192,14 +6216,14 @@ else ac_save_LIBS="$LIBS" LIBS="-l$tk_lib $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest; then +if { (eval echo configure:6227: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -6245,17 +6269,17 @@ then PWD_INCDIR=no ac_safe=`echo "pwd.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for pwd.h""... $ac_c" 1>&6 -echo "configure:6249: checking for pwd.h" >&5 +echo "configure:6273: checking for pwd.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6259: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6283: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* @@ -6385,7 +6409,23 @@ done ac_given_srcdir=$srcdir -trap 'rm -fr `echo "GNUmakefile Makefile.global backend/port/Makefile bin/pg_version/Makefile bin/psql/Makefile bin/pg_dump/Makefile backend/utils/Gen_fmgrtab.sh interfaces/libpq/Makefile interfaces/libpq++/Makefile interfaces/libpgtcl/Makefile interfaces/ecpg/lib/Makefile include/version.h interfaces/odbc/Makefile.global interfaces/odbc/GNUmakefile include/config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 +trap 'rm -fr `echo "GNUmakefile + Makefile.global + backend/port/Makefile + backend/utils/Gen_fmgrtab.sh + bin/pg_dump/Makefile + bin/pg_version/Makefile + bin/psql/Makefile + include/version.h + interfaces/ecpg/lib/Makefile + interfaces/libpgtcl/Makefile + interfaces/libpq++/Makefile + interfaces/libpq/Makefile + interfaces/odbc/GNUmakefile + interfaces/odbc/Makefile.global + pl/plpgsql/src/Makefile + pl/tcl/mkMakefile.tcldefs.sh + include/config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 EOF cat >> $CONFIG_STATUS <> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then