grub.cfg syslinux: support ESP and extlinux.conf
the so-called EFI System Partition (ESP) is used on many UEFI-based setups. some users may be migrating to libreboot, so let's support it. on BIOS setups, it would be e.g. /boot/syslinux/syslinux.conf on UEFI setups, it would be e.g. /boot/EFI/syslinux/syslinux.conf additionally, support scanning for extlinux.conf Signed-off-by: Leah Rowe <leah@libreboot.org>9020vga
parent
b817001e29
commit
eaa1341b9e
|
@ -71,16 +71,18 @@ function search_grub {
|
|||
|
||||
function try_isolinux_config {
|
||||
set root="${1}"
|
||||
for dir in '' /boot; do
|
||||
for dir in '' /boot /EFI; do
|
||||
if [ -f "${dir}"/isolinux/isolinux.cfg ]; then
|
||||
syslinux_configfile -i "${dir}"/isolinux/isolinux.cfg
|
||||
elif [ -f "${dir}"/syslinux/syslinux.cfg ]; then
|
||||
syslinux_configfile -s "${dir}"/syslinux/syslinux.cfg
|
||||
elif [ -f "${dir}"/syslinux/extlinux.conf ]; then
|
||||
syslinux_configfile -s "${dir}"/syslinux/extlinux.conf
|
||||
fi
|
||||
done
|
||||
}
|
||||
function search_isolinux {
|
||||
echo "\nAttempting to parse isolinux/syslinux config from '${1}' devices"
|
||||
echo "\nAttempting to parse iso/sys/extlinux config from '${1}' devices"
|
||||
for i in 0 1 2 3 4 5 6 7 8 9 10 11; do
|
||||
for part in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20; do
|
||||
try_isolinux_config "(${1}${i},${part})"
|
||||
|
|
Loading…
Reference in New Issue