]> git.pld-linux.org Git - packages/rpm.git/commitdiff
updated old patches to rpm5
authorJan Rękorajski <baggins@pld-linux.org>
Tue, 4 Sep 2012 05:37:04 +0000 (07:37 +0200)
committerJan Rękorajski <baggins@pld-linux.org>
Tue, 4 Sep 2012 05:37:04 +0000 (07:37 +0200)
rpm-builddir-readlink.patch
rpm-changelog_order_check_nonfatal.patch
rpm-cleanbody.patch
rpm-dirdeps-macro.patch
rpm-installbeforeerase.patch
rpm-libmagic-locale.patch
rpm-namespace-probe.patch
rpm-postun-nofail.patch

index 11afecfdd895c9841e3be2f02c7e291e14622e7d..0453045fc8eb04eebabb1ad5d77fa64b4670bfb3 100644 (file)
@@ -1,9 +1,9 @@
 --- rpm-4.5/scripts/find-debuginfo.sh~ 2010-01-27 19:25:48.000000000 +0200
 +++ rpm-4.5/scripts/find-debuginfo.sh  2010-01-27 20:23:37.279516094 +0200
 @@ -24,6 +24,11 @@
- # Barf on missing build IDs.
  strict=false
  
+ RPM_BUILD_DIR="`pwd`"
 +# canon RPM_BUILD_DIR, the DW_AT_comp_dir in ELF objects is real a real path
 +# and debugedit will ignore them as they are out of build dir.
 +RPM_BUILD_DIR=$(readlink -f "$RPM_BUILD_DIR")
@@ -21,6 +21,6 @@
 +    $strict && exit 2
 +  fi
 +
+   [ -x /usr/bin/gdb-add-index ] && /usr/bin/gdb-add-index "$f" > /dev/null 2>&1
    # A binary already copied into /usr/lib/debug doesn't get stripped,
-   # just has its file names collected and adjusted.
-   case "$dn" in
index bf2ef0409b45274e5876de8fdf6a9f79d229e0a3..9211b91d76473838c0fa4633bd18179aab4e05a5 100644 (file)
@@ -1,13 +1,13 @@
 --- rpm-4.5/build/parseChangelog.c.orig        2012-07-24 14:46:12.856158625 +0200
 +++ rpm-4.5/build/parseChangelog.c     2012-07-24 14:47:55.293158624 +0200
 @@ -181,9 +181,8 @@
-           return RPMERR_BADSPEC;
+           return RPMRC_FAIL;
        }
        if (lastTime && lastTime < time) {
--          rpmError(RPMERR_BADSPEC,
-+          rpmMessage(RPMMESS_WARNING,
+-          rpmlog(RPMLOG_ERR,
++          rpmlog(RPMLOG_WARNING,
                     _("%%changelog not in descending chronological order\n"));
--          return RPMERR_BADSPEC;
+-          return RPMRC_FAIL;
        }
        lastTime = time;
  
index f8b29efa47937feac44880f5691ff166ec1371af..4c25d33ac467a3414dac839d61bfb6bd1765459c 100644 (file)
@@ -1,10 +1,11 @@
 --- rpm-4.4.9/build/parseBuildInstallClean.c   2008-01-30 23:16:55.347346942 +0200
 +++ rpm-4.4.9/build/parseBuildInstallClean.c   2008-01-30 23:22:24.241459876 +0200
-@@ -51,7 +51,6 @@
+@@ -51,7 +51,7 @@
        if (s && *s)
-           appendStringBuf(*sbp, s);
+           *iobp = rpmiobAppend(*iobp, s, 0);
        s = _free(s);
--      sbp = NULL;     /* XXX skip %clean from spec file. */
-     }
-     /* There are no options to %build, %install, %check, or %clean */
+-#if !defined(RPM_VENDOR_OPENPKG) /* still-support-section-clean */
++#if !defined(RPM_VENDOR_OPENPKG) && !defined(RPM_VENDOR_PLD) /* still-support-section-clean */
+       /* OpenPKG still wishes to use "%clean" script/section */
+       iobp = NULL;    /* XXX skip %clean from spec file. */
+ #endif
index 2cef12db01c0b774ec09f9fa752efbf12f20f13d..8c8c88276b62bf7061b279e531354f628edcaa45 100644 (file)
@@ -1,45 +1,38 @@
-Index: lib/depends.c
-===================================================================
-RCS file: /v/rpm/cvs/rpm/lib/depends.c,v
-retrieving revision 1.404
-retrieving revision 1.405
-diff -w -u -r1.404 -r1.405
---- lib/depends.c      3 Jul 2008 15:08:05 -0000       1.404
-+++ lib/depends.c      17 Jul 2008 13:57:42 -0000      1.405
-@@ -1462,6 +1462,8 @@
+--- rpm-5.4.10/lib/depends.c~  2012-04-15 23:20:56.000000000 +0200
++++ rpm-5.4.10/lib/depends.c   2012-09-03 23:00:59.363079731 +0200
+@@ -1569,7 +1569,7 @@
      int terminate = 2;                /* XXX terminate if rc >= terminate */
      int rc;
      int ourrc = 0;
-+    int dirname_deps;
-+    int symlink_deps;
-     requires = rpmdsInit(requires);
-     if (requires != NULL)
-@@ -1537,6 +1539,8 @@
+-#if defined(RPM_VENDOR_MANDRIVA) || defined(RPM_VENDOR_ARK) || defined(RPM_OPTIONAL_DIRNAME_AND_SYMLINK_DEPS) /* optional-dirname-and-symlink-deps */
++#if defined(RPM_VENDOR_MANDRIVA) || defined(RPM_VENDOR_ARK) || defined(RPM_VENDOR_PLD) || defined(RPM_OPTIONAL_DIRNAME_AND_SYMLINK_DEPS) /* optional-dirname-and-symlink-deps */
+     int dirname_deps;
+     int symlink_deps;
+ #endif
+@@ -1648,7 +1648,7 @@
        }
      }
  
