]> git.ipfire.org Git - thirdparty/libvirt.git/commit
tests: Enable directory override for qemucapsprobe
authorAndrea Bolognani <abologna@redhat.com>
Wed, 6 May 2020 09:50:31 +0000 (11:50 +0200)
committerAndrea Bolognani <abologna@redhat.com>
Wed, 6 May 2020 10:32:49 +0000 (12:32 +0200)
commitbab946e3830ee79f07b76366c05f0f3b4cf1cda2
tree5fbc81ef663ce74b15a3edffb3aa64ce24f0fb78
parent3af4c75d59d1f8bd7e54c06a81ab1cb089060f7f
tests: Enable directory override for qemucapsprobe

Currently, qemucapsprobe fails when libvirt is not already installed
on the system:

  $ ./tests/qemucapsprobe /path/to/qemu-system-ppc64 >/dev/null
  I/O warning : failed to load external entity "/usr/share/libvirt/cpu_map/index.xml"
  2020-05-06 09:49:59.136+0000: 269822: info : libvirt version: 6.4.0
  2020-05-06 09:49:59.136+0000: 269822: info : hostname: [...]
  2020-05-06 09:49:59.136+0000: 269822: warning : virQEMUCapsLogProbeFailure:5127 :
  Failed to probe capabilities for /path/to/qemu-system-ppc64: XML error: failed to
  parse xml document '/usr/share/libvirt/cpu_map/index.xml'

It would be great if the tool could work entirely out of the build
directory, and this patch achieves just that.

Suggested-by: Peter Krempa <pkrempa@redhat.com>
Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
tests/qemucapsprobe.c