{grub2,console-setup}: make work with upstream unifont structure (#551023)

This commit is contained in:
Vladimír Čunát
2026-08-10 12:04:28 +00:00
committed by GitHub
2 changed files with 3 additions and 3 deletions

View File

@@ -26,6 +26,7 @@ stdenvNoCC.mkDerivation (finalAttrs: {
bdfresize
otf2bdf
perl
unifont
];
makeFlags = [ "prefix=${placeholder "out"}" ];
@@ -35,8 +36,7 @@ stdenvNoCC.mkDerivation (finalAttrs: {
postPatch = ''
patchShebangs .
substituteInPlace Fonts/Makefile --replace-fail '/usr/share/fonts/truetype/dejavu/' '${dejavu_fonts}/share/fonts/truetype/'
ln -s ${unifont}/share/fonts/unifont.bdf Fonts/bdf
substituteInPlace Fonts/Makefile --replace-fail 'rm -f $(fntdir)/bdf/unifont.bdf' ""
substituteInPlace Fonts/Makefile --replace-fail '/usr/share/unifont/' '${unifont.doc}/share/unifont/'
'';
preBuild = "make -j$NIX_BUILD_CORES bdf";

View File

@@ -670,7 +670,7 @@ stdenv.mkDerivation rec {
./bootstrap --no-git --gnulib-srcdir=${gnulib}
substituteInPlace ./configure --replace '/usr/share/fonts/unifont' '${unifont}/share/fonts'
substituteInPlace ./configure --replace-fail '/usr/share/fonts' '${unifont}/share/fonts'
''
# build-grub-mkfont is built & run during build, need to find freetype for buildPlatform
+ lib.optionalString (!lib.systems.equals stdenv.buildPlatform stdenv.hostPlatform) ''