Skip to content

Commit f061827

Browse files
author
Caspar van Leeuwen
committed
Make sure the hooks are applied in install_cuda_and_libraries, but that the directory check is skipped, as we INTEND to install in an exceptional (i.e. non-accelerator) path
1 parent 8ad1a7c commit f061827

2 files changed

Lines changed: 6 additions & 10 deletions

File tree

eb_hooks.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -697,7 +697,7 @@ def pre_fetch_hook_check_installation_path(self, *args, **kwargs):
697697
strict_eessi_installation = (
698698
bool(re.search(EESSI_INSTALLATION_REGEX, self.installdir)) or
699699
self.installdir.startswith(HOST_INJECTIONS_LOCATION))
700-
if strict_eessi_installation:
700+
if strict_eessi_installation and not os.getenv("EESSI_OVERRIDE_STRICT_INSTALLPATH_CHECK"):
701701
dependency_names = self.cfg.dependency_names()
702702
if self.cfg.name in accelerator_deps or any(dep in dependency_names for dep in accelerator_deps):
703703
# Make sure the path is an accelerator location
@@ -1089,7 +1089,7 @@ def pre_configure_hook_graphviz(self, *args, **kwargs):
10891089
# Replace --with-ltdl-lib and --with-zlibdir options defined in the EC to point to compat layer
10901090
lib_dir = os.path.join(usr_dir, 'lib64')
10911091
new_items = set()
1092-
# Add to the new_items all the old items except the `--with-ltdl-lib` and `--with-ltdl-lib` for
1092+
# Add to the new_items all the old items except the `--with-ltdl-lib` and `--with-ltdl-lib` for
10931093
# which we fix the lib dir to lib64 instead of lib
10941094
for item in old_items:
10951095
if item.startswith('--with-ltdl-lib'):
@@ -1483,7 +1483,7 @@ def pre_test_hook_ignore_failing_tests_OpenBabel_a64fx(self, *args, **kwargs):
14831483
Pre-test hook for OpenBabel: skip timeout tests for OpenBabel 3.1.1 on aarch64/a64fx
14841484
see https://github.com/EESSI/software-layer/pull/1332#issuecomment-3877255228
14851485
the `testroundtrip.py` test reads and writes tens of thousands of small files.
1486-
The test works fine when manually ran with EESSI-extend either directly or inside an eessi_container, but
1486+
The test works fine when manually ran with EESSI-extend either directly or inside an eessi_container, but
14871487
consistently fails with the bot
14881488
"""
14891489
cpu_target = get_eessi_envvar('EESSI_SOFTWARE_SUBDIR')

scripts/gpu_support/nvidia/install_cuda_and_libraries.sh

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -149,10 +149,9 @@ for EASYSTACK_FILE in ${TOPDIR}/easystacks/eessi-*CUDA*.yml; do
149149
MODULEPATH=${EASYBUILD_INSTALLPATH}/.modules/all
150150
echo "set MODULEPATH=${MODULEPATH}"
151151

152-
# We don't want hooks used in this install, we need vanilla installations
153-
touch "${tmpdir}"/none.py
154-
export EASYBUILD_HOOKS="${tmpdir}/none.py"
155-
152+
# We need to skip the hook that checks if CUDA software installed in an accelerator-specific prefix
153+
export EESSI_OVERRIDE_STRICT_INSTALLPATH_CHECK=1
154+
156155
# show EasyBuild configuration
157156
echo "Show EasyBuild configuration"
158157
eb --show-config
@@ -238,8 +237,6 @@ for EASYSTACK_FILE in ${TOPDIR}/easystacks/eessi-*CUDA*.yml; do
238237
# is run, it is not reinstalled.
239238
# - ${accept_eula_opt}: We only set the --accept-eula-for=CUDA option if CUDA will be installed and if
240239
# this script was called with the argument --accept-cuda-eula.
241-
# - hooks: We don't want hooks used in this install, we need vanilla
242-
# installations of CUDA and/or other libraries
243240
# - easystack: Path to easystack file that defines which packages shall be
244241
# installed
245242
accept_eula_opt=
@@ -256,7 +253,6 @@ for EASYSTACK_FILE in ${TOPDIR}/easystacks/eessi-*CUDA*.yml; do
256253
touch "$tmpdir"/none.py
257254
eb_args="--prefix=$tmpdir"
258255
eb_args="$eb_args --installpath-modules=${EASYBUILD_INSTALLPATH}/.modules"
259-
eb_args="$eb_args --hooks="$tmpdir"/none.py"
260256
eb_args="$eb_args --easystack ${EASYSTACK_FILE}"
261257
if [[ ! -z ${accept_eula_opt} ]]; then
262258
eb_args="$eb_args --accept-eula-for=$accept_eula_opt"

0 commit comments

Comments
 (0)