summaryrefslogtreecommitdiff
path: root/makechrootpkg.in
diff options
context:
space:
mode:
Diffstat (limited to 'makechrootpkg.in')
-rw-r--r--makechrootpkg.in11
1 files changed, 4 insertions, 7 deletions
diff --git a/makechrootpkg.in b/makechrootpkg.in
index ef3f2ec..71e527d 100644
--- a/makechrootpkg.in
+++ b/makechrootpkg.in
@@ -209,6 +209,7 @@ prepare_chroot() {
[[ -r $USER_HOME/$x ]] || continue
$install -m 644 "$USER_HOME/$x" "$copydir/build/$x"
done
+ echo 'keyserver-options auto-key-retrieve' >> "$copydir/build/.gnupg/gpg.conf"
sed -e '/^MAKEFLAGS=/d' -e '/^PACKAGER=/d' -i "$copydir/etc/makepkg.conf"
for x in BUILDDIR=/build PKGDEST=/pkgdest SRCPKGDEST=/srcpkgdest SRCDEST=/srcdest LOGDEST=/logdest \
@@ -266,17 +267,13 @@ download_sources() {
local copydir=$1
local makepkg_user=$2
- local builddir
- builddir="$(mktemp -d)"
- chmod 1777 "$builddir"
+ setup_workdir
+ chown "$makepkg_user" "$WORKDIR"
# Ensure sources are downloaded
- sudo -u "$makepkg_user" env SRCDEST="$SRCDEST" BUILDDIR="$builddir" \
+ sudo -u "$makepkg_user" env SRCDEST="$SRCDEST" BUILDDIR="$WORKDIR" \
makepkg --config="$copydir/etc/makepkg.conf" --verifysource -o ||
die "Could not download sources."
-
- # Clean up garbage from verifysource
- rm -rf "$builddir"
}
# Usage: move_products $copydir $owner