diff options
author | Nicolás Reynolds <apoyosis@correo.inta.gob.ar> | 2011-12-22 23:27:13 -0300 |
---|---|---|
committer | Nicolás Reynolds <apoyosis@correo.inta.gob.ar> | 2011-12-22 23:27:13 -0300 |
commit | f258090c62535b9e02450494507f2e3f08024c96 (patch) | |
tree | 87619cda3ef8da6d9d1bc0bc6a7792662f3423d0 | |
parent | 89f2322d7c3fc28690d06bda06b45ba7742be1c0 (diff) |
Keep base-devel installed. Mount bind to default CacheDir on chroot
-rwxr-xr-x | libremakepkg | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/libremakepkg b/libremakepkg index 292e4b5..5a04b4b 100755 --- a/libremakepkg +++ b/libremakepkg @@ -49,15 +49,18 @@ function usage { # Display message and exit function buildenv { # Mounts *DEST from makepkg.conf msg "Building env" - for mp in SRCDEST PKGDEST SRCPKGDEST; do +# for mp in SRCDEST PKGDEST SRCPKGDEST; do # The host system directory - lmp=LOCAL${mp} +# lmp=LOCAL${mp} - msg2 "Binding ${!lmp} to ${CHROOTDIR}/${CHROOT}${!mp}" +# msg2 "Binding ${!lmp} to ${CHROOTDIR}/${CHROOT}${!mp}" - mkdir -p "${CHROOTDIR}/${CHROOT}${!mp}" - mount -o bind ${!lmp} "${CHROOTDIR}/${CHROOT}${!mp}" || exit 1 - done +# mkdir -p "${CHROOTDIR}/${CHROOT}${!mp}" +# mount -o bind ${!lmp} "${CHROOTDIR}/${CHROOT}${!mp}" || exit 1 +# done + + msg2 "Bind ${CACHEDIR} => ${CHROOTDIR}/${CHROOT}/var/cache/pacman/pkg/" + mount -o bind ${CACHEDIR} ${CHROOTDIR}/${CHROOT}/var/cache/pacman/pkg/ } @@ -69,19 +72,14 @@ function clean_chroot { # Clean packages with pacman #!/bin/bash export LANG=C -clean='false' - -while [ "\$clean" = 'false' ]; do - pkgs=(\$(comm -23 <(pacman -Qq | sort) <(sort /root/cleansystem))) if [ \${#pkgs[@]} -gt 0 ]; then pacman --noconfirm -Rcs \${pkgs[@]} + pacman --noconfirm -S --needed base-devel gettext else - clean="true" echo "clean" fi -done EOF ) > "${CHROOTDIR}/${CHROOTNAME}/clean" chmod +x "${CHROOTDIR}/${CHROOTNAME}/clean" |