Install ReadMidas package
Preparing the Installation
In order to use the mTPCSoftware package, several third party tools must be installed on the computer where the package is being installed. In the following sections the required tools and there installation process are described.
FFTW3 installation
- Download the fftw3 package from http://www.fftw.org
- Unpack the source tarball and enter install directory
$> tar -zxvf fftw-3.2.2.tar.gz $> cd fftw-3.2.2
- Configure and install the package
$> ./configure $> make $> make install
Check if you can find the header file (fftw3.h) in /usr/local/include and the library (libfftw3.a) in /usr/local/lib. These are the default directories. If you find the files in different locations, you just need to adapt the ROOT configure command (see below).
ROOT installation
- Download the ROOT source files from http://root.cern.ch. The currently installed version on lheppc83 is 5.28.00b
- Unpack the source tarball and enter the ROOT directory
$> tar -zxvf root_v5.28.00b.source.tar.gz $> cd root
- Set the ROOT system environment variable, so you don't need to specify a prefix during configuration
$> export ROOTSYS=/path/to/root/installdir
- Configure the ROOT installation
$> ./configure <arch> --enable-explicitlink --enable-rpath --enable-soversion --enable-minuit2 --enable-qt --enable-roofit --enable-table --enable-fftw3 --with-fftw3-incdir=/usr/local/include --with-fftw3-libdir=/usr/local/lib
<arc> specifies the linux architecture. It is optional since ROOT should recognize it automatically. Make sure that you specify the fftw3 include and lib directories correctly if they differ from the default ones.
- Set the environment variables in your .bash_profile (if you use bash). Add:
export ROOTSYS=/path/to/root/installdir export PATH=$PATH:$ROOTSYS/bin export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$ROOTSYS/lib
Midas installation
- Download the Midas and XML packages from svn
$> svn co svn+ssh://svn@savannah.psi.ch/repos/meg/midas/trunk midas $> svn co svn+ssh://svn@savannah.psi.ch/repos/meg/mxml/trunk mxml
The password is svn (need to enter it 2 times for both packages)
- Enter the Midas directory and compile
$> cd midas $> make $> make install (as root)
- Set the environment variables in your .bash_profile (if you use bash). Add:
export MIDASSYS=/opt/midas export PATH=$PATH:$MIDASSYS/linux/bin export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$MIDASSYS/linux/lib
Note: If you get the error that linux/parport.h and linux/ppdev.h could not be found during installation, comment out the include lines in mscb.c.
ROOTANA installation
- Download the ROOTANA package from svn
$> svn checkout svn://ladd00.triumf.ca/rootana/trunk rootana
- Enter the ROOTANA directory and compile
$> make
- Set the environment variables in your .bash_profile (if you use bash). Add:
export ROOTANASYS=/path/to/rootana/installdir
Note: If you get errors during the installation of the mTPCSoftware package concerning the fPIC flag, enter the ROOTANA directory and add -fPIC to the CXXFLAGS in every Makefile (including libAnalyzer, libAnalyzerDisplay, libMidasInterface, libNetDirectory and libXmlServer) and recompile.
ReadMidas installation
Finally, after preparing the installation, we are ready to download the mTPCSoftware package and compile it. The software package is hosted on the diskstation lheppc90.
- Download the package
$> svn co svn+ssh://svnuser@lheppc90.unibe.ch/volume1/svn/mTPCSoftware mTPCSoftware
- Enter the mTPCSoftware directory and compile
$> cd mTPCSoftware/make $> make
- Set the environment variables in your .bashrc (if you use bash). Add:
export mTPCSYS=/path/to/mTPCSoftware/checkoutdir export PATH=$PATH:$mTPCSYS/bin export LD_LIBRARY_PATH=$ LD_LIBRARY_PATH:mTPCSYS/lib
The EventDisplay can access the SQL database on lheppc90 to retrieve run information which the user has added via the runlist. In order to be able to use this tool on your local machine you need to have libmysqlclient.so installed. On most Linux systems this library comes with the mysql-devel package.
Example .bash_profile (from lheppc83)
On lheppc83 all the third party software is installed in /opt/. The current .bash_profile looks like this:
export ROOTSYS=/opt/root export PATH=$PATH:$ROOTSYS/bin export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$ROOTSYS/lib export MIDASSYS=/opt/midas export PATH=$PATH:$MIDASSYS/linux/bin export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$MIDASSYS/linux/lib export ROOTANASYS=/opt/rootana export mTPCSYS=/home/exodaq/mTPCSoftware export PATH=$PATH:$mTPCSYS/bin export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$mTPCSYS/lib