summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Persch <chpe@src.gnome.org>2021-12-27 19:24:46 +0100
committerChristian Persch <chpe@src.gnome.org>2021-12-27 19:25:00 +0100
commiteca903d08cab9900fed9fd2f6e827479dab503f7 (patch)
tree6399835846506fcf8b10bbe49eaf8b1344f83b1d
parent95b57dd74209d22a6aae7d66d532c33e646e5be0 (diff)
downloadvte-eca903d08cab9900fed9fd2f6e827479dab503f7.tar.gz
build: Fix check for -fstack-protector* compiler support
Need to use has_link_argument() on some platforms. Fixes: https://gitlab.gnome.org/GNOME/vte/-/issues/2535 (cherry picked from commit e32dba1d5cf884959af5b2c0691db00c263ea048)
-rw-r--r--meson.build6
1 files changed, 4 insertions, 2 deletions
diff --git a/meson.build b/meson.build
index eef5f6a8..4970b0dc 100644
--- a/meson.build
+++ b/meson.build
@@ -348,8 +348,6 @@ compiler_flags_common = [
'-fdiagnostics-show-option',
'-fno-common',
'-fno-semantic-interposition',
- '-fstack-protector',
- '-fstack-protector-strong',
]
if enable_debug
@@ -437,6 +435,10 @@ add_project_arguments(global_cxxflags, language: 'cpp')
linker_flags = [
['-Wl,-Bsymbolic', false,],
['-Wl,-Bsymbolic-functions', get_option('_b_symbolic_functions'),],
+
+ # See issue vte#2535.
+ ['-fstack-protector', false],
+ ['-fstack-protector-strong', false],
]
foreach flag: linker_flags