Wednesday, September 14, 2011

Bad GL

Developing on linux is annoying sometimes.

All the OpenGL functionality tests failed!
You might need to modify the include and library search paths by editing
QMAKE_INCDIR_OPENGL, QMAKE_LIBDIR_OPENGL and QMAKE_LIBS_OPENGL in
/home/sarasmit/depot/qt5/qtbase/mkspecs/linux-g++.

If you get this error on Ubuntu, it may be due to bad OpenGL packages. To check if the bad GL packages issue is the cause, do:

cd /usr/lib && ls -la libGL*

If you have color turned on in your terminal you might see this:


If so you have bad GL packages, and a broken symlink. The build process cannot find the library because even though its there, the broken symlink is hiding it - hence why its colored red.

Just do (from the same directory /usr/lib) ensuring that the libGL.so.270.41.06 in the command below is the same as whatever your actual library installed:
sudo ln -s -f libGL.so.270.41.06 libGL.so

Then check (with the ls command again) to see if you now have a green link instead of a red one.

Now your builds should work again...