From: Martin Jansa <martin.jansa@gmail.com>
To: bitbake-devel@lists.openembedded.org
Subject: [PATCH] siggen: compare runtaskdeps dictionary even when they have the same size
Date: Wed, 22 Feb 2012 14:03:04 +0100 [thread overview]
Message-ID: <1329915784-24760-1-git-send-email-Martin.Jansa@gmail.com> (raw)
* otherwise it reports lots of changed checksums just because it compares different tasks
notice linux-libc-headers_3.1.bb.do_package_write:
Task dependency hash changed from 42acced29debf54d598802474c5e9cbb to f438a54f995df77620d0727d6f4b4ce5 (for linux-libc-headers_3.1.bb.do_package_write and linux-gta04_git.bb.do_deploy)
Task dependency hash changed from 61f8babe1d10c6e7fb1423112bb04e1e to 1b3e21ff106ecfcb7ddf76a1e29537bb (for linux-nokia900-meego_git.bb.do_deploy and linux-gta04_git.bb.do_package_write)
Task dependency hash changed from 512f9d6686d760b318d8b11c8b589226 to 42acced29debf54d598802474c5e9cbb (for linux-nokia900-meego_git.bb.do_package_write and linux-libc-headers_3.1.bb.do_package_write)
Task dependency hash changed from 153e91dfd1d2053fda7b98cc08d4b802 to 92a293bdd8ed234932b87a66025038c5 (for systemd-serialgetty.bb.do_package_write and systemd-serialgetty.bb.do_package_write)
Task dependency hash changed from 730abebf9954794bb440c2f3239f79fe to 413eaebaff27a2fd16f5cf68c1f4ff17 (for systemd_git.bb.do_package_write and systemd_git.bb.do_package_write)
with this patch:
Dependency on task linux-nokia900-meego_git.bb.do_package_write was added
Dependency on task linux-nokia900-meego_git.bb.do_deploy was added
Dependency on task linux-gta04_git.bb.do_deploy was removed
Dependency on task linux-gta04_git.bb.do_package_write was removed
Hash for dependent task systemd_git.bb.do_package_write changed from 730abebf9954794bb440c2f3239f79fe to 413eaebaff27a2fd16f5cf68c1f4ff17
Hash for dependent task systemd-serialgetty.bb.do_package_write changed from 153e91dfd1d2053fda7b98cc08d4b802 to 92a293bdd8ed234932b87a66025038c5
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
---
lib/bb/siggen.py | 33 ++++++++++++---------------------
1 files changed, 12 insertions(+), 21 deletions(-)
diff --git a/lib/bb/siggen.py b/lib/bb/siggen.py
index f31d66a..ffe85dd 100644
--- a/lib/bb/siggen.py
+++ b/lib/bb/siggen.py
@@ -292,27 +292,18 @@ def compare_sigfiles(a, b):
print "Variable %s value changed from %s to %s" % (dep, a_data['varvals'][dep], b_data['varvals'][dep])
if 'runtaskhashes' in a_data and 'runtaskhashes' in b_data:
- if len(a_data['runtaskdeps']) != len(b_data['runtaskdeps']):
- a = clean_basepaths(a_data['runtaskhashes'])
- b = clean_basepaths(b_data['runtaskhashes'])
- changed, added, removed = dict_diff(a, b)
- if added:
- for dep in added:
- print "Dependency on task %s was added" % (dep)
- if removed:
- for dep in removed:
- print "Dependency on task %s was removed" % (dep)
- if changed:
- for dep in changed:
- print "Hash for dependent task %s changed from %s to %s" % (dep, a[dep], b[dep])
- else:
- for i in range(len(a_data['runtaskdeps'])):
- aent = a_data['runtaskdeps'][i]
- bent = b_data['runtaskdeps'][i]
- aname = clean_basepath(aent)
- bname = clean_basepath(bent)
- if a_data['runtaskhashes'][aent] != b_data['runtaskhashes'][bent]:
- print "Task dependency hash changed from %s to %s (for %s and %s)" % (a_data['runtaskhashes'][aent], b_data['runtaskhashes'][bent], aname, bname)
+ a = clean_basepaths(a_data['runtaskhashes'])
+ b = clean_basepaths(b_data['runtaskhashes'])
+ changed, added, removed = dict_diff(a, b)
+ if added:
+ for dep in added:
+ print "Dependency on task %s was added" % (dep)
+ if removed:
+ for dep in removed:
+ print "Dependency on task %s was removed" % (dep)
+ if changed:
+ for dep in changed:
+ print "Hash for dependent task %s changed from %s to %s" % (dep, a[dep], b[dep])
def dump_sigfile(a):
p1 = pickle.Unpickler(file(a, "rb"))
--
1.7.8.4
next reply other threads:[~2012-02-22 13:11 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-22 13:03 Martin Jansa [this message]
2012-02-22 14:37 ` [PATCH] siggen: compare runtaskdeps dictionary even when they have the same size Richard Purdie
2012-02-22 15:01 ` Martin Jansa
2012-02-22 20:33 ` Richard Purdie
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=1329915784-24760-1-git-send-email-Martin.Jansa@gmail.com \
--to=martin.jansa@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox