ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

There is no way to affect build order in a single workspace other than a build_depend tag. There is no notion of optional dependencies.

I imagine that hector_pose_estimation will publish data in messages defined in hector_uav_msgs, but the code to do so will only be built iff hector_uav_msgs is found? A different way to do this (without optional dependencies) is to have a third package which builds a plugin for hector_pose_estimation and directly depends on both hector_pose_estimation and hector_uav_msgs. At runtime a node in hector_pose_estimation could discover, load, and execute the plugin from the third package OR you could produce a node in the third package which is a drop-in replacement of the node(s) in hector_pose_estimation but which also publishes the messages. This way hector_pose_estimation is simplified and does not require an optional dependency on hector_uav_msgs, and to add this new functionality you just add hector_uav_msgs and the new third package to the workspace.

A workaround is to build hector_uav_msgs in a separate workspace before building hector_pose_estimation. This ensures that hector_uav_msgs is built first.