diff options
author | Amjad Kotobi <amjadkotbi@gmail.com> | 2020-07-03 00:10:06 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-02 15:10:06 -0700 |
commit | 06da1f195c006d3aa1c3d43b4454a10d1ce06ee9 (patch) | |
tree | 7f368b4759b7a22d3d66efca413c89e772025b7c /var | |
parent | 3d98ad3f4cc82e96dce25c7a70db2f59456b864a (diff) | |
download | spack-06da1f195c006d3aa1c3d43b4454a10d1ce06ee9.tar.gz spack-06da1f195c006d3aa1c3d43b4454a10d1ce06ee9.tar.bz2 spack-06da1f195c006d3aa1c3d43b4454a10d1ce06ee9.tar.xz spack-06da1f195c006d3aa1c3d43b4454a10d1ce06ee9.zip |
openmpi: add singularity variant (#17288)
Diffstat (limited to 'var')
-rw-r--r-- | var/spack/repos/builtin/packages/openmpi/package.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/openmpi/package.py b/var/spack/repos/builtin/packages/openmpi/package.py index 4184e64f02..82838e5a87 100644 --- a/var/spack/repos/builtin/packages/openmpi/package.py +++ b/var/spack/repos/builtin/packages/openmpi/package.py @@ -219,6 +219,8 @@ class Openmpi(AutotoolsPackage): variant('cxx', default=False, description='Enable C++ MPI bindings') variant('cxx_exceptions', default=False, description='Enable C++ Exception support') variant('gpfs', default=True, description='Enable GPFS support (if present)') + variant('singularity', default=False, + description="Build support for the Singularity container") # Adding support to build a debug version of OpenMPI that activates # Memchecker, as described here: # @@ -265,6 +267,8 @@ class Openmpi(AutotoolsPackage): depends_on('sqlite', when='+sqlite3@:1.11') depends_on('zlib', when='@3.0.0:') depends_on('valgrind~mpi', when='+memchecker') + # Singularity release 3 works better + depends_on('singularity@3.0.0:', when='+singularity') depends_on('opa-psm2', when='fabrics=psm2') depends_on('rdma-core', when='fabrics=verbs') @@ -317,6 +321,8 @@ class Openmpi(AutotoolsPackage): conflicts('schedulers=loadleveler', when='@3.0.0:', msg='The loadleveler scheduler is not supported with ' 'openmpi(>=3.0.0).') + conflicts('+singularity', when='@5:', + msg='singularity support has been dropped in OpenMPI 5') filter_compiler_wrappers('openmpi/*-wrapper-data*', relative_root='share') @@ -528,6 +534,10 @@ class Openmpi(AutotoolsPackage): '--with-valgrind={0}'.format(spec['valgrind'].prefix), ]) + # Singularity container support + if spec.satisfies('+singularity @:4.9'): + singularity_opt = '--with-singularity={0}'.format(spec['singularity'].prefix) + config_args.append(singularity_opt) # Hwloc support if spec.satisfies('@1.5.2:'): config_args.append('--with-hwloc={0}'.format(spec['hwloc'].prefix)) |