diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-02-15 23:19:43 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-02-15 23:19:43 +0000 |
commit | 03d40a4a7bd60dcbc21f5a06c0f4f53cb47de0f3 (patch) | |
tree | 67aa9cfcdfdf0725cdc51943ef63d41a799200b3 /bitbake/lib/bb | |
parent | 579ecccc2244da43b9bc03fb09bb71d8a0219a8b (diff) | |
download | poky-03d40a4a7bd60dcbc21f5a06c0f4f53cb47de0f3.tar.gz |
bitbake/runqueue: Add a SIGCHLD handler to ensure we wake from sleeps for SIGCHLD events
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb')
-rw-r--r-- | bitbake/lib/bb/runqueue.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/bitbake/lib/bb/runqueue.py b/bitbake/lib/bb/runqueue.py index a3f444c2ab..1d38032e61 100644 --- a/bitbake/lib/bb/runqueue.py +++ b/bitbake/lib/bb/runqueue.py | |||
@@ -748,6 +748,10 @@ class RunQueueData: | |||
748 | self.rqdata.runq_depends[task], | 748 | self.rqdata.runq_depends[task], |
749 | self.rqdata.runq_revdeps[task]) | 749 | self.rqdata.runq_revdeps[task]) |
750 | 750 | ||
751 | # Dummy signal handler to ensure we break out of sleep upon SIGCHLD | ||
752 | def chldhandler(signum, stackframe): | ||
753 | pass | ||
754 | |||
751 | class RunQueue: | 755 | class RunQueue: |
752 | def __init__(self, cooker, cfgData, dataCache, taskData, targets): | 756 | def __init__(self, cooker, cfgData, dataCache, taskData, targets): |
753 | 757 | ||
@@ -760,6 +764,8 @@ class RunQueue: | |||
760 | 764 | ||
761 | self.state = runQueuePrepare | 765 | self.state = runQueuePrepare |
762 | 766 | ||
767 | signal.signal(signal.SIGCHLD, chldhandler) | ||
768 | |||
763 | def check_stamps(self): | 769 | def check_stamps(self): |
764 | unchecked = {} | 770 | unchecked = {} |
765 | current = [] | 771 | current = [] |