[PATCH 4/5] Gate including net/ethernet.h on HAVE_NET_ETHERNET_H
Denys Vlasenko
vda.linux at googlemail.com
Fri Jun 10 03:18:39 UTC 2011
On Friday 10 June 2011 01:00, Dan Fandrich wrote:
> I've reworked and simplified the header files included in sources requiring
> Ethernet support. I've been able to validate the result on a number
> of Linux systems; most of these sources already include Linux header files
> unconditionally, making them nonportable to other systems. The result
> works on glibc versions ranging from 2.11 down to 2.3, as well as uClibc
> versions 0.9.29 and 0.9.30 and Android bionic 2.1. Only one configuration
> macro was needed: HAVE_NET_ETHERNET_H
--- a/networking/libiproute/iplink.c
+++ b/networking/libiproute/iplink.c
@@ -4,15 +4,15 @@
*
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
*/
-#include <net/if.h>
-#include <net/if_packet.h>
-#include <netpacket/packet.h>
-#include <net/ethernet.h>
-
#include "ip_common.h" /* #include "libbb.h" is inside */
#include "rt_names.h"
#include "utils.h"
+#include <net/if.h>
+#include <net/if_packet.h>
+#include <netpacket/packet.h>
+#include <netinet/if_ether.h>
If it is needed, then you need to add a comment why.
Applied except for this hunk.
--
vda
More information about the busybox
mailing list