]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
fix build with compilers with default stack-protector enabled
authorNorbert Lange <norbert.lange@andritz.com>
Thu, 19 Sep 2019 15:49:20 +0000 (17:49 +0200)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Thu, 3 Oct 2019 10:19:29 +0000 (12:19 +0200)
building systemd fails with a compiler that supports
-fstack-protector but does not enable it by default.
(will miss several __stack_chk_* symbols).

fix this by also adding the switch during linking.

Signed-off-by: Norbert Lange <nolange79@gmail.com>
meson.build

index 4ef08a95391113b4727662a7c8d82b97b6d05311..69d06a1bf3c92db4da184ee4a3fb73564784f05a 100644 (file)
@@ -382,6 +382,7 @@ possible_cc_flags = [
 possible_link_flags = [
         '-Wl,-z,relro',
         '-Wl,-z,now',
+        '-fstack-protector',
 ]
 
 if cc.get_id() == 'clang'