Skip to content

Commit

Permalink
modules/tpm2-tss: sed configure script to remove hardcoding of libs, …
Browse files Browse the repository at this point in the history
…move patch 3.2.0->3.2.2

disable static lib builds

Signed-off-by: Thierry Laurion <[email protected]>
  • Loading branch information
tlaurion committed Apr 3, 2024
1 parent 2834616 commit cf97b65
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 15 deletions.
26 changes: 11 additions & 15 deletions modules/tpm2-tss
Original file line number Diff line number Diff line change
@@ -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 \
Expand All @@ -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
Expand Down
File renamed without changes.

0 comments on commit cf97b65

Please sign in to comment.