commit: 7355c99b8c22fcd81e1c7513cbe066ed015a8f10 Author: Aric Belsito <lluixhi <AT> gmail <DOT> com> AuthorDate: Mon Jun 11 17:46:42 2018 +0000 Commit: Aric Belsito <lluixhi <AT> gmail <DOT> com> CommitDate: Mon Jun 11 17:46:42 2018 +0000 URL: https://gitweb.gentoo.org/proj/musl.git/commit/?id=7355c99b
sys-apps/iproute2: refresh patch sys-apps/iproute2/files/iproute2-4.17.0-musl.patch | 268 +++++++++++++++++++++ sys-apps/iproute2/iproute2-4.17.0.ebuild | 2 +- 2 files changed, 269 insertions(+), 1 deletion(-) diff --git a/sys-apps/iproute2/files/iproute2-4.17.0-musl.patch b/sys-apps/iproute2/files/iproute2-4.17.0-musl.patch new file mode 100644 index 0000000..2a75596 --- /dev/null +++ b/sys-apps/iproute2/files/iproute2-4.17.0-musl.patch @@ -0,0 +1,268 @@ +diff -Naur iproute2-4.17.0.orig/include/uapi/linux/if_tunnel.h iproute2-4.17.0/include/uapi/linux/if_tunnel.h +--- iproute2-4.17.0.orig/include/uapi/linux/if_tunnel.h 2018-06-11 10:31:44.723159108 -0700 ++++ iproute2-4.17.0/include/uapi/linux/if_tunnel.h 2018-06-11 10:32:17.676158518 -0700 +@@ -3,7 +3,6 @@ + #define _IF_TUNNEL_H_ + + #include <linux/types.h> +-#include <linux/if.h> + #include <linux/ip.h> + #include <linux/in6.h> + #include <asm/byteorder.h> +diff -Naur iproute2-4.17.0.orig/include/uapi/linux/ip6_tunnel.h iproute2-4.17.0/include/uapi/linux/ip6_tunnel.h +--- iproute2-4.17.0.orig/include/uapi/linux/ip6_tunnel.h 2018-06-11 10:31:44.722159108 -0700 ++++ iproute2-4.17.0/include/uapi/linux/ip6_tunnel.h 2018-06-11 10:32:24.676158393 -0700 +@@ -3,7 +3,6 @@ + #define _IP6_TUNNEL_H + + #include <linux/types.h> +-#include <linux/if.h> /* For IFNAMSIZ. */ + #include <linux/in6.h> /* For struct in6_addr. */ + + #define IPV6_TLV_TNL_ENCAP_LIMIT 4 +diff -Naur iproute2-4.17.0.orig/include/uapi/linux/kernel.h iproute2-4.17.0/include/uapi/linux/kernel.h +--- iproute2-4.17.0.orig/include/uapi/linux/kernel.h 2018-06-11 10:31:44.722159108 -0700 ++++ iproute2-4.17.0/include/uapi/linux/kernel.h 2018-06-11 10:32:41.676158088 -0700 +@@ -2,7 +2,9 @@ + #ifndef _LINUX_KERNEL_H + #define _LINUX_KERNEL_H + ++#ifdef __GLIBC__ + #include <linux/sysinfo.h> ++#endif + + /* + * 'kernel.h' contains some often-used function prototypes etc +diff -Naur iproute2-4.17.0.orig/include/uapi/linux/libc-compat.h iproute2-4.17.0/include/uapi/linux/libc-compat.h +--- iproute2-4.17.0.orig/include/uapi/linux/libc-compat.h 2018-06-11 10:31:44.721159108 -0700 ++++ iproute2-4.17.0/include/uapi/linux/libc-compat.h 2018-06-11 10:37:37.376152793 -0700 +@@ -49,47 +49,57 @@ + #ifndef _LIBC_COMPAT_H + #define _LIBC_COMPAT_H + +-/* We have included glibc headers... */ +-#if defined(__GLIBC__) ++/* We're used from userspace... */ ++#if !defined(__KERNEL__) + +-/* Coordinate with glibc net/if.h header. */ ++/* Coordinate with libc net/if.h header. */ + #if defined(_NET_IF_H) && defined(__USE_MISC) + +-/* GLIBC headers included first so don't define anything ++/* libc headers included first so don't define anything + * that would already be defined. */ + + #define __UAPI_DEF_IF_IFCONF 0 + #define __UAPI_DEF_IF_IFMAP 0 + #define __UAPI_DEF_IF_IFNAMSIZ 0 + #define __UAPI_DEF_IF_IFREQ 0 +-/* Everything up to IFF_DYNAMIC, matches net/if.h until glibc 2.23 */ + #define __UAPI_DEF_IF_NET_DEVICE_FLAGS 0 ++#if !defined(__GLIBC__) ++#define __UAPI_DEF_IF_NET_DEVICE_FLAGS_LOWER_UP_DORMANT_ECHO 0 ++#else + /* For the future if glibc adds IFF_LOWER_UP, IFF_DORMANT and IFF_ECHO */ + #ifndef __UAPI_DEF_IF_NET_DEVICE_FLAGS_LOWER_UP_DORMANT_ECHO + #define __UAPI_DEF_IF_NET_DEVICE_FLAGS_LOWER_UP_DORMANT_ECHO 1 + #endif /* __UAPI_DEF_IF_NET_DEVICE_FLAGS_LOWER_UP_DORMANT_ECHO */ ++#endif /* !defined(__GLIBC__) */ + + #else /* _NET_IF_H */ + + /* Linux headers included first, and we must define everything +- * we need. The expectation is that glibc will check the ++ * we need. The expectation is that libc will check the + * __UAPI_DEF_* defines and adjust appropriately. */ + + #define __UAPI_DEF_IF_IFCONF 1 + #define __UAPI_DEF_IF_IFMAP 1 + #define __UAPI_DEF_IF_IFNAMSIZ 1 + #define __UAPI_DEF_IF_IFREQ 1 +-/* Everything up to IFF_DYNAMIC, matches net/if.h until glibc 2.23 */ + #define __UAPI_DEF_IF_NET_DEVICE_FLAGS 1 + /* For the future if glibc adds IFF_LOWER_UP, IFF_DORMANT and IFF_ECHO */ + #define __UAPI_DEF_IF_NET_DEVICE_FLAGS_LOWER_UP_DORMANT_ECHO 1 + + #endif /* _NET_IF_H */ + +-/* Coordinate with glibc netinet/in.h header. */ ++/* Coordinate with libc netinet/if_ether.h */ ++#ifdef _NETINET_IF_ETHER_H ++#define __UAPI_DEF_ETHHDR 0 ++#else ++/* glibc uses __NETINET_IF_ETHER_H and uses the uapi header */ ++#define __UAPI_DEF_ETHHDR 1 ++#endif /* _NETINET_IF_ETHER_H */ ++ ++/* Coordinate with libc netinet/in.h header. */ + #if defined(_NETINET_IN_H) + +-/* GLIBC headers included first so don't define anything ++/* libc headers included first so don't define anything + * that would already be defined. */ + #define __UAPI_DEF_IN_ADDR 0 + #define __UAPI_DEF_IN_IPPROTO 0 +@@ -99,15 +109,7 @@ + #define __UAPI_DEF_IN_CLASS 0 + + #define __UAPI_DEF_IN6_ADDR 0 +-/* The exception is the in6_addr macros which must be defined +- * if the glibc code didn't define them. This guard matches +- * the guard in glibc/inet/netinet/in.h which defines the +- * additional in6_addr macros e.g. s6_addr16, and s6_addr32. */ +-#if defined(__USE_MISC) || defined (__USE_GNU) + #define __UAPI_DEF_IN6_ADDR_ALT 0 +-#else +-#define __UAPI_DEF_IN6_ADDR_ALT 1 +-#endif + #define __UAPI_DEF_SOCKADDR_IN6 0 + #define __UAPI_DEF_IPV6_MREQ 0 + #define __UAPI_DEF_IPPROTO_V6 0 +@@ -118,7 +120,7 @@ + #else + + /* Linux headers included first, and we must define everything +- * we need. The expectation is that glibc will check the ++ * we need. The expectation is that libc will check the + * __UAPI_DEF_* defines and adjust appropriately. */ + #define __UAPI_DEF_IN_ADDR 1 + #define __UAPI_DEF_IN_IPPROTO 1 +@@ -128,7 +130,7 @@ + #define __UAPI_DEF_IN_CLASS 1 + + #define __UAPI_DEF_IN6_ADDR 1 +-/* We unconditionally define the in6_addr macros and glibc must ++/* We unconditionally define the in6_addr macros and libc must + * coordinate. */ + #define __UAPI_DEF_IN6_ADDR_ALT 1 + #define __UAPI_DEF_SOCKADDR_IN6 1 +@@ -170,7 +172,7 @@ + * or we are being included in the kernel, then define everything + * that we need. Check for previous __UAPI_* definitions to give + * unsupported C libraries a way to opt out of any kernel definition. */ +-#else /* !defined(__GLIBC__) */ ++#else /* defined(__KERNEL__) */ + + /* Definitions for if.h */ + #ifndef __UAPI_DEF_IF_IFCONF +@@ -185,7 +187,6 @@ + #ifndef __UAPI_DEF_IF_IFREQ + #define __UAPI_DEF_IF_IFREQ 1 + #endif +-/* Everything up to IFF_DYNAMIC, matches net/if.h until glibc 2.23 */ + #ifndef __UAPI_DEF_IF_NET_DEVICE_FLAGS + #define __UAPI_DEF_IF_NET_DEVICE_FLAGS 1 + #endif +@@ -194,6 +195,11 @@ + #define __UAPI_DEF_IF_NET_DEVICE_FLAGS_LOWER_UP_DORMANT_ECHO 1 + #endif + ++/* Definitions for netinet/if_ether.h */ ++#ifndef __UAPI_DEF_ETHHDR ++#define __UAPI_DEF_ETHHDR 1 ++#endif ++ + /* Definitions for in.h */ + #ifndef __UAPI_DEF_IN_ADDR + #define __UAPI_DEF_IN_ADDR 1 +@@ -262,6 +268,6 @@ + #define __UAPI_DEF_XATTR 1 + #endif + +-#endif /* __GLIBC__ */ ++#endif /* defined(__KERNEL__) */ + + #endif /* _LIBC_COMPAT_H */ +diff -Naur iproute2-4.17.0.orig/include/uapi/linux/netfilter_ipv4/ip_tables.h iproute2-4.17.0/include/uapi/linux/netfilter_ipv4/ip_tables.h +--- iproute2-4.17.0.orig/include/uapi/linux/netfilter_ipv4/ip_tables.h 2018-06-11 10:31:44.722159108 -0700 ++++ iproute2-4.17.0/include/uapi/linux/netfilter_ipv4/ip_tables.h 2018-06-11 10:38:07.727152249 -0700 +@@ -18,7 +18,6 @@ + + #include <linux/types.h> + +-#include <linux/if.h> + #include <linux/netfilter_ipv4.h> + + #include <linux/netfilter/x_tables.h> +diff -Naur iproute2-4.17.0.orig/rdma/include/uapi/rdma/rdma_user_cm.h iproute2-4.17.0/rdma/include/uapi/rdma/rdma_user_cm.h +--- iproute2-4.17.0.orig/rdma/include/uapi/rdma/rdma_user_cm.h 2018-06-11 10:31:44.742159108 -0700 ++++ iproute2-4.17.0/rdma/include/uapi/rdma/rdma_user_cm.h 2018-06-11 10:44:48.746145068 -0700 +@@ -34,9 +34,9 @@ + #ifndef RDMA_USER_CM_H + #define RDMA_USER_CM_H + ++#include <netinet/in.h> + #include <linux/types.h> + #include <linux/socket.h> +-#include <linux/in6.h> + #include <rdma/ib_user_verbs.h> + #include <rdma/ib_user_sa.h> + +diff -Naur iproute2-4.17.0.orig/tc/f_flower.c iproute2-4.17.0/tc/f_flower.c +--- iproute2-4.17.0.orig/tc/f_flower.c 2018-06-11 10:31:44.746159108 -0700 ++++ iproute2-4.17.0/tc/f_flower.c 2018-06-11 10:38:29.389151861 -0700 +@@ -14,7 +14,7 @@ + #include <unistd.h> + #include <string.h> + #include <net/if.h> +-#include <linux/if_arp.h> ++#include <net/if_arp.h> + #include <linux/if_ether.h> + #include <linux/ip.h> + #include <linux/tc_act/tc_vlan.h> +diff -Naur iproute2-4.17.0.orig/tc/m_mirred.c iproute2-4.17.0/tc/m_mirred.c +--- iproute2-4.17.0.orig/tc/m_mirred.c 2018-06-11 10:31:44.745159108 -0700 ++++ iproute2-4.17.0/tc/m_mirred.c 2018-06-11 10:38:41.545151644 -0700 +@@ -17,6 +17,7 @@ + #include <unistd.h> + #include <fcntl.h> + #include <sys/socket.h> ++#include <net/if.h> + #include <netinet/in.h> + #include <arpa/inet.h> + #include <string.h> +diff -Naur iproute2-4.17.0.orig/tc/tc_class.c iproute2-4.17.0/tc/tc_class.c +--- iproute2-4.17.0.orig/tc/tc_class.c 2018-06-11 10:31:44.743159108 -0700 ++++ iproute2-4.17.0/tc/tc_class.c 2018-06-11 10:38:53.705151426 -0700 +@@ -15,6 +15,7 @@ + #include <unistd.h> + #include <fcntl.h> + #include <sys/socket.h> ++#include <net/if.h> + #include <netinet/in.h> + #include <arpa/inet.h> + #include <string.h> +diff -Naur iproute2-4.17.0.orig/tc/tc_filter.c iproute2-4.17.0/tc/tc_filter.c +--- iproute2-4.17.0.orig/tc/tc_filter.c 2018-06-11 10:31:44.743159108 -0700 ++++ iproute2-4.17.0/tc/tc_filter.c 2018-06-11 10:39:04.147151239 -0700 +@@ -15,6 +15,7 @@ + #include <unistd.h> + #include <fcntl.h> + #include <sys/socket.h> ++#include <net/if.h> + #include <netinet/in.h> + #include <arpa/inet.h> + #include <string.h> +diff -Naur iproute2-4.17.0.orig/tc/tc_qdisc.c iproute2-4.17.0/tc/tc_qdisc.c +--- iproute2-4.17.0.orig/tc/tc_qdisc.c 2018-06-11 10:31:44.743159108 -0700 ++++ iproute2-4.17.0/tc/tc_qdisc.c 2018-06-11 10:39:17.997150991 -0700 +@@ -15,6 +15,7 @@ + #include <unistd.h> + #include <fcntl.h> + #include <sys/socket.h> ++#include <net/if.h> + #include <netinet/in.h> + #include <arpa/inet.h> + #include <string.h> +diff -Naur iproute2-4.17.0.orig/tc/tc_util.h iproute2-4.17.0/tc/tc_util.h +--- iproute2-4.17.0.orig/tc/tc_util.h 2018-06-11 10:31:44.743159108 -0700 ++++ iproute2-4.17.0/tc/tc_util.h 2018-06-11 10:39:25.558150855 -0700 +@@ -4,7 +4,6 @@ + + #define MAX_MSG 16384 + #include <limits.h> +-#include <linux/if.h> + + #include <linux/pkt_sched.h> + #include <linux/pkt_cls.h> diff --git a/sys-apps/iproute2/iproute2-4.17.0.ebuild b/sys-apps/iproute2/iproute2-4.17.0.ebuild index 7157a09..03b2299 100644 --- a/sys-apps/iproute2/iproute2-4.17.0.ebuild +++ b/sys-apps/iproute2/iproute2-4.17.0.ebuild @@ -44,7 +44,7 @@ DEPEND=" PATCHES=( "${FILESDIR}"/${PN}-3.1.0-mtu.patch #291907 "${FILESDIR}"/${PN}-4.16.0-configure-nomagic.patch # bug 643722 - "${FILESDIR}"/${PN}-4.15.0-musl.patch + "${FILESDIR}"/${P}-musl.patch ) src_prepare() {