diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2012-09-08 21:25:33 +0200 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2012-09-08 22:49:39 +0200 |
commit | 92f6779f509ece6ac7a8659c90bc335677cc62ea (patch) | |
tree | 0b1ed0f72a54ec9567d480358ab10e2dcf126a23 /tests/conntrackd/dissect-sync/configure.ac | |
parent | 46faeab56cf4117f41cb6f1f1c40a9c18a81372f (diff) | |
download | conntrack-tools-92f6779f509ece6ac7a8659c90bc335677cc62ea.tar.gz |
tests: add dissector for conntrackd protocoldissector
Addd rudimentary utility to dissect conntrackd's synchronization
protocol. This code should prepare the ground for some wireshark
dissector in the near future.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'tests/conntrackd/dissect-sync/configure.ac')
-rw-r--r-- | tests/conntrackd/dissect-sync/configure.ac | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/tests/conntrackd/dissect-sync/configure.ac b/tests/conntrackd/dissect-sync/configure.ac new file mode 100644 index 0000000..077a9c9 --- /dev/null +++ b/tests/conntrackd/dissect-sync/configure.ac @@ -0,0 +1,61 @@ +AC_INIT(cthelper-test, 0.0.1, pablo@netfilter.org) +AC_CONFIG_AUX_DIR([build-aux]) + +AC_CANONICAL_HOST +AC_CONFIG_MACRO_DIR([m4]) +AM_INIT_AUTOMAKE([-Wall foreign subdir-objects + tar-pax no-dist-gzip dist-bzip2 1.6]) + +dnl kernel style compile messages +m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) + +AC_SEARCH_LIBS([dlopen], [dl], [libdl_LIBS="$LIBS"; LIBS=""]) +AC_SUBST([libdl_LIBS]) + +AC_PROG_CC +AC_DISABLE_STATIC +AM_PROG_LIBTOOL +AC_PROG_INSTALL +AC_PROG_LN_S +AM_PROG_LEX +AC_PROG_YACC + +case "$host" in +*-*-linux*) ;; +*) AC_MSG_ERROR([Linux only, dude!]);; +esac + +AC_CHECK_HEADERS(arpa/inet.h) +dnl check for inet_pton +AC_CHECK_FUNCS(inet_pton) +dnl Some systems have it, but not IPv6 +if test "$ac_cv_func_inet_pton" = "yes" ; then +AC_MSG_CHECKING(if inet_pton supports IPv6) +AC_RUN_IFELSE([AC_LANG_SOURCE([[ +#ifdef HAVE_SYS_TYPES_H +#include <sys/types.h> +#endif +#ifdef HAVE_SYS_SOCKET_H +#include <sys/socket.h> +#endif +#ifdef HAVE_NETINET_IN_H +#include <netinet/in.h> +#endif +#ifdef HAVE_ARPA_INET_H +#include <arpa/inet.h> +#endif +int main() + { + struct in6_addr addr6; + if (inet_pton(AF_INET6, "::1", &addr6) < 1) + exit(1); + else + exit(0); + } + ]])],[ AC_MSG_RESULT(yes) + AC_DEFINE_UNQUOTED(HAVE_INET_PTON_IPV6, 1, [Define to 1 if inet_pton supports IPv6.]) + ],[AC_MSG_RESULT(no)],[AC_MSG_RESULT(no)]) +fi + +AC_CONFIG_FILES([Makefile]) +AC_OUTPUT |