From 8208c86efefa5df2e28f63417fba86b8e09ff8c1 Mon Sep 17 00:00:00 2001 From: Thierry Laurion Date: Tue, 2 Apr 2024 16:02:13 -0400 Subject: [PATCH] modules/tpm2-tss: sed configure script to remove hardcoding of libs, move patch 3.2.0->3.2.2 disable static lib builds Signed-off-by: Thierry Laurion --- modules/tpm2-tss | 26 ++++++++----------- ...2-tss-3.2.0.patch => tpm2-tss-3.2.2.patch} | 0 2 files changed, 11 insertions(+), 15 deletions(-) rename patches/{tpm2-tss-3.2.0.patch => tpm2-tss-3.2.2.patch} (100%) diff --git a/modules/tpm2-tss b/modules/tpm2-tss index eb5af1b4..3795e21f 100644 --- a/modules/tpm2-tss +++ b/modules/tpm2-tss @@ -1,27 +1,22 @@ # TPM2 TSS library modules-$(CONFIG_TPM2_TSS) += tpm2-tss -tpm2-tss_version := 3.2.0 +tpm2-tss_version := 3.2.2 tpm2-tss_dir := tpm2-tss-$(tpm2-tss_version) tpm2-tss_tar := tpm2-tss-$(tpm2-tss_version).tar.gz tpm2-tss_url := https://github.com/tpm2-software/tpm2-tss/releases/download/$(tpm2-tss_version)/$(tpm2-tss_tar) -tpm2-tss_hash := 48305e4144dcf6d10f3b25b7bccf0189fd2d1186feafd8cd68c6b17ecf0d7912 +tpm2-tss_hash := ba9e52117f254f357ff502e7d60fce652b3bfb26327d236bbf5ab634235e40f1 +#Repro checks: +# find build/x86/tpm2-tss-3.2.2/src/*/.libs/libtss2-*so* | while read file; do echo "library $file:"; strings $file|grep heads; done +# Should not return any result + +#NEEDED otherwise output on previous command +#sed -i 's/hardcode_into_libs=yes/hardcode_into_libs=no/g' configure +# needed otherwise library build/x86/tpm2-tss-3.2.2/src/tss2-tcti/.libs/libtss2-tcti-pcap.so.0.0.0: +# contains: /home/user/heads/build/x86/tpm2-tss-3.2.2/src/tss2-tcti/.libs:/home/user/heads/build/x86/tpm2-tss-3.2.2/src/tss2-mu/.libs://lib tpm2-tss_configure := aclocal && automake --add-missing && autoreconf -fi \ - && sed -i 's/hardcode_direct=yes/hardcode_direct=no/g' configure \ - && sed -i 's/hardcode_libdir_flag_spec=.*/hardcode_libdir_flag_spec=" "/' configure \ - && sed -i 's/hardcode_minus_L=yes/hardcode_minus_L=no/g' configure \ - && sed -i 's/hardcode_direct_absolute=yes/hardcode_direct_absolute=no/g' configure \ && sed -i 's/hardcode_into_libs=yes/hardcode_into_libs=no/g' configure \ - && sed -i 's/hardcode_libdir_flag_spec_CXX=.*/hardcode_libdir_flag_spec_CXX=" "/' configure \ - && sed -i 's/hardcode_automatic=yes/hardcode_automatic=no/g' configure \ - && sed -i 's/hardcode_runpath_var=yes/hardcode_runpath_var=no/g' configure \ - && sed -i 's/hardcode_direct_CXX=yes/hardcode_direct_CXX=no/g' configure \ - && sed -i 's/hardcode_direct_absolute_CXX=yes/hardcode_direct_absolute_CXX=no/g' configure \ - && sed -i 's/hardcode_minus_L_CXX=yes/hardcode_minus_L_CXX=no/g' configure \ - && sed -i 's/hardcode_automatic_CXX=yes/hardcode_automatic_CXX=no/g' configure \ - && sed -i 's/inherit_rpath=yes/inherit_rpath=no/g' configure \ - && sed -i 's/inherit_rpath_CXX=yes/inherit_rpath_CXX=no/g' configure \ && ./configure \ $(CROSS_TOOLS) \ --host $(MUSL_ARCH)-elf-linux \ @@ -31,6 +26,7 @@ tpm2-tss_configure := aclocal && automake --add-missing && autoreconf -fi \ --disable-doxygen-rtf \ --disable-doxygen-html \ --disable-fapi \ + --disable-static \ # Run one build to generate the executables with the pre-defined # exec_prefix and datarootdir, then a second make to install the binaries diff --git a/patches/tpm2-tss-3.2.0.patch b/patches/tpm2-tss-3.2.2.patch similarity index 100% rename from patches/tpm2-tss-3.2.0.patch rename to patches/tpm2-tss-3.2.2.patch