X-Git-Url: http://git.osdn.net/view?a=blobdiff_plain;f=configure;h=9b8cb48931da9d7f0ab42625c9eb6806b0718c52;hb=c6ef13937652850267e5422213af67144f4b5e1d;hp=3c14036723f073f421c3572c642943cb9f2ae066;hpb=1084f317702e1a039696ab8a37caf900e55ec8f2;p=pg-rex%2Fsyncrep.git diff --git a/configure b/configure index 3c14036723..9b8cb48931 100755 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.63 for PostgreSQL 9.0beta3. +# Generated by GNU Autoconf 2.63 for PostgreSQL 9.2devel. # # Report bugs to . # @@ -9,7 +9,7 @@ # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. # -# Copyright (c) 1996-2010, PostgreSQL Global Development Group +# Copyright (c) 1996-2011, PostgreSQL Global Development Group ## --------------------- ## ## M4sh Initialization. ## ## --------------------- ## @@ -598,8 +598,8 @@ SHELL=${CONFIG_SHELL-/bin/sh} # Identity of this package. PACKAGE_NAME='PostgreSQL' PACKAGE_TARNAME='postgresql' -PACKAGE_VERSION='9.0beta3' -PACKAGE_STRING='PostgreSQL 9.0beta3' +PACKAGE_VERSION='9.2devel' +PACKAGE_STRING='PostgreSQL 9.2devel' PACKAGE_BUGREPORT='pgsql-bugs@postgresql.org' ac_unique_file="src/backend/access/common/heaptuple.c" @@ -667,6 +667,7 @@ PTHREAD_CFLAGS PTHREAD_LIBS PTHREAD_CC acx_pthread_config +have_win32_dbghelp HAVE_IPV6 LIBOBJS OSSP_UUID_LIBS @@ -714,6 +715,7 @@ with_libxslt with_libxml XML2_CONFIG with_ossp_uuid +with_selinux with_openssl with_bonjour with_ldap @@ -836,6 +838,7 @@ with_pam with_ldap with_bonjour with_openssl +with_selinux with_readline with_libedit_preferred with_ossp_uuid @@ -1412,7 +1415,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures PostgreSQL 9.0beta3 to adapt to many kinds of systems. +\`configure' configures PostgreSQL 9.2devel to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1477,7 +1480,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of PostgreSQL 9.0beta3:";; + short | recursive ) echo "Configuration of PostgreSQL 9.2devel:";; esac cat <<\_ACEOF @@ -1532,11 +1535,11 @@ Optional Packages: --with-ldap build with LDAP support --with-bonjour build with Bonjour support --with-openssl build with OpenSSL support + --with-selinux build with SELinux support --without-readline do not use GNU Readline nor BSD Libedit for editing --with-libedit-preferred prefer BSD Libedit over GNU Readline - --with-ossp-uuid use OSSP UUID library when building - contrib/uuid-ossp + --with-ossp-uuid build contrib/uuid-ossp, requires OSSP UUID library --with-libxml build with XML support --with-libxslt use XSLT support when building contrib/xml2 --with-system-tzdata=DIR @@ -1624,7 +1627,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -PostgreSQL configure 9.0beta3 +PostgreSQL configure 9.2devel generated by GNU Autoconf 2.63 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -1632,7 +1635,7 @@ Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. -Copyright (c) 1996-2010, PostgreSQL Global Development Group +Copyright (c) 1996-2011, PostgreSQL Global Development Group _ACEOF exit fi @@ -1640,7 +1643,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by PostgreSQL $as_me 9.0beta3, which was +It was created by PostgreSQL $as_me 9.2devel, which was generated by GNU Autoconf 2.63. Invocation command line was $ $0 $@ @@ -2190,6 +2193,7 @@ case $host_os in bsdi*) template=bsdi ;; cygwin*) template=cygwin ;; darwin*) template=darwin ;; +dragonfly*) template=netbsd ;; dgux*) template=dgux ;; freebsd*) template=freebsd ;; hpux*) template=hpux ;; @@ -3999,10 +4003,15 @@ fi if test "$GCC" = yes -a "$ICC" = no; then CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith" # These work in some but not all gcc versions - { $as_echo "$as_me:$LINENO: checking if $CC supports -Wdeclaration-after-statement" >&5 -$as_echo_n "checking if $CC supports -Wdeclaration-after-statement... " >&6; } -pgac_save_CFLAGS=$CFLAGS + { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wdeclaration-after-statement" >&5 +$as_echo_n "checking whether $CC supports -Wdeclaration-after-statement... " >&6; } +if test "${pgac_cv_prog_cc_cflags__Wdeclaration_after_statement+set}" = set; then + $as_echo_n "(cached) " >&6 +else + pgac_save_CFLAGS=$CFLAGS CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement" +ac_save_c_werror_flag=$ac_c_werror_flag +ac_c_werror_flag=yes cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF @@ -4036,23 +4045,33 @@ $as_echo "$ac_try_echo") >&5 test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } + pgac_cv_prog_cc_cflags__Wdeclaration_after_statement=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - CFLAGS="$pgac_save_CFLAGS" - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + pgac_cv_prog_cc_cflags__Wdeclaration_after_statement=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_c_werror_flag=$ac_save_c_werror_flag +CFLAGS="$pgac_save_CFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" >&5 +$as_echo "$pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" >&6; } +if test x"$pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" = x"yes"; then + CFLAGS="$CFLAGS -Wdeclaration-after-statement" +fi - { $as_echo "$as_me:$LINENO: checking if $CC supports -Wendif-labels" >&5 -$as_echo_n "checking if $CC supports -Wendif-labels... " >&6; } -pgac_save_CFLAGS=$CFLAGS + { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wendif-labels" >&5 +$as_echo_n "checking whether $CC supports -Wendif-labels... " >&6; } +if test "${pgac_cv_prog_cc_cflags__Wendif_labels+set}" = set; then + $as_echo_n "(cached) " >&6 +else + pgac_save_CFLAGS=$CFLAGS CFLAGS="$pgac_save_CFLAGS -Wendif-labels" +ac_save_c_werror_flag=$ac_c_werror_flag +ac_c_werror_flag=yes cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF @@ -4086,24 +4105,95 @@ $as_echo "$ac_try_echo") >&5 test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } + pgac_cv_prog_cc_cflags__Wendif_labels=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - CFLAGS="$pgac_save_CFLAGS" - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + pgac_cv_prog_cc_cflags__Wendif_labels=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_c_werror_flag=$ac_save_c_werror_flag +CFLAGS="$pgac_save_CFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wendif_labels" >&5 +$as_echo "$pgac_cv_prog_cc_cflags__Wendif_labels" >&6; } +if test x"$pgac_cv_prog_cc_cflags__Wendif_labels" = x"yes"; then + CFLAGS="$CFLAGS -Wendif-labels" +fi + + # This was included in -Wall/-Wformat in older GCC versions + { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wformat-security" >&5 +$as_echo_n "checking whether $CC supports -Wformat-security... " >&6; } +if test "${pgac_cv_prog_cc_cflags__Wformat_security+set}" = set; then + $as_echo_n "(cached) " >&6 +else + pgac_save_CFLAGS=$CFLAGS +CFLAGS="$pgac_save_CFLAGS -Wformat-security" +ac_save_c_werror_flag=$ac_c_werror_flag +ac_c_werror_flag=yes +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + pgac_cv_prog_cc_cflags__Wformat_security=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + pgac_cv_prog_cc_cflags__Wformat_security=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_c_werror_flag=$ac_save_c_werror_flag +CFLAGS="$pgac_save_CFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wformat_security" >&5 +$as_echo "$pgac_cv_prog_cc_cflags__Wformat_security" >&6; } +if test x"$pgac_cv_prog_cc_cflags__Wformat_security" = x"yes"; then + CFLAGS="$CFLAGS -Wformat-security" +fi # Disable strict-aliasing rules; needed for gcc 3.3+ - { $as_echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5 -$as_echo_n "checking if $CC supports -fno-strict-aliasing... " >&6; } -pgac_save_CFLAGS=$CFLAGS + { $as_echo "$as_me:$LINENO: checking whether $CC supports -fno-strict-aliasing" >&5 +$as_echo_n "checking whether $CC supports -fno-strict-aliasing... " >&6; } +if test "${pgac_cv_prog_cc_cflags__fno_strict_aliasing+set}" = set; then + $as_echo_n "(cached) " >&6 +else + pgac_save_CFLAGS=$CFLAGS CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing" +ac_save_c_werror_flag=$ac_c_werror_flag +ac_c_werror_flag=yes cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF @@ -4137,24 +4227,34 @@ $as_echo "$ac_try_echo") >&5 test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } + pgac_cv_prog_cc_cflags__fno_strict_aliasing=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - CFLAGS="$pgac_save_CFLAGS" - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + pgac_cv_prog_cc_cflags__fno_strict_aliasing=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_c_werror_flag=$ac_save_c_werror_flag +CFLAGS="$pgac_save_CFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&5 +$as_echo "$pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&6; } +if test x"$pgac_cv_prog_cc_cflags__fno_strict_aliasing" = x"yes"; then + CFLAGS="$CFLAGS -fno-strict-aliasing" +fi # Disable optimizations that assume no overflow; needed for gcc 4.3+ - { $as_echo "$as_me:$LINENO: checking if $CC supports -fwrapv" >&5 -$as_echo_n "checking if $CC supports -fwrapv... " >&6; } -pgac_save_CFLAGS=$CFLAGS + { $as_echo "$as_me:$LINENO: checking whether $CC supports -fwrapv" >&5 +$as_echo_n "checking whether $CC supports -fwrapv... " >&6; } +if test "${pgac_cv_prog_cc_cflags__fwrapv+set}" = set; then + $as_echo_n "(cached) " >&6 +else + pgac_save_CFLAGS=$CFLAGS CFLAGS="$pgac_save_CFLAGS -fwrapv" +ac_save_c_werror_flag=$ac_c_werror_flag +ac_c_werror_flag=yes cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF @@ -4188,26 +4288,36 @@ $as_echo "$ac_try_echo") >&5 test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } + pgac_cv_prog_cc_cflags__fwrapv=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - CFLAGS="$pgac_save_CFLAGS" - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + pgac_cv_prog_cc_cflags__fwrapv=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_c_werror_flag=$ac_save_c_werror_flag +CFLAGS="$pgac_save_CFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fwrapv" >&5 +$as_echo "$pgac_cv_prog_cc_cflags__fwrapv" >&6; } +if test x"$pgac_cv_prog_cc_cflags__fwrapv" = x"yes"; then + CFLAGS="$CFLAGS -fwrapv" +fi elif test "$ICC" = yes; then # Intel's compiler has a bug/misoptimization in checking for # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS. - { $as_echo "$as_me:$LINENO: checking if $CC supports -mp1" >&5 -$as_echo_n "checking if $CC supports -mp1... " >&6; } -pgac_save_CFLAGS=$CFLAGS + { $as_echo "$as_me:$LINENO: checking whether $CC supports -mp1" >&5 +$as_echo_n "checking whether $CC supports -mp1... " >&6; } +if test "${pgac_cv_prog_cc_cflags__mp1+set}" = set; then + $as_echo_n "(cached) " >&6 +else + pgac_save_CFLAGS=$CFLAGS CFLAGS="$pgac_save_CFLAGS -mp1" +ac_save_c_werror_flag=$ac_c_werror_flag +ac_c_werror_flag=yes cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF @@ -4241,24 +4351,34 @@ $as_echo "$ac_try_echo") >&5 test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } + pgac_cv_prog_cc_cflags__mp1=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - CFLAGS="$pgac_save_CFLAGS" - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + pgac_cv_prog_cc_cflags__mp1=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_c_werror_flag=$ac_save_c_werror_flag +CFLAGS="$pgac_save_CFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__mp1" >&5 +$as_echo "$pgac_cv_prog_cc_cflags__mp1" >&6; } +if test x"$pgac_cv_prog_cc_cflags__mp1" = x"yes"; then + CFLAGS="$CFLAGS -mp1" +fi # Make sure strict aliasing is off (though this is said to be the default) - { $as_echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5 -$as_echo_n "checking if $CC supports -fno-strict-aliasing... " >&6; } -pgac_save_CFLAGS=$CFLAGS + { $as_echo "$as_me:$LINENO: checking whether $CC supports -fno-strict-aliasing" >&5 +$as_echo_n "checking whether $CC supports -fno-strict-aliasing... " >&6; } +if test "${pgac_cv_prog_cc_cflags__fno_strict_aliasing+set}" = set; then + $as_echo_n "(cached) " >&6 +else + pgac_save_CFLAGS=$CFLAGS CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing" +ac_save_c_werror_flag=$ac_c_werror_flag +ac_c_werror_flag=yes cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF @@ -4292,25 +4412,35 @@ $as_echo "$ac_try_echo") >&5 test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } + pgac_cv_prog_cc_cflags__fno_strict_aliasing=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - CFLAGS="$pgac_save_CFLAGS" - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + pgac_cv_prog_cc_cflags__fno_strict_aliasing=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_c_werror_flag=$ac_save_c_werror_flag +CFLAGS="$pgac_save_CFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&5 +$as_echo "$pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&6; } +if test x"$pgac_cv_prog_cc_cflags__fno_strict_aliasing" = x"yes"; then + CFLAGS="$CFLAGS -fno-strict-aliasing" +fi elif test "$PORTNAME" = "aix"; then # AIX's xlc has to have strict aliasing turned off too - { $as_echo "$as_me:$LINENO: checking if $CC supports -qnoansialias" >&5 -$as_echo_n "checking if $CC supports -qnoansialias... " >&6; } -pgac_save_CFLAGS=$CFLAGS + { $as_echo "$as_me:$LINENO: checking whether $CC supports -qnoansialias" >&5 +$as_echo_n "checking whether $CC supports -qnoansialias... " >&6; } +if test "${pgac_cv_prog_cc_cflags__qnoansialias+set}" = set; then + $as_echo_n "(cached) " >&6 +else + pgac_save_CFLAGS=$CFLAGS CFLAGS="$pgac_save_CFLAGS -qnoansialias" +ac_save_c_werror_flag=$ac_c_werror_flag +ac_c_werror_flag=yes cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF @@ -4344,18 +4474,86 @@ $as_echo "$ac_try_echo") >&5 test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } + pgac_cv_prog_cc_cflags__qnoansialias=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - CFLAGS="$pgac_save_CFLAGS" - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + pgac_cv_prog_cc_cflags__qnoansialias=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_c_werror_flag=$ac_save_c_werror_flag +CFLAGS="$pgac_save_CFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__qnoansialias" >&5 +$as_echo "$pgac_cv_prog_cc_cflags__qnoansialias" >&6; } +if test x"$pgac_cv_prog_cc_cflags__qnoansialias" = x"yes"; then + CFLAGS="$CFLAGS -qnoansialias" +fi + +elif test "$PORTNAME" = "hpux"; then + # On some versions of HP-UX, libm functions do not set errno by default. + # Fix that by using +Olibmerrno if the compiler recognizes it. + { $as_echo "$as_me:$LINENO: checking whether $CC supports +Olibmerrno" >&5 +$as_echo_n "checking whether $CC supports +Olibmerrno... " >&6; } +if test "${pgac_cv_prog_cc_cflags_pOlibmerrno+set}" = set; then + $as_echo_n "(cached) " >&6 +else + pgac_save_CFLAGS=$CFLAGS +CFLAGS="$pgac_save_CFLAGS +Olibmerrno" +ac_save_c_werror_flag=$ac_c_werror_flag +ac_c_werror_flag=yes +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + pgac_cv_prog_cc_cflags_pOlibmerrno=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + pgac_cv_prog_cc_cflags_pOlibmerrno=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_c_werror_flag=$ac_save_c_werror_flag +CFLAGS="$pgac_save_CFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags_pOlibmerrno" >&5 +$as_echo "$pgac_cv_prog_cc_cflags_pOlibmerrno" >&6; } +if test x"$pgac_cv_prog_cc_cflags_pOlibmerrno" = x"yes"; then + CFLAGS="$CFLAGS +Olibmerrno" +fi fi @@ -5314,6 +5512,40 @@ fi $as_echo "$with_openssl" >&6; } +# +# SELinux +# +{ $as_echo "$as_me:$LINENO: checking whether to build with SELinux support" >&5 +$as_echo_n "checking whether to build with SELinux support... " >&6; } + + + +# Check whether --with-selinux was given. +if test "${with_selinux+set}" = set; then + withval=$with_selinux; + case $withval in + yes) + : + ;; + no) + : + ;; + *) + { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-selinux option" >&5 +$as_echo "$as_me: error: no argument expected for --with-selinux option" >&2;} + { (exit 1); exit 1; }; } + ;; + esac + +else + with_selinux=no + +fi + + + +{ $as_echo "$as_me:$LINENO: result: $with_selinux" >&5 +$as_echo "$with_selinux" >&6; } # # Readline @@ -6738,13 +6970,13 @@ fi if test -z "$BISON"; then { $as_echo "$as_me:$LINENO: WARNING: -*** Without Bison you will not be able to build PostgreSQL from CVS nor +*** Without Bison you will not be able to build PostgreSQL from Git nor *** change any of the parser definition files. You can obtain Bison from *** a GNU mirror site. (If you are using the official distribution of *** PostgreSQL then you do not need to worry about this, because the Bison *** output is pre-generated.)" >&5 $as_echo "$as_me: WARNING: -*** Without Bison you will not be able to build PostgreSQL from CVS nor +*** Without Bison you will not be able to build PostgreSQL from Git nor *** change any of the parser definition files. You can obtain Bison from *** a GNU mirror site. (If you are using the official distribution of *** PostgreSQL then you do not need to worry about this, because the Bison @@ -6802,13 +7034,13 @@ fi $as_echo "$pgac_cv_path_flex" >&6; } if test x"$pgac_cv_path_flex" = x"no"; then { $as_echo "$as_me:$LINENO: WARNING: -*** Without Flex you will not be able to build PostgreSQL from CVS nor +*** Without Flex you will not be able to build PostgreSQL from Git nor *** change any of the scanner definition files. You can obtain Flex from *** a GNU mirror site. (If you are using the official distribution of *** PostgreSQL then you do not need to worry about this because the Flex *** output is pre-generated.)" >&5 $as_echo "$as_me: WARNING: -*** Without Flex you will not be able to build PostgreSQL from CVS nor +*** Without Flex you will not be able to build PostgreSQL from Git nor *** change any of the scanner definition files. You can obtain Flex from *** a GNU mirror site. (If you are using the official distribution of *** PostgreSQL then you do not need to worry about this because the Flex @@ -6889,12 +7121,12 @@ fi if test -z "$PERL"; then { $as_echo "$as_me:$LINENO: WARNING: -*** Without Perl you will not be able to build PostgreSQL from CVS. +*** Without Perl you will not be able to build PostgreSQL from Git. *** You can obtain Perl from any CPAN mirror site. *** (If you are using the official distribution of PostgreSQL then you do not *** need to worry about this, because the Perl output is pre-generated.)" >&5 $as_echo "$as_me: WARNING: -*** Without Perl you will not be able to build PostgreSQL from CVS. +*** Without Perl you will not be able to build PostgreSQL from Git. *** You can obtain Perl from any CPAN mirror site. *** (If you are using the official distribution of PostgreSQL then you do not *** need to worry about this, because the Perl output is pre-generated.)" >&2;} @@ -8081,6 +8313,8 @@ fi if test "$with_readline" = yes; then +{ $as_echo "$as_me:$LINENO: checking for library containing readline" >&5 +$as_echo_n "checking for library containing readline... " >&6; } if test "${pgac_cv_check_readline+set}" = set; then $as_echo_n "(cached) " >&6 else @@ -8091,8 +8325,6 @@ then READLINE_ORDER="-lreadline -ledit" else READLINE_ORDER="-ledit -lreadline" fi for pgac_rllib in $READLINE_ORDER ; do - { $as_echo "$as_me:$LINENO: checking for ${pgac_rllib}" >&5 -$as_echo_n "checking for ${pgac_rllib}... " >&6; } for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS" cat >conftest.$ac_ext <<_ACEOF @@ -8164,18 +8396,14 @@ rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext done if test "$pgac_cv_check_readline" != no ; then - { $as_echo "$as_me:$LINENO: result: yes ($pgac_cv_check_readline)" >&5 -$as_echo "yes ($pgac_cv_check_readline)" >&6; } break - else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } fi done LIBS=$pgac_save_LIBS fi - +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_check_readline" >&5 +$as_echo "$pgac_cv_check_readline" >&6; } if test "$pgac_cv_check_readline" != no ; then LIBS="$pgac_cv_check_readline $LIBS" @@ -9245,6 +9473,89 @@ fi fi +# for contrib/sepgsql +if test "$with_selinux" = yes; then + +{ $as_echo "$as_me:$LINENO: checking for selinux_sepgsql_context_path in -lselinux" >&5 +$as_echo_n "checking for selinux_sepgsql_context_path in -lselinux... " >&6; } +if test "${ac_cv_lib_selinux_selinux_sepgsql_context_path+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lselinux $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char selinux_sepgsql_context_path (); +int +main () +{ +return selinux_sepgsql_context_path (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_link") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_lib_selinux_selinux_sepgsql_context_path=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_lib_selinux_selinux_sepgsql_context_path=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_selinux_selinux_sepgsql_context_path" >&5 +$as_echo "$ac_cv_lib_selinux_selinux_sepgsql_context_path" >&6; } +if test "x$ac_cv_lib_selinux_selinux_sepgsql_context_path" = x""yes; then + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBSELINUX 1 +_ACEOF + + LIBS="-lselinux $LIBS" + +else + { { $as_echo "$as_me:$LINENO: error: library 'libselinux', version 2.0.93 or newer, is required for SELinux support" >&5 +$as_echo "$as_me: error: library 'libselinux', version 2.0.93 or newer, is required for SELinux support" >&2;} + { (exit 1); exit 1; }; } +fi + +fi + # for contrib/uuid-ossp if test "$with_ossp_uuid" = yes ; then { $as_echo "$as_me:$LINENO: checking for uuid_export in -lossp-uuid" >&5 @@ -9679,7 +9990,8 @@ done -for ac_header in crypt.h dld.h fp_class.h getopt.h ieeefp.h ifaddrs.h langinfo.h poll.h pwd.h sys/ioctl.h sys/ipc.h sys/poll.h sys/pstat.h sys/resource.h sys/select.h sys/sem.h sys/shm.h sys/socket.h sys/sockio.h sys/tas.h sys/time.h sys/un.h termios.h ucred.h utime.h wchar.h wctype.h kernel/OS.h kernel/image.h SupportDefs.h + +for ac_header in crypt.h dld.h fp_class.h getopt.h ieeefp.h ifaddrs.h langinfo.h poll.h pwd.h sys/ioctl.h sys/ipc.h sys/poll.h sys/pstat.h sys/resource.h sys/select.h sys/sem.h sys/shm.h sys/socket.h sys/sockio.h sys/tas.h sys/time.h sys/ucred.h sys/un.h termios.h ucred.h utime.h wchar.h wctype.h kernel/OS.h kernel/image.h SupportDefs.h do as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then @@ -14642,9 +14954,10 @@ _ACEOF fi -{ $as_echo "$as_me:$LINENO: checking for signed types" >&5 -$as_echo_n "checking for signed types... " >&6; } -if test "${pgac_cv_c_signed+set}" = set; then + + { $as_echo "$as_me:$LINENO: checking for flexible array members" >&5 +$as_echo_n "checking for flexible array members... " >&6; } +if test "${ac_cv_c_flexmember+set}" = set; then $as_echo_n "(cached) " >&6 else cat >conftest.$ac_ext <<_ACEOF @@ -14653,11 +14966,18 @@ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ - +#include + #include + #include + struct s { int n; double d[]; }; int main () { -signed char c; signed short s; signed int i; +int m = getchar (); + struct s *p = malloc (offsetof (struct s, d) + + m * sizeof (double)); + p->d[0] = 0.0; + return p->d != (double *) NULL; ; return 0; } @@ -14680,34 +15000,97 @@ $as_echo "$ac_try_echo") >&5 test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then - pgac_cv_c_signed=yes + ac_cv_c_flexmember=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - pgac_cv_c_signed=no + ac_cv_c_flexmember=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5 -$as_echo "$pgac_cv_c_signed" >&6; } -if test x"$pgac_cv_c_signed" = xno ; then +{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_flexmember" >&5 +$as_echo "$ac_cv_c_flexmember" >&6; } + if test $ac_cv_c_flexmember = yes; then cat >>confdefs.h <<\_ACEOF -#define signed /**/ +#define FLEXIBLE_ARRAY_MEMBER /**/ _ACEOF -fi -{ $as_echo "$as_me:$LINENO: checking for working volatile" >&5 -$as_echo_n "checking for working volatile... " >&6; } -if test "${ac_cv_c_volatile+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ + else + cat >>confdefs.h <<\_ACEOF +#define FLEXIBLE_ARRAY_MEMBER 1 _ACEOF -cat confdefs.h >>conftest.$ac_ext + + fi + +{ $as_echo "$as_me:$LINENO: checking for signed types" >&5 +$as_echo_n "checking for signed types... " >&6; } +if test "${pgac_cv_c_signed+set}" = set; then + $as_echo_n "(cached) " >&6 +else + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +int +main () +{ +signed char c; signed short s; signed int i; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + pgac_cv_c_signed=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + pgac_cv_c_signed=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5 +$as_echo "$pgac_cv_c_signed" >&6; } +if test x"$pgac_cv_c_signed" = xno ; then + +cat >>confdefs.h <<\_ACEOF +#define signed /**/ +_ACEOF + +fi +{ $as_echo "$as_me:$LINENO: checking for working volatile" >&5 +$as_echo_n "checking for working volatile... " >&6; } +if test "${ac_cv_c_volatile+set}" = set; then + $as_echo_n "(cached) " >&6 +else + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @@ -16606,66 +16989,23 @@ _ACEOF fi -{ $as_echo "$as_me:$LINENO: checking for struct cmsgcred" >&5 -$as_echo_n "checking for struct cmsgcred... " >&6; } -if test "${ac_cv_type_struct_cmsgcred+set}" = set; then +{ $as_echo "$as_me:$LINENO: checking for locale_t" >&5 +$as_echo_n "checking for locale_t... " >&6; } +if test "${pgac_cv_type_locale_t+set}" = set; then $as_echo_n "(cached) " >&6 else - ac_cv_type_struct_cmsgcred=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -#include -#include - -int -main () -{ -if (sizeof (struct cmsgcred)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ -#include -#include -#include -#include - +#include +locale_t x; int main () { -if (sizeof ((struct cmsgcred))) - return 0; + ; return 0; } @@ -16688,94 +17028,23 @@ $as_echo "$ac_try_echo") >&5 test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_struct_cmsgcred=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + pgac_cv_type_locale_t=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5 -$as_echo "$ac_cv_type_struct_cmsgcred" >&6; } -if test "x$ac_cv_type_struct_cmsgcred" = x""yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_STRUCT_CMSGCRED 1 -_ACEOF - - -fi -{ $as_echo "$as_me:$LINENO: checking for struct fcred" >&5 -$as_echo_n "checking for struct fcred... " >&6; } -if test "${ac_cv_type_struct_fcred+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type_struct_fcred=no -cat >conftest.$ac_ext <<_ACEOF + cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ -#include -#include -#include -#include - +#include +locale_t x; int main () { -if (sizeof (struct fcred)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -#include -#include -int -main () -{ -if (sizeof ((struct fcred))) - return 0; ; return 0; } @@ -16798,55 +17067,57 @@ $as_echo "$ac_try_echo") >&5 test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then - : + pgac_cv_type_locale_t='yes (in xlocale.h)' else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - ac_cv_type_struct_fcred=yes + pgac_cv_type_locale_t=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5 -$as_echo "$ac_cv_type_struct_fcred" >&6; } -if test "x$ac_cv_type_struct_fcred" = x""yes; then +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_type_locale_t" >&5 +$as_echo "$pgac_cv_type_locale_t" >&6; } +if test "$pgac_cv_type_locale_t" != no; then -cat >>confdefs.h <<_ACEOF -#define HAVE_STRUCT_FCRED 1 +cat >>confdefs.h <<\_ACEOF +#define HAVE_LOCALE_T 1 _ACEOF +fi +if test "$pgac_cv_type_locale_t" = 'yes (in xlocale.h)'; then + +cat >>confdefs.h <<\_ACEOF +#define LOCALE_T_IN_XLOCALE 1 +_ACEOF fi -{ $as_echo "$as_me:$LINENO: checking for struct sockcred" >&5 -$as_echo_n "checking for struct sockcred... " >&6; } -if test "${ac_cv_type_struct_sockcred+set}" = set; then + +{ $as_echo "$as_me:$LINENO: checking for struct cmsgcred" >&5 +$as_echo_n "checking for struct cmsgcred... " >&6; } +if test "${ac_cv_type_struct_cmsgcred+set}" = set; then $as_echo_n "(cached) " >&6 else - ac_cv_type_struct_sockcred=no + ac_cv_type_struct_cmsgcred=no cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ -#include -#include #include +#ifdef HAVE_SYS_UCRED_H #include +#endif int main () { -if (sizeof (struct sockcred)) +if (sizeof (struct cmsgcred)) return 0; ; return 0; @@ -16876,15 +17147,15 @@ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ -#include -#include #include +#ifdef HAVE_SYS_UCRED_H #include +#endif int main () { -if (sizeof ((struct sockcred))) +if (sizeof ((struct cmsgcred))) return 0; ; return 0; @@ -16913,7 +17184,7 @@ else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - ac_cv_type_struct_sockcred=yes + ac_cv_type_struct_cmsgcred=yes fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext @@ -16926,12 +17197,12 @@ fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5 -$as_echo "$ac_cv_type_struct_sockcred" >&6; } -if test "x$ac_cv_type_struct_sockcred" = x""yes; then +{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5 +$as_echo "$ac_cv_type_struct_cmsgcred" >&6; } +if test "x$ac_cv_type_struct_cmsgcred" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_STRUCT_SOCKCRED 1 +#define HAVE_STRUCT_CMSGCRED 1 _ACEOF @@ -18472,8 +18743,8 @@ else if test "${ac_cv_func_accept_arg3+set}" = set; then $as_echo_n "(cached) " >&6 else - for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do - for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do + for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL' 'SOCKET'; do + for ac_cv_func_accept_arg1 in 'int' 'unsigned int' 'SOCKET'; do for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do cat >conftest.$ac_ext <<_ACEOF @@ -18652,7 +18923,7 @@ fi -for ac_func in cbrt dlopen fcvt fdatasync getifaddrs getpeereid getpeerucred getrlimit memmove poll pstat readlink scandir setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs +for ac_func in cbrt dlopen fcvt fdatasync getifaddrs getpeerucred getrlimit memmove poll pstat readlink scandir setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs wcstombs_l do as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 @@ -20223,7 +20494,8 @@ LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'` -for ac_func in crypt erand48 getopt getrusage inet_aton random rint srandom strdup strerror strlcat strlcpy strtol strtoul + +for ac_func in crypt erand48 getopt getpeereid getrusage inet_aton random rint srandom strdup strerror strlcat strlcpy strtol strtoul do as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 @@ -20713,6 +20985,23 @@ esac fi +# mingw has adopted a GNU-centric interpretation of optind/optreset, +# so always use our version on Windows. +if test "$PORTNAME" = "win32"; then + case " $LIBOBJS " in + *" getopt.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS getopt.$ac_objext" + ;; +esac + + case " $LIBOBJS " in + *" getopt_long.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext" + ;; +esac + +fi + # Cygwin's erand48() is broken (always returns zero) in some releases, # so force use of ours. if test "$PORTNAME" = "cygwin"; then @@ -20775,20 +21064,170 @@ choke me int main () { -return $ac_func (); +return $ac_func (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_link") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + eval "$as_ac_var=yes" +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + eval "$as_ac_var=no" +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +fi +ac_res=`eval 'as_val=${'$as_ac_var'} + $as_echo "$as_val"'` + { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +as_val=`eval 'as_val=${'$as_ac_var'} + $as_echo "$as_val"'` + if test "x$as_val" = x""yes; then + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +else + case " $LIBOBJS " in + *" $ac_func.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" + ;; +esac + +fi +done + + + case " $LIBOBJS " in + *" kill.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS kill.$ac_objext" + ;; +esac + + case " $LIBOBJS " in + *" open.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS open.$ac_objext" + ;; +esac + + case " $LIBOBJS " in + *" win32env.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS win32env.$ac_objext" + ;; +esac + + case " $LIBOBJS " in + *" win32error.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS win32error.$ac_objext" + ;; +esac + + +cat >>confdefs.h <<\_ACEOF +#define HAVE_SYMLINK 1 +_ACEOF + + { $as_echo "$as_me:$LINENO: checking for MINIDUMP_TYPE" >&5 +$as_echo_n "checking for MINIDUMP_TYPE... " >&6; } +if test "${ac_cv_type_MINIDUMP_TYPE+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_cv_type_MINIDUMP_TYPE=no +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +#define WIN32_LEAN_AND_MEAN +#include +#include +#include + +int +main () +{ +if (sizeof (MINIDUMP_TYPE)) + return 0; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +#define WIN32_LEAN_AND_MEAN +#include +#include +#include + +int +main () +{ +if (sizeof ((MINIDUMP_TYPE))) + return 0; ; return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" $as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 + (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 @@ -20797,79 +21236,54 @@ $as_echo "$ac_try_echo") >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" + } && test -s conftest.$ac_objext; then + : else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext + ac_cv_type_MINIDUMP_TYPE=yes fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext else - case " $LIBOBJS " in - *" $ac_func.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" - ;; -esac - -fi -done + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 -case " $LIBOBJS " in - *" kill.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS kill.$ac_objext" - ;; -esac +fi -case " $LIBOBJS " in - *" open.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS open.$ac_objext" - ;; -esac +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_MINIDUMP_TYPE" >&5 +$as_echo "$ac_cv_type_MINIDUMP_TYPE" >&6; } +if test "x$ac_cv_type_MINIDUMP_TYPE" = x""yes; then -case " $LIBOBJS " in - *" win32env.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS win32env.$ac_objext" - ;; -esac +cat >>confdefs.h <<_ACEOF +#define HAVE_MINIDUMP_TYPE 1 +_ACEOF -case " $LIBOBJS " in - *" win32error.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS win32error.$ac_objext" - ;; -esac +pgac_minidump_type=yes +else + pgac_minidump_type=no +fi +fi +if test x"$pgac_minidump_type" = x"yes" ; then + have_win32_dbghelp=yes -cat >>confdefs.h <<\_ACEOF -#define HAVE_SYMLINK 1 -_ACEOF +else + have_win32_dbghelp=no fi if test "$with_readline" = yes; then { $as_echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5 $as_echo_n "checking for rl_completion_append_character... " >&6; } -cat >conftest.$ac_ext <<_ACEOF +if test "${pgac_cv_var_rl_completion_append_character+set}" = set; then + $as_echo_n "(cached) " >&6 +else + cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext @@ -20911,24 +21325,27 @@ $as_echo "$ac_try_echo") >&5 test "$cross_compiling" = yes || $as_test_x conftest$ac_exeext }; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - -cat >>confdefs.h <<\_ACEOF -#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1 -_ACEOF - + pgac_cv_var_rl_completion_append_character=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + pgac_cv_var_rl_completion_append_character=no fi rm -rf conftest.dSYM rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_var_rl_completion_append_character" >&5 +$as_echo "$pgac_cv_var_rl_completion_append_character" >&6; } +if test x"$pgac_cv_var_rl_completion_append_character" = x"yes"; then + +cat >>confdefs.h <<\_ACEOF +#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1 +_ACEOF + +fi for ac_func in rl_completion_matches rl_filename_completion_function @@ -21138,7 +21555,10 @@ fi { $as_echo "$as_me:$LINENO: checking for sigsetjmp" >&5 $as_echo_n "checking for sigsetjmp... " >&6; } -cat >conftest.$ac_ext <<_ACEOF +if test "${pgac_cv_func_sigsetjmp+set}" = set; then + $as_echo_n "(cached) " >&6 +else + cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext @@ -21174,24 +21594,27 @@ $as_echo "$ac_try_echo") >&5 test "$cross_compiling" = yes || $as_test_x conftest$ac_exeext }; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_SIGSETJMP 1 -_ACEOF - -{ $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } + pgac_cv_func_sigsetjmp=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + pgac_cv_func_sigsetjmp=no fi rm -rf conftest.dSYM rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_func_sigsetjmp" >&5 +$as_echo "$pgac_cv_func_sigsetjmp" >&6; } +if test x"$pgac_cv_func_sigsetjmp" = x"yes"; then + +cat >>confdefs.h <<\_ACEOF +#define HAVE_SIGSETJMP 1 +_ACEOF + +fi { $as_echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5 $as_echo_n "checking whether sys_siglist is declared... " >&6; } @@ -22331,7 +22754,8 @@ main (int argc, char **argv) } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext - if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then + # Check both linking and compiling, because they might tolerate different options. + if test "`(eval $ac_link 2>&1 1>&5)`" = "" && test "`(eval $ac_compile 2>&1 1>&5)`" = ""; then # we continue with more flags because Linux needs -lpthread # for libpq builds on PostgreSQL. The test above only # tests for building binaries, not shared libraries. @@ -27773,6 +28197,13 @@ _ACEOF SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c" fi +# Select latch implementation type. +if test "$PORTNAME" != "win32"; then + LATCH_IMPLEMENTATION="src/backend/port/unix_latch.c" +else + LATCH_IMPLEMENTATION="src/backend/port/win32_latch.c" +fi + # If not set in template file, set bytes to use libc memset() if test x"$MEMSET_LOOP_LIMIT" = x"" ; then MEMSET_LOOP_LIMIT=1024 @@ -28394,6 +28825,154 @@ fi CPPFLAGS=$ac_save_CPPFLAGS fi +# check for +if test "$with_python" = yes; then + ac_save_CPPFLAGS=$CPPFLAGS + CPPFLAGS="$python_includespec $CPPFLAGS" + if test "${ac_cv_header_Python_h+set}" = set; then + { $as_echo "$as_me:$LINENO: checking for Python.h" >&5 +$as_echo_n "checking for Python.h... " >&6; } +if test "${ac_cv_header_Python_h+set}" = set; then + $as_echo_n "(cached) " >&6 +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_Python_h" >&5 +$as_echo "$ac_cv_header_Python_h" >&6; } +else + # Is the header compilable? +{ $as_echo "$as_me:$LINENO: checking Python.h usability" >&5 +$as_echo_n "checking Python.h usability... " >&6; } +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +#include +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_header_compiler=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_compiler=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +$as_echo "$ac_header_compiler" >&6; } + +# Is the header present? +{ $as_echo "$as_me:$LINENO: checking Python.h presence" >&5 +$as_echo_n "checking Python.h presence... " >&6; } +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include +_ACEOF +if { (ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test ! -s conftest.err + }; then + ac_header_preproc=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_preproc=no +fi + +rm -f conftest.err conftest.$ac_ext +{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +$as_echo "$ac_header_preproc" >&6; } + +# So? What about this header? +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in + yes:no: ) + { $as_echo "$as_me:$LINENO: WARNING: Python.h: accepted by the compiler, rejected by the preprocessor!" >&5 +$as_echo "$as_me: WARNING: Python.h: accepted by the compiler, rejected by the preprocessor!" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: Python.h: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: Python.h: proceeding with the compiler's result" >&2;} + ac_header_preproc=yes + ;; + no:yes:* ) + { $as_echo "$as_me:$LINENO: WARNING: Python.h: present but cannot be compiled" >&5 +$as_echo "$as_me: WARNING: Python.h: present but cannot be compiled" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: Python.h: check for missing prerequisite headers?" >&5 +$as_echo "$as_me: WARNING: Python.h: check for missing prerequisite headers?" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: Python.h: see the Autoconf documentation" >&5 +$as_echo "$as_me: WARNING: Python.h: see the Autoconf documentation" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: Python.h: section \"Present But Cannot Be Compiled\"" >&5 +$as_echo "$as_me: WARNING: Python.h: section \"Present But Cannot Be Compiled\"" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: Python.h: proceeding with the preprocessor's result" >&5 +$as_echo "$as_me: WARNING: Python.h: proceeding with the preprocessor's result" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: Python.h: in the future, the compiler will take precedence" >&5 +$as_echo "$as_me: WARNING: Python.h: in the future, the compiler will take precedence" >&2;} + ( cat <<\_ASBOX +## ---------------------------------------- ## +## Report this to pgsql-bugs@postgresql.org ## +## ---------------------------------------- ## +_ASBOX + ) | sed "s/^/$as_me: WARNING: /" >&2 + ;; +esac +{ $as_echo "$as_me:$LINENO: checking for Python.h" >&5 +$as_echo_n "checking for Python.h... " >&6; } +if test "${ac_cv_header_Python_h+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_cv_header_Python_h=$ac_header_preproc +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_Python_h" >&5 +$as_echo "$ac_cv_header_Python_h" >&6; } + +fi +if test "x$ac_cv_header_Python_h" = x""yes; then + : +else + { { $as_echo "$as_me:$LINENO: error: header file is required for Python" >&5 +$as_echo "$as_me: error: header file is required for Python" >&2;} + { (exit 1); exit 1; }; } +fi + + + CPPFLAGS=$ac_save_CPPFLAGS +fi + # # Check for DocBook and tools # @@ -28840,14 +29419,15 @@ else fi if test "$PORTNAME" = "darwin"; then - { $as_echo "$as_me:$LINENO: checking if $CC supports -Wl,-dead_strip_dylibs" >&5 -$as_echo_n "checking if $CC supports -Wl,-dead_strip_dylibs... " >&6; } -pgac_save_LDFLAGS=$LDFLAGS + { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,-dead_strip_dylibs" >&5 +$as_echo_n "checking whether $CC supports -Wl,-dead_strip_dylibs... " >&6; } +if test "${pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs+set}" = set; then + $as_echo_n "(cached) " >&6 +else + pgac_save_LDFLAGS=$LDFLAGS LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs" if test "$cross_compiling" = yes; then - LDFLAGS="$pgac_save_LDFLAGS" - { $as_echo "$as_me:$LINENO: result: assuming no" >&5 -$as_echo "assuming no" >&6; } + pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs="assuming no" else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ @@ -28886,33 +29466,38 @@ $as_echo "$ac_try_echo") >&5 ac_status=$? $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } + pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=yes else $as_echo "$as_me: program exited with status $ac_status" >&5 $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) -LDFLAGS="$pgac_save_LDFLAGS" - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } +pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=no fi rm -rf conftest.dSYM rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi +LDFLAGS="$pgac_save_LDFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&5 +$as_echo "$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&6; } +if test x"$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" = x"yes"; then + LDFLAGS="$LDFLAGS -Wl,-dead_strip_dylibs" +fi elif test "$PORTNAME" = "openbsd"; then - { $as_echo "$as_me:$LINENO: checking if $CC supports -Wl,-Bdynamic" >&5 -$as_echo_n "checking if $CC supports -Wl,-Bdynamic... " >&6; } -pgac_save_LDFLAGS=$LDFLAGS + { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,-Bdynamic" >&5 +$as_echo_n "checking whether $CC supports -Wl,-Bdynamic... " >&6; } +if test "${pgac_cv_prog_cc_ldflags__Wl__Bdynamic+set}" = set; then + $as_echo_n "(cached) " >&6 +else + pgac_save_LDFLAGS=$LDFLAGS LDFLAGS="$pgac_save_LDFLAGS -Wl,-Bdynamic" if test "$cross_compiling" = yes; then - LDFLAGS="$pgac_save_LDFLAGS" - { $as_echo "$as_me:$LINENO: result: assuming no" >&5 -$as_echo "assuming no" >&6; } + pgac_cv_prog_cc_ldflags__Wl__Bdynamic="assuming no" else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ @@ -28951,33 +29536,38 @@ $as_echo "$ac_try_echo") >&5 ac_status=$? $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } + pgac_cv_prog_cc_ldflags__Wl__Bdynamic=yes else $as_echo "$as_me: program exited with status $ac_status" >&5 $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) -LDFLAGS="$pgac_save_LDFLAGS" - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } +pgac_cv_prog_cc_ldflags__Wl__Bdynamic=no fi rm -rf conftest.dSYM rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi +LDFLAGS="$pgac_save_LDFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&5 +$as_echo "$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&6; } +if test x"$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" = x"yes"; then + LDFLAGS="$LDFLAGS -Wl,-Bdynamic" +fi else - { $as_echo "$as_me:$LINENO: checking if $CC supports -Wl,--as-needed" >&5 -$as_echo_n "checking if $CC supports -Wl,--as-needed... " >&6; } -pgac_save_LDFLAGS=$LDFLAGS + { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,--as-needed" >&5 +$as_echo_n "checking whether $CC supports -Wl,--as-needed... " >&6; } +if test "${pgac_cv_prog_cc_ldflags__Wl___as_needed+set}" = set; then + $as_echo_n "(cached) " >&6 +else + pgac_save_LDFLAGS=$LDFLAGS LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed" if test "$cross_compiling" = yes; then - LDFLAGS="$pgac_save_LDFLAGS" - { $as_echo "$as_me:$LINENO: result: assuming no" >&5 -$as_echo "assuming no" >&6; } + pgac_cv_prog_cc_ldflags__Wl___as_needed="assuming no" else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ @@ -29016,23 +29606,27 @@ $as_echo "$ac_try_echo") >&5 ac_status=$? $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } + pgac_cv_prog_cc_ldflags__Wl___as_needed=yes else $as_echo "$as_me: program exited with status $ac_status" >&5 $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) -LDFLAGS="$pgac_save_LDFLAGS" - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } +pgac_cv_prog_cc_ldflags__Wl___as_needed=no fi rm -rf conftest.dSYM rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi +LDFLAGS="$pgac_save_LDFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl___as_needed" >&5 +$as_echo "$pgac_cv_prog_cc_ldflags__Wl___as_needed" >&6; } +if test x"$pgac_cv_prog_cc_ldflags__Wl___as_needed" = x"yes"; then + LDFLAGS="$LDFLAGS -Wl,--as-needed" +fi fi @@ -29048,7 +29642,8 @@ $as_echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;} # Create compiler version string if test x"$GCC" = x"yes" ; then - cc_string="GCC `${CC} --version | sed q`" + cc_string=`${CC} --version | sed q` + case $cc_string in [A-Za-z]*) ;; *) cc_string="GCC $cc_string";; esac elif test x"$SUN_STUDIO_CC" = x"yes" ; then cc_string=`${CC} -V 2>&1 | sed q` else @@ -29098,7 +29693,7 @@ fi ac_config_files="$ac_config_files GNUmakefile src/Makefile.global" -ac_config_links="$ac_config_links src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION} src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION} src/include/dynloader.h:src/backend/port/dynloader/${template}.h src/include/pg_config_os.h:src/include/port/${template}.h src/Makefile.port:src/makefiles/Makefile.${template}" +ac_config_links="$ac_config_links src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION} src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION} src/backend/port/pg_latch.c:${LATCH_IMPLEMENTATION} src/include/dynloader.h:src/backend/port/dynloader/${template}.h src/include/pg_config_os.h:src/include/port/${template}.h src/Makefile.port:src/makefiles/Makefile.${template}" if test "$PORTNAME" = "win32"; then @@ -29532,7 +30127,7 @@ exec 6>&1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by PostgreSQL $as_me 9.0beta3, which was +This file was extended by PostgreSQL $as_me 9.2devel, which was generated by GNU Autoconf 2.63. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -29599,7 +30194,7 @@ Report bugs to ." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_version="\\ -PostgreSQL config.status 9.0beta3 +PostgreSQL config.status 9.2devel configured by $0, generated by GNU Autoconf 2.63, with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" @@ -29722,6 +30317,7 @@ do "src/backend/port/dynloader.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;; "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;; "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;; + "src/backend/port/pg_latch.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_latch.c:${LATCH_IMPLEMENTATION}" ;; "src/include/dynloader.h") CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;; "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;; "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;