update flecsi and legion package.py (#15159)
* update flecsi and legion package.py * comment out a conflict * update to use extend
This commit is contained in:
parent
45306206c7
commit
9b3f5f3890
2 changed files with 35 additions and 19 deletions
|
@ -22,10 +22,13 @@ class Flecsi(CMakePackage):
|
|||
|
||||
version('master', branch='master', submodules=False, preferred=True)
|
||||
|
||||
variant('build_type', default='Release', values=('Debug', 'Release'),
|
||||
variant('build_type', default='Release',
|
||||
values=('Debug', 'Release', 'RelWithDebInfo', 'MinSizeRel'),
|
||||
description='The build type to build', multi=False)
|
||||
variant('backend', default='mpi', values=('serial', 'mpi', 'legion', 'hpx'),
|
||||
description='Backend to use for distributed memory', multi=False)
|
||||
variant('debug_backend', default=False,
|
||||
description='Build Backend with Debug Mode')
|
||||
variant('minimal', default=False,
|
||||
description='Disable FindPackageMetis')
|
||||
variant('shared', default=True,
|
||||
|
@ -48,28 +51,32 @@ class Flecsi(CMakePackage):
|
|||
description='Build FleCSI Tutorials')
|
||||
variant('flecstan', default=False,
|
||||
description='Build FleCSI Static Analyzer')
|
||||
variant('cinch', default=False,
|
||||
description='Enable External Cinch')
|
||||
|
||||
depends_on('cmake@3.12:', type='build')
|
||||
# Requires cinch > 1.0 due to cinchlog installation issue
|
||||
depends_on('cinch@1.01:', type='build')
|
||||
depends_on('cinch@1.01:', type='build', when='+cinch')
|
||||
depends_on('mpi', when='backend=mpi')
|
||||
depends_on('mpi', when='backend=legion')
|
||||
depends_on('mpi', when='backend=hpx')
|
||||
depends_on('legion@ctrl-rep +shared +mpi +hdf5', when='backend=legion +hdf5')
|
||||
depends_on('legion@ctrl-rep +shared +mpi', when='backend=legion ~hdf5')
|
||||
depends_on('hpx@1.3.0 cxxstd=14', when='backend=hpx')
|
||||
depends_on('legion@ctrl-rep+shared+mpi+hdf5 build_type=Debug', when='backend=legion +debug_backend +hdf5')
|
||||
depends_on('legion@ctrl-rep+shared+mpi build_type=Debug', when='backend=legion +debug_backend ~hdf5')
|
||||
depends_on('legion@ctrl-rep+shared+mpi+hdf5 build_type=Release', when='backend=legion ~debug_backend +hdf5')
|
||||
depends_on('legion@ctrl-rep+shared+mpi build_type=Release', when='backend=legion ~debug_backend ~hdf5')
|
||||
depends_on('hpx@1.3.0 cxxstd=14 build_type=Debug', when='backend=hpx +debug_backend')
|
||||
depends_on('hpx@1.3.0 cxxstd=14 build_type=Release', when='backend=hpx ~debug_backend')
|
||||
depends_on('boost@1.70.0: cxxstd=14 +program_options')
|
||||
depends_on('metis@5.1.0:')
|
||||
depends_on('parmetis@4.0.3:')
|
||||
depends_on('hdf5', when='+hdf5')
|
||||
depends_on('hdf5+mpi', when='+hdf5')
|
||||
depends_on('caliper', when='+caliper')
|
||||
depends_on('graphviz', when='+graphviz')
|
||||
depends_on('python@3.0:', when='+tutorial')
|
||||
depends_on('llvm', when='+flecstan')
|
||||
|
||||
conflicts('+tutorial', when='backend=hpx')
|
||||
# conflicts('+hdf5', when='backend=hpx')
|
||||
# conflicts('+hdf5', when='backend=mpi')
|
||||
# conflicts('+hdf5', when='backend=hpx')
|
||||
|
||||
def cmake_args(self):
|
||||
spec = self.spec
|
||||
|
@ -80,6 +87,8 @@ def cmake_args(self):
|
|||
'-DENABLE_COLORING=ON',
|
||||
'-DENABLE_DEVEL_TARGETS=ON'
|
||||
]
|
||||
|
||||
if '+cinch' in spec:
|
||||
options.append('-DCINCH_SOURCE_DIR=' + spec['cinch'].prefix)
|
||||
|
||||
if spec.variants['backend'].value == 'legion':
|
||||
|
@ -95,6 +104,11 @@ def cmake_args(self):
|
|||
options.append('-DFLECSI_RUNTIME_MODEL=serial')
|
||||
options.append('-DENABLE_MPI=OFF')
|
||||
|
||||
if self.run_tests:
|
||||
options.append('-DENABLE_UNIT_TESTS=ON')
|
||||
else:
|
||||
options.append('-DENABLE_UNIT_TESTS=OFF')
|
||||
|
||||
if '+minimal' in spec:
|
||||
options.append('-DCMAKE_DISABLE_FIND_PACKAGE_METIS=ON')
|
||||
else:
|
||||
|
@ -104,12 +118,7 @@ def cmake_args(self):
|
|||
else:
|
||||
options.append('-DBUILD_SHARED_LIBS=OFF')
|
||||
|
||||
if self.run_tests:
|
||||
options.append('-DENABLE_UNIT_TESTS=ON')
|
||||
else:
|
||||
options.append('-DENABLE_UNIT_TESTS=OFF')
|
||||
|
||||
if '+hdf5' in spec and spec.variants['backend'].value == 'legion':
|
||||
if '+hdf5' in spec and spec.variants['backend'].value != 'hpx':
|
||||
options.append('-DENABLE_HDF5=ON')
|
||||
else:
|
||||
options.append('-DENABLE_HDF5=OFF')
|
||||
|
|
|
@ -27,6 +27,8 @@ class Legion(CMakePackage):
|
|||
|
||||
version('master', branch='master')
|
||||
version('ctrl-rep', branch='control_replication')
|
||||
version('ctrl-rep-4', commit='b66083076016c63ea8398fdb89c237880fcb0173')
|
||||
version('ctrl-rep-3', commit='572576b312509e666f2d72fafdbe9d968b1a6ac3')
|
||||
version('ctrl-rep-2', commit='96682fd8aae071ecd30a3ed5f481a9d84457a4b6')
|
||||
version('ctrl-rep-1', commit='a03671b21851d5f0d3f63210343cb61a630f4405')
|
||||
version('ctrl-rep-0', commit='177584e77036c9913d8a62e33b55fa784748759c')
|
||||
|
@ -46,14 +48,15 @@ class Legion(CMakePackage):
|
|||
description='Build on top of ibv conduit for InfiniBand support')
|
||||
variant('shared', default=True, description='Build shared libraries')
|
||||
variant('hdf5', default=True, description='Enable HDF5 support')
|
||||
variant('build_type', default='Release', values=('Debug', 'Release'),
|
||||
description='The build type to build')
|
||||
variant('build_type', default='Release',
|
||||
values=('Debug', 'Release', 'RelWithDebInfo', 'MinSizeRel'),
|
||||
description='The build type to build', multi=False)
|
||||
|
||||
depends_on("cmake@3.1:", type='build')
|
||||
depends_on("gasnet~aligned-segments~pshm segment-mmap-max='16GB'", when='~mpi')
|
||||
depends_on("gasnet~aligned-segments~pshm segment-mmap-max='16GB' +mpi", when='+mpi')
|
||||
depends_on("gasnet~aligned-segments~pshm segment-mmap-max='16GB' +ibv", when='+ibv')
|
||||
depends_on("hdf5~mpi", when='+hdf5')
|
||||
depends_on("hdf5", when='+hdf5')
|
||||
|
||||
def cmake_args(self):
|
||||
cmake_cxx_flags = [
|
||||
|
@ -69,7 +72,11 @@ def cmake_args(self):
|
|||
'-DBUILD_SHARED_LIBS=%s' % ('+shared' in self.spec)]
|
||||
|
||||
if self.spec.variants['build_type'].value == 'Debug':
|
||||
cmake_cxx_flags.append('-DDEBUG_REALM', '-DDEBUG_LEGION', '-ggdb')
|
||||
cmake_cxx_flags.extend([
|
||||
'-DDEBUG_REALM',
|
||||
'-DDEBUG_LEGION',
|
||||
'-ggdb',
|
||||
])
|
||||
|
||||
options.append('-DCMAKE_CXX_FLAGS=%s' % (" ".join(cmake_cxx_flags)))
|
||||
|
||||
|
|
Loading…
Reference in a new issue