ROS Writing a Simple Service and Client (C++) - Invoking "make -j8 -l8" failed [closed]
Hello everyone,
In the above mentioned ROS tutorial I can't seem to not get an error when running the catkin_make command. I have double checked every step of the tutorial and recreated every txt and cpp file required many times to make sure there was no error but its still not working. (obviously I am very new to ROS programming and honestly I can't even pin point where the problem is).
This is the command and error I get:
ramiammourah@DESKTOP-EJVAUG3:~/catkin_ws$ catkin_make
Base path: /home/ramiammourah/catkin_ws
Source space: /home/ramiammourah/catkin_ws/src
Build space: /home/ramiammourah/catkin_ws/build
Devel space: /home/ramiammourah/catkin_ws/devel
Install space: /home/ramiammourah/catkin_ws/install
####
#### Running command: "make cmake_check_build_system" in "/home/ramiammourah/catkin_ws/build"
####
####
#### Running command: "make -j8 -l8" in "/home/ramiammourah/catkin_ws/build"
####
[ 0%] Built target std_msgs_generate_messages_lisp
[ 0%] Built target std_msgs_generate_messages_cpp
[ 0%] Built target std_msgs_generate_messages_eus
[ 0%] Built target std_msgs_generate_messages_py
[ 0%] Built target std_msgs_generate_messages_nodejs
[ 11%] Built target listener
[ 11%] Built target _beginner_tutorials_generate_messages_check_deps_Num
[ 11%] Built target _beginner_tutorials_generate_messages_check_deps_AddTwoInts
[ 23%] Built target talker
[ 76%] Built target beginner_tutorials_generate_messages_lisp
[ 82%] Built target beginner_tutorials_generate_messages_cpp
[ 94%] Built target beginner_tutorials_generate_messages_nodejs
[100%] Built target beginner_tutorials_generate_messages_eus
[100%] Built target beginner_tutorials_generate_messages_py
[100%] Built target beginner_tutorials_gencpp
[100%] Built target beginner_tutorials_generate_messages
make[2]: *** No rule to make target 'beginner_tutorials/CMakeFiles/add_two_ints_server.dir/build'. Stop.
CMakeFiles/Makefile2:1422: recipe for target 'beginner_tutorials/CMakeFiles/add_two_ints_server.dir/all' failed
make[1]: *** [beginner_tutorials/CMakeFiles/add_two_ints_server.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
make[2]: *** No rule to make target 'beginner_tutorials/CMakeFiles/add_two_ints_client.dir/build'. Stop.
CMakeFiles/Makefile2:1459: recipe for target 'beginner_tutorials/CMakeFiles/add_two_ints_client.dir/all' failed
make[1]: *** [beginner_tutorials/CMakeFiles/add_two_ints_client.dir/all] Error 2
Makefile:140: recipe for target 'all' failed
make: *** [all] Error 2
Invoking "make -j8 -l8" failed
CMakeLists.txt:
cmake_minimum_required(VERSION 2.8.3)
project(beginner_tutorials)
find_package(catkin REQUIRED COMPONENTS roscpp rospy std_msgs genmsg)
add_message_files(FILES Num.msg)
add_service_files(FILES AddTwoInts.srv)
generate_messages(DEPENDENCIES std_msgs)
catkin_package()
include_directories(include ${catkin_INCLUDE_DIRS})
add_executable(talker src/talker.cpp)
target_link_libraries(talker ${catkin_LIBRARIES})
add_executable(listener src/listener.cpp)
target_link_libraries(listener ${catkin_LIBRARIES})
add_executable(add_two_ints_server src/add_two_ints_server.cpp)
target_link_libraries(add_two_ints_server ${catkin_LIBRARIES})
add_dependencies(add_two_ints_server beginner_tutorials_gencpp)
add_executable(add_two_ints_client src/add_two_ints_client.cpp)
target_link_libraries(add_two_ints_client ${catkin_LIBRARIES})
add_dependencies(add_two_ints_client beginner_tutorials_gencpp)
The CMakeLists.txt, Package.xml, add_two_ints_server.cpp, add_two_ints_client.cpp files contents are exactly as described in the tutorial.
I am running on Ubuntu 18.04 for Windows application and followed the ROS wiki tutorial for installation.
Any assistance is appreciated!
paste the content of your CMakeLists.txt please