From f422dabbd714853fc058a35b01bd049f1ad63343 Mon Sep 17 00:00:00 2001 From: Simone Weiss Date: Tue, 19 Apr 2022 14:59:41 +0200 Subject: libgpg-error: Add ptest Add a ptest for libgpg-error to core-image-ptest-all. Avoid refreshing the Makefile in qemu as this would fail and is not needed. All tests passed on a trial run. (From OE-Core rev: 51dd52604eb73c55fc32a99c3208653f27ba4091) Signed-off-by: Simone Weiss Signed-off-by: Luca Ceresoli Signed-off-by: Richard Purdie --- meta/recipes-support/libgpg-error/libgpg-error/run-ptest | 3 +++ meta/recipes-support/libgpg-error/libgpg-error_1.44.bb | 14 +++++++++++++- 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 meta/recipes-support/libgpg-error/libgpg-error/run-ptest (limited to 'meta/recipes-support/libgpg-error') diff --git a/meta/recipes-support/libgpg-error/libgpg-error/run-ptest b/meta/recipes-support/libgpg-error/libgpg-error/run-ptest new file mode 100644 index 0000000000..2d23159eb0 --- /dev/null +++ b/meta/recipes-support/libgpg-error/libgpg-error/run-ptest @@ -0,0 +1,3 @@ +#!/bin/sh + +make -o Makefile runtest-TESTS diff --git a/meta/recipes-support/libgpg-error/libgpg-error_1.44.bb b/meta/recipes-support/libgpg-error/libgpg-error_1.44.bb index 41adad0ede..f5b482f4c9 100644 --- a/meta/recipes-support/libgpg-error/libgpg-error_1.44.bb +++ b/meta/recipes-support/libgpg-error/libgpg-error_1.44.bb @@ -17,13 +17,16 @@ UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html" SRC_URI = "${GNUPG_MIRROR}/libgpg-error/libgpg-error-${PV}.tar.bz2 \ file://pkgconfig.patch \ file://0001-Do-not-fail-when-testing-config-scripts.patch \ + file://run-ptest \ " SRC_URI[sha256sum] = "8e3d2da7a8b9a104dd8e9212ebe8e0daf86aa838cc1314ba6bc4de8f2d8a1ff9" BINCONFIG = "${bindir}/gpg-error-config" -inherit autotools binconfig-disabled pkgconfig gettext multilib_header multilib_script +inherit autotools binconfig-disabled pkgconfig gettext multilib_header multilib_script ptest + +RDEPENDS:${PN}-ptest:append = " make" MULTILIB_SCRIPTS = "${PN}-dev:${bindir}/gpgrt-config" @@ -35,6 +38,15 @@ do_install:append() { oe_multilib_header gpg-error.h gpgrt.h } +do_compile_ptest() { + oe_runmake -C tests buildtest-TESTS +} + +do_install_ptest() { + install ${B}/tests/t-*[!\.o] ${D}${PTEST_PATH} + install ${B}/tests/Makefile ${D}${PTEST_PATH} +} + FILES:${PN}-dev += "${bindir}/gpg-error" FILES:${PN}-doc += "${datadir}/libgpg-error/errorref.txt" -- cgit v1.2.3-54-g00ecf