diff options
author | Daniel Baumann <daniel@debian.org> | 2012-12-19 21:41:25 +0100 |
---|---|---|
committer | Daniel Baumann <daniel@debian.org> | 2012-12-20 12:27:49 +0100 |
commit | b0217026ea9608737a43f479c77f3f88a38fb860 (patch) | |
tree | ce663a129b29c25a3a8f9190dceeb1e1169d2ec5 /scripts/build | |
parent | 87008965a11890a4c69671683bf58ae66b77fb92 (diff) | |
download | vyos-live-build-b0217026ea9608737a43f479c77f3f88a38fb860.tar.gz vyos-live-build-b0217026ea9608737a43f479c77f3f88a38fb860.zip |
Moving off binary image archive areas into new config tree format.
Diffstat (limited to 'scripts/build')
-rwxr-xr-x | scripts/build/binary_debian-installer | 4 | ||||
-rwxr-xr-x | scripts/build/bootstrap_debootstrap | 4 | ||||
-rwxr-xr-x | scripts/build/chroot_archives | 44 | ||||
-rwxr-xr-x | scripts/build/chroot_linux-image | 2 | ||||
-rwxr-xr-x | scripts/build/config | 7 |
5 files changed, 29 insertions, 32 deletions
diff --git a/scripts/build/binary_debian-installer b/scripts/build/binary_debian-installer index 93ae4fa05..229850403 100755 --- a/scripts/build/binary_debian-installer +++ b/scripts/build/binary_debian-installer @@ -441,7 +441,7 @@ then then # FIXME: account for the fact that PARENT_DISTRIBUTION and DISTRIBUTION might be the same (to not have overlapping cache files for contents). - _CONTENTS="$(for _ARCHIVE_AREA in ${LB_ARCHIVE_AREAS}; do echo ${LB_MIRROR_CHROOT}/dists/${LB_DISTRIBUTION}/${_ARCHIVE_AREA}/Contents-${LIVE_IMAGE_ARCHITECTURE}.gz; done)" + _CONTENTS="$(for _ARCHIVE_AREA in ${LIVE_IMAGE_ARCHIVE_AREAS}; do echo ${LB_MIRROR_CHROOT}/dists/${LB_DISTRIBUTION}/${_ARCHIVE_AREA}/Contents-${LIVE_IMAGE_ARCHITECTURE}.gz; done)" rm -f cache/contents.chroot/contents.${LB_DISTRIBUTION}.${LIVE_IMAGE_ARCHITECTURE} @@ -502,7 +502,7 @@ then mv chroot/binary.deb ./ - for _ARCHIVE_AREA in $(echo ${LB_PARENT_ARCHIVE_AREAS} ${LB_ARCHIVE_AREAS}) + for _ARCHIVE_AREA in $(echo ${LB_PARENT_ARCHIVE_AREAS} ${LIVE_IMAGE_ARCHIVE_AREAS}) do mkdir -p binary/pool/${_ARCHIVE_AREA} done diff --git a/scripts/build/bootstrap_debootstrap b/scripts/build/bootstrap_debootstrap index 3f4a7afe4..167c5a7d9 100755 --- a/scripts/build/bootstrap_debootstrap +++ b/scripts/build/bootstrap_debootstrap @@ -66,10 +66,10 @@ then DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --arch=${LIVE_IMAGE_ARCHITECTURE}" fi -if [ "${LB_ARCHIVE_AREAS}" != "main" ] +if [ "${LIVE_IMAGE_ARCHIVE_AREAS}" != "main" ] then # Modify archive areas to remove leading/trailing whitespaces and replace other whitepspace with commas - DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --components=$(echo ${LB_ARCHIVE_AREAS} | sed -e 's| |,|g')" + DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --components=$(echo ${LIVE_IMAGE_ARCHIVE_AREAS} | sed -e 's| |,|g')" fi case "${LB_USE_FAKEROOT}" in diff --git a/scripts/build/chroot_archives b/scripts/build/chroot_archives index d8712eeec..a74f3714d 100755 --- a/scripts/build/chroot_archives +++ b/scripts/build/chroot_archives @@ -83,11 +83,11 @@ EOF _DISTRIBUTION="$(echo ${LB_DISTRIBUTION} | sed -e 's|-backports||')" - echo "deb ${LB_MIRROR_CHROOT} ${_DISTRIBUTION} ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb ${LB_MIRROR_CHROOT} ${_DISTRIBUTION} ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list if [ "${_PASS}" = "source" ] || [ "${LB_APT_SOURCE_ARCHIVES}" = "true" ] then - echo "deb-src ${LB_MIRROR_CHROOT} ${_DISTRIBUTION} ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb-src ${LB_MIRROR_CHROOT} ${_DISTRIBUTION} ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list fi fi @@ -112,20 +112,20 @@ EOF if [ "${LB_MODE}" = progress-linux ] then - echo "deb ${LB_MIRROR_CHROOT_SECURITY} ${_DISTRIBUTION}-security ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb ${LB_MIRROR_CHROOT_SECURITY} ${_DISTRIBUTION}-security ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list if [ "${_PASS}" = "source" ] || [ "${LB_APT_SOURCE_ARCHIVES}" = "true" ] then - echo "deb-src ${LB_MIRROR_CHROOT_SECURITY} ${_DISTRIBUTION}-security ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb-src ${LB_MIRROR_CHROOT_SECURITY} ${_DISTRIBUTION}-security ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list fi else if [ "${LB_DERIVATIVE}" = "true" ] then - echo "deb ${LB_MIRROR_CHROOT_SECURITY} ${_DISTRIBUTION}/updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb ${LB_MIRROR_CHROOT_SECURITY} ${_DISTRIBUTION}/updates ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list if [ "${_PASS}" = "source" ] || [ "${LB_APT_SOURCE_ARCHIVES}" = "true" ] then - echo "deb-src ${LB_MIRROR_CHROOT_SECURITY} ${_DISTRIBUTION}/updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb-src ${LB_MIRROR_CHROOT_SECURITY} ${_DISTRIBUTION}/updates ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list fi fi fi @@ -153,11 +153,11 @@ EOF if [ "${LB_DERIVATIVE}" = "true" ] && [ "${LB_MIRROR_CHROOT_UPDATES}" != "none" ] then - echo "deb ${LB_MIRROR_CHROOT_UPDATES} ${_DISTRIBUTION}-updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb ${LB_MIRROR_CHROOT_UPDATES} ${_DISTRIBUTION}-updates ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list if [ "${_PASS}" = "source" ] || [ "${LB_APT_SOURCE_ARCHIVES}" = "true" ] then - echo "deb-src ${LB_MIRROR_CHROOT_UPDATES} ${_DISTRIBUTION}-updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb-src ${LB_MIRROR_CHROOT_UPDATES} ${_DISTRIBUTION}-updates ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list fi fi fi @@ -180,11 +180,11 @@ EOF if [ "${LB_DERIVATIVE}" = "true" ] && [ "${LB_MIRROR_CHROOT_BACKPORTS}" != "none" ] then - echo "deb ${LB_MIRROR_CHROOT_BACKPORTS} ${_DISTRIBUTION}-backports ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb ${LB_MIRROR_CHROOT_BACKPORTS} ${_DISTRIBUTION}-backports ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list if [ "${_PASS}" = "source" ] || [ "${LB_APT_SOURCE_ARCHIVES}" = "true" ] then - echo "deb-src ${LB_MIRROR_CHROOT_BACKPORTS} ${_DISTRIBUTION}-backports ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb-src ${LB_MIRROR_CHROOT_BACKPORTS} ${_DISTRIBUTION}-backports ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list fi fi fi @@ -268,7 +268,7 @@ EOF then sed -e "s|@DISTRIBUTION@|${LB_DISTRIBUTION}|g" \ -e "s|@PARENT_DISTRIBUTION@|${LB_PARENT_DISTRIBUTION}|g" \ - -e "s|@ARCHIVE_AREAS@|${LB_ARCHIVE_AREAS}|g" \ + -e "s|@ARCHIVE_AREAS@|${LIVE_IMAGE_ARCHIVE_AREAS}|g" \ -e "s|@PARENT_ARCHIVE_AREAS@|${LB_PARENT_ARCHIVE_AREAS}|g" \ "${FILE}" > "chroot/etc/apt/sources.list.d/$(basename ${FILE} .chroot)" @@ -653,11 +653,11 @@ EOF _DISTRIBUTION="$(echo ${LB_DISTRIBUTION} | sed -e 's|-backports||')" - echo "deb ${LB_MIRROR_BINARY} ${_DISTRIBUTION} ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb ${LB_MIRROR_BINARY} ${_DISTRIBUTION} ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list if [ "${_PASS}" = "source" ] || [ "${LB_APT_SOURCE_ARCHIVES}" = "true" ] then - echo "deb-src ${LB_MIRROR_BINARY} ${_DISTRIBUTION} ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb-src ${LB_MIRROR_BINARY} ${_DISTRIBUTION} ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list fi fi @@ -682,20 +682,20 @@ EOF if [ "${LB_MODE}" = progress-linux ] then - echo "deb ${LB_MIRROR_BINARY_SECURITY} ${_DISTRIBUTION}-security ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb ${LB_MIRROR_BINARY_SECURITY} ${_DISTRIBUTION}-security ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list if [ "${_PASS}" = "source" ] || [ "${LB_APT_SOURCE_ARCHIVES}" = "true" ] then - echo "deb-src ${LB_MIRROR_BINARY_SECURITY} ${_DISTRIBUTION}-security ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb-src ${LB_MIRROR_BINARY_SECURITY} ${_DISTRIBUTION}-security ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list fi else if [ "${LB_DERIVATIVE}" = "true" ] then - echo "deb ${LB_MIRROR_BINARY_SECURITY} ${_DISTRIBUTION}/updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb ${LB_MIRROR_BINARY_SECURITY} ${_DISTRIBUTION}/updates ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list if [ "${_PASS}" = "source" ] || [ "${LB_APT_SOURCE_ARCHIVES}" = "true" ] then - echo "deb-src ${LB_MIRROR_BINARY_SECURITY} ${_DISTRIBUTION}/updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb-src ${LB_MIRROR_BINARY_SECURITY} ${_DISTRIBUTION}/updates ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list fi fi fi @@ -723,11 +723,11 @@ EOF if [ "${LB_DERIVATIVE}" = "true" ] && [ "${LB_MIRROR_BINARY_UPDATES}" != "none" ] then - echo "deb ${LB_MIRROR_BINARY_UPDATES} ${_DISTRIBUTION}-updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb ${LB_MIRROR_BINARY_UPDATES} ${_DISTRIBUTION}-updates ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list if [ "${_PASS}" = "source" ] || [ "${LB_APT_SOURCE_ARCHIVES}" = "true" ] then - echo "deb-src ${LB_MIRROR_BINARY_UPDATES} ${_DISTRIBUTION}-updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb-src ${LB_MIRROR_BINARY_UPDATES} ${_DISTRIBUTION}-updates ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list fi fi fi @@ -750,11 +750,11 @@ EOF if [ "${LB_DERIVATIVE}" = "true" ] && [ "${LB_MIRROR_BINARY_BACKPORTS}" != "none" ] then - echo "deb ${LB_MIRROR_BINARY_BACKPORTS} ${_DISTRIBUTION}-backports ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb ${LB_MIRROR_BINARY_BACKPORTS} ${_DISTRIBUTION}-backports ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list if [ "${_PASS}" = "source" ] || [ "${LB_APT_SOURCE_ARCHIVES}" = "true" ] then - echo "deb-src ${LB_MIRROR_BINARY_BACKPORTS} ${_DISTRIBUTION}-backports ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list + echo "deb-src ${LB_MIRROR_BINARY_BACKPORTS} ${_DISTRIBUTION}-backports ${LIVE_IMAGE_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list.d/${LB_MODE}.list fi fi fi @@ -829,7 +829,7 @@ EOF then sed -e "s|@DISTRIBUTION@|${LB_DISTRIBUTION}|g" \ -e "s|@PARENT_DISTRIBUTION@|${LB_PARENT_DISTRIBUTION}|g" \ - -e "s|@ARCHIVE_AREAS@|${LB_ARCHIVE_AREAS}|g" \ + -e "s|@ARCHIVE_AREAS@|${LIVE_IMAGE_ARCHIVE_AREAS}|g" \ -e "s|@PARENT_ARCHIVE_AREAS@|${LB_PARENT_ARCHIVE_AREAS}|g" \ "${FILE}" > "chroot/etc/apt/sources.list.d/$(basename ${FILE} .binary)" diff --git a/scripts/build/chroot_linux-image b/scripts/build/chroot_linux-image index 74995f08e..91121e353 100755 --- a/scripts/build/chroot_linux-image +++ b/scripts/build/chroot_linux-image @@ -85,7 +85,7 @@ then then # FIXME: account for the fact that PARENT_DISTRIBUTION and DISTRIBUTION might be the same (to not have overlapping cache files for contents). - _CONTENTS="$(for _ARCHIVE_AREA in ${LB_ARCHIVE_AREAS}; do echo ${LB_MIRROR_CHROOT}/dists/${LB_DISTRIBUTION}/${_ARCHIVE_AREA}/Contents-${LIVE_IMAGE_ARCHITECTURE}.gz; done)" + _CONTENTS="$(for _ARCHIVE_AREA in ${LIVE_IMAGE_ARCHIVE_AREAS}; do echo ${LB_MIRROR_CHROOT}/dists/${LB_DISTRIBUTION}/${_ARCHIVE_AREA}/Contents-${LIVE_IMAGE_ARCHITECTURE}.gz; done)" rm -f cache/contents.chroot/contents.${LB_DISTRIBUTION}.${LIVE_IMAGE_ARCHITECTURE} diff --git a/scripts/build/config b/scripts/build/config index 886f74f4d..89cc2cd87 100755 --- a/scripts/build/config +++ b/scripts/build/config @@ -491,7 +491,7 @@ Local_arguments () ;; --archive-areas) - LB_ARCHIVE_AREAS="${2}" + LIVE_IMAGE_ARCHIVE_AREAS="${2}" shift 2 ;; @@ -1210,10 +1210,6 @@ LB_MIRROR_DEBIAN_INSTALLER="${LB_MIRROR_DEBIAN_INSTALLER}" # (Default: empty) LB_ARCHIVES="${LB_ARCHIVES}" -# \$LB_ARCHIVE_AREAS: select archive areas to use -# (Default: ${LB_ARCHIVE_AREAS}) -LB_ARCHIVE_AREAS="${LB_ARCHIVE_AREAS}" - # \$LB_PARENT_ARCHIVE_AREAS: select archive areas to use # (Default: ${LB_PARENT_ARCHIVE_AREAS}) LB_PARENT_ARCHIVE_AREAS="${LB_PARENT_ARCHIVE_AREAS}" @@ -1496,6 +1492,7 @@ Set_configuration "config/control" "Configuration-Version" "${LIVE_CONFIGURATION echo "" >> config/control Set_configuration "config/control" "Name" "${LIVE_IMAGE_NAME}" Set_configuration "config/control" "Architecture" "${LIVE_IMAGE_ARCHITECTURE}" +Set_configuration "config/control" "Archive-Areas" "${LIVE_IMAGE_ARCHIVE_AREAS}" Set_configuration "config/control" "Type" "${LIVE_IMAGE_TYPE}" # Creating stage file |