Ask Your Question
0

Can't find library '-pthread' [closed]

asked 2019-12-10 11:27:57 -0600

Yummy_Ou gravatar image

I run catkin_make then this error occurs. I have no idea how to deal with it.

'controller_manager_tests' is not my project, just a basic library.

I have already found some methods like here. But still doesn't work.

My OS is Ubuntu 16.04, ROS is kinetic

-- +++ processing catkin package: 'rbdl_test'
-- ==> add_subdirectory(rbdl_test)
-- +++ processing catkin package: 'hardware_interface'
-- ==> add_subdirectory(ros_control-kinetic-devel/hardware_interface)
-- +++ processing catkin package: 'combined_robot_hw'
-- ==> add_subdirectory(ros_control-kinetic-devel/combined_robot_hw)
-- +++ processing catkin package: 'controller_interface'
-- ==> add_subdirectory(ros_control-kinetic-devel/controller_interface)
-- +++ processing catkin package: 'controller_manager'
-- ==> add_subdirectory(ros_control-kinetic-devel/controller_manager)
-- Found Boost: /usr/include (found version "1.58.0") found components:  thread chrono system date_time atomic 
-- +++ processing catkin package: 'force_torque_sensor_controller'
-- ==> add_subdirectory(ros_controllers-kinetic-devel/force_torque_sensor_controller)
-- +++ processing catkin package: 'forward_command_controller'
-- ==> add_subdirectory(ros_controllers-kinetic-devel/forward_command_controller)
-- +++ processing catkin package: 'position_controllers'
-- ==> add_subdirectory(ros_controllers-kinetic-devel/position_controllers)
-- +++ processing catkin package: 'controller_manager_tests'
-- ==> add_subdirectory(ros_control-kinetic-devel/controller_manager_tests)
CMake Error at /home/yummy/catkin_ws/devel/share/controller_manager/cmake/controller_managerConfig.cmake:150 (message):
  Project 'controller_manager_tests' tried to find library '-pthread'.  The
  library is neither a target nor built/installed properly.  Did you compile
  project 'controller_manager'? Did you find_package() it before the
  subdirectory containing its code is included?
Call Stack (most recent call first):
  /opt/ros/kinetic/share/catkin/cmake/catkinConfig.cmake:76 (find_package)
  ros_control-kinetic-devel/controller_manager_tests/CMakeLists.txt:7 (find_package)


-- Configuring incomplete, errors occurred!
See also "/home/yummy/catkin_ws/build/CMakeFiles/CMakeOutput.log".
See also "/home/yummy/catkin_ws/build/CMakeFiles/CMakeError.log".
edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by Yummy_Ou
close date 2019-12-11 05:51:39.828440

1 Answer

Sort by ยป oldest newest most voted
0

answered 2019-12-11 05:51:16 -0600

Yummy_Ou gravatar image

I solve this problem! Just by installing a lower version CMake.

Before I solve the problem: My Ubuntu still is CMake 3.5.1. But because I upgraded CMake to 3.15.3, so when I run "cmake --version", it showed me that 3.15.3.

I now downgrade the CMake version from 3.15.3 to 3.10.0-rc1. Then solve the problem:)

edit flag offensive delete link more

Question Tools

2 followers

Stats

Asked: 2019-12-10 11:27:57 -0600

Seen: 41 times

Last updated: Dec 11 '19