OSDN Git Service

mesa: don't define c99 math functions for MSVC >= 1800
authorHans <hans@chromium.org>
Sat, 1 Mar 2014 18:28:18 +0000 (11:28 -0700)
committerBrian Paul <brianp@vmware.com>
Mon, 3 Mar 2014 18:56:33 +0000 (11:56 -0700)
Signed-off-by: Brian Paul <brianp@vmware.com>
Cc: "10.0" "10.1" <mesa-stable@lists.freedesktop.org>
src/mesa/main/imports.h

index d79e2a3..9e221cc 100644 (file)
@@ -132,7 +132,7 @@ typedef union { GLfloat f; GLint i; GLuint u; } fi_type;
 #define atanhf(f) ((float) atanh(f))
 #endif
 
-#if defined(_MSC_VER)
+#if defined(_MSC_VER) && (_MSC_VER < 1800)  /* Not req'd on VS2013 and above */
 static inline float truncf(float x) { return x < 0.0f ? ceilf(x) : floorf(x); }
 static inline float exp2f(float x) { return powf(2.0f, x); }
 static inline float log2f(float x) { return logf(x) * 1.442695041f; }