System Requirements

Herwig is written in C++ but includes some FORTRAN and Python. Some of the programs we use to supply real and virtual amplitudes are written in FORTRAN.

  • By default we assume you are using gcc for compilation and should have the same version of gcc, g++ and gfortran. While Herwig should compile with any recent version of the compilers some of the amplitude providers require at least version 4.6 of gfortran, and hence at least that version of all the compilers should be used. If your system does not provide a recent version of the compilers the --build-gcc option of the bootstrap script can be used to install them.
  • You need to install both python and the headers for python so it can be linked with C++. This will usually be provided by packages called python and python-dev or python-devel on your system.
  • The OpenLoops package is installed from an svn repository and therefore you need to install svn if you wish to use this package.
  • ThePEG uses the zlib library to read compressed files. This is supplied by the zlib or zlib1g package on most systems. As the code is linked against the library the header files from the zlib-dev or zlib-devel or zlib1g-dev packages are also needed. This option can be disabled by using the -without-zlib option when configuring ThePEG.

Furthermore if you are installing Herwig or ThePEG from the repository you will need

  • The Mercurial package management system hg
  • The autotools packages automake, autoconf and libtool. If you use Mac OS X make sure that these are up to date as Mac shippes outdated versions. We require at least automake v1.13 and autoconf v2.65
  • The gengetopt program which can be installed using the --with-gengetopt of the bootstrap script if not provided by your system.

Finally if you wish to use a system install of the boost libraries, rather than installing them yourself or with the bootstrap script, you will need the boost or libboost package for the library and the header files supplied by the libboost-dev or boost-devel packages.


OS X Mavericks – All HEP dependencies (Rivet / HepMC / Fastjet)

First, make sure you get the OS X command line tools as described here (just ignore the Ruby-specific sections).

Next, install the Macports system.

Once that’s done, install the following:

sudo port install boost gsl gcc48 wget python27 cmake cython-py27 texlive-latex texlive-latex-extra texlive-latex-recommended

Run the Rivet booststrap script to sort out all the prerequisites. Then install ThePEG and Herwig++.

OS X Mountain Lion / Mavericks – Herwig alone

The install has become a lot less painful and works reliably on all of our OS X machines.

First, make sure you get the OS X command line tools as described here (just ignore the Ruby-specific sections).

From the Macports system, install gcc48, boost and gsl:

sudo port install boost gsl gcc48 wget

From here on, the can be used. Add the flags

--with-gsl=/opt/local --with-boost=/opt/local FC=gfortran-mp-4.8

to the configure step.

On some OS X systems, the build of ThePEG seems to hang indefinitely. Until we can resolve this issue permanently, add --disable-readline to the configuration flags.

Do you still get errors?

If you still get double free errors at runtime (our test machines don’t!), the most likely explanation is that you have built your toolchain with incompatible compilers.

The only compilers on your system should be /usr/bin/gcc etc. and /opt/local/bin/gcc-mp-4.8 etc. You need nothing in /usr/local and nothing from Fink (/sw).

Older versions of OS X: Leopard / Snow Leopard