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
terminate called after throwing an instance of 'rclcpp::exceptions::RCLError'
what(): could not create service: Type support not from this implementation. Got:
Handle's typesupport identifier (rosidl_typesupport_cpp) is not supported by this library, at ./src/type_support_dispatch.hpp:111
Could not load library libmy_service__rosidl_typesupport_fastrtps_cpp.so: dlopen error: libmy_service__rosidl_typesupport_fastrtps_cpp.so: cannot open shared object file: No such file or directory, at ./src/shared_library.c:99, at ./src/type_support_dispatch.hpp:76
while fetching it, at ./src/rmw_service.cpp:125, at ./src/rcl/service.c:124
Aborted (core dumped)
The text was updated successfully, but these errors were encountered:
I also wondered about this. Would the cmake be the correct place for that tho? It would be pretty nice to just have a cmake function that compiles your srv / msg file and links the result to your project.
There is a design PR opened about this topic: ros2/design#310 . While we did expose some parts of the rosidl pipeline to the command-line, I don't believe we ever implemented all of the bits necessary to do what you'd like to do.
Question
Is it possible to compile at build time generated IDL-files using
rosidl_cli
to C++ headers and build a ROS service node with that?Setup
CMakeLists.txt
main.cpp
srv/Test.srv
My project structure is also attached here: test.tar.gz
Steps
Where the files reside I execute the following:
rosidl generate --type cpp --type-support cpp my_service srv/Test.srv mv cpp my_service cmake -S . -B build cmake --build build ./build/my-test
Output:
The text was updated successfully, but these errors were encountered: