From nobody Mon Feb 9 20:12:42 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1621601841; cv=none; d=zohomail.com; s=zohoarc; b=OV5H0BuEGU+8mwt1po8pONZtuUEVds6Das1umlNZeQHuV4z//QzKySLnBYRjNIWveacrzhb/lqHryOB8/fiRelibg3IErjMFONANsDBjgAzQJf6uX96LQf2nw3CJNiOVjHyi7QQhLvTz5wtAgZW3Y6s651dU7CG0E7lGrIT/AwI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1621601841; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=DvS2lA1LIz9bbsInz9wVxHEThudVqUdsdU1VrezB0IM=; b=imnwskWwpsG2WgZ9HJHZpZ6sxYEDfSWuhvcKn5qrgaX4gTINrxpADXwlS8sKm0LRagxjSscry3FDKTxun2hPu+UoGR0nv3HL3hELQybxYhrmK6GWgRcq2xljADA4aMgYE79VAMVi7lh64iXX4LNArFIHOJCqyaj7UAhvqGmXHMA= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1621601841104318.65625292820675; Fri, 21 May 2021 05:57:21 -0700 (PDT) Received: from localhost ([::1]:50990 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lk4iO-0006Ts-4g for importer@patchew.org; Fri, 21 May 2021 08:57:20 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:52776) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lk4ek-0006sq-Dp for qemu-devel@nongnu.org; Fri, 21 May 2021 08:53:34 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:20924) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lk4ei-0007xG-K2 for qemu-devel@nongnu.org; Fri, 21 May 2021 08:53:34 -0400 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-104-OGWMm_70Mr-whMHgygvf3A-1; Fri, 21 May 2021 08:53:30 -0400 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id B162C8A9F43 for ; Fri, 21 May 2021 12:53:29 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-112-84.ams2.redhat.com [10.36.112.84]) by smtp.corp.redhat.com (Postfix) with ESMTPS id EAB195D9D5; Fri, 21 May 2021 12:53:04 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 5EA3818007A1; Fri, 21 May 2021 14:51:19 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1621601612; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=DvS2lA1LIz9bbsInz9wVxHEThudVqUdsdU1VrezB0IM=; b=OP8xzgdlxc4wWdWuZZW0Z09EsjDUY7aLa8hoBpjVv48m1k0uzOQUQT74ifZ2vtANnl7BbM zzxtGX8szp3+35UwbBo0zZ7bbxZI6zcJl8hmuqcUKZK7HbMribIXV1S/NM/87HHtbeHppN hSSBAEnUFFVaZ/wcE8AhKCsCelVW51A= X-MC-Unique: OGWMm_70Mr-whMHgygvf3A-1 From: Gerd Hoffmann To: qemu-devel@nongnu.org Subject: [PULL 03/11] build: add separate spice-protocol config option Date: Fri, 21 May 2021 14:51:11 +0200 Message-Id: <20210521125119.3173309-4-kraxel@redhat.com> In-Reply-To: <20210521125119.3173309-1-kraxel@redhat.com> References: <20210521125119.3173309-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=kraxel@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=170.10.133.124; envelope-from=kraxel@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -31 X-Spam_score: -3.2 X-Spam_bar: --- X-Spam_report: (-3.2 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.374, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Paolo Bonzini , Markus Armbruster , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , Gerd Hoffmann Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) 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 Reviewed-by: Marc-Andr=C3=A9 Lureau Message-id: 20210519053940.1888907-1-kraxel@redhat.com Message-Id: <20210519053940.1888907-2-kraxel@redhat.com> --- configure | 36 ++++++++++++++++++++++++++++++++---- meson.build | 4 ++++ 2 files changed, 36 insertions(+), 4 deletions(-) diff --git a/configure b/configure index 9470fff09ab7..676239c69707 100755 --- a/configure +++ b/configure @@ -389,6 +389,7 @@ qom_cast_debug=3D"yes" trace_backends=3D"log" trace_file=3D"trace" spice=3D"$default_feature" +spice_protocol=3D"auto" rbd=3D"auto" smartcard=3D"$default_feature" u2f=3D"auto" @@ -1132,7 +1133,15 @@ for opt do ;; --disable-spice) spice=3D"no" ;; - --enable-spice) spice=3D"yes" + --enable-spice) + spice_protocol=3D"yes" + spice=3D"yes" + ;; + --disable-spice-protocol) + spice_protocol=3D"no" + spice=3D"no" + ;; + --enable-spice-protocol) spice_protocol=3D"yes" ;; --disable-libiscsi) libiscsi=3D"disabled" ;; @@ -1870,6 +1879,7 @@ disabled with --disable-FEATURE, default is enabled i= f 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 @@ -4153,6 +4163,19 @@ fi =20 ########################################## # spice probe +if test "$spice_protocol" !=3D "no" ; then + spice_protocol_cflags=3D$($pkg_config --cflags spice-protocol 2>/dev/nul= l) + if $pkg_config --atleast-version=3D0.12.3 spice-protocol; then + spice_protocol=3D"yes" + else + if test "$spice_protocol" =3D "yes" ; then + feature_not_found "spice_protocol" \ + "Install spice-protocol(>=3D0.12.3) devel" + fi + spice_protocol=3D"no" + fi +fi + if test "$spice" !=3D "no" ; then cat > $TMPC << EOF #include @@ -4161,13 +4184,13 @@ EOF spice_cflags=3D$($pkg_config --cflags spice-protocol spice-server 2>/dev= /null) spice_libs=3D$($pkg_config --libs spice-protocol spice-server 2>/dev/nul= l) if $pkg_config --atleast-version=3D0.12.5 spice-server && \ - $pkg_config --atleast-version=3D0.12.3 spice-protocol && \ + test "$spice_protocol" =3D "yes" && \ compile_prog "$spice_cflags" "$spice_libs" ; then spice=3D"yes" else if test "$spice" =3D "yes" ; then feature_not_found "spice" \ - "Install spice-server(>=3D0.12.5) and spice-protocol(>=3D0.12.3)= devel" + "Install spice-server(>=3D0.12.5) devel" fi spice=3D"no" fi @@ -5836,9 +5859,14 @@ fi if test "$posix_memalign" =3D "yes" ; then echo "CONFIG_POSIX_MEMALIGN=3Dy" >> $config_host_mak fi + +if test "$spice_protocol" =3D "yes" ; then + echo "CONFIG_SPICE_PROTOCOL=3Dy" >> $config_host_mak + echo "SPICE_PROTOCOL_CFLAGS=3D$spice_protocol_cflags" >> $config_host_mak +fi if test "$spice" =3D "yes" ; then echo "CONFIG_SPICE=3Dy" >> $config_host_mak - echo "SPICE_CFLAGS=3D$spice_cflags" >> $config_host_mak + echo "SPICE_CFLAGS=3D$spice_cflags $spice_protocol_cflags" >> $config_ho= st_mak echo "SPICE_LIBS=3D$spice_libs" >> $config_host_mak fi =20 diff --git a/meson.build b/meson.build index 1559e8d873a7..632b380738d3 100644 --- a/meson.build +++ b/meson.build @@ -458,11 +458,15 @@ if 'CONFIG_LIBJACK' in config_host endif spice =3D not_found spice_headers =3D not_found +spice_protocol =3D not_found if 'CONFIG_SPICE' in config_host spice =3D declare_dependency(compile_args: config_host['SPICE_CFLAGS'].s= plit(), link_args: config_host['SPICE_LIBS'].split()) spice_headers =3D declare_dependency(compile_args: config_host['SPICE_CF= LAGS'].split()) endif +if 'CONFIG_SPICE_PROTOCOL' in config_host + spice_protocol =3D declare_dependency(compile_args: config_host['SPICE_P= ROTOCOL_CFLAGS'].split()) +endif rt =3D cc.find_library('rt', required: false) libdl =3D not_found if 'CONFIG_PLUGIN' in config_host --=20 2.31.1