-
Notifications
You must be signed in to change notification settings - Fork 1
Install
The following is a sequence of commands
and their explanations of how to install PAMHD. The commands should be copied and pasted into a terminal. It is assumed that each command succeeds, if not you should probably not continue with the rest of the commands and instead figure out why the command failed. If you don't want to wait for every command to finish to see whether it succeeded you can start a new shell with e.g. bash -e
, which will exit at the first error, and copy & paste all commands into the shell. You can request help by creating a new issue at https://github.com/iljah/pamhd/issues/new.
These instruction require that git is installed. A C++17 compiler is also required such as GCC-8 or later. Also make sure that $HOME/bin
is in your PATH
environment variable and $HOME/lib
is in your LD_LIBRARY_PATH
environment variable (for example in bash do a echo "export LD_LIBRARY_PATH=$HOME/lib:$LD_LIBRARY_PATH" >> $HOME/.bashrc
, similarly for PATH and then log out and log back in).
As many of the prerequisites are not available in package repositories these instructions install them into your home directory. This also allows better control of the versions to download/install. If a package is available via the system's package manager you can edit paths to the install location of the package in the makefile (default is to use the paths in makefiles/homedir).
cd $HOME
git clone https://github.com/beltoforion/muparserx.git
cd muparserx
cmake .
make
mkdir -p $HOME/lib
cp libmuparserx.a $HOME/lib/
mkdir -p $HOME/include
cp parser/*.h $HOME/include/
make clean
Some versions of Open MPI are known not to work, check the README file in the root directory of PAMHD. If you don't have a supported version of MPI, install one into your home directory:
cd $HOME
wget https://download.open-mpi.org/release/open-mpi/v4.1/openmpi-4.1.5.tar.bz2
tar xf openmpi-4.1.5.tar.bz2
cd openmpi-4.1.5
./configure --prefix=$HOME --enable-mpi-fortran=no
make
make install
cd $HOME
wget https://github.com/sandialabs/Zoltan/archive/refs/tags/v3.901.tar.gz -O zoltan_distrib_v3.901.tar.gz
tar xf zoltan_distrib_v3.901.tar.gz
mkdir zoltan-build
cd zoltan-build
CC=mpicc CXX=mpic++ ../Zoltan-3.901/configure --prefix=$HOME --enable-mpi --with-mpi-compilers --with-gnumake --with-id-type=ullong
make
make install
cd $HOME
wget https://boostorg.jfrog.io/artifactory/main/release/1.82.0/source/boost_1_82_0.tar.bz2
tar xf boost_1_82_0.tar.bz2
cd boost_1_82_0
./bootstrap.sh
echo "using gcc : $(mpic++ --version|head -1|cut -f3 -d\ ) : mpic++ ;" >> user-config.jam
echo "using mpi : mpic++ : <define>B2MPIJUSTUSEMPI ;" >> user-config.jam
./b2 --user-config=user-config.jam
./b2 --user-config=user-config.jam --prefix=$HOME install
Download PAMHD and it's submodules:
cd $HOME
git clone --recursive https://github.com/iljah/pamhd.git
and compile it running (GNU) make from the PAMHD root directory:
cd pamhd
make
Optionally select another environment to compile for:
make ENVIRONMENT_MAKEFILE=makefiles/macosx_macports_llvm
The makefiles
directory houses all environment dependent makefiles, if none correspond to your environment request a new one by creating an issue at https://github.com/iljah/pamhd/issues/new