我尝试使用 Windows SDK 中的 mt.exe 将清单添加到没有清单的可执行文件中,使用以下命令行:
C:\winsdk61>mt.exe -nologo -manifest "r:\shared\hl.exe.manifest" -updateresource:"r:\shared\hl33m.exe;#1"
不幸的是,当我这样做时,我收到此错误:
mt.exe : general error c101008c: Failed to read the manifest from
the resource of file "r:\shared\hl33m.exe". The specified resource
type cannot be found in the image file.
当然,在文件中找不到资源 - 该文件没有清单,这就是我想添加一个的原因。
如何将清单附加到可执行文件?这不是应该很简单吗?
你应该使用/输出资源代替/更新资源:.
正确的命令行是:
mt.exe -nologo -manifest "r:\shared\hl.exe.manifest" -outputresource:"r:\shared\hl33m.exe;#1"
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)