commit:     c0a799a70cabea58fcaab2443906d1ead7ff704c
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Tue May 16 01:25:47 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Tue May 16 01:52:18 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c0a799a7

sys-cluster/mpich: add Valgrind annotation support

Signed-off-by: Sam James <sam <AT> gentoo.org>

 sys-cluster/mpich/mpich-3.4.3.ebuild | 26 +++++++++++++++++---------
 1 file changed, 17 insertions(+), 9 deletions(-)

diff --git a/sys-cluster/mpich/mpich-3.4.3.ebuild 
b/sys-cluster/mpich/mpich-3.4.3.ebuild
index 2eae74fc8796..10547d371575 100644
--- a/sys-cluster/mpich/mpich-3.4.3.ebuild
+++ b/sys-cluster/mpich/mpich-3.4.3.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2022 Gentoo Authors
+# Copyright 1999-2023 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=7
@@ -17,21 +17,28 @@ S="${WORKDIR}"/${PN}-${MY_PV}
 LICENSE="mpich2"
 SLOT="0"
 KEYWORDS="amd64 ~arm64 ~hppa ~ppc ppc64 ~riscv x86 ~amd64-linux ~x86-linux"
-IUSE="+cxx doc fortran mpi-threads +romio threads"
+IUSE="+cxx doc fortran mpi-threads +romio threads valgrind"
 REQUIRED_USE="mpi-threads? ( threads )"
 
-COMMON_DEPEND=">=dev-libs/libaio-0.3.109-r5[${MULTILIB_USEDEP}]
+COMMON_DEPEND="
+       >=dev-libs/libaio-0.3.109-r5[${MULTILIB_USEDEP}]
        >=sys-apps/hwloc-2.0.2:=[${MULTILIB_USEDEP}]
        sys-libs/libunwind:=[${MULTILIB_USEDEP}]
-       romio? ( net-fs/nfs-utils )"
+       romio? ( net-fs/nfs-utils )
+"
 
-DEPEND="${COMMON_DEPEND}
+DEPEND="
+       ${COMMON_DEPEND}
        dev-lang/perl
-       sys-devel/libtool"
-RDEPEND="${COMMON_DEPEND}
+       sys-devel/libtool
+       valgrind? ( dev-util/valgrind )
+"
+RDEPEND="
+       ${COMMON_DEPEND}
        !sys-cluster/mpich2
        !sys-cluster/openmpi
-       !sys-cluster/nullmpi"
+       !sys-cluster/nullmpi
+"
 
 MULTILIB_WRAPPED_HEADERS=(
        /usr/include/mpicxx.h
@@ -123,7 +130,8 @@ multilib_src_configure() {
                --enable-versioning \
                $(use_enable romio) \
                $(use_enable cxx) \
-               $(use_enable fortran fortran all)
+               $(use_enable fortran fortran all) \
+               $(use_with valgrind)
 }
 
 multilib_src_test() {

Reply via email to