aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--erts/etc/unix/run_erl.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/erts/etc/unix/run_erl.c b/erts/etc/unix/run_erl.c
index 44efb975ba..22302d539a 100644
--- a/erts/etc/unix/run_erl.c
+++ b/erts/etc/unix/run_erl.c
@@ -42,9 +42,14 @@
# include "config.h"
#endif
#ifdef HAVE_WORKING_POSIX_OPENPT
-#ifndef _XOPEN_SOURCE
-#define _XOPEN_SOURCE 600
-#endif
+# ifndef _XOPEN_SOURCE
+ /* On OS X, we must leave _XOPEN_SOURCE undefined in order for
+ * the prototype of vsyslog() to be included.
+ */
+# ifndef __APPLE__
+# define _XOPEN_SOURCE 600
+# endif
+# endif
#endif
#include <sys/types.h>
#include <sys/wait.h>