summaryrefslogtreecommitdiff
path: root/sys-apps/iproute2
diff options
context:
space:
mode:
Diffstat (limited to 'sys-apps/iproute2')
-rw-r--r--sys-apps/iproute2/Manifest2
-rw-r--r--sys-apps/iproute2/files/iproute2-4.16.0-keep-family.patch25
-rw-r--r--sys-apps/iproute2/iproute2-4.16.0-r1.ebuild152
3 files changed, 179 insertions, 0 deletions
diff --git a/sys-apps/iproute2/Manifest b/sys-apps/iproute2/Manifest
index 99e4f294d2e2..51583a5ac7ea 100644
--- a/sys-apps/iproute2/Manifest
+++ b/sys-apps/iproute2/Manifest
@@ -5,6 +5,7 @@ AUX iproute2-4.14.1-configure-nomagic.patch 7334 BLAKE2B d1a79a653cdaa5907bc93a4
AUX iproute2-4.14.1-fix-tc-actions.patch 6665 BLAKE2B e2ff926f2122973bcbe61e16717b8a1c51b6b76a774b6ce03126b7664fc5beb47e4f38672910e822b19aadd5c369d00553b2e6b6c30c012e03ad37b023cac4f7 SHA512 cdde7bb5a0cb49471472a8412758023529976dcafefc6a759ce758fba1b0420c046ca6faf084df81ac11e7153ac820909b1b9ec41c04f643208b9db456cfda28
AUX iproute2-4.14.1-posix-shell.patch 1841 BLAKE2B ba1ab797c264dc74180b85f842810af120462df3e15523f132b67968f7be0ae68086d9c01f33cc70fb7680ce2229c76960fe7a232ce6bd1069903976c7143349 SHA512 bb4c3c75c25ec551fe006ae15a0e3bc31c1f49861083894d6d51320be52dbac60634951332135b888faf9363857b53695f3cc418029445a4578b5e9233aec4f3
AUX iproute2-4.16.0-configure-nomagic.patch 5104 BLAKE2B 49c1cb559afe12eccae26f4547bcbcf8a030ee37d1ef287c178f55f01472e3b5f04d14f25834c99d3df25fae06246086197bd11446f1f50970aecc261b595f08 SHA512 b46d7ec009f924cae2d32c16e0f45c49ddb68af70dfa5d1fc0806c2ede85c744261fd1157d8ac4b1b1455604de456e2f68075b838b42265c3bfa88c021752de1
+AUX iproute2-4.16.0-keep-family.patch 833 BLAKE2B d9ee15781df4af10997238306c53cda9cde478f61c85dc1d1ad4238ea27c53fff3737bc474a354e1db22a8524f1209e920c0c9b8589a483733f78f34e38bb6bb SHA512 0bc11d6b0b7ed0a89693c73e948f42a1a8ad471e58c557a70d55c33acad53d4e6cf7dd07f92f840e73da757b094131c9ada29543d15e4f8dd0590d59a3616088
AUX iproute2-4.2.0-no-ipv6.patch 1336 BLAKE2B bafb155e6bbd902eb0fff7d8875cc4ef7956de0071273dd373ebd09ef46ba23eb22f4226a044585faa2a00c9e4c2854e57e0e06eb1ac735edea9dce2721cadcc SHA512 f4219a094f367c9f8fac089beeffca31abbbc5d4ade1681e23a92f3dd2e1a95f331322938936b0b1771ea5a56224e0f14008f4d38a8708357a5d2b2b70efbbd5
AUX iproute2-4.5.0-no-iptables.patch 1022 BLAKE2B 5e073c3e78491ae86b137ecbea2362c25c98011121cd7b59b8791227638918ad34c417f1ecd48459ef1901c7ff015463f15e5f8343d46d4b56e5555311e3c8d8 SHA512 3a3e7a66f1528dc8d03fc6a13f363ce890d0c23c2ab8df966144d8764e95cafca168bdb7dd79cf1a8dd1e54be36939f2e6465ca6176e3bfedd222eb29901f98e
DIST iproute2-4.10.0.tar.xz 626944 BLAKE2B 8d37ae67785cd4a3110f989b0ac635c1cbdc8258afeba5894b58dfcee49fdd9a4c86d8c1693ee5c5a933ce54396dbfed054dbf7fb4888c08563c36c13c282a65 SHA512 e54477e167455e7ef5da4adc168d63eaa96091b63dc987fffe918cbb005eceed18a62283ca99ee2512dc0e960f47ae21b39ffbe399c1612fd9cea147c34c581b
@@ -27,6 +28,7 @@ EBUILD iproute2-4.13.0.ebuild 4213 BLAKE2B 4a238544e35502f785f0916ec5bd255787b01
EBUILD iproute2-4.14.1-r2.ebuild 4092 BLAKE2B b3e3ae2b24182aa2d99f16120231bd4ac2029b73b9af53f0098046ecce73049e3dac510ee405f4dd12aa8c0e45b0504b7f82425c8063d05b5a958475ac2ce9d6 SHA512 c4f5cb98704d5a78d74a17a057bebb89f059c0a622d5e7ed28c6b36a73ed6be6d2a9205ed6b1ac4401f23ae46372e25d85a1038631d6ed215b2fd68c2e6a4c73
EBUILD iproute2-4.14.1-r4.ebuild 4275 BLAKE2B d8d6a43be5eb593ab7107bff4126cda9f41fff88ccb72fd4d3aee7464457739732b2e3a161114302f7e1d9ff18a5b3c7d73a92ed523254ff4857584bc2baa109 SHA512 ae5db8ad15d20df0ec18e2703d43be081189366f535ff700d83da449eed8c120df869a6d2873e817e07bd2920eea46387bda0866ccce0b48d0e7a71e8faa8752
EBUILD iproute2-4.15.0.ebuild 4214 BLAKE2B 391db4082541f9f23fef2386194590da5dec77a8dfcaf43b0335d0e6a7ae6417a8515ec206ad8557660c33ff7a31ff6b14dff303d6499a5c3576516a870cd6c4 SHA512 a04301fe1dba7903c6043612e5321bd6b231b7913d67973a80abfa228156c9919c8b959248d4f092776603877fc3661001b529f8ca032a0a996ac93425139d75
+EBUILD iproute2-4.16.0-r1.ebuild 4265 BLAKE2B cd5455979f5ef67dd6b91af2b78d421a03acaa3bcbd08d3a60c84e05d9ec1499efc54919aafc2e620cfc9b4658e3f609ab7eb501f85f8d977e86571ca4ef4bee SHA512 72adb54a708c5a69e6d29c13b20a0da1c63a4b3d7a2402ae55fc5ca072f752101440862dcf14c16f26fa99a8cd9c5239044284253daf07099633a84ebaa38ae7
EBUILD iproute2-4.16.0.ebuild 4214 BLAKE2B 4c6a9d68cb27d3b41e8da00e1fc25c083c5277706186414d407c9000b4343dfaad8913ee640e9060b1e9acda5ed43fa642631ab3b2bf8c3a956ed1ae68cebd0f SHA512 30839985403cbda2401bccfb822d394590508836e0e780bf321f64235f372819225afbbd4dcf4ec3d05992435408ebcaba401bb7c7f2872f5e474bb2b3566f5b
EBUILD iproute2-4.4.0.ebuild 3874 BLAKE2B 38518bb4f4610a04231e03a0068b0cd232477202c2efeeab9c42883a155707d74535e7398347316bff6d4c7833ebe6893fcac246fc756780febd6e4b61f0a486 SHA512 d21f5f77a404fc3ecd70728c64af64a24080044a4634cb68078699e628120c1cba2c2b508cd34ad92e9202ccdac01596a6e988635b5c1a1e0113815d893a217a
EBUILD iproute2-4.5.0.ebuild 3887 BLAKE2B 6788057f29e49ba641f790c571035d2a489a238a2821b3b5fe12c0973fa4c2aeef703826379944defe3b9997b889c071ce51f7ffe0ab5eeff68b644ced49faeb SHA512 a5d957f6660e3d1444a46511f8040f0bc7eb7a489a087e49e90a4e1d356f5346cb39a5dfdc98411d5e3eb1d6aca9e6d88f815ea133d501e5a640e099ef8e9ecc
diff --git a/sys-apps/iproute2/files/iproute2-4.16.0-keep-family.patch b/sys-apps/iproute2/files/iproute2-4.16.0-keep-family.patch
new file mode 100644
index 000000000000..d2940c9e927f
--- /dev/null
+++ b/sys-apps/iproute2/files/iproute2-4.16.0-keep-family.patch
@@ -0,0 +1,25 @@
+Bug: https://bugs.gentoo.org/652986
+
+https://marc.info/?l=linux-netdev&m=152363743818340&w=2
+
+--- a/lib/utils.c
++++ b/lib/utils.c
+@@ -568,7 +568,7 @@ static int __get_addr_1(inet_prefix *addr, const char *name, int family)
+ if (strcmp(name, "default") == 0) {
+ if ((family == AF_DECnet) || (family == AF_MPLS))
+ return -1;
+- addr->family = (family != AF_UNSPEC) ? family : AF_INET;
++ addr->family = family;
+ addr->bytelen = af_byte_len(addr->family);
+ addr->bitlen = -2;
+ addr->flags |= PREFIXLEN_SPECIFIED;
+@@ -579,7 +579,7 @@ static int __get_addr_1(inet_prefix *addr, const char *name, int family)
+ strcmp(name, "any") == 0) {
+ if ((family == AF_DECnet) || (family == AF_MPLS))
+ return -1;
+- addr->family = AF_UNSPEC;
++ addr->family = family;
+ addr->bytelen = 0;
+ addr->bitlen = -2;
+ return 0;
+--
diff --git a/sys-apps/iproute2/iproute2-4.16.0-r1.ebuild b/sys-apps/iproute2/iproute2-4.16.0-r1.ebuild
new file mode 100644
index 000000000000..944adb2f1ff0
--- /dev/null
+++ b/sys-apps/iproute2/iproute2-4.16.0-r1.ebuild
@@ -0,0 +1,152 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit toolchain-funcs flag-o-matic multilib
+
+if [[ ${PV} == "9999" ]] ; then
+ EGIT_REPO_URI="git://git.kernel.org/pub/scm/linux/kernel/git/shemminger/iproute2.git"
+ inherit git-r3
+else
+ SRC_URI="mirror://kernel/linux/utils/net/${PN}/${P}.tar.xz"
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
+fi
+
+DESCRIPTION="kernel routing and traffic control utilities"
+HOMEPAGE="https://wiki.linuxfoundation.org/networking/iproute2"
+
+LICENSE="GPL-2"
+SLOT="0"
+IUSE="atm berkdb elf +iptables ipv6 minimal selinux"
+
+# We could make libmnl optional, but it's tiny, so eh
+RDEPEND="
+ !net-misc/arpd
+ !minimal? ( net-libs/libmnl )
+ elf? ( virtual/libelf )
+ iptables? ( >=net-firewall/iptables-1.4.20:= )
+ berkdb? ( sys-libs/db:= )
+ atm? ( net-dialup/linux-atm )
+ selinux? ( sys-libs/libselinux )
+"
+# We require newer linux-headers for ipset support #549948 and some defines #553876
+DEPEND="
+ ${RDEPEND}
+ app-arch/xz-utils
+ iptables? ( virtual/pkgconfig )
+ >=sys-devel/bison-2.4
+ sys-devel/flex
+ >=sys-kernel/linux-headers-3.16
+ elibc_glibc? ( >=sys-libs/glibc-2.7 )
+"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-3.1.0-mtu.patch #291907
+ "${FILESDIR}"/${PN}-4.16.0-configure-nomagic.patch # bug 643722
+ "${FILESDIR}"/${P}-keep-family.patch # bug 652986
+)
+
+src_prepare() {
+ if ! use ipv6 ; then
+ PATCHES+=(
+ "${FILESDIR}"/${PN}-4.11.0-no-ipv6.patch #326849
+ )
+ fi
+
+ default
+
+ sed -i \
+ -e '/^CC :\?=/d' \
+ -e "/^LIBDIR/s:=.*:=/$(get_libdir):" \
+ -e "s:-O2:${CFLAGS} ${CPPFLAGS}:" \
+ -e "/^HOSTCC/s:=.*:= $(tc-getBUILD_CC):" \
+ -e "/^DBM_INCLUDE/s:=.*:=${T}:" \
+ Makefile || die
+
+ # Use /run instead of /var/run.
+ sed -i \
+ -e 's:/var/run:/run:g' \
+ include/namespace.h \
+ man/man8/ip-netns.8 || die
+
+ # build against system headers
+ rm -r include/netinet #include/linux include/ip{,6}tables{,_common}.h include/libiptc
+ sed -i 's:TCPI_OPT_ECN_SEEN:16:' misc/ss.c || die
+
+ use minimal && sed -i -e '/^SUBDIRS=/s:=.*:=lib tc ip:' Makefile
+}
+
+src_configure() {
+ tc-export AR CC PKG_CONFIG
+
+ # This sure is ugly. Should probably move into toolchain-funcs at some point.
+ local setns
+ pushd "${T}" >/dev/null
+ printf '#include <sched.h>\nint main(){return setns(0, 0);}\n' > test.c
+ ${CC} ${CFLAGS} ${CPPFLAGS} -D_GNU_SOURCE ${LDFLAGS} test.c >&/dev/null && setns=y || setns=n
+ echo 'int main(){return 0;}' > test.c
+ ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} test.c -lresolv >&/dev/null || sed -i '/^LDLIBS/s:-lresolv::' "${S}"/Makefile
+ popd >/dev/null
+
+ # run "configure" script first which will create "config.mk"...
+ econf
+
+ # ...now switch on/off requested features via USE flags
+ # this is only useful if the test did not set other things, per bug #643722
+ cat <<-EOF >> config.mk
+ TC_CONFIG_ATM := $(usex atm y n)
+ TC_CONFIG_XT := $(usex iptables y n)
+ TC_CONFIG_NO_XT := $(usex iptables n y)
+ # We've locked in recent enough kernel headers #549948
+ TC_CONFIG_IPSET := y
+ HAVE_BERKELEY_DB := $(usex berkdb y n)
+ HAVE_MNL := $(usex minimal n y)
+ HAVE_ELF := $(usex elf y n)
+ HAVE_SELINUX := $(usex selinux y n)
+ IP_CONFIG_SETNS := ${setns}
+ # Use correct iptables dir, #144265 #293709
+ IPT_LIB_DIR := $(use iptables && ${PKG_CONFIG} xtables --variable=xtlibdir)
+ EOF
+}
+
+src_compile() {
+ emake V=1
+}
+
+src_install() {
+ if use minimal ; then
+ into /
+ dosbin tc/tc
+ dobin ip/ip
+ return 0
+ fi
+
+ emake \
+ DESTDIR="${D}" \
+ LIBDIR="${EPREFIX%/}"/$(get_libdir) \
+ SBINDIR="${EPREFIX%/}"/sbin \
+ CONFDIR="${EPREFIX%/}"/etc/iproute2 \
+ DOCDIR="${EPREFIX%/}"/usr/share/doc/${PF} \
+ MANDIR="${EPREFIX%/}"/usr/share/man \
+ ARPDDIR="${EPREFIX%/}"/var/lib/arpd \
+ install
+
+ dodir /bin
+ mv "${ED%/}"/{s,}bin/ip || die #330115
+
+ dolib.a lib/libnetlink.a
+ insinto /usr/include
+ doins include/libnetlink.h
+ # This local header pulls in a lot of linux headers it
+ # doesn't directly need. Delete this header that requires
+ # linux-headers-3.8 until that goes stable. #467716
+ sed -i '/linux\/netconf.h/d' "${ED%/}"/usr/include/libnetlink.h || die
+
+ if use berkdb ; then
+ dodir /var/lib/arpd
+ # bug 47482, arpd doesn't need to be in /sbin
+ dodir /usr/bin
+ mv "${ED%/}"/sbin/arpd "${ED%/}"/usr/bin/ || die
+ fi
+}