/* If we are performing a relocatable link, we don't need to do a
thing. The caller will take care of adjusting the reloc
addresses and symbol indices. */
- if (info->relocatable)
+ if (bfd_link_relocatable (info))
return TRUE;
rel = relocs;
|| info->strip == strip_some)
o->lineno_count += sec->lineno_count;
- if (info->relocatable)
+ if (bfd_link_relocatable (info))
o->reloc_count += sec->reloc_count;
if (sec->rawsize > max_contents_size)
if (sec->reloc_count > max_reloc_count)
max_reloc_count = sec->reloc_count;
}
- else if (info->relocatable
+ else if (bfd_link_relocatable (info)
&& (p->type == bfd_section_reloc_link_order
|| p->type == bfd_symbol_reloc_link_order))
++o->reloc_count;
/* If doing a relocatable link, allocate space for the pointers we
need to keep. */
- if (info->relocatable)
+ if (bfd_link_relocatable (info))
{
unsigned int i;
memory until the end of the link. This wastes memory,
but only when doing a relocatable link, which is not the
common case. */
- BFD_ASSERT (info->relocatable);
+ BFD_ASSERT (bfd_link_relocatable (info));
amt = o->reloc_count;
amt *= sizeof (struct internal_reloc);
flaginfo.section_info[o->target_index].relocs =
flaginfo.linenos = (bfd_byte *) bfd_malloc (amt);
flaginfo.contents = (bfd_byte *) bfd_malloc (max_contents_size);
flaginfo.external_relocs = (bfd_byte *) bfd_malloc (max_reloc_count * relsz);
- if (! info->relocatable)
+ if (! bfd_link_relocatable (info))
{
amt = max_reloc_count * sizeof (struct internal_reloc);
flaginfo.internal_relocs = (struct internal_reloc *) bfd_malloc (amt);
|| (flaginfo.linenos == NULL && max_lineno_count > 0)
|| (flaginfo.contents == NULL && max_contents_size > 0)
|| (flaginfo.external_relocs == NULL && max_reloc_count > 0)
- || (! info->relocatable
+ || (! bfd_link_relocatable (info)
&& flaginfo.internal_relocs == NULL
&& max_reloc_count > 0))
goto error_return;
flaginfo.outsyms = NULL;
}
- if (info->relocatable)
+ if (bfd_link_relocatable (info))
{
/* Now that we have written out all the global symbols, we know
the symbol indices to use for relocs against them, and we can