dune-env.dockerfile 2.27 KB
Newer Older
1 2 3 4
FROM ubuntu:bionic
LABEL maintainer="lriedel@iup.uni-heidelberg.de"
# number of cores for parallel builds
ARG PROCNUM=1
5 6 7
# Compilers to be used
ARG CC=gcc
ARG CXX=g++
8

9 10 11 12
# disable any prompts while installing packages
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get clean \
    && apt-get update \
13
    && apt-get install -y \
14 15 16 17 18 19 20
        clang \
        cmake \
        doxygen \
        gcc \
        g++ \
        gfortran \
        git \
21
        graphviz \
22 23 24 25
        libatlas-base-dev \
        libfftw3-dev \
        libfftw3-mpi-dev \
        libfreetype6-dev \
26
        libgraphviz-dev \
27 28 29 30 31 32 33 34 35 36 37 38 39
        libhdf5-mpi-dev \
        libmetis-dev \
        libmuparser-dev \
        libopenmpi-dev \
        libpng-dev \
        libparmetis-dev \
        libsuperlu-dev \
        libxft-dev \
        libyaml-cpp-dev \
        locales \
        python3-dev \
        python3-pip \
        python3-vtk7 \
40 41 42 43 44 45 46
    && apt-get clean

RUN rm -rf /var/lib/apt/lists/* \
    && localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
ENV LANG en_US.utf8

WORKDIR /opt/dune
47
RUN git clone https://gitlab.dune-project.org/staging/dune-uggrid.git -b releases/2.6 \
48
    && git clone https://gitlab.dune-project.org/oklein/dune-randomfield.git -b releases/2.6 \
49 50 51 52 53 54 55 56
    && git clone https://gitlab.dune-project.org/core/dune-common.git -b releases/2.6 \
    && git clone https://gitlab.dune-project.org/core/dune-geometry.git -b releases/2.6 \
    && git clone https://gitlab.dune-project.org/core/dune-grid.git -b releases/2.6 \
    && git clone https://gitlab.dune-project.org/core/dune-istl.git -b releases/2.6 \
    && git clone https://gitlab.dune-project.org/core/dune-localfunctions.git -b releases/2.6 \
    && git clone https://gitlab.dune-project.org/staging/dune-functions.git -b releases/2.6 \
    && git clone https://gitlab.dune-project.org/pdelab/dune-pdelab.git -b releases/2.6 \
    && git clone https://gitlab.dune-project.org/staging/dune-typetree.git -b releases/2.6 \
57
    && git clone https://gitlab.dune-project.org/quality/dune-testtools.git -b releases/2.6
58 59 60

WORKDIR /opt/dune
RUN MAKE_FLAGS="-j ${PROCNUM}" \
61
    CMAKE_FLAGS="-DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=${CC} -DCMAKE_CXX_COMPILER=${CXX} -DDUNE_PYTHON_VIRTUALENV_SETUP=True -DDUNE_PYTHON_ALLOW_GET_PIP=True" \
62
    ./dune-common/bin/dunecontrol all