Message: error while loading shared libraries: libxerces-c-3.1.so Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question error while loading shared libraries: libxerces-c-3.1.so  

Forum: Installation and Configuration
Date: 29 Sep, 2011
From: Mark McCrea <Mark McCrea>

Good day.

I am using a Macbook with MacOS X 10.5.8 with VMWARE Fusion 3.1.2 running a Scientific Linux 5.5 virtual machine. I have gcc version 4.1.2 on the Scientific Linux. I am installing geant4 in the Scientific Linux Virtual machine.

I am using a attempting to get a GEANT4.9.2.p01 installation to work with GDML.

With Geant4 removed from the system for a clean install I downloaded the xerces-c-3.1.1 source from http://xerces.apache.org/xerces-c/download.cgi. With that I then built it using

./configure --prefix /programs/xerces-c-3.1.1

make

sudo make install

I set the environment variables

export PATH="$PATH:/programs/xerces-c-3.1.1/bin"

export LD_LIBRARY_PATH=/programs/xerces-c-3.1.1/lib:$LD_LIBRARY_PATH

export XERCERSCROOT=/programs/xerces-c-3.1.1

CLHEP was built in the /programs/CLHEP folder with

./configure --prefix /programs/CLHEP

make

make install

with those in places I unpacked the geant4.9.2.p01.tar.gz, and the data files for it. All of this went into the /programs/geant4.9.2.p01 folder. From that folder I ran the commands

./Configure -build

I pointed out the CLHEP folder when requested, told it to use OpenGL and Raytracer, and indicated yes to build GDML, it could not find Xerces-c in the default location so I told it to look in /programs/xerces-c-3.1.1 . This stage reported no errors.

I next ran ./Configure to get the env.sh file generated.

I set the environment variables

export G4WORKDIR=/home/Mark/g4work

export LD_LIBRARY_PATH=/programs/CLHEP/lib

source /programs/geant4.9.2.p01/env.sh

To test if it would work I copied the N01 and G01 to the g4work folder. Both of them will make without errors, but when I attempt to run the file as shown below it says libxerces-c-3.1.1.so cannot be found.

[Mark@localhost G01]$ make clean

Cleaning up ...

[Mark@localhost G01]$ make

Making dependency for file load_gdml.cc ...

Making dependency for file src/PrimaryGeneratorAction.cc ...

Making dependency for file src/PhysicsList.cc ...

Compiling PhysicsList.cc ...

Compiling PrimaryGeneratorAction.cc ...

Creating/replacing object files in /home/Mark/g4work/tmp/Linux-g++/load_gdml /libload_gdml.a ...

ar: creating /home/Mark/g4work/tmp/Linux-g++/load_gdml/libload_gdml.a

Compiling load_gdml.cc ...

load_gUsing granular libraries ...

Linking load_gdml ...

dml... Done!

[Mark@localhost G01]$ load_gdml axes.gdml

load_gdml: error while loading shared libraries: libxerces-c-3.1.so: cannot open shared object file: No such file or directory

If on the command line I type locate libxerces-c-3 it I get

[Mark@localhost ~]$ locate libxerces-c-3

/programs/xerces-c-3.1.1/lib/libxerces-c-3.1.so

/programs/xerces-c-3.1.1/src/.libs/libxerces-c-3.1.so

so the file is present. Following advice found online I copied the .so in question to /usr/lib and /usr/local/lib and still the file is not found when I try to run the N01 or G01 even if the the example are rebuilt.

Does anyone have any advice as to why this could be happening?

Mark McCrea

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

1 None: Re: error while loading shared libraries: libxerces-c-3.1.so   (Michael H. Kelsey - 29 Sep, 2011)
1 None: Re: error while loading shared libraries: libxerces-c-3.1.so   (Mark McCrea - 30 Sep, 2011)
2 None: Re: error while loading shared libraries: libxerces-c-3.1.so   (Ben Morgan - 30 Sep, 2011)
1 None: Re: error while loading shared libraries: libxerces-c-3.1.so   (Mark McCrea - 30 Sep, 2011)
(_ None: Re: error while loading shared libraries: libxerces-c-3.1.so   (Mark McCrea - 30 Sep, 2011)
(_ None: Re: error while loading shared libraries: libxerces-c-3.1.so   (John Allison - 03 Oct, 2011)
 Add Message Add Message
to: "error while loading shared libraries: libxerces-c-3.1.so "

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]