From patchwork Fri Mar 15 11:46:16 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Qingtang Zhou X-Patchwork-Id: 227959 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 607DF2C00A7 for ; Fri, 15 Mar 2013 22:47:02 +1100 (EST) Received: from localhost ([::1]:51764 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UGT6B-0006Ub-9t for incoming@patchwork.ozlabs.org; Fri, 15 Mar 2013 07:46:59 -0400 Received: from eggs.gnu.org ([208.118.235.92]:40813) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UGT5q-0006UG-S0 for qemu-devel@nongnu.org; Fri, 15 Mar 2013 07:46:41 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UGT5m-000198-R8 for qemu-devel@nongnu.org; Fri, 15 Mar 2013 07:46:38 -0400 Received: from mx1.redhat.com ([209.132.183.28]:49505) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UGT5m-00018t-JG for qemu-devel@nongnu.org; Fri, 15 Mar 2013 07:46:34 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r2FBkV0U007982 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 15 Mar 2013 07:46:32 -0400 Received: from qzhou-work.nay.redhat.com (dhcp-8-108.nay.redhat.com [10.66.8.108]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r2FBkT4l026041; Fri, 15 Mar 2013 07:46:30 -0400 From: Qingtang Zhou To: qemu-devel@nongnu.org Date: Fri, 15 Mar 2013 19:46:16 +0800 Message-Id: <1363347976-18263-1-git-send-email-zhouqt@gmail.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.23 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 209.132.183.28 Cc: Blue Swirl , Qingtang Zhou , Anthony Liguori Subject: [Qemu-devel] [PATCH] configure: Print out missing library when configure fails 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 patch let configure tool print out which library is missing besides the qemu feature name when it fails. CC: Blue Swirl CC: Anthony Liguori Signed-off-by: Qingtang Zhou --- configure | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/configure b/configure index 46a7594..ca6258d 100755 --- a/configure +++ b/configure @@ -1352,9 +1352,14 @@ esac feature_not_found() { feature=$1 + shift + missing_lib=$* echo "ERROR" echo "ERROR: User requested feature $feature" + if [ "$missing_lib" != "" ]; then + echo "ERROR: This feature needs $missing_lib library" + fi echo "ERROR: configure was not able to find it" echo "ERROR" exit 1; @@ -1677,7 +1682,7 @@ if test "$gtk" != "no"; then gtk="yes" else if test "$gtk" = "yes" ; then - feature_not_found "gtk" + feature_not_found "gtk" "$gtkpackage-$gtkversion" "$vtepackage-$vteversion" fi gtk="no" fi @@ -2472,7 +2477,7 @@ EOF libs_softmmu="$glusterfs_libs $libs_softmmu" else if test "$glusterfs" = "yes" ; then - feature_not_found "GlusterFS backend support" + feature_not_found "GlusterFS backend support" "gfapi" "gfrpc" "gfxdr" fi glusterfs=no fi @@ -2784,7 +2789,7 @@ if test "$docs" != "no" ; then docs=yes else if test "$docs" = "yes" ; then - feature_not_found "docs" + feature_not_found "docs" "makeinfo" "pod2man" fi docs=no fi @@ -2905,7 +2910,7 @@ EOF spice_server_version=$($pkg_config --modversion spice-server) else if test "$spice" = "yes" ; then - feature_not_found "spice" + feature_not_found "spice" "spice-protocol" "spice-server" fi spice="no" fi @@ -2955,7 +2960,7 @@ if test "$usb_redir" != "no" ; then libs_softmmu="$libs_softmmu $usb_redir_libs" else if test "$usb_redir" = "yes"; then - feature_not_found "usb-redir" + feature_not_found "usb-redir" "libusbredirparser-0.5" fi usb_redir="no" fi