mirror of https://github.com/aria2/aria2
Check for sys/signal.h and/or signal.h
mingw-w64 does not actually have sys/signal.h, while OSX currently has a broken signal.h Better check the presence of both and use sys/signal.h if present, else signal.hpull/54/head
parent
7f6a446750
commit
8aa1db682b
|
@ -364,6 +364,7 @@ AC_CHECK_HEADERS([argz.h \
|
||||||
netinet/tcp.h \
|
netinet/tcp.h \
|
||||||
poll.h \
|
poll.h \
|
||||||
port.h \
|
port.h \
|
||||||
|
signal.h \
|
||||||
stddef.h \
|
stddef.h \
|
||||||
stdint.h \
|
stdint.h \
|
||||||
stdio_ext.h \
|
stdio_ext.h \
|
||||||
|
@ -372,6 +373,7 @@ AC_CHECK_HEADERS([argz.h \
|
||||||
strings.h \
|
strings.h \
|
||||||
sys/ioctl.h \
|
sys/ioctl.h \
|
||||||
sys/param.h \
|
sys/param.h \
|
||||||
|
sys/signal.h \
|
||||||
sys/socket.h \
|
sys/socket.h \
|
||||||
sys/time.h \
|
sys/time.h \
|
||||||
sys/types.h \
|
sys/types.h \
|
||||||
|
|
|
@ -34,7 +34,14 @@
|
||||||
/* copyright --> */
|
/* copyright --> */
|
||||||
#include "util.h"
|
#include "util.h"
|
||||||
|
|
||||||
#include <sys/signal.h>
|
#ifdef HAVE_SYS_SIGNAL_H
|
||||||
|
# include <sys/signal.h>
|
||||||
|
#else // HAVE_SYS_SIGNAL_H
|
||||||
|
# ifdef HAVE_SIGNAL_H
|
||||||
|
# include <signal.h>
|
||||||
|
# endif // HAVE_SIGNAL_H
|
||||||
|
#endif // HAVE_SYS_SIGNAL_H
|
||||||
|
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#ifdef HAVE_PWD_H
|
#ifdef HAVE_PWD_H
|
||||||
# include <pwd.h>
|
# include <pwd.h>
|
||||||
|
|
Loading…
Reference in New Issue