diff options
Diffstat (limited to 'var/spack/repos/builtin/packages/legion/package.py')
-rw-r--r-- | var/spack/repos/builtin/packages/legion/package.py | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/var/spack/repos/builtin/packages/legion/package.py b/var/spack/repos/builtin/packages/legion/package.py index ddfa8a8b94..2d93ee0e3a 100644 --- a/var/spack/repos/builtin/packages/legion/package.py +++ b/var/spack/repos/builtin/packages/legion/package.py @@ -47,9 +47,13 @@ class Legion(CMakePackage): version('17.02.0', '31ac3004e2fb0996764362d2b6f6844a') variant('debug', default=False, description='Build debug version') + variant('mpi', default=True, + description='Build on top of mpi conduit for mpi inoperability') + variant('shared', default=True, description='Build shared libraries') depends_on("cmake@3.1:", type='build') - depends_on("gasnet") + depends_on("gasnet", when='~mpi') + depends_on("gasnet+mpi", when='+mpi') def build_type(self): spec = self.spec @@ -59,4 +63,12 @@ class Legion(CMakePackage): return 'Release' def cmake_args(self): - return ['-DLegion_USE_GASNet=ON', '-DLegion_BUILD_EXAMPLES=ON'] + options = [ + '-DLegion_USE_GASNet=ON', + '-DLegion_BUILD_EXAMPLES=ON', + '-DBUILD_SHARED_LIBS=%s' % ('+shared' in spec)] + + if '+mpi' in self.spec: + options.append('-DGASNet_CONDUIT=mpi') + + return options |