Original Post
Hi, I recently found the Agar library(http://libagar.org/) and was trying to compile my first application when I ran into linker problems.
I'm using Visual Studio Express 2010, and when I try to compile my application with /SUBSYSTEM:WINDOWS in the linker settings, I get the following errors :
1>SDLmain.lib(SDL_win32_main.obj) : error LNK2005: _main already defined in main.obj
1>LINK : warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library
1>SDLmain.lib(SDL_win32_main.obj) : error LNK2019: unresolved external symbol _SDL_main referenced in function _main
1>C:\mydata\dev\project01\Debug\project01.exe : fatal error LNK1120: 1 unresolved externals
When I switch to /SUBSYSTEM:CONSOLE, everything works fine.
I'm using Visual Studio Express 2010, and when I try to compile my application with /SUBSYSTEM:WINDOWS in the linker settings, I get the following errors :
1>SDLmain.lib(SDL_win32_main.obj) : error LNK2005: _main already defined in main.obj
1>LINK : warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library
1>SDLmain.lib(SDL_win32_main.obj) : error LNK2019: unresolved external symbol _SDL_main referenced in function _main
1>C:\mydata\dev\project01\Debug\project01.exe : fatal error LNK1120: 1 unresolved externals
When I switch to /SUBSYSTEM:CONSOLE, everything works fine.