diff --git a/CHANGELOG.md b/CHANGELOG.md index 02e9458..f2c3233 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] ### Changed + +- Move to use spack-stack 1.9 for modules at NCCS + ### Fixed ### Removed ### Added diff --git a/g5_modules b/g5_modules index ed2bb4a..6cd526e 100755 --- a/g5_modules +++ b/g5_modules @@ -4,12 +4,10 @@ # Name: g5_modules # # Purposes - -# * provide single location for BASEDIR and module values +# * provide single location for module values # * initialize the following: -# - set BASEDIR -# - update LD_LIBRARY_PATH with BASEDIR lib (if useldlibs is set) # - load library modules -# * echo expected BASEDIR and library module values when queried +# * echo expected library module values when queried # # Notes: # 1. The script will not function correctly if the scriptname @@ -74,9 +72,6 @@ if (($node =~ discover*) || ($node =~ borg*) || \ set site = "NCCS" - # NCCS now has both SLES15 and SLES12 machines - set OS_VERSION=`grep VERSION_ID /etc/os-release | cut -d= -f2 | cut -d. -f1 | sed 's/"//g'` - else if (($node =~ pfe*) || ($node =~ afe*) || \ ($node =~ r[0-9]*i[0-9]*n[0-9]*) || \ ($node =~ r[0-9]*c[0-9]*t[0-9]*n[0-9]*)) then @@ -117,43 +112,34 @@ X86_64: set modinit = DUMMY set usemodules = 0 -set useldlibs = 0 #========# # NCCS # #========# if ( $site == NCCS ) then - set mod1 = GEOSenv - - if ( $OS_VERSION == 12 ) then - - set mod2 = comp/gcc/12.1.0 - set mod3 = comp/intel/2021.6.0 - set mod4 = mpi/impi/2021.6.0 - set mod5 = python/GEOSpyD/Min24.4.0-0_py3.11_AND_Min4.8.3_py2.7 - set basedir = /discover/swdev/gmao_SIteam/Baselibs/ESMA-Baselibs-7.32.0/x86_64-pc-linux-gnu/ifort_2021.6.0-intelmpi_2021.6.0-SLES12 - set usemod1 = /discover/swdev/gmao_SIteam/modulefiles-SLES12 - - else - - set mod2 = comp/gcc/12.3.0 - set mod3 = comp/intel/2024.2.0 - set mod4 = mpi/impi/2021.13 - set mod5 = python/GEOSpyD/24.3.0-0/3.11 - set basedir = /discover/swdev/gmao_SIteam/Baselibs/ESMA-Baselibs-7.32.0/x86_64-pc-linux-gnu/ifort_2021.13.0-intelmpi_2021.13.0-SLES15 - set usemod1 = /discover/swdev/gmao_SIteam/modulefiles-SLES15 - - endif - - set mods = ( $mod1 $mod2 $mod3 $mod4 $mod5 ) + set usemod1 = /discover/swdev/gmao_SIteam/modulefiles-SLES15 + set usemod2 = /discover/swdev/jcsda/spack-stack/scu17/modulefiles + set usemod3 = /gpfsm/dswdev/jcsda/spack-stack/scu17/spack-stack-1.9.0/envs/ue-oneapi-2024.2.0/install/modulefiles/Core + + set mod1 = stack-oneapi/2024.2.0 + set mod2 = stack-intel-oneapi-mpi/2021.13 + set mod3 = stack-python/3.11.7 + set mod4 = git + set mod5 = cmake + set mod6 = esmf/8.8.0 + set mod7 = gftl + set mod8 = gftl-shared + set mod9 = pflogger + set mod10 = fargparse + set mod11 = udunits + + set mods = ( $mod1 $mod2 $mod3 $mod4 $mod5 $mod6 $mod7 $mod8 $mod9 $mod10 $mod11 ) set modinit = /usr/share/modules/init/csh - set usemods = ( $usemod1 ) + set usemods = ( $usemod1 $usemod2 $usemod3 ) set usemodules = 1 - set useldlibs = 1 - #=======# # NAS # #=======# @@ -161,7 +147,6 @@ else if ( $site == NAS ) then set mod1 = GEOSenv - set basedir = /nobackup/gmao_SIteam/Baselibs/ESMA-Baselibs-7.32.0/x86_64-pc-linux-gnu/ifort_2021.13.0-mpt_2.30 set mod2 = comp-gcc/12.3.0-TOSS4 set mod3 = comp-intel/2024.2.0-ifort set mod4 = mpi-hpe/mpt @@ -177,14 +162,11 @@ else if ( $site == NAS ) then set usemods = ( $usemod1 $usemod2 $usemod3 ) set usemodules = 1 - set useldlibs = 0 - #=================# # GMAO DESKTOP # #=================# else if ( $site == GMAO.desktop ) then - set basedir=/ford1/share/gmao_SIteam/Baselibs/ESMA-Baselibs-7.32.0/x86_64-pc-linux-gnu/ifort_2021.13.0-intelmpi_2021.13 set mod1 = GEOSenv @@ -200,10 +182,6 @@ else if ( $site == GMAO.desktop ) then set usemods = ( $usemod1 ) set usemodules = 1 - # Testing shows adding BASEDIR lib to LD_LIBRARY_PATH - # causes issues with the TCL modules on the GMAO machines - set useldlibs = 0 - endif goto ACTION @@ -220,7 +198,6 @@ ARM64: set modinit = DUMMY set usemodules = 0 -set useldlibs = 0 goto ACTION @@ -235,10 +212,7 @@ ACTION: set wrapper = 0 if ( $#argv > 0 ) then - if ( $1 == basedir ) then - echo $basedir - - else if ( $1 == modules ) then + if ( $1 == modules ) then echo $mods else if ( $1 == modinit ) then @@ -247,9 +221,6 @@ if ( $#argv > 0 ) then else if ( $1 == usemodules ) then echo $usemods - else if ( $1 == useldlibs ) then - echo $useldlibs - else if ( $1 == ESMA_FC ) then echo $ESMA_FC @@ -278,35 +249,9 @@ SETVALUES: # SET VALUES # #================# #------------------------------------------------------------------------- -# set environment variables, BASEDIR and LD_LIBRARY_PATH; and load modules +# set environment variables, and LD_LIBRARY_PATH; and load modules #------------------------------------------------------------------------- -# setenv BASEDIR -#--------------- -if ($?basedir) then - if (! $wrapper) echo -n "${scriptname}: Setting BASEDIR" - setenv BASEDIR $basedir -else if ($?BASEDIR) then - if (! $wrapper) echo -n "${scriptname}: BASEDIR found in environment" -else - echo - echo "BASEDIR not found in environment or set by ${scriptname}" - exit 3 -endif - -# add BASEDIR lib to LD_LIBRARY_PATH, if not already there -#--------------------------------------------------------- - -if ($useldlibs) then - if ($?LD_LIBRARY_PATH) then - echo $LD_LIBRARY_PATH | grep $BASEDIR/$arch/lib > /dev/null - if ($status) then # == 1, if not found - setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:$BASEDIR/$arch/lib - endif - else - setenv LD_LIBRARY_PATH $BASEDIR/$arch/lib - endif - # add individual $ld_libraries to LD_LIBRARY_PATH, if not already there #---------------------------------------------------------------------- if ($?ld_libraries) then @@ -317,18 +262,8 @@ if ($useldlibs) then end endif - if ($?LD_LIBRARY64_PATH) then - echo $LD_LIBRARY64_PATH | grep $BASEDIR/$arch/lib > /dev/null - if ($status) then # == 1, if not found - setenv LD_LIBRARY64_PATH ${LD_LIBRARY64_PATH}:$BASEDIR/$arch/lib - endif - endif endif -# Set UDUNITS2_XML_PATH -# --------------------- -setenv UDUNITS2_XML_PATH $BASEDIR/$arch/share/udunits/udunits2.xml - # load library modules #--------------------- if (-e $modinit) then @@ -362,9 +297,6 @@ if (! $wrapper) echo " for $node" if ($wrapper) then set outfil = ".g5_modules.sh" - if ($?BASEDIR) then - echo "export BASEDIR=$BASEDIR" >! $outfil - endif if ($?LD_LIBRARY_PATH) then echo "export LD_LIBRARY_PATH=$LD_LIBRARY_PATH" >> $outfil endif @@ -400,20 +332,16 @@ usage: more <