From 18204b808546c6f354fabea815a0283cac46d363 Mon Sep 17 00:00:00 2001 From: zmoon Date: Mon, 6 May 2024 22:27:08 -0600 Subject: [PATCH] Try pre-built ESMF --- .github/workflows/ci.yml | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 47073ad..6aebe4e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -141,3 +141,36 @@ jobs: - name: Build run: cmake --build build + + build-with-apt-packages-nompi-archive: + name: Build (APT, no MPI, pre-built ESMF) + runs-on: ubuntu-22.04 + steps: + - name: Check out + uses: actions/checkout@v4 + with: + submodules: true + + - name: Install dependencies + run: sudo apt-get install -y libnetcdf-dev libnetcdff-dev + liblapack-dev libopenblas-dev + + - name: Fetch pre-built ESMF + run: | + v="8.3.1" # ESMF + gcc="12" + esmf_base=$HOME/esmf + + export ESMF_DIR=${esmf_base}/${v}-gcc-${gcc} + mkdir -p $ESMF_DIR + cd $esmf_base + wget https://github.com/zmoon/gha-esmf/releases/download/v0.0.4/${v}-gcc-${gcc}-mpiuni.tar.gz + tar xzvf ${v}-gcc-${gcc}-mpiuni.tar.gz --directory=/tmp && mv /tmp/${v}-gcc-${gcc}-mpiuni/* $ESMF_DIR + + echo "ESMFMKFILE=${ESMF_DIR}/lib/libO/Linux.gfortran.64.mpiuni.default/esmf.mk" >> "$GITHUB_ENV" + + - name: Configure + run: FC=gfortran-12 cmake -S . -B build + + - name: Build + run: cmake --build build