summaryrefslogtreecommitdiff
path: root/src/backend
diff options
context:
space:
mode:
authorBruce Momjian1999-07-19 02:27:16 +0000
committerBruce Momjian1999-07-19 02:27:16 +0000
commite44c93180172b892993fcb77370c5546606b34ab (patch)
treec6096c88d9320a3b7be2d7a645577966253046a6 /src/backend
parent677028177e231ca8dce4c237a026e3d3b58cb314 (diff)
Re-add getopt.h check, remove NT-specific tests for it.
Diffstat (limited to 'src/backend')
-rw-r--r--src/backend/bootstrap/bootstrap.c9
-rw-r--r--src/backend/postmaster/postmaster.c36
-rw-r--r--src/backend/tcop/postgres.c6
-rw-r--r--src/backend/utils/mb/common.c10
4 files changed, 25 insertions, 36 deletions
diff --git a/src/backend/bootstrap/bootstrap.c b/src/backend/bootstrap/bootstrap.c
index fc357d87a79..8db37d0a081 100644
--- a/src/backend/bootstrap/bootstrap.c
+++ b/src/backend/bootstrap/bootstrap.c
@@ -7,7 +7,7 @@
* Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/bootstrap/bootstrap.c,v 1.65 1999/07/17 20:16:47 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/bootstrap/bootstrap.c,v 1.66 1999/07/19 02:27:04 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -15,14 +15,13 @@
#include <time.h>
#include <signal.h>
#include <setjmp.h>
-#ifdef __CYGWIN32__
-#include <getopt.h>
-#endif
#define BOOTSTRAP_INCLUDE /* mask out stuff in tcop/tcopprot.h */
#include "postgres.h"
-
+#ifdef HAVE_GETOPT_H
+#include <getopt.h>
+#endif
#include "access/genam.h"
#include "access/heapam.h"
diff --git a/src/backend/postmaster/postmaster.c b/src/backend/postmaster/postmaster.c
index 15a21773e96..c21611cc1a3 100644
--- a/src/backend/postmaster/postmaster.c
+++ b/src/backend/postmaster/postmaster.c
@@ -10,7 +10,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.114 1999/07/17 20:17:32 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.115 1999/07/19 02:27:06 momjian Exp $
*
* NOTES
*
@@ -32,46 +32,40 @@
*
*-------------------------------------------------------------------------
*/
-#include "postgres.h"
+#include <unistd.h>
+#include <signal.h>
+#include <time.h>
+#include <sys/wait.h>
+#include <ctype.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <sys/time.h>
+#include <sys/socket.h>
+#include <errno.h>
+#include <fcntl.h>
#include <sys/param.h>
+
+#include "postgres.h"
/* moved here to prevent double define */
#ifdef HAVE_NETDB_H
#include <netdb.h>
#endif
-
#ifndef MAXHOSTNAMELEN
#define MAXHOSTNAMELEN 256
#endif
-#if !defined(NO_UNISTD_H)
-#include <unistd.h>
-#endif /* !NO_UNISTD_H */
-
-#include <signal.h>
-#include <time.h>
-
-
#ifdef HAVE_LIMITS_H
#include <limits.h>
#else
#include <values.h>
#endif
-#include <sys/wait.h>
-#include <ctype.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <sys/time.h>
-#include <sys/socket.h>
-
-#include <errno.h>
-#include <fcntl.h>
#ifdef HAVE_SYS_SELECT_H
#include <sys/select.h>
#endif
-#ifdef __CYGWIN32__
+#ifdef HAVE_GETOPT_H
#include "getopt.h"
#endif
diff --git a/src/backend/tcop/postgres.c b/src/backend/tcop/postgres.c
index 6dfd32f6b10..ea357ba613a 100644
--- a/src/backend/tcop/postgres.c
+++ b/src/backend/tcop/postgres.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.125 1999/07/17 20:17:51 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.126 1999/07/19 02:27:06 momjian Exp $
*
* NOTES
* this is the "main" module of the postgres backend and
@@ -39,7 +39,7 @@
#include <netinet/in.h>
#include <arpa/inet.h>
#include <netdb.h>
-#ifdef __CYGWIN32__
+#ifdef HAVE_GETOPT_H
#include <getopt.h>
#endif
@@ -1494,7 +1494,7 @@ PostgresMain(int argc, char *argv[], int real_argc, char *real_argv[])
if (!IsUnderPostmaster)
{
puts("\nPOSTGRES backend interactive interface ");
- puts("$Revision: 1.125 $ $Date: 1999/07/17 20:17:51 $\n");
+ puts("$Revision: 1.126 $ $Date: 1999/07/19 02:27:06 $\n");
}
/* ----------------
diff --git a/src/backend/utils/mb/common.c b/src/backend/utils/mb/common.c
index cab36c7b4c6..0464f5cb872 100644
--- a/src/backend/utils/mb/common.c
+++ b/src/backend/utils/mb/common.c
@@ -2,19 +2,15 @@
* This file contains some public functions
* usable for both the backend and the frontend.
* Tatsuo Ishii
- * $Id: common.c,v 1.5 1999/05/25 16:12:41 momjian Exp $ */
+ * $Id: common.c,v 1.6 1999/07/19 02:27:07 momjian Exp $ */
#include <stdlib.h>
+#include <unistd.h>
+#include <string.h>
#ifdef WIN32
#include "win32.h"
-#else
-#if !defined(NO_UNISTD_H)
-#include <unistd.h>
#endif
-#endif
-
-#include <string.h>
#include "mb/pg_wchar.h"