diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2017-03-18 00:22:41 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2017-03-18 00:22:41 +0100 |
commit | de4160206991947a45ae167c513c0c41d63381d5 (patch) | |
tree | 4893babd128fe8759a7fbc002ff3eed3aaf5cd6b /cmake/msvc.cmake | |
parent | fe1d213a5383b7967e6eb08685c513166996f032 (diff) |
cmake/msvc: disable truncation warning
Diffstat (limited to 'cmake/msvc.cmake')
-rw-r--r-- | cmake/msvc.cmake | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/cmake/msvc.cmake b/cmake/msvc.cmake index dbdfa4db..32e32641 100644 --- a/cmake/msvc.cmake +++ b/cmake/msvc.cmake @@ -16,7 +16,8 @@ set(cc "/O2it /Ob2 /arch:SSE2 /fp:fast /GS- /GF /GL /Gw /Gy") set(warns_ "") -set(warns-disable 4530 4577 4789) +#C4244: 'return': conversion from '__int64' to 'long', possible loss of data +set(warns-disable 4530 4577 4789 4244) foreach(i ${warns-disable}) set(warns_ "${warns_} /wd${i}") @@ -100,7 +101,7 @@ if((CMAKE_GENERATOR STREQUAL "NMake Makefiles") OR (CMAKE_GENERATOR STREQUAL "NM if(CMAKE_PROJECT_NAME STREQUAL "opentrack") set(warn-flag-found FALSE) foreach (i CMAKE_CXX_FLAGS CMAKE_C_FLAGS) - string(REGEX MATCH "((^| )/[W][0-9]( |\$))" ret "${${i}}") + string(REGEX MATCH "((^| )[-/][W][0-9]( |\$))" ret "${${i}}") if(ret STREQUAL "") set(${i} "-W3 ${${i}}" CACHE STRING "" FORCE) endif() |