ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
include_directories()
This is most likely your problem.
Even though you first do this:
find_package(catkin REQUIRED COMPONENTS roscpp)
You never update the include path with the contents of catkin_INCLUDE_DIRS
, leading the compiler (or actually: the preprocessor) to not be able to find the headers.
You'll need to change that statement to at least something like the following:
include_directories(${catkin_INCLUDE_DIRS})
Note that this is not really a ROS issue, but a CMake one.
2 | No.2 Revision |
include_directories()
This is most likely your problem.
Even though you first do this:
find_package(catkin REQUIRED COMPONENTS roscpp)
You never update the include path with the contents of catkin_INCLUDE_DIRS
, leading causing the compiler (or actually: the preprocessor) to not be able to find the headers.
You'll need to change that statement to at least something like the following:
include_directories(${catkin_INCLUDE_DIRS})
Note that this is not really a ROS issue, but a CMake one.