Issuse when I build rtabmap_slam
Hello, I keep seeing this when I try to build rtabmap_slam. I am using jazzy-devel
/home/thang/robot_ws/src/rtabmap_ros/rtabmap_slam/src/CoreWrapper.cpp: In member function ‘void rtabmap_slam::CoreWrapper::process(const rclcpp::Time&, rtabmap::SensorData&, const rtabmap::Transform&, const std::vector
/home/thang/robot_ws/src/rtabmap_ros/rtabmap_slam/src/CoreWrapper.cpp:2090:85: error: expected primary-expression before ‘double’ 2090 | auto iter = rtabmap_conversions::getClosestIterator<double, geometry_msgs::msg::PoseWithCovarianceStamped>(globalPoses_, data.stamp()); | ^~~~~~
/home/thang/robot_ws/src/rtabmap_ros/rtabmap_slam/src/CoreWrapper.cpp:2147:108: error: ‘getClosestIterator’ is not a member of ‘rtabmap_conversions’ 2147 | , rtabmap::GPS>::const_iterator iter = rtabmap_conversions::getClosestIterator<double, rtabmap::GPS>(gps_, data.stamp()); | ^~~~~~~~~~~~~~~~~~
/home/thang/robot_ws/src/rtabmap_ros/rtabmap_slam/src/CoreWrapper.cpp:2147:127: error: expected primary-expression before ‘double’ 2147 | nst_iterator iter = rtabmap_conversions::getClosestIterator<double, rtabmap::GPS>(gps_, data.stamp()); | ^~~~~~
gmake[2]: *** [CMakeFiles/rtabmap_slam_plugins.dir/build.make:76: CMakeFiles/rtabmap_slam_plugins.dir/src/CoreWrapper.cpp.o] Error 1 gmake[1]: *** [CMakeFiles/Makefile2:139: CMakeFiles/rtabmap_slam_plugins.dir/all] Error 2 gmake: *** [Makefile:146: all] Error 2
It sounds like you have a different version of rtabmap_conversions package on your computer. Make sure you uninstalled the binaries to avoid this issue:
sudo apt remove ros-$ROS_DISTRO-rtabmap*