summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuke Macken <lmacken@redhat.com>2009-05-12 03:09:00 (GMT)
committerLuke Macken <lmacken@redhat.com>2009-06-09 13:18:48 (GMT)
commitaff9357adbe48b8212cf4690a6dbea4bec23635c (patch)
tree801e2c11b7d42f7ae813ea72d4785f4b45874366
parent48758ef4a36bfc6e468c8487708859ba211b06f1 (diff)
downloadliveusb-creator-aff9357adbe48b8212cf4690a6dbea4bec23635c.zip
liveusb-creator-aff9357adbe48b8212cf4690a6dbea4bec23635c.tar.gz
liveusb-creator-aff9357adbe48b8212cf4690a6dbea4bec23635c.tar.xz
Use our syslinux's menu com32 modules (#492370, #494000)
com32 modules in syslinux don't seem to have a consistent API, so workaround it by copying in the menu files from syslinux.
-rwxr-xr-xliveusb/creator.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/liveusb/creator.py b/liveusb/creator.py
index cb21c71..11c2668 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -544,6 +544,20 @@ class LinuxLiveUSBCreator(LiveUSBCreator):
syslinux_path = os.path.join(self.dest, "syslinux")
shutil.move(os.path.join(self.dest, "isolinux"), syslinux_path)
os.unlink(os.path.join(syslinux_path, "isolinux.cfg"))
+
+ # Syslinux doesn't guarantee the API for its com32 modules (#492370)
+ for com32mod in ('vesamenu.c32', 'menu.c32'):
+ copied = False
+ for path in ('/usr/share', '/usr/lib'):
+ com32path = os.path.join(path, 'syslinux', com32mod)
+ if os.path.isfile(com32path):
+ self.log.debug('Copying %s on to stick' % com32path)
+ shutil.copyfile(com32path, os.path.join(syslinux_path, com32mod))
+ copied = True
+ break
+ if copied:
+ break
+
if self.drive['fstype'] in ('ext2', 'ext3'):
shutil.move(os.path.join(syslinux_path, "syslinux.cfg"),
os.path.join(syslinux_path, "extlinux.cfg"))