From abf4414edcea5e56092faea23c24176d361c2900 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sun, 21 Jan 2024 14:09:19 +0000 Subject: gentoo auto-resync : 21:01:2024 - 14:09:19 --- app-crypt/Manifest.gz | Bin 24795 -> 24796 bytes app-crypt/tpm2-tools/Manifest | 3 +- .../tpm2-tools/files/tpm2-tools-5.6-bashism.patch | 47 ++++++++++++ app-crypt/tpm2-tools/tpm2-tools-5.6-r1.ebuild | 79 +++++++++++++++++++++ app-crypt/tpm2-tools/tpm2-tools-5.6.ebuild | 78 -------------------- 5 files changed, 128 insertions(+), 79 deletions(-) create mode 100644 app-crypt/tpm2-tools/files/tpm2-tools-5.6-bashism.patch create mode 100644 app-crypt/tpm2-tools/tpm2-tools-5.6-r1.ebuild delete mode 100644 app-crypt/tpm2-tools/tpm2-tools-5.6.ebuild (limited to 'app-crypt') diff --git a/app-crypt/Manifest.gz b/app-crypt/Manifest.gz index a44aba062ebb..7f5f2b198acf 100644 Binary files a/app-crypt/Manifest.gz and b/app-crypt/Manifest.gz differ diff --git a/app-crypt/tpm2-tools/Manifest b/app-crypt/tpm2-tools/Manifest index 584d0168d050..ff0955b57b54 100644 --- a/app-crypt/tpm2-tools/Manifest +++ b/app-crypt/tpm2-tools/Manifest @@ -1,8 +1,9 @@ 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 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.tar.gz 1266731 BLAKE2B fe88722c26d62128cd6dfbdd8ef2568656a75fe27b1443fed28387d0db1f50b7d0651819d34dfa98acde785b4cfb4e7c11420b110bb5333ed2bb6b67cdd4fc70 SHA512 14216f29ed3ecca5fbe356ed3744c8b6b25a62ff11b2aed596d11101328c8bfd29a02f6ca5a218f9a4477a5e9648c50f0ae96e71de0b4ff5ea1f98ebeeb73cd7 EBUILD tpm2-tools-5.5.ebuild 1643 BLAKE2B 5029ad3299b8db9d0005866660db88884833619fade7131a6b4b7b42f1ce62a2fe8eb94ad175b889bd2d9c2b6d4bf5d91d2455bd0ea0a9ad8e0c59565c73b1e2 SHA512 195dc492373400638ec7baa5c191e7eeea646523f296ff16422ae56d7347e5e6fdea12d199e8d32bc700790f9a206b5e84b0e52348f67b4ad681e6889cf1703e -EBUILD tpm2-tools-5.6.ebuild 2097 BLAKE2B b20ad171d741a4bc8064cceca1714363d358c159dae897cc3d988e5c1f2dd1bdc5e732a9e3649b156b0dd1dc44f4b13da3153033b0a7be42d2bdfc469aa95654 SHA512 97649e27d64614efffa45574067dd9aa2ae7f3ed29d606980afd1df5b7369c107a4b74a4c05ab3edaed772dc33757bd36db6b67a7785bb7aea10036ff6c713f5 +EBUILD tpm2-tools-5.6-r1.ebuild 2136 BLAKE2B 9e38fb753afab5ef0051974999e02b8278ee58b56f85f47af710528a5f152941d2a271b044353bc42311457b194911dfe694de68f36e26982e444badff16a041 SHA512 e13b283a2d49273ec813d5d114f3e70db4c4461d6b36980791a8b0f66f734114edc840a3903e28009d831eb5dd7d4fbddf85fb8525304797e0cc2d7099f2f673 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 new file mode 100644 index 000000000000..01ce4301d4e3 --- /dev/null +++ b/app-crypt/tpm2-tools/files/tpm2-tools-5.6-bashism.patch @@ -0,0 +1,47 @@ +https://github.com/tpm2-software/tpm2-tools/pull/3339 + +From 9f244c3f74747b7f79c8c6813657b2f2f8a1c844 Mon Sep 17 00:00:00 2001 +From: Sam James +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 +--- 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/tpm2-tools-5.6-r1.ebuild b/app-crypt/tpm2-tools/tpm2-tools-5.6-r1.ebuild new file mode 100644 index 000000000000..04fb5536f1f5 --- /dev/null +++ b/app-crypt/tpm2-tools/tpm2-tools-5.6-r1.ebuild @@ -0,0 +1,79 @@ +# 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" +) + +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 ) + 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.ebuild b/app-crypt/tpm2-tools/tpm2-tools-5.6.ebuild deleted file mode 100644 index 3eb1badf0637..000000000000 --- a/app-crypt/tpm2-tools/tpm2-tools-5.6.ebuild +++ /dev/null @@ -1,78 +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" -) - -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 ) - mapfile -d $'\0' -t utils < <(printf '%s\0' "${utils[@]}" | grep -Ezvw "${nobashcomp[@]/#/-e}") - bashcomp_alias tpm2 "${utils[@]}" -} -- cgit v1.2.3