From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:58656) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T1Ysx-0004kl-NF for qemu-devel@nongnu.org; Wed, 15 Aug 2012 04:23:28 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1T1Ysw-0002RS-U4 for qemu-devel@nongnu.org; Wed, 15 Aug 2012 04:23:27 -0400 Received: from mx1.redhat.com ([209.132.183.28]:56719) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T1Ysw-0002RB-MR for qemu-devel@nongnu.org; Wed, 15 Aug 2012 04:23:26 -0400 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q7F8NPjU001796 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 15 Aug 2012 04:23:25 -0400 Message-ID: <502B5C7B.4020502@redhat.com> Date: Wed, 15 Aug 2012 10:23:23 +0200 From: Gerd Hoffmann MIME-Version: 1.0 References: <5023C014.2080407@redhat.com> <1344522080-28833-1-git-send-email-alevy@redhat.com> In-Reply-To: <1344522080-28833-1-git-send-email-alevy@redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v4 1/2] qxl: add QXL_IO_MONITORS_CONFIG_ASYNC List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Alon Levy Cc: qemu-devel@nongnu.org On 08/09/12 16:21, Alon Levy wrote: > Revision bumped to 4 for new IO support, enabled for spice-server >= > 0.11.1. New io enabled iff spice-server >= 0.11.1 && spice-protocol >= > 0.12.0. Patch doesn't apply cleanly to master. > + if $pkg_config --atleast-version=0.12.0 spice-protocol >/dev/null 2>&1; then > + QEMU_CFLAGS="$QEMU_CFLAGS -DQXL_HAS_IO_MONITORS_CONFIG_ASYNC" > + fi /me thinks now with spice-server having no dependency any more on spice-protocol we should add a #define SPICE_PROTOCOL_VERSION to spice-protocol so we don't need constructs like this. Or maybe just use #ifndef QXL_HAS_IO_MONITORS_CONFIG_ASYNC #define QXL_HAS_IO_MONITORS_CONFIG_ASYNC $whatever #endif ? > +#if SPICE_SERVER_VERSION >= 0x000b01 /* 0.11.1 */ > +#ifdef QXL_HAS_IO_MONITORS_CONFIG_ASYNC Can be on a single line: #if (SPICE_SERVER_VERSION >= 0x000b01) && defined(QXL_HAS_IO_MONITORS_CONFIG_ASYNC) Or: #if (SPICE_SERVER_VERSION >= 0x000b01) && (SPICE_PROTOCOL_VERSION >= ...) cheers, Gerd