I know my source code is correct, because I copied it straight from the LazyFoo site. I followed all the instructions from the page to get both my IDE's(Dev-C++, Code::Blocks), and yet they both give me the same error. And yes, I put the DLL files in the project folder. Heres the error:
It looks like you dont have the libraries linked in your dependencies. I'm not sure how to do this for code::blocks or Dev C++, but if you follow every step of his first tutorial you should be golden.
Also, I wouldn't recomment just copying lazyfoo's code. Only in the first tutorial (maybe two) does he give you all the code for a program that is functional. Most of the time you just get snippets. It's also a great way to memorize the SDL library if you type everything in by hand each time you do a tutorial.
My love is like a Haddoken, it's downright fierce!
When I said copied code I meant copied what he had by typing. I agree just copying source doesn't get you memorizing code. I still don't know what I'm doing wrong. I've had this problem before, I just keep forgetting how to fix it.
JaxDragon wrote:When I said copied code I meant copied what he had by typing. I agree just copying source doesn't get you memorizing code. I still don't know what I'm doing wrong. I've had this problem before, I just keep forgetting how to fix it.
If you're using Code::Blocks, go to project->build options->linker settings, then in "Other linker options", put this:
I fixed it, the problem was that I forgot to put SDL_Quit() at the bottom of the code ^^. SDL has to be referenced/dereferenced for it to link properly.