ros2_documentation icon indicating copy to clipboard operation
ros2_documentation copied to clipboard

confusion: does `colcon` or `rosdep` install packages from `package.xml`?

Open VladimirFokow opened this issue 10 months ago • 3 comments

I know rosdep uses package.xml to install packages. But does colcon also use it?

Reading the "Beginner" tutorials, this quote (in section "6 Customize package.xml") is confusing to me. It says that "colcon" is searching package.xml:

This is where your package.xml would list its dependencies on other packages, for colcon to search for


Maybe replace "colcon" with "rosdep"? Or does colcon also use it - in which case, replace "colcon" with "rosdep and colcon"?

VladimirFokow avatar Apr 18 '24 13:04 VladimirFokow

I believe it is correct as-is.

rosdep is the tool that indeed walks the package.xml files and installs dependencies.

colcon is the tool that builds a workspace full of packages. In order to do this, it has to know the topological ordering between them, so it also looks at the dependencies listed in package.xml to figure out that ordering.

If you have suggestions on how to improve the wording, we are of course happy to entertain them.

clalancette avatar Apr 18 '24 14:04 clalancette

Thank you for clarification!

I would replace "colcon" with "rosdep and colcon", just to be more clear. But if there are reasons not to, I'm okay with closing this issue

VladimirFokow avatar Apr 18 '24 14:04 VladimirFokow

@cottsay A friendly ping to follow up on this issue.

MichaelOrlov avatar Apr 25 '24 20:04 MichaelOrlov