Skip to contentSkip to conversation

systemd.bbclass: Add /usr/lib/systemd to searchpaths as well

PATCH New Khem Raj 1 participant 1 message Mar 10, 2023

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH 1/1 systemd.bbclass: Add /usr/lib/systemd to searchpaths as well

Some packages like lirc places its unit files into $systemd_user_unitdir and also uses them in SYSTEMD_SERVICE list in recipe. This fails in do_package

ERROR: Didn't find service unit 'lircmd.service', specified in SYSTEMD_SERVICE:lirc.

here lircmd.service is installed in /usr/lib/systemd/system/lircmd.service

---
 meta/classes-recipe/systemd.bbclass | 1 +
 1 file changed, 1 insertion(+)
meta/classes-recipe/systemd.bbclass +1 -0
index f9c92e6c2a..9a16babe43 100644
@@ -152,6 +152,7 @@ python systemd_populate_packages() {
     def systemd_check_services():
         searchpaths = [oe.path.join(d.getVar("sysconfdir"), "systemd", "system"),]
         searchpaths.append(d.getVar("systemd_system_unitdir"))
+        searchpaths.append(d.getVar("systemd_user_unitdir"))
         systemd_packages = d.getVar('SYSTEMD_PACKAGES')
 
         keys = 'Also'
Signature · 1 line
2.39.2