All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] systemd: Add systemd package to PACKAGE var
@ 2013-02-12  8:22 Khem Raj
  2013-02-12  9:08 ` Ross Burton
  0 siblings, 1 reply; 8+ messages in thread
From: Khem Raj @ 2013-02-12  8:22 UTC (permalink / raw)
  To: openembedded-core

If someone defines SYSTEMD_PACKAGES to be different
then ${PN} then we need to make sure that they get
added to PACKAGES variable

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 meta/classes/systemd.bbclass |    7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/meta/classes/systemd.bbclass b/meta/classes/systemd.bbclass
index 32cc5c2..672f304 100644
--- a/meta/classes/systemd.bbclass
+++ b/meta/classes/systemd.bbclass
@@ -46,6 +46,12 @@ def systemd_populate_packages(d):
             val = (d.getVar(var, True) or "").strip()
         return val
 
+    # prepend systemd-packages not already included
+    def systemd_create_package(pkg_systemd):
+        packages = d.getVar('PACKAGES', True)
+        if not pkg_systemd in packages:
+            d.appendVar('PACKAGES', " " + pkg_systemd)
+
 
     # Add a runtime dependency on systemd to pkg
     def systemd_add_rdepends(pkg):
@@ -144,6 +150,7 @@ def systemd_populate_packages(d):
     # Run all modifications once when creating package
     if os.path.exists(d.getVar("D", True)):
         for pkg in d.getVar('SYSTEMD_PACKAGES', True).split():
+            systemd_create_package(pkg)
             if d.getVar('SYSTEMD_SERVICE_' + pkg, True):
                 systemd_generate_package_scripts(pkg)
                 systemd_add_rdepends(pkg)
-- 
1.7.9.5




^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2013-02-12 22:58 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-12  8:22 [PATCH] systemd: Add systemd package to PACKAGE var Khem Raj
2013-02-12  9:08 ` Ross Burton
2013-02-12 15:01   ` Anders Darander
2013-02-12 15:06     ` Ross Burton
2013-02-12 16:49       ` Anders Darander
2013-02-12 17:35   ` Khem Raj
2013-02-12 21:06     ` Burton, Ross
2013-02-12 22:42       ` Khem Raj

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.