diff options
Diffstat (limited to 'meta/classes/buildstats.bbclass')
-rw-r--r-- | meta/classes/buildstats.bbclass | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/meta/classes/buildstats.bbclass b/meta/classes/buildstats.bbclass index c6b77e6a2a..8703cb2b33 100644 --- a/meta/classes/buildstats.bbclass +++ b/meta/classes/buildstats.bbclass | |||
@@ -75,8 +75,8 @@ def get_buildtimedata(var, d): | |||
75 | return timediff, cpuperc | 75 | return timediff, cpuperc |
76 | 76 | ||
77 | def write_task_data(status, logfile, e, d): | 77 | def write_task_data(status, logfile, e, d): |
78 | bn = d.getVar('BUILDNAME', True) | 78 | bn = d.getVar('BUILDNAME') |
79 | bsdir = os.path.join(d.getVar('BUILDSTATS_BASE', True), bn) | 79 | bsdir = os.path.join(d.getVar('BUILDSTATS_BASE'), bn) |
80 | with open(os.path.join(logfile), "a") as f: | 80 | with open(os.path.join(logfile), "a") as f: |
81 | elapsedtime = get_timedata("__timedata_task", d, e.time) | 81 | elapsedtime = get_timedata("__timedata_task", d, e.time) |
82 | if elapsedtime: | 82 | if elapsedtime: |
@@ -106,9 +106,9 @@ python run_buildstats () { | |||
106 | import bb.event | 106 | import bb.event |
107 | import time, subprocess, platform | 107 | import time, subprocess, platform |
108 | 108 | ||
109 | bn = d.getVar('BUILDNAME', True) | 109 | bn = d.getVar('BUILDNAME') |
110 | bsdir = os.path.join(d.getVar('BUILDSTATS_BASE', True), bn) | 110 | bsdir = os.path.join(d.getVar('BUILDSTATS_BASE'), bn) |
111 | taskdir = os.path.join(bsdir, d.getVar('PF', True)) | 111 | taskdir = os.path.join(bsdir, d.getVar('PF')) |
112 | 112 | ||
113 | if isinstance(e, bb.event.BuildStarted): | 113 | if isinstance(e, bb.event.BuildStarted): |
114 | ######################################################################## | 114 | ######################################################################## |
@@ -162,7 +162,7 @@ python run_buildstats () { | |||
162 | if e.task == "do_rootfs": | 162 | if e.task == "do_rootfs": |
163 | bs = os.path.join(bsdir, "build_stats") | 163 | bs = os.path.join(bsdir, "build_stats") |
164 | with open(bs, "a") as f: | 164 | with open(bs, "a") as f: |
165 | rootfs = d.getVar('IMAGE_ROOTFS', True) | 165 | rootfs = d.getVar('IMAGE_ROOTFS') |
166 | if os.path.isdir(rootfs): | 166 | if os.path.isdir(rootfs): |
167 | try: | 167 | try: |
168 | rootfs_size = subprocess.check_output(["du", "-sh", rootfs], | 168 | rootfs_size = subprocess.check_output(["du", "-sh", rootfs], |
@@ -197,7 +197,7 @@ python runqueue_stats () { | |||
197 | # are available that we need to find the output directory. | 197 | # are available that we need to find the output directory. |
198 | # The persistent SystemStats is stored in the datastore and | 198 | # The persistent SystemStats is stored in the datastore and |
199 | # closed when the build is done. | 199 | # closed when the build is done. |
200 | system_stats = d.getVar('_buildstats_system_stats', True) | 200 | system_stats = d.getVar('_buildstats_system_stats') |
201 | if not system_stats and isinstance(e, (bb.runqueue.sceneQueueTaskStarted, bb.runqueue.runQueueTaskStarted)): | 201 | if not system_stats and isinstance(e, (bb.runqueue.sceneQueueTaskStarted, bb.runqueue.runQueueTaskStarted)): |
202 | system_stats = buildstats.SystemStats(d) | 202 | system_stats = buildstats.SystemStats(d) |
203 | d.setVar('_buildstats_system_stats', system_stats) | 203 | d.setVar('_buildstats_system_stats', system_stats) |