Undefined reference pcl::search::KdTree (ROS Indigo)

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Undefined reference pcl::search::KdTree (ROS Indigo)

zzzzzzzzzz
My catkin_make entry succeeds, and definitely finds the relevant library /usr/local/lib/libpcl_kdtree.so

I was trying to use the PCL from the source Git repo.  Maybe this is causing some sort of conflict with ROS?

find_package(PCL 1.8 REQUIRED search)

When trying to use PCL as part of a ROS Indigo catkin workspace I receive the below error:
CMakeFiles/spatial_label_node.dir/src/spatial_labeler.cpp.o: In function `CloudProcessor::processCloud(std::string, std::string)':spatial_labeler.cpp:(.text._ZN14CloudProcessor12processCloudESsSs[_ZN14CloudProcessor12processCloudESsSs]+0x607): undefined reference to `pcl::search::KdTree<pcl::PointXYZ, pcl::KdTreeFLANN<pcl::PointXYZ, flann::L2_Simple<float> > >::KdTree(bool)'

CMakeFiles/spatial_label_node.dir/src/spatial_labeler.cpp.o: In function `pcl::Feature<pcl::PointXYZ, pcl::Normal>::initCompute()':spatial_labeler.cpp:.text._ZN3pcl7FeatureINS_8PointXYZENS_6NormalEE11initComputeEv[_ZN3pcl7FeatureINS_8PointXYZENS_6NormalEE11initComputeEv]+0x1b8): undefined reference to `pcl::search::KdTree<pcl::PointXYZ, pcl::KdTreeFLANN<pcl::PointXYZ, flann::L2_Simple<float> > >::KdTree(bool)'
collect2: error: ld returned 1 exit status