Bug 231591

Summary: Installer / bsdconfig creates always settings for syscons
Product: Base System Reporter: Martin <martin.jakob>
Component: binAssignee: freebsd-bugs (Nobody) <bugs>
Status: New ---    
Severity: Affects Some People CC: emaste
Priority: --- Keywords: install, vt
Version: CURRENT   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
vt messages to messages.subr
none
vt messages to keymap none

Description Martin 2018-09-22 15:40:40 UTC
Using bsdconfig to change the font or keymap, it always writes syscons settings to /etc/rc.conf, although vt is set as console driver.

For example, using bsdconfig to set the keymap to german and fonts to ISO 8859-15 results in these entries in /etc/rc.conf:

...
keymap="german.iso"
font8x8="iso15-8x8"
font8x14="iso15-8x14"
font8x16="iso15-8x16"
...

With vidfont and kbdmap i get the correct and working results:
...
keymap="de.kbd"
...
font8x8=vgarom-thin-8x8.fnt
...

Console driver is vt:
root@betablock:~ # sysctl kern.vty
kern.vty: vt

I checked in /usr/share/bsdconfig/keymap.subr, and found a check if vt or syscons is used. Depending of the result, it should use /usr/share/syscons/keymaps/INDEX.keymaps or /usr/share/vt/keymaps/INDEX.keymaps for creating the userinterface and set the korrekt keymap. But i could not see, where the problem is.

I checked bsdconfig on 11.2 and the installer on trueos 18.06, both behave in the same way.
Comment 1 Martin 2018-09-22 16:00:39 UTC
looks a little bit like bug #202081 in reverse.
Comment 2 Martin 2020-09-13 15:47:23 UTC
I tried to write a fix for the problem with the keyboard and font configuration, see attached patches.

Wouldn't it be better to use the kbdmap and vidfont tools for these configuration changes.
Comment 3 Martin 2020-09-13 15:53:33 UTC
Created attachment 217929 [details]
vt messages to messages.subr

The text is copied from /usr/share/vt/keymaps/INDEX.keymaps
Comment 4 Martin 2020-09-13 15:58:53 UTC
Created attachment 217930 [details]
vt messages to keymap

The patch seems to work for me.

I havent looked at the font problem, but it should be similar.