mirror of
https://github.com/moparisthebest/curl
synced 2025-02-28 09:21:50 -05:00
CMake: fix CURL_WERROR for MSVC
When using CURL_WERROR in MSVC builds, the debug flags were overridden by the release flags and /WX got added twice in debug mode. Closes https://github.com/curl/curl/pull/1715
This commit is contained in:
parent
26e02eae4b
commit
54aef857b3
@ -246,7 +246,7 @@ endif(BORLAND)
|
||||
if(CURL_WERROR)
|
||||
if(MSVC_VERSION)
|
||||
set(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} /WX")
|
||||
set(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_RELEASE} /WX")
|
||||
set(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} /WX")
|
||||
else()
|
||||
# this assumes clang or gcc style options
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Werror")
|
||||
|
Loading…
x
Reference in New Issue
Block a user