确定链接的 dll 版本
根据 这篇文章< /a>,引用的dll的版本嵌入到exe文件中。
使用 ProcExp,我可以看到运行时加载的 dll 确实是我的机器上可用的最新 dll,但我有兴趣知道链接的版本。
附带说明一下,我使用 VS9 msbuild 构建了该项目,并对 VC 运行时 (msvcr90.dll) 版本感兴趣。在VC9 redist文件夹中它是9.0.30729.1,运行时加载.4926。
我的问题是:
- 是否有任何工具可以用来提取链接到的 dll 版本(从 dll/exe)?
- VS默认链接到哪个版本?在 redist 文件夹中找到的那个?
谢谢。
According to this article, the version of a referenced dll is embedded in the exe file.
Using ProcExp, I can see that the runtime loaded dll is indeed the latest dll available on my machine, but I'm interested to know the linked version.
As a side note, I built the project using the VS9 msbuild, and interested in the VC runtime (msvcr90.dll) version. In the VC9 redist folder it is 9.0.30729.1, runtime the .4926 is loaded.
My questions are:
- Is there any tool with which I can extract the dll version linked to (from the dll/exe)?
- Which version does VS link to by default? The one found in its redist folder?
Thank you.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
Dependency Walker 可能会做到这一点。
Dependency Walker might do it.
实际上,Dependency Walker 似乎没有读取(或至少显示)文件中链接的版本。
但我发现我可以使用 Windows SDK 中的 mt.exe 或 ResEdit 来读取嵌入的清单。
另外,总结我的发现(使用 msbuild 和 Windows SDK for Win7 来定位 amd64,它似乎使用 VS9(SP1?)libs):
对于未来的帐户,如果: 会有
Actually, Dependency Walker seems to not read (or at least display) the version linked in the file.
But I found that I can use mt.exe from the Windows SDK or ResEdit to read the embedded manifests.
Also, to summarize my findings (targeting amd64 using msbuild with the Windows SDK for Win7, which seems to use VS9 (SP1?) libs):
_BIND_TO_CURRENT_VCLIBS_VERSION=1
is defined, then the linker would link against the VS9 SP1 CRT (version 9.0.30729.1), which as noticed before, is indeed in the redist folder.For future account, it would be nice if: