mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-07-02 02:45:37 +08:00
* ldlang.c (lang_size_sections): Clarify error message when user
specified start addr conflicts with region. Fix resetting of region pointer.
This commit is contained in:
@ -1,3 +1,9 @@
|
|||||||
|
Tue Jan 31 16:20:52 1995 Doug Evans <dje@canuck.cygnus.com>
|
||||||
|
|
||||||
|
* ldlang.c (lang_size_sections): Clarify error message when user
|
||||||
|
specified start addr conflicts with region. Fix resetting of
|
||||||
|
region pointer.
|
||||||
|
|
||||||
Tue Jan 31 12:37:09 1995 Ian Lance Taylor <ian@cygnus.com>
|
Tue Jan 31 12:37:09 1995 Ian Lance Taylor <ian@cygnus.com>
|
||||||
|
|
||||||
* ldexp.c (fold_name): In case NAME, permit an absolute symbol
|
* ldexp.c (fold_name): In case NAME, permit an absolute symbol
|
||||||
|
62
ld/ldlang.c
62
ld/ldlang.c
@ -1,5 +1,5 @@
|
|||||||
/* Linker command language support.
|
/* Linker command language support.
|
||||||
Copyright (C) 1991, 92, 93, 94 Free Software Foundation, Inc.
|
Copyright (C) 1991, 92, 93, 94, 1995 Free Software Foundation, Inc.
|
||||||
|
|
||||||
This file is part of GLD, the Gnu Linker.
|
This file is part of GLD, the Gnu Linker.
|
||||||
|
|
||||||
@ -1779,28 +1779,35 @@ lang_size_sections (s, output_section_statement, prev, fill, dot, relax)
|
|||||||
|
|
||||||
/* Replace into region ? */
|
/* Replace into region ? */
|
||||||
if (os->region != (lang_memory_region_type *) NULL)
|
if (os->region != (lang_memory_region_type *) NULL)
|
||||||
{
|
{
|
||||||
os->region->current = dot;
|
os->region->current = dot;
|
||||||
/* Make sure this isn't silly */
|
/* Make sure this isn't silly. */
|
||||||
if (( os->region->current
|
if ((os->region->current < os->region->origin)
|
||||||
> os->region->origin + os->region->length)
|
|| (os->region->current
|
||||||
|| ( os->region->origin > os->region->current ))
|
> os->region->origin + os->region->length))
|
||||||
{
|
{
|
||||||
einfo ("%X%P: region %s is full (%B section %s)\n",
|
if (os->addr_tree != (etree_type *) NULL)
|
||||||
os->region->name,
|
{
|
||||||
os->bfd_section->owner,
|
einfo ("%X%P: address 0x%v of %B section %s is not within region %s\n",
|
||||||
os->bfd_section->name);
|
os->region->current,
|
||||||
/* Reset the region pointer */
|
os->bfd_section->owner,
|
||||||
os->region->current = 0;
|
os->bfd_section->name,
|
||||||
|
os->region->name);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
}
|
{
|
||||||
|
einfo ("%X%P: region %s is full (%B section %s)\n",
|
||||||
|
os->region->name,
|
||||||
|
os->bfd_section->owner,
|
||||||
|
os->bfd_section->name);
|
||||||
|
}
|
||||||
|
/* Reset the region pointer. */
|
||||||
|
os->region->current = os->region->origin;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
break;
|
||||||
|
|
||||||
break;
|
|
||||||
case lang_constructors_statement_enum:
|
case lang_constructors_statement_enum:
|
||||||
dot = lang_size_sections (constructor_list.head,
|
dot = lang_size_sections (constructor_list.head,
|
||||||
output_section_statement,
|
output_section_statement,
|
||||||
@ -2294,9 +2301,6 @@ lang_place_orphans ()
|
|||||||
{
|
{
|
||||||
asection *s;
|
asection *s;
|
||||||
|
|
||||||
if (file->just_syms_flag)
|
|
||||||
continue;
|
|
||||||
|
|
||||||
for (s = file->the_bfd->sections;
|
for (s = file->the_bfd->sections;
|
||||||
s != (asection *) NULL;
|
s != (asection *) NULL;
|
||||||
s = s->next)
|
s = s->next)
|
||||||
@ -2306,7 +2310,15 @@ lang_place_orphans ()
|
|||||||
/* This section of the file is not attatched, root
|
/* This section of the file is not attatched, root
|
||||||
around for a sensible place for it to go */
|
around for a sensible place for it to go */
|
||||||
|
|
||||||
if (file->common_section == s)
|
if (file->just_syms_flag)
|
||||||
|
{
|
||||||
|
/* We are only retrieving symbol values from this
|
||||||
|
file. We want the symbols to act as though the
|
||||||
|
values in the file are absolute. */
|
||||||
|
s->output_section = bfd_abs_section_ptr;
|
||||||
|
s->output_offset = s->vma;
|
||||||
|
}
|
||||||
|
else if (file->common_section == s)
|
||||||
{
|
{
|
||||||
/* This is a lonely common section which must
|
/* This is a lonely common section which must
|
||||||
have come from an archive. We attatch to the
|
have come from an archive. We attatch to the
|
||||||
|
Reference in New Issue
Block a user