X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=melanie;h=3b2596ccc4170ec5ed67d9c252efcd7301a2a910;hb=de3991e803cc6f69d5eee0fbf75daf95b0f9969d;hp=9cf88c99b9aca81ed10a5c0f57e3c931a76a190d;hpb=4e3271db6f9f93073b7a173f3f95c89fa369d0bb;p=dak.git diff --git a/melanie b/melanie index 9cf88c99..3b2596cc 100755 --- a/melanie +++ b/melanie @@ -2,7 +2,7 @@ # General purpose package removal tool for ftpmaster # Copyright (C) 2000, 2001, 2002, 2003, 2004 James Troup -# $Id: melanie,v 1.42 2004-11-27 13:28:16 troup Exp $ +# $Id: melanie,v 1.44 2005-11-15 09:50:32 ajt Exp $ # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -98,11 +98,12 @@ def reverse_depends_check(removals, suites): print "Checking reverse dependencies..." components = Cnf.ValueList("Suite::%s::Components" % suites[0]) dep_problem = 0 + p2c = {}; for architecture in Cnf.ValueList("Suite::%s::Architectures" % suites[0]): if architecture in ["source", "all"]: continue - deps = {} - virtual_packages = {} + deps = {}; + virtual_packages = {}; for component in components: filename = "%s/dists/%s/%s/binary-%s/Packages.gz" % (Cnf["Dir::Root"], suites[0], component, architecture) # apt_pkg.ParseTagFile needs a real file handle and can't handle a GzipFile instance... @@ -132,6 +133,7 @@ def reverse_depends_check(removals, suites): virtual_packages[virtual_pkg] = 0 if package not in removals: virtual_packages[virtual_pkg] += 1 + p2c[package] = component; packages.close() os.unlink(temp_filename); @@ -158,7 +160,12 @@ def reverse_depends_check(removals, suites): if dep_package in removals: unsat += 1 if unsat == len(dep): - print "%s has an unsatisfied dependency on %s: %s" % (package, architecture, utils.pp_dep(dep)) + component = p2c[package]; + if component != "main": + what = "%s/%s" % (package, component); + else: + what = "** %s" % (package); + print "%s has an unsatisfied dependency on %s: %s" % (what, architecture, utils.pp_deps(dep)); dep_problem = 1 # Check source dependencies (Build-Depends and Build-Depends-Indep) @@ -191,7 +198,11 @@ def reverse_depends_check(removals, suites): if dep_package in removals: unsat += 1 if unsat == len(dep): - print "%s has an unsatisfied build-dependency: %s" % (source, utils.pp_dep(dep)) + if component != "main": + source = "%s/%s" % (source, component); + else: + source = "** %s" % (source); + print "%s has an unsatisfied build-dependency: %s" % (source, utils.pp_deps(dep)) dep_problem = 1 sources.close() os.unlink(temp_filename) @@ -498,7 +509,7 @@ def main (): Subst["__BCC__"] = "Bcc: " + ", ".join(bcc); else: Subst["__BCC__"] = "X-Filler: 42"; - Subst["__CC__"] = "X-Katie: melanie $Revision: 1.42 $"; + Subst["__CC__"] = "X-Katie: melanie $Revision: 1.44 $"; if carbon_copy: Subst["__CC__"] += "\nCc: " + ", ".join(carbon_copy); Subst["__SUITE_LIST__"] = suites_list;