Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/scripts/libmakepkg
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/libmakepkg')
-rw-r--r--scripts/libmakepkg/tidy/staticlibs.sh.in2
-rw-r--r--scripts/libmakepkg/tidy/strip.sh.in6
-rw-r--r--scripts/libmakepkg/tidy/zipman.sh.in8
3 files changed, 8 insertions, 8 deletions
diff --git a/scripts/libmakepkg/tidy/staticlibs.sh.in b/scripts/libmakepkg/tidy/staticlibs.sh.in
index eaa6ac8a..bf7601d2 100644
--- a/scripts/libmakepkg/tidy/staticlibs.sh.in
+++ b/scripts/libmakepkg/tidy/staticlibs.sh.in
@@ -34,7 +34,7 @@ tidy_staticlibs() {
if check_option "staticlibs" "n"; then
msg2 "$(gettext "Removing static library files...")"
local l
- while read -rd '' l; do
+ while IFS= read -rd '' l; do
if [[ -f "${l%.a}.so" || -h "${l%.a}.so" ]]; then
rm "$l"
fi
diff --git a/scripts/libmakepkg/tidy/strip.sh.in b/scripts/libmakepkg/tidy/strip.sh.in
index 99bfcada..1bd810f0 100644
--- a/scripts/libmakepkg/tidy/strip.sh.in
+++ b/scripts/libmakepkg/tidy/strip.sh.in
@@ -57,7 +57,7 @@ strip_file() {
# copy source files to debug directory
local f t
- while read -r t; do
+ while IFS= read -r t; do
f=${t/${dbgsrcdir}/"$srcdir"}
mkdir -p "${dbgsrc/"$dbgsrcdir"/}${t%/*}"
cp -- "$f" "${dbgsrc/"$dbgsrcdir"/}$t"
@@ -69,7 +69,7 @@ strip_file() {
objcopy --add-gnu-debuglink="$dbgdir/${binary#/}.debug" "$binary"
# create any needed hardlinks
- while read -rd '' file ; do
+ while IFS= read -rd '' file ; do
if [[ "${binary}" -ef "${file}" && ! -f "$dbgdir/${file}.debug" ]]; then
mkdir -p "$dbgdir/${file%/*}"
ln "$dbgdir/${binary}.debug" "$dbgdir/${file}.debug"
@@ -110,7 +110,7 @@ tidy_strip() {
fi
local binary strip_flags
- find . -type f -perm -u+w -print0 2>/dev/null | while read -rd '' binary ; do
+ find . -type f -perm -u+w -print0 2>/dev/null | while IFS= read -rd '' binary ; do
case "$(file -bi "$binary")" in
*application/x-sharedlib*) # Libraries (.so)
strip_flags="$STRIP_SHARED";;
diff --git a/scripts/libmakepkg/tidy/zipman.sh.in b/scripts/libmakepkg/tidy/zipman.sh.in
index 3c2e261e..ba2f006c 100644
--- a/scripts/libmakepkg/tidy/zipman.sh.in
+++ b/scripts/libmakepkg/tidy/zipman.sh.in
@@ -35,9 +35,9 @@ tidy_zipman() {
msg2 "$(gettext "Compressing man and info pages...")"
local file files inode link
while read -rd ' ' inode; do
- read file
- find ${MAN_DIRS[@]} -type l 2>/dev/null |
- while read -r link ; do
+ IFS= read -r file
+ find "${MAN_DIRS[@]}" -type l -print0 2>/dev/null |
+ while IFS= read -rd '' link ; do
if [[ "${file}" -ef "${link}" ]] ; then
rm -f "$link" "${link}.gz"
if [[ ${file%/*} = "${link%/*}" ]]; then
@@ -55,7 +55,7 @@ tidy_zipman() {
ln "${files[$inode]}.gz" "${file}.gz"
chmod 644 "${file}.gz"
fi
- done < <(find ${MAN_DIRS[@]} -type f \! -name "*.gz" \! -name "*.bz2" \
+ done < <(find "${MAN_DIRS[@]}" -type f \! -name "*.gz" \! -name "*.bz2" \
-exec @INODECMD@ '{}' + 2>/dev/null)
fi
}