mirror of
https://github.com/systemd/systemd
synced 2024-07-21 10:17:21 +00:00
meson: Add --warn-common and --fatal-warnings to link flags
This commit is contained in:
parent
aac977c892
commit
42e3bb357c
|
@ -387,11 +387,16 @@ endif
|
||||||
# --as-needed and --no-undefined are provided by meson by default,
|
# --as-needed and --no-undefined are provided by meson by default,
|
||||||
# run 'meson configure' to see what is enabled
|
# run 'meson configure' to see what is enabled
|
||||||
possible_link_flags = [
|
possible_link_flags = [
|
||||||
'-Wl,-z,relro',
|
'-Wl,--fatal-warnings',
|
||||||
'-Wl,-z,now',
|
'-Wl,-z,now',
|
||||||
|
'-Wl,-z,relro',
|
||||||
'-fstack-protector',
|
'-fstack-protector',
|
||||||
]
|
]
|
||||||
|
|
||||||
|
if get_option('b_sanitize') == 'none'
|
||||||
|
possible_link_flags += '-Wl,--warn-common'
|
||||||
|
endif
|
||||||
|
|
||||||
if cc.get_id() == 'clang'
|
if cc.get_id() == 'clang'
|
||||||
possible_common_cc_flags += [
|
possible_common_cc_flags += [
|
||||||
'-Wno-typedef-redefinition',
|
'-Wno-typedef-redefinition',
|
||||||
|
|
Loading…
Reference in a new issue