Uploaded image for project: 'Qt for Python'
  1. Qt for Python
  2. PYSIDE-528

Compile error with GL.h on 5.9 branch on windows 32-bit

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P3: Somewhat important
    • Resolution: Done
    • Affects Version/s: 5.9
    • Fix Version/s: 5.9
    • Component/s: PySide
    • Labels:
    • Environment:
      Building on Windows 7 x64, Qt 5.9 and PySide2 5.9 (a3e4e367cf).
    • Commits:
      10453490629859a01048d0b21688d6617279eeaf (5.9, 1.9.2017)

      Description

      When I build from 5.9 as of this moment (a3e4e367cf) I get the following error:

      T:/Qt/5.9/msvc2015/include\QtGui/qopenglext.h:6491:25: error: typedef redefinition with different types ('void (GLenum, GLsizei, GLsizei, GLenum, GLenum, const void *) _attribute((stdcall))' (aka 'void (unsigned int, int, int, unsigned int, unsigned int, const void *) __attribute_((stdcall))') vs 'void (GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)' (aka 'void (unsigned int, int, int, unsigned int, unsigned int, const void *)'))
       C:\Program Files (x86)\Windows Kits\10\include\10.0.14393.0\um\GL/gl.h:1516:26: note: previous definition is here
      

      There seems to be some conflict between Qt's GL headers and the windows SDK gl.h. One is __stdcall, the other isn't. The typedef in question is:

      typedef void (APIENTRYP PFNGLCOLORSUBTABLEEXTPROC) (GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const void *data);
      

      So I guess it's something with APIENTRY being defined in different ways. It compiles fine for me if I comment out the GL.h include line in global.h.in, but that might well break the build somewhere else.

      FWIW, the GL.h include line was added way back in a3cf9b0a3c, so I'm not sure how or if that still applies.

        Attachments

        For Gerrit Dashboard: PYSIDE-528
        # Subject Branch Project Status CR V

          Activity

            People

            Assignee:
            kleint Friedemann Kleint
            Reporter:
            baldurk Baldur Karlsson
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes