1 # RUN: sed -e s/ENTRYNAME/main/ %s | yaml2obj > %t.obj
2 # RUN: lld-link /out:%t.exe %t.obj
3 # RUN: llvm-readobj --file-headers %t.exe | FileCheck -check-prefix=MAIN %s
4 # RUN: lld-link /out:%t.exe %t.obj /subsystem:default,6.0
5 # RUN: llvm-readobj --file-headers %t.exe | FileCheck -check-prefix=MAIN %s
7 # RUN: sed s/ENTRYNAME/wmain/ %s | yaml2obj > %t.obj
8 # RUN: lld-link /out:%t.exe %t.obj
9 # RUN: llvm-readobj --file-headers %t.exe | FileCheck -check-prefix=WMAIN %s
11 # RUN: sed s/ENTRYNAME/WinMain/ %s | yaml2obj > %t.obj
12 # RUN: lld-link /out:%t.exe %t.obj
13 # RUN: llvm-readobj --file-headers %t.exe | FileCheck -check-prefix=WINMAIN %s
14 # RUN: lld-link /out:%t.exe %t.obj /subsystem:default,6.0
15 # RUN: llvm-readobj --file-headers %t.exe | FileCheck -check-prefix=WINMAIN %s
17 # RUN: sed s/ENTRYNAME/wWinMain/ %s | yaml2obj > %t.obj
18 # RUN: lld-link /out:%t.exe %t.obj
19 # RUN: llvm-readobj --file-headers %t.exe | FileCheck -check-prefix=WWINMAIN %s
21 # MAIN: Subsystem: IMAGE_SUBSYSTEM_WINDOWS_CUI
22 # WMAIN: Subsystem: IMAGE_SUBSYSTEM_WINDOWS_CUI
23 # WINMAIN: Subsystem: IMAGE_SUBSYSTEM_WINDOWS_GUI
24 # WWINMAIN: Subsystem: IMAGE_SUBSYSTEM_WINDOWS_GUI
28 Machine: IMAGE_FILE_MACHINE_AMD64
32 Characteristics: [ IMAGE_SCN_CNT_CODE, IMAGE_SCN_MEM_EXECUTE, IMAGE_SCN_MEM_READ ]
34 SectionData: B82A000000C3
39 SimpleType: IMAGE_SYM_TYPE_NULL
40 ComplexType: IMAGE_SYM_DTYPE_NULL
41 StorageClass: IMAGE_SYM_CLASS_STATIC
44 NumberOfRelocations: 0
45 NumberOfLinenumbers: 0
51 SimpleType: IMAGE_SYM_TYPE_NULL
52 ComplexType: IMAGE_SYM_DTYPE_NULL
53 StorageClass: IMAGE_SYM_CLASS_EXTERNAL
54 - Name: mainCRTStartup
57 SimpleType: IMAGE_SYM_TYPE_NULL
58 ComplexType: IMAGE_SYM_DTYPE_NULL
59 StorageClass: IMAGE_SYM_CLASS_EXTERNAL
60 - Name: wmainCRTStartup
63 SimpleType: IMAGE_SYM_TYPE_NULL
64 ComplexType: IMAGE_SYM_DTYPE_NULL
65 StorageClass: IMAGE_SYM_CLASS_EXTERNAL
66 - Name: WinMainCRTStartup
69 SimpleType: IMAGE_SYM_TYPE_NULL
70 ComplexType: IMAGE_SYM_DTYPE_NULL
71 StorageClass: IMAGE_SYM_CLASS_EXTERNAL
72 - Name: wWinMainCRTStartup
75 SimpleType: IMAGE_SYM_TYPE_NULL
76 ComplexType: IMAGE_SYM_DTYPE_NULL
77 StorageClass: IMAGE_SYM_CLASS_EXTERNAL