From fb57c5f60bfb763daee663f9f6f318962edc962d Mon Sep 17 00:00:00 2001 From: Scott Murray Date: Thu, 15 Jun 2023 18:03:10 -0400 Subject: [PATCH] meta-app-framework: make applaunchd polkit dependency explicit Since there seems to be no inherent dependency in the shipped systemd default or polkit unit files with respect to polkit availability with respect to network.target, we do seem to need to make applaunchd's dependency on polkit explicit to guarantee systemd DBus API access works. As well, it seems worthwhile to enforce the systemd and polkit DISTRO_FEATURES being present if someone attempts to build applaunchd, so update the recipe to do so. Bug-AGL: SPEC-4840 Change-Id: I1cc998ac7c6234de0bb857d4c4fda00d847e00bf Signed-off-by: Scott Murray Reviewed-on: https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl/+/29020 Tested-by: Jenkins Job builder account ci-image-build: Jenkins Job builder account ci-image-boot-test: Jenkins Job builder account Reviewed-by: Jan-Simon Moeller --- .../recipes-core/applaunchd/applaunchd/applaunchd.service | 4 ++-- meta-app-framework/recipes-core/applaunchd/applaunchd_git.bb | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/meta-app-framework/recipes-core/applaunchd/applaunchd/applaunchd.service b/meta-app-framework/recipes-core/applaunchd/applaunchd/applaunchd.service index a5a2df53a..b4c2b0a22 100644 --- a/meta-app-framework/recipes-core/applaunchd/applaunchd/applaunchd.service +++ b/meta-app-framework/recipes-core/applaunchd/applaunchd/applaunchd.service @@ -1,6 +1,6 @@ [Unit] -Wants=network.target -After=network.target +Wants=network.target polkit.service +After=network.target polkit.service [Service] User=applaunchd diff --git a/meta-app-framework/recipes-core/applaunchd/applaunchd_git.bb b/meta-app-framework/recipes-core/applaunchd/applaunchd_git.bb index 767c8bcc5..38d89b23f 100644 --- a/meta-app-framework/recipes-core/applaunchd/applaunchd_git.bb +++ b/meta-app-framework/recipes-core/applaunchd/applaunchd_git.bb @@ -29,7 +29,9 @@ SRCREV = "7a3e870a8349d43a4838604db2c28140c2f76c9f" S = "${WORKDIR}/git" -inherit meson pkgconfig systemd useradd +inherit meson pkgconfig systemd useradd features_check + +REQUIRED_DISTRO_FEATURES = "systemd polkit" USERADD_PACKAGES = "${PN}" USERADDEXTENSION = "useradd-staticids" -- 2.16.6