Code::Blocks Forums

User forums => Using Code::Blocks => Topic started by: kafka on March 06, 2008, 02:46:57 pm

Title: SDL problemo
Post by: kafka on March 06, 2008, 02:46:57 pm
Ok, so. I just downloaded codeblocks, and I installed SDL manually. Now that I put the commands to the linker (-lmingw32 -lSDLmain -lSDL) and try to compile, it gives me this message:
Code
F:\Ohjelmat\CodeBlocks\MinGW\bin\..\lib\gcc\mingw32\3.4.5\..\..\..\libmingw32.a(main.o):main.c:(.text+0x104)||undefined reference to `_WinMain@16'|
I dont understand what did I do wrong...
Title: Re: SDL problemo
Post by: MortenMacFly on March 06, 2008, 04:06:36 pm
I dont understand what did I do wrong...
You didn't searched this and any SDL forum. It's annoyning to answer the same question over and over again. :?
Title: Re: SDL problemo
Post by: kafka on March 06, 2008, 04:36:38 pm
Searched, but I didn't find post that is about my problem.
Title: Re: SDL problemo
Post by: stahta01 on March 06, 2008, 06:26:28 pm
Look at this post, similar error, should have related solution.

Tim S

http://forums.codeblocks.org/index.php/topic,4135.0.html
Title: Re: SDL problemo
Post by: MortenMacFly on March 06, 2008, 09:48:28 pm
Searched, but I didn't find post that is about my problem.
I  can't believe this should be true. Searching for SDL in our forums revealed
http://wiki.codeblocks.org/index.php/Using_SDL_with_Code::Blocks
as one of the first hits.

Searching with google for "undefined reference to WinMain SDL" revealed ~1400 hits.

No more to say except that if we have more questions like that in the forum we can cease development on C::B and just help with basic programming issues over and over again. That's why I am reacting like this.