summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAxel Huebl <axel.huebl@plasma.ninja>2021-01-04 19:05:11 -0800
committerGitHub <noreply@github.com>2021-01-04 21:05:11 -0600
commite6d462589f2437997c4d3c05305b89b986f7f57f (patch)
tree79b753968c62bee76224fe08560690a73e12f702
parente5b03770ed9f17406ca9015c56b3f30e8624d8c6 (diff)
downloadspack-e6d462589f2437997c4d3c05305b89b986f7f57f.tar.gz
spack-e6d462589f2437997c4d3c05305b89b986f7f57f.tar.bz2
spack-e6d462589f2437997c4d3c05305b89b986f7f57f.tar.xz
spack-e6d462589f2437997c4d3c05305b89b986f7f57f.zip
OpenMPI: Depends on hwlock & libevent (#20658)
* OpenMPI: Depends on hwlock & libevent Both hwlock & libevent are required dependencies of Open MPI. While they are also shipped internally, newer releases (>=4.0) will start looking for external packages by default. This caused build issues of Open MPI 4.0.5 with Fortran on macOS 10.15. * Open MPI 4.0: libevent external Internally shipped libevent just works fine for prior releases.
-rw-r--r--var/spack/repos/builtin/packages/openmpi/package.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/openmpi/package.py b/var/spack/repos/builtin/packages/openmpi/package.py
index c66e2b830a..fb5d70f34f 100644
--- a/var/spack/repos/builtin/packages/openmpi/package.py
+++ b/var/spack/repos/builtin/packages/openmpi/package.py
@@ -266,6 +266,8 @@ class Openmpi(AutotoolsPackage):
depends_on('pkgconfig', type='build')
+ depends_on('libevent@2.0:', when='@4:')
+
depends_on('hwloc@2.0:', when='@4:')
# ompi@:3.0.0 doesn't support newer hwloc releases:
# "configure: error: OMPI does not currently support hwloc v2 API"
@@ -676,6 +678,9 @@ class Openmpi(AutotoolsPackage):
if spec.satisfies('+lustre'):
lustre_opt = '--with-lustre={0}'.format(spec['lustre'].prefix)
config_args.append(lustre_opt)
+ # external libevent
+ if spec.satisfies('@4.0.0:'):
+ config_args.append('--with-libevent={0}'.format(spec['libevent'].prefix))
# Hwloc support
if spec.satisfies('@1.5.2:'):
config_args.append('--with-hwloc={0}'.format(spec['hwloc'].prefix))