Open zhlx007 opened 2 months ago
hello,我使用的是ROS Noetic自带的pcl,如果我没有记错的话,应该是pcl-1.10
如果你的本地环境一直没法编译通过,可以尝试使用docker,我提供的有docker环境
我的系统是ubuntu18.04,这个bug解决了,缺少头文件,我加了头文件#include <pcl/common/point_tests.h>就好了,现在又出了个问题:
[ 73%] Linking CXX executable /home/test/navigation/funny_lidar_slam_ws/devel/lib/funny_lidar_slam/funny_lidar_slam
/home/test/navigation/funny_lidar_slam_ws/devel/lib/libfunny_lidar_slam_lib.so:对‘vtable for pcl::registration::TransformationEstimationSVD<pcl::PointXYZI, pcl::PointXYZI, float>’未定义的引用
/home/test/navigation/funny_lidar_slam_ws/devel/lib/libfunny_lidar_slam_lib.so:对‘pcl::IterativeClosestPoint<pcl::PointXYZI, pcl::PointXYZI, float>::determineRequiredBlobData()’未定义的引用
/home/test/navigation/funny_lidar_slam_ws/devel/lib/libfunny_lidar_slam_lib.so:对‘tbb::interface7::internal::isolate_within_arena(tbb::interface7::internal::delegate_base&, long)’未定义的引用
/home/test/navigation/funny_lidar_slam_ws/devel/lib/libfunny_lidar_slam_lib.so:对‘vtable for pcl::IterativeClosestPoint<pcl::PointXYZI, pcl::PointXYZI, float>’未定义的引用
/home/test/navigation/funny_lidar_slam_ws/devel/lib/libfunny_lidar_slam_lib.so:对‘typeinfo for pcl::IterativeClosestPoint<pcl::PointXYZI, pcl::PointXYZI, float>’未定义的引用
/home/test/navigation/funny_lidar_slam_ws/devel/lib/libfunny_lidar_slam_lib.so:对‘pcl::IterativeClosestPoint<pcl::PointXYZI, pcl::PointXYZI, float>::transformCloud(pcl::PointCloud
我觉得这里倒不是代码BUG,更多的原因还是因为你的环境存在不匹配,尽量还是使用ros noetic和ubuntu20。如果环境实在没法满足,尝试使用docker。
作者,你的pcl版本是多少?我编译的时候报错: /home/test/navigation/funny_lidar_slam_ws/src/funny_lidar_slam/src/slam/preprocessing.cpp:475:23: error: ‘isFinite’ is not a member of ‘pcl’; did you mean ‘isValueFinite’? 475 | if (!pcl::isFinite(cloud_none[i])) { | ^
~~~ | isValueFinite funny_lidar_slam/CMakeFiles/funny_lidar_slam_lib.dir/build.make:369: recipe for target 'funny_lidar_slam/CMakeFiles/funny_lidar_slam_lib.dir/src/slam/preprocessing.cpp.o' failed make[2]: [funny_lidar_slam/CMakeFiles/funny_lidar_slam_lib.dir/src/slam/preprocessing.cpp.o] Error 1 make[2]: 正在等待未完成的任务.... CMakeFiles/Makefile2:2921: recipe for target 'funny_lidar_slam/CMakeFiles/funny_lidar_slam_lib.dir/all' failed make[1]: [funny_lidar_slam/CMakeFiles/funny_lidar_slam_lib.dir/all] Error 2 Makefile:145: recipe for target 'all' failed make: [all] Error 2 Invoking "make -j16 -l16" failed