From 8eddeb77d02dfc378ce99c341129cc5b697386ab Mon Sep 17 00:00:00 2001 From: Recep Aslantas Date: Fri, 1 May 2020 01:03:20 +0300 Subject: [PATCH] win: fix print function for _DEBUG and supress warnings --- include/cglm/common.h | 3 ++- include/cglm/io.h | 3 ++- test/include/common.h | 3 +++ 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/include/cglm/common.h b/include/cglm/common.h index 83d54be..8596970 100644 --- a/include/cglm/common.h +++ b/include/cglm/common.h @@ -8,7 +8,8 @@ #ifndef cglm_common_h #define cglm_common_h -#define _USE_MATH_DEFINES /* for windows */ +#define _USE_MATH_DEFINES /* for windows */ +#define _CRT_SECURE_NO_WARNINGS /* for windows */ #include #include diff --git a/include/cglm/io.h b/include/cglm/io.h index bbaa9bf..18c21da 100644 --- a/include/cglm/io.h +++ b/include/cglm/io.h @@ -17,7 +17,8 @@ #ifndef cglm_io_h #define cglm_io_h -#if defined(DEBUG) || defined(CGLM_DEFINE_PRINTS) || defined(CGLM_LIB_SRC) +#if defined(DEBUG) || defined(_DEBUG) \ + || defined(CGLM_DEFINE_PRINTS) || defined(CGLM_LIB_SRC) #include "common.h" diff --git a/test/include/common.h b/test/include/common.h index 3c32b9f..c5529e4 100644 --- a/test/include/common.h +++ b/test/include/common.h @@ -8,6 +8,9 @@ #ifndef tests_common_h #define tests_common_h +#define _USE_MATH_DEFINES /* for windows */ +#define _CRT_SECURE_NO_WARNINGS /* for windows */ + #include #include #include