]> code.ossystems Code Review - openembedded-core.git/commitdiff
buildstats.bbclass: Save ended time in TaskFinished events
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 15 Feb 2011 19:34:13 +0000 (19:34 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 15 Feb 2011 19:34:13 +0000 (19:34 +0000)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/buildstats.bbclass

index 9061b1150147bd3595f8cff2b3191227ed2959ae..0a29cfd5e1cdccbe7bc85622c4093d0484ce7965 100644 (file)
@@ -133,12 +133,13 @@ python run_buildstats () {
         timedata = get_timedata("__timedata_task", e.data)
         if not timedata:
             return
-        time, cpu = timedata
+        elapsedtime, cpu = timedata
         bsdir = os.path.join(bb.data.getVar('BUILDSTATS_BASE', e.data, True), bn)
         taskdir = os.path.join(bsdir, bb.data.expand("${PF}", e.data))
         file = open(os.path.join(taskdir, e.task), "a")
         file.write(bb.data.expand("${PF}: %s: Elapsed time: %0.2f seconds \n" %
-                               (e.task, time), e.data))
+                               (e.task, elapsedtime), e.data))
+        file.write("Ended: %0.2f \n" % time.time())
         if cpu:
             file.write("CPU usage: %0.1f%% \n" % cpu)