From 69335b6ff0342a2d3201158b9a18010c57cbcf26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joshua=20Ismael=20Haase=20Hern=C3=A1ndez?= Date: Sun, 26 Jun 2011 18:07:53 -0500 Subject: libremakepkg cleans better rePKGBUILD.proto finds links and delete them --- libremakepkg | 42 +++++++++++++++++++++++++++--------------- 1 file changed, 27 insertions(+), 15 deletions(-) (limited to 'libremakepkg') diff --git a/libremakepkg b/libremakepkg index babed47..e446833 100755 --- a/libremakepkg +++ b/libremakepkg @@ -51,6 +51,32 @@ function buildenv { done } +# Clean packages with pacman +function clean_chroot { + plain "making list of packages in ${CHROOTDIR}/${CHROOTNAME}/root/" + cp "/etc/libretools.d/cleansystem" "${CHROOTDIR}/${CHROOTNAME}/root/cleansystem" + (cat < "${CHROOTDIR}/${CHROOTNAME}/clean" + mkarchroot -r "/clean" "${CHROOTDIR}/${CHROOTNAME}" +} + # End inmediately but print a useful message trap_exit() { @@ -120,21 +146,7 @@ fi if [ "${CLEAN_FIRST}" = y ]; then msg "Cleaning" - plain "making list of packages in ${CHROOTDIR}/${CHROOTNAME}/root/" - cp "/etc/libretools.d/cleansystem" "${CHROOTDIR}/${CHROOTNAME}/root/cleansystem" - (cat < "${CHROOTDIR}/${CHROOTNAME}/clean" - echo -n "doing cleanup..." - mkarchroot -r "/clean" "${CHROOTDIR}/${CHROOTNAME}" - + clean_chroot fi msg "Creating the package" -- cgit v1.2.3-2-g168b