[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#777071: marked as done (does not parce architecture qualified Provides correctly, disagrees with dpkg)



Your message dated Fri, 22 May 2015 16:19:18 +0000
with message-id <E1YvpfK-0000iX-Fs@franck.debian.org>
and subject line Bug#777071: fixed in apt 1.0.9.10
has caused the Debian Bug report #777071,
regarding does not parce architecture qualified Provides correctly, disagrees with dpkg
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
777071: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=777071
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: apt
Version: 1.0.9.6
Tags: patch
User: helmutg@debian.org
Usertags: rebootstrap

Consider a system with native architecture amd64 and foreign
architecture i386. Then consider the following empty packages
(generateable with equivs):

Package: foo
Architecture: all
Provides: bar:i386

Package: baz
Architecture: i386
Depends: bar

With dpkg, baz can be installed without complaint. Then, apt-get check
loudly complains that baz' dependency on bar is not satisfied.

The underlying problem is that libapt-pkg does not correctly parse these
provides. Internally, it creates a version named "baz:i386" with
architecture amd64. Of course, such a package name is invalid and thus
this version is completely inaccessible. Thus, this bug should not cause
apt to accept a broken situation as valid. Nevertheless, it prevents
using architecture qualified depends.

The attached patch fixes the parsing problem. After upgrading to a
patched apt and running apt-get --no-download update, apt-get check no
longer complains.

If the patch looks good, it would be useful (for rebootstrap) to have
this fixed in some suite (presumably experimental) soon.

Helmut
diff -Nru apt-1.0.9.6/apt-pkg/deb/deblistparser.cc apt-1.0.9.6+nmu1/apt-pkg/deb/deblistparser.cc
--- apt-1.0.9.6/apt-pkg/deb/deblistparser.cc
+++ apt-1.0.9.6+nmu1/apt-pkg/deb/deblistparser.cc
@@ -817,10 +817,16 @@
       while (1)
       {
 	 Start = ParseDepends(Start,Stop,Package,Version,Op);
+	 const size_t archfound = Package.rfind(':');
 	 if (Start == 0)
 	    return _error->Error("Problem parsing Provides line");
 	 if (Op != pkgCache::Dep::NoOp && Op != pkgCache::Dep::Equals) {
 	    _error->Warning("Ignoring Provides line with non-equal DepCompareOp for package %s", Package.c_str());
+	 } else if (archfound != string::npos) {
+	    string OtherArch = Package.substr(archfound+1, string::npos);
+	    Package = Package.substr(0, archfound);
+	    if (NewProvides(Ver, Package, OtherArch, Version) == false)
+	       return false;
 	 } else if ((Ver->MultiArch & pkgCache::Version::Foreign) == pkgCache::Version::Foreign) {
 	    if (NewProvidesAllArch(Ver, Package, Version) == false)
 	       return false;
diff -Nru apt-1.0.9.6/debian/changelog apt-1.0.9.6+nmu1/debian/changelog
--- apt-1.0.9.6/debian/changelog
+++ apt-1.0.9.6+nmu1/debian/changelog
@@ -1,3 +1,10 @@
+apt (1.0.9.6+nmu1) UNRELEASED; urgency=low
+
+  * Non-maintainer upload.
+  * Parse architecture qualified Provides (Closes: #-1)
+
+ -- Helmut Grohne <helmut@subdivi.de>  Tue, 03 Feb 2015 20:37:34 +0100
+
 apt (1.0.9.6) unstable; urgency=medium
 
   [ Michael Vogt ]

--- End Message ---
--- Begin Message ---
Source: apt
Source-Version: 1.0.9.10

We believe that the bug you reported is fixed in the latest version of
apt, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 777071@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Michael Vogt <mvo@debian.org> (supplier of updated apt package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Fri, 22 May 2015 17:38:31 +0200
Source: apt
Binary: apt libapt-pkg4.12 libapt-inst1.5 apt-doc libapt-pkg-dev libapt-pkg-doc apt-utils apt-transport-https
Architecture: source all amd64
Version: 1.0.9.10
Distribution: unstable
Urgency: medium
Maintainer: APT Development Team <deity@lists.debian.org>
Changed-By: Michael Vogt <mvo@debian.org>
Description:
 apt        - commandline package manager
 apt-doc    - documentation for APT
 apt-transport-https - https download transport for APT
 apt-utils  - package management related utility programs
 libapt-inst1.5 - deb package format runtime library
 libapt-pkg-dev - development files for APT's libapt-pkg and libapt-inst
 libapt-pkg-doc - documentation for APT development
 libapt-pkg4.12 - package management runtime library
Closes: 777071
Changes:
 apt (1.0.9.10) unstable; urgency=medium
 .
   [ Michael Vogt ]
   * Fix crash in pkgDPkgPM::WriteApportReport(() (LP: #1436626)
   * Move sysconf(_SC_OPEN_MAX); out of the for() loop to avoid unneeded
     syscalls
   * Fix endless loop in apt-get update that can cause disk fillup
     (LP: #1445239)
 .
   [ Helmut Grohne ]
   * parse arch-qualified Provides correctly (Closes: 777071)
Checksums-Sha1:
 f2d712234b2e417f32ae0c1b0b605b8b38bb50cc 2357 apt_1.0.9.10.dsc
 d3379bdaa37b8e987e0ce5e7850cb08107606a00 1812136 apt_1.0.9.10.tar.xz
 b6e3e56efe2c676c9db46f5a802adb03d520cb65 301062 apt-doc_1.0.9.10_all.deb
 c9ef186bc4604c3e2c83d4dfe52f15cae431751f 137740 apt-transport-https_1.0.9.10_amd64.deb
 4cd2a6ee361c966ee1c3cbffb25643be3abe3a07 368968 apt-utils_1.0.9.10_amd64.deb
 012b55c115140eb10d0484a094f8d9b5f7cee40a 1110296 apt_1.0.9.10_amd64.deb
 0c5051a78339c92d850381cb3b4a00669380001d 169210 libapt-inst1.5_1.0.9.10_amd64.deb
 6e7ab65f21bbe6a1e0e6757057ba47a1fcafd5e9 193668 libapt-pkg-dev_1.0.9.10_amd64.deb
 4fe81bdffe340b5365cc56a7cadd991711af94c9 827208 libapt-pkg-doc_1.0.9.10_all.deb
 4d5cb3186d7576aa9ee850e4a2d8e38f734d0980 790186 libapt-pkg4.12_1.0.9.10_amd64.deb
Checksums-Sha256:
 c0ffa1b5bfb50ceb01d3d7696f3600503e7a8c85c934d53571e556629d2dc3c6 2357 apt_1.0.9.10.dsc
 f6d9ba405326a84cfcc3266e298ad8963e0c13f1fcfe9f269b56fc0460dce461 1812136 apt_1.0.9.10.tar.xz
 5debec93ef26bb1407d19848a247a62ba08e296df63b14083647ba4951406a7c 301062 apt-doc_1.0.9.10_all.deb
 985f0758173b2bfeb7be5bed1654d9281e8db0bbe9a73e6a160abdd503adee0c 137740 apt-transport-https_1.0.9.10_amd64.deb
 7d64c365bbea398186574f12ed2575a8be8a376dcc70defe86dfc608972ffc23 368968 apt-utils_1.0.9.10_amd64.deb
 ea1951aaf86a8e446275fcdbad3a244977e21fee8863b4caf06f0ad0aec951a5 1110296 apt_1.0.9.10_amd64.deb
 02fda797022d479f515a92b8f9e872cba51a68bcb84f07e94a62a16b46f35483 169210 libapt-inst1.5_1.0.9.10_amd64.deb
 7b00547aaa0f52eadcd492a5b23790fe823d548bdd6e29884c102f2e0fab83ca 193668 libapt-pkg-dev_1.0.9.10_amd64.deb
 4508856463e668d8d63c2cd9d2d1bbf320882d17a198b7f31762c00b9744bca9 827208 libapt-pkg-doc_1.0.9.10_all.deb
 06cab66d72b8c7b62c7a51b6235d175b5ad67502d438f5f47fec39e517ac4e77 790186 libapt-pkg4.12_1.0.9.10_amd64.deb
Files:
 33635453bc48dc8891f37786f17fa55b 2357 admin important apt_1.0.9.10.dsc
 f2913f7f1925cdd68a1c55f1145417e4 1812136 admin important apt_1.0.9.10.tar.xz
 1d5f997faf807e3cc3bef824934440e1 301062 doc optional apt-doc_1.0.9.10_all.deb
 acf1a8a7525f61fd3b1edb1c82b835bd 137740 admin optional apt-transport-https_1.0.9.10_amd64.deb
 cef2e5008a369bc3723f0d366281ff53 368968 admin important apt-utils_1.0.9.10_amd64.deb
 6f5b93d7c16d07890912ff4d056d48ec 1110296 admin important apt_1.0.9.10_amd64.deb
 71617cb0e642153595a21d6fd8ac0ee4 169210 libs important libapt-inst1.5_1.0.9.10_amd64.deb
 11a0d25e7aa96cf5a94c3d480d523df6 193668 libdevel optional libapt-pkg-dev_1.0.9.10_amd64.deb
 698f4a96a26f1319ab18d6b1c59c6d05 827208 doc optional libapt-pkg-doc_1.0.9.10_all.deb
 7f58330bb670b2a80e83a45aa2fabe70 790186 libs important libapt-pkg4.12_1.0.9.10_amd64.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBCAAGBQJVX1ABAAoJEJjKuzq9TKWe4l8P/3jOTcApB3yQhZlv3Qd+8ECM
JU+1cEcNEyOruqlTPvWhosXejrqOq2HqXbDoE67R5hnJB3YGG6WkyiN4Iw9Rs7GU
Sk627xXGtUfK3URw545x44iAizx5MQqLujW1lRpKwinpSjKvXvNOdAuAzSjknHZt
pHGgzxfsMRW0MmPdf+xcRWstUTP6+Z90eIAuPfZ+lOTjm5jDbLGzcH3hclpcWYWJ
STJaZA6CXZ8R3co42LkVNONfA7OR8RMglMcW/HT0bDYew0gswNA3l6WLd5OS2VNk
20RHS0v/k3pDGdodjIsS8xFK7qRh3yO+VRBABN4hjfz4PKgxNHINJYPXEm++BDZT
JMI8Imw4lgapov3aISoWQTOHrbYpa8HZVPDGHwfsoxmmWW3k5yt1R0De3tx/lrpV
keubmkZW+IA1VUjJsFUCkdGU1RK8xRqg5VP5+8PMNTqUWWW/fPUixHh0gFD36/jy
khpk0sQnQdwIBHph9Doyh+XdI50AWsAgmNb2mD1/iUL96lqb6bl7v84fnq/b2Ftu
6rvauFoME9gO6wqZKF1LN2zcnNjgJ7BpyQzFFVQhqpPZV2fRtGnv2wCk0dUO9idp
9XkaUiTJBdjzd7hoxtM7kr/dHuvYvLtHUiUelBO0qjoG2lrG9OsGSCQat2K5Zxrk
PfwFOan/HJR8wI+DKMnL
=c2Sy
-----END PGP SIGNATURE-----

--- End Message ---

Reply to: