Something went wrong on our end
-
Mulas, Giacomo authoredMulas, Giacomo authored
.gitlab-ci.yml 6.18 KiB
# CI pipeline configuration
default:
image: gmulas/np-tmcode
# Switch from branch pipelines to merge request pipelines when a merge request is created
workflow:
rules:
# Ensures next rules do not block triggered pipelines
- if: $CI_COMMIT_BRANCH && $CI_OPEN_MERGE_REQUESTS && $CI_PIPELINE_SOURCE == "push"
when: never
# always run for merge requests
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
# never run a branch pipeline if there is an open merge request for that branch
- if: $CI_COMMIT_BRANCH && $CI_OPEN_MERGE_REQUESTS
when: never
# the only allowed branch pipeline is that on the default branch
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
stages:
- compatibility
- build
- run
- test
compatibility_stage:
stage: compatibility
tags: ["np-tmcode"]
allow_failure: true
artifacts:
paths:
- build/cluster/*
- build/sphere/*
- build/testing/*
- build/trapping/*
- build/libnptm/*
exclude:
- ".git*"
- ".git/**/*"
expire_in: 2 hours
script:
# bash commands to be executed
- pwd
- hostname
- echo $CI_COMMIT_SHA
- echo $CI_COMMIT_BRANCH
- echo "Getting system info ..."
- cat /etc/os-release
- cd src
- echo "Running make with gnu compilers version 11..."
- make clean && BUILDDIR=$PWD/../build_gnu11 CXX=g++-11 FC=gfortran-11 make -j
- echo "Running make with gnu compilers version 12..."
- make clean && BUILDDIR=$PWD/../build_gnu12 CXX=g++-12 FC=gfortran-12 make -j
- echo "Running make with gnu compilers version 13..."
- make clean && BUILDDIR=$PWD/../build_gnu13 CXX=g++-13 FC=gfortran-13 make -j
- echo "Running make with gnu compilers version 14..."
- make clean && BUILDDIR=$PWD/../build_gnu14 CXX=g++-14 FC=gfortran-14 make -j
- echo "Running make with flang version 16 and clang version 16..."
- make clean && BUILDDIR=$PWD/../build_clang16 CXX="clang++-16 -stdlib=libstdc++ -I/usr/include/c++/13 -I/usr/include/x86_64-linux-gnu/c++/13" FC=flang-new-16 FCFLAGS=-O3 LDFLAGS="-L/usr/lib/llvm-16/lib -L/usr/lib/gcc/x86_64-linux-gnu/13" make -j
- echo "Running make with flang version 17 and clang version 17..."
- make clean && BUILDDIR=$PWD/../build_clang17 CXX="clang++-17 -stdlib=libstdc++ -I/usr/include/c++/13 -I/usr/include/x86_64-linux-gnu/c++/13" FC=flang-new-17 FCFLAGS=-O3 LDFLAGS="-L/usr/lib/llvm-17/lib -L/usr/lib/gcc/x86_64-linux-gnu/13" make -j
- echo "Running make with Intel ifort and Intel icpx..."
- make clean && LD_LIBRARY_PATH=/opt/intel/oneapi/compiler/2024.2/lib PATH=/opt/intel/oneapi/compiler/2024.2/bin:$PATH BUILDDIR=$PWD/../build_ifort-icpx CXX=icpx FC=ifort FCFLAGS="-O3 -diag-disable=10448" make -j
- echo "Running make with Intel ifx and Intel icpx..."
- make clean && LD_LIBRARY_PATH=/opt/intel/oneapi/compiler/2024.2/lib PATH=/opt/intel/oneapi/compiler/2024.2/bin:$PATH BUILDDIR=$PWD/../build_ifx-icpx CXX=icpx FC=ifx FCFLAGS=-O3 make -j
- echo "Running make with default MPI compilers"
- make clean && BUILDDIR=$PWD/../build_mpi CXX=mpicxx FC=mpif90 USE_MPI=1 make -j
building_stage:
stage: build