- for filename in 'addons.cfg', 'default.cfg', 'distri.cfg', 'hidden.cfg', 'grml.cfg', 'grml.png', 'hd.cfg', 'isoprompt.cfg', 'options.cfg','vesamenu.c32', 'vesamenu.cfg', 'grml.png':
- path = search_file(filename, iso_mount)
+ # avoid the "file is read only, overwrite anyway (y/n) ?" question
+ # of mtools by syslinux ("mmove -D o -D O s:/ldlinux.sys $target_file")
+ if os.path.isfile(syslinux_target + 'ldlinux.sys'):
+ os.unlink(syslinux_target + 'ldlinux.sys')
+
+ if not search_file('default.cfg', iso_mount + '/boot/isolinux/'):
+ logging.critical("Fatal: file default.cfg could not be found.")
+ logging.critical("Note: this grml2usb version requires an ISO generated by grml-live >=0.9.24 ...")
+ logging.critical(" ... either use grml releases >=2009.10 or switch to an older grml2usb version.")
+ raise
+
+ for filename in 'addons.cfg', 'default.cfg', 'distri.cfg', \
+ 'grml.cfg', 'grml.png', 'hd.cfg', 'isoprompt.cfg', 'options.cfg', \
+ 'prompt.cfg', 'vesamenu.c32', 'vesamenu.cfg', 'grml.png':
+ path = search_file(filename, iso_mount + '/boot/isolinux/')