From 8a4a50fdb6b206fbff62fd3043ed388f25a0ffb1 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 23 Sep 2007 10:04:51 +0200 Subject: Adding live-helper 1.0~a7-1. --- helpers/lh_chroot_sources | 62 +++++++++++++++++++++++++++++++++-------------- 1 file changed, 44 insertions(+), 18 deletions(-) (limited to 'helpers/lh_chroot_sources') diff --git a/helpers/lh_chroot_sources b/helpers/lh_chroot_sources index c4a3a513e..7d0980db7 100755 --- a/helpers/lh_chroot_sources +++ b/helpers/lh_chroot_sources @@ -57,15 +57,28 @@ case "${1}" in if [ "${LIVE_SECURITY}" = "enabled" ] then - if [ "${LIVE_DISTRIBUTION}" != "sid" ] && [ "${LIVE_DISTRIBUTION}" != "unstable" ] - then - echo "deb ${LIVE_MIRROR_BUILD_SECURITY} ${LIVE_DISTRIBUTION}/updates ${LIVE_SECTIONS}" >> chroot/etc/apt/sources.list + case "${LH_MODE}" in + debian) + if [ "${LIVE_DISTRIBUTION}" != "sid" ] && [ "${LIVE_DISTRIBUTION}" != "unstable" ] + then + echo "deb ${LIVE_MIRROR_BUILD_SECURITY} ${LIVE_DISTRIBUTION}/updates ${LIVE_SECTIONS}" >> chroot/etc/apt/sources.list - if [ "${LIVE_SOURCE}" = "yes" ] - then - echo "deb-src ${LIVE_MIRROR_BUILD_SECURITY} ${LIVE_DISTRIBUTION}/updates ${LIVE_SECTIONS}" >> chroot/etc/apt/sources.list - fi - fi + if [ "${LIVE_SOURCE}" = "enabled" ] + then + echo "deb-src ${LIVE_MIRROR_BUILD_SECURITY} ${LIVE_DISTRIBUTION}/updates ${LIVE_SECTIONS}" >> chroot/etc/apt/sources.list + fi + fi + ;; + + ubuntu) + echo "deb ${LIVE_MIRROR_BUILD_SECURITY} ${LIVE_DISTRIBUTION}-security ${LIVE_SECTIONS}" >> chroot/etc/apt/sources.list + + if [ "${LIVE_SOURCE}" = "enabled" ] + then + echo "deb-src ${LIVE_MIRROR_BUILD_SECURITY} ${LIVE_DISTRIBUTION}-security ${LIVE_SECTIONS}" >> chroot/etc/apt/sources.list + fi + ;; + esac fi # Check local sources.list @@ -158,15 +171,28 @@ case "${1}" in if [ "${LIVE_SECURITY}" = "enabled" ] then - if [ "${LIVE_DISTRIBUTION}" = "etch" ] || [ "${LIVE_DISTRIBUTION}" = "testing" ] - then - echo "deb ${LIVE_MIRROR_IMAGE_SECURITY} ${LIVE_DISTRIBUTION}/updates ${LIVE_SECTIONS}" >> chroot/etc/apt/sources.list - - if [ "${LIVE_SOURCE}" = "yes" ] - then - echo "deb-src ${LIVE_MIRROR_IMAGE_SECURITY} ${LIVE_DISTRIBUTION}/updates ${LIVE_SECTIONS}" >> chroot/etc/apt/sources.list - fi - fi + case "${LH_MODE}" in + debian) + if [ "${LIVE_DISTRIBUTION}" != "sid" ] && [ "${LIVE_DISTRIBUTION}" != "unstable" ] + then + echo "deb ${LIVE_MIRROR_IMAGE_SECURITY} ${LIVE_DISTRIBUTION}/updates ${LIVE_SECTIONS}" >> chroot/etc/apt/sources.list + + if [ "${LIVE_SOURCE}" = "enabled" ] + then + echo "deb-src ${LIVE_MIRROR_IMAGE_SECURITY} ${LIVE_DISTRIBUTION}/updates ${LIVE_SECTIONS}" >> chroot/etc/apt/sources.list + fi + fi + ;; + + ubuntu) + echo "deb ${LIVE_MIRROR_IMAGE_SECURITY} ${LIVE_DISTRIBUTION}-security ${LIVE_SECTIONS}" >> chroot/etc/apt/sources.list + + if [ "${LIVE_SOURCE}" = "enabled" ] + then + echo "deb-src ${LIVE_MIRROR_IMAGE_SECURITY} ${LIVE_DISTRIBUTION}-security ${LIVE_SECTIONS}" >> chroot/etc/apt/sources.list + fi + ;; + esac fi # Check local sources.list @@ -175,7 +201,7 @@ case "${1}" in echo "" >> chroot/etc/apt/sources.list echo "# Custom repositories" >> chroot/etc/apt/sources.list - for FILE in config/chroot_sources/*.build + for FILE in config/chroot_sources/*.image do cat ${FILE} | grep -v "^##" >> chroot/etc/apt/sources.list done -- cgit v1.2.3