ROS Resources: Documentation | Support | Discussion Forum | Service Status | Q&A answers.ros.org
Ask Your Question
1

Catkin: How to find auto-generated roslisp messages?

asked 2013-06-18 03:02:25 -0500

updated 2014-01-28 17:16:56 -0500

ngrennan gravatar image

I'm currently migrating to using roslisp under groovy. For compiling bigger projects I use roslisp_repl with slime (a.k.a. "the REPL"). I have the problem that the REPL does not find auto-generated roslisp messages from wet packages __within__ my catkin workspace.

I did some digging into the code behind the REPL and learned that for compilation it searches all subdirectories of the ROS_PACKAGE_PATH and the ROSLISP_PACKAGE_DIRECTORIES for valid lisp-system (valid lisp-system are directories containing an asd-file).

My problem description:

  • catkin workspace at ~/ros/groovy/catkin_ws
  • .bashrc sources /opt/ros/groovy/source.bash and ~/ros/groovy/catkin_ws/devel/setup.bash
  • wet package test_msgs in src-workspace with some message defintions
  • catkin_make successfully builds messages and puts generated roslisp messages in ~/ros/groovy/catkin_ws/devel/share/common-lisp/ros/test_msgs.
  • ROS_PACKAGE_PATH does not contain this path
  • ROSLISP_PACKAGE_PATH is not set
  • as a result the REPL complains that it cannot find the generated lisp-code

Here are my questions:

  • Has ROSLISP_PACKAGE_DIRECTORIES been intentionally deprecated in groovy?
  • If no, could it be used to contain /opt/ros/groovy/share/common-lisp/ros and all /devel/share/common-lisp/ros sub-directories of all overlays?
  • If yes, how can lisp-compilers find the generated lisp-code in the devel-section of my overlay?
edit retag flag offensive close merge delete

Comments

You do not have to source two setup.bash files. The second one will effectively override everything from the first. So sourcing the file from your custom workspace is enough.

Dirk Thomas gravatar imageDirk Thomas ( 2013-06-18 07:00:09 -0500 )edit

Regarding the fact that the ROS_PACKAGE_PATH does not contain the path: after compiling your workspace you have to source the setup.bash file from the subfolder devel. Than ~/ros/groovy/catkin_ws/devel should be part of tour ROS_PACKAGE_PATH.

Dirk Thomas gravatar imageDirk Thomas ( 2013-06-18 07:01:29 -0500 )edit

@Dirk: Thanks for clarifying that I need to source only one setup.bash-file. Regarding the ROS_PACKAGE_PATH: I just re-did the first catkin tutorial from ros.org (creating workspace). After sourcing devel/setup.bash after catkin_make ~/catkin_ws/devel is not part of the ROS_PACKAGE_PATH for me.

Georg Bartels gravatar imageGeorg Bartels ( 2013-06-18 20:26:45 -0500 )edit

@Dirk: With regards to ROSLISP_PACKAGE_DIRECTORIES, is this environment variable deprecated or can we use it to point to both /opt/ros/<distro>/share/common-lisp/ros and ~/<workspace-dir>/devel/share/common-lisp/ros?

Georg Bartels gravatar imageGeorg Bartels ( 2013-06-18 20:29:59 -0500 )edit

The ROS_PACKAGE_PATH is set by roslib so if that is not in your underlay or in your workspace it will not be set: https://github.com/ros/ros/blob/groovy-devel/core/roslib/env-hooks/10.ros.sh.em#L33

William gravatar imageWilliam ( 2013-06-18 20:31:26 -0500 )edit

My previous comment was incorrect, the RPP only lists the source space - never devel. I don't know how ROSLISP_PACKAGE_DIRECTORIES is used and why at all. I have never used (ros)lisp. We should talk about that offline (via Google hangout/something else) to figure out how roslisp is supposed to work.

Dirk Thomas gravatar imageDirk Thomas ( 2013-06-18 22:12:46 -0500 )edit

@Dirk: Sure. I'll send you message with my gmail-account.

Georg Bartels gravatar imageGeorg Bartels ( 2013-06-18 22:52:08 -0500 )edit

2 Answers

Sort by ยป oldest newest most voted
0

answered 2013-06-25 02:45:02 -0500

Dirk has solved the issue by submitting a patch to roslisp:

https://github.com/ros/roslisp/commit/a050701edde477fb06a807b9e097108730deeb06

Basically, the environment hook of roslisp was broken under groovy. As of roslisp version 1.9.13 the environment variable $ROSLISP_PACKAGE_DIRECTORIES is back and points to all devel/share/common-lisp sub-directories of all catkin workspaces. This makes sure that the roslisp buildsystem called ASDF can find the autogenerated roslisp messages from wet source packages: ASDF recursively crawls all sub-directories of $ROSLISP_PACKAGE_DIRECTORIES and $ROS_PACKAGE_PATH for lisp system definitions, e.g. files with extention *.asd.

edit flag offensive delete link more
0

answered 2013-06-18 06:02:38 -0500

joq gravatar image

There have recently been problems reported with some Groovy packages not generating Lisp messages correctly.

Your problem is possibly releated to this: ros/genmsg#27.

edit flag offensive delete link more

Comments

I'm aware of that problem but my question relates to another issue. I'm having trouble finding generated lisp-code in the devel-part of my catkin_workspace. Whereas the issue you mentioned concerns faulty autogenerated lisp code in the debians.

Georg Bartels gravatar imageGeorg Bartels ( 2013-06-18 20:32:23 -0500 )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

Stats

Asked: 2013-06-18 03:02:25 -0500

Seen: 474 times

Last updated: Jun 25 '13