add zmq_compat check for libzmq 4

Fixes missing ZMQ_POLL_MSEC, which was undefined with libzmq 4.
No other necessary changes to work with current libzmq.