Mesa (master): Avoid fighting with Solaris headers over isnormal()
Alan Coopersmith
alanc at kemper.freedesktop.org
Wed Feb 18 02:30:00 UTC 2015
Module: Mesa
Branch: master
Commit: d602fbd861e2c3c5570b55f0839361a6f8bd32c7
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=d602fbd861e2c3c5570b55f0839361a6f8bd32c7
Author: Alan Coopersmith <alan.coopersmith at oracle.com>
Date: Sun Feb 15 16:16:15 2015 -0800
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 <alan.coopersmith at oracle.com>
Cc: "10.5" <mesa-stable at lists.freedesktop.org>
Reviewed-by: Emil Velikov <emil.l.velikov at gmail.com>
Reviewed-by: Brian Paul <brianp at vmware.com>
---
src/glsl/ir_constant_expression.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/glsl/ir_constant_expression.cpp b/src/glsl/ir_constant_expression.cpp
index 1e8b3a3..864cb80 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)
{
More information about the mesa-commit
mailing list