summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/spack/spack/build_environment.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/spack/spack/build_environment.py b/lib/spack/spack/build_environment.py
index d849b4b56c..6e03394777 100644
--- a/lib/spack/spack/build_environment.py
+++ b/lib/spack/spack/build_environment.py
@@ -226,8 +226,8 @@ def set_build_environment_variables(pkg):
pkg_config_dirs.append(pcdir)
path_put_first("PKG_CONFIG_PATH", pkg_config_dirs)
- if pkg.spec.target.module_name:
- load_module(pkg.spec.target.module_name)
+ if pkg.spec.architecture.target.module_name:
+ load_module(pkg.spec.architecture.target.module_name)
def set_module_variables_for_package(pkg):
"""Populate the module scope of install() with some useful functions.