ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Your CMakeLists is not in the correct order; you define your executable and add libraries before you indicate which libraries to link to; this results in not linking to any libraries.

You should reorder you cmakelists so that the calls to find_package(catkin ...), catkin_package(...) and include_directories() come before any calls to add_executable(), add_library() or target_link_libraries().

Your CMakeLists is not in the correct order; you define your executable and add libraries before you indicate which libraries to link to; this results in not linking to any libraries.libraries. (unfortunately, cmake does not warn you if you use a variable before it is defined).

You should reorder you cmakelists so that the calls to find_package(catkin ...), catkin_package(...) and include_directories() come before any calls to add_executable(), add_library() or target_link_libraries().