Catkin_make error

Hi.

I am currently facing hard to run the ZED2 with ROS melodic on the Xavier NX Jetpack 4.6

I followed the below link except for this.
$ git clone --recursive https://github.com/stereolabs/zed-ros-wrapper.git

When I give “catkin_make -DCMAKE_BUILD_TYPE=Release,” it makes below error during the build.

jp@jp-xavier-nx:~/catkin_ws$ catkin_make -DCMAKE_BUILD_TYPE=Release
...
[ 78%] Generating C++ code from zed_interfaces/RGBDSensors.msg
In file included from /home/jp/catkin_ws/devel/include/zed_interfaces/ObjectsStamped.h:19:0,
                 from /home/jp/catkin_ws/src/zed-ros-examples/rviz-plugin-zed-od/src/plugin/include/zed_od_info.hpp:31,
                 from /home/jp/catkin_ws/src/zed-ros-examples/rviz-plugin-zed-od/src/plugin/src/zed_od_info.cpp:25:
/home/jp/catkin_ws/devel/include/zed_interfaces/Object.h:23:10: fatal error: zed_interfaces/Skeleton3D.h: No such file or directory
 #include <zed_interfaces/Skeleton3D.h>
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
zed-ros-examples/rviz-plugin-zed-od/CMakeFiles/rviz_plugin_zed_od.dir/build.make:86: recipe for target 'zed-ros-examples/rviz-plugin-zed-od/CMakeFiles/rviz_plugin_zed_od.dir/src/plugin/src/zed_od_info.cpp.o' failed
make[2]: *** [zed-ros-examples/rviz-plugin-zed-od/CMakeFiles/rviz_plugin_zed_od.dir/src/plugin/src/zed_od_info.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
[ 79%] Generating C++ code from zed_interfaces/Skeleton3D.msg
...
[ 97%] Linking CXX shared library /home/jp/catkin_ws/devel/lib/libZEDSyncTest.so
CMakeFiles/Makefile2:3855: recipe for target 'zed-ros-examples/rviz-plugin-zed-od/CMakeFiles/rviz_plugin_zed_od.dir/all' failed
make[1]: *** [zed-ros-examples/rviz-plugin-zed-od/CMakeFiles/rviz_plugin_zed_od.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 97%] Built target ZEDSyncTest
[ 97%] Linking CXX shared library /home/jp/catkin_ws/devel/lib/libZEDNodelets.so
[ 97%] Built target ZEDNodelets
Makefile:140: recipe for target 'all' failed
make: *** [all] Error 2
Invoking "make -j6 -l6" failed
jp@jp-xavier-nx:~/catkin_ws$

Could anyone let me make one step further?

Hi @jpkong
can you check if the folder <catkin_ws>/src/zed-ros-wrapper/zed-ros-interfaces is populated?

Sure. It populated.
I gave the ‘–recursive’ param to the git clone cmd.

When I searched a one of missing file, it located in the below dir
~/catkin_ws$ find ./ -iname Skeleton3D.h
./devel/include/zed_interfaces/Skeleton3D.h

Hi, Myzhar.

Good news!
I found the cause.

Firstly, I followed the above blog.
According to the guide, I compiled both at once after cloning the ZED ROS wrapper and ZED ROS examples.
It looks to make the error.

I changed the order as below.


I compiled it according to the guide after cloning ZED ROS wrapper.
No error occurred.

Then, I compiled it according to the guide after cloning ZED ROS examples.
No error occurred.

Finally, I could ran the ‘roslaunch zed_display_rviz display_zed2.launch’

Applying this workflow to the blog would help a newbie avoid this error.

1 Like