I found if I add -shared, It will solve the make problem, but, I don't know where to modify the Makefile. I've tried LDFLAGS,CXXFLAGS in Makefile https://gist.github.com/anonymous/5453234 , it can not work.
[dlin@h perf]$ make V=1
/bin/sh ../libtool --tag=CXX --mode=link g++ -O2 -pipe -shared -shared -o local_lat local_lat.o ../src/libzmq.la -lrt -lpthread -shared
libtool: link: g++ -O2 -pipe -o .libs/local_lat local_lat.o ../src/.libs/libzmq.so -lrt -lpthread
/usr/bin/ld: .libs/local_lat: hidden symbol `__sync_fetch_and_add_2' in /usr/lib/gcc/sh4-linux/4.2.4/libgcc.a(linux-atomic.o) is referenced by DSO
/usr/bin/ld: final link failed: Nonrepresentable section on output
collect2: ld returned 1 exit status
make: *** [local_lat] Error 1
[dlin@h perf]$ g++ -O2 -pipe -o .libs/local_lat local_lat.o ../src/.libs/libzmq.so -lrt -lpthread
/usr/bin/ld: .libs/local_lat: hidden symbol `__sync_fetch_and_add_2' in /usr/lib/gcc/sh4-linux/4.2.4/libgcc.a(linux-atomic.o) is referenced by DSO
/usr/bin/ld: final link failed: Nonrepresentable section on output
collect2: ld returned 1 exit status
[dlin@h perf]$ g++ -O2 -pipe -o .libs/local_lat local_lat.o ../src/.libs/libzmq.so -lrt -lpthread -shared
The -shared option workable on manual write at the last command, but how to put in Makefile?