Advertisement

OpenGl (C++), Linking Error

Started by February 18, 2003 06:18 PM
6 comments, last by promethius 21 years, 9 months ago
I have started the tutorials on opengl programming from http://nehe.gamedev.net/. I have downloaded the first tutorial source code, but I can''t get it to compile... Here is my error: --------------------Configuration: Lesson1 - Win32 Debug-------------------- Linking... LIBCD.lib(crt0.obj) : error LNK2001: unresolved external symbol _main Debug/Lesson1.exe : fatal error LNK1120: 1 unresolved externals Error executing link.exe. Lesson1.exe - 2 error(s), 0 warning(s) I have uninstalled then reinstalled c++, but I still get the same error... Can anyone help with this?
Are you using the projects included in the tutorials?

It looks like you might be trying to compile the code in a console project instead of a Win32 project.
Advertisement
Damn...that was a quick reply...

Ummm ok...n00b here...
I have tried to create a Win32 application...and then insert the source code...I tried copying the project file and the source file into a new folder, opening the project file and the source code, compiling (no probs) and linking...same error..

If you have a WinMain() and it''s asking for a main(), bad project settings are the only possible cause (AFAIK). It must be still trying to compile the thing as a console project.
oops silly me...it was a win32 console, not win32...thanks dude, all fixed...
It''s weird thou, coz the downloaded project must be a win32 console, not win32...coz I had to create a new win32 project and add the source to make it work...?...hmmm
Advertisement
For questions relating to the NeHe tutorials you really ougth to post it on NeHe''s forum - people there have allready had most of these problems...
/Please excuse my bad spelling - My native language is binary not english|Visit meTake my advice - I don''t use it...
Thanks.....sorry I thought this was the NeHe forum....

This topic is closed to new replies.

Advertisement