OSDN Git Service

Build fix for Linux
authorAlexis Hetu <sugoi@google.com>
Fri, 28 Aug 2015 18:39:13 +0000 (14:39 -0400)
committerAlexis Hétu <sugoi@google.com>
Fri, 28 Aug 2015 18:43:07 +0000 (18:43 +0000)
Adding the proper #include <limits.h> for Linux when using
INT_MAX and/or UINT_MAX.

Fixed ShaderCore.cpp and preemptively fixed libGLESv3.cpp.

Change-Id: Iedd445157f3de8c08394e6d2c9f99539eb123845
Reviewed-on: https://swiftshader-review.googlesource.com/3933
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
src/OpenGL/libGLESv2/libGLESv3.cpp
src/Shader/ShaderCore.cpp

index 37e9c30..6faa76f 100644 (file)
@@ -23,6 +23,8 @@
 #include <GLES3/gl3.h>\r
 #include <GLES2/gl2ext.h>\r
 \r
+#include <limits.h>\r
+\r
 using namespace es2;\r
 \r
 typedef std::pair<GLenum, GLenum> InternalFormatTypePair;\r
index c7e86c1..17659cf 100644 (file)
@@ -14,6 +14,8 @@
 #include "Renderer/Renderer.hpp"
 #include "Common/Debug.hpp"
 
+#include <limits.h>
+
 namespace sw
 {
        extern TranscendentalPrecision logPrecision;