[Dexter][NFC] Add Missing Commands to Commands.md Contents
[llvm-project.git] / lld / test / COFF / manifest.test
blobf3a388f8bbe16da9d5547df7608452a911891803
1 # RUN: yaml2obj %p/Inputs/ret42.yaml -o %t.obj
3 # RUN: rm -f %t.exe.manifest
4 # RUN: lld-link /out:%t.exe /entry:main %t.obj
5 # RUN: test ! -e %t.exe.manifest
7 # RUN: lld-link /manifest /out:%t.exe /entry:main %t.obj
8 # RUN: FileCheck -check-prefix=MANIFEST %s < %t.exe.manifest
10 MANIFEST: <?xml version="1.0" standalone="yes"?>
11 MANIFEST: <assembly xmlns="urn:schemas-microsoft-com:asm.v1"
12 MANIFEST:           manifestVersion="1.0">
13 MANIFEST:   <trustInfo>
14 MANIFEST:     <security>
15 MANIFEST:       <requestedPrivileges>
16 MANIFEST:          <requestedExecutionLevel level='asInvoker' uiAccess='false'/>
17 MANIFEST:       </requestedPrivileges>
18 MANIFEST:     </security>
19 MANIFEST:   </trustInfo>
20 MANIFEST: </assembly>
22 # RUN: lld-link /out:%t.exe /entry:main /manifest \
23 # RUN:   /manifestuac:"level='requireAdministrator' uiAccess='true'" %t.obj
24 # RUN: FileCheck -check-prefix=UAC %s < %t.exe.manifest
26 UAC: <?xml version="1.0" standalone="yes"?>
27 UAC: <assembly xmlns="urn:schemas-microsoft-com:asm.v1"
28 UAC:           manifestVersion="1.0">
29 UAC:   <trustInfo>
30 UAC:     <security>
31 UAC:       <requestedPrivileges>
32 UAC:          <requestedExecutionLevel level='requireAdministrator' uiAccess='true'/>
33 UAC:       </requestedPrivileges>
34 UAC:     </security>
35 UAC:   </trustInfo>
36 UAC: </assembly>
38 # /manifestdependency implies /manifest. (/manifestuac doesn't.)
39 # RUN: lld-link /out:%t.exe /entry:main \
40 # RUN:   /manifestdependency:"foo='bar'" %t.obj
41 # RUN: FileCheck -check-prefix=DEPENDENCY %s < %t.exe.manifest
43 DEPENDENCY: <?xml version="1.0" standalone="yes"?>
44 DEPENDENCY: <assembly xmlns="urn:schemas-microsoft-com:asm.v1"
45 DEPENDENCY:           manifestVersion="1.0">
46 DEPENDENCY:   <trustInfo>
47 DEPENDENCY:     <security>
48 DEPENDENCY:       <requestedPrivileges>
49 DEPENDENCY:          <requestedExecutionLevel level='asInvoker' uiAccess='false'/>
50 DEPENDENCY:       </requestedPrivileges>
51 DEPENDENCY:     </security>
52 DEPENDENCY:   </trustInfo>
53 DEPENDENCY:   <dependency>
54 DEPENDENCY:     <dependentAssembly>
55 DEPENDENCY:       <assemblyIdentity foo='bar' />
56 DEPENDENCY:     </dependentAssembly>
57 DEPENDENCY:   </dependency>
58 DEPENDENCY: </assembly>
60 # RUN: lld-link /manifest /out:%t.exe /entry:main /manifestuac:no \
61 # RUN:   /manifestdependency:"foo='bar'" %t.obj
62 # RUN: FileCheck -check-prefix=NOUAC %s < %t.exe.manifest
64 NOUAC: <?xml version="1.0" standalone="yes"?>
65 NOUAC: <assembly xmlns="urn:schemas-microsoft-com:asm.v1"
66 NOUAC:           manifestVersion="1.0">
67 NOUAC:   <dependency>
68 NOUAC:     <dependentAssembly>
69 NOUAC:       <assemblyIdentity foo='bar' />
70 NOUAC:     </dependentAssembly>
71 NOUAC:   </dependency>
72 NOUAC: </assembly>
74 # RUN: lld-link /manifest /out:%t.exe /entry:main /manifestuac:no %t.obj
75 # RUN: FileCheck -check-prefix=NOUACNODEP %s < %t.exe.manifest
77 NOUACNODEP: <?xml version="1.0" standalone="yes"?>
78 NOUACNODEP: <assembly xmlns="urn:schemas-microsoft-com:asm.v1"
79 NOUACNODEP:           manifestVersion="1.0">
80 NOUACNODEP: </assembly>