Small Correction in the course work in 3.1 solution

Hi,
In the exercise 3.1 solution.There is some redundancy in CMakeLists.txt file.
we are already creating a librabry here with robot_manager.cpp file as follows

## Declare a C++ library
add_library(${PROJECT_NAME}_lib
   src/robot_manager.cpp
 )

I think we just need to link library to the robot_manager_node.cpp executable. Instead, in the solution,
you are compiling robot_manager.cpp file again as shown below which is kind of redundancy

# add the executable
add_executable(robot_manager_node src/robot_manager_node.cpp [color=#]src/robot_manager.cpp[/color])
target_link_libraries(robot_manager_node ${catkin_LIBRARIES} my_robot_manager_lib)

you can change above lines as follows

add_executable(robot_manager_node src/robot_manager_node.cpp)
target_link_libraries(robot_manager_node ${catkin_LIBRARIES} my_robot_manager_lib)

Hi @rc_thota,

thank you very much for your feedback.

Iā€™m passing it to the responsible for updating that course.

Cheers.

cc: @albertoezquerro

1 Like

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.