]> granicus.if.org Git - postgresql/blobdiff - configure
If a loadable module has wrong values in its magic block, spell out
[postgresql] / configure
index c5fb6e838b6072ff540e25525847a9f112854a88..b8a7287efa8d294be77401f001bf406ff451b35e 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.61 for PostgreSQL 8.3beta3.
+# Generated by GNU Autoconf 2.61 for PostgreSQL 8.4devel.
 #
 # Report bugs to <pgsql-bugs@postgresql.org>.
 #
@@ -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-2007, PostgreSQL Global Development Group
+# Copyright (c) 1996-2008, PostgreSQL Global Development Group
 ## --------------------- ##
 ## M4sh Initialization.  ##
 ## --------------------- ##
@@ -576,8 +576,8 @@ SHELL=${CONFIG_SHELL-/bin/sh}
 # Identity of this package.
 PACKAGE_NAME='PostgreSQL'
 PACKAGE_TARNAME='postgresql'
-PACKAGE_VERSION='8.3beta3'
-PACKAGE_STRING='PostgreSQL 8.3beta3'
+PACKAGE_VERSION='8.4devel'
+PACKAGE_STRING='PostgreSQL 8.4devel'
 PACKAGE_BUGREPORT='pgsql-bugs@postgresql.org'
 
 ac_unique_file="src/backend/access/common/heaptuple.c"
@@ -718,8 +718,8 @@ STRIP_SHARED_LIB
 TAR
 LN_S
 AWK
-YACC
-YFLAGS
+BISON
+BISONFLAGS
 FLEX
 FLEXFLAGS
 PERL
