How to put files into executable?

So i just made this tic-tac-toe game using SDL. I want to show my friend the game.

So i made a folder with these files
-SDL Includes and Libs
-a bunch of .dll files
-the image files that are used in the game
-the .ttf file that is used in the game
-the .exe file

And it says mscv.dll is missing? On my computer when i click the .exe it runs perfectly. What am i doing wrong?
Does no one know how to do this?
Hmm..if you're using Visual C++, I think you'll have to get your friend to install the Microsoft Visual C++ Redistributable.

I've used SDL for over a year but I've never come across a problem like this, so I'm not entirely sure if this will fix your problem.
Link your program statically to mscv.dll or get your friend to download the Redistributable package as Poke386 pointed out.
But games like minecraft its just an executable file.

I dont want him to have to download anything except the executable
Poke386 nailed it, your friend doesn't have this DLL so either you statically link that library, use a different compiler (and potentially set your self back a few weeks because of random bugs) or your friend downloads the redistributable. The easy answer is for your friend to download the package. If there is no friend and you want to play this at school or something then you need to do one of the other two options (if this is the case please don't lie to us, it makes it harder to help you).

Right now your game requires a file that your friend doesn't seem to have, you can't just say please and expect a work around to magically appear.
Okay i choose statically linking the libary. How would i do that?
I think it's:

Project menu -> (project name) Properties (ALT+F7)

Choose C/C++ -> Code generation.

On the right choose Runtime Library and choose one of the options that does not say DLL
Last edited on
If in doubt, just ship the DLL in question with the game.
Topic archived. No new replies allowed.