ROOT with Pythia6 and Pythia8

Hi Bertrand,

thanks for the hint. I guess it was the Pythia8 version we were unlucky with (though I thought we tried a 8.1.* as well).

Anyways, just for completeness, here’s a full recipe that worked for us now …

mkdir Pythia
cd Pythia

wget https://root.cern.ch/download/pythia6.tar.gz
tar zxvf pythia6.tar.gz
rm -rf pythia6.tar.gz
wget http://www.hepforge.org/archive/pythia6/pythia-6.4.28.f.gz
gzip -d pythia-6.4.28.f.gz
mv pythia-6.4.28.f pythia6/pythia6428.f
rm -rf pythia6/pythia6416.f
mv pythia6 pythia6428
cd pythia6428
./makePythia6.linuxx8664
cd ..

wget http://home.thep.lu.se/~torbjorn/pythia8/pythia8186.tgz
tar zxvf pythia8186.tgz
rm -rf pythia8186.tgz
cd pythia8186
./configure --enable-shared --enable-64bit
make -j 4
cd ..

cat >setupPythiaROOT <<EOL
#!/bin/sh
export PYTHIA6=$PWD/pythia6428
export PYTHIA8=$PWD/pythia8186
export PYTHIA8DATA=$PWD/pythia8186/xmldoc
EOL
source setupPythiaROOT

wget http://root.cern.ch/download/root_v5.34.30.source.tar.gz
tar zxvf root_v5.34.30.source.tar.gz
mv root root53430
rm -rf root_v5.34.30.source.tar.gz
cd root53430
./configure --fail-on-missing \
  --with-pythia8-incdir=$PYTHIA8/include \
  --with-pythia8-libdir=$PYTHIA8/lib \
  --with-pythia6-libdir=$PYTHIA6 \
  --enable-pythia6 \
  --enable-pythia8
make -j 4
cd ..

cat >>setupPythiaROOT <<EOL
source root53430/bin/thisroot.sh
EOL

cp root53430/tutorials/pythia/pythiaExample.C .
cp root53430/tutorials/pythia/pythia8.C .

# adjust pythia6 path in pythiaExample.C to $PYTHIA6/libPythia6