configure.in (26180) | configure.in (39297) |
---|---|
1dnl @(#) $Header: configure.in,v 1.58 96/11/29 15:37:31 leres Exp $ (LBL) | 1dnl @(#) $Header: configure.in,v 1.71 97/07/27 22:17:59 leres Exp $ (LBL) |
2dnl | 2dnl |
3dnl Copyright (c) 1994, 1995, 1996 | 3dnl Copyright (c) 1994, 1995, 1996, 1997 |
4dnl The Regents of the University of California. All rights reserved. 5dnl 6dnl Process this file with autoconf to produce a configure script. 7dnl 8 9AC_INIT(tcpdump.c) 10 11AC_CANONICAL_SYSTEM 12 13umask 002 14 15if test -z "$PWD" ; then 16 PWD=`pwd` 17fi 18 19AC_LBL_C_INIT(V_CCOPT, V_INCLS) 20 | 4dnl The Regents of the University of California. All rights reserved. 5dnl 6dnl Process this file with autoconf to produce a configure script. 7dnl 8 9AC_INIT(tcpdump.c) 10 11AC_CANONICAL_SYSTEM 12 13umask 002 14 15if test -z "$PWD" ; then 16 PWD=`pwd` 17fi 18 19AC_LBL_C_INIT(V_CCOPT, V_INCLS) 20 |
21AC_CHECK_HEADERS(fcntl.h net/slip.h rpc/rpcent.h) | 21AC_CHECK_HEADERS(fcntl.h malloc.h memory.h rpc/rpcent.h) |
22AC_HEADER_TIME 23 | 22AC_HEADER_TIME 23 |
24case "$target_os" in 25 26linux*) 27 AC_MSG_CHECKING(Linux kernel version) 28 AC_CACHE_VAL(ac_cv_linux_vers, 29 ac_cv_linux_vers=`uname -r 2>&1 | \ 30 sed -n -e '$s/.* //' -e '$s/\..*//p'`) 31 AC_MSG_RESULT($ac_cv_linux_vers) 32 if test $ac_cv_linux_vers -lt 2 ; then 33 AC_MSG_ERROR(version 2 or higher required; see the INSTALL doc for more info) 34 fi 35 AC_DEFINE(HAVE_NET_SLIP_H) 36 ;; 37 38*) 39 AC_CHECK_HEADERS(net/slip.h) 40 ;; 41esac 42 |
|
24AC_REPLACE_FUNCS(vfprintf strcasecmp) 25AC_CHECK_FUNCS(ether_ntoa setlinebuf) 26 | 43AC_REPLACE_FUNCS(vfprintf strcasecmp) 44AC_CHECK_FUNCS(ether_ntoa setlinebuf) 45 |
27dnl The following generates a warning... | 46dnl The following generates a warning from autoconf... |
28AC_C_BIGENDIAN 29 30AC_CHECK_LIB(dnet, main) 31AC_CHECK_LIB(rpc, main) | 47AC_C_BIGENDIAN 48 49AC_CHECK_LIB(dnet, main) 50AC_CHECK_LIB(rpc, main) |
32AC_CHECK_LIB(nsl, main) 33AC_CHECK_LIB(str, main) | |
34 | 51 |
35dnl -lsocket is broken for snoop under IRIX 5.2 and earlier 36case "$target_os" in 37irix5.0*) 38 ;; | 52AC_LBL_TYPE_SIGNAL |
39 | 53 |
40irix5.1*) 41 ;; 42 43irix5.2*) 44 ;; 45 46*) 47 AC_CHECK_LIB(socket, main) 48 ;; 49esac 50 | |
51AC_LBL_LIBPCAP(V_PCAPDEP, V_INCLS) 52 53V_GROUP=0 | 54AC_LBL_LIBPCAP(V_PCAPDEP, V_INCLS) 55 56V_GROUP=0 |
57if test -f /etc/group -a ! -z "`grep '^wheel:' /etc/group`" ; then 58 V_GROUP=wheel 59fi |
|
54case "$target_os" in 55 56aix*) 57 dnl Workaround to enable certain features 58 AC_DEFINE(_SUN) 59 ;; 60 61irix*) 62 V_GROUP=sys 63 ;; 64 | 60case "$target_os" in 61 62aix*) 63 dnl Workaround to enable certain features 64 AC_DEFINE(_SUN) 65 ;; 66 67irix*) 68 V_GROUP=sys 69 ;; 70 |
71linux*) 72 V_INCLS="$V_INCLS -Ilinux-include" 73 ;; 74 |
|
65osf*) 66 V_GROUP=system | 75osf*) 76 V_GROUP=system |
67 case "$target_os" in 68 69 osf1*) 70 ;; 71 72 osf2*) 73 ;; 74 75 *) 76 dnl Workaround around ip_hl vs. ip_vhl problem in netinet/ip.h 77 AC_DEFINE(__STDC__,2) 78 ;; 79 esac | 77 dnl Workaround around ip_hl vs. ip_vhl problem in netinet/ip.h 78 AC_DEFINE(__STDC__,2) |
80 ;; 81 82solaris*) 83 V_GROUP=sys 84 ;; | 79 ;; 80 81solaris*) 82 V_GROUP=sys 83 ;; |
85 86linux*) 87 V_INCLS="$V_INCLS -Ilinux-include" 88 ;; | |
89esac 90 91if test -f /dev/bpf0 ; then 92 V_GROUP=bpf 93fi 94 | 84esac 85 86if test -f /dev/bpf0 ; then 87 V_GROUP=bpf 88fi 89 |
95AC_CHECK_TYPE(int32_t, int) 96AC_CHECK_TYPE(u_int32_t, u_int) | 90AC_LBL_CHECK_TYPE(int32_t, int) 91AC_LBL_CHECK_TYPE(u_int32_t, u_int) |
97 98AC_LBL_DEVEL(V_CCOPT) 99 | 92 93AC_LBL_DEVEL(V_CCOPT) 94 |
100AC_LBL_TYPE_SIGNAL | |
101AC_LBL_SOCKADDR_SA_LEN 102 103AC_MSG_CHECKING(if ether_header uses ether_addr structs) 104AC_CACHE_VAL(ac_cv_ether_header_has_ea, 105 LBL_SAVE_CFLAGS="$CFLAGS" 106 CFLAGS="$CFLAGS $V_INCLS" 107 AC_TRY_COMPILE([ 108# include <sys/types.h> --- 62 unchanged lines hidden (view full) --- 171 CFLAGS="$LBL_SAVE_CFLAGS") 172AC_MSG_RESULT($ac_cv_struct_ether_arp_x) 173if test $ac_cv_struct_ether_arp_x = yes ; then 174 AC_DEFINE(ETHER_ARP_HAS_X) 175fi 176 177AC_LBL_UNALIGNED_ACCESS 178 | 95AC_LBL_SOCKADDR_SA_LEN 96 97AC_MSG_CHECKING(if ether_header uses ether_addr structs) 98AC_CACHE_VAL(ac_cv_ether_header_has_ea, 99 LBL_SAVE_CFLAGS="$CFLAGS" 100 CFLAGS="$CFLAGS $V_INCLS" 101 AC_TRY_COMPILE([ 102# include <sys/types.h> --- 62 unchanged lines hidden (view full) --- 165 CFLAGS="$LBL_SAVE_CFLAGS") 166AC_MSG_RESULT($ac_cv_struct_ether_arp_x) 167if test $ac_cv_struct_ether_arp_x = yes ; then 168 AC_DEFINE(ETHER_ARP_HAS_X) 169fi 170 171AC_LBL_UNALIGNED_ACCESS 172 |
179if test -r lbl/gnuc.h ; then | 173if test "${srcdir}" = "." ; then 174 srcdirprefix="" 175else 176 srcdirprefix="./" 177fi 178 179if test -r ${srcdirprefix}lbl/gnuc.h ; then |
180 rm -f gnuc.h | 180 rm -f gnuc.h |
181 ln -s lbl/gnuc.h gnuc.h | 181 ln -s ${srcdirprefix}lbl/gnuc.h gnuc.h |
182fi 183 184AC_SUBST(V_CCOPT) 185AC_SUBST(V_GROUP) 186AC_SUBST(V_INCLS) 187AC_SUBST(V_PCAPDEP) 188 189AC_PROG_INSTALL 190 191AC_OUTPUT(Makefile) 192 193if test -f .devel ; then 194 make depend 195fi 196exit 0 | 182fi 183 184AC_SUBST(V_CCOPT) 185AC_SUBST(V_GROUP) 186AC_SUBST(V_INCLS) 187AC_SUBST(V_PCAPDEP) 188 189AC_PROG_INSTALL 190 191AC_OUTPUT(Makefile) 192 193if test -f .devel ; then 194 make depend 195fi 196exit 0 |