Showing posts with label igraph. Show all posts
Showing posts with label igraph. Show all posts

Thursday, July 17, 2014

/usr/lib64/libxml2.a: could not read symbols: Bad value

For more information on how to install python 2.7 and python-igraph, do look at the blog entry


When I was install python-igraph, I encountered the error
# python2.7 setup.py install

/usr/bin/ld: /usr/lib64/libxml2.a(entities.o): 
relocation R_X86_64_32 against `a local symbol' 
can not be used when making a shared object; recompile with -fPIC 

/usr/lib64/libxml2.a: could not read symbols: Bad value

The solution for this can be found igraph-help http://lists.gnu.org/archive/html/igraph-help/2014-05/msg00045.html

If summary, rename the libxml2.a to libxml2.a.org to ensure that the setup script of the Python interface does not find it when needed -- the installer will then fall back to /usr/lib64/libxml2.so (i.e. the dynamic version of the libxml2 library)
# mv /usr/lib64/libxml2.a /usr/lib64/libxml2.a.org

When I was install python-igraph, I encountered the error

# python2.7 setup.py install

/usr/bin/ld: /usr/lib64/libm.a(entities.o): 
relocation R_X86_64_32 against `a local symbol' 
can not be used when making a shared object; recompile with -fPIC 

# mv /usr/lib64/libm.a /usr/lib64/libm.a.org

Compiling igraph-0.7.1 on CentOS 5

Setting up the igraph-0.7.1 in C is quite easy Step 1: yum install gcc44 and above
# yum install gcc44 gcc44-c++ gcc44-gfortran
Step 2: Install libxml2 libraries
# yum install libxml2
Step 3: Download the igraph-0.7.1 from the igraph C site
# ./configure --prefix=/usr/local/igraph-0.7.1
# make -j 8
# make install