ROS Resources: Documentation | Support | Discussion Forum | Service Status | Q&A

Underlying DDS library being exported when it shouldn't be

I could use some help fixing this warning:

CMake Warning at /home/brannon/ros2b3/share/rmw_coredx_cpp/cmake/ament_cmake_export_libraries-extras.cmake:62 (message):
  Package 'rmw_coredx_cpp' exports the library
  which doesn't exist

libdds* are the compiled CoreDX libraries. I believe that I don’t need them cmake-exported. (I need them present on the machine, but they don’t need to be in the same path that the build server used for things to work correctly.) It appears that somebody tried to fix this in rmw_opensplice recently. Please see the cmake files in this repository:

The file ament_cmake_export_libraries-extras.cmake gets its information from this call in the rmw_coredx package:

I assume the second part (${CoreDX_LIBRARIES}) is the library you are seeing here? I am not sure if you can just remove it from being exported - you can give it a try.

If that doesn’t work you probably want to export the library names instead of their absolute paths.

If you end up needing to export the libraries, here’s a PR from rmw_fastrtps_cpp showing how we avoided full paths:

Thanks for the quick suggestions and good support on this. I have it fixed. Following your suggestions, I modified the problematic line to look like this:
list(APPEND rmw_coredx_cpp_LIBRARIES ${CoreDX_LIBRARIES})