diff options
Diffstat (limited to 'scripts/build/binary_syslinux')
-rwxr-xr-x | scripts/build/binary_syslinux | 21 |
1 files changed, 17 insertions, 4 deletions
diff --git a/scripts/build/binary_syslinux b/scripts/build/binary_syslinux index 3df40d0d5..72ca2e7e1 100755 --- a/scripts/build/binary_syslinux +++ b/scripts/build/binary_syslinux @@ -80,18 +80,22 @@ esac # User config replacement/additional files _SOURCE_USER="config/bootloaders/${_BOOTLOADER}" +_SOURCE_USER_COMMON="config/bootloaders/syslinux_common" if [ -n "${LIVE_BUILD}" ]; then _SOURCE="${LIVE_BUILD}/share/bootloaders/${_BOOTLOADER}" + _SOURCE_COMMON="${LIVE_BUILD}/share/bootloaders/syslinux_common" else _SOURCE="/usr/share/live/build/bootloaders/${_BOOTLOADER}" + _SOURCE_COMMON="/usr/share/live/build/bootloaders/syslinux_common" fi # Checking depends Check_package chroot /usr/lib/$(echo ${_BOOTLOADER} | tr [a-z] [A-Z]) ${_BOOTLOADER} Check_package chroot /usr/lib/syslinux syslinux-common -if ls "${_SOURCE}"/*.svg* > /dev/null 2>&1 || ls "${_SOURCE_USER}"/*.svg* > /dev/null 2>&1 +if ls "${_SOURCE}"/*.svg* > /dev/null 2>&1 || ls "${_SOURCE_COMMON}"/*.svg* > /dev/null 2>&1 || + ls "${_SOURCE_USER}"/*.svg* > /dev/null 2>&1 || ls "${_SOURCE_USER_COMMON}"/*.svg* > /dev/null 2>&1 then Check_package chroot /usr/bin/rsvg-convert librsvg2-bin fi @@ -106,11 +110,16 @@ Install_package case "${LB_BUILD_WITH_CHROOT}" in true) mkdir -p ${_TARGET} + mkdir -p chroot/root/${_BOOTLOADER} # Copy in two steps since the theme can have absolute symlinks and would therefore not be dereferenced correctly - cp -a ${_SOURCE} chroot/root + cp -a ${_SOURCE_COMMON}/* chroot/root/${_BOOTLOADER}/ + cp -af ${_SOURCE}/* chroot/root/${_BOOTLOADER}/ + if [ -e "${_SOURCE_USER_COMMON}" ]; then + cp -af ${_SOURCE_USER_COMMON}/* chroot/root/${_BOOTLOADER}/ + fi if [ -e "${_SOURCE_USER}" ]; then - cp -af ${_SOURCE_USER} chroot/root + cp -af ${_SOURCE_USER}/* chroot/root/${_BOOTLOADER}/ fi Chroot chroot cp -aL /root/${_BOOTLOADER} /root/${_BOOTLOADER}.tmp > /dev/null 2>&1 || true cp -a chroot/root/${_BOOTLOADER}.tmp/* ${_TARGET} @@ -120,7 +129,11 @@ case "${LB_BUILD_WITH_CHROOT}" in false) mkdir -p ${_TARGET} - cp -aL ${_SOURCE}/* ${_TARGET} > /dev/null 2>&1 || true + cp -aL ${_SOURCE_COMMON}/* ${_TARGET} > /dev/null 2>&1 || true + cp -aLf ${_SOURCE}/* ${_TARGET} > /dev/null 2>&1 || true + if [ -e "${_SOURCE_USER_COMMON}" ]; then + cp -aLf ${_SOURCE_USER_COMMON}/* ${_TARGET} > /dev/null 2>&1 || true + fi if [ -e "${_SOURCE_USER}" ]; then cp -aLf ${_SOURCE_USER}/* ${_TARGET} > /dev/null 2>&1 || true fi |