summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorintrigeri <intrigeri@boum.org>2015-11-10 14:30:05 +0000
committerintrigeri <intrigeri@boum.org>2015-11-10 14:30:05 +0000
commit53dd9fcb5539769f21b17dce1f9ec160f6f6a2c7 (patch)
treeee61fc55faf546c908cae424749c4cda86b70b8e
parent870bf2843eb08823bb656e782957e9407a67a4b9 (diff)
Delete leftovers of the hybrid MBR dance, that we stopped doing back in July.
-rwxr-xr-xtails_installer/creator.py30
-rwxr-xr-xtails_installer/gui.py2
2 files changed, 0 insertions, 32 deletions
diff --git a/tails_installer/creator.py b/tails_installer/creator.py
index 2e68f51..ae5f410 100755
--- a/tails_installer/creator.py
+++ b/tails_installer/creator.py
@@ -223,36 +223,6 @@ class TailsInstallerCreator(object):
+ [ self.drive['parent'] ])
self.popen(cmd, shell=False)
- def _gdisk_script(self, gdisk_cmds):
- cmd = [ '/sbin/gdisk', self.drive['device'] ]
- stdin = tempfile.TemporaryFile(mode='w')
- stdin.write('\n'.join(gdisk_cmds) + '\n')
- stdin.seek(0)
- self.popen(cmd, shell=False, stdin=stdin)
-
- def create_hybrid_mbr(self):
- # only relevant with OS that don't know how to access partitions on GPT
- self._gdisk_script([ 'r', # recovery and transformation options
- 'h', # make hybrid MBR
- '1', # add first partition
- 'N', # no EFI GPT (0xEE) partition
- '0c', # partition type (Win95 FAT32 LBA)
- 'N', # don't set the bootable flag
- 'N', # no protective partition
- 'w', # write table to disk and exit
- 'Y', # proceed, possibly destroying data
- ])
- self.flush_buffers(silent=True)
- time.sleep(3)
- self._get_object().props.block.call_rescan_sync(GLib.Variant('a{sv}', None))
-
- def remove_hybrid_mbr(self):
- self._gdisk_script([ 'x', # extra functionality
- 'n', # create a new protective MBR
- 'w', # write table to disk and exit
- 'Y', # proceed, possibly destroying data
- ])
-
def is_device_big_enough(self, deviceSize):
if (self.system_partition_size + self.min_persistence_partition_size) \
* 1024**2 <= deviceSize:
diff --git a/tails_installer/gui.py b/tails_installer/gui.py
index f6f8f41..3183016 100755
--- a/tails_installer/gui.py
+++ b/tails_installer/gui.py
@@ -198,7 +198,6 @@ class TailsInstallerThread(threading.Thread):
self.live.log.info('Clearing unreadable partition table.')
self.live.clear_all_partition_tables()
self.live.partition_device()
- # self.live.create_hybrid_mbr()
self.rescan_devices(force_partitions=True)
self.live.switch_drive_to_system_partition()
self.live.format_device()
@@ -250,7 +249,6 @@ class TailsInstallerThread(threading.Thread):
if self.parent.opts.partition:
self.live.switch_back_to_full_drive()
- # self.live.remove_hybrid_mbr()
self.live.reset_mbr()
self.live.flush_buffers()