[Interest] Qt5.3 beta and msvc2013 "Signal not found" from external dll

Brian Dentino brian.dentino at gmail.com
Tue Apr 29 06:41:00 CEST 2014


Hi all,

I'm having a hard time getting to the root of a warning I see when I run an
application I'm building for Windows 7 (compiled via msvc2013 x64
toolchain).

I have an external dll I am linking to, which exposes a QObject subclass
that has some signals:

class USYSWEBSOCKETREMOTEOBJECTLIBSHARED_EXPORT WsServerObjectRegistry

: public ObjectRegistry

{

   Q_OBJECT


   friend class WsServerMessenger;


public:

   WsServerObjectRegistry(int port, QObject* parent = 0);

   WsServerObjectRegistry(QObject* parent = 0);


   quint16 serverPort();


signals:

   void clientJoined(QUuid clientId);

   void clientLeft(QUuid clientId);

};


My application attempts to use the new Qt5 signals/slots syntax to
hook up to these signals:


QObject::connect(m_ObjectRegistry, &WsServerObjectRegistry::clientJoined,
      this, &DiagnosticsServer::onClientConnected);
QObject::connect(m_ObjectRegistry, SIGNAL(clientLeft(QUuid)),
      this, SLOT(onClientDisconnected(QUuid)));


The first connect attempt produces the following warning:

  "QObject::connect: signal not found in WsServerObjectRegistry"


Here's what I've tried/checked:

  - Old syntax using SIGNAL/SLOT macros seems to work fine.

  - Run dumpbin on the dll in question and verified that the signal
functions are actually exported.

  - dll in question, Qt libraries, and application are all compiled
with same toolchain (msvc2013, x64)


Has anyone run into something like this before? Could this be a bug,
or am I doing something wrong in the link/export/import process? My
experience with Qt Windows development is admittedly limited, so any
advice for debugging this would be greatly appreciated.


Thanks,

Brian
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20140428/9a9b88bb/attachment.html>


More information about the Interest mailing list