summaryrefslogtreecommitdiffstats
path: root/makechrootpkg.in
diff options
context:
space:
mode:
authorPierre Schmitz <pierre@archlinux.de>2011-10-31 12:43:16 +0100
committerPierre Schmitz <pierre@archlinux.de>2011-10-31 12:43:16 +0100
commita06ac2451a73744f6e4bb2b895719d2c3ad588e3 (patch)
treeebbae6111da7ef228ae53d04788078d5aaf49098 /makechrootpkg.in
parentfbdcf6e309754eef590e926c139cf4fc375c492f (diff)
downloaddevtools-a06ac2451a73744f6e4bb2b895719d2c3ad588e3.tar.gz
devtools-a06ac2451a73744f6e4bb2b895719d2c3ad588e3.tar.xz
makechrootpkg: Handle install and changelog file the same way as in commitpkg
Diffstat (limited to 'makechrootpkg.in')
-rw-r--r--makechrootpkg.in8
1 files changed, 4 insertions, 4 deletions
diff --git a/makechrootpkg.in b/makechrootpkg.in
index ba893bf..b172bdf 100644
--- a/makechrootpkg.in
+++ b/makechrootpkg.in
@@ -243,12 +243,12 @@ cp PKGBUILD "$copydir/build/"
done
# Find all changelog and install files, even inside functions
- for i in changelog install; do
- sed -n "s/^[[:space:]]*$i=//p" PKGBUILD | while IFS= read -r file; do
+ for i in 'changelog' 'install'; do
+ while read -r file; do
# evaluate any bash variables used
- eval file="$file"
+ eval file=\"$(sed 's/^\(['\''"]\)\(.*\)\1$/\2/' <<< "$file")\"
[[ -f $file ]] && cp "$file" "$copydir/build/"
- done
+ done < <(sed -n "s/^[[:space:]]*$i=//p" PKGBUILD)
done
)