* elf64-mmix.c (bpo_reloc_request_sort_fn): Use member
[deliverable/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
dfbbae4c
HPN
12002-06-16 Hans-Peter Nilsson <hp@bitrange.com>
2
3 * elf64-mmix.c (bpo_reloc_request_sort_fn): Use member
4 bpo_reloc_no to break sort order ties, not address of items.
5
d663e1cd
JL
62002-06-16 John David Anglin <dave@hiauly1.hia.nrc.ca>
7
8 * elf-hppa.h (elf_hppa_final_link): Fix formatting in comment.
9 Skip excluded sections in determing __gp value.
10 (elf_hppa_final_link_relocate): Use the symbol's address in
11 R_PARISC_FPTR64 relocations that don't need an opd entry.
12 * elf64-hppa.c (allocate_dynrel_entries): Simplify code.
13 (elf64_hppa_finalize_dynreloc): Likewise.
14 (elf64_hppa_size_dynamic_sections): Move comments and fix typo.
15 (elf64_hppa_finish_dynamic_symbol): Break up assert.
16
a8295218
NC
172002-06-14 Sergey Grigoriev <serge@leopold.Physik.Uni-Augsburg.DE>
18
19 * pei-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Enable 16 byte
20 alignment for .bss, .data and .text sections so that sse and sse2
21 code will work.
22 * pe-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
23
242002-06013 J"orn Rennecke <joern.rennecke@superh.com>
5d9b5481
JR
25
26 config.bfd: Add support for sh[1234]l*-*-elf* | sh3el*-*-elf*,
27 sh[1234]*-elf*.
28
3db4b612
JL
292002-06-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
30
2cb69dd3
JL
31 * elflink.h (elf_bfd_final_link): Improve error handling for missing
32 dynamic sections.
33
3db4b612
JL
34 * elf64-hppa.c (allocate_global_data_opd): We don't need an opd entry
35 for a symbol that has no output section.
36 (allocate_dynrel_entries): Correct comment.
37 (elf64_hppa_finalize_dynreloc): Likewise. Don't create an opd entry
38 unless we want one.
39 (elf64_hppa_finalize_opd): Prevent segfault if dyn_h is NULL.
40 (elf64_hppa_finalize_dlt): Likewise. Prevent segfault for symbols
41 with no section. Remove unnecessary parentheses.
42
f3813499
TR
432002-06-11 Tom Rix <trix@redhat.com>
44
45 * coffcode.h (coff_compute_section_file_positions): Add data
46 section to AIX loader alignment check.
47
48 * coff-rs6000.c (_bfd_xcoff_mkobject): Set default text section
49 alignment to 4 bytes.
50 (_bfd_xcoff_copy_private_bfd_data): Use text and data alignment
51 power accessor macro.
52 (do_shared_object_padding): Remove invalid assertion.
53
0ebaf185
RS
542002-06-10 Richard Sandiford <rsandifo@redhat.com>
55
56 * section.c (_bfd_strip_section_from_output): Set SEC_EXCLUDE
57 for removed output sections.
58
ebe3e2d1
NC
592002-06-10 Geoffrey Keating <geoffk@redhat.com>
60
61 * merge.c (merge_strings): Use htab_create_alloc with calloc, not
62 htab_alloc.
63 * elf-strtab.c (_bfd_elf_strtab_finalize): Likewise.
64
0b14c2aa
L
652002-06-08 H.J. Lu <hjl@gnu.org>
66
67 * elf.c (copy_private_bfd_data): Don't cast to bfd_size_type to
68 work around a long long bug in gcc 2.96 on mips.
69
3c2bfad6
JT
702002-06-08 Jason Thorpe <thorpej@wasabisystems.com>
71
72 * Makefile.am (BFD32_BACKENDS): Add vax1knetbsd.lo.
73 (BFD32_BACKENDS_CFILES): Add vax1knetbsd.c.
74 Regenerate dependency lists.
75 * Makefile.in: Regenerate.
76 * config.bfd (vax-*-netbsdelf*, vax-*-netbsdaout*): Add
77 vax1knetbsd_vec to targ_selvecs.
78 * configure.in: Add vax1knetbsd_vec.
79 * configure: Regenerate.
80 * targets.c (_bfd_target_vector): Add vax1knetbsd_vec.
81 * vax1knetbsd.c: New file.
82 * vaxnetbsd.c: Update copyright years.
83 (TARGET_PAGE_SIZE): Set to 0x1000.
84 (DEFAULT_MID): Set to M_VAX4K_NETBSD.
85
91149be3
JT
862002-06-08 Matt Thomas <matt@3am-software.com>
87
88 * libaout.h (enum machine_type): Add M_VAX4K_NETBSD.
89
21e15248
AM
902002-06-08 Alan Modra <amodra@bigpond.net.au>
91
92 * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): Make static.
93
986b7daa
AM
942002-06-08 Alan Modra <amodra@bigpond.net.au>
95
e90b95f6
AM
96 * Makefile.am: Run "make dep-am".
97 * Makefile.in: Regenerate.
98
3f9c735e
AM
99 * armnetbsd.c: Replace CONST with const.
100 * corefile.c: Likewise.
101 * elf32-dlx.c: Likewise.
102 * elf64-mips.c: Likewise.
103 * mmo.c: Likewise.
104 * ns32knetbsd.c: Likewise.
105
986b7daa
AM
106 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Check the hash
107 table is elf64-sparc.
108
5a659663
TS
1092002-06-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
110
111 * elfxx-mips.c (_bfd_mips_elf_relocate_section): Simplify code.
112 Fix RELA addends to get not shifted in the result. Don't do special
113 handling of R_MIPS_64 for NewABI.
114
9bab7074
AM
1152002-06-07 Alan Modra <amodra@bigpond.net.au>
116
117 * aoutx.h (NAME(aout,slurp_symbol_table)): Use bfd_zmalloc.
118 (NAME(aout,slurp_reloc_table)): Likewise.
119 * coff-mips.c (mips_relax_section): Use bfd_zalloc.
120 * coff-rs6000.c (xcoff_write_armap_big): Use bfd_zmalloc.
121 (xcoff_write_archive_contents_big): Likewise.
122 (xcoff_generate_rtinit): Likewise.
123 (xcoff_generate_rtinit): Likewise, and check error return.
124 * coff64-rs6000.c (xcoff64_generate_rtinit): Likewise.
125 * coffgen.c (coff_section_symbol): Use bfd_zalloc.
126 (coff_get_normalized_symtab): Likewise.
127 (coff_make_empty_symbol): Likewise.
128 (bfd_coff_set_symbol_class): Likewise.
129 * cofflink.c (coff_link_add_symbols): Likewise.
130 * ecoff.c (_bfd_ecoff_make_empty_symbol): Likewise.
131 * ecofflink.c (ecoff_write_shuffle): Use bfd_zmalloc.
132 (bfd_ecoff_write_accumulated_debug): Likewise.
133 * elf64-alpha.c (get_got_entry): Use bfd_zalloc.
134 * i386linux.c (bfd_i386linux_size_dynamic_sections): Likewise.
135 * i386lynx.c (NAME(lynx,slurp_reloc_table)): Use bfd_zmalloc.
136 * ieee.c (do_with_relocs): Use bfd_zalloc.
137 * m68klinux.c (bfd_m68klinux_size_dynamic_sections): Likewise.
138 * pdp11.c (NAME(aout,slurp_symbol_table)): Use bfd_zmalloc.
139 (NAME(aout,slurp_reloc_table)): Likewise.
140 (NAME(aout,squirt_out_relocs)): Don't memset when zalloc'd.
141 * reloc16.c (bfd_coff_reloc16_relax_section): Use bfd_zmalloc.
142 * som.c (som_build_and_write_symbol_table): Likewise.
143 (som_slurp_string_table): Likewise.
144 (som_slurp_symbol_table): Likewise.
145 (som_bfd_ar_write_symbol_stuff): Likewise.
146 * sparclinux.c (bfd_sparclinux_size_dynamic_sections): Use bfd_zalloc.
147 * sunos.c (bfd_sunos_size_dynamic_sections): Likewise.
148 * tekhex.c (find_chunk): Likewise. Get rid of unused "sname".
149 * vms-gsd.c (_bfd_vms_slurp_gsd): Use bfd_zmalloc.
150 * xcofflink.c (xcoff_link_add_symbols): Use bfd_zalloc/bfd_zmalloc.
151
1126897b
AM
1522002-06-07 Alan Modra <amodra@bigpond.net.au>
153
154 * elf-bfd.h (struct bfd_elf_section_data <group_name>): Replace with
155 "group" union.
156 (elf_group_name): Update.
157 (elf_group_id): Define.
158 (bfd_elf_set_group_contents): Declare.
159 * elf.c (elf_fake_sections): Qualify use of elf_group_name.
160 (set_group_contents): Rename to bfd_elf_set_group_contents. Remove
161 ATTRIBUTE_UNUSED from failedptrarg. If elf_group_id is set, use
162 that sym for the signature.
163 (_bfd_elf_compute_section_file_positions): Don't call
164 set_group_contents for "ld -r" case.
165 (swap_out_syms): Use bfd_zalloc.
166 * elflink.h (elf_link_add_archive_symbols): Likewise.
167 (NAME(bfd_elf,size_dynamic_sections)): Likewise.
168 (elf_bfd_final_link): Call bfd_elf_set_group_contents.
169
3fad3c7c
AM
1702002-06-07 Alan Modra <amodra@bigpond.net.au>
171
172 * elf64-ppc.c (ppc64_elf_relocate_section): Allow unresolved
173 relocs in opd for non-shared too.
174
76f99c63
JL
1752002-06-06 Jeffrey Law <law@redhat.com
176
177 * elf32-h8300.c (elf32_h8_relax_section): Ignore uninteresting
178 relocations.
179
7217313c
NC
1802002-06-06 Nick Clifton <nickc@cambridge.redhat.com>
181
182 * merge.c: Include libiberty.h.
183 * elf-strtab.c: Include libiberty.h.
184
6cb22815
AM
1852002-06-06 Elias Athanasopoulos <eathan@otenet.gr>
186
187 * peXXigen.c (pe_print_idata): Remove unused variable.
188
1ed89aa9
NC
1892002-06-06 David Heine <dlheine@tensilica.com>
190
191 * elf.c (assign_file_positions_for_segments): Remove unallocated
192 sections from the section to segment mapping for PT_LOAD segments.
193 Update comment about empty loadable segments.
194
644c4c80
RS
1952002-06-06 Richard Sandiford <rsandifo@redhat.com>
196
197 * stabs.c (_bfd_link_section_stabs): Check that the symbol offset
198 is within the .stabstr section.
199
f8ecb12b
AM
2002002-06-06 Alan Modra <amodra@bigpond.net.au>
201
202 * elf-bfd.h (struct elf_size_info <swap_symbol_in>): Function args
203 are "const PTR", not "const PTR *".
204 (bfd_elf32_swap_symbol_in): Likewise.
205 (bfd_elf64_swap_symbol_in): Likewise.
206 * elfcode.h (elf_swap_symbol_in): Change input args to const PTR.
207 (elf_slurp_symbol_table): Adjust call to elf_swap_symbol_in.
208 * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
209 (elf_link_add_object_symbols): Likewise.
210 (elf_link_record_local_dynamic_symbol): Likewise.
211 (elf_link_input_bfd): Likewise.
212 (elf_gc_mark): Likewise.
213 (elf_reloc_symbol_deleted_p): Likewise.
214 * elf-m10200.c (mn10200_elf_relax_section): Likewise.
215 (mn10200_elf_relax_delete_bytes): Likewise.
216 (mn10200_elf_symbol_address_p): Likewise.
217 (mn10200_elf_get_relocated_section_contents): Likewise.
218 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
219 (mn10300_elf_relax_section): Likewise.
220 (mn10300_elf_relax_delete_bytes): Likewise.
221 (mn10300_elf_symbol_address_p): Likewise.
222 (mn10300_elf_get_relocated_section_contents): Likewise.
223 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
224 (elf32_h8_relax_delete_bytes): Likewise.
225 (elf32_h8_symbol_address_p): Likewise.
226 (elf32_h8_get_relocated_section_contents): Likewise.
227 * elf32-hppa.c (get_local_syms): Likewise.
228 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
229 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
230 * elf32-sh.c (sh_elf_relax_section): Likewise.
231 (sh_elf_relax_delete_bytes): Likewise.
232 (sh_elf_get_relocated_section_contents): Likewise.
233 * elf32-xstormy16.c (xstormy16_elf_relax_section): Likewise.
234 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
235 * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
236 * elf64-mmix.c (mmix_elf_relax_section): Likewise.
237 * elf64-ppc.c (get_local_syms): Likewise.
238 * elf64-sh64.c (sh_elf64_get_relocated_section_contents): Likewise.
239 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
240
1ed89aa9 2412002-06-05 J"orn Rennecke <joern.rennecke@superh.com>
7a33bc10
JR
242
243 * config.bfd (sh64l*-*-elf*, shl*-*-elf*): New configurations.
244
73ff0d56
AM
2452002-06-05 Alan Modra <amodra@bigpond.net.au>
246
9dce4196
AM
247 * elf.c (group_signature): Swap in the whole symbol, and handle
248 extracting section symbol names.
249 (setup_group): Add comment.
250 (set_group_contents): When called from objcopy or ld, arrange for
251 section contents to be written. Write group member output section
252 indices to allow objcopy to reorganize sections.
253 (_bfd_elf_copy_private_section_data): Copy group info.
254
73ff0d56
AM
255 * elf-bfd.h (struct elf_size_info): Add swap_symbol_in field.
256 (bfd_elf32_swap_symbol_in): Update prototype.
257 (bfd_elf64_swap_symbol_in): Likewise.
258 * elfcode.h (elf_swap_symbol_in): Change input args to const PTR *.
259 (elf_slurp_symbol_table): Adjust call to elf_swap_symbol_in.
260 * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
261 (elf_link_add_object_symbols): Likewise.
262 (elf_link_record_local_dynamic_symbol): Likewise.
263 (elf_link_input_bfd): Likewise.
264 (elf_gc_mark): Likewise.
265 (elf_reloc_symbol_deleted_p): Likewise.
266 * elf-m10200.c (mn10200_elf_relax_section): Likewise.
267 (mn10200_elf_relax_delete_bytes): Likewise.
268 (mn10200_elf_symbol_address_p): Likewise.
269 (mn10200_elf_get_relocated_section_contents): Likewise.
270 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
271 (mn10300_elf_relax_section): Likewise.
272 (mn10300_elf_relax_delete_bytes): Likewise.
273 (mn10300_elf_symbol_address_p): Likewise.
274 (mn10300_elf_get_relocated_section_contents): Likewise.
275 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
276 (elf32_h8_relax_delete_bytes): Likewise.
277 (elf32_h8_symbol_address_p): Likewise.
278 (elf32_h8_get_relocated_section_contents): Likewise.
279 * elf32-hppa.c (get_local_syms): Likewise.
280 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
281 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
282 * elf32-sh.c (sh_elf_relax_section): Likewise.
283 (sh_elf_relax_delete_bytes): Likewise.
284 (sh_elf_get_relocated_section_contents): Likewise.
285 * elf32-xstormy16.c (xstormy16_elf_relax_section): Likewise.
286 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
287 * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
288 * elf64-mmix.c (mmix_elf_relax_section): Likewise.
289 * elf64-ppc.c (get_local_syms): Likewise.
290 * elf64-sh64.c (sh_elf64_get_relocated_section_contents): Likewise.
291 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
292 * elfcode.h (NAME(_bfd_elf,size_info)): Update initialiser.
293 * elf64-alpha.c (alpha_elf_size_info): Likewise.
294 * elf64-hppa.c (hppa64_elf_size_info): Likewise.
295 * elf64-mips.c (mips_elf64_size_info): Likewise.
296 * elf64-s390.c (s390_elf64_size_info): Likewise.
297 * elf64-sparc.c (sparc64_elf_size_info): Likewise.
298
53bfd6b4
MR
2992002-06-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
300
301 * elf32-mips.c (elf32_mips_ignore_discarded_relocs): Move to...
302 elfxx-mips.c (_bfd_mips_elf_ignore_discarded_relocs): ... here.
303 elf64-mips.c (elf_backend_ignore_discarded_relocs): Use
304 _bfd_mips_elf_ignore_discarded_relocs.
305 elfxx-mips.h (_bfd_mips_elf_ignore_discarded_relocs): Declare.
306
d4df96e6
L
3072002-06-05 H.J. Lu <hjl@gnu.org>
308
309 * elfxx-mips.c (mips_elf_calculate_relocation): Call
310 _bfd_elf_rel_local_sym for STT_SECTION relocations against
311 the SEC_MERGE section.
312
e61463e1
AM
3132002-06-05 Alan Modra <amodra@bigpond.net.au>
314
3cac74d0
AM
315 * coff-alpha.c: Update copyright date.
316 * coff-mips.c: Likewise.
317 * xcoff-target.h: Likewise.
318
e61463e1
AM
319 * bfd-in.h: Remove "taken from the source" comment.
320 * libbfd-in.h: Likewise.
321 * libcoff-in.h: Likewise.
322 * bfd-in2.h: Regenerate.
323 * libbfd.h: Regenerate.
324 * libcoff.h: Regenerate.
325
326 * elf.c (bfd_elf_discard_group): Return true.
327 * elf-bfd.h (bfd_elf_discard_group): Declare.
328 * bfd-in.h (bfd_elf_discard_group): Don't declare here.
329 * section.c (bfd_discard_group): Rename to bfd_generic_discard_group.
330 * bfd.c (bfd_discard_group): Define.
331 * targets.c (struct bfd_target): Add _bfd_discard_group.
332 (BFD_JUMP_TABLE_LINK): Here too.
333 * libbfd-in.h (_bfd_nolink_bfd_discard_group): Define.
334 * aout-adobe.c (aout_32_bfd_discard_group): Define.
335 * aout-target.h (MY_bfd_discard_group): Define.
336 * aout-tic30.c (MY_bfd_discard_group): Define.
337 * binary.c (binary_bfd_discard_group): Define.
338 * bout.c (b_out_bfd_discard_group): Define.
339 * coff-alpha.c (_bfd_ecoff_bfd_discard_group): Define.
340 * coffcode.h (coff_bfd_discard_group): Define.
341 * coff-mips.c (_bfd_ecoff_bfd_discard_group): Define.
342 * elfxx-target.h (bfd_elfNN_bfd_discard_group): Define.
343 * i386msdos.c (msdos_bfd_discard_group): Define.
344 * i386os9k.c (os9k_bfd_discard_group): Define.
345 * ieee.c (ieee_bfd_discard_group): Define.
346 * ihex.c (ihex_bfd_discard_group): Define.
347 * mmo.c (mmo_bfd_discard_group): Define.
348 * nlm-target.h (nlm_bfd_discard_group): Define.
349 * oasys.c (oasys_bfd_discard_group): Define.
350 * ppcboot.c (ppcboot_bfd_discard_group): Define.
351 * som.c (som_bfd_discard_group): Define.
352 * srec.c (srec_bfd_discard_group): Define.
353 * tekhex.c (tekhex_bfd_discard_group): Define.
354 * versados.c (versados_bfd_discard_group): Define.
355 * vms.c (vms_bfd_discard_group): Define.
356 * xcoff-target.h (_bfd_xcoff_bfd_discard_group): Define.
357 * coff64-rs6000.c (rs6000coff64_vec): Update initialiser.
358 (aix5coff64_vec): Likewise.
359 * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Likewise.
360
9cba27b2
JT
3612002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
362
363 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64-com.lo.
364 (BFD32_BACKENDS_CFILES): Add elf32-sh64-com.c.
365 (elf32-sh64-com.lo): New dependency list.
366 * Makefile.in: Regenerate.
367 * configure.in (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec)
368 (bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec): Add
369 elf32-sh64-com.lo.
370 * configure: Regenerate.
371 * elf32-sh64.c (sh64_address_in_cranges)
372 (sh64_get_contents_type, sh64_address_is_shmedia): Move to...
373 (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb):
374 (crange_bsearch_cmpl): Prepend _bfd_sh64_ to name and move to...
375 * elf32-sh64-com.c: ...here. New file.
376
8d2c33be
AM
3772002-06-04 Alan Modra <amodra@bigpond.net.au>
378
379 * elf32-openrisc.c (openrisc_elf_gc_mark_hook): Remove
380 ATTRIBUTE_UNUSED on used params.
381 * elf32-vax.c (elf_vax_gc_mark_hook): Remove unnecessary checks
382 before calling bfd_section_from_elf_index on local syms.
383 * elf64-sh64.c (sh_elf64_gc_mark_hook): Likewise.
384
5b0e55b6
JT
3852002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
386
387 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64-nbsd.lo.
388 (BFD32_BACKENDS_CFILES): Add elf32-sh64-nbsd.c.
389 (BFD64_BACKENDS): Add elf64-sh64-nbsd.lo.
390 (BFD64_BACKENDS_CFILES): Add elf64-sh64-nbsd.c.
391 (elf32-sh64-nbsd.lo, elf64-sh64-nbsd.lo): New rules.
392 * Makefile.in: Regenerate.
393 * config.bfd (sh5le-*-netbsd*, sh5-*-netbsd*, sh64le-*-netbsd*)
394 (sh64-*-netbsd*): New targets.
395 * configure.in: Add bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec,
396 bfd_elf64_sh64nbsd_vec, and bfd_elf64_sh64lnbsd_vec.
397 * configure: Regenerate.
398 * elf32-sh64-nbsd.c: New file.
399 * elf64-sh64-nbsd.c: New file.
400 * targets.c: Add extern decls for bfd_elf32_sh64nbsd_vec,
401 bfd_elf32_sh64lnbsd_vec, bfd_elf64_sh64nbsd_vec, and
402 bfd_elf64_sh64lnbsd_vec.
403
b885599b
AM
4042002-06-04 Alan Modra <amodra@bigpond.net.au>
405
406 * elf.c (setup_group): Set SEC_LINK_ONCE on GRP_COMDAT groups.
407 (bfd_section_from_shdr): Likewise. Set section name of group
408 sections from signature.
409 (group_signature): Split out from setup_group. Ensure symbol table
410 is available.
411 (bfd_elf_discard_group): New function.
412 (_bfd_elf_make_section_from_shdr): Don't set SEC_LINK_ONCE on
413 .gnu.linkonce* sections if they are members of a group.
414 (set_group_contents): Set GRP_COMDAT flag.
415 * section.c (bfd_discard_group): New function.
416 * bfd-in.h (bfd_elf_discard_group): Declare.
417 * bfd-in2.h: Regenerate.
418 * elf-bfd.h (struct bfd_elf_section_data): Add linkonce_p field.
419 (elf_linkonce_p): Define.
420
90937f86
AM
4212002-06-04 Alan Modra <amodra@bigpond.net.au>
422
423 * elf.c (bfd_section_from_shdr): Make "name" const.
424 * elf-bfd.h (elf_backend_section_from_shdr): Likewise.
425 * elf32-i370.c (i370_elf_section_from_shdr): Likewise.
426 * elf32-ppc.c (ppc_elf_section_from_shdr): Likewise.
427 * elf32-sh64.c (sh64_backend_section_from_shdr): Likewise.
428 * elf32-v850.c (v850_elf_section_from_shdr): Likewise.
429 * elf64-alpha.c (elf64_alpha_section_from_shdr): Likewise.
430 * elf64-hppa.c (elf64_hppa_section_from_shdr): Likewise.
431 * elf64-ppc.c (ppc64_elf_section_from_shdr): Likewise.
432 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Likewise.
433 * elfxx-mips.c (_bfd_mips_elf_section_from_shdr): Likewise.
434 * elfxx-mips.h (_bfd_mips_elf_section_from_shdr): Likewise.
435
cf6fb9ce
MR
4362002-06-03 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
437
438 * elfxx-mips.c (ABI_64_P): Use backend's data to determine the
439 ABI.
440
cedb70c5
KH
4412002-06-02 Kazu Hirata <kazu@cs.umass.edu>
442
443 * elf32-arc.c: Fix formatting.
444 * elf32-arm.h: Likewise.
445 * elf32-cris.c: Likewise.
446 * elf32-dlx.c: Likewise.
447 * elf32-hppa.c: Likewise.
448 * elf32-i386.c: Likewise.
449 * elf32-i386qnx.c: Likewise.
450 * elf32-or32.c: Likewise.
451 * elf32-s390.c: Likewise.
452 * elf32-sh64.c: Likewise.
453 * elf32-vax.c: Likewise.
454 * elf32-xstormy16.c: Likewise.
455 * elf64-alpha.c: Likewise.
456 * elf64-mmix.c: Likewise.
457 * elf64-ppc.c: Likewise.
458 * elf64-s390.c: Likewise.
459 * elf64-sh64.c: Likewise.
460 * elf64-x86-64.c: Likewise.
461
048d873d
RH
4622002-06-02 Richard Henderson <rth@redhat.com>
463
464 * elf64-alpha.c (elf64_alpha_relocate_section): Don't dereference
465 null when there are no got entries for a symbol.
466 (elf64_alpha_relax_find_tls_segment): Rearrange to avoid
467 uninitialized variable warning.
468
4a67a098
RH
4692002-06-01 Richard Henderson <rth@redhat.com>
470
471 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Don't test for
472 undefined symbols here.
473 (elf64_alpha_relax_section): Do it here. Also test for not
474 defined in the current module.
475 (elf64_alpha_relocate_section_r): Split out of ...
476 (elf64_alpha_relocate_section): ... here. Don't dereference
477 NULL when looking up local got entries.
478
f44f99a5
RH
4792002-06-01 Richard Henderson <rth@redhat.com>
480
481 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Reject undefined
482 symbols from JSR relaxation.
483 (elf64_alpha_size_plt_section_1): New.
484 (elf64_alpha_calc_dynrel_sizes): Split out .rela.got bits ...
485 (elf64_alpha_size_rela_got_1): ... here.
486 (elf64_alpha_size_dynamic_sections): Split out .rela.got bits ...
487 (elf64_alpha_size_rela_got_section): ... here.
488 (elf64_alpha_size_plt_section): New.
489 (elf64_alpha_relax_section): Call them.
490 (elf64_alpha_size_got_sections): Remove output_bfd arg.
491 (elf64_alpha_finish_dynamic_symbol): Check gotent use_count.
492
9e756d64
RH
4932002-06-01 Richard Henderson <rth@redhat.com>
494
495 * elf64-alpha.c (alpha_get_dtprel_base, alpha_get_tprel_base): New.
496 (elf64_alpha_relocate_section): Use them. Reject LE TLS relocs
497 in shared libraries. Fix DTPRELHI and TPRELHI value.
498 (INSN_ADDQ, INSN_RDUNIQ): New.
499 (struct alpha_relax_info): Add symtab_hdr, tls_segment, first_gotent.
500 (elf64_alpha_relax_with_lituse): Return boolean. Remove irelend
501 argument. Reject dynamic symbols. Use LITUSE symbolic constants.
502 (elf64_alpha_relax_got_load): Rename from relax_without_lituse.
503 Handle GOTDTPREL and GOTTPREL relocations.
504 (elf64_alpha_relax_gprelhilo): New.
505 (elf64_alpha_relax_tls_get_addr): New.
506 (elf64_alpha_relax_find_tls_segment): New.
507 (elf64_alpha_relax_section): Handle TLS relocations.
508 (ALPHA_ELF_LINK_HASH_TLS_IE): New.
509 (elf64_alpha_check_relocs): Set it.
510
c853d7f6
RH
5112002-06-01 Richard Henderson <rth@redhat.com>
512
b646261c
RH
513 * elf64-alpha.c (elf64_alpha_relax_section): Don't store computed gp.
514
c853d7f6
RH
515 * elf64-alpha.c (elf64_alpha_check_relocs): Fix typo on maybe_dynamic
516 check; don't suppress dynamic relocs for non-allocated sections.
517
d7e41a96
RH
518 * elf64-alpha.c: Remove dead code.
519
5f333394
AM
5202002-05-31 Alan Modra <amodra@bigpond.net.au>
521
08e0ee05
AM
522 * bfd-in2.h: Regenerate.
523 * libbfd.h: Regenerate.
524 * po/SRC-POTFILES.in: Regenerate.
525
5f333394
AM
526 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Don't allocate
527 space for bss .plt.
528
caf47ea6
AM
5292002-05-31 Graeme Peterson <gp@qnx.com>
530
531 * Makefile.am (BFD32_BACKENDS): Add elf32-i386qnx.lo.
532 (BFD32_BACKENDS_CFILES): Add elf32-i386qnx.c.
533 Run "make dep-am".
534 * Makefile.in: Regenerate.
535 * config.bfd: Add i[3456]86-*-nto-qnx* support.
536 * configure.in: Add bfd_elf32_i386qnx_vec support.
537 * configure: Regenerate.
538 * elf-bfd.h (struct elf_backend_data): Add set_nonloadable_filepos,
539 is_contained_by_filepos, and copy_private_bfd_data_p.
540 * elf.c (assign_file_positions_for_segments): Call backend
541 set_nonloadable_filepos. Fix non-K&R call to _bfd_error_handler.
542 (IS_CONTAINED_BY_FILEPOS): Define.
543 (INCLUDE_SECTION_IN_SEGMENT): Also test IS_CONTAINED_BY_FILEPOS.
544 (copy_private_bfd_data): Use IS_CONTAINED_BY_FILEPOS. Typo fix.
545 Fix non-K&R call to _bfd_error_handler.
546 (_bfd_elf_copy_private_section_data): Use backend
547 copy_private_bfd_data_p.
548 * elf32-i386.c: Don't include elfxx-target.h when
549 ELF32_I386_C_INCLUDED is defined.
550 * elf32-i386qnx.c: New QNX elf backend file.
551 * elfxx-target.h: Add elf_backend_set_nonloadable_filepos,
552 elf_backend_is_contained_by_filepos, and
553 elf_backend_do_copy_private_bfd_data.
554 * targets.c: Add bfd_target bfd_elf32_i386qnx_vec.
555
5bc56484
AM
5562002-05-31 Alan Modra <amodra@bigpond.net.au>
557
558 * elfarm-oabi.c (bfd_elf32_arm_add_glue_sections_to_bfd): Define.
559 Move other similar defines to start of file.
560
1b164155
TR
5612002-05-30 Tom Rix <trix@redhat.com>
562
563 * coff-rs6000.c (xcoff_rtype2howto): Handle 16 bit R_RBA.
564 * coff64-rs6000.c (xcoff64_rtype2howto): Same.
565
3765b1be
RH
5662002-05-30 Richard Henderson <rth@redhat.com>
567
568 * elf64-alpha.c (ALPHA_ELF_LINK_HASH_LU_TLSGD,
569 ALPHA_ELF_LINK_HASH_LU_TLSLDM, ALPHA_ELF_LINK_HASH_LU_FUNC): New.
570 (ALPHA_ELF_GOT_ENTRY_RELOCS_DONE): Remove.
571 (ALPHA_ELF_GOT_ENTRY_RELOCS_XLATED): Remove.
572 (struct alpha_elf_got_entry): Add reloc_type, reloc_done, reloc_xlated.
573 (struct alpha_elf_obj_tdata): Rename total_got_entries and
574 n_local_got_entries to total_got_size and local_got_size.
575 (elf64_alpha_howto, elf64_alpha_reloc_map): Update for TLS relocs.
576 (alpha_got_entry_size): New.
577 (elf64_alpha_relax_with_lituse): Use it.
578 (elf64_alpha_relax_without_lituse): Likewise.
579 (MAX_GOT_SIZE): Rename from MAX_GOT_ENTRIES.
580 (get_got_entry): New.
581 (elf64_alpha_check_relocs): Handle TLS relocs. Reorganize.
582 (elf64_alpha_adjust_dynamic_symbol): Test LU_FUNC as a mask.
583 (elf64_alpha_merge_ind_symbols): Check gotent->reloc_type.
584 (elf64_alpha_can_merge_gots, elf64_alpha_merge_gots): Likewise.
585 (elf64_alpha_calc_got_offsets_for_symbol): Use alpha_got_entry_size.
586 (elf64_alpha_calc_got_offsets): Likewise.
587 (alpha_dynamic_entries_for_reloc): New.
588 (elf64_alpha_calc_dynrel_sizes): Use it.
589 (elf64_alpha_size_dynamic_sections): Likewise.
590 (elf64_alpha_relocate_section): Handle TLS relocations.
591 * reloc.c: Add Alpha TLS relocations.
592 * bfd-in2.h, libbfd.h: Rebuild.
593
5e226794
NC
5942002-05-29 Ralf Habacker <ralf.habacker@freenet.de>
595
596 * peXXigen.c (pe_print_idata): Remove double printed
597 import table lines; add Bound-To comment.
598
90ace9e9
JT
5992002-05-29 Matt Thomas <matt@3am-software.com>
600
601 * Makefile.am (BFD32_BACKENDS): Add elf32-vax.lo.
602 (BFD32_BACKENDS_CFILES): Add elf32-vax.c.
603 (elf32-vax.lo): New rule.
604 * Makefile.in: Regenerate.
605 * configure.in (bfd_elf32_vax_vec)
606 (vaxnetbsd_vec): New vectors.
607 * configure: Regenerate.
608 * config.bfd (vax-*-netbsdelf*)
609 (vax-*-netbsdaout*)
610 (vax-*-netbsd*): New targets.
611 * elf32-vax.c: New file.
612 * reloc.c: Add VAX relocations.
613 * bfd-in2.h: Regenerate.
614 * targets.c (_bfd_target_vector): Add bfd_elf32_vax_vec.
615
4a253e81
JT
6162002-05-29 Jason Thorpe <thorpej@wasabisystems.com>
617
618 * config.bfd (arm-*-netbsd*): Add bfd_elf32_littlearm_vec
619 and bfd_elf32_bigarm_vec to targ_selvecs.
620
6e7c73dd
CF
6212002-05-29 Ralf Habacker <ralf.habacker@freenet.de>
622
623 * peXXigen.c (pe_print_idata): Fix seg faults on printing import tables
624 with auto-imported symbols.
625
8afb0e02
NC
6262002-05-29 Adam Nemet <anemet@lnxw.com>
627
628 * elf32-arm.h (bfd_elf32_arm_get_bfd_for_interworking): Don't add glue
629 sections only record bfd.
9bab7074 630 (bfd_elf32_arm_add_glue_sections_to_bfd): New function.
8afb0e02 631 * bfd-in.h (bfd_elf32_arm_add_glue_sections_to_bfd): Declare it.
9bab7074 632 * bfd-in2.h: Regenerate.
8afb0e02 633
a95653f5
NC
6342002-05-28 Nick Clifton <nickc@cambridge.redhat.com>
635
636 * syms.c (_bfd_stab_section_find_nearest_line): Move
637 declaration and initialisation of saw_line and saw_func out of
638 for loop.
639
7cdc5bba
AM
6402002-05-29 Alan Modra <amodra@bigpond.net.au>
641
642 * elf64-ppc.c (ppc64_elf_get_symbol_info): New function.
643 (bfd_elf64_get_symbol_info): Define.
644 * elfxx-target.h (bfd_elfNN_get_symbol_info): Only define if undef.
645
4c7aad1c
AM
6462002-05-29 Andrey Volkov <avolkov@transas.com>
647
648 * cpu-h8300.c: Make default h8300 machine first in machine list.
649
d172d4ba
NC
6502002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
651
652 * config.bfd: Added DLX configuraton.
653 * Makefile.am: Added DLX configuraton.
654 * configure.in: Added DLX configuraton.
655 * archures.c: Add DLX architecure.
656 * reloc.c: Add DLX relocs.
657 * targets.c: Added DLX target vector.
658 * configure: Regenerate.
659 * Makefile.in: Regenreate.
660 * bfd-in2.h: Regenreate.
661 * elf32-dlx.c: New file: Support DLX target.
662 * cpu-dlx.c: New file: Support DLX target.
663
d1329ca3
AM
6642002-05-25 Alan Modra <amodra@bigpond.net.au>
665
428d0de3
AM
666 * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Formatting.
667
d1329ca3
AM
668 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Revert last change.
669 (ppc64_elf_check_relocs): Don't set up function descriptor symbol
670 strings to point inside function code sym string.
671 (func_desc_adjust): Likewise.
672 (ppc64_elf_hide_symbol): Rewrite code to look up function code sym.
673
3bab7989
ML
6742002-05-24 Michal Ludvig <mludvig@suse.cz>
675
676 * elf64-x86-64.c (elf64_x86_64_grok_prstatus): Added.
677 (elf64_x86_64_grok_psinfo): Added.
678
436e8db0
NC
6792002-05-24 TAMURA Kent <kent@netbsd.org>
680
681 * config.bfd: Add a target for i386-netbsdpe.
682
ea1e4b0d
AM
6832002-05-24 Alan Modra <amodra@bigpond.net.au>
684
685 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Don't copy is_func
686 and is_func_descriptor.
687 (func_desc_adjust): Hide function code sym in shared libs unless
688 there is a matching exported function descriptor sym.
689
13ae64f3
JJ
6902002-05-23 Jakub Jelinek <jakub@redhat.com>
691
692 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_THREAD_LOCAL
693 for symbols from SHF_TLS section.
694 (_bfd_elf_print_private_bfd_data): Add PT_TLS.
695 (elf_fake_sections): Set SHF_TLS for SEC_THREAD_LOCAL sections.
696 (map_sections_to_segments): Build PT_TLS segment if necessary.
697 (assign_file_positions_for_segments): Likewise.
698 (get_program_header_size): Account for PT_TLS segment.
699 (swap_out_syms): Set type of BSF_THREAD_LOCAL symbols and symbols from
700 SEC_THREAD_LOCAL sections to STT_TLS.
701 * reloc.c: Add 386 and IA-64 TLS relocs.
702 * section.c (SEC_THREAD_LOCAL): Define.
703 (SEC_CONSTRUCTOR_TEXT, SEC_CONSTRUCTOR_DATA, SEC_CONSTRUCTOR_BSS):
704 Remove.
705 * elflink.h (elf_link_add_object_symbols): Support .tcommon.
706 (size_dynamic_sections): If DF_STATIC_TLS, set DF_FLAGS
707 unconditionally.
708 (struct elf_final_link_info): Add first_tls_sec.
709 (elf_bfd_final_link): Set first_tls_sec.
710 Compute elf_hash_table (info)->tls_segment.
711 (elf_link_output_extsym): Handle STT_TLS symbols.
712 (elf_link_input_bfd): Likewise.
713 * syms.c (BSF_THREAD_LOCAL): Define.
714 * bfd-in2.h: Rebuilt.
715 * libbfd.h: Rebuilt.
716 * elf32-i386.c (elf_i386_tls_transition, dtpoff_base, tpoff,
717 elf_i386_mkobject, elf_i386_object_p): New functions.
718 (elf_howto_table): Add TLS relocs.
719 (elf_i386_reloc_type_lookup): Support TLS relocs.
720 (elf_i386_info_to_howto_rel): Likewise.
721 (struct elf_i386_link_hash_entry): Add tls_type.
722 (struct elf_i386_obj_tdata): New.
723 (elf_i386_hash_entry, elf_i386_tdata, elf_i386_local_got_tls_type):
724 New macros.
725 (struct elf_i386_link_hash_table): Add tls_ldm_got.
726 (link_hash_newfunc): Clear tls_type.
727 (elf_i386_check_relocs): Support TLS relocs.
728 (elf_i386_gc_sweep_hook): Likewise.
729 (allocate_dynrelocs): Likewise.
730 (elf_i386_size_dynamic_sections): Likewise.
731 (elf_i386_relocate_section): Likewise.
732 (elf_i386_finish_dynamic_symbol): Likewise.
733 (bfd_elf32_mkobject, elf_backend_object_p): Define.
734 * elfxx-ia64.c (struct elfNN_ia64_dyn_sym_info): Add tprel_offset,
735 dtpmod_offset, dtprel_offset, tprel_done, dtpmod_done, dtprel_done,
736 want_tprel, want_dtpmod, want_dtprel.
737 (elfNN_ia64_tprel_base, elfNN_ia64_dtprel_base): New functions.
738 (ia64_howto_table): Add TLS relocs, rename R_IA64_LTOFF_TP22 to
739 R_IA64_LTOFF_TPREL22.
740 (elf_code_to_howto_index): Add TLS relocs.
741 (elfNN_ia64_check_relocs): Support TLS relocs.
742 (allocate_global_data_got): Account for TLS .got data.
743 (allocate_dynrel_entries): Account for TLS dynamic relocations.
744 (elfNN_ia64_install_value): Supprt TLS relocs.
745 (set_got_entry): Support TLS relocs.
746 (elfNN_ia64_relocate_section): Likewise.
747
c62e1cc3
NC
7482002-05-23 Nick Clifton <nickc@cambridge.redhat.com>
749
750 * elf32-arm.h (elf32_arm_final_link_relocate): For the Thumb
751 BLX reloc round the relocation up rather than down.
752 * coff-arm.c (coff_arm_relocate_section): Likewise.
753
c5a43a5d
L
7542002-05-21 H.J. Lu (hjl@gnu.org)
755
756 * linker.c (_bfd_generic_link_add_one_symbol): Allow multiple
757 definition.
758
afbe61cf
AM
7592002-05-22 Alan Modra <amodra@bigpond.net.au>
760
761 * elf64-ppc.c (ppc64_elf_size_stubs): Don't strip .branch_lt.
762 (ppc64_elf_relocate_section): Handle unresolved relocs in opd.
763
9c07fe7c
AM
7642002-05-22 Alan Modra <amodra@bigpond.net.au>
765
766 * elf64-ppc.c (ppc64_elf_relocate_section): Return false for
767 unresolved relocs.
768 (ppc64_elf_size_dynamic_sections): Check for splt NULL.
769
21611032
TS
7702002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
771
772 * bfd/bfd.c (bfd_get_arch_size): Remove bfd_set_error call for
773 non-ELF targets.
774
41241523
TS
7752002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
776
777 * elf-bfd.h (elf_backend_emit_relocs): Change prototype to return
778 an error value.
779 * elflink.h (elf_link_output_relocs): Likewise. Improve error message.
780 return with false on error.
781 (elf_link_input_bfd): Check reloc_emitter return value.
782
658f2588
JT
7832002-05-21 Jason Thorpe <thorpej@wasabisystems.com>
784
785 * config.bfd (armeb-*-netbsdelf*): New target.
786
c862ae31
AM
7872002-05-20 Alan Modra <amodra@bigpond.net.au>
788
789 * elf64-ppc.c (ppc_build_one_stub): Point undefined function syms
790 at the plt call stub.
791
6dd14845
TS
7922002-05-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
793
794 * cpu-mips.c (mips_compatible): Don't try to check machine
795 compatibility.
796
a58d9c34
TR
7972002-05-18 Tom Rix <trix@redhat.com>
798
799 * coff64-rs6000.c (_bfd_xcoff64_swap_aux_out): Fix C_FILE auxent.
800
ef60b7ff
AM
8012002-05-17 Alan Modra <amodra@bigpond.net.au>
802
803 * elf64-ppc.c (ppc64_elf_info_to_howto): Formatting.
804 (ppc64_elf_relocate_section): Don't warn about reloc overflow when
805 we've already warned about an undefined symbol. Report more
806 detail on reloc errors.
807
a703a6ea
AM
8082002-05-17 Alan Modra <amodra@bigpond.net.au>
809
810 * acinclude.m4 (AM_INSTALL_LIBBFD): New.
811 * configure.in: Invoke AM_INSTALL_LIBBFD.
812 * Makefile.am (install-data-local): Revert 2002-05-13. Move to..
813 (install_libbfd): .. New target.
814 (uninstall_libbfd): Likewise.
815 (install-bfdlibLTLIBRARIES): Likewise.
816 (uninstall-bfdlibLTLIBRARIES): Likewise.
817 (bfdlibdir): New.
818 (bfdincludedir): New.
819 (lib_LTLIBRARIES): Rename to bfdlib_LTLIBRARIES.
820 * aclocal.m4: Regenerate.
821 * configure: Regenerate.
822 * Makefile.in: Regenerate.
823
2c13d98b
NC
8242002-05-17 Stuart Balfour <sbalfour@cisco.com>
825
826 * hash.c (bfd_hash_lookup): Remove computation of len from inside
827 hash loop.
828
629936c5
NC
8292002-05-16 Nick Clifton <nickc@cambridge.redhat.com>
830
831 * config.bfd: Add targets for sh64-linux (little endian and
832 big endian).
833
e4cf60a8
NC
8342002-05-15 Laurent Pinchart <laurent.pinchart@skynet.be>
835
836 * peXXigen.c (pe_print_idata): Do not assume that the first thunk
837 is located in the same section as the import table. Instead
838 check, and if necessary load the section containing the thunk.
839
d1e66cd4
NC
8402002-05-15 Nick Clifton <nickc@cambridge.redhat.com>
841
842 * aix5ppc-core.c (xcoff64_core_p): Replace bfd_read with
ea1e4b0d
AM
843 bfd_bread.
844 (xcoff64_core_file_matches_executable_p): Replace bfd_read
845 with bfd_bread.
d1e66cd4 846
2d653fc7
AM
8472002-05-15 Alan Modra <amodra@bigpond.net.au>
848
849 * aix5ppc-core.c: Warning fixes.
850 * aout-adobe.c (aout_32_bfd_link_just_syms): Define.
851 * aout-target.h (MY_bfd_link_just_syms): Define.
852 * aout-tic30.c (MY_bfd_link_just_syms): Define.
853 * bfd.c (bfd_link_just_syms): Define.
854 * binary.c (binary_bfd_link_just_syms): Define.
855 * bout.c (b_out_bfd_link_just_syms): Define.
856 * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Update initializer.
857 * coff64-rs6000.c (rs6000coff64_vec, aix5coff64_vec): Likewise.
858 * coffcode.h (coff_bfd_link_just_syms): Define.
859 * elf-bfd.h (enum elf_link_info_type): Add ELF_INFO_TYPE_JUST_SYMS.
860 (elf_discarded_section): Check for ELF_INFO_TYPE_JUST_SYMS.
861 (_bfd_elf_link_just_syms): Declare.
862 * elf.c (_bfd_elf_link_just_syms): New function.
863 * elf-eh-frame.c (_bfd_elf_maybe_strip_eh_frame_hdr): Check that
864 sections haven't already been discarded by the linker.
865 * elflink.h (elf_link_add_object_symbols): Likewise for stab
866 sections and SEC_MERGE sections.
867 (elf_bfd_discard_info): Similarly here.
868 * elfxx-target.h (bfd_elfNN_bfd_link_just_syms): Define.
869 * i386msdos.c (msdos_bfd_link_just_syms): Define.
870 * i386os9k.c (os9k_bfd_link_just_syms): Define.
871 * ieee.c (ieee_bfd_link_just_syms): Define.
872 * ihex.c (ihex_bfd_link_just_syms): Define.
873 * libbfd-in.h (_bfd_nolink_bfd_link_just_syms): Define.
874 (_bfd_generic_link_just_syms): Declare.
875 * libecoff.h (_bfd_ecoff_bfd_link_just_syms): Define.
876 * linker.c (_bfd_generic_link_just_syms): New function.
877 * mmo.c (mmo_bfd_link_just_syms): Define.
878 * nlm-target.h (nlm_bfd_link_just_syms): Define.
879 * oasys.c (oasys_bfd_link_just_syms): Define.
880 * ppcboot.c (ppcboot_bfd_link_just_syms): Define.
881 * som.c (som_bfd_link_just_syms): Define.
882 * srec.c (srec_bfd_link_just_syms): Define.
883 * targets.c (struct bfd_target): Add _bfd_link_just_syms.
884 (BFD_JUMP_TABLE_LINK): And here.
885 * tekhex.c (tekhex_bfd_link_just_syms): Define.
886 * versados.c (versados_bfd_link_just_syms): Define.
887 * vms.c (vms_bfd_link_just_syms): Define.
888 * libbfd.h: Regenerate.
889 * bfd-in2.h: Regenerate.
890
cb7394f2
TS
8912002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
892
893 * elf32-mips.c: Remove superfluous definitions copied from
894 elfxx-mips.c.
895 (bfd_elf32_bigmips_vec,bfd_elf32_littlemips_vec): Use the
896 SGIish vectors to check the special case.
897 (mips_elf_hi16_reloc): Fix comment.
898 (mips_elf_got16_reloc): Likewise.
899 (_bfd_mips_elf32_gprel16_reloc): Likewise.
900 (elf_reloc_map): Code cleanup.
901 (mips_reloc_map): Add comment.
902 (bfd_elf23_bfd_reloc_type_lookup): Code cleanup.
903 (mips_elf32_rtype_to_howto): Likewise.
904 (mips_elf32_discard_info): Likewise.
905 (elf32_mips_irix_compat): Invert logic: Only SGIish vectors
906 lead to IRIX compatibility now.
907
8dc1a139
TS
9082002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
909
910 * elfxx-mips.c: Call it IRIX, not Irix in comments.
911
2051e1b5
JT
9122002-05-13 Jason Thorpe <thorpej@wasabisystems.com>
913
914 * config.bfd (shle-*-netbsdelf*): Add target which includes
915 sh64 support.
916
83954261
AM
9172002-05-13 David Edelsohn <edelsohn@gnu.org>
918
919 * configure.in: Revert 2002-04-07. Instead, auto-configure
920 HAVE_ST_C_IMPL.
921 * configure: Regenerate.
922 * config.in: Regenerate.
923 * rs6000-core.c (CNEW_IMPL): Guard use of c_impl with HAVE_ST_C_IMPL
924 or AIX_5_CORE.
925
a9bf1154
NC
9262002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
927
928 * configure.in (sparc*-*-openbsd*): Support sparc64-openbsd
929 corefiles as well.2
930 * configure: Regenerate.
931
3129eb7a
AM
9322002-05-13 Alan Modra <amodra@bigpond.net.au>
933
934 * Makefile.am (install-data-local): Install headers to
935 $(exec_prefix)/include.
936 * Makefile.in: Regenerate.
937
a9a32010
DJ
9382002-05-11 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
939 Daniel Jacobowitz <drow@mvista.com>
940
941 * coff-sh.c (sh_reloc_map): Map to R_SH_IMM32 for non-PE. Don't
942 map BFD_RELOC_RVA.
943
9442002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
690cc98b
NC
945
946 * config.bfd (alpha*-*-openbsd*, sparc64*-*-openbsd*,
947 hppa*-*-openbsd*): New targets.
948 * configure.in (alpha*-*-openbsd*): Set COREFILE.
949 * configure: Regenerate.
950
f1f0d9ab
TR
9512002-05-10 Tom Rix <trix@redhat.com>
952
ea1e4b0d 953 * coff64-rs6000.c (xcoff64_reloc_type_br): New function for
f1f0d9ab
TR
954 xcoff64_ppc_relocate_section.
955 * coff-rs6000.c : Extern common xcoff_reloc_type functions.
956 * libxcoff.h: Common xcoff_reloc_type function declaration.
957
c432ba1a
AM
9582002-05-10 Alan Modra <amodra@bigpond.net.au>
959
16a10388 960 * elf32-i386.c (elf_i386_relocate_section): Remove overflow checks
90937f86 961 added in 2002-05-09 commit.
16a10388 962
c432ba1a
AM
963 * elf32-hppa.c (elf32_hppa_size_stubs): Revert part of 2002-05-04,
964 don't look for stubs on all undefined syms.
965
4a335f3d
AM
9662002-05-09 Alan Modra <amodra@bigpond.net.au>
967
8fc39d5d
AM
968 * elf64-ppc.c (RA_REGISTER_MASK, RA_REGISTER_SHIFT): Delete.
969 (ppc64_elf_howto_raw <R_PPC64_RELATIVE>): Not pc_relative or
970 pcrel_offset.
971
4a335f3d
AM
972 * elf32-i386.c (elf_howto_table): Comments.
973 (elf_i386_relocate_section): Handle more relocs for relocatable
974 linking and against SEC_MERGE sections.
975
41fcb14e
AM
9762002-05-08 Alan Modra <amodra@bigpond.net.au>
977
978 * elf32-ppc.c (ppc_elf_create_got): New function.
979 (ppc_elf_create_dynamic_sections): Call ppc_elf_create_got before
ea1e4b0d 980 _bfd_elf_create_dynamic_sections. Correct .plt flags.
41fcb14e
AM
981 (ppc_elf_check_relocs): Use ppc_elf_create_got in place of
982 _bfd_elf_create_got_section.
983
b491616a
AM
9842002-05-07 Alan Modra <amodra@bigpond.net.au>
985
986 * elf-bfd.h (struct elf_backend_data): Add rela_normal.
987 * elfxx-target.h (elf_backend_rela_normal): Define.
988 (elfNN_bed): Init rela_normal.
989 * elflink.h (elf_link_input_bfd <emit_relocs>): Handle adjustment
990 for section symbols here if rela_normal. Simplify abs section test.
991 * elf-m10200.c (mn10200_elf_relocate_section): If relocatable,
992 return immediately. Remove code handling relocatable linking.
993 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
994 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
995 * elf32-i370.c (i370_elf_relocate_section): Likewise.
996 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
997 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
998 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
999 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
1000 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
1001 * elf32-s390.c (elf_s390_relocate_section): Likewise.
1002 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
1003 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
1004 * elf64-s390.c (elf_s390_relocate_section): Likewise.
1005 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
1006 * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
1007 * elf32-arm.h (elf32_arm_relocate_section): Likewise #ifndef USE_REL.
1008 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
1009 * elf-m10200.c (elf_backend_rela_normal): Define.
1010 * elf-m10300.c (elf_backend_rela_normal): Define.
1011 * elf32-fr30.c (elf_backend_rela_normal): Define.
1012 * elf32-i370.c (elf_backend_rela_normal): Define.
1013 * elf32-i860.c (elf_backend_rela_normal): Define.
1014 * elf32-m68k.c (elf_backend_rela_normal): Define.
1015 * elf32-mcore.c (elf_backend_rela_normal): Define.
1016 * elf32-openrisc.c (elf_backend_rela_normal): Define.
1017 * elf32-ppc.c (elf_backend_rela_normal): Define.
1018 * elf32-s390.c (elf_backend_rela_normal): Define.
1019 * elf32-xstormy16.c (elf_backend_rela_normal): Define.
1020 * elf64-ppc.c (elf_backend_rela_normal): Define.
1021 * elf64-s390.c (elf_backend_rela_normal): Define.
1022 * elf64-x86-64.c (elf_backend_rela_normal): Define.
1023 * elfxx-ia64.c (elf_backend_rela_normal): Define.
1024 * elf32-arm.h (elf_backend_rela_normal): Define #ifndef USE_REL.
1025 * elf32-m32r.c (elf_backend_rela_normal): Likewise.
1026
df212a7e
NC
10272002-05-06 Nick Clifton <nickc@cambridge.redhat.com>
1028
1029 * elf32-arm.h (elf32_arm_final_link_relocate): Convert
1030 'reloc_signed_max' and 'reloc_signed_min' into half-word offsets.
1031
3decf53c
AM
10322002-05-06 Alan Modra <amodra@bigpond.net.au>
1033
1034 * elflink.h (elf_link_input_bfd <emit_relocs>): Adjust r_offset
1035 when not relocatable. Fix reloc_emitter call for K&R.
1036
f46c2da6
AM
10372002-05-04 Alan Modra <amodra@bigpond.net.au>
1038
1039 * elf64-ppc.c (ppc64_elf_relocate_section): Reinstate code
1040 reloading local sym addend mistakenly removed in 2002-05-01 change.
1041
1042 * dwarf2.c (struct line_head): Make prologue_length a bfd_vma.
1043 (read_abbrevs): Change "offset" param to bfd_vma.
1044 (parse_comp_unit): Change "version" and addr_size to unsigned ints.
1045 Change "abbrev_offset" to bfd_vma.
1046 (read_indirect_string): Use correct conversion chars in error
1047 message format string, cast bfd_vma's to unsigned long.
1048 (read_abbrevs): Likewise.
1049 (read_attribute_value): Likewise.
1050 (decode_line_info): Likewise.
1051 (scan_unit_for_functions): Likewise.
1052 (parse_comp_unit): Likewise.
1053
59862849
TR
10542002-05-04 Tom Rix <trix@redhat.com>
1055
1056 * coffswap.h (coff_swap_reloc_in): Remove XCOFF support.
1057 (coff_swap_reloc_out): Same.
1058 * coff-rs6000.c: (xcoff_swap_reloc_in): Moved from coffswap.h.
1059 (xcoff_swap_reloc_out): Same.
1060 (xcoff_rtype2howto): Renamed from _bfd_xcoff_rtype2howto. Special
1061 case some 16 bit relocs. Add reloc value to output.
1062 (xcoff_howto_table): Remove 64 bit R_POS, add 16 bit
ea1e4b0d 1063 R_RBR. Improve names.
59862849
TR
1064 (_bfd_xcoff_reloc_type_lookup): Adjust for removal of 64 bit R_POS.
1065 (bfd_xcoff_backend_data): Update with new reloc swap names.
1066 (bfd_pmac_xcoff_backend_data) : Same.
1067 * coff64-rs6000.c: (xcoff64_swap_reloc_in): Moved from coffswap.h.
1068 (xcoff64_swap_reloc_out): Same.
ea1e4b0d 1069 (xcoff64_rtype2howto): Special case some 16 bit relocs and 32 bit
59862849 1070 R_POS. Add reloc value to output.
ea1e4b0d
AM
1071 (xcoff64_howto_table): Move 64 bit R_POS to first entry. Add 16
1072 bit R_RBR. Improve names, masks.
59862849
TR
1073 (xcoff64_reloc_type_lookup): Adjust for move of 64 bit R_POS.
1074 (bfd_xcoff_backend_data): Update with new reloc swap names.
1075 (bfd_xcoff_aix5_backend_data) : Same.
1076
b4655ea9
AM
10772002-05-04 Alan Modra <amodra@bigpond.net.au>
1078
1079 * elf32-hppa.c (struct elf32_hppa_link_hash_table): Add
1080 bfd_count top_index, input_list, all_local_syms.
1081 (elf32_hppa_setup_section_lists): New function, split from
1082 elf32_hppa_size_stubs.
1083 (elf32_hppa_next_input_section): Likewise.
1084 (group_sections): Likewise.
1085 (get_local_syms): Likewise.
1086 (elf32_hppa_size_stubs): Adjust for split out functions. Look for
1087 stubs on undefined syms too.
1088 (elf32_hppa_set_gp): Use bfd_link_hash* instead of elf_link_hash*.
8fc39d5d 1089 Only access htab elf fields when we have an elf hash table.
b4655ea9
AM
1090 * elf32-hppa.h (elf32_hppa_setup_section_lists): Declare.
1091 (elf32_hppa_next_input_section): Declare.
1092
301e3139
AM
10932002-05-04 Bob Byrnes <byrnes@curl.com>
1094
1095 * opncls.c (_bfd_new_bfd_contained_in): Check return value of
1096 _bfd_new_bfd.
1097
7c5fcef7
L
10982002-05-03 H.J. Lu (hjl@gnu.org)
1099
1100 * elfxx-mips.c (mips_elf_link_hash_entry): Add forced_local.
1101 (mips_elf_link_hash_newfunc): Initialize forced_local to false.
1102 (mips_elf_record_global_got_symbol): Call _bfd_mips_elf_hide_symbol
1103 to hide a global symbol.
1104 (_bfd_mips_elf_hide_symbol): Return if forced_local is true. Set
ea1e4b0d 1105 forced_local to true.
7c5fcef7 1106
84de6048
RH
11072002-05-02 Richard Henderson <rth@redhat.com>
1108
1109 * elf64-alpha.c (elf64_alpha_relocate_section): Force relative relocs
1110 vs SHN_UNDEF to zero.
1111
805fc799
AM
11122002-05-02 Alan Modra <amodra@bigpond.net.au>
1113
c061c2d8
AM
1114 * elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_SECTOFF>): Change to a
1115 16 bit reloc.
1116 <R_PPC64_SECTOFF_DS>: Likewise.
1117 (ppc64_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
1118 SECTOFF reloc.
1119 * elf32-ppc.c (ppc_elf_howto_raw <R_PPC_SECTOFF>): Correct.
1120 (ppc_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
1121 SECTOFF reloc.
1122
805fc799
AM
1123 * elf64-ppc.c (ppc64_elf_addr16_ha_reloc): Delete.
1124 (ppc64_elf_ha_reloc): New function.
1125 (ppc64_elf_brtaken_reloc): New function.
1126 (ppc64_elf_sectoff_reloc): New function.
1127 (ppc64_elf_sectoff_ha_reloc): New function.
1128 (ppc64_elf_toc_reloc): New function.
1129 (ppc64_elf_toc_ha_reloc): New function.
1130 (ppc64_elf_toc64_reloc): New function.
1131 (ppc64_elf_unhandled_reloc): New function.
1132 (ppc64_elf_howto_raw): Use the above.
1133 <R_PPC64_RELATIVE>: Mark pc_relative, pcrel_offset.
1134 <R_PPC64_SECTOFF>: Not pc_relative or pcrel_offset. Fix dst_mask.
1135 <R_PPC64_SECTOFF_DS>: Likewise.
1136 (IS_ABSOLUTE_RELOC): Update.
1137 (struct ppc_link_hash_table): Add have_undefweak.
1138 (ppc64_elf_link_hash_table_create): Init.
1139 (func_desc_adjust): Set have_undefweak.
1140 (ppc64_elf_func_desc_adjust): Call func_desc_adjust earlier. Only
1141 add the .sfpr blr when have_undefweak.
1142 (ppc64_elf_setup_section_lists): Check hash table flavour.
1143 (ppc64_elf_next_input_section): Move output_section->owner test to
1144 ppc64elf.em.
1145 (ppc64_elf_set_toc): Rename to ppc64_elf_toc, remove info param
1146 and relocatable test. Return TOCstart and don't set elf_gp.
1147 (ppc64_elf_relocate_section): Correct BRTAKEN/BRNTAKEN branch
1148 offset calculation. Add assert on weak sym branch tweaks.
1149 * elf64-ppc.h (ppc64_elf_set_toc): Delete.
1150 (ppc64_elf_toc): Declare.
1151 (ppc64_elf_next_input_section): Update.
ea1e4b0d 1152
818c39a3
AM
11532002-05-01 Alan Modra <amodra@bigpond.net.au>
1154
1155 * syms.c (_bfd_stab_section_find_nearest_line): Don't bomb on NULL
1156 file_name.
1157
721956f4
AM
11582002-05-01 Alan Modra <amodra@bigpond.net.au>
1159
1160 * elf64-ppc.c (CROR_151515, CROR_313131): Define.
1161 (ppc64_elf_relocate_section): Use them. Don't look for plt calls
1162 on R_PPC64_ADDR24 relocs. Require a nop or no link reg on plt
1163 call branches. Correct undefined weak destination.
1164 (ppc64_elf_func_desc_adjust): Always create at least one blr in
1165 .sfpr, and correct case where either only savef* or restf* is
1166 needed.
1167
1168 Long branch stubs, multiple stub sections.
1169 * elf64-ppc.h (ppc64_elf_setup_section_lists): Declare.
1170 (ppc64_elf_next_input_section): Declare.
1171 * elf64-ppc.c: Move linker-only prototypes.
1172 (STUB_SUFFIX): Define.
1173 (enum ppc_stub_type): New.
1174 (struct ppc_stub_hash_entry): New.
1175 (struct ppc_branch_hash_entry): New.
1176 (struct ppc_link_hash_entry): Add stub_cache, oh.
1177 (struct ppc_link_hash_table): Add stub_hash_table etc. Remove
1178 sstub. Add sbrlt, srelbrlt, has_14bit_branch, stub_iteration.
1179 Rename plt_overflow to stub_error.
1180 (ppc_stub_hash_lookup): Define.
1181 (ppc_branch_hash_lookup): Define.
1182 (stub_hash_newfunc): New function.
1183 (branch_hash_newfunc): New function.
1184 (link_hash_newfunc): Init new fields.
1185 (ppc64_elf_link_hash_table_create): Likewise.
1186 (ppc64_elf_link_hash_table_free): New function.
1187 (ppc_stub_name): New function.
1188 (ppc_get_stub_entry): New function.
1189 (ppc_add_stub): New function.
1190 (create_linkage_sections): Use bfd_make_section_anyway. Create
1191 .branch_lt and .rela.branch_lt sections. Don't create .stub.
1192 (ppc64_elf_check_relocs): Set has_14bit_branch on R_PPC64_REL14*,
1193 and set up for plt call stubs. Link func and func desc syms.
1194 (ppc64_elf_gc_sweep_hook): Handle REL14* as per REL24.
1195 (func_desc_adjust): Avoid hash lookup when func desc sym available
1196 via shortcut, and set links when processing.
1197 (ppc64_elf_hide_symbol): Likewise.
1198 (allocate_dynrelocs): Don't allocate stub section here.
1199 (ppc64_elf_size_dynamic_sections): Handle sbrlt and srelbrlt.
1200 Remove sstub code.
1201 (ppc_type_of_stub): New function.
1202 (build_one_stub): Delete.
1203 (ppc_build_one_stub): New function.
1204 (ppc_size_one_stub): New function.
1205 (ppc64_elf_setup_section_lists): New function.
1206 (ppc64_elf_next_input_section): New function.
1207 (group_sections): New function.
1208 (get_local_syms): New function.
1209 (ppc64_elf_size_stubs): Rewrite.
1210 (ppc64_elf_build_stubs): Rewrite.
1211 (ppc64_elf_relocate_section): Look up stub entry for REL24
1212 relocs. Don't propagate REL14* to dynamic objects. Look for long
1213 branch stubs if REL14* or REL24 relocs won't reach.
1214 (bfd_elf64_bfd_link_hash_table_free): Define.
1215
09c2219b
MM
12162002-04-30 Mark Mitchell <mark@codesourcery.com>
1217
1218 * bfd/config.bfd: Add support for powerpc-*-windiss.
1219
07b678c0
TR
12202002-04-30 Tom Rix <trix@redhat.com>
1221
1222 * xcofflink.c (xcoff_link_add_symbols): Always copy undef C_EXT
1223 symbol names into the hash table.
1224
dbe341c6
TR
12252002-04-28 Tom Rix <trix@redhat.com>
1226
1227 * coff-rs6000.c (xcoff_calculate_relocation) : Function table for
ea1e4b0d 1228 calulating relocations.
dbe341c6 1229 (xcoff_complain_overflow) : Function table for relocation errors.
ea1e4b0d
AM
1230 (xcoff_ppc_relocate_section): Use relocation and complain function
1231 tables.
1232 (xcoff_complain_overflow_unsigned_func): New complain function.
dbe341c6
TR
1233 (xcoff_complain_overflow_signed_func): Same.
1234 (xcoff_complain_overflow_bitfield_func): Same.
1235 (xcoff_complain_overflow_dont_func): Same.
1236 (xcoff_reloc_type_crel): New recot function.
1237 (xcoff_reloc_type_br): Same.
1238 (xcoff_reloc_type_ba): Same.
1239 (xcoff_reloc_type_toc): Same.
1240 (xcoff_reloc_type_rel): Same.
1241 (xcoff_reloc_type_neg): Same.
1242 (xcoff_reloc_type_pos): Same.
1243 (xcoff_reloc_type_fail): Same.
1244 (xcoff_reloc_type_noop): Same.
1245 * libxcoff.h : Declare common parts for xcoff64.
1246 * coff64-rs6000.c (xcoff64_ppc_relocate_section): Use relocation
ea1e4b0d 1247 and complain function tables.
dbe341c6 1248
985142a4
AM
12492002-04-28 Alan Modra <amodra@bigpond.net.au>
1250
1251 * elf64-x86-64.c (struct elf64_x86_64_dyn_relocs): Comment typo.
1252 * elf32-hppa.c (elf32_hppa_final_link): Formatting.
1253
eba91044
AM
12542002-04-26 Alan Modra <amodra@bigpond.net.au>
1255
e54fdaa5
AM
1256 * opncls.c (bfd_make_readable): Call bfd_section_list_clear.
1257 * xcofflink.c (xcoff_link_add_dynamic_symbols): Likewise.
1258
a50c1845
AM
1259 * elflink.h (elf_bfd_final_link): Ensure input bfd class is the
1260 same as the output before calling elf_link_input_bfd.
1261
eba91044
AM
1262 * coffcode.h (coff_compute_section_file_positions): Set
1263 section_tail after shuffling section list.
1264
3c25c5f6
NC
12652002-04-24 Christian Groessler <chris@groessler.org>
1266
1267 * coff-z8k.c (extra_case): Fix R_IMM32 relocations: The
1268 addresses are 23bit with a special layout, not plain 32bit
1269 values. Prevent relocation of immediate values.
1270
40d32fc6
CD
12712002-04-24 Chris G. Demetriou <cgd@broadcom.com>
1272
1273 * elfxx-mips.c (_bfd_mips_elf_print_private_bfd_data): If MDMX or
1274 MIPS-16 ASE flags are set, print something to indicate that.
1275
067fa4a6
AM
12762002-04-23 Alan Modra <amodra@bigpond.net.au>
1277
1278 * elf32-hppa.c (hppa_type_of_stub): Correct and simplify condition
1279 under which a plt call stub is used.
1280 (final_link_relocate): Similarly.
1281 (allocate_plt_static): Clear h-plabel except when plt entry is
1282 exclusively used for a plabel.
1283 (allocate_dynrelocs): Use the above to simplify plt sizing.
1284 (struct elf32_hppa_link_hash_table): Add has_22bit_branch.
1285 (elf32_hppa_link_hash_table_create): Init.
1286 (BL22_RP): Define.
1287 (hppa_build_one_stub): Use BL22_RP if has_22bit_branch.
1288 (elf32_hppa_check_relocs): Set has_22bit_branch.
1289
1290 * elf32-hppa.c (elf32_hppa_check_relocs): Remove debug message.
1291 (final_link_relocate): Likewise.
1292
af40ce3c
JJ
12932002-04-22 Jakub Jelinek <jakub@redhat.com>
1294
1295 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't build
1296 search table if some FDE is DW_EH_PE_aligned encoded either.
1297 (_bfd_elf_write_section_eh_frame): Handle terminating FDE specially.
1298
09ae86c2
JJ
12992002-04-22 Richard Smith <richard@ex-parrot.com>
1300 Jakub Jelinek <jakub@redhat.com>
1301
1302 * elf-eh-frame.c (struct eh_cie_fde): Add per_encoding_relative.
1303 (_bfd_elf_discard_section_eh_frame): Set it for CIEs with pcrel
1304 encoded personality.
1305 (_bfd_elf_write_section_eh_frame): Adjust pcrel encoded personality
1306 for CIE/FDE removal.
1307
deeb2cd7
TR
13082002-04-20 Tom Rix <trix@redhat.com>
1309
1310 * coff64-rs6000.c (_bfd_xcoff64_swap_aux_in): Fix C_FILE auxent.
1311
99dc0092
AM
13122002-04-20 Alan Modra <amodra@bigpond.net.au>
1313
aa3d5824
AM
1314 * archures.c (bfd_lookup_arch): Move the list order comment..
1315 (struct bfd_arch_info): ..to where it belongs.
1316 * bfd-in2.h: Regenerate.
1317
99dc0092
AM
1318 * archures.c (bfd_lookup_arch): Add comment on list order.
1319 (bfd_default_set_arch_mach): Use bfd_lookup_arch.
1320 * cpu-powerpc.c (bfd_powerpc_archs): Re-order so that the default
1321 is always at head of list.
1322
7831a775
NC
13232002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
1324
1325 * coff-arm.c (coff_thumb_pcrel_12, coff_thumb_pcrel_9,
1326 insert_thumb_branch, record_thumb_to_arm_glue): Suppress
1327 definition of these functions for ARM_WINCE builds as they are
1328 not used.
ea1e4b0d 1329 (SWAP_IN_RELOC_OFFSET, SWAP_OUT_RELOC_OFFSET): Do not define
7831a775
NC
1330 for ARM_WINCE builds.
1331
13322002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
1333
ea1e4b0d 1334 * coff-arm.c (bfd_arm_process_before_allocation):
7831a775
NC
1335
13362002-04-17 J"orn Rennecke <joern.rennecke@superh.com>
a44d7f9c
JR
1337
1338 * cpu-sh.c (scan_mach): Delete.
1339 (arch_info_struct): Replace scan_mach with bfd_default_scan.
1340 (bfd_sh_arch): Likewise.
1341
3d8dbe36
NC
13422002-04-16 Nick Clifton <nickc@cambridge.redhat.com>
1343
1344 * ihex.c (ihex_write_object_contents): Fix check for records
1345 crossing 64K boundaries.
1346
4ab82700
AM
13472002-04-16 Alan Modra <amodra@bigpond.net.au>
1348
1349 * elf32-m32r.c (m32r_elf_add_symbol_hook): Check the hash table
1350 type rather than just assuming entries are ELF.
1351 * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
1352 * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
1353 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Likewise.
1354 * elf64-mmix.c (mmix_elf_add_symbol_hook): Use bfd_link_hash_entry
1355 rather than elf_link_hash_entry.
1356
036fe0fe
RH
13572002-04-15 Richard Henderson <rth@redhat.com>
1358
1359 * elf32-mips.c (mips_elf32_object_p): Revert 0404 fragment: allow
1360 n32 binaries.
1361
c4f3d130
NC
13622002-04-15 Michael Snyder <msnyder@redhat.com>
1363
1364 * opncls.c (bfd_close): Write contents if writeable.
1365 Minor formatting tidy-ups.
1366
4ab82700 13672002-04-15 Alan Modra <amodra@bigpond.net.au>
27242387
AM
1368
1369 * elf32-ppc.c (ppc_elf_add_symbol_hook): Check the hash table type.
1370
0c04d169
MS
13712002-04-12 Michael Snyder <msnyder@redhat.com>
1372
1373 * bfd-in.h (bfd_get_section_lma): New access macro.
1374 Minor white-space fix-up.
1375
89d4966f
AM
13762002-04-12 Alan Modra <amodra@bigpond.net.au>
1377
1378 * elf.c (prep_headers): Don't zero EI_OSABI, EI_ABIVERSION or
1379 header pad.
1380
8d0da3c2
DD
13812002-04-09 DJ Delorie <dj@redhat.com>
1382
1383 * elfarm-nabi.c (elf32_arm_howto_table): Fix ABS16 masks.
1384
05793179
NC
13852002-04-09 Casper S. Hornstrup <chorns@users.sourceforge.net>
1386
1387 * coffcode.h (coff_read_word): New.
1388 (coff_compute_checksum): New.
1389 (coff_apply_checksum): New.
1390 (coff_write_object_contents): Call coff_apply_checksum () to
1391 apply checksum to PE image.
1392
46fe4e66
AM
13932002-04-08 Randolph Chung <tausq@debian.org>
1394
1395 * elf32-hppa.c (hppa_unwind_entry_compare): Move to elf-hppa.h.
1396 (elf32_hppa_final_link): Split out sorting logic to..
1397 * elf-hppa.h (elf_hppa_sort_unwind): ..here.
1398 (elf_hppa_final_link): Call elf_hppa_sort_unwind.
1399
3b5b409c
AC
14002002-04-07 Andrew Cagney <ac131313@redhat.com>
1401
1402 * configure.in: Add missing ``|'' to powerpc-*-aix4.[4-9]*
1403 pattern.
1404 * configure: Re-generate.
1405
ac7b6ceb
AC
14062002-04-07 Andrew Cagney <ac131313@redhat.com>
1407
1408 * configure.in: Only define AIX_CORE_DUMPX_CORE when AIX version
1409 is greater or equal to 4.3.3.
1410 * configure: Regenerate.
1411 Fix PR gdb/344.
1412
44aa49bb
HPN
14132002-04-05 Hans-Peter Nilsson <hp@axis.com>
1414
1415 * elf32-cris.c (cris_elf_howto_table) <R_CRIS_16_PCREL,
1416 R_CRIS_32_PCREL>: Fix typo in name.
1417 (cris_elf_check_relocs): Always create .rela.got here when
1418 R_CRIS_16_GOTPLT or R_CRIS_32_GOTPLT is seen.
1419 (elf_cris_adjust_gotplt_to_got): Don't create .rela.got here;
1420 assume it's created.
1421
e2d34d7d
DJ
14222002-04-04 Daniel Jacobowitz <drow@mvista.com>
1423
1424 * aout-adobe.c (aout_32_bfd_link_hash_table_free): Define.
1425 * aout-target.h (MY_bfd_link_hash_table_free): Conditionally
1426 define.
1427 * aout-tic30.c (MY_bfd_link_hash_table_free): Likewise.
1428 * bfd.c (bfd_link_hash_table_free): Define.
1429 * binary.c (binary_bfd_link_hash_table_free): Define.
1430 * bout.c (b_out_bfd_link_hash_table_free): Define.
1431 * coff-rs6000.c (rs6000coff_vec): Include
1432 _bfd_generic_link_hash_table_free.
1433 (pmac_xcoff_vec): Likewise.
1434 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
1435 (aix5coff64_vec): Likewise.
1436 * coffcode.h (coff_bfd_link_hash_table_free): Conditionally define.
1437 * elf-m10300.c (elf32_mn10300_link_hash_table_free): New function.
1438 (bfd_elf32_bfd_link_hash_table_free): Define.
1439 * elf32-hppa.c (elf32_hppa_link_hash_table_free): New function.
1440 (bfd_elf32_bfd_link_hash_table_free): Define.
1441 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_free): Conditionally
1442 define.
1443 * i386msdos.c (msdos_bfd_link_hash_table_free): Define.
1444 * i386os9k.c (os9k_bfd_link_hash_table_free): Define.
1445 * ieee.c (ieee_bfd_link_hash_table_free): Define.
1446 * ihex.c (ihex_bfd_link_hash_table_free): Define.
1447 * libbfd-in.h (_bfd_nolink_bfd_link_hash_table_free): Define.
1448 (_bfd_generic_link_hash_table_free): Add prototype.
1449 * libcoff-in.h (_bfd_xcoff_bfd_link_hash_table_free): Add prototype.
1450 * libecoff.h (_bfd_ecoff_bfd_link_hash_table_free): Define.
1451 * linker.c (_bfd_generic_link_hash_table_free): New function.
1452 * mmo.c (mmo_bfd_link_hash_table_free): Define.
1453 * nlm-target.h (nlm_bfd_link_hash_table_free): Define.
1454 * oasys.c (oasys_bfd_link_hash_table_free): Define.
1455 * ppcboot.c (ppcboot_bfd_link_hash_table_free): Define.
1456 * som.c (som_bfd_link_hash_table_free): Define.
1457 * srec.c (srec_bfd_link_hash_table_free): Define.
1458 * tekhex.c (tekhex_bfd_link_hash_table_free): Define.
1459 * versados.c (versados_bfd_link_hash_table_free): Define.
1460 * vms.c (vms_bfd_link_hash_table_free): New function.
1461 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_free): New function.
1462
1463 * coff-arm.c (coff_arm_link_hash_table_create): Use bfd_malloc
1464 instead of bfd_alloc.
1465 * coff-h8300.c (h8300_coff_link_hash_table_create): Likewise.
1466 * coff-mcore.c (coff_mcore_link_hash_table_create): Likewise.
1467 * coff-ppc.c (ppc_coff_link_hash_table_create): Likewise.
1468 * cofflink.c (_bfd_coff_link_hash_table_create): Likewise.
1469 * ecoff.c (_bfd_ecoff_bfd_link_hash_table_create): Likewise.
1470 * elf-m10300.c (elf32_mn10300_link_hash_table_create): Likewise.
1471 * elf.c (_bfd_elf_link_hash_table_create): Likewise.
1472 * elf32-arm.h (elf32_arm_link_hash_table_create): Likewise.
1473 * elf32-cris.c (elf_cris_link_hash_table_create): Likewise.
1474 * elf32-hppa.c (elf32_hppa_link_hash_table_create): Likewise.
1475 * elf32-i386.c (elf_i386_link_hash_table_create): Likewise.
1476 * elf32-m68k.c (elf_m68k_link_hash_table_create): Likewise.
1477 * elf32-s390.c (elf_s390_link_hash_table_create): Likewise.
1478 * elf32-sh.c (sh_elf_link_hash_table_create): Likewise.
1479 * elf64-alpha.c (elf64_alpha_bfd_link_hash_table_create): Likewise.
1480 * elf64-ppc.c (ppc64_elf_link_hash_table_create): Likewise.
1481 * elf64-s390.c (elf_s390_link_hash_table_create): Likewise.
1482 * elf64-sh64.c (sh64_elf64_link_hash_table_create): Likewise.
1483 * elf64-sparc.c (sparc64_elf_bfd_link_hash_table_create): Likewise.
1484 * elf64-x86-64.c (elf64_x86_64_link_hash_table_create): Likewise.
1485 * elfxx-mips.c (_bfd_mips_elf_link_hash_table_create): Likewise.
1486 * linker.c (_bfd_generic_link_hash_table_create): Likewise.
1487 * m68klinux.c (linux_link_hash_table_create): Likewise.
1488 * sparclinux.c (linux_link_hash_table_create): Likewise.
1489 * sunos.c (sunos_link_hash_table_create): Likewise.
1490 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Likewise.
1491
1492 * targets.c: Add _bfd_link_hash_table_free to xvec.
1493
1494 * bfd-in2.h: Regenerate.
1495 * libbfd.h: Regenerate.
1496 * libcoff.h: Regenerate.
1497
830629ab
AM
14982002-04-04 Alan Modra <amodra@bigpond.net.au>
1499
1500 * dep-in.sed: Cope with absolute paths.
1501 * Makefile.am (dep.sed): Subst TOPDIR, and not INCDIR.
1502 Run "make dep-am".
1503 * Makefile.in: Regenerate.
1504 * coff-arm.c: Fix copyright date.
1505 * cpu-h8300.c: Likewise.
1506 * cpu-i370.c: Likewise.
1507 * cpu-s390.c: Likewise.
1508 * cpu-mips.c: Likewise.
1509 * po/SRC-POTFILES.in: Regenerate.
1510
c6e90b02
TS
15112002-04-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1512
1513 * Makefile.am: Add elfxx-mips.c to the known backends.
1514 (elf32-mips.lo): remove dependency to coff/external.h.
1515 * Makefile.in: Regenerate.
1516 * configure.in: Add elfxx-mips.lo to all vectors using elf32-mips.lo
1517 Remove elf32-mips.lo from 64 bit vectors. Update dependencies
1518 accordingly.
1519 * configure: Regenerate.
1520 * elf-bfd.h: Move all MIPS ELF specific prototypes to elfxx-mips.h.
1521 (irix_compat_t): IRIX compatibility level, moved from elf32-mips.c.
1522 (elf_backend_mips_irix_compat, elf_backend_mips_rtype_to_howto): New
1523 MIPS specific backend functions.
1524 * elf32-mips.c: Moved most code to elfxx-mips.c.
1525 (mips_elf_hi16_reloc): Rename from _bfd_mips_elf_hi16_reloc and make
1526 static.
1527 (mips_elf_lo16_reloc): Likewise, was _bfd_mips_elf_lo16_reloc.
1528 (mips_elf_got16_reloc): Likewise, was _bfd_mips_elf_got16_reloc.
1529 (mips_elf_gprel32_reloc): Likewise, was _bfd_mips_elf_gprel32_reloc.
1530 (mips_elf32_rtype_to_howto): Rename from mips_rtype_to_howto. Changed
1531 interface to allow selection of the right REL or RELA howto table.
1532 (mips_elf32_object_p): Rename from _bfd_mips_elf_object_p and made
1533 static. Let it refuse n32 objects.
1534 (elf32_mips_grok_prstatus): Rename from _bfd_elf32_mips_grok_prstatus.
1535 (elf32_mips_grok_psinfo): Rename from _bfd_elf32_mips_grok_psinfo.
1536 (elf32_mips_discard_info): Rename from _bfd_elf32_mips_discard_info.
1537 (elf32_mips_ignore_discarded_relocs): Rename from
1538 _bfd_elf32_mips_ignore_discarded_relocs.
1539 (elf32_mips_write_section): Rename from _bfd_elf32_mips_write_section.
1540 (elf32_mips_irix_compat): New function, replaces IRIX_COMPAT.
1541 (elf_mips_howto_table_rela): Remove.
1542 * elf64-mips.c: Moved most code to elfxx-mips.c.
1543 (bfd_elf64_bfd_reloc_type_lookup): Make static.
1544 (mips_elf64_rtype_to_howto): New function.
1545 (mips_elf64_object_p): Likewise.
1546 (elf64_mips_irix_compat): Likewise.
1547 * elfxx-mips.c: New file containing common code merged together from
1548 elf32-mips.c and elf64-mips.c.
1549 * elfxx-mips.h: New file containing MIPS specific prototypes from
1550 elf-bfd.h.
1551 * elfxx-target.h: Add handling for elf_backend_mips_irix_compat and
1552 elf_backend_mips_rtype_to_howto.
1553
d8dce692
AM
15542002-04-04 Alan Modra <amodra@bigpond.net.au>
1555
1556 * srec.c (MAXCHUNK, Chunk): Revise comments.
1557 (srec_write_record): Correct buffer size.
1558 (srec_write_header): Do without intermediate buffer.
1559 (srec_write_section): Validate Chunk.
1560 (srec_write_terminator): Pass NULL instead of dummy buffer.
1561 (srec_write_symbols): Pass file and symbol names directly to
1562 bfd_bwrite so sprintf won't overflow buffer.
1563
b88a866a
JJ
15642002-04-03 Jakub Jelinek <jakub@redhat.com>
1565
1566 * elf32-sparc.c (elf32_sparc_relocate_section): Don't emit dynamic
1567 PC relative relocs against hidden symbols.
1568 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
1569
d7866f04
AM
15702002-04-03 Alan Modra <amodra@bigpond.net.au>
1571
1572 * elf.c (_bfd_elf_make_section_from_shdr): When setting section
1573 LMAs, loop over segments until p_vaddr and p_memsz specify an
1574 extent enclosing the section.
1575
9e81ee67
NC
15762002-04-02 Nick Clifton <nickc@cambridge.redhat.com>
1577
1578 * ihex.c (ihex_write_object_contents): Do not allow records to
1579 cross a 64K boundary - wrap if necessary.
1580
d2b64500
JT
15812002-04-01 Nathan Williams <nathanw@wasabisystems.com>
1582
1583 * elf.c (elfcore_netbsd_get_lwpid): Fix off-by-one error
1584 which caused the returned LWP ID to always be 0.
1585
e36f7d53
RH
15862002-04-01 Richard Henderson <rth@redhat.com>
1587
1588 * elf32-sparc.c (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
1589 (elf32_sparc_relocate_section): Use it to figure out when to
1590 initialize .got entries.
1591 * elf64-sparc.c: Similarly.
1592
e92d460e
AM
15932002-03-28 Alan Modra <amodra@bigpond.net.au>
1594
1595 * linker.c (link_action): Ignore duplicate warning syms.
1596 (_bfd_generic_link_write_global_symbol): Follow warning symbol link.
1597 * elflink.h (elf_adjust_dynstr_offsets): Likewise.
1598 (elf_adjust_dynamic_symbol): Likewise.
1599 (elf_export_symbol): Likewise.
1600 (elf_link_find_version_dependencies): Likewise.
1601 (elf_link_assign_sym_version): Likewise.
1602 (elf_link_sec_merge_syms): Likewise.
1603 (elf_link_output_extsym): Likewise.
1604 (elf_gc_sweep_symbol): Likewise.
1605 (elf_gc_propagate_vtable_entries_used): Likewise.
1606 (elf_gc_smash_unused_vtentry_relocs): Likewise.
1607 (elf_gc_allocate_got_offsets): Likewise.
1608 (elf_collect_hash_codes): Likewise.
1609 * elflink.c (elf_link_renumber_hash_table_dynsyms): Likewise.
1610 * elf-hppa.h (elf_hppa_unmark_useless_dynamic_symbols): Likewise.
1611 (elf_hppa_remark_useless_dynamic_symbols): Likewise.
1612 * elf-m10300.c (elf32_mn10300_finish_hash_table_entry): Likewise.
1613 * elf32-arm.h (elf32_arm_discard_copies): Likewise.
1614 * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Likewise.
1615 (elf_cris_discard_excess_dso_dynamics): Likewise.
1616 * elf32-hppa.c (clobber_millicode_symbols): Likewise.
1617 (mark_PIC_calls): Likewise.
1618 (allocate_plt_static): Likewise.
1619 (allocate_dynrelocs): Likewise.
1620 (readonly_dynrelocs): Likewise.
1621 * elf32-i386.c (allocate_dynrelocs): Likewise.
1622 (readonly_dynrelocs): Likewise.
1623 * elf32-i370.c (i370_elf_adjust_dynindx): Likewise.
1624 * elf32-m68k.c (elf_m68k_discard_copies): Likewise.
1625 * elf32-mips.c (mips_elf_output_extsym): Likewise.
1626 (mips_elf_sort_hash_table_f): Likewise.
1627 (mips_elf_check_mips16_stubs): Likewise.
1628 * elf32-s390.c (allocate_dynrelocs): Likewise.
1629 (readonly_dynrelocs): Likewise.
1630 * elf32-sh.c (sh_elf_discard_copies): Likewise.
1631 * elf32-xstormy16.c (xstormy16_relax_plt_check): Likewise.
1632 (xstormy16_relax_plt_realloc): Likewise.
1633 * elf64-alpha.c (elf64_alpha_calc_got_offsets_for_symbol): Likewise.
1634 (elf64_alpha_output_extsym): Likewise.
1635 * elf64-hppa.c (elf64_hppa_mark_exported_functions): Likewise.
1636 * elf64-mips.c (mips_elf64_sort_hash_table_f): Likewise.
1637 (mips_elf64_check_mips16_stubs): Likewise.
1638 (mips_elf64_output_extsym): Likewise.
1639 * elf64-ppc.c (func_desc_adjust): Likewise.
1640 (allocate_dynrelocs): Likewise.
1641 (readonly_dynrelocs): Likewise.
1642 * elf64-s390.c (allocate_dynrelocs): Likewise.
1643 (readonly_dynrelocs): Likewise.
1644 * elf64-sh64.c (sh64_elf64_discard_copies): Likewise.
1645 * elf64-x86-64.c (allocate_dynrelocs): Likewise.
1646 (readonly_dynrelocs): Likewise.
1647 * elfxx-ia64.c (elfNN_ia64_global_dyn_sym_thunk): Likewise.
1648 * aoutx.h (aout_link_write_other_symbol): Likewise.
1649 * cofflink.c (_bfd_coff_write_task_globals): Likewise.
1650 (_bfd_coff_write_global_sym): Likewise.
1651 * i386linux.c (linux_tally_symbols): Likewise.
1652 * m68klinux.c (linux_tally_symbols): Likewise.
1653 * sparclinux.c (linux_tally_symbols): Likewise.
1654 * pdp11.c (aout_link_write_other_symbol): Likewise.
1655 * sunos.c (sunos_scan_dynamic_symbol): Likewise.
1656 * xcofflink.c (xcoff_build_ldsyms): Likewise.
1657 (xcoff_write_global_symbol): Likewise.
1658
1659 * cofflink.c (_bfd_coff_final_link): Formatting.
1660 * cpu-mips.c (mips_compatible): Make static, prototype.
1661 * elf32-i386.c (elf_i386_check_relocs): Formatting.
1662 * elf32-sh.c (sh_elf_size_dynamic_sections): Likewise.
1663 * elf64-alpha.c (elf64_alpha_output_extsym): Likewise.
1664 * elf64-mips.c (mips_elf64_sort_hash_table): Likewise.
1665 (mips_elf64_final_link): Likewise.
1666 * elflink.h (elf_link_find_version_dependencies): Remove duplicate
1667 prototype.
1668
2106126f
NC
16692002-03-27 Nick Clifton <nickc@cambridge.redhat.com>
1670
1671 * coff-arm.c (SWAP_IN_RELOC_OFFSET): Define.
1672 (SWAP_OUT_RELOC_OFFSET): Define.
1673
b99d1833
AM
16742002-03-27 Gregory Steuck <greg@nest.cx>
1675
1676 * elf.c (_bfd_elf_get_symtab_upper_bound): Leave space for
1677 terminating NULL if empty symbol table.
1678 (_bfd_elf_get_dynamic_symtab_upper_bound): Likewise.
1679
ad43ed4c
L
16802002-03-26 H.J. Lu (hjl@gnu.org)
1681
1682 * elflink.h (elf_link_input_bfd): Revert the last change since
1683 the gcc exception handling isn't fixed yet.
1684
3851fca4
L
16852002-03-26 H.J. Lu (hjl@gnu.org)
1686
1687 * elflink.h (elf_link_input_bfd): Complain about relocations
1688 against local symbols in discarded sections.
1689
b91afed7
AM
16902002-03-26 Alan Modra <amodra@bigpond.net.au>
1691
1692 * elflink.h (elf_gc_mark): Don't recurse into non-ELF sections.
1693
dba143ef
AM
16942002-03-23 Alan Modra <amodra@bigpond.net.au>
1695
1696 * elf.c (_bfd_elf_make_section_from_shdr): Don't set lma based on
1697 section file offset for !SEC_LOAD sections.
1698
ee29b9fb
RE
16992002-03-21 Richard Earnshaw <rearnsha@arm.com>
1700
830629ab
AM
1701 * elf32-arm.h (elf32_arm_final_link_relocate <case R_ARM_GOTOFF>,
1702 <case R_ARM_GOT>): Handle relocations to Thumb functions.
ee29b9fb 1703
54327882
AM
17042002-03-21 Alan Modra <amodra@bigpond.net.au>
1705
1706 * coff64-rs6000.c (_bfd_xcoff64_put_symbol_name): Prototype.
1707 Whitespace changes.
1708 * archive.c: Update copyright date.
1709 * bfd-in2.h: Regenerate.
1710 * libbfd.h: Regenerate.
1711 * Makefile.am: Run "make dep-am"
1712 * Makefile.in: Regenerate.
1713 * po/SRC-POTFILES.in: Regenerate.
1714
1ee24f27
DJ
17152002-03-20 Daniel Jacobowitz <drow@mvista.com>
1716
1717 * dwarf2.c (struct funcinfo): Move up.
1718 (lookup_address_in_function_table): New argument function_ptr.
1719 Set it.
1720 (lookup_address_in_line_table): New argument function. If function
1721 is non-NULL, use it to handle ``addr'' before the first line note of
1722 the function.
1723 (comp_unit_find_nearest_line): Update and swap calls to
1724 lookup_address_in_function_table and lookup_address_in_line_table.
1725 * syms.c (_bfd_stab_section_find_nearest_line): Use the first
1726 N_SLINE encountered if we see an N_FUN before any N_SLINE.
1727
51b9608c
TR
17282002-03-20 Tom Rix <trix@redhat.com>
1729
ea1e4b0d 1730 * coff-rs6000.c (_bfd_xcoff_stat_arch_elt): Renamed from
51b9608c 1731 _bfd_xcoff_generic_stat_arch_elt. Fix format check.
ea1e4b0d 1732 * coff64-rs6000.c : Use _bfd_xcoff_stat_arch_elt.
51b9608c 1733
789c90aa
TR
17342002-03-19 Tom Rix <trix@redhat.com>
1735
ea1e4b0d 1736 * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Look through all
789c90aa
TR
1737 dynamic objects in archives.
1738
1da54d81
HPN
17392002-03-19 Hans-Peter Nilsson <hp@bitrange.com>
1740
1741 * elflink.h (NAME(bfd_elf,record_link_assignment)): Don't set
1742 STT_NOTYPE symbols to STT_OBJECT.
1743
7831a775 17442002-03-18 Jan Hubicka <jh@suse.cz>
beb43bb9
JH
1745
1746 * cpu-i386.c (bfd_x86_64_arch): Rename to "i386:x86-64"
1747
eb1e0e80
NC
17482002-03-18 Tom Rix <trix@redhat.com>
1749
1750 * aix5ppc.core.c : New file for AIX 5 64 bit core support.
1751 * bfd-in.h : Add bfd_xcoff_ar_archive_set_magic declaration.
1752 * coff-rs6000 (do_pad) : New function for archive padding.
1753 (do_copy) : New function for object file copying in archives.
1754 (do_shared_object_padding) : New function for padding shared
1755 objects to their text section alignment in archives.
1756 (bfd_xcoff_ar_achive_set_magic) : Stub.
1757 (xcoff_write_armap_big) : Use do_copy and do_pad.
1758 (xcoff_write_archive_contents_big) : Use do_shared_object_padding,
1759 do_copy and do_pad.
1760 * coff64-rs6000.c (xcoff64_write_ojbect_contents) : Use
ea1e4b0d 1761 bfd_xcoff_magic_number.
eb1e0e80
NC
1762 (xcoff64_bad_format_hook) : New function for _bfd_bad_format_hook
1763 fop.
1764 (xcoff_backend_data_r) : Use xcoff64_bad_format_hook.
1765 (bfd_xcoff_aix5_backend_data) : New Aix 5 backend data.
1766 (aix5coff64_vec) : New Aix 5 target aix5coff64-rs6000.
1767 * rs6000-core.c : Update copyright date.
ea1e4b0d 1768 * xcofflink.c (bfd_xcoff_size_dynamic_sections): Check for NULL
eb1e0e80
NC
1769 csectpp.
1770 * coffcode.h (coff_new_section_hook) : Use new accessor macros.
1771 (coff_set_arch_mach_hook) : Add Aix 5 U64_TOCMAGIC magic #.
1772 (coff_set_flags) : Use bfd_xcoff_magic_number.
1773 * libxcoff.h (bfd_xcoff_is_xcoff64): Add U64_TOCMAGIC.
1774 * configure.in : Add powerpc-*-aix5 and rs6000-*-aix5 support.
1775 * Makefile.am : Same.
1776 * config.bfd : Same.
1777 * targets.c : Same.
1778 * configure : Regnerate.
1779 * Makefile.in : Same.
1780 * bfd-in2.h : Same.
1781
a1c259a1
NC
17822002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
1783
1784 * po/fr.po: Updated version.
1785
4dae1ae7
AM
17862002-03-18 Alan Modra <amodra@bigpond.net.au>
1787
1788 * libbfd.c (bfd_write_bigendian_4byte_int): Return true iff success.
1789 * libbfd.h: Regenerate.
1790 * archive.c (coff_write_armap): Pass on failures from
1791 bfd_write_bigendian_4byte_int.
1792
36b4f6e7
L
17932002-03-14 H.J. Lu <hjl@gnu.org>
1794
1795 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the BFD
1796 error to bfd_error_nonrepresentable_section for reinit_array
1797 section in DSO.
1798
a1aefc76
NC
17992002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
1800
a181be0a
NC
1801 * coffcode.h (coff_slurp_symbol_table): When adding BSF_WEAK flag,
1802 OR it in rather than replacing previously selected flags.
1803
a1aefc76
NC
1804 * elfxx-target.h (TARGET_BIG_SYM): Set ar_max_namelen to 15.
1805 (TARGET_LITTLE_SYM): Set ar_max_namelen to 15.
1806
c119f9b8
AM
18072002-03-14 Alan Modra <amodra@bigpond.net.au>
1808
1809 * cpu-mips.c (mips_compatible): New. Don't check bits_per_word.
1810 (N): Use the above.
1811 * elflink.h (elf_bfd_final_link): Revert last change. Instead,
1812 ensure reloc size matches before calling elf_link_input_bfd.
1813 Add an assert to check reloc size when counting output relocs.
1814
c295a511
NC
18152002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
1816
1817 * mmo.c (mmo_get_loc): Return NULL rather than false.
1818
9ce88e60
NC
18192002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
1820
1821 * po/fr.po: Updated version.
1822
4ddafab0
AM
18232002-03-13 Alan Modra <amodra@bigpond.net.au>
1824
b74fa2cd
AM
1825 * archures.c (bfd_default_compatible): Test bits_per_word.
1826 * cpu-i386.c (i386_compatible): Remove. Replace occurrences with
1827 bfd_default_compatible.
1828 * cpu-i370.c (i370_compatible): Likewise.
1829 * cpu-sparc.c (sparc_compatible): Likewise.
1830 * cpu-h8300.c (compatible): Test in->arch == out->arch.
1831
40b829d4
AM
1832 * elflink.h: Formatting fixes.
1833 (elf_link_output_extsym): Merge undefined and undef weak cases.
1834
4ddafab0
AM
1835 * elflink.h (elf_bfd_final_link): Only call elf_link_input_bfd
1836 when word size of input matches output word size.
1837
dd53c801
AJ
18382002-03-12 Andreas Jaeger <aj@suse.de>
1839
1840 * cpu-i386.c (i386_compatible): New. Use it instead of
1841 bfd_default_compatible.
1842
aa066ac8
L
18432002-03-07 H.J. Lu (hjl@gnu.org)
1844
1845 * coff-sh.c (shcoff_reloc_map): Use bfd_reloc_code_real_type
1846 as the type for bfd_reloc_val.
1847
1bf42538
JL
18482002-03-05 John David Anglin <dave@hiauly1.hia.nrc.ca>
1849
1850 * elf-hppa.h (elf_hppa_is_dynamic_loader_symbol): New function.
1851 (elf_hppa_relocate_section): Ignore undefined dynamic loader symbols.
1852 (elf_hppa_final_link_relocate): Correct relocations for indirect
1853 references to local data through the DLT. Fix .opd creation for
1854 local symbols using R_PARISC_LTOFF_FPTR32 and R_PARISC_FPTR64
1855 relocations. Use e_lsel selector for R_PARISC_DLTIND21L,
1856 R_PARISC_LTOFF_FPTR21L and R_PARISC_LTOFF_TP21L as per
1857 "Processor-Specific ELF for PA_RISC, Version 1.43" document.
1858 Similarly, use e_rsel for DLT and LTOFF 'R' relocations.
1859 * elf32-hppa.c (final_link_relocate): Revise relocation selectors
1860 as per "Processor-Specific ELF for PA_RISC, Version 1.43" document.
1861
86eaf01e
JJ
18622002-03-05 Jakub Jelinek <jakub@redhat.com>
1863
1864 * merge.c (_bfd_merge_sections): Don't segfault if there
1865 is nothing to merge due to GC.
1866
c44233aa
AM
18672002-03-05 Alan Modra <amodra@bigpond.net.au>
1868
039cc25f
AM
1869 * elf32-hppa.c (clobber_millicode_symbols): Remove hack to keep
1870 symbols that have been forced local.
1871
c44233aa
AM
1872 * elflink.h (elf_bfd_final_link): Call elf_link_output_extsym
1873 to output forced local syms for non-shared link.
1874 (elf_link_output_extsym): Tweak condition for calling backend
1875 adjust_dynamic_symbol so that previous behaviour is kept.
1876 Whitespace changes throughout file.
1877
25e27870
L
18782002-03-04 H.J. Lu <hjl@gnu.org>
1879
1880 * elf.c (bfd_section_from_shdr): Handle special sections,
1881 .init_array, .fini_array and .preinit_array.
1882 (elf_fake_sections): Likewise.
1883
1884 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Create the
1885 DT entry only if the section is in output for .init_array,
1886 .fini_array and .preinit_array. Complain about .preinit_array
1887 section in DSO.
1888 (elf_bfd_final_link): Warn zero size for .init_array,
1889 .fini_array and .preinit_array sections.
1890
1891 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Remove
1892 SHT_INIT_ARRAY, SHT_FINI_ARRAY and SHT_PREINIT_ARRAY.
1893 (elfNN_ia64_fake_sections): Remove .init_array, .fini_array and
1894 .preinit_array.
1895
bb2a49f2
AM
18962002-03-04 Alan Modra <amodra@bigpond.net.au>
1897
1898 * configure.in (WIN32LIBADD): Don't eval PICFLAG assignment.
1899 * configure: Regenerate.
1900
38487e5e
TR
19012002-03-02 Tom Rix <trix@redhat.com>
1902
c44233aa
AM
1903 * coff64-rs6000.c (xcoff64_howto_table): Replace howto types with
1904 symbolic equiv.
38487e5e
TR
1905 * coff-rs6000.c (xcoff_howto_table): Same.
1906
30831527
RH
19072002-03-01 David Mosberger <davidm@hpl.hp.com>
1908
1909 * elflink.h (size_dynamic_sections): If section named
1910 ".preinit_array" exists, create DT_PREINIT_ARRAY and
1911 DT_PREINIT_ARRAYSZ entries in dynamic table. Analogously for
1912 ".init_array" and ".fini_array".
1913 (elf_bfd_final_link): Handle DT_PREINIT_ARRAYSZ, DT_INIT_ARRAYSZ,
1914 DT_FINI_ARRAYSZ, DT_PREINIT_ARRAY, DT_INIT_ARRAY, and
1915 DT_FINI_ARRAY.
1916
c8e5ddc8
AM
19172002-02-26 Andrew Macleod <amacleod@cygnus.com>
1918
1919 * elflink.h (elf_bfd_final_link): Don't crash on SHN_UNDEF local
1920 dynsyms.
1921
96e0dda4
AM
19222002-02-25 Alan Modra <amodra@bigpond.net.au>
1923
1c5b6bf8
AM
1924 * elf64-hppa.h: Update copyright date.
1925
96e0dda4
AM
1926 * elf64-ppc.c (ppc64_elf_check_relocs): Warning fix.
1927 (ppc64_elf_relocate_section): Don't generate power4 style branch
1928 hints for *_BRTAKEN and *_BRNTAKEN relocs.
1929
0fb19cbc
JJ
19302002-02-22 Jakub Jelinek <jakub@redhat.com>
1931
1932 * elf64-sh64.c (sh_elf64_relocate_section): Fix a typo from my
1933 last patch.
1934 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
1935
c434dee6
AJ
19362002-02-21 Andreas Jaeger <aj@suse.de>
1937
1938 * elf64-x86-64.c: Major rework that introduces all recent changes
1939 to the x86-64 backend. Get a closer match to elf32-i386.
1940 (struct elf64_x86_64_dyn_relocs): Rename from
1941 elf64_x86_64_pcrel_relocs_copied, add additional fields. Change
1942 all users.
1943 (struct elf64_x86_64_link_hash_table): Add short cuts to some
1944 sections.
1945 (link_hash_newfunc): Rename from elf64_x86_64_link_hash_newfunc,
1946 remove casts, initialize new hash members.
1947 (create_got_section): New.
1948 (elf64_x86_64_create_dynamic_sections): New.
1949 (elf64_x86_64_copy_indirect_symbol): New.
1950 (elf64_x86_64_check_relocs): Don't allocate space for dynamic
1951 relocs, .got or .relgot here but do it in allocate_dynrelocs.
1952 Reference count possible .plt and .got entries. Don't test input
1953 section SEC_READONLY here to try to avoid copy relocs, and keep
1954 dyn_relocs regardless of ELF_LINK_NON_GOT_REF. Don't set
1955 DF_TEXTREL here. Delay setting of variables until needed. Cache
1956 pointer to "sreloc" section in elf_section_data. Tweak condition
1957 under which .got created. Report files with bad relocation
1958 section names.
1959 (elf64_x86_64_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
1960 Reference count possible .plt entries. Don't deallocate .got and
1961 .relgot space here.
1962 (elf64_x86_64_adjust_dynamic_symbol): Handle nocopyreloc. Don't
1963 do copy reloc processing for weakdefs. Remove redundant casts and
1964 aborts. Delay setting of vars until needed. Move creation of
1965 dynamic symbols and allocation of .plt and .rela.plt to
1966 allocate_dynrelocs. Replace BFD_ASSERT with abort.
1967 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
1968 (allocate_dynrelocs): New.
1969 (readonly_dynrelocs): New.
1970 (elf64_x86_64_size_dynamic_sections): Call readonly_dynrelocs.
1971 Allocate space for dyn relocs. Replace BFD_ASSERT with abort.
1972 Zero out the dynamic allocated content space.
1973 (elf64_x86_64_discard_copies): Removed.
1974 (elf64_x86_64_relocate_section): Make use of dynamic section
1975 short-cuts. Localise vars, and delay setting. Better error
1976 reporting, replace BFD_ASSERT with abort. Check
1977 ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined in the
1978 regular object file and tread the weak definition as the normal
1979 one. Don't discard relocs for undefweak or undefined symbols and
1980 check !DEF_REGULAR as well as DEF_DYNAMIC in test for avoided copy
1981 relocs.
1982 (elf64_x86_64_finish_dynamic_symbol): Don't copy relocs for
1983 symbols that have been forced local. Use same test to decide if
1984 we can use a relative reloc for got as relocate_section. Expand
1985 SHN_UNDEF comment. Move expressions out of function calls.
1986 Replace BFD_ASSERT with abort.
1987 (bfd_elf64_bfd_final_link): Removed.
1988 (elf_backend_copy_indirect_symbol): Define.
1989
ff3a6ee3
TR
19902002-02-20 Tom Rix <trix@redhat.com>
1991
1992 * coff-rs6000.c (xcoff_howto_table): Add 16 bit R_BA.
1993 (_bfd_xcoff_reloc_type_lookup): Use it.
1994 * coff64-rs6000.c (xcoff64_howto_table): Same.
1995 (xcoff64_reloc_type_lookup): Same.
c434dee6 1996
a68d41fb
AM
19972002-02-20 Peter Schauer <pes@regent.e-technik.tu-muenchen.de>
1998
1999 * osf-core.c (osf_core_vec): OSF/1 (Digital Unix) core files are
2000 little endian.
2001
befc3abb
MS
20022002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
2003
2004 * archures.c (bfd_mach_s390_esa): Rename to bfd_mach_s390_31.
2005 (bfd_mach_s390_esame): Rename to bfd_mach_s390_64.
2006 * bfd-in2.h: Regenerate.
2007 * cpu-s390.c (arch_info_struct): Use renamed architecture defines.
2008 Replace architecture name "s390" with "s390:31-bit" and "s390:esame"
2009 with "s390:64-bit".
2010 * elf32-s390.c (elf_howto_table): Add 32 bit pc relative relocations.
2011 (elf_s390_reloc_type_lookup): Likewise.
2012 (elf_s390_check_relocs): Likewise.
2013 (elf_s390_gc_sweep_hook): Likewise.
2014 (elf_s390_relocate_section): Likewise.
2015 (elf_s390_object_p): Use renamed architecture define.
2016 * elf64-s390.c (elf_s390_object_p): Use renamed architecture define.
2017
6eeeec9b
FCE
20182002-02-19 Frank Ch. Eigler <fche@redhat.com>
2019
2020 * syms.c (stt[]): Sorted. Added .init/.fini -> "t" mapping.
2021
0bb2d96a
JJ
20222002-02-19 Jakub Jelinek <jakub@redhat.com>
2023
2024 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Enable
2025 absptr -> pcrel optimization for shared libs.
2026 Only create minimal .eh_frame_hdr if absptr FDE encoding in shared
2027 library cannot be converted to pcrel.
2028 (_bfd_elf_eh_frame_section_offset): Return -2 if making absptr
2029 relative.
2030 * elf32-i386.c (elf_i386_relocate_section): If
2031 _bfd_elf_section_offset returned -2, skip, but make sure the
2032 relocation is installed.
2033 * elf32-arm.h (elf32_arm_final_link_relocate): Likewise.
2034 * elf32-cris.c (cris_elf_relocate_section): Likewise.
2035 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
2036 * elf32-i370.c (i370_elf_relocate_section): Likewise.
2037 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
2038 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
2039 * elf32-s390.c (elf_s390_relocate_section): Likewise.
2040 * elf32-sh.c (sh_elf_relocate_section): Likewise.
2041 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
2042 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
2043 * elf64-s390.c (elf_s390_relocate_section): Likewise.
2044 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
2045 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
2046 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
2047 * elf64-alpha.c (elf64_alpha_relocate_section): Handle
2048 _bfd_elf_section_offset returning -2 the same way as -1.
2049 * elfxx-ia64.c (elfNN_ia64_install_dyn_reloc): Likewise.
2050 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add FIXME
2051 and BFD_ASSERT.
2052 * elf64-mips.c (mips_elf64_create_dynamic_relocation): Likewise.
2053
69f284c7
TR
20542002-02-18 Tom Rix <trix@redhat.com>
2055
2056 * xcofflink.c (bfd_xcoff_link_gernate_rtinit): Add -brtl support.
2057 (bfd_xcoff_size_dynamic_sections): Same.
2058 * bfd-in.h (bfd_xcoff_link_generate_rtinit): Same.
2059 (bfd_xcoff_size_dynamic_sections): Same.
2060 * coff-rs6000.c (xcoff_generate_rtinit): Same.
2061 * coff-rs646000.c (xcoff64_generate_rtinit): Same.
2062 * libxcoff.h (struct xcoff_backend_data_rec): Same.
2063 * xcofflink.c (xcoff_build_ldsyms, xcoff_link_add_symbols): Clean.
2064 * bfd-in2.h: Regenerate.
2065
82bd7b59
AM
20662002-02-18 Alan Modra <amodra@bigpond.net.au>
2067
2068 * elf64-ppc.c (STFD_FR0_0R1, LFD_FR0_0R1, BLR): Define.
2069 (struct ppc_link_hash_table): Add sfpr.
2070 (ppc64_elf_link_hash_table_create): Init it.
2071 (ppc64_elf_create_dynamic_sections): Split creation of .stub and
2072 .glink out to..
2073 (create_linkage_sections): ..here. Make .sfpr too.
2074 (ppc64_elf_check_relocs): Call create_linkage_sections, and set
2075 dynobj early.
2076 (MIN_SAVE_FPR, MAX_SAVE_FPR): Define.
2077 (ppc64_elf_func_desc_adjust): Look for missing ._savef* and
2078 ._restf* functions, and create as needed.
2079 (func_desc_adjust): Only force_local for shared libs.
2080
ef1355e8
NC
20812002-02-18 David O'Brien <obrien@FreeBSD.org>
2082
2083 * configure.in: Bump version number post 2.12 branching.
2084 * configure: Regenerate.
2085
dfa36a69
HPN
20862002-02-17 Hans-Peter Nilsson <hp@bitrange.com>
2087
2088 * mmo.c: Correct and improve comments.
2089 (mmo_write_chunk): Store trailing byte in bfd buffer; don't
2090 zero-pad. Use input to fill up non-empty bfd buffer.
2091 (mmo_flush_chunk): New function.
2092 (mmo_write_loc_chunk): Add parameter last_vmap, all callers
2093 changed. Don't emit location specifier if VMA is same as
2094 *LAST_VMAP after omitting leading zero contents. Call
2095 mmo_flush_chunk before emitting location specifier.
2096 (mmo_write_loc_chunk_list): Call mmo_flush_chunk when finished
2097 with mmo_write_loc_chunk calls.
2098 (mmo_internal_write_section): Call mmo_flush_chunk after
2099 mmo_write_chunk.
2100 (mmo_write_symbols_and_terminator): Move :Main to first position
2101 in symbol array. Add faked one if it does not exist if there are
2102 other symbols. Don't add it if there are no symbols at all. Move
2103 out test for value of :Main from symbol loop. Rename table
2104 fakemain to maintable and variable mainsym to fakemain.
2105
ccf00ab6
RH
21062002-02-15 Richard Henderson <rth@redhat.com>
2107
2108 * elf64-alpha.c (elf64_alpha_relocate_section) [BRSGP]: A target
2109 section with no got matches any got. Simplify error generaion.
2110
88eaccc2
AM
21112002-02-15 Alan Modra <amodra@bigpond.net.au>
2112
fd96f80f
AM
2113 Support arbitrary length fill patterns.
2114 * linker.c (bfd_new_link_order): Zero all fields with bfd_zalloc.
2115 (_bfd_default_link_order): Remove bfd_fill_link_order code.
2116 Call default_data_link_order.
2117 (default_fill_link_order): Delete.
2118 (default_data_link_order): New function.
2119 * elf32-mips.c (_bfd_mips_elf_final_link): Replace occurrences
2120 of bfd_fill_link_order with bfd_data_link_order.
2121 * elf64-alpha.c (elf64_alpha_final_link): Likewise.
2122 * elf64-mips.c (mips_elf64_final_link): Likewise.
2123
88eaccc2
AM
2124 * bfd.c (bfd_scan_vma): Clamp overflows to max bfd_vma value.
2125 Correct value returned in "end" for "0x<non-hex>".
2126
e2fd756b
NC
21272002-02-14 Nick Clifton <nickc@cambridge.redhat.com>
2128
2129 * cpu-arm.c (processors): Replace 'arch' field with 'mach'.
2130 (scan): Test against 'mach' field in info structure.
2131
edd29cf9
AM
21322002-02-14 Alan Modra <amodra@bigpond.net.au>
2133
2134 * elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD.
2135
1e30956e 21362002-02-14 Matt Fredette <fredette@netbsd.org>
76f57f3a
JT
2137
2138 * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Recognize
2139 EF_M68000.
2140
bf36db18
NC
21412002-02-13 Nick Clifton <nickc@cambridge.redhat.com>
2142
2143 * elf.c (_bfd_elf_make_section_from_shdr): Do not insist on
edd29cf9
AM
2144 non-zero physical addresses when adjusting the LMAs of new
2145 sections.
bf36db18 2146
189c6563
AM
21472002-02-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
2148
2149 * elf-hppa.h (elf_hppa_reloc_final_type): New function stripped
2150 from _bfd_elf_hppa_gen_reloc_type.
2151 (_bfd_elf_hppa_gen_reloc_type): Remove duplicate prototype.
2152 * elf32-hppa.h (elf32_hppa_reloc_final_type): Add protptype.
2153 * elf32-hppa.c: Include elf32-hppa.h before elf-hppa.h.
2154 * elf64-hppa.h (elf64_hppa_reloc_final_type): Add protptype.
2155
e948afaf
AO
21562002-02-12 Alexandre Oliva <aoliva@redhat.com>
2157
2158 * elf-m10300.c (mn10300_elf_relax_section): Skip section before
2159 loading its contents if there's nothing to do in it.
2160
19397422
AM
21612002-02-12 Alan Modra <amodra@bigpond.net.au>
2162
0ad3a73b
AM
2163 * elf64-ppc.c (ppc64_elf_size_stubs): Correct test for crossing
2164 64k boundary.
2165
19397422
AM
2166 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Add dynamic
2167 DT_PPC64_OPD and DT_PPC64_OPDSZ tags.
2168 (ppc64_elf_finish_dynamic_sections): Set values for them.
2169
51316059
MS
21702002-02-11 Michael Snyder <msnyder@redhat.com>
2171
2172 * elf-bfd.h (elfcore_write_lwpstatus): Add prototype.
2173 * elf.c (elfcore_grok_pstatus): Add prototype.
2174 (elfcore_grok_lwpstatus): Add prototype.
2175 (elfcore_write_lwpstatus): New function.
2176 (elfcore_write_pstatus): Fix typo, eliminate unnecessary memcpy.
2177
518313c3
AO
21782002-02-11 Alexandre Oliva <aoliva@redhat.com>
2179
2180 * elf32-sh.c: Added missing prototypes.
2181 * elf32-sh64.c: Likewise.
2182 (sh_elf_align_loads): Mark unused args as such.
2183 * elf64-sh64.c: Added missing prototypes.
2184 (struct elf_sh64_link_hash_entry): Fix typo.
2185 (sh_elf64_relocate_section): Fix info argument passed to
2186 _bfd_elf_section_offset.
2187
2c73f9d8
AM
21882002-02-11 Alan Modra <amodra@bigpond.net.au>
2189
2190 * Makefile.am: "make dep-am".
2191 * Makefile.in: Regenerate.
2192 * aclocal.m4: Regenerate.
2193 * config.in: Regenerate.
2194 * configure: Regenerate.
2195
d426c6b0
DJ
21962002-02-10 Daniel Jacobowitz <drow@mvista.com>
2197
2198 * coff-rs6000.c (xcoff_generate_rtinit): Silence uninitialized
2199 variable warnings.
2200 * elf32-sh.c (sh_elf_relax_section): Silence signed/unsigned
2201 comparison warning.
2202 * trad-core.c (trad_unix_core_file_p): Silence pointer/integer
2203 cast warnings for the common case.
2204
e58ee0cd
HPN
22052002-02-10 Hans-Peter Nilsson <hp@bitrange.com>
2206
2207 * config.bfd (sh-*-linux*, sh-*-elf* | sh-*-rtemself*): Add sh64
2208 vectors.
2209 (sh-*-netbsdelf*): New, to trump sh*-*-netbsdelf* and add sh64
2210 vectors.
2211
7793f4d0
RH
22122002-02-09 Richard Henderson <rth@redhat.com>
2213
2214 * elf64-alpha.c (elf64_alpha_howto): Add R_ALPHA_BRSGP.
2215 (elf64_alpha_reloc_map, elf64_alpha_check_relocs): Likewise.
2216 (elf64_alpha_relocate_section): Likewise.
2217 * reloc.c (BFD_RELOC_ALPHA_BRSGP): New.
2218 * bfd-in2.h, libbfd.h: Rebuild.
2219
7e799044
HPN
22202002-02-09 Hans-Peter Nilsson <hp@bitrange.com>
2221
2222 * elf64-mmix.c (_bfd_mmix_finalize_linker_allocated_gregs): Check
2223 that base-plus-offset reloc accounting is consistent.
2224 (mmix_elf_relax_section): Keep base-plus-offset reloc accounting
2225 up to date for undefined symbols.
2226
027d73eb
EC
22272002-02-08 Eric Christopher <echristo@redhat.com>
2228
2229 From Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
2230
2231 * elf32-mips.c (_bfd_mips_elf_fake_sections): Don't create .rela
2232 sections for the O32 ABI.
2233
517662d4
CD
22342002-02-08 Chris Demetriou <cgd@broadcom.com>
2235
2236 * elf32-arm.h: Fix formatting of _("...").
2237 * elf32-d10v.c: Likewise.
2238 * elf32-m68k.c: Likewise.
2239 * elf32-mips.c: Likewise.
2240
5e37cc46
NC
22412002-02-08 Ivan Guzvinec <ivang@opencores.org>
2242
2243 * coff-or32.c: Fix compile time warning messages.
2244
fbca6ad9
AO
22452002-02-08 Alexandre Oliva <aoliva@redhat.com>
2246
2247 Contribute sh64-elf.
2248 2002-01-23 Alexandre Oliva <aoliva@redhat.com>
2249 * reloc.c (R_SH_GOTPLT32, R_SH_GOT_LOW16, R_SH_GOT_MEDLOW16,
2250 R_SH_GOT_MEDHI16, R_SH_GOT_HI16, R_SH_GOTPLT_LOW16,
2251 R_SH_GOTPLT_MEDLOW16, R_SH_GOTPLT_MEDHI16, R_SH_GOTPLT_HI16,
2252 R_SH_PLT_LOW16, R_SH_PLT_MEDLOW16, R_SH_PLT_MEDHI16,
2253 R_SH_PLT_HI16, R_SH_GOTOFF_LOW16, R_SH_GOTOFF_MEDLOW16,
2254 R_SH_GOTOFF_MEDHI16, R_SH_GOTOFF_HI16, R_SH_GOTPC_LOW16,
2255 R_SH_GOTPC_MEDLOW16, R_SH_GOTPC_MEDHI16, R_SH_GOTPC_HI16,
2256 R_SH_GOT10BY4, R_SH_GOTPLT10BY4, R_SH_GOT10BY8, R_SH_GOTPLT10BY8,
2257 R_SH_COPY64, R_SH_GLOB_DAT64, R_SH_JMP_SLOT64, R_SH_RELATIVE64):
2258 New relocs.
2259 * libbfd.h, bfd-in2.h: Rebuilt.
2260 * elf32-sh.c (sh_elf_howto_table): Define new relocs.
2261 (sh_reloc_map): Map them.
2262 (PLT_ENTRY_SIZE, elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
2263 elf_sh_plt_entry_be, elf_sh_plt_entry_le, elf_sh_pic_plt_entry_be,
2264 elf_sh_pic_plt_entry_le, elf_sh_plt0_entry, elf_sh_plt_entry,
2265 elf_sh_pic_plt_entry, elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
2266 elf_sh_plt0_gotplt_offset, elf_sh_plt_temp_offset,
2267 elf_sh_plt_symbol_offset, elf_sh_plt_reloc_offset,
2268 movi_shori_putval) [INCLUDE_SHMEDIA]: New.
2269 (elf_sh_link_hash_entry) [INCLUDE_SHMEDIA]: Add
2270 datalabel_got_offset.
2271 (sh_elf_link_hash_newfunc): Initialize it.
2272 (sh_elf_relocate_section): Augment the scope of
2273 seen_stt_datalabel. Introduce GOTPLT support. Extend GOTPC, PLT,
2274 GOT and GOTOFF handling to new SHmedia relocation types. Support
2275 GOT_BIAS.
2276 (sh_elf_check_relocs): Likewise.
2277 (sh_elf_finish_dynamic_symbol) [TARGET_SHMEDIA]: Set up values in
2278 PLT entries using movi_shori_putval. Support GOT_BIAS.
2279 (sh_elf_finish_dynamic_sections): Likewise.
2280 * elf32-sh64.c (shmedia_prepare_reloc): Do not add addend to
2281 relocation, it's now done by the caller.
2282 (GOT_BIAS): New.
2283 * elf64-sh64.c (GOT_BIAS, PLT_ENTRY_SIZE, elf_sh64_sizeof_plt,
2284 elf_sh64_plt_plt0_offset, elf_sh64_plt0_gotplt_offset,
2285 elf_sh64_plt_temp_offset, elf_sh64_plt_symbol_offset,
2286 elf_sh64_plt_reloc_offset, ELF_DYNAMIC_INTERPRETER,
2287 elf_sh64_pcrel_relocs_copied, elf_sh64_link_hash_entry,
2288 elf_sh64_link_hash_table, sh64_elf64_link_hash_traverse,
2289 sh64_elf64_hash_table): New.
2290 (sh_elf64_howto_table): Introduce new relocs.
2291 (sh_elf64_info_to_howto): Accept new PIC relocs.
2292 (sh_elf64_relocate_section): Augment the scope of
2293 seen_stt_datalabel. Support new PIC relocs.
2294 (sh_elf64_check_relocs): Support new PIC relocs.
2295 (elf_sh64_plt0_entry_be, elf_sh64_plt0_entry_le,
2296 elf_sh64_plt_entry_be, elf_sh64_plt_entry_le,
2297 elf_sh64_pic_plt_entry_be, elf_sh64_pic_plt_entry_le,
2298 elf_sh64_plt0_entry, elf_sh64_plt_entry, elf_sh64_pic_plt_entry,
2299 sh64_elf64_link_hash_newfunc, sh64_elf64_link_hash_table_create,
2300 movi_shori_putval, movi_3shori_putval,
2301 sh64_elf64_create_dynamic_sections,
2302 sh64_elf64_adjust_dynamic_symbol, sh64_elf64_discard_copies,
2303 sh64_elf64_size_dynamic_sections,
2304 sh64_elf64_finish_dynamic_symbol,
2305 sh64_elf64_finish_dynamic_sections): New.
2306 (elf_backend_create_dynamic-sections,
2307 bfd_elf64_bfd_link_hash_table_create,
2308 elf_backend_adjust_dynamic_symbol,
2309 elf_backend_size_dynamic_sections,
2310 elf_backend_finish_dynamic_symbol,
2311 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
2312 elf_backend_plt_readonly, elf_backend_want_plt_sym,
2313 elf_backend_got_header_size, elf_backend_plt_header_size):
2314 Define.
2315 2001-05-16 Alexandre Oliva <aoliva@redhat.com>
2316 * elf32-sh.c: Renumbered and renamed some SH5 relocations to
2317 match official numbers and names; moved unmaching ones to the
2318 range 0xf2-0xff.
2319 * elf32-sh64.c, elf64-sh64.c: Likewise.
2320 2001-03-12 DJ Delorie <dj@redhat.com>
2321 * elf32-sh.c (sh_elf_relax_section): Don't relax SHmedia
2322 sections.
2323 2001-03-12 DJ Delorie <dj@redhat.com>
2324 * elf32-sh64.c (shmedia_prepare_reloc): Validate relocs that must
2325 be aligned.
2326 * elf64-sh64.c (sh_elf64_relocate_section): Ditto.
2327 2001-01-14 Hans-Peter Nilsson <hpn@cygnus.com>
2328 * elf32-sh64.c (bfd_elf32_bfd_copy_private_section_data): Define.
2329 (sh64_elf_fake_sections): Set type to SHT_SH5_CR_SORTED for a
2330 .cranges section with SEC_SORT_ENTRIES set.
2331 (sh64_backend_section_from_shdr): Set SEC_SORT_ENTRIES on an
2332 incoming sorted .cranges section.
2333 (sh64_bfd_elf_copy_private_section_data): New.
2334 (sh64_elf_final_write_processing): Only sort .cranges and modify
2335 start address if called by linker.
2336 2001-01-08 Ben Elliston <bje@redhat.com>
2337 * elf32-sh64.c (sh64_elf_final_write_processing): Activate
2338 Hans-Peter Nilsson's set bit 0 patch from 2001-01-06.
2339 * elf64-sh64.c (sh64_elf64_final_write_processing): Ditto.
2340 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
2341 * elf64-sh64.c (sh_elf64_howto_table): No open brace at start of
2342 line. Add comments before all entries.
2343 <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct and clarify describing
2344 comment.
2345 (sh_elf64_reloc): Correct head comment.
2346 (sh_elf64_relocate_section): Correct spacing.
2347 <relocating for a local symbol>: Do not honour STO_SH5_ISA32;
2348 instead call reloc_dangerous callback.
2349 <case R_SH_SHMEDIA_CODE>: New case.
2350 (sh_elf64_gc_mark_hook): Correct spacing.
2351 (sh_elf64_check_relocs): Ditto.
2352 * elf32-sh64.c (shmedia_prepare_reloc) <case R_SH_SHMEDIA_CODE>:
2353 New case.
2354 * elf32-sh.c: Correct #endif comments for #ifndef-wrapped
2355 functions.
2356 (sh_elf_howto_table) <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct,
2357 clarify describing comment. Add comments before all entries.
2358 (sh_elf_relocate_section) <relocating for a local symbol>: Do not
2359 honour STO_SH5_ISA32; instead call reloc_dangerous callback.
2360 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
2361 Sort .cranges section in final link. Prepare to set bit 0 on
2362 entry address.
2363 * elf32-sh64.c (struct sh64_find_section_vma_data): New.
2364 (sh64_elf_link_output_symbol_hook): Fix typo in prototype.
2365 (sh64_elf_set_mach_from_flags): Set SEC_DEBUGGING on incoming
2366 .cranges section.
2367 (sh64_backend_section_from_shdr): New, to recognize
2368 SHT_SH5_CR_SORTED on incoming .cranges section.
2369 (elf_backend_section_from_shdr): Define.
2370 (sh64_elf_final_write_processing): Sort outgoing .cranges
2371 section. (New, temporarily disabled:) Set bit 0 on entry address
2372 according to ISA type.
2373 (sh64_find_section_for_address): New.
2374 (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb,
2375 crange_bsearch_cmpl): Move here from opcodes/sh64-dis.c.
2376 (sh64_address_in_cranges): Move here from opcodes/sh64-dis.c. Use
2377 bfd_malloc, not xmalloc.
2378 (sh64_get_contents_type): Move here from opcodes/sh64-dis.c. Make
2379 global.
2380 * elf32-sh64.c (sh64_elf64_final_write_processing): New, (but
2381 temporarily disabled) setting bit 0 on entry address.
2382 (elf_backend_final_write_processing): Define.
2383 2001-01-05 Hans-Peter Nilsson <hpn@cygnus.com>
2384 * elf32-sh.c (sh_elf_howto_table) <R_SH_PT_16>: Adjust fields to
2385 be a proper relocation for PTA and PTB rather than a marker.
2386 <R_SH_IMMU5, R_SH_IMMS6, R_SH_IMMU6, R_SH_IMMS10, R_SH_IMMS10BY2,
2387 R_SH_IMMS10BY4, R_SH_IMMS10BY8, R_SH_IMMS16, R_SH_IMMU16,
2388 R_SH_IMM_LOW16, R_SH_IMM_LOW16_PCREL, R_SH_IMM_MEDLOW16,
2389 R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16, R_SH_IMM_MEDHI16_PCREL,
2390 R_SH_IMM_HI16, R_SH_IMM_HI16_PCREL, R_SH_64, R_SH_64_PCREL>:
2391 Zero src_mask.
2392 * elf64-sh64.c: Ditto.
2393 (sh_elf64_relocate_section) <case R_SH_PT_16>: New case.
2394 * elf32-sh64.c: Include opcodes/sh64-opc.h
2395 (shmedia_prepare_reloc): Take a bfd_link_info pointer as first
2396 argument. Drop const qualifiers from "bfd *" and "bfd_byte *"
2397 parameters. No unused parameters. Caller changed.
2398 <case R_SH_PT_16>: New case.
2399 * Makefile.am (elf32-sh64.lo): Add dependency on sh64-opc.h.
2400 * Makefile.in: Regenerate.
2401 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
2402 * elf64-sh64.c (sh64_elf64_fake_sections): Set SHF_SH5_ISA32 for
2403 all code sections.
2404 (sh_elf64_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
2405 (sh64_elf_merge_private_data): Ditto.
2406 * elf32-sh64.c (sh64_elf_fake_sections): Use sh64_elf_section_data
2407 to access stored section flags.
2408 (sh64_elf_final_write_processing): Return immediately unless
2409 called by linker. Use sh64_elf_section_data (cranges) to get size
2410 of linker-generated cranges entries.
2411 (sh64_elf_copy_private_data): Add missing "return true".
2412 (sh64_elf_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
2413 (sh_elf64_merge_private_data): Ditto.
2414 2000-12-19 Hans-Peter Nilsson <hpn@cygnus.com>
2415 * elf64-sh64.c (sh64_elf64_fake_sections): New, copy of
2416 elf64-sh64.c:sh64_elf_fake_sections.
2417 (elf_backend_fake_sections): Define as sh64_elf64_fake_sections.
2418 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
2419 * elf32-sh64.c (sh64_elf_copy_private_data_internal): Delete.
2420 (sh64_elf_final_write_processing): New.
2421 (elf_backend_final_write_processing): Define.
2422 (sh64_elf_fake_sections): Get header flags from tdata field.
2423 (sh64_elf_copy_private_data): Do not call
2424 sh64_elf_copy_private_data_internal, just copy e_flags field.
2425 (sh64_elf_merge_private_data): Do not call
2426 sh64_elf_copy_private_data_internal.
2427 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
2428 Remove EF_SH64_ABI64, let ELF size make difference.
2429 Remove SH64-specific BFD section flag.
2430 * elf32-sh64.c (sh64_elf_fake_sections): Recognize section as
2431 containing SHmedia through elf_section_data (asect)->tdata
2432 non-zero, not using a BFD section flag.
2433 (sh64_elf_set_mach_from_flags): Don't recognize EF_SH64_ABI64.
2434 (sh64_elf_merge_private_data): Similar.
2435 (elf_backend_section_flags): Don't define.
2436 (sh64_elf_backend_section_flags): Delete.
2437 * elf64-sh64.c (sh_elf64_set_mach_from_flags): Recognize EF_SH64,
2438 not EF_SH64_ABI64.
2439 (sh_elf64_merge_private_data): Similar.
2440 * section.c (Section flags definitions): Don't define
2441 SEC_SH_ISA_SHMEDIA.
2442 (bfd-in2.h): Regenerate.
2443 2000-12-09 Hans-Peter Nilsson <hpn@cygnus.com>
2444 Make DataLabel references work with partial linking.
2445 * elf32-sh64.c: Fix formatting.
2446 (sh64_elf_link_output_symbol_hook): New.
2447 (elf_backend_link_output_symbol_hook): Define to
2448 sh64_elf_link_output_symbol_hook.
2449 (sh64_elf_add_symbol_hook): Make DataLabel symbol just global
2450 undefined if partial linking. Adjust sanity check.
2451 * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): New.
2452 (elf_backend_link_output_symbol_hook): Define to
2453 sh64_elf64_link_output_symbol_hook.
2454 (sh64_elf64_add_symbol_hook): Make DataLabel symbol just global
2455 undefined if partial linking. Adjust sanity check.
2456 2000-12-07 Hans-Peter Nilsson <hpn@cygnus.com>
2457 Implement semantics for inter-file DataLabel references.
2458 * elf64-sh64.c (DATALABEL_SUFFIX): Define.
2459 (sh64_elf64_add_symbol_hook): New.
2460 (sh_elf64_relocate_section): If passing an indirect symbol with
2461 st_type STT_DATALABEL on the way to a symbol with st_other
2462 STO_SH5_ISA32, do not bitor 1 to the relocation.
2463 (elf_backend_add_symbol_hook): Define to
2464 sh64_elf64_add_symbol_hook.
2465 * elf64-sh32.c: Tweak comments.
2466 (DATALABEL_SUFFIX): Define.
2467 (sh64_elf_add_symbol_hook): New.
2468 (elf_backend_add_symbol_hook): Define to sh64_elf_add_symbol_hook.
2469 * elf32-sh.c (sh_elf_relocate_section): If passing an indirect
2470 symbol with st_type STT_DATALABEL on the way to a symbol with
2471 st_other STO_SH5_ISA32, do not bitor 1 to the relocation.
2472 2000-12-05 Hans-Peter Nilsson <hpn@cygnus.com>
2473 Pass through STT_DATALABEL.
2474 * elf32-sh64.c (sh64_elf_get_symbol_type): New.
2475 (elf_backend_get_symbol_type): Define.
2476 * elf64-sh64.c (sh64_elf64_get_symbol_type): New.
2477 (elf_backend_get_symbol_type): Define.
2478 2000-11-30 Hans-Peter Nilsson <hpn@cygnus.com>
2479 * elf32-sh64.c: Tweak comments.
2480 (sh64_elf_copy_private_data_internal): Add prototype.
2481 (bfd_elf32_bfd_set_private_flags): Define.
2482 (sh64_elf_copy_private_data_internal): Compare machine name, not
2483 textual BFD target name, to check whether to copy section flag
2484 SHF_SH5_ISA32.
2485 (sh64_elf_merge_private_data): Validize bfd_get_arch_size.
2486 Tweak section-contents-type-mismatch message.
2487 (shmedia_prepare_reloc): Add ATTRIBUTE_UNUSED markers.
2488 Validize reloc-types.
2489 * elf64-sh64.c: New file.
2490 * targets.c (bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec): Declare.
2491 * Makefile.am (BFD64_BACKENDS): Add elf64-sh64.lo.
2492 (BFD64_BACKENDS_CFILES): Add elf64-sh64.c.
2493 Regenerate dependencies.
2494 * Makefile.in: Regenerate.
2495 * config.bfd (sh64-*-elf*): Add bfd_elf64_sh64_vec and
2496 bfd_elf64_sh64l_vec.
2497 * configure.in: Handle bfd_elf64_sh64_vec and
2498 bfd_elf64_sh64l_vec.
2499 * configure: Regenerate.
2500 * po/POTFILES.in: Regenerate.
2501 * po/bfd.pot: Regenerate.
2502 2000-11-29 Hans-Peter Nilsson <hpn@cygnus.com>
2503 * elf32-sh64.c (sh64_elf_set_mach_from_flags): Do not recognize
2504 anything else but EF_SH64 and EF_SH64_ABI64.
2505 (sh64_elf_merge_private_data): Emit error for anything else but
2506 EF_SH64 and EF_SH64_ABI64.
2507 * config.bfd: Remove bfd_elf32_shblin_vec and bfd_elf32_shlin_vec
2508 from targ_selvecs.
2509 * configure.in: Add cofflink.lo to bfd_elf32_sh64_vec and
2510 bfd_elf32_sh64l_vec as a temporary measure.
2511 * configure: Regenerate.
2512 2000-11-27 Hans-Peter Nilsson <hpn@cygnus.com>
2513 * cpu-sh.c (arch_info_struct): Include sh5 item
2514 unconditionalized.
2515 * config.bfd (sh64-*-elf*): Do not set targ_cflags.
2516 Add targ_selvecs bfd_elf32_sh_vec, bfd_elf32_shl_vec,
2517 bfd_elf32_shblin_vec and bfd_elf32_shlin_vec.
2518 * elf32-sh64.c: Tweak comments.
2519 (sh64_elf_set_mach_from_flags): Recognize all machine flags that
2520 are proper subsets of SH64 as bfd_mach_sh5. Add EF_SH64_ABI64.
2521 (sh64_elf_copy_private_data_internal): Wrap long line.
2522 (sh64_elf_merge_private_data): Rewrite to allow objects from
2523 SH64 subsets to be linked together.
2524 (INCLUDE_SHMEDIA): Define.
2525 * elf32-sh.c (sh_elf_relocate_section) <local symbol>:
2526 Parenthesize plus-expression inside or-expression.
2527 <global symbol>: Ditto.
2528 (sh_elf_set_mach_from_flags): Remove code refusing
2529 deleted EF_SH64_32BIT_ABI flag.
2530 2000-11-26 Hans-Peter Nilsson <hpn@cygnus.com>
2531 * elf32-sh.c (sh_elf_howto_table) <R_SH_IMM_LOW16_PCREL,
2532 R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16_PCREL,
2533 R_SH_IMM_HI16_PCREL, R_SH_64_PCREL>: Set pcrel_offset to true.
2534 (sh_elf_relocate_section) <local symbol>: Or 1 in
2535 calculation of relocation if sym->st_other & STO_SH5_ISA32.
2536 <global symbol>: Ditto if h->other & STO_SH5_ISA32.
2537 * elf32-sh64.c (shmedia_prepare_reloc): Add rel->r_addend to
2538 relocation.
2539 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
2540 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64.lo.
2541 (BFD32_BACKENDS_CFILES): Add elf32-sh64.c.
2542 Regenerate dependencies.
2543 * Makefile.in: Regenerate.
2544 * archures.c: Add bfd_mach_sh5.
2545 * config.bfd: Map targ_cpu sh* to bfd_sh_arch.
2546 Handle sh64-*-elf*. Set targ_cflags to -DINCLUDE_SHMEDIA.
2547 * configure.in: Handle bfd_elf32_sh64_vec and bfd_elf32_sh64l_vec.
2548 * configure: Regenerate.
2549 * reloc.c (BFD_RELOC_SH_SHMEDIA_CODE, BFD_RELOC_SH_IMMU5,
2550 BFD_RELOC_SH_IMMS6, BFD_RELOC_SH_IMMS6BY32, BFD_RELOC_SH_IMMU6,
2551 BFD_RELOC_SH_IMMS10, BFD_RELOC_SH_IMMS10BY2,
2552 BFD_RELOC_SH_IMMS10BY4, BFD_RELOC_SH_IMMS10BY8,
2553 BFD_RELOC_SH_IMMS16, BFD_RELOC_SH_IMMU16, BFD_RELOC_SH_IMM_LOW16,
2554 BFD_RELOC_SH_IMM_LOW16_PCREL, BFD_RELOC_SH_IMM_MEDLOW16,
2555 BFD_RELOC_SH_IMM_MEDLOW16_PCREL, BFD_RELOC_SH_IMM_MEDHI16,
2556 BFD_RELOC_SH_IMM_MEDHI16_PCREL, BFD_RELOC_SH_IMM_HI16,
2557 BFD_RELOC_SH_IMM_HI16_PCREL, BFD_RELOC_SH_PT_16): New relocations.
2558 * cpu-sh.c [INCLUDE_SHMEDIA] (arch_info_struct): Define and link
2559 in item for SH5.
2560 * elf32-sh.c [INCLUDE_SHMEDIA] (sh_elf_howto_table): Add howto items
2561 for SHmedia relocs.
2562 [INCLUDE_SHMEDIA] (sh_rel): Add mappings for SHmedia relocs.
2563 [INCLUDE_SHMEDIA] (sh_elf_relocate_section) [default]: Call
2564 shmedia_prepare_reloc, goto final_link_relocate if it returns
2565 non-zero, else fail as before.
2566 (sh_elf_set_mach_from_flags): Provide function only if not defined
2567 as macro. Do not recognize objects with EF_SH64_32BIT_ABI set.
2568 (sh_elf_set_private_flags): Provide function only if not defined
2569 as a macro.
2570 (sh_elf_copy_private_data): Similar.
2571 (sh_elf_merge_private_data): Similar.
2572 * section.c (SEC_SH_ISA_SHMEDIA): New.
2573 * targets.c (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec): Declare.
2574 * elf32-sh64.c: New file.
2575 * libbfd.h: Regenerate.
2576 * bfd-in2.h: Regenerate.
2577 * po/POTFILES.in: Regenerate.
2578 * po/bfd.pot: Regenerate.
2579 * bfd-in2.h: Regenerate.
2580 * libbfd.h: Regenerate.
2581
e108f470
DJ
25822002-02-07 Daniel Jacobowitz <drow@mvista.com>
2583
2584 * bfd-in.h: Update <stdbool.h> check to only see if <stdbool.h> has
2585 been included, not drag it in.
2586 * bfd-in2.h: Regenerate.
2587
259d18a3
L
25882002-02-06 H.J. Lu (hjl@gnu.org)
2589
2590 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Update
2591 the mach and ISA fields if necessary.
2592
f13b834e
NC
25932002-02-06 Nick Clifton <nickc@cambridge.redhat.com>
2594
2595 * coffcode.h (coff_set_arch_mach_hook): Select the highest known
2596 ARM architecture when an F_ARM_5 flag is detected, since we cannot
2597 be sure exactly which architecture this represents.
2598
82f6addb
NC
25992002-02-05 Nick Clifton <nickc@redhat.com>
2600
2601 * po/tr.po: Updated translation.
2602
899f54f5
AM
26032002-02-05 Alan Modra <amodra@bigpond.net.au>
2604
2605 From Jimi X <jimix@watson.ibm.com>
2606 * archures (bfd_mach_ppc64): Define.
2607 (bfd_powerpc_arch): Rename to bfd_powerpc_archs.
2608 (bfd_powerpc_arch): Define.
2609 * bfd-in2.h: Regenerate.
2610 * cpu-powerpc.c (arch_info_struct): Rename to bfd_powerpc_archs.
2611 (bfd_powerpc_arch): Move to tail of bfd_powerpc_archs.
2612 (bfd_powerpc_archs): Add default powerpc64 arch.
2613
248866a8
AM
26142002-02-05 Alan Modra <amodra@bigpond.net.au>
2615
2616 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Check for relocs
2617 against section syms in readonly sections. Don't do the global
2618 sym check if we find one.
2619 * elf64-s390.c (elf_s390_size_dynamic_sections): Likewise.
2620 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Likewise.
0a6958db 2621 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
248866a8
AM
2622 * elf32-s390.c (elf_s390_size_dynamic_sections): Likewise.
2623 (elf_s390_grok_prstatus): Add missing prototype.
2624
4fa5c2a8
HPN
26252002-02-04 Hans-Peter Nilsson <hp@bitrange.com>
2626
2627 * elf64-mmix.c (mmix_dump_bpo_gregs): New function.
2628 (mmix_elf_check_common_relocs) <case R_MMIX_BASE_PLUS_OFFSET>:
2629 Call bfd_get_section_by_name only once. Initialize
2630 bpodata->n_bpo_relocs_this_section.
2631 (_bfd_mmix_prepare_linker_allocated_gregs): Remove comment
2632 referring to DSOs.
2633 (bpo_reloc_request_sort_fn): Don't use difference of values as
2634 return-value.
2635
537c972e
DB
26362002-02-02 David O'Brien <obrien@FreeBSD>
2637
2638 * configure.in: Tweak the FreeBSD 4.x recognition more. Only treat
2639 version 4.5 and later the same as 5-CURRENT.
2640 * configure: Re-generate.
2641
006336b8
JT
26422002-02-02 Jason Thorpe <thorpej@wasabisystems.com>
2643
2644 * config.bfd (hppa*-*-netbsd*): New target.
2645
6c571f00
PT
26462002-01-31 Philipp Thomas <pthomas@suse.de>
2647
19397422
AM
2648 * coff-arm.c (coff_arm_merge_private_bfd_data): Move ERROR
2649 to front of message. Unify messages with elf32-arm.h. Use
2650 commas where neccessary.
2651 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Use all upcase
2652 ERROR in messages. Unify messages with coff-arm.c. Correct
2653 VFP/FPA error message.
2654 (elf32_arm_print_private_bfd_data): Don't mark APCS-26 and
2655 APCS-32 for translation.
6c571f00 2656
930b4cb2
HPN
26572002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
2658
2659 Perform on-demand global register allocation from
2660 R_MMIX_BASE_PLUS_OFFSET relocs.
2661 * elf64-mmix.c (struct bpo_reloc_section_info, struct
2662 bpo_reloc_request, struct bpo_greg_section_info): New.
2663 (mmix_elf_check_common_relocs, mmix_elf_gc_sweep_hook,
2664 bpo_reloc_request_sort_fn, mmix_elf_relax_section,
2665 _bfd_mmix_check_all_relocs,
2666 _bfd_mmix_prepare_linker_allocated_gregs,
2667 _bfd_mmix_finalize_linker_allocated_gregs): New functions.
2668 (elf_mmix_howto_table): Correct src_mask for most relocs.
2669 (mmix_elf_perform_relocation) <case R_MMIX_BASE_PLUS_OFFSET>: New
2670 case.
2671 (mmix_final_link_relocate) <case R_MMIX_BASE_PLUS_OFFSET>: New
2672 case. Fix typo in comment. New label do_mmix_reloc.
2673 (mmix_elf_check_relocs): Abuse bfd_link_info member base_file to
2674 store first object file with a base-plus-offset reloc. Call
2675 mmix_elf_check_common_relocs for the part common with mmo.
2676 (mmix_elf_final_link): Write out linker-allocated register
2677 contents section.
2678 (elf_backend_gc_sweep_hook): Define.
2679 (bfd_elf64_bfd_relax_section): Define.
2680
2681 * mmo.c: Don't include <ctype.h>
2682 (mmo_init): Correct init-once logic.
2683
3e36d993
TR
26842002-02-01 Tom Rix <trix@redhat.com>
2685
2686 * config.bfd: Conditionally support <aiaff> for pre AIX 4.3.
2687
ba323545
AM
26882002-02-01 Alan Modra <amodra@bigpond.net.au>
2689
2690 * Makefile.am: Run "make dep-am"
2691 * Makefile.in: Regenerate.
2692
012884d6
DB
26932002-01-31 David O'Brien <obrien@FreeBSD>
2694
2695 * configure.in: Recognize the differences in core files from FreeBSD
2696 4.{0,1} and later versions of 4.x. This treats 4.2+ the same as
2697 5-CURRENT.
2698 * configure: Regenerate.
2699
3b16e843
NC
27002002-01-31 Ivan Guzvinec <ivang@opencores.org>
2701
2702 * coff-or32.c: New file.
2703 * cpu-or32.c: New file.
2704 * elf32-or32.c: New file.
2705 * archures.c: Add support for or32.
2706 * targets.c: Add support for or32.
2707 * bfd-in2.h: Regenerate.
7dc0ab31 2708 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags,
3b16e843
NC
2709 coff_write_object_contents): Add support for or32.
2710 * config.bfd: Add target.
2711 * configure.in: Add support for or32.
2712 * configure: Regenerate.
2713 * Makefile.am: Add support for or32.
2714 * Makefile.in: Regenerate.
3b16e843
NC
2715 * po/SRC-POTFILES.in: Add or32 files.
2716 * po/bfd.pot: Regenerate.
7dc0ab31 2717
caf8ca8e
NC
27182002-01-31 Nick Clifton <nickc@cambridge.redhat.com>
2719 Don Lindsay <lindsayd@cisco.com>
2720
2721 * elf32-mips.c (mips_elf_calculate_relocation): Replace 'return
2722 false' with a return of a bfd_reloc_ error code.
2723
e5dfef09
HPN
27242002-01-31 Hans-Peter Nilsson <hp@axis.com>
2725
2726 * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Don't
2727 unexport unreferenced symbols when --export-dynamic. Call
2728 _bfd_elf_strtab_delref when unexporting.
2729
4e4770d0
DJ
27302002-01-30 Daniel Jacobowitz <drow@mvista.com>
2731
2732 * bfd-in.h: Include <stdbool.h> if it is available.
2733 * bfd-in2.h: Regenerated.
2734
e1fa50e7
AM
27352002-01-31 Alan Modra <amodra@bigpond.net.au>
2736
2737 * elf64-ppc.c (func_desc_adjust): STV_PROTECTED functions should
2738 not go via the plt.
2739
b5f79c76
NC
27402002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
2741
b5f79c76
NC
2742 * archures.c: Tidy up formatting of embedded comments.
2743 * bfd.c: Tidy up formatting of embedded comments.
7dc0ab31 2744 * bfd-in.h: Fix formatting of comments.
b5f79c76
NC
2745 * reloc.c: Tidy up formatting of ordinary & embedded comments.
2746 * section.c: Tidy up formatting of embedded comments.
2747 * syms.c: Tidy up formatting of embedded comments.
2748 * targets.c: Tidy up formatting of embedded comments.
2749
2750 * bfd-in2.h: Regenerate.
2751
ca09e32b
NC
27522002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
2753
2754 * vms-tir.c (cmd_name): New function.
2755 (tir_cmd_name): New function.
2756 (etir_sta, etir_sto, etir_opr, etir_stc): Use cmd_name().
2757 (tir_opr, tir_ctl, tir_cmd): use tir_cmd_name().
2758 Fix formatting.
7dc0ab31 2759
ca09e32b
NC
2760 * peXXigen.c (pe_print_idata): Rearrange message to aid in
2761 translation.
2762 (pe_print_pdata): Rearrange message to aid in translation.
2763
2764 * libbfd.c (warn_deprecated): Rearrange error message to aid in
2765 translation.
2766
2767 * ihex.c (ihex_write_object_contents): Fix spelling typo.
2768
2769 * ieee.c (ieee_slurp_external_symbols): Remove spurious space.
2770
2771 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Rearrange error
2772 message to aid in translation.
2773
2774 * elf64-mmix.c (mmix_final_link_relocate): Rearrange error message
2775 to aid in translation.
2776
2777 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix typo.
2778
7dc0ab31 27792002-01-30 Philipp Thomas <pthomas@suse.de>
ae1a89b7
PT
2780
2781 * coff-arm.c, elf32-elf.h: Unify messages.
2782
05f64ac6
NC
27832002-01-30 Nick Clifton <nickc@redhat.com>
2784
2785 * po/sv.po: Updated translation.
2786
f5a3e38a
NC
27872002-01-30 Philipp Thomas <pthomas@suse.de>
2788
2789 * dwarf2.c (read_abbrev): Use full section name in error message.
2790 (decode_line_info): Likewise.
661a3fd4
NC
2791
2792 * elf.c (_bfd_elf_symbol_from_bfd_symbol): Don't translate debugging
2793 message.
2794
d926e03d
AM
27952002-01-30 Alan Modra <amodra@bigpond.net.au>
2796
2797 * elf64-ppc.c (func_desc_adjust): Only provide missing function
2798 descriptor symbols for undefined function code syms. Clear
2799 ELF_LINK_NON_ELF so that they can stay weak.
2800
030d18fb 28012002-01-29 Chris Demetriou <cgd@broadcom.com>
7dc0ab31 2802 Mitch Lichtenberg <mpl@broadcom.com>
030d18fb
CD
2803
2804 * bfd-in.h (bfd_mips_elf32_create_embedded_relocs): New prototype.
2805 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): New function
2806 to handle 32-bit ELF embedded reloc (ld --embedded-relocs)
2807 generation.
2808 * bfd-in2.h: Regenerate.
2809
fcc76bea
CD
28102002-01-29 Chris Demetriou <cgd@broadcom.com>
2811
2812 * elf32-mips.c: Add additional comments about HI16 relocation
2813 processing.
2814 (_bfd_mips_elf_hi16_reloc): Don't subtract address here for
2815 pc-relative relocations. (Reverts change made on 2001-10-31.)
2816 (_bfd_mips_elf_lo16_reloc): Subtract address of LO16 part here
2817 for pc-relative relocations.
2818 (mips_elf_calculate_relocation): Add a comment about a kludge
2819 in the R_MIPS_GNU_REL_HI16 handling.
2820 (_bfd_mips_elf_relocate_section): Implement that kludge;
2821 adjust pc-relative HI16 relocation for difference in HI16 and
2822 LO16 addresses, since it can't easily be done in
2823 mips_elf_calculate_relocation.
2824
f9cd9119
MS
28252002-01-29 Martin Schwidefsky <schwidefsky@de.ibm.com>
2826
2827 * elf32-i386 (elf_i386_adjust_dynamic_symbol): Do not replace PLT32
2828 relocations with PC32 relocations for undefined or weak symbols.
2829 * elf32-s390 (elf_i386_adjust_dynamic_symbol): Likewise.
2830 * elf64-s390x (elf_i386_adjust_dynamic_symbol): Likewise.
2831
702248bb
JT
28322002-01-28 Jason Thorpe <thorpej@wasabisystems.com>
2833
2834 * elfcore.h (elf_core_file_p): Improve comment for last change.
2835
4867be41
DJ
28362002-01-27 Daniel Jacobowitz <drow@mvista.com>
2837
2838 * configure: Regenerated.
2839
a94cef6a
JT
28402002-01-27 Jason Thorpe <thorpej@wasabisystems.com>
2841
2842 * elfcore.h (elf_core_file_p): Set the machine architecture
2843 before processing the program headers.
2844
7562a296
HPN
28452002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
2846
966abd70
HPN
2847 * configure.in <64-bit configuration>: If using gcc, check and
2848 emit error for egcs-1.1.2.
2849 * configure: Regenerate.
2850
e8eab623
NC
28512002-01-26 Egor Duda <deo@logos-m.ru>
2852
2853 * elf.c (elfcore_grok_win32pstatus): Copy only as much information
2854 as possible to avoid stack corruption.
2855
73896efb
RH
28562002-01-26 Richard Henderson <rth@redhat.com>
2857
2858 * elf64-alpha.c (elf64_alpha_check_relocs): Don't set reltext
2859 for non-allocated sections.
2860
28612002-01-25 Mark Kettenis <kettenis@gnu.org>
c106e334
MK
2862
2863 * elf.c (elfcore_write_prstatus): Make sure we pass the address of
2864 prstat.pr_reg even if it is a struct.
2865
73896efb 28662002-01-25 Steve Ellcey <sje@cup.hp.com>
254ed743
NC
2867
2868 * bfd/elfxx-ia64.c: Reset AIX vector function overrides for HP-UX.
2869
3d66c4f7
NC
28702002-01-25 Philipp Thomas <pthomas@suse.de>
2871
2872 * coffgen.c (coff_print_symbol): Don't mark info message
2873 for translation.
2874
9460ecda
NC
28752002-01-25 Nick Clifton <nickc@redhat.com>
2876
2877 * po/fr.po: Updated translation.
2878 * po/es.po: Updated translation.
2879
cc9ff76a
AM
28802002-01-25 Philipp Thomas <pthomas@suse.de>
2881
2882 * coff-alpha.c (alpha_relocate_section): Unify warning message
2883 for GP relative relocations without GP defined.
2884 * coff-mips.c (mips_relocate_section): Likewise.
2885
c68836a9
AM
28862002-01-25 Alan Modra <amodra@bigpond.net.au>
2887
2888 * elf-eh-frame.c (_bfd_elf_eh_frame_section_offset): Avoid
2889 unsigned overflow when new_offset < old_offset.
2890
e8eab623 28912002-01-24 Philipp Thomas <pthomas@suse.de>
391154e9
NC
2892
2893 * bfd.c (_bfd_abort): Fix typo.
2894
8ba89f17
RH
28952002-01-23 Richard Henderson <rth@redhat.com>
2896
2897 * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't suppress
2898 plt entries for undefweak symbols.
2899
c6953948
NC
29002002-01-23 Steve Ellcey <sje@cup.hp.com>
2901
2902 * bfd/targets.c (bfd_elf32_ia64_hpux_big_vec): Add to
2903 DEFAULT_VECTOR.
2904 (bfd_elf64_ia64_hpux_big_vec): Ditto.
2905 (bfd_elf32_h8300_vec): Ditto.
2906
41bd81ab
AM
29072002-01-23 Alan Modra <amodra@bigpond.net.au>
2908
2909 * elf64-ppc.c: Remove stale part of ABI comment.
2910 (NO_OPD_RELOCS): Define.
2911 (ppc64_elf_check_relocs): Use it.
2912 (ppc64_elf_relocate_section): Here too.
2913 (build_one_stub): Don't point function syms at the stub. Instead,
2914 hijack plt.offset.
2915 (ppc64_elf_relocate_section): Check whether REL24 relocs should
2916 really go to the stub. Make all dynamic relocs in opd against
2917 locals.
2918 (ppc64_elf_finish_dynamic_symbol): Allow for non-standard use of
2919 plt.offset.
2920
f304919d
RH
29212002-01-22 Richard Henderson <rth@redhat.com>
2922
2923 * elf64-alpha.c (INSN_UNOP): Encode with RB as $sp.
2924
c0ef99a7
AM
29252002-01-22 Alan Modra <amodra@bigpond.net.au>
2926
60ee0d4a
AM
2927 * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Correct sign of
2928 TOC_BASE_OFF adjustment.
2929
c0ef99a7
AM
2930 * Makefile.am: Run "make dep-am".
2931 * Makefile.in: Regenerate.
2932 * po/SRC-POTFILES.in: Regenerate.
2933
64328b46
AM
29342002-01-22 John David Anglin <dave@hiauly1.hia.nrc.ca>
2935
2936 * configure.host (hppa*64*-*-hpux*, hppa*64*-*-linux*): Add new
2937 host defines.
2938
59953665 29392002-01-21 Hans-Peter Nilsson <hp@axis.com>
58255df3
HPN
2940
2941 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_32_GOTREL>:
2942 Check for and emit error if sgot is NULL at this point.
2943
9596feea
JT
29442002-01-21 Jason Thorpe <thorpej@wasabisystems.com>
2945
2946 * config.bfd (ia64*-*-netbsd*): New target.
2947
7b45c6e1
AM
29482002-01-21 Thomas Klausner <wiz@danbala.ifoer.tuwien.ac.at>
2949
2950 * som.c (som_write_space_strings): Comment typo fix.
2951
e5094212
AM
29522002-01-21 Alan Modra <amodra@bigpond.net.au>
2953
e86ce104
AM
2954 * elf64-ppc.c (struct ppc_link_hash_entry): Add is_func and
2955 is_func_descriptor fields.
2956 (link_hash_newfunc): Init them.
2957 (ppc64_elf_check_relocs): Only R_PPC24_REL24 syms starting with a
2958 dot are candidates for plt entries. When processing .opd relocs,
2959 set function descriptor strings to point inside function code
2960 string, and set new ppc_link_hash_entry fields.
2961 (ppc64_elf_gc_sweep_hook): Don't sweep R_PPC64_REL24 relocs.
2962 (ppc64_elf_adjust_dynamic_symbol): Remove most code dealing with
2963 function descriptors. It's now done in..
2964 (func_desc_adjust): New.
2965 (ppc64_elf_func_desc_adjust): New.
2966 (define elf_backend_always_size_sections): Define.
2967 (ppc64_elf_hide_symbol): New.
2968 (define elf_backend_hide_symbol): Define.
2969 (allocate_dynrelocs): Remove code looking up function descriptors
2970 as that has been done earlier.
2971 (ppc64_elf_size_dynamic_sections): Use htab shortcut to elf hash
2972 table.
2973 (ppc64_elf_finish_dynamic_symbol): Likewise. Remove code looking
2974 up function descriptor.
2975 (build_one_stub): Look up the function code sym. Check for
2976 invalid plt offsets.
2977 (ppc64_elf_relocate_section): Tweak calls to undefined weak syms.
2978 Convert R_PPC64_TOC relocs to R_PPC64_RELATIVE in shared libs.
2979
e5094212
AM
2980 * elf-bfd.h (elf_backend_data <elf_backend_hide_symbol>): Add
2981 boolean param.
2982 (_bfd_elf_link_hash_hide_symbol): Likewise.
2983 * elflink.h (elf_link_add_object_symbols): Adjust call to
2984 elf_backend_hide_symbol.
2985 (elf_fix_symbol_flags): Likewise.
2986 (elf_link_assign_sym_version): Likewise. Use bfd_malloc rather
2987 than bfd_alloc.
2988 * elf.c (_bfd_elf_link_hash_hide_symbol): Add "force_local" param.
2989 Set ELF_LINK_FORCED_LOCAL and call _bfd_elf_strtab_delref.
2990 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
2991 (clobber_millicode_symbols): Adjust to suit new hide_symbol.
2992 * elf32-cris.c (elf_cris_hide_symbol): Add "force_local" param
2993 and adjust to suit.
2994 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise, and call
2995 _bfd_elf_link_hash_hide_symbol rather than duplicating code.
2996 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
2997
40b8271b
AM
29982002-01-18 Alan Modra <amodra@bigpond.net.au>
2999
3000 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Test for a
3001 dynamic function descriptor symbol, not the associated function
3002 symbol.
3003
55baa95b
EC
30042002-01-17 Eric Christopher <echristo@redhat.com>
3005
3006 * elf32-mips.c (mips_elf_calculate_relocation): Fix typo.
3007
328577ad
NC
30082002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
3009
3010 * po/bfd.pot: Regenerate.
3011 * po/fr.po: Regenerate.
3012
af746e92
AM
30132002-01-17 Alan Modra <amodra@bigpond.net.au>
3014
3015 * elf-bfd.h (elf_backend_data <elf_backend_section_from_bfd_section>):
3016 Remove "Elf_Internal_Shdr *" param.
3017 (_bfd_mips_elf_section_from_bfd_section): Ditto.
3018 * elf32-mips.c (_bfd_mips_elf_section_from_bfd_section): Ditto.
3019 * elf32-m32r.c (_bfd_m32r_elf_section_from_bfd_section): Ditto.
3020 * elf32-v850.c (v850_elf_section_from_bfd_section): Ditto.
3021 * elf64-mmix.c (mmix_elf_section_from_bfd_section): Ditto.
3022 * elfxx-ia64.c (elfNN_hpux_backend_section_from_bfd_section): Ditto.
3023 * elf.c (_bfd_elf_section_from_bfd_section): Allow backend
3024 function to override special sections. Remove hdr arg from
3025 backend call, and don't loop.
3026
175e9962
EC
30272002-01-16 Eric Christopher <echristo@redhat.com>
3028
3029 * elf32-mips.c (mips_elf_calculate_relocation): Set require_jalxp
3030 on R_MIPS_26 and target is 16bit. Add R_MIPS16_GPREL to list of
3031 relocations requiring gp0 and gp.
3032
96a846ea
RE
30332002-01-16 Richard Earnshaw <rearnsha@arm.com>
3034
175e9962 3035 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Handle
96a846ea
RE
3036 EF_ARM_VFP_FLOAT.
3037 (elf32_arm_print_private_bfd_data): Likewise.
3038
af3ae48d
NC
30392002-01-16 Nick Clifton <nickc@cambridge.redhat.com>
3040
3041 * po/tr.po: Import new version.
3042
10ed1bba
AM
30432002-01-16 Alan Modra <amodra@bigpond.net.au>
3044
3045 * elf64-ppc.c (ppc64_elf_howto_raw): Remove stale FIXMEs.
3046 (ppc64_elf_reloc_type_lookup): Use proper CTOR reloc.
3047 (ORI_R0_R0_0): Correct.
3048
5d1634d7
AM
30492002-01-16 Alan Modra <amodra@bigpond.net.au>
3050
3051 * elflink.c (_bfd_elf_create_dynamic_sections): Don't set SEC_CODE
3052 when plt_not_loaded.
3053 * elf64-ppc.c (ppc64_elf_create_dynamic_sections): No need to
3054 clear .plt SEC_CODE here. Create .stub and correct .glink flags.
3055 (PLT_INITIAL_ENTRY_SIZE): Set to 24.
3056 (ppc64_elf_glink_code): Delete.
3057 (PPC64_ELF_GLINK_SIZE): Delete.
3058 (ADDIS_R12_R2, STD_R2_40R1, LD_R11_0R12, LD_R2_0R12, MTCTR_R11,
3059 BCTR, ADDIS_R12_R12_1, LD_R2_40R1, NOP, LI_R0_0, B_DOT, LIS_R0_0,
3060 ORI_R0_R0_0): Define.
3061 (PLT_CALL_STUB_SIZE, GLINK_CALL_STUB_SIZE): Define.
3062 (struct ppc_link_hash_table): Add sstub and plt_overflow.
3063 (ppc64_elf_link_hash_table_create): Init them.
3064 (ppc64_elf_check_relocs <R_PPC64_REL24>): Refcount .plt entry.
3065 Don't copy to shared lib.
3066 (ppc64_elf_check_relocs): Call bfd_set_error on errors.
3067 (ppc64_elf_gc_sweep_hook <R_PPC64_REL24>): Sweep plt refcount.
3068 (allocate_dynrelocs <plt>): Don't change function sym here. Make
3069 room for .stub and .glink code.
3070 (ppc64_elf_size_dynamic_sections): Handle .stub. Make entry for
3071 DT_PPC64_GLINK.
3072 (ppc64_elf_final_link): Rename to ppc64_elf_set_toc. Don't call
3073 bfd_elf64_bfd_final_link.
3074 (bfd_elf64_bfd_final_link): Don't define.
3075 (ppc64_elf_size_stubs): New.
3076 (build_plt_stub): New.
3077 (build_one_stub): New.
3078 (ppc64_elf_build_stubs): New.
3079 (ppc64_elf_relocate_section <toc relocs>): Remove assert.
3080 (ppc64_elf_relocate_section): Don't copy R_PPC64_REL24 relocs.
3081 (ppc64_elf_finish_dynamic_symbol): Don't build stubs here. Set
3082 DT_PPC64_GLINK entry. Tweak DT_PLTGOT, DT_JMPREL, DT_PLTRELSZ in
3083 case output sections not separate. Adjust DT_RELASZ to not
3084 include plt relocs. Set reserved got entry. Set got and plt
3085 entry size.
3086 (elf_backend_got_header_size): Set to 8.
3087 * elf64-ppc.h: New file.
3088
c601ffdb
AM
30892002-01-16 Alan Modra <amodra@bigpond.net.au>
3090
3091 * elf32-arm.h (elf32_arm_size_dynamic_sections): When removing
3092 sections, use bfd_section_list_remove.
3093 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
3094 * elflink.h (elf_link_add_object_symbols): When removing all
3095 sections, use bfd_section_list_clear.
3096
8fb4cb7f
NC
30972002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
3098
3099 * po/sv.po: New file: Swedish translation.
3100 * configure.in (ALL_LINGUAS): Add sv.
3101 * configure: Regenerate.
3102
d3c456e9
JJ
31032002-01-15 Jakub Jelinek <jakub@redhat.com>
3104
3105 * elflink.h (elf_link_input_bfd): Back out 2002-01-07 change.
3106 * elf.c (merge_sections_remove_hook): New function.
3107 (_bfd_elf_merge_sections): Pass it as 3rd argument to
3108 _bfd_merge_sections.
3109 * libbfd-in.h (_bfd_merge_sections): Add 3rd argument.
3110 * libbfd.h: Rebuilt.
3111 * merge.c (_bfd_merge_sections): Add remove_hook argument.
3112 Call remove_hook if a SEC_EXCLUDE section is encountered.
3113
1f7fd478
NC
31142002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
3115
3116 * elf32-xstormy16.c (xstormy16_reloc_map): Add new field 'table'.
3117 (xstormy16_reloc_map): Initialise new field with correct howto
3118 table.
3119 (xstormy16_reloc_type_lookup): Use 'table' field to locate correct
3120 howto entry.
3121
b87011e9
MS
31222002-01-10 Michael Snyder <msnyder@redhat.com>
3123
3124 * elf.c (elfcore_write_prstatus): Use long instead of pid_t;
3125 (elfcore_write_pstatus): Use long instead of pid_t;
3126 * elf-bfd.h: Change prototypes to use long instead of pid_t;
3127
175e9962 31282002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
b4db1224
JT
3129
3130 * elf.c: Update copyright years.
3131 (elfcore_grok_netbsd_note): Use NT_NETBSDCORE_PROCINFO
3132 and NT_NETBSDCORE_FIRSTMACH. Improve a comment.
3133
7c76fa91
MS
31342002-01-08 Michael Snyder <msnyder@redhat.com>
3135
3136 Add capability to write corefile note sections, for gdb.
3137 * elf.c (elfcore_write_note): New function.
3138 (elfcore_write_prpsinfo): New function.
3139 (elfcore_write_prstatus): New function.
3140 (elfcore_write_pstatus): New function.
3141 (elfcore_write_prfpreg): New function.
3142 (elfcore_write_prxfpreg): New function.
97996af6 3143 * elf-bfd.h: Add prototypes for above functions.
7c76fa91 3144
e1fddb6b
AO
31452002-01-08 Alexandre Oliva <aoliva@redhat.com>
3146
3147 * elf.c (elf_fake_sections): Propagate errors from
3148 elf_backend_fake_section.
3149
8d05742f
JT
31502002-01-07 Jason Thorpe <thorpej@wasabisystems.com>
3151
3152 * Makefile.am (BFD32_BACKENDS): Add elf32-sh-nbsd.lo.
3153 (BFD32_BACKENDS_CFILES): Add elf32-sh-nbsd.c.
3154 (elf32-sh-nbsd.lo): New rule.
3155 * Makefile.in: Regenerate.
3156 * config.bfd (sh*le-*-netbsdelf*): New target.
3157 (sh*-*-netbsdelf*): New target.
3158 * configure.in: Include netbsd-core.lo for native sh*-*-netbsd*.
3159 (bfd_elf32_shnbsd_vec): New vector.
3160 (bfd_elf32_shlnbsd_vec): New vector.
3161 * configure: Regenerate.
3162 * elf32-sh-nbsd.c: New file.
3163 * targets.c: Update copyright years.
175e9962 3164 (_bfd_target_vector): Add bfd_elf32_shlnbsd_vec and
8d05742f
JT
3165 bfd_elf32_shnbsd_vec.
3166
1dba4cb4
AH
31672002-01-07 Aldy Hernandez <aldyh@redhat.com>
3168
3169 * coff-rs6000.c (READ20): Use bfd_scan_vma.
3170
47b22aef
GK
31712002-01-07 Geoffrey Keating <geoffk@redhat.com>
3172
3173 * elflink.h (elf_link_input_bfd): Don't ask for the merged offset
3174 of a symbol in a section that will be deleted.
3175
be2d1673
NC
31762002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
3177
3178 * po/es.po: New file: Spanish translation.
3179 * configure.in (ALL_LINGUAS): Add es.
3180 * configure: Regenerate.
3181
d9cf1b54
AM
31822002-01-06 Steve Ellcey <sje@cup.hp.com>
3183
3184 * elfxx-ia64.c (is_unwind_section_name): Add target vector as
3185 argument so we can handle HP-UX specially.
3186 (elfNN_ia64_hpux_vec): New for use in is_unwind_section_name.
3187 (elfNN_hpux_backend_section_from_bfd_section): New for support
3188 of SHN_IA_64_ANSI_COMMON.
3189 (elfNN_ia64_relax_section): Add support for SHN_IA_64_ANSI_COMMON.
3190 (is_unwind_section_name): Add special HP-UX support.
3191 (elfNN_ia64_section_from_shdr): Add support for more sections.
3192 (elfNN_ia64_fake_sections): Modify is_unwind_section_name call and
3193 add support for more sections.
3194 (elfNN_ia64_additional_program_headers): Modify
3195 is_unwind_section_name call.
3196 (elfNN_ia64_modify_segment_map): Remove assumption that there is
3197 only one unwind section in segment.
3198
3f3c5c34
AM
31992002-01-06 Alan Modra <amodra@bigpond.net.au>
3200
3201 * syms.c (_bfd_generic_make_empty_symbol): New function.
3202 * libbfd-in.h (_bfd_nosymbols_make_empty_symbol): Define as
3203 _bfd_generic_make_empty_symbol.
3204 * libbfd.h: Regenerate.
3205 * bfd-in2.h: Regenerate.
3206 * hppabsd-core.c (hppabsd_core_make_empty_symbol): Delete function.
3207 (hppabsd_core_get_symtab_upper_bound): Don't define.
3208 (hppabsd_core_get_symtab): Likewise.
3209 (hppabsd_core_print_symbol): Likewise.
3210 (hppabsd_core_get_symbol_info): Likewise.
3211 (hppabsd_core_bfd_is_local_label_name): Likewise.
3212 (hppabsd_core_get_lineno): Likewise.
3213 (hppabsd_core_find_nearest_line): Likewise.
3214 (hppabsd_core_bfd_make_debug_symbol): Likewise.
3215 (hppabsd_core_read_minisymbols): Likewise.
3216 (hppabsd_core_minisymbol_to_symbol): Likewise.
3217 (hppabsd_core_vec): Use BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols).
3218 Formatting fixes.
3219 * hpux-core.c: Similarly.
3220 * irix-core.c: Similarly.
3221 * osf-core.c: Similarly.
3222 * sco5-core.c: Similarly.
3223 * binary.c (binary_make_empty_symbol): Remove function, define as
3224 _bfd_generic_make_empty_symbol.
3225 * ihex.c (ihex_make_empty_symbol): Likewise.
3226 * mmo.c (mmo_make_empty_symbol): Likewise.
3227 * ppcboot.c (ppcboot_make_empty_symbol): Likewise.
3228 * srec.c (srec_make_empty_symbol): Likewise.
3229 * versados.c (versados_make_empty_symbol): Likewise.
3230 * vms.c (_bfd_vms_make_empty_symbol): Remove.
3231 (vms_make_empty_symbol): Define as _bfd_generic_make_empty_symbol.
3232 * vms-gsd.c (_bfd_vms_slurp_gsd): Call bfd_make_empty_symbol
3233 rather than _bfd_vms_make_empty_symbol.
3234 * vms-misc.c (new_symbol): Likewise.
3235
3f0a7f7f
AM
32362002-01-05 Alan Modra <amodra@bigpond.net.au>
3237
9e7b37b3
AM
3238 * section.c (bfd_section_init): Remove unnecessary initialisations.
3239 (bfd_section_list_clear): New function.
3240 (bfd_section_list_remove, bfd_section_list_insert): New macros.
3241 (_bfd_strip_section_from_output): Use them.
3242 * coffcode.h (coff_set_alignment_hook): Likewise.
3243 * elf32-mips.c (_bfd_mips_elf_final_link): Likewise.
3244 * elf64-mips.c (mips_elf64_final_link): Likewise.
3245 * elf64-mmix.c (mmix_elf_final_link): Likewise.
3246 * sunos.c (sunos_add_dynamic_symbols): Likewise.
3247 * xcofflink.c (_bfd_xcoff_bfd_final_link): Likewise.
3248 * bfd-in2.h: Regenerate.
3249
3250 * netbsd-core.c (netbsd_core_file_p): Use bfd_make_section_anyway
3251 rather than doing our own section handling. Clean up after errors
3252 with bfd_release and bfd_section_list_clear. Handle unexpected
3253 flags.
3254 * aoutf1.h (sunos4_core_file_p): Likewise.
3255 * aix386-core.c (aix386_core_file_p): Likewise.
3256 * cisco-core.c (cisco_core_file_validate): Likewise.
3257 * ptrace-core.c (ptrace_unix_core_file_p): Likewise.
3258 * trad-core.c (trad_unix_core_file_p): Likewise.
3259
3260 * hppabsd-core.c (hppabsd_core_core_file_p): Clean up after errors
3261 with bfd_release and bfd_section_list_clear.
3262 * hpux-core.c (hpux_core_core_file_p): Likewise.
3263 * irix-core.c (irix_core_core_file_p): Likewise.
3264 * lynx-core.c (lynx_core_file_p): Likewise.
3265 * osf-core.c (osf_core_core_file_p): Likewise.
3266 * rs6000-core.c (rs6000coff_core_p): Likewise.
3267 * sco5-core.c (sco5_core_file_p): Likewise.
3268
3f0a7f7f
AM
3269 * elf32-mips.c (_bfd_mips_elf_lo16_reloc): Simplify, and perform
3270 sign extension adjustments without conditionals.
3271
a3aa38ee
JJ
32722002-01-04 Jakub Jelinek <jakub@redhat.com>
3273
3274 * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): Don't crash if
3275 CIE at .eh_frame start is removed due to no FDEs referencing it.
3276
8a8b2d4b
AJ
32772002-01-04 Jason Thorpe <thorpej@wasabisystems.com>
3278
3279 * config.bfd (x86_64-*-netbsd*): New target.
3280 * configure.in (x86_64-*-netbsd*): Set COREFILE
3281 to netbsd-core.lo.
3282 * configure: Regenerated.
3283
04b5af89
TR
32842002-01-03 Tom Rix <trix@redhat.com>
3285
3286 * xcofflink.c (_bfd_xcoff_bfd_final_link): Update .pad section ordering
3287 for recent bfd_make_section_anyway change.
3288
51c5503b
NC
32892002-01-03 Nick Clifton <nickc@cambridge.redhat.com>
3290
3291 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
3292 R_ARM_THM_PC11 reloc.
3293
07f7c046
NC
32942002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
3295
3296 * configure.in (LINGUAS): Add ja.
3297 * configure: Regenerate.
3298 * po/ja.po: Import from translation project's web site.
3299
5eefb65f
NC
33002002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
3301
3302 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Reformat error
3303 messages to ease translation into other languages.
3304
39e90f10 3305For older changes see ChangeLog-0001
56882138
AM
3306\f
3307Local Variables:
3308mode: change-log
3309left-margin: 8
3310fill-column: 74
3311version-control: never
3312End:
This page took 0.258146 seconds and 4 git commands to generate.