From: Gerd Hoffmann <kraxel@redhat.com>
To: qemu-devel@nongnu.org
Cc: "Marc-André Lureau" <marcandre.lureau@redhat.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Gerd Hoffmann" <kraxel@redhat.com>,
"Markus Armbruster" <armbru@redhat.com>
Subject: [PATCH v5 1/9] build: add separate spice-protocol config option
Date: Wed, 5 May 2021 08:08:53 +0200 [thread overview]
Message-ID: <20210505060901.828658-2-kraxel@redhat.com> (raw)
In-Reply-To: <20210505060901.828658-1-kraxel@redhat.com>
When implementing spice vdagent protocol in qemu we only need the
spice-protocol package for that, spice-server is not needed. So
go split those two build dependencies.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
configure | 36 ++++++++++++++++++++++++++++++++----
meson.build | 4 ++++
2 files changed, 36 insertions(+), 4 deletions(-)
diff --git a/configure b/configure
index 4f374b48890e..e6f959da2347 100755
--- a/configure
+++ b/configure
@@ -388,6 +388,7 @@ qom_cast_debug="yes"
trace_backends="log"
trace_file="trace"
spice="$default_feature"
+spice_protocol="auto"
rbd="auto"
smartcard="$default_feature"
u2f="auto"
@@ -1129,7 +1130,15 @@ for opt do
;;
--disable-spice) spice="no"
;;
- --enable-spice) spice="yes"
+ --enable-spice)
+ spice_protocol="yes"
+ spice="yes"
+ ;;
+ --disable-spice-protocol)
+ spice_protocol="no"
+ spice="no"
+ ;;
+ --enable-spice-protocol) spice_protocol="yes"
;;
--disable-libiscsi) libiscsi="disabled"
;;
@@ -1866,6 +1875,7 @@ disabled with --disable-FEATURE, default is enabled if available
vhost-user-blk-server vhost-user-blk server support
vhost-vdpa vhost-vdpa kernel backend support
spice spice
+ spice-protocol spice-protocol
rbd rados block device (rbd)
libiscsi iscsi support
libnfs nfs support
@@ -4149,6 +4159,19 @@ fi
##########################################
# spice probe
+if test "$spice_protocol" != "no" ; then
+ spice_protocol_cflags=$($pkg_config --cflags spice-protocol 2>/dev/null)
+ if $pkg_config --atleast-version=0.12.3 spice-protocol; then
+ spice_protocol="yes"
+ else
+ if test "$spice_protocol" = "yes" ; then
+ feature_not_found "spice_protocol" \
+ "Install spice-protocol(>=0.12.3) devel"
+ fi
+ spice_protocol="no"
+ fi
+fi
+
if test "$spice" != "no" ; then
cat > $TMPC << EOF
#include <spice.h>
@@ -4157,13 +4180,13 @@ 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.12.5 spice-server && \
- $pkg_config --atleast-version=0.12.3 spice-protocol && \
+ test "$spice_protocol" = "yes" && \
compile_prog "$spice_cflags" "$spice_libs" ; then
spice="yes"
else
if test "$spice" = "yes" ; then
feature_not_found "spice" \
- "Install spice-server(>=0.12.5) and spice-protocol(>=0.12.3) devel"
+ "Install spice-server(>=0.12.5) devel"
fi
spice="no"
fi
@@ -5807,9 +5830,14 @@ fi
if test "$posix_memalign" = "yes" ; then
echo "CONFIG_POSIX_MEMALIGN=y" >> $config_host_mak
fi
+
+if test "$spice_protocol" = "yes" ; then
+ echo "CONFIG_SPICE_PROTOCOL=y" >> $config_host_mak
+ echo "SPICE_PROTOCOL_CFLAGS=$spice_protocol_cflags" >> $config_host_mak
+fi
if test "$spice" = "yes" ; then
echo "CONFIG_SPICE=y" >> $config_host_mak
- echo "SPICE_CFLAGS=$spice_cflags" >> $config_host_mak
+ echo "SPICE_CFLAGS=$spice_cflags $spice_protocol_cflags" >> $config_host_mak
echo "SPICE_LIBS=$spice_libs" >> $config_host_mak
fi
diff --git a/meson.build b/meson.build
index d8bb1ec5aa97..51898a96ba4d 100644
--- a/meson.build
+++ b/meson.build
@@ -445,11 +445,15 @@ if 'CONFIG_LIBJACK' in config_host
endif
spice = not_found
spice_headers = not_found
+spice_protocol = not_found
if 'CONFIG_SPICE' in config_host
spice = declare_dependency(compile_args: config_host['SPICE_CFLAGS'].split(),
link_args: config_host['SPICE_LIBS'].split())
spice_headers = declare_dependency(compile_args: config_host['SPICE_CFLAGS'].split())
endif
+if 'CONFIG_SPICE_PROTOCOL' in config_host
+ spice_protocol = declare_dependency(compile_args: config_host['SPICE_PROTOCOL_CFLAGS'].split())
+endif
rt = cc.find_library('rt', required: false)
libdl = not_found
if 'CONFIG_PLUGIN' in config_host
--
2.31.1
next prev parent reply other threads:[~2021-05-05 6:11 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-05 6:08 [PATCH v5 0/9] ui: add vdagent implementation and clipboard support Gerd Hoffmann
2021-05-05 6:08 ` Gerd Hoffmann [this message]
2021-05-05 6:08 ` [PATCH v5 2/9] ui: add clipboard infrastructure Gerd Hoffmann
2021-05-05 6:08 ` [PATCH v5 3/9] ui: add clipboard documentation Gerd Hoffmann
2021-05-05 6:08 ` [PATCH v5 4/9] ui/vdagent: core infrastructure Gerd Hoffmann
2021-05-05 9:54 ` Marc-André Lureau
2021-05-11 9:04 ` Gerd Hoffmann
2021-05-11 9:27 ` Marc-André Lureau
2021-05-05 6:08 ` [PATCH v5 5/9] ui/vdagent: add mouse support Gerd Hoffmann
2021-05-05 6:08 ` [PATCH v5 6/9] ui/vdagent: add clipboard support Gerd Hoffmann
2021-05-05 6:08 ` [PATCH v5 7/9] ui/vnc: " Gerd Hoffmann
2021-05-05 6:09 ` [PATCH v5 8/9] ui/gtk: move struct GtkDisplayState to ui/gtk.h Gerd Hoffmann
2021-05-05 6:09 ` [PATCH v5 9/9] ui/gtk: add clipboard support Gerd Hoffmann
2021-05-05 6:21 ` [PATCH v5 0/9] ui: add vdagent implementation and " no-reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210505060901.828658-2-kraxel@redhat.com \
--to=kraxel@redhat.com \
--cc=armbru@redhat.com \
--cc=marcandre.lureau@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).