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

You can get the packages you are missing using rosinstall_generator.

First you'll want to source the setup file for any packages you already have:

$ source /path/to/setup.bash

This will put the packages you already have on your ROS_PACKAGE_PATH (RPP). Then you can ask rosinstall_generator to generate a rosinstall file which contains all the packages you need:

$ rosinstall_generator <pkg1> <pkg2> ... <pkgn> --rosdistro indigo --deps --deps-only --tar --exclude RPP > my.rosisntall

You can replace the <pkg1> <pkg2> ... <pkgn> with a white space separated list of the packages you have for which you want to install the dependencies. The --rosdistro option tells it what ROS distribution to pull these packages from, the --deps option tells it to get the dependencies of the packages you specified, the --deps-only tells it to avoid including the packages you specified (I assume you already have those), and the --tar option tells it to get tarballs instead of git/hg repositories if possible (downloads it faster). Finally the --exclude RPP option tells it to avoid adding packages which it can find on your local RPP. It puts all of this out to stdout, so we can pipe that into a rosinstall file with > my.rosinstall, the name of which doesn't really matter.

After you run this you can look at the result in the file or run it without the redirection and see that it makes sense. It shouldn't contain packages you already have built nor the packages you are going to build, but a list of packages in between those.

Once you have the rosinstall file as you like you can fetch the packages in it with wstool:

$ wstool init ~/extra_catkin_ws/src my.rosinstall -j8

If you later need to generate additional rosinstall files, they can be merged into the workspace like this:

$ wstool merge -t ~/extra_catkin_ws/src other.rosinstall
$ wstool up -t ~/extra_catkin_ws/src -j8

Then you can follow the general pattern that is shown in the source install instructions for ROS, doing rosdep and then one of the catkin commands:

$ cd ~/extra_catkin_ws
$ rosdep install --from-paths src -i -y
$ catkin_make_isolated

Hope that helps,