nim-lang / nim-zmq

Nim ZMQ wrapper
https://nim-lang.github.io/nim-zmq/zmq.html
MIT License
67 stars 17 forks source link

make it work with zeromq-4.1.1 .. 4.2.0 #7

Closed djellemah closed 7 years ago

djellemah commented 7 years ago

based on douglass-larocca's pull request. This works for libzmq >= 4.1.1, but fails loudly for <= 4.1.0 where sizeof(TMsg) != sizeof(zmq_msg_t) with an exception like expecting TMsg size of 64 but found 48 from libzmq-4.1.0 [LibraryError] A user could edit the ZMQVERSION values in zmq.nim to make that work. I can't see a way to make that work automagically without compile-time ffi, or some kind of install-time configuration. Hopefully I'm missing something obvious ;-)