看起來很簡單的一個問題:ROS找不到消息頭文件 5C

~/catkin_ws/src/beginner_tutoruals/src/add_two_ints_server.cpp:2:43: fatal error: beginner_tutorials/AddTwoInts.h: No such file or directory
compilation terminated.
beginner_tutoruals/CMakeFiles/add_two_ints_server.dir/build.make:62: recipe for target 'beginner_tutoruals/CMakeFiles/add_two_ints_server.dir/src/add_two_ints_server.cpp.o' failed
make[2]: *** [beginner_tutoruals/CMakeFiles/add_two_ints_server.dir/src/add_two_ints_server.cpp.o] Error 1
CMakeFiles/Makefile2:363: recipe for target 'beginner_tutoruals/CMakeFiles/add_two_ints_server.dir/all' failed
make[1]: *** [beginner_tutoruals/CMakeFiles/add_two_ints_server.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
~/catkin_ws/src/beginner_tutoruals/src/add_two_ints_client.cpp:2:43: fatal error: beginner_tutorials/AddTwoInts.h: No such file or directory
compilation terminated.
beginner_tutoruals/CMakeFiles/add_two_ints_client.dir/build.make:62: recipe for target 'beginner_tutoruals/CMakeFiles/add_two_ints_client.dir/src/add_two_ints_client.cpp.o' failed
make[2]: *** [beginner_tutoruals/CMakeFiles/add_two_ints_client.dir/src/add_two_ints_client.cpp.o] Error 1
CMakeFiles/Makefile2:1357: recipe for target 'beginner_tutoruals/CMakeFiles/add_two_ints_client.dir/all' failed
make[1]: *** [beginner_tutoruals/CMakeFiles/add_two_ints_client.dir/all] Error 2
Makefile:138: recipe for target 'all' failed

ros

3个回答

通過rosmsg show和rossrv show又是可以找到的,中間不知道哪個環節出了點問題,學習中

通過rosmsg show和rossrv show又是可以找到的

这是编译错误,缺少AddTwoInts.h这个文档,需要检查下编译工程是否包含对应的文件夹和对应的头文件

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问
相关内容推荐