catkin_ws/ vs share/
Can anyone plaease explain to me what the difference between folders catkin_ws/ and /opt/ros/hydro/share is? what is the purpose of each? thanks!
ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
Can anyone plaease explain to me what the difference between folders catkin_ws/ and /opt/ros/hydro/share is? what is the purpose of each? thanks!
catkin_ws (could be called anything you want really, foo_ws) is the workspace in which you want to develop your packages on. Inside the catkin_ws folder in the devel/ folder you will see a setup.bash file. If you source this bash file, it will mean that your current terminal window is set up to the environment of your catkin_ws.
opt/ros/hydro/share is where all the debian packages you download from sudo apt-get install ros-hydro-whatever package will be installed to. Inside that folder is just the binary executables, and you most likely won't see any source files in there, except maybe for some include files. As a good practice, You don't want to edit things in this folder because this is where pre-approved, tested, and working ros packages go. If you want to possibly modify some code (say for a pull request) for some package, you should rather download the source for that package from github or wherever, put it into your catkin_ws and then build it inside your catkin_ws. So to sum things up, put the code you will write/modify, into your catkin_ws. apt-get installed ros packages into the /opt/ros/[distro]/share folder.
Hope this clarifies some things
The /opt/ros/kinetic/share
folder of ros kinetic only includes the cmake modules, and the executables you mentioned are stored in the /opt/ros/kinetic/lib
directory.
Hi there, thanks for explaining the above.
From my understanding:
1. I can create a launch file to call unmodified packages I need from /opt/ros/distro/share
.
2. I can also create launch file and call modified packages installed in catkin_ws
.
Question is, can they both work together? Thank you.
Asked: 2014-10-29 23:59:57 -0600
Seen: 2,592 times
Last updated: Oct 30 '14