Sign in to follow this  
Fredericvo

Missing msvcrt110.dll onpc other than build machine

Recommended Posts

I wanted to show some simple directx 11 program I made to a few online friends and then it appeared that

they got a missing msvcrt11.dll error.

 

I've tried to use a few solutions found online such as:

 

http://www.rhyous.com/2011/11/01/avoiding-the-msvcr110-dll-or-msvcr110d-dll-is-missing-error/

 

and

 

http://www.cplusplus.com/forum/beginner/91177/

 

but nothing works. especially the following solution:

 

For the C-runtime go to the project settings, choose C/C++ then 'Code Generation'. Change the 'runtime library' setting to 'multithreaded /MT' instead of 'multithreaded dll'

 

the exe would simply crash.

 

I wouldn't want my programs to require users to install the runtime library and such. What do I do next?

 

PS: I'm using Visual Studio Express 2012 on a 64-bit windows 7 although my friend needed a 32-bit build so I did that. Apparently a 64-bit release with the /MT setting does work but not for 32-bit. I still need it to work since he's got a 32-bit PC.

 

 

Share this post


Link to post
Share on other sites

If you want to use /MT option (include runtime library in your .exe file) all other libraries you use also have to be compiled with this option, otherwise your .exe is running several runtimes and bad things may (usually will) happen.

 

I have little knowledge of linking DirectX, but if it is compiled with shared runtime option (/MD), you have to use the same option for your exe file and distribute your game with an installer that installs this (mentioned by SiCrane) runtime on the end user machine.

Edited by Nercury

Share this post


Link to post
Share on other sites

I've tried using depends.exe to get more insight. I noticed that all 32-bit exes generate the following error: Modules with different CPU types were found. Indeed all system dlls are being displayed as being 64 bit.

Now I'm thinking all calls to system DLLs are redirected via the wow64 subsystem on a 64 bit system executing a 32 executable.(something depends.exe seems unaware of)  Could it be that by choosing the /MT switch it embeds 64 bit code in a 32 bit executable? That could explain why it crashes in a 32 bit exe  but not with a pure 64 bit exe. I could be totally wrong of course.

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