summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAxel Huebl <axel.huebl@plasma.ninja>2020-08-01 13:29:17 -0700
committerTodd Gamblin <tgamblin@llnl.gov>2020-08-12 23:58:10 -0700
commit50f76f613182bc106cae426f024d14fd28351f5a (patch)
tree41aa68b44d36775879a3af3a037d43f3ae9150ce
parent5f8ab6939670370f7d98d1ff4daf1a14697645b0 (diff)
downloadspack-50f76f613182bc106cae426f024d14fd28351f5a.tar.gz
spack-50f76f613182bc106cae426f024d14fd28351f5a.tar.bz2
spack-50f76f613182bc106cae426f024d14fd28351f5a.tar.xz
spack-50f76f613182bc106cae426f024d14fd28351f5a.zip
Hotfix: move CUDAHOSTCXX (#17826)
* Hotfix: move CUDAHOSTCXX Set only in dependent packages. * dependent compiler
-rw-r--r--var/spack/repos/builtin/packages/cuda/package.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/var/spack/repos/builtin/packages/cuda/package.py b/var/spack/repos/builtin/packages/cuda/package.py
index 5fd89cbaa1..90a8cba788 100644
--- a/var/spack/repos/builtin/packages/cuda/package.py
+++ b/var/spack/repos/builtin/packages/cuda/package.py
@@ -77,15 +77,16 @@ class Cuda(Package):
depends_on('libxml2', when='@10.1.243:')
def setup_build_environment(self, env):
- env.set('CUDAHOSTCXX', self.compiler.cxx)
if self.spec.satisfies('@10.1.243:'):
libxml2_home = self.spec['libxml2'].prefix
env.set('LIBXML2HOME', libxml2_home)
env.append_path('LD_LIBRARY_PATH', libxml2_home.lib)
+ def setup_dependent_build_environment(self, env, dependent_spec):
+ env.set('CUDAHOSTCXX', dependent_spec.package.compiler.cxx)
+
def setup_run_environment(self, env):
env.set('CUDA_HOME', self.prefix)
- env.set('CUDAHOSTCXX', self.compiler.cxx)
def install(self, spec, prefix):
if os.path.exists('/tmp/cuda-installer.log'):