From patchwork Tue Jul 26 09:30:40 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alon Levy X-Patchwork-Id: 106814 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [140.186.70.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id C3F03B70C5 for ; Tue, 26 Jul 2011 19:31:23 +1000 (EST) Received: from localhost ([::1]:37370 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qldyv-0008Bx-5X for incoming@patchwork.ozlabs.org; Tue, 26 Jul 2011 05:31:17 -0400 Received: from eggs.gnu.org ([140.186.70.92]:47147) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qldyn-00083Y-0Q for qemu-devel@nongnu.org; Tue, 26 Jul 2011 05:31:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qldyl-0002Cq-Tj for qemu-devel@nongnu.org; Tue, 26 Jul 2011 05:31:08 -0400 Received: from mx1.redhat.com ([209.132.183.28]:21434) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qldyl-0002Cj-MV for qemu-devel@nongnu.org; Tue, 26 Jul 2011 05:31:07 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p6Q9V6uj002579 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 26 Jul 2011 05:31:06 -0400 Received: from bow.tlv.redhat.com (dhcp-3-110.tlv.redhat.com [10.35.3.110]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id p6Q9V4Fr022771; Tue, 26 Jul 2011 05:31:05 -0400 From: Alon Levy To: qemu-devel@nongnu.org Date: Tue, 26 Jul 2011 12:30:40 +0300 Message-Id: <1311672640-18000-1-git-send-email-alevy@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [PATCH] configure: add --disable-zlib-test X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org This is required for building libcacard which doesn't itself require zlib without bringing in this requirement to the build environment. Signed-off-by: Alon Levy --- I'd like this to go into 0.15.0 too, it makes building libcacard possible without zlib-devel being installed. --- configure | 23 ++++++++++++++--------- 1 files changed, 14 insertions(+), 9 deletions(-) diff --git a/configure b/configure index 88159ac..5fc0f82 100755 --- a/configure +++ b/configure @@ -178,6 +178,7 @@ rbd="" smartcard="" smartcard_nss="" opengl="" +zlib="yes" # parse CC options first for opt do @@ -743,6 +744,8 @@ for opt do ;; --enable-smartcard-nss) smartcard_nss="yes" ;; + --disable-zlib-test) zlib="no" + ;; *) echo "ERROR: unknown option $opt"; show_help="yes" ;; esac @@ -1172,18 +1175,20 @@ fi ########################################## # zlib check -cat > $TMPC << EOF +if test "$zlib" != "no" ; then + cat > $TMPC << EOF #include int main(void) { zlibVersion(); return 0; } EOF -if compile_prog "" "-lz" ; then - : -else - echo - echo "Error: zlib check failed" - echo "Make sure to have the zlib libs and headers installed." - echo - exit 1 + if compile_prog "" "-lz" ; then + : + else + echo + echo "Error: zlib check failed" + echo "Make sure to have the zlib libs and headers installed." + echo + exit 1 + fi fi ##########################################