When building azmq for buildroot, I ran into a similar issue as #118. Only this time it was the signal and socket_op tests failing to link rather than the already fixed socket test. The fix should simply be to add ${CMAKE_THREAD_LIBS_INIT} to the linked libraries for those two tests.
/host/lib/gcc/arm-buildroot-linux-gnueabi/7.1.0/../../../../arm-buildroot-linux-gnueabi/bin/ld: CMakeFiles/test_socket_ops.dir/main.cpp.o: undefined reference to symbol 'pthread_key_delete@@GLIBC_2.4'
/host/arm-buildroot-linux-gnueabi/sysroot/lib/libpthread.so.0: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
/host/lib/gcc/arm-buildroot-linux-gnueabi/7.1.0/../../../../arm-buildroot-linux-gnueabi/bin/ld: CMakeFiles/test_signal.dir/main.cpp.o: undefined reference to symbol 'pthread_getspecific@@GLIBC_2.4'
/host/arm-buildroot-linux-gnueabi/sysroot/lib/libpthread.so.0: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
When building azmq for buildroot, I ran into a similar issue as #118. Only this time it was the signal and socket_op tests failing to link rather than the already fixed socket test. The fix should simply be to add ${CMAKE_THREAD_LIBS_INIT} to the linked libraries for those two tests.
/host/lib/gcc/arm-buildroot-linux-gnueabi/7.1.0/../../../../arm-buildroot-linux-gnueabi/bin/ld: CMakeFiles/test_socket_ops.dir/main.cpp.o: undefined reference to symbol 'pthread_key_delete@@GLIBC_2.4' /host/arm-buildroot-linux-gnueabi/sysroot/lib/libpthread.so.0: error adding symbols: DSO missing from command line collect2: error: ld returned 1 exit status
/host/lib/gcc/arm-buildroot-linux-gnueabi/7.1.0/../../../../arm-buildroot-linux-gnueabi/bin/ld: CMakeFiles/test_signal.dir/main.cpp.o: undefined reference to symbol 'pthread_getspecific@@GLIBC_2.4' /host/arm-buildroot-linux-gnueabi/sysroot/lib/libpthread.so.0: error adding symbols: DSO missing from command line collect2: error: ld returned 1 exit status