Received: from eggs.gnu.org ([208.118.235.92]:50820) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tu50U-00024V-7h for qemu-devel@nongnu.org; Sat, 12 Jan 2013 12:36:38 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Tu50Q-0000OK-VW for qemu-devel@nongnu.org; Sat, 12 Jan 2013 12:36:34 -0500 Received: from mail-wg0-f51.google.com ([74.125.82.51]:43036) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tu50Q-0000OG-NY for qemu-devel@nongnu.org; Sat, 12 Jan 2013 12:36:30 -0500 Received: by mail-wg0-f51.google.com with SMTP id gg4so1368491wgb.30 for ; Sat, 12 Jan 2013 09:36:30 -0800 (PST) Sender: Paolo Bonzini From: Paolo Bonzini Date: Sat, 12 Jan 2013 18:35:19 +0100 Message-Id: <1358012138-21613-9-git-send-email-pbonzini@redhat.com> In-Reply-To: <1358012138-21613-1-git-send-email-pbonzini@redhat.com> References: <1358012138-21613-1-git-send-email-pbonzini@redhat.com> Subject: [Qemu-devel] [PATCH 08/27] libcacard: require libtool to build it List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Do not fail at build time, instead just disable the library if libtool is not present. Signed-off-by: Paolo Bonzini --- Makefile | 2 ++ configure | 3 ++- libcacard/Makefile | 8 -------- rules.mak | 6 +----- 4 files changed, 5 insertions(+), 14 deletions(-) diff --git a/Makefile b/Makefile index 3c960a1..f035a61 100644 --- a/Makefile +++ b/Makefile @@ -160,12 +160,14 @@ libqemustub.a: $(stub-obj-y) ###################################################################### # Support building shared library libcacard +ifeq ($(CONFIG_SMARTCARD_NSS),y) .PHONY: libcacard.la install-libcacard libcacard.la: $(oslib-obj-y) qemu-timer-common.o $(trace-obj-y) $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C libcacard V="$(V)" TARGET_DIR="$*/" libcacard.la,) install-libcacard: libcacard.la $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C libcacard V="$(V)" TARGET_DIR="$*/" install-libcacard,) +endif ###################################################################### diff --git a/configure b/configure index 35762f5..39358ad 100755 --- a/configure +++ b/configure @@ -2824,7 +2824,8 @@ EOF if test "$werror" = "yes"; then test_cflags="-Werror $test_cflags" fi - if $pkg_config --atleast-version=3.12.8 nss >/dev/null 2>&1 && \ + if test -n "$libtool" && + $pkg_config --atleast-version=3.12.8 nss >/dev/null 2>&1 && \ compile_prog "$test_cflags" "$libcacard_libs"; then smartcard_nss="yes" QEMU_CFLAGS="$QEMU_CFLAGS $libcacard_cflags" diff --git a/libcacard/Makefile b/libcacard/Makefile index 08a47e0..a526eae 100644 --- a/libcacard/Makefile +++ b/libcacard/Makefile @@ -31,13 +31,6 @@ all: libcacard.la libcacard.pc ######################################################################### # Rules for building libcacard standalone library -ifeq ($(LIBTOOL),) -libcacard.la: - @echo "libtool is missing, please install and rerun configure"; exit 1 - -install-libcacard: - @echo "libtool is missing, please install and rerun configure"; exit 1 -else libcacard.la: $(libcacard.lib-y) $(QEMU_OBJS_LIB) $(call quiet-command,$(LIBTOOL) --mode=link --tag=CC $(CC) -rpath $(libdir) -o $@ $^ $(libcacard_libs)," lt LINK $@") @@ -63,4 +56,3 @@ install-libcacard: libcacard.pc libcacard.la vscclient for inc in *.h; do \ $(INSTALL_DATA) $(libcacard_srcpath)/$$inc "$(DESTDIR)$(libcacard_includedir)"; \ done -endif diff --git a/rules.mak b/rules.mak index 5865e9b..4297345 100644 --- a/rules.mak +++ b/rules.mak @@ -21,11 +21,7 @@ QEMU_CFLAGS += -I$(