General instructions are for GNU compiler and OpenMPI. For using other compiler/MPI use corresponding entries from the table below.

Compiler MPI
GNU gcc g++ mpicc mpicxx Open-MPI
Intel icc icpc mpiicc mpiicpc Intel-MPI
IBM bgxlc bgxlc++ mpixlcc mpixlcxx IBM-MPI

Environment Variables : The following environment variables need to be set before compiling tarang. (You may append these lines to $HOME/.bashrc)

export PATH=$HOME/local/bin:$PATH
export PKG_CONFIG_PATH=$HOME/local/lib/pkgconfig:$PKG_CONFIG_PATH
export HDF5_ROOT=$HOME/local
export CPATH=$HOME/local/include/:$CPATH
export MANPATH=$HOME/local/share/man/:$MANPATH

CMake : Download CMake library from here

CC=gcc CXX=g++ ./configure --prefix=$HOME/local
make install

Blitz++ : Download Blitz++ library from here

CC=gcc CXX=g++ ./configure --prefix=$HOME/local
make install

YAML-cpp : Download YAML-cpp library from here [Download yamp-ccp version 0.3.0 , higher versions are presently not compatible.]

make install

MPICH : Download MPICH library from here
For Mac OSX additional arguments might be needed to be supplied to configure.
64bit: CFLAGS=-m64 CXXFLAGS=-m64 FFLAGS=-m64 FCFLAGS=-m64
32bit: CFLAGS=-m32 CXXFLAGS=-m32 FFLAGS=-m32 FCFLAGS=-m32

CC=gcc CXX=g++ ./configure --prefix=$HOME/local
make install

FFTW : Download FFTW library from here

fftw – double

MPICC=mpicc CC=mpicc CXX=mpicxx ./configure --prefix=$HOME/local --enable-mpi --enable-openmp
make install

fftw – float

MPICC=mpicc CC=mpicc CXX=mpicxx ./configure --prefix=$HOME/local --enable-mpi --enable-float --enable-openmp
make install

NOTE: for intel compilers use

MPICXX=mpiicpc MPICC=mpiicc CC=mpiicc CXX=mpiicpc ./configure --prefix=$HOME/local --enable-mpi --enable-openmp

FFTK : Download FFTK library from here

CC=mpicc CXX=mpicxx cmake -DCMAKE_INSTALL_PREFIX=$HOME/local
make install

HDF5 : Download HDF5 library from here

CC=mpicc CXX=mpicxx ./configure --prefix=$HOME/local --enable-parallel --without-zlib
make install

H5SI : Note–Only for new tarang
Download H5SI library from here

CXX=mpicxx cmake . -DCMAKE_INSTALL_PREFIX=$HOME/local
make install

To compile Tarang Unzip tarang. Make a directory build just outside tarang folder and cd to it. If the above environment variables are not set, open trunk/CMakeLists.txt and change SET(INCLUDE_DIRS …) and SET(LIBRARY_DIRS …) as per your systems mpi and CUDA (If using GPU versions of the code) and pass argument ‘-DFIND_LIBRARIES=OFF’ to cmake.

CXX=mpicxx cmake ../tarang/trunk/

To setup Tarang using eclipseMake build directory in the tarang folder (has to be a sibling of trunk as required by Eclipse CDT4 CMake Generator).

CXX=mpicxx cmake ../trunk/ -DCMAKE_BUILD_TYPE=DEBUG -G"Eclipse CDT4 - Unix Makefiles"