summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sys-boot/os-prober/files/os-prober-1.79-handle-multiple-initrd-paths.patch')
-rw-r--r--sys-boot/os-prober/files/os-prober-1.79-handle-multiple-initrd-paths.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/sys-boot/os-prober/files/os-prober-1.79-handle-multiple-initrd-paths.patch b/sys-boot/os-prober/files/os-prober-1.79-handle-multiple-initrd-paths.patch
new file mode 100644
index 000000000000..0b477c17c362
--- /dev/null
+++ b/sys-boot/os-prober/files/os-prober-1.79-handle-multiple-initrd-paths.patch
@@ -0,0 +1,35 @@
+Backport handling of multiple initrd paths, like those needed by Manjaro
+installations. Note, it still requires resolution of
+https://savannah.gnu.org/bugs/index.php?47681 on grub's end.
+
+Commit: https://salsa.debian.org/installer-team/os-prober/-/commit/53b920e106f13acf87ef8a275161e20f94feeb8a
+
+--- a/linux-boot-probes/mounted/common/40grub2
++++ b/linux-boot-probes/mounted/common/40grub2
+@@ -78,11 +78,21 @@
+ fi
+ ;;
+ initrd)
+- initrd="$(echo "$2" | sed 's/(.*)//')"
+- # Initrd same.
+- if [ "$partition" != "$bootpart" ]; then
+- initrd="/boot$initrd"
+- fi
++ shift
++ initrd=""
++ for initrd_path in "$@"; do
++ # sed hack, as above
++ initrd_path="$(echo "$initrd_path" | sed 's/(.*)//')"
++ # Initrd same.
++ if [ "$partition" != "$bootpart" ]; then
++ initrd_path="/boot$initrd_path"
++ fi
++ if [ -z "$initrd" ]; then
++ initrd="$initrd_path"
++ else
++ initrd="$initrd $initrd_path"
++ fi
++ done
+ ;;
+ "}")
+ entry_result