I have a program . It is compiled without any problem. while running i get the following error.
error while loading shared libraries: libGraf3d.so: cannot open shared object file: No such file or directory
file libGraf3d.so is related to root. It is there in my system. I read on some other website that this problem can arise if you have installed a program many times and there are many versions of such files on system. Then operating system can not decide which file to link to during runtime.
LD_LIBRARY_PATH did not include the path of file. Now I have included this in my bashrc. It works.
Can you please tell a method to remove other versions of this file ? Actually i have mistakenly installed two versions of root ( 5.34 and 6.04 ). I would like to remove one of it . do you know a clean method ?
Hey,
could you please provide info how you did that?
I’m facing the ssam eproblem now but although I set the path to the file, it doesn’t work. Maybe I did something wrong. Thank you so much
This is what I included in the .bashrc:
LD_LIBRARY_PATH=/home/me/packages/usr/lib/root/libGraf3d.so
export LD_LIBRARY_PATH
Note: I’m trying to use Garfield++ on a linux remote server.
I’m on a ubuntu remote machine, no sudo privileges.
I downloaded, compiled and installed Garfield++ garfieldpp.web.cern.ch/garfieldpp/ according to the instructions.
I cloned a working code from my local machine and compiled it succesfully (pp.cc → pp).
When I do ./pp, I get the error:
./pp: error while loading shared libraries: libGraf3d.so: cannot open shared object file: No such file or directory
The same errors occurs for every Garfield++ simulation I want to run.
in the root directory, the libGraf3d.so appears in red.
“ls -l” gives:
-rw-r–r-- 1 victor victor 14341 Jan 29 01:46 libGraf3d_rdict.pcm
-rw-r–r-- 1 victor victor 1128 Jan 29 01:46 libGraf3d.rootmap
lrwxrwxrwx 1 victor victor 17 May 12 08:11 libGraf3d.so → libGraf3d.so.6.26’
I removed other libGraf3d.so.X.XX following the previous comments here.
I don’t know… do you have an idea what I did wrong?
Well, I now have libGraf3d.so at ./packages/root/lib/libGraf3d.so. So it is existent.
I’m now working with a fresh garfieldpp clone. For example, when trying to run the Gem example, I simply
source /home/me/packages/root/bin/thisroot.sh
source $GARFIELD_HOME/install/share/Garfield/setupGarfield.sh
LD_LIBRARY_PATH=/home/me/packages/root/
export LD_LIBRARY_PATH
cmake …
make
./gem
Output:
./gem: error while loading shared libraries: libGraf3d.so: cannot open shared object file: No such file or directory
Together with the additional information given above, I don’t know what else to tell you…