|
|
Line 1: |
Line 1: |
| by Rich Holmes | | by Rich Holmes |
| | | |
− | I have been working on getting the Geant4 simulation and related software up and running on a couple of non JLAB systems; here are some notes on what I did most recently. I may be omitting some steps here and I definitely have rearranged the order and left out some steps that I tried but that didn't seem to give useful results, so there are no guarantees this will work for anyone else, but it should cut down on confusion, or so I hope. This should be a better example to follow than my previous one (thanks to better understanding on my part, and probably some improvements in the solgemc package itself), but you can [[Earlier solgemc installation outside JLAB|read about that too]] if you want. | + | I have been working on getting the Geant4 simulation and related software up and running on a couple of non JLAB systems; here are some notes on what I did most recently. This is a much better example to follow than my previous ones, but you can [[Earlier solgemc installation outside JLAB|read about those too]] if you want. |
| | | |
| The target system for now is one running Ubuntu 10.10 (32 bit i386). | | The target system for now is one running Ubuntu 10.10 (32 bit i386). |
| | | |
− | Generally speaking what I tried to do was to set up a directory structure similar to what is installed using the gemc RPM; qt4 and geant4 already existed on this system but not necessarily configured as needed for gemc, so I put new installations into the new directory tree.
| + | I followed the procedure [https://gemc.jlab.org/gemc/Support/Entries/2011/8/1_Step_by_Step.html here] to install gemc. Aside from a temporary problem with off site access all that went as it should. |
| | | |
− | == initial setup ==
| + | After that: |
− | # mkdir ~/jlab_software ''and cd there''
| + | |
− | # mkdir Linux_Ubuntu10.04-i686-gcc4.4.3
| + | |
| | | |
− | == environment ==
| + | # cd $JLAB_SOFTWARE/gemc |
− | # svn checkout https://phys12svn.jlab.org/repos/trunk/ce ''in ~/jlab_software'' | + | # ''Edit $JLAB_SOFTWARE/gemc/SConstruct: copy the env.Library line at the end, paste, and replace env.Library with env.SharedLibrary .'' |
− | # ''Edit to set DEFAULT_JLAB_ROOT to ~/jlab_software. Also edit default software versions below that as needed.''
| + | |
− | # ''Depending on your Linux distribution you may need to edit ce/osreleast.pl in the obvious place to set an appropriate value for $release. For my Ubuntu 10.10 installation this was not necessary.''
| + | |
− | # source ~/jlab_software/ce/jlab.csh
| + | |
− | | + | |
− | == scons ==
| + | |
− | | + | |
− | # ''Install scons using Ubuntu Software Center''
| + | |
− | # svn checkout https://clas12svn.jlab.org/repos/trunk/clas12/scons_scripts/ ''in ~/jlab_software''
| + | |
− | # ''Depending on your ROOT version you may need to change''<br />env.Append(LIBPATH = [ROOTSYS + '/lib/root'])<br />''to''<br />env.Append(LIBPATH = [ROOTSYS + '/lib'])<br />''in loadroot.py''
| + | |
− | | + | |
− | == Qt4 ==
| + | |
− | | + | |
− | # ''Download sources from http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src-4.7.3.tar.gz''
| + | |
− | # ''Install following https://gemc.jlab.org/gemc/Support/Entries/2011/1/22_Getting_and_Compiling_qt4.html into ~/jlab_software/Linux_Ubuntu10.04-i686-gcc4.4.3/qt''
| + | |
− | | + | |
− | == ROOT ==
| + | |
− | | + | |
− | # ''Install ROOT as usual from source into ~/jlab_software/Linux_Ubuntu10.04-i686-gcc4.4.3/root ; use'' configure --enable-qt --enable-qtgsi
| + | |
− | | + | |
− | == CLHEP ==
| + | |
− | | + | |
− | # ''Install following https://gemc.jlab.org/gemc/Support/Entries/2011/1/22_Getting_and_Compiling_clhep.html into ~/jlab_software/Linux_Ubuntu10.04-i686-gcc4.4.3/clhep''
| + | |
− | | + | |
− | == geant4 ==
| + | |
− | | + | |
− | # ''Do a manual install from sources into ~/jlab_software/Linux_Ubuntu10.04-i686-gcc4.4.3/geant4. Sources from http://geant4.web.cern.ch/geant4/support/download.shtml ; manual installation instructions at http://geant4.web.cern.ch/geant4/UserDocumentation/UsersGuides/InstallationGuide/html/ch02s03.html . The ce environment defines the needed environment variables for correct configuration; don't use ./Configure -build .''
| + | |
− | | + | |
− | == evio ==
| + | |
− | | + | |
− | # svn checkout https://clas12svn.jlab.org/repos/trunk/clas12/evio ''and put into ~/jlab_software/Linux_Ubuntu10.04-i686-gcc4.4.3/evio; cd there.''
| + | |
− | # ./configure
| + | |
− | # make
| + | |
− | # make install
| + | |
− | | + | |
− | == mysql ==
| + | |
− | | + | |
− | # sudo apt-get install mysql-client libmysqlclient-dev
| + | |
− | | + | |
− | == gemc ==
| + | |
− | | + | |
− | # ''Install following https://gemc.jlab.org/gemc/Support/Entries/2011/1/19_Getting_and_Compiling_gemc.html into ~/jlab_software/Linux_Ubuntu10.04-i686-gcc4.4.3/gemc and cd there.''
| + | |
− | # ''Edit ~/jlab_software/Linux_Ubuntu10.04-i686-gcc4.4.3/gemc/SConstruct: copy the env.Library line at the end, paste, and replace env.Library with env.SharedLibrary .'' | + | |
| # scons | | # scons |
− | # ''Depending on your Linux installation you may need something like '' sudo chcon -t texrel_shlib_t ~/jlab_software/Linux_Ubuntu10.04-i686-gcc4.4.3/gemc/libgemc.so ''to avoid an error caused by selinux; this was not necessary for my Ubuntu 10.10 installation.''
| |
| | | |
| == solgemc == | | == solgemc == |
| | | |
− | # svn checkout https://jlabsvn.jlab.org/svnroot/solid/solgemc | + | # svn checkout https://jlabsvn.jlab.org/svnroot/solid/solgemc ''into $JLAB_SOFTWARE/solgemc and cd there'' |
− | # ''To test, set up mysql tunneling. In runnewbaf_solgemc.sh comment out first command and uncomment second, change -N to 10000, then run this. I get a memory allocation crash at the end but the output file is written.''
| + | |
− | | + | |
− | == banks ==
| + | |
− | | + | |
− | # svn checkout https://clas12svn.jlab.org/repos/trunk/clas12/banks into ~/jlab_software/Linux_Ubuntu10.04-i686-gcc4.4.3/banks
| + | |
− | # ''unpack tarball sent by Seamus, copy src/example4.cc to banks/src/''
| + | |
− | # ''edit src/bank.cc to replace'' db.setUserName("clasuser"); ''with'' db.setUserName("soliduser"); db.setPassword("ilovesolid");
| + | |
| # scons | | # scons |
| + | # ''In your ~/.cshrc add $JLAB_SOFTWARE/gemc to LD_LIBRARY_PATH environment variable'' |
| | | |
− | == cteq ==
| + | For additional packages, e.g. banks, cteq, event generator, root2lund see [[Earlier solgemc installation outside JLAB|Second Installation here]]. |
− | # ''download http://desy.de/~znagy/hep-programs/cteq-pdf/cteq-pdf-1.0.4.tar.gz and untar into ~/jlab_software/Linux_Ubuntu10.04-i686-gcc4.4.3/cteq-pdf/1.0.4 . cd there.''
| + | |
− | # ./configure --prefix=/usr/local ''default is to install under ~/, I chose to install in /usr/local''
| + | |
− | # make
| + | |
− | # sudo make install
| + | |
− | | + | |
− | == event generator ==
| + | |
− | | + | |
− | # svn co https://jlabsvn.jlab.org/svnroot/solid/evgen ''and put into ~/jlab_software/Linux_Ubuntu10.04-i686-gcc4.4.3/evgen; cd there.''
| + | |
− | # cd eicRate_20101102
| + | |
− | # make
| + | |
− | | + | |
− | == root2lund ==
| + | |
− | | + | |
− | # cd ~/jlab_software/Linux_Ubuntu10.04-i686-gcc4.4.3/evgen/root_to_lund
| + | |
− | # make ''Note: I did not need any environment variable changes (using ROOT 5.25).''
| + | |
I have been working on getting the Geant4 simulation and related software up and running on a couple of non JLAB systems; here are some notes on what I did most recently. This is a much better example to follow than my previous ones, but you can read about those too if you want.
The target system for now is one running Ubuntu 10.10 (32 bit i386).