--- gvpe/configure.ac 2004/06/11 15:56:10 1.31 +++ gvpe/configure.ac 2007/03/29 17:35:20 1.45 @@ -2,9 +2,9 @@ AC_PREREQ(2.59) AC_INIT -AC_CONFIG_SRCDIR([src/vped.C]) +AC_CONFIG_SRCDIR([src/gvpe.C]) AC_CANONICAL_TARGET -AM_INIT_AUTOMAKE(gvpe, 1.7) +AM_INIT_AUTOMAKE(gvpe, 2.01) AC_CONFIG_HEADERS([config.h]) AM_MAINTAINER_MODE @@ -19,21 +19,32 @@ ]) AH_BOTTOM([ +typedef unsigned char u8; +typedef signed char s8; + #if __CYGWIN__ -typedef unsigned char u8; typedef unsigned short u16; typedef unsigned int u32; +typedef signed short s16; +typedef signed int s32; #else #include /* old modula-2 habits */ -typedef unsigned char u8; typedef uint16_t u16; typedef uint32_t u32; +typedef int16_t s16; +typedef int32_t s32; +#endif + #endif +#if HAVE_CLOCALE +# define CLOCALE +#else +# define CLOCALE #endif ]) @@ -46,7 +57,7 @@ # Enable GNU extensions. # Define this here, not in acconfig's @TOP@ section, since definitions # in the latter don't make it into the configure-time tests. -AC_DEFINE([_GNU_SOURCE], 1, [Enable GNU extenstions]) +AC_DEFINE([_GNU_SOURCE], 1, [Enable GNU extensions]) # do NOT define POSIX_SOURCE, sicne this clashes with many BSDs dnl AC_DEFINE([_POSIX_SOURCE], 1, [Enable POSIX 1003.1 extensions]) @@ -68,17 +79,21 @@ AC_ARG_ENABLE(iftype, [AS_HELP_STRING(--enable-iftype=TYPE/SUBTYPE, Use kernel/net device interface TYPE/SUBTYPE. - Working combinations are: + Working combinations are (see doc/gvpe.osdep.5.pod): "native/linux" "tincd/linux" + "tincd/netbsd" "tincd/freebsd" "tincd/openbsd" + "native/darwin" "tincd/darwin" "native/cygwin"; Untested combinations are: - "tincd/netbsd" + "tincd/bsd" "tincd/solaris" - "tincd/mingw"; + "tincd/mingw" + "tincd/raw_socket" + "tincd/uml_socket"; Broken combinations are: "tincd/cygwin"; The default is to autodetect. @@ -105,7 +120,7 @@ AC_DEFINE(HAVE_FREEBSD, 1, [FreeBSD]) ;; *darwin*) - IFTYPE=tincd + IFTYPE=native IFSUBTYPE=darwin AC_DEFINE(HAVE_DARWIN, 1, [Darwin (MacOS/X)]) ;; @@ -145,7 +160,7 @@ dnl Checks for libraries. AC_LANG(C++) -AC_CHECK_HEADERS(ext/hash_map) +AC_CHECK_HEADERS(ext/hash_map clocale) dnl Checks for header files. AC_CHECK_HEADERS([fcntl.h inttypes.h limits.h malloc.h stdint.h strings.h syslog.h unistd.h \ @@ -251,6 +266,11 @@ AM_CONDITIONAL(ROHC, test x$rohc = xtrue) +dnl AC_ARG_ENABLE(bridging, +dnl [AS_HELP_STRING(--enable-bridging,enable bridging support (default disabled).)], +dnl AC_DEFINE_UNQUOTED(ENABLE_BRIDGING, 1, [bridging support.]) +dnl ) + AC_ARG_ENABLE(icmp, [AS_HELP_STRING(--enable-icmp,enable icmp protocol support (default disabled).)], AC_DEFINE_UNQUOTED(ENABLE_ICMP, 1, [ICMP protocol support.]) @@ -263,7 +283,12 @@ AC_ARG_ENABLE(dns, [AS_HELP_STRING(--enable-dns,enable dns tunnel protocol support (DOES NOT WORK).)], - AC_DEFINE_UNQUOTED(ENABLE_DNS, 1, [DNS tunnel protocol support.]) + [ + AC_CHECK_HEADER(gmp.h,,[AC_MSG_ERROR([gmp.h not found, required for --enable-dns])]) + AC_CHECK_LIB(gmp,main,,[AC_MSG_ERROR([libgmp not found, required for --enable-dns])]) + + AC_DEFINE_UNQUOTED(ENABLE_DNS, 1, [DNS tunnel protocol support.]) + ] ) AC_ARG_ENABLE(http-proxy, @@ -303,10 +328,10 @@ ) AC_DEFINE_UNQUOTED(ENABLE_COMPRESSION, $COMPRESS, [Enable compression support.]) -CIPHER=bf_cbc +CIPHER=aes_128_cbc AC_ARG_ENABLE(cipher, [AS_HELP_STRING(--enable-cipher,[ - Select the symmetric cipher (default "bf"). + Select the symmetric cipher (default "aes-128"). Must be one of "bf" (blowfish), "aes-128" (rijndael), "aes-192" or "aes-256".])], if test "x$enableval" = xbf ; then CIPHER=bf_cbc ; fi if test "x$enableval" = xaes-128; then CIPHER=aes_128_cbc; fi @@ -315,11 +340,13 @@ ) AC_DEFINE_UNQUOTED(ENABLE_CIPHER, EVP_${CIPHER}, [Select the symmetric cipher to use.]) -DIGEST=sha1 +DIGEST=ripemd160 AC_ARG_ENABLE(digest, [AS_HELP_STRING(--enable-digest,[ - Select the digets algorithm to use (default "sha1"). Must be one of - "sha1", "ripemd160", "md5" or "md4" (insecure).])], + Select the digest algorithm to use (default "ripemd160"). Must be one of + "sha512", "sha256", "sha1", "ripemd160", "md5" or "md4" (insecure).])], + if test "x$enableval" = xsha512 ; then DIGEST=sha512 ; fi + if test "x$enableval" = xsha256 ; then DIGEST=sha256 ; fi if test "x$enableval" = xsha1 ; then DIGEST=sha1 ; fi if test "x$enableval" = xripemd160; then DIGEST=ripemd160; fi if test "x$enableval" = xmd5 ; then DIGEST=md5 ; fi @@ -343,7 +370,15 @@ dnl LDFLAGS="$LDFLAGS -Wl,--gc-sections" dnl fi -AC_CONFIG_COMMANDS_POST([ +AC_SUBST(INCLUDES) + +AC_CONFIG_FILES([Makefile po/Makefile.in +src/Makefile +doc/Makefile +lib/Makefile +m4/Makefile +]) +AC_OUTPUT echo echo "***" @@ -355,7 +390,10 @@ echo "*** HMAC length: $HMAC" echo "*** RAND used: $RAND" echo "*** Max. MTU: $MTU" -echo "*** Compression: $COMPRESS" + +echo "***" +echo "*** Enable options:" +grep ENABLE_ config.h | sed -e 's/^/*** /' if test "x$DIGEST" = xmd4; then echo "***" @@ -373,18 +411,6 @@ fi echo "***" - echo -]) - -AC_SUBST(INCLUDES) -AC_CONFIG_FILES([Makefile po/Makefile.in -src/Makefile -src/rohc/Makefile -doc/Makefile -lib/Makefile -m4/Makefile -]) -AC_OUTPUT