summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDave Keeshan <96727608+davekeeshan@users.noreply.github.com>2023-12-11 09:31:56 +0000
committerGitHub <noreply@github.com>2023-12-11 10:31:56 +0100
commit64cd429cc8dff73af130ea9617d12fddaf93021c (patch)
tree0524bd451d5d49b8506c2e94902823ba5583a195 /lib
parent525809632ef3f198c182c9350db2f7c5d3afd832 (diff)
downloadspack-64cd429cc8dff73af130ea9617d12fddaf93021c.tar.gz
spack-64cd429cc8dff73af130ea9617d12fddaf93021c.tar.bz2
spack-64cd429cc8dff73af130ea9617d12fddaf93021c.tar.xz
spack-64cd429cc8dff73af130ea9617d12fddaf93021c.zip
Fix filter_compiler_wrapper where compiler is None (#41502)
Fix filer_compiler_wrapper for cases where the compiler returned in None, this happens on some installed gcc systems that do not have fortran built into them as standard, e.g. gcc@11.4.0 on ubuntu 22.04
Diffstat (limited to 'lib')
-rw-r--r--lib/spack/spack/mixins.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/spack/spack/mixins.py b/lib/spack/spack/mixins.py
index 189c3947ef..ef1d2b7916 100644
--- a/lib/spack/spack/mixins.py
+++ b/lib/spack/spack/mixins.py
@@ -93,7 +93,7 @@ def filter_compiler_wrappers(*files, **kwargs):
replacements = []
for idx, (env_var, compiler_path) in enumerate(compiler_vars):
- if env_var in os.environ:
+ if env_var in os.environ and compiler_path is not None:
# filter spack wrapper and links to spack wrapper in case
# build system runs realpath
wrapper = os.environ[env_var]