commit: a0de88f077c4e4e753e450c5ae34fbfe08c2ebd2 Author: Maciej Barć <xgqt <AT> gentoo <DOT> org> AuthorDate: Mon Aug 11 09:17:19 2025 +0000 Commit: Maciej Barć <xgqt <AT> gentoo <DOT> org> CommitDate: Mon Aug 11 09:50:41 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a0de88f0
dev-libs/libfastjson: link to libm Closes: https://bugs.gentoo.org/961289 Signed-off-by: Maciej Barć <xgqt <AT> gentoo.org> .../files/libfastjson-1.2304.0-lm.patch | 24 ++++++++++++++++++++++ ...304.0.ebuild => libfastjson-1.2304.0-r1.ebuild} | 4 +++- 2 files changed, 27 insertions(+), 1 deletion(-) diff --git a/dev-libs/libfastjson/files/libfastjson-1.2304.0-lm.patch b/dev-libs/libfastjson/files/libfastjson-1.2304.0-lm.patch new file mode 100644 index 000000000000..ec78833146f1 --- /dev/null +++ b/dev-libs/libfastjson/files/libfastjson-1.2304.0-lm.patch @@ -0,0 +1,24 @@ +From 919f7d204291047182a042ef8f76d70fefb11c2f Mon Sep 17 00:00:00 2001 +From: Thomas Deutschmann <[email protected]> +Date: Sun, 10 Aug 2025 00:18:31 +0200 +Subject: [PATCH] build: link libfastjson against libm for modf() + +glibc-2.42 changed modf causing IFUNC modf() resolution to fail at runtime +in rsyslog due to missing direct link against libm. + +Adding -lm to Libs ensures the shared library has a DT_NEEDED entry for libm. +--- + libfastjson.pc.in | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/libfastjson.pc.in b/libfastjson.pc.in +index 7d3d375..c230c47 100644 +--- a/libfastjson.pc.in ++++ b/libfastjson.pc.in +@@ -8,5 +8,5 @@ Description: a fast JSON implementation in C + Version: @VERSION@ + Requires: + Libs.private: @LIBS@ +-Libs: -L${libdir} -lfastjson ++Libs: -L${libdir} -lfastjson -lm + Cflags: -I${includedir}/libfastjson diff --git a/dev-libs/libfastjson/libfastjson-1.2304.0.ebuild b/dev-libs/libfastjson/libfastjson-1.2304.0-r1.ebuild similarity index 89% rename from dev-libs/libfastjson/libfastjson-1.2304.0.ebuild rename to dev-libs/libfastjson/libfastjson-1.2304.0-r1.ebuild index 24fefc7aeb94..fa5e7c50d722 100644 --- a/dev-libs/libfastjson/libfastjson-1.2304.0.ebuild +++ b/dev-libs/libfastjson/libfastjson-1.2304.0-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -16,6 +16,8 @@ IUSE="static-libs" BDEPEND=">=dev-build/autoconf-archive-2015.02.04" +PATCHES=( "${FILESDIR}/libfastjson-1.2304.0-lm.patch" ) + DOCS=( AUTHORS ChangeLog ) src_prepare() {
