0

I've browsed around StackOverflow but couldn't find any pratical solution to something that would seem to have such an easy solution: I had a bunch of .Net projects that were developed back in VS2005 or VS2008 and I imported them into VS2010. One of them is a C++ project, which currently targets framework 4.0 (not by my choice). One of our clients is having a problem running this application, the lack of a MSVCP100D.dll. I checked this thread what is MSVCP100D.dll? and the most accepted answer is simple: having the client install Microsoft Visual C++ 2010 Redistributable Package. However, the client is stubborn enough not to install it and I know for a fact that they have Microsoft Visual C++ 2008 Redistributable installed. So, if I'm correct in my conclusions and MSVCP100D.dll is new to VS2010, I could just target a previous framework version, rebuild the project in VS2010 and I'd be good to go. The problem is: how do I chance a VC++ target framework? I could find several guidelines to change C# and VB projects, but none about VC++. Any pointers?

Edit: To you guys who suggested that I compile it in Release mode: I am! It's been pointed out that the "D" stands for debug, which is rather strange.

Community
  • 1
  • 1
makoshichi
  • 2,310
  • 6
  • 25
  • 52
  • You did see that that is the debug version of the library (which **can not** be [legally] redistributed)? – Rowland Shaw Jul 11 '12 at 19:40
  • Have you tried compiling your program in *release* mode? MSVCP100D.DLL is the *debug* build of the runtime library. This is explained in the accepted answer of the question you linked to. – Greg Hewgill Jul 11 '12 at 19:40
  • Well, I changed Platform Toolset, made sure I was compiling in Release mode (although I was pretty sure before) and sent it away (it's kinda though to test lacking dependencies when you have everything installed in your machine). I'll get back as soon as I have some feedback from support department – makoshichi Jul 11 '12 at 20:02
  • Rather than sending it anywhere to be tested, use something like [Dependency Walker](http://www.dependencywalker.com/) to verify that you don't have any references to debug DLLs before troubling anybody else with it. – Greg Hewgill Jul 11 '12 at 20:04

2 Answers2

1

Actually, you are using the debug version of the runtime (That's the "D"). Did you try compiling with a non-debug version?

Another possibility to consider would be to statically link with the runtime library. Your program will be larger, but will not have the DLL dependency.

Dark Falcon
  • 43,592
  • 5
  • 83
  • 98
  • Thanks for the information on the "D", although I'm pretty sure I compiled it in release mode. Also, I'm not very big on statically linking a .dll as it might cause somewhat of a "chain-dependency reaction" ^^ – makoshichi Jul 11 '12 at 20:04
1

Go into the project's properties.

On the lefthand side, go into Configuration Properties > General.

Look at the Platform Toolset value. Select v90 from the drop down list to target 2008.

See here for further details: Visual C++ 2010 compatibility with VC 2008

See here for yet even more details: http://blogs.msdn.com/b/vcblog/archive/2009/12/08/c-native-multi-targeting.aspx

enter image description here

Also as Dark Falcon mentions, that's the debug version of the runtime.

Community
  • 1
  • 1
jglouie
  • 12,523
  • 6
  • 48
  • 65