File: merge-resource-manifest.test

package info (click to toggle)
swiftlang 6.0.3-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 2,519,992 kB
  • sloc: cpp: 9,107,863; ansic: 2,040,022; asm: 1,135,751; python: 296,500; objc: 82,456; f90: 60,502; lisp: 34,951; pascal: 19,946; sh: 18,133; perl: 7,482; ml: 4,937; javascript: 4,117; makefile: 3,840; awk: 3,535; xml: 914; fortran: 619; cs: 573; ruby: 573
file content (61 lines) | stat: -rw-r--r-- 2,806 bytes parent folder | download | duplicates (21)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# RUN: yaml2obj %p/Inputs/ret42.yaml -o %t.o

# RUN: yaml2obj %p/Inputs/manifest-lang0.yaml -o %t-manifest-lang0.o
# RUN: yaml2obj %p/Inputs/manifest-lang1.yaml -o %t-manifest-lang1.o
# RUN: yaml2obj %p/Inputs/manifest-lang2.yaml -o %t-manifest-lang2.o

# RUN: lld-link /lldmingw /out:%t.exe /entry:main %t.o %p/Inputs/manifest-lang0.res %p/Inputs/manifest-lang1.res
# RUN: llvm-readobj --coff-resources %t.exe | FileCheck %s

# RUN: lld-link /lldmingw /out:%t.exe /entry:main %t.o %t-manifest-lang0.o %t-manifest-lang1.o
# RUN: llvm-readobj --coff-resources %t.exe | FileCheck %s

# RUN: lld-link /lldmingw /out:%t.exe /entry:main %t.o %p/Inputs/manifest-lang1.res %p/Inputs/manifest-lang0.res
# RUN: llvm-readobj --coff-resources %t.exe | FileCheck %s

# RUN: lld-link /lldmingw /out:%t.exe /entry:main %t.o %t-manifest-lang1.o %t-manifest-lang0.o
# RUN: llvm-readobj --coff-resources %t.exe | FileCheck %s

# RUN: cp %t-manifest-lang0.o %t-manifest-lang0-copy.o
# RUN: lld-link /lldmingw /out:%t.exe /entry:main %t.o %t-manifest-lang0.o %t-manifest-lang0-copy.o %t-manifest-lang1.o
# RUN: llvm-readobj --coff-resources %t.exe | FileCheck %s

# RUN: not lld-link /lldmingw /out:%t.exe /entry:main %t.o %p/Inputs/manifest-lang1.res %p/Inputs/manifest-lang2.res 2>&1 | FileCheck --check-prefix=ERROR %s

# RUN: not lld-link /lldmingw /out:%t.exe /entry:main %t.o %t-manifest-lang1.o %t-manifest-lang2.o 2>&1 | FileCheck --check-prefix=ERROR %s

# CHECK:      Resources [
# CHECK-NEXT:  Total Number of Resources: 1
# CHECK-NEXT:  Base Table Address: 0x
# CHECK-NEXT:  {{ }}
# CHECK-NEXT:   Number of String Entries: 0
# CHECK-NEXT:   Number of ID Entries: 1
# CHECK-NEXT:   Type: MANIFEST (ID 24) [
# CHECK-NEXT:     Table Offset: 0x18
# CHECK-NEXT:     Number of String Entries: 0
# CHECK-NEXT:     Number of ID Entries: 1
# CHECK-NEXT:     Name: (ID 1) [
# CHECK-NEXT:       Table Offset: 0x30
# CHECK-NEXT:       Number of String Entries: 0
# CHECK-NEXT:       Number of ID Entries: 1
# CHECK-NEXT:       Language: (ID 1) [
# CHECK-NEXT:         Entry Offset: 0x48
# CHECK-NEXT:         Time/Date Stamp: 1970-01-01 00:00:00 (0x0)
# CHECK-NEXT:         Major Version: 0
# CHECK-NEXT:         Minor Version: 0
# CHECK-NEXT:         Characteristics: 0
# CHECK-NEXT:         Data [
# CHECK-NEXT:           DataRVA:
# CHECK-NEXT:           DataSize: 14
# CHECK-NEXT:           Codepage: 0
# CHECK-NEXT:           Reserved: 0
# CHECK-NEXT:           Data (
# CHECK-NEXT:             0000: 6D616E69 66657374 2D6C616E 6731      |manifest-lang1|
# CHECK-NEXT:           )
# CHECK-NEXT:         ]
# CHECK-NEXT:       ]
# CHECK-NEXT:     ]
# CHECK-NEXT:   ]
# CHECK-NEXT: ]

# ERROR: error: duplicate non-default manifests with languages 1 in {{.*}}manifest-lang1.{{res|o}} and 2 in {{.*}}manifest-lang2.{{res|o}}