summaryrefslogtreecommitdiffstats
path: root/meta/classes/uboot-config.bbclass
diff options
context:
space:
mode:
Diffstat (limited to 'meta/classes/uboot-config.bbclass')
-rw-r--r--meta/classes/uboot-config.bbclass12
1 files changed, 5 insertions, 7 deletions
diff --git a/meta/classes/uboot-config.bbclass b/meta/classes/uboot-config.bbclass
index fc37620369..44b46ffa0b 100644
--- a/meta/classes/uboot-config.bbclass
+++ b/meta/classes/uboot-config.bbclass
@@ -7,14 +7,12 @@
7# 7#
8# Copyright 2013 (C) O.S. Systems Software LTDA. 8# Copyright 2013 (C) O.S. Systems Software LTDA.
9 9
10addhandler uboot_config_eventhandler 10python () {
11uboot_config_eventhandler[eventmask] = "bb.event.ConfigParsed" 11 ubootconfigflags = d.getVarFlags('UBOOT_CONFIG')
12python uboot_config_eventhandler() {
13 ubootconfigflags = e.data.getVarFlags('UBOOT_CONFIG')
14 if not ubootconfigflags: 12 if not ubootconfigflags:
15 return 13 return
16 14
17 ubootconfig = (e.data.getVar('UBOOT_CONFIG', True) or "").split() 15 ubootconfig = (d.getVar('UBOOT_CONFIG', True) or "").split()
18 if len(ubootconfig) > 1: 16 if len(ubootconfig) > 1:
19 raise bb.parse.SkipPackage('You can only have a single default for UBOOT_CONFIG.') 17 raise bb.parse.SkipPackage('You can only have a single default for UBOOT_CONFIG.')
20 elif len(ubootconfig) == 0: 18 elif len(ubootconfig) == 0:
@@ -31,9 +29,9 @@ python uboot_config_eventhandler() {
31 29
32 if ubootconfig == f: 30 if ubootconfig == f:
33 bb.debug(1, "Setting UBOOT_MACHINE to %s." % items[0]) 31 bb.debug(1, "Setting UBOOT_MACHINE to %s." % items[0])
34 e.data.setVar('UBOOT_MACHINE', items[0]) 32 d.setVar('UBOOT_MACHINE', items[0])
35 33
36 if items[1]: 34 if items[1]:
37 bb.debug(1, "Appending '%s' to IMAGE_FSTYPES." % items[1]) 35 bb.debug(1, "Appending '%s' to IMAGE_FSTYPES." % items[1])
38 e.data.appendVar('IMAGE_FSTYPES', ' ' + items[1]) 36 d.appendVar('IMAGE_FSTYPES', ' ' + items[1])
39} 37}