syslinux: Add grub-pc compatibility

Directory syslinux can exist if using memtest feature.
This commit is contained in:
Anton Midyukov 2021-02-10 00:19:20 +07:00
parent 1e2a05d9bc
commit 83109b6bc4
3 changed files with 17 additions and 5 deletions

View File

@ -3,9 +3,13 @@
# when the image sizes are finally known
# NB: install2_size, live_size, rescue_size get defined here
cd "$WORKDIR"
# validate just in case (see also stage1 Makefile)
if [ -z "$(find $WORKDIR/syslinux/*.cfg)" ]; then
echo "Warning: syslinux/*.cfg not found"
exit 0
fi
[ -d "syslinux" ] || exit 0
cd "$WORKDIR"
# apply size census while looking for potential squashfs images
find -maxdepth 1 -type f -size +1M \

View File

@ -3,9 +3,13 @@
# to add rescue image hash, if any
# (for propagator in forensic mode)
cd "$WORKDIR"
# validate just in case (see also stage1 Makefile)
if [ -z "$(find $WORKDIR/syslinux/*.cfg)" ]; then
echo "Warning: syslinux/*.cfg not found"
exit 0
fi
[ -d "syslinux" ] || exit 0
cd "$WORKDIR"
grep -qs "@rescue_hash@" syslinux/*.cfg || exit 0

View File

@ -1,6 +1,10 @@
#!/bin/sh
[ -d "$WORKDIR/syslinux" ] || exit 0
# validate just in case (see also stage1 Makefile)
if [ ! -f "$WORKDIR/syslinux/$GLOBAL_BOOTLOADER.cfg" ]; then
echo "Warning: syslinux/*.cfg not found"
exit 0
fi
gfxboot_datadir=/usr/share/gfxboot