diff --git a/backport-Remove-checks-during-parsing-of-packages.patch b/backport-Remove-checks-during-parsing-of-packages.patch deleted file mode 100644 index 01920d9a748cbb421dad1d0ddd08e4583ba1dd80..0000000000000000000000000000000000000000 --- a/backport-Remove-checks-during-parsing-of-packages.patch +++ /dev/null @@ -1,107 +0,0 @@ -From 9165963de8bb5d5ad0a24ea4656d6d04d733f6bc Mon Sep 17 00:00:00 2001 -From: Florian Festi -Date: Mon, 18 Sep 2023 17:20:20 +0200 -Subject: [PATCH] Remove checks during parsing of packages - ---- - build/parsePreamble.c | 63 +++++++++++++++++++++++++------------------ - 1 file changed, 37 insertions(+), 26 deletions(-) - -diff --git a/build/parsePreamble.c b/build/parsePreamble.c -index 306a029..154b66a 100644 ---- a/build/parsePreamble.c -+++ b/build/parsePreamble.c -@@ -48,6 +48,16 @@ static const rpmTagVal copyTagsDuringParse[] = { - 0 - }; - -+/** -+ */ -+static const rpmTagVal requiredTagsForBuild[] = { -+ RPMTAG_NAME, -+ RPMTAG_VERSION, -+ RPMTAG_RELEASE, -+ 0 -+}; -+ -+ - /** - */ - static const rpmTagVal requiredTags[] = { -@@ -498,6 +508,29 @@ static int checkForRequired(Header h, const char * NVR) - return res; - } - -+/** -+ * Check that required tags are present in header. -+ * @param h header -+ * @param NVR package name-version-release -+ * @return RPMRC_OK if OK -+ */ -+static int checkForRequiredForBuild(Header h) -+{ -+ int res = RPMRC_OK; -+ const rpmTagVal * p; -+ -+ for (p = requiredTagsForBuild; *p != 0; p++) { -+ if (!headerIsEntry(h, *p)) { -+ rpmlog(RPMLOG_ERR, -+ _("%s field must be present before build in package: %s\n"), -+ rpmTagGetName(*p), headerGetString(h, RPMTAG_NAME)); -+ res = RPMRC_FAIL; -+ } -+ } -+ -+ return res; -+} -+ - /** - * Check that no duplicate tags are present in header. - * @param h header -@@ -1218,6 +1251,10 @@ int parsePreamble(rpmSpec spec, int initialPackage) - * can't be messed with by anything spec does beyond this point. - */ - if (initialPackage) { -+ if (checkForRequiredForBuild(pkg->header)) { -+ goto exit; -+ } -+ - char *buildRoot = rpmGetPath(spec->buildRoot, NULL); - free(spec->buildRoot); - spec->buildRoot = buildRoot; -@@ -1232,32 +1269,6 @@ int parsePreamble(rpmSpec spec, int initialPackage) - } - } - -- /* XXX Skip valid arch check if not building binary package */ -- if (!(spec->flags & RPMSPEC_ANYARCH) && checkForValidArchitectures(spec)) { -- goto exit; -- } -- -- /* It is the main package */ -- if (pkg == spec->packages) { -- fillOutMainPackage(pkg->header); -- /* Define group tag to something when group is undefined in main package*/ -- if (!headerIsEntry(pkg->header, RPMTAG_GROUP)) { -- headerPutString(pkg->header, RPMTAG_GROUP, "Unspecified"); -- } -- } -- -- if (checkForDuplicates(pkg->header, NVR)) { -- goto exit; -- } -- -- if (pkg != spec->packages) { -- copyInheritedTags(pkg->header, spec->packages->header); -- } -- -- if (checkForRequired(pkg->header, NVR)) { -- goto exit; -- } -- - /* if we get down here nextPart has been set to non-error */ - res = nextPart; - --- -2.43.0 - diff --git a/rpm.spec b/rpm.spec index 2f4221b3d8c69b4057ab2f5c98c90c1fcbbf21ba..535bb12dd4b9313dc7e435a9cac3051419ab92bf 100644 --- a/rpm.spec +++ b/rpm.spec @@ -1,6 +1,6 @@ Name: rpm Version: 4.18.2 -Release: 26 +Release: 25 Summary: RPM Package Manager License: GPL-2.0-or-later URL: https://rpm.org/ @@ -67,8 +67,6 @@ Patch6044: backport-Fix-race-condition-in-rpmioMkpath.patch Patch6045: backport-Ignore-EPERM-for-root-when-setting-IMA-signature-xat.patch Patch6046: backport-Fix-a-copy-paste-help-description-of-rpmbuild-rf-and.patch Patch6047: backport-Return-1-from-fdSize-for-non-regular-files.patch -Patch6048: backport-Remove-checks-during-parsing-of-packages.patch - Patch9000: Add-digest-list-plugin.patch Patch9001: Add-IMA-digest-list-support.patch @@ -358,9 +356,6 @@ make clean %exclude %{_mandir}/man8/rpmspec.8* %changelog -* Fri Jul 18 2025 andy - 4.18.2-26 -- backport Remove checks during parsing of packages - * Wed Jul 2 2025 andy - 4.18.2-25 - sync patches form upstream