LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices



Reply
 
Search this Thread
Old 10-30-2005, 05:15 PM   #1
Dquest
LQ Newbie
 
Registered: Oct 2005
Location: Barcelona, Catalonia
Distribution: Kubuntu 5.10
Posts: 7

Rep: Reputation: 0
Error: Unable to resolve GL/GLX symbols - please check your GL library installation.


First of all, hello to this big community smile

Im a newbie trying to learn how to build openGL applications under QT (university course)

Im using QT3.3.x (don't know how to search the exact version, sorry) under ubuntu distro and programming a QGLWidget class. All was ok (application running) until i choosed to install the fglrx ATI driver (for my ati mobility radeon 9700) to use 3Dacceleration and i managed to do it.

The problem now is that whenever i try to run any qt application that use QGLWidget i have this error:

Code:
Unable to resolve GL/GLX symbols - please check your GL library installation.
and im stuck here

I can use glxgears with no problem (and with good fps average) and glxinfo tells me that im really using ati radeon driver instead of mesa3d. Also i tried to change xorg.conf to use the mesa3d driver again but the problem continue.

Any suggestion with this?
Thank you
 
Old 10-30-2005, 10:49 PM   #2
foo_bar_foo
Senior Member
 
Registered: Jun 2004
Posts: 2,553

Rep: Reputation: 51
i can't say for sure but mesa can conflict with glx from driver so some of those proprietary install scripts look and wipe stuff
there are a couple of different ways to compile Qt to use GL also

lets see to diagnose
lets start out looking at the output from this
go to where the Qt libs are and run
ldd libqt-mt.so
 
Old 10-31-2005, 03:56 PM   #3
Dquest
LQ Newbie
 
Registered: Oct 2005
Location: Barcelona, Catalonia
Distribution: Kubuntu 5.10
Posts: 7

Original Poster
Rep: Reputation: 0
Thanks for helping me!

I'm not at home at this moment so i can't try it now but as soon as i return home i will do what u suggested me and i will post the results!

btw, how can re-compile qt? (maybe the key is to compile with the right opengl option...) At trolltech home i only see qt4 to download (and i think it will be not compatible with qt3 installed at university computers)

Thanks
 
Old 10-31-2005, 05:13 PM   #4
foo_bar_foo
Senior Member
 
Registered: Jun 2004
Posts: 2,553

Rep: Reputation: 51
yea lets see first if we can't fix it.
we will have to figure out exactly which qt so look at the libs and post exactly which version
they are all here
ftp://ftp.silug.org/mirrors/ftp.trolltech.com/qt/source

the option to use is
-dlopen-opengl

but like i said wait a second because compiling Qt can be kind of tricky
 
Old 10-31-2005, 07:43 PM   #5
Dquest
LQ Newbie
 
Registered: Oct 2005
Location: Barcelona, Catalonia
Distribution: Kubuntu 5.10
Posts: 7

Original Poster
Rep: Reputation: 0
okey, i searched for libqt-mt.so and found some soft links (soft=symbolic?) to /usr/lib/libqt-mt.so.3.3.3 (i think this the file we are looking for because is the unique with a 7MB size aprox.).

After ldd libqt-mt.so.3.3.3 i get this:

Code:
                libfontconfig.so.1 => /usr/lib/libfontconfig.so.1 (0xb790d000)
        libaudio.so.2 => /usr/lib/libaudio.so.2 (0xb78f8000)
        libXt.so.6 => /usr/X11R6/lib/libXt.so.6 (0xb78a8000)
        libpng12.so.0 => /usr/lib/libpng12.so.0 (0xb7884000)
        libz.so.1 => /usr/lib/libz.so.1 (0xb7873000)
        libXrender.so.1 => /usr/lib/libXrender.so.1 (0xb786b000)
        libXrandr.so.2 => /usr/X11R6/lib/libXrandr.so.2 (0xb7867000)
        libXcursor.so.1 => /usr/lib/libXcursor.so.1 (0xb785e000)
        libXinerama.so.1 => /usr/X11R6/lib/libXinerama.so.1 (0xb785a000)
        libXft.so.2 => /usr/lib/libXft.so.2 (0xb7848000)
        libfreetype.so.6 => /usr/lib/libfreetype.so.6 (0xb77db000)
        libXext.so.6 => /usr/X11R6/lib/libXext.so.6 (0xb77ce000)
        libX11.so.6 => /usr/X11R6/lib/libX11.so.6 (0xb7709000)
        libSM.so.6 => /usr/X11R6/lib/libSM.so.6 (0xb7700000)
        libICE.so.6 => /usr/X11R6/lib/libICE.so.6 (0xb76e7000)
        libdl.so.2 => /lib/tls/i686/cmov/libdl.so.2 (0xb76e4000)
        libpthread.so.0 => /lib/tls/i686/cmov/libpthread.so.0 (0xb76d4000)
        libstdc++.so.5 => /usr/lib/libstdc++.so.5 (0xb761a000)
        libm.so.6 => /lib/tls/i686/cmov/libm.so.6 (0xb75f9000)
        libgcc_s.so.1 => /lib/libgcc_s.so.1 (0xb75ee000)
        libc.so.6 => /lib/tls/i686/cmov/libc.so.6 (0xb74c0000)
        libexpat.so.1 => /usr/lib/libexpat.so.1 (0xb74a0000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)
I assume that i have the qt version 3.3.3...

PD: Thanks again helping and posting ftp site for all qt versions
PD2: Good night (2am here)
 
Old 10-31-2005, 11:55 PM   #6
foo_bar_foo
Senior Member
 
Registered: Jun 2004
Posts: 2,553

Rep: Reputation: 51
Spain -- i didn't even notice

it looks like the Qt is compiled well with no direct linkage to any GL libs
that means that GL is loaded using dlopen as in the config option i sugested
unless it's not compiled to use gl at all which seems unlikely because that would mean use of -disable flag in 3.3.3 i think
so no need to recompile (i don't think)
if you need to recompile 3.3.3 there are good instructions in beyond LFS
my copy from 12/22/2004 uses 3.3.3 anyway
if you can't find the book and need to do it i can post the page somewhere.

Qt is designed to use any MESA GLU or GLX lib i think when you use dlopen option but you still have to link you apps to it

the Qt example makefiles use -lGLU then -lGL in that order and will use the first or move on to the second


question:
Do you still have your libGLU.so and libGLU.so.1 in /usr/X11R6/lib
i think this came with X
(Mesa versions earlier than 3.1 would use the name "MesaGL" and "MesaGLU" for the libraries, instead of "GL" and "GLU")
those required Makefile hacking or just make some new sym links called libGLU.so and libGLU.so.1
if i mess up libGLU.so and libGLU.so.1 links in /usr/X11R6/lib
My Qt apps already compiled stop working but new compiles work using /usr/lib/libGL.so.1
appearently it likes the link names .so.1 so make sure they are there not just .so
this one for me is a link to libGL.so.1.0.7676 which is the lib installed by nvidia
(no experience with ati - sorry)
Do you know where and what the libs installed by ATI driver are ?
can you make a link called /usr/lib/libGL.so.1 to it if there is not one ?

Code:
Unable to resolve GL/GLX symbols - please check your GL library installation.
is that a runtime error (running an already compiled program) or a compiler linker error ?

can you compile the opengl examples that come with qt-3.3.3 like box ? and will they run after you compile them?
 
Old 11-01-2005, 07:32 AM   #7
Dquest
LQ Newbie
 
Registered: Oct 2005
Location: Barcelona, Catalonia
Distribution: Kubuntu 5.10
Posts: 7

Original Poster
Rep: Reputation: 0
YEAH, YEAH and much more... 2xYEAH! Finally it works!

Quote:
My Qt apps already compiled stop working but new compiles work using /usr/lib/libGL.so.1
appearently it likes the link names .so.1 so make sure they are there not just .so
Exactly as u said, Qt likes .so.1 and i didn't have one on /usr/lib. I added it linking to /usr/X11R6/lib/libGL.so.1.2 (i assumed this was the new openGL library by ATI driver) and all applications run again without errors (and without mesa driver as far as i know because now my 3d application is showing smother and redrawing faster whenever i resize its window)

Code:
dquest@ShimlyBB:/usr/lib$ ls -l libGL*
lrwxrwxrwx  1 root root 20 2005-05-29 20:34 libGL.a -> ../X11R6/lib/libGL.a
lrwxrwxrwx  1 root root 25 2005-10-28 19:09 libGL.so -> /usr/X11R6/lib/libGL.so.1
lrwxrwxrwx  1 root root 25 2005-11-01 12:53 libGL.so.1 -> ../X11R6/lib/libGL.so.1.2 (this is what i added)
lrwxrwxrwx  1 root root 21 2005-05-29 20:35 libGLU.a -> ../X11R6/lib/libGLU.a
lrwxrwxrwx  1 root root 13 2005-05-29 20:35 libGLU.so -> libGLU.so.1.3
lrwxrwxrwx  1 root root 13 2005-05-26 18:14 libGLU.so.1 -> libGLU.so.1.3
lrwxrwxrwx  1 root root 26 2005-05-26 18:14 libGLU.so.1.3 -> ../X11R6/lib/libGLU.so.1.3
dquest@ShimlyBB:/usr/lib$ ls -l ../X11R6/lib/libGL*
-rw-r--r--  1 root root 675582 2005-04-05 18:06 ../X11R6/lib/libGL.a
lrwxrwxrwx  1 root root     12 2005-05-29 20:34 ../X11R6/lib/libGL.so -> libGL.so.1.2
lrwxrwxrwx  1 root root     12 2005-10-28 17:50 ../X11R6/lib/libGL.so.1 -> libGL.so.1.2
-rwxr-xr-x  1 root root 773466 2005-10-26 16:37 ../X11R6/lib/libGL.so.1.2
-rw-r--r--  1 root root 643488 2005-04-05 18:06 ../X11R6/lib/libGLU.a
lrwxrwxrwx  1 root root     13 2005-05-29 20:35 ../X11R6/lib/libGLU.so -> libGLU.so.1.3
lrwxrwxrwx  1 root root     13 2005-05-26 18:14 ../X11R6/lib/libGLU.so.1 -> libGLU.so.1.3
-rw-r--r--  1 root root 479036 2005-04-05 18:06 ../X11R6/lib/libGLU.so.1.3
-rw-r--r--  1 root root  30850 2005-04-05 18:06 ../X11R6/lib/libGLw.a
I tried to change -lGL and -lGLU order on Makefile (in the .pro file exactly) but there was no difference for me.
What is LFS?
About the error i had... it was a runtime error (no error compiling and linking)

Quote:
can you compile the opengl examples that come with qt-3.3.3 like box ? and will they run after you compile them?
Where are those exemples? i can't find them.....

Well, u saved me! U are the man hehe

btw,
Quote:
Spain -- i didn't even notice
Thank you
 
Old 11-01-2005, 12:59 PM   #8
foo_bar_foo
Senior Member
 
Registered: Jun 2004
Posts: 2,553

Rep: Reputation: 51
WooHoo something actually got resolved.
LFS = Linux from scratch
if the examples didn't come with the distribution package download the 3.3.3 source code and they are in
qt-x11-free-3.3.3/examples/
lots and lots of examples with 7 in
qt-x11-free-3.3.3/examples/opengl
you gotta love those trolls
 
Old 11-02-2005, 06:31 AM   #9
Dquest
LQ Newbie
 
Registered: Oct 2005
Location: Barcelona, Catalonia
Distribution: Kubuntu 5.10
Posts: 7

Original Poster
Rep: Reputation: 0
sure i will love them.

thanks again for your help
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
KDE error -- Could not start kdeinit. Check your installation. Dade Slackware 18 11-27-2004 08:07 PM
mixxx under suse 9.1 fatal error Unable to resolve GL/GLX symbols ranjo Linux - Software 3 06-20-2004 04:27 PM
How to resolve unresolved symbols? rignes Linux - Software 5 05-16-2004 10:30 PM
SOLVED: nVidia fails to load GLX library Ed-MtnBiker Fedora 0 03-26-2004 05:57 PM
grip library dependency - can't resolve synaptical Linux - Software 1 02-09-2004 02:25 PM


All times are GMT -5. The time now is 05:52 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration