Skip to content

Commit

Permalink
Merge pull request #4 from marcsello/dev
Browse files Browse the repository at this point in the history
Added bootloader customizations
  • Loading branch information
marcsello authored Jan 31, 2021
2 parents 18154d1 + fc9e5ff commit 9a42725
Show file tree
Hide file tree
Showing 34 changed files with 999 additions and 1 deletion.
5 changes: 4 additions & 1 deletion config/binary
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,10 @@ LB_BOOTAPPEND_INSTALL=""

# $LB_BOOTAPPEND_LIVE_FAILSAFE: set boot parameters
# (Default: empty)
LB_BOOTAPPEND_LIVE_FAILSAFE="boot=live components memtest noapic noapm nodma nomce nolapic nomodeset nosmp nosplash vga=normal"
# noautologin should be added here, because it does not work the standard way
# NOTE: grub-efi have the following values hard-coded because of a bug in live-build
# See config/bootloaders/grub-pc/grub.cfg
LB_BOOTAPPEND_LIVE_FAILSAFE="boot=live components noautologin memtest noapic noapm nodma nomce nolapic nomodeset nosmp nosplash vga=normal"

# $LB_BOOTLOADERS: set bootloaders
# (Default: syslinux,grub-efi)
Expand Down
Binary file added config/bootloaders/grub-pc/dejavu-bold-14.pf2
Binary file not shown.
Binary file added config/bootloaders/grub-pc/dejavu-bold-16.pf2
Binary file not shown.
65 changes: 65 additions & 0 deletions config/bootloaders/grub-pc/grub.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
set default=0

loadfont $prefix/dejavu-bold-16.pf2
loadfont $prefix/dejavu-bold-14.pf2
loadfont $prefix/unicode.pf2
set gfxmode=auto
insmod all_video
insmod gfxterm
insmod png

set timeout=30
set color_normal=light-gray/black
set color_highlight=white/black

if [ -e /isolinux/splash.png ]; then
# binary_syslinux modifies the theme file to point to the correct
# background picture
set theme=/boot/grub/live-theme/theme.txt
elif [ -e /boot/grub/splash.png ]; then
set theme=/boot/grub/live-theme/theme.txt
else
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
fi

terminal_output gfxterm

insmod play
play 960 440 1 0 4 440 1

# Live boot

menuentry "Debian Admin CD" {
linux KERNEL_LIVE APPEND_LIVE
initrd INITRD_LIVE
}

menuentry "Debian Admin CD With SSH Server" {
linux KERNEL_LIVE APPEND_LIVE withssh
initrd INITRD_LIVE
}

# Substituting LB_BOOTAPPEND_LIVE_FAILSAFE does not work, because live-build
# (binary_grub_cfg https://salsa.debian.org/live-team/live-build/-/blob/master/scripts/build/binary_grub_cfg#L247)
# Substitutes the middle part because of the backward compatibility
# This also causes @@-wrapped values failing to substitute
# A bug report should be submitted to live-team...

menuentry "Debian Admin CD Failsafe" {
linux KERNEL_LIVE boot=live components noautologin memtest noapic noapm nodma nomce nolapic nomodeset nosmp nosplash vga=normal
initrd INITRD_LIVE
}

submenu 'Tools' {

# Installer (if any)
LINUX_INSTALL

# More installer entries (if any)
LINUX_ADVANCED_INSTALL

# Memtest (if any)
MEMTEST

}
51 changes: 51 additions & 0 deletions config/bootloaders/grub-pc/live-theme/theme.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
desktop-image: "../splash.png"
title-color: "#ffffff"
title-font: "DejaVu Sans Bold 16"
title-text: "Live Boot Menu with GRUB"
message-font: "Unifont Regular 16"
terminal-font: "Unifont Regular 16"

#help bar at the bottom
+ label {
top = 100%-50
left = 0
width = 100%
height = 20
text = "@KEYMAP_SHORT@"
align = "center"
color = "#ffffff"
font = "DejaVu Sans Bold 14"
}

#boot menu
+ boot_menu {
left = 10%
width = 80%
top = 52%
height = 48%-80
item_color = "#a8a8a8"
item_font = "DejaVu Sans Bold 14"
selected_item_color= "#ffffff"
selected_item_font = "DejaVu Sans Bold 14"
item_height = 16
item_padding = 0
item_spacing = 4
icon_width = 0
icon_heigh = 0
item_icon_space = 0
}

#progress bar
+ progress_bar {
id = "__timeout__"
left = 15%
top = 100%-80
height = 16
width = 70%
font = "DejaVu Sans Regular 14"
text_color = "#000000"
fg_color = "#ffffff"
bg_color = "#a8a8a8"
border_color = "#ffffff"
text = "@TIMEOUT_NOTIFICATION_LONG@"
}
1 change: 1 addition & 0 deletions config/bootloaders/isolinux/hdt.c32
11 changes: 11 additions & 0 deletions config/bootloaders/isolinux/install.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
label install
menu label ^Debian Installer
linux /install/vmlinuz
initrd /install/initrd.gz
append vga=788 @APPEND_INSTALL@ --- quiet

label installgui
menu label ^Debian Graphical installer
linux /install/gtk/vmlinuz
initrd /install/gtk/initrd.gz
append video=vesa:ywrap,mtrr vga=788 @APPEND_INSTALL@ --- quiet
1 change: 1 addition & 0 deletions config/bootloaders/isolinux/isolinux.bin
4 changes: 4 additions & 0 deletions config/bootloaders/isolinux/isolinux.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
include menu.cfg
default vesamenu.c32
prompt 0
timeout 300
1 change: 1 addition & 0 deletions config/bootloaders/isolinux/ldlinux.c32
1 change: 1 addition & 0 deletions config/bootloaders/isolinux/libcom32.c32
1 change: 1 addition & 0 deletions config/bootloaders/isolinux/libgpl.c32
1 change: 1 addition & 0 deletions config/bootloaders/isolinux/libmenu.c32
1 change: 1 addition & 0 deletions config/bootloaders/isolinux/libutil.c32
18 changes: 18 additions & 0 deletions config/bootloaders/isolinux/live.cfg.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
label live-@FLAVOUR@
menu label ^Debian Admin CD
menu default
linux @LINUX@
initrd @INITRD@
append @APPEND_LIVE@

label live-@FLAVOUR@-ssh
menu label ^Debian Admin CD with SSH server
linux @LINUX@
initrd @INITRD@
append @APPEND_LIVE@ withssh

label live-@FLAVOUR@-failsafe
menu label ^Debian Admin CD Failsafe
linux @LINUX@
initrd @INITRD@
append @APPEND_LIVE_FAILSAFE@
17 changes: 17 additions & 0 deletions config/bootloaders/isolinux/menu.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
menu hshift 0
menu width 82

menu title Boot menu
include stdmenu.cfg
include live.cfg
menu begin tools
menu title Tools
include stdmenu.cfg
label mainmenu
menu label ^Back..
menu exit
include install.cfg
include tools.cfg
menu end

menu clear
Loading

0 comments on commit 9a42725

Please sign in to comment.