Commit Graph

317 Commits (master)

Author SHA1 Message Date
Shinji Suzuki 1744cd34cb Recreate syslinux.bin upon distro installation.
Start isolating os dependency into osdriver.py
Cleanup gen.resurce_path()
6 years ago
Shinji Suzuki 008f8d1d4e Catch exceptions raised during install_syslinux() and make effort to undo
partially completed installation.
Qualify symobols in uninstall_distro with the module name. (Unqualified
reference to symbols in other modules is rather difficult to track.)
Fix a doc string to keep up with the function signature change.
6 years ago
Sundar bdff07055c Merge branch 'devel' of https://github.com/mbusb/multibootusb.git into devel 6 years ago
Sundar 57c30ea587 GUI improvement and bug fix.
1. Place the push button under imager tab to its original place
2. Extract additional files from ISO for proper booting of wifislax
3. PEP improvements
6 years ago
multibootusb b36e20317a
Merge pull request #349 from shinji-s/devel
Always add -f when syslinuxing in syslinux_distro_dir().
6 years ago
Shinji Suzuki c8aa216985 Always add -f when syslinuxing in syslinux_distro_dir().
(This should not increase danger level significantly because
the flag is already present when syslinuxing in syslinux_default())
6 years ago
multibootusb fe02cea56d
Merge pull request #348 from shinji-s/devel
Reformat mbusb_gui.py
6 years ago
Shinji Suzuki 848a606d51 Reformat to fit mostly within 80 columns. 6 years ago
Shinji Suzuki aff42c027e Remove an extra indentation that has been kept to avoid creating large
diff.
6 years ago
Shinji Suzuki ad0abd6079 Avoid repetitive initialization. 6 years ago
Shinji Suzuki ace09b4d7e Fix exception from os.path.basename(None). 6 years ago
Shinji Suzuki 670a18b966 Refuse to process an iso file whose name contains space(s)
because syslinux does not seem to be able to handle a
pathname that contains space(s).
6 years ago
Shinji Suzuki 6a6d1382a2 Deal with MX iso that lacks 'version' file.
Prepare for antiX/MX version 18 and beyond.
6 years ago
multibootusb 85aa42634d
Merge pull request #343 from shinji-s/mx-fix
Fix booting of MX-17.1 (an antiX derivative).
6 years ago
Shinji Suzuki 9d2575930e Fix booting of MX-17.1 (an antiX derivative). 6 years ago
Shinji Suzuki 01f30c9522 Deal with renaming of config.use_kvm to config.qemu_use_kvm. 6 years ago
Shinji Suzuki 695262ffd9 Call os.sync() before UDISKS.unmount() becase the latter will timeout if buffer flush takes too long.
Fix failure to capture exception into a variable.
6 years ago
multibootusb adc5643723
Merge pull request #340 from shinji-s/corruption_check
Address filesystem corruption
6 years ago
shinji-s 24216e63eb Update display of the mount point in response to remounting afer qemu execution. 6 years ago
shinji-s 72b1bf97ee Perform syslinux module replacement also for gentoo. 6 years ago
shinji-s eaa3b97f1b Add 'cdroot_type=vfat' to get a gentoo (livedvd-amd64-hardened-nomultilib-20170118.iso)
booting off of a vfat formatted stick.
6 years ago
shinji-s 8b5a6e76b5 Use a uuid rather than a device name when specifying 'real_root='. 6 years ago
shinji-s 9c6af84f72 Undo 'tabify' on comments.
Remove redundant code for updating mount point display.
6 years ago
shinji-s 4ce5277eac Remove os.sync() and a dubug print. 6 years ago
shinji-s fc7e988cbf Fix mishaps in merging (lost code for handling 'protected_drives', bad qemu command building.)
Fix an attemp to os.chdir('')
6 years ago
shinji-s 6588648fc5 Add gui for fsck.
Fix bug that re-enables gui controls before distro installation finishes.
Have udisks not attempt mount if the target is already mounted.
6 years ago
Shinji Suzuki fc56319187 Unmount target partition when running syslinux/dd/qemu to prevent filesystem corruption.
Fix master allocation table and backup allocation table going out of sync after syslinuxing the target.
Detect lvm partition as well.
6 years ago
Shinji Suzuki 61c1d947fa Fix exception from install_patch() raised when a distro does not have
isolinux_bin_dir.
Try relative paths first before /usr/share/multibootusb when locating a
resource.
6 years ago
shinji-s 10bc802a18 Support an alternate bios when running QEMU. 6 years ago
shinji-s 729400c6fa Unify config update implementations for Fedora and Centos. 6 years ago
Shinji Suzuki daead673a8 Postfix menu-entry with an architecture name when generating
loopback.cfg so that one for i686 won't hide another for x86_64
or vice versa.
6 years ago
Shinji Suzuki d0babd1705 Avoid gfxboot lockup when booting antiX via syslinux. 6 years ago
Shinji Suzuki 437f7264ce Merge branch 'devel' of https://github.com/mbusb/multibootusb into adhoc_fix 6 years ago
Shinji Suzuki 706f9f67d0 Fix code that assumes '.iso' extension in the image_path. 6 years ago
Shinji Suzuki 75dd18880a Hunt gfxboot.c32 hidden under a path-prefix, which fixes the hang
in Manjaro 17.0 syslinux booting.
6 years ago
Shinji Suzuki d43d808ca0 Added note about inability to support recent Salix. 6 years ago
Shinji Suzuki bfc2246472 Merge branch 'devel' of https://github.com/mbusb/multibootusb into manjaro-fix 6 years ago
Shinji Suzuki eb1cbb9845 Allow running syslinux on a fixed disk through
'config.allow_syslinux_on_fixed_drive' setting.
6 years ago
Shinji Suzuki 3fc6561ec6 Address syslinux boot issues with Manjaro and Slitaz-rolling.
* Manjaro does not provide syslinux config files. Add 'via GRUB' to
the menu title and chain to grub when the menu is select.
* Booting slitaz via syslinux used to give "vesamenu.c32 not COM32R
image" error. Now mbusb overwrites the module with the bundled one
and decompress c32box.c32 module. c32box.c32 needs decompression
because it is compressed with lzma which syslinux.exe bundled with
mbusd can't handle.
6 years ago
multibootusb 82ce94c2b9
Merge pull request #330 from shinji-s/devel
Allow protection of drives through 'config.protected_drives'
6 years ago
Shinji Suzuki 43439a9c2b Allow protection of drives through 'config.protected_drives'
variable by not showing them in the target drive listbox.
6 years ago
Shinji Suzuki 06768cb7e5 Don't show i/o error from attempting to open nonexistent config file. 6 years ago
Shinji Suzuki 7c82607eb0 Remove catch clause for UnicodeDecodeError that will never be raised. 6 years ago
Shinji Suzuki e4ac1a0139 Introduced more strict distro detection for those which fail
to be correctly identified. (grml64-full_2017.05.iso,
salixlive-xfce-14.2.1.iso, wifislax64-1.1-final.iso).
Fixed installer to make up for the fixed detection.
Removed a dead code block.
6 years ago
Shinji Suzuki 80c5a47381 Refactored distro() function with two alterations.
* file availability based checks are performed before keyword based checks.
* Next file will be tried if I/O error is raised.
6 years ago
Shinji Suzuki ffa7c4a03d Move back the check for centos-live to stay above the check for fedora.
More unittests on distro detection using unittest.TestCase.
6 years ago
Shinji Suzuki 003aa4ae6c Remove predicate that always evaluates to true. ('slacko' is caught
by the check fo puppy several lines above.)
6 years ago
Shinji Suzuki 8a4ef54a34 Remove 'acentos' from CentOS detection keyword. 6 years ago
Shinji Suzuki 96c0760067 QEMU related enhancements.
* Support accelaration via Intel HAXM hypervisor.
* Provide more flexibility in selecting which qemu to run.
* Fix multiple calls to check_qemu_exist().
6 years ago
Shinji Suzuki 1a7ca3bc02 Fix loopback.cfg file generation when working on "PING is not Ghost 4.00".
(syslinux config of this iso contains only one menu item and it
excercised a code path that had a bug but have not been been taken
before.)
Rewrite relative paths as well when generating loopback.cfg.
Deal with the case where isolinuxbin_dir is None.
6 years ago
Sundar 7cbbcd0495 Merge branch 'devel' of https://github.com/mbusb/multibootusb.git into devel 6 years ago
Sundar deec177fff Added PING and include changes parameter to slax config file 6 years ago
multibootusb e4104024a9
Merge pull request #322 from shinji-s/adhoc_fix
Avoid logging unbounded amount of info.
6 years ago
Shinji Suzuki 13fd72fad4 Avoid logging unbounded amount of info.
Replace code sequence with data definition.
6 years ago
multibootusb d4c171a7f8
Merge pull request #321 from shinji-s/adhoc_fix
Remove redundant list comprehension.
6 years ago
Shinji Suzuki f561526e68 Remove redundant list comprehension.
Deduplicate common path expression.
6 years ago
Sundar 89bfaaee33 Merge branch 'devel' of https://github.com/mbusb/multibootusb.git into devel 6 years ago
Sundar 0003e3c08a Updated the CHANGELOG for new release 6 years ago
Shinji Suzuki 266039675e Guard against tripping on non-utf8 encoded text files. 6 years ago
multibootusb 2f10191a05
Merge pull request #318 from shinji-s/wifislax
Get salitaz-rolling rolling again.
6 years ago
multibootusb ef7d1a1d89
Merge pull request #319 from shinji-s/devel
Fix exception from opening utf-8 encoded text file
6 years ago
Shinji Suzuki 90a4ff57fe Merge branch 'devel' of https://github.com/shinji-s/multibootusb into devel 6 years ago
Shinji Suzuki 7e6aa856be Fix exception from opening utf-8 encoded text file under non-utf-8 locale
setting.
Update scanned text files only when desktop-image path was tweaked.
6 years ago
Shinji Suzuki f1c057ea77 Get salitaz-rolling booting.
* Deal with syslinux config file lacking 'kernel' line.
* Fix misdetection as 'centos'
6 years ago
mbusb 50085ce8bc Implement debian persistance feature under Windows 6 years ago
Sundar f9df4bdce6 Fix for Slitaz distro detection and include Suzuki in contributor list. 6 years ago
multibootusb 0cca03339c
Merge pull request #315 from shinji-s/wifislax
Add Support for WifiSlax64-1.1-final
6 years ago
Shinji Suzuki ea8a6d0b49 Get WifiSlax64-1.1-final booting.
* Prefer 'grub.cfg' over other variants like 'grub-embedded.cfg'
* Extract the tree rooted at EFI/ as well.
* Probe .txt files other than 'thema.txt' for rewriting desktop-image:
setting.
* Add 'legacy_tweak()' method to ConfigTweakers to keep old behaviour.
* Add SalixConfigTweaker.
6 years ago
multibootusb 4fb5ef9f5e
Merge pull request #314 from shinji-s/devel
FIX/improve partition type detection.
6 years ago
shinji-s 223bcc9276 Merge branch 'devel' of https://github.com/shinji-s/multibootusb into devel 6 years ago
shinji-s 9f60b92be4 FIX/improve partition type detection. 6 years ago
multibootusb a2e16c46dd
Merge pull request #310 from shinji-s/devel
CLI enhancements
6 years ago
shinji-s 75b662d8ed Fix rewriting of image-file paths in 'theme.txt'.
* Don't strip space and tabs on the left of a line
* Don't tweak a relative path.
6 years ago
shinji-s e5296b9dfd Add support for AntiX 17.1 6 years ago
shinji-s 896b7314e6 Prevent mbusb_cli from installing over existing installation.
Support persistence size specification in mbusb_cli.
Line break adjustment to fit 80 cols.
6 years ago
shinji-s a94572c2bc Fix a rather critical bug in 'ConfigTweaker.tweak_first_match()' that got 'param_operation' contaminated with 'param_operations_for_persistence' as the recursion progress.
Support CentOS DVD installers. (Full install DVD requires ext3 formatted usb stick because its size exceeds 4GB.)
Straighten Centos Live DVD support. (Those were recognized as 'fedora' before this fix.)
Reorgazined Twaker classes a bit.
Removed control chars and extra spaces in test inputs.
6 years ago
multibootusb fe6e475d73
Merge pull request #306 from shinji-s/adhoc_fix
Change wording of a message slightly so that a user will not
6 years ago
multibootusb da811627ec
Merge pull request #305 from shinji-s/devel
Report non-existent file references in config files in more concise
6 years ago
Shinji Suzuki 00f22c5c4e Avoid rewriting paths on a comment line.
Minor change of logged messages about path rewriting.
6 years ago
Shinji Suzuki 8ae3ee1d17 Change wording of a message slightly so that a user will not
misunderstand that the distro does not implement persistence at all.
6 years ago
Shinji Suzuki d659f83925 Report non-existent file references in config files in more concise
manner.
Fix path finding regular expression to properly catch comma-delimited
paths.
6 years ago
multibootusb 9786b866ae
Merge pull request #304 from shinji-s/devel
Log path rewriting exceptions in more concise manner.
6 years ago
Shinji Suzuki 6d0e922568 Log path rewriting exceptions in more concise manner. 6 years ago
multibootusb 27d653e213
Merge pull request #303 from shinji-s/fix_distro_detection
* Fix distro detection going out of sync after uninstalling a distro
6 years ago
Shinji Suzuki dd0d23ec68 * Fix distro detection going out of sync after uninstalling a distro
because config.distro gets overwritten during uninstallation.
* Fix missed call to update_list_box() when performing config-files-only
uninstallation, which happens because distro dir is already gone.
* Fix missed update of grub.cfg when performing config-files-only
uninstallation.
* Fix multiple calls to delete_frm_file_list() when uninstalling
'windows', 'alpine' and 'generic'.
* Fix multiple calls to update_sys_cfg_file() when uninstalling a distro.
* Escape distro name when using it within regular expressions.
* Adjust line breaking to fit 80 cols.
6 years ago
multibootusb ea809a12c9
Merge pull request #299 from shinji-s/devel
Introduce infrastructure for rewriting boot configs and refreshed
6 years ago
multibootusb 9fb937d283
Merge pull request #302 from shinji-s/adhoc_fix
Fix module name typo that gets triggered by overwriting installation of
6 years ago
Shinji Suzuki 76f26f6da6 Fix assertion error that happens because persistence
size setting is remembered even for distros that
do not support persistence.
6 years ago
Shinji Suzuki 2bb9b12403 Fix module name typo that gets triggered by overwriting installation of
distros that have some dirs relocated to the root dir.
6 years ago
Shinji Suzuki a6d3744134 Fix linux (ubuntu16.04) incompatibility.
* 7z don't understand -aoa option.
* subprocess.call() can't properly pass arguments to 7z if command is
specified by a list when shell=True.
6 years ago
Shinji Suzuki ef4d34b05d Convert 'gentoo' rewrite-code to ConfigTweaker based one.
Rename 'ParamTweaker' to 'ConfigTweaker'.

