diff mbox series

[meta-oe] pv: Add valgrind dependency on platform where its available

Message ID 20250409135656.1066846-1-raj.khem@gmail.com
State New
Headers show
Series [meta-oe] pv: Add valgrind dependency on platform where its available | expand

Commit Message

Khem Raj April 9, 2025, 1:56 p.m. UTC
valgrind does not build for RISCV platforms yet and so are some other
platforms ( taken from rsyslog recipe )

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 meta-oe/recipes-support/pv/pv_1.9.31.bb | 26 ++++++++++++++++++++++++-
 1 file changed, 25 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/meta-oe/recipes-support/pv/pv_1.9.31.bb b/meta-oe/recipes-support/pv/pv_1.9.31.bb
index 2f1d38337f..578012fcfd 100644
--- a/meta-oe/recipes-support/pv/pv_1.9.31.bb
+++ b/meta-oe/recipes-support/pv/pv_1.9.31.bb
@@ -18,7 +18,31 @@  inherit autotools gettext ptest
 LDEMULATION:mipsarchn32 = "${@bb.utils.contains('TUNE_FEATURES', 'bigendian', 'elf32btsmipn32', 'elf32ltsmipn32', d)}"
 export LDEMULATION
 
-RDEPENDS:${PN}-ptest += "bash coreutils tmux valgrind"
+# for ptests
+VALGRIND = "valgrind"
+
+# valgrind supports armv7 and above
+VALGRIND:armv4 = ''
+VALGRIND:armv5 = ''
+VALGRIND:armv6 = ''
+
+# X32 isn't supported by valgrind at this time
+VALGRIND:linux-gnux32 = ''
+VALGRIND:linux-muslx32 = ''
+
+# Disable for some MIPS variants
+VALGRIND:mipsarchr6 = ''
+VALGRIND:linux-gnun32 = ''
+
+# Disable for powerpc64 with musl
+VALGRIND:libc-musl:powerpc64 = ''
+VALGRIND:libc-musl:powerpc64le = ''
+
+# RISC-V support for valgrind is not there yet
+VALGRIND:riscv64 = ""
+VALGRIND:riscv32 = ""
+
+RDEPENDS:${PN}-ptest += "bash coreutils tmux ${VALGRIND}"
 RDEPENDS:${PN}-ptest:append:libc-musl = " musl-locales"
 RDEPENDS:${PN}-ptest:append:libc-glibc = " glibc-binary-localedata-c"