-+    dirname_deps = rpmExpandNumeric("%{?_check_dirname_deps}%{?!_check_dirname_deps:1}");
-+    if (dirname_deps) {
-     dirnames = rpmdsInit(dirnames);
-     if (dirnames != NULL)
-     while (ourrc < terminate && rpmdsNext(dirnames) >= 0) {
-@@ -1577,7 +1581,10 @@
+-#if defined(RPM_VENDOR_MANDRIVA) || defined(RPM_VENDOR_ARK) || defined(RPM_OPTIONAL_DIRNAME_AND_SYMLINK_DEPS) /* optional-dirname-and-symlink-deps */
++#if defined(RPM_VENDOR_MANDRIVA) || defined(RPM_VENDOR_ARK) || defined(RPM_VENDOR_PLD) || defined(RPM_OPTIONAL_DIRNAME_AND_SYMLINK_DEPS) /* optional-dirname-and-symlink-deps */
+     dirname_deps = rpmExpandNumeric("%{?_check_dirname_deps}%{?!_check_dirname_deps:1}");
+     if (dirname_deps) {
+ #endif
+@@ -1692,7 +1692,7 @@
            /*@switchbreak@*/ break;
        }
      }
-+    }
-+    symlink_deps = rpmExpandNumeric("%{?_check_symlink_deps}%{?!_check_symlink_deps:1}");
-+    if (symlink_deps) {
-     linktos = rpmdsInit(linktos);
-     if (linktos != NULL)
-     while (ourrc < terminate && rpmdsNext(linktos) >= 0) {
-@@ -1595,6 +1602,7 @@
-       dscolor = rpmdsColor(linktos);
-       if (tscolor && dscolor && !(tscolor & dscolor))
-           continue;
-+    }
+-#if defined(RPM_VENDOR_MANDRIVA) || defined(RPM_VENDOR_ARK) || defined(RPM_OPTIONAL_DIRNAME_AND_SYMLINK_DEPS) /* optional-dirname-and-symlink-deps */
++#if defined(RPM_VENDOR_MANDRIVA) || defined(RPM_VENDOR_ARK) || defined(RPM_VENDOR_PLD) || defined(RPM_OPTIONAL_DIRNAME_AND_SYMLINK_DEPS) /* optional-dirname-and-symlink-deps */
+     }
  