pentoo-amd64-hardened-2018.0_RC5.8_pre20180305 wants 'overlayfs' present
in boot params and 'aufs' absent in order to boot properly.
6 years ago
Shinji Suzuki 4ef4146180 Replace 'live-media=' on non-liveboot lines too. This is for compatibility
with prior implementation. (Perhaps better to have this work on liveboot
lines only like other rewritings?)

Move the test function for rewrite machinary into param_rewrite.py.

Add copyright header.
6 years ago
Shinji Suzuki d75642ac62 Detect running 7zip on a currupted iso as well as the lack of 7z
executable.
Remove repeated call to _7zip.list_iso(iso_link)
Adjusted line breaking to fit within 80 columns.
6 years ago
Shinji Suzuki 7a18b71349 Introduce infrastructure for rewriting boot configs and refreshed
persistence support for debians.
  * Boot parameters have to be 'persistence' and 'persistence-path'
  rather than 'persistent' and 'persistent-path'.
  * Backing file must be named 'persistence' rather than 'live-rw'
  * Filesystem on the backing file must contain 'persistence.conf'.
Avoid rewriting of paths starting with '/cdrom/' or '/dev/'.
Try somedir/vmlinuz if somedir/vmlinuz.efi is unavailable.
Check availability of 'e2fsck' and 'resize2fs'.
Added data/tools/persistence.gz that has initialized ext3 file
system that contains 'persistence.conf' file.
6 years ago
Shinji Suzuki 03077403d2 Fix regression introduced by 8ea5932bdc.
With the change in the commit, loopback.cfg got regenerated at the
location of file determined by scanning iso tree. If no loopback.cfg was
found, it was assumed to be at the distribution root directory. In either
case, loopback.cfg was generated/overwritten at the determined location
and the file was chosen for booting.
Now, if no loopback.cfg is found, grub.cfg is sought. It is only in the
case where neither is found that loopback.cfg gets generated and used.
Therefore no config files provided by distro get overwritten.
6 years ago
Shinji Suzuki 170b8dcf58 When fixing a path to have /multibootusb/{distro-name} prepended, consider another prefix '/multibootusb/{distro-name}/boot too because some distro uses '/grub/grub.cfg' to refer to a file under boot/ directory. 6 years ago
Shinji Suzuki fa960f1a07 Fix tweaking of 'initrd=...' parameter keyed on 'initrd' because 'initrd'
part in 'initrd.img' gets affected.
6 years ago
Shinji Suzuki fe597bf1de Fix a typo that has caused failure of installation if the distribution wants .iso file available when booting.
file when booting. My bad.
6 years ago
Shinji Suzuki a3ff878087 Remove a code that does not seem essential but can potentially hurts. 6 years ago
Shinji Suzuki 0669b962ed * Split the 'kernel ...' parameter not by ',/' but by ',' because some distro contains relative paths there and then we don't see './' there.
* Fix the last block of syslinux config file being picked up but being partially extracted (only to the end of the line rather than to the end of the block). => Took $ out of the regular expression and handles the last block separately.
* Don't use 'menu label' as a key to split a syslinux config file into blocks. Solely use 'label' as the separator for extracting menu items out of syslinux config file. If 'menu label' is also considered, then we may split halfway within a block. => Removed 'menu label' from the regular expression.
6 years ago