Horde3D http://www.horde3d.org/forums/ |
|
[solved] Problem with static linking (lGL) http://www.horde3d.org/forums/viewtopic.php?f=2&t=1733 |
Page 1 of 1 |
Author: | MaybeitSimple [ 18.10.2012, 18:16 ] |
Post subject: | [solved] Problem with static linking (lGL) |
Please HELP! : (I recently switched to Linux from the Windows) And trying to compile at least sample (using static linking), but linker always complains about damn -lGL ![]() (I google it, but nothing helps!), I have already installed all that was needed...and nothin ![]() Now I hope that there is something wrong: $ar rc ../../libHorde3D.a ./egAnimatables.o ./egAnimation.o ./egCamera.o ./egCom.o ./egExtensions.o ./egGeometry.o ./egLight.o ./egMain.o ./egMaterial.o ./egModel.o ./egModules.o ./egParticle.o ./egPipeline.o ./egPrimitives.o ./egRendererBase.o ./egRenderer.o ./egResource.o ./egScene.o ./egSceneGraphRes.o ./egShader.o ./egTexture.o ./utImage.o ./utOpenGL.o ./__/__/__/Extensions/Terrain/Source/terrain.o ./__/__/__/Extensions/Terrain/Source/extension.o && ar rc ../../libHorde3DUtils.a ./main.o $ranlib libHorde3D.a && ranlib libHorde3DUtils.a $g++ -c -o app.o app.cpp -I'../glfw/' -I'../../Bindings/C++/' -I. $g++ -c -o main.o main.cpp -I'../glfw/' -I'../../Bindings/C++/' -I. $g++ -static -o Knight main.o app.o -L'../../Source/' -L'../glfw/' -L'/usr/lib/' -lGL -lX11 -lglfw -lHorde3D -lHorde3DUtils $ls /home/imuser/Horde3D_SDK/Horde3D/Source/ libHorde3DUtils.a libHorde3D.a $locate libGL /usr/lib/fglrx/libGL.so /usr/lib/fglrx/libGL.so.1 /usr/lib/fglrx/libGL.so.1.2 /usr/lib/fglrx/switchlibGL /usr/lib/x86_64-linux-gnu/libGL.so /usr/lib/x86_64-linux-gnu/libGLEW.a /usr/lib/x86_64-linux-gnu/libGLEW.so /usr/lib/x86_64-linux-gnu/libGLEW.so.1.6 /usr/lib/x86_64-linux-gnu/libGLEW.so.1.6.0 /usr/lib/x86_64-linux-gnu/libGLEWmx.so.1.6 /usr/lib/x86_64-linux-gnu/libGLEWmx.so.1.6.0 /usr/lib/x86_64-linux-gnu/libGLU.a /usr/lib/x86_64-linux-gnu/libGLU.so /usr/lib/x86_64-linux-gnu/libGLU.so.1 /usr/lib/x86_64-linux-gnu/libGLU.so.1.3.08000 /usr/lib/x86_64-linux-gnu/mesa/libGL.so /usr/lib/x86_64-linux-gnu/mesa/libGL.so.1 /usr/lib/x86_64-linux-gnu/mesa/libGL.so.1.2 Otherwise, I just don `t know what to do, in Windows I had no such problems ![]() ![]() (When I try to compile and link with dynamic libraries everything goes just fine!!! ![]() Sorry for my bad English, it is not my native language. |
Author: | MaybeitSimple [ 18.10.2012, 22:37 ] |
Post subject: | Re: Problem with static linking (lGL) |
I'm sorry I'm a little messed up ![]() ![]() Linkage order for your application You must link Horde3D library to your final executable before GL one. WRONG: gcc -o app main.cpp -lGL -lHorde3D RIGHT: gcc -o app main.cpp -lHorde3D -lGL ![]() ![]() |
Author: | Volker [ 19.10.2012, 20:02 ] |
Post subject: | Re: Problem with static linking (lGL) |
I won't delete it, maybe other people have similar problems ![]() |
Page 1 of 1 | All times are UTC + 1 hour |
Powered by phpBB® Forum Software © phpBB Group https://www.phpbb.com/ |