Jump to content
Compatible Support Forums
Sign in to follow this  
dwinn

Running program in terminal question. Please help

Recommended Posts

I am so confused by this problem because I know it shouldn't exist. I have installed a program called GEANT4 and spent the past 2 weeks trying to get it to run. Yesterday it did run and today it does not, and I couldn't understand how this is possible. When I would execute an example, I would receive this error:

[root@localhost N01]# /root/bin/Linux-g++/exampleN01

/root/bin/Linux-g++/exampleN01: error while loading shared libraries: libG4persistency.so: cannot open shared object file: No such file or directory

 

A friend helped guide me to solve this problem. He told me to enter /root and use emacs to edit .bashrc by adding lines:

LD_LIBRARY_PATH=/root/geant4/lib/:$LD_LIBRARY_PATH

export LD_LIBRARY_PATH

 

This helped because it told the computer where to find the library. Now when I would execute an example the program ran perfectly. However, I closed the terminal and re-opened it to run into the same problem. The libG4persistency.so file cannot be found, and I thought the problem was fixed so now I don't know what to do and I cannot reach my friend for 2 weeks. Can anyone please provide assistance?

Share this post


Link to post

Are you trying to run the program as root? The only environment you changed was root's. You also have a .bashrc in your user's home directory that you can use that trick with (if the user has permission to run the geant4 script, of course).

 

If this is not the problem. Have you tried running ldconfig, then running the script? Failing that, try adding

 

/root/geant4/lib

 

to the end of your /etc/ld.so.conf file and then run ldconfig then see if you can run the script.

Share this post


Link to post

Thank you for your suggestion but the error remained, I am still stumped.

Share this post


Link to post

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×