Skip to contentSkip to conversation

devtool: update-recipe: enable var history tracking

PATCH In review Markus Lehtonen 2 participants 2 messages Sep 30, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 devtool: update-recipe: enable var history tracking

Enable variable history tracking so that the variables are updated in the correct file - i.e. in the file they are already defined.

[YOCTO #7715]

---
 scripts/lib/devtool/__init__.py | 4 ++--
 scripts/lib/devtool/standard.py | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
scripts/lib/devtool/__init__.py +2 -2
index 7b1ab11..844aa12 100644
@@ -96,7 +96,7 @@ def exec_fakeroot(d, cmd, **kwargs):
             newenv[splitval[0]] = splitval[1]
     return subprocess.call("%s %s" % (fakerootcmd, cmd), env=newenv, **kwargs)
 
-def setup_tinfoil(config_only=False, basepath=None):
+def setup_tinfoil(config_only=False, basepath=None, tracking=False):
     """Initialize tinfoil api from bitbake"""
     import scriptpath
     orig_cwd = os.path.abspath(os.curdir)
@@ -108,7 +108,7 @@ def setup_tinfoil(config_only=False, basepath=None):
         sys.exit(1)
 
     import bb.tinfoil
-    tinfoil = bb.tinfoil.Tinfoil()
+    tinfoil = bb.tinfoil.Tinfoil(tracking=tracking)
     tinfoil.prepare(config_only)
     tinfoil.logger.setLevel(logger.getEffectiveLevel())
     os.chdir(orig_cwd)
scripts/lib/devtool/standard.py +1 -1
index 1dcf7cd..686c9d9 100644
@@ -797,7 +797,7 @@ def update_recipe(args, config, basepath, workspace):
             raise DevtoolError('conf/layer.conf not found in bbappend '
                                'destination layer "%s"' % args.append)
 
-    tinfoil = setup_tinfoil(basepath=basepath)
+    tinfoil = setup_tinfoil(basepath=basepath, tracking=True)
 
     rd = parse_recipe(config, tinfoil, args.recipename, True)
     if not rd:
Signature · 1 line
2.1.4
Acked-by on v1 1/1
#1 lore raw
Quoted 39 lines · On Wednesday 30 September 2015 16:51:53 Markus Lehtonen wrote:

Enable variable history tracking so that the variables are updated in the correct file - i.e. in the file they are already defined.

[YOCTO #7715]

---
 scripts/lib/devtool/__init__.py | 4 ++--
 scripts/lib/devtool/standard.py | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
(quoted diff) +0 -0

b/scripts/lib/devtool/__init__.py index 7b1ab11..844aa12 100644

scripts/lib/devtool/__init__.py +1 -1
@@ -96,7 +96,7 @@ def exec_fakeroot(d, cmd, **kwargs):
             newenv[splitval[0]] = splitval[1]
     return subprocess.call("%s %s" % (fakerootcmd, cmd), env=newenv,
 **kwargs)
 
-def setup_tinfoil(config_only=False, basepath=None):
+def setup_tinfoil(config_only=False, basepath=None, tracking=False):
     """Initialize tinfoil api from bitbake"""
     import scriptpath

orig_cwd = os.path.abspath(os.curdir)

scripts/lib/devtool/__init__.py +1 -1
@@ -108,7 +108,7 @@ def setup_tinfoil(config_only=False, basepath=None):
         sys.exit(1)
 
     import bb.tinfoil
-    tinfoil = bb.tinfoil.Tinfoil()
+    tinfoil = bb.tinfoil.Tinfoil(tracking=tracking)
     tinfoil.prepare(config_only)
     tinfoil.logger.setLevel(logger.getEffectiveLevel())
     os.chdir(orig_cwd)
(quoted diff) +0 -0

b/scripts/lib/devtool/standard.py index 1dcf7cd..686c9d9 100644

scripts/lib/devtool/standard.py def update_recipe(args, config, basepath, workspace): · line 803

Quoted 8 lines
scripts/lib/devtool/standard.py +1 -1
@@ -797,7 +797,7 @@ def update_recipe(args, config, basepath, workspace):
             raise DevtoolError('conf/layer.conf not found in bbappend '
                                'destination layer "%s"' % args.append)
 
-    tinfoil = setup_tinfoil(basepath=basepath)
+    tinfoil = setup_tinfoil(basepath=basepath, tracking=True)
 
     rd = parse_recipe(config, tinfoil, args.recipename, True)
     if not rd:

Cheers,
Paul

Signature · 2 lines
Paul Eggleton
Intel Open Source Technology Centre