From: Mark Hatle <mark.hatle@windriver.com>
To: <bitbake-devel@lists.openembedded.org>
Subject: [PATCH 1/4] build.py: Add a log to capture task execution order
Date: Wed, 23 May 2012 10:45:09 -0500 [thread overview]
Message-ID: <1337787916-591-1-git-send-email-mark.hatle@windriver.com> (raw)
In-Reply-To: <cover.1337714416.git.mark.hatle@windriver.com>
The new log.task_order contains an ordered list of the tasks as they
were executed in any given recipe. The format of the lines is
<task> <pid>: <log file>
Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
---
lib/bb/build.py | 16 +++++++++++++++-
1 files changed, 15 insertions(+), 1 deletions(-)
diff --git a/lib/bb/build.py b/lib/bb/build.py
index 95f1dcf..4f06b15 100644
--- a/lib/bb/build.py
+++ b/lib/bb/build.py
@@ -290,8 +290,22 @@ def _exec_task(fn, task, d, quieterr):
bb.fatal("T variable not set, unable to build")
bb.utils.mkdirhier(tempdir)
- loglink = os.path.join(tempdir, 'log.{0}'.format(task))
+
+ # Determine the logfile to generate
logbase = 'log.{0}.{1}'.format(task, os.getpid())
+
+ # Document the order of the tasks...
+ logorder = os.path.join(tempdir, 'log.task_order')
+ try:
+ logorderfile = file(logorder, 'a')
+ except OSError:
+ logger.exception("Opening log file '%s'", logorder)
+ pass
+ logorderfile.write('{0} ({1}): {2}\n'.format(task, os.getpid(), logbase))
+ logorderfile.close()
+
+ # Setup the courtesy link to the logfn
+ loglink = os.path.join(tempdir, 'log.{0}'.format(task))
logfn = os.path.join(tempdir, logbase)
if loglink:
bb.utils.remove(loglink)
--
1.7.3.4
next prev parent reply other threads:[~2012-05-23 15:51 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-22 19:30 [PATCH 00/30] Refactor update-alternatives Mark Hatle
2012-05-23 1:46 ` [PATCH 0/3] RFC: Refactor/cleanup logging/run file generation Mark Hatle
2012-05-22 19:30 ` [PATCH 01/30] update-alternatives.bbclass: Refactor the implementation Mark Hatle
2012-05-22 20:11 ` Koen Kooi
2012-05-22 20:25 ` Mark Hatle
2012-05-22 19:30 ` [PATCH 02/30] update-alternatives.bbclass: Change from using PN to BPN Mark Hatle
2012-05-22 19:30 ` [PATCH 03/30] which: use BPN for alternatives Mark Hatle
2012-05-22 19:30 ` [PATCH 13/30] lrzsz: use new update-alternatives Mark Hatle
2012-05-22 19:30 ` [PATCH 15/30] busybox: " Mark Hatle
2012-05-22 19:30 ` [PATCH 20/30] util-linux: " Mark Hatle
2012-05-22 19:30 ` [PATCH 30/30] shadow-utils-native: remove unnecessary alternatives Mark Hatle
2012-05-23 0:06 ` [PATCH 1/3] build.py: Add a log to capture task execution order Mark Hatle
2012-05-23 0:06 ` [PATCH 2/3] build.py: Add additional debug messages Mark Hatle
2012-05-23 0:06 ` [PATCH 3/3] build.py: Add support for log and run filename changes Mark Hatle
2012-05-23 1:46 ` [PATCH 1/3] build.py: Add a log to capture task execution order Mark Hatle
2012-05-23 1:46 ` [PATCH 2/3] build.py: Add additional debug messages Mark Hatle
2012-05-23 13:50 ` Richard Purdie
2012-05-23 1:46 ` [PATCH 3/3] build.py: Add support for log and run filename changes Mark Hatle
2012-05-23 15:45 ` Mark Hatle [this message]
2012-05-23 17:15 ` [PATCH 1/4] build.py: Add a log to capture task execution order Richard Purdie
2012-05-23 15:45 ` [PATCH 2/4] build.py: Cleanup exec_func_shell Mark Hatle
2012-05-23 15:45 ` [PATCH 3/4] build.py: Add additional debug messages Mark Hatle
2012-05-23 15:45 ` [PATCH 4/4] build.py: Add support for log and run filename changes Mark Hatle
2012-05-30 12:04 ` [PATCH 00/30] Refactor update-alternatives Richard Purdie
2012-05-30 13:55 ` Mark Hatle
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1337787916-591-1-git-send-email-mark.hatle@windriver.com \
--to=mark.hatle@windriver.com \
--cc=bitbake-devel@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.