From 3edf300dd672e9a78b0965c65c65cc73a1e4c7dc Mon Sep 17 00:00:00 2001 From: Michael Bienia Date: Thu, 25 Mar 2010 22:15:56 +0100 Subject: [PATCH] Apply patch from Julian Andres Klode for the python-apt 0.8 API transition (Closes: #572091) --- 404main | 16 ++++++++-------- debian/changelog | 4 +++- debian/control | 2 +- 3 files changed, 12 insertions(+), 10 deletions(-) diff --git a/404main b/404main index e3f93d9..0af19b7 100755 --- a/404main +++ b/404main @@ -88,19 +88,19 @@ def find_main(cache, pack): # attribute on version for this, so unfortunately we have to # do a lot of messing about with apt. deps = [] - src_records = apt_pkg.GetPkgSrcRecords() + src_records = apt_pkg.SourceRecords() got_src = False - while src_records.Lookup(version.source_name): - if pack in src_records.Binaries: + while src_records.lookup(version.source_name): + if pack in src_records.binaries: got_src = True break if got_src: - base_deps = [] - for (name, ver, op, deptype) in src_records.BuildDepends: - base_deps.append(apt.package.BaseDependency(name, comp_type_deb(op), ver, False)) - if (op & 16) != 16: - deps.append(apt.package.Dependency(base_deps)) + for deptype, all_deps in src_records.build_depends.iteritems(): + for or_deps in all_deps: base_deps = [] + for (name, ver, op) in or_deps: + base_deps.append(apt.package.BaseDependency(name, op, ver, False)) + deps.append(apt.package.Dependency(base_deps)) process_deps(cache, deps) diff --git a/debian/changelog b/debian/changelog index 64a5367..b29ea81 100644 --- a/debian/changelog +++ b/debian/changelog @@ -10,8 +10,10 @@ ubuntu-dev-tools (0.97) UNRELEASED; urgency=low * doc/requestsync.1: Update the paragraph about sponsoring (lp: #538990). * pull-lp-source: Use (anonymously) the LP API to get the URL for the .dsc file instead of screen scraping. + * Apply patch from Julian Andres Klode for the python-apt 0.8 API transition + (Closes: #572091) - -- Michael Bienia Sat, 20 Mar 2010 20:21:24 +0100 + -- Michael Bienia Thu, 25 Mar 2010 21:58:47 +0100 ubuntu-dev-tools (0.96) lucid; urgency=low diff --git a/debian/control b/debian/control index 9cfcbe9..8800f1b 100644 --- a/debian/control +++ b/debian/control @@ -14,7 +14,7 @@ Package: ubuntu-dev-tools Architecture: all Depends: ${python:Depends}, ${misc:Depends}, binutils, devscripts, sudo, python-debian, python-launchpadlib (>= 1.5.4), dctrl-tools, lsb-release, diffstat, - dpkg-dev, python-apt (>= 0.7.9), python-lazr.restfulclient + dpkg-dev, python-apt (>= 0.7.93~), python-lazr.restfulclient Recommends: bzr, pbuilder | cowdancer | sbuild, reportbug (>= 3.39ubuntu1), ca-certificates, debootstrap, genisoimage, perl-modules, libwww-perl, libapt-pkg-perl