From: Nikos Mavrogiannopoulos Date: Sun, 16 Sep 2012 19:20:04 +0000 (+0200) Subject: Use the pkg-config macro to find libtasn1. X-Git-Tag: gnutls_3_1_2~58 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3efa70984ec512173e8cb54ec4f022373ac2f45a;p=thirdparty%2Fgnutls.git Use the pkg-config macro to find libtasn1. --- diff --git a/lib/Makefile.am b/lib/Makefile.am index 8df6d9b4d8..d0951d44d2 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -37,6 +37,7 @@ AM_CPPFLAGS = \ -I$(srcdir)/includes \ -I$(builddir)/includes \ -I$(srcdir)/x509 \ + $(LIBTASN1_CFLAGS) \ $(P11_KIT_CFLAGS) if ENABLE_OPENPGP @@ -142,7 +143,7 @@ endif if ENABLE_MINITASN1 libgnutls_la_LIBADD += minitasn1/libminitasn1.la else -libgnutls_la_LDFLAGS += $(LTLIBTASN1) +libgnutls_la_LDFLAGS += $(LIBTASN1_LIBS) endif if ENABLE_NETTLE diff --git a/m4/hooks.m4 b/m4/hooks.m4 index ed5cb2fe6d..b38c27e8cc 100644 --- a/m4/hooks.m4 +++ b/m4/hooks.m4 @@ -99,10 +99,8 @@ fi included_libtasn1=$withval, included_libtasn1=no) if test "$included_libtasn1" = "no"; then - AC_LIB_HAVE_LINKFLAGS(tasn1,, [#include ], - [asn1_check_version (NULL)]) - if test "$ac_cv_libtasn1" != yes; then - included_libtasn1=yes + PKG_CHECK_MODULES(LIBTASN1, [libtasn1 >= 2.14], [], [included_libtasn1=yes]) + if test "$included_libtasn1" = yes; then AC_MSG_WARN([[ *** *** Libtasn1 was not found. Will use the included one.