| ... | @@ -922,7 +922,10 @@ pub fn create(gpa: *Allocator, options: InitOptions) !*Compilation { | ... | @@ -922,7 +922,10 @@ pub fn create(gpa: *Allocator, options: InitOptions) !*Compilation { |
| 922 | try comp.work_queue.writeItem(.libcxx); | 922 | try comp.work_queue.writeItem(.libcxx); |
| 923 | try comp.work_queue.writeItem(.libcxxabi); | 923 | try comp.work_queue.writeItem(.libcxxabi); |
| 924 | } | 924 | } |
| 925 | if (is_exe_or_dyn_lib and build_options.is_stage1) { | 925 | |
| | 926 | const needs_compiler_rt_and_c = is_exe_or_dyn_lib or |
| | 927 | (comp.getTarget().isWasm() and comp.bin_file.options.output_mode != .Obj); |
| | 928 | if (needs_compiler_rt_and_c and build_options.is_stage1) { |
| 926 | try comp.work_queue.writeItem(.{ .libcompiler_rt = {} }); | 929 | try comp.work_queue.writeItem(.{ .libcompiler_rt = {} }); |
| 927 | if (!comp.bin_file.options.link_libc) { | 930 | if (!comp.bin_file.options.link_libc) { |
| 928 | try comp.work_queue.writeItem(.{ .zig_libc = {} }); | 931 | try comp.work_queue.writeItem(.{ .zig_libc = {} }); |