Commit fbff9226 authored by Lukas Riedel's avatar Lukas Riedel

Specify compiler in DUNE testing image

* Split setup CI stage into two jobs for GCC and Clang
* Add compiler (CC) as ARG in Dockerfile
* Remove dune-env-clang.dockerfile
parent d38852b0
......@@ -45,8 +45,12 @@ setup:dune-env: &setup
--build-arg PROCNUM=$CPUS_DIND
-t $DUNE_ENV_IMAGE .
- docker push $DUNE_ENV_IMAGE
- docker build -f docker/dune-env-clang.dockerfile
--build-arg DUNE_ENV_IMAGE=$DUNE_ENV_IMAGE
setup:dune-env-clang:
<<: *setup
script:
- docker build -f docker/dune-env.dockerfile
--build-arg CC=clang
--build-arg PROCNUM=$CPUS_DIND
-t ${DUNE_ENV_IMAGE}-clang .
- docker push ${DUNE_ENV_IMAGE}-clang
......
ARG DUNE_ENV_IMAGE=dorie/dune-env
FROM $DUNE_ENV_IMAGE
RUN apt-get clean && apt-get update && apt-get install -y \
clang
WORKDIR /opt/dune
# clean directories and rebuild DUNE
RUN ./dune-common/bin/dunecontrol exec "rm -rf build-cmake"
RUN MAKE_FLAGS="-j ${PROCNUM}" \
CMAKE_FLAGS="-DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DDUNE_PYTHON_VIRTUALENV_SETUP=True -DDUNE_PYTHON_ALLOW_GET_PIP=True" \
./dune-common/bin/dunecontrol all
\ No newline at end of file
......@@ -2,12 +2,13 @@ FROM ubuntu:bionic
LABEL maintainer="lriedel@iup.uni-heidelberg.de"
# number of cores for parallel builds
ARG PROCNUM=1
# C++ compiler to be installed
ARG CC=g++
RUN apt-get clean && apt-get update && apt-get install -y \
${CC} \
cmake \
doxygen \
gcc \
g++ \
gfortran \
git \
libatlas-base-dev \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment