Skip to content

Instantly share code, notes, and snippets.

@bast
Last active November 14, 2015 21:48
Show Gist options
  • Save bast/81760961c5a8199e561a to your computer and use it in GitHub Desktop.
Save bast/81760961c5a8199e561a to your computer and use it in GitHub Desktop.
Installation walkthru for DIRAC14 with GNU and OpenMPI (64bit-integers) on Ubuntu 14.04 x86_64.
#!/usr/bin/env bash
# complete installation walkthru for DIRAC14
# with GNU and OpenMPI (64bit-integers)
# on Ubuntu 14.04 x86_64
# Copyright (c) 2015 Radovan Bast
# Licensed under the MIT license - http://opensource.org/licenses/MIT
# ADAPT locations:
DIRAC_PATH=/tmp/dirac
OPENMPI_PATH=/tmp/openmpi
# set environment variables, this then belongs to .bashrc and/or .bash_profile
# when placing in .bashrc/.bash_profile, replace "$OPENMPI_PATH" with explicit path
export PATH=$OPENMPI_PATH/bin:$PATH
export LD_LIBRARY_PATH=$OPENMPI_PATH/lib:$LD_LIBRARY_PATH
# configure openmpi
TEMP_DIR=`mktemp -d`
cd $TEMP_DIR
wget http://www.open-mpi.org/software/ompi/v1.8/downloads/openmpi-1.8.4.tar.gz
tar xzf openmpi-1.8.4.tar.gz
cd openmpi-1.8.4
export FC=gfortran
export CC=gcc
export CXX=g++
export FCFLAGS="-m64 -fdefault-integer-8"
export CFLAGS=-m64
export CXXFLAGS=-m64
./configure --prefix=$OPENMPI_PATH
# build openmpi, may require sudo
make all install
# fetch DIRAC
mkdir -p $DIRAC_PATH
cd $DIRAC_PATH
git clone git@repo.ctcc.no:dirac.git
# configure
cd dirac
./setup --mpi --int64
# build
cd build
make
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment