commit 28d5147bea00592740b6247568769528a2cbcb35
Author: Jakub Bogusz <[email protected]>
Date:   Sat Mar 4 10:21:35 2017 +0100

    - added headerChecks patch (adjust one sanity check which refused some of 
installed packages)
    - added rpm4compat-update patch (fix rpm4compat.h wrt. rpmio.h changes)

 rpm-headerChecks.patch      | 22 ++++++++++++++++++++++
 rpm-rpm4compat-update.patch | 17 +++++++++++++++++
 rpm.spec                    | 10 +++++-----
 3 files changed, 44 insertions(+), 5 deletions(-)
---
diff --git a/rpm.spec b/rpm.spec
index 092fcc2..c2ba143 100644
--- a/rpm.spec
+++ b/rpm.spec
@@ -58,7 +58,7 @@ Summary(ru.UTF-8):    Менеджер пакетов от RPM
 Summary(uk.UTF-8):     Менеджер пакетів від RPM
 Name:          rpm
 Version:       5.4.17
-Release:       0.8
+Release:       0.9
 License:       LGPL v2.1
 Group:         Base
 # http://rpm5.org/files/rpm/rpm-5.4/rpm-5.4.17-0.20160512.src.rpm
@@ -156,7 +156,7 @@ Patch53:    %{name}-lua-enable-extra-libs.patch
 Patch54:       %{name}-fix-filedigests-verify.patch
 Patch55:       %{name}-disable-hmac-verify.patch
 Patch56:       %{name}-macros.patch
-
+Patch57:       %{name}-headerChecks.patch
 Patch58:       %{name}-preserve-iterator.patch
 Patch60:       %{name}-python-sitescriptdir.patch
 Patch61:       %{name}-clean-docdir.patch
@@ -164,7 +164,7 @@ Patch62:    %{name}-DB_CONFIG.patch
 Patch63:       %{name}-pythoneggs.patch
 Patch64:       %{name}-fix-compress-doc.patch
 Patch65:       %{name}-parseSpec-skip-empty-tags.patch
-
+Patch66:       %{name}-rpm4compat-update.patch
 Patch67:       %{name}-repackage-dont-force-max-compression.patch
 Patch70:       python-%{name}sense-missingok.patch
 Patch71:       %{name}-changelog-encoding.patch
@@ -939,7 +939,7 @@ cd -
 %patch54 -p1
 %patch55 -p1
 %patch56 -p1
-
+%patch57 -p1
 %patch58 -p1
 %patch60 -p1
 %patch61 -p1
@@ -947,7 +947,7 @@ cd -
 %patch63 -p1
 %patch64 -p1
 %patch65 -p1
-
+%patch66 -p1
 %patch67 -p1
 %patch70 -p1
 %patch71 -p1
diff --git a/rpm-headerChecks.patch b/rpm-headerChecks.patch
new file mode 100644
index 0000000..4d3ddb6
--- /dev/null
+++ b/rpm-headerChecks.patch
@@ -0,0 +1,22 @@
+--- rpm-5.4.17/rpmdb/header.c.orig     2017-02-25 09:37:52.627550403 +0100
++++ rpm-5.4.17/rpmdb/header.c  2017-03-02 21:12:16.348808677 +0100
+@@ -998,14 +998,15 @@
+           if (off < 0)
+               goto errxit;
+           if (off) {
++                rpmuint32_t * stei;
+               size_t nb = REGION_TAG_COUNT;
+-              /* XXX copy to fix alignment problems */
+-                rpmuint32_t * stei = (rpmuint32_t *)
+-                          memcpy(alloca(nb), dataStart + off, nb);
+               if ((off + nb) > dl)
+                   goto errxit;
++              /* XXX copy to fix alignment problems */
++                stei = (rpmuint32_t *)
++                          memcpy(alloca(nb), dataStart + off, nb);
+               rdl = (rpmuint32_t)-ntohl(stei[2]);     /* negative offset */
+-              if (rdl < REGION_TAG_COUNT || rdl > (rpmuint32_t)(off+nb))
++              if (rdl < REGION_TAG_COUNT || rdl > (rpmuint32_t)(il * 
REGION_TAG_COUNT))
+                   goto errxit;
+               ril = (rpmuint32_t)(rdl/sizeof(*pe));
+           } else {
diff --git a/rpm-rpm4compat-update.patch b/rpm-rpm4compat-update.patch
new file mode 100644
index 0000000..c49b564
--- /dev/null
+++ b/rpm-rpm4compat-update.patch
@@ -0,0 +1,17 @@
+fdSize is now extern function, declared in <rpmio.h>.
+--- rpm-5.4.17/lib/rpm4compat.h.orig   2017-03-02 21:47:58.792117545 +0100
++++ rpm-5.4.17/lib/rpm4compat.h        2017-03-04 09:14:59.103993683 +0100
+@@ -352,13 +352,6 @@
+       return rpmProblemGetDiskNeed(prob);
+ }
+ 
+-static inline off_t fdSize(FD_t fd){
+-      struct stat sb;
+-      Fstat(fd, &sb);
+-      return sb.st_size;
+-}
+-
+-
+ static inline unsigned int rpmdbGetIteratorOffset(rpmdbMatchIterator mi) {
+     return rpmmiInstance(mi);
+ }
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/rpm.git/commitdiff/28d5147bea00592740b6247568769528a2cbcb35

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to