diff options
author | Alexandre Oliva <aoliva@redhat.com> | 2003-11-27 16:43:25 +0000 |
---|---|---|
committer | Alexandre Oliva <aoliva@redhat.com> | 2003-11-27 16:43:25 +0000 |
commit | c84fca4d1870f863ff0eeafed3cfc34bc9041851 (patch) | |
tree | 38ac73189c8ef837e02a61d448af9a8573052157 /bfd | |
parent | 13739f4d37e1ffa9021c2ea87e8e81cca67ed615 (diff) | |
download | gdb-c84fca4d1870f863ff0eeafed3cfc34bc9041851.zip gdb-c84fca4d1870f863ff0eeafed3cfc34bc9041851.tar.gz gdb-c84fca4d1870f863ff0eeafed3cfc34bc9041851.tar.bz2 |
* elf-bfd.h (elf_backend_data::elf_backend_modify_segment_map):
Add link info argument.
* elf32-i370.c (elf_backend_modify_segment_map): Likewise.
* elf32-ppc.c (ppc_elf_modify_segment_map): Likewise.
* elf32-xtensa.c (elf_xtensa_modify_segment_map): Likewise.
* elf64-hppa.c (elf64_hppa_modify_segment_map): Likewise.
* elfxx-ia64.c (elfNN_ia64_modify_segment_map): Likewise.
* elfxx-mips.c (_bfd_mips_elf_modify_segment_map): Likewise.
* elfxx-mips.h (_bfd_mips_elf_modify_segment_map): Likewise.
* elf.c (assign_file_positions_except_relocs,
assign_file_positions_for_segments): Likewise. Adjust calls.
Diffstat (limited to 'bfd')
-rw-r--r-- | bfd/ChangeLog | 14 | ||||
-rw-r--r-- | bfd/elf-bfd.h | 2 | ||||
-rw-r--r-- | bfd/elf.c | 13 | ||||
-rw-r--r-- | bfd/elf32-i370.c | 2 | ||||
-rw-r--r-- | bfd/elf32-ppc.c | 3 | ||||
-rw-r--r-- | bfd/elf32-xtensa.c | 5 | ||||
-rw-r--r-- | bfd/elf64-hppa.c | 5 | ||||
-rw-r--r-- | bfd/elfxx-ia64.c | 5 | ||||
-rw-r--r-- | bfd/elfxx-mips.c | 3 | ||||
-rw-r--r-- | bfd/elfxx-mips.h | 2 |
10 files changed, 37 insertions, 17 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog index feec9c6..9b717d5 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,17 @@ +2003-11-27 Alexandre Oliva <aoliva@redhat.com> + + * elf-bfd.h (elf_backend_data::elf_backend_modify_segment_map): + Add link info argument. + * elf32-i370.c (elf_backend_modify_segment_map): Likewise. + * elf32-ppc.c (ppc_elf_modify_segment_map): Likewise. + * elf32-xtensa.c (elf_xtensa_modify_segment_map): Likewise. + * elf64-hppa.c (elf64_hppa_modify_segment_map): Likewise. + * elfxx-ia64.c (elfNN_ia64_modify_segment_map): Likewise. + * elfxx-mips.c (_bfd_mips_elf_modify_segment_map): Likewise. + * elfxx-mips.h (_bfd_mips_elf_modify_segment_map): Likewise. + * elf.c (assign_file_positions_except_relocs, + assign_file_positions_for_segments): Likewise. Adjust calls. + 2003-11-27 Mark Kettenis <kettenis@gnu.org> * elf.c (elfcore_grok_netbsd_procinfo): Make a pseudosection out diff --git a/bfd/elf-bfd.h b/bfd/elf-bfd.h index 5cb7efa..b4db281 100644 --- a/bfd/elf-bfd.h +++ b/bfd/elf-bfd.h @@ -760,7 +760,7 @@ struct elf_backend_data /* This function is called to modify an existing segment map in a backend specific fashion. */ bfd_boolean (*elf_backend_modify_segment_map) - (bfd *); + (bfd *, struct bfd_link_info *); /* This function is called during section gc to discover the section a particular relocation refers to. */ @@ -41,7 +41,7 @@ #include "libiberty.h" static int elf_sort_sections (const void *, const void *); -static bfd_boolean assign_file_positions_except_relocs (bfd *); +static bfd_boolean assign_file_positions_except_relocs (bfd *, struct bfd_link_info *); static bfd_boolean prep_headers (bfd *); static bfd_boolean swap_out_syms (bfd *, struct bfd_strtab_hash **, int) ; static bfd_boolean elfcore_read_notes (bfd *, file_ptr, bfd_size_type) ; @@ -3103,7 +3103,7 @@ _bfd_elf_compute_section_file_positions (bfd *abfd, /* sh_offset is set in assign_file_positions_except_relocs. */ shstrtab_hdr->sh_addralign = 1; - if (!assign_file_positions_except_relocs (abfd)) + if (!assign_file_positions_except_relocs (abfd, link_info)) return FALSE; if (link_info == NULL && bfd_get_symcount (abfd) > 0) @@ -3576,7 +3576,7 @@ elf_sort_sections (const void *arg1, const void *arg2) the file header, and writes out the program headers. */ static bfd_boolean -assign_file_positions_for_segments (bfd *abfd) +assign_file_positions_for_segments (bfd *abfd, struct bfd_link_info *link_info) { const struct elf_backend_data *bed = get_elf_backend_data (abfd); unsigned int count; @@ -3628,7 +3628,7 @@ assign_file_positions_for_segments (bfd *abfd) if (bed->elf_backend_modify_segment_map) { - if (! (*bed->elf_backend_modify_segment_map) (abfd)) + if (! (*bed->elf_backend_modify_segment_map) (abfd, link_info)) return FALSE; } @@ -4136,7 +4136,8 @@ get_program_header_size (bfd *abfd) We also don't set the positions of the .symtab and .strtab here. */ static bfd_boolean -assign_file_positions_except_relocs (bfd *abfd) +assign_file_positions_except_relocs (bfd *abfd, + struct bfd_link_info *link_info) { struct elf_obj_tdata * const tdata = elf_tdata (abfd); Elf_Internal_Ehdr * const i_ehdrp = elf_elfheader (abfd); @@ -4187,7 +4188,7 @@ assign_file_positions_except_relocs (bfd *abfd) /* Assign file positions for the loaded sections based on the assignment of sections to segments. */ - if (! assign_file_positions_for_segments (abfd)) + if (! assign_file_positions_for_segments (abfd, link_info)) return FALSE; /* Assign file positions for the other sections. */ diff --git a/bfd/elf32-i370.c b/bfd/elf32-i370.c index 83783ae..a844277 100644 --- a/bfd/elf32-i370.c +++ b/bfd/elf32-i370.c @@ -1555,6 +1555,6 @@ static int i370_noop () #define elf_backend_additional_program_headers \ (int (*) PARAMS ((bfd *))) i370_noop #define elf_backend_modify_segment_map \ - (bfd_boolean (*) PARAMS ((bfd *))) i370_noop + (bfd_boolean (*) PARAMS ((bfd *, struct bfd_link_info *))) i370_noop #include "elf32-target.h" diff --git a/bfd/elf32-ppc.c b/bfd/elf32-ppc.c index c7d48aa..9dcc2ea 100644 --- a/bfd/elf32-ppc.c +++ b/bfd/elf32-ppc.c @@ -2739,7 +2739,8 @@ ppc_elf_additional_program_headers (bfd *abfd) /* Modify the segment map if needed. */ static bfd_boolean -ppc_elf_modify_segment_map (bfd *abfd ATTRIBUTE_UNUSED) +ppc_elf_modify_segment_map (bfd *abfd ATTRIBUTE_UNUSED, + struct bfd_link_info *info ATTRIBUTE_UNUSED) { return TRUE; } diff --git a/bfd/elf32-xtensa.c b/bfd/elf32-xtensa.c index cec239e..05d071d 100644 --- a/bfd/elf32-xtensa.c +++ b/bfd/elf32-xtensa.c @@ -60,7 +60,7 @@ static bfd_boolean elf_xtensa_adjust_dynamic_symbol static bfd_boolean elf_xtensa_size_dynamic_sections PARAMS ((bfd *, struct bfd_link_info *)); static bfd_boolean elf_xtensa_modify_segment_map - PARAMS ((bfd *)); + PARAMS ((bfd *, struct bfd_link_info *)); static bfd_boolean elf_xtensa_relocate_section PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *, Elf_Internal_Rela *, Elf_Internal_Sym *, asection **)); @@ -1415,8 +1415,9 @@ elf_xtensa_size_dynamic_sections (output_bfd, info) this and it probably ought to be moved into elf.c as well. */ static bfd_boolean -elf_xtensa_modify_segment_map (abfd) +elf_xtensa_modify_segment_map (abfd, info) bfd *abfd; + struct bfd_link_info *info ATTRIBUTE_UNUSED; { struct elf_segment_map **m_p; diff --git a/bfd/elf64-hppa.c b/bfd/elf64-hppa.c index 294d643..6ef19c0 100644 --- a/bfd/elf64-hppa.c +++ b/bfd/elf64-hppa.c @@ -213,7 +213,7 @@ static int elf64_hppa_additional_program_headers PARAMS ((bfd *)); static bfd_boolean elf64_hppa_modify_segment_map - PARAMS ((bfd *)); + PARAMS ((bfd *, struct bfd_link_info *)); static enum elf_reloc_type_class elf64_hppa_reloc_type_class PARAMS ((const Elf_Internal_Rela *)); @@ -2609,8 +2609,9 @@ elf64_hppa_additional_program_headers (abfd) existence of a .interp section. */ static bfd_boolean -elf64_hppa_modify_segment_map (abfd) +elf64_hppa_modify_segment_map (abfd, info) bfd *abfd; + struct bfd_link_info *info ATTRIBUTE_UNUSED; { struct elf_segment_map *m; asection *s; diff --git a/bfd/elfxx-ia64.c b/bfd/elfxx-ia64.c index 5ff5740..af2bc26 100644 --- a/bfd/elfxx-ia64.c +++ b/bfd/elfxx-ia64.c @@ -194,7 +194,7 @@ static bfd_boolean elfNN_ia64_add_symbol_hook static int elfNN_ia64_additional_program_headers PARAMS ((bfd *abfd)); static bfd_boolean elfNN_ia64_modify_segment_map - PARAMS ((bfd *)); + PARAMS ((bfd *, struct bfd_link_info *)); static bfd_boolean elfNN_ia64_is_local_label_name PARAMS ((bfd *abfd, const char *name)); static bfd_boolean elfNN_ia64_dynamic_symbol_p @@ -1405,8 +1405,9 @@ elfNN_ia64_additional_program_headers (abfd) } static bfd_boolean -elfNN_ia64_modify_segment_map (abfd) +elfNN_ia64_modify_segment_map (abfd, info) bfd *abfd; + struct bfd_link_info *info ATTRIBUTE_UNUSED; { struct elf_segment_map *m, **pm; Elf_Internal_Shdr *hdr; diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c index 0c94909..685f79b 100644 --- a/bfd/elfxx-mips.c +++ b/bfd/elfxx-mips.c @@ -7308,8 +7308,9 @@ _bfd_mips_elf_additional_program_headers (abfd) /* Modify the segment map for an IRIX5 executable. */ bfd_boolean -_bfd_mips_elf_modify_segment_map (abfd) +_bfd_mips_elf_modify_segment_map (abfd, info) bfd *abfd; + struct bfd_link_info *info ATTRIBUTE_UNUSED; { asection *s; struct elf_segment_map *m, **pm; diff --git a/bfd/elfxx-mips.h b/bfd/elfxx-mips.h index b4230eb..924ca53 100644 --- a/bfd/elfxx-mips.h +++ b/bfd/elfxx-mips.h @@ -62,7 +62,7 @@ extern void _bfd_mips_elf_final_write_processing extern int _bfd_mips_elf_additional_program_headers PARAMS ((bfd *)); extern bfd_boolean _bfd_mips_elf_modify_segment_map - PARAMS ((bfd *)); + PARAMS ((bfd *, struct bfd_link_info *)); extern asection * _bfd_mips_elf_gc_mark_hook PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *, struct elf_link_hash_entry *, Elf_Internal_Sym *)); |