Update of Flecsi Spackage (#24106)
* Update of Flecsi Spackage Update of flecsi spackage to reconcile differences between flecsi@1:1.9 and flecsi@2: for future support purposes * Removing Unnecessary Conditional Removing unused conditional. Initially the plan was to switch based on version in `cmake_args` but this was not necessary as build system variable names remained mostly the same and conflicts prevent the rest. For the most part, if a variant is there it does not need to check against what version of the code is being built. * Updated CI To Reconcile Flecsi Changes Updated CI to target flecsi@1.4.2 which best matches the previous release version and reconciled change in variant name
This commit is contained in:
@@ -222,7 +222,7 @@ spack:
|
|||||||
- darshan-util
|
- darshan-util
|
||||||
- dyninst
|
- dyninst
|
||||||
- faodel
|
- faodel
|
||||||
- flecsi +cinch
|
- flecsi@1.4.2 +external_cinch
|
||||||
- flit
|
- flit
|
||||||
- fortrilinos ^trilinos +nox +superlu-dist +stratimikos
|
- fortrilinos ^trilinos +nox +superlu-dist +stratimikos
|
||||||
- gasnet
|
- gasnet
|
||||||
|
@@ -7,7 +7,7 @@
|
|||||||
from spack import *
|
from spack import *
|
||||||
|
|
||||||
|
|
||||||
class Flecsi(CMakePackage):
|
class Flecsi(CMakePackage, CudaPackage):
|
||||||
'''FleCSI is a compile-time configurable framework designed to support
|
'''FleCSI is a compile-time configurable framework designed to support
|
||||||
multi-physics application development. As such, FleCSI attempts to
|
multi-physics application development. As such, FleCSI attempts to
|
||||||
provide a very general set of infrastructure design patterns that can
|
provide a very general set of infrastructure design patterns that can
|
||||||
@@ -18,20 +18,21 @@ class Flecsi(CMakePackage):
|
|||||||
interfaces,and dependency closures.
|
interfaces,and dependency closures.
|
||||||
'''
|
'''
|
||||||
homepage = 'http://flecsi.org/'
|
homepage = 'http://flecsi.org/'
|
||||||
git = 'https://github.com/laristra/flecsi.git'
|
git = 'https://github.com/flecsi/flecsi.git'
|
||||||
|
maintainers = ['rspavel', 'ktsai7']
|
||||||
|
|
||||||
version('devel', branch='devel', submodules=False, preferred=False)
|
version('develop', branch='devel', submodules=False)
|
||||||
version('1', branch='1', submodules=False, preferred=False)
|
version('1', git="https://github.com/laristra/flecsi.git", branch='1', submodules=False, preferred=False)
|
||||||
version('1.4', branch='1.4', submodules=False, preferred=True)
|
version('1.4', git="https://github.com/laristra/flecsi.git", branch='1.4', submodules=False, preferred=False)
|
||||||
|
version('1.4.2', git="https://github.com/laristra/flecsi.git", tag='v1.4.2', submodules=False, preferred=True)
|
||||||
|
version('2.1.0', tag='v2.1.0', submodules=False, preferred=False)
|
||||||
|
version('flecsph', git="https://github.com/laristra/flecsi.git", branch="stable/flecsph", submodules=True, preferred=False)
|
||||||
|
|
||||||
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', 'charmpp'),
|
variant('backend', default='mpi', values=('serial', 'mpi', 'legion', 'hpx', 'charmpp'),
|
||||||
description='Backend to use for distributed memory', multi=False)
|
description='Backend to use for distributed memory', multi=False)
|
||||||
variant('debug_backend', default=False,
|
variant('debug_backend', default=False,
|
||||||
description='Build Backend with Debug Mode')
|
description='Build Backend with Debug Mode')
|
||||||
variant('minimal', default=False,
|
variant('disable_metis', default=False,
|
||||||
description='Disable FindPackageMetis')
|
description='Disable FindPackageMetis')
|
||||||
variant('shared', default=True,
|
variant('shared', default=True,
|
||||||
description='Build shared libraries')
|
description='Build shared libraries')
|
||||||
@@ -45,54 +46,97 @@ class Flecsi(CMakePackage):
|
|||||||
description='Enable coverage build')
|
description='Enable coverage build')
|
||||||
variant('hdf5', default=True,
|
variant('hdf5', default=True,
|
||||||
description='Enable HDF5 Support')
|
description='Enable HDF5 Support')
|
||||||
variant('caliper', default=False,
|
variant('caliper_detail', default='none',
|
||||||
description='Enable Caliper Support')
|
values=('none', 'low', 'medium', 'high'),
|
||||||
|
description='Set Caliper Profiling Detail', multi=False)
|
||||||
variant('graphviz', default=False,
|
variant('graphviz', default=False,
|
||||||
description='Enable GraphViz Support')
|
description='Enable GraphViz Support')
|
||||||
variant('tutorial', default=False,
|
variant('tutorial', default=False,
|
||||||
description='Build FleCSI Tutorials')
|
description='Build FleCSI Tutorials')
|
||||||
variant('flecstan', default=False,
|
variant('flecstan', default=False,
|
||||||
description='Build FleCSI Static Analyzer')
|
description='Build FleCSI Static Analyzer')
|
||||||
variant('cinch', default=False,
|
variant('external_cinch', default=True,
|
||||||
description='Enable External Cinch')
|
description='Enable External Cinch')
|
||||||
|
variant('kokkos', default=False,
|
||||||
|
description='Enable Kokkos Support')
|
||||||
|
variant('unit_tests', default=False,
|
||||||
|
description='Build with Unit Tests Enabled')
|
||||||
|
variant('openmp', default=False,
|
||||||
|
description='Enable OpenMP Support')
|
||||||
|
|
||||||
depends_on('cmake@3.12:')
|
# All Current FLecsi Releases
|
||||||
# Requires cinch > 1.0 due to cinchlog installation issue
|
for level in ('low', 'medium', 'high'):
|
||||||
depends_on('cinch@1.01:', type='build', when='+cinch')
|
depends_on('caliper', when='caliper_detail=%s' % level)
|
||||||
depends_on('mpi', when='backend=mpi')
|
depends_on('caliper@2.0.1~adiak', when='@:1.9 caliper_detail=%s' % level)
|
||||||
depends_on('mpi', when='backend=legion')
|
depends_on('graphviz', when='+graphviz')
|
||||||
depends_on('mpi', when='backend=hpx')
|
depends_on('hdf5+mpi', when='+hdf5')
|
||||||
depends_on('legion+shared', when='backend=legion')
|
|
||||||
depends_on('legion+hdf5', when='backend=legion +hdf5')
|
|
||||||
depends_on('legion build_type=Debug', when='backend=legion +debug_backend')
|
|
||||||
depends_on('hpx@1.4.1 cxxstd=17 malloc=system max_cpu_count=128', when='backend=hpx')
|
|
||||||
depends_on('hpx build_type=Debug', when='backend=hpx +debug_backend')
|
|
||||||
depends_on('boost@1.70.0: cxxstd=17 +program_options')
|
|
||||||
depends_on('metis@5.1.0:')
|
depends_on('metis@5.1.0:')
|
||||||
depends_on('parmetis@4.0.3:')
|
depends_on('parmetis@4.0.3:')
|
||||||
depends_on('googletest@1.8.1+gmock')
|
depends_on('boost@1.70.0: cxxstd=17 +program_options')
|
||||||
depends_on('hdf5+hl+mpi', when='+hdf5')
|
|
||||||
depends_on('caliper@2.0.1~adiak', when='+caliper')
|
# Flecsi@1.x
|
||||||
depends_on('graphviz', when='+graphviz')
|
depends_on('cmake@3.12:', when='@:1.9')
|
||||||
depends_on('python@3.0:', when='+tutorial')
|
# Requires cinch > 1.0 due to cinchlog installation issue
|
||||||
depends_on('doxygen', when='+doxygen')
|
depends_on('cinch@1.01:', type='build', when='+external_cinch @:1.9')
|
||||||
depends_on('llvm', when='+flecstan')
|
depends_on('mpi', when='backend=mpi @:1.9')
|
||||||
depends_on('pfunit@3.0:3.99')
|
depends_on('mpi', when='backend=legion @:1.9')
|
||||||
|
depends_on('mpi', when='backend=hpx @:1.9')
|
||||||
|
depends_on('legion+shared+mpi', when='backend=legion @:1.9')
|
||||||
|
depends_on('legion+hdf5', when='backend=legion +hdf5 @:1.9')
|
||||||
|
depends_on('legion build_type=Debug', when='backend=legion +debug_backend @:1.9')
|
||||||
|
depends_on('hpx@1.4.1 cxxstd=17 malloc=system max_cpu_count=128', when='backend=hpx@:1.9')
|
||||||
|
depends_on('hpx build_type=Debug', when='backend=hpx +debug_backend @:1.9')
|
||||||
|
depends_on('googletest@1.8.1+gmock', when='@:1.9')
|
||||||
|
depends_on('hdf5+hl', when='+hdf5 @:1.9')
|
||||||
|
depends_on('python@3.0:', when='+tutorial @:1.9')
|
||||||
|
depends_on('doxygen', when='+doxygen @:1.9')
|
||||||
|
depends_on('llvm', when='+flecstan @:1.9')
|
||||||
|
depends_on('pfunit@3.0:3.99', when='@:1.9')
|
||||||
|
depends_on('py-gcovr', when='+coverage @:1.9')
|
||||||
|
|
||||||
|
# Flecsi@2.x
|
||||||
|
depends_on('cmake@3.15:', when='@2.0:')
|
||||||
|
depends_on('boost@1.70.0 +atomic +filesystem +regex +system', when='@2.0:')
|
||||||
|
depends_on('kokkos@3.2.00:', when='+kokkos @2.0:')
|
||||||
|
depends_on('legion@ctrl-rep-9:ctrl-rep-99', when='backend=legion @2.0:')
|
||||||
|
depends_on('legion+hdf5', when='backend=legion +hdf5 @2.0:')
|
||||||
|
depends_on('hdf5@1.10.7:', when='backend=legion +hdf5 @2.0:')
|
||||||
|
depends_on('hpx@1.3.0 cxxstd=17 malloc=system', when='backend=hpx @2.0:')
|
||||||
|
depends_on('kokkos@3.2.00:', when='+kokkos @2.0:')
|
||||||
|
depends_on('mpich@3.4.1', when='@2.0: ^mpich')
|
||||||
|
depends_on('openmpi@4.1.0', when='@2.0: ^openmpi')
|
||||||
|
|
||||||
conflicts('+tutorial', when='backend=hpx')
|
conflicts('+tutorial', when='backend=hpx')
|
||||||
# conflicts('+hdf5', when='backend=hpx')
|
# Flecsi@2: no longer supports serial or charmpp backends
|
||||||
|
conflicts('backend=serial', when='@2.0:')
|
||||||
|
conflicts('backend=charmpp', when='@2.0:')
|
||||||
|
# FLecsi@2: no longer expects to control how backend is built
|
||||||
|
conflicts('+debug_backend', when='@2.0:')
|
||||||
|
# Flecsi@2: No longer supports previous TPL related flags
|
||||||
|
conflicts('+disable_metis', when='@2.0:')
|
||||||
|
# Flecsi@2: no longer provides documentation variants
|
||||||
|
conflicts('+doxygen', when='@2.0:')
|
||||||
|
conflicts('+doc', when='@2.0:')
|
||||||
|
# Flecsi@2: no longer provides coverage variants
|
||||||
|
conflicts('+coverage', when='@2.0:')
|
||||||
|
# Flecsi@2: no longer provides tutorial variants
|
||||||
|
conflicts('+tutorial', when='@2.0:')
|
||||||
|
# Flecsi@2: no longer supports flecstan
|
||||||
|
conflicts('+flecstan', when='@2.0:')
|
||||||
|
# Flecsi@2: integrates cinch and no longer depends on external installs
|
||||||
|
conflicts('+external_cinch', when='@2.0:')
|
||||||
|
# Current Flecsi@:1.9 releases do not support kokkos, omp, or cuda
|
||||||
|
conflicts('+kokkos', when='@:1.9')
|
||||||
|
conflicts('+openmp', when='@:1.9')
|
||||||
|
conflicts('+cuda', when='@:1.9')
|
||||||
|
# Unit tests require flog support
|
||||||
|
conflicts('+unit_tests', when='~flog')
|
||||||
|
|
||||||
def cmake_args(self):
|
def cmake_args(self):
|
||||||
spec = self.spec
|
spec = self.spec
|
||||||
options = ['-DENABLE_OPENMP=ON',
|
options = []
|
||||||
'-DCXX_CONFORMANCE_STANDARD=c++17',
|
|
||||||
'-DENABLE_METIS=ON',
|
|
||||||
'-DENABLE_PARMETIS=ON',
|
|
||||||
'-DENABLE_COLORING=ON',
|
|
||||||
'-DENABLE_DEVEL_TARGETS=ON'
|
|
||||||
]
|
|
||||||
|
|
||||||
if '+cinch' in spec:
|
if '+external_cinch' in spec:
|
||||||
options.append('-DCINCH_SOURCE_DIR=' + spec['cinch'].prefix)
|
options.append('-DCINCH_SOURCE_DIR=' + spec['cinch'].prefix)
|
||||||
|
|
||||||
if spec.variants['backend'].value == 'legion':
|
if spec.variants['backend'].value == 'legion':
|
||||||
@@ -112,28 +156,53 @@ def cmake_args(self):
|
|||||||
options.append('-DFLECSI_RUNTIME_MODEL=serial')
|
options.append('-DFLECSI_RUNTIME_MODEL=serial')
|
||||||
options.append('-DENABLE_MPI=OFF')
|
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:
|
|
||||||
options.append('-DCMAKE_DISABLE_FIND_PACKAGE_METIS=OFF')
|
|
||||||
if '+shared' in spec:
|
if '+shared' in spec:
|
||||||
options.append('-DBUILD_SHARED_LIBS=ON')
|
options.append('-DBUILD_SHARED_LIBS=ON')
|
||||||
else:
|
else:
|
||||||
options.append('-DBUILD_SHARED_LIBS=OFF')
|
options.append('-DBUILD_SHARED_LIBS=OFF')
|
||||||
|
|
||||||
|
options.append('-DCALIPER_DETAIL=%s' %
|
||||||
|
spec.variants['caliper_detail'].value)
|
||||||
|
if spec.satisfies('@:1.9'):
|
||||||
|
if spec.variants['caliper_detail'].value == 'none':
|
||||||
|
options.append('-DENABLE_CALIPER=OFF')
|
||||||
|
else:
|
||||||
|
options.append('-DENABLE_CALIPER=ON')
|
||||||
|
|
||||||
|
if self.run_tests or '+unit' in spec:
|
||||||
|
options.append('-DENABLE_UNIT_TESTS=ON')
|
||||||
|
else:
|
||||||
|
options.append('-DENABLE_UNIT_TESTS=OFF')
|
||||||
|
|
||||||
|
if ('+flog' in spec):
|
||||||
|
options.append('-DENABLE_FLOG=ON')
|
||||||
|
else:
|
||||||
|
options.append('-DENABLE_FLOG=OFF')
|
||||||
|
|
||||||
if '+hdf5' in spec and spec.variants['backend'].value != 'hpx':
|
if '+hdf5' in spec and spec.variants['backend'].value != 'hpx':
|
||||||
options.append('-DENABLE_HDF5=ON')
|
options.append('-DENABLE_HDF5=ON')
|
||||||
else:
|
else:
|
||||||
options.append('-DENABLE_HDF5=OFF')
|
options.append('-DENABLE_HDF5=OFF')
|
||||||
if '+caliper' in spec:
|
|
||||||
options.append('-DENABLE_CALIPER=ON')
|
if '+graphviz' in spec:
|
||||||
|
options.append('-DENABLE_GRAPHVIZ=ON')
|
||||||
else:
|
else:
|
||||||
options.append('-DENABLE_CALIPER=OFF')
|
options.append('-DENABLE_GRAPHVIZ=OFF')
|
||||||
|
|
||||||
|
if '+kokkos' in spec:
|
||||||
|
options.append('-DENABLE_KOKKOS=ON')
|
||||||
|
else:
|
||||||
|
options.append('-DENABLE_KOKKOS=OFF')
|
||||||
|
if '+openmp' in spec:
|
||||||
|
options.append('-DENABLE_OPENMP=ON')
|
||||||
|
else:
|
||||||
|
options.append('-DENABLE_OPENMP=OFF')
|
||||||
|
|
||||||
|
if '+disable_metis' in spec:
|
||||||
|
options.append('-DCMAKE_DISABLE_FIND_PACKAGE_METIS=ON')
|
||||||
|
else:
|
||||||
|
options.append('-DCMAKE_DISABLE_FIND_PACKAGE_METIS=OFF')
|
||||||
|
|
||||||
if '+tutorial' in spec:
|
if '+tutorial' in spec:
|
||||||
options.append('-DENABLE_FLECSIT=ON')
|
options.append('-DENABLE_FLECSIT=ON')
|
||||||
options.append('-DENABLE_FLECSI_TUTORIAL=ON')
|
options.append('-DENABLE_FLECSI_TUTORIAL=ON')
|
||||||
|
Reference in New Issue
Block a user