dnl -*-fundamental-*-
dnl
-dnl $Id: configure.in,v 1.6 2001/06/19 22:13:57 mdw Exp $
+dnl $Id: configure.in,v 1.7 2003/04/06 10:25:17 mdw Exp $
dnl
dnl Configuration script for TrIPE
dnl
dnl ----- Revision history --------------------------------------------------
dnl
dnl $Log: configure.in,v $
+dnl Revision 1.7 2003/04/06 10:25:17 mdw
+dnl Support Linux TUN/TAP device. Fix some bugs.
+dnl
dnl Revision 1.6 2001/06/19 22:13:57 mdw
dnl Version bump.
dnl
dnl
AC_INIT(tripe.c)
-AM_INIT_AUTOMAKE(tripe, 1.0.0pre2)
+AM_INIT_AUTOMAKE(tripe, 1.0.0pre3)
AM_CONFIG_HEADER(config.h)
AC_CANONICAL_HOST
AC_PROG_CC
-mdw_GCC_FLAGS
+mdw_GCC_FLAGS([-Wall])
mdw_OPT_TRACE
+AC_ARG_WITH([linux-includes],
+[ --with-linux-includes=DIR
+ search for Linux kernel includes in DIR],
+[CFLAGS="$CFLAGS -I$withval"],
+[:])
+
case $host_os in
linux*)
- tun=unet
- AC_DEFINE([TUN_TYPE], [TUN_UNET])
+ case `uname -r` in
+ 2.[4-9].* | 2.??*.* | 3-9.* | ??*.*)
+ tun=linux
+ AC_DEFINE([TUN_TYPE], [TUN_LINUX])
+ ;;
+ *)
+ tun=unet
+ AC_DEFINE([TUN_TYPE], [TUN_UNET])
+ ;;
+ esac
;;
*bsd*)
tun=bsd