commit: b5c2b50989acd6f7c57633ff375f332453385492 Author: Holger Hoffstätte <holger <AT> applied-asynchrony <DOT> com> AuthorDate: Thu Mar 5 17:06:37 2026 +0000 Commit: Mike Gilbert <floppym <AT> gentoo <DOT> org> CommitDate: Thu Mar 5 18:42:50 2026 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b5c2b509
sys-apps/iproute2: fix build on musl Closes: https://bugs.gentoo.org/970910 Signed-off-by: Holger Hoffstätte <holger <AT> applied-asynchrony.com> Part-of: https://codeberg.org/gentoo/gentoo/pulls/223 Merges: https://codeberg.org/gentoo/gentoo/pulls/223 Signed-off-by: Mike Gilbert <floppym <AT> gentoo.org> .../files/iproute2-6.19.0-add-includes.patch | 42 ++++++++++++++++++++++ sys-apps/iproute2/iproute2-6.19.0.ebuild | 1 + 2 files changed, 43 insertions(+) diff --git a/sys-apps/iproute2/files/iproute2-6.19.0-add-includes.patch b/sys-apps/iproute2/files/iproute2-6.19.0-add-includes.patch new file mode 100644 index 000000000000..0dadfdf3be13 --- /dev/null +++ b/sys-apps/iproute2/files/iproute2-6.19.0-add-includes.patch @@ -0,0 +1,42 @@ +From https://lore.kernel.org/netdev/[email protected]/ +Bug: https://bugs.gentoo.org/970910 + +From: Sergei Trofimovich <[email protected]> +To: [email protected] +Cc: Sergei Trofimovich <[email protected]> +Subject: [PATCH iproute2] include/json_print.h: add includes for `__u32` and `timeval` declarations +Date: Mon, 23 Feb 2026 22:34:35 +0000 + +Without the change the build fails on `musl` as: + +``` +../include/json_print.h:100:44: error: unknown type name ‘__u32’ + 100 | unsigned int print_range(const char *name, __u32 start, __u32 end); + | ^~~~~ +... +../include/json_print.h:82:30: warning: ‘struct timeval’ declared inside parameter list will not be visible outside of this definition or declaration + 82 | _PRINT_FUNC(tv, const struct timeval *) + | ^~~~~~~ +../include/json_print.h:57:45: note: in definition of macro ‘_PRINT_FUNC’ + 57 | type value) \ + | ^~~~ +../include/json_print.h: In function ‘print_tv’: +../include/json_print.h:60:48: error: passing argument 5 of ‘print_color_tv’ from incompatible pointer type [-Wincompatible-pointer-types] + 60 | value); \ + | ^~~~~ + | | + | const struct timeval * +``` +--- a/include/json_print.h ++++ b/include/json_print.h +@@ -8,6 +8,10 @@ + #ifndef _JSON_PRINT_H_ + #define _JSON_PRINT_H_ + ++#include <sys/time.h> /* struct timeval typedef */ ++ ++#include <asm/types.h> /* __u32 typedef */ ++ + #include "json_writer.h" + #include "color.h" + diff --git a/sys-apps/iproute2/iproute2-6.19.0.ebuild b/sys-apps/iproute2/iproute2-6.19.0.ebuild index 21de52b78551..0a91bb8494a5 100644 --- a/sys-apps/iproute2/iproute2-6.19.0.ebuild +++ b/sys-apps/iproute2/iproute2-6.19.0.ebuild @@ -53,6 +53,7 @@ PATCHES=( "${FILESDIR}"/${PN}-6.8.0-disable-libbsd-fallback.patch # bug #911727 "${FILESDIR}"/${PN}-6.18.0-netshaper.patch # bug #967691 "${FILESDIR}"/${PN}-6.19.0-dpll.patch # bug #967691 + "${FILESDIR}"/${PN}-6.19.0-add-includes.patch # bug #970910 ) src_prepare() {
