]> The Tcpdump Group git mirrors - libpcap/commitdiff
Sigh. Not all systems have <netinet/if_ether.h> - for example, at least
authorguy <guy>
Wed, 17 Jan 2001 18:18:48 +0000 (18:18 +0000)
committerguy <guy>
Wed, 17 Jan 2001 18:18:48 +0000 (18:18 +0000)
some libc5 Linux systems don't - so we have to check whether it exists,
and include it only if it does.

config.h.in
configure
configure.in
nametoaddr.c

index af77d5b349ca8965ce42b4c25cfd183f1ff2dcfa..f012a9d500d93a4d67a5da458fc0c8f09d566358 100644 (file)
@@ -21,6 +21,9 @@
 /* Define if you have the <ifaddrs.h> header file.  */
 #undef HAVE_IFADDRS_H
 
+/* Define if you have the <netinet/if_ether.h> header file.  */
+#undef HAVE_NETINET_IF_ETHER_H
+
 /* Define if you have the <netpacket/packet.h> header file.  */
 #undef HAVE_NETPACKET_PACKET_H
 
index f33f2cee0d5845e4dec38409ac0ed87e835d8c6f..5245a8a916d5c46ad5b5c72981843a506ae3fb9e 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
 #! /bin/sh
 
-# From configure.in Revision: 1.87 
+# From configure.in Revision: 1.88 
 
 
 
@@ -1392,7 +1392,7 @@ else
 fi
 echo "$ac_t""$CPP" 1>&6
 
-for ac_hdr in sys/ioccom.h sys/sockio.h ifaddrs.h
+for ac_hdr in sys/ioccom.h sys/sockio.h ifaddrs.h netinet/if_ether.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
index 816d67621cc7f66a8b0d6b3ba9a194d2a7cc95e3..eefa3c3846020d65df6affed44274375e64ac9d1 100644 (file)
@@ -1,4 +1,4 @@
-dnl @(#) $Header: /tcpdump/master/libpcap/configure.in,v 1.87 2000-12-21 10:29:22 guy Exp $ (LBL)
+dnl @(#) $Header: /tcpdump/master/libpcap/configure.in,v 1.88 2001-01-17 18:18:48 guy Exp $ (LBL)
 dnl
 dnl Copyright (c) 1994, 1995, 1996, 1997
 dnl    The Regents of the University of California.  All rights reserved.
@@ -6,7 +6,7 @@ dnl
 dnl Process this file with autoconf to produce a configure script.
 dnl
 
-AC_REVISION($Revision: 1.87 $)
+AC_REVISION($Revision: 1.88 $)
 AC_INIT(pcap.c)
 
 AC_CANONICAL_SYSTEM
@@ -25,7 +25,7 @@ dnl in "AC_LBL_FIXINCLUDES" in "aclocal.m4" uses it, so we have to
 dnl test for it and set "HAVE_SYS_IOCCOM_H" if we have it, otherwise
 dnl "AC_LBL_FIXINCLUDES" won't work on some platforms such as Solaris.
 dnl
-AC_CHECK_HEADERS(sys/ioccom.h sys/sockio.h ifaddrs.h)
+AC_CHECK_HEADERS(sys/ioccom.h sys/sockio.h ifaddrs.h netinet/if_ether.h)
 
 AC_LBL_FIXINCLUDES
 
index c30c2288f958c0bdc35ee951aa097390d6931064..76ab5e9dff505847b8afca522a2936f3994787c7 100644 (file)
@@ -24,7 +24,7 @@
 
 #ifndef lint
 static const char rcsid[] =
-    "@(#) $Header: /tcpdump/master/libpcap/nametoaddr.c,v 1.57 2000-12-18 03:45:34 guy Exp $ (LBL)";
+    "@(#) $Header: /tcpdump/master/libpcap/nametoaddr.c,v 1.58 2001-01-17 18:18:49 guy Exp $ (LBL)";
 #endif
 
 #ifdef HAVE_CONFIG_H
@@ -40,7 +40,9 @@ struct mbuf;
 struct rtentry;
 #include <net/if.h>
 #include <netinet/in.h>
+#ifdef HAVE_NETINET_IF_ETHER_H
 #include <netinet/if_ether.h>
+#endif
 #include <arpa/inet.h>
 #ifdef INET6
 #include <netdb.h>