summaryrefslogtreecommitdiff
path: root/bfd/mach-o.c
diff options
context:
space:
mode:
authorTristan Gingold <gingold@adacore.com>2011-12-05 14:42:30 +0000
committerTristan Gingold <gingold@adacore.com>2011-12-05 14:42:30 +0000
commitd8d20093face5426f1d73a8c6880051492885444 (patch)
tree33cf8ad4343fcad265bcfda24e4118d27d92d11a /bfd/mach-o.c
parentbe333d448f62122d51e6c4ae414b036ead2002a6 (diff)
downloadbinutils-redhat-d8d20093face5426f1d73a8c6880051492885444.tar.gz
2011-12-05 Tristan Gingold <gingold@adacore.com>
* mach-o.c (bfd_mach_o_read_symtab_symbol): Accept indirect symbols.
Diffstat (limited to 'bfd/mach-o.c')
-rw-r--r--bfd/mach-o.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/bfd/mach-o.c b/bfd/mach-o.c
index 4412b0b98b..04c971e47f 100644
--- a/bfd/mach-o.c
+++ b/bfd/mach-o.c
@@ -1901,10 +1901,12 @@ bfd_mach_o_read_symtab_symbol (bfd *abfd,
}
break;
case BFD_MACH_O_N_INDR:
- (*_bfd_error_handler) (_("bfd_mach_o_read_symtab_symbol: "
- "symbol \"%s\" is unsupported 'indirect' reference: setting to undefined"),
- s->symbol.name);
- s->symbol.section = bfd_und_section_ptr;
+ /* FIXME: we don't follow the BFD convention as this indirect symbol
+ won't be followed by the referenced one. This looks harmless
+ unless we start using the linker. */
+ s->symbol.flags |= BSF_INDIRECT;
+ s->symbol.section = bfd_ind_section_ptr;
+ s->symbol.value = 0;
break;
default:
(*_bfd_error_handler) (_("bfd_mach_o_read_symtab_symbol: "