create: Incorporate non-default arch into default guest name
This commit is contained in:
parent
fc2cef8eb2
commit
83b6dc7ea4
|
@ -63,6 +63,12 @@ RHEL6_OS_SUPPORT = [
|
|||
]
|
||||
|
||||
|
||||
def pretty_arch(_a):
|
||||
if _a == "armv7l":
|
||||
return "arm"
|
||||
return _a
|
||||
|
||||
|
||||
class vmmCreate(vmmGObjectUI):
|
||||
__gsignals__ = {
|
||||
"action-show-domain": (GObject.SignalFlags.RUN_FIRST, None, [str, str]),
|
||||
|
@ -688,11 +694,6 @@ class vmmCreate(vmmGObjectUI):
|
|||
model = arch_list.get_model()
|
||||
model.clear()
|
||||
|
||||
def pretty_arch(_a):
|
||||
if _a == "armv7l":
|
||||
return "arm"
|
||||
return _a
|
||||
|
||||
default = 0
|
||||
archs = []
|
||||
for guest in self.caps.guests:
|
||||
|
@ -1557,6 +1558,10 @@ class vmmCreate(vmmGObjectUI):
|
|||
else:
|
||||
basename = variant
|
||||
|
||||
if self.guest.os.arch != self.conn.caps.host.arch:
|
||||
basename += "-%s" % pretty_arch(self.guest.os.arch)
|
||||
force_num = False
|
||||
|
||||
return util.generate_name(basename,
|
||||
self.conn.get_backend().lookupByName,
|
||||
start_num=force_num and 1 or 2, force_num=force_num,
|
||||
|
|
Loading…
Reference in New Issue