ROOT for Debian GNU/Linux 9 (stretch)

by Ricardo Yanez
Last updated: July 12, 2017

ROOT is not part of Debian as of the last stable version 9 (stretch). This is a quick installation guide from source that avoids debianization.

Download the source. When stretch was released in June 17 2017, the latest pro version of ROOT was 6.10/00.

Install dependencies,

sudo apt-get install cmake libx11-dev libxpm-dev libxft-dev libxext-dev 
libtiff5-dev libgif-dev libgsl-dev libpython-dev libkrb5-dev libxml2-dev libssl-dev 
default-libmysqlclient-dev libpq-dev libqt4-opengl-dev libgl2ps-dev libpcre-ocaml-dev 
libgraphviz-dev libdpm-dev unixodbc-dev libsqlite3-dev libfftw3-dev libcfitsio-dev 
dcap-dev libldap2-dev libavahi-compat-libdnssd-dev

Create a directory, for instance root, then untar the source,

mkdir root
cd root
tar -zxvf ../root_v6.10.00.source.tar.gz

Create a working directory,

mkdir build
cd build

then configure, compile and install,

cmake ../root-6.10.00/ -DCMAKE_INSTALL_PREFIX=/usr/opt/root -Dgnuinstall=ON
make -j4
sudo make install

The option '-j' in make means the number of jobs to run simultaneously, in this case, four. In multi-core systems this reduces the compilation time considerably.

Update the dynamic linker,


Define the ROOT environment variables in your .bashrc,

export ROOTSYS=/usr/opt/root
export PATH=$PATH:$ROOTSYS/bin

If the system has many ROOT users, it may be advantageous to define these variables system-wide in /etc/bash.bashrc instead.

Run root at the terminal-emulator.

This document was generated using AFT v5.098