Ask Your Question

Will declaring a metapackage dependency pull all children packages.

asked 2013-08-19 05:24:34 -0500

ehuang gravatar image

I have meta package structured like so


  vision_common/ (a subpackage in the package)



I want to use the vision_msgs in another package. Is it sufficient to do <run_depend>vision_common</run_depend>and


In the other package? I'm running into trouble with the following error:

CMake Error at /home/vision/catkin_ws/build/planning_common/cmake/planning_common-genmsg.cmake:3 (message):
  Could not find messages which
  depends on.  Did you forget to specify generate_messages(DEPENDENCIES ...)?

  Cannot locate message [ParametricObjectMsg]: unknown package
  [vision_common] on search path [{{'household_objects_database_msgs':
  'shape_msgs': ['/opt/ros/groovy/share/shape_msgs/msg'], 'vision_msgs':
  'std_msgs': ['/opt/ros/groovy/share/std_msgs/msg'], 'moveit_msgs':
  ['/opt/ros/groovy/share/moveit_msgs/msg'], 'trajectory_msgs':
  ['/opt/ros/groovy/share/trajectory_msgs/msg'], 'sensor_msgs':
  ['/opt/ros/groovy/share/sensor_msgs/msg'], 'object_recognition_msgs':
  ['/opt/ros/groovy/share/object_recognition_msgs/msg'], 'octomap_msgs':
  ['/opt/ros/groovy/share/octomap_msgs/msg'], 'manipulation_msgs':
  ['/opt/ros/groovy/share/manipulation_msgs/msg'], 'geometry_msgs':
  ['/opt/ros/groovy/share/geometry_msgs/msg'], 'actionlib_msgs':
  ['/opt/ros/groovy/share/actionlib_msgs/msg'], 'control_msgs':
  ['/opt/ros/groovy/share/control_msgs/msg'], 'diagnostic_msgs':
Call Stack (most recent call first):
  /opt/ros/groovy/share/genmsg/cmake/genmsg-extras.cmake:280 (include)
  planning_common/CMakeLists.txt:28 (generate_messages)
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2013-08-19 12:17:48 -0500

ahendrix gravatar image

No; you should explicitly depend on the packages that you use.

The main reason for this is that the CMake file in most metapackages does not pull in cmake files for its dependencies.

In your case, I would explicitly depend on vision_msgs in both your package.xml and your CMake file.

P.S. - this may also be a problem with your service file. If you're still having trouble, I suggest adding your service file to the question.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2013-08-19 05:24:34 -0500

Seen: 377 times

Last updated: Aug 19 '13