input file basename is crt0.o only once. */
if (silence_segment_error == 1)
silence_segment_error =
- (strlen (input_bfd->filename) == 6
- && filename_cmp (input_bfd->filename, "crt0.o") == 0)
- || (strlen (input_bfd->filename) > 6
- && filename_cmp (input_bfd->filename
- + strlen (input_bfd->filename) - 7,
+ (strlen (bfd_get_filename (input_bfd)) == 6
+ && filename_cmp (bfd_get_filename (input_bfd), "crt0.o") == 0)
+ || (strlen (bfd_get_filename (input_bfd)) > 6
+ && filename_cmp (bfd_get_filename (input_bfd)
+ + strlen (bfd_get_filename (input_bfd)) - 7,
"/crt0.o") == 0)
? -1 : 0;
#endif
flagword old_flags, new_flags;
bfd_boolean error = FALSE;
+ /* FIXME: What should be checked when linking shared libraries? */
+ if ((ibfd->flags & DYNAMIC) != 0)
+ return TRUE;
+
new_flags = elf_elfheader (ibfd)->e_flags;
old_flags = elf_elfheader (obfd)->e_flags;
strncpy ((char *) p + 4, targetsec->output_section->name, 8);
}
- if (isymbuf != NULL && symtab_hdr->contents != (unsigned char *) isymbuf)
+ if (symtab_hdr->contents != (unsigned char *) isymbuf)
free (isymbuf);
- if (internal_relocs != NULL
- && elf_section_data (datasec)->relocs != internal_relocs)
+ if (elf_section_data (datasec)->relocs != internal_relocs)
free (internal_relocs);
return TRUE;
error_return:
- if (isymbuf != NULL && symtab_hdr->contents != (unsigned char *) isymbuf)
+ if (symtab_hdr->contents != (unsigned char *) isymbuf)
free (isymbuf);
- if (internal_relocs != NULL
- && elf_section_data (datasec)->relocs != internal_relocs)
+ if (elf_section_data (datasec)->relocs != internal_relocs)
free (internal_relocs);
return FALSE;
}