Skip to content
Browse files

makechrootpkg: Handle install and changelog file the same way as in c…

…ommitpkg
  • Loading branch information...
1 parent fbdcf6e commit a06ac2451a73744f6e4bb2b895719d2c3ad588e3 @pierres pierres committed Oct 31, 2011
Showing with 4 additions and 4 deletions.
  1. +4 −4 makechrootpkg.in
View
8 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
)

0 comments on commit a06ac24

Please sign in to comment.
Something went wrong with that request. Please try again.