Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

doodah2001

Link Errors

This topic is 6483 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

Lately I've been getting some errors with linking. I can't for the life of me figure out why. It always involves whenever I use #include windows.h #include gl\gl.h #include conio.h #include gl\glaux.h void main(void) { //my code here } I get a linking error LNK2001:unresolved external symbol _WinMain@16 then a fatal error LNK1120: unresolved external symbols. whenever I've programmed using OpenGL before I haven't had this problem. Any ideas. Mat Edited by - doodah2001 on January 14, 2001 7:45:56 PM

Share this post


Link to post
Share on other sites
Advertisement
Guest Anonymous Poster
Have you declared the WinMain function correctly?
It should look something like this:

  
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, char * szCmdLine, int iShowCmd)
{
// you code here...

}


Look at the examples at MSDN

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!