- bsc#1042709 - unable to create VM with SLE4SAP SP1 over network
install virtinst-fix-sle-distro-parsing.patch OBS-URL: https://build.opensuse.org/package/show/Virtualization/virt-manager?expand=0&rev=353
This commit is contained in:
parent
0c6c31977f
commit
ee70e1bd71
@ -1,3 +1,10 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Jun 7 11:29:02 MDT 2017 - carnold@suse.com
|
||||||
|
|
||||||
|
- bsc#1042709 - unable to create VM with SLE4SAP SP1 over network
|
||||||
|
install
|
||||||
|
virtinst-fix-sle-distro-parsing.patch
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Mon Jun 5 11:38:58 MDT 2017 - carnold@suse.com
|
Mon Jun 5 11:38:58 MDT 2017 - carnold@suse.com
|
||||||
|
|
||||||
|
@ -90,6 +90,7 @@ Patch161: virtinst-xenbus-disk-index-fix.patch
|
|||||||
Patch162: virtinst-refresh_before_fetch_pool.patch
|
Patch162: virtinst-refresh_before_fetch_pool.patch
|
||||||
Patch163: virtinst-use-xenpae-kernel-for-32bit.patch
|
Patch163: virtinst-use-xenpae-kernel-for-32bit.patch
|
||||||
Patch164: virtinst-use-qemu-for-cdrom-device.patch
|
Patch164: virtinst-use-qemu-for-cdrom-device.patch
|
||||||
|
Patch165: virtinst-fix-sle-distro-parsing.patch
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
|
|
||||||
@ -225,6 +226,7 @@ machine).
|
|||||||
%patch162 -p1
|
%patch162 -p1
|
||||||
%patch163 -p1
|
%patch163 -p1
|
||||||
%patch164 -p1
|
%patch164 -p1
|
||||||
|
%patch165 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%if %{qemu_user}
|
%if %{qemu_user}
|
||||||
|
42
virtinst-fix-sle-distro-parsing.patch
Normal file
42
virtinst-fix-sle-distro-parsing.patch
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
References: bsc#1042709
|
||||||
|
|
||||||
|
Index: virt-manager-1.4.1/virtinst/urlfetcher.py
|
||||||
|
===================================================================
|
||||||
|
--- virt-manager-1.4.1.orig/virtinst/urlfetcher.py
|
||||||
|
+++ virt-manager-1.4.1/virtinst/urlfetcher.py
|
||||||
|
@@ -444,9 +444,20 @@ def _distroFromSUSEContent(fetcher, arch
|
||||||
|
arch = "ppc64le"
|
||||||
|
|
||||||
|
def _parse_sle_distribution(d):
|
||||||
|
- sle_version = d[1].strip().rsplit(' ')[4]
|
||||||
|
- if len(d[1].strip().rsplit(' ')) > 5:
|
||||||
|
- sle_version = sle_version + '.' + d[1].strip().rsplit(' ')[5][2]
|
||||||
|
+ d_list = d[1].strip().rsplit(' ')
|
||||||
|
+ d_len = len(d_list)
|
||||||
|
+ sle_version = 12
|
||||||
|
+ counter = 0
|
||||||
|
+ while counter < d_len:
|
||||||
|
+ item = d_list[counter].strip()
|
||||||
|
+ if item.isdigit():
|
||||||
|
+ sle_version = item
|
||||||
|
+ if counter+1 < d_len:
|
||||||
|
+ item = d_list[counter+1].strip()
|
||||||
|
+ if item[2].isdigit():
|
||||||
|
+ sle_version = sle_version + '.' + item[2]
|
||||||
|
+ break
|
||||||
|
+ counter += 1
|
||||||
|
return ['VERSION', sle_version]
|
||||||
|
|
||||||
|
dclass = GenericDistro
|
||||||
|
@@ -1029,7 +1040,10 @@ class SuseDistro(Distro):
|
||||||
|
distro_version = self.version_from_content[1].strip()
|
||||||
|
version = distro_version.split('.', 1)[0].strip()
|
||||||
|
self.os_variant = self.urldistro
|
||||||
|
- version_int = int(version)
|
||||||
|
+ if version.isdigit():
|
||||||
|
+ version_int = int(version)
|
||||||
|
+ else:
|
||||||
|
+ version_int = 12
|
||||||
|
if version_int >= 10:
|
||||||
|
if self.os_variant.startswith(("sles", "sled")):
|
||||||
|
sp_version = None
|
Loading…
Reference in New Issue
Block a user