From 691baba22e7fb1fe47005558ca92e540566fe383 Mon Sep 17 00:00:00 2001 From: Joshua Ismael Haase Hernandez Date: Fri, 25 Mar 2011 07:09:23 -0700 Subject: Added libremessages and format in scripts --- libremakepkg | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'libremakepkg') diff --git a/libremakepkg b/libremakepkg index cf3f13f..78ebefb 100755 --- a/libremakepkg +++ b/libremakepkg @@ -18,24 +18,34 @@ # You should have received a copy of the GNU General Public License # along with Parabola. If not, see . +source /etc/libretools.conf + if [ $UID -ne 0 ]; then - echo "This script must be run as root" + error "This script must be run as root" exit 1 fi -source /etc/libretools.conf +msg "Checking PKGBUILD for non-free issues" +pkgbuild-check-nonfree ||{ + if [[$?=15]]; then + error "PKGBUILD contains non-free issues" + exit 15 + else + error "Check failed, continuing" + fi +} [[ -z $1 ]] && { CLEAN="-c" - echo "Updating the main chroot" + msg "Updating the main chroot" mount -o bind ${CACHEDIR} ${CHROOTDIR}/${CHROOT}/var/cache/pacman/pkg || exit 1 mkarchroot -u -- ${CHROOTDIR}/${CHROOT} mount -o bind ${CACHEDIR} ${CHROOTDIR}/${CHCOPY}/var/cache/pacman/pkg || exit 1 } -echo "Creating the package" +msg "Creating the package" makechrootpkg $CLEAN -r ${CHROOTDIR} -l ${CHCOPY} -- $@ exit 0 -- cgit v1.2.3-54-g00ecf