summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--var/spack/repos/builtin/packages/petaca/package.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/var/spack/repos/builtin/packages/petaca/package.py b/var/spack/repos/builtin/packages/petaca/package.py
index 29abe2304c..1d9214dc41 100644
--- a/var/spack/repos/builtin/packages/petaca/package.py
+++ b/var/spack/repos/builtin/packages/petaca/package.py
@@ -35,6 +35,8 @@ class Petaca(CMakePackage):
description='Type build type to build',
values=('Debug', 'Release'))
+ variant('shared', default=False, description='build shared libraries')
+
# copied from openmpi/package.py to ensure fortran support
@run_before('cmake')
def die_without_fortran(self):
@@ -45,5 +47,6 @@ class Petaca(CMakePackage):
def cmake_args(self):
return [
- self.define('ENABLE_TESTS', self.run_tests)
+ self.define('ENABLE_TESTS', self.run_tests),
+ self.define_from_variant("BUILD_SHARED_LIBS", "shared")
]