aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Gilroy <michael.gilroy24@gmail.com>2017-07-20 14:36:39 -0600
committerMichael Gilroy <michael.gilroy24@gmail.com>2017-07-20 14:36:39 -0600
commit8b603b91d2ce62394c9c7fadfb3bda85198f2495 (patch)
treec0046a1b5511047f0a890abb071c3cc452c5c0c8 /eclass/mpi-select.eclass
parentadded eutils to overlay for testing hpl (diff)
downloadgentoo-mpi-8b603b91d2ce62394c9c7fadfb3bda85198f2495.tar.gz
gentoo-mpi-8b603b91d2ce62394c9c7fadfb3bda85198f2495.tar.bz2
gentoo-mpi-8b603b91d2ce62394c9c7fadfb3bda85198f2495.zip
updated functions for hpl build
Diffstat (limited to 'eclass/mpi-select.eclass')
-rw-r--r--eclass/mpi-select.eclass30
1 files changed, 23 insertions, 7 deletions
diff --git a/eclass/mpi-select.eclass b/eclass/mpi-select.eclass
index c82a4e5..dbd0642 100644
--- a/eclass/mpi-select.eclass
+++ b/eclass/mpi-select.eclass
@@ -40,24 +40,40 @@ MPI_DIR="/usr/$(get_libdir)/mpi"
# List of implementations in make.conf.
MPI_TARGETS="${MPI_TARGETS}"
+# @FUNCTION: mpi_dependencies
+# List of dependcies needed for mpi software
+mpi_dependencies()
+{
+ # similar to mpi_pkg_deplist
+ echo "hit"
+}
+
+# @FUNCTION: get_mpicc
+# @DESCRIPTION:
+# Fetches most recent version of mpicc installed
+get_mpicc()
+{
+ echo "$(ls -dv /usr/$(get_libdir)/mpi/mpich-* | tail -n 1)" || die "could not get mpicc"
+}
+
# @FUNCTION : mpi_pkg_cc
# @DESCRIPTION :
# Get location of C compiler from /usr/
mpi_pkg_cc()
{
- mpi_pkg_compiler "MPI_CC" "cc"
+ mpi_pkg_compiler "cc"
}
# @FUNCTION: mpi_pkg_compiler
# @DESCRIPTION :
-# Return /usr/bin/mpi/$PN
+# Returns correct path for the compiler
mpi_pkg_compiler
{
- local suffixes="${2}"
-
- for p in ${suffixes}; do
- if [ -x ${ROOT}usr/bin/mpi${PN} ]; then
- echo "${ROOT}usr/bin/mpi${PN}"
+ local args
+ for args in "${1}"; do
+ if [ -f "/usr/lib64/mpi/mpich-3.2/install/usr/bin" ]; then
+ die "hit!!"
+ echo "$(get_mpicc)/install/usr/bin/mpi${args}"
break
fi
done