os-prober/os-prober-gentoo-fix.patch
Hedayat Vatankhah 8cef6cc5ea Update to upstream version 1.68, bug #1267779
- Support a case where a kernel named vmlinuz/x is used under Gentoo, bug #1223237
2015-10-21 00:08:28 +03:30

14 lines
841 B
Diff

Index: os-prober/linux-boot-probes/mounted/common/90fallback
===================================================================
--- os-prober.orig/linux-boot-probes/mounted/common/90fallback
+++ os-prober/linux-boot-probes/mounted/common/90fallback
@@ -33,7 +33,7 @@ for kernpat in /vmlinuz /vmlinux /boot/v
# Dracut initramfses are named differently again.
initrdname3=$(echo "$kernfile" | sed "s/vmlinu[zx]/initramfs\*/" | sed 's/$/.img/')
# And Gentoo's also
- initrdname4=$(echo "$kernfile" | sed "s/kernel/initramfs\*/")
+ initrdname4=$(echo "$kernfile" | sed "s/kernel\|vmlinu[zx]/initramfs\*/")
foundinitrd=0
for initrd in $(eval ls "$initrdname" "$initrdname1" "$initrdname2" "$initrdname3" "$initrdname4" 2>/dev/null); do
if [ "$initrd" != "$kernfile" ] && [ -f "$initrd" ] && [ ! -L "$initrd" ]; then