[zeromq-dev] conflict between 0MQ and Qt4 C++ libraries?
Martin Sustrik
sustrik at fastmq.com
Mon Apr 20 16:53:03 CEST 2009
Hi Aamir,
> The "offending" lines in the 0MQ poller.hpp file are:
>
> /usr/local/include/zmq/poller.hpp:268: uint32_t signals = signaler.check ();
> /usr/local/include/zmq/poller.hpp:269: assert (signals);
> /usr/local/include/zmq/poller.hpp:276: if (signals & (1 <<
> source_thread_id)) {
>
> It might be a namespace collision with Qt's "signals/slots" mechanism.
All the 0MQ code is properly encapsulated into zmq namespace. Thus, if
there's a collision between 0MQ and Qt it can be caused either by:
1. Qt defines it's own namespace called 'zmq' (unlikely)
2. It defines a macro called 'signals', 'signaler' or 'check' (likely)
If the latter is true, it's quite a nasty misconduct from Qt's side -
one would expect macros to be prefixed by project name (e.g. qt_signals)
- and there's little we can do about that :(
Including qt after zmq seems to be the easiest solution.
Btw, you've did the PowerPC testing, would you like to be listed in the
AUTHORS file, 'credits' section?
Martin
More information about the zeromq-dev
mailing list