(wild_doit): Rename to lang_add_section.
This commit is contained in:
parent
16bad250ba
commit
39dcfe18ca
10
ld/ChangeLog
10
ld/ChangeLog
@ -1,3 +1,13 @@
|
|||||||
|
2001-08-14 Alan Modra <amodra@bigpond.net.au>
|
||||||
|
|
||||||
|
* ldlang.c (wild_doit): Rename to lang_add_section.
|
||||||
|
* ldlang.h: Here too.
|
||||||
|
* mpw-elfmips.c: And here.
|
||||||
|
* emultempl/beos.em: And here.
|
||||||
|
* emultempl/elf32.em: And here.
|
||||||
|
* emultempl/hppaelf.em: And here.
|
||||||
|
* emultempl/pe.em: And here.
|
||||||
|
|
||||||
2001-08-13 Richard Henderson <rth@redhat.com>
|
2001-08-13 Richard Henderson <rth@redhat.com>
|
||||||
|
|
||||||
* emultempl/needrelax.em: New file.
|
* emultempl/needrelax.em: New file.
|
||||||
|
@ -7,7 +7,8 @@ else
|
|||||||
fi
|
fi
|
||||||
cat >e${EMULATION_NAME}.c <<EOF
|
cat >e${EMULATION_NAME}.c <<EOF
|
||||||
/* This file is part of GLD, the Gnu Linker.
|
/* This file is part of GLD, the Gnu Linker.
|
||||||
Copyright 1995, 1996, 1997, 1998, 2000 Free Software Foundation, Inc.
|
Copyright 1995, 1996, 1997, 1998, 2000, 2001
|
||||||
|
Free Software Foundation, Inc.
|
||||||
|
|
||||||
This program is free software; you can redistribute it and/or modify
|
This program is free software; you can redistribute it and/or modify
|
||||||
it under the terms of the GNU General Public License as published by
|
it under the terms of the GNU General Public License as published by
|
||||||
@ -813,7 +814,7 @@ gld${EMULATION_NAME}_place_orphan (file, s)
|
|||||||
The sections still have to be sorted, but that has to wait until
|
The sections still have to be sorted, but that has to wait until
|
||||||
all such sections have been processed by us. The sorting is done by
|
all such sections have been processed by us. The sorting is done by
|
||||||
sort_sections. */
|
sort_sections. */
|
||||||
wild_doit (&l->wild_statement.children, s, os, file);
|
lang_add_section (&l->wild_statement.children, s, os, file);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -1085,7 +1085,7 @@ gld${EMULATION_NAME}_place_orphan (file, s)
|
|||||||
{
|
{
|
||||||
/* We already have an output section statement with this
|
/* We already have an output section statement with this
|
||||||
name, and its bfd section, if any, has compatible flags. */
|
name, and its bfd section, if any, has compatible flags. */
|
||||||
wild_doit (&os->children, s, os, file);
|
lang_add_section (&os->children, s, os, file);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1100,7 +1100,7 @@ gld${EMULATION_NAME}_place_orphan (file, s)
|
|||||||
&& strncmp (secname, ".gnu.warning.", sizeof ".gnu.warning." - 1) == 0
|
&& strncmp (secname, ".gnu.warning.", sizeof ".gnu.warning." - 1) == 0
|
||||||
&& hold_text.os != NULL)
|
&& hold_text.os != NULL)
|
||||||
{
|
{
|
||||||
wild_doit (&hold_text.os->children, s, hold_text.os, file);
|
lang_add_section (&hold_text.os->children, s, hold_text.os, file);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1205,7 +1205,7 @@ gld${EMULATION_NAME}_place_orphan (file, s)
|
|||||||
(etree_type *) NULL,
|
(etree_type *) NULL,
|
||||||
(etree_type *) NULL);
|
(etree_type *) NULL);
|
||||||
|
|
||||||
wild_doit (&os->children, s, os, file);
|
lang_add_section (&os->children, s, os, file);
|
||||||
|
|
||||||
lang_leave_output_section_statement
|
lang_leave_output_section_statement
|
||||||
((bfd_vma) 0, "*default*",
|
((bfd_vma) 0, "*default*",
|
||||||
|
@ -258,7 +258,7 @@ hppaelf_add_stub_section (stub_sec_name, input_section)
|
|||||||
|
|
||||||
info.input_section = input_section;
|
info.input_section = input_section;
|
||||||
lang_list_init (&info.add);
|
lang_list_init (&info.add);
|
||||||
wild_doit (&info.add, stub_sec, os, stub_file);
|
lang_add_section (&info.add, stub_sec, os, stub_file);
|
||||||
|
|
||||||
if (info.add.head == NULL)
|
if (info.add.head == NULL)
|
||||||
goto err_ret;
|
goto err_ret;
|
||||||
|
@ -9,7 +9,7 @@ rm -f e${EMULATION_NAME}.c
|
|||||||
(echo;echo;echo;echo;echo)>e${EMULATION_NAME}.c # there, now line numbers match ;-)
|
(echo;echo;echo;echo;echo)>e${EMULATION_NAME}.c # there, now line numbers match ;-)
|
||||||
cat >>e${EMULATION_NAME}.c <<EOF
|
cat >>e${EMULATION_NAME}.c <<EOF
|
||||||
/* This file is part of GLD, the Gnu Linker.
|
/* This file is part of GLD, the Gnu Linker.
|
||||||
Copyright 1995, 1996, 1997, 1998, 1999, 2000
|
Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001
|
||||||
Free Software Foundation, Inc.
|
Free Software Foundation, Inc.
|
||||||
|
|
||||||
This program is free software; you can redistribute it and/or modify
|
This program is free software; you can redistribute it and/or modify
|
||||||
@ -1458,7 +1458,7 @@ gld_${EMULATION_NAME}_place_orphan (file, s)
|
|||||||
&& os->bfd_section != NULL
|
&& os->bfd_section != NULL
|
||||||
&& ((s->flags ^ os->bfd_section->flags) & (SEC_LOAD | SEC_ALLOC)) == 0)
|
&& ((s->flags ^ os->bfd_section->flags) & (SEC_LOAD | SEC_ALLOC)) == 0)
|
||||||
{
|
{
|
||||||
wild_doit (&add_child, s, os, file);
|
lang_add_section (&add_child, s, os, file);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -1562,7 +1562,7 @@ gld_${EMULATION_NAME}_place_orphan (file, s)
|
|||||||
(etree_type *) NULL,
|
(etree_type *) NULL,
|
||||||
(etree_type *) NULL);
|
(etree_type *) NULL);
|
||||||
|
|
||||||
wild_doit (&add_child, s, os, file);
|
lang_add_section (&add_child, s, os, file);
|
||||||
|
|
||||||
lang_leave_output_section_statement
|
lang_leave_output_section_statement
|
||||||
((bfd_vma) 0, "*default*",
|
((bfd_vma) 0, "*default*",
|
||||||
|
34
ld/ldlang.c
34
ld/ldlang.c
@ -1012,11 +1012,11 @@ section_already_linked (abfd, sec, data)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Set the output_section field so that wild_doit does not
|
/* Set the output_section field so that lang_add_section
|
||||||
create a lang_input_section structure for this section.
|
does not create a lang_input_section structure for this
|
||||||
Since there might be a symbol in the section being
|
section. Since there might be a symbol in the section
|
||||||
discarded, we must retain a pointer to the section which
|
being discarded, we must retain a pointer to the section
|
||||||
we are really going to use. */
|
which we are really going to use. */
|
||||||
sec->output_section = bfd_abs_section_ptr;
|
sec->output_section = bfd_abs_section_ptr;
|
||||||
sec->kept_section = l->sec;
|
sec->kept_section = l->sec;
|
||||||
|
|
||||||
@ -1098,7 +1098,7 @@ wildcardp (pattern)
|
|||||||
input file which holds SECTION. */
|
input file which holds SECTION. */
|
||||||
|
|
||||||
void
|
void
|
||||||
wild_doit (ptr, section, output, file)
|
lang_add_section (ptr, section, output, file)
|
||||||
lang_statement_list_type *ptr;
|
lang_statement_list_type *ptr;
|
||||||
asection *section;
|
asection *section;
|
||||||
lang_output_section_statement_type *output;
|
lang_output_section_statement_type *output;
|
||||||
@ -1372,18 +1372,18 @@ output_section_callback (ptr, sec, section, file, output)
|
|||||||
of the current list. */
|
of the current list. */
|
||||||
|
|
||||||
if (before == NULL)
|
if (before == NULL)
|
||||||
wild_doit (&ptr->children, section,
|
lang_add_section (&ptr->children, section,
|
||||||
(lang_output_section_statement_type *) output,
|
(lang_output_section_statement_type *) output,
|
||||||
file);
|
file);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
lang_statement_list_type list;
|
lang_statement_list_type list;
|
||||||
lang_statement_union_type **pp;
|
lang_statement_union_type **pp;
|
||||||
|
|
||||||
lang_list_init (&list);
|
lang_list_init (&list);
|
||||||
wild_doit (&list, section,
|
lang_add_section (&list, section,
|
||||||
(lang_output_section_statement_type *) output,
|
(lang_output_section_statement_type *) output,
|
||||||
file);
|
file);
|
||||||
|
|
||||||
/* If we are discarding the section, LIST.HEAD will
|
/* If we are discarding the section, LIST.HEAD will
|
||||||
be NULL. */
|
be NULL. */
|
||||||
@ -3739,18 +3739,18 @@ lang_place_orphans ()
|
|||||||
lang_output_section_statement_lookup (".bss");
|
lang_output_section_statement_lookup (".bss");
|
||||||
|
|
||||||
}
|
}
|
||||||
wild_doit (&default_common_section->children, s,
|
lang_add_section (&default_common_section->children, s,
|
||||||
default_common_section, file);
|
default_common_section, file);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (ldemul_place_orphan (file, s))
|
else if (ldemul_place_orphan (file, s))
|
||||||
;
|
;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
lang_output_section_statement_type *os =
|
lang_output_section_statement_type *os;
|
||||||
lang_output_section_statement_lookup (s->name);
|
|
||||||
|
|
||||||
wild_doit (&os->children, s, os, file);
|
os = lang_output_section_statement_lookup (s->name);
|
||||||
|
lang_add_section (&os->children, s, os, file);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -444,7 +444,7 @@ extern bfd_vma lang_size_sections
|
|||||||
bfd_vma dot, boolean relax));
|
bfd_vma dot, boolean relax));
|
||||||
extern void lang_enter_group PARAMS ((void));
|
extern void lang_enter_group PARAMS ((void));
|
||||||
extern void lang_leave_group PARAMS ((void));
|
extern void lang_leave_group PARAMS ((void));
|
||||||
extern void wild_doit
|
extern void lang_add_section
|
||||||
PARAMS ((lang_statement_list_type *ptr, asection *section,
|
PARAMS ((lang_statement_list_type *ptr, asection *section,
|
||||||
lang_output_section_statement_type *output,
|
lang_output_section_statement_type *output,
|
||||||
lang_input_statement_type *file));
|
lang_input_statement_type *file));
|
||||||
|
@ -605,7 +605,7 @@ gldelf32ebmip_place_orphan (file, s)
|
|||||||
if (hold_use != NULL)
|
if (hold_use != NULL)
|
||||||
{
|
{
|
||||||
/* We have already placed a section with this name. */
|
/* We have already placed a section with this name. */
|
||||||
wild_doit (&hold_use->children, s, hold_use, file);
|
lang_add_section (&hold_use->children, s, hold_use, file);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -618,7 +618,7 @@ gldelf32ebmip_place_orphan (file, s)
|
|||||||
&& strncmp (secname, ".gnu.warning.", sizeof ".gnu.warning." - 1) == 0
|
&& strncmp (secname, ".gnu.warning.", sizeof ".gnu.warning." - 1) == 0
|
||||||
&& hold_text != NULL)
|
&& hold_text != NULL)
|
||||||
{
|
{
|
||||||
wild_doit (&hold_text->children, s, hold_text, file);
|
lang_add_section (&hold_text->children, s, hold_text, file);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -693,7 +693,7 @@ gldelf32ebmip_place_orphan (file, s)
|
|||||||
(etree_type *) NULL);
|
(etree_type *) NULL);
|
||||||
|
|
||||||
os = lang_output_section_statement_lookup (secname);
|
os = lang_output_section_statement_lookup (secname);
|
||||||
wild_doit (&os->children, s, os, file);
|
lang_add_section (&os->children, s, os, file);
|
||||||
|
|
||||||
lang_leave_output_section_statement
|
lang_leave_output_section_statement
|
||||||
((bfd_vma) 0, "*default*",
|
((bfd_vma) 0, "*default*",
|
||||||
|
Loading…
Reference in New Issue
Block a user