-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Renamed access-om3 -> access-om3-nuopc, access-om3-virtual -> access-…
…om3 (#94)
- Loading branch information
Showing
3 changed files
with
114 additions
and
114 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other | ||
# Spack Project Developers. See the top-level COPYRIGHT file for details. | ||
# | ||
# SPDX-License-Identifier: (Apache-2.0 OR MIT) | ||
|
||
from spack.package import CMakePackage, variant, version | ||
|
||
|
||
class AccessOm3Nuopc(CMakePackage): | ||
"""ACCESS-OM3 global ocean-sea ice-wave coupled model.""" | ||
|
||
homepage = "https://www.github.com/COSIMA/access-om3" | ||
git = "https://github.com/COSIMA/access-om3.git" | ||
|
||
maintainers = ["micaeljtoliveira", "aekiss"] | ||
|
||
version("main", branch="main", submodules=True) | ||
|
||
variant( | ||
"build_type", | ||
default="Release", | ||
description="The build type to build", | ||
values=("Debug", "Release"), | ||
) | ||
variant( | ||
"configurations", | ||
default="MOM6-CICE6, CICE6-WW3, MOM6-CICE6-WW3", | ||
values=( | ||
"MOM6", | ||
"CICE6", | ||
"WW3", | ||
"MOM6-WW3", | ||
"MOM6-CICE6", | ||
"CICE6-WW3", | ||
"MOM6-CICE6-WW3", | ||
), | ||
multi=True, | ||
description="ACCESS-OM3 configurations to build", | ||
) | ||
variant( | ||
"install_libraries", | ||
default=False, | ||
description="Install component libraries" | ||
) | ||
variant("openmp", default=False, description="Enable OpenMP") | ||
variant("mom_symmetric", default=False, description="Use symmetric memory in MOM6") | ||
variant( | ||
"cice_io", | ||
default="PIO", | ||
description="CICE IO option", | ||
values=("NectCDF", "PIO", "Binary"), | ||
multi=False, | ||
) | ||
|
||
depends_on("[email protected]:", type="build") | ||
depends_on("mpi") | ||
depends_on("[email protected]:") | ||
depends_on("[email protected]:") | ||
depends_on("[email protected]:") | ||
depends_on("[email protected]:") | ||
depends_on("[email protected]:") | ||
|
||
flag_handler = CMakePackage.build_system_flags | ||
|
||
def cmake_args(self): | ||
args = [ | ||
self.define_from_variant("OM3_MOM_SYMMETRIC", "mom_symmetric"), | ||
self.define_from_variant("OM3_LIB_INSTALL", "install_libraries"), | ||
self.define_from_variant("OM3_OPENMP", "openmp"), | ||
self.define( | ||
"OM3_ENABLE_MOM6", "configurations=MOM6" in self.spec | ||
), | ||
self.define( | ||
"OM3_ENABLE_CICE6", "configurations=CICE6" in self.spec | ||
), | ||
self.define( | ||
"OM3_ENABLE_WW3", "configurations=WW3" in self.spec | ||
), | ||
self.define( | ||
"OM3_ENABLE_MOM6-WW3", "configurations=MOM6-WW3" in self.spec | ||
), | ||
self.define( | ||
"OM3_ENABLE_MOM6-CICE6", "configurations=MOM6-CICE6" in self.spec | ||
), | ||
self.define( | ||
"OM3_ENABLE_CICE6-WW3", "configurations=CICE6-WW3" in self.spec | ||
), | ||
self.define( | ||
"OM3_ENABLE_MOM6-CICE6-WW3", | ||
"configurations=MOM6-CICE6-WW3" in self.spec | ||
), | ||
] | ||
|
||
args.append(self.define("CMAKE_C_COMPILER", self.spec["mpi"].mpicc)) | ||
args.append(self.define("CMAKE_CXX_COMPILER", self.spec["mpi"].mpicxx)) | ||
args.append(self.define("CMAKE_Fortran_COMPILER", self.spec["mpi"].mpifc)) | ||
|
||
return args |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,98 +1,28 @@ | ||
# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other | ||
# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other | ||
# Spack Project Developers. See the top-level COPYRIGHT file for details. | ||
# | ||
# Copyright 2024 ACCESS-NRI | ||
# | ||
# SPDX-License-Identifier: (Apache-2.0 OR MIT) | ||
|
||
from spack.package import CMakePackage, variant | ||
|
||
|
||
class AccessOm3(CMakePackage): | ||
"""ACCESS-OM3 global ocean-sea ice-wave coupled model.""" | ||
|
||
homepage = "https://www.github.com/COSIMA/access-om3" | ||
git = "https://github.com/COSIMA/access-om3.git" | ||
from spack.package import BundlePackage, version, depends_on | ||
|
||
maintainers = ["micaeljtoliveira", "aekiss"] | ||
|
||
version("main", branch="main", submodules=True) | ||
class AccessOm3(BundlePackage): | ||
""" | ||
ACCESS-OM3 bundle containing the ACCESS-OM3 Package. | ||
variant( | ||
"build_type", | ||
default="Release", | ||
description="The build type to build", | ||
values=("Debug", "Release"), | ||
) | ||
variant( | ||
"configurations", | ||
default="MOM6-CICE6, CICE6-WW3, MOM6-CICE6-WW3", | ||
values=( | ||
"MOM6", | ||
"CICE6", | ||
"WW3", | ||
"MOM6-WW3", | ||
"MOM6-CICE6", | ||
"CICE6-WW3", | ||
"MOM6-CICE6-WW3", | ||
), | ||
multi=True, | ||
description="ACCESS-OM3 configurations to build", | ||
) | ||
variant( | ||
"install_libraries", | ||
default=False, | ||
description="Install component libraries" | ||
) | ||
variant("openmp", default=False, description="Enable OpenMP") | ||
variant("mom_symmetric", default=False, description="Use symmetric memory in MOM6") | ||
variant( | ||
"cice_io", | ||
default="PIO", | ||
description="CICE IO option", | ||
values=("NectCDF", "PIO", "Binary"), | ||
multi=False, | ||
) | ||
This is used to version the entirety of a released deployment, including | ||
the package, it's dependencies, and the version of | ||
spack-packages/spack-config that it is bundled with | ||
""" | ||
|
||
depends_on("[email protected]:", type="build") | ||
depends_on("mpi") | ||
depends_on("[email protected]:") | ||
depends_on("[email protected]:") | ||
depends_on("[email protected]:") | ||
depends_on("[email protected]:") | ||
depends_on("[email protected]:") | ||
homepage = "https://www.access-nri.org.au" | ||
|
||
flag_handler = CMakePackage.build_system_flags | ||
git = "https://github.com/ACCESS-NRI/ACCESS-OM3.git" | ||
|
||
def cmake_args(self): | ||
args = [ | ||
self.define_from_variant("OM3_MOM_SYMMETRIC", "mom_symmetric"), | ||
self.define_from_variant("OM3_LIB_INSTALL", "install_libraries"), | ||
self.define_from_variant("OM3_OPENMP", "openmp"), | ||
self.define( | ||
"OM3_ENABLE_MOM6", "configurations=MOM6" in self.spec | ||
), | ||
self.define( | ||
"OM3_ENABLE_CICE6", "configurations=CICE6" in self.spec | ||
), | ||
self.define( | ||
"OM3_ENABLE_WW3", "configurations=WW3" in self.spec | ||
), | ||
self.define( | ||
"OM3_ENABLE_MOM6-WW3", "configurations=MOM6-WW3" in self.spec | ||
), | ||
self.define( | ||
"OM3_ENABLE_MOM6-CICE6", "configurations=MOM6-CICE6" in self.spec | ||
), | ||
self.define( | ||
"OM3_ENABLE_CICE6-WW3", "configurations=CICE6-WW3" in self.spec | ||
), | ||
self.define( | ||
"OM3_ENABLE_MOM6-CICE6-WW3", | ||
"configurations=MOM6-CICE6-WW3" in self.spec | ||
), | ||
] | ||
maintainers = ["harshula"] | ||
|
||
args.append(self.define("CMAKE_C_COMPILER", self.spec["mpi"].mpicc)) | ||
args.append(self.define("CMAKE_CXX_COMPILER", self.spec["mpi"].mpicxx)) | ||
args.append(self.define("CMAKE_Fortran_COMPILER", self.spec["mpi"].mpifc)) | ||
version("latest") | ||
|
||
return args | ||
depends_on("access-om3-cmake") |