diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2011-10-31 12:43:16 +0100 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2011-10-31 12:43:16 +0100 |
commit | a06ac2451a73744f6e4bb2b895719d2c3ad588e3 (patch) | |
tree | ebbae6111da7ef228ae53d04788078d5aaf49098 | |
parent | fbdcf6e309754eef590e926c139cf4fc375c492f (diff) | |
download | devtools-a06ac2451a73744f6e4bb2b895719d2c3ad588e3.tar.xz |
makechrootpkg: Handle install and changelog file the same way as in commitpkg
-rw-r--r-- | makechrootpkg.in | 8 |
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 ) |