[packages/grub2] - fix preferred initrd patch

baggins baggins at pld-linux.org
Mon Apr 15 11:51:46 CEST 2013


commit ab6bbe27f5d032c494dd93fe0defb22776c41371
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Mon Apr 15 11:49:36 2013 +0200

    - fix preferred initrd patch

 choose-preferred-initrd.patch | 33 +++++++++++++++++++++++----------
 grub2.spec                    |  2 +-
 2 files changed, 24 insertions(+), 11 deletions(-)
---
diff --git a/grub2.spec b/grub2.spec
index 1fd355f..3044987 100644
--- a/grub2.spec
+++ b/grub2.spec
@@ -305,7 +305,7 @@ Motyw starfield dla GRUB-a.
 %patch18 -p1
 %patch19 -p1
 %patch20 -p1
-#%patch21 -p1
+%patch21 -p1
 
 %if "%{cc_version}" < "3.4"
 grep -rl -- -Wno-missing-field-initializers . | xargs %{__sed} -i -e 's,-Wno-missing-field-initializers,,'
diff --git a/choose-preferred-initrd.patch b/choose-preferred-initrd.patch
index bd1c06f..f84e380 100644
--- a/choose-preferred-initrd.patch
+++ b/choose-preferred-initrd.patch
@@ -12,7 +12,7 @@
    rm -f "${grub_cfg}.new"
 --- grub-2.00/util/grub.d/10_linux.in~	2013-04-15 00:03:09.162253769 +0200
 +++ grub-2.00/util/grub.d/10_linux.in	2013-04-15 01:38:26.992181771 +0200
-@@ -191,10 +191,18 @@
+@@ -191,10 +191,12 @@
    linux_root_device_thisversion="${LINUX_ROOT_DEVICE}"
  
    initrd=
@@ -20,18 +20,31 @@
 -	   "initrd-${version}" "initramfs-${version}.img" \
 -	   "initrd.img-${alt_version}" "initrd-${alt_version}.img" \
 -	   "initrd-${alt_version}" "initramfs-${alt_version}.img" \
-+  if [ x"${GRUB_PREFER_DRACUT}" = "x" ]; then
-+	  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" \
++  if [ x"${GRUB_PREFER_DRACUT}" != "xtrue" ]; then
++	  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"
 +  else
-+	  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}"
++	  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}"
 +  fi
 +  for i in $initrd_search_list \
  	   "initramfs-genkernel-${version}" \
  	   "initramfs-genkernel-${alt_version}" \
  	   "initramfs-genkernel-${GENKERNEL_ARCH}-${version}" \
+--- grub-2.00/util/grub.d/20_linux_xen.in~	2013-04-15 11:47:30.852286811 +0200
++++ grub-2.00/util/grub.d/20_linux_xen.in	2013-04-15 11:49:05.606550816 +0200
+@@ -212,10 +212,12 @@
+ 	linux_root_device_thisversion="${LINUX_ROOT_DEVICE}"
+ 
+ 	initrd=
+-	for i in "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" \
++	if [ x"${GRUB_PREFER_DRACUT}" != "xtrue" ]; then
++	    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"
++	else
++	    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}"
++	fi
++	for i in $initrd_search_list \
+ 	   "initramfs-genkernel-${version}" \
+ 	   "initramfs-genkernel-${alt_version}" \
+ 	   "initramfs-genkernel-${GENKERNEL_ARCH}-${version}" \
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/grub2.git/commitdiff/51d4e70010f5105d608ec8769270eaa1cd711101



More information about the pld-cvs-commit mailing list