Patchwork [bitbake-devel,10/16] data_smart: Allow flags to use the expand cache

login
register
mail settings
Submitter Richard Purdie
Date Sept. 16, 2013, 9:53 p.m.
Message ID <1379368413-9808-10-git-send-email-richard.purdie@linuxfoundation.org>
Download mbox | patch
Permalink /patch/58197/
State Accepted
Commit a0122ab80df21597291ff32ff7fbaa4de0347a6f
Headers show

Comments

Richard Purdie - Sept. 16, 2013, 9:53 p.m.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 lib/bb/data_smart.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Patch

diff --git a/lib/bb/data_smart.py b/lib/bb/data_smart.py
index bc4ad54..054b5cb 100644
--- a/lib/bb/data_smart.py
+++ b/lib/bb/data_smart.py
@@ -598,6 +598,8 @@  class DataSmart(MutableMapping):
             cachename = None
             if flag == "_content":
                 cachename = var
+            else:
+                cachename = var + "[" + flag + "]"
             value = self.expand(value, cachename)
         if value is not None and flag == "_content" and local_var is not None and "_removeactive" in local_var:
             filtered = filter(lambda v: v not in local_var["_removeactive"],
@@ -657,7 +659,7 @@  class DataSmart(MutableMapping):
                     continue
                 flags[i] = local_var[i]
                 if expand and i in expand:
-                    flags[i] = self.expand(flags[i], None)
+                    flags[i] = self.expand(flags[i], var + "[" + i + "]")
         if len(flags) == 0:
             return None
         return flags