I read with satisfaction the fact that Cern’s ROOT physics and data analysis framework has finally been integrated into Debian. I assumed that this would lead to easier installation on Ubuntu and in the future, hopefully, ROOT in the Ubuntu repositories. For a brief and happy period there was a third party repository with up-to-date and semi-official ROOT packages.
My hopes were dashed with the news that the Brookhaven machine hosting the repository lost a hard disk and the Ubuntu repository was down. I frequently need access to ROOT packages, so I just recently built .debs from the lastest stable release (5.16.00). Here’s a guide as to how to make it work:
Install some Debian packaging tools (this might not be definitive):
apt-get install fakeroot devscripts
Install the development prerequisites (some of these might not be needed):
apt-get install libafterimage-dev libxmlrpc-c3-dev libglu1-mesa-dev libpacklib1-dev libkrb5-dev libldap2-dev libmysqlclient15-dev libpq-dev python-dev libqt3-headers libqt3-compat-headers libqt3-mt-dev qt3-dev-tools ruby1.9 ruby1.9-dev ruby1.8-dev libxml2-dev libssl-dev comerr-dev libxpm-dev libfreetype6-dev libpcre3-dev g77 libodbc++-dev libsqlod75-dev libiodbc2-dev libungif4-dev fftw3-dev krb5-user libgsl0-dev debhelper libpqxx-dev libsqldbc75-dev libttf-dev
Download the source package from the main ROOT page.
Unzip the source and change the directory name from ‘root’:
tar -zxf root_v5.16.00.source.tar.gz
mv root root-system-5.16.00
Make the .orig copy for source packages:
cp -r root-system-5.16.00 root-system-5.16.00.orig
Create the 'debian' directory
If necessary, edit the 'CONFOPTIONS' variable in debian/rules (shouldn't be necessary)
Update debian/changelog, insert a new entry with matching version number to the root directory, add your own name and email.
root-system (5.16.00) experimental; urgency=low
* Version number bump
-- Andrew O'Neill
Now, some fixes for broken things:
- For some reason, some of the builtin packages don’t get untarred during the build, this will cause an infinite error loop during build. This will fix it:
- Repeat that for unuran/src/unuran-1.0.1-root.tar.gz
- Repeat for xrootd/src/xrootd-20060928-1600.src.tgz
- For 5.16.00, there is a bug in the pgsql code that will block compilation. Edit file pgsql/src/TPgSQLServer.cxx and change the variables
stmt->fRes. This error has been fixed in the CVS version.
tar -zxf libAfterImage.tar.gz
Get ready for the build
fakeroot debian/rules debian/control
Configure, compile, link and create packages:
dpkg-buildpackage -rfakeroot -nc
If the build succeeds, you should find the packages in the parent directory of root-system-5.16.00
Despite requesting disable-builtin-afterimage, the configure script complains that the Ubuntu version of afterimage is too new, so will use the builtin one anyway.
If the build fails and you need to reconfigure and try again without building everything from scratch, you can probably speed things up by doing: