From 21e1505ef131389a99997d1976822c672cc3e9a8 Mon Sep 17 00:00:00 2001 From: Tommy Gatti Date: Tue, 29 Jul 2025 14:06:00 +1000 Subject: [PATCH 01/19] Add matrix-compatible build-ci --- .github/workflows/ci.yml | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 000000000..2ce232494 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,39 @@ +name: Build +on: + pull_request: + push: + branches: + - main + - CICE6.* +jobs: + pre-ci: + name: Pre-CI + runs-on: ubuntu-latest + outputs: + matrix: ${{ steps.set-matrix.outputs.matrix }} + steps: + - uses: actions/checkout@v4 + + - name: Set up matrix + id: set-matrix + # Find all relevant files under .github/build-ci/manifests + # then output them as a JSON array (minus the last comma) + run: | + files=$(find .github/build-ci/manifests/ -iname '*.j2' -printf '"%p",') + echo "matrix=[${files%,}]" >> $GITHUB_OUTPUT + + ci: + name: CI + needs: pre-ci + strategy: + fail-fast: false + max-parallel: 3 + matrix: + file: ${{ fromJson(needs.pre-ci.outputs.matrix) }} + uses: access-nri/build-ci/.github/workflows/ci.yml@v2 + with: + spack-manifest-path: ${{ matrix.file }} + allow-ssh-into-spack-install: false # If true, PR author must ssh into instance to complete job + # spack-packages-ref: main + # spack-config-ref: main + # spack-ref: releases/v0.22 From 24f268ef5b0396c9080b5e0842de2e915bfcbcfe Mon Sep 17 00:00:00 2001 From: Tommy Gatti Date: Tue, 29 Jul 2025 14:05:44 +1000 Subject: [PATCH 02/19] Add access3, no-access3 manifests --- .github/build-ci/manifests/access3.spack.yaml.j2 | 12 ++++++++++++ .../build-ci/manifests/no-access3.spack.yaml.j2 | 16 ++++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 .github/build-ci/manifests/access3.spack.yaml.j2 create mode 100644 .github/build-ci/manifests/no-access3.spack.yaml.j2 diff --git a/.github/build-ci/manifests/access3.spack.yaml.j2 b/.github/build-ci/manifests/access3.spack.yaml.j2 new file mode 100644 index 000000000..37fdf0faf --- /dev/null +++ b/.github/build-ci/manifests/access3.spack.yaml.j2 @@ -0,0 +1,12 @@ +spack: + specs: + - access-cice @git.{{ ref }} +access3 io_type=PIO %intel@2021.10.0 + - access-cice @git.{{ ref }} +access3 io_type=PIO build_type=Debug %oneapi@2025.2.0 + - access-cice @git.{{ ref }} +access3 io_type=PIO %oneapi@2025.2.0 + packages: + esmf: + require: + - '@8.6.0' + concretizer: + unify: false + view: false diff --git a/.github/build-ci/manifests/no-access3.spack.yaml.j2 b/.github/build-ci/manifests/no-access3.spack.yaml.j2 new file mode 100644 index 000000000..ff6c5669f --- /dev/null +++ b/.github/build-ci/manifests/no-access3.spack.yaml.j2 @@ -0,0 +1,16 @@ +spack: + specs: + - access-cice @git.{{ ref }} ~access3 io_type=PIO %intel@2021.10.0 + - access-cice @git.{{ ref }} ~access3 io_type=PIO +openmp %oneapi@2025.2.0 + - access-cice @git.{{ ref }} ~access3 io_type=PIO %oneapi@2025.2.0 + + - access-cice @git.{{ ref }} ~access3 io_type=NetCDF %intel@2021.10.0 + - access-cice @git.{{ ref }} ~access3 io_type=NetCDF %oneapi@2025.2.0 + + - access-cice @git.{{ ref }} ~access3 io_type=Binary %intel@2021.10.0 + - access-cice @git.{{ ref }} ~access3 io_type=Binary %oneapi@2025.2.0 + + - access-cice @git.{{ ref }} ~access3 io_type=PIO %gcc@13.2.0 + concretizer: + unify: false + view: false From 8e9624e0b909fb78bbb9a96a0f82ce07bb29de8e Mon Sep 17 00:00:00 2001 From: anton-seaice Date: Wed, 28 May 2025 09:19:07 +1000 Subject: [PATCH 03/19] add MPI components fortran and linking --- configuration/scripts/cmake/CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/configuration/scripts/cmake/CMakeLists.txt b/configuration/scripts/cmake/CMakeLists.txt index 0f4930678..3c9f0f935 100644 --- a/configuration/scripts/cmake/CMakeLists.txt +++ b/configuration/scripts/cmake/CMakeLists.txt @@ -102,7 +102,7 @@ if(CICE_ACCESS3) message(FATAL_ERROR "ESMF interface missing from Access3Share package") endif() else() - find_package(MPI REQUIRED) + find_package(MPI REQUIRED COMPONENTS Fortran) endif() if(CICE_OPENMP) @@ -130,6 +130,7 @@ set(CICE_CORE "${CMAKE_SOURCE_DIR}/../../../cicecore") set(ICEPACK "${CMAKE_SOURCE_DIR}/../../../icepack") add_fortran_library(cicelib mod STATIC) +target_link_libraries(cicelib PUBLIC MPI::MPI_Fortran) if(CICE_IO MATCHES "^(NetCDF|PIO)$") target_compile_definitions(cicelib PRIVATE FORTRANUNDERSCORE ncdf) From 1d8869e84c67dc2f2d1f4b3ed2c947024dbb5382 Mon Sep 17 00:00:00 2001 From: Tommy Gatti Date: Tue, 29 Jul 2025 14:50:08 +1000 Subject: [PATCH 04/19] Change esmf to git.8.7.0 --- .github/build-ci/manifests/access3.spack.yaml.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/build-ci/manifests/access3.spack.yaml.j2 b/.github/build-ci/manifests/access3.spack.yaml.j2 index 37fdf0faf..31bfb6210 100644 --- a/.github/build-ci/manifests/access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/access3.spack.yaml.j2 @@ -6,7 +6,7 @@ spack: packages: esmf: require: - - '@8.6.0' + - '@git.8.7.0=8.7.0' concretizer: unify: false view: false From e0499721dbd5ee653dfd8b0facd1d67a9772be39 Mon Sep 17 00:00:00 2001 From: Tommy Gatti Date: Tue, 29 Jul 2025 14:56:01 +1000 Subject: [PATCH 05/19] Prepend v to esmf requirements --- .github/build-ci/manifests/access3.spack.yaml.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/build-ci/manifests/access3.spack.yaml.j2 b/.github/build-ci/manifests/access3.spack.yaml.j2 index 31bfb6210..7f214aaaa 100644 --- a/.github/build-ci/manifests/access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/access3.spack.yaml.j2 @@ -6,7 +6,7 @@ spack: packages: esmf: require: - - '@git.8.7.0=8.7.0' + - '@git.v8.7.0=8.7.0' concretizer: unify: false view: false From fd6dba1caeef2882b181c38486afb433fe3e85c7 Mon Sep 17 00:00:00 2001 From: Tommy Gatti Date: Wed, 30 Jul 2025 08:47:11 +1000 Subject: [PATCH 06/19] Add oneapi compiler to openmpi constraints --- .github/build-ci/manifests/no-access3.spack.yaml.j2 | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/build-ci/manifests/no-access3.spack.yaml.j2 b/.github/build-ci/manifests/no-access3.spack.yaml.j2 index ff6c5669f..4dbf75e4b 100644 --- a/.github/build-ci/manifests/no-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/no-access3.spack.yaml.j2 @@ -11,6 +11,10 @@ spack: - access-cice @git.{{ ref }} ~access3 io_type=Binary %oneapi@2025.2.0 - access-cice @git.{{ ref }} ~access3 io_type=PIO %gcc@13.2.0 + packages: + openmpi: + require: + - '%oneapi@2025.2.0' concretizer: unify: false view: false From b133ff692d4e01effd098999adf7bf324a5b02c6 Mon Sep 17 00:00:00 2001 From: Tommy Gatti Date: Wed, 30 Jul 2025 10:31:32 +1000 Subject: [PATCH 07/19] Split manifests down compiler lines, update max-parallel to 5 --- .../build-ci/manifests/gcc-no-access3.spack.yaml.j2 | 10 ++++++++++ .../build-ci/manifests/intel-access3.spack.yaml.j2 | 13 +++++++++++++ .../manifests/intel-no-access3.spack.yaml.j2 | 12 ++++++++++++ ...3.spack.yaml.j2 => oneapi-access3.spack.yaml.j2} | 7 ++++++- ...pack.yaml.j2 => oneapi-no-access3.spack.yaml.j2} | 12 ++++-------- .github/workflows/ci.yml | 2 +- 6 files changed, 46 insertions(+), 10 deletions(-) create mode 100644 .github/build-ci/manifests/gcc-no-access3.spack.yaml.j2 create mode 100644 .github/build-ci/manifests/intel-access3.spack.yaml.j2 create mode 100644 .github/build-ci/manifests/intel-no-access3.spack.yaml.j2 rename .github/build-ci/manifests/{access3.spack.yaml.j2 => oneapi-access3.spack.yaml.j2} (72%) rename .github/build-ci/manifests/{no-access3.spack.yaml.j2 => oneapi-no-access3.spack.yaml.j2} (57%) diff --git a/.github/build-ci/manifests/gcc-no-access3.spack.yaml.j2 b/.github/build-ci/manifests/gcc-no-access3.spack.yaml.j2 new file mode 100644 index 000000000..a56403b87 --- /dev/null +++ b/.github/build-ci/manifests/gcc-no-access3.spack.yaml.j2 @@ -0,0 +1,10 @@ +spack: + specs: + - access-cice @git.{{ ref }} ~access3 io_type=PIO %gcc@13.2.0 + packages: + all: + require: + - '%gcc@13.2.0' + concretizer: + unify: false + view: false diff --git a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 new file mode 100644 index 000000000..046550335 --- /dev/null +++ b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 @@ -0,0 +1,13 @@ +spack: + specs: + - access-cice @git.{{ ref }} +access3 io_type=PIO %intel@2021.10.0 + packages: + esmf: + require: + - '@git.v8.7.0=8.7.0' + all: + require: + - '%intel@2021.10.0' + concretizer: + unify: false + view: false diff --git a/.github/build-ci/manifests/intel-no-access3.spack.yaml.j2 b/.github/build-ci/manifests/intel-no-access3.spack.yaml.j2 new file mode 100644 index 000000000..57ff3dff0 --- /dev/null +++ b/.github/build-ci/manifests/intel-no-access3.spack.yaml.j2 @@ -0,0 +1,12 @@ +spack: + specs: + - access-cice @git.{{ ref }} ~access3 io_type=PIO %intel@2021.10.0 + - access-cice @git.{{ ref }} ~access3 io_type=NetCDF %intel@2021.10.0 + - access-cice @git.{{ ref }} ~access3 io_type=Binary %intel@2021.10.0 + packages: + all: + require: + - '%intel@2021.10.0' + concretizer: + unify: false + view: false diff --git a/.github/build-ci/manifests/access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 similarity index 72% rename from .github/build-ci/manifests/access3.spack.yaml.j2 rename to .github/build-ci/manifests/oneapi-access3.spack.yaml.j2 index 7f214aaaa..91226476e 100644 --- a/.github/build-ci/manifests/access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 @@ -1,12 +1,17 @@ spack: specs: - - access-cice @git.{{ ref }} +access3 io_type=PIO %intel@2021.10.0 - access-cice @git.{{ ref }} +access3 io_type=PIO build_type=Debug %oneapi@2025.2.0 - access-cice @git.{{ ref }} +access3 io_type=PIO %oneapi@2025.2.0 packages: esmf: require: - '@git.v8.7.0=8.7.0' + gcc-runtime: + require: + - '%gcc@13.2.0' + all: + require: + - '%oneapi@2025.2.0' concretizer: unify: false view: false diff --git a/.github/build-ci/manifests/no-access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 similarity index 57% rename from .github/build-ci/manifests/no-access3.spack.yaml.j2 rename to .github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 index 4dbf75e4b..fccbbad42 100644 --- a/.github/build-ci/manifests/no-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 @@ -1,18 +1,14 @@ spack: specs: - - access-cice @git.{{ ref }} ~access3 io_type=PIO %intel@2021.10.0 - access-cice @git.{{ ref }} ~access3 io_type=PIO +openmp %oneapi@2025.2.0 - access-cice @git.{{ ref }} ~access3 io_type=PIO %oneapi@2025.2.0 - - - access-cice @git.{{ ref }} ~access3 io_type=NetCDF %intel@2021.10.0 - access-cice @git.{{ ref }} ~access3 io_type=NetCDF %oneapi@2025.2.0 - - - access-cice @git.{{ ref }} ~access3 io_type=Binary %intel@2021.10.0 - access-cice @git.{{ ref }} ~access3 io_type=Binary %oneapi@2025.2.0 - - - access-cice @git.{{ ref }} ~access3 io_type=PIO %gcc@13.2.0 packages: - openmpi: + gcc-runtime: + require: + - '%gcc@13.2.0' + all: require: - '%oneapi@2025.2.0' concretizer: diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2ce232494..60ba21dde 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -27,7 +27,7 @@ jobs: needs: pre-ci strategy: fail-fast: false - max-parallel: 3 + max-parallel: 5 matrix: file: ${{ fromJson(needs.pre-ci.outputs.matrix) }} uses: access-nri/build-ci/.github/workflows/ci.yml@v2 From 160b8fcf4c37dc13f5b5306cc8415c0a93628856 Mon Sep 17 00:00:00 2001 From: Tommy Gatti Date: Wed, 30 Jul 2025 10:35:58 +1000 Subject: [PATCH 08/19] Apply suggestions from code review Co-authored-by: Anton Steketee <79179784+anton-seaice@users.noreply.github.com> --- .github/build-ci/manifests/oneapi-access3.spack.yaml.j2 | 2 +- .github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 index 91226476e..237146cea 100644 --- a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 @@ -8,7 +8,7 @@ spack: - '@git.v8.7.0=8.7.0' gcc-runtime: require: - - '%gcc@13.2.0' + - '%gcc' all: require: - '%oneapi@2025.2.0' diff --git a/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 index fccbbad42..9fad6fa0a 100644 --- a/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 @@ -7,7 +7,7 @@ spack: packages: gcc-runtime: require: - - '%gcc@13.2.0' + - '%gcc' all: require: - '%oneapi@2025.2.0' From a9171fad1cf5a24a86b53524b3c56508fcd5b844 Mon Sep 17 00:00:00 2001 From: Tommy Gatti Date: Wed, 30 Jul 2025 11:00:33 +1000 Subject: [PATCH 09/19] Specify target explicitly so it caches better --- .../build-ci/manifests/gcc-no-access3.spack.yaml.j2 | 4 ++-- .../build-ci/manifests/intel-access3.spack.yaml.j2 | 4 ++-- .../manifests/intel-no-access3.spack.yaml.j2 | 8 ++++---- .../build-ci/manifests/oneapi-access3.spack.yaml.j2 | 8 ++++---- .../manifests/oneapi-no-access3.spack.yaml.j2 | 12 ++++++------ 5 files changed, 18 insertions(+), 18 deletions(-) diff --git a/.github/build-ci/manifests/gcc-no-access3.spack.yaml.j2 b/.github/build-ci/manifests/gcc-no-access3.spack.yaml.j2 index a56403b87..ac4667784 100644 --- a/.github/build-ci/manifests/gcc-no-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/gcc-no-access3.spack.yaml.j2 @@ -1,10 +1,10 @@ spack: specs: - - access-cice @git.{{ ref }} ~access3 io_type=PIO %gcc@13.2.0 + - access-cice @git.{{ ref }} ~access3 io_type=PIO %gcc@13.2.0 target=x86_64 packages: all: require: - - '%gcc@13.2.0' + - '%gcc@13.2.0 target=x86_64' concretizer: unify: false view: false diff --git a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 index 046550335..71b6e24f9 100644 --- a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 @@ -1,13 +1,13 @@ spack: specs: - - access-cice @git.{{ ref }} +access3 io_type=PIO %intel@2021.10.0 + - access-cice @git.{{ ref }} +access3 io_type=PIO %intel@2021.10.0 target=x86_64 packages: esmf: require: - '@git.v8.7.0=8.7.0' all: require: - - '%intel@2021.10.0' + - '%intel@2021.10.0 target=x86_64' concretizer: unify: false view: false diff --git a/.github/build-ci/manifests/intel-no-access3.spack.yaml.j2 b/.github/build-ci/manifests/intel-no-access3.spack.yaml.j2 index 57ff3dff0..8a37bbaa7 100644 --- a/.github/build-ci/manifests/intel-no-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/intel-no-access3.spack.yaml.j2 @@ -1,12 +1,12 @@ spack: specs: - - access-cice @git.{{ ref }} ~access3 io_type=PIO %intel@2021.10.0 - - access-cice @git.{{ ref }} ~access3 io_type=NetCDF %intel@2021.10.0 - - access-cice @git.{{ ref }} ~access3 io_type=Binary %intel@2021.10.0 + - access-cice @git.{{ ref }} ~access3 io_type=PIO %intel@2021.10.0 target=x86_64 + - access-cice @git.{{ ref }} ~access3 io_type=NetCDF %intel@2021.10.0 target=x86_64 + - access-cice @git.{{ ref }} ~access3 io_type=Binary %intel@2021.10.0 target=x86_64 packages: all: require: - - '%intel@2021.10.0' + - '%intel@2021.10.0 target=x86_64' concretizer: unify: false view: false diff --git a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 index 237146cea..61ca66a97 100644 --- a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 @@ -1,17 +1,17 @@ spack: specs: - - access-cice @git.{{ ref }} +access3 io_type=PIO build_type=Debug %oneapi@2025.2.0 - - access-cice @git.{{ ref }} +access3 io_type=PIO %oneapi@2025.2.0 + - access-cice @git.{{ ref }} +access3 io_type=PIO build_type=Debug %oneapi@2025.2.0 target=x86_64 + - access-cice @git.{{ ref }} +access3 io_type=PIO %oneapi@2025.2.0 target=x86_64 packages: esmf: require: - '@git.v8.7.0=8.7.0' gcc-runtime: require: - - '%gcc' + - '%gcc target=x86_64' all: require: - - '%oneapi@2025.2.0' + - '%oneapi@2025.2.0 target=x86_64' concretizer: unify: false view: false diff --git a/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 index 9fad6fa0a..f1c758bfe 100644 --- a/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 @@ -1,16 +1,16 @@ spack: specs: - - access-cice @git.{{ ref }} ~access3 io_type=PIO +openmp %oneapi@2025.2.0 - - access-cice @git.{{ ref }} ~access3 io_type=PIO %oneapi@2025.2.0 - - access-cice @git.{{ ref }} ~access3 io_type=NetCDF %oneapi@2025.2.0 - - access-cice @git.{{ ref }} ~access3 io_type=Binary %oneapi@2025.2.0 + - access-cice @git.{{ ref }} ~access3 io_type=PIO +openmp %oneapi@2025.2.0 target=x86_64 + - access-cice @git.{{ ref }} ~access3 io_type=PIO %oneapi@2025.2.0 target=x86_64 + - access-cice @git.{{ ref }} ~access3 io_type=NetCDF %oneapi@2025.2.0 target=x86_64 + - access-cice @git.{{ ref }} ~access3 io_type=Binary %oneapi@2025.2.0 target=x86_64 packages: gcc-runtime: require: - - '%gcc' + - '%gcc target=x86_64' all: require: - - '%oneapi@2025.2.0' + - '%oneapi@2025.2.0 target=x86_64' concretizer: unify: false view: false From b2811199c49a995786caffc47da2d5fbb00d4992 Mon Sep 17 00:00:00 2001 From: Anton Steketee <79179784+anton-seaice@users.noreply.github.com> Date: Wed, 30 Jul 2025 13:04:05 +1000 Subject: [PATCH 10/19] Try setting FORTRANUNDERSCORE --- configuration/scripts/cmake/CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/configuration/scripts/cmake/CMakeLists.txt b/configuration/scripts/cmake/CMakeLists.txt index 3c9f0f935..7d5b18423 100644 --- a/configuration/scripts/cmake/CMakeLists.txt +++ b/configuration/scripts/cmake/CMakeLists.txt @@ -130,10 +130,11 @@ set(CICE_CORE "${CMAKE_SOURCE_DIR}/../../../cicecore") set(ICEPACK "${CMAKE_SOURCE_DIR}/../../../icepack") add_fortran_library(cicelib mod STATIC) +target_compile_definitions(cicelib PRIVATE FORTRANUNDERSCORE) target_link_libraries(cicelib PUBLIC MPI::MPI_Fortran) if(CICE_IO MATCHES "^(NetCDF|PIO)$") - target_compile_definitions(cicelib PRIVATE FORTRANUNDERSCORE ncdf) + target_compile_definitions(cicelib PRIVATE ncdf) target_compile_definitions(cicelib PRIVATE USE_NETCDF) endif() if(CICE_ACCESS3) From 672529f721399589a0db1fc8ad0b89712feb66b3 Mon Sep 17 00:00:00 2001 From: Tommy Gatti Date: Thu, 31 Jul 2025 13:14:17 +1000 Subject: [PATCH 11/19] Replace compiler, target with template vars --- .github/build-ci/data/standard.json | 6 ++++++ .../build-ci/manifests/gcc-no-access3.spack.yaml.j2 | 4 ++-- .../build-ci/manifests/intel-access3.spack.yaml.j2 | 4 ++-- .../manifests/intel-no-access3.spack.yaml.j2 | 8 ++++---- .../build-ci/manifests/oneapi-access3.spack.yaml.j2 | 8 ++++---- .../manifests/oneapi-no-access3.spack.yaml.j2 | 12 ++++++------ .github/workflows/ci.yml | 1 + 7 files changed, 25 insertions(+), 18 deletions(-) create mode 100644 .github/build-ci/data/standard.json diff --git a/.github/build-ci/data/standard.json b/.github/build-ci/data/standard.json new file mode 100644 index 000000000..3aa9594d9 --- /dev/null +++ b/.github/build-ci/data/standard.json @@ -0,0 +1,6 @@ +{ + "gcc_compiler": "gcc@13.2.0", + "intel_compiler": "intel@2021.10.0", + "oneapi_compiler": "oneapi@2025.2.0", + "target": "x86_64" +} diff --git a/.github/build-ci/manifests/gcc-no-access3.spack.yaml.j2 b/.github/build-ci/manifests/gcc-no-access3.spack.yaml.j2 index ac4667784..efdb30782 100644 --- a/.github/build-ci/manifests/gcc-no-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/gcc-no-access3.spack.yaml.j2 @@ -1,10 +1,10 @@ spack: specs: - - access-cice @git.{{ ref }} ~access3 io_type=PIO %gcc@13.2.0 target=x86_64 + - access-cice @git.{{ ref }} ~access3 io_type=PIO packages: all: require: - - '%gcc@13.2.0 target=x86_64' + - '%{{ gcc_compiler }} target={{ target}}' concretizer: unify: false view: false diff --git a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 index 71b6e24f9..791af2fc0 100644 --- a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 @@ -1,13 +1,13 @@ spack: specs: - - access-cice @git.{{ ref }} +access3 io_type=PIO %intel@2021.10.0 target=x86_64 + - access-cice @git.{{ ref }} +access3 io_type=PIO packages: esmf: require: - '@git.v8.7.0=8.7.0' all: require: - - '%intel@2021.10.0 target=x86_64' + - '%{{ intel_compiler }} target={{ target }}' concretizer: unify: false view: false diff --git a/.github/build-ci/manifests/intel-no-access3.spack.yaml.j2 b/.github/build-ci/manifests/intel-no-access3.spack.yaml.j2 index 8a37bbaa7..3bb5a6f42 100644 --- a/.github/build-ci/manifests/intel-no-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/intel-no-access3.spack.yaml.j2 @@ -1,12 +1,12 @@ spack: specs: - - access-cice @git.{{ ref }} ~access3 io_type=PIO %intel@2021.10.0 target=x86_64 - - access-cice @git.{{ ref }} ~access3 io_type=NetCDF %intel@2021.10.0 target=x86_64 - - access-cice @git.{{ ref }} ~access3 io_type=Binary %intel@2021.10.0 target=x86_64 + - access-cice @git.{{ ref }} ~access3 io_type=PIO + - access-cice @git.{{ ref }} ~access3 io_type=NetCDF + - access-cice @git.{{ ref }} ~access3 io_type=Binary packages: all: require: - - '%intel@2021.10.0 target=x86_64' + - '%{{ intel_compiler }} target={{ target }}' concretizer: unify: false view: false diff --git a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 index 61ca66a97..990bd3ddb 100644 --- a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 @@ -1,17 +1,17 @@ spack: specs: - - access-cice @git.{{ ref }} +access3 io_type=PIO build_type=Debug %oneapi@2025.2.0 target=x86_64 - - access-cice @git.{{ ref }} +access3 io_type=PIO %oneapi@2025.2.0 target=x86_64 + - access-cice @git.{{ ref }} +access3 io_type=PIO build_type=Debug + - access-cice @git.{{ ref }} +access3 io_type=PIO packages: esmf: require: - '@git.v8.7.0=8.7.0' gcc-runtime: require: - - '%gcc target=x86_64' + - '%gcc target={{ target }}' all: require: - - '%oneapi@2025.2.0 target=x86_64' + - '%{{ oneapi_compiler }} target={{ target }}' concretizer: unify: false view: false diff --git a/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 index f1c758bfe..dfe967b29 100644 --- a/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-no-access3.spack.yaml.j2 @@ -1,16 +1,16 @@ spack: specs: - - access-cice @git.{{ ref }} ~access3 io_type=PIO +openmp %oneapi@2025.2.0 target=x86_64 - - access-cice @git.{{ ref }} ~access3 io_type=PIO %oneapi@2025.2.0 target=x86_64 - - access-cice @git.{{ ref }} ~access3 io_type=NetCDF %oneapi@2025.2.0 target=x86_64 - - access-cice @git.{{ ref }} ~access3 io_type=Binary %oneapi@2025.2.0 target=x86_64 + - access-cice @git.{{ ref }} ~access3 io_type=PIO +openmp + - access-cice @git.{{ ref }} ~access3 io_type=PIO + - access-cice @git.{{ ref }} ~access3 io_type=NetCDF + - access-cice @git.{{ ref }} ~access3 io_type=Binary packages: gcc-runtime: require: - - '%gcc target=x86_64' + - '%gcc target={{ target }}' all: require: - - '%oneapi@2025.2.0 target=x86_64' + - '%{{ oneapi_compiler }} target={{ target }}' concretizer: unify: false view: false diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 60ba21dde..00c2966b2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -34,6 +34,7 @@ jobs: with: spack-manifest-path: ${{ matrix.file }} allow-ssh-into-spack-install: false # If true, PR author must ssh into instance to complete job + spack-manifest-data-path: .github/build-ci/data/standard.json # spack-packages-ref: main # spack-config-ref: main # spack-ref: releases/v0.22 From 0caddeae13b130e601b6aa791b1a668b846f4f8c Mon Sep 17 00:00:00 2001 From: Tommy Gatti Date: Thu, 31 Jul 2025 13:19:50 +1000 Subject: [PATCH 12/19] Exclude `[intel|oneapi]-access3.spack.yaml.j2` manifests from matrix pending fix --- .github/workflows/ci.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 00c2966b2..972d4682c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -30,6 +30,10 @@ jobs: max-parallel: 5 matrix: file: ${{ fromJson(needs.pre-ci.outputs.matrix) }} + # TODO: Remove once the underlying issue with these manifests are resolved + exclude: + - file: .github/build-ci/manifests/intel-access3.spack.yaml.j2 + - file: .github/build-ci/manifests/oneapi-access3.spack.yaml.j2 uses: access-nri/build-ci/.github/workflows/ci.yml@v2 with: spack-manifest-path: ${{ matrix.file }} From 75fffaa61261afe0a4e9e10053829cf87cd88970 Mon Sep 17 00:00:00 2001 From: anton-seaice Date: Thu, 31 Jul 2025 16:15:47 +1000 Subject: [PATCH 13/19] with access3 with explicit linking --- .github/build-ci/manifests/intel-access3.spack.yaml.j2 | 3 +++ .github/build-ci/manifests/oneapi-access3.spack.yaml.j2 | 3 +++ .github/workflows/ci.yml | 4 ---- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 index 791af2fc0..80af7e74f 100644 --- a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 @@ -2,6 +2,9 @@ spack: specs: - access-cice @git.{{ ref }} +access3 io_type=PIO packages: + access3-share: + require: + - '@git.9158ee74be1ab75249c8d6a3f9d45e8d943318d2' esmf: require: - '@git.v8.7.0=8.7.0' diff --git a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 index 990bd3ddb..14f2f2ecb 100644 --- a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 @@ -3,6 +3,9 @@ spack: - access-cice @git.{{ ref }} +access3 io_type=PIO build_type=Debug - access-cice @git.{{ ref }} +access3 io_type=PIO packages: + access3-share: + require: + - '@git.9158ee74be1ab75249c8d6a3f9d45e8d943318d2' esmf: require: - '@git.v8.7.0=8.7.0' diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 972d4682c..00c2966b2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -30,10 +30,6 @@ jobs: max-parallel: 5 matrix: file: ${{ fromJson(needs.pre-ci.outputs.matrix) }} - # TODO: Remove once the underlying issue with these manifests are resolved - exclude: - - file: .github/build-ci/manifests/intel-access3.spack.yaml.j2 - - file: .github/build-ci/manifests/oneapi-access3.spack.yaml.j2 uses: access-nri/build-ci/.github/workflows/ci.yml@v2 with: spack-manifest-path: ${{ matrix.file }} From fc8a3b29e82854e070ad82e48961557fad7655d2 Mon Sep 17 00:00:00 2001 From: anton-seaice Date: Thu, 31 Jul 2025 16:46:26 +1000 Subject: [PATCH 14/19] trying linking mpi earlier --- .github/build-ci/manifests/intel-access3.spack.yaml.j2 | 2 +- .github/build-ci/manifests/oneapi-access3.spack.yaml.j2 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 index 80af7e74f..551e8b704 100644 --- a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 @@ -4,7 +4,7 @@ spack: packages: access3-share: require: - - '@git.9158ee74be1ab75249c8d6a3f9d45e8d943318d2' + - '@git.b060f1394e25b07bd8f2b05b917907f33da855cc' esmf: require: - '@git.v8.7.0=8.7.0' diff --git a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 index 14f2f2ecb..cab3d4388 100644 --- a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 @@ -5,7 +5,7 @@ spack: packages: access3-share: require: - - '@git.9158ee74be1ab75249c8d6a3f9d45e8d943318d2' + - '@git.b060f1394e25b07bd8f2b05b917907f33da855cc' esmf: require: - '@git.v8.7.0=8.7.0' From 4df78fdee8b5baaec6878687bfe058f5229b3b78 Mon Sep 17 00:00:00 2001 From: Anton Steketee <79179784+anton-seaice@users.noreply.github.com> Date: Fri, 1 Aug 2025 08:35:11 +1000 Subject: [PATCH 15/19] Update access3-share git ref again --- .github/build-ci/manifests/intel-access3.spack.yaml.j2 | 2 +- .github/build-ci/manifests/oneapi-access3.spack.yaml.j2 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 index 551e8b704..26e29b81a 100644 --- a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 @@ -4,7 +4,7 @@ spack: packages: access3-share: require: - - '@git.b060f1394e25b07bd8f2b05b917907f33da855cc' + - '@git.9667965070160ca671d194e20825575195ca94c7' esmf: require: - '@git.v8.7.0=8.7.0' diff --git a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 index cab3d4388..4e10def6d 100644 --- a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 @@ -5,7 +5,7 @@ spack: packages: access3-share: require: - - '@git.b060f1394e25b07bd8f2b05b917907f33da855cc' + - '@git.9667965070160ca671d194e20825575195ca94c7' esmf: require: - '@git.v8.7.0=8.7.0' From e1a97e2750561ec2bcd779159f696c7083ad74f3 Mon Sep 17 00:00:00 2001 From: Anton Steketee <79179784+anton-seaice@users.noreply.github.com> Date: Fri, 1 Aug 2025 08:47:51 +1000 Subject: [PATCH 16/19] export mpi from access3-share --- .github/build-ci/manifests/intel-access3.spack.yaml.j2 | 2 +- .github/build-ci/manifests/oneapi-access3.spack.yaml.j2 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 index 26e29b81a..4f18f28c1 100644 --- a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 @@ -4,7 +4,7 @@ spack: packages: access3-share: require: - - '@git.9667965070160ca671d194e20825575195ca94c7' + - '@git.36a8a9e75267f2c20734818519ce1829dbdd3074' esmf: require: - '@git.v8.7.0=8.7.0' diff --git a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 index 4e10def6d..6ba8c9c99 100644 --- a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 @@ -5,7 +5,7 @@ spack: packages: access3-share: require: - - '@git.9667965070160ca671d194e20825575195ca94c7' + - '@git.36a8a9e75267f2c20734818519ce1829dbdd3074' esmf: require: - '@git.v8.7.0=8.7.0' From 3e857c70f9abbf5cabfb35c1c43146da107a01ac Mon Sep 17 00:00:00 2001 From: Anton Steketee <79179784+anton-seaice@users.noreply.github.com> Date: Fri, 1 Aug 2025 14:59:36 +1000 Subject: [PATCH 17/19] Update to better fixes for versioning and mpi linking ! --- .github/build-ci/manifests/intel-access3.spack.yaml.j2 | 5 +---- .github/build-ci/manifests/oneapi-access3.spack.yaml.j2 | 5 +---- .github/workflows/ci.yml | 4 ++-- 3 files changed, 4 insertions(+), 10 deletions(-) diff --git a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 index 4f18f28c1..aabde6b97 100644 --- a/.github/build-ci/manifests/intel-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/intel-access3.spack.yaml.j2 @@ -4,10 +4,7 @@ spack: packages: access3-share: require: - - '@git.36a8a9e75267f2c20734818519ce1829dbdd3074' - esmf: - require: - - '@git.v8.7.0=8.7.0' + - '@2025.03.2:' #needs https://github.com/ACCESS-NRI/access3-share/pull/9 to work on github runner all: require: - '%{{ intel_compiler }} target={{ target }}' diff --git a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 index 6ba8c9c99..51674c80b 100644 --- a/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 +++ b/.github/build-ci/manifests/oneapi-access3.spack.yaml.j2 @@ -5,10 +5,7 @@ spack: packages: access3-share: require: - - '@git.36a8a9e75267f2c20734818519ce1829dbdd3074' - esmf: - require: - - '@git.v8.7.0=8.7.0' + - '@2025.03.2:' #needs https://github.com/ACCESS-NRI/access3-share/pull/9 to work on github runner gcc-runtime: require: - '%gcc target={{ target }}' diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 00c2966b2..b27e7dbd3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,6 +35,6 @@ jobs: spack-manifest-path: ${{ matrix.file }} allow-ssh-into-spack-install: false # If true, PR author must ssh into instance to complete job spack-manifest-data-path: .github/build-ci/data/standard.json - # spack-packages-ref: main + spack-packages-ref: 498242a86ca5db015403ef80fc0161e44d41223c # spack-config-ref: main - # spack-ref: releases/v0.22 + # spack-ref: 7d18920bf93312a3d9ce3c563acf11e7eaddfd1f From c072d67371408274921859fcc370379f83f9c214 Mon Sep 17 00:00:00 2001 From: Anton Steketee <79179784+anton-seaice@users.noreply.github.com> Date: Fri, 1 Aug 2025 15:45:50 +1000 Subject: [PATCH 18/19] Friday afternoons ? --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b27e7dbd3..cb95e8a9b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -37,4 +37,4 @@ jobs: spack-manifest-data-path: .github/build-ci/data/standard.json spack-packages-ref: 498242a86ca5db015403ef80fc0161e44d41223c # spack-config-ref: main - # spack-ref: 7d18920bf93312a3d9ce3c563acf11e7eaddfd1f + spack-ref: 7d18920bf93312a3d9ce3c563acf11e7eaddfd1f From 61f2c059eeb2a413a788046236878d171952d44b Mon Sep 17 00:00:00 2001 From: Anton Steketee <79179784+anton-seaice@users.noreply.github.com> Date: Mon, 4 Aug 2025 13:10:36 +1000 Subject: [PATCH 19/19] return to spack main --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cb95e8a9b..e9eaae839 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -37,4 +37,4 @@ jobs: spack-manifest-data-path: .github/build-ci/data/standard.json spack-packages-ref: 498242a86ca5db015403ef80fc0161e44d41223c # spack-config-ref: main - spack-ref: 7d18920bf93312a3d9ce3c563acf11e7eaddfd1f + # spack-ref: main