undefined reference to symbol ‘pthread_create@@GLIBC_2.2.5’
/lib/x86_64-linux-gnu/libpthread.so.0: 无法添加符号: DSO missing from command line
CMakeFiles/dm01.dir/dm01.cpp.o:在函数‘asio::detail::posix_event::posix_event()’中:
dm01.cpp:(.text._ZN4asio6detail11posix_eventC2Ev[_ZN4asio6detail11posix_eventC5Ev]+0x56):对‘pthread_condattr_setclock’未定义的引用
等等关于pthread的问题,直接在cmake添加就好了。
解决方法
target_link_libraries( aruco_single_estimator -lpthread -lm)