From faf4eed0066294cad5e0b71f5a9315f42abd9a33 Mon Sep 17 00:00:00 2001 From: Dubiousjim Date: Sat, 29 Jun 2013 16:41:25 -0400 Subject: main/syslinux: add reboot entry We don't install /boot/reboot.c32, but if it's present (it can be copied from /usr/share/syslinux/reboot.c32), we add a menu entry for it---just like with memtest. Add a comment to /etc/update-extlinux.conf stating this. It'd already be possible to get a reboot entry using the /etc/update-extlinux.d/ folder, but this patch provides a more intelligent framework with nicer layout. The syslinux sourceball also provides a shutdown module, but I couldn't get this to work and looking at the sources reveals it to be for machines with APM enabled. Not sure how many machines that applies to anymore. --- main/syslinux/update-extlinux | 7 +++++++ main/syslinux/update-extlinux.conf | 4 ++++ 2 files changed, 11 insertions(+) (limited to 'main/syslinux') diff --git a/main/syslinux/update-extlinux b/main/syslinux/update-extlinux index 0dc360170b..1c5fc5c455 100755 --- a/main/syslinux/update-extlinux +++ b/main/syslinux/update-extlinux @@ -151,6 +151,13 @@ if [ -f "/boot/memtest" ]; then echo "" >> $conf.new fi +if [ -f "/boot/reboot.c32" ]; then + everbose "Found reboot" + echo "LABEL reboot" >> $conf.new + echo " MENU LABEL Reboot" >> $conf.new + echo " COM32 reboot.c32" >> $conf.new + echo "" >> $conf.new +fi if [ "$overwrite" != "1" ]; then diff --git a/main/syslinux/update-extlinux.conf b/main/syslinux/update-extlinux.conf index 59f9e60c40..5a36a1f1c1 100644 --- a/main/syslinux/update-extlinux.conf +++ b/main/syslinux/update-extlinux.conf @@ -42,3 +42,7 @@ default=grsec # options to hand to xen hypervisor, useful ones are: # dom0_mem=256M (give domain-0 environment 256M ram) xen_opts=dom0_mem=256M + +# if you copy /usr/share/syslinux/reboot.c32 to /boot/, a menu entry will be auto-generated for it + +# a menu entry will also be auto-generated for /boot/memtest, if you download it and install it -- cgit v1.2.3