You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It should be possible to generate code for services in a different namespace than srv, like action.
Feature description
rosidl_generator_c and rosidl_generator_cpp need to be able to generate code for messages and services in the namespace action instead of msg or srv.
Implementation considerations
subfolder variable
Messages can already be generated in the srv namespace. This is done for the Request and Response messages used for services to avoid conflicting with other messages. In the templates the variable subfolder is used to switch between msg and srv.
I think this means a .msg that lived in a folder action would get the right namespace. Services don't use subfolder currently, so that will need to be changed.
CMake output file awareness
rosidl_cmake needs to know the files a generator will output ahead of time so it can create a cmake target that is invalidated when the generated files change. For services this is hardcoded to add *Request.srv and Response.srv in an srv folder. This will need to be changed to allow the service file to be in a different folder.
Feature request
It should be possible to generate code for services in a different namespace than
srv
, likeaction
.Feature description
rosidl_generator_c
androsidl_generator_cpp
need to be able to generate code for messages and services in the namespaceaction
instead ofmsg
orsrv
.Implementation considerations
subfolder
variableMessages can already be generated in the
srv
namespace. This is done for the Request and Response messages used for services to avoid conflicting with other messages. In the templates the variablesubfolder
is used to switch betweenmsg
andsrv
.rosidl/rosidl_generator_c/resource/msg.h.em
Lines 10 to 12 in 206dd2b
subfolder
is populated by the location of the.msg
file.rosidl/rosidl_generator_cpp/rosidl_generator_cpp/__init__.py
Line 52 in 206dd2b
I think this means a
.msg
that lived in a folderaction
would get the right namespace. Services don't usesubfolder
currently, so that will need to be changed.CMake output file awareness
rosidl_cmake
needs to know the files a generator will output ahead of time so it can create a cmake target that is invalidated when the generated files change. For services this is hardcoded to add*Request.srv
andResponse.srv
in ansrv
folder. This will need to be changed to allow the service file to be in a different folder.rosidl/rosidl_cmake/cmake/rosidl_generate_interfaces.cmake
Lines 97 to 98 in 206dd2b
The text was updated successfully, but these errors were encountered: