From 17e2be31aeb99bfc11b9d3af0190be48d89e605c Mon Sep 17 00:00:00 2001 From: Joshua Lock Date: Wed, 17 Aug 2011 20:25:12 -0700 Subject: [PATCH] bb/ui/crumbs/tasklistmodel: remove useless items from dependency list Ensure the dependency list is uniquified, doesn't include self references and further doesn't include -dev references. (Bitbake rev: 70aebebc3867d52e460355667e711c7c6dcd50ce) Signed-off-by: Joshua Lock Signed-off-by: Richard Purdie --- bitbake/lib/bb/ui/crumbs/tasklistmodel.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/bitbake/lib/bb/ui/crumbs/tasklistmodel.py b/bitbake/lib/bb/ui/crumbs/tasklistmodel.py index fa16609..b0f5d7a 100644 --- a/bitbake/lib/bb/ui/crumbs/tasklistmodel.py +++ b/bitbake/lib/bb/ui/crumbs/tasklistmodel.py @@ -239,10 +239,11 @@ class TaskListModel(gtk.ListStore): elif ('-image-' in name): atype = 'image' + # Create a combined list of build and runtime dependencies and + # then remove any duplicate entries and any entries for -dev + # packages depends = event_model["depends"].get(item, []) rdepends = event_model["rdepends-pn"].get(item, []) - if ("%s-dev" % item) in rdepends: - rdepends.remove("%s-dev" % item) packages = {} for pkg in event_model["packages"]: if event_model["packages"][pkg]["pn"] == name: @@ -250,6 +251,13 @@ class TaskListModel(gtk.ListStore): deps.extend(depends) deps.extend(event_model["rdepends-pkg"].get(pkg, [])) deps.extend(rdepends) + deps = self.squish(deps) + # rdepends-pn includes pn-dev + if ("%s-dev" % item) in deps: + deps.remove("%s-dev" % item) + # rdepends-on includes pn + if pkg in deps: + deps.remove(pkg) packages[pkg] = deps for p in packages: -- 2.7.4