aboutsummaryrefslogtreecommitdiffstats
path: root/main/libnet/fix-includes.patch
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2013-09-30 14:20:23 +0000
committerTimo Teräs <timo.teras@iki.fi>2013-09-30 14:20:23 +0000
commit9ac6b1ff120ebba1555e8343fad13021ccfcb21f (patch)
treed8dff56068ea8be666bb2d7b064aadee6d94445b /main/libnet/fix-includes.patch
parent2a84f8b0f857fc8931d67c31238dd2805c1b8307 (diff)
downloadaports-9ac6b1ff120ebba1555e8343fad13021ccfcb21f.tar.bz2
aports-9ac6b1ff120ebba1555e8343fad13021ccfcb21f.tar.xz
main/libnet: fix musl build
Diffstat (limited to 'main/libnet/fix-includes.patch')
-rw-r--r--main/libnet/fix-includes.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/main/libnet/fix-includes.patch b/main/libnet/fix-includes.patch
new file mode 100644
index 0000000000..5eb86bc37b
--- /dev/null
+++ b/main/libnet/fix-includes.patch
@@ -0,0 +1,29 @@
+--- libnet-1.1.6.orig/src/libnet_link_linux.c
++++ libnet-1.1.6/src/libnet_link_linux.c
+@@ -30,26 +30,15 @@
+ #include <sys/time.h>
+
+ #include <net/if.h>
+-#if (__GLIBC__)
+ #include <netinet/if_ether.h>
+ #include <net/if_arp.h>
+-#else
+-#include <linux/if_arp.h>
+-#include <linux/if_ether.h>
+-#endif
+
+ #if (HAVE_PACKET_SOCKET)
+ #ifndef SOL_PACKET
+ #define SOL_PACKET 263
+ #endif /* SOL_PACKET */
+-#if __GLIBC__ >= 2 && __GLIBC_MINOR >= 1
+ #include <netpacket/packet.h>
+ #include <net/ethernet.h> /* the L2 protocols */
+-#else
+-#include <asm/types.h>
+-#include <linux/if_packet.h>
+-#include <linux/if_ether.h> /* The L2 protocols */
+-#endif
+ #endif /* HAVE_PACKET_SOCKET */
+
+ #include "../include/libnet.h"