diff --git a/swtpm-fix-build.patch b/swtpm-fix-build.patch new file mode 100644 index 0000000..e0e0351 --- /dev/null +++ b/swtpm-fix-build.patch @@ -0,0 +1,19 @@ +Index: swtpm-0.8.0/configure.ac +=================================================================== +--- swtpm-0.8.0.orig/configure.ac ++++ swtpm-0.8.0/configure.ac +@@ -418,11 +418,11 @@ if test "x$enable_hardening" != "xno"; t + # Some versions of gcc fail with -Wstack-protector, + # some with -Wstack-protector-strong enabled + if ! $CC -fstack-protector-strong -Wstack-protector $srcdir/include/swtpm/tpm_ioctl.h 2>/dev/null; then +- if $CC -fstack-protector -Wstack-protector $srcdir/include/swtpm/tpm_ioctl.h 2>/dev/null; then +- HARDENING_CFLAGS="-fstack-protector -Wstack-protector" ++ if $CC -fstack-protector $srcdir/include/swtpm/tpm_ioctl.h 2>/dev/null; then ++ HARDENING_CFLAGS="-fstack-protector" + fi + else +- HARDENING_CFLAGS="-fstack-protector-strong -Wstack-protector" ++ HARDENING_CFLAGS="-fstack-protector-strong" + fi + + dnl Only support -D_FORTIFY_SOURCE=2 and have higher levels passed in by user diff --git a/swtpm.changes b/swtpm.changes index 75ad354..838a2bb 100644 --- a/swtpm.changes +++ b/swtpm.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue Mar 21 12:45:54 UTC 2023 - Marcus Meissner + +- swtpm-fix-build.patch: disable -Wstack-protector, it fails on s390x + ------------------------------------------------------------------- Mon Mar 6 20:21:50 UTC 2023 - Alberto Planas Dominguez diff --git a/swtpm.spec b/swtpm.spec index de2688a..b555a02 100644 --- a/swtpm.spec +++ b/swtpm.spec @@ -32,6 +32,7 @@ Group: System/Base URL: https://github.com/stefanberger/swtpm Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz Source100: swtpm-rpmlintrc +Patch0: swtpm-fix-build.patch BuildRequires: autoconf BuildRequires: automake BuildRequires: expect