Unable to find tf2_ros/transform_listner.h with ros2 Humble
I am trying to compile the HesaiLidarGeneralROS ros2 branch with ros2 Humble. Unfortunately, the compilation fails with the following error.
In file included from /home/akshay/ros2WS/src/HesaiLidar_General_ROS/src/HesaiLidar_General_SDK/src/PandarGeneralRaw/src/pandarGeneral.cc:18:
/home/akshay/ros2WS/src/HesaiLidar_General_ROS/src/HesaiLidar_General_SDK/src/PandarGeneralRaw/src/pandarGeneral_internal.h:37:10: fatal error: tf2_ros/transform_listener.h: No such file or directory
37 | #include <tf2_ros/transform_listener.h>
Changes already tried :
Added tf2, tf2ros and tf2geometry_msgs as REQUIRED
find_package(tf2 REQUIRED)
find_package(tf2_ros REQUIRED)
find_package(tf2_geometry_msgs REQUIRED)
Added tf2, tf2ros and tf2geometrymsgs into targetlink_libraries for PandarGeneralSDK based on the tutorial here
target_link_libraries(PandarGeneralSDK
PandarGeneral
${Boost_LIBRARIES}
${PCL_IO_LIBRARIES}
Boost::thread
pcap
tf2
tf2_ros
tf2_geometry_msgs
)
Added tf2 and tf2_ros as build and exec dependency in package.xml
<exec_depend>tf2</exec_depend>
<build_export_depend>tf2</build_export_depend>
<exec_depend>tf2_ros</exec_depend>
<build_export_depend>tf2_ros</build_export_depend>
Nothing seems to work. I'm not sure where I am going wrong, or what I am missing. Anything really helps. I have attached the CMakeLists.txt and package.xml files.
Asked by SpacemanSPIFF on 2023-06-25 21:27:47 UTC
Comments