Newer
Older
Alexander van Amesfoort
committed
LOFAR (LOw Frequency ARray) Software Repository - INSTALL
=========================================================
Installation instructions for LOFAR software.
Supported Systems
-----------------
- Linux (most in use at ASTRON are Ubuntu, CentOS, and SUSE Linux Enterprise)
Alexander van Amesfoort
committed
- Mac OS X (reasonably recent should work, also with LLVM/Clang)
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
Install from Ubuntu Packages
----------------------------
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
To install LOFAR Offline processing tools the easy way for a specific Ubuntu version, see:
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
https://launchpad.net/~radio-astro/+archive/ubuntu/main
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
Install using Docker Scripts
----------------------------
To create a Docker container with Ubuntu or CentOS and LOFAR Offline processing tools, see:
https://github.com/lofar-astron/lofar-deploy
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
Dependencies for Manual Build from Source
-----------------------------------------
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
Please first try to install as many dependencies as possible using your OS
package manager. For almost all cases, you also need the development packages
('pkgname-dev' for Debian/Ubuntu, or 'pkgname-devel' for CentOS/Fedora).
Alexander van Amesfoort
committed
For Debian/Ubuntu (likely incomplete list, but goes a long way):
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
apt-get install subversion cmake make g++ gfortran python-dev python-numpy
apt-get install libboost-dev libblitz0-dev libfftw3-dev libcfitsio3-dev libxml2-dev liblog4cplus-dev
apt-get install libpng12-dev # or latest version; for AOFlagger
Alexander van Amesfoort
committed
apt-get install libreadline-dev libpqxx-dev doxygen # optional
apt-get install libgsl0-dev # optional, for AOFlagger's RayleighFitter
apt-get install libgtkmm-[2.4|3.0]-dev libsigc++-2.0-dev # optional, for AOFlagger's rficonsole
apt-get install libunittest++-dev # optional, for tests that use UnitTest++
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
For CentOS/Fedora (likely incomplete list, but goes a long way):
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
yum install subversion cmake make gcc python-devel numpy
yum install boost-devel fftw-devel cfitsio-devel libxml2-devel libpng-devel
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
yum install readline-devel libpqxx-devel doxygen # optional
yum install gsl-devel # optional, for AOFlagger's RayleighFitter
yum install gtkmm[24|30]-devel libsigc++20-devel # optional, for AOFlagger's rficonsole
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
The blitz and blitz-devel pkgs are available on some distros, but not on e.g. CentOS 7.
If required for your build, but not in your repo, take the two RPMs from CentOS 6 (or build from source).
Alexander van Amesfoort
committed
Idem for log4cplus (LOFAR log4cxx support is dodgy).
Similar for unittest++ and unitest++-devel (both optional), but take two RPMs from Fedora 22 (or build from source).
RPMs known to work on CentOS 7 can be found at: https://support.astron.nl/lofar_issuetracker/issues/8161
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
NOTE (any OS): For manual builds, the most prominent dependency you likely need to build is casacore (+ friends):
Alexander van Amesfoort
committed
casacore: https://github.com/casacore/casacore
python-casacore ('pyrap'): https://github.com/casacore/python-casacore
IERS/measures tables: https://github.com/casacore/casacore-data-update
casarest: https://svn.astron.nl/casarest
Alexander van Amesfoort
committed
AOFlagger: http://sourceforge.net/projects/aoflagger/
Alexander van Amesfoort
committed
Instructions for Manual Build from Source
-----------------------------------------
Alexander van Amesfoort
committed
- SVN checkout build and configuration scripts of a tagged release x.y.z (or the
trunk) from https://svn.astron.nl/LOFAR/ into e.g. $HOME/src/LOFAR-x.y.z/
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
LOFAR_RELEASE=LOFAR-Release-x.y.z # set to used release version
svn checkout --depth=files "https://svn.astron.nl/LOFAR/tags/$LOFAR_RELEASE" "$HOME/src/$LOFAR_RELEASE"
svn update --depth=infinity "$HOME/src/$LOFAR_RELEASE/CMake"
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
- Auto-checkout and install the usual offline data reduction (imaging) packages
into e.g. $HOME/local/$LOFAR_RELEASE/
Alexander van Amesfoort
committed
(Only ends succesfully once CMake can find all required dependencies.)
Alexander van Amesfoort
committed
mkdir -p $HOME/build/$LOFAR_RELEASE/gnu_opt # last directory must be {gnu|clang}_{debug|opt}
cd $HOME/build/$LOFAR_RELEASE/gnu_opt
cmake -DCMAKE_INSTALL_PREFIX="$HOME/local/$LOFAR_RELEASE" -DBUILD_PACKAGES="DP3 Calibration Imager PyBDSM" -DUSE_OPENMP=ON "$HOME/src/$LOFAR_RELEASE"
Alexander van Amesfoort
committed
- Build and install:
Alexander van Amesfoort
committed
make -j 4
make -j 4 install # with sufficient privileges
Alexander van Amesfoort
committed
- Optionally, run the regression tests:
Alexander van Amesfoort
committed
ctest -j 4 --timeout 60
Alexander van Amesfoort
committed
Alexander van Amesfoort
committed
All tests should pass, however, a few packages (not selected above) require
GPU hardware or a database to pass all tests.
Alexander van Amesfoort
committed
- You may want to add the installation path bin/ to your PATH by sourcing (not executing!) the lofarinit script:
Alexander van Amesfoort
committed
. "$HOME/local/$LOFAR_RELEASE/lofarinit.sh" # for Bourne-like shells, or
. "$HOME/local/$LOFAR_RELEASE/lofarinit.csh" # for C-like shells