summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlan Coopersmith <[email protected]>2015-02-15 16:16:15 -0800
committerAlan Coopersmith <[email protected]>2015-02-17 18:16:33 -0800
commitd602fbd861e2c3c5570b55f0839361a6f8bd32c7 (patch)
tree00722dcbc5a792670e90183bb554b61d03514715
parent815b3bd096a3eab9f00f9270d45a6885d73180e9 (diff)
Avoid fighting with Solaris headers over isnormal()
When compiling in C99 or C++11 modes, Solaris defines isnormal() as a macro via <math.h>, which causes the function definition to become too mangled to compile. Signed-off-by: Alan Coopersmith <[email protected]> Cc: "10.5" <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Brian Paul <[email protected]>
-rw-r--r--src/glsl/ir_constant_expression.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/glsl/ir_constant_expression.cpp b/src/glsl/ir_constant_expression.cpp
index 1e8b3a3cced..864cb80de74 100644
--- a/src/glsl/ir_constant_expression.cpp
+++ b/src/glsl/ir_constant_expression.cpp
@@ -44,7 +44,7 @@ static int isnormal(double x)
{
return _fpclass(x) == _FPCLASS_NN || _fpclass(x) == _FPCLASS_PN;
}
-#elif defined(__SUNPRO_CC)
+#elif defined(__SUNPRO_CC) && !defined(isnormal)
#include <ieeefp.h>
static int isnormal(double x)
{