Sign in to follow this  
avgprogramingjoe

Defualt sdl app isn't working

Recommended Posts

Hey guys i downloaded sdl for my code::blocks with mingw. I went to run the defualt sdlapp template and it gave me this error. Switching to target: default Linking executable: sdlapp.exe C:\Program Files\CodeBlocks\bin\..\lib\gcc\mingw32\3.4.4\..\..\..\..\mingw32\bin\ld.exe: cannot find -lSDLmain collect2: ld returned 1 exit status Process terminated with status 1 (0 minutes, 0 seconds) Does anybody know how i can fix this? Thanks, Joe

Share this post


Link to post
Share on other sites
econobeing    140
you sure you downloaded the right sdl files and/or put them in the right place?

lazy foo has a tutorial on code::blocks/sdl here, be sure to read everything, even the "do it yourself" link on the bottom.

you might have to link the libraries yourself if none of that worked.

Share this post


Link to post
Share on other sites
I went over everything to make sure i had it all correct. But i do have a question now, am i supposed to put for example the sdl lib folder in the code::blocks folder, or just all of it's contents(not in the sdl lib folder)?

Share this post


Link to post
Share on other sites
k I started it over and managed to compile it with no errors, i get this:
Checking for existence: SDLapp.exe
Executing: "C:\Documents and Settings\Owner.YOUR-99DDF15D27\My Documents\SDLapp.exe" (in .)
Process terminated with status 0 (0 minutes, 0 seconds)
0 errors, 0 warnings
But when i run it I only see a window pop up and disappear so quick that i can't even tell what it is. Have i done it right, or is there still a problem?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this