• Advertisement
Sign in to follow this  

freeglut linker errors

This topic is 2024 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi,

I'm trying to install freeglut on my pc and my testApp gets linkers errors which even after severel tries to fix i have not been able to fix.
.lib and header are inside my VS directory/VC/lib and /VC/include, the dll is inside the windows directory and still i get


1>App.obj : error LNK2019: unresolved external symbol __imp__glutLeaveMainLoop@0 referenced in function "public: void __thiscall App::Keyboard(unsigned int,int,int)" (?Keyboard@App@@QAEXIHH@Z)
1>Main.obj : error LNK2019: unresolved external symbol __imp__glutSetOption@8 referenced in function _main
1>Main.obj : error LNK2019: unresolved external symbol __imp__glutInitContextProfile@4 referenced in function _main
1>Main.obj : error LNK2019: unresolved external symbol __imp__glutInitContextVersion@8 referenced in function _main

the other glut fucntions used in normal glut (without the free) do NOT throw any errors

does anyone have any suggestions
Thanks

me :)

Share this post


Link to post
Share on other sites
Advertisement
You have to tell the program where the .lib is to link it. It's not going to scan every .lib in that folder to find those 4 functions. If using visual studio, properties->c++->linker->input. Something like that, you will have to add the name/path of the .lib there.

Share this post


Link to post
Share on other sites
thanks for the reply but this was my input field allready :s

glloadD.lib;glimgD.lib;glutilD.lib;glmeshD.lib;glut32.lib;freeglutD.lib;glu32.lib;opengl32.lib;gdi32.lib;winmm.lib;user32.lib;%(AdditionalDependencies)

all the D,s arefor the debug libraries, i got them from compiling the open gl SDK

Share this post


Link to post
Share on other sites
deleted the additional library link to the open gl SDK, kept the intput field the same now no more errors,...
an explanation would still be nice :)

Share this post


Link to post
Share on other sites
Put in "xxxxx.lib" and see if it complains about not finding it. This will let you know that it isn't complaining about those because it did find them.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement