From 7170260942c403a1c6e8359e085e48cf4a14668c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20Elio=20Petten=C3=B2?= Date: Mon, 21 Mar 2011 16:41:41 +0100 Subject: [PATCH] build-sys: properly enable support for zlib in lsusb Define HAVE_LIBZ to enable the code and append -lz to the linking line. Cc: Gabor Z. Papp Signed-off-by: Greg Kroah-Hartman --- Makefile.am | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Makefile.am b/Makefile.am index 00a43e9..aa3644a 100644 --- a/Makefile.am +++ b/Makefile.am @@ -6,9 +6,6 @@ AM_LDFLAGS = \ data_DATA = \ usb.ids -if HAVE_ZLIB -data_DATA += usb.ids.gz -endif bin_PROGRAMS = \ lsusb @@ -35,6 +32,12 @@ lsusb_CPPFLAGS = \ lsusb_LDADD = \ $(LIBUSB_LIBS) +if HAVE_ZLIB +data_DATA += usb.ids.gz +lsusb_CPPFLAGS += -DHAVE_LIBZ +lsusb_LDADD += -lz +endif + man_MANS = \ lsusb.8 \ usb-devices.1