Module: Mesa Branch: master Commit: 688d7656c58ea4775dbd55fe56193a27f4799c00 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=688d7656c58ea4775dbd55fe56193a27f4799c00
Author: Brian Paul <[email protected]> Date: Thu Feb 26 10:19:37 2015 -0700 c99: in c99_math.h check that _USE_MATH_DEFINES is defined with MSVC Reviewed-by: Jose Fonseca <[email protected]> --- include/c99_math.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/c99_math.h b/include/c99_math.h index 5d4f535..0a359eb 100644 --- a/include/c99_math.h +++ b/include/c99_math.h @@ -40,6 +40,11 @@ #if defined(_MSC_VER) +/* This is to ensure that we get M_PI, etc. definitions */ +#if !defined(_USE_MATH_DEFINES) +#error _USE_MATH_DEFINES define required when building with MSVC +#endif + #if _MSC_VER < 1800 #define isfinite(x) _finite((double)(x)) #define isnan(x) _isnan((double)(x)) _______________________________________________ mesa-commit mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/mesa-commit
