Skip to content

Commit

Permalink
Add dependency for nodes to messages
Browse files Browse the repository at this point in the history
This dependency is required if the srv/msg descriptions are in the same
package, see https://answers.ros.org/question/53265/catkin-messages-and-node-in-same-package/

Fixes issue IMRCLab#461.
  • Loading branch information
whoenig committed Aug 17, 2021
1 parent 3876392 commit c2408b9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
4 changes: 1 addition & 3 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,5 @@ cd $ROOT

# ros
cd ros_ws
# -k: hack for dependency issues
catkin_make -DCMAKE_BUILD_TYPE=RelWithDebInfo -k
catkin_make
catkin_make -DCMAKE_BUILD_TYPE=RelWithDebInfo
cd $ROOT
6 changes: 6 additions & 0 deletions ros_ws/src/crazyswarm/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,9 @@ endif()
add_executable(crazyswarm_server
src/crazyswarm_server.cpp
)
add_dependencies(crazyswarm_server
crazyswarm_gencpp
)
target_link_libraries(crazyswarm_server
${catkin_LIBRARIES}
)
Expand All @@ -181,6 +184,9 @@ target_link_libraries(crazyswarm_server
add_executable(crazyswarm_teleop
src/crazyswarm_teleop.cpp
)
add_dependencies(crazyswarm_teleop
crazyswarm_gencpp
)
target_link_libraries(crazyswarm_teleop
${catkin_LIBRARIES}
)
Expand Down

0 comments on commit c2408b9

Please sign in to comment.