C++ 什么是 MSVCP100D.dll?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/6580685/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-28 20:23:38  来源:igfitidea点击:

What is MSVCP100D.dll?

c++visual-c++dll

提问by Suhail Gupta

Possible Duplicate:
Application has failed to start because MSVCP100D.dll was not found, reinstalling app may help…

可能重复:
应用程序无法启动,因为未找到 MSVCP100D.dll,重新安装应用程序可能会有所帮助...

I compiled my program using Microsoft visual C++ 2010 Express Editionand tried to run it on another machine that did not have the same compiler.

我使用Microsoft Visual C++ 2010 Express Edition编译了我的程序,并尝试在另一台没有相同编译器的机器上运行它。

As I double clicked it, and there was message saying MSVCP100D.dll file was found missing.

当我双击它时,有消息说找不到 MSVCP100D.dll 文件。

  • What sort of file is this?
  • Why did the application fail to start?
  • What can I do to start the application there?
  • 这是什么类型的文件?
  • 为什么应用程序无法启动?
  • 我该怎么做才能在那里启动应用程序?

回答by kgiannakakis

This is the C++ runtime library dll. You've used the debug version, which won't be found in a user's computer. Compile your program in release mode. This will add a dependency in MSVCP100.dll, which is most likely to be present.

这是 C++ 运行时库 dll。您已经使用了调试版本,在用户的计算机中找不到该版本。在发布模式下编译您的程序。这将在最有可能存在的 MSVCP100.dll 中添加依赖项。

In any case, you must make sure that the dll will be present in user's machine. You can do that by creating an installer or by prompting the user to install the Microsoft Visual C++ 2010 Redistributable Package.

在任何情况下,您都必须确保 dll 将存在于用户的计算机中。您可以通过创建安装程序或提示用户安装 Microsoft Visual C++ 2010 Redistributable Package 来完成此操作。

In summary:

总之:

  • Compile your code in release mode
  • Create an installer or use another way to copy the needed dlls to user's machine
  • 在发布模式下编译您的代码
  • 创建安装程序或使用其他方式将所需的 dll 复制到用户计算机

回答by Daniel Chisholm

What about statically linking your program instead? I have done this in order to avoid this hassle (of either creating an installer, or asking a user to install another package and having to point/handhod them in that direction)

静态链接你的程序呢?我这样做是为了避免这种麻烦(要么创建安装程序,要么要求用户安装另一个包,然后必须指向/用手把它们指向那个方向)

回答by Constantinius

I guess you have to download and install the redistribution package from hereto install the runtime environment necessary for your compiled code.

我猜你必须从这里下载并安装重新分发包,才能安装编译代码所需的运行时环境。

This DLLcontains extra functions, which are linked when you run the program. If this DLL is not present, you receive the error message you are experiencing.

这个DLL包含额外的函数,当您运行程序时会链接这些函数。如果此 DLL 不存在,您会收到您遇到的错误消息。