2 . I follow the tutorial here in 1.2 and wsinit a folder in my catkin_ws/src
folder.
Ok.
3 . If I want to build it, it says that there is a package missing: hardware_interface
, it turns out that this package is not available for jade (yet), so I go ahead with my "missing package" algorithm which is the following:
hardware_interface
is actually available on Jade (see debbuild/jade?q=hardware_interface), just not yet in the public repositories. Building from source is fine, but you may want to see whether you can use the ros-shadow-fixed repository.
4 . I go to my catkin_ws/devel
and do rosws set <name> --git <url_to_repository_with_package_or_stack>
You're mixing wstool
and rosws
. Don't do that.
The reason you have to go to the devel
folder is probably related to that.
5 . I update the ws: rosws update <name>
In a catkin workspace, please only use wstool
. The arguments for set
and update
are the same.
And only do it in your src
folder (which is where your .rosinstall
file should be).
6 . I re-source: source catkin_ws/devel/setup.bash
But only after you've rebuilt your workspace .. right?
Finally: maybe you are already doing it, but you don't mention it: I'd recommend running a rosdep check --from-paths /path/to/your/catkin_ws/src --ignore-src
between steps 5 & 6. That way you'll be sure you have all package dependencies installed, instead of having to find that out during catkin_make
/ catkin build
.
Edit:
The problem is, that I don't know what tools I should use (wstool over rosws) and which I shouldn't.
I'm slightly confused: I thought I was quite clear when I wrote:
In a catkin workspace, please only use wstool
.
Afaik, rosws
was used with rosbuild
workspaces, which is why it doesn't work quite so well with catkin.
Can you please tell me what my approach should be to get and build packages from source in a carkinws?
Basically what you've already been doing, but then only with wstool
, and no trips to your devel
space.
A concrete example (with wstool
):
source /opt/ros/../setup.bash
mkdir -p /path/to/a/new/catkin_ws/src
cd /path/to/a/new/catkin_ws/src
wstool init .
wstool set <name> --git <url_to_repository_with_package_or_stack>
wstool up
cd /path/to/a/new/catkin_ws
# alternatively, use 'rosdep install ..' here directly
rosdep check --from-paths /path/to/a/new/catkin_ws/src --ignore-src
catkin_make
source devel/setup.bash
Alternatively, you could just do a git clone <url_to_repository_with_package_or_stack>
in catkin_ws/src
instead of using wstool
. wstool
comes in handy if you have many repositories to clone, and don't want to do it by hand.
Originally posted by gvdhoorn with karma: 86574 on 2015-12-29
This answer was ACCEPTED on the original site
Post score: 3
Original comments
Comment by Borob on 2015-12-29:
Thank you very much! The problem is, that I don't know what tools I should use (wstool over rosws) and which I shouldn't. So rosdep is okay with catkin, but rosws and probably ros isn't... Can you please tell me what my approach should be to get and build packages from source in a carkinws?
Comment by Borob on 2015-12-29:
Thank you very much, very glad someone shed light on this! Regarding the tools: I know now that I should use wstool over rosws, but my question was: How do I know what tool sets I should use with catkin just from ROS, without asking you?
Comment by William on 2015-12-29:
@Druff sorry for the confusion. The wstool
wiki page mentions that it replaces rosws
for catkin packages: http://wiki.ros.org/wstool This wiki page also uses wstool
in conjunction with catkin: http://wiki.ros.org/catkin/Tutorials/workspace_overlaying I updated a few wiki pages with a note.
Comment by Borob on 2015-12-29:
@William A my bad. Thank you so much!