lxc ptest support and update to version 1.0.1
cover lxc ptest support and update to version 1.0.1
Hi,
This patch series adds libvirt to ptest framework and updates to 1.0.1. The tests that are using the ubuntu template are not installed, since they are not suitable to embedded distros.
Best regards,
Mihaela Sendrea.
Mihaela Sendrea (2):
lxc: Add ptest support
lxc: Update version to 1.0.1
recipes-containers/lxc/files/run-ptest | 4 +++
recipes-containers/lxc/files/runtest.patch | 32 ++++++++++++++++++++++
.../lxc/{lxc_1.0.0.bb => lxc_1.0.1.bb} | 21 +++++++++++---
3 files changed, 53 insertions(+), 4 deletions(-)
create mode 100644 recipes-containers/lxc/files/run-ptest
create mode 100644 recipes-containers/lxc/files/runtest.patch
rename recipes-containers/lxc/{lxc_1.0.0.bb => lxc_1.0.1.bb} (77%)Signature · 1 line
1.8.5.3
PATCH 1/2 lxc: Add ptest support
Install lxc test suite and run it as ptest.
--- recipes-containers/lxc/files/run-ptest | 4 ++++ recipes-containers/lxc/files/runtest.patch | 32 ++++++++++++++++++++++++++++++ recipes-containers/lxc/lxc_1.0.0.bb | 17 ++++++++++++++-- 3 files changed, 51 insertions(+), 2 deletions(-) create mode 100644 recipes-containers/lxc/files/run-ptest create mode 100644 recipes-containers/lxc/files/runtest.patch
recipes-containers/lxc/files/run-ptest new file +4 -0
@@ -0,0 +1,4 @@ +#!/bin/sh + +make -C src/tests -k check-TESTS +
recipes-containers/lxc/files/runtest.patch new file +32 -0
@@ -0,0 +1,32 @@ +Add install-ptest rule. + +Signed-off-by: Mihaela Sendrea <[email protected]> +Upstream-status: Pending + +diff -uNr a/src/tests/Makefile.am b/src/tests/Makefile.am +--- a/src/tests/Makefile.am 2014-04-07 16:25:59.246238815 +0300 ++++ b/src/tests/Makefile.am 2014-04-10 18:09:43.195772467 +0300 +@@ -54,6 +54,23 @@ + + endif + ++TESTS = lxc-test-containertests lxc-test-locktests \ ++ lxc-test-getkeys lxc-test-lxcpath lxc-test-cgpath lxc-test-console \ ++ lxc-test-snapshot lxc-test-concurrent lxc-test-may-control \ ++ lxc-test-reboot lxc-test-list lxc-test-attach lxc-test-device-add-remove ++ ++buildtest-TESTS: $(TESTS) ++ ++install-ptest: ++ install -d $(TEST_DIR) ++ install -D ../lxc/liblxc.so $(TEST_DIR)/../lxc/liblxc.so ++ install -D ../../config/test-driver $(TEST_DIR)/../../config/test-driver ++ cp Makefile $(TEST_DIR) ++ @(for file in $(TESTS); do install $$file $(TEST_DIR); done;) ++ sed -i 's|^Makefile:|_Makefile:|' $(TEST_DIR)/Makefile ++ sed -i 's|^all-am:|_all-am:|' $(TEST_DIR)/Makefile ++ sed -i -e 's|^\(.*\.log:\) \(.*EXEEXT.*\)|\1|g' $(TEST_DIR)/Makefile ++ + EXTRA_DIST = \ + cgpath.c \ + clonetest.c \
recipes-containers/lxc/lxc_1.0.0.bb +15 -2
@@ -20,12 +20,15 @@ RDEPENDS_${PN} = " \ perl-module-overload \ perl-module-exporter-heavy \ " +RDEPENDS_${PN}-ptest += "file make" SRC_URI = "http://linuxcontainers.org/downloads/${BPN}-${PV}.tar.gz \ file://lxc-1.0.0-disable-udhcp-from-busybox-template.patch \ file://config_network_type-set-macvlan-default-mode-to-priv.patch \ file://lxc-busybox-follow-symlinks-when-inspecting-busybox-.patch \ file://network.c-Add-missing-LXC_NET_NONE-option-refactor.patch \ + file://runtest.patch \ + file://run-ptest \ " SRC_URI[md5sum] = "87a9d168a6e55326303cce3b2cb7f82e" SRC_URI[sha256sum] = "0992212ddaad01dfe8c048e130566b73dd5f34191585f36bdac07a4f8a91f3bd"
@@ -34,20 +37,23 @@ S = "${WORKDIR}/${BPN}-${PV}" # Let's not configure for the host distro. # -EXTRA_OECONF += "--with-distro=${DISTRO}" +PTEST_CONF = "${@base_contains('DISTRO_FEATURES', 'ptest', '--enable-tests', '', d)}" +EXTRA_OECONF += "--with-distro=${DISTRO} ${PTEST_CONF}" PACKAGECONFIG ??= "" PACKAGECONFIG[doc] = "--enable-doc,--disable-doc,," PACKAGECONFIG[rpath] = "--enable-rpath,--disable-rpath,," PACKAGECONFIG[apparmour] = "--enable-apparmor,--disable-apparmor,apparmor,apparmor" -inherit autotools pkgconfig +inherit autotools pkgconfig ptest FILES_${PN}-doc = "${mandir} ${infodir}" # For LXC the docdir only contains example configuration files and should be included in the lxc package FILES_${PN} += "${docdir}" FILES_${PN}-dbg += "${libexecdir}/lxc/.debug" +PRIVATE_LIBS_${PN}-ptest = "liblxc.so.1" + do_install_append() { # The /var/cache/lxc directory created by the Makefile # is wiped out in volatile, we need to create this at boot.
@@ -58,8 +64,15 @@ do_install_append() { } +EXTRA_OEMAKE += "TEST_DIR=${D}${PTEST_PATH}/src/tests" + +do_install_ptest() { + oe_runmake -C src/tests install-ptest +} + pkg_postinst_${PN}() { if [ -z "$D" ] && [ -e /etc/init.d/populate-volatile.sh ] ; then /etc/init.d/populate-volatile.sh update fi } +
Signature · 1 line
1.8.5.3
PATCH 2/2 lxc: Update version to 1.0.1
In reply to Mihaela Sendrea---
recipes-containers/lxc/{lxc_1.0.0.bb => lxc_1.0.1.bb} | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
rename recipes-containers/lxc/{lxc_1.0.0.bb => lxc_1.0.1.bb} (94%)recipes-containers/lxc/lxc_1.0.1.bb renamed from recipes-containers/lxc/lxc_1.0.0.bb +2 -2
@@ -30,8 +30,8 @@ SRC_URI = "http://linuxcontainers.org/downloads/${BPN}-${PV}.tar.gz \ file://runtest.patch \ file://run-ptest \ " -SRC_URI[md5sum] = "87a9d168a6e55326303cce3b2cb7f82e" -SRC_URI[sha256sum] = "0992212ddaad01dfe8c048e130566b73dd5f34191585f36bdac07a4f8a91f3bd" +SRC_URI[md5sum] = "3c7379891e45713817ec873a167070b0" +SRC_URI[sha256sum] = "17d8e5b575207b4fb57da0b8ba2d13f3e5ee20ce8ccd1259d6eae4bd5ca575b1" S = "${WORKDIR}/${BPN}-${PV}"
Signature · 1 line
1.8.5.3
Quoted 5 lines · Mihaela Sendrea
Hi,
This patch series adds libvirt to ptest framework and updates to 1.0.1. The tests that are using the ubuntu template are not installed, since they are not suitable to embedded distros.
Looks fine to me.
merged!
Bruce
Quoted 24 lines
Best regards,
Mihaela Sendrea.Mihaela Sendrea (2):
lxc: Add ptest support
lxc: Update version to 1.0.1recipes-containers/lxc/files/run-ptest | 4 +++ recipes-containers/lxc/files/runtest.patch | 32 ++++++++++++++++++++++ .../lxc/{lxc_1.0.0.bb => lxc_1.0.1.bb} | 21 +++++++++++--- 3 files changed, 53 insertions(+), 4 deletions(-) create mode 100644 recipes-containers/lxc/files/run-ptest create mode 100644 recipes-containers/lxc/files/runtest.patch rename recipes-containers/lxc/{lxc_1.0.0.bb => lxc_1.0.1.bb} (77%)--
1.8.5.3--
_______________________________________________
meta-virtualization mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualization
Signature · 2 lines
"Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end"