[graph-tool] Building graph-tool on CentOS 7

Smith, Steven - 1004 - MITLL stsmith at ll.mit.edu
Fri Jun 26 16:42:35 CEST 2015


I’m having trouble updating load libraries when to the latest version of boost:

$ export LD_LIBRARY_PATH="/usr/local/lib:/usr/local/boost/stage/lib”
$ ipython
In [1]: import graph_tool.all
…
ImportError: libboost_thread.so.1.57.0: cannot open shared object file: No such file or directory

Why is graph-tool still pointing at the old, nonexistent boost library?? I’m certain I’ve removed the old boost libraries, and sanity checked with the command

$ ( cd / ; sudo updatedb )
$ locate boost | fgrep 1.57
# Empty result

# Remove old graph-tool libraries by hand
$ sudo rm -fr /usr/lib/python2.7/site-packages/graph_tool  /usr/lib64/python2.7/site-packages/graph_tool

This really leaves me scratching my head because I’ve expunged boost version 1.57 from everywhere, downloaded/compiled/installed boost version 1.58 from scratch, and configured graph-tool to use all the boost 1.58 directories.

Here’s the setup:

# boost build and install
$ cd /usr/local/boost_1_58_0/
$ sudo ln -s /usr/local/boost_1_58_0 /usr/local/boost
$ ./bootstrap.sh 
$ ./b2
$ sudo ./b2 install

# graph-tool build and install
$ cd ~/Downloads/graph-tool-2.2.43/
$ export LD_LIBRARY_PATH="/usr/local/lib:/usr/local/boost/stage/lib”
$ ls -l /usr/local/boost
lrwxrwxr-x. 1 root root 24 Jun 25 12:20 /usr/local/boost -> /usr/local/boost_1_58_0/
$ ./configure --with-sparsehash-prefix=google --with-boost=/usr/local/boost --with-boost-libdir=/usr/local/boost/stage/lib CPPFLAGS="-I/usr/local/boost" LDFLAGS="-L/usr/local/boost/stage/lib"
$ make
$ sudo make install


> On Oct 6, 2014, at 2:18 PM, Steven Thomas Smith <stsmith at ll.mit.edu> wrote:
> 
> Thanks — that’s it. I had to set it to this to handle a local install of CGAL in /usr/local/lib/libCGAL.so.10.0.3:
> 
> export LD_LIBRARY_PATH="/usr/local/lib:/usr/local/boost/stage/lib/"
> 
> All is working now.
> 
> Steve
> 
> 
>> You should not tell graph-tool itself, but rather the linker
>> library. This is done via the LD_LIBRARY_PATH environment variable,
>> which must include the directories to be search. In your case, before
>> you start the python interpreter, you should do
>> 
>>    export LD_LIBRARY_PATH="/usr/local/boost_1_56_0/stage/lib/"






More information about the graph-tool mailing list