Pre-seeding XFree settings for keyboard in Debian Installer
Currently, we probably all know that choosing a non US keyboard during
Debian Installer and then installing X, all this at high debconf
priority (with X configuration debconf questions about keyboard *not*
asked) will end with a strange system where the user has chosen, say a
french keyboard.....but will have a graphical login screen with a US
keyboard layout.
As a consequence, users not aware of this will just be unable to login
as soon as their chosen password contains letters which are mapped
differently on a FR and a US keyboard (and there are a *lot*).
This is obviously very bad and I sometimes feel this should be RC...
There are already bug reports suggesting that X uses console-data
settings. However, discussions have clearly shown that mapping both
is quite complicated.
As a way to circumvent this, I propose that we pre-seed
xserver-xfree86 settings about keyboard, mostly
"xserver-xfree86/config/inputdevice/keyboard/model" and
"xserver-xfree86/config/inputdevice/keyboard/layout" with appropriate
values, depending on the chosen keyboard layout during the kbd-chooser
step in d-i.
Example
debconf-get console-keymaps-at/keymap
case $RET in
fr-latin9)
debconf-set xserver-xfree86/config/inputdevice/keyboard/model "pc105"
debconf-set xserver-xfree86/config/inputdevice/keyboard/layout "fr"
;;
de-latin1)
debconf-set xserver-xfree86/config/inputdevice/keyboard/model "pc105"
debconf-set xserver-xfree86/config/inputdevice/keyboard/layout "de"
;;
.../...
and so on...
This does not seem to break X configuration process....the values are
just pre-seeded and thus will be used as such if the user has High
priority for debconf (default after d-i).....or just as a default if
he has lower priority.
Instead of a giant "case" loop, some other system with a basic mapping
in a file could of course be used.
This is also probably too much i386-centric....please transpose for
other arches, of course.
Reply to: