[bitbake-devel] [PATCH 09/16] data_smart: Allow expansion of flags in getVarFlags
Richard Purdie
richard.purdie at linuxfoundation.org
Mon Sep 16 21:53:26 UTC 2013
Allow a list of flags to expand to be passed into getVarFlags. This
is useful within bitbake itself to optimise performance of the
dependency generation code.
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
lib/bb/data_smart.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/lib/bb/data_smart.py b/lib/bb/data_smart.py
index 970e404..bc4ad54 100644
--- a/lib/bb/data_smart.py
+++ b/lib/bb/data_smart.py
@@ -647,7 +647,7 @@ class DataSmart(MutableMapping):
self.varhistory.record(**loginfo)
self.dict[var][i] = flags[i]
- def getVarFlags(self, var, internalflags=False):
+ def getVarFlags(self, var, expand = False, internalflags=False):
local_var = self._findVar(var)
flags = {}
@@ -656,7 +656,8 @@ class DataSmart(MutableMapping):
if i.startswith("_") and not internalflags:
continue
flags[i] = local_var[i]
-
+ if expand and i in expand:
+ flags[i] = self.expand(flags[i], None)
if len(flags) == 0:
return None
return flags
--
1.8.1.2
More information about the bitbake-devel
mailing list