]> Git Repo - binutils.git/blob - bfd/ChangeLog
* elf.c (bfd_section_from_shdr): Make "name" const.
[binutils.git] / bfd / ChangeLog
1 2002-06-04  Alan Modra  <[email protected]>
2
3         * elf.c (bfd_section_from_shdr): Make "name" const.
4         * elf-bfd.h (elf_backend_section_from_shdr): Likewise.
5         * elf32-i370.c (i370_elf_section_from_shdr): Likewise.
6         * elf32-ppc.c (ppc_elf_section_from_shdr): Likewise.
7         * elf32-sh64.c (sh64_backend_section_from_shdr): Likewise.
8         * elf32-v850.c (v850_elf_section_from_shdr): Likewise.
9         * elf64-alpha.c (elf64_alpha_section_from_shdr): Likewise.
10         * elf64-hppa.c (elf64_hppa_section_from_shdr): Likewise.
11         * elf64-ppc.c (ppc64_elf_section_from_shdr): Likewise.
12         * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Likewise.
13         * elfxx-mips.c (_bfd_mips_elf_section_from_shdr): Likewise.
14         * elfxx-mips.h (_bfd_mips_elf_section_from_shdr): Likewise.
15
16 2002-06-03  Maciej W. Rozycki  <[email protected]>
17
18         * elfxx-mips.c (ABI_64_P): Use backend's data to determine the
19         ABI.
20
21 2002-06-02  Kazu Hirata  <[email protected]>
22
23         * elf32-arc.c: Fix formatting.
24         * elf32-arm.h: Likewise.
25         * elf32-cris.c: Likewise.
26         * elf32-dlx.c: Likewise.
27         * elf32-hppa.c: Likewise.
28         * elf32-i386.c: Likewise.
29         * elf32-i386qnx.c: Likewise.
30         * elf32-or32.c: Likewise.
31         * elf32-s390.c: Likewise.
32         * elf32-sh64.c: Likewise.
33         * elf32-vax.c: Likewise.
34         * elf32-xstormy16.c: Likewise.
35         * elf64-alpha.c: Likewise.
36         * elf64-mmix.c: Likewise.
37         * elf64-ppc.c: Likewise.
38         * elf64-s390.c: Likewise.
39         * elf64-sh64.c: Likewise.
40         * elf64-x86-64.c: Likewise.
41
42 2002-06-02  Richard Henderson  <[email protected]>
43
44         * elf64-alpha.c (elf64_alpha_relocate_section): Don't dereference
45         null when there are no got entries for a symbol.
46         (elf64_alpha_relax_find_tls_segment): Rearrange to avoid
47         uninitialized variable warning.
48
49 2002-06-01  Richard Henderson  <[email protected]>
50
51         * elf64-alpha.c (elf64_alpha_relax_with_lituse): Don't test for
52         undefined symbols here.
53         (elf64_alpha_relax_section): Do it here.  Also test for not
54         defined in the current module.
55         (elf64_alpha_relocate_section_r): Split out of ...
56         (elf64_alpha_relocate_section): ... here.  Don't dereference
57         NULL when looking up local got entries.
58
59 2002-06-01  Richard Henderson  <[email protected]>
60
61         * elf64-alpha.c (elf64_alpha_relax_with_lituse): Reject undefined
62         symbols from JSR relaxation.
63         (elf64_alpha_size_plt_section_1): New.
64         (elf64_alpha_calc_dynrel_sizes): Split out .rela.got bits ...
65         (elf64_alpha_size_rela_got_1): ... here.
66         (elf64_alpha_size_dynamic_sections): Split out .rela.got bits ...
67         (elf64_alpha_size_rela_got_section): ... here.
68         (elf64_alpha_size_plt_section): New.
69         (elf64_alpha_relax_section): Call them.
70         (elf64_alpha_size_got_sections): Remove output_bfd arg.
71         (elf64_alpha_finish_dynamic_symbol): Check gotent use_count.
72
73 2002-06-01  Richard Henderson  <[email protected]>
74
75         * elf64-alpha.c (alpha_get_dtprel_base, alpha_get_tprel_base): New.
76         (elf64_alpha_relocate_section): Use them.  Reject LE TLS relocs
77         in shared libraries.  Fix DTPRELHI and TPRELHI value.
78         (INSN_ADDQ, INSN_RDUNIQ): New.
79         (struct alpha_relax_info): Add symtab_hdr, tls_segment, first_gotent.
80         (elf64_alpha_relax_with_lituse): Return boolean.  Remove irelend
81         argument.  Reject dynamic symbols.  Use LITUSE symbolic constants.
82         (elf64_alpha_relax_got_load): Rename from relax_without_lituse.
83         Handle GOTDTPREL and GOTTPREL relocations.
84         (elf64_alpha_relax_gprelhilo): New.
85         (elf64_alpha_relax_tls_get_addr): New.
86         (elf64_alpha_relax_find_tls_segment): New.
87         (elf64_alpha_relax_section): Handle TLS relocations.
88         (ALPHA_ELF_LINK_HASH_TLS_IE): New.
89         (elf64_alpha_check_relocs): Set it.
90
91 2002-06-01  Richard Henderson  <[email protected]>
92
93         * elf64-alpha.c (elf64_alpha_relax_section): Don't store computed gp.
94
95         * elf64-alpha.c (elf64_alpha_check_relocs): Fix typo on maybe_dynamic
96         check; don't suppress dynamic relocs for non-allocated sections.
97
98         * elf64-alpha.c: Remove dead code.
99
100 2002-05-31  Alan Modra  <[email protected]>
101
102         * bfd-in2.h: Regenerate.
103         * libbfd.h: Regenerate.
104         * po/SRC-POTFILES.in: Regenerate.
105
106         * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Don't allocate
107         space for bss .plt.
108
109 2002-05-31  Graeme Peterson  <[email protected]>
110
111         * Makefile.am (BFD32_BACKENDS): Add elf32-i386qnx.lo.
112         (BFD32_BACKENDS_CFILES): Add elf32-i386qnx.c.
113         Run "make dep-am".
114         * Makefile.in: Regenerate.
115         * config.bfd: Add i[3456]86-*-nto-qnx* support.
116         * configure.in: Add bfd_elf32_i386qnx_vec support.
117         * configure: Regenerate.
118         * elf-bfd.h (struct elf_backend_data): Add set_nonloadable_filepos,
119         is_contained_by_filepos, and copy_private_bfd_data_p.
120         * elf.c (assign_file_positions_for_segments): Call backend
121         set_nonloadable_filepos.  Fix non-K&R call to _bfd_error_handler.
122         (IS_CONTAINED_BY_FILEPOS): Define.
123         (INCLUDE_SECTION_IN_SEGMENT): Also test IS_CONTAINED_BY_FILEPOS.
124         (copy_private_bfd_data): Use IS_CONTAINED_BY_FILEPOS.  Typo fix.
125         Fix non-K&R call to _bfd_error_handler.
126         (_bfd_elf_copy_private_section_data): Use backend
127         copy_private_bfd_data_p.
128         * elf32-i386.c: Don't include elfxx-target.h when
129         ELF32_I386_C_INCLUDED is defined.
130         * elf32-i386qnx.c: New QNX elf backend file.
131         * elfxx-target.h: Add elf_backend_set_nonloadable_filepos,
132         elf_backend_is_contained_by_filepos, and
133         elf_backend_do_copy_private_bfd_data.
134         * targets.c: Add bfd_target bfd_elf32_i386qnx_vec.
135
136 2002-05-31  Alan Modra  <[email protected]>
137
138         * elfarm-oabi.c (bfd_elf32_arm_add_glue_sections_to_bfd): Define.
139         Move other similar defines to start of file.
140
141 2002-05-30  Tom Rix  <[email protected]>
142
143         * coff-rs6000.c (xcoff_rtype2howto): Handle 16 bit R_RBA.
144         * coff64-rs6000.c (xcoff64_rtype2howto): Same.
145
146 2002-05-30  Richard Henderson  <[email protected]>
147
148         * elf64-alpha.c (ALPHA_ELF_LINK_HASH_LU_TLSGD,
149         ALPHA_ELF_LINK_HASH_LU_TLSLDM, ALPHA_ELF_LINK_HASH_LU_FUNC): New.
150         (ALPHA_ELF_GOT_ENTRY_RELOCS_DONE): Remove.
151         (ALPHA_ELF_GOT_ENTRY_RELOCS_XLATED): Remove.
152         (struct alpha_elf_got_entry): Add reloc_type, reloc_done, reloc_xlated.
153         (struct alpha_elf_obj_tdata): Rename total_got_entries and
154         n_local_got_entries to total_got_size and local_got_size.
155         (elf64_alpha_howto, elf64_alpha_reloc_map): Update for TLS relocs.
156         (alpha_got_entry_size): New.
157         (elf64_alpha_relax_with_lituse): Use it.
158         (elf64_alpha_relax_without_lituse): Likewise.
159         (MAX_GOT_SIZE): Rename from MAX_GOT_ENTRIES.
160         (get_got_entry): New.
161         (elf64_alpha_check_relocs): Handle TLS relocs.  Reorganize.
162         (elf64_alpha_adjust_dynamic_symbol): Test LU_FUNC as a mask.
163         (elf64_alpha_merge_ind_symbols): Check gotent->reloc_type.
164         (elf64_alpha_can_merge_gots, elf64_alpha_merge_gots): Likewise.
165         (elf64_alpha_calc_got_offsets_for_symbol): Use alpha_got_entry_size.
166         (elf64_alpha_calc_got_offsets): Likewise.
167         (alpha_dynamic_entries_for_reloc): New.
168         (elf64_alpha_calc_dynrel_sizes): Use it.
169         (elf64_alpha_size_dynamic_sections): Likewise.
170         (elf64_alpha_relocate_section): Handle TLS relocations.
171         * reloc.c: Add Alpha TLS relocations.
172         * bfd-in2.h, libbfd.h: Rebuild.
173
174 2002-05-29 Ralf Habacker <[email protected]>
175
176         * peXXigen.c (pe_print_idata): Remove double printed
177         import table lines; add Bound-To comment.
178
179 2002-05-29  Matt Thomas  <[email protected]>
180
181         * Makefile.am (BFD32_BACKENDS): Add elf32-vax.lo.
182         (BFD32_BACKENDS_CFILES): Add elf32-vax.c.
183         (elf32-vax.lo): New rule.
184         * Makefile.in: Regenerate.
185         * configure.in (bfd_elf32_vax_vec)
186         (vaxnetbsd_vec): New vectors.
187         * configure: Regenerate.
188         * config.bfd (vax-*-netbsdelf*)
189         (vax-*-netbsdaout*)
190         (vax-*-netbsd*): New targets.
191         * elf32-vax.c: New file.
192         * reloc.c: Add VAX relocations.
193         * bfd-in2.h: Regenerate.
194         * targets.c (_bfd_target_vector): Add bfd_elf32_vax_vec.
195
196 2002-05-29  Jason Thorpe  <[email protected]>
197
198         * config.bfd (arm-*-netbsd*): Add bfd_elf32_littlearm_vec
199         and bfd_elf32_bigarm_vec to targ_selvecs.
200
201 2002-05-29  Ralf Habacker  <[email protected]>
202
203         * peXXigen.c (pe_print_idata): Fix seg faults on printing import tables
204         with auto-imported symbols.
205
206 2002-05-29  Adam Nemet  <[email protected]>
207
208         * elf32-arm.h (bfd_elf32_arm_get_bfd_for_interworking): Don't add glue
209         sections only record bfd.
210         (bfd_elf32_arm_add_glue_sections_to_bfd): New function. 
211         * bfd-in.h (bfd_elf32_arm_add_glue_sections_to_bfd): Declare it.
212         * bfd-in2.h: Regenerate.          
213
214 2002-05-28  Nick Clifton  <[email protected]>
215
216         * syms.c (_bfd_stab_section_find_nearest_line): Move
217         declaration and initialisation of saw_line and saw_func out of
218         for loop.
219
220 2002-05-29  Alan Modra  <[email protected]>
221
222         * elf64-ppc.c (ppc64_elf_get_symbol_info): New function.
223         (bfd_elf64_get_symbol_info): Define.
224         * elfxx-target.h (bfd_elfNN_get_symbol_info): Only define if undef.
225
226 2002-05-29  Andrey Volkov  <[email protected]>
227
228         * cpu-h8300.c: Make default h8300 machine first in machine list.
229
230 2002-05-28  Kuang Hwa Lin <[email protected]>
231
232         * config.bfd: Added DLX configuraton.
233         * Makefile.am: Added DLX configuraton.
234         * configure.in: Added DLX configuraton.
235         * archures.c: Add DLX architecure.
236         * reloc.c: Add DLX relocs.
237         * targets.c: Added DLX target vector.
238         * configure: Regenerate.
239         * Makefile.in: Regenreate.
240         * bfd-in2.h: Regenreate.
241         * elf32-dlx.c: New file: Support DLX target.
242         * cpu-dlx.c: New file: Support DLX target.
243
244 2002-05-25  Alan Modra  <[email protected]>
245
246         * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Formatting.
247
248         * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Revert last change.
249         (ppc64_elf_check_relocs): Don't set up function descriptor symbol
250         strings to point inside function code sym string.
251         (func_desc_adjust): Likewise.
252         (ppc64_elf_hide_symbol): Rewrite code to look up function code sym.
253
254 2002-05-24  Michal Ludvig  <[email protected]>
255
256         * elf64-x86-64.c (elf64_x86_64_grok_prstatus): Added.
257         (elf64_x86_64_grok_psinfo): Added.
258
259 2002-05-24  TAMURA Kent <[email protected]>
260
261         * config.bfd: Add a target for i386-netbsdpe.
262
263 2002-05-24  Alan Modra  <[email protected]>
264
265         * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Don't copy is_func
266         and is_func_descriptor.
267         (func_desc_adjust): Hide function code sym in shared libs unless
268         there is a matching exported function descriptor sym.
269
270 2002-05-23  Jakub Jelinek  <[email protected]>
271
272         * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_THREAD_LOCAL
273         for symbols from SHF_TLS section.
274         (_bfd_elf_print_private_bfd_data): Add PT_TLS.
275         (elf_fake_sections): Set SHF_TLS for SEC_THREAD_LOCAL sections.
276         (map_sections_to_segments): Build PT_TLS segment if necessary.
277         (assign_file_positions_for_segments): Likewise.
278         (get_program_header_size): Account for PT_TLS segment.
279         (swap_out_syms): Set type of BSF_THREAD_LOCAL symbols and symbols from
280         SEC_THREAD_LOCAL sections to STT_TLS.
281         * reloc.c: Add 386 and IA-64 TLS relocs.
282         * section.c (SEC_THREAD_LOCAL): Define.
283         (SEC_CONSTRUCTOR_TEXT, SEC_CONSTRUCTOR_DATA, SEC_CONSTRUCTOR_BSS):
284         Remove.
285         * elflink.h (elf_link_add_object_symbols): Support .tcommon.
286         (size_dynamic_sections): If DF_STATIC_TLS, set DF_FLAGS
287         unconditionally.
288         (struct elf_final_link_info): Add first_tls_sec.
289         (elf_bfd_final_link): Set first_tls_sec.
290         Compute elf_hash_table (info)->tls_segment.
291         (elf_link_output_extsym): Handle STT_TLS symbols.
292         (elf_link_input_bfd): Likewise.
293         * syms.c (BSF_THREAD_LOCAL): Define.
294         * bfd-in2.h: Rebuilt.
295         * libbfd.h: Rebuilt.
296         * elf32-i386.c (elf_i386_tls_transition, dtpoff_base, tpoff,
297         elf_i386_mkobject, elf_i386_object_p): New functions.
298         (elf_howto_table): Add TLS relocs.
299         (elf_i386_reloc_type_lookup): Support TLS relocs.
300         (elf_i386_info_to_howto_rel): Likewise.
301         (struct elf_i386_link_hash_entry): Add tls_type.
302         (struct elf_i386_obj_tdata): New.
303         (elf_i386_hash_entry, elf_i386_tdata, elf_i386_local_got_tls_type):
304         New macros.
305         (struct elf_i386_link_hash_table): Add tls_ldm_got.
306         (link_hash_newfunc): Clear tls_type.
307         (elf_i386_check_relocs): Support TLS relocs.
308         (elf_i386_gc_sweep_hook): Likewise.
309         (allocate_dynrelocs): Likewise.
310         (elf_i386_size_dynamic_sections): Likewise.
311         (elf_i386_relocate_section): Likewise.
312         (elf_i386_finish_dynamic_symbol): Likewise.
313         (bfd_elf32_mkobject, elf_backend_object_p): Define.
314         * elfxx-ia64.c (struct elfNN_ia64_dyn_sym_info): Add tprel_offset,
315         dtpmod_offset, dtprel_offset, tprel_done, dtpmod_done, dtprel_done,
316         want_tprel, want_dtpmod, want_dtprel.
317         (elfNN_ia64_tprel_base, elfNN_ia64_dtprel_base): New functions.
318         (ia64_howto_table): Add TLS relocs, rename R_IA64_LTOFF_TP22 to
319         R_IA64_LTOFF_TPREL22.
320         (elf_code_to_howto_index): Add TLS relocs.
321         (elfNN_ia64_check_relocs): Support TLS relocs.
322         (allocate_global_data_got): Account for TLS .got data.
323         (allocate_dynrel_entries): Account for TLS dynamic relocations.
324         (elfNN_ia64_install_value): Supprt TLS relocs.
325         (set_got_entry): Support TLS relocs.
326         (elfNN_ia64_relocate_section): Likewise.
327
328 2002-05-23  Nick Clifton  <[email protected]>
329
330         * elf32-arm.h (elf32_arm_final_link_relocate): For the Thumb
331         BLX reloc round the relocation up rather than down.
332         * coff-arm.c (coff_arm_relocate_section): Likewise.
333
334 2002-05-21  H.J. Lu  ([email protected])
335
336         * linker.c (_bfd_generic_link_add_one_symbol): Allow multiple
337         definition.
338
339 2002-05-22  Alan Modra  <[email protected]>
340
341         * elf64-ppc.c (ppc64_elf_size_stubs): Don't strip .branch_lt.
342         (ppc64_elf_relocate_section): Handle unresolved relocs in opd.
343
344 2002-05-22  Alan Modra  <[email protected]>
345
346         * elf64-ppc.c (ppc64_elf_relocate_section): Return false for
347         unresolved relocs.
348         (ppc64_elf_size_dynamic_sections): Check for splt NULL.
349
350 2002-05-21  Thiemo Seufer <[email protected]>
351
352         * bfd/bfd.c (bfd_get_arch_size): Remove bfd_set_error call for
353         non-ELF targets.
354
355 2002-05-21  Thiemo Seufer <[email protected]>
356
357         * elf-bfd.h (elf_backend_emit_relocs): Change prototype to return
358         an error value.
359         * elflink.h (elf_link_output_relocs): Likewise. Improve error message.
360         return with false on error.
361         (elf_link_input_bfd): Check reloc_emitter return value.
362
363 2002-05-21  Jason Thorpe  <[email protected]>
364
365         * config.bfd (armeb-*-netbsdelf*): New target.
366
367 2002-05-20  Alan Modra  <[email protected]>
368
369         * elf64-ppc.c (ppc_build_one_stub): Point undefined function syms
370         at the plt call stub.
371
372 2002-05-19  Thiemo Seufer <[email protected]>
373
374         * cpu-mips.c (mips_compatible): Don't try to check machine
375         compatibility.
376
377 2002-05-18  Tom Rix  <[email protected]>
378
379         * coff64-rs6000.c (_bfd_xcoff64_swap_aux_out):  Fix C_FILE auxent.
380
381 2002-05-17  Alan Modra  <[email protected]>
382
383         * elf64-ppc.c (ppc64_elf_info_to_howto): Formatting.
384         (ppc64_elf_relocate_section): Don't warn about reloc overflow when
385         we've already warned about an undefined symbol.  Report more
386         detail on reloc errors.
387
388 2002-05-17  Alan Modra  <[email protected]>
389
390         * acinclude.m4 (AM_INSTALL_LIBBFD): New.
391         * configure.in: Invoke AM_INSTALL_LIBBFD.
392         * Makefile.am (install-data-local): Revert 2002-05-13.  Move to..
393         (install_libbfd): .. New target.
394         (uninstall_libbfd): Likewise.
395         (install-bfdlibLTLIBRARIES): Likewise.
396         (uninstall-bfdlibLTLIBRARIES): Likewise.
397         (bfdlibdir): New.
398         (bfdincludedir): New.
399         (lib_LTLIBRARIES): Rename to bfdlib_LTLIBRARIES.
400         * aclocal.m4: Regenerate.
401         * configure: Regenerate.
402         * Makefile.in: Regenerate.
403
404 2002-05-17  Stuart Balfour <[email protected]>
405
406         * hash.c (bfd_hash_lookup): Remove computation of len from inside
407         hash loop.
408
409 2002-05-16  Nick Clifton  <[email protected]>
410
411         * config.bfd: Add targets for sh64-linux (little endian and
412         big endian).
413
414 2002-05-15  Laurent Pinchart <[email protected]>
415
416         * peXXigen.c (pe_print_idata): Do not assume that the first thunk
417         is located in the same section as the import table.  Instead
418         check, and if necessary load the section containing the thunk.
419
420 2002-05-15  Nick Clifton  <[email protected]>
421
422         * aix5ppc-core.c (xcoff64_core_p): Replace bfd_read with
423         bfd_bread.
424         (xcoff64_core_file_matches_executable_p): Replace bfd_read
425         with bfd_bread.
426
427 2002-05-15  Alan Modra  <[email protected]>
428
429         * aix5ppc-core.c: Warning fixes.
430         * aout-adobe.c (aout_32_bfd_link_just_syms): Define.
431         * aout-target.h (MY_bfd_link_just_syms): Define.
432         * aout-tic30.c (MY_bfd_link_just_syms): Define.
433         * bfd.c (bfd_link_just_syms): Define.
434         * binary.c (binary_bfd_link_just_syms): Define.
435         * bout.c (b_out_bfd_link_just_syms): Define.
436         * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Update initializer.
437         * coff64-rs6000.c (rs6000coff64_vec, aix5coff64_vec): Likewise.
438         * coffcode.h (coff_bfd_link_just_syms): Define.
439         * elf-bfd.h (enum elf_link_info_type): Add ELF_INFO_TYPE_JUST_SYMS.
440         (elf_discarded_section): Check for ELF_INFO_TYPE_JUST_SYMS.
441         (_bfd_elf_link_just_syms): Declare.
442         * elf.c (_bfd_elf_link_just_syms): New function.
443         * elf-eh-frame.c (_bfd_elf_maybe_strip_eh_frame_hdr): Check that
444         sections haven't already been discarded by the linker.
445         * elflink.h (elf_link_add_object_symbols): Likewise for stab
446         sections and SEC_MERGE sections.
447         (elf_bfd_discard_info): Similarly here.
448         * elfxx-target.h (bfd_elfNN_bfd_link_just_syms): Define.
449         * i386msdos.c (msdos_bfd_link_just_syms): Define.
450         * i386os9k.c (os9k_bfd_link_just_syms): Define.
451         * ieee.c (ieee_bfd_link_just_syms): Define.
452         * ihex.c (ihex_bfd_link_just_syms): Define.
453         * libbfd-in.h (_bfd_nolink_bfd_link_just_syms): Define.
454         (_bfd_generic_link_just_syms): Declare.
455         * libecoff.h (_bfd_ecoff_bfd_link_just_syms): Define.
456         * linker.c (_bfd_generic_link_just_syms): New function.
457         * mmo.c (mmo_bfd_link_just_syms): Define.
458         * nlm-target.h (nlm_bfd_link_just_syms): Define.
459         * oasys.c (oasys_bfd_link_just_syms): Define.
460         * ppcboot.c (ppcboot_bfd_link_just_syms): Define.
461         * som.c (som_bfd_link_just_syms): Define.
462         * srec.c (srec_bfd_link_just_syms): Define.
463         * targets.c (struct bfd_target): Add _bfd_link_just_syms.
464         (BFD_JUMP_TABLE_LINK): And here.
465         * tekhex.c (tekhex_bfd_link_just_syms): Define.
466         * versados.c (versados_bfd_link_just_syms): Define.
467         * vms.c (vms_bfd_link_just_syms): Define.
468         * libbfd.h: Regenerate.
469         * bfd-in2.h: Regenerate.
470
471 2002-05-15  Thiemo Seufer <[email protected]>
472
473         * elf32-mips.c: Remove superfluous definitions copied from
474         elfxx-mips.c.
475         (bfd_elf32_bigmips_vec,bfd_elf32_littlemips_vec): Use the
476         SGIish vectors to check the special case.
477         (mips_elf_hi16_reloc): Fix comment.
478         (mips_elf_got16_reloc): Likewise.
479         (_bfd_mips_elf32_gprel16_reloc): Likewise.
480         (elf_reloc_map): Code cleanup.
481         (mips_reloc_map): Add comment.
482         (bfd_elf23_bfd_reloc_type_lookup): Code cleanup.
483         (mips_elf32_rtype_to_howto): Likewise.
484         (mips_elf32_discard_info): Likewise.
485         (elf32_mips_irix_compat): Invert logic: Only SGIish vectors
486         lead to IRIX compatibility now.
487
488 2002-05-15  Thiemo Seufer <[email protected]>
489
490         * elfxx-mips.c: Call it IRIX, not Irix in comments.
491
492 2002-05-13  Jason Thorpe  <[email protected]>
493
494         * config.bfd (shle-*-netbsdelf*): Add target which includes
495         sh64 support.
496
497 2002-05-13  David Edelsohn  <[email protected]>
498
499         * configure.in: Revert 2002-04-07.  Instead, auto-configure
500         HAVE_ST_C_IMPL.
501         * configure: Regenerate.
502         * config.in: Regenerate.
503         * rs6000-core.c (CNEW_IMPL): Guard use of c_impl with HAVE_ST_C_IMPL
504         or AIX_5_CORE.
505
506 2002-05-11  Federico G. Schwindt <[email protected]>
507
508         * configure.in (sparc*-*-openbsd*): Support sparc64-openbsd
509         corefiles as well.2
510         * configure: Regenerate.
511
512 2002-05-13  Alan Modra  <[email protected]>
513
514         * Makefile.am (install-data-local): Install headers to
515         $(exec_prefix)/include.
516         * Makefile.in: Regenerate.
517
518 2002-05-11  Ralf Corsepius  <[email protected]>
519             Daniel Jacobowitz  <[email protected]>
520
521         * coff-sh.c (sh_reloc_map): Map to R_SH_IMM32 for non-PE.  Don't
522         map BFD_RELOC_RVA.
523
524 2002-05-11  Federico G. Schwindt <[email protected]>
525
526         * config.bfd (alpha*-*-openbsd*, sparc64*-*-openbsd*,
527         hppa*-*-openbsd*): New targets.
528         * configure.in (alpha*-*-openbsd*): Set COREFILE.
529         * configure: Regenerate.
530
531 2002-05-10  Tom Rix  <[email protected]>
532
533         * coff64-rs6000.c (xcoff64_reloc_type_br): New function for
534         xcoff64_ppc_relocate_section.
535         * coff-rs6000.c : Extern common xcoff_reloc_type functions.
536         * libxcoff.h: Common xcoff_reloc_type function declaration.
537
538 2002-05-10  Alan Modra  <[email protected]>
539
540         * elf32-i386.c (elf_i386_relocate_section): Remove overflow checks
541         added in 2002-05-09 commit.
542
543         * elf32-hppa.c (elf32_hppa_size_stubs): Revert part of 2002-05-04,
544         don't look for stubs on all undefined syms.
545
546 2002-05-09  Alan Modra  <[email protected]>
547
548         * elf64-ppc.c (RA_REGISTER_MASK, RA_REGISTER_SHIFT): Delete.
549         (ppc64_elf_howto_raw <R_PPC64_RELATIVE>): Not pc_relative or
550         pcrel_offset.
551
552         * elf32-i386.c (elf_howto_table): Comments.
553         (elf_i386_relocate_section): Handle more relocs for relocatable
554         linking and against SEC_MERGE sections.
555
556 2002-05-08  Alan Modra  <[email protected]>
557
558         * elf32-ppc.c (ppc_elf_create_got): New function.
559         (ppc_elf_create_dynamic_sections): Call ppc_elf_create_got before
560         _bfd_elf_create_dynamic_sections.  Correct .plt flags.
561         (ppc_elf_check_relocs): Use ppc_elf_create_got in place of
562         _bfd_elf_create_got_section.
563
564 2002-05-07  Alan Modra  <[email protected]>
565
566         * elf-bfd.h (struct elf_backend_data): Add rela_normal.
567         * elfxx-target.h (elf_backend_rela_normal): Define.
568         (elfNN_bed): Init rela_normal.
569         * elflink.h (elf_link_input_bfd <emit_relocs>): Handle adjustment
570         for section symbols here if rela_normal.  Simplify abs section test.
571         * elf-m10200.c (mn10200_elf_relocate_section): If relocatable,
572         return immediately.  Remove code handling relocatable linking.
573         * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
574         * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
575         * elf32-i370.c (i370_elf_relocate_section): Likewise.
576         * elf32-i860.c (elf32_i860_relocate_section): Likewise.
577         * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
578         * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
579         * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
580         * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
581         * elf32-s390.c (elf_s390_relocate_section): Likewise.
582         * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
583         * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
584         * elf64-s390.c (elf_s390_relocate_section): Likewise.
585         * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
586         * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
587         * elf32-arm.h (elf32_arm_relocate_section): Likewise #ifndef USE_REL.
588         * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
589         * elf-m10200.c (elf_backend_rela_normal): Define.
590         * elf-m10300.c (elf_backend_rela_normal): Define.
591         * elf32-fr30.c (elf_backend_rela_normal): Define.
592         * elf32-i370.c (elf_backend_rela_normal): Define.
593         * elf32-i860.c (elf_backend_rela_normal): Define.
594         * elf32-m68k.c (elf_backend_rela_normal): Define.
595         * elf32-mcore.c (elf_backend_rela_normal): Define.
596         * elf32-openrisc.c (elf_backend_rela_normal): Define.
597         * elf32-ppc.c (elf_backend_rela_normal): Define.
598         * elf32-s390.c (elf_backend_rela_normal): Define.
599         * elf32-xstormy16.c (elf_backend_rela_normal): Define.
600         * elf64-ppc.c (elf_backend_rela_normal): Define.
601         * elf64-s390.c (elf_backend_rela_normal): Define.
602         * elf64-x86-64.c (elf_backend_rela_normal): Define.
603         * elfxx-ia64.c (elf_backend_rela_normal): Define.
604         * elf32-arm.h (elf_backend_rela_normal): Define #ifndef USE_REL.
605         * elf32-m32r.c (elf_backend_rela_normal): Likewise.
606
607 2002-05-06  Nick Clifton  <[email protected]>
608
609         * elf32-arm.h (elf32_arm_final_link_relocate): Convert
610         'reloc_signed_max' and 'reloc_signed_min' into half-word offsets.
611
612 2002-05-06  Alan Modra  <[email protected]>
613
614         * elflink.h (elf_link_input_bfd <emit_relocs>): Adjust r_offset
615         when not relocatable.  Fix reloc_emitter call for K&R.
616
617 2002-05-04  Alan Modra  <[email protected]>
618
619         * elf64-ppc.c (ppc64_elf_relocate_section): Reinstate code
620         reloading local sym addend mistakenly removed in 2002-05-01 change.
621
622         * dwarf2.c (struct line_head): Make prologue_length a bfd_vma.
623         (read_abbrevs): Change "offset" param to bfd_vma.
624         (parse_comp_unit): Change "version" and addr_size to unsigned ints.
625         Change "abbrev_offset" to bfd_vma.
626         (read_indirect_string): Use correct conversion chars in error
627         message format string, cast bfd_vma's to unsigned long.
628         (read_abbrevs): Likewise.
629         (read_attribute_value): Likewise.
630         (decode_line_info): Likewise.
631         (scan_unit_for_functions): Likewise.
632         (parse_comp_unit): Likewise.
633
634 2002-05-04  Tom Rix  <[email protected]>
635
636         * coffswap.h (coff_swap_reloc_in): Remove XCOFF support.
637         (coff_swap_reloc_out): Same.
638         * coff-rs6000.c: (xcoff_swap_reloc_in): Moved from coffswap.h.
639         (xcoff_swap_reloc_out): Same.
640         (xcoff_rtype2howto): Renamed from _bfd_xcoff_rtype2howto. Special
641         case some 16 bit relocs. Add reloc value to output.
642         (xcoff_howto_table): Remove 64 bit R_POS, add 16 bit
643         R_RBR. Improve names.
644         (_bfd_xcoff_reloc_type_lookup): Adjust for removal of 64 bit R_POS.
645         (bfd_xcoff_backend_data): Update with new reloc swap names.
646         (bfd_pmac_xcoff_backend_data) : Same.
647         * coff64-rs6000.c: (xcoff64_swap_reloc_in): Moved from coffswap.h.
648         (xcoff64_swap_reloc_out): Same.
649         (xcoff64_rtype2howto): Special case some 16 bit relocs and 32 bit
650         R_POS. Add reloc value to output.
651         (xcoff64_howto_table): Move 64 bit R_POS to first entry.  Add 16
652         bit R_RBR. Improve names, masks.
653         (xcoff64_reloc_type_lookup): Adjust for move of 64 bit R_POS.
654         (bfd_xcoff_backend_data): Update with new reloc swap names.
655         (bfd_xcoff_aix5_backend_data) : Same.
656
657 2002-05-04  Alan Modra  <[email protected]>
658
659         * elf32-hppa.c (struct elf32_hppa_link_hash_table): Add
660         bfd_count top_index, input_list, all_local_syms.
661         (elf32_hppa_setup_section_lists): New function, split from
662         elf32_hppa_size_stubs.
663         (elf32_hppa_next_input_section): Likewise.
664         (group_sections): Likewise.
665         (get_local_syms): Likewise.
666         (elf32_hppa_size_stubs): Adjust for split out functions.  Look for
667         stubs on undefined syms too.
668         (elf32_hppa_set_gp): Use bfd_link_hash* instead of elf_link_hash*.
669         Only access htab elf fields when we have an elf hash table.
670         * elf32-hppa.h (elf32_hppa_setup_section_lists): Declare.
671         (elf32_hppa_next_input_section): Declare.
672
673 2002-05-04  Bob Byrnes  <[email protected]>
674
675         * opncls.c (_bfd_new_bfd_contained_in): Check return value of
676         _bfd_new_bfd.
677
678 2002-05-03  H.J. Lu  ([email protected])
679
680         * elfxx-mips.c (mips_elf_link_hash_entry): Add forced_local.
681         (mips_elf_link_hash_newfunc): Initialize forced_local to false.
682         (mips_elf_record_global_got_symbol): Call _bfd_mips_elf_hide_symbol
683         to hide a global symbol.
684         (_bfd_mips_elf_hide_symbol): Return if forced_local is true. Set
685         forced_local to true.
686
687 2002-05-02  Richard Henderson  <[email protected]>
688
689         * elf64-alpha.c (elf64_alpha_relocate_section): Force relative relocs
690         vs SHN_UNDEF to zero.
691
692 2002-05-02  Alan Modra  <[email protected]>
693
694         * elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_SECTOFF>): Change to a
695         16 bit reloc.
696         <R_PPC64_SECTOFF_DS>: Likewise.
697         (ppc64_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
698         SECTOFF reloc.
699         * elf32-ppc.c (ppc_elf_howto_raw <R_PPC_SECTOFF>): Correct.
700         (ppc_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
701         SECTOFF reloc.
702
703         * elf64-ppc.c (ppc64_elf_addr16_ha_reloc): Delete.
704         (ppc64_elf_ha_reloc): New function.
705         (ppc64_elf_brtaken_reloc): New function.
706         (ppc64_elf_sectoff_reloc): New function.
707         (ppc64_elf_sectoff_ha_reloc): New function.
708         (ppc64_elf_toc_reloc): New function.
709         (ppc64_elf_toc_ha_reloc): New function.
710         (ppc64_elf_toc64_reloc): New function.
711         (ppc64_elf_unhandled_reloc): New function.
712         (ppc64_elf_howto_raw): Use the above.
713         <R_PPC64_RELATIVE>: Mark pc_relative, pcrel_offset.
714         <R_PPC64_SECTOFF>: Not pc_relative or pcrel_offset.  Fix dst_mask.
715         <R_PPC64_SECTOFF_DS>: Likewise.
716         (IS_ABSOLUTE_RELOC): Update.
717         (struct ppc_link_hash_table): Add have_undefweak.
718         (ppc64_elf_link_hash_table_create): Init.
719         (func_desc_adjust): Set have_undefweak.
720         (ppc64_elf_func_desc_adjust): Call func_desc_adjust earlier.  Only
721         add the .sfpr blr when have_undefweak.
722         (ppc64_elf_setup_section_lists): Check hash table flavour.
723         (ppc64_elf_next_input_section): Move output_section->owner test to
724         ppc64elf.em.
725         (ppc64_elf_set_toc): Rename to ppc64_elf_toc, remove info param
726         and relocatable test.  Return TOCstart and don't set elf_gp.
727         (ppc64_elf_relocate_section): Correct BRTAKEN/BRNTAKEN branch
728         offset calculation.  Add assert on weak sym branch tweaks.
729         * elf64-ppc.h (ppc64_elf_set_toc): Delete.
730         (ppc64_elf_toc): Declare.
731         (ppc64_elf_next_input_section): Update.
732
733 2002-05-01  Alan Modra  <[email protected]>
734
735         * syms.c (_bfd_stab_section_find_nearest_line): Don't bomb on NULL
736         file_name.
737
738 2002-05-01  Alan Modra  <[email protected]>
739
740         * elf64-ppc.c (CROR_151515, CROR_313131): Define.
741         (ppc64_elf_relocate_section): Use them.  Don't look for plt calls
742         on R_PPC64_ADDR24 relocs.  Require a nop or no link reg on plt
743         call branches.  Correct undefined weak destination.
744         (ppc64_elf_func_desc_adjust): Always create at least one blr in
745         .sfpr, and correct case where either only savef* or restf* is
746         needed.
747
748         Long branch stubs, multiple stub sections.
749         * elf64-ppc.h (ppc64_elf_setup_section_lists): Declare.
750         (ppc64_elf_next_input_section): Declare.
751         * elf64-ppc.c: Move linker-only prototypes.
752         (STUB_SUFFIX): Define.
753         (enum ppc_stub_type): New.
754         (struct ppc_stub_hash_entry): New.
755         (struct ppc_branch_hash_entry): New.
756         (struct ppc_link_hash_entry): Add stub_cache, oh.
757         (struct ppc_link_hash_table): Add stub_hash_table etc.  Remove
758         sstub.  Add sbrlt, srelbrlt, has_14bit_branch, stub_iteration.
759         Rename plt_overflow to stub_error.
760         (ppc_stub_hash_lookup): Define.
761         (ppc_branch_hash_lookup): Define.
762         (stub_hash_newfunc): New function.
763         (branch_hash_newfunc): New function.
764         (link_hash_newfunc): Init new fields.
765         (ppc64_elf_link_hash_table_create): Likewise.
766         (ppc64_elf_link_hash_table_free): New function.
767         (ppc_stub_name): New function.
768         (ppc_get_stub_entry): New function.
769         (ppc_add_stub): New function.
770         (create_linkage_sections): Use bfd_make_section_anyway.  Create
771         .branch_lt and .rela.branch_lt sections.  Don't create .stub.
772         (ppc64_elf_check_relocs): Set has_14bit_branch on R_PPC64_REL14*,
773         and set up for plt call stubs.  Link func and func desc syms.
774         (ppc64_elf_gc_sweep_hook): Handle REL14* as per REL24.
775         (func_desc_adjust): Avoid hash lookup when func desc sym available
776         via shortcut, and set links when processing.
777         (ppc64_elf_hide_symbol): Likewise.
778         (allocate_dynrelocs): Don't allocate stub section here.
779         (ppc64_elf_size_dynamic_sections): Handle sbrlt and srelbrlt.
780         Remove sstub code.
781         (ppc_type_of_stub): New function.
782         (build_one_stub): Delete.
783         (ppc_build_one_stub): New function.
784         (ppc_size_one_stub): New function.
785         (ppc64_elf_setup_section_lists): New function.
786         (ppc64_elf_next_input_section): New function.
787         (group_sections): New function.
788         (get_local_syms): New function.
789         (ppc64_elf_size_stubs): Rewrite.
790         (ppc64_elf_build_stubs): Rewrite.
791         (ppc64_elf_relocate_section): Look up stub entry for REL24
792         relocs.  Don't propagate REL14* to dynamic objects.  Look for long
793         branch stubs if REL14* or REL24 relocs won't reach.
794         (bfd_elf64_bfd_link_hash_table_free): Define.
795
796 2002-04-30  Mark Mitchell  <[email protected]>
797
798         * bfd/config.bfd: Add support for powerpc-*-windiss.
799
800 2002-04-30  Tom Rix  <[email protected]>
801
802         * xcofflink.c (xcoff_link_add_symbols): Always copy undef C_EXT
803         symbol names into the hash table.
804
805 2002-04-28  Tom Rix  <[email protected]>
806
807         * coff-rs6000.c (xcoff_calculate_relocation) : Function table for
808         calulating relocations.
809         (xcoff_complain_overflow) : Function table for relocation errors.
810         (xcoff_ppc_relocate_section): Use relocation and complain function
811         tables.
812         (xcoff_complain_overflow_unsigned_func): New complain function.
813         (xcoff_complain_overflow_signed_func): Same.
814         (xcoff_complain_overflow_bitfield_func): Same.
815         (xcoff_complain_overflow_dont_func): Same.
816         (xcoff_reloc_type_crel): New recot function.
817         (xcoff_reloc_type_br): Same.
818         (xcoff_reloc_type_ba): Same.
819         (xcoff_reloc_type_toc): Same.
820         (xcoff_reloc_type_rel): Same.
821         (xcoff_reloc_type_neg): Same.
822         (xcoff_reloc_type_pos): Same.
823         (xcoff_reloc_type_fail): Same.
824         (xcoff_reloc_type_noop): Same.
825         * libxcoff.h : Declare common parts for xcoff64.
826         * coff64-rs6000.c (xcoff64_ppc_relocate_section): Use relocation
827         and complain function tables.
828
829 2002-04-28  Alan Modra  <[email protected]>
830
831         * elf64-x86-64.c (struct elf64_x86_64_dyn_relocs): Comment typo.
832         * elf32-hppa.c (elf32_hppa_final_link): Formatting.
833
834 2002-04-26  Alan Modra  <[email protected]>
835
836         * opncls.c (bfd_make_readable): Call bfd_section_list_clear.
837         * xcofflink.c (xcoff_link_add_dynamic_symbols): Likewise.
838
839         * elflink.h (elf_bfd_final_link): Ensure input bfd class is the
840         same as the output before calling elf_link_input_bfd.
841
842         * coffcode.h (coff_compute_section_file_positions): Set
843         section_tail after shuffling section list.
844
845 2002-04-24  Christian Groessler <[email protected]>
846
847         * coff-z8k.c (extra_case): Fix R_IMM32 relocations: The
848         addresses are 23bit with a special layout, not plain 32bit
849         values.  Prevent relocation of immediate values.
850
851 2002-04-24  Chris G. Demetriou  <[email protected]>
852
853         * elfxx-mips.c (_bfd_mips_elf_print_private_bfd_data): If MDMX or
854         MIPS-16 ASE flags are set, print something to indicate that.
855
856 2002-04-23  Alan Modra  <[email protected]>
857
858         * elf32-hppa.c (hppa_type_of_stub): Correct and simplify condition
859         under which a plt call stub is used.
860         (final_link_relocate): Similarly.
861         (allocate_plt_static): Clear h-plabel except when plt entry is
862         exclusively used for a plabel.
863         (allocate_dynrelocs): Use the above to simplify plt sizing.
864         (struct elf32_hppa_link_hash_table): Add has_22bit_branch.
865         (elf32_hppa_link_hash_table_create): Init.
866         (BL22_RP): Define.
867         (hppa_build_one_stub): Use BL22_RP if has_22bit_branch.
868         (elf32_hppa_check_relocs): Set has_22bit_branch.
869
870         * elf32-hppa.c (elf32_hppa_check_relocs): Remove debug message.
871         (final_link_relocate): Likewise.
872
873 2002-04-22  Jakub Jelinek  <[email protected]>
874
875         * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't build
876         search table if some FDE is DW_EH_PE_aligned encoded either.
877         (_bfd_elf_write_section_eh_frame): Handle terminating FDE specially.
878
879 2002-04-22  Richard Smith  <[email protected]>
880             Jakub Jelinek  <[email protected]>
881
882         * elf-eh-frame.c (struct eh_cie_fde): Add per_encoding_relative.
883         (_bfd_elf_discard_section_eh_frame): Set it for CIEs with pcrel
884         encoded personality.
885         (_bfd_elf_write_section_eh_frame): Adjust pcrel encoded personality
886         for CIE/FDE removal.
887
888 2002-04-20  Tom Rix  <[email protected]>
889
890         * coff64-rs6000.c (_bfd_xcoff64_swap_aux_in): Fix C_FILE auxent.
891
892 2002-04-20  Alan Modra  <[email protected]>
893
894         * archures.c (bfd_lookup_arch): Move the list order comment..
895         (struct bfd_arch_info): ..to where it belongs.
896         * bfd-in2.h: Regenerate.
897
898         * archures.c (bfd_lookup_arch): Add comment on list order.
899         (bfd_default_set_arch_mach): Use bfd_lookup_arch.
900         * cpu-powerpc.c (bfd_powerpc_archs): Re-order so that the default
901         is always at head of list.
902
903 2002-04-18  Nick Clifton  <[email protected]>
904
905         * coff-arm.c (coff_thumb_pcrel_12, coff_thumb_pcrel_9,
906         insert_thumb_branch, record_thumb_to_arm_glue): Suppress
907         definition of these functions for ARM_WINCE builds as they are
908         not used.
909         (SWAP_IN_RELOC_OFFSET, SWAP_OUT_RELOC_OFFSET): Do not define
910         for ARM_WINCE builds.
911
912 2002-04-18  Nick Clifton  <[email protected]>
913
914         * coff-arm.c (bfd_arm_process_before_allocation):
915
916 2002-04-17  J"orn Rennecke <[email protected]>
917
918         * cpu-sh.c (scan_mach): Delete.
919         (arch_info_struct): Replace scan_mach with bfd_default_scan.
920         (bfd_sh_arch): Likewise.
921
922 2002-04-16  Nick Clifton  <[email protected]>
923
924         * ihex.c (ihex_write_object_contents): Fix check for records
925         crossing 64K boundaries.
926
927 2002-04-16  Alan Modra  <[email protected]>
928
929         * elf32-m32r.c (m32r_elf_add_symbol_hook): Check the hash table
930         type rather than just assuming entries are ELF.
931         * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
932         * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
933         * elf64-sparc.c (sparc64_elf_add_symbol_hook): Likewise.
934         * elf64-mmix.c (mmix_elf_add_symbol_hook): Use bfd_link_hash_entry
935         rather than elf_link_hash_entry.
936
937 2002-04-15  Richard Henderson  <[email protected]>
938
939         * elf32-mips.c (mips_elf32_object_p): Revert 0404 fragment: allow
940         n32 binaries.
941
942 2002-04-15  Michael Snyder  <[email protected]>
943
944         * opncls.c (bfd_close): Write contents if writeable.
945         Minor formatting tidy-ups.
946
947 2002-04-15  Alan Modra  <[email protected]>
948
949         * elf32-ppc.c (ppc_elf_add_symbol_hook): Check the hash table type.
950
951 2002-04-12  Michael Snyder  <[email protected]>
952
953         * bfd-in.h (bfd_get_section_lma): New access macro.
954         Minor white-space fix-up.
955
956 2002-04-12  Alan Modra  <[email protected]>
957
958         * elf.c (prep_headers): Don't zero EI_OSABI, EI_ABIVERSION or
959         header pad.
960
961 2002-04-09  DJ Delorie  <[email protected]>
962
963         * elfarm-nabi.c (elf32_arm_howto_table): Fix ABS16 masks.
964
965 2002-04-09  Casper S. Hornstrup <[email protected]>
966
967         * coffcode.h (coff_read_word): New.
968         (coff_compute_checksum): New.
969         (coff_apply_checksum): New.
970         (coff_write_object_contents): Call coff_apply_checksum () to
971         apply checksum to PE image.
972
973 2002-04-08  Randolph Chung  <[email protected]>
974
975         * elf32-hppa.c (hppa_unwind_entry_compare): Move to elf-hppa.h.
976         (elf32_hppa_final_link): Split out sorting logic to..
977         * elf-hppa.h (elf_hppa_sort_unwind): ..here.
978         (elf_hppa_final_link): Call elf_hppa_sort_unwind.
979
980 2002-04-07  Andrew Cagney  <[email protected]>
981
982         * configure.in: Add missing ``|'' to powerpc-*-aix4.[4-9]*
983         pattern.
984         * configure: Re-generate.
985
986 2002-04-07  Andrew Cagney  <[email protected]>
987
988         * configure.in: Only define AIX_CORE_DUMPX_CORE when AIX version
989         is greater or equal to 4.3.3.
990         * configure: Regenerate.
991         Fix PR gdb/344.
992
993 2002-04-05  Hans-Peter Nilsson  <[email protected]>
994
995         * elf32-cris.c (cris_elf_howto_table) <R_CRIS_16_PCREL,
996         R_CRIS_32_PCREL>: Fix typo in name.
997         (cris_elf_check_relocs): Always create .rela.got here when
998         R_CRIS_16_GOTPLT or R_CRIS_32_GOTPLT is seen.
999         (elf_cris_adjust_gotplt_to_got): Don't create .rela.got here;
1000         assume it's created.
1001
1002 2002-04-04  Daniel Jacobowitz  <[email protected]>
1003
1004         * aout-adobe.c (aout_32_bfd_link_hash_table_free): Define.
1005         * aout-target.h (MY_bfd_link_hash_table_free): Conditionally
1006         define.
1007         * aout-tic30.c (MY_bfd_link_hash_table_free): Likewise.
1008         * bfd.c (bfd_link_hash_table_free): Define.
1009         * binary.c (binary_bfd_link_hash_table_free): Define.
1010         * bout.c (b_out_bfd_link_hash_table_free): Define.
1011         * coff-rs6000.c (rs6000coff_vec): Include
1012         _bfd_generic_link_hash_table_free.
1013         (pmac_xcoff_vec): Likewise.
1014         * coff64-rs6000.c (rs6000coff64_vec): Likewise.
1015         (aix5coff64_vec): Likewise.
1016         * coffcode.h (coff_bfd_link_hash_table_free): Conditionally define.
1017         * elf-m10300.c (elf32_mn10300_link_hash_table_free): New function.
1018         (bfd_elf32_bfd_link_hash_table_free): Define.
1019         * elf32-hppa.c (elf32_hppa_link_hash_table_free): New function.
1020         (bfd_elf32_bfd_link_hash_table_free): Define.
1021         * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_free): Conditionally
1022         define.
1023         * i386msdos.c (msdos_bfd_link_hash_table_free): Define.
1024         * i386os9k.c (os9k_bfd_link_hash_table_free): Define.
1025         * ieee.c (ieee_bfd_link_hash_table_free): Define.
1026         * ihex.c (ihex_bfd_link_hash_table_free): Define.
1027         * libbfd-in.h (_bfd_nolink_bfd_link_hash_table_free): Define.
1028         (_bfd_generic_link_hash_table_free): Add prototype.
1029         * libcoff-in.h (_bfd_xcoff_bfd_link_hash_table_free): Add prototype.
1030         * libecoff.h (_bfd_ecoff_bfd_link_hash_table_free): Define.
1031         * linker.c (_bfd_generic_link_hash_table_free): New function.
1032         * mmo.c (mmo_bfd_link_hash_table_free): Define.
1033         * nlm-target.h (nlm_bfd_link_hash_table_free): Define.
1034         * oasys.c (oasys_bfd_link_hash_table_free): Define.
1035         * ppcboot.c (ppcboot_bfd_link_hash_table_free): Define.
1036         * som.c (som_bfd_link_hash_table_free): Define.
1037         * srec.c (srec_bfd_link_hash_table_free): Define.
1038         * tekhex.c (tekhex_bfd_link_hash_table_free): Define.
1039         * versados.c (versados_bfd_link_hash_table_free): Define.
1040         * vms.c (vms_bfd_link_hash_table_free): New function.
1041         * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_free): New function.
1042
1043         * coff-arm.c (coff_arm_link_hash_table_create): Use bfd_malloc
1044         instead of bfd_alloc.
1045         * coff-h8300.c (h8300_coff_link_hash_table_create): Likewise.
1046         * coff-mcore.c (coff_mcore_link_hash_table_create): Likewise.
1047         * coff-ppc.c (ppc_coff_link_hash_table_create): Likewise.
1048         * cofflink.c (_bfd_coff_link_hash_table_create): Likewise.
1049         * ecoff.c (_bfd_ecoff_bfd_link_hash_table_create): Likewise.
1050         * elf-m10300.c (elf32_mn10300_link_hash_table_create): Likewise.
1051         * elf.c (_bfd_elf_link_hash_table_create): Likewise.
1052         * elf32-arm.h (elf32_arm_link_hash_table_create): Likewise.
1053         * elf32-cris.c (elf_cris_link_hash_table_create): Likewise.
1054         * elf32-hppa.c (elf32_hppa_link_hash_table_create): Likewise.
1055         * elf32-i386.c (elf_i386_link_hash_table_create): Likewise.
1056         * elf32-m68k.c (elf_m68k_link_hash_table_create): Likewise.
1057         * elf32-s390.c (elf_s390_link_hash_table_create): Likewise.
1058         * elf32-sh.c (sh_elf_link_hash_table_create): Likewise.
1059         * elf64-alpha.c (elf64_alpha_bfd_link_hash_table_create): Likewise.
1060         * elf64-ppc.c (ppc64_elf_link_hash_table_create): Likewise.
1061         * elf64-s390.c (elf_s390_link_hash_table_create): Likewise.
1062         * elf64-sh64.c (sh64_elf64_link_hash_table_create): Likewise.
1063         * elf64-sparc.c (sparc64_elf_bfd_link_hash_table_create): Likewise.
1064         * elf64-x86-64.c (elf64_x86_64_link_hash_table_create): Likewise.
1065         * elfxx-mips.c (_bfd_mips_elf_link_hash_table_create): Likewise.
1066         * linker.c (_bfd_generic_link_hash_table_create): Likewise.
1067         * m68klinux.c (linux_link_hash_table_create): Likewise.
1068         * sparclinux.c (linux_link_hash_table_create): Likewise.
1069         * sunos.c (sunos_link_hash_table_create): Likewise.
1070         * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Likewise.
1071
1072         * targets.c: Add _bfd_link_hash_table_free to xvec.
1073
1074         * bfd-in2.h: Regenerate.
1075         * libbfd.h: Regenerate.
1076         * libcoff.h: Regenerate.
1077
1078 2002-04-04  Alan Modra  <[email protected]>
1079
1080         * dep-in.sed: Cope with absolute paths.
1081         * Makefile.am (dep.sed): Subst TOPDIR, and not INCDIR.
1082         Run "make dep-am".
1083         * Makefile.in: Regenerate.
1084         * coff-arm.c: Fix copyright date.
1085         * cpu-h8300.c: Likewise.
1086         * cpu-i370.c: Likewise.
1087         * cpu-s390.c: Likewise.
1088         * cpu-mips.c: Likewise.
1089         * po/SRC-POTFILES.in: Regenerate.
1090
1091 2002-04-04  Thiemo Seufer <[email protected]>
1092
1093         * Makefile.am: Add elfxx-mips.c to the known backends.
1094         (elf32-mips.lo): remove dependency to coff/external.h.
1095         * Makefile.in: Regenerate.
1096         * configure.in: Add elfxx-mips.lo to all vectors using elf32-mips.lo
1097         Remove elf32-mips.lo from 64 bit vectors. Update dependencies
1098         accordingly.
1099         * configure: Regenerate.
1100         * elf-bfd.h: Move all MIPS ELF specific prototypes to elfxx-mips.h.
1101         (irix_compat_t): IRIX compatibility level, moved from elf32-mips.c.
1102         (elf_backend_mips_irix_compat, elf_backend_mips_rtype_to_howto): New
1103         MIPS specific backend functions.
1104         * elf32-mips.c: Moved most code to elfxx-mips.c.
1105         (mips_elf_hi16_reloc): Rename from _bfd_mips_elf_hi16_reloc and make
1106         static.
1107         (mips_elf_lo16_reloc): Likewise, was _bfd_mips_elf_lo16_reloc.
1108         (mips_elf_got16_reloc): Likewise, was _bfd_mips_elf_got16_reloc.
1109         (mips_elf_gprel32_reloc): Likewise, was _bfd_mips_elf_gprel32_reloc.
1110         (mips_elf32_rtype_to_howto): Rename from mips_rtype_to_howto. Changed
1111         interface to allow selection of the right REL or RELA howto table.
1112         (mips_elf32_object_p): Rename from _bfd_mips_elf_object_p and made
1113         static. Let it refuse n32 objects.
1114         (elf32_mips_grok_prstatus): Rename from _bfd_elf32_mips_grok_prstatus.
1115         (elf32_mips_grok_psinfo): Rename from _bfd_elf32_mips_grok_psinfo.
1116         (elf32_mips_discard_info): Rename from _bfd_elf32_mips_discard_info.
1117         (elf32_mips_ignore_discarded_relocs): Rename from
1118         _bfd_elf32_mips_ignore_discarded_relocs.
1119         (elf32_mips_write_section): Rename from _bfd_elf32_mips_write_section.
1120         (elf32_mips_irix_compat): New function, replaces IRIX_COMPAT.
1121         (elf_mips_howto_table_rela): Remove.
1122         * elf64-mips.c: Moved most code to elfxx-mips.c.
1123         (bfd_elf64_bfd_reloc_type_lookup): Make static.
1124         (mips_elf64_rtype_to_howto): New function.
1125         (mips_elf64_object_p): Likewise.
1126         (elf64_mips_irix_compat): Likewise.
1127         * elfxx-mips.c: New file containing common code merged together from
1128         elf32-mips.c and elf64-mips.c.
1129         * elfxx-mips.h: New file containing MIPS specific prototypes from
1130         elf-bfd.h.
1131         * elfxx-target.h: Add handling for elf_backend_mips_irix_compat and
1132         elf_backend_mips_rtype_to_howto.
1133
1134 2002-04-04  Alan Modra  <[email protected]>
1135
1136         * srec.c (MAXCHUNK, Chunk): Revise comments.
1137         (srec_write_record): Correct buffer size.
1138         (srec_write_header): Do without intermediate buffer.
1139         (srec_write_section): Validate Chunk.
1140         (srec_write_terminator): Pass NULL instead of dummy buffer.
1141         (srec_write_symbols): Pass file and symbol names directly to
1142         bfd_bwrite so sprintf won't overflow buffer.
1143
1144 2002-04-03  Jakub Jelinek  <[email protected]>
1145
1146         * elf32-sparc.c (elf32_sparc_relocate_section): Don't emit dynamic
1147         PC relative relocs against hidden symbols.
1148         * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
1149
1150 2002-04-03  Alan Modra  <[email protected]>
1151
1152         * elf.c (_bfd_elf_make_section_from_shdr): When setting section
1153         LMAs, loop over segments until p_vaddr and p_memsz specify an
1154         extent enclosing the section.
1155
1156 2002-04-02  Nick Clifton  <[email protected]>
1157
1158         * ihex.c (ihex_write_object_contents): Do not allow records to
1159         cross a 64K boundary - wrap if necessary.
1160
1161 2002-04-01  Nathan Williams  <[email protected]>
1162
1163         * elf.c (elfcore_netbsd_get_lwpid): Fix off-by-one error
1164         which caused the returned LWP ID to always be 0.
1165
1166 2002-04-01  Richard Henderson  <[email protected]>
1167
1168         * elf32-sparc.c (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
1169         (elf32_sparc_relocate_section): Use it to figure out when to
1170         initialize .got entries.
1171         * elf64-sparc.c: Similarly.
1172
1173 2002-03-28  Alan Modra  <[email protected]>
1174
1175         * linker.c (link_action): Ignore duplicate warning syms.
1176         (_bfd_generic_link_write_global_symbol): Follow warning symbol link.
1177         * elflink.h (elf_adjust_dynstr_offsets): Likewise.
1178         (elf_adjust_dynamic_symbol): Likewise.
1179         (elf_export_symbol): Likewise.
1180         (elf_link_find_version_dependencies): Likewise.
1181         (elf_link_assign_sym_version): Likewise.
1182         (elf_link_sec_merge_syms): Likewise.
1183         (elf_link_output_extsym): Likewise.
1184         (elf_gc_sweep_symbol): Likewise.
1185         (elf_gc_propagate_vtable_entries_used): Likewise.
1186         (elf_gc_smash_unused_vtentry_relocs): Likewise.
1187         (elf_gc_allocate_got_offsets): Likewise.
1188         (elf_collect_hash_codes): Likewise.
1189         * elflink.c (elf_link_renumber_hash_table_dynsyms): Likewise.
1190         * elf-hppa.h (elf_hppa_unmark_useless_dynamic_symbols): Likewise.
1191         (elf_hppa_remark_useless_dynamic_symbols): Likewise.
1192         * elf-m10300.c (elf32_mn10300_finish_hash_table_entry): Likewise.
1193         * elf32-arm.h (elf32_arm_discard_copies): Likewise.
1194         * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Likewise.
1195         (elf_cris_discard_excess_dso_dynamics): Likewise.
1196         * elf32-hppa.c (clobber_millicode_symbols): Likewise.
1197         (mark_PIC_calls): Likewise.
1198         (allocate_plt_static): Likewise.
1199         (allocate_dynrelocs): Likewise.
1200         (readonly_dynrelocs): Likewise.
1201         * elf32-i386.c (allocate_dynrelocs): Likewise.
1202         (readonly_dynrelocs): Likewise.
1203         * elf32-i370.c (i370_elf_adjust_dynindx): Likewise.
1204         * elf32-m68k.c (elf_m68k_discard_copies): Likewise.
1205         * elf32-mips.c (mips_elf_output_extsym): Likewise.
1206         (mips_elf_sort_hash_table_f): Likewise.
1207         (mips_elf_check_mips16_stubs): Likewise.
1208         * elf32-s390.c (allocate_dynrelocs): Likewise.
1209         (readonly_dynrelocs): Likewise.
1210         * elf32-sh.c (sh_elf_discard_copies): Likewise.
1211         * elf32-xstormy16.c (xstormy16_relax_plt_check): Likewise.
1212         (xstormy16_relax_plt_realloc): Likewise.
1213         * elf64-alpha.c (elf64_alpha_calc_got_offsets_for_symbol): Likewise.
1214         (elf64_alpha_output_extsym): Likewise.
1215         * elf64-hppa.c (elf64_hppa_mark_exported_functions): Likewise.
1216         * elf64-mips.c (mips_elf64_sort_hash_table_f): Likewise.
1217         (mips_elf64_check_mips16_stubs): Likewise.
1218         (mips_elf64_output_extsym): Likewise.
1219         * elf64-ppc.c (func_desc_adjust): Likewise.
1220         (allocate_dynrelocs): Likewise.
1221         (readonly_dynrelocs): Likewise.
1222         * elf64-s390.c (allocate_dynrelocs): Likewise.
1223         (readonly_dynrelocs): Likewise.
1224         * elf64-sh64.c (sh64_elf64_discard_copies): Likewise.
1225         * elf64-x86-64.c (allocate_dynrelocs): Likewise.
1226         (readonly_dynrelocs): Likewise.
1227         * elfxx-ia64.c (elfNN_ia64_global_dyn_sym_thunk): Likewise.
1228         * aoutx.h (aout_link_write_other_symbol): Likewise.
1229         * cofflink.c (_bfd_coff_write_task_globals): Likewise.
1230         (_bfd_coff_write_global_sym): Likewise.
1231         * i386linux.c (linux_tally_symbols): Likewise.
1232         * m68klinux.c (linux_tally_symbols): Likewise.
1233         * sparclinux.c (linux_tally_symbols): Likewise.
1234         * pdp11.c (aout_link_write_other_symbol): Likewise.
1235         * sunos.c (sunos_scan_dynamic_symbol): Likewise.
1236         * xcofflink.c (xcoff_build_ldsyms): Likewise.
1237         (xcoff_write_global_symbol): Likewise.
1238
1239         * cofflink.c (_bfd_coff_final_link): Formatting.
1240         * cpu-mips.c (mips_compatible): Make static, prototype.
1241         * elf32-i386.c (elf_i386_check_relocs): Formatting.
1242         * elf32-sh.c (sh_elf_size_dynamic_sections): Likewise.
1243         * elf64-alpha.c (elf64_alpha_output_extsym): Likewise.
1244         * elf64-mips.c (mips_elf64_sort_hash_table): Likewise.
1245         (mips_elf64_final_link): Likewise.
1246         * elflink.h (elf_link_find_version_dependencies): Remove duplicate
1247         prototype.
1248
1249 2002-03-27  Nick Clifton  <[email protected]>
1250
1251         * coff-arm.c (SWAP_IN_RELOC_OFFSET): Define.
1252         (SWAP_OUT_RELOC_OFFSET): Define.
1253
1254 2002-03-27  Gregory Steuck <[email protected]>
1255
1256         * elf.c (_bfd_elf_get_symtab_upper_bound): Leave space for
1257         terminating NULL if empty symbol table.
1258         (_bfd_elf_get_dynamic_symtab_upper_bound): Likewise.
1259
1260 2002-03-26  H.J. Lu  ([email protected])
1261
1262         * elflink.h (elf_link_input_bfd): Revert the last change since
1263         the gcc exception handling isn't fixed yet.
1264
1265 2002-03-26  H.J. Lu  ([email protected])
1266
1267         * elflink.h (elf_link_input_bfd): Complain about relocations
1268         against local symbols in discarded sections.
1269
1270 2002-03-26  Alan Modra  <[email protected]>
1271
1272         * elflink.h (elf_gc_mark): Don't recurse into non-ELF sections.
1273
1274 2002-03-23  Alan Modra  <[email protected]>
1275
1276         * elf.c (_bfd_elf_make_section_from_shdr): Don't set lma based on
1277         section file offset for !SEC_LOAD sections.
1278
1279 2002-03-21  Richard Earnshaw  <[email protected]>
1280
1281         * elf32-arm.h (elf32_arm_final_link_relocate <case R_ARM_GOTOFF>,
1282         <case R_ARM_GOT>): Handle relocations to Thumb functions.
1283
1284 2002-03-21  Alan Modra  <[email protected]>
1285
1286         * coff64-rs6000.c (_bfd_xcoff64_put_symbol_name): Prototype.
1287         Whitespace changes.
1288         * archive.c: Update copyright date.
1289         * bfd-in2.h: Regenerate.
1290         * libbfd.h: Regenerate.
1291         * Makefile.am: Run "make dep-am"
1292         * Makefile.in: Regenerate.
1293         * po/SRC-POTFILES.in: Regenerate.
1294
1295 2002-03-20  Daniel Jacobowitz  <[email protected]>
1296
1297         * dwarf2.c (struct funcinfo): Move up.
1298         (lookup_address_in_function_table): New argument function_ptr.
1299         Set it.
1300         (lookup_address_in_line_table): New argument function.  If function
1301         is non-NULL, use it to handle ``addr'' before the first line note of
1302         the function.
1303         (comp_unit_find_nearest_line): Update and swap calls to
1304         lookup_address_in_function_table and lookup_address_in_line_table.
1305         * syms.c (_bfd_stab_section_find_nearest_line): Use the first
1306         N_SLINE encountered if we see an N_FUN before any N_SLINE.
1307
1308 2002-03-20  Tom Rix  <[email protected]>
1309
1310         * coff-rs6000.c (_bfd_xcoff_stat_arch_elt): Renamed from
1311         _bfd_xcoff_generic_stat_arch_elt.  Fix format check.
1312         * coff64-rs6000.c :  Use _bfd_xcoff_stat_arch_elt.
1313
1314 2002-03-19  Tom Rix  <[email protected]>
1315
1316         * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Look through all
1317         dynamic objects in archives.
1318
1319 2002-03-19  Hans-Peter Nilsson  <[email protected]>
1320
1321         * elflink.h (NAME(bfd_elf,record_link_assignment)): Don't set
1322         STT_NOTYPE symbols to STT_OBJECT.
1323
1324 2002-03-18  Jan Hubicka  <[email protected]>
1325
1326         * cpu-i386.c (bfd_x86_64_arch): Rename to "i386:x86-64"
1327
1328 2002-03-18  Tom Rix  <[email protected]>
1329
1330         * aix5ppc.core.c : New file for AIX 5 64 bit core support.
1331         * bfd-in.h : Add bfd_xcoff_ar_archive_set_magic declaration.
1332         * coff-rs6000 (do_pad) : New function for archive padding.
1333         (do_copy) : New function for object file copying in archives.
1334         (do_shared_object_padding) : New function for padding shared
1335         objects to their text section alignment in archives.
1336         (bfd_xcoff_ar_achive_set_magic) : Stub.
1337         (xcoff_write_armap_big) : Use do_copy and do_pad.
1338         (xcoff_write_archive_contents_big) : Use do_shared_object_padding,
1339         do_copy and do_pad.
1340         * coff64-rs6000.c (xcoff64_write_ojbect_contents) : Use
1341         bfd_xcoff_magic_number.
1342         (xcoff64_bad_format_hook) : New function for _bfd_bad_format_hook
1343         fop.
1344         (xcoff_backend_data_r) : Use xcoff64_bad_format_hook.
1345         (bfd_xcoff_aix5_backend_data) : New Aix 5 backend data.
1346         (aix5coff64_vec) : New Aix 5 target aix5coff64-rs6000.
1347         * rs6000-core.c : Update copyright date.
1348         * xcofflink.c (bfd_xcoff_size_dynamic_sections): Check for NULL
1349         csectpp.
1350         * coffcode.h (coff_new_section_hook) : Use new accessor macros.
1351         (coff_set_arch_mach_hook) : Add Aix 5 U64_TOCMAGIC magic #.
1352         (coff_set_flags) : Use bfd_xcoff_magic_number.
1353         * libxcoff.h (bfd_xcoff_is_xcoff64): Add U64_TOCMAGIC.
1354         * configure.in : Add powerpc-*-aix5 and rs6000-*-aix5 support.
1355         * Makefile.am : Same.
1356         * config.bfd : Same.
1357         * targets.c : Same.
1358         * configure : Regnerate.
1359         * Makefile.in : Same.
1360         * bfd-in2.h : Same.
1361
1362 2002-03-18  Nick Clifton  <[email protected]>
1363
1364         * po/fr.po: Updated version.
1365
1366 2002-03-18  Alan Modra  <[email protected]>
1367
1368         * libbfd.c (bfd_write_bigendian_4byte_int): Return true iff success.
1369         * libbfd.h: Regenerate.
1370         * archive.c (coff_write_armap): Pass on failures from
1371         bfd_write_bigendian_4byte_int.
1372
1373 2002-03-14  H.J. Lu <[email protected]>
1374
1375         * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the BFD
1376         error to bfd_error_nonrepresentable_section for reinit_array
1377         section in DSO.
1378
1379 2002-03-14  Nick Clifton  <[email protected]>
1380
1381         * coffcode.h (coff_slurp_symbol_table): When adding BSF_WEAK flag,
1382         OR it in rather than replacing previously selected flags.
1383
1384         * elfxx-target.h (TARGET_BIG_SYM): Set ar_max_namelen to 15.
1385         (TARGET_LITTLE_SYM): Set ar_max_namelen to 15.
1386
1387 2002-03-14  Alan Modra  <[email protected]>
1388
1389         * cpu-mips.c (mips_compatible): New.  Don't check bits_per_word.
1390         (N): Use the above.
1391         * elflink.h (elf_bfd_final_link): Revert last change.  Instead,
1392         ensure reloc size matches before calling elf_link_input_bfd.
1393         Add an assert to check reloc size when counting output relocs.
1394
1395 2002-03-14  Nick Clifton  <[email protected]>
1396
1397         * mmo.c (mmo_get_loc): Return NULL rather than false.
1398
1399 2002-03-13  Nick Clifton  <[email protected]>
1400
1401         * po/fr.po: Updated version.
1402
1403 2002-03-13  Alan Modra  <[email protected]>
1404
1405         * archures.c (bfd_default_compatible): Test bits_per_word.
1406         * cpu-i386.c (i386_compatible): Remove.  Replace occurrences with
1407         bfd_default_compatible.
1408         * cpu-i370.c (i370_compatible): Likewise.
1409         * cpu-sparc.c (sparc_compatible): Likewise.
1410         * cpu-h8300.c (compatible): Test in->arch == out->arch.
1411
1412         * elflink.h: Formatting fixes.
1413         (elf_link_output_extsym): Merge undefined and undef weak cases.
1414
1415         * elflink.h (elf_bfd_final_link): Only call elf_link_input_bfd
1416         when word size of input matches output word size.
1417
1418 2002-03-12  Andreas Jaeger  <[email protected]>
1419
1420         * cpu-i386.c (i386_compatible): New.  Use it instead of
1421         bfd_default_compatible.
1422
1423 2002-03-07  H.J. Lu  ([email protected])
1424
1425         * coff-sh.c (shcoff_reloc_map): Use bfd_reloc_code_real_type
1426         as the type for bfd_reloc_val.
1427
1428 2002-03-05  John David Anglin  <[email protected]>
1429
1430         * elf-hppa.h (elf_hppa_is_dynamic_loader_symbol): New function.
1431         (elf_hppa_relocate_section): Ignore undefined dynamic loader symbols.
1432         (elf_hppa_final_link_relocate): Correct relocations for indirect
1433         references to local data through the DLT.  Fix .opd creation for
1434         local symbols using R_PARISC_LTOFF_FPTR32 and R_PARISC_FPTR64
1435         relocations.  Use e_lsel selector for R_PARISC_DLTIND21L,
1436         R_PARISC_LTOFF_FPTR21L and R_PARISC_LTOFF_TP21L as per
1437         "Processor-Specific ELF for PA_RISC, Version 1.43" document.
1438         Similarly, use e_rsel for DLT and LTOFF 'R' relocations.
1439         * elf32-hppa.c (final_link_relocate): Revise relocation selectors
1440         as per "Processor-Specific ELF for PA_RISC, Version 1.43" document.
1441
1442 2002-03-05  Jakub Jelinek  <[email protected]>
1443
1444         * merge.c (_bfd_merge_sections): Don't segfault if there
1445         is nothing to merge due to GC.
1446
1447 2002-03-05  Alan Modra  <[email protected]>
1448
1449         * elf32-hppa.c (clobber_millicode_symbols): Remove hack to keep
1450         symbols that have been forced local.
1451
1452         * elflink.h (elf_bfd_final_link): Call elf_link_output_extsym
1453         to output forced local syms for non-shared link.
1454         (elf_link_output_extsym): Tweak condition for calling backend
1455         adjust_dynamic_symbol so that previous behaviour is kept.
1456         Whitespace changes throughout file.
1457
1458 2002-03-04  H.J. Lu <[email protected]>
1459
1460         * elf.c (bfd_section_from_shdr): Handle special sections,
1461         .init_array, .fini_array and .preinit_array.
1462         (elf_fake_sections): Likewise.
1463
1464         * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Create the
1465         DT entry only if the section is in output for .init_array,
1466         .fini_array and .preinit_array. Complain about .preinit_array
1467         section in DSO.
1468         (elf_bfd_final_link): Warn zero size for .init_array,
1469         .fini_array and .preinit_array sections.
1470
1471         * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Remove
1472         SHT_INIT_ARRAY, SHT_FINI_ARRAY and SHT_PREINIT_ARRAY.
1473         (elfNN_ia64_fake_sections): Remove .init_array, .fini_array and
1474         .preinit_array.
1475
1476 2002-03-04  Alan Modra  <[email protected]>
1477
1478         * configure.in (WIN32LIBADD): Don't eval PICFLAG assignment.
1479         * configure: Regenerate.
1480
1481 2002-03-02  Tom Rix  <[email protected]>
1482
1483         * coff64-rs6000.c (xcoff64_howto_table): Replace howto types with
1484         symbolic equiv.
1485         * coff-rs6000.c (xcoff_howto_table): Same.
1486
1487 2002-03-01  David Mosberger  <[email protected]>
1488
1489         * elflink.h (size_dynamic_sections): If section named
1490         ".preinit_array" exists, create DT_PREINIT_ARRAY and
1491         DT_PREINIT_ARRAYSZ entries in dynamic table.  Analogously for
1492         ".init_array" and ".fini_array".
1493         (elf_bfd_final_link): Handle DT_PREINIT_ARRAYSZ, DT_INIT_ARRAYSZ,
1494         DT_FINI_ARRAYSZ, DT_PREINIT_ARRAY, DT_INIT_ARRAY, and
1495         DT_FINI_ARRAY.
1496
1497 2002-02-26  Andrew Macleod  <[email protected]>
1498
1499         * elflink.h (elf_bfd_final_link): Don't crash on SHN_UNDEF local
1500         dynsyms.
1501
1502 2002-02-25  Alan Modra  <[email protected]>
1503
1504         * elf64-hppa.h: Update copyright date.
1505
1506         * elf64-ppc.c (ppc64_elf_check_relocs): Warning fix.
1507         (ppc64_elf_relocate_section): Don't generate power4 style branch
1508         hints for *_BRTAKEN and *_BRNTAKEN relocs.
1509
1510 2002-02-22  Jakub Jelinek  <[email protected]>
1511
1512         * elf64-sh64.c (sh_elf64_relocate_section): Fix a typo from my
1513         last patch.
1514         * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
1515
1516 2002-02-21  Andreas Jaeger  <[email protected]>
1517
1518         * elf64-x86-64.c: Major rework that introduces all recent changes
1519         to the x86-64 backend.  Get a closer match to elf32-i386.
1520         (struct elf64_x86_64_dyn_relocs): Rename from
1521         elf64_x86_64_pcrel_relocs_copied, add additional fields.  Change
1522         all users.
1523         (struct elf64_x86_64_link_hash_table): Add short cuts to some
1524         sections.
1525         (link_hash_newfunc): Rename from elf64_x86_64_link_hash_newfunc,
1526         remove casts, initialize new hash members.
1527         (create_got_section): New.
1528         (elf64_x86_64_create_dynamic_sections): New.
1529         (elf64_x86_64_copy_indirect_symbol): New.
1530         (elf64_x86_64_check_relocs): Don't allocate space for dynamic
1531         relocs, .got or .relgot here but do it in allocate_dynrelocs.
1532         Reference count possible .plt and .got entries.  Don't test input
1533         section SEC_READONLY here to try to avoid copy relocs, and keep
1534         dyn_relocs regardless of ELF_LINK_NON_GOT_REF.  Don't set
1535         DF_TEXTREL here.  Delay setting of variables until needed.  Cache
1536         pointer to "sreloc" section in elf_section_data. Tweak condition
1537         under which .got created.  Report files with bad relocation
1538         section names.
1539         (elf64_x86_64_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
1540         Reference count possible .plt entries.  Don't deallocate .got and
1541         .relgot space here.
1542         (elf64_x86_64_adjust_dynamic_symbol): Handle nocopyreloc.  Don't
1543         do copy reloc processing for weakdefs.  Remove redundant casts and
1544         aborts.  Delay setting of vars until needed.  Move creation of
1545         dynamic symbols and allocation of .plt and .rela.plt to
1546         allocate_dynrelocs.  Replace BFD_ASSERT with abort.
1547         (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
1548         (allocate_dynrelocs): New.
1549         (readonly_dynrelocs): New.
1550         (elf64_x86_64_size_dynamic_sections): Call readonly_dynrelocs.
1551         Allocate space for dyn relocs.  Replace BFD_ASSERT with abort.
1552         Zero out the dynamic allocated content space.
1553         (elf64_x86_64_discard_copies): Removed.
1554         (elf64_x86_64_relocate_section): Make use of dynamic section
1555         short-cuts.  Localise vars, and delay setting.  Better error
1556         reporting, replace BFD_ASSERT with abort.  Check
1557         ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined in the
1558         regular object file and tread the weak definition as the normal
1559         one.  Don't discard relocs for undefweak or undefined symbols and
1560         check !DEF_REGULAR as well as DEF_DYNAMIC in test for avoided copy
1561         relocs.
1562         (elf64_x86_64_finish_dynamic_symbol): Don't copy relocs for
1563         symbols that have been forced local.  Use same test to decide if
1564         we can use a relative reloc for got as relocate_section.  Expand
1565         SHN_UNDEF comment.  Move expressions out of function calls.
1566         Replace BFD_ASSERT with abort.
1567         (bfd_elf64_bfd_final_link): Removed.
1568         (elf_backend_copy_indirect_symbol): Define.
1569
1570 2002-02-20  Tom Rix  <[email protected]>
1571
1572         * coff-rs6000.c (xcoff_howto_table): Add 16 bit R_BA.
1573         (_bfd_xcoff_reloc_type_lookup): Use it.
1574         * coff64-rs6000.c (xcoff64_howto_table): Same.
1575         (xcoff64_reloc_type_lookup): Same.
1576
1577 2002-02-20  Peter Schauer  <[email protected]>
1578
1579         * osf-core.c (osf_core_vec):  OSF/1 (Digital Unix) core files are
1580         little endian.
1581
1582 2002-02-19  Martin Schwidefsky  <[email protected]>
1583
1584         * archures.c (bfd_mach_s390_esa): Rename to bfd_mach_s390_31.
1585         (bfd_mach_s390_esame): Rename to bfd_mach_s390_64.
1586         * bfd-in2.h: Regenerate.
1587         * cpu-s390.c (arch_info_struct): Use renamed architecture defines.
1588         Replace architecture name "s390" with "s390:31-bit" and "s390:esame"
1589         with "s390:64-bit".
1590         * elf32-s390.c (elf_howto_table): Add 32 bit pc relative relocations.
1591         (elf_s390_reloc_type_lookup): Likewise.
1592         (elf_s390_check_relocs): Likewise.
1593         (elf_s390_gc_sweep_hook): Likewise.
1594         (elf_s390_relocate_section): Likewise.
1595         (elf_s390_object_p): Use renamed architecture define.
1596         * elf64-s390.c (elf_s390_object_p): Use renamed architecture define.
1597
1598 2002-02-19  Frank Ch. Eigler  <[email protected]>
1599
1600         * syms.c (stt[]): Sorted.  Added .init/.fini -> "t" mapping.
1601
1602 2002-02-19  Jakub Jelinek  <[email protected]>
1603
1604         * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Enable
1605         absptr -> pcrel optimization for shared libs.
1606         Only create minimal .eh_frame_hdr if absptr FDE encoding in shared
1607         library cannot be converted to pcrel.
1608         (_bfd_elf_eh_frame_section_offset): Return -2 if making absptr
1609         relative.
1610         * elf32-i386.c (elf_i386_relocate_section): If
1611         _bfd_elf_section_offset returned -2, skip, but make sure the
1612         relocation is installed.
1613         * elf32-arm.h (elf32_arm_final_link_relocate): Likewise.
1614         * elf32-cris.c (cris_elf_relocate_section): Likewise.
1615         * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
1616         * elf32-i370.c (i370_elf_relocate_section): Likewise.
1617         * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
1618         * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
1619         * elf32-s390.c (elf_s390_relocate_section): Likewise.
1620         * elf32-sh.c (sh_elf_relocate_section): Likewise.
1621         * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
1622         * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
1623         * elf64-s390.c (elf_s390_relocate_section): Likewise.
1624         * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
1625         * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
1626         * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
1627         * elf64-alpha.c (elf64_alpha_relocate_section): Handle
1628         _bfd_elf_section_offset returning -2 the same way as -1.
1629         * elfxx-ia64.c (elfNN_ia64_install_dyn_reloc): Likewise.
1630         * elf32-mips.c (mips_elf_create_dynamic_relocation): Add FIXME
1631         and BFD_ASSERT.
1632         * elf64-mips.c (mips_elf64_create_dynamic_relocation): Likewise.
1633
1634 2002-02-18  Tom Rix  <[email protected]>
1635
1636         * xcofflink.c (bfd_xcoff_link_gernate_rtinit): Add -brtl support.
1637         (bfd_xcoff_size_dynamic_sections): Same.
1638         * bfd-in.h (bfd_xcoff_link_generate_rtinit): Same.
1639         (bfd_xcoff_size_dynamic_sections): Same.
1640         * coff-rs6000.c (xcoff_generate_rtinit): Same.
1641         * coff-rs646000.c (xcoff64_generate_rtinit): Same.
1642         * libxcoff.h (struct xcoff_backend_data_rec): Same.
1643         * xcofflink.c (xcoff_build_ldsyms, xcoff_link_add_symbols): Clean.
1644         * bfd-in2.h: Regenerate.
1645
1646 2002-02-18  Alan Modra  <[email protected]>
1647
1648         * elf64-ppc.c (STFD_FR0_0R1, LFD_FR0_0R1, BLR): Define.
1649         (struct ppc_link_hash_table): Add sfpr.
1650         (ppc64_elf_link_hash_table_create): Init it.
1651         (ppc64_elf_create_dynamic_sections): Split creation of .stub and
1652         .glink out to..
1653         (create_linkage_sections): ..here.  Make .sfpr too.
1654         (ppc64_elf_check_relocs): Call create_linkage_sections, and set
1655         dynobj early.
1656         (MIN_SAVE_FPR, MAX_SAVE_FPR): Define.
1657         (ppc64_elf_func_desc_adjust): Look for missing ._savef* and
1658         ._restf* functions, and create as needed.
1659         (func_desc_adjust): Only force_local for shared libs.
1660
1661 2002-02-18  David O'Brien  <[email protected]>
1662
1663         * configure.in: Bump version number post 2.12 branching.
1664         * configure: Regenerate.
1665
1666 2002-02-17  Hans-Peter Nilsson  <[email protected]>
1667
1668         * mmo.c: Correct and improve comments.
1669         (mmo_write_chunk): Store trailing byte in bfd buffer; don't
1670         zero-pad.  Use input to fill up non-empty bfd buffer.
1671         (mmo_flush_chunk): New function.
1672         (mmo_write_loc_chunk): Add parameter last_vmap, all callers
1673         changed.  Don't emit location specifier if VMA is same as
1674         *LAST_VMAP after omitting leading zero contents.  Call
1675         mmo_flush_chunk before emitting location specifier.
1676         (mmo_write_loc_chunk_list): Call mmo_flush_chunk when finished
1677         with mmo_write_loc_chunk calls.
1678         (mmo_internal_write_section): Call mmo_flush_chunk after
1679         mmo_write_chunk.
1680         (mmo_write_symbols_and_terminator): Move :Main to first position
1681         in symbol array.  Add faked one if it does not exist if there are
1682         other symbols.  Don't add it if there are no symbols at all.  Move
1683         out test for value of :Main from symbol loop.  Rename table
1684         fakemain to maintable and variable mainsym to fakemain.
1685
1686 2002-02-15  Richard Henderson  <[email protected]>
1687
1688         * elf64-alpha.c (elf64_alpha_relocate_section) [BRSGP]: A target
1689         section with no got matches any got.  Simplify error generaion.
1690
1691 2002-02-15  Alan Modra  <[email protected]>
1692
1693         Support arbitrary length fill patterns.
1694         * linker.c (bfd_new_link_order): Zero all fields with bfd_zalloc.
1695         (_bfd_default_link_order): Remove bfd_fill_link_order code.
1696         Call default_data_link_order.
1697         (default_fill_link_order): Delete.
1698         (default_data_link_order): New function.
1699         * elf32-mips.c (_bfd_mips_elf_final_link): Replace occurrences
1700         of bfd_fill_link_order with bfd_data_link_order.
1701         * elf64-alpha.c (elf64_alpha_final_link): Likewise.
1702         * elf64-mips.c (mips_elf64_final_link): Likewise.
1703
1704         * bfd.c (bfd_scan_vma): Clamp overflows to max bfd_vma value.
1705         Correct value returned in "end" for "0x<non-hex>".
1706
1707 2002-02-14  Nick Clifton  <[email protected]>
1708
1709         * cpu-arm.c (processors): Replace 'arch' field with 'mach'.
1710         (scan): Test against 'mach' field in info structure.
1711
1712 2002-02-14  Alan Modra  <[email protected]>
1713
1714         * elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD.
1715
1716 2002-02-14  Matt Fredette  <[email protected]>
1717
1718         * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Recognize
1719         EF_M68000.
1720
1721 2002-02-13  Nick Clifton  <[email protected]>
1722
1723         * elf.c (_bfd_elf_make_section_from_shdr): Do not insist on
1724         non-zero physical addresses when adjusting the LMAs of new
1725         sections.
1726
1727 2002-02-12  John David Anglin  <[email protected]>
1728
1729         * elf-hppa.h (elf_hppa_reloc_final_type): New function stripped
1730         from _bfd_elf_hppa_gen_reloc_type.
1731         (_bfd_elf_hppa_gen_reloc_type): Remove duplicate prototype.
1732         * elf32-hppa.h (elf32_hppa_reloc_final_type): Add protptype.
1733         * elf32-hppa.c: Include elf32-hppa.h before elf-hppa.h.
1734         * elf64-hppa.h (elf64_hppa_reloc_final_type): Add protptype.
1735
1736 2002-02-12  Alexandre Oliva  <[email protected]>
1737
1738         * elf-m10300.c (mn10300_elf_relax_section): Skip section before
1739         loading its contents if there's nothing to do in it.
1740
1741 2002-02-12  Alan Modra  <[email protected]>
1742
1743         * elf64-ppc.c (ppc64_elf_size_stubs): Correct test for crossing
1744         64k boundary.
1745
1746         * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Add dynamic
1747         DT_PPC64_OPD and DT_PPC64_OPDSZ tags.
1748         (ppc64_elf_finish_dynamic_sections): Set values for them.
1749
1750 2002-02-11  Michael Snyder  <[email protected]>
1751
1752         * elf-bfd.h (elfcore_write_lwpstatus): Add prototype.
1753         * elf.c (elfcore_grok_pstatus): Add prototype.
1754         (elfcore_grok_lwpstatus): Add prototype.
1755         (elfcore_write_lwpstatus): New function.
1756         (elfcore_write_pstatus): Fix typo, eliminate unnecessary memcpy.
1757
1758 2002-02-11  Alexandre Oliva  <[email protected]>
1759
1760         * elf32-sh.c: Added missing prototypes.
1761         * elf32-sh64.c: Likewise.
1762         (sh_elf_align_loads): Mark unused args as such.
1763         * elf64-sh64.c: Added missing prototypes.
1764         (struct elf_sh64_link_hash_entry): Fix typo.
1765         (sh_elf64_relocate_section): Fix info argument passed to
1766         _bfd_elf_section_offset.
1767
1768 2002-02-11  Alan Modra  <[email protected]>
1769
1770         * Makefile.am: "make dep-am".
1771         * Makefile.in: Regenerate.
1772         * aclocal.m4: Regenerate.
1773         * config.in: Regenerate.
1774         * configure: Regenerate.
1775
1776 2002-02-10  Daniel Jacobowitz  <[email protected]>
1777
1778         * coff-rs6000.c (xcoff_generate_rtinit): Silence uninitialized
1779         variable warnings.
1780         * elf32-sh.c (sh_elf_relax_section): Silence signed/unsigned
1781         comparison warning.
1782         * trad-core.c (trad_unix_core_file_p): Silence pointer/integer
1783         cast warnings for the common case.
1784
1785 2002-02-10  Hans-Peter Nilsson  <[email protected]>
1786
1787         * config.bfd (sh-*-linux*, sh-*-elf* | sh-*-rtemself*): Add sh64
1788         vectors.
1789         (sh-*-netbsdelf*): New, to trump sh*-*-netbsdelf* and add sh64
1790         vectors.
1791
1792 2002-02-09  Richard Henderson  <[email protected]>
1793
1794         * elf64-alpha.c (elf64_alpha_howto): Add R_ALPHA_BRSGP.
1795         (elf64_alpha_reloc_map, elf64_alpha_check_relocs): Likewise.
1796         (elf64_alpha_relocate_section): Likewise.
1797         * reloc.c (BFD_RELOC_ALPHA_BRSGP): New.
1798         * bfd-in2.h, libbfd.h: Rebuild.
1799
1800 2002-02-09  Hans-Peter Nilsson  <[email protected]>
1801
1802         * elf64-mmix.c (_bfd_mmix_finalize_linker_allocated_gregs): Check
1803         that base-plus-offset reloc accounting is consistent.
1804         (mmix_elf_relax_section): Keep base-plus-offset reloc accounting
1805         up to date for undefined symbols.
1806
1807 2002-02-08  Eric Christopher  <[email protected]>
1808
1809         From Rainer Orth  <[email protected]>
1810
1811         * elf32-mips.c (_bfd_mips_elf_fake_sections): Don't create .rela
1812         sections for the O32 ABI.
1813
1814 2002-02-08  Chris Demetriou  <[email protected]>
1815
1816         * elf32-arm.h: Fix formatting of _("...").
1817         * elf32-d10v.c: Likewise.
1818         * elf32-m68k.c: Likewise.
1819         * elf32-mips.c: Likewise.
1820
1821 2002-02-08  Ivan Guzvinec <[email protected]>
1822
1823         * coff-or32.c: Fix compile time warning messages.
1824
1825 2002-02-08  Alexandre Oliva  <[email protected]>
1826
1827         Contribute sh64-elf.
1828         2002-01-23  Alexandre Oliva  <[email protected]>
1829         * reloc.c (R_SH_GOTPLT32, R_SH_GOT_LOW16, R_SH_GOT_MEDLOW16,
1830         R_SH_GOT_MEDHI16, R_SH_GOT_HI16, R_SH_GOTPLT_LOW16,
1831         R_SH_GOTPLT_MEDLOW16, R_SH_GOTPLT_MEDHI16, R_SH_GOTPLT_HI16,
1832         R_SH_PLT_LOW16, R_SH_PLT_MEDLOW16, R_SH_PLT_MEDHI16,
1833         R_SH_PLT_HI16, R_SH_GOTOFF_LOW16, R_SH_GOTOFF_MEDLOW16,
1834         R_SH_GOTOFF_MEDHI16, R_SH_GOTOFF_HI16, R_SH_GOTPC_LOW16,
1835         R_SH_GOTPC_MEDLOW16, R_SH_GOTPC_MEDHI16, R_SH_GOTPC_HI16,
1836         R_SH_GOT10BY4, R_SH_GOTPLT10BY4, R_SH_GOT10BY8, R_SH_GOTPLT10BY8,
1837         R_SH_COPY64, R_SH_GLOB_DAT64, R_SH_JMP_SLOT64, R_SH_RELATIVE64):
1838         New relocs.
1839         * libbfd.h, bfd-in2.h: Rebuilt.
1840         * elf32-sh.c (sh_elf_howto_table): Define new relocs.
1841         (sh_reloc_map): Map them.
1842         (PLT_ENTRY_SIZE, elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
1843         elf_sh_plt_entry_be, elf_sh_plt_entry_le, elf_sh_pic_plt_entry_be,
1844         elf_sh_pic_plt_entry_le, elf_sh_plt0_entry, elf_sh_plt_entry,
1845         elf_sh_pic_plt_entry, elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
1846         elf_sh_plt0_gotplt_offset, elf_sh_plt_temp_offset,
1847         elf_sh_plt_symbol_offset, elf_sh_plt_reloc_offset,
1848         movi_shori_putval) [INCLUDE_SHMEDIA]: New.
1849         (elf_sh_link_hash_entry) [INCLUDE_SHMEDIA]: Add
1850         datalabel_got_offset.
1851         (sh_elf_link_hash_newfunc): Initialize it.
1852         (sh_elf_relocate_section): Augment the scope of
1853         seen_stt_datalabel.  Introduce GOTPLT support.  Extend GOTPC, PLT,
1854         GOT and GOTOFF handling to new SHmedia relocation types.  Support
1855         GOT_BIAS.
1856         (sh_elf_check_relocs): Likewise.
1857         (sh_elf_finish_dynamic_symbol) [TARGET_SHMEDIA]: Set up values in
1858         PLT entries using movi_shori_putval.  Support GOT_BIAS.
1859         (sh_elf_finish_dynamic_sections): Likewise.
1860         * elf32-sh64.c (shmedia_prepare_reloc): Do not add addend to
1861         relocation, it's now done by the caller.
1862         (GOT_BIAS): New.
1863         * elf64-sh64.c (GOT_BIAS, PLT_ENTRY_SIZE, elf_sh64_sizeof_plt,
1864         elf_sh64_plt_plt0_offset, elf_sh64_plt0_gotplt_offset,
1865         elf_sh64_plt_temp_offset, elf_sh64_plt_symbol_offset,
1866         elf_sh64_plt_reloc_offset, ELF_DYNAMIC_INTERPRETER,
1867         elf_sh64_pcrel_relocs_copied, elf_sh64_link_hash_entry,
1868         elf_sh64_link_hash_table, sh64_elf64_link_hash_traverse,
1869         sh64_elf64_hash_table): New.
1870         (sh_elf64_howto_table): Introduce new relocs.
1871         (sh_elf64_info_to_howto): Accept new PIC relocs.
1872         (sh_elf64_relocate_section): Augment the scope of
1873         seen_stt_datalabel.  Support new PIC relocs.
1874         (sh_elf64_check_relocs): Support new PIC relocs.
1875         (elf_sh64_plt0_entry_be, elf_sh64_plt0_entry_le,
1876         elf_sh64_plt_entry_be, elf_sh64_plt_entry_le,
1877         elf_sh64_pic_plt_entry_be, elf_sh64_pic_plt_entry_le,
1878         elf_sh64_plt0_entry, elf_sh64_plt_entry, elf_sh64_pic_plt_entry,
1879         sh64_elf64_link_hash_newfunc, sh64_elf64_link_hash_table_create,
1880         movi_shori_putval, movi_3shori_putval,
1881         sh64_elf64_create_dynamic_sections,
1882         sh64_elf64_adjust_dynamic_symbol, sh64_elf64_discard_copies,
1883         sh64_elf64_size_dynamic_sections,
1884         sh64_elf64_finish_dynamic_symbol,
1885         sh64_elf64_finish_dynamic_sections): New.
1886         (elf_backend_create_dynamic-sections,
1887         bfd_elf64_bfd_link_hash_table_create,
1888         elf_backend_adjust_dynamic_symbol,
1889         elf_backend_size_dynamic_sections,
1890         elf_backend_finish_dynamic_symbol,
1891         elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
1892         elf_backend_plt_readonly, elf_backend_want_plt_sym,
1893         elf_backend_got_header_size, elf_backend_plt_header_size):
1894         Define.
1895         2001-05-16  Alexandre Oliva  <[email protected]>
1896         * elf32-sh.c: Renumbered and renamed some SH5 relocations to
1897         match official numbers and names; moved unmaching ones to the
1898         range 0xf2-0xff.
1899         * elf32-sh64.c, elf64-sh64.c: Likewise.
1900         2001-03-12  DJ Delorie  <[email protected]>
1901         * elf32-sh.c (sh_elf_relax_section): Don't relax SHmedia
1902         sections.
1903         2001-03-12  DJ Delorie  <[email protected]>
1904         * elf32-sh64.c (shmedia_prepare_reloc): Validate relocs that must
1905         be aligned.
1906         * elf64-sh64.c (sh_elf64_relocate_section): Ditto.
1907         2001-01-14  Hans-Peter Nilsson  <[email protected]>
1908         * elf32-sh64.c (bfd_elf32_bfd_copy_private_section_data): Define.
1909         (sh64_elf_fake_sections): Set type to SHT_SH5_CR_SORTED for a
1910         .cranges section with SEC_SORT_ENTRIES set.
1911         (sh64_backend_section_from_shdr): Set SEC_SORT_ENTRIES on an
1912         incoming sorted .cranges section.
1913         (sh64_bfd_elf_copy_private_section_data): New.
1914         (sh64_elf_final_write_processing): Only sort .cranges and modify
1915         start address if called by linker.
1916         2001-01-08  Ben Elliston  <[email protected]>
1917         * elf32-sh64.c (sh64_elf_final_write_processing): Activate
1918         Hans-Peter Nilsson's set bit 0 patch from       2001-01-06.
1919         * elf64-sh64.c (sh64_elf64_final_write_processing): Ditto.
1920         2001-01-06  Hans-Peter Nilsson  <[email protected]>
1921         * elf64-sh64.c (sh_elf64_howto_table): No open brace at start of
1922         line.  Add comments before all entries.
1923         <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct and clarify describing
1924         comment.
1925         (sh_elf64_reloc): Correct head comment.
1926         (sh_elf64_relocate_section): Correct spacing.
1927         <relocating for a local symbol>: Do not honour STO_SH5_ISA32;
1928         instead call reloc_dangerous callback.
1929         <case R_SH_SHMEDIA_CODE>: New case.
1930         (sh_elf64_gc_mark_hook): Correct spacing.
1931         (sh_elf64_check_relocs): Ditto.
1932         * elf32-sh64.c (shmedia_prepare_reloc) <case R_SH_SHMEDIA_CODE>:
1933         New case.
1934         * elf32-sh.c: Correct #endif comments for #ifndef-wrapped
1935         functions.
1936         (sh_elf_howto_table) <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct,
1937         clarify describing comment.  Add comments before all entries.
1938         (sh_elf_relocate_section) <relocating for a local symbol>: Do not
1939         honour STO_SH5_ISA32; instead call reloc_dangerous callback.
1940         2001-01-06  Hans-Peter Nilsson  <[email protected]>
1941         Sort .cranges section in final link.  Prepare to set bit 0 on
1942         entry address.
1943         * elf32-sh64.c (struct sh64_find_section_vma_data): New.
1944         (sh64_elf_link_output_symbol_hook): Fix typo in prototype.
1945         (sh64_elf_set_mach_from_flags): Set SEC_DEBUGGING on incoming
1946         .cranges section.
1947         (sh64_backend_section_from_shdr): New, to recognize
1948         SHT_SH5_CR_SORTED on incoming .cranges section.
1949         (elf_backend_section_from_shdr): Define.
1950         (sh64_elf_final_write_processing): Sort outgoing .cranges
1951         section.  (New, temporarily disabled:) Set bit 0 on entry address
1952         according to ISA type.
1953         (sh64_find_section_for_address): New.
1954         (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb,
1955         crange_bsearch_cmpl): Move here from opcodes/sh64-dis.c.
1956         (sh64_address_in_cranges): Move here from opcodes/sh64-dis.c.  Use
1957         bfd_malloc, not xmalloc.
1958         (sh64_get_contents_type): Move here from opcodes/sh64-dis.c.  Make
1959         global.
1960         * elf32-sh64.c (sh64_elf64_final_write_processing): New, (but
1961         temporarily disabled) setting bit 0 on entry address.
1962         (elf_backend_final_write_processing): Define.
1963         2001-01-05  Hans-Peter Nilsson  <[email protected]>
1964         * elf32-sh.c (sh_elf_howto_table) <R_SH_PT_16>: Adjust fields to
1965         be a proper relocation for PTA and PTB rather than a marker.
1966         <R_SH_IMMU5, R_SH_IMMS6, R_SH_IMMU6, R_SH_IMMS10, R_SH_IMMS10BY2,
1967         R_SH_IMMS10BY4, R_SH_IMMS10BY8, R_SH_IMMS16, R_SH_IMMU16,
1968         R_SH_IMM_LOW16, R_SH_IMM_LOW16_PCREL, R_SH_IMM_MEDLOW16,
1969         R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16, R_SH_IMM_MEDHI16_PCREL,
1970         R_SH_IMM_HI16, R_SH_IMM_HI16_PCREL, R_SH_64, R_SH_64_PCREL>:
1971         Zero src_mask.
1972         * elf64-sh64.c: Ditto.
1973         (sh_elf64_relocate_section) <case R_SH_PT_16>: New case.
1974         * elf32-sh64.c: Include opcodes/sh64-opc.h
1975         (shmedia_prepare_reloc): Take a bfd_link_info pointer as first
1976         argument.  Drop const qualifiers from "bfd *" and "bfd_byte *"
1977         parameters.  No unused parameters.  Caller changed.
1978         <case R_SH_PT_16>: New case.
1979         * Makefile.am (elf32-sh64.lo): Add dependency on sh64-opc.h.
1980         * Makefile.in: Regenerate.
1981         2000-12-30  Hans-Peter Nilsson  <[email protected]>
1982         * elf64-sh64.c (sh64_elf64_fake_sections): Set SHF_SH5_ISA32 for
1983         all code sections.
1984         (sh_elf64_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
1985         (sh64_elf_merge_private_data): Ditto.
1986         * elf32-sh64.c (sh64_elf_fake_sections): Use sh64_elf_section_data
1987         to access stored section flags.
1988         (sh64_elf_final_write_processing): Return immediately unless
1989         called by linker.  Use sh64_elf_section_data (cranges) to get size
1990         of linker-generated cranges entries.
1991         (sh64_elf_copy_private_data): Add missing "return true".
1992         (sh64_elf_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
1993         (sh_elf64_merge_private_data): Ditto.
1994         2000-12-19  Hans-Peter Nilsson  <[email protected]>
1995         * elf64-sh64.c (sh64_elf64_fake_sections): New, copy of
1996         elf64-sh64.c:sh64_elf_fake_sections.
1997         (elf_backend_fake_sections): Define as sh64_elf64_fake_sections.
1998         2000-12-18  Hans-Peter Nilsson  <[email protected]>
1999         * elf32-sh64.c (sh64_elf_copy_private_data_internal): Delete.
2000         (sh64_elf_final_write_processing): New.
2001         (elf_backend_final_write_processing): Define.
2002         (sh64_elf_fake_sections): Get header flags from tdata field.
2003         (sh64_elf_copy_private_data): Do not call
2004         sh64_elf_copy_private_data_internal, just copy e_flags field.
2005         (sh64_elf_merge_private_data): Do not call
2006         sh64_elf_copy_private_data_internal.
2007         2000-12-12  Hans-Peter Nilsson  <[email protected]>
2008         Remove EF_SH64_ABI64, let ELF size make difference.
2009         Remove SH64-specific BFD section flag.
2010         * elf32-sh64.c (sh64_elf_fake_sections): Recognize section as
2011         containing SHmedia through elf_section_data (asect)->tdata
2012         non-zero, not using a BFD section flag.
2013         (sh64_elf_set_mach_from_flags): Don't recognize EF_SH64_ABI64.
2014         (sh64_elf_merge_private_data): Similar.
2015         (elf_backend_section_flags): Don't define.
2016         (sh64_elf_backend_section_flags): Delete.
2017         * elf64-sh64.c (sh_elf64_set_mach_from_flags): Recognize EF_SH64,
2018         not EF_SH64_ABI64.
2019         (sh_elf64_merge_private_data): Similar.
2020         * section.c (Section flags definitions): Don't define
2021         SEC_SH_ISA_SHMEDIA.
2022         (bfd-in2.h): Regenerate.
2023         2000-12-09  Hans-Peter Nilsson  <[email protected]>
2024         Make DataLabel references work with partial linking.
2025         * elf32-sh64.c: Fix formatting.
2026         (sh64_elf_link_output_symbol_hook): New.
2027         (elf_backend_link_output_symbol_hook): Define to
2028         sh64_elf_link_output_symbol_hook.
2029         (sh64_elf_add_symbol_hook): Make DataLabel symbol just global
2030         undefined if partial linking.  Adjust sanity check.
2031         * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): New.
2032         (elf_backend_link_output_symbol_hook): Define to
2033         sh64_elf64_link_output_symbol_hook.
2034         (sh64_elf64_add_symbol_hook): Make DataLabel symbol just global
2035         undefined if partial linking.  Adjust sanity check.
2036         2000-12-07  Hans-Peter Nilsson  <[email protected]>
2037         Implement semantics for inter-file DataLabel references.
2038         * elf64-sh64.c (DATALABEL_SUFFIX): Define.
2039         (sh64_elf64_add_symbol_hook): New.
2040         (sh_elf64_relocate_section): If passing an indirect symbol with
2041         st_type STT_DATALABEL on the way to a symbol with st_other
2042         STO_SH5_ISA32, do not bitor 1 to the relocation.
2043         (elf_backend_add_symbol_hook): Define to
2044         sh64_elf64_add_symbol_hook.
2045         * elf64-sh32.c: Tweak comments.
2046         (DATALABEL_SUFFIX): Define.
2047         (sh64_elf_add_symbol_hook): New.
2048         (elf_backend_add_symbol_hook): Define to sh64_elf_add_symbol_hook.
2049         * elf32-sh.c (sh_elf_relocate_section): If passing an indirect
2050         symbol with st_type STT_DATALABEL on the way to a symbol with
2051         st_other STO_SH5_ISA32, do not bitor 1 to the relocation.
2052         2000-12-05  Hans-Peter Nilsson  <[email protected]>
2053         Pass through STT_DATALABEL.
2054         * elf32-sh64.c (sh64_elf_get_symbol_type): New.
2055         (elf_backend_get_symbol_type): Define.
2056         * elf64-sh64.c (sh64_elf64_get_symbol_type): New.
2057         (elf_backend_get_symbol_type): Define.
2058         2000-11-30  Hans-Peter Nilsson  <[email protected]>
2059         * elf32-sh64.c: Tweak comments.
2060         (sh64_elf_copy_private_data_internal): Add prototype.
2061         (bfd_elf32_bfd_set_private_flags): Define.
2062         (sh64_elf_copy_private_data_internal): Compare machine name, not
2063         textual BFD target name, to check whether to copy section flag
2064         SHF_SH5_ISA32.
2065         (sh64_elf_merge_private_data): Validize bfd_get_arch_size.
2066         Tweak section-contents-type-mismatch message.
2067         (shmedia_prepare_reloc): Add ATTRIBUTE_UNUSED markers.
2068         Validize reloc-types.
2069         * elf64-sh64.c: New file.
2070         * targets.c (bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec): Declare.
2071         * Makefile.am (BFD64_BACKENDS): Add elf64-sh64.lo.
2072         (BFD64_BACKENDS_CFILES): Add elf64-sh64.c.
2073         Regenerate dependencies.
2074         * Makefile.in: Regenerate.
2075         * config.bfd (sh64-*-elf*): Add bfd_elf64_sh64_vec and
2076         bfd_elf64_sh64l_vec.
2077         * configure.in: Handle bfd_elf64_sh64_vec and
2078         bfd_elf64_sh64l_vec.
2079         * configure: Regenerate.
2080         * po/POTFILES.in: Regenerate.
2081         * po/bfd.pot: Regenerate.
2082         2000-11-29  Hans-Peter Nilsson  <[email protected]>
2083         * elf32-sh64.c (sh64_elf_set_mach_from_flags): Do not recognize
2084         anything else but EF_SH64 and EF_SH64_ABI64.
2085         (sh64_elf_merge_private_data): Emit error for anything else but
2086         EF_SH64 and EF_SH64_ABI64.
2087         * config.bfd: Remove bfd_elf32_shblin_vec and bfd_elf32_shlin_vec
2088         from targ_selvecs.
2089         * configure.in: Add cofflink.lo to bfd_elf32_sh64_vec and
2090         bfd_elf32_sh64l_vec as a temporary measure.
2091         * configure: Regenerate.
2092         2000-11-27  Hans-Peter Nilsson  <[email protected]>
2093         * cpu-sh.c (arch_info_struct): Include sh5 item
2094         unconditionalized.
2095         * config.bfd (sh64-*-elf*): Do not set targ_cflags.
2096         Add targ_selvecs bfd_elf32_sh_vec, bfd_elf32_shl_vec,
2097         bfd_elf32_shblin_vec and bfd_elf32_shlin_vec.
2098         * elf32-sh64.c: Tweak comments.
2099         (sh64_elf_set_mach_from_flags): Recognize all machine flags that
2100         are proper subsets of SH64 as bfd_mach_sh5.  Add EF_SH64_ABI64.
2101         (sh64_elf_copy_private_data_internal): Wrap long line.
2102         (sh64_elf_merge_private_data): Rewrite to allow objects from
2103         SH64 subsets to be linked together.
2104         (INCLUDE_SHMEDIA): Define.
2105         * elf32-sh.c (sh_elf_relocate_section) <local symbol>:
2106         Parenthesize plus-expression inside or-expression.
2107         <global symbol>: Ditto.
2108         (sh_elf_set_mach_from_flags): Remove code refusing
2109         deleted EF_SH64_32BIT_ABI flag.
2110         2000-11-26  Hans-Peter Nilsson  <[email protected]>
2111         * elf32-sh.c (sh_elf_howto_table) <R_SH_IMM_LOW16_PCREL,
2112         R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16_PCREL,
2113         R_SH_IMM_HI16_PCREL, R_SH_64_PCREL>: Set pcrel_offset to true.
2114         (sh_elf_relocate_section) <local symbol>: Or 1 in
2115         calculation of relocation if sym->st_other & STO_SH5_ISA32.
2116         <global symbol>: Ditto if h->other & STO_SH5_ISA32.
2117         * elf32-sh64.c (shmedia_prepare_reloc): Add rel->r_addend to
2118         relocation.
2119         2000-11-24  Hans-Peter Nilsson  <[email protected]>
2120         * Makefile.am (BFD32_BACKENDS): Add elf32-sh64.lo.
2121         (BFD32_BACKENDS_CFILES): Add elf32-sh64.c.
2122         Regenerate dependencies.
2123         * Makefile.in: Regenerate.
2124         * archures.c: Add bfd_mach_sh5.
2125         * config.bfd: Map targ_cpu sh* to bfd_sh_arch.
2126         Handle sh64-*-elf*.  Set targ_cflags to -DINCLUDE_SHMEDIA.
2127         * configure.in: Handle bfd_elf32_sh64_vec and bfd_elf32_sh64l_vec.
2128         * configure: Regenerate.
2129         * reloc.c (BFD_RELOC_SH_SHMEDIA_CODE, BFD_RELOC_SH_IMMU5,
2130         BFD_RELOC_SH_IMMS6, BFD_RELOC_SH_IMMS6BY32, BFD_RELOC_SH_IMMU6,
2131         BFD_RELOC_SH_IMMS10, BFD_RELOC_SH_IMMS10BY2,
2132         BFD_RELOC_SH_IMMS10BY4, BFD_RELOC_SH_IMMS10BY8,
2133         BFD_RELOC_SH_IMMS16, BFD_RELOC_SH_IMMU16, BFD_RELOC_SH_IMM_LOW16,
2134         BFD_RELOC_SH_IMM_LOW16_PCREL, BFD_RELOC_SH_IMM_MEDLOW16,
2135         BFD_RELOC_SH_IMM_MEDLOW16_PCREL, BFD_RELOC_SH_IMM_MEDHI16,
2136         BFD_RELOC_SH_IMM_MEDHI16_PCREL, BFD_RELOC_SH_IMM_HI16,
2137         BFD_RELOC_SH_IMM_HI16_PCREL, BFD_RELOC_SH_PT_16): New relocations.
2138         * cpu-sh.c [INCLUDE_SHMEDIA] (arch_info_struct): Define and link
2139         in item for SH5.
2140         * elf32-sh.c [INCLUDE_SHMEDIA] (sh_elf_howto_table): Add howto items
2141         for SHmedia relocs.
2142         [INCLUDE_SHMEDIA] (sh_rel): Add mappings for SHmedia relocs.
2143         [INCLUDE_SHMEDIA] (sh_elf_relocate_section) [default]: Call
2144         shmedia_prepare_reloc, goto final_link_relocate if it returns
2145         non-zero, else fail as before.
2146         (sh_elf_set_mach_from_flags): Provide function only if not defined
2147         as macro.  Do not recognize objects with EF_SH64_32BIT_ABI set.
2148         (sh_elf_set_private_flags): Provide function only if not defined
2149         as a macro.
2150         (sh_elf_copy_private_data): Similar.
2151         (sh_elf_merge_private_data): Similar.
2152         * section.c (SEC_SH_ISA_SHMEDIA): New.
2153         * targets.c (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec): Declare.
2154         * elf32-sh64.c: New file.
2155         * libbfd.h: Regenerate.
2156         * bfd-in2.h: Regenerate.
2157         * po/POTFILES.in: Regenerate.
2158         * po/bfd.pot: Regenerate.
2159         * bfd-in2.h: Regenerate.
2160         * libbfd.h: Regenerate.
2161
2162 2002-02-07  Daniel Jacobowitz  <[email protected]>
2163
2164         * bfd-in.h: Update <stdbool.h> check to only see if <stdbool.h> has
2165         been included, not drag it in.
2166         * bfd-in2.h: Regenerate.
2167
2168 2002-02-06  H.J. Lu  ([email protected])
2169
2170         * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Update
2171         the mach and ISA fields if necessary.
2172
2173 2002-02-06  Nick Clifton  <[email protected]>
2174
2175         * coffcode.h (coff_set_arch_mach_hook): Select the highest known
2176         ARM architecture when an F_ARM_5 flag is detected, since we cannot
2177         be sure exactly which architecture this represents.
2178
2179 2002-02-05  Nick Clifton  <[email protected]>
2180
2181         * po/tr.po: Updated translation.
2182
2183 2002-02-05  Alan Modra  <[email protected]>
2184
2185         From Jimi X <[email protected]>
2186         * archures (bfd_mach_ppc64): Define.
2187         (bfd_powerpc_arch): Rename to bfd_powerpc_archs.
2188         (bfd_powerpc_arch): Define.
2189         * bfd-in2.h: Regenerate.
2190         * cpu-powerpc.c (arch_info_struct): Rename to bfd_powerpc_archs.
2191         (bfd_powerpc_arch): Move to tail of bfd_powerpc_archs.
2192         (bfd_powerpc_archs): Add default powerpc64 arch.
2193
2194 2002-02-05  Alan Modra  <[email protected]>
2195
2196         * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Check for relocs
2197         against section syms in readonly sections.  Don't do the global
2198         sym check if we find one.
2199         * elf64-s390.c (elf_s390_size_dynamic_sections): Likewise.
2200         * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Likewise.
2201         * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
2202         * elf32-s390.c (elf_s390_size_dynamic_sections): Likewise.
2203         (elf_s390_grok_prstatus): Add missing prototype.
2204
2205 2002-02-04  Hans-Peter Nilsson  <[email protected]>
2206
2207         * elf64-mmix.c (mmix_dump_bpo_gregs): New function.
2208         (mmix_elf_check_common_relocs) <case R_MMIX_BASE_PLUS_OFFSET>:
2209         Call bfd_get_section_by_name only once.  Initialize
2210         bpodata->n_bpo_relocs_this_section.
2211         (_bfd_mmix_prepare_linker_allocated_gregs): Remove comment
2212         referring to DSOs.
2213         (bpo_reloc_request_sort_fn): Don't use difference of values as
2214         return-value.
2215
2216 2002-02-02  David O'Brien  <obrien@FreeBSD>
2217
2218         * configure.in: Tweak the FreeBSD 4.x recognition more.  Only treat
2219         version 4.5 and later the same as 5-CURRENT.
2220         * configure: Re-generate.
2221
2222 2002-02-02  Jason Thorpe  <[email protected]>
2223
2224         * config.bfd (hppa*-*-netbsd*): New target.
2225
2226 2002-01-31  Philipp Thomas  <[email protected]>
2227
2228         * coff-arm.c (coff_arm_merge_private_bfd_data): Move ERROR
2229         to front of message. Unify messages with elf32-arm.h. Use
2230         commas where neccessary.
2231         * elf32-arm.h (elf32_arm_merge_private_bfd_data): Use all upcase
2232         ERROR in messages. Unify messages with coff-arm.c. Correct
2233         VFP/FPA error message.
2234         (elf32_arm_print_private_bfd_data): Don't mark APCS-26 and
2235         APCS-32 for translation.
2236
2237 2002-02-01  Hans-Peter Nilsson  <[email protected]>
2238
2239         Perform on-demand global register allocation from
2240         R_MMIX_BASE_PLUS_OFFSET relocs.
2241         * elf64-mmix.c (struct bpo_reloc_section_info, struct
2242         bpo_reloc_request, struct bpo_greg_section_info): New.
2243         (mmix_elf_check_common_relocs, mmix_elf_gc_sweep_hook,
2244         bpo_reloc_request_sort_fn, mmix_elf_relax_section,
2245         _bfd_mmix_check_all_relocs,
2246         _bfd_mmix_prepare_linker_allocated_gregs,
2247         _bfd_mmix_finalize_linker_allocated_gregs): New functions.
2248         (elf_mmix_howto_table): Correct src_mask for most relocs.
2249         (mmix_elf_perform_relocation) <case R_MMIX_BASE_PLUS_OFFSET>: New
2250         case.
2251         (mmix_final_link_relocate) <case R_MMIX_BASE_PLUS_OFFSET>: New
2252         case.  Fix typo in comment.  New label do_mmix_reloc.
2253         (mmix_elf_check_relocs): Abuse bfd_link_info member base_file to
2254         store first object file with a base-plus-offset reloc.  Call
2255         mmix_elf_check_common_relocs for the part common with mmo.
2256         (mmix_elf_final_link): Write out linker-allocated register
2257         contents section.
2258         (elf_backend_gc_sweep_hook): Define.
2259         (bfd_elf64_bfd_relax_section): Define.
2260
2261         * mmo.c: Don't include <ctype.h>
2262         (mmo_init): Correct init-once logic.
2263
2264 2002-02-01  Tom Rix  <[email protected]>
2265
2266         * config.bfd: Conditionally support <aiaff> for pre AIX 4.3.
2267
2268 2002-02-01  Alan Modra  <[email protected]>
2269
2270         * Makefile.am: Run "make dep-am"
2271         * Makefile.in: Regenerate.
2272
2273 2002-01-31  David O'Brien  <obrien@FreeBSD>
2274
2275         * configure.in: Recognize the differences in core files from FreeBSD
2276         4.{0,1} and later versions of 4.x.  This treats 4.2+ the same as
2277         5-CURRENT.
2278         * configure: Regenerate.
2279
2280 2002-01-31  Ivan Guzvinec  <[email protected]>
2281
2282         * coff-or32.c: New file.
2283         * cpu-or32.c: New file.
2284         * elf32-or32.c: New file.
2285         * archures.c: Add support for or32.
2286         * targets.c: Add support for or32.
2287         * bfd-in2.h: Regenerate.
2288         * coffcode.h (coff_set_arch_mach_hook, coff_set_flags,
2289         coff_write_object_contents): Add support for or32.
2290         * config.bfd: Add target.
2291         * configure.in: Add support for or32.
2292         * configure: Regenerate.
2293         * Makefile.am: Add support for or32.
2294         * Makefile.in: Regenerate.
2295         * po/SRC-POTFILES.in: Add or32 files.
2296         * po/bfd.pot: Regenerate.
2297
2298 2002-01-31  Nick Clifton  <[email protected]>
2299             Don Lindsay  <[email protected]>
2300
2301         * elf32-mips.c (mips_elf_calculate_relocation): Replace 'return
2302         false' with a return of a bfd_reloc_ error code.
2303
2304 2002-01-31  Hans-Peter Nilsson  <[email protected]>
2305
2306         * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Don't
2307         unexport unreferenced symbols when --export-dynamic.  Call
2308         _bfd_elf_strtab_delref when unexporting.
2309
2310 2002-01-30  Daniel Jacobowitz  <[email protected]>
2311
2312         * bfd-in.h: Include <stdbool.h> if it is available.
2313         * bfd-in2.h: Regenerated.
2314
2315 2002-01-31  Alan Modra  <[email protected]>
2316
2317         * elf64-ppc.c (func_desc_adjust): STV_PROTECTED functions should
2318         not go via the plt.
2319
2320 2002-01-30  Nick Clifton  <[email protected]>
2321
2322         * archures.c: Tidy up formatting of embedded comments.
2323         * bfd.c: Tidy up formatting of embedded comments.
2324         * bfd-in.h: Fix formatting of comments.
2325         * reloc.c: Tidy up formatting of ordinary & embedded comments.
2326         * section.c: Tidy up formatting of embedded comments.
2327         * syms.c: Tidy up formatting of embedded comments.
2328         * targets.c: Tidy up formatting of embedded comments.
2329
2330         * bfd-in2.h: Regenerate.
2331
2332 2002-01-30  Nick Clifton  <[email protected]>
2333
2334         * vms-tir.c (cmd_name): New function.
2335         (tir_cmd_name): New function.
2336         (etir_sta, etir_sto, etir_opr, etir_stc): Use cmd_name().
2337         (tir_opr, tir_ctl, tir_cmd): use tir_cmd_name().
2338         Fix formatting.
2339
2340         * peXXigen.c (pe_print_idata): Rearrange message to aid in
2341         translation.
2342         (pe_print_pdata):  Rearrange message to aid in translation.
2343
2344         * libbfd.c (warn_deprecated): Rearrange error message to aid in
2345         translation.
2346
2347         * ihex.c (ihex_write_object_contents): Fix spelling typo.
2348
2349         * ieee.c (ieee_slurp_external_symbols): Remove spurious space.
2350
2351         * elf64-sparc.c (sparc64_elf_add_symbol_hook): Rearrange error
2352         message to aid in translation.
2353
2354         * elf64-mmix.c (mmix_final_link_relocate): Rearrange error message
2355         to aid in translation.
2356
2357         * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix typo.
2358
2359 2002-01-30  Philipp Thomas  <[email protected]>
2360
2361         * coff-arm.c, elf32-elf.h: Unify messages.
2362
2363 2002-01-30  Nick Clifton <[email protected]>
2364
2365         * po/sv.po: Updated translation.
2366
2367 2002-01-30  Philipp Thomas  <[email protected]>
2368
2369         * dwarf2.c (read_abbrev): Use full section name in error message.
2370         (decode_line_info): Likewise.
2371
2372         * elf.c (_bfd_elf_symbol_from_bfd_symbol): Don't translate debugging
2373         message.
2374
2375 2002-01-30  Alan Modra  <[email protected]>
2376
2377         * elf64-ppc.c (func_desc_adjust): Only provide missing function
2378         descriptor symbols for undefined function code syms.  Clear
2379         ELF_LINK_NON_ELF so that they can stay weak.
2380
2381 2002-01-29  Chris Demetriou  <[email protected]>
2382             Mitch Lichtenberg  <[email protected]>
2383
2384         * bfd-in.h (bfd_mips_elf32_create_embedded_relocs): New prototype.
2385         * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): New function
2386         to handle 32-bit ELF embedded reloc (ld --embedded-relocs)
2387         generation.
2388         * bfd-in2.h: Regenerate.
2389
2390 2002-01-29  Chris Demetriou  <[email protected]>
2391
2392         * elf32-mips.c: Add additional comments about HI16 relocation
2393         processing.
2394         (_bfd_mips_elf_hi16_reloc): Don't subtract address here for
2395         pc-relative relocations.  (Reverts change made on 2001-10-31.)
2396         (_bfd_mips_elf_lo16_reloc): Subtract address of LO16 part here
2397         for pc-relative relocations.
2398         (mips_elf_calculate_relocation): Add a comment about a kludge
2399         in the R_MIPS_GNU_REL_HI16 handling.
2400         (_bfd_mips_elf_relocate_section): Implement that kludge;
2401         adjust pc-relative HI16 relocation for difference in HI16 and
2402         LO16 addresses, since it can't easily be done in
2403         mips_elf_calculate_relocation.
2404
2405 2002-01-29  Martin Schwidefsky  <[email protected]>
2406
2407         * elf32-i386 (elf_i386_adjust_dynamic_symbol): Do not replace PLT32
2408         relocations with PC32 relocations for undefined or weak symbols.
2409         * elf32-s390 (elf_i386_adjust_dynamic_symbol): Likewise.
2410         * elf64-s390x (elf_i386_adjust_dynamic_symbol): Likewise.
2411
2412 2002-01-28  Jason Thorpe  <[email protected]>
2413
2414         * elfcore.h (elf_core_file_p): Improve comment for last change.
2415
2416 2002-01-27  Daniel Jacobowitz  <[email protected]>
2417
2418         * configure: Regenerated.
2419
2420 2002-01-27  Jason Thorpe  <[email protected]>
2421
2422         * elfcore.h (elf_core_file_p): Set the machine architecture
2423         before processing the program headers.
2424
2425 2002-01-26  Hans-Peter Nilsson  <[email protected]>
2426
2427         * configure.in <64-bit configuration>: If using gcc, check and
2428         emit error for egcs-1.1.2.
2429         * configure: Regenerate.
2430
2431 2002-01-26  Egor Duda  <[email protected]>
2432
2433         * elf.c (elfcore_grok_win32pstatus): Copy only as much information
2434         as possible to avoid stack corruption.
2435
2436 2002-01-26  Richard Henderson  <[email protected]>
2437
2438         * elf64-alpha.c (elf64_alpha_check_relocs): Don't set reltext
2439         for non-allocated sections.
2440
2441 2002-01-25  Mark Kettenis  <[email protected]>
2442
2443         * elf.c (elfcore_write_prstatus): Make sure we pass the address of
2444         prstat.pr_reg even if it is a struct.
2445
2446 2002-01-25  Steve Ellcey <[email protected]>
2447
2448         * bfd/elfxx-ia64.c: Reset AIX vector function overrides for HP-UX.
2449
2450 2002-01-25  Philipp Thomas  <[email protected]>
2451
2452         * coffgen.c (coff_print_symbol): Don't mark info message
2453         for translation.
2454
2455 2002-01-25  Nick Clifton <[email protected]>
2456
2457         * po/fr.po: Updated translation.
2458         * po/es.po: Updated translation.
2459
2460 2002-01-25  Philipp Thomas  <[email protected]>
2461
2462         * coff-alpha.c (alpha_relocate_section): Unify warning message
2463         for GP relative relocations without GP defined.
2464         * coff-mips.c (mips_relocate_section): Likewise.
2465
2466 2002-01-25  Alan Modra  <[email protected]>
2467
2468         * elf-eh-frame.c (_bfd_elf_eh_frame_section_offset): Avoid
2469         unsigned overflow when new_offset < old_offset.
2470
2471 2002-01-24  Philipp Thomas  <[email protected]>
2472
2473         * bfd.c (_bfd_abort): Fix typo.
2474
2475 2002-01-23  Richard Henderson  <[email protected]>
2476
2477         * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't suppress
2478         plt entries for undefweak symbols.
2479
2480 2002-01-23  Steve Ellcey <[email protected]>
2481
2482         * bfd/targets.c (bfd_elf32_ia64_hpux_big_vec): Add to
2483         DEFAULT_VECTOR.
2484         (bfd_elf64_ia64_hpux_big_vec): Ditto.
2485         (bfd_elf32_h8300_vec): Ditto.
2486
2487 2002-01-23  Alan Modra  <[email protected]>
2488
2489         * elf64-ppc.c: Remove stale part of ABI comment.
2490         (NO_OPD_RELOCS): Define.
2491         (ppc64_elf_check_relocs): Use it.
2492         (ppc64_elf_relocate_section): Here too.
2493         (build_one_stub): Don't point function syms at the stub.  Instead,
2494         hijack plt.offset.
2495         (ppc64_elf_relocate_section): Check whether REL24 relocs should
2496         really go to the stub.  Make all dynamic relocs in opd against
2497         locals.
2498         (ppc64_elf_finish_dynamic_symbol): Allow for non-standard use of
2499         plt.offset.
2500
2501 2002-01-22  Richard Henderson  <[email protected]>
2502
2503         * elf64-alpha.c (INSN_UNOP): Encode with RB as $sp.
2504
2505 2002-01-22  Alan Modra  <[email protected]>
2506
2507         * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Correct sign of
2508         TOC_BASE_OFF adjustment.
2509
2510         * Makefile.am: Run "make dep-am".
2511         * Makefile.in: Regenerate.
2512         * po/SRC-POTFILES.in: Regenerate.
2513
2514 2002-01-22  John David Anglin  <[email protected]>
2515
2516         * configure.host (hppa*64*-*-hpux*, hppa*64*-*-linux*): Add new
2517         host defines.
2518
2519 2002-01-21  Hans-Peter Nilsson  <[email protected]>
2520
2521         * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_32_GOTREL>:
2522         Check for and emit error if sgot is NULL at this point.
2523
2524 2002-01-21  Jason Thorpe  <[email protected]>
2525
2526         * config.bfd (ia64*-*-netbsd*): New target.
2527
2528 2002-01-21  Thomas Klausner <[email protected]>
2529
2530         * som.c (som_write_space_strings): Comment typo fix.
2531
2532 2002-01-21  Alan Modra  <[email protected]>
2533
2534         * elf64-ppc.c (struct ppc_link_hash_entry): Add is_func and
2535         is_func_descriptor fields.
2536         (link_hash_newfunc): Init them.
2537         (ppc64_elf_check_relocs): Only R_PPC24_REL24 syms starting with a
2538         dot are candidates for plt entries.  When processing .opd relocs,
2539         set function descriptor strings to point inside function code
2540         string, and set new ppc_link_hash_entry fields.
2541         (ppc64_elf_gc_sweep_hook): Don't sweep R_PPC64_REL24 relocs.
2542         (ppc64_elf_adjust_dynamic_symbol): Remove most code dealing with
2543         function descriptors.  It's now done in..
2544         (func_desc_adjust): New.
2545         (ppc64_elf_func_desc_adjust): New.
2546         (define elf_backend_always_size_sections): Define.
2547         (ppc64_elf_hide_symbol): New.
2548         (define elf_backend_hide_symbol): Define.
2549         (allocate_dynrelocs): Remove code looking up function descriptors
2550         as that has been done earlier.
2551         (ppc64_elf_size_dynamic_sections): Use htab shortcut to elf hash
2552         table.
2553         (ppc64_elf_finish_dynamic_symbol): Likewise.  Remove code looking
2554         up function descriptor.
2555         (build_one_stub): Look up the function code sym.  Check for
2556         invalid plt offsets.
2557         (ppc64_elf_relocate_section): Tweak calls to undefined weak syms.
2558         Convert R_PPC64_TOC relocs to R_PPC64_RELATIVE in shared libs.
2559
2560         * elf-bfd.h (elf_backend_data <elf_backend_hide_symbol>): Add
2561         boolean param.
2562         (_bfd_elf_link_hash_hide_symbol): Likewise.
2563         * elflink.h (elf_link_add_object_symbols): Adjust call to
2564         elf_backend_hide_symbol.
2565         (elf_fix_symbol_flags): Likewise.
2566         (elf_link_assign_sym_version): Likewise. Use bfd_malloc rather
2567         than bfd_alloc.
2568         * elf.c (_bfd_elf_link_hash_hide_symbol): Add "force_local" param.
2569         Set ELF_LINK_FORCED_LOCAL and call _bfd_elf_strtab_delref.
2570         * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
2571         (clobber_millicode_symbols): Adjust to suit new hide_symbol.
2572         * elf32-cris.c (elf_cris_hide_symbol): Add "force_local" param
2573         and adjust to suit.
2574         * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise, and call
2575         _bfd_elf_link_hash_hide_symbol rather than duplicating code.
2576         * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
2577
2578 2002-01-18  Alan Modra  <[email protected]>
2579
2580         * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Test for a
2581         dynamic function descriptor symbol, not the associated function
2582         symbol.
2583
2584 2002-01-17  Eric Christopher  <[email protected]>
2585
2586         * elf32-mips.c (mips_elf_calculate_relocation): Fix typo.
2587
2588 2002-01-17  Nick Clifton  <[email protected]>
2589
2590         * po/bfd.pot: Regenerate.
2591         * po/fr.po: Regenerate.
2592
2593 2002-01-17  Alan Modra  <[email protected]>
2594
2595         * elf-bfd.h (elf_backend_data <elf_backend_section_from_bfd_section>):
2596         Remove "Elf_Internal_Shdr *" param.
2597         (_bfd_mips_elf_section_from_bfd_section): Ditto.
2598         * elf32-mips.c (_bfd_mips_elf_section_from_bfd_section): Ditto.
2599         * elf32-m32r.c (_bfd_m32r_elf_section_from_bfd_section): Ditto.
2600         * elf32-v850.c (v850_elf_section_from_bfd_section): Ditto.
2601         * elf64-mmix.c (mmix_elf_section_from_bfd_section): Ditto.
2602         * elfxx-ia64.c (elfNN_hpux_backend_section_from_bfd_section): Ditto.
2603         * elf.c (_bfd_elf_section_from_bfd_section): Allow backend
2604         function to override special sections.  Remove hdr arg from
2605         backend call, and don't loop.
2606
2607 2002-01-16  Eric Christopher  <[email protected]>
2608
2609         * elf32-mips.c (mips_elf_calculate_relocation): Set require_jalxp
2610         on R_MIPS_26 and target is 16bit. Add R_MIPS16_GPREL to list of
2611         relocations requiring gp0 and gp.
2612
2613 2002-01-16  Richard Earnshaw  <[email protected]>
2614
2615         * elf32-arm.h (elf32_arm_merge_private_bfd_data): Handle
2616         EF_ARM_VFP_FLOAT.
2617         (elf32_arm_print_private_bfd_data): Likewise.
2618
2619 2002-01-16  Nick Clifton  <[email protected]>
2620
2621         * po/tr.po: Import new version.
2622
2623 2002-01-16  Alan Modra  <[email protected]>
2624
2625         * elf64-ppc.c (ppc64_elf_howto_raw): Remove stale FIXMEs.
2626         (ppc64_elf_reloc_type_lookup): Use proper CTOR reloc.
2627         (ORI_R0_R0_0): Correct.
2628
2629 2002-01-16  Alan Modra  <[email protected]>
2630
2631         * elflink.c (_bfd_elf_create_dynamic_sections): Don't set SEC_CODE
2632         when plt_not_loaded.
2633         * elf64-ppc.c (ppc64_elf_create_dynamic_sections): No need to
2634         clear .plt SEC_CODE here.  Create .stub and correct .glink flags.
2635         (PLT_INITIAL_ENTRY_SIZE): Set to 24.
2636         (ppc64_elf_glink_code): Delete.
2637         (PPC64_ELF_GLINK_SIZE): Delete.
2638         (ADDIS_R12_R2, STD_R2_40R1, LD_R11_0R12, LD_R2_0R12, MTCTR_R11,
2639         BCTR, ADDIS_R12_R12_1, LD_R2_40R1, NOP, LI_R0_0, B_DOT, LIS_R0_0,
2640         ORI_R0_R0_0): Define.
2641         (PLT_CALL_STUB_SIZE, GLINK_CALL_STUB_SIZE): Define.
2642         (struct ppc_link_hash_table): Add sstub and plt_overflow.
2643         (ppc64_elf_link_hash_table_create): Init them.
2644         (ppc64_elf_check_relocs <R_PPC64_REL24>): Refcount .plt entry.
2645         Don't copy to shared lib.
2646         (ppc64_elf_check_relocs): Call bfd_set_error on errors.
2647         (ppc64_elf_gc_sweep_hook <R_PPC64_REL24>): Sweep plt refcount.
2648         (allocate_dynrelocs <plt>): Don't change function sym here.  Make
2649         room for .stub and .glink code.
2650         (ppc64_elf_size_dynamic_sections): Handle .stub.  Make entry for
2651         DT_PPC64_GLINK.
2652         (ppc64_elf_final_link): Rename to ppc64_elf_set_toc.  Don't call
2653         bfd_elf64_bfd_final_link.
2654         (bfd_elf64_bfd_final_link): Don't define.
2655         (ppc64_elf_size_stubs): New.
2656         (build_plt_stub): New.
2657         (build_one_stub): New.
2658         (ppc64_elf_build_stubs): New.
2659         (ppc64_elf_relocate_section <toc relocs>): Remove assert.
2660         (ppc64_elf_relocate_section): Don't copy R_PPC64_REL24 relocs.
2661         (ppc64_elf_finish_dynamic_symbol): Don't build stubs here.  Set
2662         DT_PPC64_GLINK entry.  Tweak DT_PLTGOT, DT_JMPREL, DT_PLTRELSZ in
2663         case output sections not separate.  Adjust DT_RELASZ to not
2664         include plt relocs.  Set reserved got entry.  Set got and plt
2665         entry size.
2666         (elf_backend_got_header_size): Set to 8.
2667         * elf64-ppc.h: New file.
2668
2669 2002-01-16  Alan Modra  <[email protected]>
2670
2671         * elf32-arm.h (elf32_arm_size_dynamic_sections): When removing
2672         sections, use bfd_section_list_remove.
2673         * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
2674         * elflink.h (elf_link_add_object_symbols): When removing all
2675         sections, use bfd_section_list_clear.
2676
2677 2002-01-15  Nick Clifton  <[email protected]>
2678
2679         * po/sv.po: New file: Swedish translation.
2680         * configure.in (ALL_LINGUAS): Add sv.
2681         * configure: Regenerate.
2682
2683 2002-01-15  Jakub Jelinek  <[email protected]>
2684
2685         * elflink.h (elf_link_input_bfd): Back out 2002-01-07 change.
2686         * elf.c (merge_sections_remove_hook): New function.
2687         (_bfd_elf_merge_sections): Pass it as 3rd argument to
2688         _bfd_merge_sections.
2689         * libbfd-in.h (_bfd_merge_sections): Add 3rd argument.
2690         * libbfd.h: Rebuilt.
2691         * merge.c (_bfd_merge_sections): Add remove_hook argument.
2692         Call remove_hook if a SEC_EXCLUDE section is encountered.
2693
2694 2002-01-15  Nick Clifton  <[email protected]>
2695
2696         * elf32-xstormy16.c (xstormy16_reloc_map): Add new field 'table'.
2697         (xstormy16_reloc_map): Initialise new field with correct howto
2698         table.
2699         (xstormy16_reloc_type_lookup): Use 'table' field to locate correct
2700         howto entry.
2701
2702 2002-01-10  Michael Snyder  <[email protected]>
2703
2704         * elf.c (elfcore_write_prstatus): Use long instead of pid_t;
2705         (elfcore_write_pstatus): Use long instead of pid_t;
2706         * elf-bfd.h: Change prototypes to use long instead of pid_t;
2707
2708 2002-01-09  Jason Thorpe  <[email protected]>
2709
2710         * elf.c: Update copyright years.
2711         (elfcore_grok_netbsd_note): Use NT_NETBSDCORE_PROCINFO
2712         and NT_NETBSDCORE_FIRSTMACH.  Improve a comment.
2713
2714 2002-01-08  Michael Snyder  <[email protected]>
2715
2716         Add capability to write corefile note sections, for gdb.
2717         * elf.c (elfcore_write_note): New function.
2718         (elfcore_write_prpsinfo): New function.
2719         (elfcore_write_prstatus): New function.
2720         (elfcore_write_pstatus): New function.
2721         (elfcore_write_prfpreg): New function.
2722         (elfcore_write_prxfpreg): New function.
2723         * elf-bfd.h: Add prototypes for above functions.
2724
2725 2002-01-08  Alexandre Oliva  <[email protected]>
2726
2727         * elf.c (elf_fake_sections): Propagate errors from
2728         elf_backend_fake_section.
2729
2730 2002-01-07  Jason Thorpe  <[email protected]>
2731
2732         * Makefile.am (BFD32_BACKENDS): Add elf32-sh-nbsd.lo.
2733         (BFD32_BACKENDS_CFILES): Add elf32-sh-nbsd.c.
2734         (elf32-sh-nbsd.lo): New rule.
2735         * Makefile.in: Regenerate.
2736         * config.bfd (sh*le-*-netbsdelf*): New target.
2737         (sh*-*-netbsdelf*): New target.
2738         * configure.in: Include netbsd-core.lo for native sh*-*-netbsd*.
2739         (bfd_elf32_shnbsd_vec): New vector.
2740         (bfd_elf32_shlnbsd_vec): New vector.
2741         * configure: Regenerate.
2742         * elf32-sh-nbsd.c: New file.
2743         * targets.c: Update copyright years.
2744         (_bfd_target_vector): Add bfd_elf32_shlnbsd_vec and
2745         bfd_elf32_shnbsd_vec.
2746
2747 2002-01-07  Aldy Hernandez  <[email protected]>
2748
2749         * coff-rs6000.c (READ20): Use bfd_scan_vma.
2750
2751 2002-01-07  Geoffrey Keating  <[email protected]>
2752
2753         * elflink.h (elf_link_input_bfd): Don't ask for the merged offset
2754         of a symbol in a section that will be deleted.
2755
2756 2002-01-07  Nick Clifton  <[email protected]>
2757
2758         * po/es.po: New file: Spanish translation.
2759         * configure.in (ALL_LINGUAS): Add es.
2760         * configure: Regenerate.
2761
2762 2002-01-06  Steve Ellcey  <[email protected]>
2763
2764         * elfxx-ia64.c (is_unwind_section_name): Add target vector as
2765         argument so we can handle HP-UX specially.
2766         (elfNN_ia64_hpux_vec): New for use in is_unwind_section_name.
2767         (elfNN_hpux_backend_section_from_bfd_section): New for support
2768         of SHN_IA_64_ANSI_COMMON.
2769         (elfNN_ia64_relax_section): Add support for SHN_IA_64_ANSI_COMMON.
2770         (is_unwind_section_name): Add special HP-UX support.
2771         (elfNN_ia64_section_from_shdr): Add support for more sections.
2772         (elfNN_ia64_fake_sections): Modify is_unwind_section_name call and
2773         add support for more sections.
2774         (elfNN_ia64_additional_program_headers): Modify
2775         is_unwind_section_name call.
2776         (elfNN_ia64_modify_segment_map): Remove assumption that there is
2777         only one unwind section in segment.
2778
2779 2002-01-06  Alan Modra  <[email protected]>
2780
2781         * syms.c (_bfd_generic_make_empty_symbol): New function.
2782         * libbfd-in.h (_bfd_nosymbols_make_empty_symbol): Define as
2783         _bfd_generic_make_empty_symbol.
2784         * libbfd.h: Regenerate.
2785         * bfd-in2.h: Regenerate.
2786         * hppabsd-core.c (hppabsd_core_make_empty_symbol): Delete function.
2787         (hppabsd_core_get_symtab_upper_bound): Don't define.
2788         (hppabsd_core_get_symtab): Likewise.
2789         (hppabsd_core_print_symbol): Likewise.
2790         (hppabsd_core_get_symbol_info): Likewise.
2791         (hppabsd_core_bfd_is_local_label_name): Likewise.
2792         (hppabsd_core_get_lineno): Likewise.
2793         (hppabsd_core_find_nearest_line): Likewise.
2794         (hppabsd_core_bfd_make_debug_symbol): Likewise.
2795         (hppabsd_core_read_minisymbols): Likewise.
2796         (hppabsd_core_minisymbol_to_symbol): Likewise.
2797         (hppabsd_core_vec): Use BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols).
2798         Formatting fixes.
2799         * hpux-core.c: Similarly.
2800         * irix-core.c: Similarly.
2801         * osf-core.c: Similarly.
2802         * sco5-core.c: Similarly.
2803         * binary.c (binary_make_empty_symbol): Remove function, define as
2804         _bfd_generic_make_empty_symbol.
2805         * ihex.c (ihex_make_empty_symbol): Likewise.
2806         * mmo.c (mmo_make_empty_symbol): Likewise.
2807         * ppcboot.c (ppcboot_make_empty_symbol): Likewise.
2808         * srec.c (srec_make_empty_symbol): Likewise.
2809         * versados.c (versados_make_empty_symbol): Likewise.
2810         * vms.c (_bfd_vms_make_empty_symbol): Remove.
2811         (vms_make_empty_symbol): Define as _bfd_generic_make_empty_symbol.
2812         * vms-gsd.c (_bfd_vms_slurp_gsd): Call bfd_make_empty_symbol
2813         rather than _bfd_vms_make_empty_symbol.
2814         * vms-misc.c (new_symbol): Likewise.
2815
2816 2002-01-05  Alan Modra  <[email protected]>
2817
2818         * section.c (bfd_section_init): Remove unnecessary initialisations.
2819         (bfd_section_list_clear): New function.
2820         (bfd_section_list_remove, bfd_section_list_insert): New macros.
2821         (_bfd_strip_section_from_output): Use them.
2822         * coffcode.h (coff_set_alignment_hook): Likewise.
2823         * elf32-mips.c (_bfd_mips_elf_final_link): Likewise.
2824         * elf64-mips.c (mips_elf64_final_link): Likewise.
2825         * elf64-mmix.c (mmix_elf_final_link): Likewise.
2826         * sunos.c (sunos_add_dynamic_symbols): Likewise.
2827         * xcofflink.c (_bfd_xcoff_bfd_final_link): Likewise.
2828         * bfd-in2.h: Regenerate.
2829
2830         * netbsd-core.c (netbsd_core_file_p): Use bfd_make_section_anyway
2831         rather than doing our own section handling.  Clean up after errors
2832         with bfd_release and bfd_section_list_clear.  Handle unexpected
2833         flags.
2834         * aoutf1.h (sunos4_core_file_p): Likewise.
2835         * aix386-core.c (aix386_core_file_p): Likewise.
2836         * cisco-core.c (cisco_core_file_validate): Likewise.
2837         * ptrace-core.c (ptrace_unix_core_file_p): Likewise.
2838         * trad-core.c (trad_unix_core_file_p): Likewise.
2839
2840         * hppabsd-core.c (hppabsd_core_core_file_p):  Clean up after errors
2841         with bfd_release and bfd_section_list_clear.
2842         * hpux-core.c (hpux_core_core_file_p): Likewise.
2843         * irix-core.c (irix_core_core_file_p): Likewise.
2844         * lynx-core.c (lynx_core_file_p): Likewise.
2845         * osf-core.c (osf_core_core_file_p): Likewise.
2846         * rs6000-core.c (rs6000coff_core_p): Likewise.
2847         * sco5-core.c (sco5_core_file_p): Likewise.
2848
2849         * elf32-mips.c (_bfd_mips_elf_lo16_reloc): Simplify, and perform
2850         sign extension adjustments without conditionals.
2851
2852 2002-01-04  Jakub Jelinek  <[email protected]>
2853
2854         * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): Don't crash if
2855         CIE at .eh_frame start is removed due to no FDEs referencing it.
2856
2857 2002-01-04  Jason Thorpe  <[email protected]>
2858
2859         * config.bfd (x86_64-*-netbsd*): New target.
2860         * configure.in (x86_64-*-netbsd*): Set COREFILE
2861         to netbsd-core.lo.
2862         * configure: Regenerated.
2863
2864 2002-01-03  Tom Rix  <[email protected]>
2865
2866         * xcofflink.c (_bfd_xcoff_bfd_final_link): Update .pad section ordering
2867         for recent bfd_make_section_anyway change.
2868
2869 2002-01-03  Nick Clifton  <[email protected]>
2870
2871         * elf32-arm.h (elf32_arm_final_link_relocate): Handle
2872         R_ARM_THM_PC11 reloc.
2873
2874 2002-01-02  Nick Clifton  <[email protected]>
2875
2876         * configure.in (LINGUAS): Add ja.
2877         * configure: Regenerate.
2878         * po/ja.po: Import from translation project's web site.
2879
2880 2002-01-02  Nick Clifton  <[email protected]>
2881
2882         * elf32-arm.h (elf32_arm_merge_private_bfd_data): Reformat error
2883         messages to ease translation into other languages.
2884
2885 For older changes see ChangeLog-0001
2886 \f
2887 Local Variables:
2888 mode: change-log
2889 left-margin: 8
2890 fill-column: 74
2891 version-control: never
2892 End:
This page took 0.197462 seconds and 4 git commands to generate.