]> TLD Linux GIT Repositories - packages/grub2.git/blob - choose-preferred-initrd.patch
- info how to generate new tarball
[packages/grub2.git] / choose-preferred-initrd.patch
1 diff -dur -x '*.orig' grub-2.00.git20131218.orig/util/grub-mkconfig.in grub-2.00.git20131218/util/grub-mkconfig.in
2 --- grub-2.00.git20131218.orig/util/grub-mkconfig.in    2013-12-18 14:44:31.000000000 +0100
3 +++ grub-2.00.git20131218/util/grub-mkconfig.in 2013-12-18 14:45:37.000000000 +0100
4 @@ -255,7 +255,8 @@
5    GRUB_ENABLE_CRYPTODISK \
6    GRUB_BADRAM \
7    GRUB_OS_PROBER_SKIP_LIST \
8 -  GRUB_DISABLE_SUBMENU
9 +  GRUB_DISABLE_SUBMENU \
10 +  GRUB_PREFER_DRACUT
11  
12  if test "x${grub_cfg}" != "x"; then
13    rm -f "${grub_cfg}.new"
14 diff -dur -x '*.orig' grub-2.00.git20131218.orig/util/grub.d/10_linux.in grub-2.00.git20131218/util/grub.d/10_linux.in
15 --- grub-2.00.git20131218.orig/util/grub.d/10_linux.in  2013-12-18 14:44:31.000000000 +0100
16 +++ grub-2.00.git20131218/util/grub.d/10_linux.in       2013-12-18 14:44:49.000000000 +0100
17 @@ -198,10 +198,12 @@
18    linux_root_device_thisversion="${LINUX_ROOT_DEVICE}"
19  
20    initrd=
21 -  for i in "initrd.img-${version}" "initrd-${version}.img" "initrd-${version}.gz" \
22 -          "initrd-${version}" "initramfs-${version}.img" \
23 -          "initrd.img-${alt_version}" "initrd-${alt_version}.img" \
24 -          "initrd-${alt_version}" "initramfs-${alt_version}.img" \
25 +  if [ x"${GRUB_PREFER_DRACUT}" != "xtrue" ]; then
26 +         initrd_search_list="initrd.img-${version} initrd-${version}.img initrd-${version}.gz initrd-${version} initramfs-${version}.img initrd.img-${alt_version} initrd-${alt_version}.img initrd-${alt_version} initramfs-${alt_version}.img"
27 +  else
28 +         initrd_search_list="initramfs-${version}.img initrd.img-${version} initrd-${version}.img initrd-${version}.gz initrd-${version}  initramfs-${alt_version}.img initrd.img-${alt_version} initrd-${alt_version}.img initrd-${alt_version}"
29 +  fi
30 +  for i in $initrd_search_list \
31            "initramfs-genkernel-${version}" \
32            "initramfs-genkernel-${alt_version}" \
33            "initramfs-genkernel-${GENKERNEL_ARCH}-${version}" \
34 diff -dur -x '*.orig' grub-2.00.git20131218.orig/util/grub.d/20_linux_xen.in grub-2.00.git20131218/util/grub.d/20_linux_xen.in
35 --- grub-2.00.git20131218.orig/util/grub.d/20_linux_xen.in      2013-12-18 14:44:31.000000000 +0100
36 +++ grub-2.00.git20131218/util/grub.d/20_linux_xen.in   2013-12-18 14:44:49.000000000 +0100
37 @@ -207,10 +207,12 @@
38         linux_root_device_thisversion="${LINUX_ROOT_DEVICE}"
39  
40         initrd=
41 -       for i in "initrd.img-${version}" "initrd-${version}.img" "initrd-${version}.gz" \
42 -          "initrd-${version}" "initramfs-${version}.img" \
43 -          "initrd.img-${alt_version}" "initrd-${alt_version}.img" \
44 -          "initrd-${alt_version}" "initramfs-${alt_version}.img" \
45 +       if [ x"${GRUB_PREFER_DRACUT}" != "xtrue" ]; then
46 +           initrd_search_list="initrd.img-${version} initrd-${version}.img initrd-${version}.gz initrd-${version} initramfs-${version}.img initrd.img-${alt_version} initrd-${alt_version}.img initrd-${alt_version} initramfs-${alt_version}.img"
47 +       else
48 +           initrd_search_list="initramfs-${version}.img initrd.img-${version} initrd-${version}.img initrd-${version}.gz initrd-${version}  initramfs-${alt_version}.img initrd.img-${alt_version} initrd-${alt_version}.img initrd-${alt_version}"
49 +       fi
50 +       for i in $initrd_search_list \
51            "initramfs-genkernel-${version}" \
52            "initramfs-genkernel-${alt_version}" \
53            "initramfs-genkernel-${GENKERNEL_ARCH}-${version}" \