@@ -51,14 +51,23 @@ if [ -d $EESSI_PREFIX ]; then
51
51
show_msg "Using ${EESSI_SOFTWARE_SUBDIR} as software subdirectory."
52
52
export EESSI_SOFTWARE_PATH=$EESSI_PREFIX/software/$EESSI_OS_TYPE/$EESSI_SOFTWARE_SUBDIR
53
53
54
- # Configure our LMOD_RC file
55
- export LMOD_RC="$EESSI_SOFTWARE_PATH/.lmod/lmodrc.lua"
56
- if [ -f $LMOD_RC ]; then
57
- show_msg "Found Lmod configuration file at $LMOD_RC"
54
+ # Configure our LMOD
55
+ export LMOD_CONFIG_DIR="$EESSI_SOFTWARE_PATH/.lmod"
56
+ lmod_rc_file="$LMOD_CONFIG_DIR/lmodrc.lua"
57
+ if [ -f $lmod_rc_file ]; then
58
+ show_msg "Found Lmod configuration file at $lmod_rc_file"
58
59
else
59
- error "Lmod configuration file not found at $LMOD_RC "
60
+ error "Lmod configuration file not found at $lmod_rc_file "
60
61
fi
61
62
63
+ export LMOD_PACKAGE_PATH="$EESSI_SOFTWARE_PATH/.lmod"
64
+ lmod_sitepackage_file="$LMOD_PACKAGE_PATH/SitePackage.lua"
65
+ if [ -f $lmod_sitepackage_file ]; then
66
+ show_msg "Found Lmod SitePackage.lua file at $lmod_sitepackage_file"
67
+ else
68
+ error "Lmod SitePackage.lua file not found at $lmod_sitepackage_file"
69
+ fi
70
+
62
71
if [ ! -z $EESSI_BASIC_ENV ]; then
63
72
show_msg "Only setting up basic environment, so we're done"
64
73
elif [ -d $EESSI_SOFTWARE_PATH ]; then
@@ -85,21 +94,6 @@ if [ -d $EESSI_PREFIX ]; then
85
94
false
86
95
fi
87
96
88
- export LMOD_CONFIG_DIR="$EESSI_SOFTWARE_PATH/.lmod"
89
- lmod_rc_file="$LMOD_CONFIG_DIR/lmodrc.lua"
90
- if [ -f $lmod_rc_file ]; then
91
- show_msg "Found Lmod configuration file at $lmod_rc_file"
92
- else
93
- error "Lmod configuration file not found at $lmod_rc_file"
94
- fi
95
-
96
- export LMOD_PACKAGE_PATH="$EESSI_SOFTWARE_PATH/.lmod"
97
- lmod_sitepackage_file="$LMOD_PACKAGE_PATH/SitePackage.lua"
98
- if [ -f $lmod_sitepackage_file ]; then
99
- show_msg "Found Lmod SitePackage.lua file at $lmod_sitepackage_file"
100
- else
101
- error "Lmod SitePackage.lua file not found at $lmod_sitepackage_file"
102
- fi
103
97
104
98
else
105
99
error "EESSI software layer at $EESSI_SOFTWARE_PATH not found!"
0 commit comments