Undefined Symbols for Architecture x86_64

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

Undefined Symbols for Architecture x86_64

AcrimoniousMirth
This post has NOT been accepted by the mailing list yet.
So I've spent the entire day trying to get PCL (1.6.0 then 1.8.1) to work with xCode 8.0 on MacOS Sierra. I've downloaded it in several different ways (CMake, from source, Homebrew, Macports etc) and let me tell you, the information out there seems to be sparse and very different depending who you ask. I was hoping for a series of YouTube videos targeting the different platforms and installations, I mean, even OpenCV has that, if they are somewhat outdated.
It doesn't help that I'm new to the world of coding and dove right in the deep end.
Anyway, the recurring issue I'm getting is an "undefined symbols for architecture x86_64" whenever I try to compile. See end of message for readout.
The vast interwebs seemed to suggest the issue arose from a 32bit-64bit mismatch.

I also had some advice when initially setting up that I should add a "new group" to the xCode project, named plc and add files from /build/lib/libpcl_io.1.7.0.dylib and /build/lib/libpcl_common.1.7.0.dylib where 1.7.0 was the user's version. Those files appear to be in 1.6.0 but having scanned my entire computer for them for 1.8.1 I haven't found anything.

Anyway, thanks for any advice on how on earth I'm meant to get PCL working.

Undefined symbols for architecture x86_64:
  "pcl::console::print(pcl::console::VERBOSITY_LEVEL, char const*, ...)", referenced from:
      int pcl::PCDWriter::writeBinary<pcl::PointXYZ>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, pcl::PointCloud<pcl::PointXYZ> const&) in main.o
      int pcl::PCDWriter::writeASCII<pcl::PointXYZ>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, pcl::PointCloud<pcl::PointXYZ> const&, int) in main.o
  "pcl::PCDWriter::writeASCII(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, pcl::PCLPointCloud2 const&, Eigen::Matrix<float, 4, 1, 0, 4, 1> const&, Eigen::Quaternion<float, 0> const&, int)", referenced from:
      pcl::PCDWriter::write(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, pcl::PCLPointCloud2 const&, Eigen::Matrix<float, 4, 1, 0, 4, 1> const&, Eigen::Quaternion<float, 0> const&, bool) in main.o
  "pcl::PCDWriter::writeBinary(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, pcl::PCLPointCloud2 const&, Eigen::Matrix<float, 4, 1, 0, 4, 1> const&, Eigen::Quaternion<float, 0> const&)", referenced from:
      pcl::PCDWriter::write(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, pcl::PCLPointCloud2 const&, Eigen::Matrix<float, 4, 1, 0, 4, 1> const&, Eigen::Quaternion<float, 0> const&, bool) in main.o
  "pcl::PCDWriter::setLockingPermissions(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, boost::interprocess::file_lock&)", referenced from:
      int pcl::PCDWriter::writeBinary<pcl::PointXYZ>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, pcl::PointCloud<pcl::PointXYZ> const&) in main.o
      int pcl::PCDWriter::writeASCII<pcl::PointXYZ>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, pcl::PointCloud<pcl::PointXYZ> const&, int) in main.o
  "pcl::PCDWriter::resetLockingPermissions(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, boost::interprocess::file_lock&)", referenced from:
      int pcl::PCDWriter::writeBinary<pcl::PointXYZ>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, pcl::PointCloud<pcl::PointXYZ> const&) in main.o
      int pcl::PCDWriter::writeASCII<pcl::PointXYZ>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, pcl::PointCloud<pcl::PointXYZ> const&, int) in main.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)