commit:     0bfbb814409fc9204f3bc39421cd148ad2319420
Author:     Christopher Byrne <salah.coronya <AT> gmail <DOT> com>
AuthorDate: Mon Jul  4 18:38:42 2022 +0000
Commit:     Matthew Smith <matthew <AT> gentoo <DOT> org>
CommitDate: Sat Jul  9 12:26:23 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0bfbb814

dev-libs/libtpms: add 0.9.5

Signed-off-by: Christopher Byrne <salah.coronya <AT> gmail.com>
Closes: https://github.com/gentoo/gentoo/pull/26222
Signed-off-by: Matthew Smith <matthew <AT> gentoo.org>

 dev-libs/libtpms/Manifest             |  1 +
 dev-libs/libtpms/libtpms-0.9.5.ebuild | 47 +++++++++++++++++++++++++++++++++++
 2 files changed, 48 insertions(+)

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

diff --git a/dev-libs/libtpms/libtpms-0.9.5.ebuild 
b/dev-libs/libtpms/libtpms-0.9.5.ebuild
new file mode 100644
index 000000000000..fc15af9bf0f4
--- /dev/null
+++ b/dev-libs/libtpms/libtpms-0.9.5.ebuild
@@ -0,0 +1,47 @@
+# Copyright 1999-2022 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 ~ppc ~ppc64 ~riscv ~x86"
+
+DEPEND="dev-libs/openssl:="
+RDEPEND="${DEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+       "${FILESDIR}/${PN}-0.9.0-Remove-WError.patch"
+)
+
+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
+}

Reply via email to