-       rc = unsatisfiedDepend(ts, linktos, adding);
+     symlink_deps = rpmExpandNumeric("%{?_check_symlink_deps}%{?!_check_symlink_deps:1}");
+@@ -1740,7 +1740,7 @@
+           /*@switchbreak@*/ break;
+       }
+     }
+-#if defined(RPM_VENDOR_MANDRIVA) || defined(RPM_VENDOR_ARK) || defined(RPM_OPTIONAL_DIRNAME_AND_SYMLINK_DEPS) /* optional-dirname-and-symlink-deps */
++#if defined(RPM_VENDOR_MANDRIVA) || defined(RPM_VENDOR_ARK) || defined(RPM_VENDOR_PLD) || defined(RPM_OPTIONAL_DIRNAME_AND_SYMLINK_DEPS) /* optional-dirname-and-symlink-deps */
+     }
+ #endif    
  
index 33715cf99cf8dccc3171757a0083438b1ab376b8..8939bfa027ca92ab88a6dbbf996914c14080cfb3 100644 (file)
@@ -4,49 +4,32 @@
        - glen: do not skip %clean from spec file
        - robert: install rpmdeps and debugedit to pkglibdir as on HEAD
        - jbj: fix: python ts.hdrFromFdno(fdno) segfault.
---- rpm-4.5/lib/depends.c~     2008/10/26 18:29:50     1.327.2.10
-+++ rpm-4.5/lib/depends.c      2008-10-27 14:42:52.984295775 +0200
-@@ -1936,7 +1936,7 @@
-       return 0;
-     /* Avoid certain dependency relations. */
--    if (teType == TR_ADDED && ignoreDep(ts, p, q))
-+    if (ignoreDep(ts, p, q))
-       return 0;
+--- rpm-5.4.10/lib/order.c~    2012-07-06 17:39:16.000000000 +0200
++++ rpm-5.4.10/lib/order.c     2012-09-03 23:09:03.706487979 +0200
+@@ -1631,7 +1631,7 @@
+           (void) orgrpmAddRelation(ts, al, p, requires);
+       }
  
-     /* Avoid redundant relations. */
-@@ -2191,6 +2191,25 @@
+-#ifdef        NOTYET
++#if defined(RPM_VENDOR_PLD)
+       /* Ensure that erasures follow installs during upgrades. */
+       if (rpmteType(p) == TR_REMOVED && p->flink.Pkgid && p->flink.Pkgid[0]) {
+       rpmtsi qi;
+@@ -1652,7 +1652,7 @@
        }
+       qi = rpmtsiFree(qi);
        }
+-#endif        /* NOTYET */
++#endif
  