@@ -1277,7 +1277,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 8.3beta3 to adapt to many kinds of systems.
+\`configure' configures PostgreSQL 8.4devel to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1342,14 +1342,14 @@ fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of PostgreSQL 8.3beta3:";;
+     short | recursive ) echo "Configuration of PostgreSQL 8.4devel:";;
    esac
   cat <<\_ACEOF
 
 Optional Features:
   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
-  --enable-integer-datetimes  enable 64-bit integer date/time support
+  --disable-integer-datetimes  disable 64-bit integer date/time support
   --enable-nls[=LANGUAGES]  enable Native Language Support
   --disable-shared        do not build shared libraries
   --disable-rpath         do not embed shared library search path in executables
@@ -1361,18 +1361,22 @@ Optional Features:
   --enable-cassert        enable assertion checks (for debugging)
   --enable-thread-safety  make client libraries thread-safe
   --enable-thread-safety-force  force thread-safety despite thread test failure
+  --disable-float4-byval  disable float4 passed by value
+  --disable-float8-byval  disable float8 passed by value
   --disable-largefile     omit support for large files
 
 Optional Packages:
   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
 
-  --with-docdir=DIR       install the documentation in DIR [PREFIX/doc]
-  --without-docdir        do not install the documentation
   --with-includes=DIRS    look for additional header files in DIRS
   --with-libraries=DIRS   look for additional libraries in DIRS
   --with-libs=DIRS        alternative spelling of --with-libraries
-  --with-pgport=PORTNUM   change default port number [5432]
+  --with-pgport=PORTNUM   set default port number [5432]
+  --with-blocksize=BLOCKSIZE  set table block size in kB [8]
+  --with-segsize=SEGSIZE  set table segment size in GB [1]
+  --with-wal-blocksize=BLOCKSIZE  set WAL block size in kB [8]
+  --with-wal-segsize=SEGSIZE  set WAL segment size in MB [16]
   --with-tcl              build Tcl modules (PL/Tcl)
   --with-tclconfig=DIR    tclConfig.sh is in DIR
   --with-perl             build Perl modules (PL/Perl)
@@ -1386,9 +1390,9 @@ Optional Packages:
   --with-openssl          build with OpenSSL 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        use OSSP UUID library when building contrib/uuid-ossp
   --with-libxml           build with XML support
-  --with-libxslt          use XSLT support when building /contrib/xml2
+  --with-libxslt          use XSLT support when building contrib/xml2
   --with-system-tzdata=DIR  use system time zone data in DIR
   --without-zlib          do not use Zlib
   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
@@ -1470,7 +1474,7 @@ fi
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-PostgreSQL configure 8.3beta3
+PostgreSQL configure 8.4devel
 generated by GNU Autoconf 2.61
 
 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1478,7 +1482,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-2007, PostgreSQL Global Development Group
+Copyright (c) 1996-2008, PostgreSQL Global Development Group
 _ACEOF
   exit
 fi
@@ -1486,7 +1490,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 8.3beta3, which was
+It was created by PostgreSQL $as_me 8.4devel, which was
 generated by GNU Autoconf 2.61.  Invocation command line was
 
   $ $0 $@
@@ -2087,38 +2091,6 @@ tas_file=dummy.s
 ## Command line options
 ##
 
-#
-# Installation directory for documentation
-#
-
-pgac_args="$pgac_args with_docdir"
-
-
-# Check whether --with-docdir was given.
-if test "${with_docdir+set}" = set; then
-  withval=$with_docdir;
-  case $withval in
-    yes)
-      { { echo "$as_me:$LINENO: error: option --with-docdir requires an argument" >&5
-echo "$as_me: error: option --with-docdir requires an argument" >&2;}
-   { (exit 1); exit 1; }; }
-      ;;
-    no)
-      docdir=
-      ;;
-    *)
-      docdir=$withval
-      ;;
-  esac
-
-else
-  docdir='${prefix}/doc'
-fi
-
-
-
-
-
 #
 # Add non-standard directories to the include path
 #
@@ -2209,7 +2181,7 @@ fi
 
 
 #
-# 64-bit integer date/time storage (--enable-integer-datetimes)
+# 64-bit integer date/time storage: enabled by default.
 #
 { echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
 echo $ECHO_N "checking whether to build with 64-bit integer date/time support... $ECHO_C" >&6; }
@@ -2238,7 +2210,11 @@ echo "$as_me: error: no argument expected for --enable-integer-datetimes option"
   esac
 
 else
-  enable_integer_datetimes=no
+  enable_integer_datetimes=yes
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_INTEGER_DATETIMES 1
+_ACEOF
 
 fi
 
@@ -2575,6 +2551,213 @@ fi
 
 
 
+#
+# Block size
+#
+{ echo "$as_me:$LINENO: checking for block size" >&5
+echo $ECHO_N "checking for block size... $ECHO_C" >&6; }
+
+pgac_args="$pgac_args with_blocksize"
+
+
+# Check whether --with-blocksize was given.
+if test "${with_blocksize+set}" = set; then
+  withval=$with_blocksize;
+  case $withval in
+    yes)
+      { { echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
+echo "$as_me: error: argument required for --with-blocksize option" >&2;}
+   { (exit 1); exit 1; }; }
+      ;;
+    no)
+      { { echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
+echo "$as_me: error: argument required for --with-blocksize option" >&2;}
+   { (exit 1); exit 1; }; }
+      ;;
+    *)
+      blocksize=$withval
+      ;;
+  esac
+
+else
+  blocksize=8
+fi
+
+
+case ${blocksize} in
+  1) BLCKSZ=1024;;
+  2) BLCKSZ=2048;;
+  4) BLCKSZ=4096;;
+  8) BLCKSZ=8192;;
+ 16) BLCKSZ=16384;;
+ 32) BLCKSZ=32768;;
+  *) { { echo "$as_me:$LINENO: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&5
+echo "$as_me: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&2;}
+   { (exit 1); exit 1; }; }
+esac
+{ echo "$as_me:$LINENO: result: ${blocksize}kB" >&5
+echo "${ECHO_T}${blocksize}kB" >&6; }
+
+
+cat >>confdefs.h <<_ACEOF
+#define BLCKSZ ${BLCKSZ}
+_ACEOF
+
+
+#
+# Relation segment size
+#
+{ echo "$as_me:$LINENO: checking for segment size" >&5
+echo $ECHO_N "checking for segment size... $ECHO_C" >&6; }
+
+pgac_args="$pgac_args with_segsize"
+
+
+# Check whether --with-segsize was given.
+if test "${with_segsize+set}" = set; then
+  withval=$with_segsize;
+  case $withval in
+    yes)
+      { { echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
+echo "$as_me: error: argument required for --with-segsize option" >&2;}
+   { (exit 1); exit 1; }; }
+      ;;
+    no)
+      { { echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
+echo "$as_me: error: argument required for --with-segsize option" >&2;}
+   { (exit 1); exit 1; }; }
+      ;;
+    *)
+      segsize=$withval
+      ;;
+  esac
+
+else
+  segsize=1
+fi
+
+
+# this expression is set up to avoid unnecessary integer overflow
+# blocksize is already guaranteed to be a factor of 1024
+RELSEG_SIZE=`expr '(' 1024 / ${blocksize} ')' '*' ${segsize} '*' 1024`
+test $? -eq 0 || exit 1
+{ echo "$as_me:$LINENO: result: ${segsize}GB" >&5
+echo "${ECHO_T}${segsize}GB" >&6; }
+
+
+cat >>confdefs.h <<_ACEOF
+#define RELSEG_SIZE ${RELSEG_SIZE}
+_ACEOF
+
+
+#
+# WAL block size
+#
+{ echo "$as_me:$LINENO: checking for WAL block size" >&5
+echo $ECHO_N "checking for WAL block size... $ECHO_C" >&6; }
+
+pgac_args="$pgac_args with_wal_blocksize"
+
+
+# Check whether --with-wal-blocksize was given.
+if test "${with_wal_blocksize+set}" = set; then
+  withval=$with_wal_blocksize;
+  case $withval in
+    yes)
+      { { echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
+echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
+   { (exit 1); exit 1; }; }
+      ;;
+    no)
+      { { echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
+echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
+   { (exit 1); exit 1; }; }
+      ;;
+    *)
+      wal_blocksize=$withval
+      ;;
+  esac
+
+else
+  wal_blocksize=8
+fi
+
+
+case ${wal_blocksize} in
+  1) XLOG_BLCKSZ=1024;;
+  2) XLOG_BLCKSZ=2048;;
+  4) XLOG_BLCKSZ=4096;;
+  8) XLOG_BLCKSZ=8192;;
+ 16) XLOG_BLCKSZ=16384;;
+ 32) XLOG_BLCKSZ=32768;;
+ 64) XLOG_BLCKSZ=65536;;
+  *) { { echo "$as_me:$LINENO: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&5
+echo "$as_me: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&2;}
+   { (exit 1); exit 1; }; }
+esac
+{ echo "$as_me:$LINENO: result: ${wal_blocksize}kB" >&5
+echo "${ECHO_T}${wal_blocksize}kB" >&6; }
+
+
+cat >>confdefs.h <<_ACEOF
+#define XLOG_BLCKSZ ${XLOG_BLCKSZ}
+_ACEOF
+
+
+#
+# WAL segment size
+#
+{ echo "$as_me:$LINENO: checking for WAL segment size" >&5
+echo $ECHO_N "checking for WAL segment size... $ECHO_C" >&6; }
+
+pgac_args="$pgac_args with_wal_segsize"
+
+
+# Check whether --with-wal-segsize was given.
+if test "${with_wal_segsize+set}" = set; then
+  withval=$with_wal_segsize;
+  case $withval in
+    yes)
+      { { echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
+echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
+   { (exit 1); exit 1; }; }
+      ;;
+    no)
+      { { echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
+echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
+   { (exit 1); exit 1; }; }
+      ;;
+    *)
+      wal_segsize=$withval
+      ;;
+  esac
+
+else
+  wal_segsize=16
+fi
+
+
+case ${wal_segsize} in
+  1) ;;
+  2) ;;
+  4) ;;
+  8) ;;
+ 16) ;;
+ 32) ;;
+ 64) ;;
+  *) { { echo "$as_me:$LINENO: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&5
+echo "$as_me: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&2;}
+   { (exit 1); exit 1; }; }
+esac
+{ echo "$as_me:$LINENO: result: ${wal_segsize}MB" >&5
+echo "${ECHO_T}${wal_segsize}MB" >&6; }
+
+
+cat >>confdefs.h <<_ACEOF
+#define XLOG_SEG_SIZE (${wal_segsize} * 1024 * 1024)
+_ACEOF
+
+
 #
 # C compiler
 #
@@ -3418,7 +3601,7 @@ fi
 # ICC pretends to be GCC but it's lying; it doesn't support these options.
 
 if test "$GCC" = yes -a "$ICC" = no; then
-  CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith -Winline"
+  CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith"
   # These work in some but not all gcc versions
   { echo "$as_me:$LINENO: checking if $CC supports -Wdeclaration-after-statement" >&5
 echo $ECHO_N "checking if $CC supports -Wdeclaration-after-statement... $ECHO_C" >&6; }
@@ -3566,6 +3749,56 @@ sed 's/^/| /' conftest.$ac_ext >&5
 echo "${ECHO_T}no" >&6; }
 fi
 
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+  # Disable optimizations that assume no overflow; needed for gcc 4.3+
+  { echo "$as_me:$LINENO: checking if $CC supports -fwrapv" >&5
+echo $ECHO_N "checking if $CC supports -fwrapv... $ECHO_C" >&6; }
+pgac_save_CFLAGS=$CFLAGS
+CFLAGS="$pgac_save_CFLAGS -fwrapv"
+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 "echo \"\$as_me:$LINENO: $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
+  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
+  { echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6; }
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       CFLAGS="$pgac_save_CFLAGS"
+                    { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 
 elif test "$ICC" = yes; then
@@ -3744,9 +3977,6 @@ echo "$as_me: error: --enable-profiling is supported only when using GCC" >&2;}
   fi
 fi
 
-{ echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
-echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
-
 # We already have this in Makefile.win32, but configure needs it too
 if test "$PORTNAME" = "win32"; then
   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
@@ -5253,11 +5483,6 @@ rm -f conftest*
 CPPFLAGS="$CPPFLAGS $INCLUDES"
 LDFLAGS="$LDFLAGS $LIBDIRS"
 
-{ echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
-echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
-{ echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
-echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
-
 
 
 
@@ -5727,18 +5952,18 @@ done
 
 
 # Let the user override the search
-if test -z "$YACC"; then
-  for ac_prog in 'bison -y'
+if test -z "$BISON"; then
+  for ac_prog in bison
 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 "$as_me:$LINENO: checking for $ac_word" >&5
 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_YACC+set}" = set; then
+if test "${ac_cv_prog_BISON+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  if test -n "$YACC"; then
-  ac_cv_prog_YACC="$YACC" # Let the user override the test.
+  if test -n "$BISON"; then
+  ac_cv_prog_BISON="$BISON" # Let the user override the test.
 else
 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
 for as_dir in $PATH
@@ -5747,7 +5972,7 @@ do
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_YACC="$ac_prog"
+    ac_cv_prog_BISON="$ac_prog"
     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
     break 2
   fi
@@ -5757,26 +5982,26 @@ IFS=$as_save_IFS
 
 fi
 fi
-YACC=$ac_cv_prog_YACC
-if test -n "$YACC"; then
-  { echo "$as_me:$LINENO: result: $YACC" >&5
-echo "${ECHO_T}$YACC" >&6; }
+BISON=$ac_cv_prog_BISON
+if test -n "$BISON"; then
+  { echo "$as_me:$LINENO: result: $BISON" >&5
+echo "${ECHO_T}$BISON" >&6; }
 else
   { echo "$as_me:$LINENO: result: no" >&5
 echo "${ECHO_T}no" >&6; }
 fi
 
 
-  test -n "$YACC" && break
+  test -n "$BISON" && break
 done
 
 fi
 
-if test "$YACC"; then
-  pgac_yacc_version=`$YACC --version 2>/dev/null | sed q`
-  { echo "$as_me:$LINENO: using $pgac_yacc_version" >&5
-echo "$as_me: using $pgac_yacc_version" >&6;}
-  if echo "$pgac_yacc_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
+if test "$BISON"; then
+  pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
+  { echo "$as_me:$LINENO: using $pgac_bison_version" >&5
+echo "$as_me: using $pgac_bison_version" >&6;}
+  if echo "$pgac_bison_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
   then
     { echo "$as_me:$LINENO: WARNING:
 *** The installed version of Bison is too old to use with PostgreSQL.
@@ -5784,29 +6009,25 @@ echo "$as_me: using $pgac_yacc_version" >&6;}
 echo "$as_me: WARNING:
 *** The installed version of Bison is too old to use with PostgreSQL.
 *** Bison version 1.875 or later is required." >&2;}
-    YACC=""
+    BISON=""
   fi
 fi
 
-if test -z "$YACC"; then
+if test -z "$BISON"; then
   { echo "$as_me:$LINENO: WARNING:
 *** Without Bison you will not be able to build PostgreSQL from CVS 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.)  To use a different yacc program (possible,
-*** but not recommended), set the environment variable YACC before running
-*** 'configure'." >&5
+*** output is pre-generated.)" >&5
 echo "$as_me: WARNING:
 *** Without Bison you will not be able to build PostgreSQL from CVS 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.)  To use a different yacc program (possible,
-*** but not recommended), set the environment variable YACC before running
-*** 'configure'." >&2;}
+*** output is pre-generated.)" >&2;}
 fi
-# We don't need AC_SUBST(YACC) because AC_PATH_PROG did it
+# We don't need AC_SUBST(BISON) because AC_PATH_PROG did it
 
 
 { echo "$as_me:$LINENO: checking for flex" >&5
@@ -7950,9 +8171,9 @@ fi
 
 if test "$with_libxslt" = yes ; then
 
-{ echo "$as_me:$LINENO: checking for xsltLibxmlVersion in -lxslt" >&5
-echo $ECHO_N "checking for xsltLibxmlVersion in -lxslt... $ECHO_C" >&6; }
-if test "${ac_cv_lib_xslt_xsltLibxmlVersion+set}" = set; then
+{ echo "$as_me:$LINENO: checking for xsltCleanupGlobals in -lxslt" >&5
+echo $ECHO_N "checking for xsltCleanupGlobals in -lxslt... $ECHO_C" >&6; }
+if test "${ac_cv_lib_xslt_xsltCleanupGlobals+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
@@ -7970,11 +8191,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char xsltLibxmlVersion ();
+char xsltCleanupGlobals ();
 int
 main ()
 {
-return xsltLibxmlVersion ();
+return xsltCleanupGlobals ();
   ;
   return 0;
 }
@@ -7997,21 +8218,21 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_xslt_xsltLibxmlVersion=yes
+  ac_cv_lib_xslt_xsltCleanupGlobals=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_xslt_xsltLibxmlVersion=no
+       ac_cv_lib_xslt_xsltCleanupGlobals=no
 fi
 
 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
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltLibxmlVersion" >&5
-echo "${ECHO_T}$ac_cv_lib_xslt_xsltLibxmlVersion" >&6; }
-if test $ac_cv_lib_xslt_xsltLibxmlVersion = yes; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltCleanupGlobals" >&5
+echo "${ECHO_T}$ac_cv_lib_xslt_xsltCleanupGlobals" >&6; }
+if test $ac_cv_lib_xslt_xsltCleanupGlobals = yes; then
   cat >>confdefs.h <<_ACEOF
 #define HAVE_LIBXSLT 1
 _ACEOF
@@ -12847,7 +13068,6 @@ _ACEOF
 
 fi
 
-
 { echo "$as_me:$LINENO: checking for inline" >&5
 echo $ECHO_N "checking for inline... $ECHO_C" >&6; }
 if test "${ac_cv_c_inline+set}" = set; then
@@ -12864,7 +13084,7 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifndef __cplusplus
 typedef int foo_t;
 static $ac_kw foo_t static_foo () {return 0; }
-$ac_kw int foo () {return 0; }
+$ac_kw foo_t foo () {return 0; }
 #endif
 
 _ACEOF
@@ -12885,7 +13105,7 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
        } && test -s conftest.$ac_objext; then
-  ac_cv_c_inline=$ac_kw; break
+  ac_cv_c_inline=$ac_kw
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
@@ -12894,22 +13114,27 @@ sed 's/^/| /' conftest.$ac_ext >&5
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+  test "$ac_cv_c_inline" != no && break
 done
 
 fi
 { echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
 echo "${ECHO_T}$ac_cv_c_inline" >&6; }
+
+
 case $ac_cv_c_inline in
   inline | yes) ;;
-  no)
-cat >>confdefs.h <<\_ACEOF
-#define inline
-_ACEOF
- ;;
-  *)  cat >>confdefs.h <<_ACEOF
-#define inline $ac_cv_c_inline
+  *)
+    case $ac_cv_c_inline in
+      no) ac_val=;;
+      *) ac_val=$ac_cv_c_inline;;
+    esac
+    cat >>confdefs.h <<_ACEOF
+#ifndef __cplusplus
+#define inline $ac_val
+#endif
 _ACEOF
- ;;
   ;;
 esac
 
 { echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
@@ -16439,8 +16664,7 @@ LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
 
 
 
-
-for ac_func in crypt fseeko getopt getrusage inet_aton random rint srandom strdup strerror strlcat strlcpy strtol strtoul unsetenv
+for ac_func in crypt getopt getrusage inet_aton random rint srandom strdup strerror strlcat strlcpy strtol strtoul unsetenv
 do
 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
 { echo "$as_me:$LINENO: checking for $ac_func" >&5
@@ -16661,8 +16885,23 @@ esac
 
 fi
 
-# similarly, use system's getopt_long() only if system provides struct option.
-if test x"$ac_cv_type_struct_option" = xyes ; then
+# Similarly, use system's getopt_long() only if system provides struct option.
+# Solaris' getopt() doesn't do what we want for long options, so always use
+# our versions on that platform.
+if test "$PORTNAME" = "solaris"; 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
+
+elif test x"$ac_cv_type_struct_option" = xyes ; then
 
 for ac_func in getopt_long
 do
@@ -16774,13 +17013,6 @@ esac
 
 fi
 
-# BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
-# We override the previous test that said fseeko/ftello didn't exist
-# OS tests are also done in include/c.h and port/fseeko.c
-case $host_os in bsdi*|netbsd*)
-ac_cv_func_fseeko=yes
-esac
-
 # Win32 support
 if test "$PORTNAME" = "win32"; then
 
 done
 
 
-{ echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
-echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6; }
-if test "${ac_cv_sys_largefile_source+set}" = set; then
+
+for ac_func in fseeko
+do
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+{ echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
+if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  while :; do
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <stdio.h>
-int
-main ()
-{
-return fseeko (stdin, 0, 0) && (fseeko) (stdin, 0, 0);
-  ;
-  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 "echo \"\$as_me:$LINENO: $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
-  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 &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_sys_largefile_source=no; break
-else
-  echo "$as_me: failed program was:" >&5
+/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
+   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
+#define $ac_func innocuous_$ac_func
+
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char $ac_func (); below.
+    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+    <limits.h> exists even on freestanding compilers.  */
+
+#ifdef __STDC__
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+
+#undef $ac_func
+
+/* 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 $ac_func ();
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined __stub_$ac_func || defined __stub___$ac_func
+choke me
+#endif
+
+int
+main ()
+{
+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 "echo \"\$as_me:$LINENO: $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
+  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 &&
+       $as_test_x conftest$ac_exeext; then
+  eval "$as_ac_var=yes"
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       eval "$as_ac_var=no"
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+fi
+ac_res=`eval echo '${'$as_ac_var'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define `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 $host_os in
+       # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
+       bsdi*|netbsd*)
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_FSEEKO 1
+_ACEOF
+
+               ac_cv_func_fseeko=yes;;
+       *)
+               { echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
+echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6; }
+if test "${ac_cv_sys_largefile_source+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  while :; do
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#include <sys/types.h> /* for off_t */
+     #include <stdio.h>
+int
+main ()
+{
+int (*fp) (FILE *, off_t, int) = fseeko;
+     return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
+  ;
+  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 "echo \"\$as_me:$LINENO: $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
+  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 &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_sys_largefile_source=no; break
+else
+  echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
 
@@ -18021,11 +18367,13 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 #define _LARGEFILE_SOURCE 1
-#include <stdio.h>
+#include <sys/types.h> /* for off_t */
+     #include <stdio.h>
 int
 main ()
 {
-return fseeko (stdin, 0, 0) && (fseeko) (stdin, 0, 0);
+int (*fp) (FILE *, off_t, int) = fseeko;
+     return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
   ;
   return 0;
 }
@@ -18084,6 +18432,8 @@ cat >>confdefs.h <<\_ACEOF
 _ACEOF
 
 fi
+;;
+esac
 
 
 #
@@ -18861,7 +19211,7 @@ done
 # Do test here with the proper thread flags
 { echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
 echo $ECHO_N "checking whether getpwuid_r takes a fifth argument... $ECHO_C" >&6; }
-if test "${pgac_func_getpwuid_r_5arg+set}" = set; then
+if test "${pgac_cv_func_getpwuid_r_5arg+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   cat >conftest.$ac_ext <<_ACEOF
@@ -18902,19 +19252,19 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
        } && test -s conftest.$ac_objext; then
