[Mesa-dev] [Bug 105328] Can't include gl and gles headers simultaneously on non-64 bit architectures
bugzilla-daemon at freedesktop.org
bugzilla-daemon at freedesktop.org
Fri Mar 2 17:22:40 UTC 2018
https://bugs.freedesktop.org/show_bug.cgi?id=105328
--- Comment #4 from Brian Paul <brianp at vmware.com> ---
(In reply to Brian Paul from comment #2)
> Evidently, the problem with the 32-bit build is that ptrdiff_t is not
> equivalent to signed long int.
>
> This hack works for me:
>
> #include <stddef.h>
> #include <GLES2/gl2.h>
> #define GL_VERSION_1_5
> #include <GL/gl.h>
> int main (int argc, char **argv) { return 0; }
>
> This basically causes the GL_VERSION_1_5 section in glext.h to be skipped.
> If you need definitions from that section, you'd probably have to copy&paste
> them.
>
> I proper fix would probably involve adding #ifndef GLSIZEIPTR / #endif
> guards around the typedefs. That would have to be done upstream in the
> Khronos headers.
On second thought, including khrplatform.h in glext.h and changing the typedefs
to read
typedef khronos_ssize_t GLsizeiptr;
typedef khronos_intptr_t GLintptr;
would be pretty simple. I added this to Eric's Khronos bug report.
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20180302/dcaedd6c/attachment.html>
More information about the mesa-dev
mailing list