You should have to add SDL_main.c to your project…
What I do is just copy SDL.LIB and SDLmain.lib to my project folder,
then add these two to my Project->Settings->Link->Object/Library Modules
(you can skip the copy part, and just reference these files with a full
Path like c:\winnt\sdl_lib\ or something).
Then I make sure the checkbox for Ignore all default Libraries is NOT
Checked (I have had problems with this before).
Now you just have to be sure that your main looks something like this,
int main(int argc, char* argv[] )
{
}
Oh, and your project should be a Win32 Console Application…
Also, check that your are including al the necessary Header Files.
Another important thing is to check that you have "Multithreaded DLL"
In Project->Settings->C/C+±>[Combo]:Code Generation->Use Run-time
Library.
This is all I can remember for now…
Good Luck
Juan Ignacio Carniglia - Programmer - Buenos Aires, Argentina.> -----Original Message-----
From: sdl-admin at libsdl.org [mailto:sdl-admin at libsdl.org] On
Behalf Of Sashnov Alexander
Sent: Saturday, September 06, 2003 2:01 PM
To: dade at ravingninja.com
Subject: Re: [SDL] MSVC 6 and SDL 1.2
Hello
Thursday, September 4, 2003, 10:36:26 PM, you wrote:
I’m trying to get SDL 1.2 working in MSVC 6, but I have been
experiencing issues when trying link my project. I have
set the code
generation to multi- threaded dll already, and included sdl.lib and
sdl_main.lib, but those didn’t work. So I physically
dropped those to
lib files into the project’s file list and tried that, but
it didn’t
work either. I then included sdl_main.c into the project, and now
I’ve got an error that there seems to be no resources on
the 'net for.
What I’m getting now is:
SDL_main.obj : error LNK2001: unresolved external symbol
_SDL_SetModuleHandle
Debug/sdl_trade.exe : fatal error LNK1120: 1 unresolved externals
I’m have SDL 1.2.4
It’s work fine with Visual C++ 6
See carefully VisualC.html!
–
Best regards,
Sashnov Alexander mailto:sashnov at ngs.ru
SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl