Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updates required to build using ufs_utils on NOAA CSP AWS PW. #833

9 changes: 8 additions & 1 deletion build_all.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ set -eux

target=${target:-"NULL"}
compiler=${compiler:-"intel"}
PW_CSP=${PW_CSP:-} # TODO: This is an implementation from EPIC and consistent with the UFS WM build system.
GeorgeGayno-NOAA marked this conversation as resolved.
Show resolved Hide resolved
export MOD_PATH

if [[ "$target" == "linux.*" || "$target" == "macosx.*" ]]; then
Expand All @@ -20,7 +21,13 @@ if [[ "$target" == "linux.*" || "$target" == "macosx.*" ]]; then
else
set +x
source ./sorc/machine-setup.sh
module use ./modulefiles
if [[ "${target}" == "noaacloud" ]]; then
#TODO: This will need to be revisited once the EPIC supported-stacks come online.
#TODO: This is a hack due to how the spack-stack module files are generated; there may be a better way to do this.
source /contrib/global-workflow/spack-stack/envs/spack_2021.0.3.env
else
module use ./modulefiles
fi
module load build.$target.$compiler > /dev/null
module list
set -x
Expand Down
59 changes: 59 additions & 0 deletions modulefiles/build.noaacloud.intel.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
help([[
Load environment to compile UFS_UTILS on NOAA CSPs using Intel
]])

cmake_ver=os.getenv("cmake_ver") or "3.16.1"
load(pathJoin("cmake", cmake_ver))

hpc_intel_ver=os.getenv("hpc_intel_ver") or "2021.3.0"
load(pathJoin("intel", hpc_intel_ver))

impi_ver=os.getenv("impi_ver") or "2021.3.0"
load(pathJoin("impi", impi_ver))

bacio_ver=os.getenv("bacio_ver") or "2.4.1"
load(pathJoin("bacio", bacio_ver))

g2_ver=os.getenv("g2_ver") or "3.4.5"
load(pathJoin("g2", g2_ver))

ip_ver=os.getenv("ip_ver") or "4.0.0"
load(pathJoin("ip", ip_ver))

nemsio_ver=os.getenv("nemsio_ver") or "2.5.4"
load(pathJoin("nemsio", nemsio_ver))

sp_ver=os.getenv("sp_ver") or "2.3.3"
load(pathJoin("sp", sp_ver))

w3emc_ver=os.getenv("w3emc_ver") or "2.9.2"
load(pathJoin("w3emc", w3emc_ver))

sfcio_ver=os.getenv("sfcio_ver") or "1.4.1"
load(pathJoin("sfcio", sfcio_ver))

sigio_ver=os.getenv("sigio_ver") or "2.3.2"
load(pathJoin("sigio", sigio_ver))

zlib_ver=os.getenv("zlib_ver") or "1.2.11"
load(pathJoin("zlib", zlib_ver))

png_ver=os.getenv("png_ver") or "1.6.35"
load(pathJoin("libpng", png_ver))

hdf5_ver=os.getenv("hdf5_ver") or "1.10.6"
load(pathJoin("hdf5", hdf5_ver))

netcdf_ver=os.getenv("netcdf_ver") or "4.6.1"
load(pathJoin("netcdf", netcdf_ver))

nccmp_ver=os.getenv("nccmp_ver") or "1.8.9.0"
load(pathJoin("nccmp", nccmp_ver))

esmf_ver=os.getenv("esmf_ver") or "8.4.0b08"
load(pathJoin("esmf", esmf_ver))

nco_ver=os.getenv("nco_ver") or "4.9.1"
load(pathJoin("nco", nco_ver))

whatis("Description: UFS_UTILS build environment")
8 changes: 8 additions & 0 deletions sorc/machine-setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,15 @@ elif [[ -d /data/prod ]] ; then
fi
target=s4
module purge
elif [[ "$(dnsdomainname)" =~ "pw" ]]; then
if [[ "${PW_CSP}" == "aws" ]]; then # TODO: Add other CSPs here.
target=noaacloud
module purge
else
echo WARNING: UNSUPPORTED CSP PLATFORM 1>&2; exit 99
fi
else

echo WARNING: UNKNOWN PLATFORM 1>&2
fi

Expand Down