Ask Your Question
3

User generated resources for a catkin package

asked 2014-03-06 10:34:41 -0600

aharmat gravatar image

updated 2014-03-07 06:25:53 -0600

I am converting a package from rosbuild to catkin, which has a 'launch' folder as well as folders for various user generated files that are loaded by an executable after the file names are passed in as params. After catkin builds the package, the results are placed in the devel folder, but the launch files and the user generated files remain in the source folder. Using my package in this way seems wrong, as I am constantly messing around with the launch files and the user files, which seems to go against the spirit of the catkin build system. What is the accepted way of handling launch and user generated files with catkinized packages?

UPDATE: I have followed the method at the bottom of http://wiki.ros.org/catkin/CMakeLists... and can now install launch and other files to CATKIN_PACKAGE_SHARE_DESTINATION when invoking the install target on catkin_make. The problem now is that calling roslaunch my_package my_launch.launch still refers to the launch file in the src directory, so the installation was effectively useless. Also, calling $(find my_package) in a launch file finds my_package in the src directory, so any user generated files placed in install/share/my_package are not found.

UPDATE 2: I forgot to source the setup.bash file from the install directory (instead of the devel directory), which is why I was seeing the behaviour above. Once I sourced the proper setup.bash file, everything worked as intended. On a side note, why is CATKIN_PACKAGE_BIN_DESTINATION lib/my_package rather than bin/my_package?

edit retag flag offensive close merge delete

Comments

``CATKIN_PACKAGE_BIN_DESTINATION`` follows Linux Filesystem Hierarchy standards for executable files that are not supposed to be globally defined.

joq gravatar imagejoq ( 2014-03-07 06:30:49 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2014-03-07 04:48:21 -0600

Dirk Thomas gravatar image

It is the intended behavior that only generated artifacts (e.g. executables, libraries and generated code) are placed in the devel folder. It is explicitly avoided to copy files from source to devel.

The recommended way is that you place your launch files in a subfolder launch inside of your package and in the installations step make sure to install them to ${CATKIN_PACKAGE_SHARE_DESTINATION}/launch.

Please describe why you need to "mess around" with the launch files and user files because of that in order to get a more precise answer how to deal with "user files".

edit flag offensive delete link more

Comments

Please see updated question. Users might need to change launch files in order to tweak parameters or to remap topics. The "user files" in this case refer to camera masks used to block image regions corresponding to the robot body, which will be unique for each user/robot.

aharmat gravatar imageaharmat ( 2014-03-07 06:05:42 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

2 followers

Stats

Asked: 2014-03-06 10:34:41 -0600

Seen: 333 times

Last updated: Mar 07 '14