Closed lixiangnlp closed 8 years ago
I have the same issue on ubuntu 15.10
I have the same issue on ubuntu 15.04
Any ideas? I have the same issue with Arch Linux
put the option -lpthread at the end of the cxxflags
should be fixed in recent versions
FYI, it's still an issue when compiling with examples on arch:
Scanning dependencies of target BroadcastProxy
[ 33%] Building CXX object CMakeFiles/BroadcastProxy.dir/example/broadcast/BroadcastProxy.cpp.o
[ 34%] Linking CXX executable bin/BroadcastProxy
/usr/bin/ld: CMakeFiles/BroadcastProxy.dir/example/broadcast/BroadcastProxy.cpp.o: undefined reference to symbol 'pthread_setname_np@@GLIBC_2.12'
/usr/lib/libpthread.so.0: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
make[2]: *** [CMakeFiles/BroadcastProxy.dir/build.make:107: bin/BroadcastProxy] Error 1
make[1]: *** [CMakeFiles/Makefile2:68: CMakeFiles/BroadcastProxy.dir/all] Error 2
make: *** [Makefile:139: all] Error 2
Builds fine without expamles though, still thought it's worth mentioning.
/usr/bin/ld: warning: libboost_thread.so.1.59.0, needed by /usr/local/lib/../lib/libfolly.so, may conflict with libboost_thread.so.1.54.0 /usr/bin/ld: warning: libboost_system.so.1.59.0, needed by /usr/local/lib/../lib/libfolly.so, may conflict with libboost_system.so.1.54.0 /usr/bin/ld: ../gmock/src/gmock-build/libgmock.a(gtest-all.cc.o): undefined reference to symbol 'pthread_key_delete@@GLIBC_2.2.5' //lib/x86_64-linux-gnu/libpthread.so.0: error adding symbols: DSO missing from command line collect2: error: ld returned 1 exit status make[2]: * [bin/AcceptorTest] error 1 make[1]: * [CMakeFiles/AcceptorTest.dir/all] error 2 make: *\ [all] error 2
I can not find the solution for the error.
uname -a:
Linux lixiang-ubuntu 3.16.0-50-generic #67~14.04.1-Ubuntu SMP Fri Oct 2 22:07:51 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux