From c746513893742e75578d44773612de8408d118de Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 14 Feb 2011 16:20:00 +0100 Subject: Making sure to correctly deference syslinux theme files when building chrooted. --- scripts/build/lb_binary_syslinux | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'scripts') diff --git a/scripts/build/lb_binary_syslinux b/scripts/build/lb_binary_syslinux index b6b2c0aee..e6f137872 100755 --- a/scripts/build/lb_binary_syslinux +++ b/scripts/build/lb_binary_syslinux @@ -58,8 +58,6 @@ case "${LB_BUILD_WITH_CHROOT}" in # Installing depends Install_package - - _PREFIX="chroot" ;; esac @@ -83,7 +81,19 @@ esac # Copying files mkdir -p ${_SUFFIX} -cp -aL ${_PREFIX}/usr/share/syslinux/themes/${LB_SYSLINUX_THEME}/${_BOOTLOADER}-live/* ${_SUFFIX} + +case "${LB_BUILD_WITH_CHROOT}" in + true) + # Copy in two steps since the theme can have absolute symlinks and would therefore not be dereferenced correctly + Chroot chroot "cp -aL /usr/share/syslinux/themes/${LB_SYSLINUX_THEME}/${_BOOTLOADER}-live /root/tmp" + mv chroot/root/tmp/* ${_SUFFIX} + rmdir chroot/root/tmp + ;; + + false) + cp -aL /usr/share/syslinux/themes/${LB_SYSLINUX_THEME}/${_BOOTLOADER}-live/* ${_SUFFIX} + ;; +esac # Configuring files if [ -e ${_SUFFIX}/live.cfg ] -- cgit v1.2.3