From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1495367-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 36512158062
	for <garchives@archives.gentoo.org>; Sat, 11 Mar 2023 17:15:42 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 24940E085A;
	Sat, 11 Mar 2023 17:15:41 +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))
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id 0858BE085A
	for <gentoo-commits@lists.gentoo.org>; Sat, 11 Mar 2023 17:15:41 +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))
	(No client certificate requested)
	by smtp.gentoo.org (Postfix) with ESMTPS id 21CD2340E33
	for <gentoo-commits@lists.gentoo.org>; Sat, 11 Mar 2023 17:15:40 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id B1AF38DC
	for <gentoo-commits@lists.gentoo.org>; Sat, 11 Mar 2023 17:15:38 +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: <1678554900.23a58fcc488cbf098048cc82d65461c05ef629c0.sam@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/libtpms/
X-VCS-Repository: repo/gentoo
X-VCS-Files: dev-libs/libtpms/Manifest dev-libs/libtpms/libtpms-0.9.6.ebuild dev-libs/libtpms/metadata.xml
X-VCS-Directories: dev-libs/libtpms/
X-VCS-Committer: sam
X-VCS-Committer-Name: Sam James
X-VCS-Revision: 23a58fcc488cbf098048cc82d65461c05ef629c0
X-VCS-Branch: master
Date: Sat, 11 Mar 2023 17:15:38 +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: 315515a7-d16b-4266-9b14-fefa1a283113
X-Archives-Hash: f360c1e80cd1c6f6b6b74f70c10553e3

commit:     23a58fcc488cbf098048cc82d65461c05ef629c0
Author:     Christopher Byrne <salah.coronya <AT> gmail <DOT> com>
AuthorDate: Tue Feb 28 23:52:26 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat Mar 11 17:15:00 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=23a58fcc

dev-libs/libtpms: add 0.9.6

Bug: https://bugs.gentoo.org/898504
Signed-off-by: Christopher Byrne <salah.coronya <AT> gmail.com>
Closes: https://github.com/gentoo/gentoo/pull/29913
Signed-off-by: Sam James <sam <AT> gentoo.org>

 dev-libs/libtpms/Manifest             |  1 +
 dev-libs/libtpms/libtpms-0.9.6.ebuild | 48 +++++++++++++++++++++++++++++++++++
 dev-libs/libtpms/metadata.xml         |  3 +++
 3 files changed, 52 insertions(+)

diff --git a/dev-libs/libtpms/Manifest b/dev-libs/libtpms/Manifest
index cdb18c0fe3a7..f12b36ff8c9b 100644
--- a/dev-libs/libtpms/Manifest
+++ b/dev-libs/libtpms/Manifest
@@ -1,2 +1,3 @@
 DIST libtpms-0.9.4.tar.gz 1264030 BLAKE2B 56731b913145afcd49fae13f0fcbe4fc147edf206a44849cef45ed34a7644f0894bb6ab5dcb72d620eb1ab121bf4e821fe7893557508af394585171133d659e2 SHA512 ae3e2613bc31d98c10def546c70d0c25bd1246af5090268afa0411502bfd0e454967046ebcd9025350976817441e595fa4e21562f800285db98331e4c2743505
 DIST libtpms-0.9.5.tar.gz 1264086 BLAKE2B 3e6da08dd31414bdf19260f47fce6ba7ace0ae72b152b681f1c1fbc9d75b7708238e5c2a161827c7a6e2b9a6ae4786dfbf921ec37b9f0b7c044835c974a111a3 SHA512 96b8d6dd66a6c4bc7b72d172d0b75444c7725a7fb5b0f792cd1cff9d8f7ec894c51e94493816f033198cc8adf2f95cf473629431dadb70b423068d834de09e21
+DIST libtpms-0.9.6.tar.gz 1264338 BLAKE2B 7b127ef370a48214814bb9ad0e8461ed0af21f32ab84f243945980c5e36ba5e374b4de7a83bf9c67c29264609063d48eae2dae83832daed70170bb1ed39eafea SHA512 35f26e4849eb98cd73461aff439c19f77bbbcde9b7661402e3d419354c4dcddd057349c4f7178573f1ceea2e95326498eb9afea3bd48064bbff534fc7f6939c3

diff --git a/dev-libs/libtpms/libtpms-0.9.6.ebuild b/dev-libs/libtpms/libtpms-0.9.6.ebuild
new file mode 100644
index 000000000000..79acc47b57eb
--- /dev/null
+++ b/dev-libs/libtpms/libtpms-0.9.6.ebuild
@@ -0,0 +1,48 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools
+
+DESCRIPTION="Library providing software emultion of a TPM"
+HOMEPAGE="https://github.com/stefanberger/libtpms"
+SRC_URI="https://github.com/stefanberger/libtpms/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~x86"
+
+DEPEND="dev-libs/openssl:="
+RDEPEND="${DEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-0.9.0-Remove-WError.patch"
+	"${FILESDIR}/${PN}-0.9.5-slibtool.patch" # 858671
+)
+
+src_prepare() {
+	default
+	eautoreconf
+}
+
+src_configure() {
+	econf \
+		--with-openssl
+}
+
+src_install() {
+	default
+	find "${ED}" -name '*.la' -delete || die
+}
+
+pkg_postinst() {
+	if [[ ${REPLACING_VERSIONS} ]] && ver_test ${REPLACING_VERSIONS} -lt 0.8.0; then
+		elog "Versions of libtpms prior to 0.8.0 generate weaker than expected TPM 2.0 RSA"
+		elog "keys due to a flawed key creation algorithm. Because fixing this would render"
+		elog "existing sealed data inaccessible, to use the corrected algorithm, the old"
+		elog "TPM state file must be deleted and a new TPM state file created. Data still"
+		elog "sealed using the old state file will be permanently inaccessible. For the"
+		elog "details see https://github.com/stefanberger/libtpms/issues/183"
+	fi
+}

diff --git a/dev-libs/libtpms/metadata.xml b/dev-libs/libtpms/metadata.xml
index b22f99269a84..655ec184708d 100644
--- a/dev-libs/libtpms/metadata.xml
+++ b/dev-libs/libtpms/metadata.xml
@@ -13,4 +13,7 @@
 		<email>virtualization@gentoo.org</email>
 		<name>Gentoo Virtualization Project</name>
 	</maintainer>
+	<upstream>
+		<remote-id type="github">stefanberger/libtpms</remote-id>
+	</upstream>
 </pkgmetadata>