Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. GLvoid does not name a type
Qt 6.11 is out! See what's new in the release blog

GLvoid does not name a type

Scheduled Pinned Locked Moved General and Desktop
26 Posts 3 Posters 13.3k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    The most recent future
    wrote on last edited by
    #1

    error: ‘GLvoid’ does not name a type ???

    1 Reply Last reply
    0
    • T Offline
      T Offline
      The most recent future
      wrote on last edited by
      #2

      /root/downSource/qt-everywhere-opensource-src-5.2.0/qtbase/include/QtGui/5.2.0/QtGui/private/../../../../../src/gui/opengl/qopenglextensions_p.h:131:1: error: expected class-name before ‘{’ token
      {
      ^
      /root/downSource/qt-everywhere-opensource-src-5.2.0/qtbase/include/QtGui/5.2.0/QtGui/private/../../../../../src/gui/opengl/qopenglextensions_p.h:135:5: error: ‘GLvoid’ does not name a type
      GLvoid* (QOPENGLF_APIENTRYP MapBuffer)(GLenum target, GLenum access);
      ^
      /root/downSource/qt-everywhere-opensource-src-5.2.0/qtbase/include/QtGui/5.2.0/QtGui/private/../../../../../src/gui/opengl/qopenglextensions_p.h:136:16: error: ‘QOPENGLF_APIENTRYP’ has not been declared
      GLboolean (QOPENGLF_APIENTRYP UnmapBuffer)(GLenum target);
      ^
      /root/downSource/qt-everywhere-opensource-src-5.2.0/qtbase/include/QtGui/5.2.0/QtGui/private/../../../../../src/gui/opengl/qopenglextensions_p.h:136:48: error: ‘GLenum’ has not been declared
      GLboolean (QOPENGLF_APIENTRYP UnmapBuffer)(GLenum target);
      ^
      /root/downSource/qt-everywhere-opensource-src-5.2.0/qtbase/include/QtGui/5.2.0/QtGui/private/../../../../../src/gui/opengl/qopenglextensions_p.h:136:61: error: ISO C++ forbids declaration of ‘GLboolean’ with no type [-fpermissive]
      GLboolean (QOPENGLF_APIENTRYP UnmapBuffer)(GLenum target);

      1 Reply Last reply
      0
      • SGaistS Offline
        SGaistS Offline
        SGaist
        Lifetime Qt Champion
        wrote on last edited by
        #3

        Hi and welcome to devnet,

        Please don't highjack other people thread with completely unrelated questions. I've created one for your question.

        From your error it looks like you don't have the OpenGL development package for your distribution installed.

        Also note that Qt 5.2.0 is pretty outdated, the current version is 5.8.0.

        One last thing, developing as root is really a bad idea, if you do anything wrong, there won't be any warning or stopping measure so you can brick your system pretty easily.

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        T 2 Replies Last reply
        3
        • T Offline
          T Offline
          The most recent future
          wrote on last edited by
          #4

          thanks i come from china ,build qt just 2 days

          1 Reply Last reply
          0
          • SGaistS SGaist

            Hi and welcome to devnet,

            Please don't highjack other people thread with completely unrelated questions. I've created one for your question.

            From your error it looks like you don't have the OpenGL development package for your distribution installed.

            Also note that Qt 5.2.0 is pretty outdated, the current version is 5.8.0.

            One last thing, developing as root is really a bad idea, if you do anything wrong, there won't be any warning or stopping measure so you can brick your system pretty easily.

            T Offline
            T Offline
            The most recent future
            wrote on last edited by
            #5

            @SGaist :184:116: error: ‘GLvoid’ was not declared in this scope
            /root/downSource/qt-everywhere-opensource-src-5.2.0/qtbase/include/QtGui/5.2.0/QtGui/private/../../../../../src/gui/opengl/qopenglextensions_p.h:184:124: error: ‘data’ was not declared in this scope
            In file included from ../../../../include/QtQuick/5.2.0/QtQuick/private/qsgdepthstencilbuffer_p.h:1:0,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/qsgcontext_p.h:55,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/qsgcontext_p.h:1,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickwindow_p.h:59,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickitem_p.h:62,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/qquickitem_p.h:1,
            from qquickviewinspector.cpp:49:
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/util/qsgdepthstencilbuffer_p.h:92:5: error: ‘GLuint’ does not name a type
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/util/qsgdepthstencilbuffer_p.h:93:5: error: ‘GLuint’ does not name a type
            In file included from ../../../../include/QtQuick/5.2.0/QtQuick/private/qsgcontext_p.h:1:0,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickwindow_p.h:59,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickitem_p.h:62,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/qquickitem_p.h:1,
            from qquickviewinspector.cpp:49:
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/qsgcontext_p.h:96:57: error: ‘GLuint’ has not been declared
            In file included from ../../../../include/QtQuick/5.2.0/QtQuick/private/qsgadaptationlayer_p.h:1:0,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickshadereffectsource_p.h:47,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/qquickshadereffectsource_p.h:1,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickitem_p.h:81,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/qquickitem_p.h:1,
            from qquickviewinspector.cpp:49:
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/qsgadaptationlayer_p.h:180:9: error: ‘GLuint’ does not name a type
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/qsgadaptationlayer_p.h:243:24: error: ‘GLuint’ has not been declared
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/qsgadaptationlayer_p.h:243:39: error: ‘GLuint’ has not been declared
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/qsgadaptationlayer_p.h:246:5: error: ‘GLuint’ does not name a type
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/qsgadaptationlayer_p.h: In constructor ‘QSGDistanceFieldGlyphCache::Texture::Texture()’:
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/qsgadaptationlayer_p.h:183:21: error: class ‘QSGDistanceFieldGlyphCache::Texture’ does not have any field named ‘textureId’
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/qsgadaptationlayer_p.h: In member function ‘bool QSGDistanceFieldGlyphCache::Texture::operator==(const QSGDistanceFieldGlyphCache::Texture&) const’:
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/qsgadaptationlayer_p.h:184:64: error: ‘textureId’ was not declared in this scope
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/qsgadaptationlayer_p.h:184:83: error: ‘const struct QSGDistanceFieldGlyphCache::Texture’ has no member named ‘textureId’
            In file included from ../../../../include/QtQuick/qsgmaterial.h:1:0,
            from ../../../../include/QtQuick/../../src/quick/scenegraph/util/qsgtexturematerial.h:45,
            from ../../../../include/QtQuick/qsgtexturematerial.h:1,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/scenegraph/qsgdefaultimagenode_p.h:47,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/qsgdefaultimagenode_p.h:1,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickshadereffectsource_p.h:49,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/qquickshadereffectsource_p.h:1,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickitem_p.h:81,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/qquickitem_p.h:1,
            from qquickviewinspector.cpp:49:
            ../../../../include/QtQuick/../../src/quick/scenegraph/coreapi/qsgmaterial.h: At global scope:
            ../../../../include/QtQuick/../../src/quick/scenegraph/coreapi/qsgmaterial.h:100:12: error: ‘QOpenGLShaderProgram’ does not name a type
            ../../../../include/QtQuick/../../src/quick/scenegraph/coreapi/qsgmaterial.h:109:30: error: ‘QOpenGLShader’ has not been declared
            ../../../../include/QtQuick/../../src/quick/scenegraph/coreapi/qsgmaterial.h:109:56: error: expected ‘,’ or ‘...’ before ‘type’
            ../../../../include/QtQuick/../../src/quick/scenegraph/coreapi/qsgmaterial.h:110:31: error: ‘QOpenGLShader’ has not been declared
            ../../../../include/QtQuick/../../src/quick/scenegraph/coreapi/qsgmaterial.h:110:57: error: expected ‘,’ or ‘...’ before ‘type’
            ../../../../include/QtQuick/../../src/quick/scenegraph/coreapi/qsgmaterial.h:119:5: error: ‘QOpenGLShaderProgram’ does not name a type
            In file included from ../../../../include/QtQuick/5.2.0/QtQuick/private/qquickshadereffectsource_p.h:1:0,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickitem_p.h:81,
            from ../../../../include/QtQuick/5.2.0/QtQuick/private/qquickitem_p.h:1,
            from qquickviewinspector.cpp:49:
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickshadereffectsource_p.h:106:5: error: ‘GLenum’ does not name a type
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickshadereffectsource_p.h:107:20: error: ‘GLenum’ has not been declared
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickshadereffectsource_p.h:136:5: error: ‘GLenum’ does not name a type
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickshadereffectsource_p.h:143:5: error: ‘GLuint’ does not name a type
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickshadereffectsource_p.h:183:17: error: ‘GL_ALPHA’ was not declared in this scope
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickshadereffectsource_p.h:184:15: error: ‘GL_RGB’ was not declared in this scope
            ../../../../include/QtQuick/5.2.0/QtQuick/private/../../../../../src/quick/items/qquickshadereffectsource_p.h:185:16: error: ‘GL_RGBA’ was not declared in this scope
            compiling inspecttool.cpp
            make[5]: *** [.obj/qquickviewinspector.o] Error 1
            make[5]: *** Waiting for unfinished jobs....
            make[5]: Leaving directory /root/downSource/qt-everywhere-opensource-src-5.2.0/qtdeclarative/src/plugins/qmltooling/qmldbg_qtquick2' make[4]: *** [sub-qmldbg_qtquick2-make_first] Error 2 make[4]: Leaving directory /root/downSource/qt-everywhere-opensource-src-5.2.0/qtdeclarative/src/plugins/qmltooling'
            make[3]: *** [sub-qmltooling-make_first] Error 2
            make[3]: Leaving directory /root/downSource/qt-everywhere-opensource-src-5.2.0/qtdeclarative/src/plugins' make[2]: *** [sub-plugins-make_first-ordered] Error 2 make[2]: Leaving directory /root/downSource/qt-everywhere-opensource-src-5.2.0/qtdeclarative/src'
            make[1]: *** [sub-src-make_first] Error 2

            1 Reply Last reply
            0
            • SGaistS SGaist

              Hi and welcome to devnet,

              Please don't highjack other people thread with completely unrelated questions. I've created one for your question.

              From your error it looks like you don't have the OpenGL development package for your distribution installed.

              Also note that Qt 5.2.0 is pretty outdated, the current version is 5.8.0.

              One last thing, developing as root is really a bad idea, if you do anything wrong, there won't be any warning or stopping measure so you can brick your system pretty easily.

              T Offline
              T Offline
              The most recent future
              wrote on last edited by
              #6

              @SGaist
              sudo apt-get install build-essential

              sudo apt-get install libgl1-mesa-dev

              sudo apt-get install libglu1-mesa-dev

              sudo apt-get install freeglut3-dev

              jsulmJ 1 Reply Last reply
              0
              • T The most recent future

                @SGaist
                sudo apt-get install build-essential

                sudo apt-get install libgl1-mesa-dev

                sudo apt-get install libglu1-mesa-dev

                sudo apt-get install freeglut3-dev

                jsulmJ Offline
                jsulmJ Offline
                jsulm
                Lifetime Qt Champion
                wrote on last edited by
                #7

                @The-most-recent-future Do you have to use this old Qt version?
                Current version is 5.8

                https://forum.qt.io/topic/113070/qt-code-of-conduct

                T 1 Reply Last reply
                0
                • jsulmJ jsulm

                  @The-most-recent-future Do you have to use this old Qt version?
                  Current version is 5.8

                  T Offline
                  T Offline
                  The most recent future
                  wrote on last edited by
                  #8

                  @jsulm
                  yes. version 5.2.0
                  but , the error ................ can you help me??

                  jsulmJ 1 Reply Last reply
                  0
                  • T The most recent future

                    @jsulm
                    yes. version 5.2.0
                    but , the error ................ can you help me??

                    jsulmJ Offline
                    jsulmJ Offline
                    jsulm
                    Lifetime Qt Champion
                    wrote on last edited by
                    #9

                    @The-most-recent-future Do you build for desktop or for a device?
                    Also as @SGaist said you should really not develop as root - this is a very very bad idea.

                    https://forum.qt.io/topic/113070/qt-code-of-conduct

                    1 Reply Last reply
                    0
                    • SGaistS Offline
                      SGaistS Offline
                      SGaist
                      Lifetime Qt Champion
                      wrote on last edited by
                      #10

                      What exact options did you pass to configure before building Qt ?

                      Interested in AI ? www.idiap.ch
                      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                      T 2 Replies Last reply
                      0
                      • SGaistS SGaist

                        What exact options did you pass to configure before building Qt ?

                        T Offline
                        T Offline
                        The most recent future
                        wrote on last edited by
                        #11

                        @SGaist
                        ./configure
                        -release
                        -opensource
                        -qt-libpng
                        -qt-zlib
                        -qt-libjpeg
                        -glib
                        -plugin-sql-sqlite
                        -qt-sql-sqlite
                        -make libs
                        -no-cups
                        -no-nis
                        -no-iconv
                        -no-dbus
                        -no-opengl
                        -no-xcb
                        -no-accessibility
                        -no-javascript-jit
                        -silent
                        -arch arm
                        -xplatform linux-arm-gnueabi-g++
                        -linuxfb
                        -nomake tools
                        -nomake examples
                        -nomake tests
                        -qt-freetype
                        -no-glib
                        -strip
                        -plugindir /root/downSource/qt-everywhere-opensource-src-5.2.0/plugins
                        -confirm-license "$@" -verbose

                        1 Reply Last reply
                        0
                        • SGaistS Offline
                          SGaistS Offline
                          SGaist
                          Lifetime Qt Champion
                          wrote on last edited by
                          #12

                          There: -no-opengl. I remember there where some problem at some point building with -no-opengl, it should have been fixed in between but I don't remember if it was prior to or after Qt 5.2.0

                          Interested in AI ? www.idiap.ch
                          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                          T 1 Reply Last reply
                          0
                          • SGaistS SGaist

                            What exact options did you pass to configure before building Qt ?

                            T Offline
                            T Offline
                            The most recent future
                            wrote on last edited by
                            #13

                            @SGaist
                            Whether or not to add
                            -no-egl
                            -no-opengl

                            these error will be show !

                            @SGaist 大神,就我!!

                            1 Reply Last reply
                            0
                            • SGaistS SGaist

                              There: -no-opengl. I remember there where some problem at some point building with -no-opengl, it should have been fixed in between but I don't remember if it was prior to or after Qt 5.2.0

                              T Offline
                              T Offline
                              The most recent future
                              wrote on last edited by
                              #14

                              @SGaist
                              这个问题困扰了我好几天了,大神,你救救我吧!我都要哭了....

                              1 Reply Last reply
                              0
                              • SGaistS Offline
                                SGaistS Offline
                                SGaist
                                Lifetime Qt Champion
                                wrote on last edited by
                                #15

                                When changing the configure options, are you doing from a clean source ? That's the first thing to do before calling configure again.

                                Or better: do out of source builds, so if something goes wrong, you juste nuke the build folder and start new.

                                Interested in AI ? www.idiap.ch
                                Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                                T 1 Reply Last reply
                                0
                                • SGaistS SGaist

                                  When changing the configure options, are you doing from a clean source ? That's the first thing to do before calling configure again.

                                  Or better: do out of source builds, so if something goes wrong, you juste nuke the build folder and start new.

                                  T Offline
                                  T Offline
                                  The most recent future
                                  wrote on last edited by
                                  #16

                                  @SGaist
                                  yes , make clean && make distclean
                                  when i change the configure , i will be make clean and make distclean,
                                  but, the error will be show .

                                  1 Reply Last reply
                                  0
                                  • SGaistS Offline
                                    SGaistS Offline
                                    SGaist
                                    Lifetime Qt Champion
                                    wrote on last edited by
                                    #17

                                    What does the configuration summary show ?

                                    Interested in AI ? www.idiap.ch
                                    Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                                    T 6 Replies Last reply
                                    0
                                    • SGaistS SGaist

                                      What does the configuration summary show ?

                                      T Offline
                                      T Offline
                                      The most recent future
                                      wrote on last edited by
                                      #18

                                      @SGaist
                                      1 : make and make install

                                                     Looks like a success
                                                     data size : 108 M
                                                     but, why the example files  is not be generated ???
                                      
                                      1 Reply Last reply
                                      0
                                      • SGaistS SGaist

                                        What does the configuration summary show ?

                                        T Offline
                                        T Offline
                                        The most recent future
                                        wrote on last edited by
                                        #19

                                        @SGaist

                                        make -j3

                                        compiling .moc/moc_abstractliveedittool.cpp
                                        compiling .moc/moc_liveselectiontool.cpp
                                        compiling .moc/moc_boundingrecthighlighter.cpp
                                        compiling .moc/moc_zoomtool.cpp
                                        compiling .moc/moc_colorpickertool.cpp
                                        compiling .moc/moc_abstracttool.cpp
                                        rm -f libqmldbg_inspector.so
                                        linking ../../../../plugins/qml1tooling/libqmldbg_inspector.so
                                        mv -f libqmldbg_inspector.so ../../../../plugins/qml1tooling/
                                        make[5]: Leaving directory /home/cc/qt-everywhere-opensource-src-5.2.0/qtquick1/src/plugins/qmltooling/qmldbg_inspector' make[4]: Leaving directory /home/cc/qt-everywhere-opensource-src-5.2.0/qtquick1/src/plugins/qmltooling'
                                        make[3]: Leaving directory /home/cc/qt-everywhere-opensource-src-5.2.0/qtquick1/src/plugins' make[2]: Leaving directory /home/cc/qt-everywhere-opensource-src-5.2.0/qtquick1/src'
                                        cd tools/ && ( test -e Makefile || /home/cc/qt-everywhere-opensource-src-5.2.0/qtbase/bin/qmake /home/cc/qt-everywhere-opensource-src-5.2.0/qtquick1/tools/tools.pro -o Makefile ) && make -f Makefile
                                        make[2]: Entering directory /home/cc/qt-everywhere-opensource-src-5.2.0/qtquick1/tools' make[2]: Nothing to be done for first'.
                                        make[2]: Leaving directory /home/cc/qt-everywhere-opensource-src-5.2.0/qtquick1/tools' make[1]: Leaving directory /home/cc/qt-everywhere-opensource-src-5.2.0/qtquick1'
                                        cc@ubuntu:~/qt-everywhere-opensource-src-5.2.0$

                                        1 Reply Last reply
                                        0
                                        • SGaistS SGaist

                                          What does the configuration summary show ?

                                          T Offline
                                          T Offline
                                          The most recent future
                                          wrote on last edited by
                                          #20

                                          @SGaist

                                          No ”example“ folder

                                          [root@cv_soc /usr/local/Qt-5.2.0]# ls
                                          bin/ imports/ lib/ qml/
                                          doc/ include/ mkspecs/ translations/
                                          [root@cv_soc /usr/local/Qt-5.2.0]#

                                          1 Reply Last reply
                                          0

                                          • Login

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • Users
                                          • Groups
                                          • Search
                                          • Get Qt Extensions
                                          • Unsolved