]> git.proxmox.com Git - swtpm.git/commit - configure.ac
build-sys: Use -Wl,-z,relro and -Wl,-z,now only when linking (clang)
authorStefan Berger <stefanb@linux.vnet.ibm.com>
Sat, 12 Sep 2020 12:57:33 +0000 (08:57 -0400)
committerStefan Berger <stefanb@us.ibm.com>
Sat, 12 Sep 2020 14:55:32 +0000 (10:55 -0400)
commit0586d2f55abfd6e9eaacab3e8f4d02b3ceb597e1
treef2e789d94f8b336d41f2b061f35f4000f983219a
parent2ba23cee13582d871dfbd53382e376b25f93250d
build-sys: Use -Wl,-z,relro and -Wl,-z,now only when linking (clang)

Clang complains if eiher one of those linker flags are used during compilation:

clang-9: error: -Wl,-z,relro: 'linker' input unused [-Werror,-Wunused-command-line-argument]
clang-9: error: -Wl,-z,now: 'linker' input unused [-Werror,-Wunused-command-line-argument]

This patch applies those flags only when linking.

Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
configure.ac
src/swtpm/Makefile.am