Directive inheritance: laziness for the win (#2623)

* inheritance of directives: using meta-classes to inject attributes coming from directives into packages + lazy directives

* _dep_types -> dependency_types
* using a meta-class to inject directives into packages
* directives are lazy

fixes #2466

* directives.py: allows for multiple inheritance. Added blank lines as suggested by @tgamblin

* directives.py: added a test for simple inheritance of directives

* Minor improvement requested by @tgamblin

CMakePackage: importing names from spack.directives
directives: wrap __new__ to respect pep8

* Refactoring requested by @tgamblin

directives: removed global variables in favor of class variables. Simplified the interface for directives (they return a callable on a package or a list of them).
This commit is contained in:
Massimiliano Culpo
2016-12-28 21:37:02 +01:00
committed by Todd Gamblin
parent 857dac88c8
commit 17b13b161b
11 changed files with 282 additions and 203 deletions

View File

@@ -90,7 +90,6 @@ class Dealii(CMakePackage):
"boost@1.59.0:+thread+system+serialization+iostreams+mpi+python",
when='@8.5.0:+mpi+python')
depends_on("bzip2")
depends_on("cmake", type='build')
depends_on("lapack")
depends_on("muparser")
depends_on("suite-sparse")