summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/backend/libpq/auth.c3
-rw-r--r--src/backend/postmaster/pgstat.c3
-rw-r--r--src/bin/pg_basebackup/pg_basebackup.c4
-rw-r--r--src/bin/pg_basebackup/pg_recvlogical.c3
-rw-r--r--src/bin/pg_basebackup/receivelog.c3
-rw-r--r--src/bin/pg_dump/parallel.c4
-rw-r--r--src/port/pgsleep.c3
-rw-r--r--src/test/examples/testlibpq2.c4
8 files changed, 26 insertions, 1 deletions
diff --git a/src/backend/libpq/auth.c b/src/backend/libpq/auth.c
index 31b56da1e27..b6eee179c28 100644
--- a/src/backend/libpq/auth.c
+++ b/src/backend/libpq/auth.c
@@ -20,6 +20,9 @@
#include <netinet/in.h>
#include <arpa/inet.h>
#include <unistd.h>
+#ifdef HAVE_SYS_SELECT_H
+#include <sys/select.h>
+#endif
#include "libpq/auth.h"
#include "libpq/crypt.h"
diff --git a/src/backend/postmaster/pgstat.c b/src/backend/postmaster/pgstat.c
index b2f226cfd9e..085b94acfe7 100644
--- a/src/backend/postmaster/pgstat.c
+++ b/src/backend/postmaster/pgstat.c
@@ -28,6 +28,9 @@
#include <arpa/inet.h>
#include <signal.h>
#include <time.h>
+#ifdef HAVE_SYS_SELECT_H
+#include <sys/select.h>
+#endif
#include "pgstat.h"
diff --git a/src/bin/pg_basebackup/pg_basebackup.c b/src/bin/pg_basebackup/pg_basebackup.c
index 204ceccb456..ed78d09dd8f 100644
--- a/src/bin/pg_basebackup/pg_basebackup.c
+++ b/src/bin/pg_basebackup/pg_basebackup.c
@@ -20,7 +20,9 @@
#include <sys/wait.h>
#include <signal.h>
#include <time.h>
-
+#ifdef HAVE_SYS_SELECT_H
+#include <sys/select.h>
+#endif
#ifdef HAVE_LIBZ
#include <zlib.h>
#endif
diff --git a/src/bin/pg_basebackup/pg_recvlogical.c b/src/bin/pg_basebackup/pg_recvlogical.c
index 545103be146..16f755c6ec4 100644
--- a/src/bin/pg_basebackup/pg_recvlogical.c
+++ b/src/bin/pg_basebackup/pg_recvlogical.c
@@ -15,6 +15,9 @@
#include <dirent.h>
#include <sys/stat.h>
#include <unistd.h>
+#ifdef HAVE_SYS_SELECT_H
+#include <sys/select.h>
+#endif
/* local includes */
#include "streamutil.h"
diff --git a/src/bin/pg_basebackup/receivelog.c b/src/bin/pg_basebackup/receivelog.c
index 660116dcec5..33ecf20ed45 100644
--- a/src/bin/pg_basebackup/receivelog.c
+++ b/src/bin/pg_basebackup/receivelog.c
@@ -16,6 +16,9 @@
#include <sys/stat.h>
#include <unistd.h>
+#ifdef HAVE_SYS_SELECT_H
+#include <sys/select.h>
+#endif
/* local includes */
#include "receivelog.h"
diff --git a/src/bin/pg_dump/parallel.c b/src/bin/pg_dump/parallel.c
index 5f9f8a33ac2..e73a16e7cdd 100644
--- a/src/bin/pg_dump/parallel.c
+++ b/src/bin/pg_dump/parallel.c
@@ -59,6 +59,10 @@
#include "postgres_fe.h"
+#ifdef HAVE_SYS_SELECT_H
+#include <sys/select.h>
+#endif
+
#include "pg_backup_utils.h"
#include "parallel.h"
diff --git a/src/port/pgsleep.c b/src/port/pgsleep.c
index 37b4ef99a82..3e8eaff9b7f 100644
--- a/src/port/pgsleep.c
+++ b/src/port/pgsleep.c
@@ -14,6 +14,9 @@
#include <unistd.h>
#include <sys/time.h>
+#ifdef HAVE_SYS_SELECT_H
+#include <sys/select.h>
+#endif
/*
* In a Windows backend, we don't use this implementation, but rather
diff --git a/src/test/examples/testlibpq2.c b/src/test/examples/testlibpq2.c
index 850993f6e82..07c6317a212 100644
--- a/src/test/examples/testlibpq2.c
+++ b/src/test/examples/testlibpq2.c
@@ -34,6 +34,10 @@
#include <errno.h>
#include <sys/time.h>
#include <sys/types.h>
+#ifdef HAVE_SYS_SELECT_H
+#include <sys/select.h>
+#endif
+
#include "libpq-fe.h"
static void