Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions .github/build-ci/manifests/library-gcc.spack.yaml.j2
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
spack:
specs:
# package is defined in the workflows inputs.spack-manifest-data-pairs
# gcc_compiler_ver is defined in the standard_definitions.json data file
- cable@git.{{ ref }} +mpi library=access3
- cable@git.{{ ref }} ~mpi library=access3
packages:
gcc:
require:
- '@13.2.0'
all:
require:
- '%access_gcc'
- target=x86_64
concretizer:
unify: false
view: false
17 changes: 17 additions & 0 deletions .github/build-ci/manifests/library-intel.spack.yaml.j2
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
spack:
specs:
# package is defined in the workflows inputs.spack-manifest-data-pairs
# intel_compiler_ver is defined in the standard_definitions.json data file
- cable@git.{{ ref }} +mpi library=access3
- cable@git.{{ ref }} ~mpi library=access3
packages:
intel-oneapi-compilers-classic:
require:
- '@2021.10.0'
all:
require:
- '%access_intel'
- target=x86_64
concretizer:
unify: false
view: false
3 changes: 3 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,15 @@ jobs:
spack-manifest-path:
- .github/build-ci/manifests/gcc.spack.yaml.j2
- .github/build-ci/manifests/intel.spack.yaml.j2
- .github/build-ci/manifests/library-gcc.spack.yaml.j2
- .github/build-ci/manifests/library-intel.spack.yaml.j2
uses: access-nri/build-ci/.github/workflows/ci.yml@v3
with:
# For defaults for args not specified here (eg. spack/packages/config refs), see https://github.com/ACCESS-NRI/build-ci/blob/v3/.github/workflows/README.md
spack-manifest-path: ${{ matrix.spack-manifest-path }}
# We need to install the compilers manually here because the upstream image is too large to run on GitHub-hosted runners
spack-compiler-manifest-path: .github/build-ci/compilers/spack.yaml
access-spack-packages-ref: 1d9acf45c39229ff4e90a9aa49922b1169305476
allow-ssh-into-spack-install: false
spack-oci-buildcache-url: oci://ghcr.io/CABLE-LSM/build-ci-buildcache # https://github.com/orgs/CABLE-LSM/packages/container/package/build-ci-buildcache
# Since CABLE-LSM can't access ACCESS-NRI's self-hosted runners, we use a GitHub-hosted version
Expand Down
33 changes: 29 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -139,10 +139,6 @@ if(CABLE_LIBRARY)
src/params/cable_maths_constants_mod.F90
src/util/cable_runtime_opts_mod.F90
src/util/cable_common.F90
src/coupled/shared/cable_canopy_type_mod.F90
src/coupled/shared/cable_soilsnow_type_mod.F90
src/coupled/shared/cable_soil_type_mod.F90
src/coupled/shared/cable_veg_type_mod.F90
src/util/cable_climate_type_mod.F90
src/util/masks_cbl.F90
)
Expand All @@ -156,6 +152,10 @@ if(CABLE_LIBRARY)
src/coupled/esm/cable_pft_params_mod.F90
src/coupled/esm/casa_landuse.F90
src/coupled/esm/LAI_canopy_height_cbl.F90
src/coupled/shared/cable_canopy_type_mod.F90
src/coupled/shared/cable_soilsnow_type_mod.F90
src/coupled/shared/cable_soil_type_mod.F90
src/coupled/shared/cable_veg_type_mod.F90
)
if(CMAKE_Fortran_COMPILER_ID MATCHES "Intel")
add_compile_options(-r8 -i8)
Expand All @@ -165,6 +165,31 @@ if(CABLE_LIBRARY)
message(STATUS "Cannot compile library with unknown compiler")
endif()

elseif(CABLE_LIBRARY_TARGET STREQUAL "access3")
list(APPEND SOURCES
src/coupled/AM3/control/CM3/air_type.F90
src/coupled/AM3/control/CM3/balances_type.F90
src/coupled/AM3/control/CM3/bgc_pool_type.F90
src/coupled/AM3/control/CM3/cable_define_types.F90
src/coupled/AM3/control/CM3/cbl_canopy_type.F90
src/coupled/AM3/control/CM3/cable_cbm_mod.F90
src/coupled/AM3/control/CM3/climate_type.F90
src/coupled/AM3/control/CM3/met_type_cbl.F90
src/coupled/AM3/control/CM3/radiation_type.F90
src/coupled/AM3/control/CM3/read_cable_namelists_mod.F90
src/coupled/AM3/control/CM3/roughness_type.F90
src/coupled/AM3/control/CM3/soil_type_cbl.F90
src/coupled/AM3/control/CM3/ssnow_type.F90
src/coupled/AM3/control/CM3/sum_flux_type.F90
src/coupled/AM3/control/CM3/veg_type.F90
)
if (CMAKE_Fortran_COMPILER_ID MATCHES "Intel")
add_compile_options(-r8 -i8)
elseif(CMAKE_Fortran_COMPILER_ID MATCHES "GNU")
add_compile_options(-fdefault-real-8 -fdefault-integer-8 -fdefault-double-8)
else()
message(STATUS "Cannot compile library with unknown compiler")
endif()
else()
message(STATUS "Specified library application does not exist")
endif()
Expand Down
Loading