Add -D__STDC_LIMIT_MACROS for Visual Studio 2017.
Fixes a problem with `INT64_MAX` etc. being undeclared. Signed-off-by: Rafael Kitover <rkitover@gmail.com>
This commit is contained in:
parent
3a6e4b3c27
commit
a078dd2487
|
@ -730,7 +730,7 @@ elseif(MSVC)
|
||||||
string(REGEX REPLACE "/[Ww][^ ]+" "" CMAKE_C_FLAGS ${CMAKE_C_FLAGS})
|
string(REGEX REPLACE "/[Ww][^ ]+" "" CMAKE_C_FLAGS ${CMAKE_C_FLAGS})
|
||||||
string(REGEX REPLACE "/[Ww][^ ]+" "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
|
string(REGEX REPLACE "/[Ww][^ ]+" "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
|
||||||
|
|
||||||
add_compile_options(/std:c++17)
|
add_compile_options(/std:c++17 -D__STDC_LIMIT_MACROS)
|
||||||
|
|
||||||
if(CMAKE_BUILD_TYPE STREQUAL Debug)
|
if(CMAKE_BUILD_TYPE STREQUAL Debug)
|
||||||
add_compile_options(/W4)
|
add_compile_options(/W4)
|
||||||
|
|
Loading…
Reference in New Issue