diff --git a/models/ICON/ICON.def b/models/ICON/ICON.def new file mode 100644 index 0000000000000000000000000000000000000000..eb281e4a30812b83904b0c86f6bb4a5cd947b42e --- /dev/null +++ b/models/ICON/ICON.def @@ -0,0 +1,50 @@ +BootStrap: localimage +From: /home/maximilian/ubuntu-mpi.img + +%labels + maintainer IT-IMGW <it.img-wien@univie.ac.at> + +%post +# set noninteractive installation +export DEBIAN_FRONTEND=noninteractive +# Install building tools and ICON dependencies: +apt update -y \ +&& apt install -y \ + python3 \ + libhdf5-dev \ + libnetcdf-dev \ + libnetcdff-dev \ + libeccodes-dev \ + libblas-dev \ + liblapack-dev \ + libxml2-dev + +# Select the compiler: +#update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-6 50 \ +# --slave /usr/bin/gfortran gfortran /usr/bin/gfortran-6 + +# The command above can be reverted as follows: +# sudo update-alternatives --remove gcc /usr/bin/gcc-6 + +# Select MPI libraries and compiler wrappers +# update-alternatives --set mpi /usr/include/mpich +# update-alternatives --set mpirun /usr/bin/mpirun.mpich +# update-alternatives --set mpi /usr/lib/x86_64-linux-gnu/openmpi/include +# update-alternatives --set mpirun /usr/bin/mpirun.openmpi + +# If the two non-interactive commands above do not work, +# try the interactive analogues: +# sudo update-alternatives --config mpirun +# sudo update-alternatives --config mpi + +# Install optional tools: +apt install -y ksh cdo + +# set timezone manually +ln -fs /usr/share/zoneinfo/UTC /etc/localtime +dpkg-reconfigure --frontend noninteractive tzdata + +%environment + # What do we need to build ICON? + export INCLUDE=/usr/include/x86_64-linux-gnu + export LIBRARY=/usr/lib/x86_64-linux-gnu