Package: virt-goodies
Version: 0.4-1
Severity: normal
Tags: patch
User: [email protected]
Usertags: origin-ubuntu natty ubuntu-patch


In Ubuntu, the attached patch was applied to achieve the following:

  * vmware2libvirt: allow for ide0:0.filename (used by easyvmx). Patch based
    on work by Ang Way Chuang.

This is discussed in http://art.ubuntuforums.org/showthread.php?p=10318275.

Thanks for considering the patch.


-- System Information:
Debian Release: squeeze/sid
  APT prefers natty-updates
  APT policy: (500, 'natty-updates'), (500, 'natty-security'), (500, 'natty')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.37-11-generic (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
diff -u virt-goodies-0.4/debian/control virt-goodies-0.4/debian/control
--- virt-goodies-0.4/debian/control
+++ virt-goodies-0.4/debian/control
@@ -1,7 +1,8 @@
 Source: virt-goodies
 Section: admin
 Priority: extra
-Maintainer: Petter Reinholdtsen <[email protected]>
+Maintainer: Ubuntu MOTU Developers <[email protected]>
+XSBC-Original-Maintainer: Petter Reinholdtsen <[email protected]>
 Build-Depends: cdbs, debhelper (>= 5)
 Standards-Version: 3.8.4
 Homepage: http://launchpad.net/virt-goodies
diff -u virt-goodies-0.4/debian/changelog virt-goodies-0.4/debian/changelog
only in patch2:
unchanged:
--- virt-goodies-0.4.orig/vmware2libvirt
+++ virt-goodies-0.4/vmware2libvirt
@@ -102,19 +102,22 @@
         raise V2LError("'uuidgen' exited with error: " + out)
     return out.strip()
 
-def get_disk(dir, vmx):
+def get_disk(directory, vmx):
     '''Detect the disk vmware image uses'''
     scsi_disk = ""
     ide_disk = ""
     disk = ""
     try:
-         scsi_disk = get_vmx_value(vmx, "scsi0:0.fileName")
+        scsi_disk = get_vmx_value(vmx, "scsi0:0.fileName")
     except:
-         pass
+        pass
     try:
-         ide_disk = get_vmx_value(vmx, "ide0:0.fileName")
+        ide_disk = get_vmx_value(vmx, "ide0:0.fileName")
     except:
-         pass
+        try:
+            ide_disk = get_vmx_value(vmx, "ide0:0.filename")
+        except:
+            pass
 
     if scsi_disk != "" and ide_disk != "":
         # found two disks, default to scsi for now
@@ -131,7 +134,7 @@
     else:
         raise V2LError("Couldn't find any disks")
 
-    disk = os.path.join(dir, disk)
+    disk = os.path.join(directory, disk)
     if not os.path.exists(disk):
         warn("'" + disk + "' does not exist")
 
@@ -224,9 +227,9 @@
 if opts.netmodel:
     netmodel = opts.netmodel
 
-dir = os.path.abspath(os.path.dirname(opts.vmxfile))
+directory = os.path.abspath(os.path.dirname(opts.vmxfile))
 try:
-    disk = get_disk(dir, vmx)
+    disk = get_disk(directory, vmx)
 except:
     error
 

Reply via email to