我已经合并了 msm 与 2015 crt:
<DirectoryRef Id="TARGETDIR" >
<Merge Id = "Microsoft_VC140_CRT_x64.msm" FileCompression = "yes" Language = "1033" SourceFile = "..\\..\\..\\..\\..\\..\\..\\external\\tools\\systemsetups\\merge_modules\\Microsoft_VC140_CRT_x64.msm" DiskId = "1" />"
</DirectoryRef>
<Feature>
<Feature Id="Complete" Title="Complete" Absent="allow" Level="1">
...
<MergeRef Id="Microsoft_VC140_CRT_x64.msm"/>
...
</Feature>
但我仍然收到:
---------------------------
MyApp.exe - System Error
---------------------------
The program can't start because mfc140u.dll is missing from your computer. Try reinstalling the program to fix this problem.
---------------------------
OK
---------------------------
有什么想法如何正确合并它吗?
微软似乎建议您使用 redist 可执行文件之一(vcredist_x86.exe
, vcredist_x64.exe
) 而不是合并模块 https://learn.microsoft.com/en-us/cpp/windows/redistributing-components-by-using-merge-modules?view=msvc-160(见底部)自从 2015 版本的运行时以来,这些天比以前更复杂 https://blogs.msdn.microsoft.com/vcblog/2015/03/03/introducing-the-universal-crt/并且合并模块基本不足:”通用 CRT 不会有合并模块".
UPDATE: 如何将 exe 二进制文件 VCRedist 与您的 MSI 一起安装? https://stackoverflow.com/a/67375780/129130.
这完全可以解释为鲍勃·阿恩森在这个答案中:用于在 Windows 7 上部署使用 Visual Studio 2015 开发的 C++ exe 的可再发行组件 https://stackoverflow.com/questions/34592378/redistributables-for-deploying-c-exe-developed-with-visual-studio-2015-on-wind/34597936#34597936 (必须阅读链接- 这就是答案,我刚刚添加了这个答案以添加一些进一步的链接)。
另外,我面前没有这个 Linux 机器上的合并模块列表,但也许您需要 x86 版本 - 您正在安装 x64 版本?只是检查一下 - 这些位数问题让我们所有人都发疯了。
一些链接:
- 重新分发 Visual C++ 文件 https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads
- 演练:使用 Visual C++ 可再发行组件包部署 Visual C++ 应用程序 https://learn.microsoft.com/en-us/cpp/windows/deploying-visual-cpp-application-by-using-the-vcpp-redistributable-package?view=msvc-160
- 使用合并模块重新分布组件 https://learn.microsoft.com/en-us/cpp/windows/redistributing-components-by-using-merge-modules?view=msvc-160
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)