32 位 VC++可在 64 位操作系统上重新分发吗?

发布于 2024-09-25 05:37:14 字数 222 浏览 0 评论 0原文

使用 Visual Studio,我构建了一个以 32 位运行的 C++ 应用程序。它将部署到 32 位和 64 位 Windows 服务器。它不会在 64 位模式下运行(而是在 WoW 下运行)。

我应该同时包含 32 位和 64 位 Visual C++ 可再发行组件,并在 32 位 Windows 上安装 32 位,在 64 位 Windows 上安装 64 位,还是只安装 32 位可再发行组件就足够了?

Using Visual Studio, I have built an C++ application running in 32bit. It will be deployed both to 32-bit and 64-bit Windows servers. It won't be run in 64-bit mode (but rather under WoW).

Should I include both the 32-bit and 64-bit Visual C++ redistributable, and install 32bit on 32bit Windows and 64bit on 64 bit Windows, or is it enough to just install the 32bit redistributable?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

回心转意 2024-10-02 05:37:14

安装 32 位可再发行组件就足够了。

It is enough to install the 32bit redistributable.

随遇而安 2024-10-02 05:37:14

编辑:我在下面评论了一个误导性的答案,但答案是你只需要 32 位可再发行组件,如 Karel Petranek 首先回答

这不是答案。它应该只是一条评论,但由于我没有所需的声誉...:

我只是想警告人们不要提防 Ruel 提供的信息。不,64 位 Visual C++ 可再发行软件包不包含 32 位 DLL。

我什至测试了(他的)理论。我尝试运行一个需要 Visual C++ 2010 32 位可再发行组件的应用程序,它提示我它需要该组件。然后我安装了64位的,还是提示需要32位版本的Visual C++ 2010,安装完32位的就可以了。

为什么人们会提出理论并提供它们作为答案,这让我很困惑。或者也许他也受到声誉系统的“鼓励”,不仅提供了多余的信息,而且还提供了虚假信息。或者他只是将 C++ 与 DirectX 9 可再发行组件(既安装 32 位又安装 64 位 DLL)混淆了。

EDIT: I commented below on a misleading answer, but the answer is you only need the 32-bit redistributables, as Karel Petranek answered first.

This is not an answer. It should only be a comment, but since I don't have the required reputation for that...:

I just wanted to warn people against Ruel's provided information. No, the 64-bit Visual C++ redistributable packages don't also include the 32-bit DLLs.

I have even tested that (his) theory. I tried to run an application that requires Visual C++ 2010 32-bit redistributables and it prompted me that it needs that. I then installed the 64-bit one, and it still prompted it needed the 32 bit version of Visual C++ 2010. After installing the 32 bit one, it worked.

Why people come up with theories and provide them as answers beats me. Or maybe he was also "encouraged" by the reputation system to give not only superfluous, but also false information. Or maybe he just confused C++ with DirectX 9 redistributables (that one does install both 32-bit and 64-bit DLLs).

尐籹人 2024-10-02 05:37:14

两者都是微软产品,但不要被它欺骗了。

您的 C++ 应用程序创建一个 32 位 EXE,链接到 32 位 DLL。碰巧,其中一两个 DLL 是 Microsoft CRT DLL,但操作系统仍然使用相同的规则。因此,您不需要 64 位 DLL。

Both are Microsoft products, but don't let that fool you.

Your C++ application creates a 32 bits EXE, linking to 32 bits DLLs. As it happens, one or two of those DLLs are Microsoft CRT DLLs, but the OS still uses the same rules. Therefore, you don't need the 64 bits DLLs.

人│生佛魔见 2024-10-02 05:37:14

使用/MT选项编译它,VC++运行时库将被编译到您的exe中,因此您不必担心分发它。

项目>>属性>配置属性> C/C++>代码生成>运行时库>多线程 (/MT)。

Compile it using /MT option and VC++ runtime library will be compiled into your exe, so you don't have to worry about distributing it.

Project > Properties > Configuration Properties > C/C++ > Code Generation > Runtime Library > Multi-threaded (/MT).

预谋 2024-10-02 05:37:14

64 位 Visual C++ 可再发行组件包包括 32 位 Visual C++ 可再发行组件和 64 位 Visual C++ 可再发行组件。

The 64-bit Visual C++ redistributable package includes both 32-bit Visual C++ redistributable and 64-bit Visual C++ redistributable.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文