SOLVED - Error when compile : 1: error: cannot find -lGL 2: ld returned 1 exit status
-
I have a simple program for testing the istallation of Creator, but when i compile the program,
lauch this message and can't run. i work on xubuntu1: error: cannot find -lGL
2: ld returned 1 exit statuson screen compile output:
15:10:14: Running steps for project test3...
15:10:14: Configuration unchanged, skipping qmake step.
15:10:14: Starting: "/usr/bin/make"
g++ -Wl,-rpath,/home/lucho/Qt5.1.0/5.1.0/gcc_64 -Wl,-rpath,/home/lucho/Qt5.1.0/5.1.0/gcc_64/lib -o test3 main.o widget.o moc_widget.o -L/home/lucho/Qt5.1.0//5.1.0/gcc_64/lib -lQt5Widgets -lQt5Gui -lQt5Core -lGL -lpthread
/usr/bin/ld: cannot find -lGL
collect2: ld returned 1 exit status
make: *** [test3] Error 1
15:10:15: The process "/usr/bin/make" exited with code 2.
Error while building/deploying project test3 (kit: Kit_lucho)
When executing step 'Make'
15:10:15: Elapsed time: 00:00.And this message is the first intent to compile, whit another kit (default) (the same simple program):
15:45:03: Running steps for project test2...
15:45:03: Configuration unchanged, skipping qmake step.
15:45:03: Starting: "/usr/bin/make"
g++ -Wl,-O1 -Wl,-rpath,/home/lucho/Qt5.1.0/5.1.0/gcc_64 -Wl,-rpath,/home/lucho/Qt5.1.0/5.1.0/gcc_64/lib -o test2 main.o widget.o moc_widget.o -L/home/lucho/Qt5.1.0//5.1.0/gcc_64/lib -lQt5Widgets -lQt5Gui -lQt5Core -lGL -lpthread
/usr/bin/ld: cannot find -lGL
collect2: ld returned 1 exit status
make: *** [test2] Error 1
15:45:03: The process "/usr/bin/make" exited with code 2.
Error while building/deploying project test2 (kit: Desktop Qt 5.1.0 GCC 64bit)
When executing step 'Make'
15:45:03: Elapsed time: 00:00.Thanks in advance for help me
Luis
-
Hi,
You are missing the opengl dev files
-
Hello SGaist:
Can you tell me how to install thats files and first where find it.
I work on Xubuntu -
Did you try to search this forum a bit ?
This question as already come up several times on the forum (xubuntu is just a derivative of ubuntu)Anyway have a look "here":http://qt-project.org/wiki/Building_Qt_5_from_Git even if you don't build Qt yourself the information is valid
-
Thanks a lot SGaist; I couid solve the problem.
Only, I have installed the opengl dev files on my computer, and now all is ok.
I can do my firsts qt programs. -
You're welcome !
Please update the thread's title prepending solved so other forum users may know a solution has been found :)