mirror of
https://github.com/ziglang/zig.git
synced 2026-01-02 03:25:01 +00:00
zld: add temp debug info fix by setting mtime=0
This commit is contained in:
parent
b03983b450
commit
b00d08b667
@ -208,14 +208,13 @@ pub fn parseObject(self: Archive, offset: u32) !Object {
|
||||
|
||||
const object_name = try parseName(self.allocator, object_header, reader);
|
||||
defer self.allocator.free(object_name);
|
||||
const object_basename = std.fs.path.basename(object_name);
|
||||
|
||||
log.debug("extracting object '{s}' from archive '{s}'", .{ object_basename, self.name.? });
|
||||
log.debug("extracting object '{s}' from archive '{s}'", .{ object_name, self.name.? });
|
||||
|
||||
const name = name: {
|
||||
var buffer: [std.fs.MAX_PATH_BYTES]u8 = undefined;
|
||||
const path = try std.os.realpath(self.name.?, &buffer);
|
||||
break :name try std.fmt.allocPrint(self.allocator, "{s}({s})", .{ path, object_basename });
|
||||
break :name try std.fmt.allocPrint(self.allocator, "{s}({s})", .{ path, object_name });
|
||||
};
|
||||
|
||||
var object = Object.init(self.allocator);
|
||||
|
||||
@ -2627,7 +2627,7 @@ fn writeDebugInfo(self: *Zld) !void {
|
||||
.n_type = macho.N_OSO,
|
||||
.n_sect = 0,
|
||||
.n_desc = 1,
|
||||
.n_value = tu_mtime,
|
||||
.n_value = 0, //tu_mtime, TODO figure out why precalculated mtime value doesn't work
|
||||
});
|
||||
|
||||
for (object.stabs.items) |stab| {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user