Commit cb292206 authored by Peter Eisentraut's avatar Peter Eisentraut

Remove a bunch of unused configure tests, in particular cases where

* the result is not recorded anywhere
* the result is not used anywhere
* the result is only used in some places, whereas others have been getting away with it
* the result is used improperly

Also make command line options handling a little better (e.g., --disable-locale,
while redundant, should really still *dis*able).
parent dce43d22
This diff is collapsed.
This diff is collapsed.
#include "postgres.h"
#include <stdlib.h> #include <stdlib.h>
#include <ctype.h> #include <ctype.h>
#include <errno.h> #include <errno.h>
...@@ -6,17 +8,15 @@ ...@@ -6,17 +8,15 @@
#include <math.h> #include <math.h>
#include "postgres.h"
#ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#ifndef MAXINT #ifndef MAXINT
#define MAXINT INT_MAX #define MAXINT INT_MAX
#endif #endif
#else
#ifdef HAVE_VALUES_H #ifdef HAVE_VALUES_H
#include <values.h> #include <values.h>
#endif #endif
#endif
#include "fmgr.h" #include "fmgr.h"
#include "utils/timestamp.h" #include "utils/timestamp.h"
#include "utils/builtins.h" #include "utils/builtins.h"
......
/* /*
* $Header: /cvsroot/pgsql/contrib/pgbench/pgbench.c,v 1.4 2000/05/29 05:44:29 tgl Exp $ * $Header: /cvsroot/pgsql/contrib/pgbench/pgbench.c,v 1.5 2000/07/12 22:58:57 petere Exp $
* *
* pgbench: a simple TPC-B like benchmark program for PostgreSQL * pgbench: a simple TPC-B like benchmark program for PostgreSQL
* written by Tatsuo Ishii * written by Tatsuo Ishii
...@@ -30,9 +30,7 @@ ...@@ -30,9 +30,7 @@
#include "win32.h" #include "win32.h"
#else #else
#include <sys/time.h> #include <sys/time.h>
#if HAVE_UNISTD_H
#include <unistd.h> #include <unistd.h>
#endif
#ifdef HAVE_GETOPT_H #ifdef HAVE_GETOPT_H
#include <getopt.h> #include <getopt.h>
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
* Dec 17, 1997 - Todd A. Brandys * Dec 17, 1997 - Todd A. Brandys
* Orignal Version Completed. * Orignal Version Completed.
* *
* $Id: crypt.c,v 1.27 2000/07/04 16:31:53 petere Exp $ * $Id: crypt.c,v 1.28 2000/07/12 22:58:59 petere Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
#include "utils/nabstime.h" #include "utils/nabstime.h"
#ifdef HAVE_CRYPT_H #ifdef HAVE_CRYPT_H
#include "crypt.h" #include <crypt.h>
#endif #endif
char **pwd_cache = NULL; char **pwd_cache = NULL;
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc * Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California * Portions Copyright (c) 1994, Regents of the University of California
* *
* $Id: pqformat.c,v 1.14 2000/07/08 05:30:33 tgl Exp $ * $Id: pqformat.c,v 1.15 2000/07/12 22:58:59 petere Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -48,9 +48,7 @@ ...@@ -48,9 +48,7 @@
#include "postgres.h" #include "postgres.h"
#include <errno.h> #include <errno.h>
#ifdef HAVE_SYS_PARAM_H
#include <sys/param.h> #include <sys/param.h>
#endif
#include "libpq/libpq.h" #include "libpq/libpq.h"
#include "libpq/pqformat.h" #include "libpq/pqformat.h"
...@@ -58,7 +56,7 @@ ...@@ -58,7 +56,7 @@
#include "mb/pg_wchar.h" #include "mb/pg_wchar.h"
#endif #endif
#ifdef HAVE_ENDIAN_H #ifdef HAVE_ENDIAN_H
#include "endian.h" #include <endian.h>
#endif #endif
#ifndef BYTE_ORDER #ifndef BYTE_ORDER
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc * Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California * Portions Copyright (c) 1994, Regents of the University of California
* *
* $Id: geqo_eval.c,v 1.51 2000/06/28 03:31:45 tgl Exp $ * $Id: geqo_eval.c,v 1.52 2000/07/12 22:59:01 petere Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -22,13 +22,10 @@ ...@@ -22,13 +22,10 @@
#include "postgres.h" #include "postgres.h"
#include <math.h> #include <math.h>
#ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#else
#ifdef HAVE_VALUES_H #ifdef HAVE_VALUES_H
#include <values.h> #include <values.h>
#endif #endif
#endif
#include "optimizer/geqo.h" #include "optimizer/geqo.h"
#include "optimizer/pathnode.h" #include "optimizer/pathnode.h"
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.155 2000/07/12 17:38:42 petere Exp $ * $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.156 2000/07/12 22:59:04 petere Exp $
* *
* NOTES * NOTES
* *
...@@ -49,17 +49,12 @@ ...@@ -49,17 +49,12 @@
#include <sys/param.h> #include <sys/param.h>
/* moved here to prevent double define */ /* moved here to prevent double define */
#ifdef HAVE_NETDB_H
#include <netdb.h> #include <netdb.h>
#endif
#ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#else
#ifdef HAVE_VALUES_H #ifdef HAVE_VALUES_H
#include <values.h> #include <values.h>
#endif #endif
#endif
#ifdef HAVE_SYS_SELECT_H #ifdef HAVE_SYS_SELECT_H
#include <sys/select.h> #include <sys/select.h>
...@@ -87,10 +82,6 @@ ...@@ -87,10 +82,6 @@
#include "utils/guc.h" #include "utils/guc.h"
#if !defined(MAXINT)
#define MAXINT INT_MAX
#endif
#define INVALID_SOCK (-1) #define INVALID_SOCK (-1)
#define ARGV_SIZE 64 #define ARGV_SIZE 64
...@@ -166,7 +157,7 @@ int MaxBackends = DEF_MAXBACKENDS; ...@@ -166,7 +157,7 @@ int MaxBackends = DEF_MAXBACKENDS;
* semaphores, even if you never actually use that many backends. * semaphores, even if you never actually use that many backends.
*/ */
static int NextBackendTag = MAXINT; /* XXX why count down not up? */ static int NextBackendTag = INT_MAX; /* XXX why count down not up? */
static char *progname = (char *) NULL; static char *progname = (char *) NULL;
static char **real_argv; static char **real_argv;
static int real_argc; static int real_argc;
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/date.c,v 1.48 2000/06/19 03:54:27 tgl Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/date.c,v 1.49 2000/07/12 22:59:08 petere Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -17,9 +17,7 @@ ...@@ -17,9 +17,7 @@
#include <limits.h> #include <limits.h>
#include <time.h> #include <time.h>
#ifdef HAVE_FLOAT_H
#include <float.h> #include <float.h>
#endif
#include "access/hash.h" #include "access/hash.h"
#include "miscadmin.h" #include "miscadmin.h"
......
...@@ -8,22 +8,20 @@ ...@@ -8,22 +8,20 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/datetime.c,v 1.50 2000/06/14 18:17:42 petere Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/datetime.c,v 1.51 2000/07/12 22:59:08 petere Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include "postgres.h"
#include <ctype.h> #include <ctype.h>
#include <math.h> #include <math.h>
#include <sys/types.h> #include <sys/types.h>
#include <errno.h> #include <errno.h>
#include "postgres.h"
#ifdef HAVE_FLOAT_H
#include <float.h> #include <float.h>
#endif
#ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#endif
#ifndef USE_POSIX_TIME #ifndef USE_POSIX_TIME
#include <sys/timeb.h> #include <sys/timeb.h>
#endif #endif
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/float.c,v 1.63 2000/07/06 05:48:11 tgl Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/float.c,v 1.64 2000/07/12 22:59:08 petere Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -53,16 +53,10 @@ ...@@ -53,16 +53,10 @@
#include "postgres.h" #include "postgres.h"
#ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#ifndef MAXINT
#define MAXINT INT_MAX
#endif
#else
#ifdef HAVE_VALUES_H #ifdef HAVE_VALUES_H
#include <values.h> #include <values.h>
#endif #endif
#endif
/* for finite() on Solaris */ /* for finite() on Solaris */
#ifdef HAVE_IEEEFP_H #ifdef HAVE_IEEEFP_H
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/int.c,v 1.39 2000/07/03 23:09:52 wieck Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/int.c,v 1.40 2000/07/12 22:59:08 petere Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -27,13 +27,10 @@ ...@@ -27,13 +27,10 @@
* intmod, int4fac * intmod, int4fac
*/ */
#include <ctype.h>
#include "postgres.h" #include "postgres.h"
#ifdef HAVE_LIMITS_H #include <ctype.h>
#include <limits.h> #include <limits.h>
#endif
#include "utils/builtins.h" #include "utils/builtins.h"
......
...@@ -7,20 +7,17 @@ ...@@ -7,20 +7,17 @@
* Portions Copyright (c) 1994, Regents of the University of California * Portions Copyright (c) 1994, Regents of the University of California
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/int8.c,v 1.22 2000/07/03 23:09:52 wieck Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/int8.c,v 1.23 2000/07/12 22:59:09 petere Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include "postgres.h"
#include <ctype.h> #include <ctype.h>
#include <time.h> #include <time.h>
#include <math.h> #include <math.h>
#include <float.h> #include <float.h>
#include "postgres.h"
#ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#endif
#include "utils/int8.h" #include "utils/int8.h"
......
...@@ -9,32 +9,24 @@ ...@@ -9,32 +9,24 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/nabstime.c,v 1.71 2000/07/03 23:09:52 wieck Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/nabstime.c,v 1.72 2000/07/12 22:59:09 petere Exp $
* *
* NOTES * NOTES
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include "postgres.h"
#include <ctype.h> #include <ctype.h>
#include <time.h> #include <time.h>
#include <sys/time.h> #include <sys/time.h>
#include <sys/types.h> #include <sys/types.h>
#include "postgres.h"
#ifdef HAVE_FLOAT_H
#include <float.h> #include <float.h>
#endif
#ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#ifndef MAXINT
#define MAXINT INT_MAX
#endif
#else
#ifdef HAVE_VALUES_H #ifdef HAVE_VALUES_H
#include <values.h> #include <values.h>
#endif #endif
#endif
#ifndef USE_POSIX_TIME #ifndef USE_POSIX_TIME
#include <sys/timeb.h> #include <sys/timeb.h>
......
...@@ -11,17 +11,16 @@ ...@@ -11,17 +11,16 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/numutils.c,v 1.40 2000/04/12 17:15:51 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/numutils.c,v 1.41 2000/07/12 22:59:09 petere Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include "postgres.h"
#include <errno.h> #include <errno.h>
#include <math.h> #include <math.h>
#include "postgres.h"
#ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#endif
#include "utils/builtins.h" #include "utils/builtins.h"
#ifndef INT_MAX #ifndef INT_MAX
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/timestamp.c,v 1.32 2000/07/05 23:11:35 tgl Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/timestamp.c,v 1.33 2000/07/12 22:59:09 petere Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -19,12 +19,9 @@ ...@@ -19,12 +19,9 @@
#include <math.h> #include <math.h>
#include <errno.h> #include <errno.h>
#include <sys/types.h> #include <sys/types.h>
#ifdef HAVE_FLOAT_H
#include <float.h> #include <float.h>
#endif
#ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#endif
#ifndef USE_POSIX_TIME #ifndef USE_POSIX_TIME
#include <sys/timeb.h> #include <sys/timeb.h>
#endif #endif
......
...@@ -4,33 +4,27 @@ ...@@ -4,33 +4,27 @@
* Functions for the built-in type bit() and varying bit(). * Functions for the built-in type bit() and varying bit().
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/varbit.c,v 1.4 2000/07/03 23:09:53 wieck Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/varbit.c,v 1.5 2000/07/12 22:59:09 petere Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include "postgres.h"
/* Include file list stolen from float.c. /* Include file list stolen from float.c.
* Can probably get rid of some of these. * Can probably get rid of some of these.
* - thomas 2000-04-07 * - thomas 2000-04-07
*/ */
#include <ctype.h> #include <ctype.h>
#include <errno.h> #include <errno.h>
#include <float.h> /* faked on sunos4 */ #include <float.h> /* faked on sunos4 */
#include <math.h> #include <math.h>
#include "postgres.h"
#ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#ifndef MAXINT
#define MAXINT INT_MAX
#endif
#else
#ifdef HAVE_VALUES_H #ifdef HAVE_VALUES_H
#include <values.h> #include <values.h>
#endif #endif
#endif
#include "fmgr.h" #include "fmgr.h"
#include "utils/builtins.h" #include "utils/builtins.h"
#include "utils/varbit.h" #include "utils/varbit.h"
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc * Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California * Portions Copyright (c) 1994, Regents of the University of California
* *
* $Id: c.h,v 1.77 2000/07/12 17:38:53 petere Exp $ * $Id: c.h,v 1.78 2000/07/12 22:59:12 petere Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -46,15 +46,12 @@ ...@@ -46,15 +46,12 @@
#include "config.h" #include "config.h"
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include <sys/fcntl.h> #include <sys/fcntl.h>
#ifdef STDC_HEADERS
#include <stddef.h> #include <stddef.h>
#include <stdarg.h> #include <stdarg.h>
#endif
#ifdef __CYGWIN32__ #ifdef __CYGWIN32__
#include <errno.h> #include <errno.h>
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
* or in config.h afterwards. Of course, if you edit config.h, then your * or in config.h afterwards. Of course, if you edit config.h, then your
* changes will be overwritten the next time you run configure. * changes will be overwritten the next time you run configure.
* *
* $Id: config.h.in,v 1.125 2000/07/11 14:30:30 momjian Exp $ * $Id: config.h.in,v 1.126 2000/07/12 22:59:12 petere Exp $
*/ */
#ifndef CONFIG_H #ifndef CONFIG_H
...@@ -291,9 +291,6 @@ ...@@ -291,9 +291,6 @@
/* Define if your cpp understands the ANSI stringizing operators in macros */ /* Define if your cpp understands the ANSI stringizing operators in macros */
#undef HAVE_STRINGIZE #undef HAVE_STRINGIZE
/* Set to 1 if you have <arpa/inet.h> */
#undef HAVE_ARPA_INET_H
/* Set to 1 if you have <crypt.h> */ /* Set to 1 if you have <crypt.h> */
#undef HAVE_CRYPT_H #undef HAVE_CRYPT_H
...@@ -303,9 +300,6 @@ ...@@ -303,9 +300,6 @@
/* Set to 1 if you have <endian.h> */ /* Set to 1 if you have <endian.h> */
#undef HAVE_ENDIAN_H #undef HAVE_ENDIAN_H
/* Set to 1 if you have <float.h> */
#undef HAVE_FLOAT_H
/* Set to 1 if you have <fp_class.h> */ /* Set to 1 if you have <fp_class.h> */
#undef HAVE_FP_CLASS_H #undef HAVE_FP_CLASS_H
...@@ -318,15 +312,6 @@ ...@@ -318,15 +312,6 @@
/* Set to 1 if you have <ieeefp.h> */ /* Set to 1 if you have <ieeefp.h> */
#undef HAVE_IEEEFP_H #undef HAVE_IEEEFP_H
/* Set to 1 if you have <limits.h> */
#undef HAVE_LIMITS_H
/* Set to 1 if you have <netdb.h> */
#undef HAVE_NETDB_H
/* Set to 1 if you have <netinet/in.h> */
#undef HAVE_NETINET_IN_H
/* Set to 1 if you have <readline.h> */ /* Set to 1 if you have <readline.h> */
#undef HAVE_READLINE_H #undef HAVE_READLINE_H
...@@ -345,18 +330,9 @@ ...@@ -345,18 +330,9 @@
/* Set to 1 if you have <values.h> */ /* Set to 1 if you have <values.h> */
#undef HAVE_VALUES_H #undef HAVE_VALUES_H
/* Set to 1 if you have <sys/exec.h> */
#undef HAVE_SYS_EXEC_H
/* Set to 1 if you have <sys/pstat.h> */ /* Set to 1 if you have <sys/pstat.h> */
#undef HAVE_SYS_PSTAT_H #undef HAVE_SYS_PSTAT_H
/* Set to 1 if you have <machine/vmparam.h> */
#undef HAVE_MACHINE_VMPARAM_H
/* Define if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Define if you have the setproctitle function. */ /* Define if you have the setproctitle function. */
#undef HAVE_SETPROCTITLE #undef HAVE_SETPROCTITLE
...@@ -375,9 +351,6 @@ ...@@ -375,9 +351,6 @@
/* Set to 1 if you have <pwd.h> */ /* Set to 1 if you have <pwd.h> */
#undef HAVE_PWD_H #undef HAVE_PWD_H
/* Define if you have the <sys/param.h> header file. */
#undef HAVE_SYS_PARAM_H
/* Set to 1 if you gettimeofday(a,b) vs gettimeofday(a) */ /* Set to 1 if you gettimeofday(a,b) vs gettimeofday(a) */
#undef GETTIMEOFDAY_1ARG #undef GETTIMEOFDAY_1ARG
#ifdef GETTIMEOFDAY_1ARG #ifdef GETTIMEOFDAY_1ARG
......
#ifndef VARBIT_H #ifndef VARBIT_H
#define VARBIT_H #define VARBIT_H
#include <math.h>
#include "postgres.h" #include "postgres.h"
#ifdef HAVE_LIMITS_H
#include <math.h>
#include <limits.h> #include <limits.h>
#ifndef MAXINT
#define MAXINT INT_MAX
#endif
#else
#ifdef HAVE_VALUES_H #ifdef HAVE_VALUES_H
#include <values.h> #include <values.h>
#endif #endif
#endif
#include "utils/builtins.h" #include "utils/builtins.h"
...@@ -26,6 +21,7 @@ struct varbita ...@@ -26,6 +21,7 @@ struct varbita
bits8 vl_dat[1]; bits8 vl_dat[1];
}; };
#undef BITSPERBYTE /* sometimes declared in <values.h> */
#define BITSPERBYTE 8 #define BITSPERBYTE 8
#define VARBITHDRSZ sizeof(int32) #define VARBITHDRSZ sizeof(int32)
/* Number of bits in this bit string */ /* Number of bits in this bit string */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment