diff options
author | Kevin Huck <khuck@cs.uoregon.edu> | 2021-06-01 11:14:18 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-01 20:14:18 +0200 |
commit | 73c78358a811c61dbcdbe777ed40dc109f86876b (patch) | |
tree | 09864fdcfb6b24647bb10ca2f7741912aa931364 | |
parent | 50dac14d109398a0e46d9168a0d490ecf1a739d2 (diff) | |
download | spack-73c78358a811c61dbcdbe777ed40dc109f86876b.tar.gz spack-73c78358a811c61dbcdbe777ed40dc109f86876b.tar.bz2 spack-73c78358a811c61dbcdbe777ed40dc109f86876b.tar.xz spack-73c78358a811c61dbcdbe777ed40dc109f86876b.zip |
apex: updated package, added maintainer (#18569)
Adding versions: 2.2.0, 2.3.0, 2.3.1, 2.3.2, 2.4.0
-rw-r--r-- | var/spack/repos/builtin/packages/apex/package.py | 116 |
1 files changed, 99 insertions, 17 deletions
diff --git a/var/spack/repos/builtin/packages/apex/package.py b/var/spack/repos/builtin/packages/apex/package.py index 7222670768..21e6d67ddc 100644 --- a/var/spack/repos/builtin/packages/apex/package.py +++ b/var/spack/repos/builtin/packages/apex/package.py @@ -4,30 +4,112 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) from spack import * +import sys class Apex(CMakePackage): """Autonomic Performance Environment for eXascale (APEX).""" - homepage = "http://github.com/khuck/xpress-apex" - url = "http://github.com/khuck/xpress-apex/archive/v0.1.tar.gz" + maintainers = ['khuck'] + homepage = "https://github.com/khuck/xpress-apex" + url = "https://github.com/khuck/xpress-apex/archive/v2.3.1.tar.gz" + git = "https://github.com/khuck/xpress-apex" - version('0.1', sha256='efd10f38a61ebdb9f8adee9dc84acaee22d065b2e6eea1888872a7bfca0f4495') + version('develop', branch='develop') + version('master', branch='master') + version('2.4.0', sha256='15d8957da7b37d2c684a6f0f32aef65b0b26be6558da17963cf71f3fd3cfdf2f') + version('2.3.2', sha256='acf37c024a2283cafbf206f508929208b62c8f800af22ad7c74c570863a31bb4') + version('2.3.1', sha256='86bf6933f2c53531fcb24cda9fc7dc9919909bed54740d1e0bc3e7ce6ed78091') + version('2.3.0', sha256='7e1d16c9651b913c5e28abdbad75f25c55ba25e9fa35f5d979c1d3f9b9852c58') + version('2.2.0', sha256='cd5eddb1f6d26b7dbb4a8afeca2aa28036c7d0987e0af0400f4f96733889c75c') - depends_on("binutils+libiberty@:2.33.1") - depends_on("boost@1.54:") - depends_on('cmake@2.8.12:', type='build') - depends_on("activeharmony@4.5:") - depends_on("ompt-openmp") + # Disable some default dependencies on Darwin/OSX + darwin_default = False + if sys.platform != 'darwin': + darwin_default = True + + # Enable by default + variant('activeharmony', default=True, description='Enables Active Harmony support') + variant('plugins', default=True, description='Enables Policy Plugin support') + variant('binutils', default=True, description='Enables Binutils support') + variant('otf2', default=True, description='Enables OTF2 support') + variant('gperftools', default=True, description='Enables Google PerfTools TCMalloc support') + variant('openmp', default=darwin_default, description='Enables OpenMP support') + variant('papi', default=darwin_default, description='Enables PAPI support') + + # Disable by default + variant('cuda', default=False, description='Enables CUDA support') + variant('boost', default=False, description='Enables Boost support') + variant('jemalloc', default=False, description='Enables JEMalloc support') + variant('lmsensors', default=False, description='Enables LM-Sensors support') + variant('mpi', default=False, description='Enables MPI support') + variant('tests', default=False, description='Build Unit Tests') + variant('examples', default=False, description='Build Examples') + + # Dependencies + depends_on('cmake@3.10.0:', type='build') + depends_on('binutils@2.33:+libiberty+headers', when='+binutils') + depends_on('activeharmony@4.6:', when='+activeharmony') + depends_on('activeharmony@4.6:', when='+plugins') + depends_on('otf2@2.1:', when='+otf2') + depends_on('mpi', when='+mpi') + depends_on('gperftools', when='+gperftools') + depends_on('jemalloc', when='+jemalloc') + depends_on('papi@5.7.0:', when='+papi') + depends_on('cuda', when='+cuda') + depends_on('boost@1.54:', when='+boost') + + # Conflicts + conflicts('+jemalloc', when='+gperftools') + conflicts('+plugins', when='~activeharmony') def cmake_args(self): + args = [] spec = self.spec - return [ - '-DBOOST_ROOT=%s' % spec['boost'].prefix, - '-DUSE_BFD=TRUE', - '-DBFD_ROOT=%s' % spec['binutils'].prefix, - '-DUSE_ACTIVEHARMONY=TRUE', - '-DACTIVEHARMONY_ROOT=%s' % spec['activeharmony'].prefix, - '-DUSE_OMPT=TRUE', - '-DOMPT_ROOT=%s' % spec['ompt-openmp'].prefix, - ] + # CMake variables were updated in version 2.3.0, to make + prefix = 'APEX_WITH' + test_prefix = 'APEX_' + if '@2.2.0' in spec: + prefix = 'USE' + test_prefix = '' + + args.append(self.define_from_variant(prefix + '_ACTIVEHARMONY', + 'activeharmony')) + args.append(self.define_from_variant(prefix + '_BFD', 'binutils')) + args.append(self.define_from_variant('APEX_WITH_CUDA', 'cuda')) + args.append(self.define_from_variant(prefix + '_MPI', 'mpi')) + args.append(self.define_from_variant(prefix + '_OMPT', 'openmp')) + args.append(self.define_from_variant(prefix + '_OTF2', 'otf2')) + args.append(self.define_from_variant(prefix + '_PAPI', 'papi')) + args.append(self.define_from_variant(prefix + '_PLUGINS', 'plugins')) + args.append(self.define_from_variant(prefix + '_LM_SENSORS', 'lmsensors')) + args.append(self.define_from_variant(prefix + '_TCMALLOC', 'gperftools')) + args.append(self.define_from_variant(prefix + '_JEMALLOC', 'jemalloc')) + args.append(self.define_from_variant(test_prefix + 'BUILD_TESTS', 'tests')) + args.append(self.define_from_variant(test_prefix + 'BUILD_EXAMPLES', + 'examples')) + + if '+activeharmony' in spec: + args.append('-DACTIVEHARMONY_ROOT={0}'.format( + spec['activeharmony'].prefix)) + + if '+binutils' in spec: + args.append('-DBFD_ROOT={0}'.format(spec['binutils'].prefix)) + + if '+otf2' in spec: + args.append('-DOTF2_ROOT={0}'.format(spec['otf2'].prefix)) + + if '+papi' in spec: + args.append('-DPAPI_ROOT={0}'.format(spec['papi'].prefix)) + + if '+gperftools' in spec: + args.append('-DGPERFTOOLS_ROOT={0}'.format( + spec['gperftools'].prefix)) + + if '+jemalloc' in spec: + args.append('-DJEMALLOC_ROOT={0}'.format(spec['jemalloc'].prefix)) + + if '+boost' in spec: + args.append('-DBOOST_ROOT={0}'.format(spec['boost'].prefix)) + + return args |