From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <gentoo-commits+bounces-1388353-garchives=archives.gentoo.org@lists.gentoo.org> Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 3819315808D for <garchives@archives.gentoo.org>; Fri, 22 Apr 2022 00:39:05 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 09E8FE0826; Fri, 22 Apr 2022 00:39:04 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 4D21EE0826 for <gentoo-commits@lists.gentoo.org>; Fri, 22 Apr 2022 00:39:03 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id D7503341DEF for <gentoo-commits@lists.gentoo.org>; Fri, 22 Apr 2022 00:39:01 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 134B43B8 for <gentoo-commits@lists.gentoo.org>; Fri, 22 Apr 2022 00:39:00 +0000 (UTC) From: "Sam James" <sam@gentoo.org> To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" <sam@gentoo.org> Message-ID: <1650587877.7c4680a05d41067908b293ea9a3975a280491118.sam@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: net-libs/loudmouth/files/, net-libs/loudmouth/ X-VCS-Repository: repo/gentoo X-VCS-Files: net-libs/loudmouth/Manifest net-libs/loudmouth/files/loudmouth-1.5.4-freeaddrinfo-musl.patch net-libs/loudmouth/loudmouth-1.5.4.ebuild X-VCS-Directories: net-libs/loudmouth/files/ net-libs/loudmouth/ X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: 7c4680a05d41067908b293ea9a3975a280491118 X-VCS-Branch: master Date: Fri, 22 Apr 2022 00:39:00 +0000 (UTC) Precedence: bulk List-Post: <mailto:gentoo-commits@lists.gentoo.org> List-Help: <mailto:gentoo-commits+help@lists.gentoo.org> List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org> List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org> List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org> X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 9487f052-8aa3-451f-9e9d-5c5f6eb57c02 X-Archives-Hash: 517aa1aff76cf8bc649785dbcdbd88a5 commit: 7c4680a05d41067908b293ea9a3975a280491118 Author: Sam James <sam <AT> gentoo <DOT> org> AuthorDate: Fri Apr 22 00:37:57 2022 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Fri Apr 22 00:37:57 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7c4680a0 net-libs/loudmouth: add 1.5.4 Signed-off-by: Sam James <sam <AT> gentoo.org> net-libs/loudmouth/Manifest | 1 + .../files/loudmouth-1.5.4-freeaddrinfo-musl.patch | 40 +++++++++++++++ net-libs/loudmouth/loudmouth-1.5.4.ebuild | 57 ++++++++++++++++++++++ 3 files changed, 98 insertions(+) diff --git a/net-libs/loudmouth/Manifest b/net-libs/loudmouth/Manifest index e1ff682afffe..5a762f8d133f 100644 --- a/net-libs/loudmouth/Manifest +++ b/net-libs/loudmouth/Manifest @@ -1 +1,2 @@ DIST loudmouth-1.5.3.tar.bz2 375974 BLAKE2B c9707fe18560104456a624a61437240a16bb6bbaf544cdf775f6d6c64fdbeb6eb8f7042eb13fcdeb36c89bb8d9522c2eba02c24987757c0f0ac8748d92a2b166 SHA512 ab6b16b4e644b69cdb7d8df1753d1bb5b43c2f1e76944e639339169b332e1b5c6a4246053c5b8a579ee9b53c845cef610b0040dfdffeb857180b6bab71adfcce +DIST loudmouth-1.5.4.tar.bz2 361323 BLAKE2B 1d8453625262e4f9dc8d603619b71cac073831462164a10a92a5118c212293ae4ad9a0ca276b07b7919a0aebce633b4afaabb015ecf4b33e7c641a4273edc64a SHA512 49a08f0130b9ee56f07586d244504c81242723865a136b03e1049f32b1aa1e6c49e9b76b38f0cfb812ef4c66f73b7d83914a58e9a93e0496207e06c2b5efa9d8 diff --git a/net-libs/loudmouth/files/loudmouth-1.5.4-freeaddrinfo-musl.patch b/net-libs/loudmouth/files/loudmouth-1.5.4-freeaddrinfo-musl.patch new file mode 100644 index 000000000000..f75714a75058 --- /dev/null +++ b/net-libs/loudmouth/files/loudmouth-1.5.4-freeaddrinfo-musl.patch @@ -0,0 +1,40 @@ +https://github.com/mcabber/loudmouth/pull/46 + +From f32119e1408c742da9a1862805d76d222937756d Mon Sep 17 00:00:00 2001 +From: psykose <alice@ayaya.dev> +Date: Thu, 21 Apr 2022 18:23:32 +0000 +Subject: [PATCH] fix macro define for freeaddrinfo with asyncns + +previously, this define was only made in lm-asyncns-resolver.c, which +does not propagate it to lm-resolver.c, where freeaddrinfo() is used. +this means that when asyncns support is used, the standard libc +freeaddrinfo() is called on an addrinfo acquired from +asyncns_getaddrinfo, which is undefined behaviour, and leads to a +segfault on musl libc. +--- a/loudmouth/lm-asyncns-resolver.c ++++ b/loudmouth/lm-asyncns-resolver.c +@@ -21,7 +21,6 @@ + #include <string.h> + #ifdef HAVE_ASYNCNS + #include <asyncns.h> +-#define freeaddrinfo(x) asyncns_freeaddrinfo(x) + + /* Needed on Mac OS X */ + #if HAVE_ARPA_NAMESER_COMPAT_H +--- a/loudmouth/lm-asyncns-resolver.h ++++ b/loudmouth/lm-asyncns-resolver.h +@@ -19,8 +19,14 @@ + #ifndef __LM_ASYNCNS_RESOLVER_H__ + #define __LM_ASYNCNS_RESOLVER_H__ + ++#include <config.h> ++ + #include <glib-object.h> + ++#ifdef HAVE_ASYNCNS ++#define freeaddrinfo(x) asyncns_freeaddrinfo(x) ++#endif ++ + #include "lm-resolver.h" + + G_BEGIN_DECLS diff --git a/net-libs/loudmouth/loudmouth-1.5.4.ebuild b/net-libs/loudmouth/loudmouth-1.5.4.ebuild new file mode 100644 index 000000000000..bd960d3f5dbc --- /dev/null +++ b/net-libs/loudmouth/loudmouth-1.5.4.ebuild @@ -0,0 +1,57 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DESCRIPTION="Lightweight C Jabber library" +HOMEPAGE="https://mcabber.com" +SRC_URI="https://mcabber.com/files/${PN}/${P}.tar.bz2" + +LICENSE="LGPL-2.1" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~riscv ~sparc ~x86 ~ppc-macos" +IUSE="asyncns ssl openssl test" +RESTRICT="!test? ( test )" + +# Automagic libidn dependency +RDEPEND=">=dev-libs/glib-2.16:2 + net-dns/libidn:= + ssl? ( + !openssl? ( >=net-libs/gnutls-1.4.0:0= ) + openssl? ( dev-libs/openssl:0= ) + ) + asyncns? ( >=net-libs/libasyncns-0.3 )" +DEPEND="${RDEPEND} + test? ( dev-libs/check )" +BDEPEND="dev-util/glib-utils + virtual/pkgconfig" + +PATCHES=( + "${FILESDIR}"/${PN}-1.5.4-freeaddrinfo-musl.patch +) + +src_configure() { + local myconf + + if use ssl; then + if ! use openssl; then + myconf="${myconf} --with-ssl=gnutls" + else + myconf="${myconf} --with-ssl=openssl" + fi + else + myconf="${myconf} --with-ssl=no" + fi + + # --with-compile-warnings=yes to avoid default =error + econf \ + $(use_with asyncns) \ + --with-compile-warnings=yes \ + ${myconf} +} + +src_install() { + default + + find "${ED}" -name '*.la' -delete || die +}