- re-add compress_doc functionality
authorJan Rękorajski <baggins@pld-linux.org>
Mon, 6 Jan 2020 09:05:10 +0000 (18:05 +0900)
committerJan Rękorajski <baggins@pld-linux.org>
Mon, 6 Jan 2020 09:05:10 +0000 (18:05 +0900)
rpm-add-compress-doc.patch [new file with mode: 0644]
rpm-fix-compress-doc.patch [deleted file]
rpm.spec

diff --git a/rpm-add-compress-doc.patch b/rpm-add-compress-doc.patch
new file mode 100644 (file)
index 0000000..8a1c680
--- /dev/null
@@ -0,0 +1,18 @@
+--- rpm-5.4.10/build/files.c~  2013-01-25 13:14:36.692060288 +0100
++++ rpm-5.4.10/build/files.c   2013-02-25 12:03:26.110910465 +0100
+@@ -2380,6 +2380,15 @@
+       appendLineStringBuf(docScript, " ||:");
+       free(efn);
+     }
++
++    {
++      char *compress_doc;
++
++      compress_doc = rpmExpand("%{__compress_doc}", NULL);
++      if (compress_doc && *compress_doc != '%')
++          appendLineStringBuf(docScript, compress_doc);
++      compress_doc = _free(compress_doc);
++    }
+     if (install) {
+       if (doScript(spec, RPMBUILD_STRINGBUF, sdname,
diff --git a/rpm-fix-compress-doc.patch b/rpm-fix-compress-doc.patch
deleted file mode 100644 (file)
index a9256d3..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
---- rpm-5.4.10/build/files.c~  2013-01-25 13:14:36.692060288 +0100
-+++ rpm-5.4.10/build/files.c   2013-02-25 12:03:26.110910465 +0100
-@@ -1041,7 +1041,6 @@
-       /* XXX FIXME: this is easy to do as macro expansion */
-           if (! fl->passedSpecialDoc) {
--              char *compress_doc;
-               char *mkdir_p;
-               pkg->specialDoc = rpmiobNew(0);
-@@ -1056,11 +1055,6 @@
-               mkdir_p = _free(mkdir_p);
-               pkg->specialDoc = rpmiobAppend(pkg->specialDoc, " \"$DOCDIR\"", 1);
--              compress_doc = rpmExpand("%{__compress_doc}", NULL);
--              if (compress_doc && *compress_doc != '%')
--                  pkg->specialDoc = rpmiobAppend(pkg->specialDoc, compress_doc, 1);
--              compress_doc = _free(compress_doc);
--
-               /*@-temptrans@*/
-               *fileName = buf;
-               /*@=temptrans@*/
-@@ -1071,6 +1065,15 @@
-           pkg->specialDoc = rpmiobAppend(pkg->specialDoc, "cp -pr ", 0);
-           pkg->specialDoc = rpmiobAppend(pkg->specialDoc, specialDocBuf, 0);
-           pkg->specialDoc = rpmiobAppend(pkg->specialDoc, " \"$DOCDIR\"", 1);
-+
-+          {
-+              char *compress_doc;
-+
-+              compress_doc = rpmExpand("%{__compress_doc}", NULL);
-+              if (compress_doc && *compress_doc != '%')
-+                  pkg->specialDoc = rpmiobAppend(pkg->specialDoc, compress_doc, 1);
-+              compress_doc = _free(compress_doc);
-+          }
-       }
-     }
index 45d0f242969fca950ff8030ba2d825105bebc2f7..742bd08f5d0763d530d02607dae532799e584421 100644 (file)
--- a/rpm.spec
+++ b/rpm.spec
@@ -79,7 +79,7 @@ Patch14:      %{name}-clean-docdir.patch
 Patch15:       %{name}-perl-magic.patch
 Patch16:       %{name}-ignore-missing-macro-files.patch
 Patch17:       x32.patch
-Patch18:       %{name}-fix-compress-doc.patch
+Patch18:       %{name}-add-compress-doc.patch
 Patch20:       rpm5-db-compat.patch
 Patch21:       python-internal-build.patch
 URL:           https://rpm.org/
@@ -594,7 +594,7 @@ Dokumentacja API RPM-a oraz przewodniki w formacie HTML generowane ze
 %patch15 -p1
 %patch16 -p1
 %patch17 -p1
-#%patch18 -p1
+%patch18 -p1
 %patch20 -p1
 %patch21 -p1
 
This page took 0.115507 seconds and 4 git commands to generate.