summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/data_smart.py
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib/bb/data_smart.py')
-rw-r--r--bitbake/lib/bb/data_smart.py18
1 files changed, 13 insertions, 5 deletions
diff --git a/bitbake/lib/bb/data_smart.py b/bitbake/lib/bb/data_smart.py
index ecc71bd644..4ad0567c9a 100644
--- a/bitbake/lib/bb/data_smart.py
+++ b/bitbake/lib/bb/data_smart.py
@@ -722,7 +722,7 @@ class DataSmart(MutableMapping):
722 self.dict["__exportlist"]["_content"] = set() 722 self.dict["__exportlist"]["_content"] = set()
723 self.dict["__exportlist"]["_content"].add(var) 723 self.dict["__exportlist"]["_content"].add(var)
724 724
725 def getVarFlag(self, var, flag, expand=True, noweakdefault=False, parsing=False): 725 def getVarFlag(self, var, flag, expand=True, noweakdefault=False, parsing=False, retparser=False):
726 if flag == "_content": 726 if flag == "_content":
727 cachename = var 727 cachename = var
728 else: 728 else:
@@ -798,9 +798,11 @@ class DataSmart(MutableMapping):
798 if match: 798 if match:
799 value = r + value 799 value = r + value
800 800
801 parser = None
802 if expand or retparser:
803 parser = self.expandWithRefs(value, cachename)
801 if expand: 804 if expand:
802 self.expand_cache[cachename] = self.expandWithRefs(value, cachename) 805 value = parser.value
803 value = self.expand_cache[cachename].value
804 806
805 if value and flag == "_content" and local_var is not None and "_remove" in local_var and not parsing: 807 if value and flag == "_content" and local_var is not None and "_remove" in local_var and not parsing:
806 removes = [] 808 removes = []
@@ -818,8 +820,14 @@ class DataSmart(MutableMapping):
818 filtered = filter(lambda v: v not in removes, 820 filtered = filter(lambda v: v not in removes,
819 __whitespace_split__.split(value)) 821 __whitespace_split__.split(value))
820 value = "".join(filtered) 822 value = "".join(filtered)
821 if expand and cachename in self.expand_cache: 823 if parser:
822 self.expand_cache[cachename].value = value 824 parser.value = value
825
826 if parser:
827 self.expand_cache[cachename] = parser
828
829 if retparser:
830 return value, parser
823 831
824 return value 832 return value
825 833