BootStrap: docker
From: ubuntu:16.04

%post
    export DEBIAN_FRONTEND=noninteractive
    apt-get update
    apt-get upgrade --no-install-recommends -y
    apt-get install --no-install-recommends -y \
        bc build-essential curl doxygen vim-nox wget \
        make cmake cmake-curses-gui ninja-build git \
        rsync ssh less \
        ccache gcc g++ gfortran \
        mpi-default-bin mpi-default-dev \
        libfftw3-dev libjpeg-dev libpng12-dev libblas-dev liblapack-dev \
        python-dev libeigen3-dev libgsl-dev libopenblas-dev libreadline-dev \
        virtualenv python3-dev python3-pip python3-pkg-resources \
        python3-setuptools python3-virtualenv \
        enchant

        # set custom prompt indicating the container name
        CUSTOM_PROMPT_ENV=/.singularity.d/env/99-zz_custom_prompt.sh
        cat >$CUSTOM_PROMPT_ENV <<EOF
#!/bin/bash
PS1="[ubuntu16.04:\u@\h] \W> "
EOF
        chmod 755 $CUSTOM_PROMPT_ENV

%environment
        LC_ALL=C
        export LC_ALL
        # tell OpenMPI to not try using Infiniband
        OMPI_MCA_btl="^openib"
        # do not warn about unused components as this messes up testing
        OMPI_MCA_btl_base_warn_component_unused="0"
        export OMPI_MCA_btl OMPI_MCA_btl_base_warn_component_unused

%labels
        Author akohlmey, rbberger
