From 17c91bad6f4c44c93933190eba5f08b69b257a67 Mon Sep 17 00:00:00 2001 From: Ahmad Fatoum Date: Thu, 23 Nov 2017 07:44:55 +0100 Subject: [PATCH] Disable CRT "secure" warnings Suppresses 88 of the 213 warnings reported when compiling with MSVC 2015 on AppVeyor. --- src/CMakeLists.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index fc1e4ca85..6ab8e6064 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -44,6 +44,8 @@ if(${PLATFORM} MATCHES "Desktop") set(GRAPHICS "GRAPHICS_API_OPENGL_33") set_source_files_properties(rglfw.c PROPERTIES COMPILE_FLAGS "-x objective-c") link_libraries("-framework CoreFoundation -framework Cocoa -framework IOKit -framework CoreVideo") + elseif(WIN32) + add_definitions(-D_CRT_SECURE_NO_WARNINGS) endif() elseif(${PLATFORM} MATCHES "Web") set(PLATFORM "PLATFORM_WEB")