-  pgac_func_getpwuid_r_5arg=yes
+  pgac_cv_func_getpwuid_r_5arg=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       pgac_func_getpwuid_r_5arg=no
+       pgac_cv_func_getpwuid_r_5arg=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-{ echo "$as_me:$LINENO: result: $pgac_func_getpwuid_r_5arg" >&5
-echo "${ECHO_T}$pgac_func_getpwuid_r_5arg" >&6; }
-if test x"$pgac_func_getpwuid_r_5arg" = xyes ; then
+{ echo "$as_me:$LINENO: result: $pgac_cv_func_getpwuid_r_5arg" >&5
+echo "${ECHO_T}$pgac_cv_func_getpwuid_r_5arg" >&6; }
+if test x"$pgac_cv_func_getpwuid_r_5arg" = xyes ; then
 
 cat >>confdefs.h <<\_ACEOF
 #define GETPWUID_R_5ARG
@@ -18924,7 +19274,7 @@ fi
 
 { echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
 echo $ECHO_N "checking whether strerror_r returns int... $ECHO_C" >&6; }
-if test "${pgac_func_strerror_r_int+set}" = set; then
+if test "${pgac_cv_func_strerror_r_int+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   cat >conftest.$ac_ext <<_ACEOF
@@ -18964,19 +19314,19 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
        } && test -s conftest.$ac_objext; then
