mirror of
https://github.com/google/googletest.git
synced 2026-07-30 08:16:27 +08:00
fix: initialize cxx_strict_flags before compiler branches
cxx_strict_flags was omitted in several compiler conditional blocks (such as MSVC, SunPro, XL, and HP), leading to a CMake developer warning about an uninitialized variable when dev warnings are enabled. Fixes #4071
This commit is contained in:
parent
fa005b296f
commit
51109ebb47
@ -70,6 +70,7 @@ macro(config_compiler_and_linker)
|
||||
endif()
|
||||
|
||||
fix_default_compiler_settings_()
|
||||
set(cxx_strict_flags "")
|
||||
if (MSVC)
|
||||
# Newlines inside flags variables break CMake's NMake generator.
|
||||
# TODO(vladl@google.com): Add -RTCs and -RTCu to debug builds.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user