ROS Resources: Documentation | Support | Discussion Forum | Service Status | Q&A

Classifying Dependencies in package.xml

I’m trying to familiarize myself with ROS Package Format 2 and the general structure of ROS dependencies.

I’ve sketched out some Venn diagrams in a Google Slides presentation, which is open for comments.

I have the basic use cases down (I think) but would appreciate feedback on what I’m missing and where I’ve misclassified things.

1 Like

I believe build_export_depends includes libraries dynamically linked by libraries you export as well as libraries included by headers you export.

It’s also worth noting that for some packages, the build_depend key may be different from the exec_depend key. The most common case of this is that many system packages have a libfoo and libfoo-dev where the latter includes headers. The headers are needed to build, but not to run. Of course, not all packages have both rosdep keys declared, and there’re a lot of lazy dependencies on libfoo-dev.

Comment for the first diagram: As @EVenator mentioned the statement All build depends must be run depends. as well as the visualization of this in the diagram is incorrect.

Comments on the second diagram:

  • The definition of depend is wrong. You can find correct definition in REP 140 (depend = build + build_export + exec).
  • The statement All build export depends are build depends is incorrect - similar to the first diagram.

For completeness, I’m posting links to some more related pages: