diff --git a/rmw_fastrtps_cpp/CMakeLists.txt b/rmw_fastrtps_cpp/CMakeLists.txt index a16b2f69e..c7e5ad922 100644 --- a/rmw_fastrtps_cpp/CMakeLists.txt +++ b/rmw_fastrtps_cpp/CMakeLists.txt @@ -39,12 +39,6 @@ find_package(rosidl_generator_c REQUIRED) find_package(rosidl_typesupport_introspection_c REQUIRED) find_package(rosidl_typesupport_introspection_cpp REQUIRED) -ament_export_dependencies(rcutils) -ament_export_dependencies(rmw) -ament_export_dependencies(rosidl_generator_c) -ament_export_dependencies(rosidl_typesupport_introspection_c) -ament_export_dependencies(rosidl_typesupport_introspection_cpp) - include_directories(include) add_library(rmw_fastrtps_cpp @@ -105,6 +99,12 @@ PRIVATE "RMW_FASTRTPS_CPP_BUILDING_LIBRARY") ament_export_include_directories(include) ament_export_libraries(rmw_fastrtps_cpp) +ament_export_dependencies(rosidl_typesupport_introspection_cpp) +ament_export_dependencies(rosidl_typesupport_introspection_c) +ament_export_dependencies(rosidl_generator_c) +ament_export_dependencies(rcutils) +ament_export_dependencies(rmw) + register_rmw_implementation( "c:rosidl_typesupport_c:rosidl_typesupport_introspection_c" "cpp:rosidl_typesupport_cpp:rosidl_typesupport_introspection_cpp") @@ -115,7 +115,7 @@ if(BUILD_TESTING) endif() ament_package( - CONFIG_EXTRAS "rmw_fastrtps_cpp-extras.cmake" + CONFIG_EXTRAS_POST "rmw_fastrtps_cpp-extras.cmake" ) install( diff --git a/rmw_fastrtps_cpp/rmw_fastrtps_cpp-extras.cmake b/rmw_fastrtps_cpp/rmw_fastrtps_cpp-extras.cmake index 6991ce4ac..5924d3216 100644 --- a/rmw_fastrtps_cpp/rmw_fastrtps_cpp-extras.cmake +++ b/rmw_fastrtps_cpp/rmw_fastrtps_cpp-extras.cmake @@ -20,4 +20,4 @@ find_package(fastrtps REQUIRED CONFIG) find_package(FastRTPS REQUIRED MODULE) list(APPEND rmw_fastrtps_cpp_INCLUDE_DIRS ${FastRTPS_INCLUDE_DIR}) -list(APPEND rmw_fastrtps_cpp_LIBRARIES fastcdr fastrtps) +list(APPEND rmw_fastrtps_cpp_LIBRARIES fastrtps fastcdr)