mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-03-08 20:58:20 +03:00
meson: Compile with -ftrivial-auto-var-init=zero in release mode
This commit is contained in:
parent
7eeedcfcb1
commit
1a4e392760
@ -413,6 +413,13 @@ if cc.get_id() == 'clang'
|
|||||||
]
|
]
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
if get_option('mode') == 'release'
|
||||||
|
# We could enable 'pattern' for developer mode, but that can interfere with
|
||||||
|
# valgrind and sanitizer builds. Also, clang does not zero-initialize unions,
|
||||||
|
# breaking some of our code (https://reviews.llvm.org/D68115).
|
||||||
|
possible_common_cc_flags += '-ftrivial-auto-var-init=zero'
|
||||||
|
endif
|
||||||
|
|
||||||
possible_cc_flags = possible_common_cc_flags + [
|
possible_cc_flags = possible_common_cc_flags + [
|
||||||
'-Werror=missing-declarations',
|
'-Werror=missing-declarations',
|
||||||
'-Werror=missing-prototypes',
|
'-Werror=missing-prototypes',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user