# Grub modules to install
GRUB_MODULES=(
+ all_video
+ gfxmenu
iso9660
linux
linux16
cat > "${path}" <<EOF
# Bricklayer GRUB configuration
-# Select the first entry
-set default=0
+# Load font
+loadfont unicode
+
+terminal_output gfxterm
+insmod gfxmenu
# Try loading video output
-insmod efi_gop
-insmod efi_uga
-insmod video_bochs
-insmod video_cirrus
insmod all_video
-# Keep resolution selected by the BIOS
-set gfxpayload=keep
+# Select the first entry
+set default=0
# Wait for 60 seconds for the user to make a decision
set timeout=60
# Generate GRUB configuration
if ! make_grub_config "${tempdir}/boot/grub/grub.cfg" \
- "${PRETTY_NAME}" "${ID}" "${arch}"; then
+ "${PRETTY_NAME}" "${ID}" "${arch}" "${label}"; then
echo "Could not generate GRUB configuration" >&2
rm -rf "${tempdir}"
return 1
fi
+ mkdir -p "${tempdir}/boot/grub/fonts"
+
+ # Install GRUB fonts
+ local font
+ for font in unicode.pf2; do
+ if ! cp -- "${buildsystem}/usr/share/grub/${font}" \
+ "${tempdir}/boot/grub/fonts/${font}"; then
+ echo "Could not install font '${font}'" >&2
+ rm -rf "${tempdir}"
+ return 1
+ fi
+ done
+
# Master the ISO file
if ! xorriso "${args[@]}"; then
r=1