6b2dd0f
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
f4c76c0
From: Peter Jones <pjones@redhat.com>
f4c76c0
Date: Mon, 14 Mar 2011 14:27:42 -0400
31cddd6
Subject: [PATCH] Don't say "GNU/Linux" in generated menus.
f4c76c0
e622855
[rharwood: say it even less]
f4c76c0
---
e622855
 grub-core/normal/main.c         | 2 +-
e622855
 tests/util/grub-shell-tester.in | 2 +-
e622855
 tests/util/grub-shell.in        | 2 +-
e622855
 util/grub.d/10_linux.in         | 4 ++--
e622855
 util/grub.d/20_linux_xen.in     | 4 ++--
e622855
 5 files changed, 7 insertions(+), 7 deletions(-)
f4c76c0
e622855
diff --git a/grub-core/normal/main.c b/grub-core/normal/main.c
e622855
index 7ca2e5400b..98372217ad 100644
e622855
--- a/grub-core/normal/main.c
e622855
+++ b/grub-core/normal/main.c
e622855
@@ -218,7 +218,7 @@ grub_normal_init_page (struct grub_term_output *term,
e622855
  
e622855
   grub_term_cls (term);
e622855
 
e622855
-  msg_formatted = grub_xasprintf (_("GNU GRUB  version %s"), PACKAGE_VERSION);
e622855
+  msg_formatted = grub_xasprintf (_("GRUB version %s"), PACKAGE_VERSION);
e622855
   if (!msg_formatted)
e622855
     return;
e622855
  
e622855
diff --git a/tests/util/grub-shell-tester.in b/tests/util/grub-shell-tester.in
e622855
index 8a87109b15..9a4319d4f4 100644
e622855
--- a/tests/util/grub-shell-tester.in
e622855
+++ b/tests/util/grub-shell-tester.in
e622855
@@ -56,7 +56,7 @@ for option in "$@"; do
e622855
 	usage
e622855
 	exit 0 ;;
e622855
     -v | --version)
e622855
-	echo "$0 (GNU GRUB ${PACKAGE_VERSION})"
e622855
+	echo "$0 (GRUB ${PACKAGE_VERSION})"
e622855
 	exit 0 ;;
e622855
     --modules=*)
e622855
 	ms=`echo "$option" | sed -e 's/--modules=//'`
e622855
diff --git a/tests/util/grub-shell.in b/tests/util/grub-shell.in
e622855
index 93e9f51484..ec1182bf93 100644
e622855
--- a/tests/util/grub-shell.in
e622855
+++ b/tests/util/grub-shell.in
e622855
@@ -209,7 +209,7 @@ for option in "$@"; do
e622855
 	usage
e622855
 	exit 0 ;;
e622855
     -v | --version)
e622855
-	echo "$0 (GNU GRUB ${PACKAGE_VERSION})"
e622855
+	echo "$0 (GRUB ${PACKAGE_VERSION})"
e622855
 	exit 0 ;;
e622855
     --trim)
e622855
 	trim=1
f4c76c0
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
e622855
index dc75a1c30b..4a499c53a6 100644
f4c76c0
--- a/util/grub.d/10_linux.in
f4c76c0
+++ b/util/grub.d/10_linux.in
f4c76c0
@@ -29,9 +29,9 @@ export TEXTDOMAINDIR="@localedir@"
f4c76c0
 CLASS="--class gnu-linux --class gnu --class os"
f4c76c0
 
f4c76c0
 if [ "x${GRUB_DISTRIBUTOR}" = "x" ] ; then
f4c76c0
-  OS=GNU/Linux
f4c76c0
+  OS="$(sed 's, release .*$,,g' /etc/system-release)"
f4c76c0
 else
f4c76c0
-  OS="${GRUB_DISTRIBUTOR} GNU/Linux"
f4c76c0
+  OS="${GRUB_DISTRIBUTOR}"
f4c76c0
   CLASS="--class $(echo ${GRUB_DISTRIBUTOR} | tr 'A-Z' 'a-z' | cut -d' ' -f1|LC_ALL=C sed 's,[^[:alnum:]_],_,g') ${CLASS}"
f4c76c0
 fi
f4c76c0
 
f4c76c0
diff --git a/util/grub.d/20_linux_xen.in b/util/grub.d/20_linux_xen.in
e622855
index 3b1f470492..ada20775a1 100644
f4c76c0
--- a/util/grub.d/20_linux_xen.in
f4c76c0
+++ b/util/grub.d/20_linux_xen.in
f4c76c0
@@ -29,9 +29,9 @@ export TEXTDOMAINDIR="@localedir@"
f4c76c0
 CLASS="--class gnu-linux --class gnu --class os --class xen"
f4c76c0
 
f4c76c0
 if [ "x${GRUB_DISTRIBUTOR}" = "x" ] ; then
f4c76c0
-  OS=GNU/Linux
f4c76c0
+  OS="$(sed 's, release .*$,,g' /etc/system-release)"
f4c76c0
 else
f4c76c0
-  OS="${GRUB_DISTRIBUTOR} GNU/Linux"
f4c76c0
+  OS="${GRUB_DISTRIBUTOR}"
f4c76c0
   CLASS="--class $(echo ${GRUB_DISTRIBUTOR} | tr 'A-Z' 'a-z' | cut -d' ' -f1|LC_ALL=C sed 's,[^[:alnum:]_],_,g') ${CLASS}"
f4c76c0
 fi
f4c76c0