cmake and boost library installation problem

hi all,

I am new to linux and C++ programming so I'm posting in hope of some help.

I am trying to install a C++ library using boost and cmake but I keep gettin this error in the terminal:

CMake Error at /usr/share/cmake/Modules/FindBoost.cmake:1199 (message):
Unable to find the requested Boost libraries.

Unable to find the Boost header files. Please set BOOST_ROOT to the root
directory containing Boost or BOOST_INCLUDEDIR to the directory containing
Boost's headers.
Call Stack (most recent call first):
CMakeLists.txt:184 (find_package)

---- your help is appreciated.
-peter

Chances are you just need to install boost ( library AND dev package ). How to do that depends on your distribution. Don't try compiling it by hand -- boost is huge enough it would take a very long time, and your distro almost certainly has precompiled versions anyway.

What distribution of linux do you have?

hi friend, thanks for the reply.

I am using Fedora 16.I am following the installation at:
Compilation ā€” liblas.org#using-unix-makefiles-on-linux

(I left out the http in the above address , since I cant post websites as I'm new to this forum).

I am downloaded Boost_1_49_0. I extracted the .tar file.
I tried using : ./configure to install but I get the follwoing from terminal :

bash: ./configure: No such file or directory

---- your advice is appreciated
-Peter

Like I said, I suggest not building boost from scratch. There's almost certainly a pre-compiled version for your distribution. There's good odds you even have boost already, just not its headers. By downloading the tar, and trying to ./configure, you're trying to build boost from scratch.

In fact, what library are you trying to build? There might be a package for that too.

Building it yourself is a last resort, not a first one.

yum install boost-devel

thanks... yum install boost-devel worked.

I am now running into more problems. The library called "Liblas", which I am trying to install can be found at :

Compilation ā€” liblas.org#using-unix-makefiles-on-linux

(I left out the http in the above address , since I cant post websites as I'm new to this forum).

I am following the steps on this web site. So after running :
$ yum install boost-devel

I ran on terminal :
$ cmake -G "Unix Makefiles"

This work fined. next I ran on :
$ make

Then I went on to :
$ make install

At $ make install , it builds 100% but I am getting an error as follows:

-- Install configuration: "Release"
CMake Error at cmake_install.cmake:36 (FILE):
file cannot create directory: /usr/local/share/liblas/doc. Maybe need
administrative privileges.

make: *** [install] Error 1

--- can you suggest what I should do?
peter

---------- Post updated at 08:26 PM ---------- Previous update was at 08:17 PM ----------

I think I figure out what to do as follows:
$ sudo make install

Now I am trying to read a file called "lasinfo" as:
$ lasinfo ../test/data/TO_core_last_clip.las

But I am getting the following error:

lasinfo: error while loading shared libraries: liblas.so.2.2.0: cannot open shared object file: No such file or directory

---- again, your help is appreciated

You probably installed it under /usr/local/lib. Which isn't a bad thing in of itself -- makes it easy to tell apart from the things which your system was able to install automatically. But the dynamic loader doesn't look in there by default... If so, you'll need to

LD_LIBRARY_PATH="/usr/local/lib" lasinfo

or somesuch.

When I run:

$ LD_LIBRARY_PATH="/usr/local/lib" lasinfo

the ouput is some information about the software library itself:

--------------------------------------------------------------------
    lasinfo (libLAS 1.7.0)
--------------------------------------------------------------------

lasinfo options:
  -h [ --help ]         produce help message
  -i [ --input ] arg    input LAS file
  -v [ --verbose ]      Verbose message output

I am trying to open the file "TO_core_last_clip.las" using:

$  LD_LIBRARY_PATH="/usr/local/lib" lasinfo -i[TO_core_last_clip.las]

But I am getting the message:

Cannot open [TO_core_last_clip.las] for read.  Exiting...

--- can you suggest anything?
thanks

---------- Post updated 03-15-12 at 02:33 AM ---------- Previous update was 03-14-12 at 10:02 PM ----------

just to update.... I managed to read the file in terminal:

$ LD_LIBRARY_PATH="/usr/local/lib" lasinfo /home/peter/libLAS-1.7.0/test/data/TO_core_last_clip.las

thanks again,
peter

hi .. i face this problem ..\
after untar.... you change to Boost_1_49_0 .. like this # cd Boost_1_49_0
then Exxcute ls cmd ...
it showing file .... after that you do
#./bootstrap.sh
this installation taking few mins... once it done you do
#./bjam

that all it works.
l

---------- Post updated at 03:03 AM ---------- Previous update was at 02:56 AM ----------

after untar
# cd Boost_1_49_0
Exxcute #ls
it showing some confi file
then you do
#./bootstrap.sh (this action taking long ) after it you do execute
#./bjam

that all it works.....

Hello,

Please do not ask new questions in existing threads. Unless you have new information to a particular problem, please create a new thread in the appropriate forum.

Also, please search the forums first, as it might be that someone has already posted an answer for a similar problem.

Best regards,
The UNIX and Linux Forums