diff -Nru virt-manager-1.3.2/debian/changelog virt-manager-1.3.2/debian/changelog --- virt-manager-1.3.2/debian/changelog 2016-07-26 07:15:10.000000000 -0500 +++ virt-manager-1.3.2/debian/changelog 2016-11-29 12:52:23.000000000 -0600 @@ -1,3 +1,11 @@ +virt-manager (1:1.3.2-3ubuntu4) yakkety; urgency=medium + + * Fix virt-install so that it can install 16.04 and newer images. + Error message is 'Couldn't find hvm kernel for Ubuntu tree + Closes (LP: #1634304) + + -- Dave Chiluk Tue, 29 Nov 2016 12:52:23 -0600 + virt-manager (1:1.3.2-3ubuntu3) yakkety; urgency=medium * debian/patches/use_virtio_for_pseries_disks.patch: virtinst: Use diff -Nru virt-manager-1.3.2/debian/patches/series virt-manager-1.3.2/debian/patches/series --- virt-manager-1.3.2/debian/patches/series 2016-07-20 18:34:44.000000000 -0500 +++ virt-manager-1.3.2/debian/patches/series 2016-11-29 12:52:23.000000000 -0600 @@ -12,3 +12,4 @@ virtinst/dont_disable_vmport.patch 0001-details-Fix-screenshot-on-F24-rawhide-bz-1297988.patch use_virtio_for_pseries_disks.patch +virtinst/urlfetcher_Fix_ubuntu_location.patch diff -Nru virt-manager-1.3.2/debian/patches/virtinst/urlfetcher_Fix_ubuntu_location.patch virt-manager-1.3.2/debian/patches/virtinst/urlfetcher_Fix_ubuntu_location.patch --- virt-manager-1.3.2/debian/patches/virtinst/urlfetcher_Fix_ubuntu_location.patch 1969-12-31 18:00:00.000000000 -0600 +++ virt-manager-1.3.2/debian/patches/virtinst/urlfetcher_Fix_ubuntu_location.patch 2016-11-29 12:52:23.000000000 -0600 @@ -0,0 +1,54 @@ +Origin: upstream, https://github.com/virt-manager/virt-manager/commit/3f15a489cda87f8028828d567848193dd2640a43 +Author: Cole Robinson +Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/virt-manager/+bug/1634304 +Reveiwed-by: Dave Chiluk + +Description: urlfetcher: Fix ubuntu --location $iso arch detection + Reported here: + http://www.redhat.com/archives/virt-tools-list/2016-August/msg00009.html + +Index: virt-manager-1.3.2/virtinst/urlfetcher.py +=================================================================== +--- virt-manager-1.3.2.orig/virtinst/urlfetcher.py 2016-11-29 12:17:03.685445710 -0600 ++++ virt-manager-1.3.2/virtinst/urlfetcher.py 2016-11-29 12:17:03.685445710 -0600 +@@ -1057,18 +1057,32 @@ + def __init__(self, *args, **kwargs): + Distro.__init__(self, *args, **kwargs) + +- # Pull the tree's arch out of the URL text +- self._treeArch = "i386" ++ self._treeArch = self._find_treearch() ++ self._url_prefix = 'current/images' ++ self._installer_dirname = self.name.lower() + "-installer" ++ self._set_media_paths() ++ ++ def _find_treearch(self): + for pattern in ["^.*/installer-(\w+)/?$", + "^.*/daily-images/(\w+)/?$"]: + arch = re.findall(pattern, self.uri) +- if arch: +- self._treeArch = arch[0] +- break ++ if not arch: ++ continue ++ logging.debug("Found pattern=%s treearch=%s in uri", ++ pattern, arch[0]) ++ return arch[0] + +- self._url_prefix = 'current/images' +- self._installer_dirname = self.name.lower() + "-installer" +- self._set_media_paths() ++ # Check for standard 'i386' and 'amd64' which will be ++ # in the URI name for --location $ISO mounts ++ for arch in ["i386", "amd64"]: ++ if arch in self.uri: ++ logging.debug("Found treearch=%s in uri", arch) ++ return arch ++ ++ # Otherwise default to amd64 ++ arch = "i386" ++ logging.debug("No treearch found in uri, defaulting to arch=%s", arch) ++ return arch + + def _set_media_paths(self): + self._boot_iso_paths = ["%s/netboot/mini.iso" % self._url_prefix]