Use pyparted to check for bootflag [Closes: issue1248] mika/bootflag_with_pyparted
authorMichael Prokop <mika@grml.org>
Wed, 25 Sep 2013 12:54:06 +0000 (14:54 +0200)
committerMichael Prokop <mika@grml.org>
Wed, 25 Sep 2013 12:59:57 +0000 (14:59 +0200)
commit360632e096cbcd38d025d610cd64ce3fbb45c131
treefba6eeb8e630ef74b7e592e56cb50249a7474769
parentbb8723484d9384bc2e4095340be9ce7f9e58d802
Use pyparted to check for bootflag [Closes: issue1248]

The approach to check the 7th field in the MBR for the
bootable flag being set isn't enough. This fails to detect
bootable partitions if they aren't the first primary ones.

pyparted provides a way to check whether the specified
partition really has the boot flag set, so let's use this
approach, iff pyparted is available.

Took the get_partition_for_path function from Evgeni Golov's
https://github.com/evgeni/grml2usb/tree/pyparted with his
permission.
debian/control
grml2usb