From cbe8ceb7876316d35b7ada45076f8a3e4cef6187 Mon Sep 17 00:00:00 2001 From: Bruce Ashfield Date: Wed, 9 Apr 2025 20:48:24 +0000 Subject: podman: fix PACKAGECONFIG QA errors bitbake now errors if PACKAGECONFIG is used, but doesn't have entries for the possible values in the variable. podman was using PACKAGECONFIG as a local feature variable in one case (docker) and in the other, was later adding a RDEPEND that could have been done via the packageconfig directly (rootless). The docker issue is fixed by creating a PODMAN_FEATURES variable and testing on it, and the rootless one is fixed by using PACKAGECONFIG to add the rdepends Signed-off-by: Bruce Ashfield --- recipes-containers/podman/podman_git.bb | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/recipes-containers/podman/podman_git.bb b/recipes-containers/podman/podman_git.bb index dd3e78d9..46c6c969 100644 --- a/recipes-containers/podman/podman_git.bb +++ b/recipes-containers/podman/podman_git.bb @@ -65,10 +65,13 @@ EXTRA_OEMAKE = " \ SYSTEMDDIR=${systemd_unitdir}/system USERSYSTEMDDIR=${systemd_user_unitdir} \ " -# remove 'docker' from the packageconfig if you don't want podman to +# remove 'docker' from the features if you don't want podman to # build and install the docker wrapper. If docker is enabled in the -# packageconfig, the podman package will rconfict with docker. -PACKAGECONFIG ?= "docker" +# variable, the podman package will rconfict with docker. +PODMAN_FEATURES ?= "docker" + +PACKAGECONFIG ?= "" +PACKAGECONFIG[rootless] = ",,,fuse-overlayfs slirp4netns,," do_compile() { cd ${S}/src @@ -106,7 +109,7 @@ do_install() { export GOROOT="${STAGING_DIR_NATIVE}/${nonarch_libdir}/${HOST_SYS}/go" oe_runmake install DESTDIR="${D}" - if ${@bb.utils.contains('PACKAGECONFIG', 'docker', 'true', 'false', d)}; then + if ${@bb.utils.contains('PODMAN_FEATURES', 'docker', 'true', 'false', d)}; then oe_runmake install.docker DESTDIR="${D}" fi @@ -156,7 +159,6 @@ COMPATIBLE_HOST = "^(?!mips).*" RDEPENDS:${PN} += "\ catatonit conmon ${VIRTUAL-RUNTIME_container_runtime} iptables libdevmapper \ ${VIRTUAL-RUNTIME_container_dns} ${VIRTUAL-RUNTIME_container_networking} ${VIRTUAL-RUNTIME_base-utils-nsenter} \ - ${@bb.utils.contains('PACKAGECONFIG', 'rootless', 'fuse-overlayfs slirp4netns', '', d)} \ " RRECOMMENDS:${PN} += "slirp4netns \ kernel-module-xt-masquerade \ -- cgit v1.2.3-54-g00ecf