From e0f4e5a5751df6db569efdffe250258f26bfac70 Mon Sep 17 00:00:00 2001 From: hugel <2712504175@qq.com> Date: Mon, 22 Sep 2025 14:25:29 +0800 Subject: [PATCH] revert Make brp-strip-comment-note multi process (cherry picked from commit df8b6b250f92c74cca6fd461d0e7fd99a66f6f5a) --- ...brp-strip-comment-note-multi-process.patch | 35 +++++++++++++++++++ rpm.spec | 6 +++- 2 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 backport-revert-Make-brp-strip-comment-note-multi-process.patch diff --git a/backport-revert-Make-brp-strip-comment-note-multi-process.patch b/backport-revert-Make-brp-strip-comment-note-multi-process.patch new file mode 100644 index 0000000..73a6ca6 --- /dev/null +++ b/backport-revert-Make-brp-strip-comment-note-multi-process.patch @@ -0,0 +1,35 @@ +From 16ccdb704b8604e56f0809e6ae5f8790f8a3acdc Mon Sep 17 00:00:00 2001 +From: Florian Festi +Date: Wed, 15 Sep 2021 14:54:40 +0200 +Subject: [PATCH] Make brp-strip-comment-note multi process + +Run at least the file classification in parallel + +Resolves: #1230 +--- + scripts/brp-strip-comment-note | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git a/scripts/brp-strip-comment-note b/scripts/brp-strip-comment-note +index a90be71090..baf8537f3d 100755 +--- a/scripts/brp-strip-comment-note ++++ b/scripts/brp-strip-comment-note +@@ -6,7 +6,6 @@ fi + + STRIP=${1:-strip} + OBJDUMP=${2:-objdump} +-NCPUS=${RPM_BUILD_NCPUS:-1} + + case `uname -a` in + Darwin*) exit 0 ;; +@@ -15,7 +14,9 @@ esac + + # Strip .comment and .note sections (the latter only if it is not allocated) + # for already stripped elf files in the build root +-for f in `find "$RPM_BUILD_ROOT" -type f \( -perm -0100 -or -perm -0010 -or -perm -0001 \) -print0 | xargs -0 -r -P$NCPUS -n32 sh -c "file \"\\$@\" | grep -v \"^${RPM_BUILD_ROOT}/\?usr/lib/debug\" | sed -n -e 's/^\(.*\):[ ]*ELF.*, stripped.*/\1/p'" ARG0`; do ++for f in `find "$RPM_BUILD_ROOT" -type f \( -perm -0100 -or -perm -0010 -or -perm -0001 \) -exec file {} \; | \ ++ grep -v "^${RPM_BUILD_ROOT}/\?usr/lib/debug" | \ ++ sed -n -e 's/^\(.*\):[ ]*ELF.*, stripped.*/\1/p'`; do + note="-R .note" + if $OBJDUMP -h $f | grep '^[ ]*[0-9]*[ ]*.note[ ]' -A 1 | \ + grep ALLOC >/dev/null; then diff --git a/rpm.spec b/rpm.spec index 133f549..dd65fb6 100644 --- a/rpm.spec +++ b/rpm.spec @@ -1,6 +1,6 @@ Name: rpm Version: 4.18.2 -Release: 28 +Release: 29 Summary: RPM Package Manager License: GPL-2.0-or-later URL: https://rpm.org/ @@ -70,6 +70,7 @@ Patch6047: backport-Return-1-from-fdSize-for-non-regular-files.patch Patch6048: backport-Check-RPATH-and-RUNPATH-separately-in-check-rpaths.patch Patch6049: backport-Avoid-Python-reference-leaks.patch Patch6050: backport-Ensure-header-object-is-cleaned-even-in-case-of-an-e.patch +Patch6051: backport-revert-Make-brp-strip-comment-note-multi-process.patch Patch9000: Add-digest-list-plugin.patch Patch9001: Add-IMA-digest-list-support.patch @@ -359,6 +360,9 @@ make clean %exclude %{_mandir}/man8/rpmspec.8* %changelog +* Mon Sep 22 2025 hugel - 4.18.2-29 +- revert Make brp-strip-comment-note multi process + * Thu Aug 14 2025 fuanan - 4.18.2-28 - sync patches from upstream -- Gitee