authorgravatar for kubkon@jakubkonka.comJakub Konka <kubkon@jakubkonka.com> 2023-06-20 11:57:44+02:00
committergravatar for kubkon@jakubkonka.comJakub Konka <kubkon@jakubkonka.com> 2023-06-21 00:31:01+02:00
logd2b256711944f75007199ea65141642511b21d8d
tree9b8de290b2aa9b886112bdfccf5c66a3c12cc2d2
parent7b5bd3a93f1c54609cdab19952a6f4b3fc8a20fa

macho: do not skip scanning relocs if the sym is non-extern


1 files changed, 0 insertions(+), 6 deletions(-)

src/link/MachO/ZldAtom.zig-6
...@@ -288,9 +288,6 @@ fn scanAtomRelocsArm64(zld: *Zld, atom_index: AtomIndex, relocs: []align(1) cons...@@ -288,9 +288,6 @@ fn scanAtomRelocsArm64(zld: *Zld, atom_index: AtomIndex, relocs: []align(1) cons
288 .sym_index = sym_index,288 .sym_index = sym_index,
289 .file = atom.file,289 .file = atom.file,
290 };290 };
291 const sym = zld.getSymbol(sym_loc);
292
293 if (sym.sect() and !sym.ext()) continue;
294291
295 const target = if (object.getGlobal(sym_index)) |global_index|292 const target = if (object.getGlobal(sym_index)) |global_index|
296 zld.globals.items[global_index]293 zld.globals.items[global_index]
...@@ -337,9 +334,6 @@ fn scanAtomRelocsX86(zld: *Zld, atom_index: AtomIndex, relocs: []align(1) const...@@ -337,9 +334,6 @@ fn scanAtomRelocsX86(zld: *Zld, atom_index: AtomIndex, relocs: []align(1) const
337 .sym_index = sym_index,334 .sym_index = sym_index,
338 .file = atom.file,335 .file = atom.file,
339 };336 };
340 const sym = zld.getSymbol(sym_loc);
341
342 if (sym.sect() and !sym.ext()) continue;
343337
344 const target = if (object.getGlobal(sym_index)) |global_index|338 const target = if (object.getGlobal(sym_index)) |global_index|
345 zld.globals.items[global_index]339 zld.globals.items[global_index]