Set target CARCH before sourcing the PKGBUILD

CARCH might be used within the PKGBUILD to select correct sources
This commit is contained in:
Pierre Schmitz 2010-05-02 15:23:54 +02:00
parent 52e140f2fe
commit 4a4455c086
1 changed files with 2 additions and 0 deletions

View File

@ -147,6 +147,8 @@ if ! grep 'SRCDEST=/srcdest' "$copydir/etc/makepkg.conf" >/dev/null 2>&1; then
echo 'SRCDEST=/srcdest' >> "$copydir/etc/makepkg.conf"
fi
# Set target CARCH as it might be used within the PKGBUILD to select correct sources
CARCH=$(eval $(grep '^CARCH=' "$copydir/etc/makepkg.conf"))
# Copy PKGBUILD and sources
source PKGBUILD
cp PKGBUILD "$copydir/build/"