|
30 | 30 |
|
31 | 31 | # Minimal subset of targets used by CI systems to build enough to be useful
|
32 | 32 | MINIMAL_TASKS = [
|
33 |
| - 'libbulkmemory', |
34 |
| - 'libcompiler_rt', |
35 |
| - 'libcompiler_rt-wasm-sjlj', |
36 |
| - 'libcompiler_rt-ww', |
37 |
| - 'libc', |
38 |
| - 'libc-debug', |
39 |
| - 'libc-ww-debug', |
40 |
| - 'libc_optz', |
41 |
| - 'libc_optz-debug', |
42 |
| - 'libc++abi', |
43 |
| - 'libc++abi-except', |
44 |
| - 'libc++abi-noexcept', |
45 |
| - 'libc++abi-debug', |
46 |
| - 'libc++abi-debug-except', |
47 |
| - 'libc++abi-debug-noexcept', |
48 |
| - 'libc++abi-debug-ww-noexcept', |
49 |
| - 'libc++', |
50 |
| - 'libc++-except', |
51 |
| - 'libc++-noexcept', |
52 |
| - 'libc++-ww-noexcept', |
53 |
| - 'libal', |
54 |
| - 'libdlmalloc', |
55 |
| - 'libdlmalloc-tracing', |
56 |
| - 'libdlmalloc-debug', |
57 |
| - 'libdlmalloc-ww', |
58 |
| - 'libembind', |
59 |
| - 'libembind-rtti', |
60 |
| - 'libemmalloc', |
61 |
| - 'libemmalloc-debug', |
62 |
| - 'libemmalloc-memvalidate', |
63 |
| - 'libemmalloc-verbose', |
64 |
| - 'libemmalloc-memvalidate-verbose', |
65 |
| - 'libmimalloc', |
66 |
| - 'libmimalloc-mt', |
67 |
| - 'libGL', |
68 |
| - 'libGL-getprocaddr', |
69 |
| - 'libGL-emu-getprocaddr', |
70 |
| - 'libGL-emu-webgl2-ofb-getprocaddr', |
71 |
| - 'libGL-webgl2-ofb-getprocaddr', |
72 |
| - 'libGL-ww-getprocaddr', |
73 |
| - 'libhtml5', |
74 |
| - 'libsockets', |
75 |
| - 'libsockets-ww', |
76 |
| - 'libstubs', |
77 |
| - 'libstubs-debug', |
78 |
| - 'libstandalonewasm-nocatch', |
79 |
| - 'crt1', |
80 |
| - 'crt1_proxy_main', |
81 |
| - 'crtbegin', |
82 |
| - 'libunwind-except', |
83 |
| - 'libnoexit', |
84 |
| - 'sqlite3', |
85 |
| - 'sqlite3-mt', |
86 |
| - 'libwebgpu', |
87 |
| - 'libwebgpu_cpp', |
| 33 | + 'libbulkmemory', |
| 34 | + 'libcompiler_rt', |
| 35 | + 'libcompiler_rt-wasm-sjlj', |
| 36 | + 'libcompiler_rt-ww', |
| 37 | + 'libc', |
| 38 | + 'libc-debug', |
| 39 | + 'libc-ww-debug', |
| 40 | + 'libc_optz', |
| 41 | + 'libc_optz-debug', |
| 42 | + 'libc++abi', |
| 43 | + 'libc++abi-except', |
| 44 | + 'libc++abi-noexcept', |
| 45 | + 'libc++abi-debug', |
| 46 | + 'libc++abi-debug-except', |
| 47 | + 'libc++abi-debug-noexcept', |
| 48 | + 'libc++abi-debug-ww-noexcept', |
| 49 | + 'libc++', |
| 50 | + 'libc++-except', |
| 51 | + 'libc++-noexcept', |
| 52 | + 'libc++-ww-noexcept', |
| 53 | + 'libal', |
| 54 | + 'libdlmalloc', |
| 55 | + 'libdlmalloc-tracing', |
| 56 | + 'libdlmalloc-debug', |
| 57 | + 'libdlmalloc-ww', |
| 58 | + 'libembind', |
| 59 | + 'libembind-rtti', |
| 60 | + 'libemmalloc', |
| 61 | + 'libemmalloc-debug', |
| 62 | + 'libemmalloc-memvalidate', |
| 63 | + 'libemmalloc-verbose', |
| 64 | + 'libemmalloc-memvalidate-verbose', |
| 65 | + 'libmimalloc', |
| 66 | + 'libmimalloc-mt', |
| 67 | + 'libGL', |
| 68 | + 'libGL-getprocaddr', |
| 69 | + 'libGL-emu-getprocaddr', |
| 70 | + 'libGL-emu-webgl2-ofb-getprocaddr', |
| 71 | + 'libGL-webgl2-ofb-getprocaddr', |
| 72 | + 'libGL-ww-getprocaddr', |
| 73 | + 'libhtml5', |
| 74 | + 'libsockets', |
| 75 | + 'libsockets-ww', |
| 76 | + 'libstubs', |
| 77 | + 'libstubs-debug', |
| 78 | + 'libstandalonewasm-nocatch', |
| 79 | + 'crt1', |
| 80 | + 'crt1_proxy_main', |
| 81 | + 'crtbegin', |
| 82 | + 'libunwind-except', |
| 83 | + 'libnoexit', |
| 84 | + 'sqlite3', |
| 85 | + 'sqlite3-mt', |
| 86 | + 'libwebgpu', |
| 87 | + 'libwebgpu_cpp', |
88 | 88 | ]
|
89 | 89 |
|
90 | 90 | # Additional tasks on top of MINIMAL_TASKS that are necessary for PIC testing on
|
91 | 91 | # CI (which has slightly more tests than other modes that want to use MINIMAL)
|
92 | 92 | MINIMAL_PIC_TASKS = MINIMAL_TASKS + [
|
93 |
| - 'libcompiler_rt-mt', |
94 |
| - 'libc-mt', |
95 |
| - 'libc-mt-debug', |
96 |
| - 'libc_optz-mt', |
97 |
| - 'libc_optz-mt-debug', |
98 |
| - 'libc++abi-mt', |
99 |
| - 'libc++abi-mt-noexcept', |
100 |
| - 'libc++abi-debug-mt', |
101 |
| - 'libc++abi-debug-mt-noexcept', |
102 |
| - 'libc++-mt', |
103 |
| - 'libc++-mt-noexcept', |
104 |
| - 'libdlmalloc-mt', |
105 |
| - 'libGL-emu', |
106 |
| - 'libGL-emu-webgl2-getprocaddr', |
107 |
| - 'libGL-mt-getprocaddr', |
108 |
| - 'libGL-mt-emu', |
109 |
| - 'libGL-mt-emu-webgl2-getprocaddr', |
110 |
| - 'libGL-mt-emu-webgl2-ofb-getprocaddr', |
111 |
| - 'libsockets_proxy', |
112 |
| - 'libsockets-mt', |
113 |
| - 'crtbegin', |
114 |
| - 'libsanitizer_common_rt', |
115 |
| - 'libubsan_rt', |
116 |
| - 'libwasm_workers-debug-stub', |
117 |
| - 'libfetch', |
118 |
| - 'libfetch-mt', |
119 |
| - 'libwasmfs', |
120 |
| - 'libwasmfs-debug', |
121 |
| - 'libwasmfs_no_fs', |
122 |
| - 'giflib', |
| 93 | + 'libcompiler_rt-mt', |
| 94 | + 'libc-mt', |
| 95 | + 'libc-mt-debug', |
| 96 | + 'libc_optz-mt', |
| 97 | + 'libc_optz-mt-debug', |
| 98 | + 'libc++abi-mt', |
| 99 | + 'libc++abi-mt-noexcept', |
| 100 | + 'libc++abi-debug-mt', |
| 101 | + 'libc++abi-debug-mt-noexcept', |
| 102 | + 'libc++-mt', |
| 103 | + 'libc++-mt-noexcept', |
| 104 | + 'libdlmalloc-mt', |
| 105 | + 'libGL-emu', |
| 106 | + 'libGL-emu-webgl2-getprocaddr', |
| 107 | + 'libGL-mt-getprocaddr', |
| 108 | + 'libGL-mt-emu', |
| 109 | + 'libGL-mt-emu-webgl2-getprocaddr', |
| 110 | + 'libGL-mt-emu-webgl2-ofb-getprocaddr', |
| 111 | + 'libsockets_proxy', |
| 112 | + 'libsockets-mt', |
| 113 | + 'crtbegin', |
| 114 | + 'libsanitizer_common_rt', |
| 115 | + 'libubsan_rt', |
| 116 | + 'libwasm_workers-debug-stub', |
| 117 | + 'libfetch', |
| 118 | + 'libfetch-mt', |
| 119 | + 'libwasmfs', |
| 120 | + 'libwasmfs-debug', |
| 121 | + 'libwasmfs_no_fs', |
| 122 | + 'giflib', |
123 | 123 | ]
|
124 | 124 |
|
125 | 125 | PORTS = sorted(list(ports.ports_by_name.keys()) + list(ports.port_variants.keys()))
|
@@ -187,19 +187,17 @@ def handle_port_error(target, message):
|
187 | 187 | def main():
|
188 | 188 | all_build_start_time = time.time()
|
189 | 189 |
|
190 |
| - parser = argparse.ArgumentParser(description=__doc__, |
191 |
| - formatter_class=argparse.RawDescriptionHelpFormatter, |
192 |
| - epilog=get_help()) |
| 190 | + parser = argparse.ArgumentParser( |
| 191 | + description=__doc__, formatter_class=argparse.RawDescriptionHelpFormatter, epilog=get_help() |
| 192 | + ) |
193 | 193 | parser.add_argument('--lto', action='store_const', const='full', help='build bitcode object for LTO')
|
194 |
| - parser.add_argument('--lto=thin', dest='lto', action='store_const', const='thin', help='build bitcode object for ThinLTO') |
195 |
| - parser.add_argument('--pic', action='store_true', |
196 |
| - help='build relocatable objects for suitable for dynamic linking') |
197 |
| - parser.add_argument('--force', action='store_true', |
198 |
| - help='force rebuild of target (by removing it first)') |
199 |
| - parser.add_argument('--verbose', action='store_true', |
200 |
| - help='show build commands') |
201 |
| - parser.add_argument('--wasm64', action='store_true', |
202 |
| - help='use wasm64 architecture') |
| 194 | + parser.add_argument( |
| 195 | + '--lto=thin', dest='lto', action='store_const', const='thin', help='build bitcode object for ThinLTO' |
| 196 | + ) |
| 197 | + parser.add_argument('--pic', action='store_true', help='build relocatable objects for suitable for dynamic linking') |
| 198 | + parser.add_argument('--force', action='store_true', help='force rebuild of target (by removing it first)') |
| 199 | + parser.add_argument('--verbose', action='store_true', help='show build commands') |
| 200 | + parser.add_argument('--wasm64', action='store_true', help='use wasm64 architecture') |
203 | 201 | parser.add_argument('operation', choices=['build', 'clear', 'rebuild'])
|
204 | 202 | parser.add_argument('targets', nargs='*', help='see below')
|
205 | 203 | args = parser.parse_args()
|
@@ -240,7 +238,7 @@ def main():
|
240 | 238 |
|
241 | 239 | # process tasks
|
242 | 240 | auto_tasks = False
|
243 |
| - task_targets = dict.fromkeys(args.targets) # use dict to keep targets order |
| 241 | + task_targets = dict.fromkeys(args.targets) # use dict to keep targets order |
244 | 242 |
|
245 | 243 | # substitute
|
246 | 244 | predefined_tasks = {
|
@@ -315,14 +313,28 @@ def main():
|
315 | 313 | return 1
|
316 | 314 |
|
317 | 315 | time_taken = time.time() - start_time
|
318 |
| - logger.info('...success. Took %s(%.2fs)' % (('%02d:%02d mins ' % (time_taken // 60, time_taken % 60) if time_taken >= 60 else ''), time_taken)) |
| 316 | + logger.info( |
| 317 | + '...success. Took %s(%.2fs)' |
| 318 | + % (('%02d:%02d mins ' % (time_taken // 60, time_taken % 60) if time_taken >= 60 else ''), time_taken) |
| 319 | + ) |
319 | 320 |
|
320 | 321 | if USE_NINJA and args.operation != 'clear':
|
321 | 322 | system_libs.build_deferred()
|
322 | 323 |
|
323 | 324 | if len(tasks) > 1 or USE_NINJA:
|
324 | 325 | all_build_time_taken = time.time() - all_build_start_time
|
325 |
| - logger.info('Built %d targets in %s(%.2fs)' % (len(tasks), ('%02d:%02d mins ' % (all_build_time_taken // 60, all_build_time_taken % 60) if all_build_time_taken >= 60 else ''), all_build_time_taken)) |
| 326 | + logger.info( |
| 327 | + 'Built %d targets in %s(%.2fs)' |
| 328 | + % ( |
| 329 | + len(tasks), |
| 330 | + ( |
| 331 | + '%02d:%02d mins ' % (all_build_time_taken // 60, all_build_time_taken % 60) |
| 332 | + if all_build_time_taken >= 60 |
| 333 | + else '' |
| 334 | + ), |
| 335 | + all_build_time_taken, |
| 336 | + ) |
| 337 | + ) |
326 | 338 |
|
327 | 339 | return 0
|
328 | 340 |
|
|
0 commit comments