1 2004-03-18 Alan Modra <amodra@bigpond.net.au>
3 * elf-bfd.h (struct elf_obj_tdata): Delete dt_soname field. Add
4 dyn_lib_class field. Rearrange for better packing.
5 (elf_dt_soname): Delete.
6 (elf_dyn_lib_class): Define.
7 * elf.c (bfd_elf_set_dt_needed_name): Update comment.
8 (bfd_elf_set_dt_needed_soname): Delete.
9 (bfd_elf_set_dyn_lib_class): New function.
10 * elflink.h (add_dt_needed_tag): New function. Split out from..
11 (elf_link_add_object_symbols): ..here. Rename "name" to "soname".
12 Use elf_dyn_lib_class to set dt_needed and add_needed. Move fallback
13 initialization of soname.
14 (elf_link_check_versioned_symbol): Test elf_dyn_lib_class instead of
16 * bfd-in.h (enum dynamic_lib_link_class): New.
17 (bfd_elf_set_dt_needed_soname): Delete.
18 (bfd_elf_set_dyn_lib_class): Declare.
19 * bfd-in2.h: Regenerate.
21 * elflink.c (_bfd_elf_merge_symbol): Rewrite weak symbol handling.
22 (_bfd_elf_add_default_symbol): Remove indirect BFD_ASSERTs.
23 * elflink.h (elf_link_add_object_symbols): Don't clear dt_needed in
24 symbol loop. Instead use add_needed to flag tag as written.
26 2004-03-17 Nathan Sidwell <nathan@codesourcery.com>
28 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Correct
29 logic for null_input_bfd detection.
31 2004-03-17 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
33 * config.bfd: Switch sh-*-rtems* to ELF. Add sh-*-rtemscoff*.
35 2004-03-16 Mark Kettenis <kettenis@gnu.org>
37 * netbsd-core.c (netbsd_core_file_p) [CORE_FPU_OFFSET]: Remove
40 2004-03-16 Alan Modra <amodra@bigpond.net.au>
42 * elflink.c (elf_link_read_relocs_from_section): Don't use
43 NUM_SHDR_ENTRIES in end of reloc calc. Move NULL shdr check..
44 (_bfd_elf_link_read_relocs): ..to here.
45 * elf32-ppc.c (ppc_elf_relax_section): Formatting.
47 2004-03-16 Alan Modra <amodra@bigpond.net.au>
49 * configure.in (HOST_64BIT_TYPE, HOST_U_64BIT_TYPE): Don't override
50 values selected in configure.host. Require both to be defined
51 before setting BFD_HOST_64_BIT_DEFINED. Protect assignment to
52 corresponding BFD_HOST vars with quotes.
53 <${host64}-${target64}-${want64} in *true*>: Don't exempt gcc;
54 Always require BFD_HOST_64_BIT_DEFINED.
55 <file_ptr type>: Find off_t size before emitting message. Combine
56 off_t and ftello64 conditional.
57 * configure: Regenerate.
59 2004-03-16 Alan Modra <amodra@bigpond.net.au>
61 * elf32-m32r.c (m32r_elf_create_dynamic_sections): Fix pointer
62 aliasing warning. Remove trailing whitespace throughout file.
64 2004-03-15 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
66 * elf-hppa.h (elf_hppa_relocate_section): Pass input_bfd instead of
67 input_section in calls to get_dyn_name.
68 * elf64-hppa.c (get_dyn_name): Change type of first argument to "bfd *". Use section id of first section in input BFD to build dynamic name for
70 (elf64_hppa_check_relocs): Pass abfd in call to get_dyn_name.
72 2004-03-15 Alan Modra <amodra@bigpond.net.au>
74 * bfd-in.h (bfd_int64_t, bfd_uint64_t): New types.
75 (BFD_HOST_64_BIT, BFD_HOST_U_64_BIT): Don't define here.
76 (bfd_getb64, bfd_getl64, bfd_get_bits): Return bfd_uint64_t.
77 (bfd_getb_signed_64, bfd_getl_signed_64): Return bfd_int64_t.
78 (bfd_putb64, bfd_putl64, bfd_put_bits): Accept bfd_uint64_t.
79 * configure.in (HOST_U_64BIT_TYPE): Set when sizeof long is 8.
80 (BFD_HOST_64_BIT_DEFINED, BFD_HOST_64_BIT, BFD_HOST_U_64_BIT): Set
82 * libbfd.c (EIGHT_GAZILLION, COERCE64): Use bfd_int64_t.
83 (bfd_getb64): Return bfd_uint64_t. Enable when BFD_HOST_64_BIT.
84 (bfd_getl64, bfd_getb_signed_64, bfd_getl_signed_64): Likewise.
85 (bfd_putb64): Accept bfd_uint64_t. Enable when BFD_HOST_64_BIT.
86 (bfd_putl64, bfd_put_bits, bfd_get_bits): Likewise.
87 * dwarf2.c (struct attribute): Use bfd_int64_t and bfd_uint64_t.
88 (read_8_bytes, read_indirect_string, read_address): Likewise.
89 (read_abbrevs, parse_comp_unit): Likewise.
90 * targets.c (struct bfd_target): Likewise.
91 * aix386-core.c (NO_GET64, NO_PUT64, NO_GETS64): Define and use.
92 * hppabsd-core.c: Likewise. Formatting.
93 * hpux-core.c: Likewise.
94 * irix-core.c: Likewise.
95 * netbsd-core.c: Likewise.
96 * osf-core.c: Likewise.
97 * ptrace-core.c: Likewise.
98 * sco5-core.c: Likewise.
99 * trad-core.c: Likewise.
100 * configure: Regenerate.
101 * bfd-in2.h: Regenerate.
103 2004-03-15 Alan Modra <amodra@bigpond.net.au>
105 * bfd-in.h (bfd_getb64, bfd_getl64): Replace bfd_byte* with void*.
106 (bfd_getb32, bfd_getl32, bfd_getb16, bfd_getl16): Likewise.
107 (bfd_getb_signed_64, bfd_getl_signed_64): Likewise.
108 (bfd_getb_signed_32, bfd_getl_signed_32): Likewise.
109 (bfd_getb_signed_16, bfd_getl_signed_16): Likewise.
110 (bfd_putb64, bfd_putl64, bfd_putb32, bfd_putl32): Likewise.
111 (bfd_putb16, bfd_putl16, bfd_get_bits, bfd_put_bits): Likewise.
112 * libbfd.c: Likewise in function definitions.
113 (bfd_put_8): Mask with 0xff rather than casting to char.
114 (bfd_putb16, bfd_putl16, bfd_putb32, bfd_putl32): Likewise.
115 (bfd_putb64, bfd_putl64, bfd_put_bits): Likewise.
116 (H_PUT_64, H_PUT_32, H_PUT_16, H_PUT_8): Remove casts, simplify.
117 (H_PUT_S64, H_PUT_S32, H_PUT_S16, H_PUT_S8): Likewise.
118 (H_GET_64, H_GET_32, H_GET_16, H_GET_8): Likewise.
119 (H_GET_S64, H_GET_S32, H_GET_S16, H_GET_S8): Likewise.
120 * libaout.h (H_PUT_64 H_PUT_32, H_PUT_16): Remove casts, simplify.
121 (H_PUT_S64, H_PUT_S32, H_PUT_S16): Likewise.
122 (H_GET_64, H_GET_32, H_GET_16): Likewise.
123 (H_GET_S64, H_GET_S32, H_GET_S16): Likewise.
124 * archive.c (do_slurp_coff_armap): Update swap prototype.
125 * coff-tic54x.c (tic54x_getl32): Replace bfd_byte* with void*.
126 (tic54x_getl_signed_32): Likewise.
127 (tic54x_putl32): Likewise. Mask with 0xff rather than casting to char.
128 * mach-o.c (bfd_mach_o_read_header): Update get32 prototype.
129 * pdp11.c (bfd_getp32): Make static, replace bfd_byte* with void*.
130 (bfd_getp_signed_32, bfd_putp32): Likewise.
131 * targets.c (struct bfd_target): Use void* in place of bfd_byte* for
132 bfd_getx64, bfd_getx_signed_64, bfd_putx64, bfd_getx32,
133 bfd_getx_signed_32, bfd_putx32, bfd_getx16, bfd_getx_signed_16,
134 bfd_putx16, bfd_h_getx64, bfd_h_getx_signed_64, bfd_h_putx64,
135 bfd_h_getx32, bfd_h_getx_signed_32, bfd_h_putx32, bfd_h_getx16,
136 bfd_h_getx_signed_16, bfd_h_putx16.
137 * aix386-core.c (NO_GET, NO_GETS, NO_PUT): Update prototypes.
138 * hppabsd-core.c: Similarly. Rename NO_SIGNED_GET to NO_GETS.
139 * hpux-core.c: Likewise.
140 * irix-core.c: Likewise.
141 * netbsd-core.c: Likewise.
142 * osf-core.c: Likewise.
143 * ptrace-core.c: Likewise.
144 * sco5-core.c: Likewise.
145 * trad-core.c: Likewise.
146 * bfd-in2.h: Regenerate.
148 2004-03-15 Matt Thomas <matt@3am-software.com>
150 * config.bfd: Add x86-64 vector to NetBSD/i386 if 64bit BFD is
153 2004-03-13 Mark Kettenis <kettenis@gnu.org>
155 * config.bfd: Add x86_64-*-openbsd*.
156 * configure.in (x86_64-*-openbsd*): Set COREFILE to
158 * configure: Regenerate.
160 2004-03-12 Nick Clifton <nickc@redhat.com>
161 Dave Murphy <wintermute2k4@ntlworld.com>
163 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Skip most checks
164 if the input bfd does not contain any code.
166 2004-03-09 Steve Ellcey <sje@cup.hp.com>
168 * elfxx-ia64.c (plt_full_entry): Change ld8 to ld8.acq.
170 2004-03-05 Fred Fish <fnf@redhat.com>
172 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Just force
173 mips16 symbols to be even rather than testing first for even/odd.
174 (_bfd_mips_elf_link_output_symbol_hook): Ditto.
176 2004-03-05 Nathan Sidwell <nathan@codesourcery.com>
178 * elf.c (map_sections_to_segments): Ignore .tbss sections for
181 2004-03-03 Alexandre Oliva <aoliva@redhat.com>
183 * elflink.c (bfd_elf_record_link_assignment): Mark undefweak and
184 undefined symbols as hash_new.
186 2003-03-03 Andrew Stubbs <andrew.stubbs@superh.com>
188 * archures.c: Add bfd_mach_sh4_nommu_nofpu.
191 * bfd-in2.h: Regenerate.
193 2004-03-02 Alexandre Oliva <aoliva@redhat.com>
195 * elf32-frv.c (struct frv_pic_relocs_info): Added fixups and
197 (_frv_count_got_plt_entries): Initialize them.
198 (frv_pic_relocs_info_find): Add insert argument. Adjust all
200 (frv_pic_relocs_info_for_global): Likewise.
201 (frv_pic_relocs_info_for_local): Likewise.
202 (frv_pic_merge_early_relocs_info): New.
203 (_frv_resolve_final_relocs_info): Use it in case one entry maps to
205 (_frv_add_dyn_reloc): Add entry argument. Adjust all callers.
206 Check that we don't exceed the allocated count for entry.
207 (_frv_add_rofixup): Likewise.
208 (_frv_emit_got_relocs_plt_entries): Adjust for coding standards.
209 (elf32_frv_finish_dynamic_sections): Improve error message in case
210 we emit too few rofixup entries.
212 2004-03-01 Richard Sandiford <rsandifo@redhat.com>
214 * archures.c (bfd_mach_fr450): New.
215 * bfd-in2.h: Regenerate.
216 * cpu-frv.c (arch_info_450): New bfd_arch_info_type.
217 (arch_info_500): Link to it.
218 * elf32-frv.c (elf32_frv_machine, frv_elf_merge_private_bfd_data)
219 (frv_elf_print_private_bfd_data): Handle fr405 and fr450 header flags.
220 (frv_elf_arch_extension_p): New function.
221 (frv_elf_merge_private_bfd_data): Use it.
223 2004-02-28 H.J. Lu <hongjiu.lu@intel.com>
225 * elf-bfd.h (_bfd_elf_link_add_archive_symbols): New prototype.
227 * elflink.h (is_global_data_symbol_definition): Moved to
229 (elf_link_is_defined_archive_symbol): Likewise.
230 (elf_link_add_archive_symbols): Likewise. Renamed to
231 _bfd_elf_link_add_archive_symbols.
233 * elflink.c (elf_link_is_defined_archive_symbol): Get the size
234 of ELF symbol table entry from backend.
235 (_bfd_elf_link_add_archive_symbols): Call bfd_link_add_symbols
236 instead of elf_link_add_object_symbols.
238 2004-02-27 Alexandre Oliva <aoliva@redhat.com>
240 * elf-bfd.h (struct elf_backend_data): Added
241 elf_backend_can_make_relative_eh_frame,
242 elf_backend_can_make_lsda_relative_eh_frame and
243 elf_backend_encode_eh_address.
244 (_bfd_elf_encode_eh_address): Declare.
245 (_bfd_elf_can_make_relative): Declare.
246 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Use new
247 hooks to decide whether to attempt to make_relative and
249 (_bfd_elf_write_section_eh_frame_hdr): Call encode_eh_address.
250 (_bfd_elf_can_make_relative): New.
251 (_bfd_elf_encode_eh_address): New.
252 * elf32-frv.c (frv_elf_use_relative_eh_frame): New.
253 (frv_elf_encode_eh_address): New.
254 (elf_backend_can_make_relative_eh_frame): Define.
255 (elf_backend_can_make_lsda_relative_eh_frame): Define.
256 (elf_backend_encode_eh_address): Define.
258 (elf_backend_can_make_relative_eh_frame): Define.
259 (elf_backend_can_make_lsda_relative_eh_frame): Define.
260 (elf_backend_encode_eh_address): Define.
261 (elfNN_bed): Add them.
263 2004-02-27 Alexandre Oliva <aoliva@redhat.com>
265 * elf32-frv.c (elf32_frv_howto_table) <R_FRV_LABEL16>: Set
266 complain_on_overflow to signed.
268 2004-02-27 H.J. Lu <hongjiu.lu@intel.com>
270 * elflink.h (sort_symbol): New.
271 (elf_link_add_object_symbols): Use a sorted symbol array for
274 2004-02-27 Jakub Jelinek <jakub@redhat.com>
276 * elf32-s390.c (allocate_dynrelocs): Use SYMBOL_REFERENCES_LOCAL
277 for pc relative relocs.
278 (elf_s390_relocate_section): Likewise.
279 * elf64-s390.c (allocate_dynrelocs): Use SYMBOL_REFERENCES_LOCAL
280 for pc relative relocs.
281 (elf_s390_relocate_section): Likewise.
283 2004-02-26 H.J. Lu <hongjiu.lu@intel.com>
285 * elfxx-ia64.c (elfNN_ia64_check_relocs): Fix call to
288 2004-02-25 H.J. Lu <hongjiu.lu@intel.com>
290 * elfxx-ia64.c (elfNN_ia64_dyn_reloc_entry): Add the reltext.
291 field to track if a relocation is against readonly section.
292 (count_dyn_reloc): Take a new argument for rent->reltext.
293 (elfNN_ia64_check_relocs): Adjust call to count_dyn_reloc.
294 (get_reloc_section): Don't set ia64_info->reltext here.
295 (allocate_dynrel_entries): Set ia64_info->reltext here.
297 2004-02-24 Alexandre Oliva <aoliva@redhat.com>
299 * elf32-frv.c (FRV_SYM_LOCAL): Weak undefined doesn't imply local.
300 (_frv_emit_got_relocs_plt_entries): Decay relocation to protected
301 function's descriptor to symbol+offset, and map local undefweak
302 symbol to NULL function descriptor.
303 (elf32_frv_relocate_section): Likewise.
305 2004-02-23 Mark Kettenis <kettenis@gnu.org>
307 * libaout.h (enum machine_type): Add M_SPARC64_NETBSD and
309 * netbsd-core.c (M_SPARC64_OPENBSD): Define.
310 (netbsd_core_file_p): Set architecture from machine ID for
313 2004-02-23 Jakub Jelinek <jakub@redhat.com>
315 * elflink.h (size_dynamic_sections): If not adding DT_FLAGS and
316 DF_BIND_NOW is set in info->flags, create DT_BIND_NOW dynamic entry.
318 2004-02-21 H.J. Lu <hongjiu.lu@intel.com>
320 * elflink.c (_bfd_elf_merge_symbol): Properly handle undefined
321 symbols with non-default visibility.
323 2004-02-21 Danny Smith <daanysmith@users.sourceforge.net>
325 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Clear
326 IMAGE_SCN_MEM_WRITE on known sections only.
328 2004-02-20 Jakub Jelinek <jakub@redhat.com>
330 * elf32-ppc.c (allocate_dynrelocs): Create dynsym for undef weak
331 symbols used in PIE relocs.
333 2004-02-19 Jakub Jelinek <jakub@redhat.com>
335 * elf32-sparc.c (elf32_sparc_finish_dynamic_sections): Clear
338 2004-02-18 Daniel Jacobowitz <drow@mvista.com>
340 * configure.in: Update version to 2.15.90.
341 * configure: Regenerate.
343 2004-02-17 Daniel Jacobowitz <drow@mvista.com>
344 Richard Sandiford <rsandifo@redhat.com>
346 * elfxx-mips.c (mips_elf_calculate_relocation): Use
347 _bfd_elf_symbol_refs_local_p to decide whether to decay
348 a GOT_PAGE/GOT_OFST pair to GOT_DISP/addend.
349 (_bfd_mips_elf_check_relocs): Add a global GOT entry for GOT_PAGE
350 relocs if the symbol wasn't defined by a regular object file.
351 Don't check the symbol's dynindx.
353 2004-02-16 Andrew Cagney <cagney@redhat.com>
355 * bfd-in.h (file_ptr, ufile_ptr): Configure type using
357 * bfd-in2.h: Re-generate.
359 2004-02-14 Andrew Cagney <cagney@redhat.com>
361 * configure.host (HDEFINES): When hppa*-*-hpux*, define
364 2004-02-13 Andrew Cagney <cagney@redhat.com>
366 * elf.c (vma_page_aligned_bias): New function.
367 (assign_file_positions_except_relocs)
368 (assign_file_positions_for_segments): Replace broken modulo
369 arithmetic with call to vma_page_aligned_bias.
371 2004-02-11 Andrew Cagney <cagney@redhat.com>
373 * bfd-in.h: Update copyright.
374 (bfd_tell): Change return type to file_ptr.
375 * bfd-in2.h: Re-generate.
376 * cache.c: Update copyright.
377 (bfd_cache_lookup_worker): Use real_fseek, do not cast offset
379 (close_one): Use real_ftell.
380 * bfdio.c: Update copyright.
381 (real_ftell, real_fseek): New functions.
382 (bfd_tell): Use real_fseek and real_ftell, change return type to
384 (bfd_seek): Use real_ftell and real_fseek, change type of
385 file_position to a file_ptr.
386 * libbfd-in.h: Update copyright.
387 (real_ftell, real_fseek): Declare.
388 * libbfd.h: Re-generate.
390 * configure.in (AC_CHECK_FUNCS): Check for ftello, ftello64,
391 fseeko and fseeko64. Determine bfd_file_ptr.
392 * configure: Re-generate.
393 * config.in: Re-generate.
395 2004-02-09 Anil Paranjpe <anilp1@KPITCummins.com>
397 * coff-h8300.c: Added comments about relaxation for ldc.w and stc.w.
398 * elf32-h8300.c: Likewise.
400 2004-02-09 Christian Vogel <vogelchr@vogel.cx>
401 Nick Clifton <nickc@redhat.com>
403 * elf64-alpha.c (elf64_alpha_calc_got_offsets_for_symbol): Catch
404 GOT entries with no associated GOT subsection.
406 2004-02-09 Richard Sandiford <rsandifo@redhat.com>
408 * bfd-elf.h (elf_backend_name_local_section_symbols): New hook.
409 * elf.c (swap_out_syms): Use it to decide whether local section
410 symbols should be named.
411 * elfxx-target.h (elf_backend_name_local_section_symbols): New macro.
412 * elfxx-mips.h (_bfd_mips_elf_name_local_section_symbols): Declare.
413 (elf_backend_name_local_section_symbols): Define.
414 * elfxx-mips.c (_bfd_mips_elf_name_local_section_symbols): New.
416 2004-01-30 H.J. Lu <hongjiu.lu@intel.com>
418 * elfxx-ia64.c (elfNN_ia64_relax_brl): New function.
419 (elfNN_ia64_relax_section): Optimize brl to br during the relax
422 2004-01-30 Alexandre Oliva <aoliva@redhat.com>
424 * elf32-frv.c (elf32_frv_always_size_sections): Initialize pointer
425 to bfd_link_hash_entry passed by reference to
426 _bfd_generic_link_add_one_symbol.
428 2004-01-25 H.J. Lu <hongjiu.lu@intel.com>
430 * elfxx-ia64.c (elfNN_ia64_relocate_section): Disallow imm
431 relocations against dynamic symbols.
433 2004-01-23 Daniel Jacobowitz <drow@mvista.com>
435 * elf32-arm.h (elf32_arm_check_relocs): Revert part of 2004-01-13
438 2004-01-21 Tom Rix <tcrix@worldnet.att.net>
440 * reloc.c: New 5 bit reloc, BFD_RELOC_M68HC12_5B, for m68hc12 movb/movw.
441 * bfd-in2.h, libbfd.h: Rebuilt.
443 2004-01-20 Danny Smith <dannysmith@users.sourceforge.net>
445 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Don't remove
446 IMAGE_SCN_MEM_WRITE flag from .text section if WP_TEXT
447 flag has been cleared.
449 2004-01-19 Kazu Hirata <kazu@cs.umass.edu>
451 * coff-h8300.c: Add and adjust comments about relaxation.
452 * elf32-h8300.c: Likewise.
454 2004-01-16 Kazu Hirata <kazu@cs.umass.edu>
456 * coff-h8300.c: Fix comment typos.
457 * elf32-h8300.c: Likewise.
459 2004-01-16 Kazu Hirata <kazu@cs.umass.edu>
461 * coff-h8300.c: Add comments about relaxation.
462 * elf32-h8300.c: Likewise.
464 2004-01-14 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
466 * acinclude.m4: Quote names of macros to be defined by AC_DEFUN
468 * aclocal.m4: Regenerate.
469 * configure: Regenerate.
471 2004-01-13 Ian Lance Taylor <ian@wasabisystems.com>
473 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Call
474 mips_elf64_rtype_to_howto instead of using howto_table.
476 2004-01-13 Daniel Jacobowitz <drow@mvista.com>
478 * elf32-arm.h (elf32_arm_final_link_relocate): Check that we created
480 (elf32_arm_check_relocs): Don't increment the PLT refcount for
481 relocs which would not use the PLT.
483 2004-01-13 Alan Modra <amodra@bigpond.net.au>
485 * elf64-ppc.c (ppc64_elf_check_relocs): Ignore !SEC_ALLOC relocs.
486 (ppc64_elf_gc_sweep_hook): Likewise.
487 (ppc64_elf_size_dynamic_sections): Test for .plt directly.
489 2004-01-12 Anil Paranjpe <anilp1@KPITCummins.com>
491 Adds linker relaxation support for bit manipulation insns like
492 band, bclr, biand, bild, bior, bist, bixor, bld, bnot, bor, bset,
494 * elf32-h8300.c: Opcode for bit manipulation insn is checked in
495 elf32_h8_relax_section function while relxation for aa:16 and aa:32.
496 * coff-h8300.c: Opcode for bit manipulation insn is checked in
497 h8300_reloc16_extra_cases function while relxation for aa:16 and aa:32.
499 2004-01-12 Alan Modra <amodra@bigpond.net.au>
501 * dwarf2.c: Convert to C90, remove unneeded casts and prototypes.
503 2004-01-11 Kazu Hirata <kazu@cs.umass.edu>
505 * elf32-h8300.c: Fix formatting.
507 2004-01-11 Kazu Hirata <kazu@cs.umass.edu>
509 * elf32-cris.c (cris_elf_gc_sweep_hook): Return early if no
510 dynamic object is present. Declare r_symndx and h in an inner
512 * elf32-vax.c (elf_vax_gc_sweep_hook): Likewise.
514 2004-01-09 Daniel Jacobowitz <drow@mvista.com>
516 * elf32-arm.h (struct elf32_arm_relocs_copied): Remove pc_count.
517 (elf32_arm_copy_indirect_symbol): Don't copy pc_count.
518 (elf32_arm_final_link_relocate): Handle PLT32 and PC24 relocs
519 identically. Do not emit PC24 relocations for shared libraries.
520 (elf32_arm_gc_sweep_hook): Handle PLT32 and PC24 relocs
521 identically. Don't adjust pc_count.
522 (elf32_arm_check_relocs): Handle PLT32 and PC24 relocs identically.
523 Set ELF_LINK_HASH_NEEDS_PLT for both. Don't adjust pc_count; don't
524 adjust count for branch relocations.
525 (allocate_dynrelocs): Correct typo in call to
526 WILL_CALL_FINISH_DYNAMIC_SYMBOL. Never allocate space for
527 PC24 or PLT32 relocs when linking.
529 2004-01-09 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
531 * coff-arm.c (aoutarm_std_reloc_howto): [ARM_WINCE] Synchronize ARM_26D
532 relocation howto with ARM_26 one for consistency.
533 (coff_arm_relocate_section): Set partial_inplace for ARM_26 relocations
534 that will be converted to ARM_26D ones, since we always want 'done'
535 relocations to be reflected in section's data.
536 (coff_arm_relocate_section): [ARM_WINCE] Quick fix for BL instruction
538 (_bfd_final_link_relocate): Do not modify "inplace" data, if not
541 2004-01-08 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
543 * coff-arm.c (coff_arm_relocate_section): Do not alter relocs that
544 are not partial_inplace during a relocatable link.
546 2004-01-08 Kazu Hirata <kazu@cs.umass.edu>
548 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Return early
549 if no dynamic object is present. Declare r_symndx and h in an
552 2004-01-07 H.J. Lu <hongjiu.lu@intel.com>
554 * elfxx-ia64.c (elfNN_ia64_relax_section): Don't install
555 trampoline if it is known out of range.
557 2004-01-06 Alexandre Oliva <aoliva@redhat.com>
559 2003-12-17 Alexandre Oliva <aoliva@redhat.com>
560 * elf32-frv.c (_frv_osec_readonly_p): New.
561 (_frv_emit_got_relocs_plt_entries): Don't emit rofixup for
563 (_frv_count_got_plt_entries): Adjust expected count accordingly.
564 (elf32_frv_relocate_section): Likewise. Error out if attempting
565 to emit rofixups or dynamic relocs in read-only segments. Use
566 _bfd_elf_section_offset to adjust r_offsets in rofixups and
568 2003-12-12 Alexandre Oliva <aoliva@redhat.com>
569 * elf32-frv.c (elf32_frv_relocate_section): Compute dynamic
570 relocations or fixups involving merged sections correctly. Avoid
571 crash when undefined symbol is referenced by R_FRV_32 or
572 R_FRV_FUNCDESC_VALUE.
573 2003-12-02 Alexandre Oliva <aoliva@redhat.com>
574 * elf32-frv.c (elf32_frv_relocate_section): Add output_offset of
575 input section holding local symbol to addend of R_FRV_32 or
576 R_FRV_FUNCDESC_VALUE dynamic relocation.
577 2003-11-27 Alexandre Oliva <aoliva@redhat.com>
578 * elf32-frv.c (elf32_frv_modify_segment_map): Add link info arg.
579 (elf32_frv_always_size_sections): Don't store pointer to
580 __stacksize symbol in sec_info.
581 (elf32_frv_modify_segment_map): Look it up here.
582 2003-11-26 Alexandre Oliva <aoliva@redhat.com>
583 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Emit the address
584 of the lazy PLT entry, not only its offset, as the low word of a
586 2003-11-10 Alexandre Oliva <aoliva@redhat.com>
587 * elf32-frv.c (elf32_frv_always_size_sections): Define __stacksize
588 if a hash table entry already exists but is not a definition.
589 2003-11-05 Alexandre Oliva <aoliva@redhat.com>
590 * elf32-frv.c (frv_elf_link_hash_table_create): Use bfd_zalloc.
591 (_frv_add_rofixup): Don't inline.
592 (_frv_emit_got_relocs_plt_entries): Use NULL as funcdesc address
593 for undefweak symbols.
594 (elf32_frv_relocate_section): Avoid crash while computing
595 relocation when linking with shared library. Only emit rofixups
596 and dynamic relocations for alloc&load sections. Mark binaries
597 with inter-segment relocations for relocation as a unit.
598 (_frv_create_got_section): Rename .rofixup.got to .rofixup.
599 (DEFAULT_STACK_SIZE): New.
600 (_frv_count_got_plt_entries): Fix thinko in deciding whether to
601 emit rofixups or dynamic relocs when linking dynamic non-PIE
603 (elf32_frv_size_dynamic_sections): Generate rofixup on PIEs and
604 shared libs too. Reserve the last entry for the GOT pointer.
605 (elf32_frv_finish_dynamic_sections): Emit it.
606 (elf32_frv_always_size_sections): New.
607 (elf32_frv_modify_segment_map): New.
608 (elf32_frv_check_relocs): Reserve relocs32 space only in ALLOC
610 (frv_elf_merge_private_bfd_data): Clear PIC bit if FDPIC is set.
611 (frv_elf_print_private_bfd_data): Handle FDPIC and LIBPIC.
612 (elf_backend_always_size_sections): New.
613 (elf_backend_modify_segment_map): New.
614 2003-10-31 Alexandre Oliva <aoliva@redhat.com>
615 * config.bfd: Added frv-*-*linux*.
616 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Use idx 0 for
617 ABS section, instead of crashing.
618 (elf32_frv_relocate_section): Don't crash before warning about
619 different segments in non-PIC relocation.
620 2003-10-17 Alexandre Oliva <aoliva@redhat.com>
621 * elf32-frv.c (elf32_frv_relocate_section): Don't warn on LABEL24
622 relocs to undefweak symbols.
623 (elf32_frv_relocate_section): Ditto for undefined symbols.
624 2003-10-06 Alexandre Oliva <aoliva@redhat.com>
625 * elf32-frv.c (elf32_frv_create_dynamic_sections): Make sure
626 gotfixup section was created.
627 2003-09-30 Alexandre Oliva <aoliva@redhat.com>
628 * elf32-frv.c (elf32_frv_howto_table): Change GOT12,
629 FUNCDESC_GOT12, GOTOFF12 and FUNCDESC_GOTOFF12 to
630 complain_overflow_signed.
631 * elf32-frv.c (_frv_add_rofixup): Do not error out if contents
632 have not been allocated.
633 (_frv_emit_got_relocs_plt_entries): Return non-void. Assert
634 privfd only if dynamic sections were created.
635 (elf32_frv_relocate_section): Compute gprel_segment, and use it
636 for GPREL relocs. When linking relocatable FDPIC executables,
637 emit warnings for relocations that would be illegal on PIE or
638 shared libraries. Emit rofixup for R_FRV_32 only if input object
640 (_frv_create_got_section): Define _gp symbol in the rofixup
642 (elf32_frv_finish_dynamic_sections): If rofixups needed but
643 dynamic sections missing, error out requesting -melf32frvfd.
644 2003-09-19 Alexandre Oliva <aoliva@redhat.com>
645 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Rearrange
646 computation of addends from section and global or local symbol
647 value. Change return type to bfd_boolean, and return a failure if
648 a dynamic FUNCDESC or FUNCDESC_VALUE relocation that requires a
649 nonzero addend is required.
650 (elf32_frv_relocate_section): Likewise. Print error for
651 unsupported nonzero addends.
652 2003-09-18 Alexandre Oliva <aoliva@redhat.com>
653 * elf32-frv.c (FRV_SYM_LOCAL): In the absence of dynamic sections,
654 force everything local.
655 (_frv_emit_got_relocs_plt_entries): Cope with NULL sec.
656 * elf32-frv.c (struct frv_elf_link_hash_table): Added sgotfixup.
657 (frv_gotfixup_section): New.
658 (FRV_SYM_LOCAL): Accept undefweak and local common symbols.
659 (struct frv_pic_relocs_info): Split relocs into relocs32, relocsfd
661 (_frv_add_rofixup): New.
662 (_frv_emit_got_relocs_plt_entries): Generate fixups for non-PIE
663 fdpic executables. Use FRV_SYM_LOCAL more widely to simplify and
664 improve some ugly conditions.
665 (elf32_frv_relocate_section): Likewise. Reject inter-segment
666 relocations in fdpic.
667 (_frv_create_got_section): Create .rofixup.got section.
668 (struct _frv_dynamic_got_info): Added fixups.
669 (_frv_count_got_plt_entries): Account in-GOT relocations into
670 relocs32, relocsfd and relocsfdv. Account them into relocs or
671 fixups, as appropriate.
672 (elf32_frv_size_dynamic_sections): Size rofixup section. Simplify
674 (elf32_frv_finish_dynamic_sections): Verify that the right number
675 of relocations and fixups was generated.
676 (elf32_frv_check_relocs): Compute relocs32, relocsfd and
678 * elf32-frv.c (FRV_SYM_LOCAL): New macro, used instead of
679 SYMBOL_CALLS_LOCAL and SYMBOL_REFERENCES_LOCAL.
680 (FRV_FUNCDESC_LOCAL): New macro, used to decide whether a function
681 descriptor of a (formerly-)global symbol is local.
682 (struct frv_pic_relocs_info): Adjust comments.
683 (_frv_emit_got_relocs_plt_entries): Adjust.
684 (elf32_frv_relocate_section): Likewise.
685 (_frv_count_got_plt_entries): Likewise.
686 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Don't add global
687 symbol's value to addend in the common preamble. Decay dynamic
688 symbols to section+offset if they bind or call locally, for GOT
689 and FUNCDESC_VALUE, respectively.
690 (elf32_frv_relocate_section): Likewise.
691 (elf32_frv_check_relocs): Don't register as dynamic symbols of
692 internal or hidden visibility.
693 2003-09-17 Alexandre Oliva <aoliva@redhat.com>
694 * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Get addend as
695 argument, so as to not call _bfd_elf_rel_local_sym to compute it.
696 (elf32_frv_relocate_section): Pass relocation addend in. Use
697 original relocation addend to look up the got relocs/plt entries
698 table. Do not call _bfd_elf_rel_local_sym. Don't error out when
699 processing relocations that reference .scommon symbols.
700 2003-09-15 Alexandre Oliva <aoliva@redhat.com>
701 Introduce support for dynamic linking.
702 * elf32-frv.c (R_FRV_FUNCDESC_VALUE): Mark it as 64 bits.
703 (elf32_frv_rel_32_howto, elf32_frv_rel_funcdesc_howto,
704 elf32_frv_rel_funcdesc_value_howto): New REL descriptors.
705 (frv_reloc_type_lookup): Return REL howtos for executables and
707 (frv_info_to_howto_rel): New.
708 (struct frv_elf_link_hash_table): New.
709 (frv_hash_table, frv_got_section, frv_gotrel_section,
710 frv_plt_section, frv_pltrel_section, frv_relocs_info,
711 frv_got_initial_offset, frv_plt_initial_offset): New macros.
712 (frv_elf_link_hash_table_create): New.
713 (struct frv_pic_relocs_info): New.
714 (frv_pic_relocs_info_hash, frv_pic_relocs_info_eq): New.
715 (frv_pic_relocs_info_find): New.
716 (frv_pic_relocs_info_for_global, frv_pic_relocs_info_for_local):
718 (FRV_LZPLT_BLOCK_SIZE, FRV_LZPLT_RESOLVE_LOC): New.
719 (_frv_add_dyn_reloc, _frv_osec_to_segment): New.
720 (_frv_emit_got_relocs_plt_entries): New.
721 (elf32_frv_relocate_section): Add support for dynamic linking.
722 Handle new relocations.
723 (_frv_create_got_section): New.
724 (elf32_frv_create_dynamic_sections): New.
725 (ELF_DYNAMIC_INTERPRETER): New.
726 (struct _frv_dynamic_got_info): New.
727 (_frv_count_got_plt_entries): New.
728 (struct _frv_dynamic_got_plt_info): New.
729 (_frv_compute_got_alloc_data): New.
730 (_frv_get_got_entry, _frv_get_fd_entry): New.
731 (_frv_assign_got_entries, _frv_assign_plt_entries): New.
732 (_frv_resolve_final_relocs_info): New.
733 (elf32_frv_size_dynamic_sections): New.
734 (elf32_frv_finish_dynamic_sections): New.
735 (elf32_frv_adjust_dynamic_symbol): New.
736 (elf32_frv_finish_dynamic_symbol): New.
737 (elf32_frv_check_relocs): Handle new relocs. Explain how the
739 (elf_info_to_howto_rel): Define.
740 (bfd_elf32_bfd_link_hash_table_create): Define.
741 (elf_backend_create_dynamic_sections): Define.
742 (elf_backend_adjust_dynamic_symbol): Define.
743 (elf_backend_size_dynamic_sections): Define.
744 (elf_backend_finish_dynamic_symbol): Define.
745 (elf_backend_finish_dynamic_sections): Define.
746 (elf_backend_want_got_sym): Define.
747 (elf_backend_got_header_size): Define.
748 (elf_backend_want_got_plt): Define.
749 (elf_backend_plt_readonly): Define.
750 (elf_backend_want_plt_sym): Define.
751 (elf_backend_plt_header_size): Define.
752 (elf_backend_may_use_rel_p): Define.
753 (elf_backend_may_use_rela_p): Define.
754 (elf_backend_default_use_rela_p): Define.
755 2003-08-08 Alexandre Oliva <aoliva@redhat.com>
756 * elf32-frv.c (R_FRV_FUNCDESC_VALUE, R_FRV_FUNCDESC_GOTOFF12,
757 R_FRV_FUNCDESC_GOTOFFHI, R_FRV_FUNCDESC_GOTOFFLO, R_FRV_GOTOFF12,
758 R_FRV_GOTOFFHI, R_FRV_GOTOFFLO): New.
759 (frv_reloc_map): Map the corresponding BFD relocs to them.
760 (frv_reloc_type_lookup): ... and back to BFD relocs.
761 * reloc.c: New relocs.
762 * bfd-in2.h, libbfd.h: Rebuilt.
763 2003-08-04 Alexandre Oliva <aoliva@redhat.com>
764 * elf32-frv.c (R_FRV_GOT12, R_FRV_GOTHI, R_FRV_GOTLO,
765 R_FRV_FUNCDESC, R_FRV_FUNCDESC_GOT12, R_FRV_FUNCDESC_GOTHI,
766 R_FRV_FUNCDESC_GOTLO): New.
767 (frv_reloc_map): Map the corresponding BFD relocs to them.
768 (frv_reloc_type_lookup): ... and back to BFD relocs.
769 * reloc.c: New relocs.
770 * bfd-in2.h, libbfd.h: Rebuilt.
772 2004-01-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
774 * elf32-mips.c (ELF_MAXPAGESIZE): Redefine for traditional
775 targets to support pages of up to 64kB.
776 (elf32_bed): Redefine to get a separate backend data structure for
778 * elf64-mips.c (ELF_MAXPAGESIZE): Redefine for traditional
779 targets to support pages of up to 64kB.
780 (elf64_bed): Redefine to get a separate backend data structure for
782 * elfn32-mips.c (ELF_MAXPAGESIZE): Redefine for traditional
783 targets to support pages of up to 64kB.
784 (elf32_bed): Redefine to get a separate backend data structure for
787 2004-01-04 Mark Kettenis <kettenis@gnu.org>
789 * elf32-sparc.c (elf32_sparc_grok_psinfo): New function.
791 2004-01-02 Mark Kettenis <kettenis@gnu.org>
793 * elf32-i386.c (elf_i386_grok_prstatus): Add support for FreeBSD.
794 (elf_i386_grok_psinfo): Likewise.
796 2004-01-02 Bernardo Innocenti <bernie@develer.com>
798 * config.bfd: Add m68k-uClinux target.
800 2004-01-01 Grant Edwards <grante@visi.com>
802 * elflink.h (elf_gc_sections): Warn when gc-sections option is ignored.
803 * elf32-h8300.c (elf32_h8_gc_mark_hook): New function.
804 (elf32_h8_gc_sweep_hook): New function.
805 (elf_backend_gc_mark_hook): Define.
806 (elf_backend_gc_sweep_hook): Define.
807 (elf_backend_can_gc_sections): Define.
809 For older changes see ChangeLog-0203
815 version-control: never