Commit 09d18e4b authored by Ian Barber's avatar Ian Barber

Merge branch 'master' of https://github.com/zeromq/libzmq

parents 09956dee f8b79f88
...@@ -20,6 +20,31 @@ ...@@ -20,6 +20,31 @@
#include <stddef.h> #include <stddef.h>
#include "platform.hpp"
#if defined ZMQ_FORCE_SELECT
#define ZMQ_POLL_BASED_ON_SELECT
#elif defined ZMQ_FORCE_POLL
#define ZMQ_POLL_BASED_ON_POLL
#elif defined ZMQ_HAVE_LINUX || defined ZMQ_HAVE_FREEBSD ||\
defined ZMQ_HAVE_OPENBSD || defined ZMQ_HAVE_SOLARIS ||\
defined ZMQ_HAVE_OSX || defined ZMQ_HAVE_QNXNTO ||\
defined ZMQ_HAVE_HPUX || defined ZMQ_HAVE_AIX ||\
defined ZMQ_HAVE_NETBSD
#define ZMQ_POLL_BASED_ON_POLL
#elif defined ZMQ_HAVE_WINDOWS || defined ZMQ_HAVE_OPENVMS ||\
defined ZMQ_HAVE_CYGWIN
#define ZMQ_POLL_BASED_ON_SELECT
#endif
// On AIX platform, poll.h has to be included first to get consistent
// definition of pollfd structure (AIX uses 'reqevents' and 'retnevents'
// instead of 'events' and 'revents' and defines macros to map from POSIX-y
// names to AIX-specific names).
#if defined ZMQ_POLL_BASED_ON_POLL
#include <poll.h>
#endif
#include "../include/zmq.h" #include "../include/zmq.h"
#include "device.hpp" #include "device.hpp"
......
...@@ -19,7 +19,6 @@ ...@@ -19,7 +19,6 @@
along with this program. If not, see <http://www.gnu.org/licenses/>. along with this program. If not, see <http://www.gnu.org/licenses/>.
*/ */
#define ZMQ_TYPE_UNSAFE #define ZMQ_TYPE_UNSAFE
#include "../include/zmq.h"
#include "platform.hpp" #include "platform.hpp"
...@@ -46,6 +45,9 @@ ...@@ -46,6 +45,9 @@
#include <poll.h> #include <poll.h>
#endif #endif
// zmq.h must be included *after* poll.h for AIX to build properly
#include "../include/zmq.h"
#if defined ZMQ_HAVE_WINDOWS #if defined ZMQ_HAVE_WINDOWS
#include "windows.hpp" #include "windows.hpp"
#else #else
......
...@@ -122,4 +122,5 @@ int main (int argc, char *argv []) ...@@ -122,4 +122,5 @@ int main (int argc, char *argv [])
assert (events & ZMQ_EVENT_CLOSED); assert (events & ZMQ_EVENT_CLOSED);
return 0 ; return 0 ;
} }
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment