Add universal build_type variant to CMakePackage (#4797)

* Add universal build_type variant to CMakePackage
* Override build_type in some packages with different possible values
* Remove reference to no longer existent debug variant
* Update CBTF packages with new build_type variant
* Keep note on build size of LLVM
This commit is contained in:
Adam J. Stewart
2017-07-25 18:34:43 -05:00
committed by Todd Gamblin
parent 4b996e9f49
commit 07aec4366f
46 changed files with 68 additions and 319 deletions

View File

@@ -36,8 +36,6 @@ class Elemental(CMakePackage):
version('0.87.7', '6c1e7442021c59a36049e37ea69b8075')
version('0.87.6', '9fd29783d45b0a0e27c0df85f548abe9')
variant('debug', default=False,
description='Builds a debug version of the libraries')
variant('shared', default=True,
description='Enables the build of shared libraries')
variant('hybrid', default=True,
@@ -61,6 +59,9 @@ class Elemental(CMakePackage):
' Requires local build of BLAS library.')
variant('scalapack', default=False,
description='Build with ScaLAPACK library')
variant('build_type', default='Release',
description='The build type to build',
values=('Debug', 'Release'))
# Note that this forces us to use OpenBLAS until #1712 is fixed
depends_on('blas', when='~openmp_blas ~int64_blas')
@@ -85,15 +86,6 @@ def libs(self):
'libEl', root=self.prefix, shared=shared, recurse=True
)
def build_type(self):
"""Returns the correct value for the ``CMAKE_BUILD_TYPE`` variable
:return: value for ``CMAKE_BUILD_TYPE``
"""
if '+debug' in self.spec:
return 'Debug'
else:
return 'Release'
def cmake_args(self):
spec = self.spec