• Advertisement
Sign in to follow this  

SDL and MSVC++ 2005 Express

This topic is 4259 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I've been messing around with c++ for a while, just making little stuff and showing it to my friends. A few days ago I decided to check out SDL, and it's simplicity has made it pretty fun to use... But for some reason all of the programs I make with it wont run on any of my friend's computers. I've sent programs to them before, console programs, and opengl, and they've never had any problems. My friend sent me a screenshot of the error he gets, its just a dialogue box that pops up saying 'This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem.' Also, I sent my friend sdl.DLL that the .exe needs, and he downloaded and ran vcredist_x86, still to no avail(idk why that would help since other programs compiled with vc++ have worked). Well, thats my situation, hopefully that makes sense to someone, any help at all is appreciated. Thanks in advance for any help :) -glBender

Share this post


Link to post
Share on other sites
Advertisement
Guest Anonymous Poster
Yeah, he's been working on something to optimize our progress on a project but whenever he sends it to me I get an error. I looked it up on the net and it said it's common when trying to run an Office 2003 program on Windows XP O_O!!

Some please help us D:

Share this post


Link to post
Share on other sites
I changed from /MD to /MT and now i get these errors:

msvcrt.lib(ti_inst.obj) : error LNK2005: "private: __thiscall type_info::type_info(class type_info const &)" (??0type_info@@AAE@ABV0@@Z) already defined in LIBCMT.lib(typinfo.obj)
msvcrt.lib(ti_inst.obj) : error LNK2005: "private: class type_info & __thiscall type_info::operator=(class type_info const &)" (??4type_info@@AAEAAV0@ABV0@@Z) already defined in LIBCMT.lib(typinfo.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _exit already defined in LIBCMT.lib(crt0dat.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _fprintf already defined in LIBCMT.lib(fprintf.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: ___iob_func already defined in LIBCMT.lib(_file.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _fopen already defined in LIBCMT.lib(fopen.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _fclose already defined in LIBCMT.lib(fclose.obj)
msvcrt.lib(MSVCR80.dll) : error LNK2005: _isspace already defined in LIBCMT.lib(_ctype.obj)
LIBCMT.lib(crt0init.obj) : warning LNK4098: defaultlib 'msvcrt.lib' conflicts
with use of other libs; use /NODEFAULTLIB:library


I did what it said and tried ignoring msvcrt.lib, and it gives these errors:

sdlmain.lib(SDL_win32_main.obj) : error LNK2001: unresolved external symbol __imp__strrchr
sdlmain.lib(SDL_win32_main.obj) : error LNK2001: unresolved external symbol __imp__remove
sdlmain.lib(SDL_win32_main.obj) : error LNK2001: unresolved external symbol __imp__fgetc
sdlmain.lib(SDL_win32_main.obj) : error LNK2001: unresolved external symbol __imp__setbuf
sdlmain.lib(SDL_win32_main.obj) : error LNK2001: unresolved external symbol __imp__setvbuf
sdlmain.lib(SDL_win32_main.obj) : error LNK2001: unresolved external symbol __imp__freopen

Share this post


Link to post
Share on other sites
Ok I did what the link in that thread you posted said to do, and made used WIX to create an installer, and my friend ran it and it still didnt work... All other app's i've made have worked on others computers, just not after I started using SDL, is there anything their computer would need SDL related, other than sdl.DLL ?

Share this post


Link to post
Share on other sites
No, try giving him "MSVCP71D.dll" and "MSVCR71D.dll". When you select Multi-threaded DLL, it does not statically link the C and C++ runtimes, so your program needs to link to them dynamically with these DLLs (I think[smile]).

If this was the case though, I would think his error message would say "Cannot find MSVCP71D.dll" or somthing.

Share this post


Link to post
Share on other sites
Those DLL's are for VC7.1 not VC8 and they are debug versions of the C runtime.

Share this post


Link to post
Share on other sites
My bad. It fixed my problem to include those, but I use MSVC 7.1 If this is your problem, your friend's error message will give the exact files missing.

Share this post


Link to post
Share on other sites
Quote:
Original post by Simian Man
No, try giving him "MSVCP71D.dll" and "MSVCR71D.dll". When you select Multi-threaded DLL, it does not statically link the C and C++ runtimes, so your program needs to link to them dynamically with these DLLs (I think[smile]).
Is there a way to statically link the C and C++ runtimes yet still dynamically link SDL?

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement