aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/backend/utils/fmgr/dfmgr.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/backend/utils/fmgr/dfmgr.c b/src/backend/utils/fmgr/dfmgr.c
index c2a257258de..4a5cc7cfc7f 100644
--- a/src/backend/utils/fmgr/dfmgr.c
+++ b/src/backend/utils/fmgr/dfmgr.c
@@ -18,7 +18,17 @@
#ifdef HAVE_DLOPEN
#include <dlfcn.h>
+
+/*
+ * On macOS, <dlfcn.h> insists on including <stdbool.h>. If we're not
+ * using stdbool, undef bool to undo the damage.
+ */
+#ifndef USE_STDBOOL
+#ifdef bool
+#undef bool
+#endif
#endif
+#endif /* HAVE_DLOPEN */
#include "fmgr.h"
#include "lib/stringinfo.h"