ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

What is the use of catkin_package(CATKIN_DEPENDS message_runtime) for ROS Python packages defining new messages or services?

asked 2016-06-20 10:05:15 -0500

khatribharat gravatar image

This ROS Wiki page in Section 1.1 Messages and Services states that we need to add the following in CMakeLists.txt for all ROS Python packages defining new messages or services:

catkin_package(CATKIN_DEPENDS message_runtime)

Can someone explain why is this required?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2016-06-20 15:47:30 -0500

William gravatar image

updated 2016-06-20 15:49:45 -0500

It ensures that when another package asks for this packages headers, libraries, etc. by using find_package, that those include the headers and libraries from message runtime as well. This necessary because there are headers provided by message runtime (either directly or indirectly) that are included by the generated code for your messages in this package.

edit more specifically for Python I believe there is Python code which provided somehow by message runtime that the generated Python code for your messages will import.

edit flag offensive delete link more

Comments

Can you elaborate the specifically for Python part? My question is specifically related to Python packages.

khatribharat gravatar image khatribharat  ( 2016-06-21 01:01:43 -0500 )edit
1

Messages are not language specific. While you might only use them in Python someone else might use the messages from your package with C++.

Dirk Thomas gravatar image Dirk Thomas  ( 2016-06-21 08:51:15 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2016-06-20 10:05:15 -0500

Seen: 1,782 times

Last updated: Jun 20 '16