New entries could also be appended by the new add_boot_entry function
in custom.cfg like
add_boot_entry /android-7.1-r2 "Android-x86 7.1-r2" quiet
-# $1 Title
-# $2... Kernel cmdline
-function add_entry {
- menuentry "OS_TITLE VER $1" "$@" --class android-x86 {
- shift 2
+# $1 Kernel dir
+# $2 Title
+# $3... Kernel cmdline
+function add_boot_entry {
+ menuentry "$2" "$@" --class android-x86 {
savedefault
set root=$android
- linux $kdir/kernel CMDLINE $src $@
- initrd $kdir/initrd.img
+ if [ -e $2/kernel ]; then
+ true
+ else
+ search --no-floppy --set root -f $2/kernel
+ fi
+ set kd=$2
+ shift 3
+ linux $kd/kernel CMDLINE $src $@
+ initrd $kd/initrd.img
}
}
+# $1 Title
+# $2... Kernel cmdline
+function add_entry {
+ set title="OS_TITLE VER $1"
+ shift 1
+ add_boot_entry "$kdir" "$title" "$@"
+}
+
# $1 EFI to chainload
# $2 OS name
# $3 Class