authorgravatar for kubkon@jakubkonka.comJakub Konka <kubkon@jakubkonka.com> 2022-03-27 13:20:06+02:00
committergravatar for kubkon@jakubkonka.comJakub Konka <kubkon@jakubkonka.com> 2022-03-27 13:20:13+02:00
logd15bbebe2e6b8fcbfcd730a6c0d1be621b27045d
tree65e0f49a0665f60dd7b9bd1ca452d2c702a7d850
parent406507c6dcdfff13633f9047549fe1d1f93b6819

macho: do not create dSYM bundle for stage2 LLVM backend

Instead, we fallback to the old-fashioned stabs-based mechanism until I add the missing mechanism for extracting and relocating DWARF from relocatable object files and writing it into a dSYM bundle.

1 files changed, 7 insertions(+), 1 deletions(-)

src/link/MachO.zig+7-1
......@@ -332,7 +332,13 @@ pub fn openPath(allocator: Allocator, options: link.Options) !*MachO {
332332 return self;
333333 }
334334
335 if (!options.strip and options.module != null) {
335 if (!options.strip and options.module != null) blk: {
336 // TODO once I add support for converting (and relocating) DWARF info from relocatable
337 // object files, this check becomes unnecessary.
338 // For now, for LLVM backend we fallback to the old-fashioned stabs approach used by
339 // stage1.
340 if (build_options.have_llvm and options.use_llvm) break :blk;
341
336342 // Create dSYM bundle.
337343 const dir = options.module.?.zig_cache_artifact_directory;
338344 log.debug("creating {s}.dSYM bundle in {s}", .{ emit.sub_path, dir.path });