darwin: do not use _XOPEN_SOURCE
[charm.git] / src / conv-core / threads.c
index 08765baf55318deec1be93db257bf59e3e4228b3..2aac77c282154a8730679f9783c22cf44ddd1228 100644 (file)
@@ -1610,7 +1610,12 @@ Gengbin Zheng October, 2007
 
 #if CMK_THREADS_USE_CONTEXT
 /* system builtin context routines: */
+
+#if defined(__APPLE__)
+#include <sys/ucontext.h>
+#else
 #include <ucontext.h>
+#endif
 
 typedef ucontext_t uJcontext_t;
 typedef void (*uJcontext_fn_t)(void);