From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id A4FCA1382C5 for ; Tue, 3 Apr 2018 18:16:41 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 9D615E09C1; Tue, 3 Apr 2018 18:16:40 +0000 (UTC) Received: from smtp.gentoo.org (mail.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 65CAAE09C1 for ; Tue, 3 Apr 2018 18:16:40 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id C5A31335D65 for ; Tue, 3 Apr 2018 18:16:38 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id CA09525A for ; Tue, 3 Apr 2018 18:16:36 +0000 (UTC) From: "Aric Belsito" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Aric Belsito" Message-ID: <1522779363.f5b30611ae531c861d26f859cd888c3b6c3cc87d.lluixhi@gentoo> Subject: [gentoo-commits] proj/musl:master commit in: sys-apps/iproute2/files/, sys-apps/iproute2/ X-VCS-Repository: proj/musl X-VCS-Files: sys-apps/iproute2/Manifest sys-apps/iproute2/files/iproute2-4.16.0-configure-nomagic.patch sys-apps/iproute2/iproute2-4.15.0.ebuild sys-apps/iproute2/iproute2-4.16.0.ebuild sys-apps/iproute2/metadata.xml X-VCS-Directories: sys-apps/iproute2/ sys-apps/iproute2/files/ X-VCS-Committer: lluixhi X-VCS-Committer-Name: Aric Belsito X-VCS-Revision: f5b30611ae531c861d26f859cd888c3b6c3cc87d X-VCS-Branch: master Date: Tue, 3 Apr 2018 18:16:36 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 51f1aae4-d90d-4a3b-b6c0-777f2435a297 X-Archives-Hash: 485db88339a88c0b9ee4c5d1873c4654 commit: f5b30611ae531c861d26f859cd888c3b6c3cc87d Author: Aric Belsito gmail com> AuthorDate: Tue Apr 3 18:16:03 2018 +0000 Commit: Aric Belsito gmail com> CommitDate: Tue Apr 3 18:16:03 2018 +0000 URL: https://gitweb.gentoo.org/proj/musl.git/commit/?id=f5b30611 sys-apps/iproute2: version bump to 4.16.0 sys-apps/iproute2/Manifest | 1 + .../files/iproute2-4.16.0-configure-nomagic.patch | 191 +++++++++++++++++++++ sys-apps/iproute2/iproute2-4.15.0.ebuild | 7 +- ...route2-4.15.0.ebuild => iproute2-4.16.0.ebuild} | 9 +- sys-apps/iproute2/metadata.xml | 1 + 5 files changed, 202 insertions(+), 7 deletions(-) diff --git a/sys-apps/iproute2/Manifest b/sys-apps/iproute2/Manifest index 0390df9..769cee9 100644 --- a/sys-apps/iproute2/Manifest +++ b/sys-apps/iproute2/Manifest @@ -1,2 +1,3 @@ DIST iproute2-4.14.1.tar.xz 636876 BLAKE2B 232dbe29b9af516d8345c86c044359d3b0cfe73fb88a2ba1dcd05534b52dea37c9155d2b273a4a0d40b55fba8b5503a0fbe5bc71f37864c0a2ba9d6f08b6bf41 SHA512 e593b68c46ef5f98bd6911ee7beb38388a14935a29fefabdeccc96aa012593b6f3a49b3bb1baed7d77e54f1f4a857172e058b73407f4070f158b8713f44f5d2c DIST iproute2-4.15.0.tar.xz 648836 BLAKE2B e7f3a027ec88de7c6ac82c5529b37fdf22311bc9290e71662bc3b1e32d4cb6a1845e2badb961a21b50b5ed1b9d23130e512a011767183f7df1b33eb05101044b SHA512 bcc54b8dc83d7b0e759a2de77eb38fed483d7f7f82698f482e0259000f2f55ba79c556b721730eb999e85c865ad136fd7549304ebe936545e02e848ba7f698bc +DIST iproute2-4.16.0.tar.xz 661336 BLAKE2B 4efb08c88a60b1bbbeef807c0731e610032bfb11d022562c1df052d324eb43cb25b9523f49730d22a3f92eb06bd5037c70d8ed0b58276a0cf0854a0f82800b64 SHA512 a8fbc92665a8d4ca6ee1e894bfb27373cf6b16dac9e2ab3831e418fcc9b895acc7d6fc64efa0b0e37b3affd4ef8eacf4dae5715536138d6a05c65ad49a2becad diff --git a/sys-apps/iproute2/files/iproute2-4.16.0-configure-nomagic.patch b/sys-apps/iproute2/files/iproute2-4.16.0-configure-nomagic.patch new file mode 100644 index 0000000..01a1fe2 --- /dev/null +++ b/sys-apps/iproute2/files/iproute2-4.16.0-configure-nomagic.patch @@ -0,0 +1,191 @@ +The hand-rolled configure script, for multiple options (selinux,mnl,elf), sets +a variable as well as modifying CFLAGS & LDLIBS. + +If config.mk is later amended to disable a feature, the CFLAGS/LDLIBS tweaks +are still in place. + +Push the CFLAGS/LDLIBS changes into new conditional Makefile code, so that they +are only passed when correctly needed. + +Prior Gentoo testcase for reproduction: +USE=minimal ebuild ... compile. +- Linking with libelf & libmnl based only on presence. +- Links based on libselinux based only on presence. + +Closes: https://bugs.gentoo.org/643722 +Signed-off-by: Robin H. Johnson + +Forward-ported from v4.14.1 to v4.16.0 by Lars Wendler + +--- iproute2-4.16.0/bridge/Makefile ++++ iproute2-4.16.0/bridge/Makefile +@@ -2,6 +2,7 @@ + BROBJ = bridge.o fdb.o monitor.o link.o mdb.o vlan.o + + include ../config.mk ++include ../config.include + + all: bridge + +--- iproute2-4.16.0/config.include ++++ iproute2-4.16.0/config.include +@@ -0,0 +1,22 @@ ++# We can only modify CFLAGS/LDLIBS after all the config options are known. ++ifeq ($(IP_CONFIG_SETNS),y) ++ CFLAGS += $(IP_CONFIG_SETNS_CFLAGS) ++endif ++ifeq ($(HAVE_ELF),y) ++ CFLAGS += $(HAVE_ELF_CFLAGS) ++ LDLIBS += $(HAVE_ELF_LDLIBS) ++endif ++ifeq ($(HAVE_SELINUX),y) ++ CFLAGS += $(HAVE_SELINUX_CFLAGS) ++ LDLIBS += $(HAVE_SELINUX_LDLIBS) ++endif ++ifeq ($(HAVE_MNL),y) ++ CFLAGS += $(HAVE_MNL_CFLAGS) ++ LDLIBS += $(HAVE_MNL_LDLIBS) ++endif ++ ++# Rules can only be declared after all variables in them are known. ++%.o: %.c ++ $(QUIET_CC)$(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c -o $@ $< ++ ++# vim: ft=make: +--- iproute2-4.16.0/configure ++++ iproute2-4.16.0/configure +@@ -212,7 +212,7 @@ + then + echo "IP_CONFIG_SETNS:=y" >>$CONFIG + echo "yes" +- echo "CFLAGS += -DHAVE_SETNS" >>$CONFIG ++ echo "IP_CONFIG_SETNS_CFLAGS += -DHAVE_SETNS" >>$CONFIG + else + echo "no" + fi +@@ -257,8 +257,8 @@ + echo "HAVE_ELF:=y" >>$CONFIG + echo "yes" + +- echo 'CFLAGS += -DHAVE_ELF' `${PKG_CONFIG} libelf --cflags` >> $CONFIG +- echo 'LDLIBS += ' `${PKG_CONFIG} libelf --libs` >>$CONFIG ++ echo 'HAVE_ELF_CFLAGS += -DHAVE_ELF' `${PKG_CONFIG} libelf --cflags` >> $CONFIG ++ echo 'HAVE_ELF_LDLIBS += ' `${PKG_CONFIG} libelf --libs` >>$CONFIG + else + echo "no" + fi +@@ -272,8 +272,8 @@ + echo "HAVE_SELINUX:=y" >>$CONFIG + echo "yes" + +- echo 'LDLIBS +=' `${PKG_CONFIG} --libs libselinux` >>$CONFIG +- echo 'CFLAGS += -DHAVE_SELINUX' `${PKG_CONFIG} --cflags libselinux` >>$CONFIG ++ echo 'HAVE_SELINUX_CFLAGS += -DHAVE_SELINUX' `${PKG_CONFIG} --cflags libselinux` >>$CONFIG ++ echo 'HAVE_SELINUX_LDLIBS +=' `${PKG_CONFIG} --libs libselinux` >>$CONFIG + else + echo "no" + fi +@@ -286,8 +286,8 @@ + echo "HAVE_MNL:=y" >>$CONFIG + echo "yes" + +- echo 'CFLAGS += -DHAVE_LIBMNL' `${PKG_CONFIG} libmnl --cflags` >>$CONFIG +- echo 'LDLIBS +=' `${PKG_CONFIG} libmnl --libs` >> $CONFIG ++ echo 'HAVE_MNL_CFLAGS += -DHAVE_LIBMNL' `${PKG_CONFIG} libmnl --cflags` >>$CONFIG ++ echo 'HAVE_MNL_LDLIBS +=' `${PKG_CONFIG} libmnl --libs` >> $CONFIG + else + echo "no" + fi +@@ -426,7 +426,3 @@ + + echo -n "libcap support: " + check_cap +- +-echo >> $CONFIG +-echo "%.o: %.c" >> $CONFIG +-echo ' $(QUIET_CC)$(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c -o $@ $<' >> $CONFIG +--- iproute2-4.16.0/devlink/Makefile ++++ iproute2-4.16.0/devlink/Makefile +@@ -1,5 +1,6 @@ + # SPDX-License-Identifier: GPL-2.0 + include ../config.mk ++include ../config.include + + TARGETS := + +--- iproute2-4.16.0/genl/Makefile ++++ iproute2-4.16.0/genl/Makefile +@@ -2,6 +2,7 @@ + GENLOBJ=genl.o + + include ../config.mk ++include ../config.include + SHARED_LIBS ?= y + + CFLAGS += -fno-strict-aliasing +--- iproute2-4.16.0/ip/Makefile ++++ iproute2-4.16.0/ip/Makefile +@@ -15,6 +15,7 @@ + RTMONOBJ=rtmon.o + + include ../config.mk ++include ../config.include + + ALLOBJ=$(IPOBJ) $(RTMONOBJ) + SCRIPTS=ifcfg rtpr routel routef +--- iproute2-4.16.0/lib/Makefile ++++ iproute2-4.16.0/lib/Makefile +@@ -1,5 +1,6 @@ + # SPDX-License-Identifier: GPL-2.0 + include ../config.mk ++include ../config.include + + CFLAGS += -fPIC + +--- iproute2-4.16.0/misc/Makefile ++++ iproute2-4.16.0/misc/Makefile +@@ -5,6 +5,7 @@ + TARGETS=ss nstat ifstat rtacct lnstat + + include ../config.mk ++include ../config.include + + ifeq ($(HAVE_BERKELEY_DB),y) + TARGETS += arpd +--- iproute2-4.16.0/netem/Makefile ++++ iproute2-4.16.0/netem/Makefile +@@ -1,5 +1,6 @@ + # SPDX-License-Identifier: GPL-2.0 + include ../config.mk ++include ../config.include + + DISTGEN = maketable normal pareto paretonormal + DISTDATA = normal.dist pareto.dist paretonormal.dist experimental.dist +--- iproute2-4.16.0/rdma/Makefile ++++ iproute2-4.16.0/rdma/Makefile +@@ -1,5 +1,6 @@ + # SPDX-License-Identifier: GPL-2.0 + include ../config.mk ++include ../config.include + + TARGETS := + +--- iproute2-4.16.0/tc/Makefile ++++ iproute2-4.16.0/tc/Makefile +@@ -4,6 +4,7 @@ + emp_ematch.yacc.o emp_ematch.lex.o + + include ../config.mk ++include ../config.include + + SHARED_LIBS ?= y + +--- iproute2-4.16.0/tipc/Makefile ++++ iproute2-4.16.0/tipc/Makefile +@@ -1,5 +1,6 @@ + # SPDX-License-Identifier: GPL-2.0 + include ../config.mk ++include ../config.include + + TARGETS := + diff --git a/sys-apps/iproute2/iproute2-4.15.0.ebuild b/sys-apps/iproute2/iproute2-4.15.0.ebuild index fddcf37..4b485e8 100644 --- a/sys-apps/iproute2/iproute2-4.15.0.ebuild +++ b/sys-apps/iproute2/iproute2-4.15.0.ebuild @@ -18,12 +18,13 @@ HOMEPAGE="https://wiki.linuxfoundation.org/networking/iproute2" LICENSE="GPL-2" SLOT="0" -IUSE="atm berkdb +iptables ipv6 minimal selinux" +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 virtual/libelf ) + !minimal? ( net-libs/libmnl ) + elf? ( virtual/libelf ) iptables? ( >=net-firewall/iptables-1.4.20:= ) berkdb? ( sys-libs/db:= ) atm? ( net-dialup/linux-atm ) @@ -102,7 +103,7 @@ src_configure() { TC_CONFIG_IPSET := y HAVE_BERKELEY_DB := $(usex berkdb y n) HAVE_MNL := $(usex minimal n y) - HAVE_ELF := $(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 diff --git a/sys-apps/iproute2/iproute2-4.15.0.ebuild b/sys-apps/iproute2/iproute2-4.16.0.ebuild similarity index 95% copy from sys-apps/iproute2/iproute2-4.15.0.ebuild copy to sys-apps/iproute2/iproute2-4.16.0.ebuild index fddcf37..842de0b 100644 --- a/sys-apps/iproute2/iproute2-4.15.0.ebuild +++ b/sys-apps/iproute2/iproute2-4.16.0.ebuild @@ -18,12 +18,13 @@ HOMEPAGE="https://wiki.linuxfoundation.org/networking/iproute2" LICENSE="GPL-2" SLOT="0" -IUSE="atm berkdb +iptables ipv6 minimal selinux" +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 virtual/libelf ) + !minimal? ( net-libs/libmnl ) + elf? ( virtual/libelf ) iptables? ( >=net-firewall/iptables-1.4.20:= ) berkdb? ( sys-libs/db:= ) atm? ( net-dialup/linux-atm ) @@ -42,7 +43,7 @@ DEPEND=" PATCHES=( "${FILESDIR}"/${PN}-3.1.0-mtu.patch #291907 - "${FILESDIR}"/${PN}-4.14.1-configure-nomagic.patch # bug 643722 + "${FILESDIR}"/${PN}-4.16.0-configure-nomagic.patch # bug 643722 "${FILESDIR}"/${PN}-4.15.0-musl.patch ) @@ -102,7 +103,7 @@ src_configure() { TC_CONFIG_IPSET := y HAVE_BERKELEY_DB := $(usex berkdb y n) HAVE_MNL := $(usex minimal n y) - HAVE_ELF := $(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 diff --git a/sys-apps/iproute2/metadata.xml b/sys-apps/iproute2/metadata.xml index 2605d5f..ad652ef 100644 --- a/sys-apps/iproute2/metadata.xml +++ b/sys-apps/iproute2/metadata.xml @@ -7,6 +7,7 @@ build programs that use berkdb (just arpd) + support loading eBPF programs from ELFs (e.g. LLVM's eBPF backend) include support for iptables filtering only install ip and tc programs, without eBPF support