<div dir="ltr"> Hi Terry,<br><div class="gmail_extra"><br></div><div class="gmail_extra">Thanks for the testing and suggested fix. I've found a simpler solution - just change the GL.in to use #cmakedefine, so the GL.in now looks like:<br><br>
<div>
<span style="font-family:monospace"><span style="color:#000000;background-color:#ffffff">svn diff
</span><br>Index: src/osg/GL.in
<br>===================================================================
<br>--- src/osg/GL.in (revision 15005)
<br>+++ src/osg/GL.in (working copy)
<br>@@ -29,6 +29,8 @@
<br> #cmakedefine OSG_GL_VERTEX_FUNCS_AVAILABLE
<br> #cmakedefine OSG_GL_VERTEX_ARRAY_FUNCS_AVAILABLE
<br> #cmakedefine OSG_GL_FIXED_FUNCTION_AVAILABLE
<br>+#cmakedefine GL_HEADER_HAS_GLINT64
<br>+#cmakedefine GL_HEADER_HAS_GLUINT64
<br> <br> #define OSG_GL1_FEATURES @OSG_GL1_FEATURES@
<br> #define OSG_GL2_FEATURES @OSG_GL2_FEATURES@
<br>@@ -36,9 +38,8 @@
<br> #define OSG_GLES1_FEATURES @OSG_GLES1_FEATURES@
<br> #define OSG_GLES2_FEATURES @OSG_GLES2_FEATURES@
<br> #define OSG_GLES3_FEATURES @OSG_GLES3_FEATURES@
<br>-#define GL_HEADER_HAS_GLINT64 @GL_HEADER_HAS_GLINT64@
<br>-#define GL_HEADER_HAS_GLUINT64 @GL_HEADER_HAS_GLUINT64@
<br> <br>+
<br> #ifndef WIN32
<br> <br> // Required for compatibility with glext.h sytle function definitions of
<br>@@ -117,7 +118,7 @@
<br> #endif // GL_APIENTRY
<br> <br> <br>-#if !GL_HEADER_HAS_GLINT64
<br>+#ifndef GL_HEADER_HAS_GLINT64
<br> #ifdef _WIN32
<br> typedef __int64 GLint64;
<br> #else
<br>@@ -125,7 +126,7 @@
<br> #endif
<br> #endif
<br> <br>-#if !GL_HEADER_HAS_GLUINT64
<br>+#ifndef GL_HEADER_HAS_GLUINT64
<br> #ifdef _WIN32
<br> typedef unsigned __int64 GLuint64;
<br> #else<br>
<br></span></div>
I've tested this by toggling the test to an non existent typedef and it correctly picks out that it's not available and doesn't define the <span style="font-family:monospace">GL_HEADER_HAS_GLINT64 so I get a failure. This should mean that it should work for you system now.<br><br></span></div><div class="gmail_extra"><span style="font-family:monospace">BTW, what GL headers are you using that don't define GLuint64/GLint64?<br></span></div><div class="gmail_extra"><span style="font-family:monospace"><br></span></div><div class="gmail_extra"><span style="font-family:monospace">Robert,<br>
</span></div><div class="gmail_extra"><br></div><div class="gmail_extra"><br><div class="gmail_quote">On 23 July 2015 at 07:54, Terry Welsh <span dir="ltr"><<a href="mailto:mogumbo@gmail.com" target="_blank">mogumbo@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Robert,<br>
Thanks for tackling the GLint/GLuint problem. I looked into it a<br>
couple weeks ago but never discovered check_cxx_source_compiles or any<br>
other solution.<br>
<br>
One small issue: if your checks for GLint and GLuint fail, you get<br>
these lines in include/osg/GL<br>
<br>
#define GL_HEADER_HAS_GLINT64<br>
#define GL_HEADER_HAS_GLUINT64<br>
<br>
This causes errors because the code later in that file expects<br>
<br>
#define GL_HEADER_HAS_GLINT64 0<br>
#define GL_HEADER_HAS_GLUINT64 0<br>
<br>
I fixed it by adding the following to CMakeLists.txt<br>
<br>
@@ -593,6 +593,9 @@<br>
int main() { GLint64 test; return 0; }"<br>
GL_HEADER_HAS_GLINT64<br>
)<br>
+IF(GL_HEADER_HAS_GLINT64 STREQUAL "")<br>
+ SET(GL_HEADER_HAS_GLINT64 0)<br>
+ENDIF()<br>
<br>
check_cxx_source_compiles(<br>
"${OPENGL_HEADER1}<br>
@@ -600,6 +603,9 @@<br>
int main() { GLuint64 test; return 0; }"<br>
GL_HEADER_HAS_GLUINT64<br>
)<br>
+IF(GL_HEADER_HAS_GLUINT64 STREQUAL "")<br>
+ SET(GL_HEADER_HAS_GLUINT64 0)<br>
+ENDIF()<br>
<br>
<br>
--<br>
Terry Welsh<br>
<a href="http://www.reallyslick.com" rel="noreferrer" target="_blank">http://www.reallyslick.com</a><br>
<br>
<br>
><br>
> Message: 1<br>
> Date: Wed, 22 Jul 2015 16:09:09 +0100<br>
> From: Robert Osfield <<a href="mailto:robert.osfield@gmail.com">robert.osfield@gmail.com</a>><br>
> To: OpenSceneGraph Users <<a href="mailto:osg-users@lists.openscenegraph.org">osg-users@lists.openscenegraph.org</a>><br>
> Subject: [osg-users] OpenSceneGraph-3.4.0-rc6 tagged<br>
> Message-ID:<br>
> <<a href="mailto:CAFN7Y%2BW1z%2BWOLYdNGtxSQtTZen4cgEC3H77n9Yqy1BnDXvmKjg@mail.gmail.com">CAFN7Y+W1z+WOLYdNGtxSQtTZen4cgEC3H77n9Yqy1BnDXvmKjg@mail.gmail.com</a>><br>
> Content-Type: text/plain; charset="utf-8"<br>
<span class="">><br>
> Hi All,<br>
><br>
> I have done some CMake work on handling whether the GL header provides the<br>
> GLuint64 and GLint64 typedefs which will hopefully help with address some<br>
> of platform specfic build errors with certain GL/ES headers.<br>
><br>
</span>> - Zip file containing source code : OpenSceneGraph-3.4.0-rc6.zip<br>
> <<a href="http://www.openscenegraph.org/downloads/developer_releases/OpenSceneGraph-3.4.0-rc6.zip" rel="noreferrer" target="_blank">http://www.openscenegraph.org/downloads/developer_releases/OpenSceneGraph-3.4.0-rc6.zip</a>><br>
> - Subversion tag for 3.4.0-rc6 : svn co<br>
> <a href="http://svn.openscenegraph.org/osg/OpenSceneGraph/tags/OpenSceneGraph-3.4" rel="noreferrer" target="_blank">http://svn.openscenegraph.org/osg/OpenSceneGraph/tags/OpenSceneGraph-3.4</a>.<br>
> <<a href="http://svn.openscenegraph.org/osg/OpenSceneGraph/tags/OpenSceneGraph-3.4.0-rc6" rel="noreferrer" target="_blank">http://svn.openscenegraph.org/osg/OpenSceneGraph/tags/OpenSceneGraph-3.4.0-rc6</a>>0-rc6<br>
<span class="">> OpenSceneGraph<br>
><br>
> My plan is now to make 3.4.0 tomorrow.<br>
><br>
> Thanks in advance for any testing you can do.<br>
> Robert.<br>
</span>_______________________________________________<br>
osg-users mailing list<br>
<a href="mailto:osg-users@lists.openscenegraph.org">osg-users@lists.openscenegraph.org</a><br>
<a href="http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org" rel="noreferrer" target="_blank">http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org</a><br>
</blockquote></div><br></div></div>