From f83ff491b4812e9b68df5a55391ac3f4e18755ae Mon Sep 17 00:00:00 2001 From: Björn Stenberg Date: Wed, 19 Dec 2012 17:18:31 +0100 Subject: Add ptest for bash. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit (From OE-Core rev: 71e07ce8d1e4c2a50e937f0c819f025afd4677cb) Signed-off-by: Björn Stenberg Signed-off-by: Saul Wold Signed-off-by: Richard Purdie --- meta/recipes-extended/bash/bash.inc | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'meta/recipes-extended/bash/bash.inc') diff --git a/meta/recipes-extended/bash/bash.inc b/meta/recipes-extended/bash/bash.inc index f1de931e82..20a23f030f 100644 --- a/meta/recipes-extended/bash/bash.inc +++ b/meta/recipes-extended/bash/bash.inc @@ -4,7 +4,7 @@ SECTION = "base/shell" DEPENDS = "ncurses bison-native" -inherit autotools gettext update-alternatives +inherit autotools gettext update-alternatives ptest PARALLEL_MAKE = "" @@ -17,18 +17,32 @@ ALTERNATIVE_PRIORITY = "100" export AUTOHEADER = "true" +RDEPENDS_${PN}-ptest += "make" + do_configure_prepend () { if [ ! -e acinclude.m4 ]; then cat aclocal.m4 > acinclude.m4 fi } +do_compile_append () { + if [ "${PN}" = "${BPN}" -a ${PTEST_ENABLED} = "1" ]; then + oe_runmake buildtest + fi +} + do_install_append () { # Move /usr/bin/bash to /bin/bash, if need if [ "${base_bindir}" != "${bindir}" ]; then mkdir -p ${D}${base_bindir} mv ${D}${bindir}/bash ${D}${base_bindir} fi + + if [ "${PN}" = "${BPN}" -a ${PTEST_ENABLED} = "1" ]; then + ptest_do_install + make INSTALL_TEST_DIR=${D}${PTEST_PATH}/tests install-test + cp ${B}/Makefile ${D}${PTEST_PATH} + fi } pkg_postinst_${PN} () { -- cgit v1.2.3-54-g00ecf