Fix rpmbuild -ba --nodeps regression wrt dynamic buildrequires (#2078744)

This commit is contained in:
Panu Matilainen 2022-04-26 16:32:29 +03:00
parent 0c48f210b1
commit f384795ec8
2 changed files with 36 additions and 1 deletions

View File

@ -0,0 +1,31 @@
From d220e0063e836ba14806c7efb2a85d1be04cd673 Mon Sep 17 00:00:00 2001
Message-Id: <d220e0063e836ba14806c7efb2a85d1be04cd673.1650979848.git.pmatilai@redhat.com>
From: Panu Matilainen <pmatilai@redhat.com>
Date: Tue, 26 Apr 2022 16:27:10 +0300
Subject: [PATCH] Fix regression on dynamic buildrequires with -ba --nodeps
(RhBug:2078744)
---
rpmbuild.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/rpmbuild.c b/rpmbuild.c
index da3810f75..377d672a7 100644
--- a/rpmbuild.c
+++ b/rpmbuild.c
@@ -673,9 +673,10 @@ int main(int argc, char *argv[])
/* fallthrough */
case 'd':
ba->buildAmount |= RPMBUILD_BUILDREQUIRES;
- ba->buildAmount |= RPMBUILD_DUMPBUILDREQUIRES;
- if (!noDeps)
+ if ((buildChar == 'd' || buildChar == 'r') || noDeps == 0) {
+ ba->buildAmount |= RPMBUILD_DUMPBUILDREQUIRES;
ba->buildAmount |= RPMBUILD_CHECKBUILDREQUIRES;
+ }
if ((buildChar == 'r' || buildChar == 'd') && shortCircuit)
break;
/* fallthrough */
--
2.35.1

View File

@ -30,7 +30,7 @@
%global rpmver 4.18.0 %global rpmver 4.18.0
%global snapver alpha1 %global snapver alpha1
%global baserelease 2 %global baserelease 3
%global sover 9 %global sover 9
%global srcver %{rpmver}%{?snapver:-%{snapver}} %global srcver %{rpmver}%{?snapver:-%{snapver}}
@ -59,6 +59,7 @@ Patch3: rpm-4.9.90-no-man-dirs.patch
Patch100: 0001-Fix-OpenPGP-key-ID-parsing-regression.patch Patch100: 0001-Fix-OpenPGP-key-ID-parsing-regression.patch
Patch101: 0001-Revert-Fix-shared-colored-files-not-removed-on-erasu.patch Patch101: 0001-Revert-Fix-shared-colored-files-not-removed-on-erasu.patch
Patch102: 0001-Fix-rpmbuild-br-not-building-.src.rpm-regression-RhB.patch Patch102: 0001-Fix-rpmbuild-br-not-building-.src.rpm-regression-RhB.patch
Patch103: 0001-Fix-regression-on-dynamic-buildrequires-with-ba-node.patch
# These are not yet upstream # These are not yet upstream
Patch906: rpm-4.7.1-geode-i686.patch Patch906: rpm-4.7.1-geode-i686.patch
@ -613,6 +614,9 @@ fi
%doc docs/librpm/html/* %doc docs/librpm/html/*
%changelog %changelog
* Tue Apr 26 2022 Panu Matilainen <pmatilai@redhat.com> - 4.18.0-0.alpha1.3
- Fix rpmbuild -ba --nodeps regression wrt dynamic buildrequires (#2078744)
* Tue Apr 26 2022 Panu Matilainen <pmatilai@redhat.com> - 4.18.0-0.alpha1.2 * Tue Apr 26 2022 Panu Matilainen <pmatilai@redhat.com> - 4.18.0-0.alpha1.2
- Fix rpmbuild -br not producing a src.rpm regression (#2078744) - Fix rpmbuild -br not producing a src.rpm regression (#2078744)