Ask Your Question
0

trigger recompilation of installed msgs

asked 2018-06-05 06:11:27 -0600

amosteo gravatar image

Related to my question about triggering a new language generator: https://answers.ros.org/question/2918...

I currently have a workspace (from source) with the official ROS2 repositories. This is "installed", so to say, so it is not recompiled. My Ada-related packages are in an overlay workspace, which is recompiled often.

My generator for Ada is correctly triggered when a new .msg is defined in my packages. However, messages already in the official sources (std_msgs, etc) are obviously left alone.

My question is if there is some sanctioned way of regenerating the messages in "parent" overlays.

Looking at ros2_java I see that it basically brings in a lot of ros2 repositories to its workspace during the compilation of ros2_java. I see some problems with this:

  1. Compilation times are higher.
  2. It seems a waste to recompile things that have been compiled during the "official" installation.
  3. If I were working with a "stable" ROS2 source (e.g. Ubuntu packages) it would feel very strange to have to recompile from sources core packages that are installed via package manager (I'm thinking here on the long term for users of those client libraries that don't come in the base ROS2).

I'm leaning toward identifying the installation tree of rosidl_generator_c and search all messages in there, but it seems inelegant, and it would miss other hypothetical overlays' messages.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-07-05 17:54:43 -0600

Dirk Thomas gravatar image

My question is if there is some sanctioned way of regenerating the messages in "parent" overlays.

No, currently there is no such way.

I'm leaning toward identifying the installation tree of rosidl_generator_c and search all messages in there, but it seems inelegant, and it would miss other hypothetical overlays' messages.

There is certainly a better approach for this. All message packages already register themselves at the resource index (see the directory <install>/share/ament_index/resource_index/rosidl_interfaces). Each mesage package only exports all messages / services using a CMake config file (e.g. <install>/share/std_msgs/cmake/rosidl_cmake-extras.cmake). It should be easily doable to provide that information through the resource index to make it available in non-CMake context.

edit flag offensive delete link more

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: 2018-06-05 06:11:27 -0600

Seen: 50 times

Last updated: Jul 05 '18