[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#505750: d-i: allow user to return to syslinux VESA menu from help screens

On Friday 14 November 2008, Frans Pop wrote:
> The attached patch makes it possible to return to the graphical
> syslinux boot menu after viewing the help screens by typing 'menu'.

A small additional change is needed to make this work with netboot (using 
pxe). Problem was that we now have two moments where we look for the 
config file:
- pxe looks in pxelinux.cfg/ when things first get loaded
- syslinux looks in boot-screens when the user types menu

I fixed it by using a syslink. I could alternatively have fixed it by 
specifying the correct path in prompt.cfg, but IMO that would have made 
things much more complex.

This change should still be compatible with any existing setups.

diff --git a/installer/build/config/x86.cfg b/installer/build/config/x86.cfg
index 75bdd5c..501013b 100644
--- a/installer/build/config/x86.cfg
+++ b/installer/build/config/x86.cfg
@@ -272,9 +272,6 @@ arch_netboot_dir:
 	$(foreach file,$(shell syslinux-cfgs "$(INITRD_GTK)"), \
 		outfile=$(TEMP_NETBOOT_DIR)/$(BOOT_SCREEN_DIR)/`basename $(file)`; \
-		if [ `basename $(file)` = syslinux.cfg ]; then \
-			outfile=$(TEMP_NETBOOT_DIR)/$(NETBOOT_PATH)/pxelinux.cfg/default; \
-		fi; \
 		[ "$(BOOTMENU_BEEP)" = y ] && beep="$$(printf '\a')"; \
 		cat $(file) \
 		| bootvars-subst MEDIA_TYPE "$(MEDIA_TYPE)" \
@@ -288,7 +285,10 @@ arch_netboot_dir:
 			SYSLINUX_CFG syslinux.cfg \
 		> $$outfile; \
+	# This is where pxelinux looks for the config file.
+	ln -sf ../boot-screens/syslinux.cfg \
+		$(TEMP_NETBOOT_DIR)/$(NETBOOT_PATH)/pxelinux.cfg/default
 	# This symlink is required as pxelinux always looks in the root
 	# of the tftp server for its config.
 	rm -f $(TEMP_NETBOOT_DIR)/pxelinux.cfg

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply to: