2006-04-06 Carlos O'Donell <carlos@codesourcery.com>
[deliverable/binutils-gdb.git] / bfd / ChangeLog
1 2006-04-06 Carlos O'Donell <carlos@codesourcery.com>
2
3 * po/Make-in: Add install-html target.
4 * Makefile.am: Rename docdir to bfddocdir. Add datarootdir, docdir
5 htmldir. Add install-html and install-html-recursive targets.
6 * Makefile.in: Regenerate.
7 * configure.in: AC_SUBST for datarootdir, docdir and htmldir.
8 * configure: Regenerate.
9
10 2006-04-06 H.J. Lu <hongjiu.lu@intel.com>
11
12 * elfxx-ia64.c (elfNN_ia64_relax_section): Skip unneeded passes
13 with the skip_relax_pass_0 and skip_relax_pass_1 bits in the
14 section structure.
15
16 2006-04-05 Bernd Schmidt <bernd.schmidt@analog.com>
17
18 * elf32-bfin.c (bfinfdpic_relocs_info_hash): Sprinkle casts to
19 eliminate warnings.
20
21 2006-04-05 H.J. Lu <hongjiu.lu@intel.com>
22 James E Wilson <wilson@specifixinc.com>
23
24 PR ld/2442
25 * elfxx-ia64.c (elfNN_ia64_dyn_sym_info): Remove next.
26 (elfNN_ia64_local_hash_entry): Add count, sorted_count and
27 size.
28 (elfNN_ia64_link_hash_entry): Likewise.
29 (elfNN_ia64_new_elf_hash_entry): Initialize count, sorted_count
30 and size.
31 (elfNN_ia64_hash_copy_indirect): Updated elfNN_ia64_dyn_sym_info
32 processing.
33 (elfNN_ia64_hash_hide_symbol): Likewise.
34 (elfNN_ia64_global_dyn_sym_thunk): Likewise.
35 (elfNN_ia64_local_dyn_sym_thunk): Likewise.
36 (elfNN_ia64_global_dyn_info_free): New function.
37 (elfNN_ia64_local_dyn_info_free): Likewise.
38 (elfNN_ia64_hash_table_free): Free local and global
39 elfNN_ia64_dyn_sym_info.
40 (addend_compare): New function.
41 (sort_dyn_sym_info): Likewise.
42 (get_dyn_sym_info): Updated to use binary search for addend.
43 (elfNN_ia64_check_relocs): Scan relocations to create dynamic
44 relocation arrays first.
45
46 2006-04-05 Bernd Schmidt <bernd.schmidt@analog.com>
47
48 * elf32-bfin.c (_bfin_create_got_section): Don't generate a _gp
49 symbol.
50
51 2006-04-05 H.J. Lu <hongjiu.lu@intel.com>
52
53 PR ld/2411
54 * elflink.c (check_dynsym): New.
55 (elf_link_output_extsym): Use it.
56 (bfd_elf_final_link): Likewise.
57
58 2006-04-05 H.J. Lu <hongjiu.lu@intel.com>
59
60 PR ld/2404
61 * elflink.c (_bfd_elf_merge_symbol): Skip the default indirect
62 symbol from the dynamic definition with the default version if
63 its type and the type of existing regular definition mismatch.
64
65 2006-04-05 Richard Sandiford <richard@codesourcery.com>
66 Daniel Jacobowitz <dan@codesourcery.com>
67
68 * config.bfd (sparc-*-vxworks*): New stanza.
69 * configure.in (bfd_elf32_sparc_vxworks_vec): New stanza.
70 (bfd_elf32_sparc_vec, bfd_elf64_sparc_vec): Add elf-vxworks.lo.
71 * configure: Regenerate.
72 * elf32-sparc.c: Include elf-vxworks.h.
73 (elf32_sparc_vxworks_link_hash_table_create: New.
74 (elf32_sparc_vxworks_final_write_processing): New.
75 (TARGET_BIG_SYM): Override for VxWorks.
76 (TARGET_BIG_NAME, ELF_MINPAGESIZE): Likewise.
77 (bfd_elf32_bfd_link_hash_table_create): Likewise.
78 (elf_backend_want_got_plt, elf_backend_plt_readonly): Likewise.
79 (elf_backend_got_header_size, elf_backend_add_symbol_hook): Likewise.
80 (elf_backend_link_output_symbol_hook): Likewise.
81 (elf_backend_emit_relocs): Likewise.
82 (elf_backend_final_write_processing, elf32_bed): Likewise.
83 * elfxx-sparc.c: Include libiberty.h and elf-vxworks.h.
84 (sparc_vxworks_exec_plt0_entry, sparc_vxworks_exec_plt_entry): New.
85 (sparc_vxworks_shared_plt0_entry, sparc_vxworks_shared_plt_entry): New.
86 (_bfd_sparc_elf_link_hash_table_create): Don't initialize
87 build_plt_entry here.
88 (create_got_section): Initialize sgotplt for VxWorks.
89 (_bfd_sparc_elf_create_dynamic_sections): Initialize build_plt_entry,
90 plt_header_size and plt_entry_size, with new VxWorks-specific settings.
91 Call elf_vxworks_create_dynamic_sections for VxWorks.
92 (allocate_dynrelocs): Use plt_header_size and plt_entry_size.
93 Allocate room for .got.plt and .rela.plt.unloaded entries on VxWorks.
94 (_bfd_sparc_elf_size_dynamic_sections): Don't allocate a nop in .plt
95 for VxWorks. Check for the .got.plt section.
96 (sparc_vxworks_build_plt_entry): New function.
97 (_bfd_sparc_elf_finish_dynamic_symbol): Add handling of VxWorks PLTs.
98 Don't make _GLOBAL_OFFSET_TABLE_ and _PROCEDURE_LINKAGE_TABLE_
99 absolute on VxWorks.
100 (sparc32_finish_dyn): Add special handling for DT_RELASZ
101 and DT_PLTGOT on VxWorks.
102 (sparc_vxworks_finish_exec_plt): New.
103 (sparc_vxworks_finish_shared_plt): New.
104 (_bfd_sparc_elf_finish_dynamic_sections): Call them.
105 Use plt_header_size and plt_entry_size.
106 * elfxx-sparc.h (_bfd_sparc_elf_link_hash_table): Add is_vxworks,
107 srelplt2, sgotplt, plt_header_size and plt_entry_size fields.
108 * Makefile.am (elfxx-sparc.lo): Depend on elf-vxworks.h.
109 (elf32-sparc.lo): Likewise.
110 * Makefile.in: Regenerate.
111 * targets.c (bfd_elf32_sparc_vxworks_vec): Declare.
112 (_bfd_target_vector): Add a pointer to it.
113
114 2006-03-30 Ben Elliston <bje@au.ibm.com>
115
116 PR ld/2267
117 * elflink.c (elf_fixup_link_order): Ensure `elfsec' is not a
118 special section number that exceeds the number of ELF sections
119 (eg. SHN_MIPS_SCOMMON).
120
121 2006-03-27 Richard Sandiford <richard@codesourcery.com>
122
123 * elfxx-mips.c (mips_got_entry): Add more commentary.
124 (mips_elf_local_got_index): Use the hash table entry to record
125 the GOT index of forced-local symbols.
126 (mips_elf_initialize_tls_index): Rearrange code. Store the index
127 in either the hash table entry or the mips_got_entry, not both.
128 Add more commentary.
129 (mips_elf_multi_got): Make sure the g->next is nonnull when calling
130 mips_elf_initialize_tls_index.
131
132 2006-03-25 Bernd Schmidt <bernd.schmidt@analog.com>
133
134 * elf32-bfin.c (bfd_const_reloc, bfd_oper_reloc, bfin_push_reloc,
135 RELOC_STACK_SIZE, reloc_stack, reloc_stack_tos, is_reloc_stack_empty,
136 reloc_stack_push, reloc_stack_pop, reloc_stack_operate,
137 bfin_areloc_howto_table): Delete. All
138 uses deleted as well.
139 (bfin_reloc_map): Delete all stack relocs.
140 (bfin_info_to_howto, bfin_bfd_reloc_type_lookup,
141 bfin_reloc_type_lookup): Don't support them.
142 (bfin_relocate_section): Don't try to handle them.
143
144 * config.bfd (bfin-*-*): Add bfd_elf32_bfinfdpic_vec.
145 * configure.in: Likewise.
146 * configure: Regenerate.
147 * elf32-bfin.c: Include "elf/dwarf2.h" and "hashtab.h".
148 (BFIN_RELOC_MAX): Now 0x21.
149 (bfin_howto_table, bfin_reloc_map): Add FD-PIC relocs.
150 (bfd_elf32_bfinfdpic_vec): Declare.
151 (IS_FDPIC): New macro.
152 (struct bfinfdpic_elf_link_hash_table): New struct.
153 (bfinfdpic_hash_table, bfinfdpic_got_section,
154 bfinfdpic_gotrel_section, bfinfdpic_gotfixup_section,
155 bfinfdpic_plt_setion, bfinfdpic_pltrel_section,
156 bfinfdpic_relocs_info, bfinfdpic_got_initial_offset,
157 bfinfdpic_plt_initial_offset): Accessor macros for it.
158 (BFINFDPIC_SYM_LOCAL, BFINFDPIC_FUNCDESC_LOCAL): New macros.
159 (struct bfinfdpic_relocs_info): New struct.
160 (LZPLT_RESOLVER_EXTRA, LZPLT_NORMAL_SIZE, LZPLT_ENTRIES,
161 BFINFDPIC_LZPLT_BLOCK_SIZE, BFINFDPIC_LZPLT_RESOLV_LOC,
162 DEFAULT_STACK_SIZE): New macros.
163 (bfinfdpic_elf_link_hash_table_create, bfinfdpic_relocs_info_hash,
164 bfinfdpic_relocs_info_eq, bfinfdpics_relocs_info_find,
165 bfinfdpic_relocs_info_for_global, bfinfdpic_relocs_info_for_local,
166 bfinfdpic_pic_merge_early_relocs_info, _bfinfdpic_add_dyn_reloc,
167 _bfinfdpic_add_rofixup, _bfinfdpic_osec_to_segment,
168 _bfinfdpic_osec_readonly_p, bfinfdpic_relocate_section,
169 bfinfdpic_check_relocs, bfinfdpic_gc_sweep_hook,
170 _bfinfdpic_link_omit_section_dynsym, _bfin_create_got_section,
171 elf32_bfinfdpic_create_dynamic_sections, _bfinfdpic_get_fd_entry,
172 _bfinfdpic_compute_got_alloc_data, _bfinfdpic_get_got_entry,
173 _bfinfdpic_assign_got_entries, _bfinfdpic_assign_plt_entries,
174 _bfinfdpic_resolve_final_relocs_info,
175 elf32_bfinfdpic_size_dynamic_sections,
176 elf32_bfinfdpic_always_size_sections,
177 elf32_bfinfdpic_modify_segment_map,
178 _bfinfdpic_count_got_plt_entries,
179 elf32_bfinfdpic_finish_dynamic_sections,
180 elf32_bfinfdpic_adjust_dynamic_symbol,
181 elf32_bfinfdpic_finish_dynamic_symbol,
182 elf32_bfinfdpic_elf_use_relative_eh_frame,
183 elf32_bfinfdpic_elf_encode_eh_address,
184 elf32_bfin_object_p, bfin_elf_copy_private_bfd_data,
185 elf32_bfinfdpic_copy_private_bfd_data,
186 (struct _bfinfdpic_dynamic_got_info,
187 struct _bfinfdpic_dynamic_got_plt_info): New structs.
188 (elf32_bfin_print_private_bfd_data): Print PIC flags.
189 (elf32_bfin_merge_private_bfd_data): Extend to support FD-PIC.
190 (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME, elf32_bed,
191 elf_backend_got_header_size, bfd_elf32_bfd_link_hash_table_create,
192 elf_backend_always_size_sectinos, elf_backend_modify_segment_map,
193 bfd_elf32_bfd_copy_private_bfd_data,
194 elf_backend_create_dynamic_sections, elf_backend_adjust_dynamic_symbol,
195 elf_backend_size_dynamic_sections, elf_backend_finish_dynamic_symbol,
196 elf_backend_finish_dynamic_sections, elf_backend_relocate_section,
197 elf_backend_can_make_relative_eh_frame, elf_backend_check_relocs,
198 elf_backend_can_make_ldsa_relative_eh_frame, elf_backend_may_use_rel_p,
199 elf_backend_may_use_rela_p, elf_backend_default_use_rela_p,
200 elf_backend_omit_section_dynsym): Redefine these macros and include
201 "elf32-target.h" again to create the elf32-bfinfdpic target.
202 * reloc.c (BFD_RELOC_BFIN_GOT17M4, BFD_RELOC_BFIN_GOTHI,
203 BFD_RELOC_BFIN_GOTLO, BFD_RELOC_BFIN_FUNCDESC,
204 BFD_RELOC_BFIN_FUNCDESC_GOT17M4, BFD_RELOC_BFIN_FUNCDESC_GOTHI,
205 BFD_RELOC_BFIN_FUNCDESC_GOTLO, BFD_RELOC_BFIN_FUNCDESC_VALUE,
206 BFD_RELOC_BFIN_FUNCDESC_GOTOFF17M4, BFD_RELOC_BFIN_FUNCDESC_GOTOFFHI,
207 BFD_RELOC_BFIN_FUNCDESC_GOTOFFLO, BFD_RELOC_BFIN_GOTOFFHI,
208 BFD_RELOC_BFIN_GOTOFFLO): New.
209 * targets.c (bfd_elf32_bfinfdpic_vec): New bfd_target.
210 (_bfd_target_vector): Add it.
211 * bfd-in2.h: Regenerate.
212 * libbfd.h: Regenerate.
213
214 2006-03-25 Richard Sandiford <richard@codesourcery.com>
215
216 * cpu-m68k.c (bfd_m68k_compatible): Treat ISA A+ and ISA B code as
217 incompatible. Likewise MAC and EMAC code.
218 * elf32-m68k.c (elf32_m68k_merge_private_bfd_data): Use
219 bfd_get_compatible to set the new bfd architecture. Rely on it
220 to detect incompatibilities.
221
222 2006-03-22 Bob Wilson <bob.wilson@acm.org>
223
224 * elf32-xtensa.c (xtensa_read_table_entries): Remove assertion that
225 rel->r_addend is zero.
226
227 2006-03-22 Richard Sandiford <richard@codesourcery.com>
228
229 * elfxx-mips.c (_bfd_mips_vxworks_finish_dynamic_symbol): Fix type
230 of "loc".
231
232 2006-03-22 Richard Sandiford <richard@codesourcery.com>
233 Daniel Jacobowitz <dan@codesourcery.com>
234 Phil Edwards <phil@codesourcery.com>
235 Zack Weinberg <zack@codesourcery.com>
236 Mark Mitchell <mark@codesourcery.com>
237 Nathan Sidwell <nathan@codesourcery.com>
238
239 * bfd-in2.h: Regenerate.
240 * config.bfd (mips*-*-vxworks*, mips*el-*-vxworks*): New stanzas.
241 * configure.in (bfd_elf32_bigmips_vxworks_vec): New stanza.
242 (bfd_elf32_littlemips_vxworks_vec): Likewise.
243 (bfd_elf32_bigmips_vec): Add elf-vxworks.lo.
244 (bfd_elf32_littlemips_vec): Likewise.
245 (bfd_elf32_nbigmips_vec): Likewise.
246 (bfd_elf32_nlittlemips_vec): Likewise.
247 (bfd_elf32_ntradbigmips_vec): Likewise.
248 (bfd_elf32_ntradlittlemips_vec): Likewise.
249 (bfd_elf32_tradbigmips_vec): Likewise.
250 (bfd_elf32_tradlittlemips_vec): Likewise.
251 (bfd_elf64_bigmips_vec): Likewise.
252 (bfd_elf64_littlemips_vec): Likewise.
253 (bfd_elf64_tradbigmips_vec): Likewise.
254 (bfd_elf64_tradlittlemips_vec): Likewise.
255 * elf32-mips.c: Include elf-vxworks.h.
256 (mips_info_to_howto_rel): Use elf_backend_mips_rtype_to_howto
257 instead of calling mips_elf32_rtype_to_howto directly.
258 (mips_vxworks_copy_howto_rela): New reloc howto.
259 (mips_vxworks_jump_slot_howto_rela): Likewise.
260 (mips_vxworks_bfd_reloc_type_lookup): New function.
261 (mips_vxworks_rtype_to_howto): Likewise.
262 (mips_vxworks_final_write_processing): Likewise.
263 (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME): Override for VxWorks.
264 (TARGET_BIG_SYM, TARGET_BIG_NAME, elf_bed, ELF_MAXPAGESIZE): Likewise.
265 (elf_backend_want_got_plt): Likewise.
266 (elf_backend_want_plt_sym): Likewise.
267 (elf_backend_got_symbol_offset): Likewise.
268 (elf_backend_want_dynbss): Likewise.
269 (elf_backend_may_use_rel_p): Likewise.
270 (elf_backend_may_use_rela_p): Likewise.
271 (elf_backend_default_use_rela_p): Likewise.
272 (elf_backend_got_header_size: Likewise.
273 (elf_backend_plt_readonly): Likewise.
274 (bfd_elf32_bfd_reloc_type_lookup): Likewise.
275 (elf_backend_mips_rtype_to_howto): Likewise.
276 (elf_backend_adjust_dynamic_symbol): Likewise.
277 (elf_backend_finish_dynamic_symbol): Likewise.
278 (bfd_elf32_bfd_link_hash_table_create): Likewise.
279 (elf_backend_add_symbol_hook): Likewise.
280 (elf_backend_link_output_symbol_hook): Likewise.
281 (elf_backend_emit_relocs): Likewise.
282 (elf_backend_final_write_processing: Likewise.
283 (elf_backend_additional_program_headers): Likewise.
284 (elf_backend_modify_segment_map): Likewise.
285 (elf_backend_symbol_processing): Likewise.
286 * elfxx-mips.c: Include elf-vxworks.h.
287 (mips_elf_link_hash_entry): Add is_relocation_target and
288 is_branch_target fields.
289 (mips_elf_link_hash_table): Add is_vxworks, srelbss, sdynbss, srelplt,
290 srelplt2, sgotplt, splt, plt_header_size and plt_entry_size fields.
291 (MIPS_ELF_RELA_SIZE, MIPS_ELF_REL_DYN_NAME): New macros.
292 (MIPS_RESERVED_GOTNO): Take a mips_elf_link_hash_table argument.
293 Return 3 for VxWorks.
294 (ELF_MIPS_GP_OFFSET): Change the argument from a bfd to a
295 mips_elf_link_hash_table. Return 0 for VxWorks.
296 (MIPS_ELF_GOT_MAX_SIZE): Change the argument from a bfd to a
297 mips_elf_link_hash_table. Update the call to ELF_MIPS_GP_OFFSET.
298 (mips_vxworks_exec_plt0_entry): New variable.
299 (mips_vxworks_exec_plt_entry): Likewise.
300 (mips_vxworks_shared_plt0_entry): Likewise.
301 (mips_vxworks_shared_plt_entry): Likewise.
302 (mips_elf_link_hash_newfunc): Initialize the new hash_entry fields.
303 (mips_elf_rel_dyn_section): Change the bfd argument to a
304 mips_elf_link_hash_table. Use MIPS_ELF_REL_DYN_NAME to get
305 the name of the section.
306 (mips_elf_initialize_tls_slots): Update the call to
307 mips_elf_rel_dyn_section.
308 (mips_elf_gotplt_index): New function.
309 (mips_elf_local_got_index): Add an input_section argument.
310 Update the call to mips_elf_create_local_got_entry.
311 (mips_elf_got_page): Likewise.
312 (mips_elf_got16_entry): Likewise.
313 (mips_elf_create_local_got_entry): Add bfd_link_info and input_section
314 arguments. Create dynamic relocations for each entry on VxWorks.
315 (mips_elf_merge_gots): Update the use of MIPS_ELF_GOT_MAX_SIZE.
316 (mips_elf_multi_got): Update the uses of MIPS_ELF_GOT_MAX_SIZE
317 and MIPS_RESERVED_GOTNO.
318 (mips_elf_create_got_section): Update the uses of
319 MIPS_ELF_GOT_MAX_SIZE. Create .got.plt on VxWorks.
320 (is_gott_symbol): New function.
321 (mips_elf_calculate_relocation): Use a dynobj local variable.
322 Update the calls to mips_elf_local_got_index, mips_elf_got16_entry and
323 mips_elf_got_page_entry. Set G to the .got.plt entry when calculating
324 VxWorks R_MIPS_CALL* relocations. Calculate and use G for all GOT
325 relocations on VxWorks. Add dynamic relocations for references
326 to the VxWorks __GOTT_BASE__ and __GOTT_INDEX__ symbols. Don't
327 create dynamic relocations for R_MIPS_32, R_MIPS_REL32 or R_MIPS_64
328 in VxWorks executables.
329 (mips_elf_allocate_dynamic_relocations): Add a bfd_link_info argument.
330 Use MIPS_ELF_RELA_SIZE to calculate the size of a VxWorks entry.
331 Don't allocate a null entry on VxWorks.
332 (mips_elf_create_dynamic_relocation): Update the call to
333 mips_elf_rel_dyn_section. Use absolute rather than relative
334 relocations for VxWorks, and make them RELA rather than REL.
335 (_bfd_mips_elf_create_dynamic_sections): Don't make .dynamic
336 read-only on VxWorks. Update the call to mips_elf_rel_dyn_section.
337 Create the .plt, .rela.plt, .dynbss and .rela.bss sections on
338 VxWorks. Likewise create the _PROCEDURE_LINKAGE_TABLE symbol.
339 Call elf_vxworks_create_dynamic_sections for VxWorks and
340 initialize the plt_header_size and plt_entry_size fields.
341 (_bfd_mips_elf_check_relocs): Don't allow GOT relocations to be
342 used in VxWorks executables. Don't allocate dynamic relocations
343 for R_MIPS_32, R_MIPS_REL32 or R_MIPS_64 in VxWorks executables.
344 Set is_relocation_target for each symbol referenced by a relocation.
345 Allocate .rela.dyn entries for relocations against the special
346 VxWorks __GOTT_BASE__ and __GOTT_INDEX__ symbols. Create GOT
347 entries for all VxWorks R_MIPS_GOT16 relocations. Don't allocate
348 a global GOT entry for symbols mentioned in VxWorks R_MIPS_CALL*,
349 R_MIPS_32, R_MIPS_REL32 or R_MIPS_64 relocations. Update the calls
350 to mips_elf_rel_dyn_section and mips_elf_allocate_dynamic_relocations.
351 Set is_branch_target for symbols mentioned in R_MIPS_PC16 or R_MIPS_26
352 relocations. Don't set no_fn_stub on VxWorks.
353 (_bfd_mips_elf_adjust_dynamic_symbol): Update the call to
354 mips_elf_allocate_dynamic_relocations.
355 (_bfd_mips_vxworks_adjust_dynamic_symbol): New function.
356 (_bfd_mips_elf_always_size_sections): Do not allocate GOT page
357 entries for VxWorks, and do not create multiple GOTs.
358 (_bfd_mips_elf_size_dynamic_sections): Use MIPS_ELF_REL_DYN_NAME.
359 Handle .got specially for VxWorks. Update the uses of
360 MIPS_RESERVED_GOTNO and mips_elf_allocate_dynamic_relocations.
361 Check for sgotplt and splt. Allocate the .rel(a).dyn contents last,
362 once its final size is known. Set DF_TEXTREL for VxWorks. Add
363 DT_RELA, DT_RELASZ, DT_RELAENT, DT_PLTREL, DT_PLTRELSZ and DT_JMPREL
364 tags on VxWorks. Do not add the MIPS-specific tags for VxWorks.
365 (_bfd_mips_vxworks_finish_dynamic_symbol): New function.
366 (mips_vxworks_finish_exec_plt): Likewise.
367 (mips_vxworks_finish_shared_plt): Likewise.
368 (_bfd_mips_elf_finish_dynamic_sections): Remove an unncessary call
369 to mips_elf_rel_dyn_section. Use a VxWorks-specific value of
370 DT_PLTGOT. Handle DT_RELA, DT_RELASZ, DT_RELAENT, DT_PLTREL,
371 DT_PLTRELSZ and DT_JMPREL. Update the uses of MIPS_RESERVED_GOTNO
372 and mips_elf_rel_dyn_section. Use a different GOT header for
373 VxWorks. Don't sort .rela.dyn on VxWorks. Finish the PLT on VxWorks.
374 (_bfd_mips_elf_link_hash_table_create): Initialize the new
375 mips_elf_link_hash_table fields.
376 (_bfd_mips_vxworks_link_hash_table_create): New function.
377 (_bfd_mips_elf_final_link): Set the GP value to _GLOBAL_OFFSET_TABLE_
378 on VxWorks. Update the call to ELF_MIPS_GP_OFFSET.
379 * elfxx-mips.h (_bfd_mips_vxworks_adjust_dynamic_symbol): Declare.
380 (_bfd_mips_vxworks_finish_dynamic_symbol): Likewise.
381 (_bfd_mips_vxworks_link_hash_table_create): Likewise.
382 * libbfd.h: Regenerate.
383 * Makefile.am (elfxx-mips.lo): Depend on elf-vxworks.h.
384 (elf32-mips.lo): Likewise.
385 * Makefile.in: Regenerate.
386 * reloc.c (BFD_RELOC_MIPS_COPY, BFD_RELOC_MIPS_JUMP_SLOT): Declare.
387 * targets.c (bfd_elf32_bigmips_vxworks_vec): Declare.
388 (bfd_elf32_littlemips_vxworks_vec): Likewise.
389 (_bfd_target_vector): Add entries for them.
390
391 2006-03-19 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
392
393 * elf64-hppa.c (elf64_hppa_special_sections): Change flags for .tbss
394 section from SHF_PARISC_WEAKORDER to SHF_HP_TLS.
395 (elf_backend_special_sections): Remove #undef.
396
397 2006-03-18 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
398
399 * elf64-hppa.c (allocate_global_data_opd): Don't create an OPD entry
400 for undefined weak symbols.
401
402 2006-03-17 Daniel Jacobowitz <dan@codesourcery.com>
403
404 PR ld/2462
405 * elflink.c (bfd_elf_final_link): Remove
406 bed->elf_backend_emit_relocs from emit_relocs.
407
408 2006-03-17 Alexandre Oliva <aoliva@redhat.com>
409
410 * elf32-ppc.c (ppc_elf_relocate_section): Copy addend from
411 first relocation to the second when relaxing TLS GD to LE;
412 zero it out when relaxing to IE.
413
414 2006-03-17 Alan Modra <amodra@bigpond.net.au>
415
416 PR 2434
417 * elflink.c (elf_link_add_object_symbols): Save and restore
418 warning sym's linked sym.
419
420 2006-03-16 Alan Modra <amodra@bigpond.net.au>
421
422 PR 2434
423 * elflink.c (struct elf_smash_syms_data, elf_smash_syms): Delete.
424 (elf_link_add_object_symbols): Delete unnecessary locals. Rename
425 hash_table -> htab. Formatting. Save entire symbol table
426 before loading as-needed syms, and restore afterwards if lib not
427 needed. Use bfd_hash_allocate rather than bfd_alloc for sym
428 name. Free some buffers earlier.
429 * bfd-in.h (struct bfd_hash_table): Add entsize.
430 (bfd_hash_table_init, bfd_hash_table_init_n): Adjust prototype.
431 * elf-bfd.h (_bfd_elf_link_hash_table_init): Likewise
432 * hash.c (bfd_hash_table_init_n): Add entsize param, save to
433 hash table.
434 (bfd_hash_table_init): Add param, adjust calls.
435 * aoutx.h: Adjust all hash_table_init functions and calls.
436 * bfd.c: Likewise.
437 * coff-arm.c: Likewise.
438 * coff-h8300.c: Likewise.
439 * coff-ppc.c: Likewise.
440 * cofflink.c: Likewise.
441 * ecoff.c: Likewise.
442 * ecofflink.c: Likewise.
443 * elf-m10300.c: Likewise.
444 * elf-strtab.c: Likewise.
445 * elf.c: Likewise.
446 * elf32-arm.c: Likewise.
447 * elf32-bfin.c: Likewise.
448 * elf32-cris.c: Likewise.
449 * elf32-frv.c: Likewise.
450 * elf32-hppa.c: Likewise.
451 * elf32-i386.c: Likewise.
452 * elf32-m32r.c: Likewise.
453 * elf32-m68hc1x.c: Likewise.
454 * elf32-m68k.c: Likewise.
455 * elf32-ppc.c: Likewise.
456 * elf32-s390.c: Likewise.
457 * elf32-sh.c: Likewise.
458 * elf32-vax.c: Likewise.
459 * elf64-alpha.c: Likewise.
460 * elf64-hppa.c: Likewise.
461 * elf64-ppc.c: Likewise.
462 * elf64-s390.c: Likewise.
463 * elf64-sh64.c: Likewise.
464 * elf64-x86-64.c: Likewise.
465 * elfxx-ia64.c: Likewise.
466 * elfxx-mips.c: Likewise.
467 * elfxx-sparc.c: Likewise.
468 * i386linux.c: Likewise.
469 * libaout.h: Likewise.
470 * libbfd-in.h: Likewise.
471 * libcoff-in.h: Likewise.
472 * linker.c: Likewise.
473 * m68klinux.c: Likewise.
474 * merge.c: Likewise.
475 * opncls.c: Likewise.
476 * pdp11.c: Likewise.
477 * sparclinux.c: Likewise.
478 * stabs.c: Likewise.
479 * sunos.c: Likewise.
480 * vms.c: Likewise.
481 * xcofflink.c: Likewise.
482 * section.c (struct section_hash_entry): Move to..
483 * libbfd-in.h: ..here.
484 * Makefile.am: Run "make dep-am"
485 * Makefile.in: Regenerate.
486 * bfd-in2.h: Regenerate.
487 * libbfd.h: Regenerate.
488 * libcoff.h: Regenerate.
489
490 2006-03-16 Alan Modra <amodra@bigpond.net.au>
491
492 * elf32-ppc.c (ppc_elf_check_relocs): REL24 and REL14 relocs
493 against __GLOBAL_OFFSET_TABLE__ need never be dynamic. Tweak
494 last change to REL32 relocs so that they are counted as
495 possibly dynamic as per REL24 and REL14.
496
497 2006-03-16 Alan Modra <amodra@bigpond.net.au>
498
499 * elf32-ppc.c (ppc_elf_check_relocs): Don't fall into REL24
500 checks from REL32.
501
502 2006-03-15 Ben Elliston <bje@au.ibm.com>
503
504 * elf32-arm.c (elf32_arm_merge_eabi_attributes): Iterate over all
505 in_list elements, not just the first.
506
507 2006-03-14 Richard Sandiford <richard@codesourcery.com>
508
509 * elf32-mips.c (mips_elf_adjust_addend): New function, mostly split
510 out from...
511 (_bfd_mips_elf_relocate_section): ...here. Use it to adjust r_addend
512 for final links too.
513
514 2006-03-13 Richard Sandiford <richard@codesourcery.com>
515
516 * elfxx-mips.c (mips_elf_create_got_section): Initialize hgot.
517
518 2006-03-11 H.J. Lu <hongjiu.lu@intel.com>
519
520 PR ld/2443
521 * dwarf2.c (concat_filename): Don't issue an error if file is
522 0.
523
524 2006-03-10 Paul Brook <paul@codesourcery.com>
525
526 * elf32-arm.c (INTERWORK_FLAG): Handle EABIv5.
527 (elf32_arm_print_private_bfd_data): Ditto.
528
529 2006-03-09 Paul Brook <paul@codesourcery.com>
530
531 * cpu-arm.c (bfd_is_arm_mapping_symbol_name): Recognise additional
532 mapping symbols.
533
534 2006-03-09 Khem Raj <khem@mvista.com>
535
536 * elf32-arm.c(elf32_arm_finish_dynamic_sections): Use unsigned
537 char type.
538
539 2006-03-08 H.J. Lu <hongjiu.lu@intel.com>
540
541 * elfxx-ia64.c (elfNN_ia64_choose_gp): Properly choose gp.
542
543 2006-03-07 Richard Sandiford <richard@codesourcery.com>
544 Daniel Jacobowitz <dan@codesourcery.com>
545 Zack Weinberg <zack@codesourcery.com>
546 Nathan Sidwell <nathan@codesourcery.com>
547 Paul Brook <paul@codesourcery.com>
548 Ricardo Anguiano <anguiano@codesourcery.com>
549 Phil Edwards <phil@codesourcery.com>
550
551 * configure.in (bfd_elf32_bigarm_vec): Include elf-vxworks.lo.
552 (bfd_elf32_bigarm_symbian_vec): Likewise.
553 (bfd_elf32_bigarm_vxworks_vec): Likewise.
554 (bfd_elf32_littlearm_vec): Likewise.
555 (bfd_elf32_littlearm_symbian_vec): Likewise.
556 (bfd_elf32_littlearm_vxworks_vec): Likewise.
557 * configure: Regenerate.
558 * elf32-arm.c: Include libiberty.h and elf-vxworks.h.
559 (RELOC_SECTION, RELOC_SIZE, SWAP_RELOC_IN, SWAP_RELOC_OUT): New macros.
560 (elf32_arm_vxworks_bed): Add forward declaration.
561 (elf32_arm_howto_table_1): Fix the masks for R_ASM_ABS12.
562 (elf32_arm_vxworks_exec_plt0_entry): New table.
563 (elf32_arm_vxworks_exec_plt_entry): Likewise.
564 (elf32_arm_vxworks_shared_plt_entry): Likewise.
565 (elf32_arm_link_hash_table): Add vxworks_p and srelplt2 fields.
566 (reloc_section_p): New function.
567 (create_got_section): Use RELOC_SECTION.
568 (elf32_arm_create_dynamic_sections): Likewise. Call
569 elf_vxworks_create_dynamic_sections for VxWorks targets.
570 Choose between the two possible values of plt_header_size
571 and plt_entry_size.
572 (elf32_arm_link_hash_table_create): Initialize vxworks_p and srelplt2.
573 (elf32_arm_abs12_reloc): New function.
574 (elf32_arm_final_link_relocate): Call it. Allow the creation of
575 dynamic R_ARM_ABS12 relocs on VxWorks. Use reloc_section_p,
576 RELOC_SIZE, SWAP_RELOC_OUT and RELOC_SECTION. Initialize the
577 r_addend fields of relocs. On rela targets, skip any code that
578 adjusts in-place addends. When using _bfd_link_final_relocate
579 to perform a final relocation, pass rel->r_addend as the addend
580 argument.
581 (elf32_arm_merge_private_bfd_data): If one of the bfds is a VxWorks
582 object, ignore flags that are not standard on VxWorks.
583 (elf32_arm_check_relocs): Allow the creation of dynamic R_ARM_ABS12
584 relocs on VxWorks. Use reloc_section_p.
585 (elf32_arm_adjust_dynamic_symbol): Use RELOC_SECTION and RELOC_SIZE.
586 (allocate_dynrelocs): Use RELOC_SIZE. Account for the size of
587 .rela.plt.unloaded relocs on VxWorks targets.
588 (elf32_arm_size_dynamic_sections): Use RELOC_SIZE. Check for
589 .rela.plt.unloaded as well as .rel(a).plt. Add DT_RELA* tags
590 instead of DT_REL* tags on RELA targets.
591 (elf32_arm_finish_dynamic_symbol): Use RELOC_SECTION, RELOC_SIZE
592 and SWAP_RELOC_OUT. Initialize r_addend fields. Handle VxWorks
593 PLT entries. Do not make _GLOBAL_OFFSET_TABLE_ absolute on VxWorks.
594 (elf32_arm_finish_dynamic_sections): Use RELOC_SECTION, RELOC_SIZE
595 and SWAP_RELOC_OUT. Initialize r_addend fields. Handle DT_RELASZ
596 like DT_RELSZ. Handle the VxWorks form of initial PLT entry.
597 Correct the .rela.plt.unreloaded symbol indexes.
598 (elf32_arm_output_symbol_hook): Call the VxWorks version of this
599 hook on VxWorks targets.
600 (elf32_arm_vxworks_link_hash_table_create): Set vxworks_p to true.
601 Minor formatting tweak.
602 (elf32_arm_vxworks_final_write_processing): New function.
603 (elf_backend_add_symbol_hook): Override for VxWorks and reset
604 for Symbian.
605 (elf_backend_final_write_processing): Likewise.
606 (elf_backend_emit_relocs): Likewise.
607 (elf_backend_want_plt_sym): Likewise.
608 (ELF_MAXPAGESIZE): Likewise.
609 (elf_backend_may_use_rel_p): Minor formatting tweak.
610 (elf_backend_may_use_rela_p): Likewise.
611 (elf_backend_default_use_rela_p): Likewise.
612 (elf_backend_rela_normal): Likewise.
613 * Makefile.in (elf32-arm.lo): Depend on elf-vxworks.h.
614
615 2006-03-06 Nathan Sidwell <nathan@codesourcery.com>
616
617 * archures.c (bfd_mach_mcf_isa_a_nodiv, bfd_mach_mcf_isa_b_nousp):
618 New. Adjust other variants.
619 (bfd_default_scan): Update.
620 * bfd-in2.h: Rebuilt.
621 * cpu-m68k.c: Adjust.
622 (bfd_m68k_compatible): New. Use it for architectures.
623 * elf32-m68k.c (elf32_m68k_object_p): Adjust.
624 (elf32_m68k_merge_private_bfd_data): Adjust. Correct isa-a/b
625 mismatch.
626 (elf32_m68k_print_private_bfd_data): Adjust.
627 * ieee.c (ieee_write_processor): Adjust.
628
629 2006-03-06 Alan Modra <amodra@bigpond.net.au>
630
631 * dwarf2.c: Formatting.
632 (add_line_info): Remove outer loop.
633
634 2006-03-05 H.J. Lu <hongjiu.lu@intel.com>
635 Alan Modra <amodra@bigpond.net.au>
636
637 PR binutils/2338
638 * dwarf2.c (loadable_section): New struct.
639 (dwarf2_debug): Add loadable_section_count and
640 loadable_sections.
641 (new_line_sorts_after): New.
642 (add_line_info): Use new_line_sorts_after to compare line
643 addresses.
644 (check_function_name): Removed.
645 (unset_sections): New.
646 (place_sections): New.
647 (_bfd_dwarf2_find_nearest_line): Updated. Call place_sections
648 and unset_sections on relocatable files.
649 (_bfd_dwarf2_find_line): Likewise.
650
651 2006-03-03 Nick Clifton <nickc@redhat.com>
652
653 * cpu-avr.c: Update to ISO-C90 formatting.
654 * elf32-avr.c: Likewise.
655
656 2006-03-03 Bjoern Haase <bjoern.m.haase@web.de>
657
658 * elf32-avr.c (avr_reloc_map): Insert BFD_RELOC_AVR_MS8_LDI
659 and R_AVR_MS8_LDI
660 (bfd_elf_avr_final_write_processing): Set
661 EF_AVR_LINKRELAX_PREPARED in e_flags field.
662 (elf32_avr_relax_section): New function.
663 (elf32_avr_relax_delete_bytes): New function.
664 (elf32_avr_get_relocated_section_contents): New function.
665 (avr_pc_wrap_around): New function.
666 (avr_relative_distance_considering_wrap_around): New function.
667 (avr_final_link_relocate): Handle negative int8t_t immediate for R_AVR_LDI.
668 * reloc.c: Add BFD_RELOC_AVR_MS8_LDI and BFD_RELOC_AVR_LDI_NEG
669 * libbfd.h: Regenerate.
670 * bfd-in2.h: Regenerate.
671
672 2006-03-02 DJ Delorie <dj@redhat.com>
673
674 * elf32-m32c.c (m32c_offset_for_reloc): Fix local symbol
675 calculations.
676
677 2006-03-02 Richard Sandiford <richard@codesourcery.com>
678
679 * elf32-ppc.c (is_ppc_elf_target): Return true if the target is
680 bfd_elf32_powerpc_vxworks_vec.
681
682 2006-03-02 Nick Clifton <nickc@redhat.com>
683
684 * elf32-m32c.c (m32c_elf_relax_section): Initialise 'gap'.
685
686 2006-03-02 Richard Sandiford <richard@codesourcery.com>
687
688 * elf32-i386.c (elf_i386_create_dynamic_sections): Use
689 elf_vxworks_create_dynamic_sections.
690 (elf_i386_size_dynamic_sections): Remove VxWorks GOT and PLT
691 symbol handling.
692 * elf32-ppc.c (ppc_elf_create_dynamic_sections): Use
693 elf_vxworks_create_dynamic_sections.
694 (ppc_elf_size_dynamic_sections): Remove VxWorks GOT and PLT
695 symbol handling.
696 * elf-vxworks.c (elf_vxworks_create_dynamic_sections): New function.
697 * elf-vxworks.h (elf_vxworks_create_dynamic_sections): Declare.
698
699 2006-03-02 Richard Sandiford <richard@codesourcery.com>
700
701 * elf32-i386.c (elf_i386_vxworks_link_output_symbol_hook): Delete.
702 (elf_backend_link_output_symbol_hook): Use
703 elf_vxworks_link_output_symbol_hook instead.
704 * elf32-ppc.c (elf_i386_vxworks_link_output_symbol_hook): Delete.
705 (elf_backend_link_output_symbol_hook): Use
706 elf_vxworks_link_output_symbol_hook instead.
707 * elf-vxworks.c (elf_vxworks_link_output_symbol_hook): Provide the
708 same interface as elf_backend_link_output_symbol_hook.
709 * elf-vxworks.h (elf_vxworks_link_output_symbol_hook): Update
710 prototype accordingly.
711
712 2006-03-02 Richard Sandiford <richard@codesourcery.com>
713
714 * elf32-ppc.c (ppc_elf_plt_type): New enumeration.
715 (ppc_elf_link_hash_table): Replace old_got and new_got with
716 plt_type and can_use_new_plt.
717 (ppc_elf_create_dynamic_sections): Add SEC_HAS_CONTENTS,
718 SEC_LOAD and SEC_READONLY to the VxWorks .plt flags.
719 (ppc_elf_check_relocs): Set can_use_new_plt instead of new_plt.
720 Move from plt_type == PLT_UNSET to PLT_OLD instead of setting old_plt.
721 (ppc_elf_select_plt_layout): Move from plt_type == PLT_UNSET to
722 either plt_type == PLT_OLD or plt_type == PLT_NEW. Assert that
723 this function should not be called for VxWorks targets.
724 (ppc_elf_tls_setup): Use plt_type instead of old_got.
725 (allocate_got): Likewise. Rearrange so that max_before_header
726 is only used for PLT_OLD and PLT_NEW.
727 (allocate_dynrelocs): Use plt_type instead of old_got and is_vxworks.
728 (ppc_elf_size_dynamic_sections): Likewise.
729 (ppc_elf_relax_section): Likewise.
730 (ppc_elf_relocate_section): Likewise.
731 (ppc_elf_finish_dynamic_symbol): Likewise.
732 (ppc_elf_vxworks_link_hash_table_create): Initialize plt_type.
733
734 2006-02-28 Richard Sandiford <richard@codesourcery.com>
735
736 * elf32-i386.c (elf_i386_link_hash_table): Add next_tls_desc_index.
737 (elf_i386_link_hash_table_create): Initialize it.
738 (elf_i386_compute_jump_table_size): Use it instead of
739 srelplt->reloc_count.
740 (allocate_dynrelocs): Likewise.
741 (elf_i386_size_dynamic_sections): Likewise.
742 (elf_i386_relocate_section): Likewise.
743
744 2006-02-27 Jakub Jelinek <jakub@redhat.com>
745
746 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Handle S flag.
747 (_bfd_elf_write_section_eh_frame): Likewise.
748
749 2006-02-27 Carlos O'Donell <carlos@codesourcery.com>
750
751 * po/Make-in: Add html target.
752
753 2006-02-27 Richard Sandiford <richard@codesourcery.com>
754
755 * elf-m10300.c (_bfd_mn10300_elf_finish_dynamic_symbol): Use the
756 cached hgot entry to check for _GLOBAL_OFFSET_TABLE_.
757 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Likewise.
758 * elf32-bfin.c (bfin_finish_dynamic_symbol): Likewise.
759 * elf32-cris.c (elf_cris_finish_dynamic_symbol): Likewise.
760 * elf32-hppa.c (elf32_hppa_finish_dynamic_symbol): Likewise.
761 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Likewise.
762 * elf32-m32r.c (m32r_elf_finish_dynamic_symbol): Likewise.
763 * elf32-m68k.c (elf_m68k_finish_dynamic_symbol): Likewise.
764 * elf32-sh.c (sh_elf_finish_dynamic_symbol): Likewise.
765 * elf32-vax.c (elf_vax_finish_dynamic_symbol): Likewise.
766 * elf32-xtensa.c (elf_xtensa_finish_dynamic_symbol): Likewise.
767 * elf64-sh64.c (sh64_elf64_finish_dynamic_symbol): Likewise.
768 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Likewise.
769 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Likewise.
770 * elf32-s390.c (elf_s390_finish_dynamic_symbol): Likewise. Also use
771 the cached hplt entry to check for _PROCEDURE_LINKAGE_TABLE_.
772 * elf64-alpha.c (elf64_alpha_finish_dynamic_symbol): Likewise.
773 * elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
774 * elfxx-ia64.c (elfNN_ia64_finish_dynamic_symbol): Likewise.
775 * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): Likewise.
776
777 2006-02-25 Richard Sandiford <richard@codesourcery.com>
778
779 * elf-bfd.h (elf_link_hash_table): Add hplt field.
780 * elflink.c (_bfd_elf_create_dynamic_sections): Initialize it.
781 * elf-m10300.c (_bfd_mn10300_elf_create_got_section): Likewise.
782 * elf32-frv.c (_frv_create_got_section): Likewise.
783 * elf32-m32r.c (m32r_elf_create_dynamic_sections): Likewise.
784 * elf32-sh.c (sh_elf_create_dynamic_sections): Likewise.
785 * elf64-alpha.c (elf64_alpha_create_dynamic_sections): Likewise.
786 * elf64-sh64.c (sh64_elf64_create_dynamic_sections): Likewise.
787 * elf32-i386.c (elf_i386_link_hash_table): Remove hgot and hplt.
788 (elf_i386_link_hash_table_create): Don't initialize them.
789 (elf_i386_size_dynamic_sections): Use the generic ELF hplt and
790 hgot fields.
791 (elf_i386_finish_dynamic_symbol): Likewise.
792 * elf32-ppc.c (ppc_elf_link_hash_table): Remove hplt.
793 (ppc_elf_size_dynamic_sections): Use the generic ELF hplt fields.
794 (ppc_elf_finish_dynamic_symbol): Likewise.
795
796 2006-02-24 DJ Delorie <dj@redhat.com>
797
798 * elf32-m32c.c (m32c_elf_howto_table): Add relaxation relocs.
799 (m32c_elf_relocate_section): Don't relocate them.
800 (compare_reloc): New.
801 (relax_reloc): Remove.
802 (m32c_offset_for_reloc): New.
803 (m16c_addr_encodings): New.
804 (m16c_jmpaddr_encodings): New.
805 (m32c_addr_encodings): New.
806 (m32c_elf_relax_section): Relax jumps and address displacements.
807 (m32c_elf_relax_delete_bytes): Adjust for internal syms. Fix up
808 short jumps.
809
810 * reloc.c: Add m32c relax relocs.
811 * libbfd.h: Regenerate.
812 * bfd-in2.h: Regenerate.
813
814 2006-02-24 H.J. Lu <hongjiu.lu@intel.com>
815
816 PR ld/2218
817 * elf-bfd.h (elf_backend_data): Add elf_backend_fixup_symbol.
818 (_bfd_elf_link_hash_fixup_symbol): New.
819
820 * elflink.c (_bfd_elf_link_hash_fixup_symbol): New.
821 (_bfd_elf_fix_symbol_flags): Call elf_backend_fixup_symbol if
822 it isn't NULL.
823
824 * elfxx-ia64.c (elf_backend_fixup_symbol): Defined.
825
826 * elfxx-target.h (elf_backend_fixup_symbol): New.
827 (elfNN_bed): Initialize elf_backend_fixup_symbol.
828
829 2006-02-23 H.J. Lu <hongjiu.lu@intel.com>
830
831 * cpu-ia64-opc.c (ins_immu5b): New.
832 (ext_immu5b): Likewise.
833 (elf64_ia64_operands): Add IMMU5b.
834
835 2006-02-21 Alan Modra <amodra@bigpond.net.au>
836
837 PR ld/2218
838 * elf32-arm.c (allocate_dynrelocs): Ensure undef weak sym in pie
839 is dynamic.
840 * elf32-hppa.c (allocate_dynrelocs): Likewise.
841 * elf32-i386.c (allocate_dynrelocs): Likewise.
842 * elf32-s390.c (allocate_dynrelocs): Likewise.
843 * elf32-sh.c (allocate_dynrelocs): Likewise.
844 * elf64-s390.c (allocate_dynrelocs): Likewise.
845 * elf64-x86-64.c (allocate_dynrelocs): Likewise.
846 * elf32-m32r.c (allocate_dynrelocs): Likewise. Discard relocs
847 on undef weak with non-default visibility too.
848 * elfxx-sparc.c (allocate_dynrelocs): Ditto.
849
850 2006-02-21 Alan Modra <amodra@bigpond.net.au>
851
852 * bfd.c: (_bfd_default_error_handler): Don't call abort on
853 error, instead call _exit.
854 (_bfd_abort): Call _exit not xexit.
855
856 2006-02-17 Kevin Buettner <kevinb@redhat.com>
857
858 * elf32-frv.c (elf32_frv_grok_prstatus, elf32_frv_grok_psinfo):
859 New functions.
860 * elf_backend_grok_prstatus, elf_backend_grok_psinfo): Define.
861
862 2006-02-17 Shrirang Khisti <shrirangk@kpitcummins.com>
863 Anil Paranjape <anilp1@kpitcummins.com>
864 Shilin Shakti <shilins@kpitcummins.com>
865
866 * Makefile.am: Add xc16x related entry
867 * Makefile.in: Regenerate
868 * archures.c: Add bfd_xc16x_arch
869 * bfd-in2.h: Regenerate
870 * config.bfd: Add xc16x-*-elf
871 * configure.in: Add bfd_elf32_xc16x_vec
872 * configure: Regenerate.
873 * targets.c: Added xc16x related information
874 * cpu-xc16x.c: New file
875 * reloc.c: Add new relocations specific to xc16x:
876 BFD_RELOC_XC16X_PAG, BFD_RELOC_XC16X_POF, BFD_RELOC_XC16X_SEG,
877 BFD_RELOC_XC16X_SOF
878 * elf32-xc16x.c: New file.
879
880 2006-02-17 Alan Modra <amodra@bigpond.net.au>
881
882 * elf32-ppc.c (allocate_dynrelocs): Tweak undef weak handling.
883 * elf64-ppc.c (allocate_dynrelocs): Likewise.
884
885 2006-02-17 Alan Modra <amodra@bigpond.net.au>
886
887 PR ld/2218
888 * elf64-ppc.c (allocate_dynrelocs): Ensure undef weak sym is
889 dynamic.
890 (ppc64_elf_relocate_section): Check output reloc section size.
891 * elf32-ppc.c (allocate_dynrelocs): Simplify undef weak test.
892
893 2006-02-16 H.J. Lu <hongjiu.lu@intel.com>
894
895 PR ld/2322
896 * elf.c (get_segment_type): New function.
897 (_bfd_elf_print_private_bfd_data): Use it.
898 (print_segment_map): New function.
899 (assign_file_positions_for_segments): Call print_segment_map
900 when there are not enough room for program headers.
901
902 2006-02-16 Nick Hudson <nick.hudson@dsl.pipex.com>
903
904 * config.bfd (mips*el-*-netbsd*, mips*-*-netbsd*): Use
905 traditional MIPS ELF targets.
906
907 2006-02-15 H.J. Lu <hongjiu.lu@intel.com>
908
909 PR binutils/2338
910 * dwarf2.c (check_function_name): New function.
911 (_bfd_dwarf2_find_nearest_line): Use check_function_name to
912 check if function is correct.
913
914 2006-02-16 Alan Modra <amodra@bigpond.net.au>
915
916 * elflink.c (_bfd_elf_default_action_discarded): Return 0 for
917 debug sections.
918 (elf_link_input_bfd): Adjust comments.
919
920 2006-02-10 H.J. Lu <hongjiu.lu@intel.com>
921
922 * elf.c (copy_private_bfd_data): Minor update.
923
924 2006-02-10 H.J. Lu <hongjiu.lu@intel.com>
925
926 PR binutils/2258
927 * elf.c (copy_private_bfd_data): Renamed to ...
928 (rewrite_elf_program_header): This.
929 (copy_elf_program_header): New function.
930 (copy_private_bfd_data): Likewise.
931
932 2006-02-07 Nathan Sidwell <nathan@codesourcery.com>
933
934 * archures.c (bfd_mach_mcf5200, bfd_mach_mcf5206e,
935 bfd_mach_mcf5307, bfd_mach_mcf5407, bfd_mach_mcf528x,
936 bfd_mach_mcfv4e, bfd_mach_mcf521x, bfd_mach_mcf5249,
937 bfd_mach_mcf547x, bfd_mach_mcf548x): Remove.
938 (bfd_mach_mcf_isa_a, bfd_mach_mcf_isa_a_div,
939 bfd_mach_mcf_isa_a_div_mac, bfd_mach_mcf_isa_a_div_emac,
940 bfd_mach_mcf_isa_aplus, bfd_mach_mcf_isa_aplus_mac,
941 bfd_mach_mcf_isa_aplus_emac, bfd_mach_mcf_isa_aplus_usp,
942 bfd_mach_mcf_isa_aplus_usp_mac, bfd_mach_mcf_isa_aplus_usp_emac,
943 bfd_mach_mcf_isa_b, bfd_mach_mcf_isa_b_mac, bfd_mach_mcf_isa_b_emac,
944 bfd_mach_mcf_isa_b_usp_float, bfd_mach_mcf_isa_b_usp_float_mac,
945 bfd_mach_mcf_isa_b_usp_float_emac): New.
946 (bfd_default_scan): Update coldfire mapping.
947 * bfd-in.h (bfd_m68k_mach_to_features,
948 bfd_m68k_features_to_mach): Declare.
949 * bfd-in2.h: Rebuilt.
950 * cpu-m68k.c (arch_info_struct): Add new coldfire machines,
951 adjust legacy names.
952 (m68k_arch_features): New.
953 (bfd_m68k_mach_to_features,
954 bfd_m68k_features_to_mach): Define.
955 * elf32-m68k.c (elf32_m68k_object_p): New.
956 (elf32_m68k_merge_private_bfd_data): Merge the CF EF flags.
957 (elf32_m68k_print_private_bfd_data): Print the CF EF flags.
958 (elf_backend_object_p): Define.
959 * ieee.c (ieee_write_processor): Update coldfire machines.
960 * libbfd.h: Rebuilt.
961
962 2006-02-06 Steve Ellcey <sje@cup.hp.com>
963
964 * elfxx-ia64.c (elfNN_ia64_fake_sections): Set SHF_IA_64_HP_TLS
965 if SHF_TLS is set.
966
967 2006-02-05 Arnold Metselaar <arnold.metselaar@planet.nl>
968
969 * coff-z80.c (r_imm24): New howto.
970 (rtype2howto): New case R_IMM24.
971 (coff_z80_reloc_type_lookup): New case BFD_RELOC_24.
972 (extra_case): Use bfd_get_8 for R_IMM8, new case R_IMM24.
973
974 2006-02-04 Richard Sandiford <richard@codesourcery.com>
975
976 * elfxx-mips.c (mips_elf_initialize_tls_index): If a TLS symbol
977 has already been assigned a GOT index, copy that index to the
978 current hash table entry.
979
980 2006-02-01 Eric Botcazou <ebotcazou@libertysurf.fr>
981
982 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Reinstate bypass
983 for call-to-undefweak reloc overflow.
984
985 2006-01-31 Eric Botcazou <ebotcazou@libertysurf.fr>
986
987 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Reinstate bypass
988 for 32-bit relocs overflow.
989
990 2006-01-27 Paul Brook <paul@codesourcery.com>
991
992 * elf32-arm.c (elf32_arm_get_symbol_type): Allow STT_TLS thumb
993 objects.
994
995 2006-01-18 Alexandre Oliva <aoliva@redhat.com>
996
997 Introduce TLS descriptors for i386 and x86_64.
998 * reloc.c (BFD_RELOC_386_TLS_GOTDESC, BFD_RELOC_386_TLS_DESC,
999 BFD_RELOC_386_TLS_DESC_CALL, BFD_RELOC_X86_64_GOTPC32_TLSDESC,
1000 BFD_RELOC_X86_64_TLSDESC, BFD_RELOC_X86_64_TLSDESC_CALL): New.
1001 * libbfd.h, bfd-in2.h: Rebuilt.
1002 * elf32-i386.c (elf_howto_table): New relocations.
1003 (R_386_tls): Adjust.
1004 (elf_i386_reloc_type_lookup): Map new relocations.
1005 (GOT_TLS_GDESC, GOT_TLS_GD_BOTH_P): New macros.
1006 (GOT_TLS_GD_P, GOT_TLS_GDESC_P, GOT_TLS_GD_ANY_P): New macros.
1007 (struct elf_i386_link_hash_entry): Add tlsdesc_got field.
1008 (struct elf_i386_obj_tdata): Add local_tlsdesc_gotent field.
1009 (elf_i386_local_tlsdesc_gotent): New macro.
1010 (struct elf_i386_link_hash_table): Add sgotplt_jump_table_size.
1011 (elf_i386_compute_jump_table_size): New macro.
1012 (link_hash_newfunc): Initialize tlsdesc_got.
1013 (elf_i386_link_hash_table_create): Set sgotplt_jump_table_size.
1014 (elf_i386_tls_transition): Handle R_386_TLS_GOTDESC and
1015 R_386_TLS_DESC_CALL.
1016 (elf_i386_check_relocs): Likewise. Allocate space for
1017 local_tlsdesc_gotent.
1018 (elf_i386_gc_sweep_hook): Handle R_386_TLS_GOTDESC and
1019 R_386_TLS_DESC_CALL.
1020 (allocate_dynrelocs): Count function PLT relocations. Reserve
1021 space for TLS descriptors and relocations.
1022 (elf_i386_size_dynamic_sections): Reserve space for TLS
1023 descriptors and relocations. Set up sgotplt_jump_table_size.
1024 Don't zero reloc_count in srelplt.
1025 (elf_i386_always_size_sections): New. Set up _TLS_MODULE_BASE_.
1026 (elf_i386_relocate_section): Handle R_386_TLS_GOTDESC and
1027 R_386_TLS_DESC_CALL.
1028 (elf_i386_finish_dynamic_symbol): Use GOT_TLS_GD_ANY_P.
1029 (elf_backend_always_size_sections): Define.
1030 * elf64-x86-64.c (x86_64_elf_howto): Add R_X86_64_GOTPC32_TLSDESC,
1031 R_X86_64_TLSDESC, R_X86_64_TLSDESC_CALL.
1032 (R_X86_64_standard): Adjust.
1033 (x86_64_reloc_map): Map new relocs.
1034 (elf64_x86_64_rtype_to_howto): New, split out of...
1035 (elf64_x86_64_info_to_howto): ... this function, and...
1036 (elf64_x86_64_reloc_type_lookup): ... use it to map elf_reloc_val.
1037 (GOT_TLS_GDESC, GOT_TLS_GD_BOTH_P): New macros.
1038 (GOT_TLS_GD_P, GOT_TLS_GDESC_P, GOT_TLS_GD_ANY_P): New macros.
1039 (struct elf64_x86_64_link_hash_entry): Add tlsdesc_got field.
1040 (struct elf64_x86_64_obj_tdata): Add local_tlsdesc_gotent field.
1041 (elf64_x86_64_local_tlsdesc_gotent): New macro.
1042 (struct elf64_x86_64_link_hash_table): Add tlsdesc_plt,
1043 tlsdesc_got and sgotplt_jump_table_size fields.
1044 (elf64_x86_64_compute_jump_table_size): New macro.
1045 (link_hash_newfunc): Initialize tlsdesc_got.
1046 (elf64_x86_64_link_hash_table_create): Initialize new fields.
1047 (elf64_x86_64_tls_transition): Handle R_X86_64_GOTPC32_TLSDESC and
1048 R_X86_64_TLSDESC_CALL.
1049 (elf64_x86_64_check_relocs): Likewise. Allocate space for
1050 local_tlsdesc_gotent.
1051 (elf64_x86_64_gc_sweep_hook): Handle R_X86_64_GOTPC32_TLSDESC and
1052 R_X86_64_TLSDESC_CALL.
1053 (allocate_dynrelocs): Count function PLT relocations. Reserve
1054 space for TLS descriptors and relocations.
1055 (elf64_x86_64_size_dynamic_sections): Reserve space for TLS
1056 descriptors and relocations. Set up sgotplt_jump_table_size,
1057 tlsdesc_plt and tlsdesc_got. Make room for them. Don't zero
1058 reloc_count in srelplt. Add dynamic entries for DT_TLSDESC_PLT
1059 and DT_TLSDESC_GOT.
1060 (elf64_x86_64_always_size_sections): New. Set up
1061 _TLS_MODULE_BASE_.
1062 (elf64_x86_64_relocate_section): Handle R_386_TLS_GOTDESC and
1063 R_386_TLS_DESC_CALL.
1064 (elf64_x86_64_finish_dynamic_symbol): Use GOT_TLS_GD_ANY_P.
1065 (elf64_x86_64_finish_dynamic_sections): Set DT_TLSDESC_PLT and
1066 DT_TLSDESC_GOT. Set up TLS descriptor lazy resolver PLT entry.
1067 (elf_backend_always_size_sections): Define.
1068
1069 2006-01-17 H.J. Lu <hongjiu.lu@intel.com>
1070
1071 PR binutils/2096
1072 * dwarf2.c (comp_unit_contains_address): Update comment.
1073 (_bfd_dwarf2_find_nearest_line): Use section's vma, instead of
1074 lma. Return TRUE only if both comp_unit_contains_address and
1075 comp_unit_find_nearest_line return TRUE.
1076 (_bfd_dwarf2_find_line): Use section's vma, instead of lma.
1077
1078 2006-01-18 Alan Modra <amodra@bigpond.net.au>
1079
1080 * elf-bfd.h (struct elf_backend_data): Add gc_mark_dynamic_ref.
1081 (bfd_elf_gc_mark_dynamic_ref_symbol): Declare.
1082 * elflink.c (bfd_elf_gc_mark_dynamic_ref_symbol): Rename from
1083 elf_gc_mark_dynamic_ref_symbol. Make global.
1084 (bfd_elf_gc_sections): Call bed->gc_mark_dynamic_ref.
1085 * elfxx-target.h (elf_backend_gc_mark_dynamic_ref): Define.
1086 (elfNN_bed): Init new field.
1087 * elf64-ppc.c (elf_backend_gc_mark_dynamic_ref): Define.
1088 (ppc64_elf_gc_mark_dynamic_ref): New function.
1089
1090 2006-01-17 Alan Modra <amodra@bigpond.net.au>
1091
1092 * elf64-ppc.c (ppc64_elf_gc_mark_hook): Don't hang forever in loop.
1093
1094 2006-01-17 Nick Clifton <nickc@redhat.com>
1095
1096 PR binutils/2159
1097 * elf.c (elfcore_write_pstatus): Add ATTRIBUTE_UNUSED to unused
1098 parameters.
1099
1100 2006-01-11 Nick Clifton <nickc@redhat.com>
1101
1102 * elf32-arm.c (elf32_arm_output_symbol_hook): Install new entry
1103 into the newly (re)allocated map array.
1104
1105 2006-01-09 Alexis Wilke <alexis_wilke@yahoo.com>
1106
1107 * peXXigen.c (tbl): Add comma after "HIGH3ADJ".
1108
1109 2006-01-01 Jakub Jelinek <jakub@redhat.com>
1110
1111 * elf64-ppc.c (ppc64_elf_action_discarded): Return 0
1112 for .toc1 section.
1113
1114 For older changes see ChangeLog-2005
1115 \f
1116 Local Variables:
1117 mode: change-log
1118 left-margin: 8
1119 fill-column: 74
1120 version-control: never
1121 End:
This page took 0.061455 seconds and 4 git commands to generate.