Skip to content

Commit

Permalink
Declare as components
Browse files Browse the repository at this point in the history
  • Loading branch information
roncapat committed Jul 20, 2023
1 parent 799c00d commit 0a2b773
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 3 deletions.
2 changes: 1 addition & 1 deletion rosbag2_storage/src/rosbag2_storage/storage_options.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ void declare_storage_options_rw_params(std::shared_ptr<rclcpp::Node> nh, Storage
// std::unordered_map<std::string, std::string> custom_data{};
declare_storage_options_r_params(nh, so);
}
}
} // namespace rosbag2_storage

namespace YAML
{
Expand Down
2 changes: 2 additions & 0 deletions rosbag2_transport/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ find_package(ament_cmake_ros REQUIRED)
find_package(keyboard_handler REQUIRED)
find_package(rcl REQUIRED)
find_package(rclcpp REQUIRED)
find_package(rclcpp_components REQUIRED)
find_package(rcutils REQUIRED)
find_package(rmw REQUIRED)
find_package(rosbag2_compression REQUIRED)
Expand All @@ -57,6 +58,7 @@ target_link_libraries(${PROJECT_NAME}
keyboard_handler::keyboard_handler
rcl::rcl
rclcpp::rclcpp
rclcpp_components::rclcpp_components
rcutils::rcutils
rmw::rmw
rosbag2_compression::rosbag2_compression
Expand Down
1 change: 1 addition & 0 deletions rosbag2_transport/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
<buildtool_depend>ament_cmake_ros</buildtool_depend>

<depend>rclcpp</depend>
<depend>rclcpp_components</depend>
<depend>rosbag2_compression</depend>
<depend>rosbag2_cpp</depend>
<depend>rosbag2_interfaces</depend>
Expand Down
2 changes: 1 addition & 1 deletion rosbag2_transport/src/rosbag2_transport/play_options.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -152,4 +152,4 @@ void declare_play_options_rw_params(std::shared_ptr<rclcpp::Node> nh, PlayOption
"play.disable_loan_message",
false);
}
}
} // namespace rosbag2_transport
7 changes: 7 additions & 0 deletions rosbag2_transport/src/rosbag2_transport/player.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -962,3 +962,10 @@ void Player::publish_clock_update(const rclcpp::Time & time)
}

} // namespace rosbag2_transport

#include "rclcpp_components/register_node_macro.hpp"

// Register the component with class_loader.
// This acts as a sort of entry point, allowing the component to be
// discoverable when its library is being loaded into a running process.
RCLCPP_COMPONENTS_REGISTER_NODE(rosbag2_transport::Player)
2 changes: 1 addition & 1 deletion rosbag2_transport/src/rosbag2_transport/record_options.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ void declare_record_options_rw_params(std::shared_ptr<rclcpp::Node> nh, RecordOp
"record.use_sim_time",
false);
}
}
} // namespace rosbag2_transport

namespace YAML
{
Expand Down
7 changes: 7 additions & 0 deletions rosbag2_transport/src/rosbag2_transport/recorder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -772,3 +772,10 @@ Recorder::stop_discovery()
}

} // namespace rosbag2_transport

#include "rclcpp_components/register_node_macro.hpp"

// Register the component with class_loader.
// This acts as a sort of entry point, allowing the component to be
// discoverable when its library is being loaded into a running process.
RCLCPP_COMPONENTS_REGISTER_NODE(rosbag2_transport::Recorder)

0 comments on commit 0a2b773

Please sign in to comment.