mirror of
https://github.com/moparisthebest/pacman
synced 2025-03-01 01:41:52 -05:00
makepkg: fix strip section to allow spaces in paths
Inside tidy_install, change the section which strips libraries to use find | while read rather than for foo in `find`. This should allow whitespaces in filenames to still be processed correctly. This fixes FS#10294. Signed-off-by: Daenyth Blank <Daenyth+git@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
This commit is contained in:
parent
c465d9e848
commit
27943a04d6
@ -751,12 +751,14 @@ tidy_install() {
|
||||
|
||||
if [ "$(check_option strip)" = "y" ]; then
|
||||
msg2 "$(gettext "Stripping debugging symbols from binaries and libraries...")"
|
||||
for file in $(find {,usr/{,local/},opt/*/}{bin,lib,sbin} -type f 2>/dev/null || true); do
|
||||
case "$(file -biz "$file")" in
|
||||
local binary bindirs
|
||||
bindirs="bin lib sbin usr/bin usr/lib usr/sbin usr/local/bin usr/local/lib usr/local/sbin opt/*/bin opt/*/lib opt/*/sbin"
|
||||
find ${bindirs} -type f 2>/dev/null | while read binary ; do
|
||||
case "$(file -biz "$binary")" in
|
||||
*application/x-sharedlib*) # Libraries
|
||||
/usr/bin/strip --strip-debug "$file";;
|
||||
/usr/bin/strip --strip-debug "$binary";;
|
||||
*application/x-executable*) # Binaries
|
||||
/usr/bin/strip "$file";;
|
||||
/usr/bin/strip "$binary";;
|
||||
esac
|
||||
done
|
||||
fi
|
||||
|
Loading…
x
Reference in New Issue
Block a user