From 7fa27f1e98b07bd5b837478f3c8333bfc98a1ecf Mon Sep 17 00:00:00 2001 From: Camilla Berglund Date: Thu, 27 Sep 2012 02:49:20 +0200 Subject: [PATCH] Fixed warnings on VC++. --- src/CMakeLists.txt | 4 ++++ tests/threads.c | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 8a7bdec3..5d066b70 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -2,6 +2,10 @@ include_directories(${GLFW_SOURCE_DIR}/src ${GLFW_BINARY_DIR}/src ${glfw_INCLUDE_DIRS}) +if (MSVC) + add_definitions(-D_CRT_SECURE_NO_WARNINGS) +endif() + set(common_HEADERS ${GLFW_SOURCE_DIR}/include/GL/glfw3.h internal.h) set(common_SOURCES clipboard.c fullscreen.c gamma.c init.c input.c joystick.c opengl.c time.c window.c) diff --git a/tests/threads.c b/tests/threads.c index 35c83716..49e3739a 100644 --- a/tests/threads.c +++ b/tests/threads.c @@ -28,6 +28,8 @@ // //======================================================================== +#include "tinycthread.h" + #include #include @@ -35,8 +37,6 @@ #include #include -#include "tinycthread.h" - typedef struct { GLFWwindow window;