commit: b307fb376a2e122a767fb9aa08410c51f7ffc62e Author: Alfredo Tupone <tupone <AT> gentoo <DOT> org> AuthorDate: Wed May 29 18:09:09 2024 +0000 Commit: Alfredo Tupone <tupone <AT> gentoo <DOT> org> CommitDate: Wed May 29 18:09:34 2024 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b307fb37
dev-ml/core_unix: Fix build on musl Closes: https://bugs.gentoo.org/932770 Signed-off-by: Alfredo Tupone <tupone <AT> gentoo.org> dev-ml/core_unix/core_unix-0.16.0-r1.ebuild | 3 +-- dev-ml/core_unix/files/core_unix-0.16.0-musl.patch | 12 ++++++++++++ 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/dev-ml/core_unix/core_unix-0.16.0-r1.ebuild b/dev-ml/core_unix/core_unix-0.16.0-r1.ebuild index 1f91c21dfc4f..c1f4d14d1f55 100644 --- a/dev-ml/core_unix/core_unix-0.16.0-r1.ebuild +++ b/dev-ml/core_unix/core_unix-0.16.0-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 2023 Gentoo Authors +# Copyright 2023-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -25,7 +25,6 @@ DEPEND=" dev-ml/timezone:${SLOT} " RDEPEND="${DEPEND}" -BDEPEND="" PATCHES=( "${FILESDIR}"/${P}-musl.patch ) diff --git a/dev-ml/core_unix/files/core_unix-0.16.0-musl.patch b/dev-ml/core_unix/files/core_unix-0.16.0-musl.patch index e37ad2f8454a..8e26f9706317 100644 --- a/dev-ml/core_unix/files/core_unix-0.16.0-musl.patch +++ b/dev-ml/core_unix/files/core_unix-0.16.0-musl.patch @@ -9,3 +9,15 @@ ssize_t ret; if (total_len > THREAD_IO_CUTOFF || contains_mmapped(v_iovecs, count)) { Begin_roots1(v_iovecs); +--- a/linux_ext/src/linux_ext_stubs.c 2024-05-29 19:59:43.955479960 +0200 ++++ b/linux_ext/src/linux_ext_stubs.c 2024-05-29 20:00:26.661018190 +0200 +@@ -243,7 +243,8 @@ + int count = Int_val(v_count); + ssize_t ret; + struct iovec *iovecs = caml_stat_alloc(sizeof(struct iovec) * count); +- struct msghdr msghdr = { NULL, 0, NULL, 0, NULL, 0, 0 }; ++ struct msghdr msghdr; ++ memset(&msghdr, 0, sizeof(msghdr)); + msghdr.msg_iov = iovecs; + msghdr.msg_iovlen = count; + for (--count; count >= 0; --count) {
