From 5b0ace18a3db9ddc2fe69b080207fd1e33f876d3 Mon Sep 17 00:00:00 2001 From: Rune Morling Date: Tue, 5 Dec 2023 14:42:37 +0100 Subject: [PATCH] grub2: Update default config to set font to ter-32b **Summary** Increase default font size to 32px (terminus bold) to help with legibility on HiDPI displays. Additionally, set GRUB_GFXMODE 1366x768, with a 1024x768 fallback, and auto for when VM gfx adapters are genuinely clueless. This will probably work in VMs and on (most) older laptops. Shout out to @TraceyC77 and sheepman4267 for the suggestions and valuable QA work on this. Part of #826 **Test Plan** - Update grub2 - run `sudo mv /etc/default/grub.newconfig /etc/default/grub` - run `sudo clr-update-wrapper` - reboot and check that new font is displayed in grub bootloader menu Signed-off-by: Rune Morling --- packages/g/grub2/files/conf/grub | 4 ++++ packages/g/grub2/package.yml | 4 +++- packages/g/grub2/pspec_x86_64.xml | 6 ++++-- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/packages/g/grub2/files/conf/grub b/packages/g/grub2/files/conf/grub index 9e91c1a46e2d..a19f1c8e6daf 100644 --- a/packages/g/grub2/files/conf/grub +++ b/packages/g/grub2/files/conf/grub @@ -10,6 +10,9 @@ GRUB_BACKGROUND="" GRUB_COLOR_NORMAL="black/white" GRUB_COLOR_HIGHLIGHT="light-blue/white" +# Use large 16x32 terminus fonts to help people on HiDPI monitors +GRUB_FONT="/boot/grub/fonts/ter-32b.pf2" + # Uncomment to enable BadRAM filtering, modify to suit your needs # This works with Linux (no patch required) and with any kernel that obtains # the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...) @@ -22,6 +25,7 @@ GRUB_COLOR_HIGHLIGHT="light-blue/white" # note that you can use only modes which your graphic card supports via VBE # you can see them in real GRUB with the command `vbeinfo' #GRUB_GFXMODE=640x480 +GRUB_GFXMODE=1366x768,1024x768x32,auto # Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux #GRUB_DISABLE_LINUX_UUID=true diff --git a/packages/g/grub2/package.yml b/packages/g/grub2/package.yml index 4992aa910039..7a136a31bad5 100644 --- a/packages/g/grub2/package.yml +++ b/packages/g/grub2/package.yml @@ -1,6 +1,6 @@ name : grub2 version : '2.04' -release : 32 +release : 34 source : - git|https://git.savannah.gnu.org/git/grub.git : e7b8856f8be3292afdb38d2e8c70ad8d62a61e10 homepage : https://www.gnu.org/software/grub/ @@ -49,3 +49,5 @@ install : | # build grub-compatible PF2 fonts from BDF format terminus fonts in 16x32 $installdir/usr/bin/grub-mkfont $pkgfiles/font-terminus-bdf/ter-u32b.bdf -o $installdir/usr/share/grub/ter-32b.pf2 $installdir/usr/bin/grub-mkfont $pkgfiles/font-terminus-bdf/ter-u32n.bdf -o $installdir/usr/share/grub/ter-32n.pf2 + install -Dm00644 $installdir/usr/share/grub/ter-32b.pf2 $installdir/boot/grub/fonts/ter-32b.pf2 + install -Dm00644 $installdir/usr/share/grub/ter-32n.pf2 $installdir/boot/grub/fonts/ter-32n.pf2 diff --git a/packages/g/grub2/pspec_x86_64.xml b/packages/g/grub2/pspec_x86_64.xml index 588c66469332..7f9c6cd11ed1 100644 --- a/packages/g/grub2/pspec_x86_64.xml +++ b/packages/g/grub2/pspec_x86_64.xml @@ -21,6 +21,8 @@ system.boot + /boot/grub/fonts/ter-32b.pf2 + /boot/grub/fonts/ter-32n.pf2 /etc/bash_completion.d/grub /etc/default/grub /etc/grub.d/00_header @@ -646,8 +648,8 @@ - - 2023-11-23 + + 2023-12-07 2.04 Packaging update Rune Morling