21 commits - AUTHORS liveusb-creator liveusb/creator.py liveusb-creator.spec liveusb/gui.py liveusb/releases.py README.txt setup.py tools/syslinux.exe

Luke Macken lmacken at fedoraproject.org
Mon Mar 9 00:57:26 UTC 2009


 AUTHORS              |    3 ++
 README.txt           |    7 +++--
 liveusb-creator      |    6 ++--
 liveusb-creator.spec |   11 +++++++-
 liveusb/creator.py   |   63 ++++++++++++++++++++++++++++++++++--------------
 liveusb/gui.py       |   66 ++++++++++++++++++++++++++++++++++++++-------------
 liveusb/releases.py  |   22 +++++++++++++++++
 setup.py             |    4 +--
 tools/syslinux.exe   |binary
 9 files changed, 140 insertions(+), 42 deletions(-)

New commits:
commit ce87e169d7df90ee2c9c1f16ddd2629a3eb86b69
Author: Luke Macken <lmacken at redhat.com>
Date:   Sun Mar 8 20:16:42 2009 -0400

    v3.6

diff --git a/liveusb-creator b/liveusb-creator
index 41039f2..60afa81 100755
--- a/liveusb-creator
+++ b/liveusb-creator
@@ -18,7 +18,7 @@
 #
 # Author(s): Luke Macken <lmacken at redhat.com>
 
-__version__ = '3.5'
+__version__ = '3.6'
 
 def parse_args():
     from optparse import OptionParser
