1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-31 22:04:40 +03:00

Generate pg_config.h.in by autoheader. Separate out manually editable

parts.  Standardize spelling of comments in pg_config.h.
This commit is contained in:
Peter Eisentraut
2003-04-06 22:45:23 +00:00
parent d7c333eb9a
commit cb1d036acb
13 changed files with 924 additions and 899 deletions

View File

@ -1,5 +1,5 @@
dnl Process this file with autoconf to produce a configure script.
dnl $Header: /cvsroot/pgsql/configure.in,v 1.241 2003/04/02 00:49:28 tgl Exp $
dnl $Header: /cvsroot/pgsql/configure.in,v 1.242 2003/04/06 22:45:22 petere Exp $
dnl
dnl Developers, please strive to achieve this order:
dnl
@ -149,7 +149,7 @@ PGAC_ARG_REQ(with, libs, [ --with-libs=DIRS alternative spelling of
AC_MSG_CHECKING([whether to build with 64-bit integer date/time support])
PGAC_ARG_BOOL(enable, integer-datetimes, no, [ --enable-integer-datetimes enable 64-bit integer date/time support],
[AC_DEFINE([USE_INTEGER_DATETIMES], 1,
[Set to 1 if you want integer date/time support (--enable-integer-datetimes)])])
[Define to 1 if you want 64-bit integer timestamp and interval support. (--enable-integer-datetimes)])])
AC_MSG_RESULT([$enable_integer_datetimes])
@ -158,7 +158,7 @@ AC_MSG_RESULT([$enable_integer_datetimes])
AC_MSG_CHECKING([whether to build with recode support])
PGAC_ARG_BOOL(enable, recode, no, [ --enable-recode enable single-byte recode support],
[AC_DEFINE([CYR_RECODE], 1,
[Set to 1 if you want single-byte recode support (--enable-recode)])])
[Define to 1 if you want single-byte recode support. (--enable-recode)])])
AC_MSG_RESULT([$enable_recode])
@ -171,7 +171,7 @@ PGAC_ARG_OPTARG(enable, nls,
[],
[WANTED_LANGUAGES=$enableval],
[AC_DEFINE(ENABLE_NLS, 1,
[Define to 1 if you want National Language Support (--enable-nls)])])
[Define to 1 if you want National Language Support. (--enable-nls)])])
AC_MSG_RESULT([$enable_nls])
AC_SUBST(enable_nls)
AC_SUBST(WANTED_LANGUAGES)
@ -186,26 +186,14 @@ PGAC_ARG_REQ(with, pgport, [ --with-pgport=PORTNUM change default port number
AC_MSG_RESULT([$default_port])
# Need both of these because some places want an integer and some a string
AC_DEFINE_UNQUOTED(DEF_PGPORT, ${default_port},
[The default TCP port number on which the server listens and to which
clients will try to connect to. This can be overridden at run-time,
but it's convenient if your clients have the right default compiled in.
(--with-pgport=PORTNUM)])
[Define to the default TCP port number on which the server listens and
to which clients will try to connect to. This can be overridden at
run-time, but it's convenient if your clients have the right default
compiled in. (--with-pgport=PORTNUM)])
AC_DEFINE_UNQUOTED(DEF_PGPORT_STR, "${default_port}",
[Default TCP port number as string constant])
[Define to the default TCP port number as string constant.])
AC_SUBST(default_port)
#
# Maximum number of allowed connections (--with-maxbackends), default 32
#
AC_MSG_CHECKING([for default soft limit on number of connections])
PGAC_ARG_REQ(with, maxbackends, [ --with-maxbackends=N set default maximum number of connections [32]],
[],
[with_maxbackends=32])
AC_MSG_RESULT([$with_maxbackends])
AC_DEFINE_UNQUOTED([DEF_MAXBACKENDS], [$with_maxbackends],
[The default soft limit on the number of concurrent connections, i.e., the default for the postmaster -N switch (--with-maxbackends)])
#
# Option to disable shared libraries
#
@ -278,7 +266,9 @@ if test x"$GCC" = x"yes" ; then
else
cc_string=$CC
fi
AC_DEFINE_UNQUOTED(PG_VERSION_STR, ["PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string"], [A canonical string containing the version number, platform, and C compiler])
AC_DEFINE_UNQUOTED(PG_VERSION_STR,
["PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string"],
[A string containing the version number, platform, and C compiler])
#
@ -294,7 +284,7 @@ AC_SUBST(autodepend)
#
PGAC_ARG_BOOL(enable, cassert, no, [ --enable-cassert enable assertion checks (for debugging)],
[AC_DEFINE([USE_ASSERT_CHECKING], 1,
[Define to 1 to build with assertion checks])])
[Define to 1 to build with assertion checks. (--enable-cassert)])])
#
@ -411,7 +401,7 @@ PGAC_ARG_OPTARG(with, krb4, [[ --with-krb4[=DIR] build with Kerberos 4 su
[krb4_prefix=$withval],
[
AC_MSG_RESULT(yes)
AC_DEFINE(KRB4, 1, [Define if you are building with Kerberos 4 support.])
AC_DEFINE(KRB4, 1, [Define to build with Kerberos 4 support. (--with-krb4)])
if test -d "$krb4_prefix/include"; then
INCLUDES="$INCLUDES -I$krb4_prefix/include"
@ -436,7 +426,7 @@ PGAC_ARG_OPTARG(with, krb5, [[ --with-krb5[=DIR] build with Kerberos 5 su
[krb5_prefix=$withval],
[
AC_MSG_RESULT([yes])
AC_DEFINE(KRB5, 1, [Define if you are building with Kerberos 5 support.])
AC_DEFINE(KRB5, 1, [Define to build with Kerberos 5 support. (--with-krb5)])
if test -d "$krb5_prefix/include"; then
INCLUDES="$INCLUDES -I$krb5_prefix/include"
@ -468,7 +458,7 @@ PGAC_ARG_REQ(with, krb-srvnam,
[],
[with_krb_srvnam="postgres"])
AC_DEFINE_UNQUOTED([PG_KRB_SRVNAM], ["$with_krb_srvnam"],
[The name of the PostgreSQL service principal in Kerberos])
[Define to the name of the PostgreSQL service principal in Kerberos. (--with-krb-srvnam=NAME)])
#
@ -477,7 +467,7 @@ AC_DEFINE_UNQUOTED([PG_KRB_SRVNAM], ["$with_krb_srvnam"],
AC_MSG_CHECKING([whether to build with PAM support])
PGAC_ARG_BOOL(with, pam, no,
[ --with-pam build with PAM support],
[AC_DEFINE([USE_PAM], 1, [Define to build with PAM support])])
[AC_DEFINE([USE_PAM], 1, [Define to 1 to build with PAM support. (--with-pam)])])
AC_MSG_RESULT([$with_pam])
AC_SUBST(with_pam)
@ -491,7 +481,7 @@ PGAC_ARG_OPTARG(with, openssl,
[openssl_prefix=$withval],
[
AC_MSG_RESULT([building with OpenSSL support])
AC_DEFINE([USE_SSL], 1, [Define to build with (Open)SSL support])
AC_DEFINE([USE_SSL], 1, [Define to build with (Open)SSL support. (--with-openssl)])
if test -d "${openssl_prefix}/include" ; then
INCLUDES="$INCLUDES -I${openssl_prefix}/include"
@ -794,7 +784,7 @@ AC_CHECK_DECLS(fdatasync, [], [], [#include <unistd.h>])
AC_CHECK_TYPE([struct sockaddr_in6],
[AC_CHECK_FUNC(inet_ntop,
[AC_DEFINE(HAVE_IPV6, 1)])],
[AC_DEFINE(HAVE_IPV6, 1, [Define to 1 if you have support for IPv6.])])],
[],
[$ac_includes_default
#include <netinet/in.h>])
@ -809,7 +799,7 @@ PS_STRINGS->ps_argvstr = "foo";],
[pgac_cv_var_PS_STRINGS=yes],
[pgac_cv_var_PS_STRINGS=no])])
if test "$pgac_cv_var_PS_STRINGS" = yes ; then
AC_DEFINE([HAVE_PS_STRINGS], [], [Define if the PS_STRINGS thing exists.])
AC_DEFINE([HAVE_PS_STRINGS], [], [Define to 1 if the PS_STRINGS thing exists.])
fi
@ -841,7 +831,7 @@ AC_CACHE_CHECK([for isinf], ac_cv_func_isinf,
[ac_cv_func_isinf=no])])
if test $ac_cv_func_isinf = yes ; then
AC_DEFINE(HAVE_ISINF, 1, [Define to 1 if you have isinf()])
AC_DEFINE(HAVE_ISINF, 1, [Define to 1 if you have isinf().])
else
AC_LIBOBJ(isinf)
# Look for a way to implement a substitute for isinf()
@ -896,24 +886,23 @@ dnl Cannot use AC_CHECK_FUNC because finite may be a macro
AC_MSG_CHECKING(for finite)
AC_TRY_LINK([#include <math.h>],
[int dummy=finite(1.0);],
[AC_DEFINE(HAVE_FINITE, 1, [Set to 1 if you have finite()])
[AC_DEFINE(HAVE_FINITE, 1, [Define to 1 if you have finite().])
AC_MSG_RESULT(yes)],
[AC_MSG_RESULT(no)])
dnl Cannot use AC_CHECK_FUNC because sigsetjmp may be a macro
dnl (especially on GNU libc)
dnl See also comments in pg_config.h.
dnl See also comments in c.h.
AC_MSG_CHECKING(for sigsetjmp)
AC_TRY_LINK([#include <setjmp.h>],
[sigjmp_buf x; sigsetjmp(x, 1);],
[AC_DEFINE(HAVE_SIGSETJMP, 1, [Set to 1 if you have sigsetjmp()])
[AC_DEFINE(HAVE_SIGSETJMP, 1, [Define to 1 if you have sigsetjmp().])
AC_MSG_RESULT(yes)],
[AC_MSG_RESULT(no)])
AC_CHECK_FUNC(syslog,
[AC_CHECK_HEADER(syslog.h,
[AC_DEFINE(HAVE_SYSLOG, 1, [])],
[])])
[AC_CHECK_HEADER(syslog.h,
[AC_DEFINE(HAVE_SYSLOG, 1, [Define to 1 if you have the syslog interface.])])])
AC_CACHE_CHECK([for optreset], pgac_cv_var_int_optreset,
[AC_TRY_LINK([#include <unistd.h>],
@ -921,7 +910,7 @@ AC_CACHE_CHECK([for optreset], pgac_cv_var_int_optreset,
[pgac_cv_var_int_optreset=yes],
[pgac_cv_var_int_optreset=no])])
if test x"$pgac_cv_var_int_optreset" = x"yes"; then
AC_DEFINE(HAVE_INT_OPTRESET, 1, [Define to 1 if you have the global variable 'int optreset'])
AC_DEFINE(HAVE_INT_OPTRESET, 1, [Define to 1 if you have the global variable 'int optreset'.])
fi
AC_CHECK_FUNCS([strtoll strtoq], [break])
@ -978,7 +967,7 @@ if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
long long int foo = INT64CONST(0x1234567890123456);
],
[],
[AC_DEFINE(HAVE_LL_CONSTANTS, 1, [Define if you have LL constants])],
[AC_DEFINE(HAVE_LL_CONSTANTS, 1, [Define to 1 if constants of type 'long long int' should have the suffix LL.])],
[])
fi
@ -1008,16 +997,14 @@ else
fi
AC_DEFINE_UNQUOTED(INT64_FORMAT, $INT64_FORMAT,
[Define this as the appropriate snprintf format for 64-bit ints, if any])
[Define to the appropriate snprintf format for 64-bit ints, if any.])
if test $pgac_need_repl_snprintf = yes; then
AC_LIBOBJ(snprintf)
fi
dnl Need a #define for the size of Datum (unsigned long)
# Need a #define for the size of Datum (unsigned long)
AC_CHECK_SIZEOF([unsigned long])
AC_DEFINE_UNQUOTED(SIZEOF_DATUM, $ac_cv_sizeof_unsigned_long, [sizeof(Datum) -- don't change])
# Determine memory alignment requirements for the basic C data types.
@ -1040,7 +1027,7 @@ 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"
fi
AC_DEFINE_UNQUOTED(MAXIMUM_ALIGNOF, $MAX_ALIGNOF, [Define as the maximum alignment requirement of any type])
AC_DEFINE_UNQUOTED(MAXIMUM_ALIGNOF, $MAX_ALIGNOF, [Define as the maximum alignment requirement of any C data type.])
# Some platforms predefine the types int8, int16, etc. Only check
@ -1064,21 +1051,21 @@ fi
# Select semaphore implementation type.
if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
AC_DEFINE(USE_NAMED_POSIX_SEMAPHORES, 1, [Define to select named POSIX semaphores])
AC_DEFINE(USE_NAMED_POSIX_SEMAPHORES, 1, [Define to select named POSIX semaphores.])
SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
else
if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
AC_DEFINE(USE_UNNAMED_POSIX_SEMAPHORES, 1, [Define to select unnamed POSIX semaphores])
AC_DEFINE(USE_UNNAMED_POSIX_SEMAPHORES, 1, [Define to select unnamed POSIX semaphores.])
SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
else
AC_DEFINE(USE_SYSV_SEMAPHORES, 1, [Define to select SysV-style semaphores])
AC_DEFINE(USE_SYSV_SEMAPHORES, 1, [Define to select SysV-style semaphores.])
SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
fi
fi
# Select shared-memory implementation type.
AC_DEFINE(USE_SYSV_SHARED_MEMORY, 1, [Define to select SysV-style shared memory])
AC_DEFINE(USE_SYSV_SHARED_MEMORY, 1, [Define to select SysV-style shared memory.])
SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"