| ... | @@ -472,9 +472,12 @@ pub fn create(gpa: *Allocator, options: InitOptions) !*Compilation { | ... | @@ -472,9 +472,12 @@ pub fn create(gpa: *Allocator, options: InitOptions) !*Compilation { |
| 472 | break :blk false; | 472 | break :blk false; |
| 473 | }; | 473 | }; |
| 474 | | 474 | |
| 475 | const syslibroot = if (build_options.have_llvm and use_lld and options.is_native_os and options.target.isDarwin()) blk: { | 475 | const syslibroot = if (build_options.have_llvm and comptime std.Target.current.isDarwin()) outer: { |
| 476 | const syslibroot_path = try std.zig.system.getSDKPath(arena); | 476 | const path = if (use_lld and options.is_native_os and options.target.isDarwin()) inner: { |
| 477 | break :blk syslibroot_path; | 477 | const syslibroot_path = try std.zig.system.getSDKPath(arena); |
| | 478 | break :inner syslibroot_path; |
| | 479 | } else null; |
| | 480 | break :outer path; |
| 478 | } else null; | 481 | } else null; |
| 479 | | 482 | |
| 480 | const link_libc = options.link_libc or target_util.osRequiresLibC(options.target); | 483 | const link_libc = options.link_libc or target_util.osRequiresLibC(options.target); |