Check for GnuTLS library when tools are enabled
authorMarcel Holtmann <marcel@holtmann.org>
Fri, 29 Oct 2010 18:08:05 +0000 (20:08 +0200)
committerMarcel Holtmann <marcel@holtmann.org>
Fri, 29 Oct 2010 18:08:05 +0000 (20:08 +0200)
Makefile.am
configure.ac

index 9ac6f3a..056fff8 100644 (file)
@@ -78,8 +78,7 @@ src_connmand_SOURCES += $(gsupplicant_sources)
 endif
 
 src_connmand_LDADD = $(builtin_libadd) @GLIB_LIBS@ @DBUS_LIBS@ \
-                                               @CAPNG_LIBS@ @XTABLES_LIBS@ \
-                                                       -lresolv -ldl
+                               @CAPNG_LIBS@ @XTABLES_LIBS@ -lresolv -ldl
 
 src_connmand_LDFLAGS = -Wl,--export-dynamic \
                                -Wl,--version-script=$(srcdir)/src/connman.ver
@@ -102,8 +101,8 @@ build_plugindir = $(plugindir)
 build_scriptdir = $(scriptdir)
 endif
 
-AM_CFLAGS = @XTABLES_CFLAGS@ @NETLINK_CFLAGS@ @CAPNG_CFLAGS@ \
-                       @DBUS_CFLAGS@ @GLIB_CFLAGS@ @XTABLES_CFLAGS@ \
+AM_CFLAGS = @DBUS_CFLAGS@ @GLIB_CFLAGS@ @CAPNG_CFLAGS@ @XTABLES_CFLAGS@ \
+                               @NETLINK_CFLAGS@ @GNUTLS_CFLAGS@ \
                                $(builtin_cflags) \
                                -DCONNMAN_PLUGIN_BUILTIN \
                                -DSTATEDIR=\""$(statedir)"\" \
index f36a766..1f406f0 100644 (file)
@@ -317,7 +317,7 @@ fi
 AC_SUBST(DBUS_DATADIR)
 
 PKG_CHECK_MODULES(XTABLES, xtables, dummy=yes,
-                       AC_MSG_ERROR(xtables library is required))
+                               AC_MSG_ERROR(Xtables library is required))
 AC_SUBST(XTABLES_CFLAGS)
 AC_SUBST(XTABLES_LIBS)
 
@@ -360,6 +360,11 @@ if (test "${enable_tools}" = "yes"); then
                                AC_MSG_ERROR(Netlink library is required))
        AC_SUBST(NETLINK_CFLAGS)
        AC_SUBST(NETLINK_LIBS)
+
+       PKG_CHECK_MODULES(GNUTLS, gnutls, dummy=yes,
+                               AC_MSG_ERROR(GnuTLS library is required))
+       AC_SUBST(GNUTLS_CFLAGS)
+       AC_SUBST(GNUTLS_LIBS)
 fi
 AM_CONDITIONAL(TOOLS, test "${enable_tools}" = "yes")