configure: ignore spice libraries on 32 bit.
PATCH 1/1 configure: ignore spice libraries on 32 bit.
As featured on:
https://bugs.launchpad.net/qemu-linaro/+bug/928432
Since we compile with -Werror, the presence of spice headers breaks compile. Yet except for x86-64, it doesn't compile, doesn't work, isn't supported. See: http://spice-space.org/faq.html
--- configure | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-)
configure +3 -2
@@ -2509,7 +2509,7 @@ if compile_prog "" "" ; then need_offsetof=no fi -# spice probe +# spice probe: x86-64 only (see http://spice-space.org/page/FAQ) if test "$spice" != "no" ; then cat > $TMPC << EOF #include <spice.h>
@@ -2517,7 +2517,8 @@ int main(void) { spice_server_new(); return 0; } EOF spice_cflags=$($pkg_config --cflags spice-protocol spice-server 2>/dev/null) spice_libs=$($pkg_config --libs spice-protocol spice-server 2>/dev/null) - if $pkg_config --atleast-version=0.6.0 spice-server >/dev/null 2>&1 && \ + if [ "$ARCH" = x86_64 ] && \ + $pkg_config --atleast-version=0.6.0 spice-server >/dev/null 2>&1 && \ compile_prog "$spice_cflags" "$spice_libs" ; then spice="yes" libs_softmmu="$libs_softmmu $spice_libs"
Quoted 6 lines · Rusty Russell
As featured on:
https://bugs.launchpad.net/qemu-linaro/+bug/928432Since we compile with -Werror, the presence of spice headers breaks compile. Yet except for x86-64, it doesn't compile, doesn't work, isn't supported. See: http://spice-space.org/faq.html
Outdated. 64bit restrictions are gone, spice server works on 32bit too.
Thats why 32bit spice packages exist in the first place ;)
Attached patch fixes the warnings.
cheers,
Gerd
Quoted 1 line
From
a45a8229260d45804fea654fb9b45c35eb454478Mon Sep 17 00:00:00 2001
From: Gerd Hoffmann <[email protected]>
Date: Wed, 8 Feb 2012 15:58:35 +0100
Subject: [PATCH] qxl: fix warnings on 32bit
--- hw/qxl.c | 7 ++++--- 1 files changed, 4 insertions(+), 3 deletions(-)
hw/qxl.c +4 -3
@@ -625,7 +625,7 @@ static void interface_release_resource(QXLInstance *sin,if (ext.group_id ==MEMSLOT_GROUP_HOST ) {/* host group -> vga mode update request */ -qemu_spice_destroy_update (&qxl->ssd, (void *)ext.info->id); +qemu_spice_destroy_update (&qxl->ssd, (void *)(intptr_t )ext.info->id);return ; }
@@ -748,7 +748,8 @@ static void interface_async_complete(QXLInstance *sin, uint64_t cookie) qxl->current_async =QXL_UNDEFINED_IO ;qemu_mutex_unlock (&qxl->async_lock); -dprint (qxl,2 ,"async_complete: %d (%ld) done\n" , current_async, cookie); +dprint (qxl,2 ,"async_complete: %d (%" PRId64") done\n" , + current_async, cookie);switch (current_async) {case QXL_IO_CREATE_PRIMARY_ASYNC :qxl_create_guest_primary_complete (qxl);
@@ -1017,7 +1018,7 @@ void *qxl_phys2virt(PCIQXLDevice *qxl, QXLPHYSICAL pqxl, int group_id)switch (group_id) {case MEMSLOT_GROUP_HOST : -return (void *)offset; +return (void *)(intptr_t )offset;case MEMSLOT_GROUP_GUEST :PANIC_ON (slot >=NUM_MEMSLOTS );PANIC_ON (!qxl->guest_slots[slot].active);
Signature · 1 line
1.7.1
Quoted 4 lines · Gerd Hoffmann
Quoted 3 lines · Rusty Russell
As featured on:
https://bugs.launchpad.net/qemu-linaro/+bug/928432
Quoted 8 lines
Quoted 3 lines
Since we compile with -Werror, the presence of spice headers breaks compile. Yet except for x86-64, it doesn't compile, doesn't work, isn't supported. See: http://spice-space.org/faq.html
Outdated. 64bit restrictions are gone, spice server works on 32bit too. Thats why 32bit spice packages exist in the first place ;)
Attached patch fixes the warnings.
Ping -- there seem to have been a couple of spice patch queue pulls since but did this warning fix patch get lost?
thanks
-- PMM
Quoted 9 lines · Peter Maydell
Quoted 8 lines · Gerd Hoffmann
Quoted 6 lines · Rusty Russell
As featured on:
https://bugs.launchpad.net/qemu-linaro/+bug/928432Since we compile with -Werror, the presence of spice headers breaks compile. Yet except for x86-64, it doesn't compile, doesn't work, isn't supported. See: http://spice-space.org/faq.html
Quoted 7 lines
Quoted 4 lines
Outdated. 64bit restrictions are gone, spice server works on 32bit too.
Thats why 32bit spice packages exist in the first place ;)Attached patch fixes the warnings.
Ping -- there seem to have been a couple of spice patch queue pulls since but did this warning fix patch get lost?
commit f4a8a424fceb0f79bbd9f7ae4285c8a58eb5598e
But it still doesn't build indeed.
Looks like new warnings sneaked in ...
cheers,
Gerd
Quoted 5 lines · Gerd Hoffmann
Quoted 2 lines · Peter Maydell
Ping -- there seem to have been a couple of spice patch queue pulls since but did this warning fix patch get lost?
commit
f4a8a424fceb0f79bbd9f7ae4285c8a58eb5598e
Yeah, I just spotted this, not sure why I thought the patch hadn't been applied. Sorry about the noise.
Quoted 2 lines
But it still doesn't build indeed.
Looks like new warnings sneaked in ...
Hohum :-(
-- PMM
Quoted 2 lines · Gerd Hoffmann
But it still doesn't build indeed.
Looks like new warnings sneaked in ...
Actually I get an outright compile error:
CC ui/spice-display.oui/spice-display.c: In function ‘qemu_spice_add_memslot’:ui/spice-display.c:79:42: error: ‘QXL_IO_MEMSLOT_ADD_ASYNC’ undeclared (first use in this function)ui/spice-display.c:79:42: note: each undeclared identifier is reported only once for each function it appears in ui/spice-display.c: In function ‘qemu_spice_create_primary_surface’:ui/spice-display.c:97:42: error: ‘QXL_IO_CREATE_PRIMARY_ASYNC’ undeclared (first use in this function)ui/spice-display.c: In function ‘qemu_spice_destroy_primary_surface’:ui/spice-display.c:110:42: error: ‘QXL_IO_DESTROY_PRIMARY_ASYNC’ undeclared (first use in this function)
make: *** [ui/spice-display.o] Error 1
git bisect blames commit 2e1a98c9c "qxl: introduce QXLCookie". Do we need a preprocessor guard so we don't try to use these if the host's spice headers don't support them?
(My host is Ubuntu Oneiric with libspice-server-dev 0.8.2-2 and spice-protocol-dev 0.8.0-0ubuntu1.)
-- PMM
Hi,
Quoted 6 lines
git bisect blames commit
2e1a98c9c"qxl: introduce QXLCookie". Do we need a preprocessor guard so we don't try to use these if the host's spice headers don't support them?(My host is Ubuntu Oneiric with libspice-server-dev 0.8.2-2 and spice-protocol-dev 0.8.0-0ubuntu1.)
Hmm, spice-protocol 0.8.1 adds them. qemu configure has a hard dependency on spice-server 0.8.2 or newer, and I through that automagically pulls in a recent enougth spice-protocol too because it is needed to build spice-server in the first place.
Alon? Did I mix up the versioning? Or is this a bug in the ubuntu package dependencies?
cheers,
Gerd
Quoted 9 lines · Gerd Hoffmann
Hi,
Quoted 6 lines
git bisect blames commit
2e1a98c9c"qxl: introduce QXLCookie". Do we need a preprocessor guard so we don't try to use these if the host's spice headers don't support them?(My host is Ubuntu Oneiric with libspice-server-dev 0.8.2-2 and spice-protocol-dev 0.8.0-0ubuntu1.)
Quoted 7 lines
Hmm, spice-protocol 0.8.1 adds them. qemu configure has a hard dependency on spice-server 0.8.2 or newer, and I through that automagically pulls in a recent enougth spice-protocol too because it is needed to build spice-server in the first place.
Alon? Did I mix up the versioning? Or is this a bug in the ubuntu package dependencies?
There is no spice-protocol requires in spice-server.pc from 0.8 branch (took the 0.8.2 commit f0e5a3cb77625b32050f052a8ede7ab0ca008224), This is the Requires line:
Requires: pixman-1 >= 0.17.7 celt051 >= 0.5.1.1 alsa openssl xrandr xfixes x11 xext xrender
so I think we need to add our own.
configure +1 -0
@@ -2544,6 +2544,7 @@ EOF spice_cflags=$($pkg_config --cflags spice-protocol spice-server 2>/dev/null) spice_libs=$($pkg_config --libs spice-protocol spice-server 2>/dev/null) if $pkg_config --atleast-version=0.8.2 spice-server >/dev/null 2>&1 && \ + $pkg_config --atleast-version=0.8.1 spice-protocol > /dev/null 2>&1 && \ compile_prog "$spice_cflags" "$spice_libs" ; then spice="yes" libs_softmmu="$libs_softmmu $spice_libs"
Quoted 4 lines
cheers,
Gerd
Quoted 10 lines · Alon Levy
configure +1
-0@@ -2544,6 +2544,7 @@ EOF spice_cflags=$($pkg_config --cflags spice-protocol spice-server 2>/dev/null) spice_libs=$($pkg_config --libs spice-protocol spice-server 2>/dev/null) if $pkg_config --atleast-version=0.8.2 spice-server >/dev/null 2>&1 && \ + $pkg_config --atleast-version=0.8.1 spice-protocol > /dev/null 2>&1 && \
Quoted 3 lines
compile_prog "$spice_cflags" "$spice_libs" ; then spice="yes"
libs_softmmu="$libs_softmmu $spice_libs"
I've confirmed that this change (a) disables spice on the Oneiric system that was failing to compile and (b) doesn't disable spice on Precise.
Could you submit it as a proper patch with a commit message and a signed-off-by line?
Thanks
-- PMM
PATCH 1/1 spice: require spice-protocol >= 0.8.1
Requiring spice-server >= 0.8.2 is not enough since spice-server.pc doesn't require spice-protocol (any version). Until that is fixed upstream an explicit requirement in qemu fixes compilation broken since
commit 2e1a98c9c1b90ca093278c6b43244dc46604d7b7
Author: Alon Levy <[email protected]> Date: Fri Feb 24 23:19:30 2012 +0200
qxl: introduce QXLCookie
--- configure | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
configure +1 -0
@@ -2544,6 +2544,7 @@ EOF spice_cflags=$($pkg_config --cflags spice-protocol spice-server 2>/dev/null) spice_libs=$($pkg_config --libs spice-protocol spice-server 2>/dev/null) if $pkg_config --atleast-version=0.8.2 spice-server >/dev/null 2>&1 && \ + $pkg_config --atleast-version=0.8.1 spice-protocol > /dev/null 2>&1 && \ compile_prog "$spice_cflags" "$spice_libs" ; then spice="yes" libs_softmmu="$libs_softmmu $spice_libs"
Signature · 1 line
1.7.9.1