aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CMakeLists.txt3
-rw-r--r--tests/general/line-aa-width.c3
-rw-r--r--tests/texturing/rg-teximage-common.c3
3 files changed, 3 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index ae2ca08e..5a97486b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -64,6 +64,9 @@ if (WIN32)
# Don't define min/max macros
add_definitions (-DNOMINMAX)
+
+ # Define M_PI and others
+ add_definitions (-D_USE_MATH_DEFINES)
endif (WIN32)
if (APPLE)
diff --git a/tests/general/line-aa-width.c b/tests/general/line-aa-width.c
index 038f8865..4cd560cf 100644
--- a/tests/general/line-aa-width.c
+++ b/tests/general/line-aa-width.c
@@ -36,9 +36,6 @@
* ugly.
*/
-#ifdef _MSC_VER
-#define _USE_MATH_DEFINES
-#endif
#include "piglit-util.h"
int piglit_width = 300, piglit_height = 100;
diff --git a/tests/texturing/rg-teximage-common.c b/tests/texturing/rg-teximage-common.c
index 910ae943..1f1a7e07 100644
--- a/tests/texturing/rg-teximage-common.c
+++ b/tests/texturing/rg-teximage-common.c
@@ -32,9 +32,6 @@
* \author Ian Romanick <ian.d.romanick@intel.com>
*/
-#ifdef _MSC_VER
-#define _USE_MATH_DEFINES
-#endif
#include "piglit-framework.h"
#include "piglit-util.h"
#include "rg-teximage-common.h"