Description of problem: The version string that qemu used to print out looked like: QEMU PC emulator version x.yy.zz (qemu-kvm- And libvirt expected this. Recently (on April 28, qemu commit f75ca1ae205f24dae296c82d534c37746f87232f), this has changed to look like: QEMU emulator version x.yy.zz (qemu-kvm- Note the lack of "PC". We need to update qemudParseHelpStr() to be able to handle this new version.
I've got the following patch for this: diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c index 5fa8c0a..08a2865 100644 --- a/src/qemu/qemu_conf.c +++ b/src/qemu/qemu_conf.c @@ -1260,6 +1260,8 @@ static unsigned long long qemudComputeCmdFlags(const char * whether it is KVM QEMU or mainline QEMU. */ #define QEMU_VERSION_STR "QEMU PC emulator version" +/* in Qemu 0.13, the version string changed to remove the PC part */ +#define QEMU_VERSION_STR_013 "QEMU emulator version" #define QEMU_KVM_VER_PREFIX "(qemu-kvm-" #define KVM_VER_PREFIX "(kvm-" @@ -1277,11 +1279,13 @@ int qemudParseHelpStr(const char *qemu, *flags = *version = *is_kvm = *kvm_version = 0; - if (!STRPREFIX(p, QEMU_VERSION_STR)) + if (STRPREFIX(p, QEMU_VERSION_STR)) + p += strlen(QEMU_VERSION_STR); + else if (STRPREFIX(p, QEMU_VERSION_STR_013)) + p += strlen(QEMU_VERSION_STR_013); + else goto fail; - p += strlen(QEMU_VERSION_STR); - SKIP_BLANKS(p); major = virParseNumber(&p); Jes is going to test it out for me and get back to me about it. Chris Lalancette
This is now upstream. Marking as MODIFIED. Chris Lalancette