From 16dbe96e3abba58c2ad9f5b9419dfb3e7a534da2 Mon Sep 17 00:00:00 2001 From: kgerheiser Date: Fri, 25 Feb 2022 15:52:34 -0500 Subject: [PATCH] Fix Github Action builds Bring changes to the OASIS tests layout (ww3_tp2.14) to Github workflows. --- .github/workflows/gnu.yml | 11 ++++++----- .github/workflows/intel.yml | 11 ++++++----- .../util/make_dir/{make.inc.tmpl => make.inc} | 2 +- .../ww3_tp2.14/input/toy/{Makefile.tmpl => Makefile} | 2 +- regtests/ww3_tp2.14/input_oasacm/prep_env.sh | 3 --- regtests/ww3_tp2.14/input_oasacm2/prep_env.sh | 3 --- regtests/ww3_tp2.14/input_oasacm4/prep_env.sh | 3 --- regtests/ww3_tp2.14/input_oasacm5/prep_env.sh | 3 --- regtests/ww3_tp2.14/input_oasacm6/prep_env.sh | 3 --- regtests/ww3_tp2.14/input_oasicm/prep_env.sh | 3 --- regtests/ww3_tp2.14/input_oasocm/prep_env.sh | 3 --- 11 files changed, 14 insertions(+), 33 deletions(-) rename regtests/ww3_tp2.14/input/oasis3-mct/util/make_dir/{make.inc.tmpl => make.inc} (88%) rename regtests/ww3_tp2.14/input/toy/{Makefile.tmpl => Makefile} (98%) diff --git a/.github/workflows/gnu.yml b/.github/workflows/gnu.yml index 591b409c8d..a063de01b8 100644 --- a/.github/workflows/gnu.yml +++ b/.github/workflows/gnu.yml @@ -2,7 +2,7 @@ name: GNU Linux Build on: [push, pull_request] env: - cache_key: gnu3 + cache_key: gnu4 CC: gcc-10 FC: gfortran-10 CXX: g++-10 @@ -44,7 +44,7 @@ jobs: spack env create ww3-gnu ww3/model/ci/spack.yaml spack env activate ww3-gnu spack compiler find - spack external find m4 cmake pkgconf openssl + spack external find spack add mpich@3.4.2 spack concretize spack install --dirty -v @@ -55,11 +55,12 @@ jobs: source spack/share/spack/setup-env.sh spack env activate ww3-gnu export WWATCH3_DIR=${GITHUB_WORKSPACE}/ww3/model + export OASIS_INPUT_PATH=${GITHUB_WORKSPACE}/ww3/regtests/ww3_tp2.14/input/oasis3-mct + export OASIS_WORK_PATH=${GITHUB_WORKSPACE}/ww3/regtests/ww3_tp2.14/input/work_oasis3-mct cd ww3/regtests/ww3_tp2.14/input/oasis3-mct/util/make_dir - mkdir build && cd build - cmake .. + cmake . make VERBOSE=1 - cp -r ${GITHUB_WORKSPACE}/ww3/regtests/ww3_tp2.14/work_oasis3-mct ${GITHUB_WORKSPACE} + cp -r ${GITHUB_WORKSPACE}/ww3/regtests/ww3_tp2.14/input/work_oasis3-mct ${GITHUB_WORKSPACE} build: needs: setup diff --git a/.github/workflows/intel.yml b/.github/workflows/intel.yml index 3ff6f896ed..b76eb741fc 100644 --- a/.github/workflows/intel.yml +++ b/.github/workflows/intel.yml @@ -9,7 +9,7 @@ defaults: # Set I_MPI_CC/F90 so Intel MPI wrapper uses icc/ifort instead of gcc/gfortran env: - cache_key: intel4 + cache_key: intel5 CC: icc FC: ifort CXX: icpc @@ -64,7 +64,7 @@ jobs: spack env create ww3-intel ww3/model/ci/spack.yaml spack env activate ww3-intel spack compiler find - spack external find m4 cmake pkgconf openssl + spack external find spack add intel-oneapi-mpi spack concretize spack install --dirty -v @@ -75,11 +75,12 @@ jobs: source spack/share/spack/setup-env.sh spack env activate ww3-intel export WWATCH3_DIR=${GITHUB_WORKSPACE}/ww3/model + export OASIS_INPUT_PATH=${GITHUB_WORKSPACE}/ww3/regtests/ww3_tp2.14/input/oasis3-mct + export OASIS_WORK_PATH=${GITHUB_WORKSPACE}/ww3/regtests/ww3_tp2.14/input/work_oasis3-mct cd ww3/regtests/ww3_tp2.14/input/oasis3-mct/util/make_dir - mkdir build && cd build - cmake .. + cmake . make - cp -r ${GITHUB_WORKSPACE}/ww3/regtests/ww3_tp2.14/work_oasis3-mct ${GITHUB_WORKSPACE} + cp -r ${GITHUB_WORKSPACE}/ww3/regtests/ww3_tp2.14/input/work_oasis3-mct ${GITHUB_WORKSPACE} build: needs: setup diff --git a/regtests/ww3_tp2.14/input/oasis3-mct/util/make_dir/make.inc.tmpl b/regtests/ww3_tp2.14/input/oasis3-mct/util/make_dir/make.inc similarity index 88% rename from regtests/ww3_tp2.14/input/oasis3-mct/util/make_dir/make.inc.tmpl rename to regtests/ww3_tp2.14/input/oasis3-mct/util/make_dir/make.inc index 9aaa891d94..776738a7ad 100644 --- a/regtests/ww3_tp2.14/input/oasis3-mct/util/make_dir/make.inc.tmpl +++ b/regtests/ww3_tp2.14/input/oasis3-mct/util/make_dir/make.inc @@ -10,6 +10,6 @@ # Note: Choose one of these includes files and modify it according to your # local settings. Replace the currently active file with your own. # -include /util/make_dir/cmplr +include $(OASIS_INPUT_PATH)/util/make_dir/cmplr # ### End User configurable options ### diff --git a/regtests/ww3_tp2.14/input/toy/Makefile.tmpl b/regtests/ww3_tp2.14/input/toy/Makefile similarity index 98% rename from regtests/ww3_tp2.14/input/toy/Makefile.tmpl rename to regtests/ww3_tp2.14/input/toy/Makefile index 6b19c9ab36..41016fec89 100755 --- a/regtests/ww3_tp2.14/input/toy/Makefile.tmpl +++ b/regtests/ww3_tp2.14/input/toy/Makefile @@ -1,5 +1,5 @@ # -include /util/make_dir/make.inc +include $(OASIS_INPUT_PATH)/util/make_dir/make.inc # LIBPSMILE = $(ARCHDIR)/lib/libpsmile.${CHAN}.a $(ARCHDIR)/lib/libmct.a $(ARCHDIR)/lib/libmpeu.a $(ARCHDIR)/lib/libscrip.a # diff --git a/regtests/ww3_tp2.14/input_oasacm/prep_env.sh b/regtests/ww3_tp2.14/input_oasacm/prep_env.sh index 3bbab16283..dd5c16bcc7 100755 --- a/regtests/ww3_tp2.14/input_oasacm/prep_env.sh +++ b/regtests/ww3_tp2.14/input_oasacm/prep_env.sh @@ -34,7 +34,6 @@ echo ' Setup oasis cmplr file' cd $path_w/oasis3-mct/util/make_dir echo ' setup oasis make.inc file' -sed -e "s::$path_w/oasis3-mct:" make.inc.tmpl > make.inc echo ' compile oasis coupler' # Build OASIS with CMake wrapper @@ -44,8 +43,6 @@ make echo ' setup toy Makefile' cd $path_w/toy -sed -e "s::$path_w/oasis3-mct:" Makefile.tmpl > Makefile - echo ' compile toy model' make clean > $path_w/toy_clean.out diff --git a/regtests/ww3_tp2.14/input_oasacm2/prep_env.sh b/regtests/ww3_tp2.14/input_oasacm2/prep_env.sh index 3bbab16283..dd5c16bcc7 100755 --- a/regtests/ww3_tp2.14/input_oasacm2/prep_env.sh +++ b/regtests/ww3_tp2.14/input_oasacm2/prep_env.sh @@ -34,7 +34,6 @@ echo ' Setup oasis cmplr file' cd $path_w/oasis3-mct/util/make_dir echo ' setup oasis make.inc file' -sed -e "s::$path_w/oasis3-mct:" make.inc.tmpl > make.inc echo ' compile oasis coupler' # Build OASIS with CMake wrapper @@ -44,8 +43,6 @@ make echo ' setup toy Makefile' cd $path_w/toy -sed -e "s::$path_w/oasis3-mct:" Makefile.tmpl > Makefile - echo ' compile toy model' make clean > $path_w/toy_clean.out diff --git a/regtests/ww3_tp2.14/input_oasacm4/prep_env.sh b/regtests/ww3_tp2.14/input_oasacm4/prep_env.sh index 3bbab16283..dd5c16bcc7 100755 --- a/regtests/ww3_tp2.14/input_oasacm4/prep_env.sh +++ b/regtests/ww3_tp2.14/input_oasacm4/prep_env.sh @@ -34,7 +34,6 @@ echo ' Setup oasis cmplr file' cd $path_w/oasis3-mct/util/make_dir echo ' setup oasis make.inc file' -sed -e "s::$path_w/oasis3-mct:" make.inc.tmpl > make.inc echo ' compile oasis coupler' # Build OASIS with CMake wrapper @@ -44,8 +43,6 @@ make echo ' setup toy Makefile' cd $path_w/toy -sed -e "s::$path_w/oasis3-mct:" Makefile.tmpl > Makefile - echo ' compile toy model' make clean > $path_w/toy_clean.out diff --git a/regtests/ww3_tp2.14/input_oasacm5/prep_env.sh b/regtests/ww3_tp2.14/input_oasacm5/prep_env.sh index 3bbab16283..dd5c16bcc7 100755 --- a/regtests/ww3_tp2.14/input_oasacm5/prep_env.sh +++ b/regtests/ww3_tp2.14/input_oasacm5/prep_env.sh @@ -34,7 +34,6 @@ echo ' Setup oasis cmplr file' cd $path_w/oasis3-mct/util/make_dir echo ' setup oasis make.inc file' -sed -e "s::$path_w/oasis3-mct:" make.inc.tmpl > make.inc echo ' compile oasis coupler' # Build OASIS with CMake wrapper @@ -44,8 +43,6 @@ make echo ' setup toy Makefile' cd $path_w/toy -sed -e "s::$path_w/oasis3-mct:" Makefile.tmpl > Makefile - echo ' compile toy model' make clean > $path_w/toy_clean.out diff --git a/regtests/ww3_tp2.14/input_oasacm6/prep_env.sh b/regtests/ww3_tp2.14/input_oasacm6/prep_env.sh index 3bbab16283..dd5c16bcc7 100755 --- a/regtests/ww3_tp2.14/input_oasacm6/prep_env.sh +++ b/regtests/ww3_tp2.14/input_oasacm6/prep_env.sh @@ -34,7 +34,6 @@ echo ' Setup oasis cmplr file' cd $path_w/oasis3-mct/util/make_dir echo ' setup oasis make.inc file' -sed -e "s::$path_w/oasis3-mct:" make.inc.tmpl > make.inc echo ' compile oasis coupler' # Build OASIS with CMake wrapper @@ -44,8 +43,6 @@ make echo ' setup toy Makefile' cd $path_w/toy -sed -e "s::$path_w/oasis3-mct:" Makefile.tmpl > Makefile - echo ' compile toy model' make clean > $path_w/toy_clean.out diff --git a/regtests/ww3_tp2.14/input_oasicm/prep_env.sh b/regtests/ww3_tp2.14/input_oasicm/prep_env.sh index 3bbab16283..dd5c16bcc7 100755 --- a/regtests/ww3_tp2.14/input_oasicm/prep_env.sh +++ b/regtests/ww3_tp2.14/input_oasicm/prep_env.sh @@ -34,7 +34,6 @@ echo ' Setup oasis cmplr file' cd $path_w/oasis3-mct/util/make_dir echo ' setup oasis make.inc file' -sed -e "s::$path_w/oasis3-mct:" make.inc.tmpl > make.inc echo ' compile oasis coupler' # Build OASIS with CMake wrapper @@ -44,8 +43,6 @@ make echo ' setup toy Makefile' cd $path_w/toy -sed -e "s::$path_w/oasis3-mct:" Makefile.tmpl > Makefile - echo ' compile toy model' make clean > $path_w/toy_clean.out diff --git a/regtests/ww3_tp2.14/input_oasocm/prep_env.sh b/regtests/ww3_tp2.14/input_oasocm/prep_env.sh index 3bbab16283..dd5c16bcc7 100755 --- a/regtests/ww3_tp2.14/input_oasocm/prep_env.sh +++ b/regtests/ww3_tp2.14/input_oasocm/prep_env.sh @@ -34,7 +34,6 @@ echo ' Setup oasis cmplr file' cd $path_w/oasis3-mct/util/make_dir echo ' setup oasis make.inc file' -sed -e "s::$path_w/oasis3-mct:" make.inc.tmpl > make.inc echo ' compile oasis coupler' # Build OASIS with CMake wrapper @@ -44,8 +43,6 @@ make echo ' setup toy Makefile' cd $path_w/toy -sed -e "s::$path_w/oasis3-mct:" Makefile.tmpl > Makefile - echo ' compile toy model' make clean > $path_w/toy_clean.out