Wiki

Clone wiki

supernu / setup_instructions

SETUP INSTRUCTIONS

The following procedure produces two supernu executables, one serial and one MPI-parallel version. Please report build errors to Daan van Rossum.

mkdir ~/supernu
cd ~/supernu
hg clone https://drrossum@bitbucket.org/drrossum/supernu src

#-- SERIAL --
mkdir bin
cd bin
lndir ../src
# Tools/lndir.sh can be used instead of lndir if lndir is not available on the system)
# make sure that no .mod, .o, or .a files were linked from the source directory
ln -sf ./mpimod_ser.f ./mpimod.f
cp -f ./System/Makefile.compiler.gfortran ./Makefile.compiler
# modify the compiler flags to your liking (e.g. optimization, debug flags etc.)
make -j
cd ../../supernu

#-- MPI --
mkdir bin-mpi
cd bin-mpi
lndir ../src
cp -f ./System/Makefile.compiler.gfortran ./Makefile.compiler
# update the ./Makefile.compiler to something like: FC=mpif90
# modify the compiler flags to your liking (e.g. optimization, debug flags etc.)
ln -sf ./mpimod_mpi.f ./mpimod.f
make -j

Note that the current Makefile requires Bash v. 4.0 or greater due to the use of associative arrays. Some systems with older shells, such as OS/X (which has Bash v 3.2.57 as of OS/X 10.11.5 installed in /bin/bash) may report an error during the build, i.e.

dependmodule.sh: line 12: declare: -A: invalid option

Updated