Unable to build surround360_render - CMake issue - c++

Background
I am running this on Kubuntu 16.04.04 LTS, a fresh install.
I'm trying to build surround360_render based on the code and instructions at: https://github.com/facebook/Surround360/tree/master/surround360_render
I followed the instructions except for the ones for the python, numpy, pip. gooey, pil installs (I don't need python).
Installed ceres based on the instructions here, not the ones on the ceres git page.
installed llvm, Halide to use accelerated ISP
and I get the following error while make'ing ...360_render:
[ 92%] Linking CXX executable bin/Unpacker
//usr/local/lib/libfolly.a(Conv.cpp.o): In function `folly::Expected<float, folly::ConversionCode> folly::detail::str_to_floating<float>(folly::Range<char const*>*)':
/home/rinka/bin/fb-lib/folly/folly/folly/Conv.cpp:354: undefined reference to `double_conversion::StringToDoubleConverter::StringToDouble(char const*, int, int*) const'
//usr/local/lib/libfolly.a(Conv.cpp.o): In function `folly::Expected<double, folly::ConversionCode> folly::detail::str_to_floating<double>(folly::Range<char const*>*)':
/home/rinka/bin/fb-lib/folly/folly/folly/Conv.cpp:354: undefined reference to `double_conversion::StringToDoubleConverter::StringToDouble(char const*, int, int*) const'
//usr/local/lib/libfolly.a(dynamic.cpp.o): In function `double_conversion::DoubleToStringConverter::ToShortest(double, double_conversion::StringBuilder*) const':
/usr/local/include/double-conversion/double-conversion.h:158: undefined reference to `double_conversion::DoubleToStringConverter::ToShortestIeeeNumber(double, double_conversion::StringBuilder*, double_conversion::DoubleToStringConverter::DtoaMode) const'
//usr/local/lib/libfolly.a(dynamic.cpp.o): In function `std::enable_if<std::is_floating_point<double>::value&&folly::IsSomeString<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >::value, void>::type folly::toAppend<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, double>(double, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*, double_conversion::DoubleToStringConverter::DtoaMode, unsigned int)':
/home/rinka/bin/fb-lib/folly/folly/folly/Conv.h:704: undefined reference to `double_conversion::DoubleToStringConverter::ToFixed(double, int, double_conversion::StringBuilder*) const'
/home/rinka/bin/fb-lib/folly/folly/folly/Conv.h:708: undefined reference to `double_conversion::DoubleToStringConverter::ToPrecision(double, int, double_conversion::StringBuilder*) const'
//usr/local/lib/libfolly.a(Format.cpp.o): In function `folly::FormatValue<double, void>::formatHelper(folly::basic_fbstring<char, std::char_traits<char>, std::allocator<char>, folly::fbstring_core<char> >&, int&, folly::FormatArg&) const':
/home/rinka/bin/fb-lib/folly/folly/folly/Format.cpp:162: undefined reference to `double_conversion::DoubleToStringConverter::ToFixed(double, int, double_conversion::StringBuilder*) const'
/home/rinka/bin/fb-lib/folly/folly/folly/Format.cpp:181: undefined reference to `double_conversion::DoubleToStringConverter::ToExponential(double, int, double_conversion::StringBuilder*) const'
collect2: error: ld returned 1 exit status
CMakeFiles/TestRenderStereoPanorama.dir/build.make:112: recipe for target 'bin/TestRenderStereoPanorama' failed
make[2]: *** [bin/TestRenderStereoPanorama] Error 1
CMakeFiles/Makefile2:556: recipe for target 'CMakeFiles/TestRenderStereoPanorama.dir/all' failed
make[1]: *** [CMakeFiles/TestRenderStereoPanorama.dir/all] Error 2
[ 96%] Built target Unpacker
[ 96%] Built target GeometricCalibration
Makefile:83: recipe for target 'all' failed
What I've tried so far
I tried implementing https://github.com/facebook/Surround360/issues/253 Failed. I get the following message:
[ 98%] Generating folly_dep.cpp
Scanning dependencies of target folly
[ 98%] Building CXX object CMakeFiles/folly.dir/folly_dep.cpp.o
[ 99%] Linking CXX shared library libfolly.so
/usr/bin/ld: CMakeFiles/folly_base.dir/folly/ClockGettimeWrappers.cpp.o: relocation R_X86_64_32 against `.rodata' can not be used when making a shared object; recompile with -fPIC
CMakeFiles/folly_base.dir/folly/ClockGettimeWrappers.cpp.o: error adding symbols: Bad value
collect2: error: ld returned 1 exit status
CMakeFiles/folly.dir/build.make:514: recipe for target 'libfolly.so' failed
make[2]: *** [libfolly.so] Error 1
CMakeFiles/Makefile2:180: recipe for target 'CMakeFiles/folly.dir/all' failed
make[1]: *** [CMakeFiles/folly.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
assuming it is a problem with the standard double-conversion-dev library installed by apt, I uninstalled that, recompiled double-conversion using the following instructions:
git clone https://github.com/google/double-conversion.git
cd double-conversion
cmake -DBUILD_SHARED_LIBS=ON .
make -j $(nproc)
sudo make install
and rebuilt folly as follows:
$ cmake configure ..
$ make -j $(nproc)
didn't work. redid cmake & make
$ cmake configure "-DCMAKE_INCLUDE_PATH=$HOME/bin/fb-lib/double-conversion/build/include" "-DCMAKE_LIBRARY_PATH=$HOME/bin/fb-lib/double-conversion/build//lib" ..
$ make -j $(nproc)
I get the following error:
CMake Error at CMakeLists.txt:201 (find_package):
Could not find a package configuration file provided by "double-conversion"
with any of the following names:
double-conversionConfig.cmake
double-conversion-config.cmake
Add the installation prefix of "double-conversion" to CMAKE_PREFIX_PATH or
set "double-conversion_DIR" to a directory containing one of the above
files. If "double-conversion" provides a separate development package or
SDK, be sure it has been installed.

The issues were because "double-conversion" was not included as a library to be linked in the various modules of surround360_render. To solve the problem, modify CMakeLists.txt under the directory surround360_render as follows:
Add:
double-conversion
to the sections TARGET_LINK_LIBRARIES of the various modules that fail. In my case the failed modules were: TestRenderStereoPanorama, TestHyperPreview, TestPoleRemoval, TestColorCalibration, TestVignettingCalibration, TestVignettingDataAcquisition and GeometricCalibration
The reason I list these, there are more modules than these which is why one doesn't need to add double-conversion as a default library to be linked.
Putting this here in case someone else runs into similar issues.

Related

Linking yaml-cpp with conan

I'm using yaml-cpp from conan center, in my conan file, yaml-cpp/0.6.3, along with other dependencies.
The rest of the libraries link properly, so there must be something missing in my CMakeLists.txt file. (Maybe some extra definition...?)
Until now, with those lines:
include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake)
conan_basic_setup()
set(CMAKE_CXX_STANDARD 20)
It worked fine (For other libraries, like bullet, glm...)
At link time, problems with missing implementation arise:
cmake --build build --config Debug --target all -- -j 10
/usr/bin/ld: CMakeFiles/my-project.dir/src/MySourceFile.cpp.o: in function `YAML::Node::Scalar[abi:cxx11]() const':
/home/my-user/.conan/data/yaml-cpp/0.6.3/_/_/package/82ef5eac51c38971dea2fd342dd55ddf2ddfbbc3/include/yaml-cpp/node/impl.h:169: undefined reference to `YAML::detail::node_data::empty_scalar[abi:cxx11]()'
/usr/bin/ld: CMakeFiles/my-project.dir/src/MySource.cpp.o: in function `tojson::loadyaml(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)':
/home/my-user/my-project/lib/nlohmann/tojson.hpp:162: undefined reference to `YAML::LoadFile(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
collect2: error: ld returned 1 exit status
Seems that the problem is that YAML::LoadFile appears to be undefined.
(I've tried using it without tojson also)
YAML::Node test = YAML::LoadFile("test.yaml");
The package is okay, but your profile is misconfigured.
undefined reference to `YAML::LoadFile(std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&)'
collect2: error: ld returned 1 exit status
You have to update your libcxx setting:
conan profile update settings.compiler.libcxx=libstdc++11 default
More info about: https://docs.conan.io/en/latest/howtos/manage_gcc_abi.html

bitcoin compile (.undefined reference to `BlockAssembler::BlockAssembler(CChainParams const&)')

I'm getting error after make command like,
undefined reference to `BlockAssembler::BlockAssembler(CChainParams const&)'
and in last
Makefile:774: recipe for target 'all-recursive' failed
make: **[all-recursive] Error 1
I have followed all steps given here:-
https://www.toshblocks.com/bitcoin/compile-bitcoin-source-code-ubuntu-16-04-lts/
Output :-
Making all in src
make[1]: Entering directory '/home/khushbu/bitcoin/src'
make[2]: Entering directory '/home/khushbu/bitcoin/src'
make[3]: Entering directory '/home/khushbu/bitcoin'
make[3]: Leaving directory '/home/khushbu/bitcoin'
CXXLD bitcoind
libbitcoin_server.a(libbitcoin_server_a-mining.o): In function `generateBlocks(std::shared_ptr<CReserveScript>, int, unsigned long, bool)':
/home/khushbu/bitcoin/src/rpc/mining.cpp:122: undefined reference to `BlockAssembler::BlockAssembler(CChainParams const&)'
/home/khushbu/bitcoin/src/rpc/mining.cpp:122: undefined reference to `BlockAssembler::CreateNewBlock(CScript const&, bool)'
/home/khushbu/bitcoin/src/rpc/mining.cpp:128: undefined reference to `IncrementExtraNonce(CBlock*, CBlockIndex const*, unsigned int&)'
libbitcoin_server.a(libbitcoin_server_a-mining.o): In function `getmininginfo(JSONRPCRequest const&)':
/home/khushbu/bitcoin/src/rpc/mining.cpp:216: undefined reference to `nLastBlockWeight'
/home/khushbu/bitcoin/src/rpc/mining.cpp:217: undefined reference to `nLastBlockTx'
libbitcoin_server.a(libbitcoin_server_a-mining.o): In function `getblocktemplate(JSONRPCRequest const&)':
/home/khushbu/bitcoin/src/rpc/mining.cpp:521: undefined reference to `BlockAssembler::BlockAssembler(CChainParams const&)'
/home/khushbu/bitcoin/src/rpc/mining.cpp:521: undefined reference to `BlockAssembler::CreateNewBlock(CScript const&, bool)'
/home/khushbu/bitcoin/src/rpc/mining.cpp:533: undefined reference to `UpdateTime(CBlockHeader*, Consensus::Params const&, CBlockIndex const*)'
collect2: error: ld returned 1 exit status
Makefile:3888: recipe for target 'bitcoind' failed
make[2]: *** [bitcoind] Error 1
make[2]: Leaving directory '/home/khushbu/bitcoin/src'
Makefile:10190: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/khushbu/bitcoin/src'
Makefile:774: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1
How to solve this error and compile bitcoin source code successfully?
This tutorial helped me to solve the issue.
https://www.youtube.com/watch?v=l0A91Yx9juQ
By, Following Unix build notes,
https://github.com/bitcoin/bitcoin/blob/master/doc/build-UNIX.md
and downloading needed dependencies can solve the problem.
I think problem occurred due to bad installation of Berkeley DB,
and so i have remove all old files and then again followed steps from build-UNIX.md.
and download dependencies which are,
sudo apt-get install build-essential libtool autotools-dev automake pkg-config bsdmainutils python3
sudo apt-get install libssl-dev libevent-dev libboost-system-dev libboost-filesystem-dev libboost-chrono-dev libboost-test-dev libboost-thread-dev
sudo apt-get install software-properties-common
sudo add-apt-repository ppa:bitcoin/bitcoin
sudo apt-get update
sudo apt-get install libdb4.8-dev libdb4.8++-dev
This worked for me. Thank you!

Why does deleting these two lines lead to ld error "undefined reference"?

I have a project using opencv and cmake which builds 100% fine.
Then, I go to a C++ source file, which contains these lines, among other nonremarkable lines:
cv::imshow("Test", display);
cv::waitKey(0);
And I delete ONLY these two lines. Try building again, and I get:
$ make
(...)
[ 77%] Linking CXX executable project_test
libproject.so: undefined reference to `cv::resize(cv::_InputArray const&, cv::_OutputArray const&, cv::Size_<int>, double, double, int)'
libproject.so: undefined reference to `cv::imread(cv::String const&, int)'
libproject.so: undefined reference to `cv::cvtColor(cv::_InputArray const&, cv::_OutputArray const&, int, int)'
collect2: error: ld returned 1 exit status
CMakeFiles/project_test.dir/build.make:226: recipe for target 'project_test' failed
make[2]: *** [project_test] Error 1
CMakeFiles/Makefile2:105: recipe for target 'CMakeFiles/project_test.dir/all' failed
make[1]: *** [CMakeFiles/project_test.dir/all] Error 2
Makefile:94: recipe for target 'all' failed
make: *** [all] Error 2
Do you know of anything that would cause linking to fail on a small code deletion like that?
I tried building the original code from scratch and it worked, and I tried building the code with the two line deletion from scratch and it failed in the above way again.
EDIT:
Originally, the project's main CMakeLists.txt file contained this:
target_link_libraries(project opencv_core opencv_highgui)
Now I edited it to this:
target_link_libraries(project opencv_core opencv_imgproc opencv_highgui opencv_imgcodecs)
And the project builds again. But why did it build in the first place without those libraries explicitly being linked? And why do those two lines work around that?

OpenCV undefined reference to

I'm using Ubuntu 16.04 and OpenCV 2.4.9 and my quite simple example programs are constantly failing to build. I'm building on CLion.
As I'm kinda new to OpenCV I have some issues to narrow down the problem. I tried two different programs.
Number 1 is this one:
#include <iostream>
#include <opencv2/core/core.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc.hpp>
int main(int argc, char **argv) {
IplImage *img = cvLoadImage(argv[1]);
cvNamedWindow("Example1", CV_WINDOW_AUTOSIZE );
cvShowImage("Example1", img);
cvWaitKey(0);
cvReleaseImage(&img);
cvDestroyWindow("Example1" );
}
Which fails with:
Scanning dependencies of target untitled
[ 50%] Building CXX object CMakeFiles/untitled.dir/main.cpp.o
[100%] Linking CXX executable untitled
CMakeFiles/untitled.dir/main.cpp.o: In function `main':
/home/computervision/CLionProjects/untitled/main.cpp:7: undefined reference to `cvLoadImage'
/home/computervision/CLionProjects/untitled/main.cpp:8: undefined reference to `cvNamedWindow'
/home/computervision/CLionProjects/untitled/main.cpp:9: undefined reference to `cvShowImage'
/home/computervision/CLionProjects/untitled/main.cpp:10: undefined reference to `cvWaitKey'
/home/computervision/CLionProjects/untitled/main.cpp:11: undefined reference to `cvReleaseImage'
/home/computervision/CLionProjects/untitled/main.cpp:12: undefined reference to `cvDestroyWindow'
collect2: error: ld returned 1 exit status
CMakeFiles/untitled.dir/build.make:94: recipe for target 'untitled' failed
make[3]: *** [untitled] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/untitled.dir/all' failed
make[2]: *** [CMakeFiles/untitled.dir/all] Error 2
CMakeFiles/Makefile2:79: recipe for target 'CMakeFiles/untitled.dir/rule' failed
make[1]: *** [CMakeFiles/untitled.dir/rule] Error 2
Makefile:118: recipe for target 'untitled' failed
make: *** [untitled] Error 2
My 2nd one is this:
#include <iostream>
#include <opencv2/core/core.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc.hpp>
int main( int argc, char** argv ) {
cv::Mat image;
image = cv::imread("sample.jpeg" , CV_LOAD_IMAGE_COLOR);
if(! image.data ) {
std::cout << "Could not open or find the image" << std::endl ;
return -1;
}
cv::namedWindow( "Display window", cv::WINDOW_AUTOSIZE );
cv::imshow( "Display window", image );
cv::waitKey(0);
return 0;
}
Which fails with:
Scanning dependencies of target untitled
[ 50%] Building CXX object CMakeFiles/untitled.dir/main.cpp.o
[100%] Linking CXX executable untitled
CMakeFiles/untitled.dir/main.cpp.o: In function `main':
/home/computervision/CLionProjects/untitled/main.cpp:9: undefined reference to `cv::imread(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/home/computervision/CLionProjects/untitled/main.cpp:16: undefined reference to `cv::namedWindow(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/home/computervision/CLionProjects/untitled/main.cpp:17: undefined reference to `cv::_InputArray::_InputArray(cv::Mat const&)'
/home/computervision/CLionProjects/untitled/main.cpp:17: undefined reference to `cv::imshow(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, cv::_InputArray const&)'
/home/computervision/CLionProjects/untitled/main.cpp:19: undefined reference to `cv::waitKey(int)'
CMakeFiles/untitled.dir/main.cpp.o: In function `cv::Mat::~Mat()':
/usr/local/include/opencv2/core/mat.hpp:278: undefined reference to `cv::fastFree(void*)'
CMakeFiles/untitled.dir/main.cpp.o: In function `cv::Mat::operator=(cv::Mat const&)':
/usr/local/include/opencv2/core/mat.hpp:298: undefined reference to `cv::Mat::copySize(cv::Mat const&)'
CMakeFiles/untitled.dir/main.cpp.o: In function `cv::Mat::release()':
/usr/local/include/opencv2/core/mat.hpp:367: undefined reference to `cv::Mat::deallocate()'
collect2: error: ld returned 1 exit status
CMakeFiles/untitled.dir/build.make:94: recipe for target 'untitled' failed
make[3]: *** [untitled] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/untitled.dir/all' failed
make[2]: *** [CMakeFiles/untitled.dir/all] Error 2
CMakeFiles/Makefile2:79: recipe for target 'CMakeFiles/untitled.dir/rule' failed
make[1]: *** [CMakeFiles/untitled.dir/rule] Error 2
Makefile:118: recipe for target 'untitled' failed
make: *** [untitled] Error 2
My CMakeLists.txt:
cmake_minimum_required(VERSION 3.9)
project(untitled)
set(CMAKE_CXX_STANDARD 11)
add_executable(untitled main.cpp)
I wonder what I could have done so wrong.
Most searches lead to wrong settings of the g++ command, but I assume CLion knows what it's doing (also I tried with the command too, same errors).
For instance this here: openCV error : undefined reference to `cvLoadImage' Ubuntu
I assume highgui is not linked properly. Which might be the case, my output of:
computervision#computervision-VirtualBox:~/ex$ pkg-config opencv --libs
/usr/local/lib/libopencv_core.so /usr/local/lib/libopencv_flann.so /usr/local/lib/libopencv_ml.so
looks kinda poor, I assume I made a mistake during installation (just which?).
Another error might be the CMakeLists.txt. Here it was recommended to change it. But the line
LIBRARIES += glog gflags protobuf leveldb snappy
causes an error.
Executing
export CMAKE_CXX_FLAGS=`pkg-config opencv --cflags --libs`
before starting CLion doesn't make any difference either.
EDIT:
Using cmake:
computervision#computervision-VirtualBox:~/CLionProjects/untitled$ cmake .
-- The C compiler identification is GNU 5.4.0
-- The CXX compiler identification is GNU 5.4.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
OpenCV_LIBS: opencv_mlopencv_flannopencv_core
-- Configuring done
-- Generating done
-- Build files have been written to: /home/computervision/CLionProjects/untitled
computervision#computervision-VirtualBox:~/CLionProjects/untitled$ g++ -o untitled main.cpp `pkg-config opencv --cflags --libs`
/tmp/ccdAr2hr.o: In function `main':
main.cpp:(.text+0x78): undefined reference to `cv::imread(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
main.cpp:(.text+0x128): undefined reference to `cv::namedWindow(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
main.cpp:(.text+0x1a2): undefined reference to `cv::imshow(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, cv::_InputArray const&)'
main.cpp:(.text+0x1ca): undefined reference to `cv::waitKey(int)'
collect2: error: ld returned 1 exit status
EDIT (2):
Using make after cmake:
computervision#computervision-VirtualBox:~/CLionProjects/untitled$ make
Scanning dependencies of target untitled
[ 50%] Building CXX object CMakeFiles/untitled.dir/main.cpp.o
[100%] Linking CXX executable untitled
CMakeFiles/untitled.dir/main.cpp.o: In function `main':
main.cpp:(.text+0x78): undefined reference to `cv::imread(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
main.cpp:(.text+0x128): undefined reference to `cv::namedWindow(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
main.cpp:(.text+0x1a2): undefined reference to `cv::imshow(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, cv::_InputArray const&)'
main.cpp:(.text+0x1ca): undefined reference to `cv::waitKey(int)'
collect2: error: ld returned 1 exit status
CMakeFiles/untitled.dir/build.make:97: recipe for target 'untitled' failed
make[2]: *** [untitled] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/untitled.dir/all' failed
make[1]: *** [CMakeFiles/untitled.dir/all] Error 2
Makefile:83: recipe for target 'all' failed
make: *** [all] Error 2
Linking OpenCV in CMakeLists.txt is missing.
cmake_minimum_required(VERSION 3.9)
project(untitled)
set(CMAKE_CXX_STANDARD 11)
find_package( OpenCV REQUIRED ) # locate OpenCV in system
include_directories( ${OpenCV_INCLUDE_DIRS} ) # provide library headers
add_executable(untitled main.cpp)
target_link_libraries( untitled ${OpenCV_LIBS} /usr/lib/x86_64-linux-gnu/libopencv_highgui.so) # link OpenCV libraries , hightgui.so not found by cmake so this hack
MESSAGE("OpenCV_LIBS: " ${OpenCV_LIBS} ) #display opencv libs found
if your compiler finds OpenCV and after executing cmake it should show OpenCV libraries found.

Linking to boost libraries when building pcl-1.7.1 from source

I have downloaded the pcl-1.7.1 release from github and have tried to build the code using
cd PCL-1.6.0 && mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release ..
make
sudo make install
The cmake command runs successful and and writes this concerning boost
-- Boost version: 1.55.0
-- Found the following Boost libraries:
-- system
-- filesystem
-- thread
-- date_time
-- iostreams
The problem comes with the make command which after some time returns the following error:
Scanning dependencies of target pcl_convert_pcd_ascii_binary
[ 12%] Building CXX object io/tools/CMakeFiles/pcl_convert_pcd_ascii_binary.dir/convert_pcd_ascii_binary.cpp.o
Linking CXX executable ../../bin/pcl_convert_pcd_ascii_binary
../../lib/libpcl_common.so.1.7.1: error: undefined reference to 'boost::thread::join_noexcept()'
../../lib/libpcl_common.so.1.7.1: error: undefined reference to 'boost::thread::start_thread_noexcept()'
../../lib/libpcl_io.so.1.7.1: error: undefined reference to 'boost::filesystem::detail::permissions(boost::filesystem::path const&, boost::filesystem::perms, boost::system::error_code*)'
../../lib/libpcl_io.so.1.7.1: error: undefined reference to 'boost::filesystem::detail::status(boost::filesystem::path const&, boost::system::error_code*)'
../../lib/libpcl_io.so.1.7.1: error: undefined reference to 'boost::filesystem::path::extension() const'
../../lib/libpcl_io.so.1.7.1: error: undefined reference to 'boost::filesystem::detail::dir_itr_close(void*&, void*&)'
../../lib/libpcl_io.so.1.7.1: error: undefined reference to 'boost::filesystem::path::stem() const'
../../lib/libpcl_io.so.1.7.1: error: undefined reference to 'boost::filesystem::detail::directory_iterator_construct(boost::filesystem::directory_iterator&, boost::filesystem::path const&, boost::system::error_code*)'
../../lib/libpcl_io.so.1.7.1: error: undefined reference to 'boost::filesystem::detail::directory_iterator_increment(boost::filesystem::directory_iterator&, boost::system::error_code*)'
../../lib/libpcl_io.so.1.7.1: error: undefined reference to 'boost::filesystem::directory_entry::m_get_status(boost::system::error_code*) const'
../../lib/libpcl_io.so.1.7.1: error: undefined reference to 'boost::thread::do_try_join_until_noexcept(timespec const&, bool&)'
collect2: ld returned 1 exit status
make[2]: *** [bin/pcl_convert_pcd_ascii_binary] Error 1
make[1]: *** [io/tools/CMakeFiles/pcl_convert_pcd_ascii_binary.dir/all] Error 2
make: *** [all] Error 2
Is it correct that this is a linking problem? can it be the boost installation that causes the problem?
I have built the boost library from source (version 1.55.0) by executing the following inside the boost_1_55_0 directory
sudo ./bootstrap
sudo ./b2 install
The boost is then installed in /usr/local/include and /usr/local/lib
I use 32 bit Ubuntu 12.04
I found some libboost files in /usr/lib which I forgot to delete from the last install of boost (as pointed out by #D.J.Duff). Removing those files and intstalling boost again fixed the problem.