Question

I get the following error:

"Error 1 error LNK2019: unresolved external symbol _imp_zmq_init referenced in function "public: __thiscall zmq::context_t::context_t(int)" (??0context_t@zmq@@QAE@H@Z) ZeroMQPlay.obj ZeroMQPlay"

With this C++ code:

include "stdafx.h"
include <zmq.hpp>

int _tmain(int argc, _TCHAR* argv[])
{
 zmq::context_t ctx(1);

 return 0;
}

Heelp!

Was it helpful?

Solution

You have to tell the linker about the ZeroMQ library. If you've built ZeroMQ as a VS project, the easiest way is to add the ZeroMQ project to the solution containing your own project and mark your project as dependent on it.

OTHER TIPS

Afaiu you're supposed to build the zeromq library first, and link it with your app.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top