summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Reynolds <fauno@kiwwwi.com.ar>2012-02-14 11:47:52 -0300
committerNicolas Reynolds <fauno@kiwwwi.com.ar>2012-02-14 11:47:52 -0300
commit7506b06cb81951a4705908f6bfe93f81d50667a7 (patch)
tree51d257cec4863822058bd6510fb39f4f33e29a06
parent875ec16b3d25c2b4d9dc5c940702f5ecde76cf7f (diff)
parentbb7f637b5c5fe7df671d374d2b8547f2431bad82 (diff)
Merge branch 'master' into fauno
-rw-r--r--cleansystem131
-rwxr-xr-xlibrechroot16
-rwxr-xr-xlibrerelease15
-rwxr-xr-xupdate-cleansystem2
4 files changed, 24 insertions, 140 deletions
diff --git a/cleansystem b/cleansystem
deleted file mode 100644
index f210416..0000000
--- a/cleansystem
+++ /dev/null
@@ -1,131 +0,0 @@
-acl
-attr
-autoconf
-automake
-bash
-binutils
-bison
-bzip2
-ca-certificates
-cloog
-coreutils
-cracklib
-cronie
-cryptsetup
-curl
-db
-dbus-core
-device-mapper
-dhcpcd
-diffutils
-dirmngr
-e2fsprogs
-expat
-fakeroot
-file
-filesystem
-findutils
-flex
-gawk
-gcc
-gcc-libs
-gdbm
-gettext
-glib2
-glibc
-gmp
-gnupg
-gnupg2
-gpgme
-grep
-groff
-grub
-gzip
-heirloom-mailx
-iana-etc
-inetutils
-initscripts
-iproute2
-iputils
-isl
-jfsutils
-kbd
-keyutils
-kmod
-krb5
-less
-libarchive
-libassuan
-libcap
-libfetch
-libffi
-libgcrypt
-libgpg-error
-libgssglue
-libksba
-libldap
-libltdl
-libmpc
-libnl
-libpcap
-libpipeline
-libsasl
-libssh2
-libtirpc
-libtool
-libusb
-libusb-compat
-licenses-libre
-linux-api-headers
-linux-libre
-logrotate
-lvm2
-m4
-make
-man-db
-man-pages
-mdadm
-mkinitcpio
-mkinitcpio-busybox
-mpfr
-nano
-ncurses
-openssl
-pacman
-pacman-mirrorlist-libre
-pam
-patch
-pciutils
-pcmciautils
-pcre
-perl
-pinentry
-pkg-config
-popt
-ppl
-ppp
-procps
-psmisc
-pth
-readline
-reiserfsprogs
-run-parts
-sed
-shadow
-sudo
-sysfsutils
-sysvinit
-tar
-texinfo
-tzdata
-udev
-usbutils
-util-linux
-vi
-wget
-which
-wpa_supplicant
-xfsprogs
-xz
-your-freedom
-zlib
diff --git a/librechroot b/librechroot
index 31516ac..0398a0f 100755
--- a/librechroot
+++ b/librechroot
@@ -24,14 +24,15 @@
function usage {
+ echo ""
echo "Usage: $0 [options] [chrootname]"
echo "Use it as root."
- echo ''
+ echo ""
echo "Default chroot name: $CHROOT"
echo "Default chrootdir: $CHROOTDIR"
- echo ''
+ echo ""
echo "OPTIONS:"
- echo ''
+ echo ""
echo " -c : clean the chroot using pacman"
echo " only 'base', 'base-devel' and 'sudo' on chroot"
echo " -d <chrootdir> : use <chrootdir> instead of default"
@@ -43,9 +44,8 @@ function usage {
}
function clean_chroot { # Clean packages with pacman
-
msg "Cleaning chroot: ${CHROOTDIR}/${CHROOTNAME}"
-
+ update-cleansystem
cp "/etc/libretools.d/cleansystem" "${CHROOTDIR}/${CHROOTNAME}/cleansystem"
(cat <<EOF
#!/bin/bash
@@ -83,8 +83,12 @@ EOF
function clean_repo {
msg "Cleaning repo for chroot: ${CHROOTDIR}/${CHROOTNAME}"
if [ -d "${CHROOTDIR}/${CHROOTNAME}/repo" ]; then
- rm -rf "${CHROOTDIR}/${CHROOTNAME}/repo"
+ find "${CHROOTDIR}/${CHROOTNAME}/repo/" -mindepth 1 -delete
+ else
+ mkdir -p "${CHROOTDIR}/${CHROOTNAME}/repo"
fi
+ bsdtar -czf "${CHROOTDIR}/${CHROOTNAME}/repo/repo.db.tar.gz" -T /dev/null
+ ln -s "repo.db.tar.gz" "${CHROOTDIR}/${CHROOTNAME}/repo/repo.db"
}
source /etc/libretools.conf
diff --git a/librerelease b/librerelease
index f31bc3a..bac5b88 100755
--- a/librerelease
+++ b/librerelease
@@ -72,7 +72,12 @@ function sign_packages {
fi
msg2 "Signing ${package}..."
- gpg --default-key "${SIGID}" --output "${package}${SIGEXT}" --detach-sig "${package}"
+ gpg --default-key "${SIGID}" --output "${package}${SIGEXT}" \
+ --detach-sig "${package}" || {
+ error "Signing failed"
+ exit 2
+ }
+
done
}
@@ -110,11 +115,17 @@ done
clean_non_packages
if [ ! -z "${SIGID}" ]; then
sign_packages
-else
+else
error "Package signing is *required*"
exit 1
fi
+# Make the permissions of the packages 644 otherwize the user will get access
+# denied error when they try to download (rsync --no-perms doesn't seem to
+# work).
+find ${WORKDIR}/staging -type f -exec chmod 644 {} \;
+find ${WORKDIR}/staging -type d -exec chmod 755 {} \;
+
msg "Uploading packages..."
rsync --recursive \
${dryrun} \
diff --git a/update-cleansystem b/update-cleansystem
index d4ad943..af215d7 100755
--- a/update-cleansystem
+++ b/update-cleansystem
@@ -19,6 +19,6 @@ pacman -r ${tmpdir} --config /etc/pacman.conf -Sy
pacman -r ${tmpdir} \
--config /etc/pacman.conf \
-Sp --print-format "%n" \
- base base-devel ${@} | sort > $(dirname $0)/cleansystem
+ base base-devel ${@} | sort > /etc/libretools.d/cleansystem
exit $?