Installing CbmRoot


In order to install CbmRoot, you need
  • The external packages (fairsoft); for their installation see InstallExternPackages.
  • FairRoot; for its installation see InstallFairRoot. This is only necessary for revision later than 7014 (11 March 2015) on releases later than FEB14. Previous versions of CbmRoot contain the FairRoot libraries as svn:externals, so you do not have to care about it.

Installation Procedure

Getting the CbmRoot source code

The CbmRoot code is distributed through a subversion repository. Here we describe how to get the current trunk version, which is the working version for developers. As a user, you should instead use a stable version (release). Instructions on how to get other versions than the trunk can be found in InstallCbmRootVersions.

First decide in which directory you want the source code to be. Let us call it CBMSRC. To get the CbmRoot trunk, type

svn checkout [CBMSRC]

If you do not specify CBMSRC, the code will be put in your current directory.

Install the magnetic field maps

Beside the source code you will need in most cases a magnetic field map to run CbmRoot. Because of their size (about 73 MB each), these files are not distributed with the CbmRoot source code. They are in a branch of the cbmroot repository. The fieldmaps have to be located in the directory [CBMSRC]/input, so you either copy them to this directory after checkout or (more preferable) create soft links there.

svn checkout [FIELDMAP_DIR]
cd [SRCDIR]/input

For a list of available field maps, see here.

Build the project

We use the cmake tool to build and configure the CbmRoot project. This automatically checks the prerequisites. First, specify the installations paths of fairsoft and FairRoot (see above):

export SIMPATH=[path_to_fairsoft_installation]
export FAIRROOTPATH=[path_to_fairroot_installation]

Choose a path where the CbmRoot binaries should be built (henceforth called CBMBIN). Create and change to that directory:
mkdir [CBMBIN]

Then, build the project by
$SIMPATH/bin/cmake [CBMSRC]

Compile CbmRoot

cmake has created a configuration file, which you should execute before compiling (and running) CbmRoot:

. ./

Then, just compile by

It will take a while. If you have more than one core, you can accelerate the compilation process and limit your caffeine consumption by using
nice make -j [number_of_cores]

Test your CbmRoot installation

After the compilation has finished, test if the defined tests run and finish successful

make test

Running CbmRoot

Now you can start using CbmRoot. If you want to do that in a later shell session, remember to run the configuration script before (. [CBMBIN]/ For more details, see Run_CbmRoot.

Updated by Florian Uhlig 6 months ago · 8 revisions