From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1437585-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 B1E57158094
	for <garchives@archives.gentoo.org>; Mon, 19 Sep 2022 19:01:07 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id CC509E07E1;
	Mon, 19 Sep 2022 19:01:06 +0000 (UTC)
Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4])
	(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 B68A7E07E1
	for <gentoo-commits@lists.gentoo.org>; Mon, 19 Sep 2022 19:01:06 +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 E1786340DA4
	for <gentoo-commits@lists.gentoo.org>; Mon, 19 Sep 2022 19:01:05 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id 544DB5C0
	for <gentoo-commits@lists.gentoo.org>; Mon, 19 Sep 2022 19:01:04 +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: <1663614056.e392093bd82887baa40eba4b8b81916e4dd9b66d.sam@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/libffi/
X-VCS-Repository: repo/gentoo
X-VCS-Files: dev-libs/libffi/Manifest dev-libs/libffi/libffi-3.4.3.ebuild
X-VCS-Directories: dev-libs/libffi/
X-VCS-Committer: sam
X-VCS-Committer-Name: Sam James
X-VCS-Revision: e392093bd82887baa40eba4b8b81916e4dd9b66d
X-VCS-Branch: master
Date: Mon, 19 Sep 2022 19:01:04 +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: 761263a0-10c5-4102-bf15-e9b4b4569799
X-Archives-Hash: 9538a79e5ffb3e7a0662c874c2cfa1b3

commit:     e392093bd82887baa40eba4b8b81916e4dd9b66d
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Mon Sep 19 18:35:45 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Sep 19 19:00:56 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e392093b

dev-libs/libffi: add 3.4.3

Signed-off-by: Sam James <sam <AT> gentoo.org>

 dev-libs/libffi/Manifest            |  1 +
 dev-libs/libffi/libffi-3.4.3.ebuild | 70 +++++++++++++++++++++++++++++++++++++
 2 files changed, 71 insertions(+)

diff --git a/dev-libs/libffi/Manifest b/dev-libs/libffi/Manifest
index 022b0d07614b..f6f7c7666608 100644
--- a/dev-libs/libffi/Manifest
+++ b/dev-libs/libffi/Manifest
@@ -1,3 +1,4 @@
 DIST libffi-3.3.tar.gz 1305466 BLAKE2B cddc40729a30a9bd34d675809f51f8d1b4ccaffa54bc6dd6f7e965f4e260edd34754719f9f6247c8957aeb7cf154d56ce1fe16a54c3f1ad39afbebdf41d23caa SHA512 61513801a156f11420f541d325de697131846487122d6bdcf5491b18b4da788589f5c0bb07e88e396495d3be5830d74e9135595e2b8ddbfe95c448d8597fbd6f
 DIST libffi-3.4.2-loongarch64-20220428.patch.xz 64932 BLAKE2B d144dc28a7fce008bc5cd43d9e04125ea8e972324d77951d42039d46e818014079c871f87a0cdbec758b55320c02dff718cf2449f9c630cc899e8e1610784a60 SHA512 33715b21fe027692cc584d6524c03510af7876cc35f318221e1b2b91644cf165c02979c8b426228a8cc6c471e6a59d0435e761b6b7aef589c41a4f28caa36e62
 DIST libffi-3.4.2.tar.gz 1351355 BLAKE2B a8137bc895b819f949fd7705e405be627219c6d1fdef280253330f7407d4a548bb057d7bb0e9225d1767d42f9bf5f0ab3c455db1c3470d7cc876bb7b7d55d308 SHA512 31bad35251bf5c0adb998c88ff065085ca6105cf22071b9bd4b5d5d69db4fadf16cadeec9baca944c4bb97b619b035bb8279de8794b922531fddeb0779eb7fb1
+DIST libffi-3.4.3.tar.gz 1358634 BLAKE2B 5e751c53a6b65316e438723810fbafe7f27732feb50466f1459d086c35a519f460b57968721212496a7502b0a5860546c84b22ec269e979728f18d0731fc918a SHA512 6e3620d3842ae0f983c47c3268364be32b6eeb2fc708b23d141531730e9149abb035c618b295be834999eadef64fabfa39df21c955c40473f3bbc9fd3170bad8

diff --git a/dev-libs/libffi/libffi-3.4.3.ebuild b/dev-libs/libffi/libffi-3.4.3.ebuild
new file mode 100644
index 000000000000..5c3948fcc4a8
--- /dev/null
+++ b/dev-libs/libffi/libffi-3.4.3.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit multilib-minimal preserve-libs
+
+MY_PV=${PV/_rc/-rc}
+MY_P=${PN}-${MY_PV}
+
+DESCRIPTION="a portable, high level programming interface to various calling conventions"
+HOMEPAGE="https://sourceware.org/libffi/"
+SRC_URI="https://github.com/libffi/libffi/releases/download/v${MY_PV}/${MY_P}.tar.gz"
+S="${WORKDIR}"/${MY_P}
+
+LICENSE="MIT"
+# This is a core package which is depended on by e.g. Python
+# Please use preserve-libs.eclass in pkg_{pre,post}inst to cover users
+# with FEATURES="-preserved-libs" or another package manager if SONAME
+# changes.
+SLOT="0/8" # SONAME=libffi.so.8
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+IUSE="debug exec-static-trampoline experimental-loong pax-kernel static-libs test"
+
+RESTRICT="!test? ( test )"
+BDEPEND="test? ( dev-util/dejagnu )"
+
+src_prepare() {
+	default
+
+	if [[ ${CHOST} == arm64-*-darwin* ]] ; then
+		# ensure we use aarch64 asm, not x86 on arm64
+		sed -i -e 's/aarch64\*-\*-\*/arm64*-*-*|&/' \
+			configure configure.host || die
+	fi
+}
+
+multilib_src_configure() {
+	# --includedir= path maintains a few properties:
+	# 1. have stable name across libffi versions: some packages like
+	#    dev-lang/ghc or kde-frameworks/networkmanager-qt embed
+	#    ${includedir} at build-time. Don't require those to be
+	#    rebuilt unless SONAME changes. bug #695788
+	#
+	#    We use /usr/.../${PN} (instead of former /usr/.../${P}).
+	#
+	# 2. have ${ABI}-specific location as ffi.h is target-dependent.
+	#
+	#    We use /usr/$(get_libdir)/... to have ABI identifier.
+	ECONF_SOURCE="${S}" econf \
+		--includedir="${EPREFIX}"/usr/$(get_libdir)/${PN}/include \
+		--disable-multi-os-directory \
+		$(use_enable static-libs static) \
+		$(use_enable exec-static-trampoline exec-static-tramp) \
+		$(use_enable pax-kernel pax_emutramp) \
+		$(use_enable debug)
+}
+
+multilib_src_install_all() {
+	einstalldocs
+	find "${ED}" -name "*.la" -delete || die
+}
+
+pkg_preinst() {
+	preserve_old_lib /usr/$(get_libdir)/libffi.so.7
+}
+
+pkg_postinst() {
+	preserve_old_lib_notify /usr/$(get_libdir)/libffi.so.7
+}