}
else
s->n_type = BFD_MACH_O_N_SECT;
-
- if (s->symbol.flags & BSF_GLOBAL)
- s->n_type |= BFD_MACH_O_N_EXT;
}
+ /* Update external symbol bit in case objcopy changed it. */
+ if (s->symbol.flags & BSF_GLOBAL)
+ s->n_type |= BFD_MACH_O_N_EXT;
+ else
+ s->n_type &= ~BFD_MACH_O_N_EXT;
+
/* Put the section index in, where required. */
if ((s->symbol.section != bfd_abs_section_ptr
&& s->symbol.section != bfd_und_section_ptr
return NULL;
}
+static bfd_boolean
+bfd_mach_o_fat_close_and_cleanup (bfd *abfd)
+{
+ _bfd_unlink_from_archive_parent (abfd);
+ return TRUE;
+}
+
int
bfd_mach_o_lookup_command (bfd *abfd,
bfd_mach_o_load_command_type type,
/* Not yet handled: creating an archive. */
#define bfd_mach_o_mkarchive _bfd_noarchive_mkarchive
-#define bfd_mach_o_close_and_cleanup _bfd_bool_bfd_true
+#define bfd_mach_o_close_and_cleanup bfd_mach_o_fat_close_and_cleanup
/* Not used. */
#define bfd_mach_o_generic_stat_arch_elt bfd_mach_o_fat_stat_arch_elt