From 07ae996d849e5edf91e2fb6712c801d10c148222 Mon Sep 17 00:00:00 2001 From: Slavic Brutalik Date: Fri, 13 Dec 2019 00:30:54 +0200 Subject: systemd-systemctl: Fix handling of aliased targets The script scans for services, parses them and makes sure those targets are still there. The exists file check fails if the target is an alias, such as default.target so add an additional test. [YOCTO #13685] (From OE-Core rev: 10bdbf033e51c97f6408c9114d480372135a2c2e) (From OE-Core rev: 64d305024e0514b832da05867672f61d1b5b3225) Signed-off-by: Werner Grift Signed-off-by: Richard Purdie Signed-off-by: Anuj Mittal Signed-off-by: Richard Purdie --- meta/recipes-core/systemd/systemd-systemctl/systemctl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'meta/recipes-core/systemd') diff --git a/meta/recipes-core/systemd/systemd-systemctl/systemctl b/meta/recipes-core/systemd/systemd-systemctl/systemctl index ebac863739..990de1ab39 100755 --- a/meta/recipes-core/systemd/systemd-systemctl/systemctl +++ b/meta/recipes-core/systemd/systemd-systemctl/systemctl @@ -172,7 +172,7 @@ class SystemdUnit(): def _path_for_unit(self, unit): for location in locations: path = self.root / location / "system" / unit - if path.exists(): + if path.exists() or path.is_symlink(): return path raise SystemdUnitNotFoundError(self.root, unit) -- cgit v1.2.3-54-g00ecf