[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#488111: support for installing GRUB without blocklists on GPT



On Fri, Jun 27, 2008 at 12:57:31AM +0200, Frans Pop wrote:
> On Thursday 26 June 2008, Robert Millan wrote:
> > > Should the description "BIOS boot area:" not also mention grub in
> > > some way? Something like "Reserve BIOS boot area for GRUB:" (although
> > > that may already be a bit long for this dialog)?
> >
> > I don't think it's essential to mention GRUB; in theory, other
> > bootloaders could want to replace GRUB in this partition whenever
> > they're installed in MBR.
> 
> OK. In that case I think "Reserve BIOS boot area:" would have my vote.

Here's a new patch with all the requested changes.

-- 
Robert Millan

<GPLv2> I know my rights; I want my phone call!
<DRM> What good is a phone call… if you are unable to speak?
(as seen on /.)
Index: debian/partman-partitioning.templates
===================================================================
--- debian/partman-partitioning.templates	(revision 53798)
+++ debian/partman-partitioning.templates	(working copy)
@@ -221,6 +221,13 @@
 # :sl2:
 _Description: Name:
 
+Template: partman-partitioning/text/biosgrub
+Type: text
+# :sl3:
+# Setting to reserve a small part of the disk for use by BIOS-based bootloaders
+# such as GRUB.
+_Description: Reserve BIOS boot area:
+
 Template: partman-partitioning/text/bootable
 Type: text
 # :sl2:
Index: active_partition/_numbers
===================================================================
--- active_partition/_numbers	(revision 53798)
+++ active_partition/_numbers	(working copy)
@@ -1,6 +1,7 @@
 10 change_name
 65 toggle_bootable
 66 change_flags
+67 toggle_biosgrub
 80 resize
 83 copy
 87 delete
Index: active_partition/toggle_biosgrub/do_option
===================================================================
--- active_partition/toggle_biosgrub/do_option	(revision 53798)
+++ active_partition/toggle_biosgrub/do_option	(working copy)
@@ -8,22 +8,16 @@
 
 cd $dev
 
-if [ "$task" = bootable ]; then
+if [ "$task" = biosgrub ]; then
 	open_dialog PARTITION_INFO $id
 	read_line x1 x2 x3 type x5 x6 x7
 	close_dialog
-	if [ "$type" = logical ]; then
-		db_input high partman-partitioning/bootable_logical || true
-		db_go || exit 0
-		db_get partman-partitioning/bootable_logical
-		[ "$RET" = true ] || exit 0
-	fi
 fi
 
 new_flags=''
 open_dialog GET_FLAGS $id
 while { read_line flag; [ "$flag" ]; }; do
-	if [ "$flag" != boot ]; then
+	if [ "$flag" != bios_grub ]; then
 		if [ "$new_flags" ]; then
 			new_flags="$new_flags
 $flag"
@@ -34,9 +28,9 @@
 done
 close_dialog
 
-if [ $task = bootable ]; then
+if [ $task = biosgrub ]; then
 	new_flags="$new_flags
-boot"
+bios_grub"
 fi
 
 open_dialog SET_FLAGS $id
Index: active_partition/toggle_biosgrub/choices
===================================================================
--- active_partition/toggle_biosgrub/choices	(revision 53798)
+++ active_partition/toggle_biosgrub/choices	(working copy)
@@ -7,33 +7,33 @@
 
 cd $dev
 
-valid_boot=no
+valid_biosgrub=no
 open_dialog VALID_FLAGS $id
 while { read_line flag; [ "$flag" ]; }; do
-	if [ "$flag" = boot ]; then
-		valid_boot=yes
+	if [ "$flag" = bios_grub ]; then
+		valid_biosgrub=yes
 	fi
 done
 close_dialog
 
-[ $valid_boot = yes ] || exit 0
+[ $valid_biosgrub = yes ] || exit 0
 
-bootable=no
+biosgrub=no
 open_dialog GET_FLAGS $id
 while { read_line flag; [ "$flag" ]; }; do
-	if [ "$flag" = boot ]; then
-		bootable=yes
+	if [ "$flag" = bios_grub ]; then
+		biosgrub=yes
 	fi
 done
 close_dialog
 
-db_metaget partman-partitioning/text/bootable description
+db_metaget partman-partitioning/text/biosgrub description
 description=$(stralign -25 "$RET")
 
-if [ $bootable = yes ]; then
+if [ $biosgrub = yes ]; then
 	db_metaget partman-partitioning/text/on description
-	printf "unbootable\t%s%s\n" "$description" "${RET}"
+	printf "nobiosgrub\t%s%s\n" "$description" "${RET}"
 else
 	db_metaget partman-partitioning/text/off description
-	printf "bootable\t%s%s\n" "$description" "${RET}"
+	printf "biosgrub\t%s%s\n" "$description" "${RET}"
 fi

Reply to: