summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/cooker.py
diff options
context:
space:
mode:
authorLiping Ke <liping.ke@intel.com>2011-06-03 08:22:40 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2011-06-07 22:40:01 +0100
commit5af197b55a4b779f1ec93186f0723026949ba2b5 (patch)
tree935a789f32e2f284cd71359461785f1f6eaa751a /bitbake/lib/bb/cooker.py
parentb3c41b1f469a1d4d558e5dbef827322444d3ba54 (diff)
downloadpoky-5af197b55a4b779f1ec93186f0723026949ba2b5.tar.gz
cache: Implement multiple extra cache fields request support
This patch is to support extra cache. If user needs to request extra cache fields besides CoreRecipeInfo fields, just add a new XXXRecipeInfo class definition as Hob Does. Currently supported Extra RecipeInfo name is an array. We can support multiple extra cache fields at the same time besides CoreRecipeInfo which is needed by all clients. (Bitbake rev: 077657e50ad032c0fa876bf54e9802af2686e0fb) Signed-off-by: Liping Ke <liping.ke@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/cooker.py')
-rw-r--r--bitbake/lib/bb/cooker.py16
1 files changed, 8 insertions, 8 deletions
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py
index 89da7e99cf..8379d0caf1 100644
--- a/bitbake/lib/bb/cooker.py
+++ b/bitbake/lib/bb/cooker.py
@@ -773,13 +773,13 @@ class BBCooker:
773 773
774 fn = bb.cache.Cache.realfn2virtual(fn, cls) 774 fn = bb.cache.Cache.realfn2virtual(fn, cls)
775 try: 775 try:
776 maininfo = infos[fn] 776 info_array = infos[fn]
777 except KeyError: 777 except KeyError:
778 bb.fatal("%s does not exist" % fn) 778 bb.fatal("%s does not exist" % fn)
779 self.status.add_from_recipeinfo(fn, maininfo) 779 self.status.add_from_recipeinfo(fn, info_array)
780 780
781 # Tweak some variables 781 # Tweak some variables
782 item = maininfo.pn 782 item = info_array[0].pn
783 self.status.ignored_dependencies = set() 783 self.status.ignored_dependencies = set()
784 self.status.bbfile_priority[fn] = 1 784 self.status.bbfile_priority[fn] = 1
785 785
@@ -1231,10 +1231,10 @@ class CookerParser(object):
1231 else: 1231 else:
1232 self.cached += 1 1232 self.cached += 1
1233 1233
1234 for virtualfn, info in result: 1234 for virtualfn, info_array in result:
1235 if info.skipped: 1235 if info_array[0].skipped:
1236 self.skipped += 1 1236 self.skipped += 1
1237 self.bb_cache.add_info(virtualfn, info, self.cooker.status, 1237 self.bb_cache.add_info(virtualfn, info_array, self.cooker.status,
1238 parsed=parsed) 1238 parsed=parsed)
1239 return True 1239 return True
1240 1240
@@ -1242,5 +1242,5 @@ class CookerParser(object):
1242 infos = self.bb_cache.parse(filename, 1242 infos = self.bb_cache.parse(filename,
1243 self.cooker.get_file_appends(filename), 1243 self.cooker.get_file_appends(filename),
1244 self.cfgdata, self.cooker.caches_array) 1244 self.cfgdata, self.cooker.caches_array)
1245 for vfn, info in infos: 1245 for vfn, info_array in infos:
1246 self.cooker.status.add_from_recipeinfo(vfn, info) 1246 self.cooker.status.add_from_recipeinfo(vfn, info_array)