diff --git a/configure b/configure index 8360364db9b..00ad3e5f1de 100755 --- a/configure +++ b/configure @@ -52,10 +52,12 @@ ac_help="$ac_help --with-krb-srvnam=NAME name of the Postgres service principal in Kerberos" ac_help="$ac_help --with-krb-srvtab=FILE location of Kerberos server's keytab file" +ac_help="$ac_help + --with-openssl[=DIR] build with OpenSSL support [/usr/local/ssl]" ac_help="$ac_help --enable-odbc build the ODBC driver package" ac_help="$ac_help - --with-odbcinst=DIR default directory for odbcinst.ini [datadir]" + --with-odbcinst=DIR default directory for odbcinst.ini [sysconfdir]" ac_help="$ac_help --enable-cassert enable assertion checks (for debugging) " ac_help="$ac_help @@ -581,7 +583,7 @@ fi ac_aux_dir= -for ac_dir in `pwd`/config $srcdir/`pwd`/config; do +for ac_dir in config $srcdir/config; do if test -f $ac_dir/install-sh; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install-sh -c" @@ -593,7 +595,7 @@ for ac_dir in `pwd`/config $srcdir/`pwd`/config; do fi done if test -z "$ac_aux_dir"; then - { echo "configure: error: can not find install-sh or install.sh in `pwd`/config $srcdir/`pwd`/config" 1>&2; exit 1; } + { echo "configure: error: can not find install-sh or install.sh in config $srcdir/config" 1>&2; exit 1; } fi ac_config_guess=$ac_aux_dir/config.guess ac_config_sub=$ac_aux_dir/config.sub @@ -607,9 +609,6 @@ cat >> confdefs.h </dev/null 2>&1; then : @@ -617,7 +616,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; } fi echo $ac_n "checking host system type""... $ac_c" 1>&6 -echo "configure:621: checking host system type" >&5 +echo "configure:620: checking host system type" >&5 host_alias=$host case "$host_alias" in @@ -701,7 +700,7 @@ fi echo $ac_n "checking setting template to""... $ac_c" 1>&6 -echo "configure:705: checking setting template to" >&5 +echo "configure:704: checking setting template to" >&5 # Check whether --with-template or --without-template was given. if test "${with_template+set}" = set; then withval="$with_template" @@ -834,7 +833,7 @@ fi echo $ac_n "checking whether to support locale""... $ac_c" 1>&6 -echo "configure:838: checking whether to support locale" >&5 +echo "configure:837: checking whether to support locale" >&5 # Check whether --enable-locale or --disable-locale was given. if test "${enable_locale+set}" = set; then enableval="$enable_locale" @@ -849,7 +848,7 @@ fi echo $ac_n "checking whether to support cyrillic recode""... $ac_c" 1>&6 -echo "configure:853: checking whether to support cyrillic recode" >&5 +echo "configure:852: checking whether to support cyrillic recode" >&5 # Check whether --enable-recode or --disable-recode was given. if test "${enable_recode+set}" = set; then enableval="$enable_recode" @@ -865,7 +864,7 @@ fi echo $ac_n "checking whether to support multibyte""... $ac_c" 1>&6 -echo "configure:869: checking whether to support multibyte" >&5 +echo "configure:868: checking whether to support multibyte" >&5 # Check whether --enable-multibyte or --disable-multibyte was given. if test "${enable_multibyte+set}" = set; then enableval="$enable_multibyte" @@ -904,7 +903,7 @@ fi echo $ac_n "checking setting DEF_PGPORT""... $ac_c" 1>&6 -echo "configure:908: checking setting DEF_PGPORT" >&5 +echo "configure:907: checking setting DEF_PGPORT" >&5 # Check whether --with-pgport or --without-pgport was given. if test "${with_pgport+set}" = set; then withval="$with_pgport" @@ -926,7 +925,7 @@ echo "$ac_t""${default_port}" 1>&6 echo $ac_n "checking setting DEF_MAXBACKENDS""... $ac_c" 1>&6 -echo "configure:930: checking setting DEF_MAXBACKENDS" >&5 +echo "configure:929: checking setting DEF_MAXBACKENDS" >&5 # Check whether --with-maxbackends or --without-maxbackends was given. if test "${with_maxbackends+set}" = set; then withval="$with_maxbackends" @@ -961,7 +960,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:965: checking for $ac_word" >&5 +echo "configure:964: 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 @@ -991,7 +990,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:995: checking for $ac_word" >&5 +echo "configure:994: 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 @@ -1042,7 +1041,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:1046: checking for $ac_word" >&5 +echo "configure:1045: 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 @@ -1074,7 +1073,7 @@ fi fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 -echo "configure:1078: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +echo "configure:1077: 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. @@ -1085,12 +1084,12 @@ cross_compiling=$ac_cv_prog_cc_cross cat > conftest.$ac_ext << EOF -#line 1089 "configure" +#line 1088 "configure" #include "confdefs.h" main(){return(0);} EOF -if { (eval echo configure:1094: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1093: \"$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 @@ -1116,12 +1115,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:1120: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +echo "configure:1119: 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:1125: checking whether we are using GNU C" >&5 +echo "configure:1124: 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 @@ -1130,7 +1129,7 @@ else yes; #endif EOF -if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1134: \"$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:1133: \"$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 @@ -1149,7 +1148,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:1153: checking whether ${CC-cc} accepts -g" >&5 +echo "configure:1152: 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 @@ -1181,7 +1180,7 @@ else fi echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 -echo "configure:1185: checking how to run the C preprocessor" >&5 +echo "configure:1184: checking how to run the C preprocessor" >&5 # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= @@ -1196,13 +1195,13 @@ else # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1206: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1205: \"$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 : @@ -1213,13 +1212,13 @@ else rm -rf conftest* CPP="${CC-cc} -E -traditional-cpp" cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1223: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1222: \"$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 : @@ -1230,13 +1229,13 @@ else rm -rf conftest* CPP="${CC-cc} -nologo -E" cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1240: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1239: \"$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 : @@ -1262,13 +1261,13 @@ echo "$ac_t""$CPP" 1>&6 if test $ac_cv_prog_gcc = yes; then echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6 -echo "configure:1266: checking whether ${CC-cc} needs -traditional" >&5 +echo "configure:1265: checking whether ${CC-cc} needs -traditional" >&5 if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else ac_pattern="Autoconf.*'x'" cat > conftest.$ac_ext < Autoconf TIOCGETP @@ -1286,7 +1285,7 @@ rm -f conftest* if test $ac_cv_prog_gcc_traditional = no; then cat > conftest.$ac_ext < Autoconf TCGETA @@ -1322,7 +1321,7 @@ EOF echo $ac_n "checking setting USE_TCL""... $ac_c" 1>&6 -echo "configure:1326: checking setting USE_TCL" >&5 +echo "configure:1325: checking setting USE_TCL" >&5 # Check whether --with-tcl or --without-tcl was given. if test "${with_tcl+set}" = set; then withval="$with_tcl" @@ -1375,7 +1374,7 @@ fi echo $ac_n "checking whether to build Perl modules""... $ac_c" 1>&6 -echo "configure:1379: checking whether to build Perl modules" >&5 +echo "configure:1378: checking whether to build Perl modules" >&5 # Check whether --with-perl or --without-perl was given. if test "${with_perl+set}" = set; then withval="$with_perl" @@ -1392,7 +1391,7 @@ fi echo $ac_n "checking whether to build Python modules""... $ac_c" 1>&6 -echo "configure:1396: checking whether to build Python modules" >&5 +echo "configure:1395: checking whether to build Python modules" >&5 # Check whether --with-python or --without-python was given. if test "${with_python+set}" = set; then withval="$with_python" @@ -1401,7 +1400,7 @@ if test "${with_python+set}" = set; then # Extract the first word of "python", so it can be a program name with args. set dummy python; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1405: checking for $ac_word" >&5 +echo "configure:1404: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_PYTHON'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1437,7 +1436,7 @@ if test "${PYTHON+set}" = set ; then python_extmakefile="${python_configdir}/Makefile.pre.in" echo $ac_n "checking for Python extension makefile""... $ac_c" 1>&6 -echo "configure:1441: checking for Python extension makefile" >&5 +echo "configure:1440: checking for Python extension makefile" >&5 if test -f "${python_extmakefile}" ; then echo "$ac_t""found" 1>&6 else @@ -1465,306 +1464,103 @@ fi -echo $ac_n "checking whether to build with Kerberos 4 support""... $ac_c" 1>&6 -echo "configure:1470: checking whether to build with Kerberos 4 support" >&5 + +# +# Kerberos 4 +# # Check whether --with-krb4 or --without-krb4 was given. if test "${with_krb4+set}" = set; then withval="$with_krb4" if test x"$withval" != x"no"; then - # If the user didn't give an argument, we take the Kerberos 4 default - # path /usr/athena. We look into lib/ and include/ for the Kerberos - # libraries and includes. If the user has a more complicated layout - # he can use --with-includes and --with-libraries. - if test x"$withval" = x"yes"; then - krb4dir=/usr/athena + if test x"$withval" != x"yes"; then + krb4_prefix=$withval else - krb4dir=$withval + krb4_prefix=/usr/athena fi with_krb4=yes - echo "$ac_t""yes" 1>&6 - if test -d $krb4dir; then - if test -d "$krb4dir/include"; then - INCLUDES="$INCLUDES -I$krb4dir/include" - fi - if test -d "$krb4dir/lib"; then - krb_libdir="-L$krb4dir/lib" - LIBS="$krb_libdir $LIBS" - fi - fi - echo $ac_n "checking for main in -ldes""... $ac_c" 1>&6 -echo "configure:1496: checking for main in -ldes" >&5 -ac_lib_var=`echo des'_'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 else - ac_save_LIBS="$LIBS" -LIBS="-ldes $LIBS" -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" -else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + with_krb4=no fi -rm -f conftest* -LIBS="$ac_save_LIBS" - -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_lib=HAVE_LIB`echo des | sed -e 's/[^a-zA-Z0-9_]/_/g' \ - -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` - cat >> confdefs.h <&6 -{ echo "configure: error: library \`des' is required for Kerberos 4" 1>&2; exit 1; } + with_krb4=no fi - echo $ac_n "checking for main in -lkrb""... $ac_c" 1>&6 -echo "configure:1540: checking for main in -lkrb" >&5 -ac_lib_var=`echo krb'_'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 -else - ac_save_LIBS="$LIBS" -LIBS="-lkrb $LIBS" -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" -else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" -fi -rm -f conftest* -LIBS="$ac_save_LIBS" -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_lib=HAVE_LIB`echo krb | sed -e 's/[^a-zA-Z0-9_]/_/g' \ - -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` - cat >> confdefs.h <&6 -{ echo "configure: error: library \`krb' is required for Kerberos 4" 1>&2; exit 1; } -fi - - KRB_LIBS="$krb_libdir -lkrb -ldes" +if test "$with_krb4" = yes ; then + echo "$ac_t""building with Kerberos 4 support" 1>&6 cat >> confdefs.h <<\EOF #define KRB4 EOF -else - echo "$ac_t""no" 1>&6 -fi -else - echo "$ac_t""no" 1>&6 + + if test -d "$krb4_prefix"; then + if test -d "$krb4_prefix/include"; then + INCLUDES="$INCLUDES -I$krb4_prefix/include" + fi + if test -d "$krb4_prefix/lib"; then + krb_libdir="-L$krb4_prefix/lib" + LIBS="$krb_libdir $LIBS" + fi + fi + KRB_LIBS="$krb_libdir -lkrb -ldes" fi - - -echo $ac_n "checking whether to build with Kerberos 5 support""... $ac_c" 1>&6 -echo "configure:1599: checking whether to build with Kerberos 5 support" >&5 +# +# Kerberos 5 +# # Check whether --with-krb5 or --without-krb5 was given. if test "${with_krb5+set}" = set; then withval="$with_krb5" if test x"$withval" != x"no"; then - if test x"$withval" = x"yes"; then - krb5dir=/usr/athena + if test x"$withval" != x"yes"; then + krb5_prefix=$withval else - krb5dir=$withval + krb5_prefix=/usr/athena fi with_krb5=yes - echo "$ac_t""yes" 1>&6 - if test -d $krb5dir; then - if test -d "$krb5dir/include"; then - INCLUDES="$INCLUDES -I$krb5dir/include" - fi - if test -d "$krb5dir/lib"; then - krb_libdir="-L$krb5dir/lib" - LIBS="$krb_libdir $LIBS" - fi - fi - echo $ac_n "checking for main in -lcom_err""... $ac_c" 1>&6 -echo "configure:1621: checking for main in -lcom_err" >&5 -ac_lib_var=`echo com_err'_'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 else - ac_save_LIBS="$LIBS" -LIBS="-lcom_err $LIBS" -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" -else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + with_krb5=no fi -rm -f conftest* -LIBS="$ac_save_LIBS" - -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_lib=HAVE_LIB`echo com_err | sed -e 's/[^a-zA-Z0-9_]/_/g' \ - -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` - cat >> confdefs.h <&6 -{ echo "configure: error: library \`com_err' is required for Kerberos 5" 1>&2; exit 1; } + with_krb5=no fi - echo $ac_n "checking for main in -lcrypto""... $ac_c" 1>&6 -echo "configure:1665: checking for main in -lcrypto" >&5 -ac_lib_var=`echo crypto'_'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 -else - ac_save_LIBS="$LIBS" -LIBS="-lcrypto $LIBS" -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" -else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" -fi -rm -f conftest* -LIBS="$ac_save_LIBS" -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_lib=HAVE_LIB`echo crypto | sed -e 's/[^a-zA-Z0-9_]/_/g' \ - -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` - cat >> confdefs.h <&6 -{ echo "configure: error: library \`crypto' is required for Kerberos 5" 1>&2; exit 1; } -fi - - echo $ac_n "checking for main in -lkrb5""... $ac_c" 1>&6 -echo "configure:1709: checking for main in -lkrb5" >&5 -ac_lib_var=`echo krb5'_'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 -else - ac_save_LIBS="$LIBS" -LIBS="-lkrb5 $LIBS" -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" -else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" -fi -rm -f conftest* -LIBS="$ac_save_LIBS" - -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_lib=HAVE_LIB`echo krb5 | sed -e 's/[^a-zA-Z0-9_]/_/g' \ - -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` - cat >> confdefs.h <&6 -{ echo "configure: error: library \`krb5' is required for Kerberos 5" 1>&2; exit 1; } -fi - - KRB_LIBS="$krb_libdir -lkrb5 -lcrypto -lcom_err" +if test "$with_krb5" = yes ; then + echo "$ac_t""building with Kerberos 5 support" 1>&6 cat >> confdefs.h <<\EOF #define KRB5 EOF -else - echo "$ac_t""no" 1>&6 + + if test -d $krb5_prefix; then + if test -d "$krb5_prefix/include"; then + INCLUDES="$INCLUDES -I$krb5_prefix/include" + fi + if test -d "$krb5_prefix/lib"; then + krb_libdir="-L$krb5_prefix/lib" + LIBS="$krb_libdir $LIBS" + fi + fi + + KRB_LIBS="$krb_libdir -lkrb5 -lcrypto -lcom_err" fi -else - echo "$ac_t""no" 1>&6 + + +# Using both Kerberos 4 and Kerberos 5 at the same time isn't going to work. +if test "$with_krb4" = yes && test "$with_krb5" = yes ; then + { echo "configure: error: Kerberos 4 and Kerberos 5 support cannot be combined" 1>&2; exit 1; } fi - - +# +# Kerberos configuration parameters +# # Check whether --with-krb-srvnam or --without-krb-srvnam was given. if test "${with_krb_srvnam+set}" = set; then withval="$with_krb_srvnam" @@ -1791,18 +1587,62 @@ else krb_srvtab=$withval fi else - if test x"$with_krb5" = x"yes"; then - krb_srvtab="FILE:/usr/local/postgres/krb5.keytab" + if test "$with_krb5" = yes ; then + krb_srvtab='FILE:${sysconfdir}/krb5.keytab' +elif test "$with_krb4" = yes ; then + krb_srvtab='/etc/srvtab' else - krb_srvtab="/etc/srvtab" + krb_srvtab= fi fi -cat >> confdefs.h <&6 + cat >> confdefs.h <<\EOF +#define USE_SSL EOF + if test -d "${openssl_prefix}/include" ; then + INCLUDES="$INCLUDES -I${openssl_prefix}/include" + fi + if test -d "${openssl_prefix}/lib" ; then + openssl_libdir="${openssl_prefix}/lib" + LIBS="$LIBS -L${openssl_prefix}/lib" + fi +fi + + +# OpenSSL and Kerberos 5 both have a `crypto' library, so if you want to +# use both of them you'll have to figure it out yourself. +if test "$with_openssl" = yes && test "$with_krb5" = yes ; then + { echo "configure: error: OpenSSL and Kerberos 5 support cannot be combined" 1>&2; exit 1; } +fi @@ -1811,7 +1651,7 @@ if test "x${with_odbc+set}" = xset && test "x${enable_odbc+set}" != xset; then fi echo $ac_n "checking whether to build the ODBC driver""... $ac_c" 1>&6 -echo "configure:1815: checking whether to build the ODBC driver" >&5 +echo "configure:1655: checking whether to build the ODBC driver" >&5 # Check whether --enable-odbc or --disable-odbc was given. if test "${enable_odbc+set}" = set; then enableval="$enable_odbc" @@ -1836,18 +1676,18 @@ if test "${with_odbcinst+set}" = set; then fi odbcinst_ini_dir=$withval else - odbcinst_ini_dir='${datadir}' + odbcinst_ini_dir='${sysconfdir}' fi else - odbcinst_ini_dir='${datadir}' + odbcinst_ini_dir='${sysconfdir}' fi echo $ac_n "checking setting ASSERT CHECKING""... $ac_c" 1>&6 -echo "configure:1851: checking setting ASSERT CHECKING" >&5 +echo "configure:1691: checking setting ASSERT CHECKING" >&5 # Check whether --enable-cassert or --disable-cassert was given. if test "${enable_cassert+set}" = set; then enableval="$enable_cassert" @@ -1868,7 +1708,7 @@ LDFLAGS="$LDFLAGS $PGSQL_LDFLAGS" echo "- setting LDFLAGS=$LDFLAGS" echo $ac_n "checking setting debug compiler flag""... $ac_c" 1>&6 -echo "configure:1872: checking setting debug compiler flag" >&5 +echo "configure:1712: checking setting debug compiler flag" >&5 # Check whether --enable-debug or --disable-debug was given. if test "${enable_debug+set}" = set; then enableval="$enable_debug" @@ -1893,7 +1733,7 @@ fi # Assume system is ELF if it predefines __ELF__ as 1, # otherwise believe "elf" setting from check of host_os above. cat > conftest.$ac_ext <&6 -echo "configure:1938: checking whether to build C++ modules" >&5 +echo "configure:1778: checking whether to build C++ modules" >&5 # Check whether --with-CXX or --without-CXX was given. if test "${with_CXX+set}" = set; then withval="$with_CXX" @@ -1948,7 +1788,7 @@ do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1952: checking for $ac_word" >&5 +echo "configure:1792: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1980,7 +1820,7 @@ test -n "$CXX" || CXX="gcc" echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6 -echo "configure:1984: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5 +echo "configure:1824: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5 ac_ext=C # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. @@ -1991,12 +1831,12 @@ cross_compiling=$ac_cv_prog_cxx_cross cat > conftest.$ac_ext << EOF -#line 1995 "configure" +#line 1835 "configure" #include "confdefs.h" int main(){return(0);} EOF -if { (eval echo configure:2000: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1840: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ac_cv_prog_cxx_works=yes # If we can't run a trivial program, we are probably using a cross compiler. if (./conftest; exit) 2>/dev/null; then @@ -2022,12 +1862,12 @@ if test $ac_cv_prog_cxx_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 ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 -echo "configure:2026: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5 +echo "configure:1866: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5 echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6 cross_compiling=$ac_cv_prog_cxx_cross echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6 -echo "configure:2031: checking whether we are using GNU C++" >&5 +echo "configure:1871: checking whether we are using GNU C++" >&5 if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2036,7 +1876,7 @@ else yes; #endif EOF -if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:2040: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then +if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1880: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then ac_cv_prog_gxx=yes else ac_cv_prog_gxx=no @@ -2055,7 +1895,7 @@ ac_test_CXXFLAGS="${CXXFLAGS+set}" ac_save_CXXFLAGS="$CXXFLAGS" CXXFLAGS= echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6 -echo "configure:2059: checking whether ${CXX-g++} accepts -g" >&5 +echo "configure:1899: checking whether ${CXX-g++} accepts -g" >&5 if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2087,7 +1927,7 @@ else fi echo $ac_n "checking how to run the C++ preprocessor""... $ac_c" 1>&6 -echo "configure:2091: checking how to run the C++ preprocessor" >&5 +echo "configure:1931: checking how to run the C++ preprocessor" >&5 if test -z "$CXXCPP"; then if eval "test \"`echo '$''{'ac_cv_prog_CXXCPP'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2100,12 +1940,12 @@ ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftes cross_compiling=$ac_cv_prog_cxx_cross CXXCPP="${CXX-g++} -E" cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2109: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1949: \"$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 : @@ -2139,17 +1979,17 @@ cross_compiling=$ac_cv_prog_cxx_cross ac_safe=`echo "string" | sed 'y%./+-%__p_%'` echo $ac_n "checking for string""... $ac_c" 1>&6 -echo "configure:2143: checking for string" >&5 +echo "configure:1983: checking for string" >&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:2153: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1993: \"$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* @@ -2176,12 +2016,12 @@ fi if test x"$ac_cv_header_string" != xyes ; then echo $ac_n "checking for class string in ""... $ac_c" 1>&6 -echo "configure:2180: checking for class string in " >&5 +echo "configure:2020: checking for class string in " >&5 if eval "test \"`echo '$''{'pgac_cv_class_string_in_string_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #include @@ -2191,7 +2031,7 @@ int main() { string foo = "test" ; return 0; } EOF -if { (eval echo configure:2195: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2035: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* pgac_cv_class_string_in_string_h=yes else @@ -2218,7 +2058,7 @@ cross_compiling=$ac_cv_prog_cc_cross echo $ac_n "checking for namespace std in C++""... $ac_c" 1>&6 -echo "configure:2222: checking for namespace std in C++" >&5 +echo "configure:2062: checking for namespace std in C++" >&5 if eval "test \"`echo '$''{'pgac_cv_cxx_namespace_std'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2232,7 +2072,7 @@ ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftes cross_compiling=$ac_cv_prog_cxx_cross cat > conftest.$ac_ext < #include @@ -2245,7 +2085,7 @@ int main() { ; return 0; } EOF -if { (eval echo configure:2249: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2089: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* pgac_cv_cxx_namespace_std=yes else @@ -2282,7 +2122,7 @@ fi - +# Figure out how to invoke "install" and what install options to use. # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or @@ -2296,7 +2136,7 @@ fi # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # ./install, which can be erroneously created by make from ./install.sh. echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 -echo "configure:2300: checking for a BSD compatible install" >&5 +echo "configure:2140: checking for a BSD compatible install" >&5 if test -z "$INSTALL"; then if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2348,37 +2188,37 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' - -INSTLOPTS="-m 444" -INSTL_EXE_OPTS="-m 555" -INSTL_SCRIPT_OPTS="-m 755" -INSTL_LIB_OPTS="-m 644" -INSTL_SHLIB_OPTS="-m 644" - -case "$host_os" in - hpux*) - INSTL_SHLIB_OPTS="-m 555" ;; +# When Autoconf chooses install-sh as install program it tries to generate +# a relative path to it in each makefile where it subsitutes it. This clashes +# with our Makefile.global concept. This workaround helps. +case $INSTALL in + *install-sh*) INSTALL='\${SHELL} \${top_srcdir}/config/install-sh -c';; esac +# Fix Autoconf's brain-dead defaults for script installs. +INSTALL_SCRIPT="\${INSTALL} -m 755" - - - - - -INSTALL_SCRIPT="\${INSTALL} $INSTL_SCRIPT_OPTS" - +# HPUX wants shared libs to be mode 555. Add your platform's special +# needs here if necessary. +case $host_os in + hpux*) INSTL_SHLIB_OPTS="-m 555" ;; + *) INSTL_SHLIB_OPTS="-m 644" ;; +esac INSTALL_SHLIB="\${INSTALL} $INSTL_SHLIB_OPTS" +mkinstalldirs="\$(SHELL) \$(top_srcdir)/config/mkinstalldirs" + + + for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2382: checking for $ac_word" >&5 +echo "configure:2222: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2411,7 +2251,7 @@ done # Extract the first word of "flex", so it can be a program name with args. set dummy flex; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2415: checking for $ac_word" >&5 +echo "configure:2255: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2445,7 +2285,7 @@ then *) ac_lib=l ;; esac echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6 -echo "configure:2449: checking for yywrap in -l$ac_lib" >&5 +echo "configure:2289: checking for yywrap in -l$ac_lib" >&5 ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2453,7 +2293,7 @@ else ac_save_LIBS="$LIBS" LIBS="-l$ac_lib $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2308: \"$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 @@ -2501,7 +2341,7 @@ broken as well.) fi fi echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 -echo "configure:2505: checking whether ln -s works" >&5 +echo "configure:2345: checking whether ln -s works" >&5 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2524,7 +2364,7 @@ fi # 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:2528: checking for $ac_word" >&5 +echo "configure:2368: 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 @@ -2551,45 +2391,10 @@ else echo "$ac_t""no" 1>&6 fi -# Extract the first word of "find", so it can be a program name with args. -set dummy find; ac_word=$2 -echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2558: checking for $ac_word" >&5 -if eval "test \"`echo '$''{'ac_cv_path_find'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - case "$find" in - /*) - ac_cv_path_find="$find" # Let the user override the test with a path. - ;; - ?:/*) - ac_cv_path_find="$find" # Let the user override the test with a dos path. - ;; - *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - ac_cv_path_find="$ac_dir/$ac_word" - break - fi - done - IFS="$ac_save_ifs" - ;; -esac -fi -find="$ac_cv_path_find" -if test -n "$find"; then - echo "$ac_t""$find" 1>&6 -else - echo "$ac_t""no" 1>&6 -fi - # Extract the first word of "tar", so it can be a program name with args. set dummy tar; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2593: checking for $ac_word" >&5 +echo "configure:2398: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_path_tar'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2621,53 +2426,12 @@ else echo "$ac_t""no" 1>&6 fi -for ac_prog in gzcat zcat -do -# Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2630: checking for $ac_word" >&5 -if eval "test \"`echo '$''{'ac_cv_path_GZCAT'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - case "$GZCAT" in - /*) - ac_cv_path_GZCAT="$GZCAT" # Let the user override the test with a path. - ;; - ?:/*) - ac_cv_path_GZCAT="$GZCAT" # Let the user override the test with a dos path. - ;; - *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - ac_cv_path_GZCAT="$ac_dir/$ac_word" - break - fi - done - IFS="$ac_save_ifs" - ;; -esac -fi -GZCAT="$ac_cv_path_GZCAT" -if test -n "$GZCAT"; then - echo "$ac_t""$GZCAT" 1>&6 -else - echo "$ac_t""no" 1>&6 -fi - -test -n "$GZCAT" && break -done -test -n "$GZCAT" || GZCAT="gzcat" - for ac_prog in perl do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2671: checking for $ac_word" >&5 +echo "configure:2435: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_PERL'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2701,7 +2465,7 @@ do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2705: checking for $ac_word" >&5 +echo "configure:2469: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2734,51 +2498,8 @@ test -n "$YACC" || YACC="yacc" -echo $ac_n "checking for main in -lz""... $ac_c" 1>&6 -echo "configure:2739: checking for main in -lz" >&5 -ac_lib_var=`echo z'_'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 -else - ac_save_LIBS="$LIBS" -LIBS="-lz $LIBS" -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" -else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" -fi -rm -f conftest* -LIBS="$ac_save_LIBS" - -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_lib=HAVE_LIB`echo z | sed -e 's/[^a-zA-Z0-9_]/_/g' \ - -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` - cat >> confdefs.h <&6 -fi - echo $ac_n "checking for main in -lsfio""... $ac_c" 1>&6 -echo "configure:2782: checking for main in -lsfio" >&5 +echo "configure:2503: checking for main in -lsfio" >&5 ac_lib_var=`echo sfio'_'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 @@ -2786,14 +2507,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lsfio $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2518: \"$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 @@ -2821,7 +2542,7 @@ else fi echo $ac_n "checking for main in -lncurses""... $ac_c" 1>&6 -echo "configure:2825: checking for main in -lncurses" >&5 +echo "configure:2546: checking for main in -lncurses" >&5 ac_lib_var=`echo ncurses'_'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 @@ -2829,14 +2550,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lncurses $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2561: \"$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 @@ -2862,7 +2583,7 @@ EOF else echo "$ac_t""no" 1>&6 echo $ac_n "checking for main in -lcurses""... $ac_c" 1>&6 -echo "configure:2866: checking for main in -lcurses" >&5 +echo "configure:2587: checking for main in -lcurses" >&5 ac_lib_var=`echo curses'_'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 @@ -2870,14 +2591,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lcurses $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2602: \"$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 @@ -2907,7 +2628,7 @@ fi fi echo $ac_n "checking for main in -ltermcap""... $ac_c" 1>&6 -echo "configure:2911: checking for main in -ltermcap" >&5 +echo "configure:2632: checking for main in -ltermcap" >&5 ac_lib_var=`echo termcap'_'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 @@ -2915,14 +2636,14 @@ else ac_save_LIBS="$LIBS" LIBS="-ltermcap $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2647: \"$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 @@ -2950,7 +2671,7 @@ else fi echo $ac_n "checking for main in -lreadline""... $ac_c" 1>&6 -echo "configure:2954: checking for main in -lreadline" >&5 +echo "configure:2675: checking for main in -lreadline" >&5 ac_lib_var=`echo readline'_'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 @@ -2958,14 +2679,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lreadline $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2690: \"$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 @@ -2993,7 +2714,7 @@ else fi echo $ac_n "checking for using_history in -lreadline""... $ac_c" 1>&6 -echo "configure:2997: checking for using_history in -lreadline" >&5 +echo "configure:2718: checking for using_history in -lreadline" >&5 ac_lib_var=`echo readline'_'using_history | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3001,7 +2722,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lreadline $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2737: \"$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 @@ -3034,7 +2755,7 @@ EOF else echo "$ac_t""no" 1>&6 echo $ac_n "checking for main in -lhistory""... $ac_c" 1>&6 -echo "configure:3038: checking for main in -lhistory" >&5 +echo "configure:2759: checking for main in -lhistory" >&5 ac_lib_var=`echo history'_'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 @@ -3042,14 +2763,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lhistory $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2774: \"$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 @@ -3082,7 +2803,7 @@ fi if test "$PORTNAME" != "aix" -a "$PORTNAME" != "alpha" then echo $ac_n "checking for main in -lbsd""... $ac_c" 1>&6 -echo "configure:3086: checking for main in -lbsd" >&5 +echo "configure:2807: checking for main in -lbsd" >&5 ac_lib_var=`echo bsd'_'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 @@ -3090,14 +2811,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lbsd $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2822: \"$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 @@ -3126,7 +2847,7 @@ fi fi echo $ac_n "checking for setproctitle in -lutil""... $ac_c" 1>&6 -echo "configure:3130: checking for setproctitle in -lutil" >&5 +echo "configure:2851: checking for setproctitle in -lutil" >&5 ac_lib_var=`echo util'_'setproctitle | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3134,7 +2855,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lutil $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2870: \"$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 @@ -3173,7 +2894,7 @@ else fi echo $ac_n "checking for main in -lm""... $ac_c" 1>&6 -echo "configure:3177: checking for main in -lm" >&5 +echo "configure:2898: checking for main in -lm" >&5 ac_lib_var=`echo m'_'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 @@ -3181,14 +2902,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lm $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2913: \"$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 @@ -3216,7 +2937,7 @@ else fi echo $ac_n "checking for main in -ldl""... $ac_c" 1>&6 -echo "configure:3220: checking for main in -ldl" >&5 +echo "configure:2941: checking for main in -ldl" >&5 ac_lib_var=`echo dl'_'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 @@ -3224,14 +2945,14 @@ else ac_save_LIBS="$LIBS" LIBS="-ldl $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2956: \"$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 @@ -3259,7 +2980,7 @@ else fi echo $ac_n "checking for main in -lsocket""... $ac_c" 1>&6 -echo "configure:3263: checking for main in -lsocket" >&5 +echo "configure:2984: checking for main in -lsocket" >&5 ac_lib_var=`echo socket'_'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 @@ -3267,14 +2988,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lsocket $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2999: \"$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 @@ -3302,7 +3023,7 @@ else fi echo $ac_n "checking for main in -lnsl""... $ac_c" 1>&6 -echo "configure:3306: checking for main in -lnsl" >&5 +echo "configure:3027: checking for main in -lnsl" >&5 ac_lib_var=`echo nsl'_'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 @@ -3310,14 +3031,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lnsl $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3042: \"$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 @@ -3345,7 +3066,7 @@ else fi echo $ac_n "checking for main in -lipc""... $ac_c" 1>&6 -echo "configure:3349: checking for main in -lipc" >&5 +echo "configure:3070: checking for main in -lipc" >&5 ac_lib_var=`echo ipc'_'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 @@ -3353,14 +3074,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lipc $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3085: \"$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 @@ -3388,7 +3109,7 @@ else fi echo $ac_n "checking for main in -lIPC""... $ac_c" 1>&6 -echo "configure:3392: checking for main in -lIPC" >&5 +echo "configure:3113: checking for main in -lIPC" >&5 ac_lib_var=`echo IPC'_'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 @@ -3396,14 +3117,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lIPC $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3128: \"$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 @@ -3431,7 +3152,7 @@ else fi echo $ac_n "checking for main in -llc""... $ac_c" 1>&6 -echo "configure:3435: checking for main in -llc" >&5 +echo "configure:3156: checking for main in -llc" >&5 ac_lib_var=`echo lc'_'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 @@ -3439,14 +3160,14 @@ else ac_save_LIBS="$LIBS" LIBS="-llc $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3171: \"$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 @@ -3474,7 +3195,7 @@ else fi echo $ac_n "checking for main in -ldld""... $ac_c" 1>&6 -echo "configure:3478: checking for main in -ldld" >&5 +echo "configure:3199: checking for main in -ldld" >&5 ac_lib_var=`echo dld'_'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 @@ -3482,14 +3203,14 @@ else ac_save_LIBS="$LIBS" LIBS="-ldld $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3214: \"$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 @@ -3517,7 +3238,7 @@ else fi echo $ac_n "checking for main in -lln""... $ac_c" 1>&6 -echo "configure:3521: checking for main in -lln" >&5 +echo "configure:3242: checking for main in -lln" >&5 ac_lib_var=`echo ln'_'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 @@ -3525,14 +3246,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lln $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3257: \"$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 @@ -3560,7 +3281,7 @@ else fi echo $ac_n "checking for main in -lld""... $ac_c" 1>&6 -echo "configure:3564: checking for main in -lld" >&5 +echo "configure:3285: checking for main in -lld" >&5 ac_lib_var=`echo ld'_'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 @@ -3568,14 +3289,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lld $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3300: \"$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 @@ -3603,7 +3324,7 @@ else fi echo $ac_n "checking for main in -lcompat""... $ac_c" 1>&6 -echo "configure:3607: checking for main in -lcompat" >&5 +echo "configure:3328: checking for main in -lcompat" >&5 ac_lib_var=`echo compat'_'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 @@ -3611,14 +3332,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lcompat $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3343: \"$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 @@ -3646,7 +3367,7 @@ else fi echo $ac_n "checking for main in -lBSD""... $ac_c" 1>&6 -echo "configure:3650: checking for main in -lBSD" >&5 +echo "configure:3371: checking for main in -lBSD" >&5 ac_lib_var=`echo BSD'_'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 @@ -3654,14 +3375,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lBSD $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3386: \"$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 @@ -3689,7 +3410,7 @@ else fi echo $ac_n "checking for main in -lgen""... $ac_c" 1>&6 -echo "configure:3693: checking for main in -lgen" >&5 +echo "configure:3414: checking for main in -lgen" >&5 ac_lib_var=`echo gen'_'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 @@ -3697,14 +3418,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lgen $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3429: \"$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 @@ -3732,7 +3453,7 @@ else fi echo $ac_n "checking for main in -lPW""... $ac_c" 1>&6 -echo "configure:3736: checking for main in -lPW" >&5 +echo "configure:3457: checking for main in -lPW" >&5 ac_lib_var=`echo PW'_'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 @@ -3740,14 +3461,14 @@ else ac_save_LIBS="$LIBS" LIBS="-lPW $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3472: \"$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 @@ -3776,14 +3497,14 @@ fi echo $ac_n "checking for library containing crypt""... $ac_c" 1>&6 -echo "configure:3780: checking for library containing crypt" >&5 +echo "configure:3501: checking for library containing crypt" >&5 if eval "test \"`echo '$''{'ac_cv_search_crypt'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else ac_func_search_save_LIBS="$LIBS" ac_cv_search_crypt="no" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3519: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_search_crypt="none required" else @@ -3805,7 +3526,7 @@ rm -f conftest* test "$ac_cv_search_crypt" = "no" && for i in crypt; do LIBS="-l$i $ac_func_search_save_LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3541: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_search_crypt="-l$i" break @@ -3836,14 +3557,395 @@ if test "$ac_cv_search_crypt" != "no"; then else : fi +echo $ac_n "checking for inflate in -lz""... $ac_c" 1>&6 +echo "configure:3562: checking for inflate in -lz" >&5 +ac_lib_var=`echo z'_'inflate | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lz $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_lib=HAVE_LIB`echo z | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + cat >> confdefs.h <&6 +fi + + +if test "$with_krb4" = yes ; then + echo $ac_n "checking for des_encrypt in -ldes""... $ac_c" 1>&6 +echo "configure:3611: checking for des_encrypt in -ldes" >&5 +ac_lib_var=`echo des'_'des_encrypt | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-ldes $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_lib=HAVE_LIB`echo des | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + cat >> confdefs.h <&6 +{ echo "configure: error: library \`des' is required for Kerberos 4" 1>&2; exit 1; } +fi + + echo $ac_n "checking for krb_sendauth in -lkrb""... $ac_c" 1>&6 +echo "configure:3659: checking for krb_sendauth in -lkrb" >&5 +ac_lib_var=`echo krb'_'krb_sendauth | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lkrb $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_lib=HAVE_LIB`echo krb | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + cat >> confdefs.h <&6 +{ echo "configure: error: library \`krb' is required for Kerberos 4" 1>&2; exit 1; } +fi + +fi + +if test "$with_krb5" = yes ; then + echo $ac_n "checking for main in -lcom_err""... $ac_c" 1>&6 +echo "configure:3710: checking for main in -lcom_err" >&5 +ac_lib_var=`echo com_err'_'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 +else + ac_save_LIBS="$LIBS" +LIBS="-lcom_err $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_lib=HAVE_LIB`echo com_err | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + cat >> confdefs.h <&6 +{ echo "configure: error: library \`com_err' is required for Kerberos 5" 1>&2; exit 1; } +fi + + echo $ac_n "checking for main in -lcrypto""... $ac_c" 1>&6 +echo "configure:3754: checking for main in -lcrypto" >&5 +ac_lib_var=`echo crypto'_'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 +else + ac_save_LIBS="$LIBS" +LIBS="-lcrypto $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_lib=HAVE_LIB`echo crypto | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + cat >> confdefs.h <&6 +{ echo "configure: error: library \`crypto' is required for Kerberos 5" 1>&2; exit 1; } +fi + + echo $ac_n "checking for main in -lkrb5""... $ac_c" 1>&6 +echo "configure:3798: checking for main in -lkrb5" >&5 +ac_lib_var=`echo krb5'_'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 +else + ac_save_LIBS="$LIBS" +LIBS="-lkrb5 $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_lib=HAVE_LIB`echo krb5 | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + cat >> confdefs.h <&6 +{ echo "configure: error: library \`krb5' is required for Kerberos 5" 1>&2; exit 1; } +fi + +fi + +if test "$with_openssl" = yes ; then + echo $ac_n "checking for CRYPTO_new_ex_data in -lcrypto""... $ac_c" 1>&6 +echo "configure:3845: checking for CRYPTO_new_ex_data in -lcrypto" >&5 +ac_lib_var=`echo crypto'_'CRYPTO_new_ex_data | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lcrypto $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_lib=HAVE_LIB`echo crypto | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + cat >> confdefs.h <&6 +{ echo "configure: error: library \`ssl' is required for OpenSSL" 1>&2; exit 1; } +fi + + echo $ac_n "checking for SSL_library_init in -lssl""... $ac_c" 1>&6 +echo "configure:3893: checking for SSL_library_init in -lssl" >&5 +ac_lib_var=`echo ssl'_'SSL_library_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 +else + ac_save_LIBS="$LIBS" +LIBS="-lssl $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_lib=HAVE_LIB`echo ssl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + cat >> confdefs.h <&6 +{ echo "configure: error: library \`ssl' is required for OpenSSL" 1>&2; exit 1; } +fi + +fi + echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 -echo "configure:3842: checking for ANSI C header files" >&5 +echo "configure:3944: 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 < #include @@ -3851,7 +3953,7 @@ else #include EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3855: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:3957: \"$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* @@ -3868,7 +3970,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 @@ -3886,7 +3988,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 @@ -3907,7 +4009,7 @@ if test "$cross_compiling" = yes; then : else cat > conftest.$ac_ext < #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') @@ -3918,7 +4020,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); exit (0); } EOF -if { (eval echo configure:3922: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:4024: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then : else @@ -3942,12 +4044,12 @@ EOF fi echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6 -echo "configure:3946: checking for sys/wait.h that is POSIX.1 compatible" >&5 +echo "configure:4048: checking for sys/wait.h that is POSIX.1 compatible" >&5 if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #include @@ -3963,7 +4065,7 @@ wait (&s); s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; ; return 0; } EOF -if { (eval echo configure:3967: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4069: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_header_sys_wait_h=yes else @@ -3987,17 +4089,17 @@ for ac_hdr in arpa/inet.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3991: checking for $ac_hdr" >&5 +echo "configure:4093: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4001: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4103: \"$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* @@ -4027,17 +4129,17 @@ for ac_hdr in crypt.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4031: checking for $ac_hdr" >&5 +echo "configure:4133: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4041: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4143: \"$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* @@ -4067,17 +4169,17 @@ for ac_hdr in dld.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4071: checking for $ac_hdr" >&5 +echo "configure:4173: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4081: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4183: \"$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* @@ -4107,17 +4209,17 @@ for ac_hdr in endian.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4111: checking for $ac_hdr" >&5 +echo "configure:4213: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4121: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4223: \"$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* @@ -4147,17 +4249,17 @@ for ac_hdr in float.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4151: checking for $ac_hdr" >&5 +echo "configure:4253: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4161: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4263: \"$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* @@ -4187,17 +4289,17 @@ for ac_hdr in fp_class.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4191: checking for $ac_hdr" >&5 +echo "configure:4293: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4201: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4303: \"$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* @@ -4227,57 +4329,17 @@ for ac_hdr in getopt.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4231: checking for $ac_hdr" >&5 +echo "configure:4333: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4241: \"$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* - eval "ac_cv_header_$ac_safe=yes" -else - echo "$ac_err" >&5 - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" -fi -rm -f conftest* -fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 -fi -done - -for ac_hdr in history.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4271: 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 -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4281: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4343: \"$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* @@ -4307,17 +4369,17 @@ for ac_hdr in ieeefp.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4311: checking for $ac_hdr" >&5 +echo "configure:4373: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4321: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4383: \"$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* @@ -4347,17 +4409,17 @@ for ac_hdr in limits.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4351: checking for $ac_hdr" >&5 +echo "configure:4413: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4361: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4423: \"$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* @@ -4387,17 +4449,17 @@ for ac_hdr in netdb.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4391: checking for $ac_hdr" >&5 +echo "configure:4453: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4401: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4463: \"$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* @@ -4427,17 +4489,17 @@ for ac_hdr in netinet/in.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4431: checking for $ac_hdr" >&5 +echo "configure:4493: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4441: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4503: \"$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* @@ -4463,21 +4525,21 @@ else fi done -for ac_hdr in readline.h +for ac_hdr in readline/readline.h readline.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4471: checking for $ac_hdr" >&5 +echo "configure:4533: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4481: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4543: \"$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* @@ -4497,27 +4559,27 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then cat >> confdefs.h <&6 fi done -for ac_hdr in readline/history.h +for ac_hdr in readline/history.h history.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4511: checking for $ac_hdr" >&5 +echo "configure:4573: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4521: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4583: \"$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* @@ -4537,47 +4599,7 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then cat >> confdefs.h <&6 -fi -done - -for ac_hdr in readline/readline.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4551: 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 -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4561: \"$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* - eval "ac_cv_header_$ac_safe=yes" -else - echo "$ac_err" >&5 - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" -fi -rm -f conftest* -fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 fi @@ -4587,17 +4609,17 @@ for ac_hdr in sys/select.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4591: checking for $ac_hdr" >&5 +echo "configure:4613: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4601: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4623: \"$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* @@ -4627,17 +4649,17 @@ for ac_hdr in termios.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4631: checking for $ac_hdr" >&5 +echo "configure:4653: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4641: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4663: \"$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* @@ -4667,17 +4689,17 @@ for ac_hdr in unistd.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4671: checking for $ac_hdr" >&5 +echo "configure:4693: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4681: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4703: \"$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* @@ -4707,17 +4729,17 @@ for ac_hdr in values.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4711: checking for $ac_hdr" >&5 +echo "configure:4733: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4721: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4743: \"$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* @@ -4743,21 +4765,21 @@ else fi done -for ac_hdr in sys/exec.h sys/pstat.h machine/vmparam.h +for ac_hdr in sys/pstat.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4751: checking for $ac_hdr" >&5 +echo "configure:4773: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4761: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4783: \"$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* @@ -4787,17 +4809,17 @@ for ac_hdr in sys/types.h sys/socket.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4791: checking for $ac_hdr" >&5 +echo "configure:4813: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4801: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4823: \"$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* @@ -4827,17 +4849,17 @@ for ac_hdr in sys/param.h pwd.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4831: checking for $ac_hdr" >&5 +echo "configure:4853: 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 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4841: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4863: \"$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* @@ -4864,14 +4886,193 @@ fi done +if test "$with_krb4" = yes ; then + ac_safe=`echo "krb.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for krb.h""... $ac_c" 1>&6 +echo "configure:4893: checking for krb.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:4903: \"$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* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +{ echo "configure: error: header file is required for Kerberos 4" 1>&2; exit 1; } +fi + +fi + +if test "$with_krb5" = yes ; then + ac_safe=`echo "krb5.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for krb5.h""... $ac_c" 1>&6 +echo "configure:4930: checking for krb5.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:4940: \"$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* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +{ echo "configure: error: header file is required for Kerberos 5" 1>&2; exit 1; } +fi + + ac_safe=`echo "com_err.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for com_err.h""... $ac_c" 1>&6 +echo "configure:4964: checking for com_err.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:4974: \"$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* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +{ echo "configure: error: header file is required for Kerberos 5" 1>&2; exit 1; } +fi + +fi + +if test "$with_openssl" = yes ; then + ac_safe=`echo "openssl/ssl.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for openssl/ssl.h""... $ac_c" 1>&6 +echo "configure:5001: checking for openssl/ssl.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:5011: \"$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* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +{ echo "configure: error: header file is required for OpenSSL" 1>&2; exit 1; } +fi + + ac_safe=`echo "openssl/err.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for openssl/err.h""... $ac_c" 1>&6 +echo "configure:5035: checking for openssl/err.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:5045: \"$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* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +{ echo "configure: error: header file is required for OpenSSL" 1>&2; exit 1; } +fi + +fi + echo $ac_n "checking for working const""... $ac_c" 1>&6 -echo "configure:4870: checking for working const" >&5 +echo "configure:5071: checking for working const" >&5 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5125: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_const=yes else @@ -4941,21 +5142,21 @@ EOF fi echo $ac_n "checking for inline""... $ac_c" 1>&6 -echo "configure:4945: checking for inline" >&5 +echo "configure:5146: checking for inline" >&5 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else ac_cv_c_inline=no for ac_kw in inline __inline__ __inline; do cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5160: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_inline=$ac_kw; break else @@ -4983,12 +5184,12 @@ esac echo $ac_n "checking for preprocessor stringizing operator""... $ac_c" 1>&6 -echo "configure:4987: checking for preprocessor stringizing operator" >&5 +echo "configure:5188: checking for preprocessor stringizing operator" >&5 if eval "test \"`echo '$''{'ac_cv_c_stringize'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&6 echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 -echo "configure:5022: checking for uid_t in sys/types.h" >&5 +echo "configure:5223: 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 @@ -5052,12 +5253,12 @@ EOF fi echo $ac_n "checking for mode_t""... $ac_c" 1>&6 -echo "configure:5056: checking for mode_t" >&5 +echo "configure:5257: 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 < #if STDC_HEADERS @@ -5085,12 +5286,12 @@ EOF fi echo $ac_n "checking for off_t""... $ac_c" 1>&6 -echo "configure:5089: checking for off_t" >&5 +echo "configure:5290: checking for off_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #if STDC_HEADERS @@ -5118,12 +5319,12 @@ EOF fi echo $ac_n "checking for size_t""... $ac_c" 1>&6 -echo "configure:5122: checking for size_t" >&5 +echo "configure:5323: 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 < #if STDC_HEADERS @@ -5151,12 +5352,12 @@ EOF fi echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 -echo "configure:5155: checking whether struct tm is in sys/time.h or time.h" >&5 +echo "configure:5356: 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 < #include @@ -5164,7 +5365,7 @@ int main() { struct tm *tp; tp->tm_sec; ; return 0; } EOF -if { (eval echo configure:5168: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5369: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_tm=time.h else @@ -5185,12 +5386,12 @@ EOF fi echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 -echo "configure:5189: checking for tm_zone in struct tm" >&5 +echo "configure:5390: 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 < #include <$ac_cv_struct_tm> @@ -5198,7 +5399,7 @@ int main() { struct tm tm; tm.tm_zone; ; return 0; } EOF -if { (eval echo configure:5202: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5403: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_tm_zone=yes else @@ -5218,12 +5419,12 @@ EOF else echo $ac_n "checking for tzname""... $ac_c" 1>&6 -echo "configure:5222: checking for tzname" >&5 +echo "configure:5423: 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 < #ifndef tzname /* For SGI. */ @@ -5233,7 +5434,7 @@ int main() { atoi(*tzname); ; return 0; } EOF -if { (eval echo configure:5237: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5438: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_var_tzname=yes else @@ -5255,19 +5456,19 @@ EOF fi echo $ac_n "checking for signed types""... $ac_c" 1>&6 -echo "configure:5259: checking for signed types" >&5 +echo "configure:5460: checking for signed types" >&5 if eval "test \"`echo '$''{'pgac_cv_c_signed'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5472: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* pgac_cv_c_signed=yes else @@ -5287,19 +5488,19 @@ EOF fi echo $ac_n "checking for volatile""... $ac_c" 1>&6 -echo "configure:5291: checking for volatile" >&5 +echo "configure:5492: checking for volatile" >&5 if eval "test \"`echo '$''{'pgac_cv_c_volatile'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5504: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* pgac_cv_c_volatile=yes else @@ -5319,7 +5520,7 @@ EOF fi echo $ac_n "checking types of arguments for accept()""... $ac_c" 1>&6 -echo "configure:5323: checking types of arguments for accept()" >&5 +echo "configure:5524: checking types of arguments for accept()" >&5 if eval "test \"`echo '$''{'ac_cv_func_accept_arg1'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -5333,7 +5534,7 @@ else for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'void *'; do for ac_cv_func_accept_arg3 in 'socklen_t' 'size_t' 'unsigned int' 'int'; do cat > conftest.$ac_ext < @@ -5346,7 +5547,7 @@ int main() { ; return 0; } EOF -if { (eval echo configure:5350: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5551: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_not_found=no ; break 3 else @@ -5387,19 +5588,19 @@ EOF echo $ac_n "checking for int timezone""... $ac_c" 1>&6 -echo "configure:5391: checking for int timezone" >&5 +echo "configure:5592: checking for int timezone" >&5 if eval "test \"`echo '$''{'pgac_cv_var_int_timezone'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < int main() { int res = timezone / 60; ; return 0; } EOF -if { (eval echo configure:5403: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5604: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* pgac_cv_var_int_timezone=yes else @@ -5419,12 +5620,12 @@ EOF fi echo $ac_n "checking whether gettimeofday takes only one argument""... $ac_c" 1>&6 -echo "configure:5423: checking whether gettimeofday takes only one argument" >&5 +echo "configure:5624: checking whether gettimeofday takes only one argument" >&5 if eval "test \"`echo '$''{'pgac_cv_func_gettimeofday_1arg'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < int main() { @@ -5433,7 +5634,7 @@ struct timezone *tzp; gettimeofday(tp,tzp); ; return 0; } EOF -if { (eval echo configure:5437: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5638: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* pgac_cv_func_gettimeofday_1arg=no else @@ -5453,12 +5654,12 @@ EOF fi echo $ac_n "checking for union semun""... $ac_c" 1>&6 -echo "configure:5457: checking for union semun" >&5 +echo "configure:5658: checking for union semun" >&5 if eval "test \"`echo '$''{'pgac_cv_union_semun'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #include @@ -5467,7 +5668,7 @@ int main() { union semun semun; ; return 0; } EOF -if { (eval echo configure:5471: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5672: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* pgac_cv_union_semun=yes else @@ -5489,9 +5690,10 @@ fi echo $ac_n "checking for fcntl(F_SETLK)""... $ac_c" 1>&6 -echo "configure:5493: checking for fcntl(F_SETLK)" >&5 +echo "configure:5694: checking for fcntl(F_SETLK)" >&5 +if test "$os" != linux ; then cat > conftest.$ac_ext < #include @@ -5502,7 +5704,7 @@ struct flock lck; fcntl(0, F_SETLK, &lck); ; return 0; } EOF -if { (eval echo configure:5506: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5708: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* cat >> confdefs.h <<\EOF #define HAVE_FCNTL_SETLK 1 @@ -5515,9 +5717,12 @@ else echo "$ac_t""no" 1>&6 fi rm -f conftest* +else + echo "$ac_t""broken on Linux" 1>&6 +fi echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6 -echo "configure:5521: checking for 8-bit clean memcmp" >&5 +echo "configure:5726: 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 @@ -5525,7 +5730,7 @@ else ac_cv_func_memcmp_clean=no else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:5744: \"$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 @@ -5553,12 +5758,12 @@ echo "$ac_t""$ac_cv_func_memcmp_clean" 1>&6 test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.${ac_objext}" echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 -echo "configure:5557: checking return type of signal handlers" >&5 +echo "configure:5762: checking return type of signal handlers" >&5 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #include @@ -5575,7 +5780,7 @@ int main() { int i; ; return 0; } EOF -if { (eval echo configure:5579: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5784: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_type_signal=void else @@ -5594,12 +5799,12 @@ EOF echo $ac_n "checking for vprintf""... $ac_c" 1>&6 -echo "configure:5598: checking for vprintf" >&5 +echo "configure:5803: checking for vprintf" >&5 if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5831: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_vprintf=yes" else @@ -5646,12 +5851,12 @@ fi if test "$ac_cv_func_vprintf" != yes; then echo $ac_n "checking for _doprnt""... $ac_c" 1>&6 -echo "configure:5650: checking for _doprnt" >&5 +echo "configure:5855: checking for _doprnt" >&5 if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5883: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func__doprnt=yes" else @@ -5701,12 +5906,12 @@ fi for ac_func in memmove sysconf do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:5705: checking for $ac_func" >&5 +echo "configure:5910: 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 <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5938: \"$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 @@ -5756,12 +5961,12 @@ done for ac_func in sigprocmask waitpid setsid fcvt do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:5760: checking for $ac_func" >&5 +echo "configure:5965: 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 <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5993: \"$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 @@ -5811,12 +6016,12 @@ done for ac_func in setproctitle pstat do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:5815: checking for $ac_func" >&5 +echo "configure:6020: 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 <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6048: \"$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 @@ -5865,44 +6070,50 @@ done echo $ac_n "checking for PS_STRINGS""... $ac_c" 1>&6 -echo "configure:5869: checking for PS_STRINGS" >&5 -cat > conftest.$ac_ext <&5 +if eval "test \"`echo '$''{'pgac_cv_var_PS_STRINGS'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < -#endif -#ifdef HAVE_SYS_EXEC_H -# include -#endif +#include +#include + int main() { PS_STRINGS->ps_nargvstr = 1; PS_STRINGS->ps_argvstr = "foo"; ; return 0; } EOF -if { (eval echo configure:5884: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6089: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - echo "$ac_t""yes" 1>&6 cat >> confdefs.h <<\EOF -#define HAVE_PS_STRINGS 1 -EOF - + pgac_cv_var_PS_STRINGS=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - echo "$ac_t""no" 1>&6 + pgac_cv_var_PS_STRINGS=no fi rm -f conftest* +fi + +echo "$ac_t""$pgac_cv_var_PS_STRINGS" 1>&6 +if test "$pgac_cv_var_PS_STRINGS" = yes ; then + cat >> confdefs.h <<\EOF +#define HAVE_PS_STRINGS +EOF + +fi for ac_func in fpclass fp_class fp_class_d class do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:5901: checking for $ac_func" >&5 +echo "configure:6112: 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 <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6140: \"$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 @@ -5951,12 +6162,12 @@ done SNPRINTF='' echo $ac_n "checking for snprintf""... $ac_c" 1>&6 -echo "configure:5955: checking for snprintf" >&5 +echo "configure:6166: checking for snprintf" >&5 if eval "test \"`echo '$''{'ac_cv_func_snprintf'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6194: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_snprintf=yes" else @@ -6003,12 +6214,12 @@ SNPRINTF='snprintf.o' fi echo $ac_n "checking for vsnprintf""... $ac_c" 1>&6 -echo "configure:6007: checking for vsnprintf" >&5 +echo "configure:6218: checking for vsnprintf" >&5 if eval "test \"`echo '$''{'ac_cv_func_vsnprintf'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6246: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_vsnprintf=yes" else @@ -6056,7 +6267,7 @@ fi cat > conftest.$ac_ext < EOF @@ -6071,7 +6282,7 @@ fi rm -f conftest* cat > conftest.$ac_ext < EOF @@ -6086,19 +6297,19 @@ fi rm -f conftest* echo $ac_n "checking for isinf""... $ac_c" 1>&6 -echo "configure:6090: checking for isinf" >&5 +echo "configure:6301: checking for isinf" >&5 if eval "test \"`echo '$''{'ac_cv_func_or_macro_isinf'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < int main() { double x = 0.0; int res = isinf(x); ; return 0; } EOF -if { (eval echo configure:6102: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6313: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_func_or_macro_isinf=yes else @@ -6123,12 +6334,12 @@ else fi echo $ac_n "checking for getrusage""... $ac_c" 1>&6 -echo "configure:6127: checking for getrusage" >&5 +echo "configure:6338: checking for getrusage" >&5 if eval "test \"`echo '$''{'ac_cv_func_getrusage'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_getrusage=yes" else @@ -6176,12 +6387,12 @@ fi echo $ac_n "checking for srandom""... $ac_c" 1>&6 -echo "configure:6180: checking for srandom" >&5 +echo "configure:6391: checking for srandom" >&5 if eval "test \"`echo '$''{'ac_cv_func_srandom'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6419: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_srandom=yes" else @@ -6229,12 +6440,12 @@ fi echo $ac_n "checking for gethostname""... $ac_c" 1>&6 -echo "configure:6233: checking for gethostname" >&5 +echo "configure:6444: checking for gethostname" >&5 if eval "test \"`echo '$''{'ac_cv_func_gethostname'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6472: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_gethostname=yes" else @@ -6282,12 +6493,12 @@ fi echo $ac_n "checking for random""... $ac_c" 1>&6 -echo "configure:6286: checking for random" >&5 +echo "configure:6497: checking for random" >&5 if eval "test \"`echo '$''{'ac_cv_func_random'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6525: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_random=yes" else @@ -6335,12 +6546,12 @@ fi echo $ac_n "checking for inet_aton""... $ac_c" 1>&6 -echo "configure:6339: checking for inet_aton" >&5 +echo "configure:6550: checking for inet_aton" >&5 if eval "test \"`echo '$''{'ac_cv_func_inet_aton'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6578: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_inet_aton=yes" else @@ -6388,12 +6599,12 @@ fi echo $ac_n "checking for strerror""... $ac_c" 1>&6 -echo "configure:6392: checking for strerror" >&5 +echo "configure:6603: 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 <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6631: \"$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 @@ -6442,12 +6653,12 @@ fi echo $ac_n "checking for strdup""... $ac_c" 1>&6 -echo "configure:6446: checking for strdup" >&5 +echo "configure:6657: checking for strdup" >&5 if eval "test \"`echo '$''{'ac_cv_func_strdup'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6685: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_strdup=yes" else @@ -6495,12 +6706,12 @@ fi echo $ac_n "checking for strtol""... $ac_c" 1>&6 -echo "configure:6499: checking for strtol" >&5 +echo "configure:6710: checking for strtol" >&5 if eval "test \"`echo '$''{'ac_cv_func_strtol'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6738: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_strtol=yes" else @@ -6548,12 +6759,12 @@ fi echo $ac_n "checking for strtoul""... $ac_c" 1>&6 -echo "configure:6552: checking for strtoul" >&5 +echo "configure:6763: 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 <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6791: \"$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 @@ -6601,12 +6812,12 @@ fi echo $ac_n "checking for strcasecmp""... $ac_c" 1>&6 -echo "configure:6605: checking for strcasecmp" >&5 +echo "configure:6816: checking for strcasecmp" >&5 if eval "test \"`echo '$''{'ac_cv_func_strcasecmp'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6844: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_strcasecmp=yes" else @@ -6654,12 +6865,12 @@ fi echo $ac_n "checking for cbrt""... $ac_c" 1>&6 -echo "configure:6658: checking for cbrt" >&5 +echo "configure:6869: checking for cbrt" >&5 if eval "test \"`echo '$''{'ac_cv_func_cbrt'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6897: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_cbrt=yes" else @@ -6703,7 +6914,7 @@ EOF else echo "$ac_t""no" 1>&6 echo $ac_n "checking for cbrt in -lm""... $ac_c" 1>&6 -echo "configure:6707: checking for cbrt in -lm" >&5 +echo "configure:6918: checking for cbrt in -lm" >&5 ac_lib_var=`echo m'_'cbrt | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -6711,7 +6922,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lm $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6937: \"$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 @@ -6760,12 +6971,12 @@ esac echo $ac_n "checking for rint""... $ac_c" 1>&6 -echo "configure:6764: checking for rint" >&5 +echo "configure:6975: checking for rint" >&5 if eval "test \"`echo '$''{'ac_cv_func_rint'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7003: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_rint=yes" else @@ -6809,7 +7020,7 @@ EOF else echo "$ac_t""no" 1>&6 echo $ac_n "checking for rint in -lm""... $ac_c" 1>&6 -echo "configure:6813: checking for rint in -lm" >&5 +echo "configure:7024: checking for rint in -lm" >&5 ac_lib_var=`echo m'_'rint | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -6817,7 +7028,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lm $HPUXMATHLIB $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7043: \"$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 @@ -6855,7 +7066,7 @@ fi cat > conftest.$ac_ext < EOF @@ -6869,7 +7080,7 @@ EOF else rm -rf conftest* cat > conftest.$ac_ext < EOF @@ -6891,12 +7102,12 @@ rm -f conftest* for ac_func in filename_completion_function do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:6895: checking for $ac_func" >&5 +echo "configure:7106: 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 <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7134: \"$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 @@ -6938,7 +7149,7 @@ if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then #define $ac_tr_func 1 EOF cat > conftest.$ac_ext < EOF @@ -6952,7 +7163,7 @@ EOF else rm -rf conftest* cat > conftest.$ac_ext < EOF @@ -6981,12 +7192,12 @@ done for ac_func in getopt_long do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:6985: checking for $ac_func" >&5 +echo "configure:7196: 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 <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7224: \"$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 @@ -7035,16 +7246,16 @@ done echo $ac_n "checking for finite""... $ac_c" 1>&6 -echo "configure:7039: checking for finite" >&5 +echo "configure:7250: checking for finite" >&5 cat > conftest.$ac_ext < int main() { int dummy=finite(1.0); ; return 0; } EOF -if { (eval echo configure:7048: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7259: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* cat >> confdefs.h <<\EOF #define HAVE_FINITE 1 @@ -7059,16 +7270,16 @@ fi rm -f conftest* echo $ac_n "checking for sigsetjmp""... $ac_c" 1>&6 -echo "configure:7063: checking for sigsetjmp" >&5 +echo "configure:7274: checking for sigsetjmp" >&5 cat > conftest.$ac_ext < int main() { sigjmp_buf x; sigsetjmp(x, 1); ; 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:7283: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* cat >> confdefs.h <<\EOF #define HAVE_SIGSETJMP 1 @@ -7087,12 +7298,12 @@ if test "${enable_syslog+set}" = set; then enableval="$enable_syslog" case $enableval in y|ye|yes) echo $ac_n "checking for syslog""... $ac_c" 1>&6 -echo "configure:7091: checking for syslog" >&5 +echo "configure:7302: checking for syslog" >&5 if eval "test \"`echo '$''{'ac_cv_func_syslog'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7330: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_syslog=yes" else @@ -7146,7 +7357,7 @@ fi echo $ac_n "checking whether long int is 64 bits""... $ac_c" 1>&6 -echo "configure:7150: checking whether long int is 64 bits" >&5 +echo "configure:7361: checking whether long int is 64 bits" >&5 if eval "test \"`echo '$''{'pgac_cv_type_long_int_64'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7155,7 +7366,7 @@ else echo "configure: warning: 64 bit arithmetic disabled when cross-compiling" 1>&2 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:7399: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then pgac_cv_type_long_int_64=yes else @@ -7211,7 +7422,7 @@ fi if test x"$HAVE_LONG_INT_64" = x"no" ; then echo $ac_n "checking whether long long int is 64 bits""... $ac_c" 1>&6 -echo "configure:7215: checking whether long long int is 64 bits" >&5 +echo "configure:7426: checking whether long long int is 64 bits" >&5 if eval "test \"`echo '$''{'pgac_cv_type_long_long_int_64'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7220,7 +7431,7 @@ else echo "configure: warning: 64 bit arithmetic disabled when cross-compiling" 1>&2 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:7464: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then pgac_cv_type_long_long_int_64=yes else @@ -7280,7 +7491,7 @@ fi if [ x"$HAVE_LONG_LONG_INT_64" = xyes ] ; then if [ x$SNPRINTF = x ] ; then echo $ac_n "checking whether snprintf handles 'long long int' as %lld""... $ac_c" 1>&6 -echo "configure:7284: checking whether snprintf handles 'long long int' as %lld" >&5 +echo "configure:7495: checking whether snprintf handles 'long long int' as %lld" >&5 if test "$cross_compiling" = yes; then echo "$ac_t""assuming not on target machine" 1>&6 # Force usage of our own snprintf, since we cannot test foreign snprintf @@ -7289,7 +7500,7 @@ echo "configure:7284: checking whether snprintf handles 'long long int' as %lld" else cat > conftest.$ac_ext < typedef long long int int64; @@ -7316,7 +7527,7 @@ main() { exit(! does_int64_snprintf_work()); } EOF -if { (eval echo configure:7320: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:7531: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then echo "$ac_t""yes" 1>&6 INT64_FORMAT='"%lld"' @@ -7327,7 +7538,7 @@ else rm -fr conftest* echo "$ac_t""no" 1>&6 echo $ac_n "checking whether snprintf handles 'long long int' as %qd""... $ac_c" 1>&6 -echo "configure:7331: checking whether snprintf handles 'long long int' as %qd" >&5 +echo "configure:7542: checking whether snprintf handles 'long long int' as %qd" >&5 if test "$cross_compiling" = yes; then echo "$ac_t""assuming not on target machine" 1>&6 # Force usage of our own snprintf, since we cannot test foreign snprintf @@ -7336,7 +7547,7 @@ echo "configure:7331: checking whether snprintf handles 'long long int' as %qd" else cat > conftest.$ac_ext < typedef long long int int64; @@ -7363,7 +7574,7 @@ main() { exit(! does_int64_snprintf_work()); } EOF -if { (eval echo configure:7367: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:7578: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then echo "$ac_t""yes" 1>&6 INT64_FORMAT='"%qd"' @@ -7402,7 +7613,7 @@ EOF echo $ac_n "checking alignment of short""... $ac_c" 1>&6 -echo "configure:7406: checking alignment of short" >&5 +echo "configure:7617: checking alignment of short" >&5 if eval "test \"`echo '$''{'pgac_cv_alignof_short'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7410,7 +7621,7 @@ else pgac_cv_alignof_short='sizeof(short)' else cat > conftest.$ac_ext < struct { char filler; short field; } mystruct; @@ -7422,7 +7633,7 @@ main() exit(0); } EOF -if { (eval echo configure:7426: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:7637: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then pgac_cv_alignof_short=`cat conftestval` else @@ -7442,7 +7653,7 @@ EOF echo $ac_n "checking alignment of int""... $ac_c" 1>&6 -echo "configure:7446: checking alignment of int" >&5 +echo "configure:7657: checking alignment of int" >&5 if eval "test \"`echo '$''{'pgac_cv_alignof_int'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7450,7 +7661,7 @@ else pgac_cv_alignof_int='sizeof(int)' else cat > conftest.$ac_ext < struct { char filler; int field; } mystruct; @@ -7462,7 +7673,7 @@ main() exit(0); } EOF -if { (eval echo configure:7466: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:7677: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then pgac_cv_alignof_int=`cat conftestval` else @@ -7482,7 +7693,7 @@ EOF echo $ac_n "checking alignment of long""... $ac_c" 1>&6 -echo "configure:7486: checking alignment of long" >&5 +echo "configure:7697: checking alignment of long" >&5 if eval "test \"`echo '$''{'pgac_cv_alignof_long'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7490,7 +7701,7 @@ else pgac_cv_alignof_long='sizeof(long)' else cat > conftest.$ac_ext < struct { char filler; long field; } mystruct; @@ -7502,7 +7713,7 @@ main() exit(0); } EOF -if { (eval echo configure:7506: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:7717: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then pgac_cv_alignof_long=`cat conftestval` else @@ -7523,7 +7734,7 @@ EOF if [ x"$HAVE_LONG_LONG_INT_64" = xyes ] ; then echo $ac_n "checking alignment of long long int""... $ac_c" 1>&6 -echo "configure:7527: checking alignment of long long int" >&5 +echo "configure:7738: checking alignment of long long int" >&5 if eval "test \"`echo '$''{'pgac_cv_alignof_long_long_int'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7531,7 +7742,7 @@ else pgac_cv_alignof_long_long_int='sizeof(long long int)' else cat > conftest.$ac_ext < struct { char filler; long long int field; } mystruct; @@ -7543,7 +7754,7 @@ main() exit(0); } EOF -if { (eval echo configure:7547: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:7758: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then pgac_cv_alignof_long_long_int=`cat conftestval` else @@ -7564,7 +7775,7 @@ EOF fi echo $ac_n "checking alignment of double""... $ac_c" 1>&6 -echo "configure:7568: checking alignment of double" >&5 +echo "configure:7779: checking alignment of double" >&5 if eval "test \"`echo '$''{'pgac_cv_alignof_double'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7572,7 +7783,7 @@ else pgac_cv_alignof_double='sizeof(double)' else cat > conftest.$ac_ext < struct { char filler; double field; } mystruct; @@ -7584,7 +7795,7 @@ main() exit(0); } EOF -if { (eval echo configure:7588: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:7799: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then pgac_cv_alignof_double=`cat conftestval` else @@ -7622,12 +7833,12 @@ EOF echo $ac_n "checking for POSIX signal interface""... $ac_c" 1>&6 -echo "configure:7626: checking for POSIX signal interface" >&5 +echo "configure:7837: checking for POSIX signal interface" >&5 if eval "test \"`echo '$''{'pgac_cv_func_posix_signals'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < @@ -7638,7 +7849,7 @@ act.sa_flags = SA_RESTART; sigaction(0, &act, &oact); ; return 0; } EOF -if { (eval echo configure:7642: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7853: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* pgac_cv_func_posix_signals=yes else @@ -7667,7 +7878,7 @@ then # Extract the first word of "tclsh", so it can be a program name with args. set dummy tclsh; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:7671: checking for $ac_word" >&5 +echo "configure:7882: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_path_TCLSH'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7704,7 +7915,7 @@ fi # Extract the first word of "tcl", so it can be a program name with args. set dummy tcl; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:7708: checking for $ac_word" >&5 +echo "configure:7919: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_path_TCLSH'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7747,7 +7958,7 @@ fi if test "$USE_TCL" = true then echo $ac_n "checking for tclConfig.sh""... $ac_c" 1>&6 -echo "configure:7751: checking for tclConfig.sh" >&5 +echo "configure:7962: checking for tclConfig.sh" >&5 TCL_CONFIG_SH= library_dirs= if test -z "$TCL_DIRS" @@ -7776,7 +7987,7 @@ USE_TK=$USE_TCL # If TCL is disabled, disable TK if test "$USE_TK" = true then echo $ac_n "checking for tkConfig.sh""... $ac_c" 1>&6 -echo "configure:7780: checking for tkConfig.sh" >&5 +echo "configure:7991: checking for tkConfig.sh" >&5 TK_CONFIG_SH= # library_dirs are set in the check for TCL for dir in $library_dirs @@ -7798,7 +8009,7 @@ echo "configure:7780: checking for tkConfig.sh" >&5 # Extract the first word of "wish", so it can be a program name with args. set dummy wish; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:7802: checking for $ac_word" >&5 +echo "configure:8013: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_path_WISH'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -7848,7 +8059,7 @@ if test "$USE_X" = true; then # Uses ac_ vars as temps to allow command line to override cache and checks. # --without-x overrides everything else, but does not touch the cache. echo $ac_n "checking for X""... $ac_c" 1>&6 -echo "configure:7852: checking for X" >&5 +echo "configure:8063: checking for X" >&5 # Check whether --with-x or --without-x was given. if test "${with_x+set}" = set; then @@ -7910,12 +8121,12 @@ if test "$ac_x_includes" = NO; then # First, try using that file with no special directory specified. cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7919: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:8130: \"$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* @@ -7984,14 +8195,14 @@ if test "$ac_x_libraries" = NO; then ac_save_LIBS="$LIBS" LIBS="-l$x_direct_test_library $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8206: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* LIBS="$ac_save_LIBS" # We can link X programs with no special library path. @@ -8097,17 +8308,17 @@ else case "`(uname -sr) 2>/dev/null`" in "SunOS 5"*) echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6 -echo "configure:8101: checking whether -R must be followed by a space" >&5 +echo "configure:8312: checking whether -R must be followed by a space" >&5 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8322: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_R_nospace=yes else @@ -8123,14 +8334,14 @@ rm -f conftest* else LIBS="$ac_xsave_LIBS -R $x_libraries" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8345: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_R_space=yes else @@ -8162,7 +8373,7 @@ rm -f conftest* # libraries were built with DECnet support. And karl@cs.umb.edu says # the Alpha needs dnet_stub (dnet does not exist). echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6 -echo "configure:8166: checking for dnet_ntoa in -ldnet" >&5 +echo "configure:8377: checking for dnet_ntoa in -ldnet" >&5 ac_lib_var=`echo dnet'_'dnet_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 @@ -8170,7 +8381,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldnet $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8396: \"$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 @@ -8203,7 +8414,7 @@ fi if test $ac_cv_lib_dnet_dnet_ntoa = no; then echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6 -echo "configure:8207: checking for dnet_ntoa in -ldnet_stub" >&5 +echo "configure:8418: checking for dnet_ntoa in -ldnet_stub" >&5 ac_lib_var=`echo dnet_stub'_'dnet_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 @@ -8211,7 +8422,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldnet_stub $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8437: \"$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 @@ -8251,12 +8462,12 @@ fi # The nsl library prevents programs from opening the X display # on Irix 5.2, according to dickey@clark.net. echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 -echo "configure:8255: checking for gethostbyname" >&5 +echo "configure:8466: 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 <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8494: \"$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 @@ -8300,7 +8511,7 @@ fi if test $ac_cv_func_gethostbyname = no; then echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6 -echo "configure:8304: checking for gethostbyname in -lnsl" >&5 +echo "configure:8515: 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 @@ -8308,7 +8519,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lnsl $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8534: \"$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 @@ -8349,12 +8560,12 @@ fi # -lsocket must be given before -lnsl if both are needed. # We assume that if connect needs -lnsl, so does gethostbyname. echo $ac_n "checking for connect""... $ac_c" 1>&6 -echo "configure:8353: checking for connect" >&5 +echo "configure:8564: 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 <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8592: \"$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 @@ -8398,7 +8609,7 @@ fi if test $ac_cv_func_connect = no; then echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6 -echo "configure:8402: checking for connect in -lsocket" >&5 +echo "configure:8613: checking for connect in -lsocket" >&5 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -8406,7 +8617,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lsocket $X_EXTRA_LIBS $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8632: \"$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 @@ -8441,12 +8652,12 @@ fi # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX. echo $ac_n "checking for remove""... $ac_c" 1>&6 -echo "configure:8445: checking for remove" >&5 +echo "configure:8656: checking for remove" >&5 if eval "test \"`echo '$''{'ac_cv_func_remove'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8684: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_remove=yes" else @@ -8490,7 +8701,7 @@ fi if test $ac_cv_func_remove = no; then echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6 -echo "configure:8494: checking for remove in -lposix" >&5 +echo "configure:8705: checking for remove in -lposix" >&5 ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -8498,7 +8709,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lposix $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8724: \"$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 @@ -8533,12 +8744,12 @@ fi # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. echo $ac_n "checking for shmat""... $ac_c" 1>&6 -echo "configure:8537: checking for shmat" >&5 +echo "configure:8748: checking for shmat" >&5 if eval "test \"`echo '$''{'ac_cv_func_shmat'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8776: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_shmat=yes" else @@ -8582,7 +8793,7 @@ fi if test $ac_cv_func_shmat = no; then echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6 -echo "configure:8586: checking for shmat in -lipc" >&5 +echo "configure:8797: checking for shmat in -lipc" >&5 ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -8590,7 +8801,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lipc $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8816: \"$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 @@ -8634,7 +8845,7 @@ fi # libraries we check for below, so use a different variable. # --interran@uluru.Stanford.EDU, kb@cs.umb.edu. echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6 -echo "configure:8638: checking for IceConnectionNumber in -lICE" >&5 +echo "configure:8849: checking for IceConnectionNumber in -lICE" >&5 ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -8642,7 +8853,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lICE $X_EXTRA_LIBS $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8868: \"$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 @@ -8686,7 +8897,7 @@ fi X11_LIBS="" echo $ac_n "checking for XOpenDisplay in -lX11""... $ac_c" 1>&6 -echo "configure:8690: checking for XOpenDisplay in -lX11" >&5 +echo "configure:8901: checking for XOpenDisplay in -lX11" >&5 ac_lib_var=`echo X11'_'XOpenDisplay | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -8694,7 +8905,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lX11 ${X_PRE_LIBS} $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8920: \"$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 @@ -8744,6 +8955,12 @@ See the file 'config.log' for further diagnostics." 1>&2 fi +# Wait with these until we're done so no tests fail because of too +# many warnings. +if test x"$GCC" = x"yes" ; then + CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wmissing-declarations" +fi + trap '' 1 2 15 cat > confcache <<\EOF @@ -8884,7 +9101,6 @@ s%@oldincludedir@%$oldincludedir%g s%@infodir@%$infodir%g s%@mandir@%$mandir%g s%@VERSION@%$VERSION%g -s%@mkinstalldirs@%$mkinstalldirs%g s%@host@%$host%g s%@host_alias@%$host_alias%g s%@host_cpu@%$host_cpu%g @@ -8907,6 +9123,8 @@ s%@with_python@%$with_python%g s%@with_krb4@%$with_krb4%g s%@with_krb5@%$with_krb5%g s%@KRB_LIBS@%$KRB_LIBS%g +s%@krb_srvtab@%$krb_srvtab%g +s%@with_openssl@%$with_openssl%g s%@enable_odbc@%$enable_odbc%g s%@odbcinst_ini_dir@%$odbcinst_ini_dir%g s%@ELF_SYS@%$ELF_SYS%g @@ -8927,19 +9145,14 @@ s%@with_CXX@%$with_CXX%g s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g s%@INSTALL_DATA@%$INSTALL_DATA%g -s%@INSTLOPTS@%$INSTLOPTS%g -s%@INSTL_LIB_OPTS@%$INSTL_LIB_OPTS%g -s%@INSTL_SHLIB_OPTS@%$INSTL_SHLIB_OPTS%g -s%@INSTL_EXE_OPTS@%$INSTL_EXE_OPTS%g s%@INSTALL_SHLIB@%$INSTALL_SHLIB%g +s%@mkinstalldirs@%$mkinstalldirs%g s%@AWK@%$AWK%g s%@LEX@%$LEX%g s%@LEXLIB@%$LEXLIB%g s%@LN_S@%$LN_S%g s%@RANLIB@%$RANLIB%g -s%@find@%$find%g s%@tar@%$tar%g -s%@GZCAT@%$GZCAT%g s%@PERL@%$PERL%g s%@YACC@%$YACC%g s%@YFLAGS@%$YFLAGS%g diff --git a/configure.in b/configure.in index 468f94dda4c..74892551707 100644 --- a/configure.in +++ b/configure.in @@ -1,18 +1,30 @@ dnl Process this file with autoconf to produce a configure script. + +dnl Developers, please strive to achieve this order: +dnl +dnl 0. Initialization and options processing +dnl 1. Programs +dnl 2. Libraries +dnl 3. Header files +dnl 4. Types +dnl 5. Structures +dnl 6. Compiler characteristics +dnl 7. Functions, global variables +dnl 8. System services +dnl +dnl Read the Autoconf manual for details. + AC_INIT(src/backend/access/common/heaptuple.c) AC_PREFIX_DEFAULT(/usr/local/pgsql) AC_CONFIG_HEADER(src/include/config.h) AC_PREREQ(2.13) -AC_CONFIG_AUX_DIR(`pwd`/config) +AC_CONFIG_AUX_DIR(config) VERSION='7.1devel' AC_SUBST(VERSION) AC_DEFINE_UNQUOTED(PG_VERSION, "$VERSION") -mkinstalldirs="\$(SHELL) \$(top_srcdir)/config/mkinstalldirs" -AC_SUBST(mkinstalldirs) - AC_CANONICAL_HOST tas_file=dummy.s @@ -400,83 +412,99 @@ fi], AC_SUBST(with_python) +dnl A note on the Kerberos and OpenSSL options: dnl -dnl Optionally build with Kerberos 4 support -dnl -AC_MSG_CHECKING(whether to build with Kerberos 4 support) +dnl The user can give an argument to the option in order the specify +dnl the base path of the respective installation (what he specified +dnl perhaps as --prefix). If no argument is given ($withval is "yes") +dnl then we take the path where the package installs by default. This +dnl way the user doesn't have to use redundant --with-includes and +dnl --with-libraries options, but he can still use them if the layout +dnl is non-standard. + +# +# Kerberos 4 +# AC_ARG_WITH(krb4, [ --with-krb4[=DIR] use Kerberos 4 [/usr/athena]], [if test x"$withval" != x"no"; then - # If the user didn't give an argument, we take the Kerberos 4 default - # path /usr/athena. We look into lib/ and include/ for the Kerberos - # libraries and includes. If the user has a more complicated layout - # he can use --with-includes and --with-libraries. - if test x"$withval" = x"yes"; then - krb4dir=/usr/athena + if test x"$withval" != x"yes"; then + krb4_prefix=$withval else - krb4dir=$withval + krb4_prefix=/usr/athena fi with_krb4=yes - AC_MSG_RESULT(yes) - if test -d $krb4dir; then - if test -d "$krb4dir/include"; then - INCLUDES="$INCLUDES -I$krb4dir/include" +else + with_krb4=no +fi], +[with_krb4=no]) + +AC_SUBST(with_krb4) +if test "$with_krb4" = yes ; then + AC_MSG_RESULT([building with Kerberos 4 support]) + AC_DEFINE(KRB4, [], [Define if you are building with Kerberos 4 support.]) + + if test -d "$krb4_prefix"; then + if test -d "$krb4_prefix/include"; then + INCLUDES="$INCLUDES -I$krb4_prefix/include" fi - if test -d "$krb4dir/lib"; then - krb_libdir="-L$krb4dir/lib" + if test -d "$krb4_prefix/lib"; then + krb_libdir="-L$krb4_prefix/lib" LIBS="$krb_libdir $LIBS" fi fi - AC_CHECK_LIB(des, main, [], [AC_MSG_ERROR([library \`des' is required for Kerberos 4])]) - AC_CHECK_LIB(krb, main, [], [AC_MSG_ERROR([library \`krb' is required for Kerberos 4])]) + dnl Test for these libraries is below KRB_LIBS="$krb_libdir -lkrb -ldes" - AC_DEFINE(KRB4,, [Define if you are building with Kerberos 4 support.]) -else - AC_MSG_RESULT(no) -fi], -[AC_MSG_RESULT(no)]) -AC_SUBST(with_krb4) +fi -dnl -dnl Optionally build with Kerberos 5 support -dnl -AC_MSG_CHECKING(whether to build with Kerberos 5 support) +# +# Kerberos 5 +# AC_ARG_WITH(krb5, [ --with-krb5[=DIR] use Kerberos 5 [/usr/athena]], [if test x"$withval" != x"no"; then - if test x"$withval" = x"yes"; then - krb5dir=/usr/athena + if test x"$withval" != x"yes"; then + krb5_prefix=$withval else - krb5dir=$withval + krb5_prefix=/usr/athena fi with_krb5=yes - AC_MSG_RESULT(yes) - if test -d $krb5dir; then - if test -d "$krb5dir/include"; then - INCLUDES="$INCLUDES -I$krb5dir/include" +else + with_krb5=no +fi], +[with_krb5=no]) + +AC_SUBST(with_krb5) +if test "$with_krb5" = yes ; then + AC_MSG_RESULT([building with Kerberos 5 support]) + AC_DEFINE(KRB5,, [Define if you are building with Kerberos 5 support.]) + + if test -d $krb5_prefix; then + if test -d "$krb5_prefix/include"; then + INCLUDES="$INCLUDES -I$krb5_prefix/include" fi - if test -d "$krb5dir/lib"; then - krb_libdir="-L$krb5dir/lib" + if test -d "$krb5_prefix/lib"; then + krb_libdir="-L$krb5_prefix/lib" LIBS="$krb_libdir $LIBS" fi fi - AC_CHECK_LIB(com_err, main, [], [AC_MSG_ERROR([library \`com_err' is required for Kerberos 5])]) - AC_CHECK_LIB(crypto, main, [], [AC_MSG_ERROR([library \`crypto' is required for Kerberos 5])]) - AC_CHECK_LIB(krb5, main, [], [AC_MSG_ERROR([library \`krb5' is required for Kerberos 5])]) + + dnl Test for these libraries is below KRB_LIBS="$krb_libdir -lkrb5 -lcrypto -lcom_err" - AC_DEFINE(KRB5,, [Define if you are building with Kerberos 5 support.]) -else - AC_MSG_RESULT(no) -fi], -[AC_MSG_RESULT(no)]) -AC_SUBST(with_krb5) +fi + + +# Using both Kerberos 4 and Kerberos 5 at the same time isn't going to work. +if test "$with_krb4" = yes && test "$with_krb5" = yes ; then + AC_MSG_ERROR([Kerberos 4 and Kerberos 5 support cannot be combined]) +fi dnl Necessary for special libpq link AC_SUBST(KRB_LIBS) -dnl -dnl Kerberos configuration parameters -dnl +# +# Kerberos configuration parameters +# AC_ARG_WITH(krb-srvnam, [ --with-krb-srvnam=NAME name of the Postgres service principal in Kerberos], [if test x"$withval" = x"yes"; then AC_MSG_ERROR([argument required for --with-krb-srvnam]) @@ -492,14 +520,53 @@ AC_ARG_WITH(krb-srvtab, [ --with-krb-srvtab=FILE location of Kerberos server's else krb_srvtab=$withval fi], -[if test x"$with_krb5" = x"yes"; then - krb_srvtab="FILE:/usr/local/postgres/krb5.keytab" +[if test "$with_krb5" = yes ; then + krb_srvtab='FILE:${sysconfdir}/krb5.keytab' +elif test "$with_krb4" = yes ; then + krb_srvtab='/etc/srvtab' else - krb_srvtab="/etc/srvtab" + krb_srvtab= fi]) -AC_DEFINE_UNQUOTED(PG_KRB_SRVTAB, ["$krb_srvtab"], [The location of the Kerberos server's keytab file]) +AC_SUBST(krb_srvtab) +# +# OpenSSL +# +AC_ARG_WITH(openssl, [ --with-openssl[=DIR] build with OpenSSL support [/usr/local/ssl]], +[if test x"$withval" != x"no" ; then + if test x"$withval" != x"yes" ; then + openssl_prefix=$withval + else + openssl_prefix=/usr/local/ssl + fi + with_openssl=yes +else + with_openssl=no +fi], +[with_openssl=no]) + +AC_SUBST(with_openssl) +if test "$with_openssl" = yes ; then + AC_MSG_RESULT([building with OpenSSL support]) + AC_DEFINE([USE_SSL], [], [Define to build with (Open)SSL support]) + + if test -d "${openssl_prefix}/include" ; then + INCLUDES="$INCLUDES -I${openssl_prefix}/include" + fi + if test -d "${openssl_prefix}/lib" ; then + openssl_libdir="${openssl_prefix}/lib" + LIBS="$LIBS -L${openssl_prefix}/lib" + fi +fi + + +# OpenSSL and Kerberos 5 both have a `crypto' library, so if you want to +# use both of them you'll have to figure it out yourself. +if test "$with_openssl" = yes && test "$with_krb5" = yes ; then + AC_MSG_ERROR([OpenSSL and Kerberos 5 support cannot be combined]) +fi + dnl dnl Optionally enable the building of the ODBC driver @@ -524,14 +591,14 @@ AC_SUBST(enable_odbc) dnl Allow for overriding the default location of the odbcinst.ini dnl file which is normally ${datadir} (i.e., ${prefix}/share). if test x"$enable_odbc" = x"yes" ; then -AC_ARG_WITH(odbcinst, [ --with-odbcinst=DIR default directory for odbcinst.ini [datadir]], +AC_ARG_WITH(odbcinst, [ --with-odbcinst=DIR default directory for odbcinst.ini [sysconfdir]], [if test x"$with_odbcinst" = x"yes" || test x"$with_odbcinst" = x"no" ; then AC_MSG_ERROR([You must supply an argument to the --with-odbcinst option.]) fi odbcinst_ini_dir=$withval], -[odbcinst_ini_dir='${datadir}']) +[odbcinst_ini_dir='${sysconfdir}']) else - odbcinst_ini_dir='${datadir}' + odbcinst_ini_dir='${sysconfdir}' fi AC_SUBST(odbcinst_ini_dir) @@ -628,37 +695,34 @@ fi], AC_SUBST(with_CXX) - -dnl Figure out how to invoke "install" and what install options to use. +# Figure out how to invoke "install" and what install options to use. AC_PROG_INSTALL - -INSTLOPTS="-m 444" -INSTL_EXE_OPTS="-m 555" -INSTL_SCRIPT_OPTS="-m 755" -INSTL_LIB_OPTS="-m 644" -INSTL_SHLIB_OPTS="-m 644" - -dnl HPUX wants shared libs to be mode 555. -case "$host_os" in - hpux*) - INSTL_SHLIB_OPTS="-m 555" ;; +# When Autoconf chooses install-sh as install program it tries to generate +# a relative path to it in each makefile where it subsitutes it. This clashes +# with our Makefile.global concept. This workaround helps. +case $INSTALL in + *install-sh*) INSTALL='\${SHELL} \${top_srcdir}/config/install-sh -c';; esac -AC_SUBST(INSTLOPTS) -AC_SUBST(INSTL_LIB_OPTS) -AC_SUBST(INSTL_SHLIB_OPTS) -AC_SUBST(INSTL_EXE_OPTS) +# Fix Autoconf's brain-dead defaults for script installs. +INSTALL_SCRIPT="\${INSTALL} -m 755" -dnl Fix autoconf's brain-dead defaults for script and shlib installs. - -INSTALL_SCRIPT="\${INSTALL} $INSTL_SCRIPT_OPTS" -AC_SUBST(INSTALL_SCRIPT) +# HPUX wants shared libs to be mode 555. Add your platform's special +# needs here if necessary. +case $host_os in + hpux*) INSTL_SHLIB_OPTS="-m 555" ;; + *) INSTL_SHLIB_OPTS="-m 644" ;; +esac INSTALL_SHLIB="\${INSTALL} $INSTL_SHLIB_OPTS" AC_SUBST(INSTALL_SHLIB) +mkinstalldirs="\$(SHELL) \$(top_srcdir)/config/mkinstalldirs" +AC_SUBST(mkinstalldirs) + + AC_PROG_AWK AC_PROG_LEX @@ -678,15 +742,12 @@ broken as well.) fi AC_PROG_LN_S AC_PROG_RANLIB -AC_PATH_PROG(find, find) AC_PATH_PROG(tar, tar) -AC_PATH_PROGS(GZCAT, gzcat zcat, gzcat) AC_CHECK_PROGS(PERL, perl,) AC_PROG_YACC AC_SUBST(YFLAGS) -AC_CHECK_LIB(z, main) AC_CHECK_LIB(sfio, main) AC_CHECK_LIB(ncurses, main, [], [AC_CHECK_LIB(curses, main)]) AC_CHECK_LIB(termcap, main) @@ -714,8 +775,29 @@ AC_CHECK_LIB(BSD, main) AC_CHECK_LIB(gen, main) AC_CHECK_LIB(PW, main) AC_SEARCH_LIBS(crypt, crypt) +AC_CHECK_LIB(z, inflate) +if test "$with_krb4" = yes ; then + AC_CHECK_LIB(des, [des_encrypt], [], [AC_MSG_ERROR([library \`des' is required for Kerberos 4])]) + AC_CHECK_LIB(krb, [krb_sendauth], [], [AC_MSG_ERROR([library \`krb' is required for Kerberos 4])]) +fi + +if test "$with_krb5" = yes ; then + AC_CHECK_LIB(com_err, main, [], [AC_MSG_ERROR([library \`com_err' is required for Kerberos 5])]) + AC_CHECK_LIB(crypto, main, [], [AC_MSG_ERROR([library \`crypto' is required for Kerberos 5])]) + AC_CHECK_LIB(krb5, main, [], [AC_MSG_ERROR([library \`krb5' is required for Kerberos 5])]) +fi + +if test "$with_openssl" = yes ; then + dnl Order matters! + AC_CHECK_LIB(crypto, [CRYPTO_new_ex_data], [], [AC_MSG_ERROR([library \`ssl' is required for OpenSSL])]) + AC_CHECK_LIB(ssl, [SSL_library_init], [], [AC_MSG_ERROR([library \`ssl' is required for OpenSSL])]) +fi + + +dnl dnl Checks for header files. +dnl AC_HEADER_STDC AC_HEADER_SYS_WAIT AC_CHECK_HEADERS(arpa/inet.h) @@ -725,24 +807,38 @@ AC_CHECK_HEADERS(endian.h) AC_CHECK_HEADERS(float.h) AC_CHECK_HEADERS(fp_class.h) AC_CHECK_HEADERS(getopt.h) -AC_CHECK_HEADERS(history.h) AC_CHECK_HEADERS(ieeefp.h) AC_CHECK_HEADERS(limits.h) AC_CHECK_HEADERS(netdb.h) AC_CHECK_HEADERS(netinet/in.h) -AC_CHECK_HEADERS(readline.h) -AC_CHECK_HEADERS(readline/history.h) -AC_CHECK_HEADERS(readline/readline.h) +AC_CHECK_HEADERS([readline/readline.h readline.h], [break]) +AC_CHECK_HEADERS([readline/history.h history.h], [break]) AC_CHECK_HEADERS(sys/select.h) AC_CHECK_HEADERS(termios.h) AC_CHECK_HEADERS(unistd.h) AC_CHECK_HEADERS(values.h) -AC_CHECK_HEADERS(sys/exec.h sys/pstat.h machine/vmparam.h) +AC_CHECK_HEADERS(sys/pstat.h) AC_CHECK_HEADERS(sys/types.h sys/socket.h) AC_CHECK_HEADERS(sys/param.h pwd.h) +if test "$with_krb4" = yes ; then + AC_CHECK_HEADER(krb.h, [], [AC_MSG_ERROR([header file is required for Kerberos 4])]) +fi +if test "$with_krb5" = yes ; then + AC_CHECK_HEADER(krb5.h, [], [AC_MSG_ERROR([header file is required for Kerberos 5])]) + AC_CHECK_HEADER(com_err.h, [], [AC_MSG_ERROR([header file is required for Kerberos 5])]) +fi + +if test "$with_openssl" = yes ; then + AC_CHECK_HEADER([openssl/ssl.h], [], [AC_MSG_ERROR([header file is required for OpenSSL])]) + AC_CHECK_HEADER([openssl/err.h], [], [AC_MSG_ERROR([header file is required for OpenSSL])]) +fi + + +dnl dnl Checks for typedefs, structures, and compiler characteristics. +dnl AC_C_CONST AC_C_INLINE AC_C_STRINGIZE @@ -762,6 +858,7 @@ PGAC_UNION_SEMUN AC_MSG_CHECKING(for fcntl(F_SETLK)) +if test "$os" != linux ; then AC_TRY_LINK([#include #include ], [struct flock lck; @@ -770,6 +867,9 @@ AC_TRY_LINK([#include fcntl(0, F_SETLK, &lck);], [AC_DEFINE(HAVE_FCNTL_SETLK) AC_MSG_RESULT(yes)], AC_MSG_RESULT(no)) +else + AC_MSG_RESULT([broken on Linux]) +fi dnl Checks for library functions. AC_FUNC_MEMCMP @@ -779,18 +879,18 @@ AC_CHECK_FUNCS(memmove sysconf) AC_CHECK_FUNCS(sigprocmask waitpid setsid fcvt) AC_CHECK_FUNCS(setproctitle pstat) -AC_MSG_CHECKING(for PS_STRINGS) -AC_TRY_LINK( -[#ifdef HAVE_MACHINE_VMPARAM_H -# include -#endif -#ifdef HAVE_SYS_EXEC_H -# include -#endif], +AC_CACHE_CHECK([for PS_STRINGS], [pgac_cv_var_PS_STRINGS], +[AC_TRY_LINK( +[#include +#include +], [PS_STRINGS->ps_nargvstr = 1; PS_STRINGS->ps_argvstr = "foo";], -[AC_MSG_RESULT(yes) AC_DEFINE(HAVE_PS_STRINGS)], -AC_MSG_RESULT(no)) +[pgac_cv_var_PS_STRINGS=yes], +[pgac_cv_var_PS_STRINGS=no])]) +if test "$pgac_cv_var_PS_STRINGS" = yes ; then + AC_DEFINE([HAVE_PS_STRINGS], [], [Define if the PS_STRINGS thing exists.]) +fi AC_CHECK_FUNCS(fpclass fp_class fp_class_d class) dnl We use our snprintf.c emulation if either snprintf() or vsnprintf() @@ -1193,6 +1293,12 @@ See the file 'config.log' for further diagnostics.]) fi +# Wait with these until we're done so no tests fail because of too +# many warnings. +if test x"$GCC" = x"yes" ; then + CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wmissing-declarations" +fi + dnl Finally ready to produce output files ... AC_OUTPUT( diff --git a/contrib/Makefile b/contrib/Makefile index 2a3b099afaf..bd7626ad88c 100644 --- a/contrib/Makefile +++ b/contrib/Makefile @@ -1,13 +1,12 @@ # # The PostgreSQL contrib tree Makefile # -# Portions Copyright (c) 1999-2000, PostgreSQL, Inc -# -# $Header: /cvsroot/pgsql/contrib/Makefile,v 1.5 2000/06/19 13:52:59 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/Makefile,v 1.6 2000/07/09 13:12:57 petere Exp $ # -TOPDIR = .. -include Makefile.global +subdir = contrib +top_builddir = .. +include ../src/Makefile.global WANTED_DIRS = array \ earthdistance \ @@ -25,34 +24,22 @@ WANTED_DIRS = array \ spi \ string \ tips \ - tools \ unixdate \ userlock \ vacuumlo # odbc - -all: +all .DEFAULT: for dir in $(WANTED_DIRS); do \ if [ -e $$dir/Makefile ]; then \ $(MAKE) -C $$dir $@ ; \ fi; \ done - install: - ../config/mkinstalldirs $(CONTRIB_BINDIR) $(CONTRIB_MODDIR) $(CONTRIB_DOCDIR) $(CONTRIB_SQLDIR) $(CONTRIB_EXAMPLESDIR) - for dir in $(WANTED_DIRS); do \ - if [ -e $$dir/Makefile ]; then \ - $(MAKE) -C $$dir $@ ; \ - fi; \ - done - $(INSTALL) $(INSTL_LIB_OPTS) Contrib.index $(CONTRIB_DOCDIR); - - -.DEFAULT: for dir in $(WANTED_DIRS); do \ if [ -e $$dir/Makefile ]; then \ $(MAKE) -C $$dir $@ ; \ fi; \ done + $(INSTALL_DATA) Contrib.index $(docdir)/contrib diff --git a/contrib/Makefile.global b/contrib/Makefile.global deleted file mode 100644 index f1efad49d1c..00000000000 --- a/contrib/Makefile.global +++ /dev/null @@ -1,44 +0,0 @@ - -#------------------------------------------------------------------------- -# -# Makefile.global -# Build and install PostgreSQL contrib. -# -# Portions Copyright (c) 1999-2000, PostgreSQL, Inc -# -# -# IDENTIFICATION -# $Header: /cvsroot/pgsql/contrib/Attic/Makefile.global,v 1.2 2000/06/19 13:52:59 momjian Exp $ -# -#------------------------------------------------------------------------- - -SRCDIR = $(TOPDIR)/src -include $(SRCDIR)/Makefile.global - -### --------------------------------------------------------- -### DELETE THIS PART if ../src/Makefile.global is standardize -### (has define all next definitions itself) - -DOCDIR=$(POSTDOCDIR) - -# not $PGDATA, but anything like '/usr/local/pgsql/share' -DATADIR=$(LIBDIR) - -### ---------------------------------------------------------- - -# execute-able -CONTRIB_BINDIR = $(BINDIR) -# *.so -CONTRIB_MODDIR = $(LIBDIR)/modules -# *.doc -CONTRIB_DOCDIR = $(DOCDIR)/contrib -# *.sql -CONTRIB_SQLDIR = $(DATADIR)/sql -# *.examples -CONTRIB_EXAMPLESDIR = $(CONTRIB_DOCDIR)/examples - - -RM = rm -f -SED = sed - - diff --git a/contrib/array/Makefile b/contrib/array/Makefile index e0717f08461..61f12fcfc97 100644 --- a/contrib/array/Makefile +++ b/contrib/array/Makefile @@ -1,54 +1,38 @@ # -# $Header: /cvsroot/pgsql/contrib/array/Attic/Makefile,v 1.11 2000/07/04 16:16:43 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/array/Attic/Makefile,v 1.12 2000/07/09 13:12:59 petere Exp $ # -TOPDIR=../.. +subdir = contrib/array +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global - -NAME = array_iterator - -PROGRAM = -OBJS = $(NAME).o -DOCS = README.$(NAME) -SQLS = $(NAME).sql -BINS = -EXAMPLES= -MODS = $(NAME)$(DLSUFFIX) +NAME := array_iterator +SONAME := $(NAME)$(DLSUFFIX) CFLAGS += -I. $(CFLAGS_SL) -OTHER_CLEAN = $(SQLS) +all: $(SONAME) $(NAME).sql -all: $(MODS) $(SQLS) +$(NAME).sql: $(NAME).sql.in + sed -e 's:MODULE_PATHNAME:$(libdir)/contrib/$(SONAME):g' < $< > $@ -%.sql: %.sql.in - $(SED) "s|MODULE_PATHNAME|$(CONTRIB_MODDIR)/$(@:.sql=$(DLSUFFIX))|" < $< > $@ +install: all installdirs + $(INSTALL_DATA) README.$(NAME) $(docdir)/contrib + $(INSTALL_DATA) $(NAME).sql $(datadir)/contrib + $(INSTALL_SHLIB) $(SONAME) $(libdir)/contrib -install: install_doc install_sql install_mod +installdirs: + $(mkinstalldirs) $(docdir)/contrib $(datadir)/contrib $(libdir)/contrib -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done - -install_sql: - for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ - done - -install_mod: - for inst_file in $(MODS); do \ - $(INSTALL) $(INSTL_SHLIB_OPTS) $$inst_file $(CONTRIB_MODDIR); \ - done +uninstall: + rm -rf $(docdir)/contrib/README.$(NAME) $(datadir)/contrib/$(NAME).sql $(libdir)/contrib/$(SONAME) +clean distclean maintainer-clean: + rm -f $(SONAME) $(NAME).sql depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif diff --git a/contrib/earthdistance/Makefile b/contrib/earthdistance/Makefile index c6a971f7c08..733f128b82b 100644 --- a/contrib/earthdistance/Makefile +++ b/contrib/earthdistance/Makefile @@ -1,53 +1,38 @@ # -# $Header: /cvsroot/pgsql/contrib/earthdistance/Makefile,v 1.5 2000/07/04 16:16:44 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/earthdistance/Makefile,v 1.6 2000/07/09 13:13:00 petere Exp $ # -TOPDIR=../.. +subdir = contrib/earthdistance +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global - -NAME = earthdistance - -PROGRAM = -OBJS = $(NAME).o -DOCS = README.$(NAME) -SQLS = $(NAME).sql -BINS = -EXAMPLES= -MODS = $(NAME)$(DLSUFFIX) +NAME := earthdistance +SONAME := $(NAME)$(DLSUFFIX) CFLAGS += -I. $(CFLAGS_SL) -OTHER_CLEAN = $(SQLS) +all: $(SONAME) $(NAME).sql -all: $(MODS) $(SQLS) +$(NAME).sql: $(NAME).sql.in + sed -e 's:MODULE_PATHNAME:$(datadir)/contrib/$(SONAME):g' < $< > $@ -%.sql: %.sql.in - $(SED) "s|MODULE_PATHNAME|$(CONTRIB_MODDIR)/$(@:.sql=$(DLSUFFIX))|" < $< > $@ +install: all installdirs + $(INSTALL_SHLIB) $(SONAME) $(libdir)/contrib + $(INSTALL_DATA) $(NAME).sql $(datadir)/contrib + $(INSTALL_DATA) README.$(NAME) $(docdir)/contrib -install: install_doc install_sql install_mod +installdirs: + $(mkinstalldirs) $(libdir)/contrib $(datadir)/contrib $(docdir)/contrib -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done +uninstall: + rm -f $(libdir)/contrib/$(SONAME) $(datadir)/contrib/$(NAME).sql $(docdir)/contrib/README.$(NAME) -install_sql: - for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ - done - -install_mod: - for inst_file in $(MODS); do \ - $(INSTALL) $(INSTL_SHLIB_OPTS) $$inst_file $(CONTRIB_MODDIR); \ - done +clean distclean maintainer-clean: + rm -f $(SONAME) $(NAME).sql depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif diff --git a/contrib/findoidjoins/Makefile b/contrib/findoidjoins/Makefile index 530e218d445..68ebf72c431 100644 --- a/contrib/findoidjoins/Makefile +++ b/contrib/findoidjoins/Makefile @@ -1,50 +1,26 @@ # -# $Header: /cvsroot/pgsql/contrib/findoidjoins/Attic/Makefile,v 1.7 2000/06/19 13:53:22 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/findoidjoins/Attic/Makefile,v 1.8 2000/07/09 13:13:03 petere Exp $ # -TOPDIR=../.. +subdir = contrib/findoidjoins +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global +CFLAGS += -I$(LIBPGEASYDIR) -I$(LIBPQDIR) +LIBS += $(LIBPGEASY) -NAME = findoidjoins +all: findoidjoins -PROGRAM = $(NAME) -OBJS = $(NAME).o -DOCS = README.$(NAME) -SQLS = -BINS = $(PROGRAM) make_oidjoins_check -EXAMPLES= -MODS = +install: all installdirs + $(INSTALL_PROGRAM) findoidjoins$(X) $(bindir) + $(INSTALL_SCRIPT) make_oidjoins_check $(bindir) + $(INSTALL_DATA) README.findoidjoins $(docdir)/contrib -CFLAGS += -I$(LIBPGEASYDIR) -I$(LIBPQDIR) +installdirs: + $(mkinstalldirs) $(bindir) $(docdir)/contrib -OTHER_CLEAN = +uninstall: + rm -f $(bindir)/findoidjoins$(X) $(bindir)/make_oidjoins_check $(docdir)/contrib/README.findoidjoins - -all: $(PROGRAM) - -$(PROGRAM): $(OBJS) $(LIBPGEASYDIR)/libpgeasy.a - $(CC) $(CFLAGS) -o $@ $(OBJS) $(LIBPGEASY) - - -install: install_doc nstall_bin - -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done - -install_bin: - for inst_file in $(BINS); do \ - $(INSTALL) $(INSTL_EXE_OPTS) $$inst_file $(CONTRIB_BINDIR); \ - done - -depend dep: - $(CC) -MM -MG $(CFLAGS) *.c > depend - -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - -ifeq (depend,$(wildcard depend)) -include depend -endif +clean distclean maintainer-clean: + rm -f findoidjoins$(X) diff --git a/contrib/fulltextindex/BENCH b/contrib/fulltextindex/BENCH deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/contrib/fulltextindex/Makefile b/contrib/fulltextindex/Makefile index 0ab836c6013..cb76c19405a 100644 --- a/contrib/fulltextindex/Makefile +++ b/contrib/fulltextindex/Makefile @@ -1,58 +1,40 @@ # -# $Header: /cvsroot/pgsql/contrib/fulltextindex/Attic/Makefile,v 1.6 2000/07/04 16:16:48 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/fulltextindex/Attic/Makefile,v 1.7 2000/07/09 13:13:07 petere Exp $ # -TOPDIR=../.. +subdir = contrib/fulltextindex +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global - -NAME = fti - -PROGRAM = -OBJS = $(NAME).o -DOCS = README.$(NAME) -SQLS = $(NAME).sql -BINS = fti.pl -EXAMPLES= -MODS = $(NAME)$(DLSUFFIX) +NAME := fti +SONAME := $(NAME)$(DLSUFFIX) CFLAGS += -I. $(CFLAGS_SL) -OTHER_CLEAN = $(SQLS) +all: $(SONAME) $(NAME).sql -all: $(MODS) $(SQLS) +$(NAME).sql: $(NAME).sql.in + sed -e 's:MODULE_PATHNAME:$(libdir)/contrib/$(SONAME):g' < $< > $@ -%.sql: %.sql.in - $(SED) "s|MODULE_PATHNAME|$(CONTRIB_MODDIR)/$(@:.sql=$(DLSUFFIX))|" < $< > $@ +install: all installdirs + $(INSTALL_SCRIPT) fti.pl $(bindir) + $(INSTALL_SHLIB) $(SONAME) $(libdir)/contrib + $(INSTALL_DATA) $(NAME).sql $(datadir)/contrib + $(INSTALL_DATA) README.$(NAME) $(docdir)/contrib -install: install_doc install_sql install_mod install_bin +installdirs: + $(mkinstalldirs) $(bindir) $(libdir)/contrib $(datadir)/contrib $(docdir)/contrib -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done +uninstall: + rm -f $(bindir)/fti.pl $(libdir)/contrib/$(SONAME) \ + $(datadir)/contrib/$(NAME).sql $(docdir)/contrib/README.$(NAME) -install_sql: - for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ - done - -install_mod: - for inst_file in $(MODS); do \ - $(INSTALL) $(INSTL_SHLIB_OPTS) $$inst_file $(CONTRIB_MODDIR); \ - done - -install_bin: - for inst_file in $(BINS); do \ - $(INSTALL) $(INSTL_EXE_OPTS) $$inst_file $(CONTRIB_BINDIR); \ - done +clean distclean maintainer-clean: + rm -f $(SONAME) $(NAME).sql depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif diff --git a/contrib/isbn_issn/Makefile b/contrib/isbn_issn/Makefile index fcf120df877..6969063eeb3 100644 --- a/contrib/isbn_issn/Makefile +++ b/contrib/isbn_issn/Makefile @@ -1,54 +1,38 @@ # -# $Header: /cvsroot/pgsql/contrib/isbn_issn/Attic/Makefile,v 1.6 2000/07/04 16:16:53 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/isbn_issn/Attic/Makefile,v 1.7 2000/07/09 13:13:10 petere Exp $ # -TOPDIR=../.. +subdir = contrib/isbn_issn +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global - -NAME = isbn_issn - -PROGRAM = -OBJS = $(NAME).o -DOCS = README.$(NAME) -SQLS = $(NAME).sql -BINS = -EXAMPLES= -MODS = $(NAME)$(DLSUFFIX) +NAME := isbn_issn +SONAME := $(NAME)$(DLSUFFIX) CFLAGS += -I. $(CFLAGS_SL) -OTHER_CLEAN = $(SQLS) +all: $(SONAME) $(NAME).sql -all: $(MODS) $(SQLS) +$(NAME).sql: $(NAME).sql.in + sed -e 's:MODULE_PATHNAME:$(libdir)/contrib/$(SONAME):g' < $< > $@ +install: all installdirs + $(INSTALL_DATA) README.$(NAME) $(docdir)/contrib + $(INSTALL_DATA) $(NAME).sql $(datadir)/contrib + $(INSTALL_SHLIB) $(SONAME) $(libdir)/contrib -%.sql: %.sql.in - $(SED) "s|MODULE_PATHNAME|$(CONTRIB_MODDIR)/$(@:.sql=$(DLSUFFIX))|" < $< > $@ +installdirs: + $(mkinstalldirs) $(docdir)/contrib $(datadir)/contrib $(libdir)/contrib -install: install_doc install_sql install_mod +uninstall: + rm -rf $(docdir)/contrib/README.$(NAME) $(datadir)/contrib/$(NAME).sql $(libdir)/contrib/$(SONAME) -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done - -install_sql: - for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ - done - -install_mod: - for inst_file in $(MODS); do \ - $(INSTALL) $(INSTL_SHLIB_OPTS) $$inst_file $(CONTRIB_MODDIR); \ - done +clean distclean maintainer-clean: + rm -f $(SONAME) $(NAME).sql depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif diff --git a/contrib/linux/Makefile b/contrib/linux/Makefile deleted file mode 100644 index 3e11fd11cd8..00000000000 --- a/contrib/linux/Makefile +++ /dev/null @@ -1,40 +0,0 @@ -# -# $Header: /cvsroot/pgsql/contrib/linux/Attic/Makefile,v 1.2 2000/06/19 13:53:41 momjian Exp $ -# - -TOPDIR=../.. - -include ../Makefile.global - -NAME = - -PROGRAM = -OBJS = -DOCS = -SQLS = -BINS = -BINS = postgres.init.csh postgres.init.sh - -EXAMPLES= -MODS = - -OTHER_CLEAN = - -all: - -install: install_bin - -install_bin: - for inst_file in $(BINS); do \ - $(INSTALL) $(INSTL_EXE_OPTS) $$inst_file $(CONTRIB_BINDIR); \ - done - -depend dep: - $(CC) -MM -MG $(CFLAGS) *.c > depend - -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - -ifeq (depend,$(wildcard depend)) -include depend -endif diff --git a/contrib/lo/Makefile b/contrib/lo/Makefile index 4685bcd131d..ed192a9d280 100644 --- a/contrib/lo/Makefile +++ b/contrib/lo/Makefile @@ -1,19 +1,15 @@ # -# $Header: /cvsroot/pgsql/contrib/lo/Makefile,v 1.6 2000/07/04 16:16:54 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/lo/Makefile,v 1.7 2000/07/09 13:13:14 petere Exp $ # -TOPDIR=../.. +subdir = contrib/lo +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global +NAME := lo +SONAME := $(NAME)$(DLSUFFIX) -NAME = lo - -PROGRAM = -OBJS = $(NAME).o -DOCS = README.$(NAME) SQLS = $(NAME).sql lo_drop.sql lo_test.sql -BINS = -EXAMPLES= MODS = $(NAME)$(DLSUFFIX) CFLAGS += -I. $(CFLAGS_SL) @@ -22,39 +18,31 @@ ifdef REFINT_VERBOSE CFLAGS+= -DREFINT_VERBOSE endif -OTHER_CLEAN = $(SQLS) +all: $(SONAME) $(NAME).sql -all: $(MODS) $(SQLS) +$(NAME).sql: $(NAME).sql.in + sed -e 's:MODULE_PATHNAME:$(libdir)/contrib/$(SONAME):g' < $< > $@ +install: all installdirs + $(INSTALL_SHLIB) $(SONAME) $(libdir)/contrib + $(INSTALL_DATA) README.$(NAME) $(docdir)/contrib + $(INSTALL_DATA) $(NAME).sql $(datadir)/contrib + $(INSTALL_DATA) lo_drop.sql $(datadir)/contrib + $(INSTALL_DATA) lo_test.sql $(datadir)/contrib -%.sql: %.sql.in - $(SED) "s|MODULE_PATHNAME|$(CONTRIB_MODDIR)/$(@:.sql=$(DLSUFFIX))|" < $< > $@ +installdirs: + $(mkinstalldirs) $(libdir)/contrib $(docdir)/contrib $(datadir)/contrib +uninstall: + rm -f $(libdir)/contrib/$(SONAME) $(docdir)/contrib/README.$(NAME) \ + $(addprefix $(datadir)/contrib/, $(NAME).sql lo_drop.sql lo_test.sql) -install: install_doc install_sql install_mod - -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done - -install_sql: - for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ - done - -install_mod: - for inst_file in $(MODS); do \ - $(INSTALL) $(INSTL_SHLIB_OPTS) $$inst_file $(CONTRIB_MODDIR); \ - done +clean distclean maintainer-clean: + rm -f $(SONAME) $(NAME).sql depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif - diff --git a/contrib/mSQL-interface/Makefile b/contrib/mSQL-interface/Makefile index 7950b6934db..cbebcef9293 100644 --- a/contrib/mSQL-interface/Makefile +++ b/contrib/mSQL-interface/Makefile @@ -1,35 +1,30 @@ # -# $Header: /cvsroot/pgsql/contrib/mSQL-interface/Attic/Makefile,v 1.3 2000/06/19 13:53:47 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/mSQL-interface/Attic/Makefile,v 1.4 2000/07/09 13:13:17 petere Exp $ # -TOPDIR=../.. +subdir = contrib/mSQL-interface +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global +NAME := mpgsql +SO_MAJOR_VERSION := 0 +SO_MINOR_VERSION := 0 +OBJS := mpgsql.o -NAME = mpgsql +CFLAGS += -I$(LIBPQDIR) -PROGRAM = -OBJS = -DOCS = README.$(NAME) $(NAME).c -SQLS = -BINS = -EXAMPLES= -MODS = +include $(top_srcdir)/src/Makefile.shlib -OTHER_CLEAN = +all: all-lib -all:: +install: all installdirs install-lib + $(INSTALL_DATA) README.$(NAME) $(docdir)/contrib -install: install_doc +installdirs: + $(mkinstalldirs) $(libdir) $(docdir)/contrib -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done +uninstall: uninstall-lib + rm -f $(docdir)/contrib/README.$(NAME) -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - -ifeq (depend,$(wildcard depend)) -include depend -endif +clean distclean maintainer-clean: clean-lib + rm -f $(OBJS) diff --git a/contrib/miscutil/Makefile b/contrib/miscutil/Makefile index 1faf78b0716..6ed5712bf4d 100644 --- a/contrib/miscutil/Makefile +++ b/contrib/miscutil/Makefile @@ -1,53 +1,38 @@ # -# $Header: /cvsroot/pgsql/contrib/miscutil/Attic/Makefile,v 1.11 2000/07/04 16:16:59 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/miscutil/Attic/Makefile,v 1.12 2000/07/09 13:13:20 petere Exp $ # -TOPDIR=../.. +subdir = contrib/miscutil +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global - -NAME = misc_utils - -PROGRAM = -OBJS = $(NAME).o -DOCS = README.$(NAME) -SQLS = $(NAME).sql -BINS = -EXAMPLES= -MODS = $(NAME)$(DLSUFFIX) +NAME := misc_utils +SONAME := $(NAME)$(DLSUFFIX) CFLAGS += -I. $(CFLAGS_SL) -OTHER_CLEAN = $(SQLS) +all: $(SONAME) $(NAME).sql -all: $(MODS) $(SQLS) +$(NAME).sql: $(NAME).sql.in + sed -e 's:MODULE_PATHNAME:$(libdir)/contrib/$(SONAME):g' < $< > $@ -%.sql: %.sql.in - $(SED) "s|MODULE_PATHNAME|$(CONTRIB_MODDIR)/$(@:.sql=$(DLSUFFIX))|" < $< > $@ +install: all installdirs + $(INSTALL_SHLIB) $(SONAME) $(libdir)/contrib + $(INSTALL_DATA) $(NAME).sql $(datadir)/contrib + $(INSTALL_DATA) README.$(NAME) $(docdir)/contrib -install: install_doc install_sql install_mod +installdirs: + $(mkinstalldirs) $(libdir)/contrib $(datadir)/contrib $(docdir)/contrib -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done +uninstall: + rm -f $(libdir)/contrib/$(SONAME) $(datadir)/contrib/$(NAME).sql $(docdir)/contrib/README.$(NAME) -install_sql: - for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ - done - -install_mod: - for inst_file in $(MODS); do \ - $(INSTALL) $(INSTL_SHLIB_OPTS) $$inst_file $(CONTRIB_MODDIR); \ - done +clean distclean maintainer-clean: + rm -f $(SONAME) $(NAME).sql depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif diff --git a/contrib/noupdate/Makefile b/contrib/noupdate/Makefile index ea8b48f2d21..65a6e06737b 100644 --- a/contrib/noupdate/Makefile +++ b/contrib/noupdate/Makefile @@ -1,53 +1,38 @@ # -# $Header: /cvsroot/pgsql/contrib/noupdate/Attic/Makefile,v 1.4 2000/07/04 16:17:03 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/noupdate/Attic/Makefile,v 1.5 2000/07/09 13:13:24 petere Exp $ # -TOPDIR=../.. +subdir = contrib/noupdate +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global - -NAME = noup - -PROGRAM = -OBJS = $(NAME).o -DOCS = README.$(NAME) -SQLS = $(NAME).sql -BINS = -EXAMPLES= -MODS = $(NAME)$(DLSUFFIX) +NAME := noup +SONAME := $(NAME)$(DLSUFFIX) CFLAGS += -I. $(CFLAGS_SL) -OTHER_CLEAN = $(SQLS) +all: $(SONAME) $(NAME).sql -all: $(MODS) $(SQLS) +$(NAME).sql: $(NAME).sql.in + sed -e 's:MODULE_PATHNAME:$(libdir)/contrib/$(SONAME):g' < $< > $@ -%.sql: %.sql.in - $(SED) "s|MODULE_PATHNAME|$(CONTRIB_MODDIR)/$(@:.sql=$(DLSUFFIX))|" < $< > $@ +install: all installdirs + $(INSTALL_SHLIB) $(SONAME) $(libdir)/contrib + $(INSTALL_DATA) $(NAME).sql $(datadir)/contrib + $(INSTALL_DATA) README.$(NAME) $(docdir)/contrib -install: install_doc install_sql install_mod +installdirs: + $(mkinstalldirs) $(libdir)/contrib $(datadir)/contrib $(docdir)/contrib -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done +uninstall: + rm -f $(libdir)/contrib/$(SONAME) $(datadir)/contrib/$(NAME).sql $(docdir)/contrib/README.$(NAME) -install_sql: - for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ - done - -install_mod: - for inst_file in $(MODS); do \ - $(INSTALL) $(INSTL_SHLIB_OPTS) $$inst_file $(CONTRIB_MODDIR); \ - done +clean distclean maintainer-clean: + rm -f $(SONAME) $(NAME).sql depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif diff --git a/contrib/pg_dumplo/Makefile b/contrib/pg_dumplo/Makefile index d981e380071..569339cbb6d 100644 --- a/contrib/pg_dumplo/Makefile +++ b/contrib/pg_dumplo/Makefile @@ -1,50 +1,35 @@ # -# $Header: /cvsroot/pgsql/contrib/pg_dumplo/Attic/Makefile,v 1.4 2000/06/19 13:54:01 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/pg_dumplo/Attic/Makefile,v 1.5 2000/07/09 13:13:24 petere Exp $ # -TOPDIR=../.. +subdir = contrib/pg_dumplo +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global - -NAME = pg_dumplo - -PROGRAM = $(NAME) OBJS = main.o lo_export.o lo_import.o utils.o -DOCS = README.$(NAME) -SQLS = -BINS = $(PROGRAM) -EXAMPLES= -MODS = - CFLAGS += -I$(LIBPQDIR) -OTHER_CLEAN = +all: pg_dumplo -all: $(PROGRAM) - -$(PROGRAM): $(OBJS) $(LIBPQDIR)/libpq.a +pg_dumplo: $(OBJS) $(LIBPQDIR)/libpq.a $(CC) $(CFLAGS) -o $@ $(OBJS) $(LIBPQ) -install: install_doc install_bin +install: all installdirs + $(INSTALL_PROGRAM) pg_dumplo$(X) $(bindir) + $(INSTALL_DATA) README.pg_dumplo $(docdir)/contrib -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done +installdirs: + $(mkinstalldirs) $(bindir) $(docdir)/contrib -install_bin: - for inst_file in $(BINS); do \ - $(INSTALL) $(INSTL_EXE_OPTS) $$inst_file $(CONTRIB_BINDIR); \ - done +uninstall: + rm -f $(bindir)/pg_dumplo$(X) $(docdir)/contrib/README.pg_dumplo + +clean distclean maintainer-clean: + rm -f pg_dumplo $(OBJS) depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif - - \ No newline at end of file diff --git a/contrib/pgbench/Makefile b/contrib/pgbench/Makefile index c9f7c3f2b22..8db147cce7d 100644 --- a/contrib/pgbench/Makefile +++ b/contrib/pgbench/Makefile @@ -1,48 +1,26 @@ # -# $Header: /cvsroot/pgsql/contrib/pgbench/Makefile,v 1.4 2000/06/19 13:54:09 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/pgbench/Makefile,v 1.5 2000/07/09 13:13:29 petere Exp $ # -TOPDIR=../.. +subdir = contrib/pgbench +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global +CFLAGS += -I$(LIBPQDIR) +LIBS += $(LIBPQ) -NAME = pgbench +all: pgbench -PROGRAM = $(NAME) -OBJS = $(NAME).o -DOCS = README.$(NAME) README.$(NAME)_jis -SQLS = -BINS = $(PROGRAM) -EXAMPLES= -MODS = +install: all installdirs + $(INSTALL_PROGRAM) pgbench$(X) $(bindir) + $(INSTALL_DATA) README.pgbench $(docdir)/contrib + $(INSTALL_DATA) README.pgbench_jis $(docdir)/contrib -CFLAGS += -I$(LIBPQDIR) +installdirs: + $(mkinstalldirs) $(bindir) $(docdir)/contrib -OTHER_CLEAN = +uninstall: + rm -f $(bindir)/pgbench$(X) $(docdir)/contrib/README.pgbench $(docdir)/contrib/README.pgbench_jis -all: $(PROGRAM) - -$(PROGRAM): $(OBJS) $(LIBPQDIR)/libpq.a - $(CC) $(CFLAGS) -o $@ $(OBJS) $(LIBPQ) - -install: install_doc install_bin - -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done - -install_bin: - for inst_file in $(BINS); do \ - $(INSTALL) $(INSTL_EXE_OPTS) $$inst_file $(CONTRIB_BINDIR); \ - done - -depend dep: - $(CC) -MM -MG $(CFLAGS) *.c > depend - -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - -ifeq (depend,$(wildcard depend)) -include depend -endif +clean distclean maintainer-clean: + rm -f pgbench$(X) diff --git a/contrib/soundex/Makefile b/contrib/soundex/Makefile index ffd64f49926..616b96c47ee 100644 --- a/contrib/soundex/Makefile +++ b/contrib/soundex/Makefile @@ -1,54 +1,38 @@ # -# $Header: /cvsroot/pgsql/contrib/soundex/Attic/Makefile,v 1.6 2000/07/04 16:17:08 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/soundex/Attic/Makefile,v 1.7 2000/07/09 13:13:33 petere Exp $ # -TOPDIR=../.. +subdir = contrib/soundex +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global - -NAME = soundex - -PROGRAM = -OBJS = $(NAME).o -DOCS = README.$(NAME) -SQLS = $(NAME).sql -BINS = -EXAMPLES= -MODS = $(NAME)$(DLSUFFIX) +NAME := soundex +SONAME := $(NAME)$(DLSUFFIX) CFLAGS += -I. $(CFLAGS_SL) -OTHER_CLEAN = $(SQLS) +all: $(SONAME) $(NAME).sql -all: $(MODS) $(SQLS) +$(NAME).sql: $(NAME).sql.in + sed -e 's:MODULE_PATHNAME:$(datadir)/contrib/$(SONAME):g' < $< > $@ +install: all installdirs + $(INSTALL_SHLIB) $(SONAME) $(libdir)/contrib + $(INSTALL_DATA) $(NAME).sql $(datadir)/contrib + $(INSTALL_DATA) README.$(NAME) $(docdir)/contrib -%.sql: %.sql.in - $(SED) "s|MODULE_PATHNAME|$(CONTRIB_MODDIR)/$(@:.sql=$(DLSUFFIX))|" < $< > $@ +installdirs: + $(mkinstalldirs) $(libdir)/contrib $(datadir)/contrib $(docdir)/contrib -install: install_doc install_sql install_mod +uninstall: + rm -f $(libdir)/contrib/$(SONAME) $(datadir)/contrib/$(NAME).sql $(docdir)/contrib/README.$(NAME) -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done - -install_sql: - for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ - done - -install_mod: - for inst_file in $(MODS); do \ - $(INSTALL) $(INSTL_SHLIB_OPTS) $$inst_file $(CONTRIB_MODDIR); \ - done +clean distclean maintainer-clean: + rm -f $(SONAME) $(NAME).sql depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif diff --git a/contrib/spi/Makefile b/contrib/spi/Makefile index 9a6ca052975..60bc2e6dbf3 100644 --- a/contrib/spi/Makefile +++ b/contrib/spi/Makefile @@ -1,19 +1,15 @@ # -# $Header: /cvsroot/pgsql/contrib/spi/Makefile,v 1.16 2000/07/04 16:17:11 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/spi/Makefile,v 1.17 2000/07/09 13:13:36 petere Exp $ # -TOPDIR=../.. +subdir = contrib/spi +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global - -NAME = - -PROGRAM = OBJS = autoinc.o insert_username.o moddatetime.o refint.o timetravel.o DOCS = README.spi SQLS = $(OBJS:.o=.sql) -BINS = -EXAMPLES= $(OBJS:.o=.example) new_example.example +EXAMPLES= $(OBJS:.o=.example) MODS = $(OBJS:.o=$(DLSUFFIX)) CFLAGS += -I. $(CFLAGS_SL) @@ -22,43 +18,36 @@ ifdef REFINT_VERBOSE CFLAGS+= -DREFINT_VERBOSE endif -OTHER_CLEAN = $(SQLS) - all: $(MODS) $(SQLS) %.sql: %.sql.in - $(SED) "s|MODULE_PATHNAME|$(CONTRIB_MODDIR)/$(@:.sql=$(DLSUFFIX))|" < $< > $@ + sed -e 's:MODULE_PATHNAME:$(libdir)/contrib/$(@:.sql=$(DLSUFFIX)):g' < $< > $@ -install: install_doc install_sql install_mod install_example - -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done - -install_sql: +install: all installdirs for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ + $(INSTALL_DATA) $$inst_file $(datadir)/contrib || exit; \ done - -install_mod: for inst_file in $(MODS); do \ - $(INSTALL) $(INSTL_SHLIB_OPTS) $$inst_file $(CONTRIB_MODDIR); \ + $(INSTALL_SHLIB) $$inst_file $(libdir)/contrib || exit; \ + done + for inst_file in $(EXAMPLES) README.spi; do \ + $(INSTALL_DATA) $$inst_file $(docdir)/contrib/spi || exit; \ done -install_example: - for inst_file in $(EXAMPLES); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_EXAMPLESDIR); \ - done +installdirs: + $(mkinstalldirs) $(datadir)/contrib $(libdir)/contrib $(docdir)/contrib/spi + +uninstall: + rm -f $(addprefix $(datadir)/contrib/, $(SQLS)) \ + $(addprefix $(libdir)/contrib/, $(MODS)) \ + $(addprefix $(docdir)/contrib/spi/, $(EXAMPLES) README.spi) + +clean distclean maintainer-clean: + rm -f $(MODS) $(SQLS) $(OBJS) depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif - - diff --git a/contrib/spi/new_example.sql b/contrib/spi/new_example.sql deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/contrib/statmath/Makefile b/contrib/statmath/Makefile index cafd36e2b43..e292c52e6ca 100644 --- a/contrib/statmath/Makefile +++ b/contrib/statmath/Makefile @@ -1,58 +1,38 @@ # -# $Header: /cvsroot/pgsql/contrib/statmath/Attic/Makefile,v 1.1 2000/07/04 14:36:03 wieck Exp $ +# $Header: /cvsroot/pgsql/contrib/statmath/Attic/Makefile,v 1.2 2000/07/09 13:13:41 petere Exp $ # -TOPDIR=../.. +subdir = contrib/statmath +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global - -NAME = statmath - -PROGRAM = -OBJS = $(NAME).o -DOCS = README.$(NAME) -SQLS = $(NAME).sql -BINS = -EXAMPLES= -MODS = $(NAME)$(DLSUFFIX) +NAME := statmath +SONAME := $(NAME)$(DLSUFFIX) CFLAGS += -I. $(CFLAGS_SL) -OTHER_CLEAN = $(SQLS) +all: $(SONAME) $(NAME).sql -all: $(MODS) $(SQLS) +$(NAME).sql: $(NAME).sql.in + sed -e 's:MODULE_PATHNAME:$(libdir)/contrib/$(SONAME):g' < $< > $@ -%.sql: %.sql.in - $(SED) "s|MODULE_PATHNAME|$(CONTRIB_MODDIR)/$(NAME)$(DLSUFFIX)|" < $< > $@ +install: all installdirs + $(INSTALL_SHLIB) $(SONAME) $(libdir)/contrib + $(INSTALL_DATA) $(NAME).sql $(datadir)/contrib + $(INSTALL_DATA) README.$(NAME) $(docdir)/contrib -install: install_doc install_sql install_mod install_bin +installdirs: + $(mkinstalldirs) $(libdir)/contrib $(datadir)/contrib $(docdir)/contrib -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done +uninstall: + rm -f $(libdir)/contrib/$(SONAME) $(datadir)/contrib/$(NAME).sql $(docdir)/contrib/README.$(NAME) -install_sql: - for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ - done - -install_mod: - for inst_file in $(MODS); do \ - $(INSTALL) $(INSTL_SHLIB_OPTS) $$inst_file $(CONTRIB_MODDIR); \ - done - -install_bin: - for inst_file in $(BINS); do \ - $(INSTALL) $(INSTL_EXE_OPTS) $$inst_file $(CONTRIB_BINDIR); \ - done +clean: + rm -f $(SONAME) $(NAME).sql depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif diff --git a/contrib/string/Makefile b/contrib/string/Makefile index ad80116e032..1b01e63afbf 100644 --- a/contrib/string/Makefile +++ b/contrib/string/Makefile @@ -1,54 +1,38 @@ # -# $Header: /cvsroot/pgsql/contrib/string/Attic/Makefile,v 1.11 2000/07/04 16:17:17 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/string/Attic/Makefile,v 1.12 2000/07/09 13:13:43 petere Exp $ # -TOPDIR=../.. +subdir = contrib/string +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global - -NAME = string_io - -PROGRAM = -OBJS = $(NAME).o -DOCS = README.$(NAME) -SQLS = $(NAME).sql -BINS = -EXAMPLES= -MODS = $(NAME)$(DLSUFFIX) +NAME := string_io +SONAME := $(NAME)$(DLSUFFIX) CFLAGS += -I. $(CFLAGS_SL) -OTHER_CLEAN = $(SQLS) - -all: $(MODS) $(SQLS) - +all: $(SONAME) $(NAME).sql %.sql: %.sql.in - $(SED) "s|MODULE_PATHNAME|$(CONTRIB_MODDIR)/$(@:.sql=$(DLSUFFIX))|" < $< > $@ + sed -e 's:MODULE_PATHNAME:$(libdir)/contrib/$(@:.sql=$(DLSUFFIX)):g' < $< > $@ -install: install_doc install_sql install_mod +install: all installdirs + $(INSTALL_SHLIB) $(SONAME) $(libdir)/contrib + $(INSTALL_DATA) $(NAME).sql $(datadir)/contrib + $(INSTALL_DATA) README.$(NAME) $(docdir)/contrib -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done +installdirs: + $(mkinstalldirs) $(libdir)/contrib $(datadir)/contrib $(docdir)/contrib -install_sql: - for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ - done +uninstall: + rm -f $(libdir)/contrib/$(SONAME) $(datadir)/contrib/$(NAME).sql $(docdir)/contrib/README.$(NAME) -install_mod: - for inst_file in $(MODS); do \ - $(INSTALL) $(INSTL_SHLIB_OPTS) $$inst_file $(CONTRIB_MODDIR); \ - done +clean distclean maintainer-clean: + rm -f $(SONAME) $(NAME).sql depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif diff --git a/contrib/tips/Makefile b/contrib/tips/Makefile index 54d5e19f280..d14514b482e 100644 --- a/contrib/tips/Makefile +++ b/contrib/tips/Makefile @@ -1,31 +1,18 @@ # -# $Header: /cvsroot/pgsql/contrib/tips/Attic/Makefile,v 1.3 2000/06/19 13:54:31 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/tips/Attic/Makefile,v 1.4 2000/07/09 13:13:43 petere Exp $ # -TOPDIR=../.. +subdir = contrib/tips +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global +all: -NAME = +install: installdirs + $(INSTALL_DATA) README.apachelog $(docdir)/contrib -PROGRAM = -OBJS = -DOCS = README.apachelog -SQLS = -BINS = -EXAMPLES= -MODS = - -all:: - -install: install_doc - -install_doc: - $(TOPDIR)/config/mkinstalldirs $(CONTRIB_DOCDIR)/tips - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR)/tips; \ - done - -clean: - $(RM) *~ +installdirs: + $(mkinstalldirs) $(docdir)/contrib +uninstall: + rm -f $(docdir)/contrib/README.apachelog diff --git a/contrib/tools/Makefile b/contrib/tools/Makefile deleted file mode 100644 index ecf8ac3167b..00000000000 --- a/contrib/tools/Makefile +++ /dev/null @@ -1,21 +0,0 @@ -# -# $Header: /cvsroot/pgsql/contrib/tools/Attic/Makefile,v 1.3 2000/06/19 13:54:37 momjian Exp $ -# - -TOPDIR=../.. - -include ../Makefile.global - -NAME = - -PROGRAM = -OBJS = -DOCS = -SQLS = -BINS = -EXAMPLES= -MODS = - -clean: - $(RM) *~ - diff --git a/contrib/unixdate/Makefile b/contrib/unixdate/Makefile index 137f15493ce..828ed9579cc 100644 --- a/contrib/unixdate/Makefile +++ b/contrib/unixdate/Makefile @@ -1,30 +1,18 @@ # -# $Header: /cvsroot/pgsql/contrib/unixdate/Attic/Makefile,v 1.2 2000/06/19 13:54:38 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/unixdate/Attic/Makefile,v 1.3 2000/07/09 13:13:50 petere Exp $ # -TOPDIR=../.. +subdir = contrib/unixdate +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global +all: -NAME = unixdate +install: installdirs + $(INSTALL_DATA) unixdate.sql $(datadir)/contrib -PROGRAM = -OBJS = -DOCS = -SQLS = $(NAME).sql -BINS = -EXAMPLES= -MODS = - -all:: - -install: install_sql - -install_sql: - for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ - done - -clean: - $(RM) *~ +uninstall: + rm -f $(datadir)/contrib/unixdate.sql +installdirs: + $(mkinstalldirs) $(datadir)/contrib diff --git a/contrib/userlock/Makefile b/contrib/userlock/Makefile index d68315a70d9..7c262087c9e 100644 --- a/contrib/userlock/Makefile +++ b/contrib/userlock/Makefile @@ -1,53 +1,38 @@ # -# $Header: /cvsroot/pgsql/contrib/userlock/Attic/Makefile,v 1.11 2000/07/04 16:17:21 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/userlock/Attic/Makefile,v 1.12 2000/07/09 13:13:52 petere Exp $ # -TOPDIR=../.. +subdir = contrib/userlock +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global - -NAME = user_locks - -PROGRAM = -OBJS = $(NAME).o -DOCS = README.$(NAME) -SQLS = $(NAME).sql -BINS = -EXAMPLES= -MODS = $(NAME)$(DLSUFFIX) +NAME := user_locks +SONAME := $(NAME)$(DLSUFFIX) CFLAGS += -I. $(CFLAGS_SL) -OTHER_CLEAN = $(SQLS) - -all: $(MODS) $(SQLS) +all: $(SONAME) $(NAME).sql %.sql: %.sql.in - $(SED) "s|MODULE_PATHNAME|$(CONTRIB_MODDIR)/$(@:.sql=$(DLSUFFIX))|" < $< > $@ + sed -e 's:MODULE_PATHNAME:$(libdir)/contrib/$(@:.sql=$(DLSUFFIX)):g' < $< > $@ -install: install_doc install_sql install_mod +install: all installdirs + $(INSTALL_SHLIB) $(SONAME) $(libdir)/contrib + $(INSTALL_DATA) $(NAME).sql $(datadir)/contrib + $(INSTALL_DATA) README.$(NAME) $(docdir)/contrib -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done +installdirs: + $(mkinstalldirs) $(libdir)/contrib $(datadir)/contrib $(docdir)/contrib -install_sql: - for inst_file in $(SQLS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_SQLDIR); \ - done +uninstall: + rm -rf $(libdir)/contrib/$(SONAME) $(datadir)/contrib/$(NAME).sql $(docdir)/contrib/README.$(NAME) -install_mod: - for inst_file in $(MODS); do \ - $(INSTALL) $(INSTL_SHLIB_OPTS) $$inst_file $(CONTRIB_MODDIR); \ - done +clean distclean maintainer-clean: + rm -f $(SONAME) $(NAME).sql depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif diff --git a/contrib/vacuumlo/Makefile b/contrib/vacuumlo/Makefile index 2c56e542fcd..fefa2ef41e0 100644 --- a/contrib/vacuumlo/Makefile +++ b/contrib/vacuumlo/Makefile @@ -1,48 +1,32 @@ # -# $Header: /cvsroot/pgsql/contrib/vacuumlo/Makefile,v 1.5 2000/06/19 13:54:50 momjian Exp $ +# $Header: /cvsroot/pgsql/contrib/vacuumlo/Makefile,v 1.6 2000/07/09 13:13:55 petere Exp $ # -TOPDIR=../.. +subdir = contrib/vacuumlo +top_builddir = ../.. +include ../../src/Makefile.global -include ../Makefile.global +CPPFLAGS += -I$(LIBPQDIR) +LIBS += $(LIBPQ) -NAME = vacuumlo +all: vacuumlo -PROGRAM = $(NAME) -OBJS = $(NAME).o -DOCS = README.$(NAME) -SQLS = -BINS = $(PROGRAM) -EXAMPLES= -MODS = +install: all installdirs + $(INSTALL_PROGRAM) vacuumlo$(X) $(bindir) + $(INSTALL_DATA) README.vacuumlo $(docdir)/contrib -CFLAGS += -I$(LIBPQDIR) +installdirs: + $(mkinstalldirs) $(bindir) $(docdir)/contrib -OTHER_CLEAN = +uninstall: + rm -f $(bindir)/vacuumlo$(X) $(docdir)/contrib/README.vacuumlo -all: $(PROGRAM) - -$(PROGRAM): $(OBJS) $(LIBPGEASYDIR)/libpgeasy.a - $(CC) $(CFLAGS) -o $@ $(OBJS) $(LIBPGEASY) - -install: install_doc install_bin - -install_doc: - for inst_file in $(DOCS); do \ - $(INSTALL) $(INSTL_LIB_OPTS) $$inst_file $(CONTRIB_DOCDIR); \ - done - -install_bin: - for inst_file in $(BINS); do \ - $(INSTALL) $(INSTL_EXE_OPTS) $$inst_file $(CONTRIB_BINDIR); \ - done +clean distclean maintainer-clean: + rm -f vacuumlo$(X) depend dep: $(CC) -MM -MG $(CFLAGS) *.c > depend -clean: - $(RM) *~ $(OBJS) $(MODS) $(PROGRAM) depend $(OTHER_CLEAN) core log - ifeq (depend,$(wildcard depend)) include depend endif diff --git a/doc/Makefile b/doc/Makefile index 55d0a746299..6dfdb97dade 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -8,7 +8,7 @@ # # # IDENTIFICATION -# $Header: /cvsroot/pgsql/doc/Makefile,v 1.15 2000/05/17 16:57:40 momjian Exp $ +# $Header: /cvsroot/pgsql/doc/Makefile,v 1.16 2000/07/09 13:13:55 petere Exp $ # #---------------------------------------------------------------------------- @@ -16,7 +16,6 @@ PGDOCS= $(POSTGRESDIR)/doc SRCDIR= ../src TAR= tar -GZCAT= zcat # Pick up Makefile.global from the source area # This is the only resource from the code source area and is optional. @@ -58,7 +57,7 @@ distclean:: man:: -@if test ! -d $(POSTMANDIR) ; then mkdir $(POSTMANDIR) ; fi - $(GZCAT) man.tar.gz | (cd $(POSTMANDIR) ; $(TAR) xf - ) + gunzip -c man.tar.gz | (cd $(POSTMANDIR) ; $(TAR) xf - ) # # Generic production rules @@ -75,5 +74,5 @@ man:: %: %.tar.gz rm -rf ./$@ $(PGDOCS)/$* if test ! -d $(PGDOCS)/$* ; then mkdir $(PGDOCS)/$* ; fi - $(GZCAT) $< | (cd $(PGDOCS)/$* ; $(TAR) xf - ) + gunzip -c $< | (cd $(PGDOCS)/$* ; $(TAR) xf - ) # touch ./$* diff --git a/src/Makefile.global.in b/src/Makefile.global.in index cf766b08b61..2c3e85f2d5c 100644 --- a/src/Makefile.global.in +++ b/src/Makefile.global.in @@ -7,7 +7,7 @@ # # # IDENTIFICATION -# $Header: /cvsroot/pgsql/src/Makefile.global.in,v 1.85 2000/07/02 15:20:41 petere Exp $ +# $Header: /cvsroot/pgsql/src/Makefile.global.in,v 1.86 2000/07/09 13:13:59 petere Exp $ # # NOTES # Essentially all Postgres make files include this file and use the @@ -38,17 +38,23 @@ # PostgreSQL version number VERSION = @VERSION@ +ifndef top_builddir +top_builddir = $(SRCDIR)/.. +endif + ifndef SRCDIR +SRCDIR = $(top_builddir)/src +endif + # This should be changed once we have separate build dirs. top_srcdir = $(top_builddir) + ifeq ($(top_builddir), $(top_srcdir)) srcdir = . else srcdir = $(top_srcdir)/$(subdir) endif VPATH = $(srcdir) -SRCDIR = $(top_builddir)/src -endif ############################################################################## # @@ -88,7 +94,9 @@ sharedstatedir = @sharedstatedir@ localstatedir = @localstatedir@ libdir = @libdir@ includedir = @includedir@ +mandir = @mandir@ +docdir = ${prefix}/doc odbcinst_ini_dir = @odbcinst_ini_dir@ # old variable names for installation directories @@ -97,8 +105,8 @@ POSTGRESDIR= $(prefix) BINDIR= $(bindir) LIBDIR= $(libdir) TEMPLATEDIR= $(libdir) -POSTMANDIR= $(POSTGRESDIR)/man -POSTDOCDIR= $(POSTGRESDIR)/doc +POSTMANDIR= $(mandir) +POSTDOCDIR= $(docdir) HEADERDIR= $(includedir) @@ -126,6 +134,8 @@ PYTHON = @PYTHON@ python_extmakefile = @python_extmakefile@ python_moduledir = @python_moduledir@ +krb_srvtab = @krb_srvtab@ + # # Please do not edit USE_TCL and USE_TK by hand. # @@ -156,12 +166,6 @@ INSTALL_SHLIB = @INSTALL_SHLIB@ mkinstalldirs = @mkinstalldirs@ -# don't use these any more -INSTLOPTS= @INSTLOPTS@ -INSTL_EXE_OPTS= @INSTL_EXE_OPTS@ -INSTL_LIB_OPTS= @INSTL_LIB_OPTS@ -INSTL_SHLIB_OPTS= @INSTL_SHLIB_OPTS@ - RANLIB= @RANLIB@ #------------------------------------------------------------- @@ -184,11 +188,11 @@ LDOUT= -o DLSUFFIX= @DLSUFFIX@ LN_S= @LN_S@ TAR= @tar@ -GZCAT= @GZCAT@ PERL = @PERL@ AWK = @AWK@ CXX=@CXX@ CXXFLAGS=@CXXFLAGS@ @INCLUDES@ +GCC = @GCC@ ############################################################################## @@ -259,12 +263,6 @@ ifneq ($(CUSTOM_COPT),) COPT= $(CUSTOM_COPT) endif -GCC = @GCC@ - -ifeq ($(GCC), yes) -CFLAGS+= -Wall -Wmissing-prototypes -Wmissing-declarations -endif - ifdef COPT CFLAGS+= $(COPT) LDFLAGS+= $(COPT) @@ -284,3 +282,4 @@ SNPRINTF = @SNPRINTF@ STRDUP = @STRDUP@ .PHONY: all install installdirs uninstall dep depend clean distclean maintainer-clean +.SILENT: installdirs diff --git a/src/backend/libpq/Makefile b/src/backend/libpq/Makefile index 8712a61bb91..f4ce69d9c92 100644 --- a/src/backend/libpq/Makefile +++ b/src/backend/libpq/Makefile @@ -4,11 +4,12 @@ # Makefile for libpq subsystem (backend half of libpq interface) # # IDENTIFICATION -# $Header: /cvsroot/pgsql/src/backend/libpq/Makefile,v 1.21 2000/07/08 03:04:39 tgl Exp $ +# $Header: /cvsroot/pgsql/src/backend/libpq/Makefile,v 1.22 2000/07/09 13:14:05 petere Exp $ # #------------------------------------------------------------------------- -SRCDIR = ../.. +subdir = src/backend/libpq +top_builddir = ../.. include ../../Makefile.global # be-fsstubs is here for historical reasons, probably belongs elsewhere @@ -17,6 +18,12 @@ OBJS = be-fsstubs.o \ auth.o crypt.o hba.o password.o \ pqcomm.o pqformat.o pqpacket.o pqsignal.o util.o +# This location might depend on the installation directories. Therefore +# we can't subsitute it into config.h. +ifdef krb_srvtab +CPPFLAGS += -DPG_KRB_SRVTAB='"$(krb_srvtab)"' +endif + all: SUBSYS.o diff --git a/src/backend/postmaster/postmaster.c b/src/backend/postmaster/postmaster.c index c20ddbd1ec4..580786c2e69 100644 --- a/src/backend/postmaster/postmaster.c +++ b/src/backend/postmaster/postmaster.c @@ -11,7 +11,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.153 2000/07/08 03:04:13 tgl Exp $ + * $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.154 2000/07/09 13:14:05 petere Exp $ * * NOTES * @@ -86,11 +86,6 @@ #include "utils/exc.h" #include "utils/guc.h" -/* - * "postmaster.opts" is a file containing options for postmaser. - * pg_ctl will use it to restart postmaster. - */ -#define OPTSFNAME "postmaster.opts" #if !defined(MAXINT) #define MAXINT INT_MAX @@ -246,7 +241,7 @@ extern int optind, /* * postmaster.c - function prototypes */ -static void pmdaemonize(char *extraoptions); +static void pmdaemonize(int argc, char *argv[]); static Port *ConnCreate(int serverFd); static void ConnFree(Port *port); static void reset_shared(int port); @@ -267,15 +262,7 @@ static long PostmasterRandom(void); static void RandomSalt(char *salt); static void SignalChildren(SIGNAL_ARGS); static int CountChildren(void); -static int -SetOptsFile(char *progname, int port, char *datadir, - int assert, int nbuf, - int debuglvl, int netserver, -#ifdef USE_SSL - int securenetserver, -#endif - int maxbackends, int reinit, - int silent, int sendstop, char *extraoptions); +static bool CreateOptsFile(int argc, char *argv[]); extern int BootstrapMain(int argc, char *argv[]); static pid_t SSDataBase(bool startup); @@ -564,8 +551,8 @@ PostmasterMain(int argc, char *argv[]) #ifdef USE_SSL if (!NetServer && SecureNetServer) { - fprintf(stderr, "For SSL, you must enable TCP/IP connections.\n", - argv[0]); + fprintf(stderr, "%s: For SSL, you must enable TCP/IP connections.\n", + progname); exit(1); } InitSSL(); @@ -602,7 +589,7 @@ PostmasterMain(int argc, char *argv[]) PortList = DLNewList(); if (silentflag) - pmdaemonize(original_extraoptions); + pmdaemonize(argc, argv); else { @@ -612,26 +599,7 @@ PostmasterMain(int argc, char *argv[]) SetPidFname(DataDir); if (SetPidFile(getpid()) == 0) { - if (SetOptsFile( - progname, /* postmaster executable file */ - PostPortName, /* port number */ - DataDir, /* PGDATA */ - assert_enabled, /* whether -A is specified - * or not */ - NBuffers, /* -B: number of shared buffers */ - DebugLvl, /* -d: debug level */ - NetServer, /* -i: accept connection from INET */ -#ifdef USE_SSL - SecureNetServer, /* -l: use SSL */ -#endif - MaxBackends, /* -N: max number of - * backends */ - Reinit, /* -n: reinit shared mem after - * failure */ - silentflag, /* -S: detach tty */ - SendStop, /* -s: send SIGSTOP */ - original_extraoptions /* options for backend */ - ) != 0) + if (!CreateOptsFile(argc, argv)) { UnlinkPidFile(); ExitPostmaster(1); @@ -678,7 +646,7 @@ PostmasterMain(int argc, char *argv[]) } static void -pmdaemonize(char *extraoptions) +pmdaemonize(int argc, char *argv[]) { int i; pid_t pid; @@ -700,26 +668,7 @@ pmdaemonize(char *extraoptions) */ if (SetPidFile(pid) == 0) { - if (SetOptsFile( - progname, /* postmaster executable file */ - PostPortName, /* port number */ - DataDir, /* PGDATA */ - assert_enabled, /* whether -A is specified - * or not */ - NBuffers, /* -B: number of shared buffers */ - DebugLvl, /* -d: debug level */ - NetServer, /* -i: accept connection from INET */ -#ifdef USE_SSL - SecureNetServer, /* -l: use SSL */ -#endif - MaxBackends, /* -N: max number of - * backends */ - Reinit, /* -n: reinit shared mem after - * failure */ - 1, /* -S: detach tty */ - SendStop, /* -s: send SIGSTOP */ - extraoptions /* options for backend */ - ) != 0) + if (!CreateOptsFile(argc, argv)) { /* @@ -2202,84 +2151,44 @@ SSDataBase(bool startup) return (pid); } + /* * Create the opts file */ -static int -SetOptsFile(char *progname, int port, char *datadir, - int assert, int nbuf, - int debuglvl, int netserver, -#ifdef USE_SSL - int securenetserver, -#endif - int maxbackends, int reinit, - int silent, int sendstop, char *extraoptions) +static bool +CreateOptsFile(int argc, char *argv[]) { - int fd; - char optsfile[MAXPGPATH]; - char opts[1024]; - char buf[1024]; + char fullprogname[MAXPGPATH]; + char *filename; + FILE *fp; + unsigned i; - /* - * Creating opts file - */ - snprintf(optsfile, sizeof(optsfile), "%s/%s", datadir, OPTSFNAME); - fd = open(optsfile, O_RDWR | O_TRUNC | O_CREAT, 0600); - if (fd < 0) + if (FindExec(fullprogname, argv[0], "postmaster") == -1) + return false; + + filename = palloc(strlen(DataDir) + 20); + sprintf(filename, "%s/postmaster.opts", DataDir); + + fp = fopen(filename, "w"); + if (fp == NULL) { - fprintf(stderr, "Can't create optsfile:%s", optsfile); - return (-1); - } - snprintf(opts, sizeof(opts), "%s\n-p %d\n-D %s\n", progname, port, datadir); - if (assert) - { - sprintf(buf, "-A %d\n", assert); - strcat(opts, buf); + fprintf(stderr, "%s: cannot create file %s: %s\n", progname, + filename, strerror(errno)); + return false; } - snprintf(buf, sizeof(buf), "-B %d\n", nbuf); - strcat(opts, buf); + fprintf(fp, "%s", fullprogname); + for (i = 1; i < argc; i++) + fprintf(fp, " '%s'", argv[i]); + fputs("\n", fp); - if (debuglvl) + if (ferror(fp)) { - sprintf(buf, "-d %d\n", debuglvl); - strcat(opts, buf); + fprintf(stderr, "%s: writing file %s failed\n", progname, filename); + fclose(fp); + return false; } - if (netserver) - strcat(opts, "-i\n"); - -#ifdef USE_SSL - if (securenetserver) - strcat(opts, "-l\n"); -#endif - - snprintf(buf, sizeof(buf), "-N %d\n", maxbackends); - strcat(opts, buf); - - if (!reinit) - strcat(opts, "-n\n"); - - if (silent) - strcat(opts, "-S\n"); - - if (sendstop) - strcat(opts, "-s\n"); - - if (strlen(extraoptions) > 0) - { - strcat(opts, "-o '"); - strcat(opts, extraoptions); - strcat(opts, "'"); - } - - if (write(fd, opts, strlen(opts)) != strlen(opts)) - { - perror("Writing to opts file failed"); - close(fd); - return (-1); - } - close(fd); - - return (0); + fclose(fp); + return true; } diff --git a/src/backend/utils/init/findbe.c b/src/backend/utils/init/findbe.c index be9f2647d25..4568e76de54 100644 --- a/src/backend/utils/init/findbe.c +++ b/src/backend/utils/init/findbe.c @@ -7,7 +7,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/utils/init/Attic/findbe.c,v 1.18 2000/06/08 22:37:33 momjian Exp $ + * $Header: /cvsroot/pgsql/src/backend/utils/init/Attic/findbe.c,v 1.19 2000/07/09 13:14:08 petere Exp $ * *------------------------------------------------------------------------- */ @@ -151,7 +151,7 @@ ValidateBinary(char *path) * we change directories to the /data directory. */ int -FindExec(char *full_path, char *argv0, char *binary_name) +FindExec(char *full_path, const char *argv0, const char *binary_name) { char buf[MAXPGPATH + 2]; char *p; diff --git a/src/backend/utils/misc/ps_status.c b/src/backend/utils/misc/ps_status.c index edc82f35218..75d9f8802c7 100644 --- a/src/backend/utils/misc/ps_status.c +++ b/src/backend/utils/misc/ps_status.c @@ -5,7 +5,7 @@ * to contain some useful information. Differs wildly across * platforms. * - * $Header: /cvsroot/pgsql/src/backend/utils/misc/ps_status.c,v 1.1 2000/06/04 01:44:34 petere Exp $ + * $Header: /cvsroot/pgsql/src/backend/utils/misc/ps_status.c,v 1.2 2000/07/09 13:14:11 petere Exp $ * * Copyright 2000 by PostgreSQL Global Development Group * various details abducted from various places @@ -20,11 +20,9 @@ #ifdef HAVE_SYS_PSTAT_H # include /* for HP-UX */ #endif -#ifdef HAVE_MACHINE_VMPARAM_H +#ifdef HAVE_PS_STRINGS # include /* for old BSD */ -#endif -#ifdef HAVE_SYS_EXEC_H -# include /* for old BSD */ +# include #endif #include "miscadmin.h" diff --git a/src/include/config.h.in b/src/include/config.h.in index 2c2f5e4482c..25e8be291ff 100644 --- a/src/include/config.h.in +++ b/src/include/config.h.in @@ -8,7 +8,7 @@ * or in config.h afterwards. Of course, if you edit config.h, then your * changes will be overwritten the next time you run configure. * - * $Id: config.h.in,v 1.123 2000/07/05 17:44:29 scrappy Exp $ + * $Id: config.h.in,v 1.124 2000/07/09 13:14:13 petere Exp $ */ #ifndef CONFIG_H @@ -58,8 +58,8 @@ /* Kerberos name of the Postgres service principal (--with-krb-srvnam=NAME) */ #undef PG_KRB_SRVNAM -/* Location of the Kerberos server's keytab file (--with-krb-srvtab=FILE) */ -#undef PG_KRB_SRVTAB +/* Define to build with (Open)SSL support (--with-openssl[=DIR]) */ +#undef USE_SSL /* * DEF_PGPORT is the TCP port number on which the Postmaster listens and diff --git a/src/include/miscadmin.h b/src/include/miscadmin.h index 59269216ea7..7bc96c9f76f 100644 --- a/src/include/miscadmin.h +++ b/src/include/miscadmin.h @@ -12,7 +12,7 @@ * Portions Copyright (c) 1996-2000, PostgreSQL, Inc * Portions Copyright (c) 1994, Regents of the University of California * - * $Id: miscadmin.h,v 1.62 2000/07/02 15:21:18 petere Exp $ + * $Id: miscadmin.h,v 1.63 2000/07/09 13:14:13 petere Exp $ * * NOTES * some of the information in this file will be moved to @@ -133,7 +133,7 @@ extern char *getpgusername(void); extern void SetPgUserName(void); extern int GetUserId(void); extern void SetUserId(void); -extern int FindExec(char *backend, char *argv0, char *binary_name); +extern int FindExec(char *full_path, const char *argv0, const char *binary_name); extern int CheckPathAccess(char *path, char *name, int open_mode); /* lower case version for case-insensitive SQL referenced in pg_proc.h */ diff --git a/src/interfaces/libpq/fe-connect.c b/src/interfaces/libpq/fe-connect.c index e1af29a1b28..c232256f608 100644 --- a/src/interfaces/libpq/fe-connect.c +++ b/src/interfaces/libpq/fe-connect.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.130 2000/06/14 18:17:58 petere Exp $ + * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.131 2000/07/09 13:14:17 petere Exp $ * *------------------------------------------------------------------------- */ @@ -795,7 +795,7 @@ connectDBStart(PGconn *conn) np.protoVersion = htonl(NEGOTIATE_SSL_CODE); if (pqPacketSend(conn, (char *) &np, sizeof(StartupPacket)) != STATUS_OK) { - sprintf(conn->errorMessage, + printfPQExpBuffer(&conn->errorMessage, "connectDB() -- couldn't send SSL negotiation packet: errno=%d\n%s\n", errno, strerror(errno)); goto connect_errReturn; @@ -803,7 +803,7 @@ connectDBStart(PGconn *conn) /* Now receive the postmasters response */ if (recv(conn->sock, &SSLok, 1, 0) != 1) { - sprintf(conn->errorMessage, "PQconnectDB() -- couldn't read postmaster response: errno=%d\n%s\n", + printfPQExpBuffer(&conn->errorMessage, "PQconnectDB() -- couldn't read postmaster response: errno=%d\n%s\n", errno, strerror(errno)); goto connect_errReturn; } @@ -816,7 +816,7 @@ connectDBStart(PGconn *conn) SSL_context = SSL_CTX_new(SSLv23_method()); if (!SSL_context) { - sprintf(conn->errorMessage, + printfPQExpBuffer(&conn->errorMessage, "connectDB() -- couldn't create SSL context: %s\n", ERR_reason_error_string(ERR_get_error())); goto connect_errReturn; @@ -826,7 +826,7 @@ connectDBStart(PGconn *conn) !SSL_set_fd(conn->ssl, conn->sock) || SSL_connect(conn->ssl) <= 0) { - sprintf(conn->errorMessage, + printfPQExpBuffer(&conn->errorMessage, "connectDB() -- couldn't establish SSL connection: %s\n", ERR_reason_error_string(ERR_get_error())); goto connect_errReturn; @@ -844,7 +844,7 @@ connectDBStart(PGconn *conn) } else if (SSLok != 'N') { - strcpy(conn->errorMessage, + printfPQExpBuffer(&conn->errorMessage, "Received invalid negotiation response.\n"); goto connect_errReturn; } diff --git a/src/test/regress/run_check.sh b/src/test/regress/run_check.sh index d057d35264f..0a3b2347080 100755 --- a/src/test/regress/run_check.sh +++ b/src/test/regress/run_check.sh @@ -1,6 +1,6 @@ #!/bin/sh # -# $Header: /cvsroot/pgsql/src/test/regress/Attic/run_check.sh,v 1.21 2000/07/06 21:33:45 petere Exp $ +# $Header: /cvsroot/pgsql/src/test/regress/Attic/run_check.sh,v 1.22 2000/07/09 13:14:19 petere Exp $ # ---------- # Check call syntax @@ -187,7 +187,7 @@ export PATH # Run initdb to initialize a database system in ./tmp_check # ---------- echo "=============== Initializing check database instance ================" -initdb -D $PGDATA --noclean >$LOGDIR/initdb.log 2>&1 +initdb -D $PGDATA -L $CHKDIR/share --noclean >$LOGDIR/initdb.log 2>&1 if [ $? -ne 0 ] then