[Rpm-maint] [rpm-software-management/rpm] scripts/brp-strip: Rectify parallel stripping logic (PR #2161)
Shreenidhi Shedi
notifications at github.com
Mon Sep 5 17:37:52 UTC 2022
@sshedi commented on this pull request.
> +# Only operate on non-stripped binaries
+find "$RPM_BUILD_ROOT" -type f \
+ ! -regex "${RPM_BUILD_ROOT}/*usr/lib/debug.*" \
+ ! -name "*.go" -links 1 -print0 | \
+ xargs -0 -r -P${NCPUS} -n${MAX_ARGS} sh -c "file \"\$@\" | \
+ sed -n -e 's/^\(.*\):[ ]*ELF.*, not stripped.*/\1/p' | \
+ grep -v 'no machine' | \
+ xargs -I\{\} $STRIP -g \{\}" ARG0
+
+# Same as above but for files with more than 1 link
+for f in $(find "$RPM_BUILD_ROOT" -type f \
+ ! -regex "${RPM_BUILD_ROOT}/*usr/lib/debug.*" \
+ ! -name "*.go" -links +1 -exec file {} \; | \
+ sed -n -e 's/^\(.*\):[ ]*ELF.*, not stripped.*/\1/p' | \
+ grep -v 'no machine'); do
+ $STRIP -g "$f" || :
@pmatilai I have made the suggested changes, please review again.
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/2161#discussion_r963069603
You are receiving this because you are subscribed to this thread.
Message ID: <rpm-software-management/rpm/pull/2161/review/1096693097 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20220905/a5673c46/attachment.html>
More information about the Rpm-maint
mailing list