Merge pull request #732 from citibeth/efischer/160403-ConditionalExtendsBugfix
[Needs Review] Fix conditional extends (BUG #683)
This commit is contained in:
commit
c7b11360e9
1 changed files with 8 additions and 3 deletions
|
@ -163,9 +163,14 @@ def write(self):
|
|||
# package-specific modifications
|
||||
spack_env = EnvironmentModifications()
|
||||
for item in self.pkg.extendees:
|
||||
package = self.spec[item].package
|
||||
package.setup_dependent_package(self.pkg.module, self.spec)
|
||||
package.setup_dependent_environment(spack_env, env, self.spec)
|
||||
try:
|
||||
package = self.spec[item].package
|
||||
package.setup_dependent_package(self.pkg.module, self.spec)
|
||||
package.setup_dependent_environment(spack_env, env, self.spec)
|
||||
except:
|
||||
# The extends was conditional, so it doesn't count here
|
||||
# eg: extends('python', when='+python')
|
||||
pass
|
||||
|
||||
# Package-specific environment modifications
|
||||
self.spec.package.setup_environment(spack_env, env)
|
||||
|
|
Loading…
Reference in a new issue