[BusyBox-cvs] busybox/networking ifconfig.c,1.21,1.22 nameif.c,1.3,1.4

Erik Andersen andersen at codepoet.org
Tue Jan 14 08:54:11 UTC 2003


Update of /var/cvs/busybox/networking
In directory winder:/tmp/cvs-serv12906/networking

Modified Files:
	ifconfig.c nameif.c 
Log Message:
Eliminate most instances where we use linux kernel headers
 -Erik


Index: ifconfig.c
===================================================================
RCS file: /var/cvs/busybox/networking/ifconfig.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -d -r1.21 -r1.22
--- ifconfig.c	27 Dec 2002 17:42:01 -0000	1.21
+++ ifconfig.c	14 Jan 2003 08:54:07 -0000	1.22
@@ -38,15 +38,21 @@
 #include <ctype.h>		/* isdigit and friends */
 #include <stddef.h>		/* offsetof */
 #include <sys/ioctl.h>
+#include <net/if.h>
 #include <net/if_arp.h>
 #include <netinet/in.h>
+#if __GLIBC__ >=2 && __GLIBC_MINOR >= 1
+#include <netpacket/packet.h>
+#include <net/ethernet.h>
+#else
+#include <asm/types.h>
 #include <linux/if_ether.h>
-#include <net/if.h>
+#endif
 #include "inet_common.h"
 #include "busybox.h"
 
 #ifdef CONFIG_FEATURE_IFCONFIG_SLIP
-# include <linux/if_slip.h>
+# include <net/if_slip.h>
 #endif
 
 /* I don't know if this is needed for busybox or not.  Anyone? */

Index: nameif.c
===================================================================
RCS file: /var/cvs/busybox/networking/nameif.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- nameif.c	17 Dec 2002 12:43:43 -0000	1.3
+++ nameif.c	14 Jan 2003 08:54:07 -0000	1.4
@@ -32,9 +32,11 @@
 #include <string.h>
 #include <net/if.h>
 #include <netinet/ether.h>
-#include <linux/sockios.h>
 
 #include "busybox.h"
+
+/* take from linux/sockios.h */
+#define SIOCSIFNAME	0x8923		/* set interface name */
 
 /* Octets in one ethernet addr, from <linux/if_ether.h>	 */
 #define ETH_ALEN	6




More information about the busybox-cvs mailing list