summaryrefslogtreecommitdiffstats
path: root/meta/classes/sstate.bbclass
diff options
context:
space:
mode:
authorAlexandru DAMIAN <alexandru.damian@intel.com>2014-03-31 17:39:18 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-03-31 22:53:45 +0100
commitedd500ed0de0cd085f5e5b3a3a317c1d511db3d2 (patch)
treedeaaa83082d005172999fa039e94075ba6127cbe /meta/classes/sstate.bbclass
parentcb0bb7c823ebf1466332b61dcf4d818fbdcce925 (diff)
downloadpoky-edd500ed0de0cd085f5e5b3a3a317c1d511db3d2.tar.gz
sstate.bbclass: update missed sstate event
This is a patch to update the missed sstate event with info about the sstate files locations that were found. It's needed as to display the found file in the toaster ui. Also fixes a bug where a setscene task may have appeared in the missed list even if it was found in a sstate mirror. (From OE-Core rev: ad66cd521d3e661dd57c5aa02c204585101984f3) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/sstate.bbclass')
-rw-r--r--meta/classes/sstate.bbclass12
1 files changed, 10 insertions, 2 deletions
diff --git a/meta/classes/sstate.bbclass b/meta/classes/sstate.bbclass
index 25b8d72633..f761909f3d 100644
--- a/meta/classes/sstate.bbclass
+++ b/meta/classes/sstate.bbclass
@@ -690,6 +690,8 @@ def sstate_checkhashes(sq_fn, sq_task, sq_hash, sq_hashfn, d):
690 fetcher.checkstatus() 690 fetcher.checkstatus()
691 bb.debug(2, "SState: Successful fetch test for %s" % srcuri) 691 bb.debug(2, "SState: Successful fetch test for %s" % srcuri)
692 ret.append(task) 692 ret.append(task)
693 if task in missed:
694 missed.remove(task)
693 except: 695 except:
694 missed.append(task) 696 missed.append(task)
695 bb.debug(2, "SState: Unsuccessful fetch test for %s" % srcuri) 697 bb.debug(2, "SState: Unsuccessful fetch test for %s" % srcuri)
@@ -697,9 +699,15 @@ def sstate_checkhashes(sq_fn, sq_task, sq_hash, sq_hashfn, d):
697 699
698 inheritlist = d.getVar("INHERIT", True) 700 inheritlist = d.getVar("INHERIT", True)
699 if "toaster" in inheritlist: 701 if "toaster" in inheritlist:
700 evdata = [] 702 evdata = {'missed': [], 'found': []};
701 for task in missed: 703 for task in missed:
702 evdata.append( (sq_fn[task], sq_task[task], sq_hash[task], generate_sstatefn(spec, sq_hash[task],d) ) ) 704 spec, extrapath, tname = getpathcomponents(task, d)
705 sstatefile = d.expand(extrapath + generate_sstatefn(spec, sq_hash[task], d) + "_" + tname + ".tgz")
706 evdata['missed'].append( (sq_fn[task], sq_task[task], sq_hash[task], sstatefile ) )
707 for task in ret:
708 spec, extrapath, tname = getpathcomponents(task, d)
709 sstatefile = d.expand(extrapath + generate_sstatefn(spec, sq_hash[task], d) + "_" + tname + ".tgz")
710 evdata['found'].append( (sq_fn[task], sq_task[task], sq_hash[task], sstatefile ) )
703 bb.event.fire(bb.event.MetadataEvent("MissedSstate", evdata), d) 711 bb.event.fire(bb.event.MetadataEvent("MissedSstate", evdata), d)
704 712
705 return ret 713 return ret