Restore build on Mac OSX >= 10.7 since the inclusion of ucontext.h
This commit is contained in:
parent
1a98e0add4
commit
3ca2a177b5
|
@ -38,7 +38,13 @@
|
||||||
#include <cstdio>
|
#include <cstdio>
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
#if defined(__APPLE__)
|
||||||
|
# define _XOPEN_SOURCE // ucontext.h APIs can only be used on Mac OSX >= 10.7 if _XOPEN_SOURCE is defined
|
||||||
# include <ucontext.h>
|
# include <ucontext.h>
|
||||||
|
# undef _XOPEN_SOURCE
|
||||||
|
#else
|
||||||
|
# include <ucontext.h>
|
||||||
|
#endif
|
||||||
#ifdef __linux__
|
#ifdef __linux__
|
||||||
#include <sys/syscall.h>
|
#include <sys/syscall.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
|
Loading…
Reference in New Issue