Check for existing files when copying to chroot
Use basename when checking for files in the source array This allows us to actually check for pre-downloaded remote files and copy them to the build root as well. Original-work-by: Jaroslaw Swierczynski <swiergot@juvepoland.com> Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
This commit is contained in:
parent
a0ccba5622
commit
484d36e931
|
@ -151,8 +151,9 @@ chown -R nobody "$uniondir/build"
|
||||||
source PKGBUILD
|
source PKGBUILD
|
||||||
cp PKGBUILD "$uniondir/build/"
|
cp PKGBUILD "$uniondir/build/"
|
||||||
for f in ${source[@]}; do
|
for f in ${source[@]}; do
|
||||||
if [ -f "$f" ]; then
|
basef=$(basename $f)
|
||||||
cp "$f" "$uniondir/build/"
|
if [ -f "$basef" ]; then
|
||||||
|
cp "$basef" "$uniondir/build/"
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
if [ "$install" != "" -a -f "$install" ]; then
|
if [ "$install" != "" -a -f "$install" ]; then
|
||||||
|
|
Loading…
Reference in New Issue