1

I'm using the kinect to get 3D models of soil erosion and to scan vegetation and I'm trying to compile this application for the kinect: http://www.ccs.neu.edu/research/gpc/imucam/index.html ,however when I run make I get the following error:

    linking record_frames from record_frames.o fps.o frame.o grabber.o interactor.o os.o pick_player.o player.o reader.o recorder.o source.o um6.o viewer.o writer.o
/usr/bin/ld: cannot find -lboost_serialization-mt
/usr/bin/ld: cannot find -lboost_system-mt
/usr/bin/ld: cannot find -lboost_filesystem-mt
/usr/bin/ld: cannot find -lboost_thread-mt
/usr/bin/ld: cannot find -lboost_date_time-mt
/usr/bin/ld: cannot find -lboost_iostreams-mt
/usr/bin/ld: cannot find -lboost_regex-mt
/usr/bin/ld: cannot find -lboost_mpi-mt
collect2: error: ld returned 1 exit status
make: *** [record_frames.bin] Error 1

I read the makefile and found:

DEF_BOOST_LIBS := -lboost_serialization-mt -lboost_system-mt \
          -lboost_filesystem-mt -lboost_thread-mt \
          -lboost_date_time-mt -lboost_iostreams-mt \
          -lboost_regex-mt -lboost_mpi-mt

So, my question is how can I call my libbost.so libraries in the makefile. I have libboost 1.55. I tried to change mt for .so but I get the same error:

/usr/bin/ld: cannot find -libboost_serialization.so

Any help to solve this wolud be great Thanks, in advance José Soto

andrew.46
  • 37,085
  • 25
  • 149
  • 228

1 Answers1

2

The libboost libraries changed their names, removing the "-mt" You can probably edit the makefile to remove the -mt s in the names, or try a suggestion from http://forum.freecadweb.org/viewtopic.php?t=4541 to rebuild the makefile.


The kinect requires a 64 bit and your boot libraries are in the 32 bit directory. Are you on a 64 bit machine and if you are, can you install the 64 bit boost packages?


In a terminal, run

 uname -a 

to see if your OS is 32 bit or 64 bit (X86_64 indicates 64 bit). You might have installed a 32 bit version of the OS.


Check the individual packages for being the 64 bit version with:

dpkg -l |fgrep boost  

e.g. the ":amd64" on the package name.

ii libboost-filesystem-dev:amd64 1.54.0.1ubuntu1 ...
If you get an ":i386" instead of the "amd64", it's a 32 bit version. Not sure how that could have happened unless you installed them explicitly (including the ":i386" on the package name at installation. You can simply install the needed 64 bit boost packages with:

sudo apt-get install  libboost-filesystem-dev  

or simply force the 64 bit package by using libboost-filesystem-dev:amd64 . You don't even have to worry about uninstalling the i386 versions, they are different directories, but if you do remove them, use the ":i386" on the package name to select them over the 64 bit version.

On my 14.04 system, I downloaded the latest kinect package (containing imucam-R186M_2014-05-29), added a boost library I was missing, edited the makefile to remove the "-mt"s, and everything successfully compiled with one openni warning.

ubfan1
  • 17,041
  • 4
  • 39
  • 47
  • Hi ubfan1, thanks for your reply. I've tried to do that but is the same error. It claims for /usr/bin location but my libboost.so libraries are in /usr/lib/i386-linux-gnu. The sorce only has a makefile and I've never before write a makefile, so I really don't know how can I call the installed libraries. – José Trinidad Soto Mar 08 '16 at 00:11
  • I'm into a 64 machine, Ubuntu 15.10, and I installed boost libraries from synaptic package libboost-all-dev, how can I uninstall libbost libraries and then install 64 bit boost package?? I'm sorry, but I'm a begginer into linux environment. Thank you – José Trinidad Soto Mar 08 '16 at 18:57
  • Amm, no, is 64 bit, uname -a displays x86_64 – José Trinidad Soto Mar 08 '16 at 20:46