Re: [patch] incorrect default value for LH_INITRAMFS
This patch is not correct. On Mon, 10 Sep 2007 22:07:14 +0300 Tzafrir Cohen [EMAIL PROTECTED] wrote: When a value for LH_INITRAMFS is not set, defaults.sh will set it to 'auto' rather than setting it to something sensible (as is when it is set explicitly to 'auto'. The rationale for setting it to auto and not explicitly to some value is that it depends on the distribution. If you do a build, then change the distribution to something new, LH_INITRAMFS will remain unchanged. This will likely break (e.g. if it was etch before and you change to lenny or sid, casper is not in lenny or sid, but the initramfs remains as casper, so you end up with a broken build). The auto value allows live-helper to automatically select an appropriate value for the currently configured distribution *at build time*. So it should remain auto unless manually configured to be a specific initramfs (casper or live-initramfs). I'm not sure why you think the way it is now is a problem. Please explain. Ben -- ,-. nSLUGhttp://www.nslug.ns.ca [EMAIL PROTECTED] \`' Debian http://www.debian.org[EMAIL PROTECTED] ` [ gpg 395C F3A4 35D3 D247 1387 2D9E 5A94 F3CA 0B27 13C8 ] [ pgp 7F DA 09 4B BA 2C 0D E0 1B B1 31 ED C6 A9 39 4F ] ___ debian-live-devel mailing list debian-live-devel@lists.alioth.debian.org http://lists.alioth.debian.org/mailman/listinfo/debian-live-devel
Re: [patch] incorrect default value for LH_INITRAMFS
On Tue, 11 Sep 2007 14:50:51 +0300 Tzafrir Cohen [EMAIL PROTECTED] wrote: Well, this is where this test is implemented. I just want to apply the same logic for both auto and an empty value. With the original script, if I set it to auto this snippet would set it to a distro-specific value but with an empty value, it would get set to auto. Ah, I see. I misunderstood. I agree it appears to be wrong and should be set to the same thing for either case. Well, without it things don't work. With it , things do. Well, that's not very specific ... Specifically lh_binary_linux-image assumes that the value of LH_BINARY_IMAGES is one of iso, net, tar or usb-hdd. But that's a different variable ... Anyway, I still maintain it is wrong. It's now just wrong in the same way for both cases. The value saved in config/common should be auto. This patch makes the value saved in config/common be the distribution- specific value, destroying the ability to auto set the initramfs in subsequent builds if-and-when you change the distribution to a different value. But ... I don't know how to fix this. lh_config calls Set_defaults before rewriting all configs. If we make Set_defaults responsible for determining auto values, the autoness is lost. It seems there should be a separate step that determines at build time all appropriate values for any variable set to auto (or any other derived value that needs to be determined at build time). I have not yet done a thorough review of the code to find the appropriate place. Thanks, Ben -- ,-. nSLUGhttp://www.nslug.ns.ca [EMAIL PROTECTED] \`' Debian http://www.debian.org[EMAIL PROTECTED] ` [ gpg 395C F3A4 35D3 D247 1387 2D9E 5A94 F3CA 0B27 13C8 ] [ pgp 7F DA 09 4B BA 2C 0D E0 1B B1 31 ED C6 A9 39 4F ] ___ debian-live-devel mailing list debian-live-devel@lists.alioth.debian.org http://lists.alioth.debian.org/mailman/listinfo/debian-live-devel
[patch] incorrect default value for LH_INITRAMFS
When a value for LH_INITRAMFS is not set, defaults.sh will set it to 'auto' rather than setting it to something sensible (as is when it is set explicitly to 'auto'. -- Tzafrir Cohen icq#16849755jabber:[EMAIL PROTECTED] +972-50-7952406 mailto:[EMAIL PROTECTED] http://www.xorcom.com iax:[EMAIL PROTECTED]/tzafrir diff --git a/functions/defaults.sh b/functions/defaults.sh index 05b1e0d..ae9c8a4 100755 --- a/functions/defaults.sh +++ b/functions/defaults.sh @@ -168,7 +168,7 @@ Set_defaults () if [ -z ${LH_INITRAMFS} ] then LH_INITRAMFS=auto - else + fi if [ ${LH_INITRAMFS} = auto ] then case ${LH_MODE} in @@ -190,7 +190,6 @@ Set_defaults () ;; esac fi - fi # Setting losetup if [ -z ${LH_LOSETUP} ] || [ ! -x ${LH_LOSETUP} ] ___ debian-live-devel mailing list debian-live-devel@lists.alioth.debian.org http://lists.alioth.debian.org/mailman/listinfo/debian-live-devel