From 31fa4d3f40673c869e05a3ef4b2d918ed4357df1 Mon Sep 17 00:00:00 2001 From: Dennis ten Hoove Date: Thu, 29 Feb 2024 20:32:40 +0100 Subject: [PATCH] Mount local pacman cache to workdir --- arkdep-build | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/arkdep-build b/arkdep-build index 44372f4..2324a62 100755 --- a/arkdep-build +++ b/arkdep-build @@ -206,8 +206,16 @@ if [[ $type == 'archlinux' ]]; then # Read package list and install secondary system components, skip if not used if [[ -e $variantdir/package.list ]]; then printf '\e[1;34m-->\e[0m\e[1m Installing secondary packages\e[0m\n' + + # Mount the pacman cache + mount --bind /var/cache/pacman/pkg $workdir/var/cache/pacman/pkg + + # Read package list and install readarray packages < $variantdir/package.list arch-chroot $workdir pacman -S --noconfirm ${packages[*]} || cleanup_and_quit 'Failed to install base packages' + + # Unmount pacman cache + umount $workdir/var/cache/pacman/pkg fi # Run post-install script if exists