summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin Bronder <jsbronder@gentoo.org>2012-03-07 01:28:34 +0000
committerJustin Bronder <jsbronder@gentoo.org>2012-03-07 01:28:34 +0000
commite80889347fba8fef9d7001f0496c1283a5a2f00f (patch)
treeb1b58b4474739015459f0c77c5c5fbab21585ab6 /sys-cluster/mpich2
parentMore strict block to force uninstall of not compliant scp-gnome, add pycurl d... (diff)
downloadgentoo-2-e80889347fba8fef9d7001f0496c1283a5a2f00f.tar.gz
gentoo-2-e80889347fba8fef9d7001f0496c1283a5a2f00f.tar.bz2
gentoo-2-e80889347fba8fef9d7001f0496c1283a5a2f00f.zip
Version bump, fix #393361, EAPI 4, fortran update.
(Portage version: 2.1.10.11/cvs/Linux x86_64)
Diffstat (limited to 'sys-cluster/mpich2')
-rw-r--r--sys-cluster/mpich2/ChangeLog8
-rw-r--r--sys-cluster/mpich2/files/mpich2-1.4.1-fix-pkg-config-files.patch119
-rw-r--r--sys-cluster/mpich2/files/mpich2-hvector.patch63
-rw-r--r--sys-cluster/mpich2/mpich2-1.4.1_p1.ebuild165
4 files changed, 354 insertions, 1 deletions
diff --git a/sys-cluster/mpich2/ChangeLog b/sys-cluster/mpich2/ChangeLog
index 5abee19f2caa..1ecf881240ab 100644
--- a/sys-cluster/mpich2/ChangeLog
+++ b/sys-cluster/mpich2/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for sys-cluster/mpich2
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-cluster/mpich2/ChangeLog,v 1.74 2012/01/12 02:11:50 jsbronder Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-cluster/mpich2/ChangeLog,v 1.75 2012/03/07 01:28:34 jsbronder Exp $
+
+*mpich2-1.4.1_p1 (07 Mar 2012)
+
+ 07 Mar 2012; Justin Bronder <jsbronder@gentoo.org> +mpich2-1.4.1_p1.ebuild,
+ +files/mpich2-hvector.patch, +files/mpich2-1.4.1-fix-pkg-config-files.patch:
+ Version bump, fix #393361, EAPI 4, fortran update.
12 Jan 2012; Justin Bronder <jsbronder@gentoo.org> mpich2-1.4_rc2-r1.ebuild,
+files/mpich2-1.4_rc2-fix-pkg-config-files.patch:
diff --git a/sys-cluster/mpich2/files/mpich2-1.4.1-fix-pkg-config-files.patch b/sys-cluster/mpich2/files/mpich2-1.4.1-fix-pkg-config-files.patch
new file mode 100644
index 000000000000..d9c311e31bb8
--- /dev/null
+++ b/sys-cluster/mpich2/files/mpich2-1.4.1-fix-pkg-config-files.patch
@@ -0,0 +1,119 @@
+From cba731049a24735beb660dc236f61070aa6e387a Mon Sep 17 00:00:00 2001
+From: Justin Bronder <jsbronder@gmail.com>
+Date: Thu, 5 Jan 2012 22:20:31 -0500
+Subject: [PATCH] fix pkg config files
+
+Conditionals are not supported.
+https://trac.mcs.anl.gov/projects/mpich2/ticket/1044
+---
+ configure.in | 6 ++++++
+ src/packaging/pkgconfig/mpich2-c.pc.in | 8 +-------
+ src/packaging/pkgconfig/mpich2-cxx.pc.in | 8 +-------
+ src/packaging/pkgconfig/mpich2-f77.pc.in | 8 +-------
+ src/packaging/pkgconfig/mpich2-f90.pc.in | 8 +-------
+ 5 files changed, 10 insertions(+), 28 deletions(-)
+
+diff --git a/configure.in b/configure.in
+index 294dc85..44b1010 100644
+--- a/configure.in
++++ b/configure.in
+@@ -5332,6 +5332,12 @@ AC_SUBST(MPICH_TIMER_KIND)
+ # Setup other replaceable values
+ AC_SUBST(MPILIBNAME)
+ AC_SUBST(PMPILIBNAME)
++PKGCONFIG_PMPILIB=""
++if test "$NEEDSPLIB" = yes -a test -n "${PMPILIBNAME}" ; then
++ PKGCONFIG_PMPILIB="-l${PMPILIBNAME}"
++fi
++AC_SUBST(PKGCONFIG_PMPILIB)
++
+ # Note that aint_size must be used instead of void_p where the desired check
+ # is on the size of MPI_Aint
+ aint_size=$ac_cv_sizeof_void_p
+diff --git a/src/packaging/pkgconfig/mpich2-c.pc.in b/src/packaging/pkgconfig/mpich2-c.pc.in
+index 394630b..e0ab3fa 100644
+--- a/src/packaging/pkgconfig/mpich2-c.pc.in
++++ b/src/packaging/pkgconfig/mpich2-c.pc.in
+@@ -4,15 +4,9 @@ exec_prefix=@exec_prefix@
+ libdir=@libdir@
+ includedir=@includedir@
+
+-if test "@NEEDSPLIB@" = "yes" ; then
+- plib=@PMPILIBNAME@
+-else
+- plib=
+-fi
+-
+ Name: mpich2
+ Description: MPICH2 is an implementation of the Message-Passing Interface (MPI). The goals of MPICH2 are to provide an MPI implementation for important platforms, including clusters, SMPs, and massively parallel processors. It also provides a vehicle for MPI implementation research and for developing new and better parallel programming environments.
+ Version: @MPICH2_VERSION@
+ Requires:
+-Libs: @WRAPPER_LDFLAGS@ -L${libdir} -l${plib} -l@MPILIBNAME@ @WRAPPER_LIBS@
++Libs: @WRAPPER_LDFLAGS@ -L${libdir} @PKGCONFIG_PMPILIB@ -l@MPILIBNAME@ @WRAPPER_LIBS@
+ Cflags: @WRAPPER_CPPFLAGS@ @WRAPPER_CFLAGS@ -I${includedir}
+diff --git a/src/packaging/pkgconfig/mpich2-cxx.pc.in b/src/packaging/pkgconfig/mpich2-cxx.pc.in
+index 936ade6..d82e184 100644
+--- a/src/packaging/pkgconfig/mpich2-cxx.pc.in
++++ b/src/packaging/pkgconfig/mpich2-cxx.pc.in
+@@ -4,15 +4,9 @@ exec_prefix=@exec_prefix@
+ libdir=@libdir@
+ includedir=@includedir@
+
+-if test "@NEEDSPLIB@" = "yes" ; then
+- plib=@PMPILIBNAME@
+-else
+- plib=
+-fi
+-
+ Name: mpich2
+ Description: MPICH2 is an implementation of the Message-Passing Interface (MPI). The goals of MPICH2 are to provide an MPI implementation for important platforms, including clusters, SMPs, and massively parallel processors. It also provides a vehicle for MPI implementation research and for developing new and better parallel programming environments.
+ Version: @MPICH2_VERSION@
+ Requires:
+-Libs: @WRAPPER_LDFLAGS@ -L${libdir} -l${plib} -l@MPILIBNAME@ @WRAPPER_LIBS@
++Libs: @WRAPPER_LDFLAGS@ -L${libdir} @PKGCONFIG_PMPILIB@ -l@MPILIBNAME@ @WRAPPER_LIBS@
+ Cxxflags: @WRAPPER_CPPFLAGS@ @WRAPPER_CXXFLAGS@ -I${includedir}
+diff --git a/src/packaging/pkgconfig/mpich2-f77.pc.in b/src/packaging/pkgconfig/mpich2-f77.pc.in
+index 291462e..193c2ab 100644
+--- a/src/packaging/pkgconfig/mpich2-f77.pc.in
++++ b/src/packaging/pkgconfig/mpich2-f77.pc.in
+@@ -4,15 +4,9 @@ exec_prefix=@exec_prefix@
+ libdir=@libdir@
+ includedir=@includedir@
+
+-if test "@NEEDSPLIB@" = "yes" ; then
+- plib=@PMPILIBNAME@
+-else
+- plib=
+-fi
+-
+ Name: mpich2
+ Description: MPICH2 is an implementation of the Message-Passing Interface (MPI). The goals of MPICH2 are to provide an MPI implementation for important platforms, including clusters, SMPs, and massively parallel processors. It also provides a vehicle for MPI implementation research and for developing new and better parallel programming environments.
+ Version: @MPICH2_VERSION@
+ Requires:
+-Libs: @WRAPPER_LDFLAGS@ -L${libdir} -l${plib} -l@MPILIBNAME@ @WRAPPER_LIBS@
++Libs: @WRAPPER_LDFLAGS@ -L${libdir} @PKGCONFIG_PMPILIB@ -l@MPILIBNAME@ @WRAPPER_LIBS@
+ Fflags: @WRAPPER_FFLAGS@ -I${includedir}
+diff --git a/src/packaging/pkgconfig/mpich2-f90.pc.in b/src/packaging/pkgconfig/mpich2-f90.pc.in
+index ca15e18..700976f 100644
+--- a/src/packaging/pkgconfig/mpich2-f90.pc.in
++++ b/src/packaging/pkgconfig/mpich2-f90.pc.in
+@@ -4,15 +4,9 @@ exec_prefix=@exec_prefix@
+ libdir=@libdir@
+ includedir=@includedir@
+
+-if test "@NEEDSPLIB@" = "yes" ; then
+- plib=@PMPILIBNAME@
+-else
+- plib=
+-fi
+-
+ Name: mpich2
+ Description: MPICH2 is an implementation of the Message-Passing Interface (MPI). The goals of MPICH2 are to provide an MPI implementation for important platforms, including clusters, SMPs, and massively parallel processors. It also provides a vehicle for MPI implementation research and for developing new and better parallel programming environments.
+ Version: @MPICH2_VERSION@
+ Requires:
+-Libs: @WRAPPER_LDFLAGS@ -L${libdir} -l${plib} -l@MPILIBNAME@ @WRAPPER_LIBS@
++Libs: @WRAPPER_LDFLAGS@ -L${libdir} @PKGCONFIG_PMPILIB@ -l@MPILIBNAME@ @WRAPPER_LIBS@
+ Fcflags: @WRAPPER_FCFLAGS@ -I${includedir}
+--
+1.7.3.4
+
diff --git a/sys-cluster/mpich2/files/mpich2-hvector.patch b/sys-cluster/mpich2/files/mpich2-hvector.patch
new file mode 100644
index 000000000000..9d67561e3680
--- /dev/null
+++ b/sys-cluster/mpich2/files/mpich2-hvector.patch
@@ -0,0 +1,63 @@
+--- src/binding/f90/buildiface 2011-12-06 09:57:04.000000000 +0100
++++ src/binding/f90/buildiface 2011-12-06 09:57:54.000000000 +0100
+@@ -117,9 +117,13 @@
+ 'Type_hindexed-3' => 'int[]',
+ 'Type_indexed-2' => 'int[]',
+ 'Type_indexed-3' => 'int[]',
++ 'Type_hvector-3' => 'int',
+ 'Type_struct-2' => 'int[]',
+ 'Type_struct-3' => 'int[]',
+ 'Type_struct-4' => 'MPI_Datatype[]',
++ 'Type_extent-2' => 'int',
++ 'Type_lb-2' => 'int',
++ 'Type_ub-2' => 'int',
+ 'Waitall-2' => 'MPI_Request[]',
+ 'Waitall-3' => 'MPI_Status[]',
+ 'Waitany-2' => 'MPI_Request[]',
+--- src/binding/f90/mpi_base.f90.in 2011-12-06 09:58:42.000000000 +0100
++++ src/binding/f90/mpi_base.f90.in 2011-12-06 10:00:30.000000000 +0100
+@@ -15,9 +15,7 @@
+ END SUBROUTINE MPI_COMM_FREE_KEYVAL
+
+ SUBROUTINE MPI_TYPE_EXTENT(v0,v1,ierror)
+- USE MPI_CONSTANTS,ONLY:MPI_ADDRESS_KIND
+- INTEGER v0
+- INTEGER(KIND=MPI_ADDRESS_KIND) v1
++ INTEGER v0, v1
+ INTEGER ierror
+ END SUBROUTINE MPI_TYPE_EXTENT
+
+@@ -114,9 +112,7 @@
+ END SUBROUTINE MPI_OP_COMMUTATIVE
+
+ SUBROUTINE MPI_TYPE_LB(v0,v1,ierror)
+- USE MPI_CONSTANTS,ONLY:MPI_ADDRESS_KIND
+- INTEGER v0
+- INTEGER(KIND=MPI_ADDRESS_KIND) v1
++ INTEGER v0, v1
+ INTEGER ierror
+ END SUBROUTINE MPI_TYPE_LB
+
+@@ -562,9 +558,7 @@
+ END SUBROUTINE MPI_TYPE_CREATE_RESIZED
+
+ SUBROUTINE MPI_TYPE_UB(v0,v1,ierror)
+- USE MPI_CONSTANTS,ONLY:MPI_ADDRESS_KIND
+- INTEGER v0
+- INTEGER(KIND=MPI_ADDRESS_KIND) v1
++ INTEGER v0, v1
+ INTEGER ierror
+ END SUBROUTINE MPI_TYPE_UB
+
+@@ -822,10 +816,7 @@
+ END SUBROUTINE MPI_GET_VERSION
+
+ SUBROUTINE MPI_TYPE_HVECTOR(v0,v1,v2,v3,v4,ierror)
+- USE MPI_CONSTANTS,ONLY:MPI_ADDRESS_KIND
+- INTEGER v0, v1
+- INTEGER(KIND=MPI_ADDRESS_KIND) v2
+- INTEGER v3, v4
++ INTEGER v0, v1, v2, v3, v4
+ INTEGER ierror
+ END SUBROUTINE MPI_TYPE_HVECTOR
+
diff --git a/sys-cluster/mpich2/mpich2-1.4.1_p1.ebuild b/sys-cluster/mpich2/mpich2-1.4.1_p1.ebuild
new file mode 100644
index 000000000000..0a2701ef9c18
--- /dev/null
+++ b/sys-cluster/mpich2/mpich2-1.4.1_p1.ebuild
@@ -0,0 +1,165 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-cluster/mpich2/mpich2-1.4.1_p1.ebuild,v 1.1 2012/03/07 01:28:34 jsbronder Exp $
+
+EAPI=4
+
+inherit autotools eutils fortran-2 toolchain-funcs
+
+MY_PV=${PV/_/}
+DESCRIPTION="A high performance and portable MPI implementation"
+HOMEPAGE="http://www.mcs.anl.gov/research/projects/mpich2/index.php"
+SRC_URI="http://www.mcs.anl.gov/research/projects/mpich2/downloads/tarballs/${MY_PV}/${PN}-${MY_PV}.tar.gz"
+
+LICENSE="as-is"
+SLOT="0"
+KEYWORDS="~amd64 ~hppa ~ppc ~ppc64 ~x86"
+IUSE="+cxx debug doc fortran mpi-threads romio threads"
+
+COMMON_DEPEND="dev-libs/libaio
+ sys-apps/hwloc
+ romio? ( net-fs/nfs-utils )"
+
+DEPEND="${COMMON_DEPEND}
+ dev-lang/perl
+ sys-devel/libtool"
+
+RDEPEND="${COMMON_DEPEND}
+ fortran? ( virtual/fortran )
+ !sys-cluster/openmpi
+ !sys-cluster/lam-mpi"
+
+S="${WORKDIR}"/${PN}-${MY_PV}
+
+pkg_setup() {
+ if use fortran; then
+ FORTRAN_STANDARD="77 90"
+ fortran-2_pkg_setup
+ fi
+
+ if use mpi-threads && ! use threads; then
+ ewarn "mpi-threads requires threads, assuming that's what you want"
+ fi
+}
+
+src_prepare() {
+ # Cannot use bin/mpiexec as hydra is built by autotools and is
+ # a shell wrapped executable.
+ sed -i \
+ -e "s,@MPIEXEC@,${S}/src/pm/hydra/mpiexec.hydra,g" \
+ $(find ./test/ -name 'Makefile.in') || die
+
+ # #293665
+ # We could use MPICH2LIB_XFLAGS here and unset the cooresponding ones
+ # in the environment, however that's messy and doesn't for for LDFLAGS.
+ sed -i \
+ -e 's,\(.*=\ *\)"@WRAPPER_[A-Z]*FLAGS@",\1"",' \
+ src/env/*.in || die
+
+ # See
+ # http://lists.mcs.anl.gov/pipermail/mpich-discuss/2011-August/010680.html
+ # http://lists.mcs.anl.gov/pipermail/mpich-discuss/2011-August/010678.html
+ # and countless other sources pointing out the insanity.
+ sed -i \
+ -e 's|prefix=${DESTDIR}|prefix=|g' \
+ -e 's|dir=${DESTDIR}|dir=|g' \
+ Makefile.in || die
+
+ sed -i \
+ -e "s|prefix='\${DESTDIR}|prefix='|" \
+ -e "s|dir='\${DESTDIR}|dir='|" \
+ src/env/Makefile.in || die
+
+ # 369263 and 1500 upstream.
+ epatch "${FILESDIR}"/mpich2-1.4.1-fix-pkg-config-files.patch
+
+ # 393361, backport of r8809 upstream.
+ epatch "${FILESDIR}"/mpich2-hvector.patch
+
+ AT_M4DIR="${S}"/confdb eautoreconf || die
+}
+
+src_configure() {
+ local c="--enable-shared --disable-rpath"
+ local romio_conf
+
+ # The configure statements can be somewhat confusing, as they
+ # don't all show up in the top level configure, however, they
+ # are picked up in the children directories.
+
+ use debug && c="${c} --enable-g=dbg --enable-debuginfo"
+
+ if use mpi-threads; then
+ # MPI-THREAD requries threading.
+ c="${c} --with-thread-package=pthreads"
+ c="${c} --enable-threads=runtime"
+ else
+ if use threads ; then
+ c="${c} --with-thread-package=pthreads"
+ else
+ c="${c} --with-thread-package=none"
+ fi
+ c="${c} --enable-threads=single"
+ fi
+
+ c="${c} --sysconfdir=${EPREFIX}/etc/${PN}"
+ econf ${c} ${romio_conf} \
+ --docdir=/usr/share/doc/${PF} \
+ --with-pm=hydra \
+ --disable-mpe \
+ --with-hwloc-prefix="${EPREFIX}/usr" \
+ --disable-fast \
+ --enable-smpcoll \
+ $(use_enable romio) \
+ $(use_enable cxx) \
+ $(use_enable fortran f77) \
+ $(use_enable fortran fc)
+}
+
+src_compile() {
+ # Oh, the irony.
+ # http://wiki.mcs.anl.gov/mpich2/index.php/Frequently_Asked_Questions#Q:_The_build_fails_when_I_use_parallel_make.
+ # https://trac.mcs.anl.gov/projects/mpich2/ticket/711
+ emake -j1
+}
+
+src_test() {
+ # See #362655 and comments in the testlist files.
+ # large_message: only on machines with > 8gb of ram
+ # bcastlength: This is an extension to MPI that's not necessary
+ # non_zero_root: performance test
+ # Also note that I/O tests may fail on non-local filesystems.
+ sed -i '/^[# ]*large_message/d' test/mpi/pt2pt/testlist || die
+ sed -i '/^[# ]*bcastlength/d' test/mpi/errors/coll/testlist || die
+ sed -i '/^[# ]*non_zero_root/d' test/mpi/perf/testlist || die
+
+ # Failing tests based on requiring MPI_THREAD_MULTIPLE.
+ # http://lists.mcs.anl.gov/pipermail/mpich-discuss/2012-January/011618.html
+ sed -i \
+ -e '/^[# ]*pt2pt/d' \
+ -e '/^[# ]*comm/d' \
+ -e '/^[# ]*spawn/d' \
+ test/mpi/threads/testlist || die
+
+ emake -j1 \
+ CC="${S}"/bin/mpicc \
+ CXX="${S}"/bin/mpicxx \
+ F77="${S}"/bin/mpif77 \
+ FC="${S}"/bin/mpif90 \
+ testing
+}
+
+src_install() {
+ emake -j1 DESTDIR="${D}" install
+
+ dodir /usr/share/doc/${PF}
+ dodoc COPYRIGHT README CHANGES RELEASE_NOTES || die
+ newdoc src/pm/hydra/README README.hydra|| die
+ if use romio; then
+ newdoc src/mpi/romio/README README.romio || die
+ fi
+
+ if ! use doc; then
+ rm -rf "${D}"/usr/share/doc/${PF}/www* || die
+ fi
+}