prelude-manager/master: Use pkg-config to check for GnuTLS

[email protected] Fri, 11 Sep 2009 11:11:44 +0200 (CEST)
Newsgroups gmane.comp.security.ids.prelude.cvs
Message-ID <[email protected]>
commit 2f7e9dcb0718ef4e0f5321d87ab5065955e6d473
Author: Pierre Chifflier <[email protected]>
Date:   Wed Aug 19 21:20:01 2009 +0200

    Use pkg-config to check for GnuTLS
    
    Recent versions of GnuTLS (>= 2.8.x) do not provide libgnutls-config script
    anymore.
    Use pkg-config first to check for GnuTLS, and fall back to old method
    if not found to keep compatibility with previous versions.
    
    Signed-off-by: Pierre Chifflier <[email protected]>


========================================

 configure.in |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

========================================

diff --git a/configure.in b/configure.in
index 74cffa0..8b61354 100644
--- a/configure.in
+++ b/configure.in
@@ -76,10 +76,11 @@ fi
 dnl **************************************************
 dnl * Check for GnuTLS.                              *
 dnl **************************************************
-AM_PATH_LIBGNUTLS(1.0.17, gnutls=yes, gnutls=no)
-if test x$gnutls != xyes; then
-        AC_MSG_ERROR(libgnutls is required in order to build prelude-manager.)
-fi
+GNUTLS_MIN_VERSION=1.0.17
+
+PKG_CHECK_EXISTS(gnutls,
+                 [PKG_CHECK_MODULES([LIBGNUTLS], [gnutls >= $GNUTLS_MIN_VERSION])],
+                 [AM_PATH_LIBGNUTLS($GNUTLS_MIN_VERSION, [], [AC_MSG_ERROR(libgnutls is required in order to build prelude-manager.)])])
 
 old_LIBS=$LIBS
 old_CPPFLAGS=$CPPFLAGS
_______________________________________________
Prelude-cvslog site list
[email protected]
http://lists.prelude-ids.org/mailman/listinfo/prelude-cvslog