-  pgac_func_strerror_r_int=yes
+  pgac_cv_func_strerror_r_int=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       pgac_func_strerror_r_int=no
+       pgac_cv_func_strerror_r_int=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-{ echo "$as_me:$LINENO: result: $pgac_func_strerror_r_int" >&5
-echo "${ECHO_T}$pgac_func_strerror_r_int" >&6; }
-if test x"$pgac_func_strerror_r_int" = xyes ; then
+{ echo "$as_me:$LINENO: result: $pgac_cv_func_strerror_r_int" >&5
+echo "${ECHO_T}$pgac_cv_func_strerror_r_int" >&6; }
+if test x"$pgac_cv_func_strerror_r_int" = xyes ; then
 
 cat >>confdefs.h <<\_ACEOF
 #define STRERROR_R_INT
@@ -19513,7 +19863,7 @@ HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
 if test x"$pgac_cv_type_long_int_64" = xyes ; then
 
 cat >>confdefs.h <<\_ACEOF
-#define HAVE_LONG_INT_64
+#define HAVE_LONG_INT_64 1
 _ACEOF
 
 fi
@@ -19646,7 +19996,7 @@ HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
 
 cat >>confdefs.h <<\_ACEOF
-#define HAVE_LONG_LONG_INT_64
+#define HAVE_LONG_LONG_INT_64 1
 _ACEOF
 
 fi
@@ -20658,6 +21008,137 @@ _ACEOF
 
 
 
