diff options
author | Kang Kai <kai.kang@windriver.com> | 2012-07-27 16:38:02 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-08-02 15:28:39 +0100 |
commit | b2a959a0ce039b7630c0ea537d772df647c75663 (patch) | |
tree | 087c53a0ae4d5b3ee9066cc02f516270c725e2af /bitbake/lib/bb/event.py | |
parent | 0125438b853348e8a0869e17848173c9d8d51c5d (diff) | |
download | poky-b2a959a0ce039b7630c0ea537d772df647c75663.tar.gz |
bitbake: monitordisk: fire event DISKFULL when terminate build
Part of [Yocto #2168]
Add a event DiskFull to descript the termination by disk monitor.
Update check() to fire the event DiskFull when terminates the build.
This could help UIs to deal this scenario and show more information to
end user.
(Bitbake rev: 0a0fca3d94a1db6458ae21501a66461a334410ed)
Signed-off-by: Kang Kai <kai.kang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/event.py')
-rw-r--r-- | bitbake/lib/bb/event.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/bitbake/lib/bb/event.py b/bitbake/lib/bb/event.py index 1116c0a7bf..20923b5f08 100644 --- a/bitbake/lib/bb/event.py +++ b/bitbake/lib/bb/event.py | |||
@@ -312,6 +312,14 @@ class BuildCompleted(BuildBase, OperationCompleted): | |||
312 | OperationCompleted.__init__(self, total, "Building Failed") | 312 | OperationCompleted.__init__(self, total, "Building Failed") |
313 | BuildBase.__init__(self, n, p, failures) | 313 | BuildBase.__init__(self, n, p, failures) |
314 | 314 | ||
315 | class DiskFull(Event): | ||
316 | """Disk full case build aborted""" | ||
317 | def __init__(self, dev, type, freespace, mountpoint): | ||
318 | Event.__init__(self) | ||
319 | self._dev = dev | ||
320 | self._type = type | ||
321 | self._free = freespace | ||
322 | self._mountpoint = mountpoint | ||
315 | 323 | ||
316 | class NoProvider(Event): | 324 | class NoProvider(Event): |
317 | """No Provider for an Event""" | 325 | """No Provider for an Event""" |