summaryrefslogtreecommitdiffstats
path: root/meta-phosphor
diff options
context:
space:
mode:
authorPatrick Williams <patrick@stwcx.xyz>2016-07-11 13:26:20 -0500
committerGitHub <noreply@github.com>2016-07-11 13:26:20 -0500
commitaa2220b3700207278f7a2ad4b0ba800ee95b08a4 (patch)
tree30443f80f99dccd06e7b4ef1b65b70f9bca37e3d /meta-phosphor
parentb248dbdbed5550345c208f4d147a9873ce18e5e7 (diff)
parent62d676a6853ec27959d54d5060c67f60c297f68e (diff)
downloadtalos-openbmc-aa2220b3700207278f7a2ad4b0ba800ee95b08a4.tar.gz
talos-openbmc-aa2220b3700207278f7a2ad4b0ba800ee95b08a4.zip
Merge pull request #463 from bradbishop/systemd
classes-systemd: bug fix and best practices.
Diffstat (limited to 'meta-phosphor')
-rw-r--r--meta-phosphor/classes/obmc-phosphor-systemd.bbclass17
1 files changed, 8 insertions, 9 deletions
diff --git a/meta-phosphor/classes/obmc-phosphor-systemd.bbclass b/meta-phosphor/classes/obmc-phosphor-systemd.bbclass
index b07174f9f..f882bfcfe 100644
--- a/meta-phosphor/classes/obmc-phosphor-systemd.bbclass
+++ b/meta-phosphor/classes/obmc-phosphor-systemd.bbclass
@@ -7,32 +7,31 @@
# and these files will be added to the main package if they exist.
#
# Alternatively this class can just be inherited and
-# ${BPN}.service will be added to the main package.
+# ${PN}.service will be added to the main package.
inherit systemd
python() {
- bpn = d.getVar('BPN', True)
+ pn = d.getVar('PN', True)
searchpaths = d.getVar('FILESPATH', True)
- services = d.getVar('SYSTEMD_SERVICE_' + bpn, True)
+ services = d.getVar('SYSTEMD_SERVICE_' + pn, True)
if services:
services = services.split()
else:
- services = [bpn + '.service']
+ services = [pn + '.service']
for s in services:
file = s
path = bb.utils.which(searchpaths, file)
if os.path.isfile(path):
d.appendVar('SRC_URI', ' file://' + file)
- d.appendVar(
- 'FILES_' + bpn, ' ' +
- d.getVar('systemd_system_unitdir', True) + file)
+ d.appendVar("FILES_%s" %(pn), " %s/%s" \
+ % (d.getVar('systemd_system_unitdir', True), file))
d.appendVar('OBMC_SYSTEMD_SERVICES', ' ' + file)
- if file not in (d.getVar('SYSTEMD_SERVICE_' + bpn, True) or "").split():
- d.appendVar('SYSTEMD_SERVICE_' + bpn, ' ' + file)
+ if file not in (d.getVar('SYSTEMD_SERVICE_' + pn, True) or "").split():
+ d.appendVar('SYSTEMD_SERVICE_' + pn, ' ' + file)
else:
bb.error("Could not find service file: %s" % file)
}
OpenPOWER on IntegriCloud