dcavalca / rpms / grub2

Forked from rpms/grub2 3 years ago
Clone

Blame SOURCES/0096-Clean-up-dangling-references-to-grub-setup.patch

f96e0b
From d1a9a3ec88483b5f1aa1e4a6c8bc38d47efa73af Mon Sep 17 00:00:00 2001
f96e0b
From: Colin Watson <cjwatson@ubuntu.com>
f96e0b
Date: Sat, 12 Jan 2013 13:30:37 +0000
f96e0b
Subject: [PATCH 096/482] Clean up dangling references to grub-setup. Fixes
f96e0b
 Ubuntu bug #1082045.
f96e0b
f96e0b
* docs/grub.texi (Images): Refer generally to grub-install rather
f96e0b
than directly to grub-setup.
f96e0b
(Installing GRUB using grub-install): Remove direct reference to
f96e0b
grub-setup.
f96e0b
(Device map) Likewise.
f96e0b
(Invoking grub-install): Likewise.
f96e0b
* docs/man/grub-install.h2m (SEE ALSO): Likewise.
f96e0b
* docs/man/grub-mkimage.h2m (SEE ALSO): Likewise.
f96e0b
* util/grub-install.in (usage): Likewise.
f96e0b
f96e0b
* util/bash-completion.d/grub-completion.bash.in (_grub_setup):
f96e0b
Apply to grub-bios-setup and grub-sparc64-setup rather than to
f96e0b
grub-setup.
f96e0b
* configure.ac: Remove grub_setup output variable.
f96e0b
f96e0b
* docs/man/grub-bios-setup.h2m (NAME): Change name from grub-setup
f96e0b
to grub-bios-setup.
f96e0b
* docs/man/grub-sparc64-setup.h2m (NAME): Change name from
f96e0b
grub-setup to grub-sparc64-setup.
f96e0b
---
f96e0b
 ChangeLog                                      | 25 +++++++++++++++++++++++++
f96e0b
 configure.ac                                   |  1 -
f96e0b
 docs/grub.texi                                 | 24 ++++++++++++------------
f96e0b
 docs/man/grub-bios-setup.h2m                   |  2 +-
f96e0b
 docs/man/grub-install.h2m                      |  1 -
f96e0b
 docs/man/grub-mkimage.h2m                      |  1 -
f96e0b
 docs/man/grub-sparc64-setup.h2m                |  2 +-
f96e0b
 util/bash-completion.d/grub-completion.bash.in | 14 ++++++++++----
f96e0b
 util/grub-install.in                           |  4 ++--
f96e0b
 9 files changed, 51 insertions(+), 23 deletions(-)
f96e0b
f96e0b
diff --git a/ChangeLog b/ChangeLog
f96e0b
index 22b18b1..61bf8e7 100644
f96e0b
--- a/ChangeLog
f96e0b
+++ b/ChangeLog
f96e0b
@@ -1,3 +1,28 @@
f96e0b
+2013-01-12  Colin Watson  <cjwatson@ubuntu.com>
f96e0b
+
f96e0b
+	Clean up dangling references to grub-setup.
f96e0b
+	Fixes Ubuntu bug #1082045.
f96e0b
+
f96e0b
+	* docs/grub.texi (Images): Refer generally to grub-install rather
f96e0b
+	than directly to grub-setup.
f96e0b
+	(Installing GRUB using grub-install): Remove direct reference to
f96e0b
+	grub-setup.
f96e0b
+	(Device map) Likewise.
f96e0b
+	(Invoking grub-install): Likewise.
f96e0b
+	* docs/man/grub-install.h2m (SEE ALSO): Likewise.
f96e0b
+	* docs/man/grub-mkimage.h2m (SEE ALSO): Likewise.
f96e0b
+	* util/grub-install.in (usage): Likewise.
f96e0b
+
f96e0b
+	* util/bash-completion.d/grub-completion.bash.in (_grub_setup):
f96e0b
+	Apply to grub-bios-setup and grub-sparc64-setup rather than to
f96e0b
+	grub-setup.
f96e0b
+	* configure.ac: Remove grub_setup output variable.
f96e0b
+
f96e0b
+	* docs/man/grub-bios-setup.h2m (NAME): Change name from grub-setup
f96e0b
+	to grub-bios-setup.
f96e0b
+	* docs/man/grub-sparc64-setup.h2m (NAME): Change name from
f96e0b
+	grub-setup to grub-sparc64-setup.
f96e0b
+
f96e0b
 2013-01-11  Vladimir Serbinenko  <phcoder@gmail.com>
f96e0b
 
f96e0b
 	Import gcrypt public-key cryptography and implement signature checking.
