diff options
author | Colin Watson <cjwatson@ubuntu.com> | 2012-09-30 09:33:06 +0200 |
---|---|---|
committer | Daniel Baumann <daniel@debian.org> | 2012-09-30 09:38:17 +0200 |
commit | cab0d9e783ef18c334a09e0f1aa141dec0687978 (patch) | |
tree | 3b15c3a0231ff750221f6dd1f7e12f8e5bc311b2 /scripts/build/binary_package-lists | |
parent | 2046ad7fdd0aebc26ff3ffb625c4446e83b76b68 (diff) | |
download | vyos-live-build-cab0d9e783ef18c334a09e0f1aa141dec0687978.tar.gz vyos-live-build-cab0d9e783ef18c334a09e0f1aa141dec0687978.zip |
If --build-with-chroot is false, run ! lines in package-lists in the host system.
Diffstat (limited to 'scripts/build/binary_package-lists')
-rwxr-xr-x | scripts/build/binary_package-lists | 48 |
1 files changed, 35 insertions, 13 deletions
diff --git a/scripts/build/binary_package-lists b/scripts/build/binary_package-lists index 86716785d..ce459ab3a 100755 --- a/scripts/build/binary_package-lists +++ b/scripts/build/binary_package-lists @@ -41,15 +41,33 @@ Create_lockfile .lock if ls config/package-lists/*.list > /dev/null 2>&1 || \ ls config/package-lists/*.list.binary > /dev/null 2>&1 then - # Restoring cache - Restore_cache cache/packages.chroot - - # Check depends - Check_package chroot/usr/bin/apt-ftparchive apt-utils - Check_package chroot/usr/bin/grep-aptavail dctrl-tools - - # Installing depends - Install_package + case "${LB_BUILD_WITH_CHROOT}" in + true) + # Restoring cache + Restore_cache cache/packages.chroot + + # Check depends + Check_package chroot/usr/bin/apt-ftparchive apt-utils + Check_package chroot/usr/bin/grep-aptavail dctrl-tools + + # Installing depends + Install_package + ;; + + false) + if [ ! -e /usr/bin/apt-ftparchive ]; then + # apt-utils + Echo_error "/usr/bin/apt-ftparchive - no such file." + exit 1 + fi + + if [ ! -e /usr/bin/grep-aptavail ]; then + # dctrl-tools + Echo_error "/usr/bin/grep-aptavail - no such file." + exit 1 + fi + ;; + esac if [ -e "${LIVE_BUILD}/share/bin/Packages" ] then @@ -133,11 +151,15 @@ then rm -rf chroot/binary.deb mv chroot/var/lib/dpkg/status.tmp chroot/var/lib/dpkg/status - # Removing depends - Remove_package + case "${LB_BUILD_WITH_CHROOT}" in + true) + # Removing depends + Remove_package - # Saving cache - Save_cache cache/packages.chroot + # Saving cache + Save_cache cache/packages.chroot + ;; + esac # Creating stage file Create_stagefile .build/binary_package-lists |