From e4f7365f39037cc3fbff5f28b73323318d2d4e9e Mon Sep 17 00:00:00 2001 From: Tammo van der Heide Date: Fri, 6 Dec 2024 16:02:04 +0100 Subject: [PATCH] Update GitHub workflows --- .github/workflows/build.yml | 49 ++++++++++++++----------------------- 1 file changed, 19 insertions(+), 30 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 366786d..eadb894 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -107,17 +107,12 @@ jobs: os: [ubuntu-latest] mpi: [nompi] socket: [nosocket, socket] - fc: [ifort] + fc: [ifx] cc: [icx] env: FC: ${{ matrix.fc }} CC: ${{ matrix.cc }} WITH_MPI: false - APT_PACKAGES: >- - intel-oneapi-compiler-fortran - intel-oneapi-compiler-dpcpp-cpp - intel-oneapi-mkl - intel-oneapi-mkl-devel CMAKE_OPTIONS: >- -DCMAKE_BUILD_TYPE=RelWithDebInfo -DFYPP_FLAGS='-DTRAVIS' @@ -131,34 +126,28 @@ jobs: with: python-version: 3.x - - name: Add Intel repository - if: contains(matrix.os, 'ubuntu') - run: | - wget -O- https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB | gpg --dearmor | sudo tee /usr/share/keyrings/oneapi-archive-keyring.gpg > /dev/null - echo "deb [signed-by=/usr/share/keyrings/oneapi-archive-keyring.gpg] https://apt.repos.intel.com/oneapi all main" | sudo tee /etc/apt/sources.list.d/oneAPI.list - sudo apt-get update + - name: Setup Intel compiler + uses: rscohn2/setup-oneapi@v0 + with: + components: | + icx@2024.0.0 + ifx@2024.0.0 + mkl@2024.0.0 - - name: Install Intel oneAPI compiler - if: contains(matrix.os, 'ubuntu') + - name: Setup Intel environment run: | - sudo apt-get update - sudo apt-get install ${APT_PACKAGES} source /opt/intel/oneapi/setvars.sh - printenv >> $GITHUB_ENV + printenv >> ${GITHUB_ENV} + echo "FC=ifx" >> ${GITHUB_ENV} + echo "CC=icx" >> ${GITHUB_ENV} - - name: Install HDF5 (gcc) - if: contains(matrix.os, 'ubuntu') - run: | - sudo apt-get update - sudo apt-get install hdf5-tools libhdf5-dev libhdf5-103 - - - name: Install HDF5 (intel) + - name: Install HDF5 if: contains(matrix.os, 'ubuntu') run: | - wget https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-1.13/hdf5-1.13.2/src/CMake-hdf5-1.13.2.tar.gz - tar xfz CMake-hdf5-1.13.2.tar.gz - cd CMake-hdf5-1.13.2/hdf5-1.13.2/ - CC=icx CXX=icx FC=ifort F9X=ifort ./configure --prefix=${PWD}/hdf5 --enable-fortran --with-default-api-version=v110 --enable-shared + wget https://support.hdfgroup.org/releases/hdf5/v1_14/v1_14_4/downloads/hdf5-1.14.4-3.tar.gz + tar xfz hdf5-1.14.4-3.tar.gz + cd hdf5-1.14.4-3/ + CC=icx CXX=icx FC=ifx F9X=ifx ./configure --prefix=${PWD}/hdf5 --enable-fortran --enable-shared make -j -l2 make install export HDF5_ROOT=${PWD}/hdf5 @@ -169,7 +158,7 @@ jobs: if: contains(matrix.mpi, 'nompi') run: | echo "WITH_MPI=false" >> $GITHUB_ENV - echo "FC=ifort" >> $GITHUB_ENV + echo "FC=ifx" >> $GITHUB_ENV - name: Enable socket build if: contains(matrix.socket, 'socket') @@ -198,7 +187,7 @@ jobs: - name: Run regression tests run: | pushd ${BUILD_DIR} - ctest -j 2 --output-on-failure + ctest -j2 --output-on-failure popd - name: Install project