From fcafaede192e150daaf61591aef57edf3c2983fc Mon Sep 17 00:00:00 2001 From: jnqnfe Date: Mon, 5 Jan 2015 16:53:53 +0000 Subject: simplify --debian-installer choices `false` and `none` make no sense as choices for this option. Here we replace `false` with `none`, and remove `true`. Note that `true` was treated as an alias for netinst (see the changes to source_disk and and binary_disk). For backwards compatibility we still allow `true` and `false` by converting them to `netinst` and `none` respectively, whilst printing a warning to encourage users to move to `netinst`/`none`. Gbp-Dch: Short Closes: #952864 --- functions/defaults.sh | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'functions') diff --git a/functions/defaults.sh b/functions/defaults.sh index 8c91d3b38..1c7831532 100755 --- a/functions/defaults.sh +++ b/functions/defaults.sh @@ -576,7 +576,17 @@ Set_defaults () LB_BUILD_WITH_TMPFS="${LB_BUILD_WITH_TMPFS:-false}" # Setting debian-installer option - LB_DEBIAN_INSTALLER="${LB_DEBIAN_INSTALLER:-false}" + LB_DEBIAN_INSTALLER="${LB_DEBIAN_INSTALLER:-none}" + if [ "${LB_DEBIAN_INSTALLER}" = "false" ] + then + LB_DEBIAN_INSTALLER="none" + Echo_warning "A value of 'false' for option LB_DEBIAN_INSTALLER is deprecated, please use 'none' in future." + fi + if [ "${LB_DEBIAN_INSTALLER}" = "true" ] + then + LB_DEBIAN_INSTALLER="netinst" + Echo_warning "A value of 'true' for option LB_DEBIAN_INSTALLER is deprecated, please use 'netinst' in future." + fi LB_DEBIAN_INSTALLER_DISTRIBUTION="${LB_DEBIAN_INSTALLER_DISTRIBUTION:-${LB_DISTRIBUTION}}" @@ -715,7 +725,7 @@ Set_defaults () *) case "${LB_ARCHITECTURES}" in amd64|i386) - if [ "${LB_DEBIAN_INSTALLER}" != "false" ] + if [ "${LB_DEBIAN_INSTALLER}" != "none" ] then LB_LOADLIN="${LB_LOADLIN:-true}" else @@ -739,7 +749,7 @@ Set_defaults () *) case "${LB_ARCHITECTURES}" in amd64|i386) - if [ "${LB_DEBIAN_INSTALLER}" != "false" ] + if [ "${LB_DEBIAN_INSTALLER}" != "none" ] then LB_WIN32_LOADER="${LB_WIN32_LOADER:-true}" else @@ -823,7 +833,7 @@ Check_defaults () exit 1 fi - if [ "${LB_DEBIAN_INSTALLER}" != "false" ] + if [ "${LB_DEBIAN_INSTALLER}" != "none" ] then # d-i true, no caching if ! echo ${LB_CACHE_STAGES} | grep -qs "bootstrap\b" || [ "${LB_CACHE}" != "true" ] || [ "${LB_CACHE_PACKAGES}" != "true" ] -- cgit v1.2.3