zeromq / zeromq3-x

ØMQ/3.2 release branch - bug fixes only

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to link the zmq static library?

fengrujun opened this issue · comments

Hi,Sorry for my poor English!
This is a test main.c:
#include <zmq.h>
int main (void)
{
int major, minor, patch;
zmq_version (&major, &minor, &patch);
printf ("Current 0MQ version is %d.%d.%d\n", major, minor, patch);
return 0;
}
When I linked the libzmq.a(gcc main.c /usr/local/lib/libzmq.a),i get some errors(here is a part of errors) like:
/home/test1/armbuild/zeromq-3.2.4/src/ipc_connecter.cpp:116: undefined reference to `std::nothrow'
but i use :gcc main.c /usr/local/lib/libzmq.so
it works great,so how do i link the zmq static libraries?

Please use the IRC channel or zeromq-dev list for questions on building & using ZeroMQ, thanks!