PERFORCE change 88142 for review
soc-andrew
soc-andrew at FreeBSD.org
Tue Dec 13 12:50:05 PST 2005
http://perforce.freebsd.org/chv.cgi?CH=88142
Change 88142 by soc-andrew at soc-andrew_serv on 2005/12/13 20:49:03
Allow boot1 to be used rather than boot0
Affected files ...
.. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/270_install_bootblocks.lua#2 edit
.. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/storage.lua#5 edit
Differences ...
==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/270_install_bootblocks.lua#2 (text+ko) ====
@@ -21,6 +21,7 @@
local dataset = {
disk = raw_name,
boot0cfg = "Y",
+ boot0 = "Y",
packet = "N"
}
@@ -72,6 +73,12 @@
control = "checkbox"
},
{
+ id = "boot0",
+ name = _("Use boot menu?"),
+ short_desc = _("Install the boot0 menu bootblock"),
+ control = "checkbox"
+ },
+ {
id = "packet",
name = _("Packet mode?"),
short_desc = _("Select this to use 'packet mode' to boot the disk"),
@@ -109,6 +116,7 @@
if dataset.boot0cfg == "Y" then
dd = disk_ref[dataset.disk]
dd:cmds_install_bootblock(cmds,
+ (dataset.boot0 == "Y"),
(dataset.packet == "Y"))
end
end
==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/storage.lua#5 (text+ko) ====
@@ -1111,7 +1111,18 @@
--
-- Create commands to install a bootblock on this disk.
--
- method.cmds_install_bootblock = function(self, cmds, packet_mode)
+ method.cmds_install_bootblock = function(self, cmds, use_boot0, packet_mode)
+ if not use_boot0 then
+ cmds:add(
+ {
+ cmdline = "${root}${YES} | ${root}${FDISK} -B " ..
+ self:get_raw_device_name(),
+ failure = CmdChain.FAILURE_WARN,
+ tag = self
+ })
+ return
+ end
+
local o = " "
local s = " "
More information about the p4-projects
mailing list