mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-09 12:05:50 +03:00
install-grub: only try to loadfont if font is not null
This commit is contained in:
parent
52de38f5f4
commit
ab889c14b5
1 changed files with 14 additions and 12 deletions
|
@ -281,22 +281,24 @@ else {
|
||||||
else
|
else
|
||||||
insmod vbe
|
insmod vbe
|
||||||
fi
|
fi
|
||||||
insmod font
|
|
||||||
if loadfont " . $grubBoot->path . "/converted-font.pf2; then
|
|
||||||
insmod gfxterm
|
|
||||||
if [ \"\${grub_platform}\" = \"efi\" ]; then
|
|
||||||
set gfxmode=$gfxmodeEfi
|
|
||||||
set gfxpayload=keep
|
|
||||||
else
|
|
||||||
set gfxmode=$gfxmodeBios
|
|
||||||
set gfxpayload=text
|
|
||||||
fi
|
|
||||||
terminal_output gfxterm
|
|
||||||
fi
|
|
||||||
";
|
";
|
||||||
|
|
||||||
if ($font) {
|
if ($font) {
|
||||||
copy $font, "$bootPath/converted-font.pf2" or die "cannot copy $font to $bootPath\n";
|
copy $font, "$bootPath/converted-font.pf2" or die "cannot copy $font to $bootPath\n";
|
||||||
|
$conf .= "
|
||||||
|
insmod font
|
||||||
|
if loadfont " . $grubBoot->path . "/converted-font.pf2; then
|
||||||
|
insmod gfxterm
|
||||||
|
if [ \"\${grub_platform}\" = \"efi\" ]; then
|
||||||
|
set gfxmode=$gfxmodeEfi
|
||||||
|
set gfxpayload=keep
|
||||||
|
else
|
||||||
|
set gfxmode=$gfxmodeBios
|
||||||
|
set gfxpayload=text
|
||||||
|
fi
|
||||||
|
terminal_output gfxterm
|
||||||
|
fi
|
||||||
|
";
|
||||||
}
|
}
|
||||||
if ($splashImage) {
|
if ($splashImage) {
|
||||||
# Keeps the image's extension.
|
# Keeps the image's extension.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue