MT.exe 的使用


脚本:

AutoManifestSign.bat

@echo mt.exe -manifest .\ApplicationController.exe.manifest -outputresource:.\Exe\ApplicationController.exe;#1

manifest:文件

名称:ApplicationController.exe.manifest

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
    <assemblyIdentity version="1.0.0.0" processorArchitecture="*" name="ApplicationController.exe.manifest" type="win32"></assemblyIdentity>
    <trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
            <security>
                <requestedPrivileges>
                    <requestedExecutionLevel level="requireAdministrator" uiAccess="false"></requestedExecutionLevel>
                </requestedPrivileges>
            </security>
    </trustInfo>
    <compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
      <application>
        <!--The ID below indicates application support for Windows Vista -->
        <supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"/>
    <!--The ID below indicates application support for Windows 7 -->
    <supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>
    </application>
    </compatibility>
</assembly>

参考:

http://technet.microsoft.com/zh-tw/library/aa375649%28v=vs.80%29.aspx

你可能感兴趣的:(MT.exe 的使用)