From d493658a583231eeb778613cf7b6c8c8641c63a0 Mon Sep 17 00:00:00 2001 From: Cyrus Harrison Date: Sun, 20 Mar 2016 15:18:36 -0700 Subject: [PATCH 1/2] cmake package: add variant for openssl support The openssl variant defaults to true to preserve spack's current CMake configuration, which is using OpenSSL. Signed-off-by: Cyrus Harrison --- var/spack/repos/builtin/packages/cmake/package.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/var/spack/repos/builtin/packages/cmake/package.py b/var/spack/repos/builtin/packages/cmake/package.py index cc93c7067c..be930a90ab 100644 --- a/var/spack/repos/builtin/packages/cmake/package.py +++ b/var/spack/repos/builtin/packages/cmake/package.py @@ -38,6 +38,7 @@ class Cmake(Package): version('2.8.10.2', '097278785da7182ec0aea8769d06860c') variant('ncurses', default=True, description='Enables the build of the ncurses gui') + variant('openssl', default=True, description="Enables CMake's OpenSSL features") variant('qt', default=False, description='Enables the build of cmake-gui') variant('doc', default=False, description='Enables the generation of html and man page documentation') @@ -77,8 +78,9 @@ def install(self, spec, prefix): options.append('--sphinx-html') options.append('--sphinx-man') - options.append('--') - options.append('-DCMAKE_USE_OPENSSL=ON') + if '+openssl' in spec: + options.append('--') + options.append('-DCMAKE_USE_OPENSSL=ON') configure(*options) make() From bba66cbe2836e364b58a611a5a5f5ae0d9692df4 Mon Sep 17 00:00:00 2001 From: Cyrus Harrison Date: Sun, 20 Mar 2016 19:27:22 -0700 Subject: [PATCH 2/2] cmake: depend on openssl when openssl variant=true --- var/spack/repos/builtin/packages/cmake/package.py | 1 + 1 file changed, 1 insertion(+) diff --git a/var/spack/repos/builtin/packages/cmake/package.py b/var/spack/repos/builtin/packages/cmake/package.py index be930a90ab..1f93d39769 100644 --- a/var/spack/repos/builtin/packages/cmake/package.py +++ b/var/spack/repos/builtin/packages/cmake/package.py @@ -43,6 +43,7 @@ class Cmake(Package): variant('doc', default=False, description='Enables the generation of html and man page documentation') depends_on('ncurses', when='+ncurses') + depends_on('openssl', when='+openssl') depends_on('qt', when='+qt') depends_on('python@2.7.11:', when='+doc') depends_on('py-sphinx', when='+doc')