-
Notifications
You must be signed in to change notification settings - Fork 10
Continuous Integration
kreczko edited this page Jun 10, 2014
·
3 revisions
This recipe is based on the one from rootpy wiki page.
travis-ci.org is a free open source continuous integration service with a native support of github pull requests. We use it to test DailyPythonScripts code on 64-bit Ubuntu with Python 2.7 and different ROOT versions. Python 3 is planned to be integrated in future.
The ROOT binaries are custom-built using the Virtual Box machine, this recipe explains how to do it. Let's start:
- Install VirtualBox
- Download the latest 64bit Ubuntu desktop ISO disk image here
- Install the ISO as a virtual machine and start it
- Update, upgrade and install some essential tools from the terminal:
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install emacs23 vim subversion git
- Install the ROOT build prerequisites:
sudo apt-get install dpkg-dev make g++ gcc binutils libx11-dev libxpm-dev libxft-dev libxext-dev
- Might as well install these packages if you want to test changes to rootpy or DPS:
sudo apt-get install python-dev python-nose python-numpy python-matplotlib python-tables ipython-notebook
- Create a build directory:
mkdir -p ~/software/install
cd ~/software
- Download all the ROOT versions you want to build, for example:
# Example: ROOT v5-34-18, Python 2:
git clone http://root.cern.ch/git/root.git
mv root root_v5.34.18_python_2.7
cd root_v5.34.18_python_2.7
git tag -l
git checkout -b v5-34-18 v5-34-18
- Now let's configure, build, install and make a tarball for each ROOT version, e.g.:
./configure --enable-roofit --enable-minuit2 --enable-builtin-freetype
make -j8
source bin/thisroot.sh
# Check if PyROOT is OK (TBrowser will quickly pop up and close):
python -c 'import ROOT; ROOT.TBrowser()'
make DESTDIR=/tmp install
mv /tmp/home/travis/software/root_v5.34.18_python_2.7 ~/software/install/
cd ~/software/install/
tar zcvf root_v5.34.18_python_2.7.tar.gz root_v5.34.18_python_2.7
- The tarball is ready, now put it online in order to be accessible for Travis (e.g. CERN-based web page)
- Update .travis.yml accordingly to include your new tarball.