+# Decide whether float4 is passed by value: user-selectable, enabled by default
+{ echo "$as_me:$LINENO: checking whether to build with float4 passed by value" >&5
+echo $ECHO_N "checking whether to build with float4 passed by value... $ECHO_C" >&6; }
+
+pgac_args="$pgac_args enable_float4_byval"
+
+# Check whether --enable-float4-byval was given.
+if test "${enable_float4_byval+set}" = set; then
+  enableval=$enable_float4_byval;
+  case $enableval in
+    yes)
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_FLOAT4_BYVAL 1
+_ACEOF
+
+               float4passbyval=true
+      ;;
+    no)
+      float4passbyval=false
+      ;;
+    *)
+      { { echo "$as_me:$LINENO: error: no argument expected for --enable-float4-byval option" >&5
+echo "$as_me: error: no argument expected for --enable-float4-byval option" >&2;}
+   { (exit 1); exit 1; }; }
+      ;;
+  esac
+
+else
+  enable_float4_byval=yes
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_FLOAT4_BYVAL 1
+_ACEOF
+
+               float4passbyval=true
+fi
+
+
+{ echo "$as_me:$LINENO: result: $enable_float4_byval" >&5
+echo "${ECHO_T}$enable_float4_byval" >&6; }
+
+cat >>confdefs.h <<_ACEOF
+#define FLOAT4PASSBYVAL $float4passbyval
+_ACEOF
+
+
+# Decide whether float8 is passed by value.
+# Note: this setting also controls int8 and related types such as timestamp.
+# If sizeof(Datum) >= 8, this is user-selectable, enabled by default.
+# If not, trying to select it is an error.
+{ echo "$as_me:$LINENO: checking whether to build with float8 passed by value" >&5
+echo $ECHO_N "checking whether to build with float8 passed by value... $ECHO_C" >&6; }
+if test $ac_cv_sizeof_unsigned_long -ge 8 ; then
+
+pgac_args="$pgac_args enable_float8_byval"
+
+# Check whether --enable-float8-byval was given.
+if test "${enable_float8_byval+set}" = set; then
+  enableval=$enable_float8_byval;
+  case $enableval in
+    yes)
+      :
+      ;;
+    no)
+      :
+      ;;
+    *)
+      { { echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
+echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
+   { (exit 1); exit 1; }; }
+      ;;
+  esac
+
+else
+  enable_float8_byval=yes
+
+fi
+
+
+else
+
+pgac_args="$pgac_args enable_float8_byval"
+
+# Check whether --enable-float8-byval was given.
+if test "${enable_float8_byval+set}" = set; then
+  enableval=$enable_float8_byval;
+  case $enableval in
+    yes)
+      :
+      ;;
+    no)
+      :
+      ;;
+    *)
+      { { echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
+echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
+   { (exit 1); exit 1; }; }
+      ;;
+  esac
+
+else
+  enable_float8_byval=no
+
+fi
+
+
+  if test "$enable_float8_byval" = yes ; then
+    { { echo "$as_me:$LINENO: error: --enable-float8-byval is not supported on 32-bit platforms." >&5
+echo "$as_me: error: --enable-float8-byval is not supported on 32-bit platforms." >&2;}
+   { (exit 1); exit 1; }; }
+  fi
+fi
+if test "$enable_float8_byval" = yes ; then
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_FLOAT8_BYVAL 1
+_ACEOF
+
+  float8passbyval=true
+else
+  float8passbyval=false
+fi
+{ echo "$as_me:$LINENO: result: $enable_float8_byval" >&5
+echo "${ECHO_T}$enable_float8_byval" >&6; }
+
+cat >>confdefs.h <<_ACEOF
+#define FLOAT8PASSBYVAL $float8passbyval
+_ACEOF
+
+
 # Determine memory alignment requirements for the basic C data types.
 
 { echo "$as_me:$LINENO: checking for short" >&5
 { echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
 echo "${ECHO_T}$ac_cv_type_short" >&6; }
 
+# The cast to long int works around a bug in the HP C Compiler,
+# see AC_CHECK_SIZEOF for more information.
 { echo "$as_me:$LINENO: checking alignment of short" >&5
 echo $ECHO_N "checking alignment of short... $ECHO_C" >&6; }
-if test "${pgac_cv_alignof_short+set}" = set; then
+if test "${ac_cv_alignof_short+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  if test "$ac_cv_type_short" = yes; then
   if test "$cross_compiling" = yes; then
   # Depending upon the size, compute the lo and hi bounds.
 cat >conftest.$ac_ext <<_ACEOF
@@ -20729,11 +21211,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; short field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; short y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
 test_array [0] = 0
 
   ;
@@ -20766,11 +21251,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; short field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; short y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
 test_array [0] = 0
 
   ;
@@ -20820,11 +21308,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; short field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; short y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
 test_array [0] = 0
 
   ;
@@ -20857,11 +21348,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; short field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; short y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
 test_array [0] = 0
 
   ;
@@ -20921,11 +21415,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; short field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; short y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
 test_array [0] = 0
 
   ;
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 done
 case $ac_lo in
-?*) pgac_cv_alignof_short=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
-echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
-   { (exit 1); exit 1; }; } ;;
+?*) ac_cv_alignof_short=$ac_lo;;
+'') if test "$ac_cv_type_short" = yes; then
+     { { echo "$as_me:$LINENO: error: cannot compute alignment of short
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute alignment of short
+See \`config.log' for more details." >&2;}
+   { (exit 77); exit 77; }; }
+   else
+     ac_cv_alignof_short=0
+   fi ;;
 esac
 else
   cat >conftest.$ac_ext <<_ACEOF
@@ -20973,9 +21476,12 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; short field; } pgac_struct;
-static long int longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
-static unsigned long int ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; short y; } ac__type_alignof_;
+static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
+static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
 #include <stdio.h>
 #include <stdlib.h>
 int
@@ -20985,17 +21491,17 @@ main ()
   FILE *f = fopen ("conftest.val", "w");
   if (! f)
     return 1;
-  if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
+  if (((long int) offsetof (ac__type_alignof_, y)) < 0)
     {
       long int i = longval ();
-      if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
+      if (i != ((long int) offsetof (ac__type_alignof_, y)))
        return 1;
       fprintf (f, "%ld\n", i);
     }
   else
     {
       unsigned long int i = ulongval ();
-      if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
+      if (i != ((long int) offsetof (ac__type_alignof_, y)))
        return 1;
       fprintf (f, "%lu\n", i);
     }
@@ -21025,29 +21531,34 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  pgac_cv_alignof_short=`cat conftest.val`
+  ac_cv_alignof_short=`cat conftest.val`
 else
   echo "$as_me: program exited with status $ac_status" >&5
 echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
 ( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
-echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
-   { (exit 1); exit 1; }; }
+if test "$ac_cv_type_short" = yes; then
+     { { echo "$as_me:$LINENO: error: cannot compute alignment of short
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute alignment of short
+See \`config.log' for more details." >&2;}
+   { (exit 77); exit 77; }; }
+   else
+     ac_cv_alignof_short=0
+   fi
 fi
 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
 fi
 rm -f conftest.val
-
-else
-  pgac_cv_alignof_short=0
-fi
 fi
-{ echo "$as_me:$LINENO: result: $pgac_cv_alignof_short" >&5
-echo "${ECHO_T}$pgac_cv_alignof_short" >&6; }
+{ echo "$as_me:$LINENO: result: $ac_cv_alignof_short" >&5
+echo "${ECHO_T}$ac_cv_alignof_short" >&6; }
+
+
+
 cat >>confdefs.h <<_ACEOF
-#define ALIGNOF_SHORT $pgac_cv_alignof_short
+#define ALIGNOF_SHORT $ac_cv_alignof_short
 _ACEOF
 
 
 { echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
 echo "${ECHO_T}$ac_cv_type_int" >&6; }
 
+# The cast to long int works around a bug in the HP C Compiler,
+# see AC_CHECK_SIZEOF for more information.
 { echo "$as_me:$LINENO: checking alignment of int" >&5
 echo $ECHO_N "checking alignment of int... $ECHO_C" >&6; }
-if test "${pgac_cv_alignof_int+set}" = set; then
+if test "${ac_cv_alignof_int+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  if test "$ac_cv_type_int" = yes; then
   if test "$cross_compiling" = yes; then
   # Depending upon the size, compute the lo and hi bounds.
 cat >conftest.$ac_ext <<_ACEOF
@@ -21120,11 +21632,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; int field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; int y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
 test_array [0] = 0
 
   ;
@@ -21157,11 +21672,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; int field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; int y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
 test_array [0] = 0
 
   ;
@@ -21211,11 +21729,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; int field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; int y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
 test_array [0] = 0
 
   ;
@@ -21248,11 +21769,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; int field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; int y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
 test_array [0] = 0
 
   ;
@@ -21312,11 +21836,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; int field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; int y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
 test_array [0] = 0
 
   ;
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 done
 case $ac_lo in
-?*) pgac_cv_alignof_int=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
-echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
-   { (exit 1); exit 1; }; } ;;
+?*) ac_cv_alignof_int=$ac_lo;;
+'') if test "$ac_cv_type_int" = yes; then
+     { { echo "$as_me:$LINENO: error: cannot compute alignment of int
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute alignment of int
+See \`config.log' for more details." >&2;}
+   { (exit 77); exit 77; }; }
+   else
+     ac_cv_alignof_int=0
+   fi ;;
 esac
 else
   cat >conftest.$ac_ext <<_ACEOF
@@ -21364,9 +21897,12 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; int field; } pgac_struct;
-static long int longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
-static unsigned long int ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; int y; } ac__type_alignof_;
+static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
+static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
 #include <stdio.h>
 #include <stdlib.h>
 int
@@ -21376,17 +21912,17 @@ main ()
   FILE *f = fopen ("conftest.val", "w");
   if (! f)
     return 1;
-  if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
+  if (((long int) offsetof (ac__type_alignof_, y)) < 0)
     {
       long int i = longval ();
-      if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
+      if (i != ((long int) offsetof (ac__type_alignof_, y)))
        return 1;
       fprintf (f, "%ld\n", i);
     }
   else
     {
       unsigned long int i = ulongval ();
-      if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
+      if (i != ((long int) offsetof (ac__type_alignof_, y)))
        return 1;
       fprintf (f, "%lu\n", i);
     }
@@ -21416,29 +21952,34 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  pgac_cv_alignof_int=`cat conftest.val`
+  ac_cv_alignof_int=`cat conftest.val`
 else
   echo "$as_me: program exited with status $ac_status" >&5
 echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
 ( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
-echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
-   { (exit 1); exit 1; }; }
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+if test "$ac_cv_type_int" = yes; then
+     { { echo "$as_me:$LINENO: error: cannot compute alignment of int
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute alignment of int
+See \`config.log' for more details." >&2;}
+   { (exit 77); exit 77; }; }
+   else
+     ac_cv_alignof_int=0
+   fi
 fi
-rm -f conftest.val
-
-else
-  pgac_cv_alignof_int=0
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
 fi
+rm -f conftest.val
 fi
-{ echo "$as_me:$LINENO: result: $pgac_cv_alignof_int" >&5
-echo "${ECHO_T}$pgac_cv_alignof_int" >&6; }
+{ echo "$as_me:$LINENO: result: $ac_cv_alignof_int" >&5
+echo "${ECHO_T}$ac_cv_alignof_int" >&6; }
+
+
+
 cat >>confdefs.h <<_ACEOF
-#define ALIGNOF_INT $pgac_cv_alignof_int
+#define ALIGNOF_INT $ac_cv_alignof_int
 _ACEOF
 
 
 { echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
 echo "${ECHO_T}$ac_cv_type_long" >&6; }
 
+# The cast to long int works around a bug in the HP C Compiler,
+# see AC_CHECK_SIZEOF for more information.
 { echo "$as_me:$LINENO: checking alignment of long" >&5
 echo $ECHO_N "checking alignment of long... $ECHO_C" >&6; }
-if test "${pgac_cv_alignof_long+set}" = set; then
+if test "${ac_cv_alignof_long+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  if test "$ac_cv_type_long" = yes; then
   if test "$cross_compiling" = yes; then
   # Depending upon the size, compute the lo and hi bounds.
 cat >conftest.$ac_ext <<_ACEOF
@@ -21511,11 +22053,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; long field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; long y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
 test_array [0] = 0
 
   ;
@@ -21548,11 +22093,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; long field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; long y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
 test_array [0] = 0
 
   ;
@@ -21602,11 +22150,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; long field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; long y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
 test_array [0] = 0
 
   ;
@@ -21639,11 +22190,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; long field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; long y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
 test_array [0] = 0
 
   ;
@@ -21703,11 +22257,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; long field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; long y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
 test_array [0] = 0
 
   ;
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 done
 case $ac_lo in
-?*) pgac_cv_alignof_long=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
-echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
-   { (exit 1); exit 1; }; } ;;
+?*) ac_cv_alignof_long=$ac_lo;;
+'') if test "$ac_cv_type_long" = yes; then
+     { { echo "$as_me:$LINENO: error: cannot compute alignment of long
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute alignment of long
+See \`config.log' for more details." >&2;}
+   { (exit 77); exit 77; }; }
+   else
+     ac_cv_alignof_long=0
+   fi ;;
 esac
 else
   cat >conftest.$ac_ext <<_ACEOF
@@ -21755,9 +22318,12 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; long field; } pgac_struct;
-static long int longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
-static unsigned long int ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; long y; } ac__type_alignof_;
+static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
+static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
 #include <stdio.h>
 #include <stdlib.h>
 int
@@ -21767,17 +22333,17 @@ main ()
   FILE *f = fopen ("conftest.val", "w");
   if (! f)
     return 1;
-  if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
+  if (((long int) offsetof (ac__type_alignof_, y)) < 0)
     {
       long int i = longval ();
-      if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
+      if (i != ((long int) offsetof (ac__type_alignof_, y)))
        return 1;
       fprintf (f, "%ld\n", i);
     }
   else
     {
       unsigned long int i = ulongval ();
-      if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
+      if (i != ((long int) offsetof (ac__type_alignof_, y)))
        return 1;
       fprintf (f, "%lu\n", i);
     }
@@ -21807,29 +22373,34 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  pgac_cv_alignof_long=`cat conftest.val`
+  ac_cv_alignof_long=`cat conftest.val`
 else
   echo "$as_me: program exited with status $ac_status" >&5
 echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
 ( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
-echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
-   { (exit 1); exit 1; }; }
+if test "$ac_cv_type_long" = yes; then
+     { { echo "$as_me:$LINENO: error: cannot compute alignment of long
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute alignment of long
+See \`config.log' for more details." >&2;}
+   { (exit 77); exit 77; }; }
+   else
+     ac_cv_alignof_long=0
+   fi
 fi
 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
 fi
 rm -f conftest.val
-
-else
-  pgac_cv_alignof_long=0
-fi
 fi
-{ echo "$as_me:$LINENO: result: $pgac_cv_alignof_long" >&5
-echo "${ECHO_T}$pgac_cv_alignof_long" >&6; }
+{ echo "$as_me:$LINENO: result: $ac_cv_alignof_long" >&5
+echo "${ECHO_T}$ac_cv_alignof_long" >&6; }
+
+
+
 cat >>confdefs.h <<_ACEOF
-#define ALIGNOF_LONG $pgac_cv_alignof_long
+#define ALIGNOF_LONG $ac_cv_alignof_long
 _ACEOF
 
 
 { echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
 echo "${ECHO_T}$ac_cv_type_long_long_int" >&6; }
 
+# The cast to long int works around a bug in the HP C Compiler,
+# see AC_CHECK_SIZEOF for more information.
 { echo "$as_me:$LINENO: checking alignment of long long int" >&5
 echo $ECHO_N "checking alignment of long long int... $ECHO_C" >&6; }
-if test "${pgac_cv_alignof_long_long_int+set}" = set; then
+if test "${ac_cv_alignof_long_long_int+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  if test "$ac_cv_type_long_long_int" = yes; then
   if test "$cross_compiling" = yes; then
   # Depending upon the size, compute the lo and hi bounds.
 cat >conftest.$ac_ext <<_ACEOF
@@ -21903,11 +22475,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; long long int field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; long long int y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
 test_array [0] = 0
 
   ;
@@ -21940,11 +22515,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; long long int field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; long long int y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
 test_array [0] = 0
 
   ;
@@ -21994,11 +22572,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; long long int field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; long long int y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
 test_array [0] = 0
 
   ;
@@ -22031,11 +22612,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; long long int field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; long long int y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
 test_array [0] = 0
 
   ;
@@ -22095,11 +22679,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; long long int field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; long long int y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
 test_array [0] = 0
 
   ;
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 done
 case $ac_lo in
-?*) pgac_cv_alignof_long_long_int=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
-echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
-   { (exit 1); exit 1; }; } ;;
+?*) ac_cv_alignof_long_long_int=$ac_lo;;
+'') if test "$ac_cv_type_long_long_int" = yes; then
+     { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute alignment of long long int
+See \`config.log' for more details." >&2;}
+   { (exit 77); exit 77; }; }
+   else
+     ac_cv_alignof_long_long_int=0
+   fi ;;
 esac
 else
   cat >conftest.$ac_ext <<_ACEOF
@@ -22147,9 +22740,12 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; long long int field; } pgac_struct;
-static long int longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
-static unsigned long int ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; long long int y; } ac__type_alignof_;
+static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
+static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
 #include <stdio.h>
 #include <stdlib.h>
 int
@@ -22159,17 +22755,17 @@ main ()
   FILE *f = fopen ("conftest.val", "w");
   if (! f)
     return 1;
-  if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
+  if (((long int) offsetof (ac__type_alignof_, y)) < 0)
     {
       long int i = longval ();
-      if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
+      if (i != ((long int) offsetof (ac__type_alignof_, y)))
        return 1;
       fprintf (f, "%ld\n", i);
     }
   else
     {
       unsigned long int i = ulongval ();
-      if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
+      if (i != ((long int) offsetof (ac__type_alignof_, y)))
        return 1;
       fprintf (f, "%lu\n", i);
     }
@@ -22199,29 +22795,34 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  pgac_cv_alignof_long_long_int=`cat conftest.val`
+  ac_cv_alignof_long_long_int=`cat conftest.val`
 else
   echo "$as_me: program exited with status $ac_status" >&5
 echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
 ( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
-echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
-   { (exit 1); exit 1; }; }
+if test "$ac_cv_type_long_long_int" = yes; then
+     { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute alignment of long long int
+See \`config.log' for more details." >&2;}
+   { (exit 77); exit 77; }; }
+   else
+     ac_cv_alignof_long_long_int=0
+   fi
 fi
 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
 fi
 rm -f conftest.val
-
-else
-  pgac_cv_alignof_long_long_int=0
-fi
 fi
-{ echo "$as_me:$LINENO: result: $pgac_cv_alignof_long_long_int" >&5
-echo "${ECHO_T}$pgac_cv_alignof_long_long_int" >&6; }
+{ echo "$as_me:$LINENO: result: $ac_cv_alignof_long_long_int" >&5
+echo "${ECHO_T}$ac_cv_alignof_long_long_int" >&6; }
+
+
+
 cat >>confdefs.h <<_ACEOF
-#define ALIGNOF_LONG_LONG_INT $pgac_cv_alignof_long_long_int
+#define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
 _ACEOF
 
 
 { echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
 echo "${ECHO_T}$ac_cv_type_double" >&6; }
 
+# The cast to long int works around a bug in the HP C Compiler,
+# see AC_CHECK_SIZEOF for more information.
 { echo "$as_me:$LINENO: checking alignment of double" >&5
 echo $ECHO_N "checking alignment of double... $ECHO_C" >&6; }
-if test "${pgac_cv_alignof_double+set}" = set; then
+if test "${ac_cv_alignof_double+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  if test "$ac_cv_type_double" = yes; then
   if test "$cross_compiling" = yes; then
   # Depending upon the size, compute the lo and hi bounds.
 cat >conftest.$ac_ext <<_ACEOF
@@ -22295,11 +22897,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; double field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; double y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
 test_array [0] = 0
 
   ;
@@ -22332,11 +22937,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; double field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; double y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
 test_array [0] = 0
 
   ;
@@ -22386,11 +22994,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; double field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; double y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
 test_array [0] = 0
 
   ;
@@ -22423,11 +23034,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; double field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; double y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
 test_array [0] = 0
 
   ;
@@ -22487,11 +23101,14 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; double field; } pgac_struct;
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; double y; } ac__type_alignof_;
 int
 main ()
 {
-static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
 test_array [0] = 0
 
   ;
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 done
 case $ac_lo in
-?*) pgac_cv_alignof_double=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
-echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
-   { (exit 1); exit 1; }; } ;;
+?*) ac_cv_alignof_double=$ac_lo;;
+'') if test "$ac_cv_type_double" = yes; then
+     { { echo "$as_me:$LINENO: error: cannot compute alignment of double
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute alignment of double
+See \`config.log' for more details." >&2;}
+   { (exit 77); exit 77; }; }
+   else
+     ac_cv_alignof_double=0
+   fi ;;
 esac
 else
   cat >conftest.$ac_ext <<_ACEOF
@@ -22539,9 +23162,12 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-struct { char filler; double field; } pgac_struct;
-static long int longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
-static unsigned long int ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
+#ifndef offsetof
+# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
+#endif
+typedef struct { char x; double y; } ac__type_alignof_;
+static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
+static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
 #include <stdio.h>
 #include <stdlib.h>
 int
@@ -22551,17 +23177,17 @@ main ()
   FILE *f = fopen ("conftest.val", "w");
   if (! f)
     return 1;
-  if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
+  if (((long int) offsetof (ac__type_alignof_, y)) < 0)
     {
       long int i = longval ();
-      if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
+      if (i != ((long int) offsetof (ac__type_alignof_, y)))
        return 1;
       fprintf (f, "%ld\n", i);
     }
   else
     {
       unsigned long int i = ulongval ();
-      if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
+      if (i != ((long int) offsetof (ac__type_alignof_, y)))
        return 1;
       fprintf (f, "%lu\n", i);
     }
@@ -22591,29 +23217,34 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  pgac_cv_alignof_double=`cat conftest.val`
+  ac_cv_alignof_double=`cat conftest.val`
 else
   echo "$as_me: program exited with status $ac_status" >&5
 echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
 ( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
-echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
-   { (exit 1); exit 1; }; }
+if test "$ac_cv_type_double" = yes; then
+     { { echo "$as_me:$LINENO: error: cannot compute alignment of double
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute alignment of double
+See \`config.log' for more details." >&2;}
+   { (exit 77); exit 77; }; }
+   else
+     ac_cv_alignof_double=0
+   fi
 fi
 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
 fi
 rm -f conftest.val
-
-else
-  pgac_cv_alignof_double=0
-fi
 fi
-{ echo "$as_me:$LINENO: result: $pgac_cv_alignof_double" >&5
-echo "${ECHO_T}$pgac_cv_alignof_double" >&6; }
+{ echo "$as_me:$LINENO: result: $ac_cv_alignof_double" >&5
+echo "${ECHO_T}$ac_cv_alignof_double" >&6; }
+
+
+
 cat >>confdefs.h <<_ACEOF
-#define ALIGNOF_DOUBLE $pgac_cv_alignof_double
+#define ALIGNOF_DOUBLE $ac_cv_alignof_double
 _ACEOF
 
 
@@ -22622,12 +23253,12 @@ _ACEOF
 # We assume long's alignment is at least as strong as char, short, or int;
 # but we must check long long (if it exists) and double.
 
-MAX_ALIGNOF=$pgac_cv_alignof_long
-if test $MAX_ALIGNOF -lt $pgac_cv_alignof_double ; then
-  MAX_ALIGNOF=$pgac_cv_alignof_double
+MAX_ALIGNOF=$ac_cv_alignof_long
+if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
+  MAX_ALIGNOF=$ac_cv_alignof_double
 fi
-if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $pgac_cv_alignof_long_long_int ; then
-  MAX_ALIGNOF="$pgac_cv_alignof_long_long_int"
+if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
+  MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
 fi
 
 cat >>confdefs.h <<_ACEOF
 
 
 
+# If the user did not disable integer datetimes, check that
+# there is a working 64-bit integral type to use.
+if test x"$USE_INTEGER_DATETIMES" = x"yes" &&
+   test x"$HAVE_LONG_INT_64" = x"no" &&
+   test x"$HAVE_LONG_LONG_INT_64" = x"no" &&
+   test x"$HAVE_INT64" = x"no" ; then
+  { { echo "$as_me:$LINENO: error:
+Integer-based datetime support requires a 64-bit integer type,
+but no such type could be found. The --disable-integer-datetimes
+configure option can be used to disable integer-based storage
+of datetime values." >&5
+echo "$as_me: error:
+Integer-based datetime support requires a 64-bit integer type,
+but no such type could be found. The --disable-integer-datetimes
+configure option can be used to disable integer-based storage
+of datetime values." >&2;}
+   { (exit 1); exit 1; }; }
+fi
+
+
 if test "$PORTNAME" != "win32"
 then
 { echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
 
 fi
 
-# SunOS doesn't handle negative byte comparisons properly with +/- return
-{ echo "$as_me:$LINENO: checking for working memcmp" >&5
-echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6; }
-if test "${ac_cv_func_memcmp_working+set}" = set; then
+# Check for largefile support (must be after AC_SYS_LARGEFILE)
+{ echo "$as_me:$LINENO: checking for off_t" >&5
+echo $ECHO_N "checking for off_t... $ECHO_C" >&6; }
+if test "${ac_cv_type_off_t+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test "$cross_compiling" = yes; then
-  ac_cv_func_memcmp_working=no
 else
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
@@ -23413,179 +24061,596 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
+typedef off_t ac__type_new_;
 int
 main ()
 {
-
-  /* Some versions of memcmp are not 8-bit clean.  */
-  char c0 = '\100', c1 = '\200', c2 = '\201';
-  if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
-    return 1;
-
-  /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
-     or more and with at least one buffer not starting on a 4-byte boundary.
-     William Lewis provided this test program.   */
-  {
-    char foo[21];
-    char bar[21];
-    int i;
-    for (i = 0; i < 4; i++)
-      {
-       char *a = foo + i;
-       char *b = bar + i;
-       strcpy (a, "--------01111111");
-       strcpy (b, "--------10000000");
-       if (memcmp (a, b, 16) >= 0)
-         return 1;
-      }
-    return 0;
-  }
-
+if ((ac__type_new_ *) 0)
+  return 0;
+if (sizeof (ac__type_new_))
+  return 0;
   ;
   return 0;
 }
 _ACEOF
-rm -f 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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
-  { (case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_try") 2>&5
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  ac_cv_func_memcmp_working=yes
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
+        test ! -s conftest.err
+       } && test -s conftest.$ac_objext; then
+  ac_cv_type_off_t=yes
 else
-  echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
+  echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-( exit $ac_status )
-ac_cv_func_memcmp_working=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
-fi
-
-
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
-echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6; }
-test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in
-  *" memcmp.$ac_objext "* ) ;;
-  *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
- ;;
-esac
-
-
-
-
-# Select semaphore implementation type.
-if test "$PORTNAME" != "win32"; then
-  if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
-
-cat >>confdefs.h <<\_ACEOF
-#define USE_NAMED_POSIX_SEMAPHORES 1
-_ACEOF
-
-    SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
-  else
-    if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
-
-cat >>confdefs.h <<\_ACEOF
-#define USE_UNNAMED_POSIX_SEMAPHORES 1
-_ACEOF
-
-      SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
-    else
-
-cat >>confdefs.h <<\_ACEOF
-#define USE_SYSV_SEMAPHORES 1
-_ACEOF
-
-      SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
-    fi
-  fi
-else
-
-cat >>confdefs.h <<\_ACEOF
-#define USE_WIN32_SEMAPHORES 1
-_ACEOF
-
-  SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
-fi
-
-
-# Select shared-memory implementation type.
-if test "$PORTNAME" != "win32"; then
-
-cat >>confdefs.h <<\_ACEOF
-#define USE_SYSV_SHARED_MEMORY 1
-_ACEOF
-
-  SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
-else
-
-cat >>confdefs.h <<\_ACEOF
-#define USE_WIN32_SHARED_MEMORY 1
-_ACEOF
-
-  SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
+       ac_cv_type_off_t=no
 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
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
+{ echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
+echo "${ECHO_T}$ac_cv_type_off_t" >&6; }
 
-cat >>confdefs.h <<_ACEOF
-#define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
-_ACEOF
-
-
-
-if test "$enable_nls" = yes ; then
-
-  { echo "$as_me:$LINENO: checking for library containing gettext" >&5
-echo $ECHO_N "checking for library containing gettext... $ECHO_C" >&6; }
-if test "${ac_cv_search_gettext+set}" = set; then
+# The cast to long int works around a bug in the HP C Compiler
+# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
+# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
+# This bug is HP SR number 8606223364.
+{ echo "$as_me:$LINENO: checking size of off_t" >&5
+echo $ECHO_N "checking size of off_t... $ECHO_C" >&6; }
+if test "${ac_cv_sizeof_off_t+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_func_search_save_LIBS=$LIBS
+  if test "$cross_compiling" = yes; then
+  # Depending upon the size, compute the lo and hi bounds.
 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 gettext ();
+$ac_includes_default
+   typedef off_t ac__type_sizeof_;
 int
 main ()
 {
-return gettext ();
+static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
+test_array [0] = 0
+
   ;
   return 0;
 }
 _ACEOF
-for ac_lib in '' intl; do
-  if test -z "$ac_lib"; then
+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 "echo \"\$as_me:$LINENO: $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
+  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_lo=0 ac_mid=0
+  while :; do
+    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
+   typedef off_t ac__type_sizeof_;
+int
+main ()
+{
+static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
+test_array [0] = 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 "echo \"\$as_me:$LINENO: $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
+  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_hi=$ac_mid; break
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       ac_lo=`expr $ac_mid + 1`
+                       if test $ac_lo -le $ac_mid; then
+                         ac_lo= ac_hi=
+                         break
+                       fi
+                       ac_mid=`expr 2 '*' $ac_mid + 1`
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+  done
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       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
+   typedef off_t ac__type_sizeof_;
+int
+main ()
+{
+static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
+test_array [0] = 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 "echo \"\$as_me:$LINENO: $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
+  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_hi=-1 ac_mid=-1
+  while :; do
+    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
+   typedef off_t ac__type_sizeof_;
+int
+main ()
+{
+static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
+test_array [0] = 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 "echo \"\$as_me:$LINENO: $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
+  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_lo=$ac_mid; break
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       ac_hi=`expr '(' $ac_mid ')' - 1`
+                       if test $ac_mid -le $ac_hi; then
+                         ac_lo= ac_hi=
+                         break
+                       fi
+                       ac_mid=`expr 2 '*' $ac_mid`
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+  done
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       ac_lo= ac_hi=
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+# Binary search between lo and hi bounds.
+while test "x$ac_lo" != "x$ac_hi"; do
+  ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
+  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
+   typedef off_t ac__type_sizeof_;
+int
+main ()
+{
+static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
+test_array [0] = 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 "echo \"\$as_me:$LINENO: $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
+  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_hi=$ac_mid
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       ac_lo=`expr '(' $ac_mid ')' + 1`
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+done
+case $ac_lo in
+?*) ac_cv_sizeof_off_t=$ac_lo;;
+'') if test "$ac_cv_type_off_t" = yes; then
+     { { echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute sizeof (off_t)
+See \`config.log' for more details." >&2;}
+   { (exit 77); exit 77; }; }
+   else
+     ac_cv_sizeof_off_t=0
+   fi ;;
+esac
+else
+  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
+   typedef off_t ac__type_sizeof_;
+static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
+static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
+#include <stdio.h>
+#include <stdlib.h>
+int
+main ()
+{
+
+  FILE *f = fopen ("conftest.val", "w");
+  if (! f)
+    return 1;
+  if (((long int) (sizeof (ac__type_sizeof_))) < 0)
+    {
+      long int i = longval ();
+      if (i != ((long int) (sizeof (ac__type_sizeof_))))
+       return 1;
+      fprintf (f, "%ld\n", i);
+    }
+  else
+    {
+      unsigned long int i = ulongval ();
+      if (i != ((long int) (sizeof (ac__type_sizeof_))))
+       return 1;
+      fprintf (f, "%lu\n", i);
+    }
+  return ferror (f) || fclose (f) != 0;
+
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_link") 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+  { (case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_try") 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_sizeof_off_t=`cat conftest.val`
+else
+  echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+if test "$ac_cv_type_off_t" = yes; then
+     { { echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute sizeof (off_t)
+See \`config.log' for more details." >&2;}
+   { (exit 77); exit 77; }; }
+   else
+     ac_cv_sizeof_off_t=0
+   fi
+fi
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+fi
+rm -f conftest.val
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
+echo "${ECHO_T}$ac_cv_sizeof_off_t" >&6; }
+
+
+
+cat >>confdefs.h <<_ACEOF
+#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
+_ACEOF
+
+
+
+# If we don't have largefile support, can't handle segsize >= 2GB.
+if test "$ac_cv_sizeof_off_t" -lt 8 -a "$segsize" != "1"; then
+   { { echo "$as_me:$LINENO: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&5
+echo "$as_me: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&2;}
+   { (exit 1); exit 1; }; }
+fi
+
+# SunOS doesn't handle negative byte comparisons properly with +/- return
+{ echo "$as_me:$LINENO: checking for working memcmp" >&5
+echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6; }
+if test "${ac_cv_func_memcmp_working+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test "$cross_compiling" = yes; then
+  ac_cv_func_memcmp_working=no
+else
+  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
+int
+main ()
+{
+
+  /* Some versions of memcmp are not 8-bit clean.  */
+  char c0 = '\100', c1 = '\200', c2 = '\201';
+  if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
+    return 1;
+
+  /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
+     or more and with at least one buffer not starting on a 4-byte boundary.
+     William Lewis provided this test program.   */
+  {
+    char foo[21];
+    char bar[21];
+    int i;
+    for (i = 0; i < 4; i++)
+      {
+       char *a = foo + i;
+       char *b = bar + i;
+       strcpy (a, "--------01111111");
+       strcpy (b, "--------10000000");
+       if (memcmp (a, b, 16) >= 0)
+         return 1;
+      }
+    return 0;
+  }
+
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_link") 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+  { (case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_try") 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_func_memcmp_working=yes
+else
+  echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+ac_cv_func_memcmp_working=no
+fi
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+fi
+
+
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
+echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6; }
+test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in
+  *" memcmp.$ac_objext "* ) ;;
+  *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
+ ;;
+esac
+
+
+
+
+# Select semaphore implementation type.
+if test "$PORTNAME" != "win32"; then
+  if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_NAMED_POSIX_SEMAPHORES 1
+_ACEOF
+
+    SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
+  else
+    if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_UNNAMED_POSIX_SEMAPHORES 1
+_ACEOF
+
+      SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
+    else
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_SYSV_SEMAPHORES 1
+_ACEOF
+
+      SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
+    fi
+  fi
+else
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_WIN32_SEMAPHORES 1
+_ACEOF
+
+  SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
+fi
+
+
+# Select shared-memory implementation type.
+if test "$PORTNAME" != "win32"; then
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_SYSV_SHARED_MEMORY 1
+_ACEOF
+
+  SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
+else
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_WIN32_SHARED_MEMORY 1
+_ACEOF
+
+  SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.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
+fi
+
+cat >>confdefs.h <<_ACEOF
+#define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
+_ACEOF
+
+
+
+if test "$enable_nls" = yes ; then
+
+  { echo "$as_me:$LINENO: checking for library containing bind_textdomain_codeset" >&5
+echo $ECHO_N "checking for library containing bind_textdomain_codeset... $ECHO_C" >&6; }
+if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_func_search_save_LIBS=$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 bind_textdomain_codeset ();
+int
+main ()
+{
+return bind_textdomain_codeset ();
+  ;
+  return 0;
+}
+_ACEOF
+for ac_lib in '' intl; do
+  if test -z "$ac_lib"; then
     ac_res="none required"
   else
     ac_res=-l$ac_lib
@@ -23609,7 +24674,7 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_search_gettext=$ac_res
+  ac_cv_search_bind_textdomain_codeset=$ac_res
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext
-  if test "${ac_cv_search_gettext+set}" = set; then
+  if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
   break
 fi
 done
-if test "${ac_cv_search_gettext+set}" = set; then
+if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
   :
 else
-  ac_cv_search_gettext=no
+  ac_cv_search_bind_textdomain_codeset=no
 fi
 rm conftest.$ac_ext
 LIBS=$ac_func_search_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_search_gettext" >&5
-echo "${ECHO_T}$ac_cv_search_gettext" >&6; }
-ac_res=$ac_cv_search_gettext
+{ echo "$as_me:$LINENO: result: $ac_cv_search_bind_textdomain_codeset" >&5
+echo "${ECHO_T}$ac_cv_search_bind_textdomain_codeset" >&6; }
+ac_res=$ac_cv_search_bind_textdomain_codeset
 if test "$ac_res" != no; then
   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
 
 done
 
 
-  # Note: share/locale is always the default, independent of $datadir
-  localedir='${prefix}/share/locale'
-
-
 fi
 
 # Check for Tcl configuration script tclConfig.sh
 if test "$with_tcl" = yes; then
-    for ac_prog in tclsh tcl
+    for ac_prog in tclsh tcl tclsh8.5 tclsh8.4 tclsh8.3
 do
   # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
   test -n "$TCLSH" && break
 done
 
+if test x"$TCLSH" = x""; then
+  { { echo "$as_me:$LINENO: error: Tcl shell not found" >&5
+echo "$as_me: error: Tcl shell not found" >&2;}
+   { (exit 1); exit 1; }; }
+fi
+
 { echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
 echo $ECHO_N "checking for tclConfig.sh... $ECHO_C" >&6; }
 # Let user override test
@@ -24566,6 +25633,154 @@ echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
 fi
 fi
 
+# If compiler will take -Wl,--as-needed then add that to LDFLAGS.
+# This is much easier than trying to filter LIBS to the minimum for each
+# executable.  (Note that shared library links won't use this switch, though.)
+# On (at least) some Red-Hat-derived systems, this switch breaks linking to
+# libreadline; therefore we postpone testing it until we know what library
+# dependencies readline has.  The test code will try to link with $LIBS.
+if test "$with_readline" = yes; then
+  link_test_func=readline
+else
+  link_test_func=exit
+fi
+if test "$PORTNAME" != "darwin"; then
+  { echo "$as_me:$LINENO: checking if $CC supports -Wl,--as-needed" >&5
+echo $ECHO_N "checking if $CC supports -Wl,--as-needed... $ECHO_C" >&6; }
+pgac_save_LDFLAGS=$LDFLAGS
+LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed"
+if test "$cross_compiling" = yes; then
+  LDFLAGS="$pgac_save_LDFLAGS"
+               { echo "$as_me:$LINENO: result: assuming no" >&5
+echo "${ECHO_T}assuming no" >&6; }
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+extern void $link_test_func (); void (*fptr) () = $link_test_func;
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_link") 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+  { (case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_try") 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  { echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6; }
+else
+  echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+LDFLAGS="$pgac_save_LDFLAGS"
+               { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+fi
+
+
+
+else
+  # On Darwin it's spelled -Wl,-dead_strip_dylibs, but don't try that elsewhere
+  { echo "$as_me:$LINENO: checking if $CC supports -Wl,-dead_strip_dylibs" >&5
+echo $ECHO_N "checking if $CC supports -Wl,-dead_strip_dylibs... $ECHO_C" >&6; }
+pgac_save_LDFLAGS=$LDFLAGS
+LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs"
+if test "$cross_compiling" = yes; then
+  LDFLAGS="$pgac_save_LDFLAGS"
+               { echo "$as_me:$LINENO: result: assuming no" >&5
+echo "${ECHO_T}assuming no" >&6; }
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+extern void $link_test_func (); void (*fptr) () = $link_test_func;
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_link") 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+  { (case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_try") 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  { echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6; }
+else
+  echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+LDFLAGS="$pgac_save_LDFLAGS"
+               { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+fi
+
+
+
+fi
+
+
+# Begin output steps
+
+{ echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
+echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
+{ echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
+echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
+{ echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
+echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
+
 # prepare build tree if outside source tree
 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
 # Note 2: /bin/pwd might be better than shell's built-in at getting
@@ -25001,7 +26216,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 8.3beta3, which was
+This file was extended by PostgreSQL $as_me 8.4devel, which was
 generated by GNU Autoconf 2.61.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -25058,7 +26273,7 @@ Report bugs to <bug-autoconf@gnu.org>."
 _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF
 ac_cs_version="\\
-PostgreSQL config.status 8.3beta3
+PostgreSQL config.status 8.4devel
 configured by $0, generated by GNU Autoconf 2.61,
   with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
 
@@ -25381,8 +26596,8 @@ for ac_last_try in false false false false false :; do
 TAR!$TAR$ac_delim
 LN_S!$LN_S$ac_delim
 AWK!$AWK$ac_delim
-YACC!$YACC$ac_delim
-YFLAGS!$YFLAGS$ac_delim
+BISON!$BISON$ac_delim
+BISONFLAGS!$BISONFLAGS$ac_delim
 FLEX!$FLEX$ac_delim
 FLEXFLAGS!$FLEXFLAGS$ac_delim
 PERL!$PERL$ac_delim