ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
Hi, I have the same problem but my CMakeLists.txt and package.xml seems good. First I was thinking it was a problem with the new version of ROS Kinetics but it is not, as my other packages compile and work well. Here is my error :
.../catkin_ws/src/stereocamera/src/stereocamera.cpp:21:21: fatal error: ros/ros.h: No such file or directory
The header in my stereocamera.cpp file is #include<ros/ros.h>
. This is my CMakeLists.txt :
cmake_minimum_required(VERSION 2.8.3)
project(stereo_camera)
find_package(catkin REQUIRED COMPONENTS roscpp std_msgs sensor_msgs cv_bridge image_transport compressed_image_transport)
find_package(OpenCV REQUIRED)
catkin_package()
add_executable(stereocamera src/stereocamera.cpp)
target_link_libraries(stereocamera ${catkin_LIBRARIES} ${OpenCV_LIBS})
And my package.xml :
<?xml version="1.0"?>
<package>
<name>stereo_camera</name>
<author>Me</author>
<maintainer email="you@yourdomain.tld">Me</maintainer>
<description>Stereo camera package</description>
<buildtool_depend>catkin</buildtool_depend>
<build_depend>roscpp</build_depend>
<build_depend>std_msgs</build_depend>
<build_depend>sensor_msgs</build_depend>
<build_depend>OpenCV</build_depend>
<build_depend>cv_bridge</build_depend>
<build_depend>image_transport</build_depend>
<build_depend>compressed_image_transport</build_depend>
<run_depend>roscpp</run_depend>
<run_depend>std_msgs</run_depend>
<run_depend>sensor_msgs</run_depend>
<run_depend>OpenCV</run_depend>
<run_depend>cv_bridge</run_depend>
<run_depend>image_transport</run_depend>
<run_depend>compressed_image_transport</run_depend>
</package>
Do you have any idea to fix the problem ?
2 | No.2 Revision |
Hi, I have the same problem but my CMakeLists.txt and package.xml seems seem good.
First I was thinking thought it was a problem with the new version of ROS Kinetics but it is not, as my other packages compile and work well.
Here is my error :
.../catkin_ws/src/stereocamera/src/stereocamera.cpp:21:21: fatal error: ros/ros.h: No such file or directory
The header in my stereocamera.cpp file is #include<ros/ros.h>
. This is my CMakeLists.txt :
cmake_minimum_required(VERSION 2.8.3)
project(stereo_camera)
find_package(catkin REQUIRED COMPONENTS roscpp std_msgs sensor_msgs cv_bridge image_transport compressed_image_transport)
find_package(OpenCV REQUIRED)
catkin_package()
add_executable(stereocamera src/stereocamera.cpp)
target_link_libraries(stereocamera ${catkin_LIBRARIES} ${OpenCV_LIBS})
And my package.xml :
<?xml version="1.0"?>
<package>
<name>stereo_camera</name>
<author>Me</author>
<maintainer email="you@yourdomain.tld">Me</maintainer>
<description>Stereo camera package</description>
<buildtool_depend>catkin</buildtool_depend>
<build_depend>roscpp</build_depend>
<build_depend>std_msgs</build_depend>
<build_depend>sensor_msgs</build_depend>
<build_depend>OpenCV</build_depend>
<build_depend>cv_bridge</build_depend>
<build_depend>image_transport</build_depend>
<build_depend>compressed_image_transport</build_depend>
<run_depend>roscpp</run_depend>
<run_depend>std_msgs</run_depend>
<run_depend>sensor_msgs</run_depend>
<run_depend>OpenCV</run_depend>
<run_depend>cv_bridge</run_depend>
<run_depend>image_transport</run_depend>
<run_depend>compressed_image_transport</run_depend>
</package>
Do you have any idea to fix the problem ?
3 | No.3 Revision |
Hi, I have the same problem but my CMakeLists.txt and package.xml seem good.
First I thought it was a problem with the new version of ROS Kinetics but it is not, as my other packages compile and work well.
well. I am using Ubuntu 16.04 with ROS Kinetics.
Here is my error :
.../catkin_ws/src/stereocamera/src/stereocamera.cpp:21:21: fatal error: ros/ros.h: No such file or directory
The header in my stereocamera.cpp file is #include<ros/ros.h>
. This is my CMakeLists.txt :
cmake_minimum_required(VERSION 2.8.3)
project(stereo_camera)
find_package(catkin REQUIRED COMPONENTS roscpp std_msgs sensor_msgs cv_bridge image_transport compressed_image_transport)
find_package(OpenCV REQUIRED)
catkin_package()
add_executable(stereocamera src/stereocamera.cpp)
target_link_libraries(stereocamera ${catkin_LIBRARIES} ${OpenCV_LIBS})
And my package.xml :
<?xml version="1.0"?>
<package>
<name>stereo_camera</name>
<author>Me</author>
<maintainer email="you@yourdomain.tld">Me</maintainer>
<description>Stereo camera package</description>
<buildtool_depend>catkin</buildtool_depend>
<build_depend>roscpp</build_depend>
<build_depend>std_msgs</build_depend>
<build_depend>sensor_msgs</build_depend>
<build_depend>OpenCV</build_depend>
<build_depend>cv_bridge</build_depend>
<build_depend>image_transport</build_depend>
<build_depend>compressed_image_transport</build_depend>
<run_depend>roscpp</run_depend>
<run_depend>std_msgs</run_depend>
<run_depend>sensor_msgs</run_depend>
<run_depend>OpenCV</run_depend>
<run_depend>cv_bridge</run_depend>
<run_depend>image_transport</run_depend>
<run_depend>compressed_image_transport</run_depend>
</package>
Do you have any idea to fix the problem ?
Note that the package runs well on Ubuntu 14.04 with ROS Jade.
4 | No.4 Revision |
Hi, I have the same problem but my CMakeLists.txt and package.xml seem good.
First I thought it was a problem with the new version of ROS Kinetics Kinetic but it is not, as my other packages compile and work well. I am using Ubuntu 16.04 with ROS Kinetics. Kinetic.
Here is my error :
.../catkin_ws/src/stereocamera/src/stereocamera.cpp:21:21: fatal error: ros/ros.h: No such file or directory
The header in my stereocamera.cpp file is #include<ros/ros.h>
. This is my CMakeLists.txt :
cmake_minimum_required(VERSION 2.8.3)
project(stereo_camera)
find_package(catkin REQUIRED COMPONENTS roscpp std_msgs sensor_msgs cv_bridge image_transport compressed_image_transport)
find_package(OpenCV REQUIRED)
catkin_package()
add_executable(stereocamera src/stereocamera.cpp)
target_link_libraries(stereocamera ${catkin_LIBRARIES} ${OpenCV_LIBS})
And my package.xml :
<?xml version="1.0"?>
<package>
<name>stereo_camera</name>
<author>Me</author>
<maintainer email="you@yourdomain.tld">Me</maintainer>
<description>Stereo camera package</description>
<buildtool_depend>catkin</buildtool_depend>
<build_depend>roscpp</build_depend>
<build_depend>std_msgs</build_depend>
<build_depend>sensor_msgs</build_depend>
<build_depend>OpenCV</build_depend>
<build_depend>cv_bridge</build_depend>
<build_depend>image_transport</build_depend>
<build_depend>compressed_image_transport</build_depend>
<run_depend>roscpp</run_depend>
<run_depend>std_msgs</run_depend>
<run_depend>sensor_msgs</run_depend>
<run_depend>OpenCV</run_depend>
<run_depend>cv_bridge</run_depend>
<run_depend>image_transport</run_depend>
<run_depend>compressed_image_transport</run_depend>
</package>
Do you have any idea to fix the problem ?
Note that the package runs well on Ubuntu 14.04 with ROS Jade.
5 | No.5 Revision |
Hi, I have the same problem but my CMakeLists.txt and package.xml seem good. First I thought it was a problem with the new version of ROS Kinetic but it is not, as my other packages compile and work well. I am using Ubuntu 16.04 with ROS Kinetic. Here is my error :
.../catkin_ws/src/stereocamera/src/stereocamera.cpp:21:21: .../catkin_ws/src/stereocamera/src/stereocamera.cpp:1:21: fatal error: ros/ros.h: No such file or directory
The header in my stereocamera.cpp file is #include<ros/ros.h>
. This is my CMakeLists.txt :
cmake_minimum_required(VERSION 2.8.3)
project(stereo_camera)
find_package(catkin REQUIRED COMPONENTS roscpp std_msgs sensor_msgs cv_bridge image_transport compressed_image_transport)
find_package(OpenCV REQUIRED)
catkin_package()
add_executable(stereocamera src/stereocamera.cpp)
target_link_libraries(stereocamera ${catkin_LIBRARIES} ${OpenCV_LIBS})
And my package.xml :
<?xml version="1.0"?>
<package>
<name>stereo_camera</name>
<author>Me</author>
<maintainer email="you@yourdomain.tld">Me</maintainer>
<description>Stereo camera package</description>
<buildtool_depend>catkin</buildtool_depend>
<build_depend>roscpp</build_depend>
<build_depend>std_msgs</build_depend>
<build_depend>sensor_msgs</build_depend>
<build_depend>OpenCV</build_depend>
<build_depend>cv_bridge</build_depend>
<build_depend>image_transport</build_depend>
<build_depend>compressed_image_transport</build_depend>
<run_depend>roscpp</run_depend>
<run_depend>std_msgs</run_depend>
<run_depend>sensor_msgs</run_depend>
<run_depend>OpenCV</run_depend>
<run_depend>cv_bridge</run_depend>
<run_depend>image_transport</run_depend>
<run_depend>compressed_image_transport</run_depend>
</package>
Do you have any idea to fix the problem ?
Note that the package runs well on Ubuntu 14.04 with ROS Jade.