summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO8
-rw-r--r--PKGBUILD31
-rw-r--r--fixes.patch138
3 files changed, 164 insertions, 13 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 3b2525e7bd01..ceb0dc5dc47c 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,20 +1,20 @@
pkgbase = multibootusb
pkgdesc = Boot multiple live Linux distros from a usb flash drive.
pkgver = 9.2.0
- pkgrel = 4
- url = http://multibootusb.org
+ pkgrel = 5
+ url = https://sourceforge.net/projects/multibootusb/
arch = any
license = GPL
depends = python-pyqt5
depends = python-dbus
depends = mtools
- depends = util-linux
depends = parted
depends = p7zip
- depends = python-six
depends = python-pyudev
source = https://github.com/mbusb/multibootusb/archive/v9.2.0.tar.gz
+ source = fixes.patch
sha512sums = 461ce6edd835b2a017d96c3987338cd9004894949ac0b121fc289d100b7945dd89970f966e48310b97f312221a2f5a047190c55802d3a07a9eec0bf6ec22356d
+ sha512sums = e10ddbd1588bb17d05040c001e4ca4f85d5da5a77de95154ac34d0fc7b3310a464077c88636a008b92af09b0920711d7b057f4c7542e1576708bed5a591e76d3
pkgname = multibootusb
diff --git a/PKGBUILD b/PKGBUILD
index d5557bbcbd8c..cbe5c0e00322 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -6,19 +6,32 @@
pkgname=multibootusb
pkgver=9.2.0
-pkgrel=4
+pkgrel=5
pkgdesc="Boot multiple live Linux distros from a usb flash drive."
-arch=("any")
-url="http://multibootusb.org"
-license=("GPL")
-depends=("python-pyqt5" "python-dbus" "mtools" "util-linux" "parted" "p7zip" "python-six" "python-pyudev")
+arch=('any')
+url="https://sourceforge.net/projects/multibootusb/"
+license=('GPL')
+depends=('python-pyqt5' 'python-dbus' 'mtools' 'parted' 'p7zip' 'python-pyudev')
-sha512sums=("461ce6edd835b2a017d96c3987338cd9004894949ac0b121fc289d100b7945dd89970f966e48310b97f312221a2f5a047190c55802d3a07a9eec0bf6ec22356d")
-source=("https://github.com/mbusb/$pkgname/archive/v${pkgver}.tar.gz")
+sha512sums=('461ce6edd835b2a017d96c3987338cd9004894949ac0b121fc289d100b7945dd89970f966e48310b97f312221a2f5a047190c55802d3a07a9eec0bf6ec22356d'
+ 'e10ddbd1588bb17d05040c001e4ca4f85d5da5a77de95154ac34d0fc7b3310a464077c88636a008b92af09b0920711d7b057f4c7542e1576708bed5a591e76d3')
+source=("https://github.com/mbusb/$pkgname/archive/v${pkgver}.tar.gz"
+ "fixes.patch")
+
+prepare() {
+ cd "$srcdir/$pkgname-$pkgver"
+
+ patch -Np1 < "$srcdir/fixes.patch"
+}
+
+build() {
+ cd "$srcdir/$pkgname-$pkgver"
+ python setup.py build
+}
package () {
cd "$srcdir/$pkgname-$pkgver"
chmod 755 "$srcdir/$pkgname-$pkgver/data/multibootusb.desktop"
- python3 setup.py install --root="$pkgdir/" --optimize=1
- sed -i 's/\/usr\/local\/bin/\/usr\/bin/' "$pkgdir/usr/share/polkit-1/actions/org.debian.pkexec.run-multibootusb.policy"
+ python setup.py install --root="$pkgdir/" --optimize=1 --skip-build
+ sed -i "s/\/usr\/local\/bin/\/usr\/bin/" "$pkgdir/usr/share/polkit-1/actions/org.debian.pkexec.run-multibootusb.policy"
}
diff --git a/fixes.patch b/fixes.patch
new file mode 100644
index 000000000000..89b0ada039ad
--- /dev/null
+++ b/fixes.patch
@@ -0,0 +1,138 @@
+diff --git a/multibootusb b/multibootusb
+index ae831e0..5f8db76 100644
+--- a/multibootusb
++++ b/multibootusb
+@@ -102,7 +102,7 @@ Example for installing multiple distros without user intervention:
+
+ Windows:
+ python3 multibootusb -c -y -i ../../favourite.iso,../../other-distro.iso -t G:
+-
++
+ Example for writing ISO image to target USB disk (will destroy data on USB disk):
+
+ Linux:
+@@ -184,25 +184,33 @@ if __name__ == '__main__':
+ sys.exit()
+ '''
+
++if platform.system() == 'Linux':
++ if os.getuid() != 0:
++ exit("You need to have root privileges to run this application."
++ "\nPlease try again using 'sudo'. Exiting.")
++elif platform.system() == 'Windows':
++ if ctypes.windll.shell32.IsUserAnAdmin() != 1:
++ exit("You need to have admin privileges to run this application."
++ "\nPlease open command window with admin rights. Exiting.")
++
+ if config.debug is True:
+ from scripts.debug import colors
+ log(colors.HEADER + "=== DEBUG ENABLED ===")
+
+
+ if gui is False:
+- check_admin()
+- if uninstall is True and config.usb_disk is not '':
++ if uninstall is True and config.usb_disk is not None:
+ cli_uninstall_distro()
+- elif uninstall is True and config.usb_disk is '':
++ elif uninstall is True and config.usb_disk is None:
+ log('\nYou must provide \'-t\' option to point to your USB disk for uninstalling a distro.\n'
+ 'See the usage example below.')
+ usage()
+- elif config.image_path is '' and config.usb_disk is '':
++ elif config.image_path is None and config.usb_disk is None:
+ log('\nNo option provided. See the usage below.')
+ usage()
+- elif config.cli_syslinux is True and config.usb_disk is not '':
++ elif config.cli_syslinux is True and config.usb_disk is not None:
+ cli_install_syslinux()
+- elif config.image_path is '' or config.usb_disk is '':
++ elif config.image_path is None or config.usb_disk is None:
+ log('\nOptions \'-i\' and \'-t\' must be supplied together. See the usage below.')
+ usage()
+ elif config.cli_dd is True:
+diff --git a/scripts/gen.py b/scripts/gen.py
+index f29dc6e..2f2218d 100644
+--- a/scripts/gen.py
++++ b/scripts/gen.py
+@@ -137,7 +137,8 @@ def mbusb_log_file():
+ if platform.system() == "Linux":
+ # home_dir = os.path.expanduser('~')
+ # log_file = os.path.join(home_dir, "multibootusb.log")
+- log_file = os.path.join(tempfile.gettempdir(), "multibootusb.log")
++ # log_file = os.path.join(tempfile.gettempdir(), "multibootusb.log")
++ log_file = "/var/log/multibootusb.log"
+ elif platform.system() == "Windows":
+ # log_file = os.path.join(tempfile.gettempdir(), "multibootusb", "multibootusb.log")
+ log_file = os.path.join("multibootusb.log")
+@@ -241,7 +242,7 @@ def copy_mbusb_dir_usb(usb_disk):
+ if not os.path.exists(os.path.join(usb_mount_path, 'multibootusb', 'grub', 'core-msdos.img')):
+ shutil.copy(resource_path(os.path.join('data', 'multibootusb', 'grub', 'core-msdos.img')),
+ os.path.join(usb_mount_path, 'multibootusb', 'grub', 'core-msdos.img'))
+-
++
+ if not os.path.exists(os.path.join(usb_mount_path, 'multibootusb', 'grub', 'x86_64-efi')):
+ log("New EFI modules does not exist. Copying now.")
+ shutil.copytree(resource_path(os.path.join('data', 'multibootusb', 'grub', 'x86_64-efi')),
+@@ -443,7 +444,7 @@ class MemoryCheck():
+ Cross platform way to checks memory of a given system. Works on Linux and Windows.
+ psutil is a good option to get memory info. But version 5.0 and only will work.
+ Source: https://doeidoei.wordpress.com/2009/03/22/python-tip-3-checking-available-ram-with-python/
+- Call this class like this:
++ Call this class like this:
+ mem_info = memoryCheck()
+ print(mem_info.value)
+ """
+@@ -500,7 +501,7 @@ def wmi_get_drive_info(usb_disk):
+ if disk.Caption == usb_disk:
+ return (partition, disk)
+ raise RuntimeError('Failed to obtain drive information ' + usb_disk)
+-
++
+ def get_physical_disk_number(usb_disk):
+ """
+ Get the physical disk number as detected ny Windows.
+diff --git a/scripts/mbusb_gui.py b/scripts/mbusb_gui.py
+index ba87a30..440aa1f 100644
+--- a/scripts/mbusb_gui.py
++++ b/scripts/mbusb_gui.py
+@@ -753,9 +753,6 @@ class GuiInstallProgress(QtCore.QThread):
+ def __init__(self):
+ QtCore.QThread.__init__(self)
+
+- def __del__(self):
+- self.wait()
+-
+ def run(self):
+ install_dir = os.path.join(config.usb_mount, "multibootusb", iso_basename(config.image_path))
+ self.thread = GenericThread(install_progress)
+@@ -797,9 +794,6 @@ class GuiUninstallProgress(QtCore.QThread):
+ QtCore.QThread.__init__(self)
+ self.thread = GenericThread(uninstall_progress)
+
+- def __del__(self):
+- self.wait()
+-
+ def run(self):
+ self.thread.start()
+
+@@ -840,9 +834,6 @@ class DD_Progress(QtCore.QThread):
+ elif platform.system() == 'Windows':
+ self.thread = GenericThread(dd_win)
+
+- def __del__(self):
+- self.wait()
+-
+ def run(self):
+ self.thread.start()
+ while self.thread.isRunning():
+@@ -870,9 +861,6 @@ class GenericThread(QtCore.QThread):
+ self.args = args
+ self.kwargs = kwargs
+
+- def __del__(self):
+- self.wait()
+-
+ def run(self):
+ self.function(*self.args, **self.kwargs)
+ return