From: Andrei Gherzan <[email protected]>
Signed-off-by: Andrei Gherzan <[email protected]>
---
recipes-containers/podman/podman/run-ptest | 13 +++++++++++
recipes-containers/podman/podman_git.bb | 27 +++++++++++++++++++++-
2 files changed, 39 insertions(+), 1 deletion(-)
create mode 100644 recipes-containers/podman/podman/run-ptest
diff --git a/recipes-containers/podman/podman/run-ptest
b/recipes-containers/podman/podman/run-ptest
new file mode 100644
index 0000000..108ff45
--- /dev/null
+++ b/recipes-containers/podman/podman/run-ptest
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+# SPDX-FileCopyrightText: Huawei Inc.
+#
+# SPDX-License-Identifier: MIT
+
+#
+# Podman system tests
+#
+
+# The system tests don't need any go related variables. Dummy-define them to
+# avoid useless warnings/errors.
+GOOS=undefined GO=true BUILDTAGS= make localsystem
diff --git a/recipes-containers/podman/podman_git.bb
b/recipes-containers/podman/podman_git.bb
index 09bf827..9dd40d4 100644
--- a/recipes-containers/podman/podman_git.bb
+++ b/recipes-containers/podman/podman_git.bb
@@ -24,6 +24,7 @@ SRC_URI = " \
file://0002-Define-ActKillThread-equal-to-ActKill.patch;patchdir=src/import/vendor/github.com/seccomp/libseccomp-golang
\
file://CVE-2022-27649.patch;patchdir=src/import \
${@bb.utils.contains('PACKAGECONFIG', 'rootless',
'file://50-podman-rootless.conf', '', d)} \
+ file://run-ptest \
"
LICENSE = "Apache-2.0"
@@ -49,7 +50,7 @@ export LDFLAGS=""
TOOLCHAIN = "gcc"
inherit go goarch
-inherit systemd pkgconfig
+inherit systemd pkgconfig ptest
do_configure[noexec] = "1"
@@ -110,6 +111,17 @@ do_install() {
fi
}
+do_install_ptest () {
+ cp ${S}/src/import/Makefile ${D}${PTEST_PATH}
+ install -d ${D}${PTEST_PATH}/test
+ cp -r ${S}/src/import/test/system ${D}${PTEST_PATH}/test
+
+ # Some compatibility links for the Makefile assumptions.
+ install -d ${D}${PTEST_PATH}/bin
+ ln -s ${bindir}/podman ${D}${PTEST_PATH}/bin/podman
+ ln -s ${bindir}/podman-remote ${D}${PTEST_PATH}/bin/podman-remote
+}
+
FILES:${PN} += " \
${systemd_unitdir}/system/* \
${systemd_unitdir}/user/* \
@@ -129,3 +141,16 @@ RDEPENDS:${PN} += "\
"
RRECOMMENDS:${PN} += "slirp4netns kernel-module-xt-masquerade
kernel-module-xt-comment"
RCONFLICTS:${PN} = "${@bb.utils.contains('PACKAGECONFIG', 'docker', 'docker',
'', d)}"
+
+RDEPENDS:${PN}-ptest += " \
+ bash \
+ bats \
+ buildah \
+ catatonit \
+ coreutils \
+ file \
+ gnupg \
+ jq \
+ make \
+ tar \
+"
--
2.25.1
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#7598):
https://lists.yoctoproject.org/g/meta-virtualization/message/7598
Mute This Topic: https://lists.yoctoproject.org/mt/93476493/21656
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-