Khronos Public Bugzilla

Bug 762

Summary: .spec file MacOSX issue with GLhandleARB.
Product: OpenGL Reporter: Alfonse <alfonse215>
Component: RegistryAssignee: Jon Leech <devrel>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 4.3   
Target Milestone: ---   
Hardware: PC   
OS: Windows   

Description Alfonse 2013-01-05 11:32:57 PST
In the .spec file, it defines GLhandleARB as `unsigned int` for all platforms. However, the MacOSX Cocoa header `gltypes.h` defines it as `void*`. This causes a conflict.

Both GLEW (https://sourceforge.net/p/glew/bugs/206/) and glLoadGen (https://bitbucket.org/alfonse/glloadgen/issue/33/mac-compilation-error) have encountered this issue, and simply ifdef-ing around `gltypes.h` is probably not a reliable solution.

You should get with Apple and figure out what they want their GLhandleARB to be defined as, and provide an appropriate #ifdef around it for other platforms.
Comment 1 Jon Leech 2013-06-07 17:18:27 PDT
Benj, could you verify this? I can work around it although I'd also
need to know a reliable preprocessor-level way of distingushing that the
header is being processed in a MacOS X environment where GLhandleARB
is defined differently than the GL spec says it is. Thanks.
Comment 2 Benj Lipchak 2013-06-08 16:20:46 PDT
Jon, #ifdef __APPLE__ should work fine for this.
Comment 3 Jon Leech 2013-06-15 13:29:29 PDT
Fixed in gl.xml & glext.h in Subversion.