summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorAdrian Jackson <a.jackson@epcc.ed.ac.uk>2019-11-11 19:22:20 +0000
committerAdam J. Stewart <ajstewart426@gmail.com>2019-11-11 13:22:20 -0600
commit3eaa790efa71a5e43df0aef9648c3cc7051dc069 (patch)
treef20d866df70ec80cb1ed1eb039698f96247e436c /var
parentdc51d676a2fe6966876277c76aead6c02a035f3f (diff)
downloadspack-3eaa790efa71a5e43df0aef9648c3cc7051dc069.tar.gz
spack-3eaa790efa71a5e43df0aef9648c3cc7051dc069.tar.bz2
spack-3eaa790efa71a5e43df0aef9648c3cc7051dc069.tar.xz
spack-3eaa790efa71a5e43df0aef9648c3cc7051dc069.zip
Add HPE MPT package (#13616)
* Adding in HMPT package for HPE MPI libraries * Updating copyright dates * Renaming HPE MPI package * Fixing error in package file * Tidying up defintions and linting * liniting * Adding in library setup so packages that want to manually add mpi libraries can do so (i.e. npb) * Linting * Linting * Investigating old API errors * Investigating api errors * Investigating api errors * Investigating api errors * Investigating api errors * Investigating api errors: adding back in functions to see when the build fails * Investigating api errors: adding back in functions to see when the build fails * Investigating api errors: adding back in functions to see when the build fails * Investigating api errors: adding back in functions to see when the build fails * Investigating api errors: adding back in functions to see when the build fails * Linting * Linting * Fixing * Fixing
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/mpt/package.py77
1 files changed, 77 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/mpt/package.py b/var/spack/repos/builtin/packages/mpt/package.py
new file mode 100644
index 0000000000..65a286f9eb
--- /dev/null
+++ b/var/spack/repos/builtin/packages/mpt/package.py
@@ -0,0 +1,77 @@
+# Copyright 2013-2019 Lawrence Livermore National Security, LLC and other
+# Spack Project Developers. See the top-level COPYRIGHT file for details.
+#
+# SPDX-License-Identifier: (Apache-2.0 OR MIT)
+
+from spack import *
+
+
+class Mpt(Package):
+ """HPE MPI is HPE's implementation of
+ the Message Passing Interface (MPI) standard.
+
+ Note: HPE MPI is proprietry software. Spack will search your
+ current directory for the download file. Alternatively, add this file to a
+ mirror so that Spack can find it. For instructions on how to set up a
+ mirror, see http://spack.readthedocs.io/en/latest/mirrors.html"""
+
+ homepage = "https://buy.hpe.com/us/en/software/high-performance-computing-software/hpe-message-passing-interface-mpi/p/1010144155"
+
+ provides('mpi')
+ provides('mpi@:3.1', when='@3:')
+ provides('mpi@:1.3', when='@1:')
+
+ filter_compiler_wrappers(
+ 'mpicc', 'mpicxx', 'mpif77', 'mpif90', 'mpif77', 'mpif08',
+ relative_root='bin'
+ )
+
+ @property
+ def libs(self):
+ query_parameters = self.spec.last_query.extra_parameters
+ libraries = ['libmpi']
+
+ if 'cxx' in query_parameters:
+ libraries = ['libmpicxx'] + libraries
+
+ return find_libraries(
+ libraries, root=self.prefix, shared=True, recursive=True
+ )
+
+ def setup_dependent_build_environment(self, env, dependent_spec):
+ env.set('MPICC', self.prefix.bin.mpicc)
+ env.set('MPICXX', self.prefix.bin.mpicxx)
+ env.set('MPIF77', self.prefix.bin.mpif77)
+ env.set('MPIF90', self.prefix.bin.mpifc)
+ env.set('MPICC_CC', spack_cc)
+ env.set('MPICXX_CXX', spack_cxx)
+ env.set('MPIF90_F90', spack_fc)
+
+ def setup_dependent_package(self, module, dependent_spec):
+ if 'platform=cray' in self.spec:
+ self.spec.mpicc = spack_cc
+ self.spec.mpicxx = spack_cxx
+ self.spec.mpifc = spack_fc
+ self.spec.mpif77 = spack_f77
+ else:
+ self.spec.mpicc = self.prefix.bin.mpicc
+ self.spec.mpicxx = self.prefix.bin.mpicxx
+ self.spec.mpifc = self.prefix.bin.mpifc
+ self.spec.mpif77 = self.prefix.bin.mpif77
+
+ @property
+ def fetcher(self):
+ msg = """This package is a placeholder for HPE MPI, a
+ system-provided, proprietary MPI implementation.
+
+ Add to your packages.yaml (changing the /opt/ path to match
+ where HPE MPI is actually installed):
+
+ packages:
+ mpt:
+ paths:
+ mpt@2.20: /opt/
+ buildable: False
+
+ """
+ raise InstallError(msg)