Blame SOURCES/0066-util-grub-install.in-Follow-the-symbolic-link-parame.patch

f96e0b
From 421249fda0ae1b6138ccf14b34fa4c58fd3296d4 Mon Sep 17 00:00:00 2001
f96e0b
From: Paulo Flabiano Smorigo <pfsmorigo@br.ibm.com>
f96e0b
Date: Mon, 10 Dec 2012 17:07:01 +0100
f96e0b
Subject: [PATCH 066/482] 	* util/grub-install.in: Follow the symbolic
f96e0b
 link parameter added 	to the file command.
f96e0b
f96e0b
---
f96e0b
 ChangeLog            | 5 +++++
f96e0b
 util/grub-install.in | 2 +-
f96e0b
 2 files changed, 6 insertions(+), 1 deletion(-)
f96e0b
f96e0b
diff --git a/ChangeLog b/ChangeLog
f96e0b
index 0b57abf..e522078 100644
f96e0b
--- a/ChangeLog
f96e0b
+++ b/ChangeLog
f96e0b
@@ -1,3 +1,8 @@
f96e0b
+2012-12-10  Paulo Flabiano Smorigo <pfsmorigo@br.ibm.com>
f96e0b
+
f96e0b
+	* util/grub-install.in: Follow the symbolic link parameter added
f96e0b
+	to the file command.
f96e0b
+
f96e0b
 2012-12-10  Andrey Borzenkov <arvidjaar@gmail.com>
f96e0b
 
f96e0b
 	* util/grub-install.in: Remove stale TODO.
f96e0b
diff --git a/util/grub-install.in b/util/grub-install.in
f96e0b
index a2cf07a..9dc4e0b 100644
f96e0b
--- a/util/grub-install.in
f96e0b
+++ b/util/grub-install.in
f96e0b
@@ -748,7 +748,7 @@ elif [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = "i386-ieee1275" ]
f96e0b
 	       exit 1
f96e0b
         fi
f96e0b
 
f96e0b
-        if [ "$(file -s "${install_device}" -b | awk '{ print $1 }')" = ELF ] || [ x$("${grub_probe}" -m "${device_map}" -d "${install_device}" -t zero_check) = xtrue ]; then
f96e0b
+        if [ "$(file -s -b -L "${install_device}" | awk '{ print $1 }')" = ELF ] || [ x$("${grub_probe}" -m "${device_map}" -d "${install_device}" -t zero_check) = xtrue ]; then
f96e0b
 	        dd if="${grubdir}/${grub_modinfo_target_cpu}-$grub_modinfo_platform/core.${imgext}" of="${install_device}" status=noxfer || {
f96e0b
 	        gettext "Failed to copy Grub to the PReP partition." 1>&2
f96e0b
 	            echo 1>&2
f96e0b
-- 
f96e0b
1.8.2.1
f96e0b