Gentoo Archives: gentoo-commits

From: Joonas Niilola <juippis@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/libtpms/, dev-libs/libtpms/files/
Date: Fri, 24 Sep 2021 07:22:27
Message-Id: 1632468114.88916a1ebd27aeae7d6dc6d6d5739f8521af5329.juippis@gentoo
1 commit: 88916a1ebd27aeae7d6dc6d6d5739f8521af5329
2 Author: Christopher Byrne <salah.coronya <AT> gmail <DOT> com>
3 AuthorDate: Tue Sep 21 21:39:45 2021 +0000
4 Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
5 CommitDate: Fri Sep 24 07:21:54 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=88916a1e
7
8 dev-libs/libtpms: Bump to 0.8.7
9
10 Package-Manager: Portage-3.0.20, Repoman-3.0.3
11 Signed-off-by: Christopher Byrne <salah.coronya <AT> gmail.com>
12 Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
13
14 dev-libs/libtpms/Manifest | 1 +
15 .../files/libtpms-0.8.7-Remove-WError.patch | 13 ++++++
16 dev-libs/libtpms/libtpms-0.8.7.ebuild | 47 ++++++++++++++++++++++
17 3 files changed, 61 insertions(+)
18
19 diff --git a/dev-libs/libtpms/Manifest b/dev-libs/libtpms/Manifest
20 index 5afffbf543e..d341cd25e0a 100644
21 --- a/dev-libs/libtpms/Manifest
22 +++ b/dev-libs/libtpms/Manifest
23 @@ -1 +1,2 @@
24 DIST libtpms-0.8.6.tar.gz 1255964 BLAKE2B 44d9b1f78944ede5842b3cbef09900899f53ba3525e63f09de8263b9c1878a889db80eaf3ba35334a2233334bcb4ebd03d2bb841e4184059f9a155ad4a2aa244 SHA512 d57d52d140d582a6a7d2146aa9a10445c5c50807da53b26f6efbb8632ac83afa3c67e1a47ffa6a898a45cbac3aff199fe61947d69bc5af727e9623564bac45d8
25 +DIST libtpms-0.8.7.tar.gz 1256807 BLAKE2B d3630ece39a78dcc99d15ad603eec5c3d858d1d0c928ae2d3ae5ad5e4d419e186fa23b25ad15824806838401aac33e7224d7cc7ce6fb79647500d4b3a3871223 SHA512 061ec66bbeee9838f12c6a9724ba953cd604981148d6f3a8ebe444e89e59b228b763d8f98c55d67b9477277ccbf9987f2e5632d1b518e78d182f5d7066020ed4
26
27 diff --git a/dev-libs/libtpms/files/libtpms-0.8.7-Remove-WError.patch b/dev-libs/libtpms/files/libtpms-0.8.7-Remove-WError.patch
28 new file mode 100644
29 index 00000000000..54b7150cfbd
30 --- /dev/null
31 +++ b/dev-libs/libtpms/files/libtpms-0.8.7-Remove-WError.patch
32 @@ -0,0 +1,13 @@
33 +diff --git a/configure.ac b/configure.ac
34 +index 180bcc0..2efb801 100644
35 +--- a/configure.ac
36 ++++ b/configure.ac
37 +@@ -311,7 +311,7 @@ if test "x$enable_hardening" != "xno"; then
38 + AC_SUBST([HARDENING_LDFLAGS])
39 + fi
40 +
41 +-CFLAGS="$CFLAGS $COVERAGE_CFLAGS -Wall -Werror -Wreturn-type -Wsign-compare -Wno-self-assign"
42 ++CFLAGS="$CFLAGS $COVERAGE_CFLAGS -Wall -Wreturn-type -Wsign-compare -Wno-self-assign"
43 + CFLAGS="$CFLAGS -Wmissing-prototypes -Wno-deprecated-declarations"
44 + LDFLAGS="$LDFLAGS $COVERAGE_LDFLAGS"
45 +
46
47 diff --git a/dev-libs/libtpms/libtpms-0.8.7.ebuild b/dev-libs/libtpms/libtpms-0.8.7.ebuild
48 new file mode 100644
49 index 00000000000..3e913f4e034
50 --- /dev/null
51 +++ b/dev-libs/libtpms/libtpms-0.8.7.ebuild
52 @@ -0,0 +1,47 @@
53 +# Copyright 1999-2021 Gentoo Authors
54 +# Distributed under the terms of the GNU General Public License v2
55 +
56 +EAPI=8
57 +
58 +inherit autotools
59 +
60 +DESCRIPTION="Library providing software emultion of a TPM"
61 +HOMEPAGE="https://github.com/stefanberger/libtpms"
62 +SRC_URI="https://github.com/stefanberger/libtpms/archive/v${PV}.tar.gz -> ${P}.tar.gz"
63 +LICENSE="BSD"
64 +SLOT="0"
65 +KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86"
66 +
67 +DEPEND="dev-libs/openssl:="
68 +RDEPEND="${DEPEND}"
69 +BDEPEND="virtual/pkgconfig"
70 +
71 +PATCHES=(
72 + "${FILESDIR}/${PN}-0.8.7-Remove-WError.patch"
73 +)
74 +
75 +src_prepare() {
76 + default
77 + eautoreconf
78 +}
79 +
80 +src_configure() {
81 + econf \
82 + --with-openssl
83 +}
84 +
85 +src_install() {
86 + default
87 + find "${ED}" -name '*.la' -delete || die
88 +}
89 +
90 +pkg_postinst() {
91 + if [[ ${REPLACING_VERSIONS} ]] && ver_test ${REPLACING_VERSIONS} -lt 0.8.0; then
92 + elog "Versions of libtpms prior to 0.8.0 generate weaker than expected TPM 2.0 RSA"
93 + elog "keys due to a flawed key creation algorithm. Because fixing this would render"
94 + elog "existing sealed data inaccessible, to use the corrected algorithm, the old"
95 + elog "TPM state file must be deleted and a new TPM state file created. Data still"
96 + elog "sealed using the old state file will be permanently inaccessible. For the"
97 + elog "details see https://github.com/stefanberger/libtpms/issues/183"
98 + fi
99 +}