f96e0b
diff --git a/configure.ac b/configure.ac
f96e0b
index dde954e..92b550a 100644
f96e0b
--- a/configure.ac
f96e0b
+++ b/configure.ac
f96e0b
@@ -64,7 +64,6 @@ grub_TRANSFORM([grub-probe])
f96e0b
 grub_TRANSFORM([grub-reboot])
f96e0b
 grub_TRANSFORM([grub-script-check])
f96e0b
 grub_TRANSFORM([grub-set-default])
f96e0b
-grub_TRANSFORM([grub-setup])
f96e0b
 grub_TRANSFORM([grub-sparc64-setup])
f96e0b
 
f96e0b
 # Optimization flag.  Allow user to override.
f96e0b
diff --git a/docs/grub.texi b/docs/grub.texi
f96e0b
index a92bd96..e75bae9 100644
f96e0b
--- a/docs/grub.texi
f96e0b
+++ b/docs/grub.texi
f96e0b
@@ -622,11 +622,11 @@ This install doesn't conflict with standard install as long as they are in
f96e0b
 separate directories.
f96e0b
 
f96e0b
 Note that @command{grub-install} is actually just a shell script and the
f96e0b
-real task is done by @command{grub-mkimage} and @command{grub-setup}.
f96e0b
-Therefore, you may run those commands directly to install GRUB, without
f96e0b
-using @command{grub-install}. Don't do that, however, unless you are very
f96e0b
-familiar with the internals of GRUB. Installing a boot loader on a running
f96e0b
-OS may be extremely dangerous.
f96e0b
+real task is done by other tools such as @command{grub-mkimage}. Therefore,
f96e0b
+you may run those commands directly to install GRUB, without using
f96e0b
+@command{grub-install}. Don't do that, however, unless you are very familiar
f96e0b
+with the internals of GRUB. Installing a boot loader on a running OS may be
f96e0b
+extremely dangerous.
f96e0b
 
f96e0b
 @node Making a GRUB bootable CD-ROM
f96e0b
 @section Making a GRUB bootable CD-ROM
f96e0b
@@ -688,8 +688,8 @@ storage devices.
f96e0b
 @section The map between BIOS drives and OS devices
f96e0b
 
f96e0b
 If the device map file exists, the GRUB utilities (@command{grub-probe},
f96e0b
-@command{grub-setup}, etc.) read it to map BIOS drives to OS devices.  This
f96e0b
-file consists of lines like this:
f96e0b
+etc.) read it to map BIOS drives to OS devices.  This file consists of lines
f96e0b
+like this:
f96e0b
 
f96e0b
 @example
f96e0b
 (@var{device}) @var{file}
f96e0b
@@ -2283,8 +2283,8 @@ bytes.
f96e0b
 The sole function of @file{boot.img} is to read the first sector of the core
f96e0b
 image from a local disk and jump to it.  Because of the size restriction,
f96e0b
 @file{boot.img} cannot understand any file system structure, so
f96e0b
-@command{grub-setup} hardcodes the location of the first sector of the core
f96e0b
-image into @file{boot.img} when installing GRUB.
f96e0b
+@command{grub-install} hardcodes the location of the first sector of the
f96e0b
+core image into @file{boot.img} when installing GRUB.
f96e0b
 
f96e0b
 @item diskboot.img
f96e0b
 This image is used as the first sector of the core image when booting from a
f96e0b
@@ -4689,9 +4689,9 @@ GRUB.
f96e0b
 @node Invoking grub-install
f96e0b
 @chapter Invoking grub-install
f96e0b
 
f96e0b
-The program @command{grub-install} installs GRUB on your drive using
f96e0b
-@command{grub-mkimage} and (on some platforms) @command{grub-setup}.  You
f96e0b
-must specify the device name on which you want to install GRUB, like this:
f96e0b
+The program @command{grub-install} generates a GRUB core image using
f96e0b
+@command{grub-mkimage} and installs it on your system.  You must specify the
f96e0b
+device name on which you want to install GRUB, like this:
f96e0b
 
f96e0b
 @example
f96e0b
 grub-install @var{install_device}
f96e0b
diff --git a/docs/man/grub-bios-setup.h2m b/docs/man/grub-bios-setup.h2m
f96e0b
index eebe3ef..ac6ede3 100644
f96e0b
--- a/docs/man/grub-bios-setup.h2m
f96e0b
+++ b/docs/man/grub-bios-setup.h2m
f96e0b
@@ -1,5 +1,5 @@
f96e0b
 [NAME]
f96e0b
-grub-setup \- set up a device to boot using GRUB
f96e0b
+grub-bios-setup \- set up a device to boot using GRUB
f96e0b
 [SEE ALSO]
