The following commit has been merged in the master branch:
commit 960ce492e95ea1555c2c18ca948118c291488f7c
Author: Raphaƫl Hertzog <hert...@debian.org>
Date:   Thu Dec 15 10:28:30 2011 +0100

    dpkg: Do not try to disappear other packages from the same set
    
    Packages within a set can rightfully share files and should not
    be disappeared in the case where they share all the files.
    
    Closes: #652063
    
    Reported-by: Martin Pitt <mp...@debian.org>
    Signed-off-by: Guillem Jover <guil...@debian.org>

diff --git a/src/archives.c b/src/archives.c
index 8b5c70d..82bdea4 100644
--- a/src/archives.c
+++ b/src/archives.c
@@ -152,6 +152,13 @@ filesavespackage(struct fileinlist *file,
     if (thirdpkg == pkgbeinginstalled || thirdpkg == pkgtobesaved)
       continue;
 
+    /* A Multi-Arch: same package can share files and their presence in a
+     * third package of the same set is not a sign that we can get rid of
+     * it. */
+    if (pkgtobesaved->installed.multiarch == multiarch_same &&
+        thirdpkg->set == pkgtobesaved->set)
+      continue;
+
     /* If !fileslistvalid then we've already disappeared this one, so
      * we shouldn't try to make it take over this shared directory. */
     debug(dbg_eachfiledetail,"filesavespackage ...  is 3rd package");
diff --git a/src/processarc.c b/src/processarc.c
index 7f45524..3683aef 100644
--- a/src/processarc.c
+++ b/src/processarc.c
@@ -1239,6 +1239,12 @@ void process_archive(const char *filename) {
         otherpkg->status == stat_configfiles ||
        otherpkg->clientdata->istobe == itb_remove ||
         !otherpkg->clientdata->files) continue;
+    /* Do not try to disappear other packages from the same set
+     * if they are Multi-Arch: same */
+    if (pkg->installed.multiarch == multiarch_same &&
+        otherpkg->installed.multiarch == multiarch_same &&
+        otherpkg->set == pkg->set)
+      continue;
     debug(dbg_veryverbose, "process_archive checking disappearance %s",
           pkg_name(otherpkg, pnaw_always));
     assert(otherpkg->clientdata->istobe == itb_normal ||

-- 
dpkg's main repository


-- 
To UNSUBSCRIBE, email to debian-dpkg-cvs-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to