diff options
author | Pramod Kumbhar <pramod.s.kumbhar@gmail.com> | 2017-02-21 00:39:51 +0100 |
---|---|---|
committer | Todd Gamblin <tgamblin@llnl.gov> | 2017-02-20 15:39:51 -0800 |
commit | 8c2f5baa195457d9890d0624ee810a9adec6cbf7 (patch) | |
tree | 7bb211cd99b48df094765acc840ad41471a8dda8 /var/spack/repos/builtin/packages/zoltan | |
parent | 4de85ab4b79f81b82603f6eee5b68065535106f5 (diff) | |
download | spack-8c2f5baa195457d9890d0624ee810a9adec6cbf7.tar.gz spack-8c2f5baa195457d9890d0624ee810a9adec6cbf7.tar.bz2 spack-8c2f5baa195457d9890d0624ee810a9adec6cbf7.tar.xz spack-8c2f5baa195457d9890d0624ee810a9adec6cbf7.zip |
Fix zoltan installation issue on bg-q #3193 (#3194)
Zoltan expects mpi libraries with option --with-mpi-libs.
If this option is not provided then it uses '-lmpi' which
may not be correct. To avoid this, we have to explicitly
pass empty string.
This adds notes to the source explaining the change.
Diffstat (limited to 'var/spack/repos/builtin/packages/zoltan')
-rw-r--r-- | var/spack/repos/builtin/packages/zoltan/package.py | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/var/spack/repos/builtin/packages/zoltan/package.py b/var/spack/repos/builtin/packages/zoltan/package.py index 8d4dd321b0..21c90a05e4 100644 --- a/var/spack/repos/builtin/packages/zoltan/package.py +++ b/var/spack/repos/builtin/packages/zoltan/package.py @@ -88,9 +88,18 @@ class Zoltan(Package): config_args.append('CXX={0}'.format(spec['mpi'].mpicxx)) config_args.append('FC={0}'.format(spec['mpi'].mpifc)) - mpi_libs = ' -l'.join(self.get_mpi_libs()) config_args.append('--with-mpi={0}'.format(spec['mpi'].prefix)) - config_args.append('--with-mpi-libs=-l{0}'.format(mpi_libs)) + + mpi_libs = self.get_mpi_libs() + + # NOTE: Some external mpi installations may have empty lib + # directory (e.g. bg-q). In this case we need to explicitly + # pass empty library name. + if mpi_libs: + mpi_libs = ' -l'.join(mpi_libs) + config_args.append('--with-mpi-libs=-l{0}'.format(mpi_libs)) + else: + config_args.append('--with-mpi-libs= ') # NOTE: Early versions of Zoltan come packaged with a few embedded # library packages (e.g. ParMETIS, Scotch), which messes with Spack's |