guard against SPACK_FC possibly not being defined (#30581)
This commit is contained in:
parent
01b79abcdf
commit
cfed42ecfc
2 changed files with 8 additions and 2 deletions
|
@ -303,7 +303,10 @@ def hostconfig(self):
|
||||||
#######################
|
#######################
|
||||||
c_compiler = env["SPACK_CC"]
|
c_compiler = env["SPACK_CC"]
|
||||||
cpp_compiler = env["SPACK_CXX"]
|
cpp_compiler = env["SPACK_CXX"]
|
||||||
f_compiler = env["SPACK_FC"]
|
if "+fortran" in spec:
|
||||||
|
f_compiler = env["SPACK_FC"]
|
||||||
|
else:
|
||||||
|
f_compiler = None
|
||||||
|
|
||||||
#######################################################################
|
#######################################################################
|
||||||
# Directly fetch the names of the actual compilers to create a
|
# Directly fetch the names of the actual compilers to create a
|
||||||
|
|
|
@ -287,7 +287,10 @@ def hostconfig(self):
|
||||||
#######################
|
#######################
|
||||||
c_compiler = env["SPACK_CC"]
|
c_compiler = env["SPACK_CC"]
|
||||||
cpp_compiler = env["SPACK_CXX"]
|
cpp_compiler = env["SPACK_CXX"]
|
||||||
f_compiler = env["SPACK_FC"]
|
if "+fortran" in spec:
|
||||||
|
f_compiler = env["SPACK_FC"]
|
||||||
|
else:
|
||||||
|
f_compiler = None
|
||||||
|
|
||||||
#######################################################################
|
#######################################################################
|
||||||
# Directly fetch the names of the actual compilers to create a
|
# Directly fetch the names of the actual compilers to create a
|
||||||
|
|
Loading…
Reference in a new issue