]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
devtool: modify: fix usage on the kernel paule/devtool-tinfoil2-fix
authorPaul Eggleton <paul.eggleton@linux.intel.com>
Thu, 15 Dec 2016 21:05:53 +0000 (10:05 +1300)
committerPaul Eggleton <paul.eggleton@linux.intel.com>
Thu, 15 Dec 2016 21:16:34 +0000 (10:16 +1300)
When using devtool modify on the kernel, we have to do a bit of a dance
with tinfoil instances because we only find out that we're working on a
kernel recipe after tinfoil is initialised, but then we need to build
kern-tools-native which we're doing just by running bitbake directly.
With the tinfoil2 changes, a datastore for the recipe that we were
keeping around across the opening and closing of tinfoil is no longer
able to be used. Re-parse the recipe to avoid this problem.

(In future this whole thing will be able to be done in the same tinfoil
instance thanks to tinfoil2, but that refactoring is yet to be done.)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
scripts/lib/devtool/standard.py

index c52b00678ef08b8f928009ee5f365e2de2e7f5bc..793fdaf013315263a244c46105cd72cdba31eadf 100644 (file)
@@ -746,6 +746,8 @@ def modify(args, config, basepath, workspace):
             if not tinfoil:
                 # Error already shown
                 return 1
+            # We need to re-parse because tinfoil may have been re-initialised
+            rd = parse_recipe(config, tinfoil, args.recipename, True)
 
         recipefile = rd.getVar('FILE', True)
         appendfile = recipe_to_append(recipefile, config, args.wildcard)