From 76d4c929d7504c604c0db6b14ad587028facc4d0 Mon Sep 17 00:00:00 2001 From: Ross Lagerwall Date: Wed, 8 Feb 2012 18:46:00 +0200 Subject: [PATCH] Put #ifdef around some files to support alternate build systems. --- devpoll.c | 4 ++++ epoll.c | 4 ++++ evport.c | 4 ++++ kqueue.c | 4 ++++ poll.c | 4 ++++ select.c | 4 ++++ 6 files changed, 24 insertions(+) diff --git a/devpoll.c b/devpoll.c index aeb97ae92c..628af7cb4f 100644 --- a/devpoll.c +++ b/devpoll.c @@ -27,6 +27,8 @@ #include "event2/event-config.h" #include "evconfig-private.h" +#ifdef _EVENT_HAVE_DEVPOLL + #include #include #ifdef _EVENT_HAVE_SYS_TIME_H @@ -305,3 +307,5 @@ devpoll_dealloc(struct event_base *base) memset(devpollop, 0, sizeof(struct devpollop)); mm_free(devpollop); } + +#endif /* _EVENT_HAVE_DEVPOLL */ diff --git a/epoll.c b/epoll.c index f1219e7dfb..6829076a57 100644 --- a/epoll.c +++ b/epoll.c @@ -27,6 +27,8 @@ #include "event2/event-config.h" #include "evconfig-private.h" +#ifdef _EVENT_HAVE_EPOLL + #include #include #include @@ -582,3 +584,5 @@ epoll_dealloc(struct event_base *base) memset(epollop, 0, sizeof(struct epollop)); mm_free(epollop); } + +#endif /* _EVENT_HAVE_EPOLL */ diff --git a/evport.c b/evport.c index 50f065a65c..33041f54f9 100644 --- a/evport.c +++ b/evport.c @@ -53,6 +53,8 @@ #include "event2/event-config.h" #include "evconfig-private.h" +#ifdef _EVENT_HAVE_EVENT_PORTS + #include #include #include @@ -442,3 +444,5 @@ evport_dealloc(struct event_base *base) mm_free(evpd); } + +#endif /* _EVENT_HAVE_EVENT_PORTS */ diff --git a/kqueue.c b/kqueue.c index 1e42dcf167..4ff1135518 100644 --- a/kqueue.c +++ b/kqueue.c @@ -29,6 +29,8 @@ #include "event2/event-config.h" #include "evconfig-private.h" +#ifdef _EVENT_HAVE_KQUEUE + #include #ifdef _EVENT_HAVE_SYS_TIME_H #include @@ -465,3 +467,5 @@ kq_sig_del(struct event_base *base, int nsignal, short old, short events, void * return (0); } + +#endif /* _EVENT_HAVE_KQUEUE */ diff --git a/poll.c b/poll.c index 0e4401a6d3..9eaa77f10a 100644 --- a/poll.c +++ b/poll.c @@ -29,6 +29,8 @@ #include "event2/event-config.h" #include "evconfig-private.h" +#ifdef _EVENT_HAVE_POLL + #include #ifdef _EVENT_HAVE_SYS_TIME_H #include @@ -332,3 +334,5 @@ poll_dealloc(struct event_base *base) memset(pop, 0, sizeof(struct pollop)); mm_free(pop); } + +#endif /* _EVENT_HAVE_POLL */ diff --git a/select.c b/select.c index b482a1c707..e543fb4024 100644 --- a/select.c +++ b/select.c @@ -29,6 +29,8 @@ #include "event2/event-config.h" #include "evconfig-private.h" +#ifdef _EVENT_HAVE_SELECT + #ifdef __APPLE__ /* Apple wants us to define this if we might ever pass more than * FD_SETSIZE bits to select(). */ @@ -338,3 +340,5 @@ select_dealloc(struct event_base *base) select_free_selectop(base->evbase); } + +#endif /* _EVENT_HAVE_SELECT */