From 88c800a92ff42cef0dc5af1939b331bfb7c7d633 Mon Sep 17 00:00:00 2001 From: nakul-py Date: Tue, 7 Jan 2025 15:33:00 +0530 Subject: [PATCH] Using urdf/model.hpp for rolling. --- joint_state_broadcaster/src/joint_state_broadcaster.cpp | 6 ++++++ .../src/joint_trajectory_controller.cpp | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/joint_state_broadcaster/src/joint_state_broadcaster.cpp b/joint_state_broadcaster/src/joint_state_broadcaster.cpp index 9bbb862925..068559d5a3 100644 --- a/joint_state_broadcaster/src/joint_state_broadcaster.cpp +++ b/joint_state_broadcaster/src/joint_state_broadcaster.cpp @@ -25,7 +25,13 @@ #include "rclcpp/qos.hpp" #include "rclcpp/time.hpp" #include "std_msgs/msg/header.hpp" + +#include "rclcpp/version.h" +#if RCLCPP_VERSION_GTE(29, 0, 0) +#include "urdf/model.hpp" +#else #include "urdf/model.h" +#endif namespace rclcpp_lifecycle { diff --git a/joint_trajectory_controller/src/joint_trajectory_controller.cpp b/joint_trajectory_controller/src/joint_trajectory_controller.cpp index 763d2acd07..b1c97175cb 100644 --- a/joint_trajectory_controller/src/joint_trajectory_controller.cpp +++ b/joint_trajectory_controller/src/joint_trajectory_controller.cpp @@ -33,7 +33,13 @@ #include "rclcpp_action/create_server.hpp" #include "rclcpp_action/server_goal_handle.hpp" #include "rclcpp_lifecycle/state.hpp" + +#include "rclcpp/version.h" +#if RCLCPP_VERSION_GTE(29, 0, 0) +#include "urdf/model.hpp" +#else #include "urdf/model.h" +#endif namespace joint_trajectory_controller {