From 7e1d399584fd2eb0c8e6f49c473ff6b1a2a7ecf6 Mon Sep 17 00:00:00 2001 From: Nick Wellnhofer Date: Mon, 24 Nov 2014 21:59:30 +0100 Subject: Fix MSVC options Also disable some warnings. --- src/CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/CMakeLists.txt') diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 71f45a7..f71f09c 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -121,13 +121,14 @@ if(MSVC) else() set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /W4") endif() + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /wd4127 /wd4244 /wd4267 /wd4706 /wd4800 /D_CRT_SECURE_NO_WARNINGS") elseif(CMAKE_COMPILER_IS_GNUCC OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -std=c99 -pedantic") endif() # Compile as C++ under MSVC if(MSVC) - set(CMAKE_C_FLAGS "/TP") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /TP") endif() if($ENV{TIMER}) -- cgit v1.2.3