]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
uboot-config.bbclass: Don't bail out early in multi configs
authorKevin Hao <kexin.hao@windriver.com>
Tue, 9 Aug 2022 10:28:19 +0000 (18:28 +0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 12 Aug 2022 18:22:01 +0000 (19:22 +0100)
Previously we had the support to build multiple u-boot configs for a
machine, but after the change in the commit 801a27d73b10
("uboot-config.bbclass: Raise error for bad key"), this anonymous
function would bail out after handling the first config in UBOOT_CONFIG.
This is definitely not what we want. Fix it by making sure all the
configs are handled.

Fixed: 801a27d73b10 ("uboot-config.bbclass: Raise error for bad key")
Signed-off-by: Kevin Hao <kexin.hao@windriver.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
meta/classes-recipe/uboot-config.bbclass

index 9889d026fada8c1d5daf7415d6cb3c673293279a..7ab006a20de72db2f1085d285b4d8f1acb4e2727 100644 (file)
@@ -112,8 +112,10 @@ python () {
 
     if len(ubootconfig) > 0:
         for config in ubootconfig:
+            found = False
             for f, v in ubootconfigflags.items():
                 if config == f: 
+                    found = True
                     items = v.split(',')
                     if items[0] and len(items) > 3:
                         raise bb.parse.SkipRecipe('Only config,images,binary can be specified!')
@@ -128,6 +130,8 @@ python () {
                     else:
                         bb.debug(1, "Appending '%s' to UBOOT_BINARIES." % ubootbinary)
                         d.appendVar('UBOOT_BINARIES', ' ' + ubootbinary)
-                    return
-        raise bb.parse.SkipRecipe("The selected UBOOT_CONFIG key %s has no match in %s." % (ubootconfig, ubootconfigflags.keys()))
+                    break
+
+            if not found:
+                raise bb.parse.SkipRecipe("The selected UBOOT_CONFIG key %s has no match in %s." % (ubootconfig, ubootconfigflags.keys()))
 }