Version 11 (modified by 6 years ago) ( diff ) | ,
---|
The preferred way to install root is from source and with *cmake*. The installation from source might not be necessary but is necessary for example if extra libraries (such as GQt for the FACT++ GUI) are required.
Forst download the source tar-ball from http://root.cern.ch (The version in the following is just an example, names and places are just a suggestions)
[0] tar xvfz root_v6.14.04.source.tar.gz # Extract the tar file [1] mv root-6.14.04 root-6.14.04-src # Rename the source diretory (for convenience) [2] mkdir root-6.14.04 # Create a build directory [3] cd root-6.14.04 # Change into the build directory [4] cmake ../root-6.14.04-src # Create the build environment [5] make # Make root [6] . bin/thisroot.sh # Properly setup your environment
Expect the compilation to take quite some time! With four 2.5GHz cores (-j4) it usually tages around one hour!
You might want to call cmake to setup the build environment with a different (e.g. faster) compiler like clang:
[4] cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ ../root-6.14.04-src
To force the compilation of the GQt module
[4] cmake -Dqt=ON ../root-6.14.04-src
Note that the current version of root (6.14) need RootNewMacros.cmake during compilation of derived projects which is (only) located in the source directory. Therefore, you must not remove or change the name of the source directory. I hope that will be fixed in the future.
Saving Space
To save space, after compilation you can create a binary package with make package
. This will create a .tar.gz
file. You can then extract this file (tar xvfz filename.tar.gz
) to any location you like (the default ist ./root
) and remove the build directory (and if you like also the source directory).
Font size
Lately, on modern screens, the default GUI fonts of root (10 and 12) are exceptionally small. They can be changed by adding the following lines to your .rootrc
. As root is always using the one in your home directory additonally, it is advisable to add these lines to your global .rootrc
.
Gui.DefaultFont: -*-helvetica-*-r-*-*-18-*-*-*-*-*-iso8859-1 Gui.MenuFont: -*-helvetica-*-r-*-*-18-*-*-*-*-*-iso8859-1 Gui.MenuHiFont: -*-helvetica-bold-r-*-*-18-*-*-*-*-*-iso8859-1 Gui.DocFixedFont: -*-courier-*-r-*-*-18-*-*-*-*-*-iso8859-1 Gui.DocPropFont: -*-helvetica-*-r-*-*-18-*-*-*-*-*-iso8859-1 Gui.IconFont: -*-helvetica-*-r-*-*-16-*-*-*-*-*-iso8859-1 Gui.StatusFont: -*-helvetica-*-r-*-*-16-*-*-*-*-*-iso8859-1
Packages
Ubuntu Packages known to be required
- libxpm-dev
- libxft-dev
Suggested (speeds up compilation):
- clang (-DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++)
- llvm-5.0 (-Dbuiltin_llvm=OFF -DLLVM_CONFIG=/usr/bin/llvm-config-5.0)
- libafterimage-dev (-Dbuiltin_afterimage=OFF)
- libftgl-dev (-Dbuiltin_ftgl=OFF)
- libglew-dev (-Dbuiltin_glew=OFF)
- libz-dev
- libcfitsio-dev
- libgl2ps-dev
- libgsl-dev
- liblz4-dev
- liblzma-dev
- libssl-dev
- libgif-dev
- libxml2-dev
- libfftw3-dev
- libtbb-dev
- libsqlite-dev
- libpythia8-dev
- libblas-dev