]> xenbits.xensource.com Git - people/royger/xen.git/commitdiff
tools: Fix configure of upstream QEMU
authorAnthony PERARD <anthony.perard@citrix.com>
Wed, 23 Sep 2020 11:03:23 +0000 (12:03 +0100)
committerWei Liu <wl@xen.org>
Wed, 30 Sep 2020 15:08:17 +0000 (15:08 +0000)
QEMU as recently switch its build system to use meson and the
./configure step with meson is more restrictive that the step used to
be, most installation path wants to be within prefix, otherwise we
have this error message:

    ERROR: The value of the 'datadir' option is '/usr/share/qemu-xen' which must be a subdir of the prefix '/usr/lib/xen'.

In order to workaround the limitation, we will set prefix to the same
one as for the rest of Xen installation, and set all the other paths.

For reference, a thread in qemu-devel:
    "configure with datadir outside of --prefix fails with meson"
    https://lore.kernel.org/qemu-devel/20200918133012.GH2024@perard.uk.xensource.com/t/

And an issue in meson:
    "artificial limitation of directories (forced to be in prefix)"
    https://github.com/mesonbuild/meson/issues/2561

Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Tested-by: Paul Durrant <paul@xen.org>
Acked-by: Wei Liu <wl@xen.org>
tools/Makefile

index ea69675ccace2543b4c12ba151beec61fd862ff4..c1eba22c0c425954a295d1851510229fab98180f 100644 (file)
@@ -237,7 +237,7 @@ subdir-all-qemu-xen-dir: qemu-xen-dir-find
        $$source/configure --enable-xen --target-list=i386-softmmu \
                $(QEMU_XEN_ENABLE_DEBUG) \
                $$enable_trace_backend \
-               --prefix=$(LIBEXEC) \
+               --prefix=$(prefix) \
                --libdir=$(LIBEXEC_LIB) \
                --includedir=$(LIBEXEC_INC) \
                --extra-cflags="-DXC_WANT_COMPAT_EVTCHN_API=1 \
@@ -249,6 +249,10 @@ subdir-all-qemu-xen-dir: qemu-xen-dir-find
                --bindir=$(LIBEXEC_BIN) \
                --datadir=$(SHAREDIR)/qemu-xen \
                --localstatedir=$(localstatedir) \
+               --docdir=$(LIBEXEC)/share/doc \
+               --mandir=$(LIBEXEC)/share/man \
+               --libexecdir=$(LIBEXEC)/libexec \
+               --firmwarepath=$(LIBEXEC)/share/qemu-firmware \
                --disable-kvm \
                --disable-docs \
                --disable-guest-agent \