Rosdep - how to define dependency management on custom package?
Hi all,
I want to utilise ROS dependency management for my custom packages (in new workspace). I have packages A and B on github, where A depends on B. This means that package.xml of A has to include this line:
<run_depend>'B'</run_depend>
Suppose that A and B are not installed. Now I would like to download just A and use rosdep install to download also B. But I am not sure about correct workflow - how to setup this. I know that there is a .rosinstall file, which connects name of particular package with its address on github. But this means that I can install only packages with depend on packages listed in the .rosinstall file, right?
So in order to use this dependency management, I have to manually add every package name and location (also B) into the .rosinstall file? This does not seem to be very practical..
My question is: Is there any way how to do this in more decentralised fashion? That is: I would like to be able to define entire dependency directly inside the package A, something like this:
<run_depend>'B'</run_depend><location>'http://github.com/B'</location>
..so the rosdep would be able to install new, previously unlisted package B.
============================================
================ edit (based on tfoote's answer):
Still, I would like to be able to do this somehow dynamically. I just discovered this command, which gives me git uri for package referenced by name:
roslocate uri ros_tutorials
And I found out that these information (used by roslocate) are stored here. I suppose that this is some global storage of information about packages which is used also by rosdep and rosinstall_generator??
So my supposed workflow could be:
- create packages A and B on github
- publish info about them them somehow through http://ros.org/doc/groovy/api/
- tell people to:
- download A (e.g. 'git cone github/A')
- run: 'rosdep install src' (finds A in src, determines that B is needed, checks its uri online and downloads it)
- run 'catkin_make --install'
So my updated questions are:
- Is this the right approach to publish own packages?
- Can I publish info about my packages on http://ros.org/doc/groovy/api/?
- If yes: how should I do this? (is the correct approach the one described here)?
- If not: is there a better way? (e.g. I could provide my custom alternative to list of packages on http://ros.org/doc/groovy/api/, but how to redirect all those ros-tools to use it?)
Thank you very much for clarification in advance. Best, Jarda