Merge pull request #1387 from jow-/etherwake-musl-compat
authorJo-Philipp Wich <jow@openwrt.org>
Wed, 24 Jun 2015 11:50:00 +0000 (13:50 +0200)
committerJo-Philipp Wich <jow@openwrt.org>
Wed, 24 Jun 2015 11:50:00 +0000 (13:50 +0200)
etherwake: fix musl compatibility

net/etherwake/Makefile
net/etherwake/patches/120-musl-compat.patch [new file with mode: 0644]

index 7343adc0dc00dc4a50c7973bf3be69254426ac48..4d05e3dab0ec49d6ad297e546fc2be7bd5f5e232 100644 (file)
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2007-2011 OpenWrt.org
+# Copyright (C) 2007-2015 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=etherwake
 PKG_VERSION:=1.09
-PKG_RELEASE:=3
+PKG_RELEASE:=4
 
 PKG_SOURCE:=$(PKG_NAME)_$(PKG_VERSION).orig.tar.gz
 PKG_SOURCE_URL:=http://ftp.debian.org/debian/pool/main/e/etherwake
diff --git a/net/etherwake/patches/120-musl-compat.patch b/net/etherwake/patches/120-musl-compat.patch
new file mode 100644 (file)
index 0000000..a2cdfba
--- /dev/null
@@ -0,0 +1,17 @@
+--- a/ether-wake.c
++++ b/ether-wake.c
+@@ -82,14 +82,8 @@ static char usage_msg[] =
+ #include <linux/if.h>
+ #include <features.h>
+-#if __GLIBC__ >= 2 && __GLIBC_MINOR >= 1
+ #include <netpacket/packet.h>
+ #include <net/ethernet.h>
+-#else
+-#include <asm/types.h>
+-#include <linux/if_packet.h>
+-#include <linux/if_ether.h>
+-#endif
+ #include <netdb.h>
+ #include <netinet/ether.h>