public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Panu Matilainen <pmatilai@redhat.com>
To: git-commits@fedoraproject.org
Subject: [rpms/rpm] pmatilai-v6: - Resurrect payload and tilde rpmlib() dependencies
Date: Mon, 23 Nov 2026 09:29:09 GMT	[thread overview]
Message-ID: <179542614929.1.8180512713387320961.rpms-rpm-5ce01ef30331@fedoraproject.org> (raw)

A new commit has been pushed.

Repo   : rpms/rpm
Branch : pmatilai-v6
Commit : 5ce01ef3033116c05063d3cffcdeaa5a0372f780
Author : Panu Matilainen <pmatilai@redhat.com>
Date   : 2014-09-09T13:16:01+03:00
Stats  : +73/-1 in 2 file(s)
URL    : https://src.fedoraproject.org/rpms/rpm/c/5ce01ef3033116c05063d3cffcdeaa5a0372f780?branch=pmatilai-v6

Log:
- Resurrect payload and tilde rpmlib() dependencies

---
diff --git a/rpm-4.12.0-rc1-rpmlibdep.patch b/rpm-4.12.0-rc1-rpmlibdep.patch
new file mode 100644
index 0000000..5720c92
--- /dev/null
+++ b/rpm-4.12.0-rc1-rpmlibdep.patch
@@ -0,0 +1,68 @@
+commit cac311c2ddb43b62ad9dbdb5543d50848eb9fd65
+Author: Panu Matilainen <pmatilai@redhat.com>
+Date:   Tue Sep 9 12:58:08 2014 +0300
+
+    Regression the 13th: The Final Friday
+    
+    - Yet another regression from the recent dependency refactoring and
+      ensuing patches-on-patches-on-patches work: some rpmlib() dependencies
+      (payload, tilde) are added as late as writeRPM(), those have been going
+      to /dev/null recently.
+    - The fix actually removing code is probably a good sign...
+
+diff --git a/build/pack.c b/build/pack.c
+index d25449f..74471d9 100644
+--- a/build/pack.c
++++ b/build/pack.c
+@@ -438,6 +438,17 @@ static rpmRC writeRPM(Package pkg, unsigned char ** pkgidp,
+     if (haveTildeDep(pkg->header))
+ 	(void) rpmlibNeedsFeature(pkg, "TildeInVersions", "4.10.0-1");
+ 
++    /* All dependencies added finally, write them into the header */
++    for (int i = 0; i < PACKAGE_NUM_DEPS; i++) {
++	/* Nuke any previously added dependencies from the header */
++	headerDel(pkg->header, rpmdsTagN(pkg->dependencies[i]));
++	headerDel(pkg->header, rpmdsTagEVR(pkg->dependencies[i]));
++	headerDel(pkg->header, rpmdsTagF(pkg->dependencies[i]));
++	headerDel(pkg->header, rpmdsTagTi(pkg->dependencies[i]));
++	/* ...and add again, now with automatic dependencies included */
++	rpmdsPutToHeader(pkg->dependencies[i], pkg->header);
++    }
++
+     /* Create and add the cookie */
+     if (cookie) {
+ 	rasprintf(cookie, "%s %d", buildHost(), (int) (*getBuildTime()));
+@@ -623,16 +634,6 @@ rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating)
+ 	headerPutString(pkg->header, RPMTAG_BUILDHOST, buildHost());
+ 	headerPutUint32(pkg->header, RPMTAG_BUILDTIME, getBuildTime(), 1);
+ 
+-	for (int i=0; i<PACKAGE_NUM_DEPS; i++) {
+-	    /* Nuke any previously added dependencies from the header */
+-	    headerDel(pkg->header, rpmdsTagN(pkg->dependencies[i]));
+-	    headerDel(pkg->header, rpmdsTagEVR(pkg->dependencies[i]));
+-	    headerDel(pkg->header, rpmdsTagF(pkg->dependencies[i]));
+-	    headerDel(pkg->header, rpmdsTagTi(pkg->dependencies[i]));
+-	    /* ...and add again, now with automatic dependencies included */
+-	    rpmdsPutToHeader(pkg->dependencies[i], pkg->header);
+-	}
+-
+ 	if (spec->sourcePkgId != NULL) {
+ 	    headerPutBin(pkg->header, RPMTAG_SOURCEPKGID, spec->sourcePkgId,16);
+ 	}
+@@ -714,16 +715,6 @@ rpmRC packageSources(rpmSpec spec, char **cookie)
+     headerPutString(sourcePkg->header, RPMTAG_BUILDHOST, buildHost());
+     headerPutUint32(sourcePkg->header, RPMTAG_BUILDTIME, getBuildTime(), 1);
+ 
+-    for (int i=0; i<PACKAGE_NUM_DEPS; i++) {
+-	/* Nuke any previously added dependencies from the header */
+-	headerDel(sourcePkg->header, rpmdsTagN(sourcePkg->dependencies[i]));
+-	headerDel(sourcePkg->header, rpmdsTagEVR(sourcePkg->dependencies[i]));
+-	headerDel(sourcePkg->header, rpmdsTagF(sourcePkg->dependencies[i]));
+-	headerDel(sourcePkg->header, rpmdsTagTi(sourcePkg->dependencies[i]));
+-	/* ...and add again, now with automatic dependencies included */
+-	rpmdsPutToHeader(sourcePkg->dependencies[i], sourcePkg->header);
+-    }
+-
+     /* XXX this should be %_srpmdir */
+     {	char *fn = rpmGetPath("%{_srcrpmdir}/", spec->sourceRpmName,NULL);
+ 	char *pkgcheck = rpmExpand("%{?_build_pkgcheck_srpm} ", fn, NULL);

diff --git a/rpm.spec b/rpm.spec
index 272f8a6..881099d 100644
--- a/rpm.spec
+++ b/rpm.spec
@@ -27,7 +27,7 @@
 Summary: The RPM package management system
 Name: rpm
 Version: %{rpmver}
-Release: %{?snapver:0.%{snapver}.}1%{?dist}
+Release: %{?snapver:0.%{snapver}.}2%{?dist}
 Group: System Environment/Base
 Url: http://www.rpm.org/
 Source0: http://rpm.org/releases/testing/%{name}-%{srcver}.tar.bz2
@@ -48,6 +48,7 @@ Patch3: rpm-4.9.90-no-man-dirs.patch
 Patch4: rpm-4.8.1-use-gpg2.patch
 
 # Patches already upstream:
+Patch100: rpm-4.12.0-rc1-rpmlibdep.patch
 
 # These are not yet upstream
 Patch302: rpm-4.7.1-geode-i686.patch
@@ -526,6 +527,9 @@ exit 0
 %doc doc/librpm/html/*
 
 %changelog
+* Tue Sep 02 2014 Panu Matilainen <pmatilai@redhat.com> - 4.12.0-0.rc1.2
+- Resurrect payload and tilde rpmlib() dependencies
+
 * Wed Aug 27 2014 Panu Matilainen <pmatilai@redhat.com> - 4.12.0-0.rc1.1
 - Update to rpm-4.12.0-rc1
 

                 reply	other threads:[~2026-11-23  9:29 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=179542614929.1.8180512713387320961.rpms-rpm-5ce01ef30331@fedoraproject.org \
    --to=pmatilai@redhat.com \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox