tags 452331 + patch tags 452331 - help thanks On Thursday 22 November 2007, Christian Perrier wrote: > Unfortunately, I can't tell I'm entirely sure to understand everything > in all this and the way both packages are interacting together. AFAICT you are correct: the config script in dh-consoledata needs to be changed and then console-data must be uploaded with an updated versioned build dependency on the new version of that package. > That script is Perl source...and really hard for me to understand. So, > some help figuring exactly what needs modification is probably > required. The problem here is that having the keymap policy question asked is completely correct in all other use cases, so the only solution I can come up with is to somehow tell console-data that it is being installed inside D-I and to skip the question only in that specific case. The attached patch does this by checking for the existence of a file in /tmp: /tmp/debian-installer/keymap-policy-default. The patch has been tested and does what we want. Even though it probably is not strictly necessary, I explicitly set keymap/policy that seems most consistent with the rest of the script, As we install locales from the post-base-installer 05localechooser hook script, it seems logical to have that file touched (in /target of course) in that hook script. If we want to allow for the fact that locales could also be installed for other reasons, we should delay deleting the file/dir to finish-install. One option there would be 05localechooser, but we could also make the directory more general (with an eye on future other uses) and remove it in 95umount instead. (Yes, I know that /tmp will be cleaned on reboot too, but IMO cleaning up after yourself is a good general principle.) If anyone can think of a cleaner solution (or a better name/location for the temp file), please shout. If this patch is acceptable, I request that both console-common and console-data be uploaded with urgency=medium (unless there are other, more risky changes too). After that I'll make the necessary changes in D-I. Cheers, FJP
diff -Nru /tmp/vrO83w9yNL/console-common-0.7.71/config.in /tmp/xrg5RU2VB9/console-common-0.7.72/config.in --- /tmp/vrO83w9yNL/console-common-0.7.71/config.in 2007-08-02 18:10:18.000000000 +0200 +++ /tmp/xrg5RU2VB9/console-common-0.7.72/config.in 2007-12-13 14:33:23.000000000 +0100 @@ -281,14 +281,20 @@ ($state == 0) && do { # This one has a default, we can trust it has a value - ($ret) = input ('high', 'console-data/keymap/policy'); - if ($ret == 30) { # if the question is not going to be asked... - maybe_set_default_choice ('console-data/keymap/policy', "Don't touch keymaps"); - } - @retval = go; - if ($retval[0] eq 30) { + # Skip the question when console-data is being installed from + # debian-installer as it sets up the keymap itself + if (! -r '/tmp/debian-installer/keymap-policy-default') { + ($ret) = input ('high', 'console-data/keymap/policy'); + if ($ret == 30) { # if the question is not going to be asked... + maybe_set_default_choice ('console-data/keymap/policy', "Don't touch keymaps"); + } + @retval = go; + if ($retval[0] eq 30) { + set ('console-data/keymap/policy', "Don't touch keymap"); + exit 30; + } + } else { set ('console-data/keymap/policy', "Don't touch keymap"); - exit 30; } my $policy = get ('console-data/keymap/policy'); diff -Nru /tmp/vrO83w9yNL/console-common-0.7.71/debian/changelog /tmp/xrg5RU2VB9/console-common-0.7.72/debian/changelog --- /tmp/vrO83w9yNL/console-common-0.7.71/debian/changelog 2007-10-14 12:41:20.000000000 +0200 +++ /tmp/xrg5RU2VB9/console-common-0.7.72/debian/changelog 2007-12-13 14:37:52.000000000 +0100 @@ -1,3 +1,11 @@ +console-common (0.7.72) UNRELEASED; urgency=low + + * Don't display the keymap policy question when console-data is installed + from debian-installer as that takes care of setting up the correct keymap + itself. Closes: #452331. + + -- Frans Pop <fjp@debian.org> Thu, 13 Dec 2007 14:33:28 +0100 + console-common (0.7.71) unstable; urgency=low [ Debconf translations ]
Attachment:
signature.asc
Description: This is a digitally signed message part.