Dear Maintainer,
The build of tpm2-pkcs11 fails on hppa with the following error:
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I./src/lib -Wdate-time -D_FORTIFY_SOURCE=2 -I./src -I./src/lib -Wall -Wextra -Werror -Wformat -Wformat-security -Wstack-protector -fstack-protector-all -Wstrict-overflow=5 -O2 -fPIC -pthread -g -O2 -fdebug-prefix-map=/<<PKGBUILDDIR>>=. -Wformat -Werror=format-security -g -c src/lib/attrs.c -fPIC -DPIC -o src/lib/.libs/attrs.o
cc1: error: ‘-fstack-protector’ not supported for this target [-Werror]
cc1: all warnings being treated as errors
make[1]: *** [Makefile:1577: src/lib/digest.lo] Error 1
See:
https://buildd.debian.org/status/fetch.php?pkg=tpm2-pkcs11&arch=hppa&ver=1.2.0-1&stamp=1589690866&raw=0
The problem is the configure check for -fstack-protector-all is broken:
configure:12151: checking whether C compiler accepts -fstack-protector-all
configure:12170: gcc -c -g -O2 -fdebug-prefix-map=/home/dave/debian/tpm2-pkcs11/tpm2-pkcs11-1.2.0=. -Wformat -Werror=format-security -g -fstack-protector-all -Wdate-time -D_FORTIFY_SOURCE=2 conftest.c >&5
cc1: warning: '-fstack-protector' not supported for this target
configure:12170: $? = 0
configure:12178: result: yes
As you can see, there is a warning but -Werror is not passed in the configure
check, so the test passes.
There is a similar problem in tpm2-tools.
This problem also affects alpha and ia64.
Regards,
Dave Anglin