-+
-+      /* Ensure that erasures follow installs during upgrades. */
-+      if (rpmteType(p) == TR_REMOVED && p->flink.Pkgid && p->flink.Pkgid[0]) {
-+
-+      qi = rpmtsiInit(ts);
-+      while ((q = rpmtsiNext(qi, TR_ADDED)) != NULL) {
-+          if (strcmp(q->pkgid, p->flink.Pkgid[0]))
-+              continue;
-+          requires = rpmdsFromPRCO(q->PRCO, RPMTAG_NAME);
-+          if (requires != NULL) {
-+              /* XXX disable erased arrow reversal. */
-+              p->type = TR_ADDED;
-+              (void) addRelation(ts, p, selected, requires);
-+              p->type = TR_REMOVED;
-+          }
-+      }
-+      qi = rpmtsiFree(qi);
-+      }
-+
-       if (_autobits != 0xffffffff)
-       {
-@@ -2401,7 +2420,7 @@
+ #ifdef        NOTYET
+       /* Order by requiring parent directories as prerequisites. */
+@@ -2175,7 +2175,7 @@
                const char * dp;
-               char buf[4096];
-               int msglvl = (anaconda || (rpmtsDFlags(ts) & RPMDEPS_FLAG_DEPLOOPS))
--                      ? RPMMESS_WARNING : RPMMESS_DEBUG;
-+                      ? RPMMESS_WARNING : RPMMESS_ERROR;
- ;
-               /* Unchain predecessor loop. */
+               rpmlogLvl msglvl = (anaconda || (rpmtsDFlags(ts) & RPMDEPS_FLAG_DEPLOOPS))
+                       ? RPMLOG_WARNING : RPMLOG_ERR;
+-#if defined(RPM_VENDOR_MANDRIVA) /* loop-detection-optional-loglevel */
++#if defined(RPM_VENDOR_MANDRIVA) || defined(RPM_VENDOR_PLD) /* loop-detection-optional-loglevel */
+               // Report loops as debug-level message by default (7 = RPMLOG_DEBUG), overridable
+               msglvl = rpmExpandNumeric("%{?_loop_detection_loglevel}%{?!_loop_detection_loglevel:7}");
+ #endif
index 29fcc32986867cdd270d732bec0fa3d761ecc760..f0184271d4c92bc7c659e87c985c7ac71cca368d 100644 (file)
@@ -1,11 +1,9 @@
---- rpm-4.5/lib/rpmfc.c.org    2012-02-29 16:32:05.655058968 +0100
-+++ rpm-4.5/lib/rpmfc.c        2012-02-29 16:36:22.430972834 +0100
-@@ -1114,9 +1114,31 @@
-           /* XXX skip all files in /dev/ which are (or should be) %dev dummies. */
-           else if (slen >= fc->brlen+sizeof("/dev/") && !strncmp(s+fc->brlen, "/dev/", sizeof("/dev/")-1))
-               ftype = "";
--          else
-+          else {
+--- rpm-4.5/rpmio/rpmmg.c.org  2012-02-29 16:32:05.655058968 +0100
++++ rpm-4.5/rpmio/rpmmg.c      2012-02-29 16:36:22.430972834 +0100
+@@ -1114,7 +1114,28 @@
+           /*@fallthrough@*/
+       case URL_IS_UNKNOWN:
+       default:
 +              char *old_ctype = setlocale(LC_CTYPE, NULL);
 +              char *old_collate = setlocale(LC_COLLATE, NULL);
 +
@@ -18,8 +16,8 @@
 +                      setlocale(LC_COLLATE, "C");
 +              }
 +
-               ftype = magic_file(ms, s);
+           t = magic_file(mg->ms, fn);
++
 +              if (old_ctype) {
 +                      setlocale(LC_CTYPE, old_ctype);
 +                      _free(old_ctype);
@@ -28,8 +26,6 @@
 +                      setlocale(LC_COLLATE, old_collate);
 +                      _free(old_collate);
 +              }
-+          }
-+
-           if (ftype == NULL) {
-               xx = RPMERR_EXEC;
-               rpmError(xx, _("magic_file(ms, \"%s\") failed: mode %06o %s\n"),
+           /* XXX HACK: libmagic compiled without <pcreposix.h> spews here. */
+           if (t == NULL) {
+               const char * msg = magic_error(mg->ms);
index d7f271b63f495ce3f23df36daa60c2cbb16a1f8a..32a9f26914596cf00c4ce2a49d589060c3bf1300 100644 (file)
@@ -24,8 +24,8 @@ as for example uninstalling this spec: https://bugs.pld-linux.org/attachment.cgi
  
      /* Evaluate access(2) probe dependencies. */
      if (NSType == RPMNS_TYPE_ACCESS) {
---- rpm-4.4.9/lib/rpmns.c~     2007-05-16 14:31:58.000000000 +0300
-+++ rpm-4.4.9/lib/rpmns.c      2008-04-25 15:36:20.223855745 +0300
+--- rpm-4.4.9/lib/order.c~     2007-05-16 14:31:58.000000000 +0300
++++ rpm-4.4.9/lib/order.c      2008-04-25 15:36:20.223855745 +0300
 @@ -179,8 +179,10 @@
      case RPMNS_TYPE_UNAME:
      case RPMNS_TYPE_SONAME:
index 12a64064a2e2c2a0e87226f8e8ca4ce4f2cf357d..e02ab7cd9689217a513ad4e086ae91d34645af6c 100644 (file)
@@ -4,7 +4,7 @@
            psm->countCorrection = -1;
  
            if (!(rpmtsFlags(ts) & RPMTRANS_FLAG_NOPOSTUN)) {
--              rc = rpmpsmNext(psm, PSM_SCRIPT);
+-              rc = (rpmRC) rpmpsmNext(psm, PSM_SCRIPT);
 -              if (rc) break;
 +              if (rpmpsmNext(psm, PSM_SCRIPT))
 +                  rpmMessage(RPMMESS_VERBOSE, _("Ignoring failed %%postun scriptlet\n"));
This page took 0.057785 seconds and 4 git commands to generate.