Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. #include <GL/glu.h> was removed from QtOpenGL/qgl.h while upgrading from Qt 4.7.3 to 4.8
Qt 6.11 is out! See what's new in the release blog

#include <GL/glu.h> was removed from QtOpenGL/qgl.h while upgrading from Qt 4.7.3 to 4.8

Scheduled Pinned Locked Moved Installation and Deployment
6 Posts 4 Posters 22.7k 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.
  • ? Offline
    ? Offline
    A Former User
    wrote on last edited by
    #1

    Hi,

    I found that there is a problematic change in the file 'QtOpenGL/qgl.h' when upgrading from 4.7.3 to 4.8.0.
    this line was removed:
    @

    include <GL/glu.h>

    @
    This change introduces lots of errors when I tried to compile any previous codes and libraries related with OpenGL.

    As a banding solution, I manually added it back to 4.8.0 (or return to 4.7.X) and the compilation succeeds and really don't want to modify any headers of GPL or LGPL libraries while I'm compiling them. Shall we return the include statement for the backward compatibility?

    Cheers,

    1 Reply Last reply
    0
    • S Offline
      S Offline
      stukdev
      wrote on last edited by
      #2

      I include
      @
      #include <QtOpenGL>
      @
      And all works well after install the correct package with aptitude (in on ubuntu)

      1 Reply Last reply
      0
      • ? Offline
        ? Offline
        A Former User
        wrote on last edited by
        #3

        Please consider to "file a bug report":http://bugreports.qt.nokia.com/ .

        Bug reports automatically end up at the desk of somebody who can actually fix something, forum posts do not.

        1 Reply Last reply
        0
        • ? Offline
          ? Offline
          A Former User
          wrote on last edited by
          #4

          OK, I think I solve the problem by adding the following lines under Line 90 (after the include statement for gl.h):

          @#if defined(Q_WS_MAC)

          include <OpenGL/glu.h>

          #else

          ifndef QT_LINUXBASE

          include <GL/glu.h>

          endif

          #endif@

          in thee files in the SDK 1.2

          /Developer/QtSDKs/QtSDK1.2/Desktop/Qt/4.8.0/gcc/lib/QtOpenGL.framework/Versions/4/Headers/qgl.h
          /Developer/QtSDKs/QtSDK1.2/Desktop/Qt/4.8.0/gcc/include/Qt/qgl.h
          /Developer/QtSDKs/QtSDK1.2/Desktop/Qt/4.8.0/gcc/include/QtOpenGL/qgl.h

          Now I can compile any previous libraries and codes smoothly without hacking any codes.

          Thanks!

          1 Reply Last reply
          0
          • ? Offline
            ? Offline
            A Former User
            wrote on last edited by
            #5

            Although I solved the compilation errors, I actually introduced a new problem now. When I launch the compiled application, it launches X-Windows, instead of using OS X OpenGL implementation. When I used Qt 4.7.X, I didn't have this problem. Could you explain why X-windows is launched? Didn't I mess up something?

            Cheers,

            1 Reply Last reply
            0
            • ? Offline
              ? Offline
              A Former User
              wrote on last edited by
              #6

              You are probably linking to the X11 version of the underlying GL library. Try running tool -L on the program binary. If X11 is installed on Mac Os X, you end up with GL implementations for X11 and native OSX.

              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