makechrootpkg - understand makepkg source syntax

The source line in a PKGBUILD can have a structure like
source=(´filename::url´).

Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
Allan McRae 2009-01-31 20:26:45 +10:00
parent 9dd60741bd
commit c67729af98
1 changed files with 1 additions and 1 deletions

View File

@ -172,7 +172,7 @@ chown -R nobody "$uniondir/pkgdest"
source PKGBUILD
cp PKGBUILD "$uniondir/build/"
for f in ${source[@]}; do
basef=$(basename $f)
basef=$(echo $f | sed 's|::.*||' | sed 's|^.*://.*/||g')
if [ -f "$basef" ]; then
cp "$basef" "$uniondir/srcdest/"
fi