f96e0b
 .BR grub-install (8),
f96e0b
 .BR grub-mkimage (1),
f96e0b
diff --git a/docs/man/grub-install.h2m b/docs/man/grub-install.h2m
f96e0b
index 2de371a..8cbbc87 100644
f96e0b
--- a/docs/man/grub-install.h2m
f96e0b
+++ b/docs/man/grub-install.h2m
f96e0b
@@ -3,5 +3,4 @@ grub-install \- install GRUB to a device
f96e0b
 [SEE ALSO]
f96e0b
 .BR grub-mkconfig (8),
f96e0b
 .BR grub-mkimage (1),
f96e0b
-.BR grub-setup (8),
f96e0b
 .BR grub-mkrescue (1)
f96e0b
diff --git a/docs/man/grub-mkimage.h2m b/docs/man/grub-mkimage.h2m
f96e0b
index ca08b0c..f0fbc2b 100644
f96e0b
--- a/docs/man/grub-mkimage.h2m
f96e0b
+++ b/docs/man/grub-mkimage.h2m
f96e0b
@@ -2,6 +2,5 @@
f96e0b
 grub-mkimage \- make a bootable image of GRUB
f96e0b
 [SEE ALSO]
f96e0b
 .BR grub-install (8),
f96e0b
-.BR grub-setup (8),
f96e0b
 .BR grub-mkrescue (1),
f96e0b
 .BR grub-mknetdir (8)
f96e0b
diff --git a/docs/man/grub-sparc64-setup.h2m b/docs/man/grub-sparc64-setup.h2m
f96e0b
index eebe3ef..18f803a 100644
f96e0b
--- a/docs/man/grub-sparc64-setup.h2m
f96e0b
+++ b/docs/man/grub-sparc64-setup.h2m
f96e0b
@@ -1,5 +1,5 @@
f96e0b
 [NAME]
f96e0b
-grub-setup \- set up a device to boot using GRUB
f96e0b
+grub-sparc64-setup \- set up a device to boot using GRUB
f96e0b
 [SEE ALSO]
f96e0b
 .BR grub-install (8),
f96e0b
 .BR grub-mkimage (1),
f96e0b
diff --git a/util/bash-completion.d/grub-completion.bash.in b/util/bash-completion.d/grub-completion.bash.in
f96e0b
index 5f4b249..44bf135 100644
f96e0b
--- a/util/bash-completion.d/grub-completion.bash.in
f96e0b
+++ b/util/bash-completion.d/grub-completion.bash.in
f96e0b
@@ -252,10 +252,16 @@ _grub_setup () {
f96e0b
         _filedir
f96e0b
     fi
f96e0b
 }
f96e0b
-__grub_setup_program="@grub_setup@"
f96e0b
-have ${__grub_setup_program} && \
f96e0b
- complete -F _grub_setup -o filenames ${__grub_setup_program}
f96e0b
-unset __grub_setup_program
f96e0b
+
f96e0b
+__grub_bios_setup_program="@grub_bios_setup@"
f96e0b
+have ${__grub_bios_setup_program} && \
f96e0b
+ complete -F _grub_setup -o filenames ${__grub_bios_setup_program}
f96e0b
+unset __grub_bios_setup_program
f96e0b
+
f96e0b
+__grub_sparc64_setup_program="@grub_sparc64_setup@"
f96e0b
+have ${__grub_sparc64_setup_program} && \
f96e0b
+ complete -F _grub_setup -o filenames ${__grub_sparc64_setup_program}
f96e0b
+unset __grub_sparc64_setup_program
f96e0b
 
f96e0b
 
f96e0b
 #
f96e0b
diff --git a/util/grub-install.in b/util/grub-install.in
f96e0b
index 218bbd9..aac27c7 100644
f96e0b
--- a/util/grub-install.in
f96e0b
+++ b/util/grub-install.in
f96e0b
@@ -114,8 +114,8 @@ echo
f96e0b
 gettext "INSTALL_DEVICE must be system device filename.";echo
f96e0b
 echo
f96e0b
 
f96e0b
-gettext_printf "%s copies GRUB images into %s, and uses grub-setup
f96e0b
-to install grub into the boot sector.\n" "$self" "$grubdir";echo
f96e0b
+gettext_printf "%s copies GRUB images into %s.  On some platforms, it
f96e0b
+may also install GRUB into the boot sector.\n" "$self" "$grubdir";echo
f96e0b
 echo
f96e0b
 gettext "Report bugs to <bug-grub@gnu.org>."; echo
f96e0b
 }
f96e0b
-- 
f96e0b
1.8.2.1
f96e0b