diff --git a/liveusb-creator.spec b/liveusb-creator.spec
index 243aa54..fa2abae 100644
--- a/liveusb-creator.spec
+++ b/liveusb-creator.spec
@@ -1,8 +1,8 @@
 %{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
 
 Name:           liveusb-creator
-Version:        3.5
-Release:        3%{?dist}
+Version:        3.6
+Release:        1%{?dist}
 Summary:        A liveusb creator
 
 Group:          Applications/System
@@ -68,9 +68,9 @@ rm -rf %{buildroot}
 %config(noreplace) %{_sysconfdir}/security/console.apps/%{name}
 
 %changelog
-* Mon Feb 07 2009 Luke Macken <lmacken at redhat.com> 3.5-3
+* Mon Mar 07 2009 Luke Macken <lmacken at redhat.com> 3.6-1
 - Require pyparted
-- Allow for ext4 formatted devices
+- Update to v3.6
 
 * Fri Mar 06 2009 wwp <subscript at free.fr> 3.5-2
 - Fix dd commands when output path contain whitespaces
diff --git a/setup.py b/setup.py
index 31929ce..43b98eb 100644
--- a/setup.py
+++ b/setup.py
@@ -14,7 +14,7 @@ if sys.platform == 'win32':
 
     setup(
         name = 'liveusb-creator',
-        version = '3.5',
+        version = '3.6',
         packages = ['liveusb', 'liveusb/urlgrabber'],
         scripts = ['liveusb-creator'], 
         license = 'GNU General Public License (GPL)',
@@ -55,7 +55,7 @@ if sys.platform == 'win32':
 else:
     setup(
         name = 'liveusb-creator',
-        version = '3.5',
+        version = '3.6',
         packages = ['liveusb'],
         scripts = ['liveusb-creator'],
         license = 'GNU General Public License (GPL)',


commit 7e370e88facef7da8b39d4788db36fea7dd5fc83
Author: Luke Macken <lmacken at redhat.com>
Date:   Sun Mar 8 20:15:00 2009 -0400

    Update our translators list

diff --git a/AUTHORS b/AUTHORS
index 70136f8..9e4aef3 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -20,3 +20,6 @@ Xavier Conde - Catalan
 PabloMartin-Gomez - French
 Milos Komarcevic - Serbian
 Sainrysec - Chinese 
+Mario Santagiuliana - Italian
+Manuel da Costa Gouveia - Portuguese
+


commit bdd8b4a16957abb5654d64d63c71be43c8debf7e
Author: Luke Macken <lmacken at redhat.com>
Date:   Sun Mar 8 19:58:22 2009 -0400

    Update our win32 syslinux to 3.73

diff --git a/tools/syslinux.exe b/tools/syslinux.exe
index 06ea292..c631b4b 100644
Binary files a/tools/syslinux.exe and b/tools/syslinux.exe differ


commit f671c69554175080a9180c25b6e8261b620edc9e
Author: Luke Macken <lmacken at redhat.com>
Date:   Sun Mar 8 14:21:26 2009 -0400

    Handle OSErrors when trying to mount the device

diff --git a/liveusb/gui.py b/liveusb/gui.py
index 4e6eaf5..bb019ac 100755
--- a/liveusb/gui.py
+++ b/liveusb/gui.py
@@ -408,6 +408,10 @@ class LiveUSBDialog(QtGui.QDialog, LiveUSBInterface):
             self.status(e.message)
             self.enable_widgets(True)
             return
+        except OSError, e:
+            self.status(_('Unable to mount device'))
+            self.enable_widgets(True)
+            return
 
         if self.live.existing_liveos():
             if not self.confirmed:


commit 2921c795fbe7e7647e7f24e30dd4e86f2facb226
Author: Luke Macken <lmacken at redhat.com>
Date:   Sun Mar 8 14:20:32 2009 -0400

    Do not reset the MBR for now, since we cannot seem to umount, reset, then remount...

diff --git a/liveusb/creator.py b/liveusb/creator.py
index 1e715e6..59a8779 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -494,7 +494,12 @@ class LinuxLiveUSBCreator(LiveUSBCreator):
         # Ensure our master boot record is not empty
         if self.blank_mbr():
             self.log.debug(_('Your MBR appears to be blank'))
-            self.reset_mbr()
+            # @@ FIXME:  To do this properly, we first need to unmount the device,
+            # then reset the mbr, then remount.  However, for some reason we
+            # are unable to re-mount the drive after resetting the MBR, and it
+            # tends to hose the USB stick as well.  Maybe we need to rescan/reprobe
+            # the device with DBus/Hal? -luke
+            #    self.live.reset_mbr()
 
     def extract_iso(self):
         """ Extract self.iso to self.dest """


commit d83155d996b2ce5842e6e0b333e65c6fc3ab879e
Author: Luke Macken <lmacken at redhat.com>
Date:   Sun Mar 8 01:25:39 2009 -0500

    Support ext filesystems, and ext4 support until we have an extlinux that supports it

diff --git a/liveusb/creator.py b/liveusb/creator.py
index b60bb9d..1e715e6 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -464,7 +464,7 @@ class LinuxLiveUSBCreator(LiveUSBCreator):
 
     def verify_filesystem(self):
         self.log.info(_("Verifying filesystem..."))
-        if self.fstype not in ('vfat', 'msdos', 'ext2', 'ext3', 'ext4'):
+        if self.fstype not in ('vfat', 'msdos', 'ext2', 'ext3'):
             if not self.fstype:
                 raise LiveUSBError(_("Unknown filesystem for %s.  Your device "
                                      "may need to be reformatted."))
@@ -530,12 +530,17 @@ class LinuxLiveUSBCreator(LiveUSBCreator):
         """ Run syslinux to install the bootloader on our devices """
         LiveUSBCreator.install_bootloader(self)
         self.log.info(_("Installing bootloader..."))
-        shutil.move(os.path.join(self.dest, "isolinux"),
-                    os.path.join(self.dest, "syslinux"))
-        os.unlink(os.path.join(self.dest, "syslinux", "isolinux.cfg"))
-        self.popen('syslinux%s%s -d %s %s' %  (self.opts.force and ' -f' or ' ',
-                   self.opts.safe and ' -s' or ' ',
-                   'syslinux', self.drive['device']))
+        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"))
+        if self.drive['fstype'] in ('ext2', 'ext3'):
+            shutil.move(os.path.join(syslinux_path, "syslinux.cfg"),
+                        os.path.join(syslinux_path, "extlinux.cfg"))
+            self.popen('extlinux -i %s' % syslinux_path)
+        else: # FAT
+            self.popen('syslinux%s%s -d %s %s' %  (self.opts.force and ' -f' or ' ',
+                       self.opts.safe and ' -s' or ' ',
+                       'syslinux', self.drive['device']))
 
     def get_free_bytes(self, device=None):
         """ Return the number of available bytes on our device """
@@ -675,7 +680,7 @@ class WindowsLiveUSBCreator(LiveUSBCreator):
                 try:
                     vol = win32api.GetVolumeInformation(drive)
                     label = vol[0]
-                except:
+                except pywintypes.error, e:
                     label = None
                 self.drives[drive] = {
                     'label': label,


commit c1cf34c6a545a432b2bd528a271f44467862e54d
Author: Luke Macken <lmacken at redhat.com>
Date:   Sun Mar 8 00:39:25 2009 -0500

    Don't fill the device 100%

diff --git a/liveusb/gui.py b/liveusb/gui.py
index a9ac1c9..4e6eaf5 100755
--- a/liveusb/gui.py
+++ b/liveusb/gui.py
@@ -357,6 +357,8 @@ class LiveUSBDialog(QtGui.QDialog, LiveUSBInterface):
         if self.live.isosize:
             freespace -= self.live.isosize / 1024**2
 
+        freespace -= 1 # Don't fill the device 100%
+
         if freespace < current_overlay:
             self.overlaySlider.setValue(freespace)
             self.live.overlay = self.overlaySlider.value()


commit 2106272d9e424548909628d144b59f04adb37c88
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 22:19:12 2009 -0500

    Overlay slider changes.
    
    - Remove the overlay size restriction for FAT32 (#486627).
    - Refresh the overlay slider when an ISO is selected, and upon mount.
    - When initially starting up, if the selected device is not mounted, we cannot
      determine the amount of free space on it, so we currently set the maximum
      size to 8G.  Once the device is mounted, the slider is refreshed.
    - When an ISO is selected, subtract the size from the overlay slider.

diff --git a/liveusb/gui.py b/liveusb/gui.py
index c1df219..a9ac1c9 100755
--- a/liveusb/gui.py
+++ b/liveusb/gui.py
@@ -325,9 +325,42 @@ class LiveUSBDialog(QtGui.QDialog, LiveUSBInterface):
         """
         if not str(drive):
             return
-        freespace = self.live.drives[str(drive).split()[0]]['free']
-        if not freespace or freespace > 2047:
-            freespace = 2047
+        self._refresh_overlay_slider(str(drive).split()[0])
+
+    def _refresh_overlay_slider(self, drive=None):
+        """
+        Reset the persistent storage slider based on the amount of free space
+        on the device and the ISO size.
+        """
+        if not drive:
+            drive = self.get_selected_drive()
+
+        device = self.live.drives[drive]
+        freespace = device['free']
+        current_overlay = self.overlaySlider.value()
+
+        if not freespace:
+            self.live.log.warning(_('Device is not yet mounted, so we cannot '
+                                    'determine the amount of free space.  '
+                                    'Setting a maximum limit of 8G for the '
+                                    'persistent storage.'))
+            freespace = 8192
+
+        # FAT16 cannot handle files greater than 2G
+        if device['fsversion'] == 'FAT16':
+            self.live.log.warning(_('Partition is FAT16; Restricting overlay '
+                                    'size to 2G'))
+            if freespace > 2047:
+                freespace = 2047
+
+        # Subtract the size of the ISO from our maximum overlay size
+        if self.live.isosize:
+            freespace -= self.live.isosize / 1024**2
+
+        if freespace < current_overlay:
+            self.overlaySlider.setValue(freespace)
+            self.live.overlay = self.overlaySlider.value()
+
         self.overlaySlider.setMaximum(freespace)
 
     def progress(self, value):
@@ -368,6 +401,7 @@ class LiveUSBDialog(QtGui.QDialog, LiveUSBInterface):
 
         try:
             self.live.mount_device()
+            self._refresh_overlay_slider() # To reflect the drives free space
         except LiveUSBError, e:
             self.status(e.message)
             self.enable_widgets(True)
@@ -449,6 +483,7 @@ class LiveUSBDialog(QtGui.QDialog, LiveUSBInterface):
 
             self.live.log.info('%s ' % os.path.basename(self.live.iso) + 
                                _("selected"))
+            self._refresh_overlay_slider()
 
     def terminate(self):
         """ Terminate any processes that we have spawned """


commit 80378ca3dde52a177e5e212887c248233ba9d6e2
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 22:18:24 2009 -0500

    Properly handle LiveUSBError objects in our gui status method

diff --git a/liveusb/gui.py b/liveusb/gui.py
index af9f91b..c1df219 100755
--- a/liveusb/gui.py
+++ b/liveusb/gui.py
@@ -337,6 +337,8 @@ class LiveUSBDialog(QtGui.QDialog, LiveUSBInterface):
         self.progressBar.setMaximum(value)
 
     def status(self, text):
+        if isinstance(text, LiveUSBError):
+            text = text.message
         self.textEdit.append(text)
 
     def enable_widgets(self, enabled=True):


commit f67400e57f1bde2750f101b48562a4d1d23e41de
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 22:17:39 2009 -0500

    Refresh the free space once the device is mounted.

diff --git a/liveusb/creator.py b/liveusb/creator.py
index b6cbe99..b60bb9d 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -434,6 +434,7 @@ class LinuxLiveUSBCreator(LiveUSBCreator):
             self.log.debug("Mounted %s to %s " % (self.drive['device'],
                                                   self.dest))
             self.drive['mount'] = self.dest
+            self.drive['free'] = self.get_free_bytes(self.dest) / 1024**2
         else:
             self.log.debug("Using existing mount: %s" % self.dest)
 


commit e71c2b0e0e9ceeed8621b651b62af48fd8cc04c3
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 22:16:18 2009 -0500

    Allow ext4. Bug #480495

diff --git a/liveusb-creator.spec b/liveusb-creator.spec
index 09df8cc..243aa54 100644
--- a/liveusb-creator.spec
+++ b/liveusb-creator.spec
@@ -70,6 +70,7 @@ rm -rf %{buildroot}
 %changelog
 * Mon Feb 07 2009 Luke Macken <lmacken at redhat.com> 3.5-3
 - Require pyparted
+- Allow for ext4 formatted devices
 
 * Fri Mar 06 2009 wwp <subscript at free.fr> 3.5-2
 - Fix dd commands when output path contain whitespaces
diff --git a/liveusb/creator.py b/liveusb/creator.py
index 46a4b37..b6cbe99 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -397,6 +397,7 @@ class LinuxLiveUSBCreator(LiveUSBCreator):
         self.drives[device] = {
             'label'   : str(dev.GetProperty('volume.label')).replace(' ', '_'),
             'fstype'  : str(dev.GetProperty('volume.fstype')),
+            'fsversion': str(dev.GetProperty('volume.fsversion')),
             'uuid'    : str(dev.GetProperty('volume.uuid')),
             'mount'   : mount,
             'udi'     : dev,
@@ -682,6 +683,7 @@ class WindowsLiveUSBCreator(LiveUSBCreator):
                     'free': self.get_free_bytes(drive) / 1024**2,
                     'fstype': 'vfat',
                     'device': drive,
+                    'fsversion': vol[-1],
                 }
         if not len(self.drives):
             raise LiveUSBError(_("Unable to find any removable devices"))


commit e1072155b0b04732fdf856aa14173986dbb175b3
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 22:14:29 2009 -0500

    Enable OLPC support by default.

diff --git a/liveusb-creator b/liveusb-creator
index 635e0b1..41039f2 100755
--- a/liveusb-creator
+++ b/liveusb-creator
@@ -38,8 +38,8 @@ def parse_args():
                       action='store', metavar='ARGS', 
                       help='Supply extra kernel arguments'
                            ' (eg: -k noswap,selinux=0,elevator=noop)')
-    parser.add_option('-x', '--xo', dest='xo', action='store_true',
-                      help='Make it bootable on the OLPC')
+    parser.add_option('-x', '--no-xo', dest='xo', action='store_false',
+                      default=True, help='Disable OLPC support')
     #parser.add_option('-z', '--usb-zip', dest='zip', action='store_true',
     #                  help='Initialize device with zipdrive-compatible geometry'
     #                        ' for booting in USB-ZIP mode with legacy BIOSes. '


commit 9d8cfd6f12a9b40d8db8a681d23839195d7293c5
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 22:13:57 2009 -0500

    Instead of warning about it, just silently skip loop devices.

diff --git a/liveusb/creator.py b/liveusb/creator.py
index b0a5807..46a4b37 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -330,11 +330,9 @@ class LiveUSBCreator(object):
         return mbr == '0000'
 
     def reset_mbr(self):
-        self.log.info(_('Resetting MBR...'))
-        if '/dev/loop' in self.drive:
-            self.log.warning('Cannot reset MBR on loopback device')
-            return
-        self.popen('cat /usr/lib/syslinux/mbr.bin > %s' % self._drive)
+        if '/dev/loop' not in self.drive:
+            self.log.info(_('Resetting MBR...'))
+            self.popen('cat /usr/lib/syslinux/mbr.bin > %s' % self._drive)
 
     def bootable_partition(self):
         """ Ensure that the selected partition is flagged as bootable """


commit 2c060fc473f3c2356a502925a0adf6ec74c9055c
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 22:12:28 2009 -0500

    Create a LiveUSBCreator.set_iso method.
    
    This method is used to prefetch the size of the ISO, so that we can reflect
    it in the Persistent Storage slider.
    
    This also moves to _to_unicode method into the LiveUSBCreator.

diff --git a/liveusb/creator.py b/liveusb/creator.py
index 326c971..b0a5807 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -226,7 +226,6 @@ class LiveUSBCreator(object):
         """ Make sure there is enough space for the LiveOS and overlay """
         freebytes = self.get_free_bytes()
         self.log.debug('freebytes = %d' % freebytes)
-        self.isosize = os.stat(self.iso)[ST_SIZE]
         self.log.debug('isosize = %d' % self.isosize)
         overlaysize = self.overlay * 1024**2
         self.log.debug('overlaysize = %d' % overlaysize)
@@ -341,6 +340,19 @@ class LiveUSBCreator(object):
         """ Ensure that the selected partition is flagged as bootable """
         pass
 
+    def set_iso(self, iso):
+        """ Select the given ISO """
+        self.iso = self._to_unicode(iso)
+        self.isosize = os.stat(self.iso)[ST_SIZE]
+
+    def _to_unicode(self, obj, encoding='utf-8'):
+        if hasattr(obj, 'toUtf8'): # PyQt4.QtCore.QString
+            obj = str(obj.toUtf8())
+        if isinstance(obj, basestring):
+            if not isinstance(obj, unicode):
+                obj = unicode(obj, encoding, 'replace')
+        return obj
+
 
 class LinuxLiveUSBCreator(LiveUSBCreator):
 
diff --git a/liveusb/gui.py b/liveusb/gui.py
index 0f3b0af..af9f91b 100755
--- a/liveusb/gui.py
+++ b/liveusb/gui.py
@@ -438,13 +438,12 @@ class LiveUSBDialog(QtGui.QDialog, LiveUSBInterface):
                                                     ".", "ISO (*.iso)" )
         if isofile:
             try:
-                self.live.iso = self._to_unicode(isofile)
+                self.live.set_iso(isofile)
             except Exception, e:
                 self.live.log.error(e.message.encode('utf8'))
-                self.status(_("Sorry, I'm having trouble encoding the filename "
-                              "of your livecd.  You may have better luck if "
-                              "you move your ISO to the root of your drive "
-                              "(ie: C:\)"))
+                self.status(_("Unable to encode the filename of your livecd.  "
+                              "You may have better luck if you move your ISO "
+                              "to the root of your drive (ie: C:\)"))
 
             self.live.log.info('%s ' % os.path.basename(self.live.iso) + 
                                _("selected"))
@@ -452,11 +451,3 @@ class LiveUSBDialog(QtGui.QDialog, LiveUSBInterface):
     def terminate(self):
         """ Terminate any processes that we have spawned """
         self.live.terminate()
-
-    def _to_unicode(self, obj, encoding='utf-8'):
-        if hasattr(obj, 'toUtf8'): # PyQt4.QtCore.QString
-            obj = str(obj.toUtf8())
-        if isinstance(obj, basestring):
-            if not isinstance(obj, unicode):
-                obj = unicode(obj, encoding, 'replace')
-        return obj


commit 48c01f0d570b585f8d09d9c602e69714e10647d0
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 19:24:26 2009 -0500

    Minor readme update

diff --git a/README.txt b/README.txt
index a576a0e..548704c 100644
--- a/README.txt
+++ b/README.txt
@@ -17,9 +17,12 @@ See the Developers Guide on the wiki for details,
 
         https://fedorahosted.org/liveusb-creator/wiki/Development
 
-================================================================================
+License
+-------
 
-This tool is distributed with the following open source software
+The liveusb-creator is licensed under the GPLv2.
+
+This tool is distributed with the following open source software::
 
    Python
    http://python.org


commit 0867d7fb06080f24365df05b0f50dce099e31813
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 19:14:43 2009 -0500

    Allow for ext4

diff --git a/liveusb/creator.py b/liveusb/creator.py
index 1859871..326c971 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -452,7 +452,7 @@ class LinuxLiveUSBCreator(LiveUSBCreator):
 
     def verify_filesystem(self):
         self.log.info(_("Verifying filesystem..."))
-        if self.fstype not in ('vfat', 'msdos', 'ext2', 'ext3'):
+        if self.fstype not in ('vfat', 'msdos', 'ext2', 'ext3', 'ext4'):
             if not self.fstype:
                 raise LiveUSBError(_("Unknown filesystem for %s.  Your device "
                                      "may need to be reformatted."))


commit aaa0b15d8ae5d423cb65ac0ed02a7bddee373ee2
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 17:57:37 2009 -0500

    Add Fedora 11 Alpha to our releases list

diff --git a/liveusb/releases.py b/liveusb/releases.py
index de274fa..83ffd2b 100644
--- a/liveusb/releases.py
+++ b/liveusb/releases.py
@@ -20,6 +20,28 @@ releases = (
         'sha1': 'a58634cf8dbd9e27db2b9cbf48d18c2e0dfe941e',
     },
 
+    ## F11 Alpha
+    {
+        'name': 'Fedora 11 Alpha (i686)',
+        'url': 'http://download.fedoraproject.org/pub/fedora/linux/releases/test/11-Alpha/Live/i686/F11-Alpha-i686-Live.iso',
+        'sha1': '6eb44cd56b041ed683a898cf690b468177f3e3f5',
+    },
+    {
+        'name': 'Fedora 11 Alpha KDE (i686)',
+        'url': 'http://download.fedoraproject.org/pub/fedora/linux/releases/test/11-Alpha/Live/i686/F11-Alpha-i686-Live-KDE.iso',
+        'sha1': '64851662f7b11e230c875e066519e49211ac8ad0',
+    },
+    {
+        'name': 'Fedora 11 Alpha (x86_64)',
+        'url': 'http://download.fedoraproject.org/pub/fedora/linux/releases/test/11-Alpha/Live/x86_64/F11-Alpha-x86_64-Live.iso',
+        'sha1': 'd499f6c85b6e76967b7161c634539d9077b30cb8',
+    },
+    {
+        'name': 'Fedora 11 Alpha KDE (x86_64)',
+        'url': 'http://download.fedoraproject.org/pub/fedora/linux/releases/test/11-Alpha/Live/x86_64/F11-Alpha-x86_64-Live-KDE.iso',
+        'sha1': 'fefb6d261cfb547c7b8a99db9452ac7469cac778',
+    },
+
     {
         'name': 'Fedora 9 (i686)',
         'url': 'http://download.fedoraproject.org/pub/fedora/linux/releases/9/Live/i686/Fedora-9-i686-Live.iso',


commit ee5c2ae05a5418c2f0f4adc3234e3ae74ff30d45
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 17:33:31 2009 -0500

    Fix dd commands when output path contain whitespaces.
    
    Thanks to wwp <subscript at free dot fr> for the patch!

diff --git a/liveusb-creator.spec b/liveusb-creator.spec
index 314c56b..09df8cc 100644
--- a/liveusb-creator.spec
+++ b/liveusb-creator.spec
@@ -2,7 +2,7 @@
 
 Name:           liveusb-creator
 Version:        3.5
-Release:        2%{?dist}
+Release:        3%{?dist}
 Summary:        A liveusb creator
 
 Group:          Applications/System
@@ -29,6 +29,7 @@ A liveusb creator from Live Fedora images
 %build
 %{__python} setup.py build
 make mo
+make mo
 
 %install
 rm -rf %{buildroot}
@@ -67,9 +68,12 @@ rm -rf %{buildroot}
 %config(noreplace) %{_sysconfdir}/security/console.apps/%{name}
 
 %changelog
-* Mon Feb 02 2009 Luke Macken <lmacken at redhat.com> 3.5-2
+* Mon Feb 07 2009 Luke Macken <lmacken at redhat.com> 3.5-3
 - Require pyparted
 
+* Fri Mar 06 2009 wwp <subscript at free.fr> 3.5-2
+- Fix dd commands when output path contain whitespaces
+
 * Fri Jan 16 2009 Luke Macken <lmacken at redhat.com> 3.5-1
 - Update to v3.5
 
diff --git a/liveusb/creator.py b/liveusb/creator.py
index e4fce27..1859871 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -243,10 +243,10 @@ class LiveUSBCreator(object):
                           _("persistent overlay"))
             if self.fstype == 'vfat':
                 # vfat apparently can't handle sparse files
-                self.popen('dd if=/dev/zero of=%s count=%d bs=1M'
+                self.popen('dd if=/dev/zero of="%s" count=%d bs=1M'
                            % (self.get_overlay(), self.overlay))
             else:
-                self.popen('dd if=/dev/zero of=%s count=1 bs=1M seek=%d'
+                self.popen('dd if=/dev/zero of="%s" count=1 bs=1M seek=%d'
                            % (self.get_overlay(), self.overlay))
 
     def update_configs(self):


commit 98a3c9864f67fb5747f690326b491b82ed5f5e7b
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 16:59:41 2009 -0500

    Better handle unmount exceptions

diff --git a/liveusb/creator.py b/liveusb/creator.py
index 0f1fdf5..e4fce27 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -440,8 +440,9 @@ class LinuxLiveUSBCreator(LiveUSBCreator):
                 self.drive['udi'].Unmount([],
                         dbus_interface='org.freedesktop.Hal.Device.Volume')
             except dbus.exceptions.DBusException, e:
-                raise
+                import traceback
                 self.log.warning("Unable to unmount device: %s" % str(e))
+                self.log.debug(traceback.format_exc())
                 return
             self.drive['unmount'] = False
             self.drive['mount'] = None


commit 455a709a90c9366c4760bc4bc842dbf877bb7003
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 16:59:01 2009 -0500

    Handle cases in unmount_device where the drive key doesn't exist

diff --git a/liveusb/creator.py b/liveusb/creator.py
index 7362d1c..0f1fdf5 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -429,7 +429,10 @@ class LinuxLiveUSBCreator(LiveUSBCreator):
     def unmount_device(self):
         """ Unmount our device """
         import dbus
-        unmount = self.drive.get('unmount', None)
+        try:
+            unmount = self.drive.get('unmount', None)
+        except KeyError:
+            return
         if self.dest and unmount:
             self.log.debug("Unmounting %s from %s" % (self.drive['device'],
                                                       self.dest))


commit 4b9db9a2e9c6ab7b3845ec856a4b1947822637e2
Author: Luke Macken <lmacken at redhat.com>
Date:   Sat Mar 7 16:51:55 2009 -0500

    Require pyparted

diff --git a/liveusb-creator.spec b/liveusb-creator.spec
index c0277c5..314c56b 100644
--- a/liveusb-creator.spec
+++ b/liveusb-creator.spec
@@ -2,7 +2,7 @@
 
 Name:           liveusb-creator
 Version:        3.5
-Release:        1%{?dist}
+Release:        2%{?dist}
 Summary:        A liveusb creator
 
 Group:          Applications/System
@@ -18,6 +18,7 @@ ExcludeArch:    ppc64
 BuildRequires:  python-devel, python-setuptools, PyQt4-devel, desktop-file-utils gettext
 Requires:       syslinux, PyQt4, usermode, isomd5sum
 Requires:       python-urlgrabber
+Requires:       pyparted
 
 %description
 A liveusb creator from Live Fedora images
@@ -66,6 +67,9 @@ rm -rf %{buildroot}
 %config(noreplace) %{_sysconfdir}/security/console.apps/%{name}
 
 %changelog
+* Mon Feb 02 2009 Luke Macken <lmacken at redhat.com> 3.5-2
+- Require pyparted
+
 * Fri Jan 16 2009 Luke Macken <lmacken at redhat.com> 3.5-1
 - Update to v3.5
 




More information about the liveusb-creator mailing list