Boost logo

Boost Users :

Subject: Re: [Boost-users] Boost build and first program
From: Vladimir Prus (vladimir_at_[hidden])
Date: 2014-12-01 10:04:28

On 12/01/2014 02:05 PM, Great Avenger Singh wrote:
> Hi I am first time boost user. I build it using following procedure on
> Ubuntu Linux 14.04.
> cd /boost-src/
> ./ and followed instructions. after the completion it gave
> me following suggestion:
> The Boost libraries were successfully built.
> Following directory should be included to compiler include paths;
> /home/metal-machine/boost-src
> Following directory should be included to linker library paths;
> /home/metal-machine/boost-src/stage/lib
> Now I try to compile and program with following options from command line:
> $ g++ -I "/home/metal-machine/boost-src/" -L
> "/home/metal-machine/boost-src/stage/lib/" boostlist.cpp
> -lboost_system -lboost_filesystem -o honey
> $ ./honey
> ./honey: error while loading shared libraries:
> cannot open shared object file: No such
> file or directory


You need to run it as


Default linking on Linux is shared, and to run executable that is linked
against shared library in non-system location, you need to specify that
non-system location at runtime.

Vladimir Prus
CodeSourcery / Mentor Embedded

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at