From 7ffd2288d944840937f556bd56703ba381f4edcc Mon Sep 17 00:00:00 2001 From: jnqnfe Date: Thu, 15 Jan 2015 04:41:16 +0000 Subject: [PATCH] syslinux: add install menu entries only if including installer --- scripts/build/binary_syslinux | 8 ++++++++ share/bootloaders/extlinux/menu.cfg | 2 +- share/bootloaders/isolinux/menu.cfg | 2 +- share/bootloaders/pxelinux/menu.cfg | 2 +- share/bootloaders/syslinux/menu.cfg | 2 +- 5 files changed, 12 insertions(+), 4 deletions(-) diff --git a/scripts/build/binary_syslinux b/scripts/build/binary_syslinux index ba2b2edae..b85e56774 100755 --- a/scripts/build/binary_syslinux +++ b/scripts/build/binary_syslinux @@ -266,6 +266,14 @@ do fi done +# Replace placeholder for optional install menu entries include +if [ "${LB_DEBIAN_INSTALLER}" = "none" ]; then + rm -f "${_TARGET}"/install.cfg + sed -i "#@OPTIONAL_INSTALLER_INCLUDE@#d" "${_TARGET}"/menu.cfg +else + sed -i "s#@OPTIONAL_INSTALLER_INCLUDE@#include install.cfg#g" "${_TARGET}"/menu.cfg +fi + if [ -e "${_TARGET}/splash.svg" ] then case "${LB_BUILD_WITH_CHROOT}" in diff --git a/share/bootloaders/extlinux/menu.cfg b/share/bootloaders/extlinux/menu.cfg index a5a6727c8..b70ef5a2a 100644 --- a/share/bootloaders/extlinux/menu.cfg +++ b/share/bootloaders/extlinux/menu.cfg @@ -4,7 +4,7 @@ menu width 82 menu title Boot menu include stdmenu.cfg include live.cfg -include install.cfg +@OPTIONAL_INSTALLER_INCLUDE@ menu begin advanced menu label ^Advanced options menu title Advanced options diff --git a/share/bootloaders/isolinux/menu.cfg b/share/bootloaders/isolinux/menu.cfg index a5a6727c8..b70ef5a2a 100644 --- a/share/bootloaders/isolinux/menu.cfg +++ b/share/bootloaders/isolinux/menu.cfg @@ -4,7 +4,7 @@ menu width 82 menu title Boot menu include stdmenu.cfg include live.cfg -include install.cfg +@OPTIONAL_INSTALLER_INCLUDE@ menu begin advanced menu label ^Advanced options menu title Advanced options diff --git a/share/bootloaders/pxelinux/menu.cfg b/share/bootloaders/pxelinux/menu.cfg index a5a6727c8..b70ef5a2a 100644 --- a/share/bootloaders/pxelinux/menu.cfg +++ b/share/bootloaders/pxelinux/menu.cfg @@ -4,7 +4,7 @@ menu width 82 menu title Boot menu include stdmenu.cfg include live.cfg -include install.cfg +@OPTIONAL_INSTALLER_INCLUDE@ menu begin advanced menu label ^Advanced options menu title Advanced options diff --git a/share/bootloaders/syslinux/menu.cfg b/share/bootloaders/syslinux/menu.cfg index a5a6727c8..b70ef5a2a 100644 --- a/share/bootloaders/syslinux/menu.cfg +++ b/share/bootloaders/syslinux/menu.cfg @@ -4,7 +4,7 @@ menu width 82 menu title Boot menu include stdmenu.cfg include live.cfg -include install.cfg +@OPTIONAL_INSTALLER_INCLUDE@ menu begin advanced menu label ^Advanced options menu title Advanced options