summaryrefslogtreecommitdiff
path: root/app-crypt/tpm2-tools
diff options
context:
space:
mode:
Diffstat (limited to 'app-crypt/tpm2-tools')
-rw-r--r--app-crypt/tpm2-tools/Manifest13
-rw-r--r--app-crypt/tpm2-tools/files/tpm2-tools-5.6-bashism.patch47
-rw-r--r--app-crypt/tpm2-tools/files/tpm2-tools-5.6-test-eventlog-fix-check-eventlog.sh-if-efivar.h-exis.patch123
-rw-r--r--app-crypt/tpm2-tools/files/tpm2-tools-5.6-test-eventlog.sh-Fix-accidental-deletions.patch68
-rw-r--r--app-crypt/tpm2-tools/files/tpm2-tools-5.7-tests-Eliminate-dependency-on-which.patch42
-rw-r--r--app-crypt/tpm2-tools/tpm2-tools-5.5.ebuild66
-rw-r--r--app-crypt/tpm2-tools/tpm2-tools-5.6-r1.ebuild81
-rw-r--r--app-crypt/tpm2-tools/tpm2-tools-5.6.1.ebuild87
-rw-r--r--app-crypt/tpm2-tools/tpm2-tools-5.7.ebuild1
9 files changed, 45 insertions, 483 deletions
diff --git a/app-crypt/tpm2-tools/Manifest b/app-crypt/tpm2-tools/Manifest
index 834464e8ccf4..fab223f97567 100644
--- a/app-crypt/tpm2-tools/Manifest
+++ b/app-crypt/tpm2-tools/Manifest
@@ -1,14 +1,5 @@
AUX tpm2-tools-5.6-Makefile-am-Dont-require-pandoc-for-tests.patch 408 BLAKE2B a0d042d7a1beeba1b671c130179f416aa53c1d59a66787fde69bbf9c9a6ce1d8e8aa4f074e2c2304160bcd3725287e78671c62d9a5ef348fb172bbad17e4fd8a SHA512 c9e3035a413540a373fb8de4bb5f0f18347c836ed338bc2d2dacbdfc0274aa5087786b894ca2d484038dd90499e97618039ac88743fb5e466e4b42fa522dc99e
-AUX tpm2-tools-5.6-bashism.patch 1802 BLAKE2B 28bf27329d0fbb314c3bc297788e6ae5615c53f74c7a11784e0200ad39f6ec5e887aa7341130b4d9136b6639147cbd11546dbbc1552bb59e565debd4594595f8 SHA512 784d06e6933e108409994b21b5d55c498a800e5a693889c6ab06378c2babbb7bb6ea18d0bae9fa3fee13ca961d6ff21ebe363962bd998f5c42950c8f820fe2d9
-AUX tpm2-tools-5.6-test-eventlog-fix-check-eventlog.sh-if-efivar.h-exis.patch 4136 BLAKE2B c7531d8425ac1df9610c8371a3a01a4cf68c224ca5bf2d8d5f68187c6013ab16d8c16ad261c53319caae04769421398bbbaa0710d95b202c43f62722b631f1d6 SHA512 8f3c38417d546beb8cf7e3410a5d91af59893eb7b08ee0060c5c5363f316490ae904a456009a2643e95e4db3fefc85795884fc91c2fb492e8911d92c97e6aba5
-AUX tpm2-tools-5.6-test-eventlog.sh-Fix-accidental-deletions.patch 2805 BLAKE2B f8d1f063fef10c3a8d2324a70b4ee6efc99a4a4a08ce79db822169a65319d4fc50dc6a62036d74a1da43d09a008d33d09fd1efcb2c109e5e67ffed9e56b36412 SHA512 c01d78bf67ecc57a6f594739a20ec6e4c0e78ef2c062e7f82594d17cec86b907b0c2aacbb44be119a7d2b2a01f3d0931ad558d2e775ba1d75eac2ddeb1570b8c
-DIST tpm2-tools-5.5.tar.gz 1241390 BLAKE2B 2225f9e0835988351f84ed06f914616e25fd65bacaa93b51d0bb04185314efb9a6f60eb3539b250f54b2c2ba590f1b76594df3e625e45c8d37e38d13371bea26 SHA512 24f72a3e9840d531d900e96771a863baae1c71a76fcad0fda8020dff06acd8e3b65b86401ace21f034766403caf9ae97ce710ff6013bb7ed25657a6ecf325470
-DIST tpm2-tools-5.6-tpm2_eventlog-Create-raw-and-pretty-print-format-for.patch.xz 47916 BLAKE2B 1bbc84f58ad46507417c89be1b4ce2450fb33cf3abe8f080c23890d96be85379f135ef1dbf4b580e1a386fa6d5ebc4fbaab351b5238bbf1011bb97b0f49a847b SHA512 3db0daa39a8dc756d7cb25e3673149dc3eeafd7410f2c6537464431b501e3704a886d9b7a9acd71440d6d419649dd471fd6f9247d593c89a30b05774a8d1b3de
-DIST tpm2-tools-5.6.1.tar.gz 1255474 BLAKE2B 7fda0084283bbd592c3323605f598ebb77ba267ebb900e62b2eff2742257378d95f99b48aab090f80438a6c86f168e1863f9350c18571a23e17eea90a1b9bdd9 SHA512 7a5903db0578a1364c44ca8ac3672c3cae745e2b0ab66ddf6a91fdb75146441af32dfe4ccad6825bea343fea74bed97f9e45bf752594ee56f32e4cb7be2bed33
-DIST tpm2-tools-5.6.tar.gz 1266731 BLAKE2B fe88722c26d62128cd6dfbdd8ef2568656a75fe27b1443fed28387d0db1f50b7d0651819d34dfa98acde785b4cfb4e7c11420b110bb5333ed2bb6b67cdd4fc70 SHA512 14216f29ed3ecca5fbe356ed3744c8b6b25a62ff11b2aed596d11101328c8bfd29a02f6ca5a218f9a4477a5e9648c50f0ae96e71de0b4ff5ea1f98ebeeb73cd7
+AUX tpm2-tools-5.7-tests-Eliminate-dependency-on-which.patch 1382 BLAKE2B 823d13dd3b47cb04cf668ccd5e2c7565101943be00a2e06d28ef7290ab065a4053c6b28914c534f76b485adf96d7b73731720e50f49f335c0bd716af9f63e463 SHA512 59fcd058de4d11f5c858a9dc44d91786693d21b85f757628fea74355b27610db5ad05ea4a4131399273440fa54b95ad1715e6353a6a46e099fceaeac6607086d
DIST tpm2-tools-5.7.tar.gz 1339035 BLAKE2B 3984f25176e0b092793a33a0b40b396bc650de989e0b600989d11439cccdf7bc410535c01e1a0e985ab67b36b63eb02d392342aa1746b86727ba22d67d522389 SHA512 629b0b1826815877f452935285f7b3fe0f32bd24fe9130eb169a2dc9b7b254a737797043af9eea68be706b87c32ab2b7189151360c9c00bc5c31dce62a799670
-EBUILD tpm2-tools-5.5.ebuild 1643 BLAKE2B 5029ad3299b8db9d0005866660db88884833619fade7131a6b4b7b42f1ce62a2fe8eb94ad175b889bd2d9c2b6d4bf5d91d2455bd0ea0a9ad8e0c59565c73b1e2 SHA512 195dc492373400638ec7baa5c191e7eeea646523f296ff16422ae56d7347e5e6fdea12d199e8d32bc700790f9a206b5e84b0e52348f67b4ad681e6889cf1703e
-EBUILD tpm2-tools-5.6-r1.ebuild 2230 BLAKE2B 29bd871f43e77ad687efdaf30866929b0c78b7013e2fb3aec8ffe6aee30bb184efee7b96a3e0cd487bd4c6510494f7b8df91ddecfc43c53b711cdbc45f69271f SHA512 ddc4b86bf59291e6fdbb0b443435f135992d4e0ba9e7b69ab0a5efb0f950ed8004fa9a3155cbb1fc26c41b59241769d6c16e65180ae474b48b43ce8e27d20a9f
-EBUILD tpm2-tools-5.6.1.ebuild 2331 BLAKE2B 780cc29ffa04e805e2504a8180a741959c162206e93b32cc5a70d8000b4ea494173ba0a37e9c18f7b2517b46c9fa46cd738709489a7bd524d55dfb1f53154c65 SHA512 7f5f35c6b7294b7f4f22487f8af1d2766b946573e8abbaaec6e040e82dceb60eb15155c8dcaa7f3a9f4b192b09ef49fa50ab3df7265d5e5e0b5276047f24b1bb
-EBUILD tpm2-tools-5.7.ebuild 1946 BLAKE2B 036b526770caf7db787ba78f2646d1e9d52fa20998a36bb8412fdf308ea7a90e76c8abf2ad9bcb334f1385349d04ebf0eac619ca650612292ebb5ea5e7def2dc SHA512 3bd0836de7d949a59b2f134b7211f25292fc748db05b331a2488a44c6ae01cc3edcb2d57a077e7dcf6a9395bf057f26b56632e085a940a971c7c6df0d5a806f9
+EBUILD tpm2-tools-5.7.ebuild 2013 BLAKE2B 9c9ab245c6d510eb04c306f36e045ad70450a8e08c5124b2f8b9c077d906afc499eca2978e145825b17f3e77db046b08cbb90ab9ccc6e3272f9aa033e502afce SHA512 ddcc52569a129a222524d6eb4a72a0af387eeed831efacf560482907639bc2815bc06f170d58a9406f549c21a205dee9335d85a033968697b5bbd5d57c08e88a
MISC metadata.xml 560 BLAKE2B fe8daaba2a7586247537f8ed7b92769676b20f2c1377f7bb582dff49e06cf3f9beba4f79e28f10ea76d67d089eb152b060b091414dd9b47c5694ca153211421f SHA512 a744fcc50c7e44b1939190150404aee9054eab8e921e6f63cafa58dc80be5f20692632509de85399b6a9633701da72fd951e8bcfbe9e5177f315fa1dcbcc9ee5
diff --git a/app-crypt/tpm2-tools/files/tpm2-tools-5.6-bashism.patch b/app-crypt/tpm2-tools/files/tpm2-tools-5.6-bashism.patch
deleted file mode 100644
index 01ce4301d4e3..000000000000
--- a/app-crypt/tpm2-tools/files/tpm2-tools-5.6-bashism.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-https://github.com/tpm2-software/tpm2-tools/pull/3339
-
-From 9f244c3f74747b7f79c8c6813657b2f2f8a1c844 Mon Sep 17 00:00:00 2001
-From: Sam James <sam@gentoo.org>
-Date: Sun, 21 Jan 2024 08:08:28 +0000
-Subject: [PATCH] configure.ac: fix bashisms
-
-configure scripts need to be runnable with a POSIX-compliant /bin/sh.
-
-On many (but not all!) systems, /bin/sh is provided by Bash, so errors
-like this aren't spotted. Notably Debian defaults to /bin/sh provided
-by dash which doesn't tolerate such bashisms as '=='.
-
-This retains compatibility with bash.
-
-Fixes configure warnings/errors like:
-```
-checking for libcurl... yes
-./configure: 15201: test: xauto: unexpected operator
-./configure: 15286: test: xauto: unexpected operator
-checking for efivar/efivar.h... yes
-```
-
-This fixes a build error later on too:
-```
-/usr/lib/gcc/x86_64-pc-linux-gnu/14/../../../../x86_64-pc-linux-gnu/bin/ld: lib/libcommon.a(libcommon_a-tpm2_eventlog_yaml.o): in function `yaml_devicepath':
-tpm2_eventlog_yaml.c:(.text.yaml_devicepath+0x2f): undefined reference to `efidp_format_device_path'
-/usr/lib/gcc/x86_64-pc-linux-gnu/14/../../../../x86_64-pc-linux-gnu/bin/ld: tpm2_eventlog_yaml.c:(.text.yaml_devicepath+0x61): undefined reference to `efidp_format_device_path'
-```
-
-Bug: https://bugs.gentoo.org/922592
-Signed-off-by: Sam James <sam@gentoo.org>
---- a/configure.ac
-+++ b/configure.ac
-@@ -94,9 +94,9 @@ AC_ARG_WITH([efivar],
- )
-
- # use the true program to avoid failing hard
--AS_IF([test "x$with_efivar" == "xauto"],
-+AS_IF([test "x$with_efivar" = "xauto"],
- [PKG_CHECK_MODULES([EFIVAR], [efivar], [AC_CHECK_HEADERS([efivar/efivar.h], , [true])], [true])],
-- [test "x$with_efivar" == "xyes"],
-+ [test "x$with_efivar" = "xyes"],
- [PKG_CHECK_MODULES([EFIVAR], [efivar], [AC_CHECK_HEADERS([efivar/efivar.h])])],
- )
-
-
diff --git a/app-crypt/tpm2-tools/files/tpm2-tools-5.6-test-eventlog-fix-check-eventlog.sh-if-efivar.h-exis.patch b/app-crypt/tpm2-tools/files/tpm2-tools-5.6-test-eventlog-fix-check-eventlog.sh-if-efivar.h-exis.patch
deleted file mode 100644
index f24cf50aff5c..000000000000
--- a/app-crypt/tpm2-tools/files/tpm2-tools-5.6-test-eventlog-fix-check-eventlog.sh-if-efivar.h-exis.patch
+++ /dev/null
@@ -1,123 +0,0 @@
-From 9cd74df24dbeee81b408e12ac10a98a088008d07 Mon Sep 17 00:00:00 2001
-From: Juergen Repp <juergen_repp@web.de>
-Date: Mon, 20 Nov 2023 13:55:36 +0100
-Subject: [PATCH] test eventlog: fix check eventlog.sh if efivar.h exists
-
-If efivar.h exist a pretty print function for the DevicePath
-is executed. Therefore two yaml test files are needed for
-the bin test file uefiservices.
-Fixes #3302.
-
-Signed-off-by: Juergen Repp <juergen_repp@web.de>
----
- Makefile.am | 13 ++++++
- configure.ac | 3 ++
- .../event-uefiservices.bin.yaml.pretty | 45 +++++++++++++++++++
- ...n.yaml => event-uefiservices.bin.yaml.raw} | 0
- 4 files changed, 61 insertions(+)
- create mode 100644 test/integration/fixtures/event-uefiservices.bin.yaml.pretty
- rename test/integration/fixtures/{event-uefiservices.bin.yaml => event-uefiservices.bin.yaml.raw} (100%)
-
-diff --git a/Makefile.am b/Makefile.am
-index 413345cd..ef76dca8 100644
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -352,6 +352,7 @@ TEST_EXTENSIONS = .sh
-
- check-hook:
- rm -rf .lock_file
-+ rm -f $(abs_top_srcdir)/test/integration/fixtures/event-uefiservices.bin.yaml
-
- EXTRA_DIST_IGNORE = \
- .gitignore \
-@@ -647,6 +648,18 @@ dist-hook:
- for f in $(EXTRA_DIST_IGNORE); do \
- rm -rf `find $(distdir) -name $$f`; \
- done;
-+
-+prepare-check:
-+if HAVE_EFIVAR_H
-+ cp $(abs_top_srcdir)/test/integration/fixtures/event-uefiservices.bin.yaml.pretty \
-+ $(abs_top_srcdir)/test/integration/fixtures/event-uefiservices.bin.yaml
-+else
-+ cp $(abs_top_srcdir)/test/integration/fixtures/event-uefiservices.bin.yaml.raw \
-+ $(abs_top_srcdir)/test/integration/fixtures/event-uefiservices.bin.yaml
-+endif
-+
-+check: prepare-check
-+
- if !HAVE_PANDOC
- # If pandoc is not enabled, we want to complain that you need pandoc for make dist,
- # so hook the target and complain.
-diff --git a/configure.ac b/configure.ac
-index 362ae0aa..54224048 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -97,6 +97,9 @@ AS_IF([test "x$with_efivar" == "xauto"],
- [PKG_CHECK_MODULES([EFIVAR], [efivar], [AC_CHECK_HEADERS([efivar/efivar.h])])],
- )
-
-+AC_CHECK_HEADERS([efivar/efivar.h],[efivar_h=yes ], [efivar = no ])
-+AM_CONDITIONAL([HAVE_EFIVAR_H], [test "$efivar_h" = yes])
-+
- # backwards compat with older pkg-config
- # - pull in AC_DEFUN from pkg.m4
- m4_ifndef([PKG_CHECK_VAR], [
-diff --git a/test/integration/fixtures/event-uefiservices.bin.yaml.pretty b/test/integration/fixtures/event-uefiservices.bin.yaml.pretty
-new file mode 100644
-index 00000000..f0819f70
---- /dev/null
-+++ b/test/integration/fixtures/event-uefiservices.bin.yaml.pretty
-@@ -0,0 +1,45 @@
-+---
-+version: 1
-+events:
-+- EventNum: 0
-+ PCRIndex: 0
-+ EventType: EV_NO_ACTION
-+ Digest: "0000000000000000000000000000000000000000"
-+ EventSize: 37
-+ SpecID:
-+ - Signature: Spec ID Event03
-+ platformClass: 0
-+ specVersionMinor: 0
-+ specVersionMajor: 2
-+ specErrata: 0
-+ uintnSize: 2
-+ numberOfAlgorithms: 2
-+ Algorithms:
-+ - Algorithm[0]:
-+ algorithmId: sha1
-+ digestSize: 20
-+ - Algorithm[1]:
-+ algorithmId: sha256
-+ digestSize: 32
-+ vendorInfoSize: 0
-+- EventNum: 1
-+ PCRIndex: 2
-+ EventType: EV_EFI_BOOT_SERVICES_DRIVER
-+ DigestCount: 2
-+ Digests:
-+ - AlgorithmId: sha1
-+ Digest: "855685b4dbd4b67d50e0594571055054cfe2b1e9"
-+ - AlgorithmId: sha256
-+ Digest: "dd8576b4ff346c19c56c3e4f97ce55c5afa646f9c669be0a7cdd05057a0ecdf3"
-+ EventSize: 84
-+ Event:
-+ ImageLocationInMemory: 0x7dcf6018
-+ ImageLengthInMemory: 171464
-+ ImageLinkTimeAddress: 0x0
-+ LengthOfDevicePath: 52
-+ DevicePath1: 'PciRoot(0x0)/Pci(0x2,0x0)/Pci(0x0,0x0)/Offset(0x12600,0x3c3ff)'
-+pcrs:
-+ sha1:
-+ 2 : 0x5b5f4d5c31664f01670a98a5796a36473671befc
-+ sha256:
-+ 2 : 0x35fcf9d737c52c971f7c74058d36937dbd7824177fa0f1de3eba3934fcb83b9d
-diff --git a/test/integration/fixtures/event-uefiservices.bin.yaml b/test/integration/fixtures/event-uefiservices.bin.yaml.raw
-similarity index 100%
-rename from test/integration/fixtures/event-uefiservices.bin.yaml
-rename to test/integration/fixtures/event-uefiservices.bin.yaml.raw
---
-2.41.0
-
diff --git a/app-crypt/tpm2-tools/files/tpm2-tools-5.6-test-eventlog.sh-Fix-accidental-deletions.patch b/app-crypt/tpm2-tools/files/tpm2-tools-5.6-test-eventlog.sh-Fix-accidental-deletions.patch
deleted file mode 100644
index 7274ee40827a..000000000000
--- a/app-crypt/tpm2-tools/files/tpm2-tools-5.6-test-eventlog.sh-Fix-accidental-deletions.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-From 4dec5295361d753c3466bc9e8b0ae3a3cc58dff5 Mon Sep 17 00:00:00 2001
-From: Juergen Repp <juergen_repp@web.de>
-Date: Thu, 4 Apr 2024 09:42:51 +0200
-Subject: [PATCH] test eventlog.sh Fix accidental deletions.
-
-* Accidental deletions made in commit 196e3d439407e81040ced054a8ed302489348a9d
- are undone.
-* python3 is used as default instead of python.
-
-Signed-off-by: Juergen Repp <juergen_repp@web.de>
----
- test/integration/tests/eventlog.sh | 33 ++++++++++++++++++++++++++++--
- 1 file changed, 31 insertions(+), 2 deletions(-)
-
-diff --git a/test/integration/tests/eventlog.sh b/test/integration/tests/eventlog.sh
-index 9d5290f0..e7c13706 100755
---- a/test/integration/tests/eventlog.sh
-+++ b/test/integration/tests/eventlog.sh
-@@ -3,7 +3,7 @@
- set -E
- shopt -s expand_aliases
-
--alias python=${PYTHON-python}
-+alias python=${PYTHON-python3}
-
- yaml_validate() {
- cmd=$1
-@@ -88,7 +88,36 @@ expect_pass() {
- expect_fail
- expect_fail foo
- expect_fail foo bar
--expect_fail ${srcdir}/test/integration/fix
-+expect_fail ${srcdir}/test/integration/fixtures/event-bad.bin
-+
-+expect_pass ${srcdir}/test/integration/fixtures/specid-vendordata.bin
-+expect_pass ${srcdir}/test/integration/fixtures/event.bin
-+expect_pass ${srcdir}/test/integration/fixtures/event-uefivar.bin
-+expect_pass ${srcdir}/test/integration/fixtures/event-uefiaction.bin
-+expect_pass ${srcdir}/test/integration/fixtures/event-uefiservices.bin
-+expect_pass ${srcdir}/test/integration/fixtures/event-uefi-sha1-log.bin
-+expect_pass ${srcdir}/test/integration/fixtures/event-bootorder.bin
-+expect_pass ${srcdir}/test/integration/fixtures/event-postcode.bin
-+
-+# Make sure that --eventlog-version=2 works on complete TPM2 logs
-+expect_pass ${srcdir}/test/integration/fixtures/event-arch-linux.bin --eventlog-version=2
-+expect_pass ${srcdir}/test/integration/fixtures/event-gce-ubuntu-2104-log.bin --eventlog-version=2
-+expect_pass ${srcdir}/test/integration/fixtures/event-sd-boot-fedora37.bin --eventlog-version=2
-+expect_pass ${srcdir}/test/integration/fixtures/event-moklisttrusted.bin --eventlog-version=2
-+
-+# Pick an event with leading whitespace and validate we have
-+# preserved it correctly after parsing the YAML
-+event=$(yaml_validate "print(y['events'][80]['Event']['String'])" < ${srcdir}/test/integration/fixtures/event-moklisttrusted.bin.yaml | tr -d '\0')
-+expect=$(echo -e "grub_cmd: menuentry UEFI Firmware Settings --id uefi-firmware {\n\t\tfwsetup\n\t}")
-+if test "$event" != "$expect"
-+then
-+ echo "Got $event"
-+ echo "Want $expect"
-+ exit 1
-+fi
-+
-+# Compare strings generated by tpm2_eventlog with binary data of the corresponding
-+# events.
- hex_file="${srcdir}/test/integration/fixtures/event-moklisttrusted-hex.yaml"
- tool_file="${srcdir}/test/integration/fixtures/event-moklisttrusted.bin.yaml"
-
---
-2.43.2
-
diff --git a/app-crypt/tpm2-tools/files/tpm2-tools-5.7-tests-Eliminate-dependency-on-which.patch b/app-crypt/tpm2-tools/files/tpm2-tools-5.7-tests-Eliminate-dependency-on-which.patch
new file mode 100644
index 000000000000..1872d7d2389e
--- /dev/null
+++ b/app-crypt/tpm2-tools/files/tpm2-tools-5.7-tests-Eliminate-dependency-on-which.patch
@@ -0,0 +1,42 @@
+From e9af1553f26ebad6e8db14b599dc74bab5663806 Mon Sep 17 00:00:00 2001
+From: Christopher Byrne <salah.coronya@gmail.com>
+Date: Tue, 16 Apr 2024 09:32:30 -0500
+Subject: [PATCH] tests: Eliminate dependency on 'which'
+
+See https://lwn.net/Articles/874049/
+
+Signed-off-by: Christopher Byrne <salah.coronya@gmail.com>
+---
+ test/integration/tests/pcrevent.sh | 2 +-
+ test/integration/tests/symlink.sh | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/test/integration/tests/pcrevent.sh b/test/integration/tests/pcrevent.sh
+index 5484cfbe..d7166789 100644
+--- a/test/integration/tests/pcrevent.sh
++++ b/test/integration/tests/pcrevent.sh
+@@ -44,7 +44,7 @@ yaml_verify $hash_out_file
+ while IFS='' read -r l || [[ -n "$l" ]]; do
+
+ alg=`echo -n $l | cut -d\: -f 1-1`
+- if ! which "$alg"sum >/dev/null 2>&1; then
++ if ! command -v "$alg"sum >/dev/null 2>&1; then
+ echo "Ignore checking $alg algorithm due to unavailable \"${alg}sum\" program"
+ continue
+ fi
+diff --git a/test/integration/tests/symlink.sh b/test/integration/tests/symlink.sh
+index 606e1a1a..f65a7567 100644
+--- a/test/integration/tests/symlink.sh
++++ b/test/integration/tests/symlink.sh
+@@ -17,7 +17,7 @@ start_up
+ # Positive tests:
+ #
+ fail=0
+-TPM2_TOOL="$(which tpm2)"
++TPM2_TOOL="$(command -v tpm2)"
+
+ if [ -z "$TPM2_TOOL" ]; then
+ echo "unable to locate tpm2 tool"
+--
+2.45.2
+
diff --git a/app-crypt/tpm2-tools/tpm2-tools-5.5.ebuild b/app-crypt/tpm2-tools/tpm2-tools-5.5.ebuild
deleted file mode 100644
index 866f1e799d24..000000000000
--- a/app-crypt/tpm2-tools/tpm2-tools-5.5.ebuild
+++ /dev/null
@@ -1,66 +0,0 @@
-# Copyright 1999-2024 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{10..12} )
-inherit bash-completion-r1 flag-o-matic python-any-r1
-
-DESCRIPTION="Tools for the TPM 2.0 TSS"
-HOMEPAGE="https://github.com/tpm2-software/tpm2-tools"
-SRC_URI="https://github.com/tpm2-software/tpm2-tools/releases/download/${PV}/${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="amd64 arm arm64 ppc64 x86"
-IUSE="+fapi test"
-
-RESTRICT="!test? ( test )"
-
-RDEPEND=">=app-crypt/tpm2-tss-3.0.1:=[fapi?]
- dev-libs/openssl:=
- net-misc/curl
- sys-libs/efivar:="
-DEPEND="${RDEPEND}
- test? (
- app-crypt/swtpm
- app-crypt/tpm2-abrmd
- dev-util/cmocka
- )"
-BDEPEND="virtual/pkgconfig
- dev-build/autoconf-archive
- test? (
- app-editors/vim-core
- dev-tcltk/expect
- $(python_gen_any_dep 'dev-python/pyyaml[${PYTHON_USEDEP}]')
- )
- ${PYTHON_DEPS}"
-
-python_check_deps() {
- python_has_version "dev-python/pyyaml[${PYTHON_USEDEP}]"
-}
-
-pkg_setup() {
- use test && python-any-r1_pkg_setup
-}
-
-src_configure() {
- # tests fail with LTO enabbled. See bug 865275 and 865277
- filter-lto
- econf \
- $(use_enable fapi) \
- $(use_enable test unit) \
- --with-bashcompdir=$(get_bashcompdir) \
- --enable-hardening
-}
-
-src_install() {
- default
- mv "${ED}"/$(get_bashcompdir)/tpm2{_completion.bash,} || die
- local utils=( "${ED}"/usr/bin/tpm2_* )
- utils=("${utils[@]##*/}")
- # these utiltites don't have bash completions
- local nobashcomp=( tpm2_encodeobject tpm2_getpolicydigest tpm2_sessionconfig )
- mapfile -d $'\0' -t utils < <(printf '%s\0' "${utils[@]}" | grep -Ezvw "${nobashcomp[@]/#/-e}")
- bashcomp_alias tpm2 "${utils[@]}"
-}
diff --git a/app-crypt/tpm2-tools/tpm2-tools-5.6-r1.ebuild b/app-crypt/tpm2-tools/tpm2-tools-5.6-r1.ebuild
deleted file mode 100644
index ab59eed9520d..000000000000
--- a/app-crypt/tpm2-tools/tpm2-tools-5.6-r1.ebuild
+++ /dev/null
@@ -1,81 +0,0 @@
-# Copyright 1999-2024 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{10..12} )
-inherit autotools bash-completion-r1 flag-o-matic python-any-r1
-
-DESCRIPTION="Tools for the TPM 2.0 TSS"
-HOMEPAGE="https://github.com/tpm2-software/tpm2-tools"
-SRC_URI="https://github.com/tpm2-software/tpm2-tools/releases/download/${PV}/${P}.tar.gz"
-SRC_URI+=" https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/tpm2-tools-5.6-tpm2_eventlog-Create-raw-and-pretty-print-format-for.patch.xz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
-IUSE="+fapi test"
-
-RESTRICT="!test? ( test )"
-
-RDEPEND=">=app-crypt/tpm2-tss-3.0.1:=[fapi?]
- dev-libs/openssl:=
- net-misc/curl
- sys-libs/efivar:="
-DEPEND="${RDEPEND}
- test? (
- app-crypt/swtpm
- app-crypt/tpm2-abrmd
- dev-util/cmocka
- )"
-BDEPEND="virtual/pkgconfig
- dev-build/autoconf-archive
- test? (
- app-editors/vim-core
- dev-tcltk/expect
- $(python_gen_any_dep 'dev-python/pyyaml[${PYTHON_USEDEP}]')
- )
- ${PYTHON_DEPS}"
-
-PATCHES=(
- "${FILESDIR}/${PN}-5.6-test-eventlog-fix-check-eventlog.sh-if-efivar.h-exis.patch"
- "${WORKDIR}/${PN}-5.6-tpm2_eventlog-Create-raw-and-pretty-print-format-for.patch"
- "${FILESDIR}/${PN}-5.6-Makefile-am-Dont-require-pandoc-for-tests.patch"
- "${FILESDIR}/${PN}-5.6-bashism.patch"
- "${FILESDIR}/${PN}-5.6-test-eventlog.sh-Fix-accidental-deletions.patch"
-)
-
-python_check_deps() {
- python_has_version "dev-python/pyyaml[${PYTHON_USEDEP}]"
-}
-
-pkg_setup() {
- use test && python-any-r1_pkg_setup
-}
-
-src_prepare() {
- default
- eautoreconf
-}
-
-src_configure() {
- # tests fail with LTO enabbled. See bug 865275 and 865277
- filter-lto
- econf \
- $(use_enable fapi) \
- $(use_enable test unit) \
- --with-bashcompdir=$(get_bashcompdir) \
- --enable-hardening
-}
-
-src_install() {
- default
- mv "${ED}"/$(get_bashcompdir)/tpm2{_completion.bash,} || die
- local utils=( "${ED}"/usr/bin/tpm2_* )
- utils=("${utils[@]##*/}")
- # these utiltites don't have bash completions
- local nobashcomp=( tpm2_encodeobject tpm2_getpolicydigest\
- tpm2_sessionconfig tpm2_tr_encode)
- mapfile -d $'\0' -t utils < <(printf '%s\0' "${utils[@]}" | grep -Ezvw "${nobashcomp[@]/#/-e}")
- bashcomp_alias tpm2 "${utils[@]}"
-}
diff --git a/app-crypt/tpm2-tools/tpm2-tools-5.6.1.ebuild b/app-crypt/tpm2-tools/tpm2-tools-5.6.1.ebuild
deleted file mode 100644
index d66c553ca767..000000000000
--- a/app-crypt/tpm2-tools/tpm2-tools-5.6.1.ebuild
+++ /dev/null
@@ -1,87 +0,0 @@
-# Copyright 1999-2024 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{10..12} )
-inherit autotools bash-completion-r1 flag-o-matic python-any-r1
-
-DESCRIPTION="Tools for the TPM 2.0 TSS"
-HOMEPAGE="https://github.com/tpm2-software/tpm2-tools"
-SRC_URI="https://github.com/tpm2-software/tpm2-tools/releases/download/${PV}/${P}.tar.gz"
-SRC_URI+=" https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/tpm2-tools-5.6-tpm2_eventlog-Create-raw-and-pretty-print-format-for.patch.xz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="amd64 arm arm64 ppc64 x86"
-IUSE="+fapi test"
-
-RESTRICT="!test? ( test )"
-
-RDEPEND=">=app-crypt/tpm2-tss-3.0.1:=[fapi?]
- dev-libs/openssl:=
- net-misc/curl
- sys-libs/efivar:="
-DEPEND="${RDEPEND}
- test? (
- app-crypt/swtpm
- app-crypt/tpm2-abrmd
- dev-util/cmocka
- )"
-BDEPEND="virtual/pkgconfig
- dev-build/autoconf-archive
- test? (
- app-editors/vim-core
- dev-tcltk/expect
- $(python_gen_any_dep 'dev-python/pyyaml[${PYTHON_USEDEP}]')
- )
- ${PYTHON_DEPS}"
-
-PATCHES=(
- "${FILESDIR}/${PN}-5.6-test-eventlog-fix-check-eventlog.sh-if-efivar.h-exis.patch"
- "${WORKDIR}/${PN}-5.6-tpm2_eventlog-Create-raw-and-pretty-print-format-for.patch"
- "${FILESDIR}/${PN}-5.6-Makefile-am-Dont-require-pandoc-for-tests.patch"
- "${FILESDIR}/${PN}-5.6-test-eventlog.sh-Fix-accidental-deletions.patch"
-)
-
-python_check_deps() {
- python_has_version "dev-python/pyyaml[${PYTHON_USEDEP}]"
-}
-
-pkg_setup() {
- use test && python-any-r1_pkg_setup
-}
-
-src_prepare() {
- default
- eautoreconf
-}
-
-src_configure() {
- # tests fail with LTO enabbled. See bug 865275 and 865277
- filter-lto
- econf \
- $(use_enable fapi) \
- $(use_enable test unit) \
- --with-bashcompdir=$(get_bashcompdir) \
- --enable-hardening
-}
-
-src_install() {
- default
- mv "${ED}"/$(get_bashcompdir)/tpm2{_completion.bash,} || die
- local utils=( "${ED}"/usr/bin/tpm2_* )
- utils=("${utils[@]##*/}")
- # these utiltites don't have bash completions
- local nobashcomp=( tpm2_encodeobject tpm2_getpolicydigest\
- tpm2_sessionconfig tpm2_tr_encode)
- mapfile -d $'\0' -t utils < <(printf '%s\0' "${utils[@]}" | grep -Ezvw "${nobashcomp[@]/#/-e}")
- bashcomp_alias tpm2 "${utils[@]}"
-}
-
-src_test() {
-# This hook doesn't get invoked consisently, so call it manually
-# else one of the tests will fail
- emake prepare-check
- default
-}
diff --git a/app-crypt/tpm2-tools/tpm2-tools-5.7.ebuild b/app-crypt/tpm2-tools/tpm2-tools-5.7.ebuild
index 99c2a66f1a7f..aa2d0dcdcc58 100644
--- a/app-crypt/tpm2-tools/tpm2-tools-5.7.ebuild
+++ b/app-crypt/tpm2-tools/tpm2-tools-5.7.ebuild
@@ -38,6 +38,7 @@ BDEPEND="virtual/pkgconfig
PATCHES=(
"${FILESDIR}/${PN}-5.6-Makefile-am-Dont-require-pandoc-for-tests.patch"
+ "${FILESDIR}/${PN}-5.7-tests-Eliminate-dependency-on-which.patch"
)
python_check_deps() {