Compiling and installing ROOT on Ubuntu

Mustafa | December 6, 2009 | 8:55 am

ROOT is an important framework for people working in high energy physics and in analyzing accelerators data and some other fields. I am not here to introduce ROOT, you probably know what it is if you are looking for how to compile it.

  1. First you need to download the source code package.
  2. Uncompress the source code package.
  3. Enter the folder
  4. Now you need to install the required packages sudo apt-get install build-essential libx11-dev libxft2-dev xorg-dev
  5. Here you start with configuration, there are many compilation options. You can check them by entering ./configure --help
  6. I used the following command, the python parameter is to instruct the compiler to compile the python interface ./configure --enable-opengl --prefix=/usr/local --enable-python --enable-debug
  7. Now the making sudo make
  8. The installing sudo make install
  9. Now go to gedit /etc/ld.so.conf.d/libc.conf
  10. Add the following line, do not forget to replace $ROOT by the path to the root folder on your computer $ROOT/lib
  11. sudo ldconfig

This worked for me.

ENJOY!