]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - bfd/ChangeLog
2002-08-14 H.J. Lu <hjl@gnu.org>
[thirdparty/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
c828c771
L
12002-08-13 H.J. Lu <hjl@gnu.org>
2
3 * elflink.h (NAME(bfd_elf,size_dynamic_sections): Don't count
4 definitions in shared objects when checking symbol with
5 undefined version.
6
9b701e44
SC
72002-08-13 Stephane Carrez <stcarrez@nerim.fr>
8
9 * elf32-m68hc11.c (elf32_m68hc11_gc_mark_hook): New for section GC.
10 (elf32_m68hc11_gc_sweep_hook): Likewise.
11 (elf_backend_gc_mark_hook): Define for GC section support.
12 (elf_backend_gc_sweep_hook): Likewise.
13 (elf_backend_can_gc_sections): Likewise.
14
15 * elf32-m68hc12.c: Likewise.
16
96405e3c
SC
172002-08-13 Stephane Carrez <stcarrez@nerim.fr>
18
19 * elf32-m68hc11.c (_bfd_m68hc11_elf_print_private_bfd_data): New.
20 (_bfd_m68hc11_elf_merge_private_bfd_data): New function.
21 (_bfd_m68hc11_elf_set_private_flags): New function.
22 Use them to set/check/print ELF flags specific to 68HC11.
23
24 * elf32-m68hc12.c (_bfd_m68hc12_elf_print_private_bfd_data): New.
25 (_bfd_m68hc12_elf_merge_private_bfd_data): New function.
26 (_bfd_m68hc12_elf_set_private_flags): New function.
27 Use them to set/check/print ELF flags specific to 68HC12.
28
dae78fb0
SC
292002-08-13 Stephane Carrez <stcarrez@nerim.fr>
30
31 * elf32-m68hc11.c (elf_m68hc11_howto_table): Add the new relocs;
32 fix masks for PC-rel relocs.
33 (m68hc11_elf_ignore_reloc): New function.
34
35 * elf32-m68hc12.c (m68hc12_elf_special_reloc): New to handle specific
36 68HC12 banked addressing relocs.
37 (m68hc12_phys_addr): New to compute physical address of banked memory.
38 (m68hc12_phys_page): Likewise for page.
39 (m68hc12_addr_is_banked): New to see if address is in banked area.
40 (elf_m68hc12_howto_table): Add new relocs and rename to xx12.
41
3dbfec86
SC
422002-08-13 Stephane Carrez <stcarrez@nerim.fr>
43
44 * reloc.c (BFD_RELOC_M68HC11_RL_JUMP, BFD_RELOC_M68HC11_RL_GROUP,
45 BFD_RELOC_M68HC11_LO16, BFD_RELOC_M68HC11_PAGE,
46 BFD_RELOC_M68HC11_24): New relocs for 68HC11/68HC12.
47 * bfd-in2.h: Regenerate.
48
871da94f
L
492002-08-12 H.J. Lu <hjl@gnu.org>
50
51 * elflink.h (elf_add_default_symbol): Preserve section across
52 elf_merge_symbol.
53
59bc061d
NC
542002-08-09 Graeme Peterson <gp@qnx.com>
55
56 * Makefile.am: Add entries for elf32-ppcqnx.c, and add
57 elf32-qnx.h dependency to elfarmqnx-nabi.c and elf32-i386qnx.c.
58 * Makefile.in: Regenerate.
59 * config.bfd: Add support for powerpc{le}-*-nto targets.
60 * configure.in: Add support for bfd_elf32_powerpc{le}qnx_vec.
61 * configure: Regenerate.
62 * elf32-i386qnx.c: Moved backend functions into a QNX specific
63 common file "elf32-qnx.h", and now include that file.
64 * elf32-qnx.h: New file: QNX specific common elf backend.
65 * elf32-ppc.c: Do not include elf32-target.h if
66 ELF32_PPC_C_INCLUDED is defined.
67 * elf32-ppcqnx.c: New file: Support for QNX.
68 * elfarmqnx-nabi.c: Include elf32-qnx.h for qnx elf backend.
69 * targets.c: Add bfd_elf32_powerpc{le}qnx_vec.
70
2b692c59
NC
712002-08-09 Nick Clifton <nickc@redhat.com>
72
73 * po/sv.po: Updated Swedish translation.
74
d0c7ff07
TS
752002-08-09 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
76
77 * elfxx-mips.c (mips_elf_global_got_index): Avoid segfault if
78 g->global_gotsym is NULL.
79
d8bbe778
L
802002-08-08 H.J. Lu <hjl@gnu.org>
81
82 * elflink.h (elf_add_default_symbol): Don't warn a defintion
83 overrides an indirect versioned symbol.
84
c366c25e
JJ
852002-08-08 Jakub Jelinek <jakub@redhat.com>
86
87 * elf32-i386.c (elf_i386_relocate_section): Fill in proper addend
88 for R_386_TLS_TPOFF32 relocs against symndx 0.
89
31941635
L
902002-08-07 H.J. Lu <hjl@gnu.org>
91
92 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Check symbol
93 with undefined version if needed.
94 (elf_link_assign_sym_version): Match a default symbol with a
95 version without definition. No need to hide the default
96 definition separately.
97
0f3bd64f
AM
982002-08-08 Alan Modra <amodra@bigpond.net.au>
99
7330fb86
AM
100 * elflink.h (elf_link_output_extsym): Don't output symbols from
101 SEC_EXCLUDE sections.
102
0f3bd64f
AM
103 * aoutx.h (aout_link_write_symbols): Correct handling of warning syms.
104
a4aa0fb7
AM
1052002-08-07 Alan Modra <amodra@bigpond.net.au>
106
107 * elf64-ppc.c (edit_opd): Arrange to drop symbols for discarded .opd
108 entries.
109
34ea4a36
TS
1102002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
111
112 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Cast signedness
113 mismatch.
114
141ff970
TS
1152002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
116
117 * elfxx-mips.c (ABI_64_P): Remove superfluous check.
118
28458e7e
TS
1192002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
120
121 * elf32-mips.c (mips_reloc_map): Fix typo.
122
0121a3da
AM
1232002-08-06 Alan Modra <amodra@bigpond.net.au>
124
125 * xcofflink.c (xcoff_write_global_symbol): Set n_scnum for abs_section.
126
d006db6c
AM
1272002-08-06 Alan Modra <amodra@bigpond.net.au>
128
129 * elf64-ppc.c (ppc64_elf_howto_raw): Zero all src_mask entries.
130
8ea80f08
AM
1312002-08-06 Alan Modra <amodra@bigpond.net.au>
132
2a52da53
AM
133 * libxcoff.h: Use PARAMS on function declarations.
134 * coff-rs6000.c (xcoff_generate_rtinit): Simplify size calc.
135 * coff64-rs6000.c (xcoff64_generate_rtinit): Likewise.
136
8ea80f08
AM
137 * coff-rs6000.c: (xcoff_rtype2howto): Don't place reloc address in
138 addend.
139 * coff64-rs6000.c: (xcoff64_rtype2howto): Likewise.
140
cf9ab45b
AM
1412002-08-06 Alan Modra <amodra@bigpond.net.au>
142
143 * coff-rs6000.c: Formatting fixes.
144 (xcoff_calculate_relocation): Use PARAMS in declaration.
145 (xcoff_complain_overflow): Likewise.
146 (xcoff_ppc_relocate_section): Use old-style function pointer call.
147 (bfd_xcoff_backend_data): Remove useless comments.
148 (rs6000coff_vec): Likewise.
149 (bfd_pmac_xcoff_backend_data): Likewise.
150 (pmac_xcoff_vec): Likewise.
8ea80f08 151
cf9ab45b
AM
152 * coff64-rs6000.c: Formatting fixes.
153 (xcoff64_calculate_relocation): Use PARAMS in declaration.
154 (xcoff64_ppc_relocate_section): Use old-style function pointer call.
155 (bfd_xcoff_backend_data): Remove useless comments.
156 (rs6000coff64_vec): Likewise.
157 (bfd_xcoff_aix5_backend_data): Likewise.
158 (aix5coff64_vec): Likewise.
159
48bfecdd
AM
1602002-08-06 Alan Modra <amodra@bigpond.net.au>
161
a78eab4e
AM
162 * coff-rs6000.c (xcoff_howto_table): Revert some of last change to
163 mask entries. Use complain_overflow_dont for R_REF.
164 (xcoff_reloc_type_ba): Revert last change.
165 (xcoff_reloc_type_br): Likewise.
166 (xcoff_reloc_type_crel): Likewise.
167 (xcoff_ppc_relocate_section): Likewise.
168 * coff64-rs6000.c (xcoff64_reloc_type_br): Likewise.
169 (xcoff64_ppc_relocate_section): Likewise.
170 (xcoff64_howto_table): Revert some of last change to mask entries.
171 Use complain_overflow_dont for R_REF.
172
48bfecdd
AM
173 * coff-rs6000.c (xcoff_howto_table): Fix src_mask entries. Make all
174 relocs with bitsize == 16 have size = 1.
175 (xcoff_reloc_type_ba): Correct src_mask and dst_mask adjustment.
176 (xcoff_reloc_type_br): Likewise.
177 (xcoff_reloc_type_crel): Likewise.
178 (xcoff_ppc_relocate_section): Set up src_mask and dst_mask correctly.
179 * coff64-rs6000.c (xcoff64_reloc_type_br): Correct src_mask and
180 dst_mask adjustment.
181 (xcoff64_ppc_relocate_section): Set up src_mask and dst_mask correctly.
182 (xcoff64_howto_table): Fix src_mask entries. Make all relocs with
183 bitsize == 16 have size = 1.
184
fd13ed0c
DC
1852002-08-01 Denis Chertykov <denisc@overta.ru>
186
187 * elf32-ip2k.c: Processor manufacturer changed to Ubicom.
188 (struct misc): New field isymbuf. All free_* fields removed.
189 (symbol_value): Pass in internal syms. No need to swap syms in.
190 (ip2k_elf_relax_section): Use bfd_elf_get_elf_syms. Properly free
191 possibly cached info.
192 (tidyup_after_error): Removed.
193 (ip2k_elf_relax_section_pass1): Don't use removed fields of struct
194 misc. Use new field.
195 (adjust_all_relocations): Use internal syms. No need to swap syms
196 in and out.
197 (add_page_insn): Don't use removed fields of struct misc.
198
24a1ba0f
NC
1992002-08-01 Nick Clifton <nickc@redhat.com>
200
201 * elf32-arm.h: Revert previous delta.
202
a6903459
NC
2032002-08-01 Nick Clifton <nickc@redhat.com>
204
205 * configure.in (AM_INIT_AUTOMAKE): Bump version number.
206 * configure: Regenerate.
207
39a2a3eb
L
2082002-07-31 H.J. Lu <hjl@gnu.org>
209
210 * config.bfd: Add x86-64 vector to Linux/i386 if 64bit BFD is
211 selected.
212
a0dfa6a8
L
2132002-07-31 H.J. Lu <hjl@gnu.org>
214
215 * config.bfd: Add n32 vectors to 32bit Linux/mips if 64bit BFD
216 is selected.
217
cd67d266
JJ
2182002-07-31 Jakub Jelinek <jakub@redhat.com>
219
220 * elf32-i386.c (elf_i386_copy_indirect_symbol): Swap tls_type
221 if _bfd_elf_link_hash_copy_indirect will swap got.refcount.
222
4eb6b71c
NC
2232002-07-31 Ian Dall <ian@sibyl.beware.dropbear.id.au>
224
225 * cpu-ns32k.c (_bfd_ns32k_put_immdeiate, _bfd_ns32k_get_immediate):
226 There is no 8 byte relocation type for this architecture.
227 (do_ns32k_reloc): Use bfd_vma instead of native types.
228 (bfd_ns32k_put_immediate, _bfd_ns32k_relocate_contents) put_data
229 returns void.
230 (_bfd_ns32k_put_displacement): Don't check for overflow. We can
231 rely on generic code to do that.
232 * aout-ns32k.c (howto_table): Add appropriate overflow detection
233 to all table entries.
234 (_bfd_ns32k_relocate_contents): put_data returns void.
235 * ns32k.h: (_bfd_ns32k_put_displacement, _bfd_ns32k_put_immediate)
236 (_bfd_do_ns32k_reloc_contents): Fix prototypes. put data functions
237 return void.
238
f7c33884
NC
2392002-07-31 Ian Dall <ian@sibyl.beware.dropbear.id.au>
240
241 * aoutx.h (aout_link_check_ar_symbols): Whether to include an
242 archive object is target dependant.
243
8f64befb
NC
2442002-07-31 Adam Nemet <anemet@lnxw.com>
245
246 * elf32-arm.h (ARM_PLT_ENTRY_SIZE): Rename PLT_ENTRY_SIZE.
247 (THUMB_PLT_ENTRY_SIZE): New macro.
248 (PLT_ENTRY_SIZE): Return the appropriate *_PLT_ENTRY_SIZE.
249 (elf32_arm_plt0_entry): Rename PLT_ENTRY_SIZE to
250 ARM_PLT_ENTRY_SIZE.
251 (elf32_arm_plt_entry): Likewise.
252 (elf_backend_plt_header_size): Likewise.
253 (elf32_thumb_plt0_entry): New global.
254 (elf32_arm_finish_dynamic_sections): Use it. Put Thumb entries
255 into .plt.thumb.
256 (elf32_thumb_plt_entry): New global.
257 (elf32_arm_finish_dynamic_symbol): Use it. Use .thumb.plt for
258 Thumb entries. Set the bottom bit of the corresponding GOT entry
259 for a Thumb PLT entry.
260 (struct elf32_arm_plt_entry_info): New structure.
261 (struct elf32_arm_link_hash_entry, plt_info): New member of this
262 type.
263 (elf32_arm_link_hash_newfunc): Initialize new member.
264 (elf32_arm_final_link_relocate, R_ARM_THM_PC22 case): Handle
265 relocations against the PLT.
266 (elf32_arm_check_relocs, case R_ARM_PLT32 case): Set
267 first_rel_type if this is the first time we encounter the symbol.
268 (elf32_arm_check_relocs, case R_ARM_THM_PC22 case): New case.
269 Determine if relocation needs a PLT entry. Set first_rel_type if
270 this is the first time we encounter the symbol
271 (elf32_arm_adjust_dynamic_symbol): Create PLT entries for Thumb
272 functions as well.
273 (elf32_arm_size_dynamic_sections): Handle .plt.thumb like .plt.
274 (elf32_arm_create_dynamic_sections): New function. Create the
275 .plt.thumb section.
276 (elf_backend_create_dynamic_sections): Call it.
277
47badb7b
NC
2782002-07-31 Nick Clifton <nickc@redhat.com>
279
280 * bfd.c (bfd_alt_mach_code): Rename parameter 'index' to
281 'alternative' in order to avoid shadowing global symbol of the
282 same name.
283 * bfd-in2.h: Regenerate.
284 * libbfd.h: Regenerate.
285 * libcoff.h: Regenerate.
286
8a397dad
TS
2872002-07-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
288
289 * Makefile.am: Add n32 ABI support.
290 * Makefile.in: Regenerate.
291 * config.bfd: Add n32 vectors to mips64*-*-linux* targets. Treat 64
292 bit vectors for mips*-*-linux targets as optional.
293 * configure.in: Add n32 ABI vectors.
294 * configure: Regenerate.
295 * elf32-mips.c (mips_elf32_object_p): Reject n32 ABI files.
296 * elfn32-mips.c: New file, n32 ABI support.
297 * targets.c: Add n32 ABI vectors.
298
7e392df6 2992002-07-30 Graeme Peterson <gp@qnx.com>
83e1617e 300
7e392df6
NC
301 * elfarmqnx-nabi.c: New file: Support for QNX.
302 * config.bfd: Add support for arm-*-nto target.
303 * configure.in: Add support for bfd_elf32_{big|little}armqnx_vec.
304 * configure: Regenerate.
305 * Makefile.am: Add entries for elfarmqnx-nabi.c.
306 * Makefile.in: Regenerate.
307 * elf32-arm.h (ELF_MAXPAGESIZE): Do not define if already defined.
308 Do not define global function if ELFARM_NABI_C_INCLUDED is defined.
309 * elfarm-nabi.c: Do not include elf32-arm.h if
310 ELFARM_NABI_C_INCLUDED is defined.
311 * targets.c: Add bfd_elf32_{big|little}armqnx_vec.
7330fb86 312
7e392df6 3132002-07-30 Nick Clifton <nickc@redhat.com>
7330fb86 314
83e1617e
NC
315 * po/sv.po: Updated Swedish translation.
316
704afa60
JJ
3172002-07-30 Jakub Jelinek <jakub@redhat.com>
318
319 * elf.c (elf_fake_sections): Fix up .tbss sh_size and sh_type.
320
487e54f2
AM
3212002-07-30 Alan Modra <amodra@bigpond.net.au>
322
323 * aoutx.h (some_aout_object_p): Clean up tdata properly on error.
324 * archive.c (bfd_generic_archive_p): Likewise.
325 * coff-rs6000.c (_bfd_xcoff_archive_p): Likewise.
326 (_bfd_xcoff_archive_p): Use bfd_scan_vma in place of strtol.
327 * coff64-rs6000.c (xcoff64_slurp_armap): Likewise.
328 (xcoff64_archive_p): Likewise.
329 (xcoff64_openr_next_archived_file): Likewise.
330 (xcoff64_archive_p): Clean up tdata properly on error.
331 * coffgen.c (coff_real_object_p): Likewise.
332 (coff_object_p): Release filehdr and opthdr.
333 * ecoff.c (_bfd_ecoff_archive_p): Clean up tdata properly on error.
334 * ieee.c (ieee_archive_p): Likewise.
335 * ihex.c (ihex_object_p): Likewise.
336 (ihex_mkobject): Always allocate tdata.
337 * peicode.h (pe_ILF_object_p): Release bfd_alloc'd buffer on error.
338 * srec.c (srec_mkobject): Always allocate tdata.
339 (srec_object_p): Clean up tdata properly on error.
340 (symbolsrec_object_p): Likewise.
341 * versados.c (versados_object_p): Likewise.
342 * vms-misc.c (_bfd_vms_get_record): Use bfd_malloc instead of malloc,
343 and bfd_realloc instead of realloc.
344 (add_new_contents): Use bfd_alloc instead of bfd_malloc for sections.
345 * vms.c (vms_initialize): Always allocate tdata. Use bfd_alloc in
346 place of bfd_malloc, simplifying error freeing. Free hash table too.
347 (vms_object_p): Clean up tdata on error.
348 (vms_mkobject): Don't complain on stderr if vms_initialize fails.
349 (vms_close_and_cleanup): Adjust for bfd_alloc use.
350
9d46020e
AM
3512002-07-30 Alan Modra <amodra@bigpond.net.au>
352
353 * elfxx-ia64.c (elfNN_ia64_final_write_processing): Set e_flags.
354
fb39dac1
RS
3552002-07-26 Chris Demetriou <cgd@broadcom.com>
356
357 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Merge ASE
358 flags into resulting BFD.
359
7a624474
AM
3602002-07-26 Alan Modra <amodra@bigpond.net.au>
361
362 From John Reiser <jreiser@BitWagon.com>
363 * elf32-i386.c (elf_i386_link_hash_table_create): Clear
364 tls_ldm_got.refcount.
365
a4382ec6
TS
3662002-07-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
367
368 * elf64-mips.c: Update TODO comment.
369 (mips_elf64_higher_reloc,mips_elf64_highest_reloc,
370 mips_elf64_gprel16_reloca): Remove prototypes.
371 (mips16_jump_reloc,mips16_gprel_reloc): Add functions.
372 (UNUSED_RELOC): Replace by EMPTY_RELOC.
373 (mips_elf64_howto_table_rel): Use special R_MIPS_HI16 handling. Remove
374 wrong comments. Remove disfunctional support of R_MIPS_HIGHER and
375 R_MIPS_HIGHEST.
376 (mips_elf64_howto_table_rela): Fix handling of R_MIPS_GPREL16 and
377 R_MIPS_GOT16. Remove wrong comments.
378 (elf_mips16_jump_howto,elf_mips16_gprel_howto,
379 elf_mips_gnu_vtinherit_howto,elf_mips_gnu_vtentry_howto): New, code
380 from elf32-mips.c.
381 (mips_elf64_hi16_reloc): Fix formatting.
382 (mips_elf64_higher_reloc,mips_elf64_highest_reloc): Remove.
383 (mips_elf64_got16_reloc): Fix formatting. Remove superfluous code.
384 Better comment. Fall back to R_MIPS_GOT_DISP instead of abort().
385 (mips_elf64_gprel16_reloc): Make static. Add check for
386 partial_inplace.
387 (mips_elf64_gprel16_reloca): Remove.
388 (mips_elf64_literal_reloc): New function.
389 (mips_elf64_gprel32_reloc): Fix formatting.
390 (mips_elf64_shift6_reloc): Fix comment. Make static.
391 (mips16_jump_reloc,mips16_gprel_reloc): New functions, code from
392 elf32-mips.c.
393 (elf_reloc_map,mips_reloc_map): New mapping table, similiar as in
394 elf32-mips.c
395 (bfd_elf64_bfd_reloc_type_lookup): Use the mapping table. Enable GNU
396 specific relocations.
397 (mips_elf64_rtype_to_howto): Enable GNU specific relocations.
398 (mips_elf64_object_p): Invert logic to check for SGI-ish ABI.
399 (ELF_MAXPAGESIZE): Add comment.
400
219576a4
NC
4012002-07-25 Nick Clifton <nickc@redhat.com>
402
403 * po/sv.po: Updated Swedish translation.
404 * po/es.po: Updated Spanish translation.
405 * po/fr.po: Updated French translation.
406
8c58d23b
AM
4072002-07-25 Alan Modra <amodra@bigpond.net.au>
408
409 * elf-bfd.h (_bfd_elf32_link_record_local_dynamic_symbol): Define
410 as elf_link_record_local_dynamic_symbol.
411 (_bfd_elf64_link_record_local_dynamic_symbol): Likewise.
412 (elf_link_record_local_dynamic_symbol): Declare. Now returns int.
413 * elflink.h (elf_link_record_local_dynamic_symbol): Move to..
414 * elflink.c: .. here. Use bfd_elf_get_elf_syms. Check whether an
415 attempt is made to record a symbol in a discarded section, and
416 return `2' in that case.
417
ff3063f5
NC
4182002-07-24 Nick Clifton <nickc@redhat.com>
419
420 * po/sv.po: Updated Swedish translation.
421 * po/es.po: Updated Spanish translation.
422
f0fe0e16
AM
4232002-07-23 Alan Modra <amodra@bigpond.net.au>
424
c1fb5f8a
AM
425 * po/SRC-POTFILES.in: Regenerate.
426
f0fe0e16
AM
427 * elf-hppa.h (elf_hppa_relocate_section): If relocatable, return
428 immediately. Remove code handling relocatable linking.
429 * elf32-avr.c (elf32_avr_relocate_section): Likewise.
430 * elf32-cris.c (cris_elf_relocate_section): Likewise.
431 * elf32-fr30.c (elf32_frv_relocate_section): Likewise.
de2d743e 432 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
f0fe0e16
AM
433 * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
434 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
435 * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
436 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
437 * elf32-v850.c (v850_elf_relocate_section): Likewise.
438 * elf32-vax.c (elf_vax_relocate_section): Likewise.
439 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
440 * elf32-avr.c (elf_backend_rela_normal): Define.
441 * elf32-cris.c: Likewise.
442 * elf32-fr30.c: Likewise.
de2d743e 443 * elf32-frv.c: Likewise.
f0fe0e16
AM
444 * elf32-h8300.c: Likewise.
445 * elf32-hppa.c: Likewise.
446 * elf32-ip2k.c: Likewise.
447 * elf32-sparc.c: Likewise.
448 * elf32-v850.c: Likewise.
449 * elf32-vax.c: Likewise.
450 * elf64-hppa.c: Likewise.
451 * elf64-sparc.c: Likewise.
452 * elf32-fr30.c (elf32_frv_relocate_section): Edit comment.
de2d743e 453 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
f0fe0e16
AM
454 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
455 * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
456 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
457 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
458 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
459 * elf-m10200.c (USE_RELA): Don't define.
460 * elf-m10300.c: Likewise.
de2d743e 461 * elfarm-oabi.c: Likewise.
f0fe0e16
AM
462 * elf32-i370.c: Likewise.
463 * elf32-ip2k.c: Likewise.
464 * elf32-m68k.c: Likewise.
465 * elf32-mcore.c: Likewise.
466 * elf32-ppc.c: Likewise.
467 * elf32-s390.c: Likewise.
468 * elf32-vax.c: Likewise.
469 * elf64-ppc.c: Likewise.
470 * elf64-s390.c: Likewise.
471 * elf64-x86-64.c: Likewise.
472 * elfxx-ia64.c: Likewise.
473 * elf32-avr.c (USE_REL): Don't undef.
474 * elf32-ip2k.c: Likewise.
475
5e8d7549
NC
4762002-07-23 Nick Clifton <nickc@redhat.com>
477
478 * elf-bfd.h (struct elf_backend_data): Add new bitfield
479 'want_p_paddr_set_to_zero'.
480 * elfxx-target.h: Set default value for want_p_paddr_set_to_zero
481 to false;
482 * elfxx-ia64.c: Set want_p_paddr_set_zero for HPUX target.
483 * elf.c (copy_private_bfd_data): Test want_p_paddr_set_zero.
484
9e12c7db
NC
4852002-07-23 Gabor Keresztfalvi <keresztg@mail.com>
486
487 * nlmcode.h (nlm_swap_auxiliary_headers_out): Swapped the order of
488 the MeSsAgEs and CoPyRiGhT tags to make >=NW4.x NLM loaders to
489 show the Copyright string.
490 Minor formatting tidy ups.
491
0461a601
NC
4922002-07-23 Nick Clifton <nickc@redhat.com>
493
ff3063f5
NC
494 * po/fr.po: Updated French translation.
495 * po/sv.po: Updated Swedish translation.
0461a601 496
fad2542d
AM
4972002-07-23 Alan Modra <amodra@bigpond.net.au>
498
499 * elflink.h (elf_link_input_bfd): Don't change internal symbols
500 when outputting relocs.
501
c0647bfc
JT
5022002-07-20 Jason Thorpe <thorpej@wasabisystems.com>
503
504 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Only insert
505 DT_PLTGOT into the dynamic section if there is a PLT.
506
d01414a5
TS
5072002-07-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
508
509 * elfxx-mips.c (_bfd_mips_elf_discard_info): New function, code from
510 elf32-mips.c.
511 (_bfd_mips_elf_write_section): Likewise.
512 * elfxx-mips.h (_bfd_mips_elf_discard_info): New prototype.
513 (_bfd_mips_elf_write_section): Likewise.
514 * elf32-mips.c (elf32_mips_discard_info): Move to elfxx-mips.c.
515 (elf32_mips_write_section): Likewise.
516 * elf64-mips.c (_bfd_mips_elf_ignore_discarded_relocs): Use it.
517 (_bfd_mips_elf_write_section): Likewise.
518
40c97fc6
AM
5192002-07-19 Alan Modra <amodra@bigpond.net.au>
520
521 * elfxx-ia64.c: (elfNN_ia64_modify_segment_map): Properly scan
522 PT_IA_64_UNWIND segments for a given section.
523
58378160
L
5242002-07-17 H.J. Lu <hjl@gnu.org>
525
526 * Makefile.am: Fix a typo.
527 * Makefile.in: Regenerate.
528
cf88bb9f
NC
5292002-07-15 Denis Chertykov <denisc@overta.ru>
530 Frank Ch. Eigler <fche@redhat.com>
531 Ben Elliston <bje@redhat.com>
532 Alan Lehotsky <alehotsky@cygnus.com>
533 John Healy <jhealy@redhat.com>
534 Graham Stott <grahams@redhat.com>
535 Jeff Johnston <jjohnstn@redhat.com>
536
537 * Makefile.am: Add support for ip2k.
538 * Makefile.in: Regenerate.
539 * doc/Makefile.in: Regenerate.
540 * archures.c: Add support for ip2k.
541 * config.bfd: Add support for ip2k.
542 * configure.in: Add support for ip2k.
543 * configure: Regenerate.
544 * reloc.c: Add support for ip2k.
545 * targets.c: Add support for ip2k.
546 * bfd-in2.h: Regenerate.
547 * libbfd.h: Regenerate.
548 * cpu-ip2k.c: New file.
549 * elf32-ip2k.c: New file.
550
0dafd5f6
RE
5512002-07-17 Ian Rickards <irickard@arm.com>
552
40c97fc6 553 * dwarf2.c (concat_filename): If we can't establish the directory
0dafd5f6
RE
554 just return the filename.
555
36b08f12
AM
5562002-07-16 Moritz Jodeit <moritz@jodeit.org>
557
558 * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Correct order of memset args.
559
58821868
AM
5602002-07-16 Alan Modra <amodra@bigpond.net.au>
561
562 * elflink.h: Formatting fixes, tidy prototypes.
563 (elf_link_assign_sym_version): Move common code out of loop.
564
c89583f8
AM
5652002-07-16 Alan Modra <amodra@bigpond.net.au>
566
567 * elflink.h (elf_link_input_bfd): Don't call reloc_emitter when
568 reloc section size is zero. Correct reloc output location.
569
ba94744e
AM
5702002-07-16 John David Anglin <dave@hiauly1.hia.nrc.ca>
571
572 * elf-hppa.h (elf_hppa_reloc_final_type): Use R_PARISC_PCREL16F as
573 the final type for the e_fsel selector when generating PA2.0W code.
574 (elf_hppa_relocate_insn): Provide support for PA2.0W 16-bit format 1
575 relocations.
576
96a94295
L
5772002-07-14 H.J. Lu <hjl@gnu.org>
578
579 * elflink.h (elf_link_assign_sym_version): Hide the default
580 definition if there is a hidden versioned definition.
581
6849c52f
HPN
5822002-07-12 Hans-Peter Nilsson <hp@axis.com>
583
584 * elf32-cris.c (cris_elf_relocate_section): Drop nonsensical
585 dynamic reference test in assertion when initializing GOT with
586 static contents. Just assert that there are either no dynamic
587 sections, the symbol is defined in the regular objects or that the
588 symbol is undef weak. Tweak comment.
589 (elf_cris_finish_dynamic_symbol): Emit .got reloc for a program
590 only if the symbol isn't defined in the program and isn't undef
591 weak.
592 (elf_cris_adjust_dynamic_symbol): Simplify condition for getting
593 rid of PLT entry: only do it if the symbol isn't defined in a DSO.
594 When doing so, clear ELF_LINK_HASH_NEEDS_PLT. Tweak comments.
595 (elf_cris_discard_excess_program_dynamics): Don't consider
596 ELF_LINK_HASH_REF_DYNAMIC when omitting .got runtime relocs.
597
239e1f3a
AM
5982002-07-11 Alan Modra <amodra@bigpond.net.au>
599
600 * elf32-i386.c (elf_i386_relocate_section): Don't complain about
601 unresolved debugging relocs in dynamic applications.
602 * elf32-s390.c (elf_s390_relocate_section): Likewise.
603 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
604 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
605 * elf64-s390.c (elf_s390_relocate_section): Likewise.
606 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
607 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
608
2f6d9989
AM
6092002-07-10 Alan Modra <amodra@bigpond.net.au>
610
f5e87a1d
AM
611 * elf64-ppc.c (ONES): Define.
612 (ppc64_elf_howto_table): Use ONES here to avoid warnings. Fill in
613 missing src_mask fields. Tweak R_PPC64_NONE, R_PPC64_COPY. Fill
614 in missing dst_mask fields on R_PPC64_PLT32, R_PPC64_PLTREL32.
615
2f6d9989
AM
616 * elf64-ppc.c (ppc64_elf_get_symbol_info): Delete.
617 (ppc64_elf_set_private_flags): Delete.
618 (ppc64_elf_section_from_shdr): Delete.
619 (ppc64_elf_merge_private_bfd_data): Remove flag checking/merging code.
620 (ppc64_elf_fake_sections): Delete.
621 (bfd_elf64_bfd_set_private_flags): Don't define.
622 (bfd_elf64_get_symbol_info): Likewise.
623 (elf_backend_section_from_shdr): Likewise.
624 (elf_backend_fake_sections): Likewise.
625
0594c12d
AM
6262002-07-10 Marco Walther <Marco.Walther@sun.com>
627
628 * elf.c: (assign_section_numbers) Set sh_entsize for .stab only
629 when not already set.
630 * elf64-sparc.c: (sparc64_elf_fake_sections): New function.
631 (elf_backend_fake_sections): Define.
632
699cb9b8
AM
6332002-07-10 Alan Modra <amodra@bigpond.net.au>
634
635 * merge.c (_bfd_merge_section): Remove redundant output_section check.
636 Formatting.
637 (_bfd_merge_sections): Don't set SEC_EXCLUDE on unused sections.
638
0a4787a0
HPN
6392002-07-09 Hans-Peter Nilsson <hp@axis.com>
640
641 * elf32-cris.c (cris_elf_relocate_section): Move sanity-check for
642 NULL sym_hashes to just before use.
643 <case R_CRIS_32_GOTREL>: In test for local symbol, accept also
644 symbol with non-default visibility.
645 <case R_CRIS_32_GOTREL, case R_CRIS_32_PLT_GOTREL>: Ditto.
646 <case R_CRIS_8_PCREL, case R_CRIS_16_PCREL, case R_CRIS_32_PCREL>:
647 Ditto.
648 (cris_elf_gc_sweep_hook): Only decrease h->plt.refcount for
649 symbol with non-default visibility.
650 (cris_elf_check_relocs): At tests for local symbol before
651 increasing h->plt.refcount, also check for non-default
652 visibility. Ditto when checking for local symbol to eliminate
653 pc-relative runtime relocs.
654
aecc8f8a
AM
6552002-07-08 Alan Modra <amodra@bigpond.net.au>
656
657 * elf.c: Formatting.
658 (IS_SOLARIS_PT_INTERP): Add p_paddr and p_memsz checks.
659 (INCLUDE_SECTION_IN_SEGMENT): Remove IS_SOLARIS_PT_INTERP.
660 (copy_private_bfd_data): Set p_vaddr on broken Solaris PT_INTERP
661 segments.
662
e9168c1e
MM
6632002-07-07 Mark Mitchell <mark@codesourcery.com>
664 Alan Modra <amodra@bigpond.net.au>
665
666 * cofflink.c (_bfd_coff_final_link): On PE COFF systems, take into
667 account the impact of relocation count overflow when computing
668 section offsets.
669 * coffcode.h (coff_write_relocs): Use obj_pe when deciding whether
670 or not to apply the PE COFF reloc overflow handling. Fix a
671 fencepost error in deciding whether or not to use that technique.
672
6cdc0ccc
AM
6732002-07-07 Alan Modra <amodra@bigpond.net.au>
674
675 * elf-bfd.h (struct elf_reloc_cookie): Remove locsym_shndx,
676 change type of locsyms.
677 (bfd_elf_get_elf_syms): Declare.
678 * elf.c (bfd_elf_get_elf_syms): New function.
679 (group_signature): Use bfd_elf_get_elf_syms.
680 (bfd_section_from_r_symndx): Likewise.
681 * elfcode.h (elf_slurp_symbol_table): Likewise.
682 * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
683 (elf_link_add_object_symbols): Likewise. Reorganise to increase
684 locality of various data structures. Properly free internal relocs.
685 (elf_bfd_final_link): Properly free internal relocs.
686 (elf_link_check_versioned_symbol): Use bfd_elf_get_elf_syms.
687 (elf_link_input_bfd): Likewise.
688 (elf_gc_mark): Likewise. Properly free internal relocs.
689 (elf_gc_sweep): Properly free internal relocs.
690 (elf_reloc_symbol_deleted_p): No need to swap syms in.
691 (elf_bfd_discard_info): Use bfd_elf_get_elf_syms. Properly free
692 internal relocs.
693 * elf-m10200.c (mn10200_elf_relax_section): Use bfd_elf_get_elf_syms.
694 Properly free possibly cached info.
695 (mn10200_elf_relax_delete_bytes): Remove symbol swapping code.
696 (mn10200_elf_symbol_address_p): Pass in internal syms. Remove
697 symbol swapping code.
698 (mn10200_elf_get_relocated_section_contents): Use bfd_elf_get_elf_syms.
699 Properly free possibly cached info.
700 * elf-m10300.c (mn10300_elf_relax_section): As above for elf-m10200.c.
701 (mn10300_elf_relax_delete_bytes): Likewise.
702 (mn10300_elf_symbol_address_p): Likewise.
703 (mn10300_elf_get_relocated_section_contents): Likewise.
704 * elf32-h8300.c (elf32_h8_relax_section): As above for elf-m10200.c.
705 (elf32_h8_relax_delete_bytes): Likewise.
706 (elf32_h8_symbol_address_p): Likewise.
707 (elf32_h8_get_relocated_section_contents): Likewise.
708 * elf32-m32r.c (m32r_elf_relax_section): As above for elf-m10200.c.
709 (m32r_elf_relax_delete_bytes): Likewise.
710 (m32r_elf_get_relocated_section_contents): Likewise.
711 * elf32-sh.c (sh_elf_reloc_loop): Free section contents using
712 elf_section_data to determine whether cached.
713 (sh_elf_relax_section): As above for elf-m10200.c.
714 (sh_elf_relax_delete_bytes): Likewise.
715 (sh_elf_get_relocated_section_contents): Likewise.
716 * elf32-xstormy16.c (xstormy16_elf_relax_section): As above.
717 * elf64-alpha.c (elf64_alpha_relax_section): As above. Also delay
718 reading of local syms.
719 * elf64-mmix.c (mmix_elf_relax_section): Likewise.
720 * elf64-sh64.c (sh_elf64_get_relocated_section_contents): As above.
721 * elfxx-ia64.c (elfNN_ia64_relax_section): As above.
722 * elfxx-mips.c (_bfd_mips_elf_check_relocs): Properly free internal
723 relocs.
724 * elf32-arm.h (bfd_elf32_arm_process_before_allocation): Properly
725 free internal relocs and section contents. Don't read symbols.
726 * elf32-hppa.c (get_local_syms): Use bfd_elf_get_elf_syms.
727 (elf32_hppa_size_stubs): Don't free local syms.
728 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Delay
729 reading of local syms. Use bfd_elf_get_elf_syms. Properly free
730 possibly cached info.
731 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
732 * elf64-hppa.c (elf64_hppa_check_relocs): Use bfd_elf_get_elf_syms.
733 * elf64-ppc.c (struct ppc_link_hash_table): Delete bfd_count and
734 all_local_syms.
735 (get_local_syms): Delete function.
736 (edit_opd): Use bfd_elf_get_elf_syms. Free on error exit. Cache
737 on exit.
738 (ppc64_elf_size_stubs): Use bfd_elf_get_elf_syms. Free/cache on exit.
739
b3212001
JW
7402002-07-05 Jim Wilson <wilson@redhat.com>
741
742 * syms.c (decode_section_type): New.
743 (bfd_decode_symclass): Call decode_section_type.
744
894bb1ee
JJ
7452002-07-04 Jakub Jelinek <jakub@redhat.com>
746
747 * merge.c (_bfd_merged_section_offset): Avoid accessing byte before
748 section content start.
749 Reported by Michael Schumacher <mike@hightec-rt.com>.
750
bc0ba537
AM
7512002-07-04 Alan Modra <amodra@bigpond.net.au>
752
753 * section.c (_bfd_strip_section_from_output): Remove unnecessary
754 link order code. Don't actually remove the output section here;
755 Just set a flag for the linker to do so.
756 * elflink.c (_bfd_elf_link_renumber_dynsyms): Test for removed
757 sections when setting up output section dynsyms.
758
797fc050
AM
7592002-07-04 Alan Modra <amodra@bigpond.net.au>
760
761 * elflink.h (elf_link_add_object_symbols): Revert 1999-09-02 hpux
762 fudge.
763 * elf.c (bfd_section_from_shdr): Work around broken hpux shared
764 libs here instead.
765
99881371
MS
7662002-07-02 Martin Schwidefsky <schwidefsky@de.ibm.com>
767
768 * elf64-s390.c (create_got_section): Set .got section alignment to
769 8 bytes.
770 (elf_s390_check_relocs): Set .rela.dyn section alignment to 8 bytes.
771
47d9a591
AM
7722002-07-02 Alan Modra <amodra@bigpond.net.au>
773
774 * elf.c (_bfd_elf_reloc_type_class): Fix comment grammar.
775
179d3252
JT
7762002-07-01 Matt Thomas <matt@3am-software.com>
777
778 * elf32-vax.c (elf32_vax_print_private_bfd_data): Change EF_*
779 to EF_VAX_*.
780
4a14403c
TS
7812002-07-01 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
782
783 * elfxx-mips.c (ABI_64_P): Fix comment.
784 (MIPS_ELF_OPTIONS_SECTION_NAME,MIPS_ELF_STUB_SECTION_NAME): Use the
785 new section names for N64 ABI.
786 (mips_elf_output_extsym): No special _gp_disp handling for NewABI.
787 (mips_elf_calculate_relocation): Code formatting.
788 (mips_elf_create_dynamic_relocation): Likewise.
789 (_bfd_mips_elf_fake_sections): IRIX6 needs this hack, too.
790 (_bfd_mips_elf_size_dynamic_sections): Handle GOT_PAGE for any NewABI.
791 (_bfd_mips_elf_relocate_section): No special handling for R_MIPS_64
792 in any NewABI.
793 (_bfd_mips_elf_finish_dynamic_symbol): No special _gp_disp handling
794 for NewABI.
795 (_bfd_mips_elf_modify_segment_map): Handle any N64 ABI.
796 (_bfd_mips_elf_gc_sweep_hook): NewABI GOT relocs should be handled
797 here, too.
798
607c0e09
AS
7992002-07-01 Andreas Schwab <schwab@suse.de>
800
801 * elf64-x86-64.c (elf64_x86_64_relocate_section): Only convert
802 R_X86_64_64 to R_X86_64_RELATIVE.
803
ba26fd96
AM
8042002-07-01 John David Anglin <dave@hiauly1.hia.nrc.ca>
805
806 * vaxbsd.c: New BFD backend for VAX BSD and Ultrix.
807 * Makefile.am (BFD32_BACKENDS, BFD32_BACKENDS_CFILES): Add new backend.
808 Run "make dep-am".
809 * config.bfd (vax-*-bsd* | vax-*-ultrix*): Use vaxbsd_vec instead of
810 host_aout_vec.
811 * configure.in (vaxbsd_vec): Add.
812 * targets.c (vaxbsd_vec): Add.
813 * Makefile.in: Rebuild.
814 * configure: Rebuild.
815 * po/SRC-POTFILES.in: Rebuild.
816
1e2f5b6e
AM
8172002-07-01 Alan Modra <amodra@bigpond.net.au>
818
819 * elflink.h (elf_gc_mark): Pass in the section whose relocs we are
820 examining to gc_mark_hook, rather than the bfd.
821 (elf_gc_sections): Adjust.
822 * elf-bfd.h (struct elf_backend_data <gc_mark_hook>): Likewise.
823 * elf-m10300.c (mn10300_elf_gc_mark_hook): Likewise.
824 * elf32-arm.h (elf32_arm_gc_mark_hook): Likewise.
825 * elf32-avr.c (elf32_avr_gc_mark_hook): Likewise.
826 * elf32-cris.c (cris_elf_gc_mark_hook): Likewise.
827 * elf32-d10v.c (elf32_d10v_gc_mark_hook): Likewise.
828 * elf32-fr30.c (fr30_elf_gc_mark_hook): Likewise.
829 * elf32-hppa.c (elf32_hppa_gc_mark_hook): Likewise.
830 * elf32-i386.c (elf_i386_gc_mark_hook): Likewise.
831 * elf32-m32r.c (m32r_elf_gc_mark_hook): Likewise.
832 * elf32-m68k.c (elf_m68k_gc_mark_hook): Likewise.
833 * elf32-mcore.c (mcore_elf_gc_mark_hook): Likewise.
834 * elf32-openrisc.c (openrisc_elf_gc_mark_hook): Likewise.
835 * elf32-ppc.c (ppc_elf_gc_mark_hook): Likewise.
836 * elf32-s390.c (elf_s390_gc_mark_hook): Likewise.
837 * elf32-sh.c (sh_elf_gc_mark_hook): Likewise.
838 * elf32-sparc.c (elf32_sparc_gc_mark_hook): Likewise.
839 * elf32-v850.c (v850_elf_gc_mark_hook): Likewise.
840 * elf32-vax.c (elf_vax_gc_mark_hook): Likewise.
841 * elf32-xstormy16.c (xstormy16_elf_gc_mark_hook): Likewise.
842 * elf64-mmix.c (mmix_elf_gc_mark_hook): Likewise.
843 * elf64-ppc.c (ppc64_elf_gc_mark_hook): Likewise.
844 * elf64-s390.c (elf_s390_gc_mark_hook): Likewise.
845 * elf64-sh64.c (sh_elf64_gc_mark_hook): Likewise.
846 * elfxx-mips.c (_bfd_mips_elf_gc_mark_hook): Likewise.
847 * elfxx-mips.h (_bfd_mips_elf_gc_mark_hook): Likewise.
848 * elf64-x86-64.c (elf64_x86_64_gc_mark_hook): Likewise.
849 * elf32-frv.c (elf32_frv_gc_mark_hook): Likewise. Also remove
850 redundant local sym tests.
851 * elf64-ppc.c (struct ppc_link_hash_entry): Add is_entry.
852 (link_hash_newfunc): Init is_entry.
853 (ppc64_elf_copy_indirect_symbol): Copy is_entry.
854 (ppc64_elf_link_hash_table_create): Init all_local_syms.
855 (create_linkage_sections): Use bfd_make_section_anyway rather than
856 bfd_make_section.
857 (ppc64_elf_mark_entry_syms): New function.
858 (ppc64_elf_check_relocs): Don't bother testing elf_bad_symtab. Set
859 up opd entry to function section map.
860 (ppc64_elf_gc_mark_hook): Special case opd section relocs, and
861 relocs that reference the opd section.
862 (edit_opd): New function.
863 (ppc64_elf_size_dynamic_sections): Call get_local_syms and edit_opd.
864 (ppc64_elf_setup_section_lists): Don't calculate htab->bfd_count here.
865 (get_local_syms): Do so here. Exit if we already have local syms.
866 Remove bogus comment imported from elf32-hppa.c. Don't attempt to
867 read local syms on non-ELF input.
868 (ppc64_elf_size_stubs): Call _bfd_elf64_link_read_relocs rather
869 than duplicating it's function here. Adjust free of internal
870 relocs to suit.
871 (ppc64_elf_relocate_section): Adjust local syms in opd section.
872 * elf64-ppc.h (ppc64_elf_mark_entry_syms): Declare.
873 * elf32-hppa.c (elf32_hppa_size_stubs): Call
874 _bfd_elf32_link_read_relocs rather than duplicating it's function
875 here. Adjust free of internal relocs to suit.
876
1b71fb54
AJ
8772002-07-01 Andreas Jaeger <aj@suse.de>
878
879 * elf64-x86-64.c (elf64_x86_64_check_relocs): Certain relocations
880 are not allowed in shared libs code, enforce -fPIC.
881
8d28f606
HPN
8822002-06-29 Hans-Peter Nilsson <hp@bitrange.com>
883
884 * mmo.c (mmo_write_loc_chunk): Don't eliminate leading and
885 trailing zero-sequences when there's previous left-over data.
886
5ac81c74
JL
8872002-06-27 John David Anglin <dave@hiauly1.hia.nrc.ca>
888
889 * elf64-hppa.c (elf64_hppa_reloc_type_class): New function.
890 (elf64_hppa_finish_dynamic_sections): Check other_rel_sec, dlt_rel_sec
891 and opd_rel_sec in order for starting rela section. Check _raw_size.
892 (elf_backend_reloc_type_class): Define.
893
91a4d569
AM
8942002-06-27 Kevin Buettner <kevinb@redhat.com>
895
896 * dwarf2.c (decode_line_info): Handle older, non-standard, 64-bit
897 DWARF2 formats.
898
feee612b
AM
8992002-06-27 Alan Modra <amodra@bigpond.net.au>
900
901 * cpu-powerpc.c: Comment on ordering of arch_info.
902 * elf32-ppc.c (ppc_elf_object_p): New function.
903 (elf_backend_object_p): Define.
904 * elf64-ppc.c (ppc64_elf_object_p): New function.
905 (elf_backend_object_p): Define.
906
a4e6cefc
JT
9072002-06-26 Jason Thorpe <thorpej@wasabisystems.com>
908
909 * configure.in (vax-*-netbsd*): Set COREFILE to netbsd-core.lo.
910 * configure: Regenerate.
911
dae2dd0d
NC
9122002-06-25 Jason Eckhardt <jle@rice.edu>
913
914 * dwarf2.c (decode_line_info): Check unit->addr_size
915 to read in the proper number of prologue bytes.
916
680f9d5c
NC
9172002-06-25 Nick Clifton <nickc@cambridge.redhat.com>
918
919 * config.bfd (powerpc-*-aix5*): Only create a selvecs for
920 aix5coff64_vec if 64-bit bfd support has been enabled.
91a4d569
AM
921 (powerpc64-*-aix5*): Only define if 64-bit bfd support has
922 been enabled.
dae2dd0d 923
680f9d5c
NC
924 * targets.c (_bfd_target_vector[]): Only include
925 aix5coff64_vec if 64-bit bfd support has been enabled.
926
d4c88bbb
AM
9272002-06-25 Alan Modra <amodra@bigpond.net.au>
928
929 * elf64-ppc.c (ppc_add_stub): Replace strcpy/strncpy with memcpy.
930 * elf32-hppa.c (hppa_add_stub): Likewise.
931 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
932 * elflink.h (elf_add_default_symbol): Fix comment typo.
933 (elf_add_default_symbol): Replace strcpy and strncpy with memcpy.
934 (elf_link_add_object_symbols): Likewise.
935 (elf_link_assign_sym_version): Likewise.
936 * hash.c (bfd_hash_lookup): Likewise.
937 * linker.c (_bfd_generic_link_add_one_symbol): Likewise.
938 * section.c (bfd_get_unique_section_name): Likewise.
939 * syms.c (_bfd_stab_section_find_nearest_line): Likewise.
940 * elf.c (_bfd_elf_make_section_from_phdr): Likewise.
941 (assign_section_numbers): Likewise.
942 (_bfd_elfcore_make_pseudosection): Likewise.
943 (elfcore_grok_lwpstatus): Likewise.
944 (elfcore_grok_win32pstatus): Likewise.
945 (elfcore_write_note): Constify input params. Use PTR instead of
946 void *. Include terminating NUL in namesz. Correct padding.
947 Support NULL "name" param. Use memcpy instead of strcpy.
948 (elfcore_write_prpsinfo): Constify input params.
949 (elfcore_write_prstatus): Likewise. Use PTR instead of void *.
950 (elfcore_write_lwpstatus): Likewise.
951 (elfcore_write_pstatus): Likewise.
952 (elfcore_write_prfpreg): Likewise.
953 (elfcore_write_prxfpreg): Likewise.
954 * elf-bfd.h (elfcore_write_note): Update declaration.
955 (elfcore_write_prpsinfo): Likewise.
956 (elfcore_write_prstatus): Likewise.
957 (elfcore_write_pstatus): Likewise.
958 (elfcore_write_prfpreg): Likewise.
959 (elfcore_write_prxfpreg): Likewise.
960 (elfcore_write_lwpstatus): Likewise.
961
b0ac09d2
NC
9622002-06-25 Jason Eckhardt <jle@rice.edu>
963
964 * ecoff.c (ecoff_set_symbol_info): Set BSF_FUNCTION for
965 symbols of type stProc and stStaticProc.
966
9672002-06-25 Nick Clifton <nickc@redhat.com>
968
969 * ecoff.c: VArious formatting fixes.
970
021d6096
AM
9712002-06-25 Alan Modra <amodra@bigpond.net.au>
972
973 * coff-rs6000.c (xcoff_generate_rtinit): Fix typo.
974
82e51918
AM
9752002-06-25 Alan Modra <amodra@bigpond.net.au>
976
977 * aout-adobe.c: Don't compare against "true" or "false.
978 * aout-target.h: Likewise.
979 * aoutx.h: Likewise.
980 * archive.c: Likewise.
981 * bout.c: Likewise.
982 * cache.c: Likewise.
983 * coff-a29k.c: Likewise.
984 * coff-alpha.c: Likewise.
985 * coff-i386.c: Likewise.
986 * coff-mips.c: Likewise.
987 * coff-or32.c: Likewise.
988 * coff64-rs6000.c: Likewise.
989 * coffcode.h: Likewise.
990 * coffgen.c: Likewise.
991 * cpu-ns32k.c: Likewise.
992 * ecoff.c: Likewise.
993 * ecofflink.c: Likewise.
994 * elf.c: Likewise.
995 * elf32-arm.h: Likewise.
996 * elf32-cris.c: Likewise.
997 * elf32-d30v.c: Likewise.
998 * elf32-i386.c: Likewise.
999 * elf32-mcore.c: Likewise.
1000 * elf32-ppc.c: Likewise.
1001 * elf32-sh.c: Likewise.
1002 * elf32-sh64.c: Likewise.
1003 * elf32-v850.c: Likewise.
1004 * elf64-alpha.c: Likewise.
1005 * elf64-sh64.c: Likewise.
1006 * elfcode.h: Likewise.
1007 * elfcore.h: Likewise.
1008 * elflink.h: Likewise.
1009 * elfxx-mips.c: Likewise.
1010 * i386os9k.c: Likewise.
1011 * ieee.c: Likewise.
1012 * libbfd.c: Likewise.
1013 * linker.c: Likewise.
1014 * mmo.c: Likewise.
1015 * nlm32-alpha.c: Likewise.
1016 * nlm32-i386.c: Likewise.
1017 * nlm32-ppc.c: Likewise.
1018 * nlm32-sparc.c: Likewise.
1019 * nlmcode.h: Likewise.
1020 * oasys.c: Likewise.
1021 * pdp11.c: Likewise.
1022 * peicode.h: Likewise.
1023 * reloc.c: Likewise.
1024 * som.c: Likewise.
1025 * srec.c: Likewise.
1026 * tekhex.c: Likewise.
1027 * vms.c: Likewise.
1028 * xcofflink.c: Likewise.
1029 * elf64-sparc.c: Edit comment to not use "== false".
1030
1031 * aoutf1.h: Don't use "? true : false".
1032 * ecoff.c: Likewise.
1033 * format.c: Likewise.
1034 * ieee.c: Likewise.
1035 * linker.c: Likewise.
1036 * mmo.c: Likewise.
1037 * oasys.c: Likewise.
1038
48fc70a2
AM
10392002-06-23 H.J. Lu <hjl@gnu.org>
1040
1041 * elflink.h (elf_link_add_archive_symbols): For the default
1042 version, check references with only one `@' first.
1043
47b7c2db
AM
10442002-06-23 John David Anglin <dave@hiauly1.hia.nrc.ca>
1045
1046 * elf64-hppa.c (elf64_hppa_mark_milli_and_exported_functions): New
1047 function.
1048 (allocate_global_data_dlt): Don't add millicode symbols to dynamic
1049 symbol table.
1050 (allocate_global_data_opd, allocate_dynrel_entries): Likewise.
1051 (elf64_hppa_size_dynamic_sections): Revise to use
1052 elf64_hppa_mark_milli_and_exported_functions.
1053 (elf64_hppa_finish_dynamic_symbol): Remove code to keep millicode
1054 symbols out of dynamic symbol table.
1055
f5d44ba0
AM
10562002-06-23 Alan Modra <amodra@bigpond.net.au>
1057
bb3fff1e
AM
1058 * Makefile.in: Regenerate.
1059 * libbfd.h: Regenerate.
1060 * bfd-in2.h: Regenerate.
1061 * configure: Regenerate.
1062 * po/SRC-POTFILES.in: Regenerate.
1063
f5d44ba0
AM
1064 * elflink.h: Comment typo fixes.
1065
10662002-06-23 H.J. Lu <hjl@gnu.org>
1067
1068 * elf-bfd.h (elf_link_loaded_list): New structure.
1069 (elf_link_hash_table): Add "loaded".
1070 * elf.c (_bfd_elf_link_hash_table_init): Initialize "loaded".
1071 * elflink.h (elf_link_check_versioned_symbol): New function.
1072 (elf_link_output_extsym): Call elf_link_check_versioned_symbol.
1073
cc36acdf
NC
10742002-06-19 Nick Clifton <nickc@cambridge.redhat.com>
1075
1076 * elflink.h (size_dynamic_sections): If the target does not
f5d44ba0 1077 support an ELF style hash table, return true, indicating that
cc36acdf
NC
1078 nothing needed to be done, rather than false, indicating that the
1079 section's size could not be computed.
1080
4e5ba5b7
DB
10812002-06-18 Dave Brolley <brolley@redhat.com>
1082
1083 From Catherine Moore, Michael Meissner, Dave Brolley:
1084 * po/SRC-POTFILES.in: Add cpu-frv.c and elf32-frv.c
1085 * targets.c: Support bfd_elf32_frv_vec.
1086 * reloc.c: Add FRV relocs.
1087 * configure.in: Add support for bfd-elf32-frv-vec.
1088 * config.bfd (targ_cpu): Add support for frv-*-elf.
1089 * archures.c: Add frv arch and machines.
1090 * Makefile.am (ALL_MACHINES): Add cpu-frv.lo.
1091 (ALL_MACHINES_CFILES): Add cpu-frv.c.
1092 (BFD32_BACKENDS): Add elf32-frv.lo.
1093 (BFD32_BACKENDS_CFILES): Add elf32-frv.c
1094 (cpu-frv.lo): New target.
1095 (elf32-frv.lo): New target.
1096 * cpu-frv.c: New file.
1097 * elf32-frv.c: New file.
1098
7ece0d85
JJ
10992002-06-18 Jakub Jelinek <jakub@redhat.com>
1100
1101 * elfcode.h (elf_object_p): Sanity check eh_shoff == 0 implies
1102 e_shnum == 0.
1103 Only read the first section header if e_shoff is non-zero.
1104 Don't consider e_shstrndx if there are no sections.
1105
57fb03ac
TR
11062002-06-17 Tom Rix <trix@redhat.com>
1107
1108 * elf32-d10v.c (elf_d10v_howto_table): Change R_D10V_10_PCREL_R,
f5d44ba0 1109 R_D10V_10_PCREL_L and R_D10V_18_PCREL to use
57fb03ac
TR
1110 complain_overflow_bitfield.
1111
341ca622
AM
11122002-06-17 Alan Modra <amodra@bigpond.net.au>
1113
767e34d1
AM
1114 * opncls.c (bfd_openr): Remove redundant bfd_set_error.
1115 (bfd_fdopenr): Likewise.
1116 (bfd_openstreamr): Likewise.
1117 (bfd_openw): Likewise.
1118
341ca622
AM
1119 * targets.c: Sort target vecs.
1120 (_bfd_target_vector): Add aix5coff64_vec, bfd_elf32_sh64_vec,
1121 bfd_elf32_sh64l_vec, bfd_elf32_sh64lnbsd_vec,
1122 bfd_elf32_sh64nbsd_vec, bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec,
1123 bfd_elf64_sh64lnbsd_vec, bfd_elf64_sh64nbsd_vec.
1124 * configure.in: Sort target vecs. Add m88kmach3_vec.
1125 * configure: Regenerate.
1126
dfbbae4c
HPN
11272002-06-16 Hans-Peter Nilsson <hp@bitrange.com>
1128
1129 * elf64-mmix.c (bpo_reloc_request_sort_fn): Use member
1130 bpo_reloc_no to break sort order ties, not address of items.
1131
d663e1cd
JL
11322002-06-16 John David Anglin <dave@hiauly1.hia.nrc.ca>
1133
1134 * elf-hppa.h (elf_hppa_final_link): Fix formatting in comment.
1135 Skip excluded sections in determing __gp value.
1136 (elf_hppa_final_link_relocate): Use the symbol's address in
1137 R_PARISC_FPTR64 relocations that don't need an opd entry.
1138 * elf64-hppa.c (allocate_dynrel_entries): Simplify code.
1139 (elf64_hppa_finalize_dynreloc): Likewise.
1140 (elf64_hppa_size_dynamic_sections): Move comments and fix typo.
1141 (elf64_hppa_finish_dynamic_symbol): Break up assert.
1142
a8295218
NC
11432002-06-14 Sergey Grigoriev <serge@leopold.Physik.Uni-Augsburg.DE>
1144
1145 * pei-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Enable 16 byte
1146 alignment for .bss, .data and .text sections so that sse and sse2
1147 code will work.
1148 * pe-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
1149
11502002-06013 J"orn Rennecke <joern.rennecke@superh.com>
5d9b5481
JR
1151
1152 config.bfd: Add support for sh[1234]l*-*-elf* | sh3el*-*-elf*,
1153 sh[1234]*-elf*.
1154
3db4b612
JL
11552002-06-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
1156
2cb69dd3
JL
1157 * elflink.h (elf_bfd_final_link): Improve error handling for missing
1158 dynamic sections.
1159
3db4b612
JL
1160 * elf64-hppa.c (allocate_global_data_opd): We don't need an opd entry
1161 for a symbol that has no output section.
1162 (allocate_dynrel_entries): Correct comment.
1163 (elf64_hppa_finalize_dynreloc): Likewise. Don't create an opd entry
1164 unless we want one.
1165 (elf64_hppa_finalize_opd): Prevent segfault if dyn_h is NULL.
1166 (elf64_hppa_finalize_dlt): Likewise. Prevent segfault for symbols
1167 with no section. Remove unnecessary parentheses.
1168
f3813499
TR
11692002-06-11 Tom Rix <trix@redhat.com>
1170
1171 * coffcode.h (coff_compute_section_file_positions): Add data
1172 section to AIX loader alignment check.
1173
f5d44ba0 1174 * coff-rs6000.c (_bfd_xcoff_mkobject): Set default text section
f3813499
TR
1175 alignment to 4 bytes.
1176 (_bfd_xcoff_copy_private_bfd_data): Use text and data alignment
1177 power accessor macro.
1178 (do_shared_object_padding): Remove invalid assertion.
1179
0ebaf185
RS
11802002-06-10 Richard Sandiford <rsandifo@redhat.com>
1181
1182 * section.c (_bfd_strip_section_from_output): Set SEC_EXCLUDE
1183 for removed output sections.
1184
ebe3e2d1
NC
11852002-06-10 Geoffrey Keating <geoffk@redhat.com>
1186
1187 * merge.c (merge_strings): Use htab_create_alloc with calloc, not
1188 htab_alloc.
1189 * elf-strtab.c (_bfd_elf_strtab_finalize): Likewise.
1190
0b14c2aa
L
11912002-06-08 H.J. Lu <hjl@gnu.org>
1192
1193 * elf.c (copy_private_bfd_data): Don't cast to bfd_size_type to
1194 work around a long long bug in gcc 2.96 on mips.
1195
3c2bfad6
JT
11962002-06-08 Jason Thorpe <thorpej@wasabisystems.com>
1197
1198 * Makefile.am (BFD32_BACKENDS): Add vax1knetbsd.lo.
1199 (BFD32_BACKENDS_CFILES): Add vax1knetbsd.c.
1200 Regenerate dependency lists.
1201 * Makefile.in: Regenerate.
1202 * config.bfd (vax-*-netbsdelf*, vax-*-netbsdaout*): Add
1203 vax1knetbsd_vec to targ_selvecs.
1204 * configure.in: Add vax1knetbsd_vec.
1205 * configure: Regenerate.
1206 * targets.c (_bfd_target_vector): Add vax1knetbsd_vec.
1207 * vax1knetbsd.c: New file.
1208 * vaxnetbsd.c: Update copyright years.
1209 (TARGET_PAGE_SIZE): Set to 0x1000.
1210 (DEFAULT_MID): Set to M_VAX4K_NETBSD.
1211
91149be3
JT
12122002-06-08 Matt Thomas <matt@3am-software.com>
1213
1214 * libaout.h (enum machine_type): Add M_VAX4K_NETBSD.
1215
21e15248
AM
12162002-06-08 Alan Modra <amodra@bigpond.net.au>
1217
1218 * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): Make static.
1219
986b7daa
AM
12202002-06-08 Alan Modra <amodra@bigpond.net.au>
1221
e90b95f6
AM
1222 * Makefile.am: Run "make dep-am".
1223 * Makefile.in: Regenerate.
1224
3f9c735e
AM
1225 * armnetbsd.c: Replace CONST with const.
1226 * corefile.c: Likewise.
1227 * elf32-dlx.c: Likewise.
1228 * elf64-mips.c: Likewise.
1229 * mmo.c: Likewise.
1230 * ns32knetbsd.c: Likewise.
1231
986b7daa
AM
1232 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Check the hash
1233 table is elf64-sparc.
1234
5a659663
TS
12352002-06-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1236
1237 * elfxx-mips.c (_bfd_mips_elf_relocate_section): Simplify code.
1238 Fix RELA addends to get not shifted in the result. Don't do special
1239 handling of R_MIPS_64 for NewABI.
1240
9bab7074
AM
12412002-06-07 Alan Modra <amodra@bigpond.net.au>
1242
1243 * aoutx.h (NAME(aout,slurp_symbol_table)): Use bfd_zmalloc.
1244 (NAME(aout,slurp_reloc_table)): Likewise.
1245 * coff-mips.c (mips_relax_section): Use bfd_zalloc.
1246 * coff-rs6000.c (xcoff_write_armap_big): Use bfd_zmalloc.
1247 (xcoff_write_archive_contents_big): Likewise.
1248 (xcoff_generate_rtinit): Likewise.
1249 (xcoff_generate_rtinit): Likewise, and check error return.
1250 * coff64-rs6000.c (xcoff64_generate_rtinit): Likewise.
1251 * coffgen.c (coff_section_symbol): Use bfd_zalloc.
1252 (coff_get_normalized_symtab): Likewise.
1253 (coff_make_empty_symbol): Likewise.
1254 (bfd_coff_set_symbol_class): Likewise.
1255 * cofflink.c (coff_link_add_symbols): Likewise.
1256 * ecoff.c (_bfd_ecoff_make_empty_symbol): Likewise.
1257 * ecofflink.c (ecoff_write_shuffle): Use bfd_zmalloc.
1258 (bfd_ecoff_write_accumulated_debug): Likewise.
1259 * elf64-alpha.c (get_got_entry): Use bfd_zalloc.
1260 * i386linux.c (bfd_i386linux_size_dynamic_sections): Likewise.
1261 * i386lynx.c (NAME(lynx,slurp_reloc_table)): Use bfd_zmalloc.
1262 * ieee.c (do_with_relocs): Use bfd_zalloc.
1263 * m68klinux.c (bfd_m68klinux_size_dynamic_sections): Likewise.
1264 * pdp11.c (NAME(aout,slurp_symbol_table)): Use bfd_zmalloc.
1265 (NAME(aout,slurp_reloc_table)): Likewise.
1266 (NAME(aout,squirt_out_relocs)): Don't memset when zalloc'd.
1267 * reloc16.c (bfd_coff_reloc16_relax_section): Use bfd_zmalloc.
1268 * som.c (som_build_and_write_symbol_table): Likewise.
1269 (som_slurp_string_table): Likewise.
1270 (som_slurp_symbol_table): Likewise.
1271 (som_bfd_ar_write_symbol_stuff): Likewise.
1272 * sparclinux.c (bfd_sparclinux_size_dynamic_sections): Use bfd_zalloc.
1273 * sunos.c (bfd_sunos_size_dynamic_sections): Likewise.
1274 * tekhex.c (find_chunk): Likewise. Get rid of unused "sname".
1275 * vms-gsd.c (_bfd_vms_slurp_gsd): Use bfd_zmalloc.
1276 * xcofflink.c (xcoff_link_add_symbols): Use bfd_zalloc/bfd_zmalloc.
1277
1126897b
AM
12782002-06-07 Alan Modra <amodra@bigpond.net.au>
1279
1280 * elf-bfd.h (struct bfd_elf_section_data <group_name>): Replace with
1281 "group" union.
1282 (elf_group_name): Update.
1283 (elf_group_id): Define.
1284 (bfd_elf_set_group_contents): Declare.
1285 * elf.c (elf_fake_sections): Qualify use of elf_group_name.
1286 (set_group_contents): Rename to bfd_elf_set_group_contents. Remove
1287 ATTRIBUTE_UNUSED from failedptrarg. If elf_group_id is set, use
1288 that sym for the signature.
1289 (_bfd_elf_compute_section_file_positions): Don't call
1290 set_group_contents for "ld -r" case.
1291 (swap_out_syms): Use bfd_zalloc.
1292 * elflink.h (elf_link_add_archive_symbols): Likewise.
1293 (NAME(bfd_elf,size_dynamic_sections)): Likewise.
1294 (elf_bfd_final_link): Call bfd_elf_set_group_contents.
1295
3fad3c7c
AM
12962002-06-07 Alan Modra <amodra@bigpond.net.au>
1297
1298 * elf64-ppc.c (ppc64_elf_relocate_section): Allow unresolved
1299 relocs in opd for non-shared too.
1300
76f99c63
JL
13012002-06-06 Jeffrey Law <law@redhat.com
1302
1303 * elf32-h8300.c (elf32_h8_relax_section): Ignore uninteresting
1304 relocations.
1305
7217313c
NC
13062002-06-06 Nick Clifton <nickc@cambridge.redhat.com>
1307
1308 * merge.c: Include libiberty.h.
1309 * elf-strtab.c: Include libiberty.h.
1310
6cb22815
AM
13112002-06-06 Elias Athanasopoulos <eathan@otenet.gr>
1312
1313 * peXXigen.c (pe_print_idata): Remove unused variable.
1314
1ed89aa9
NC
13152002-06-06 David Heine <dlheine@tensilica.com>
1316
1317 * elf.c (assign_file_positions_for_segments): Remove unallocated
1318 sections from the section to segment mapping for PT_LOAD segments.
1319 Update comment about empty loadable segments.
1320
644c4c80
RS
13212002-06-06 Richard Sandiford <rsandifo@redhat.com>
1322
1323 * stabs.c (_bfd_link_section_stabs): Check that the symbol offset
1324 is within the .stabstr section.
1325
f8ecb12b
AM
13262002-06-06 Alan Modra <amodra@bigpond.net.au>
1327
1328 * elf-bfd.h (struct elf_size_info <swap_symbol_in>): Function args
1329 are "const PTR", not "const PTR *".
1330 (bfd_elf32_swap_symbol_in): Likewise.
1331 (bfd_elf64_swap_symbol_in): Likewise.
1332 * elfcode.h (elf_swap_symbol_in): Change input args to const PTR.
1333 (elf_slurp_symbol_table): Adjust call to elf_swap_symbol_in.
1334 * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
1335 (elf_link_add_object_symbols): Likewise.
1336 (elf_link_record_local_dynamic_symbol): Likewise.
1337 (elf_link_input_bfd): Likewise.
1338 (elf_gc_mark): Likewise.
1339 (elf_reloc_symbol_deleted_p): Likewise.
1340 * elf-m10200.c (mn10200_elf_relax_section): Likewise.
1341 (mn10200_elf_relax_delete_bytes): Likewise.
1342 (mn10200_elf_symbol_address_p): Likewise.
1343 (mn10200_elf_get_relocated_section_contents): Likewise.
1344 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
1345 (mn10300_elf_relax_section): Likewise.
1346 (mn10300_elf_relax_delete_bytes): Likewise.
1347 (mn10300_elf_symbol_address_p): Likewise.
1348 (mn10300_elf_get_relocated_section_contents): Likewise.
1349 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
1350 (elf32_h8_relax_delete_bytes): Likewise.
1351 (elf32_h8_symbol_address_p): Likewise.
1352 (elf32_h8_get_relocated_section_contents): Likewise.
1353 * elf32-hppa.c (get_local_syms): Likewise.
1354 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
1355 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
1356 * elf32-sh.c (sh_elf_relax_section): Likewise.
1357 (sh_elf_relax_delete_bytes): Likewise.
1358 (sh_elf_get_relocated_section_contents): Likewise.
1359 * elf32-xstormy16.c (xstormy16_elf_relax_section): Likewise.
1360 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
1361 * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
1362 * elf64-mmix.c (mmix_elf_relax_section): Likewise.
1363 * elf64-ppc.c (get_local_syms): Likewise.
1364 * elf64-sh64.c (sh_elf64_get_relocated_section_contents): Likewise.
1365 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
1366
1ed89aa9 13672002-06-05 J"orn Rennecke <joern.rennecke@superh.com>
7a33bc10
JR
1368
1369 * config.bfd (sh64l*-*-elf*, shl*-*-elf*): New configurations.
1370
73ff0d56
AM
13712002-06-05 Alan Modra <amodra@bigpond.net.au>
1372
9dce4196
AM
1373 * elf.c (group_signature): Swap in the whole symbol, and handle
1374 extracting section symbol names.
1375 (setup_group): Add comment.
1376 (set_group_contents): When called from objcopy or ld, arrange for
1377 section contents to be written. Write group member output section
1378 indices to allow objcopy to reorganize sections.
1379 (_bfd_elf_copy_private_section_data): Copy group info.
1380
73ff0d56
AM
1381 * elf-bfd.h (struct elf_size_info): Add swap_symbol_in field.
1382 (bfd_elf32_swap_symbol_in): Update prototype.
1383 (bfd_elf64_swap_symbol_in): Likewise.
1384 * elfcode.h (elf_swap_symbol_in): Change input args to const PTR *.
1385 (elf_slurp_symbol_table): Adjust call to elf_swap_symbol_in.
1386 * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
1387 (elf_link_add_object_symbols): Likewise.
1388 (elf_link_record_local_dynamic_symbol): Likewise.
1389 (elf_link_input_bfd): Likewise.
1390 (elf_gc_mark): Likewise.
1391 (elf_reloc_symbol_deleted_p): Likewise.
1392 * elf-m10200.c (mn10200_elf_relax_section): Likewise.
1393 (mn10200_elf_relax_delete_bytes): Likewise.
1394 (mn10200_elf_symbol_address_p): Likewise.
1395 (mn10200_elf_get_relocated_section_contents): Likewise.
1396 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
1397 (mn10300_elf_relax_section): Likewise.
1398 (mn10300_elf_relax_delete_bytes): Likewise.
1399 (mn10300_elf_symbol_address_p): Likewise.
1400 (mn10300_elf_get_relocated_section_contents): Likewise.
1401 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
1402 (elf32_h8_relax_delete_bytes): Likewise.
1403 (elf32_h8_symbol_address_p): Likewise.
1404 (elf32_h8_get_relocated_section_contents): Likewise.
1405 * elf32-hppa.c (get_local_syms): Likewise.
1406 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
1407 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
1408 * elf32-sh.c (sh_elf_relax_section): Likewise.
1409 (sh_elf_relax_delete_bytes): Likewise.
1410 (sh_elf_get_relocated_section_contents): Likewise.
1411 * elf32-xstormy16.c (xstormy16_elf_relax_section): Likewise.
1412 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
1413 * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
1414 * elf64-mmix.c (mmix_elf_relax_section): Likewise.
1415 * elf64-ppc.c (get_local_syms): Likewise.
1416 * elf64-sh64.c (sh_elf64_get_relocated_section_contents): Likewise.
1417 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
1418 * elfcode.h (NAME(_bfd_elf,size_info)): Update initialiser.
1419 * elf64-alpha.c (alpha_elf_size_info): Likewise.
1420 * elf64-hppa.c (hppa64_elf_size_info): Likewise.
1421 * elf64-mips.c (mips_elf64_size_info): Likewise.
1422 * elf64-s390.c (s390_elf64_size_info): Likewise.
1423 * elf64-sparc.c (sparc64_elf_size_info): Likewise.
1424
53bfd6b4
MR
14252002-06-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
1426
1427 * elf32-mips.c (elf32_mips_ignore_discarded_relocs): Move to...
1428 elfxx-mips.c (_bfd_mips_elf_ignore_discarded_relocs): ... here.
1429 elf64-mips.c (elf_backend_ignore_discarded_relocs): Use
1430 _bfd_mips_elf_ignore_discarded_relocs.
1431 elfxx-mips.h (_bfd_mips_elf_ignore_discarded_relocs): Declare.
1432
d4df96e6
L
14332002-06-05 H.J. Lu <hjl@gnu.org>
1434
1435 * elfxx-mips.c (mips_elf_calculate_relocation): Call
1436 _bfd_elf_rel_local_sym for STT_SECTION relocations against
1437 the SEC_MERGE section.
1438
e61463e1
AM
14392002-06-05 Alan Modra <amodra@bigpond.net.au>
1440
3cac74d0
AM
1441 * coff-alpha.c: Update copyright date.
1442 * coff-mips.c: Likewise.
1443 * xcoff-target.h: Likewise.
1444
e61463e1
AM
1445 * bfd-in.h: Remove "taken from the source" comment.
1446 * libbfd-in.h: Likewise.
1447 * libcoff-in.h: Likewise.
1448 * bfd-in2.h: Regenerate.
1449 * libbfd.h: Regenerate.
1450 * libcoff.h: Regenerate.
1451
1452 * elf.c (bfd_elf_discard_group): Return true.
1453 * elf-bfd.h (bfd_elf_discard_group): Declare.
1454 * bfd-in.h (bfd_elf_discard_group): Don't declare here.
1455 * section.c (bfd_discard_group): Rename to bfd_generic_discard_group.
1456 * bfd.c (bfd_discard_group): Define.
1457 * targets.c (struct bfd_target): Add _bfd_discard_group.
1458 (BFD_JUMP_TABLE_LINK): Here too.
1459 * libbfd-in.h (_bfd_nolink_bfd_discard_group): Define.
1460 * aout-adobe.c (aout_32_bfd_discard_group): Define.
1461 * aout-target.h (MY_bfd_discard_group): Define.
1462 * aout-tic30.c (MY_bfd_discard_group): Define.
1463 * binary.c (binary_bfd_discard_group): Define.
1464 * bout.c (b_out_bfd_discard_group): Define.
1465 * coff-alpha.c (_bfd_ecoff_bfd_discard_group): Define.
1466 * coffcode.h (coff_bfd_discard_group): Define.
1467 * coff-mips.c (_bfd_ecoff_bfd_discard_group): Define.
1468 * elfxx-target.h (bfd_elfNN_bfd_discard_group): Define.
1469 * i386msdos.c (msdos_bfd_discard_group): Define.
1470 * i386os9k.c (os9k_bfd_discard_group): Define.
1471 * ieee.c (ieee_bfd_discard_group): Define.
1472 * ihex.c (ihex_bfd_discard_group): Define.
1473 * mmo.c (mmo_bfd_discard_group): Define.
1474 * nlm-target.h (nlm_bfd_discard_group): Define.
1475 * oasys.c (oasys_bfd_discard_group): Define.
1476 * ppcboot.c (ppcboot_bfd_discard_group): Define.
1477 * som.c (som_bfd_discard_group): Define.
1478 * srec.c (srec_bfd_discard_group): Define.
1479 * tekhex.c (tekhex_bfd_discard_group): Define.
1480 * versados.c (versados_bfd_discard_group): Define.
1481 * vms.c (vms_bfd_discard_group): Define.
1482 * xcoff-target.h (_bfd_xcoff_bfd_discard_group): Define.
1483 * coff64-rs6000.c (rs6000coff64_vec): Update initialiser.
1484 (aix5coff64_vec): Likewise.
1485 * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Likewise.
1486
9cba27b2
JT
14872002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
1488
1489 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64-com.lo.
1490 (BFD32_BACKENDS_CFILES): Add elf32-sh64-com.c.
1491 (elf32-sh64-com.lo): New dependency list.
1492 * Makefile.in: Regenerate.
1493 * configure.in (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec)
1494 (bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec): Add
1495 elf32-sh64-com.lo.
1496 * configure: Regenerate.
1497 * elf32-sh64.c (sh64_address_in_cranges)
1498 (sh64_get_contents_type, sh64_address_is_shmedia): Move to...
1499 (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb):
1500 (crange_bsearch_cmpl): Prepend _bfd_sh64_ to name and move to...
1501 * elf32-sh64-com.c: ...here. New file.
1502
8d2c33be
AM
15032002-06-04 Alan Modra <amodra@bigpond.net.au>
1504
1505 * elf32-openrisc.c (openrisc_elf_gc_mark_hook): Remove
1506 ATTRIBUTE_UNUSED on used params.
1507 * elf32-vax.c (elf_vax_gc_mark_hook): Remove unnecessary checks
1508 before calling bfd_section_from_elf_index on local syms.
1509 * elf64-sh64.c (sh_elf64_gc_mark_hook): Likewise.
1510
5b0e55b6
JT
15112002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
1512
1513 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64-nbsd.lo.
1514 (BFD32_BACKENDS_CFILES): Add elf32-sh64-nbsd.c.
1515 (BFD64_BACKENDS): Add elf64-sh64-nbsd.lo.
1516 (BFD64_BACKENDS_CFILES): Add elf64-sh64-nbsd.c.
1517 (elf32-sh64-nbsd.lo, elf64-sh64-nbsd.lo): New rules.
1518 * Makefile.in: Regenerate.
1519 * config.bfd (sh5le-*-netbsd*, sh5-*-netbsd*, sh64le-*-netbsd*)
1520 (sh64-*-netbsd*): New targets.
1521 * configure.in: Add bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec,
1522 bfd_elf64_sh64nbsd_vec, and bfd_elf64_sh64lnbsd_vec.
1523 * configure: Regenerate.
1524 * elf32-sh64-nbsd.c: New file.
1525 * elf64-sh64-nbsd.c: New file.
1526 * targets.c: Add extern decls for bfd_elf32_sh64nbsd_vec,
1527 bfd_elf32_sh64lnbsd_vec, bfd_elf64_sh64nbsd_vec, and
1528 bfd_elf64_sh64lnbsd_vec.
1529
b885599b
AM
15302002-06-04 Alan Modra <amodra@bigpond.net.au>
1531
1532 * elf.c (setup_group): Set SEC_LINK_ONCE on GRP_COMDAT groups.
1533 (bfd_section_from_shdr): Likewise. Set section name of group
1534 sections from signature.
1535 (group_signature): Split out from setup_group. Ensure symbol table
1536 is available.
1537 (bfd_elf_discard_group): New function.
1538 (_bfd_elf_make_section_from_shdr): Don't set SEC_LINK_ONCE on
1539 .gnu.linkonce* sections if they are members of a group.
1540 (set_group_contents): Set GRP_COMDAT flag.
1541 * section.c (bfd_discard_group): New function.
1542 * bfd-in.h (bfd_elf_discard_group): Declare.
1543 * bfd-in2.h: Regenerate.
1544 * elf-bfd.h (struct bfd_elf_section_data): Add linkonce_p field.
1545 (elf_linkonce_p): Define.
1546
90937f86
AM
15472002-06-04 Alan Modra <amodra@bigpond.net.au>
1548
1549 * elf.c (bfd_section_from_shdr): Make "name" const.
1550 * elf-bfd.h (elf_backend_section_from_shdr): Likewise.
1551 * elf32-i370.c (i370_elf_section_from_shdr): Likewise.
1552 * elf32-ppc.c (ppc_elf_section_from_shdr): Likewise.
1553 * elf32-sh64.c (sh64_backend_section_from_shdr): Likewise.
1554 * elf32-v850.c (v850_elf_section_from_shdr): Likewise.
1555 * elf64-alpha.c (elf64_alpha_section_from_shdr): Likewise.
1556 * elf64-hppa.c (elf64_hppa_section_from_shdr): Likewise.
1557 * elf64-ppc.c (ppc64_elf_section_from_shdr): Likewise.
1558 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Likewise.
1559 * elfxx-mips.c (_bfd_mips_elf_section_from_shdr): Likewise.
1560 * elfxx-mips.h (_bfd_mips_elf_section_from_shdr): Likewise.
1561
cf6fb9ce
MR
15622002-06-03 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
1563
1564 * elfxx-mips.c (ABI_64_P): Use backend's data to determine the
1565 ABI.
1566
cedb70c5
KH
15672002-06-02 Kazu Hirata <kazu@cs.umass.edu>
1568
1569 * elf32-arc.c: Fix formatting.
1570 * elf32-arm.h: Likewise.
1571 * elf32-cris.c: Likewise.
1572 * elf32-dlx.c: Likewise.
1573 * elf32-hppa.c: Likewise.
1574 * elf32-i386.c: Likewise.
1575 * elf32-i386qnx.c: Likewise.
1576 * elf32-or32.c: Likewise.
1577 * elf32-s390.c: Likewise.
1578 * elf32-sh64.c: Likewise.
1579 * elf32-vax.c: Likewise.
1580 * elf32-xstormy16.c: Likewise.
1581 * elf64-alpha.c: Likewise.
1582 * elf64-mmix.c: Likewise.
1583 * elf64-ppc.c: Likewise.
1584 * elf64-s390.c: Likewise.
1585 * elf64-sh64.c: Likewise.
1586 * elf64-x86-64.c: Likewise.
1587
048d873d
RH
15882002-06-02 Richard Henderson <rth@redhat.com>
1589
1590 * elf64-alpha.c (elf64_alpha_relocate_section): Don't dereference
1591 null when there are no got entries for a symbol.
1592 (elf64_alpha_relax_find_tls_segment): Rearrange to avoid
1593 uninitialized variable warning.
1594
4a67a098
RH
15952002-06-01 Richard Henderson <rth@redhat.com>
1596
1597 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Don't test for
1598 undefined symbols here.
1599 (elf64_alpha_relax_section): Do it here. Also test for not
1600 defined in the current module.
1601 (elf64_alpha_relocate_section_r): Split out of ...
1602 (elf64_alpha_relocate_section): ... here. Don't dereference
1603 NULL when looking up local got entries.
1604
f44f99a5
RH
16052002-06-01 Richard Henderson <rth@redhat.com>
1606
1607 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Reject undefined
1608 symbols from JSR relaxation.
1609 (elf64_alpha_size_plt_section_1): New.
1610 (elf64_alpha_calc_dynrel_sizes): Split out .rela.got bits ...
1611 (elf64_alpha_size_rela_got_1): ... here.
1612 (elf64_alpha_size_dynamic_sections): Split out .rela.got bits ...
1613 (elf64_alpha_size_rela_got_section): ... here.
1614 (elf64_alpha_size_plt_section): New.
1615 (elf64_alpha_relax_section): Call them.
1616 (elf64_alpha_size_got_sections): Remove output_bfd arg.
1617 (elf64_alpha_finish_dynamic_symbol): Check gotent use_count.
1618
9e756d64
RH
16192002-06-01 Richard Henderson <rth@redhat.com>
1620
1621 * elf64-alpha.c (alpha_get_dtprel_base, alpha_get_tprel_base): New.
1622 (elf64_alpha_relocate_section): Use them. Reject LE TLS relocs
1623 in shared libraries. Fix DTPRELHI and TPRELHI value.
1624 (INSN_ADDQ, INSN_RDUNIQ): New.
1625 (struct alpha_relax_info): Add symtab_hdr, tls_segment, first_gotent.
1626 (elf64_alpha_relax_with_lituse): Return boolean. Remove irelend
1627 argument. Reject dynamic symbols. Use LITUSE symbolic constants.
1628 (elf64_alpha_relax_got_load): Rename from relax_without_lituse.
1629 Handle GOTDTPREL and GOTTPREL relocations.
1630 (elf64_alpha_relax_gprelhilo): New.
1631 (elf64_alpha_relax_tls_get_addr): New.
1632 (elf64_alpha_relax_find_tls_segment): New.
1633 (elf64_alpha_relax_section): Handle TLS relocations.
1634 (ALPHA_ELF_LINK_HASH_TLS_IE): New.
1635 (elf64_alpha_check_relocs): Set it.
1636
c853d7f6
RH
16372002-06-01 Richard Henderson <rth@redhat.com>
1638
b646261c
RH
1639 * elf64-alpha.c (elf64_alpha_relax_section): Don't store computed gp.
1640
c853d7f6
RH
1641 * elf64-alpha.c (elf64_alpha_check_relocs): Fix typo on maybe_dynamic
1642 check; don't suppress dynamic relocs for non-allocated sections.
1643
d7e41a96
RH
1644 * elf64-alpha.c: Remove dead code.
1645
5f333394
AM
16462002-05-31 Alan Modra <amodra@bigpond.net.au>
1647
08e0ee05
AM
1648 * bfd-in2.h: Regenerate.
1649 * libbfd.h: Regenerate.
1650 * po/SRC-POTFILES.in: Regenerate.
1651
5f333394
AM
1652 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Don't allocate
1653 space for bss .plt.
1654
caf47ea6
AM
16552002-05-31 Graeme Peterson <gp@qnx.com>
1656
1657 * Makefile.am (BFD32_BACKENDS): Add elf32-i386qnx.lo.
1658 (BFD32_BACKENDS_CFILES): Add elf32-i386qnx.c.
1659 Run "make dep-am".
1660 * Makefile.in: Regenerate.
1661 * config.bfd: Add i[3456]86-*-nto-qnx* support.
1662 * configure.in: Add bfd_elf32_i386qnx_vec support.
1663 * configure: Regenerate.
1664 * elf-bfd.h (struct elf_backend_data): Add set_nonloadable_filepos,
1665 is_contained_by_filepos, and copy_private_bfd_data_p.
1666 * elf.c (assign_file_positions_for_segments): Call backend
1667 set_nonloadable_filepos. Fix non-K&R call to _bfd_error_handler.
1668 (IS_CONTAINED_BY_FILEPOS): Define.
1669 (INCLUDE_SECTION_IN_SEGMENT): Also test IS_CONTAINED_BY_FILEPOS.
1670 (copy_private_bfd_data): Use IS_CONTAINED_BY_FILEPOS. Typo fix.
1671 Fix non-K&R call to _bfd_error_handler.
1672 (_bfd_elf_copy_private_section_data): Use backend
1673 copy_private_bfd_data_p.
1674 * elf32-i386.c: Don't include elfxx-target.h when
1675 ELF32_I386_C_INCLUDED is defined.
1676 * elf32-i386qnx.c: New QNX elf backend file.
1677 * elfxx-target.h: Add elf_backend_set_nonloadable_filepos,
1678 elf_backend_is_contained_by_filepos, and
1679 elf_backend_do_copy_private_bfd_data.
1680 * targets.c: Add bfd_target bfd_elf32_i386qnx_vec.
1681
5bc56484
AM
16822002-05-31 Alan Modra <amodra@bigpond.net.au>
1683
1684 * elfarm-oabi.c (bfd_elf32_arm_add_glue_sections_to_bfd): Define.
1685 Move other similar defines to start of file.
1686
1b164155
TR
16872002-05-30 Tom Rix <trix@redhat.com>
1688
1689 * coff-rs6000.c (xcoff_rtype2howto): Handle 16 bit R_RBA.
1690 * coff64-rs6000.c (xcoff64_rtype2howto): Same.
1691
3765b1be
RH
16922002-05-30 Richard Henderson <rth@redhat.com>
1693
1694 * elf64-alpha.c (ALPHA_ELF_LINK_HASH_LU_TLSGD,
1695 ALPHA_ELF_LINK_HASH_LU_TLSLDM, ALPHA_ELF_LINK_HASH_LU_FUNC): New.
1696 (ALPHA_ELF_GOT_ENTRY_RELOCS_DONE): Remove.
1697 (ALPHA_ELF_GOT_ENTRY_RELOCS_XLATED): Remove.
1698 (struct alpha_elf_got_entry): Add reloc_type, reloc_done, reloc_xlated.
1699 (struct alpha_elf_obj_tdata): Rename total_got_entries and
1700 n_local_got_entries to total_got_size and local_got_size.
1701 (elf64_alpha_howto, elf64_alpha_reloc_map): Update for TLS relocs.
1702 (alpha_got_entry_size): New.
1703 (elf64_alpha_relax_with_lituse): Use it.
1704 (elf64_alpha_relax_without_lituse): Likewise.
1705 (MAX_GOT_SIZE): Rename from MAX_GOT_ENTRIES.
1706 (get_got_entry): New.
1707 (elf64_alpha_check_relocs): Handle TLS relocs. Reorganize.
1708 (elf64_alpha_adjust_dynamic_symbol): Test LU_FUNC as a mask.
1709 (elf64_alpha_merge_ind_symbols): Check gotent->reloc_type.
1710 (elf64_alpha_can_merge_gots, elf64_alpha_merge_gots): Likewise.
1711 (elf64_alpha_calc_got_offsets_for_symbol): Use alpha_got_entry_size.
1712 (elf64_alpha_calc_got_offsets): Likewise.
1713 (alpha_dynamic_entries_for_reloc): New.
1714 (elf64_alpha_calc_dynrel_sizes): Use it.
1715 (elf64_alpha_size_dynamic_sections): Likewise.
1716 (elf64_alpha_relocate_section): Handle TLS relocations.
1717 * reloc.c: Add Alpha TLS relocations.
1718 * bfd-in2.h, libbfd.h: Rebuild.
1719
5e226794
NC
17202002-05-29 Ralf Habacker <ralf.habacker@freenet.de>
1721
1722 * peXXigen.c (pe_print_idata): Remove double printed
1723 import table lines; add Bound-To comment.
1724
90ace9e9
JT
17252002-05-29 Matt Thomas <matt@3am-software.com>
1726
1727 * Makefile.am (BFD32_BACKENDS): Add elf32-vax.lo.
1728 (BFD32_BACKENDS_CFILES): Add elf32-vax.c.
1729 (elf32-vax.lo): New rule.
1730 * Makefile.in: Regenerate.
1731 * configure.in (bfd_elf32_vax_vec)
1732 (vaxnetbsd_vec): New vectors.
1733 * configure: Regenerate.
1734 * config.bfd (vax-*-netbsdelf*)
1735 (vax-*-netbsdaout*)
1736 (vax-*-netbsd*): New targets.
1737 * elf32-vax.c: New file.
1738 * reloc.c: Add VAX relocations.
1739 * bfd-in2.h: Regenerate.
1740 * targets.c (_bfd_target_vector): Add bfd_elf32_vax_vec.
1741
4a253e81
JT
17422002-05-29 Jason Thorpe <thorpej@wasabisystems.com>
1743
1744 * config.bfd (arm-*-netbsd*): Add bfd_elf32_littlearm_vec
1745 and bfd_elf32_bigarm_vec to targ_selvecs.
1746
6e7c73dd
CF
17472002-05-29 Ralf Habacker <ralf.habacker@freenet.de>
1748
1749 * peXXigen.c (pe_print_idata): Fix seg faults on printing import tables
1750 with auto-imported symbols.
1751
8afb0e02
NC
17522002-05-29 Adam Nemet <anemet@lnxw.com>
1753
1754 * elf32-arm.h (bfd_elf32_arm_get_bfd_for_interworking): Don't add glue
1755 sections only record bfd.
9bab7074 1756 (bfd_elf32_arm_add_glue_sections_to_bfd): New function.
8afb0e02 1757 * bfd-in.h (bfd_elf32_arm_add_glue_sections_to_bfd): Declare it.
9bab7074 1758 * bfd-in2.h: Regenerate.
8afb0e02 1759
a95653f5
NC
17602002-05-28 Nick Clifton <nickc@cambridge.redhat.com>
1761
1762 * syms.c (_bfd_stab_section_find_nearest_line): Move
1763 declaration and initialisation of saw_line and saw_func out of
1764 for loop.
1765
7cdc5bba
AM
17662002-05-29 Alan Modra <amodra@bigpond.net.au>
1767
1768 * elf64-ppc.c (ppc64_elf_get_symbol_info): New function.
1769 (bfd_elf64_get_symbol_info): Define.
1770 * elfxx-target.h (bfd_elfNN_get_symbol_info): Only define if undef.
1771
4c7aad1c
AM
17722002-05-29 Andrey Volkov <avolkov@transas.com>
1773
1774 * cpu-h8300.c: Make default h8300 machine first in machine list.
1775
d172d4ba
NC
17762002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
1777
1778 * config.bfd: Added DLX configuraton.
1779 * Makefile.am: Added DLX configuraton.
1780 * configure.in: Added DLX configuraton.
1781 * archures.c: Add DLX architecure.
1782 * reloc.c: Add DLX relocs.
1783 * targets.c: Added DLX target vector.
1784 * configure: Regenerate.
1785 * Makefile.in: Regenreate.
1786 * bfd-in2.h: Regenreate.
1787 * elf32-dlx.c: New file: Support DLX target.
1788 * cpu-dlx.c: New file: Support DLX target.
1789
d1329ca3
AM
17902002-05-25 Alan Modra <amodra@bigpond.net.au>
1791
428d0de3
AM
1792 * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Formatting.
1793
d1329ca3
AM
1794 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Revert last change.
1795 (ppc64_elf_check_relocs): Don't set up function descriptor symbol
1796 strings to point inside function code sym string.
1797 (func_desc_adjust): Likewise.
1798 (ppc64_elf_hide_symbol): Rewrite code to look up function code sym.
1799
3bab7989
ML
18002002-05-24 Michal Ludvig <mludvig@suse.cz>
1801
1802 * elf64-x86-64.c (elf64_x86_64_grok_prstatus): Added.
1803 (elf64_x86_64_grok_psinfo): Added.
1804
436e8db0
NC
18052002-05-24 TAMURA Kent <kent@netbsd.org>
1806
1807 * config.bfd: Add a target for i386-netbsdpe.
1808
ea1e4b0d
AM
18092002-05-24 Alan Modra <amodra@bigpond.net.au>
1810
1811 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Don't copy is_func
1812 and is_func_descriptor.
1813 (func_desc_adjust): Hide function code sym in shared libs unless
1814 there is a matching exported function descriptor sym.
1815
13ae64f3
JJ
18162002-05-23 Jakub Jelinek <jakub@redhat.com>
1817
1818 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_THREAD_LOCAL
1819 for symbols from SHF_TLS section.
1820 (_bfd_elf_print_private_bfd_data): Add PT_TLS.
1821 (elf_fake_sections): Set SHF_TLS for SEC_THREAD_LOCAL sections.
1822 (map_sections_to_segments): Build PT_TLS segment if necessary.
1823 (assign_file_positions_for_segments): Likewise.
1824 (get_program_header_size): Account for PT_TLS segment.
1825 (swap_out_syms): Set type of BSF_THREAD_LOCAL symbols and symbols from
1826 SEC_THREAD_LOCAL sections to STT_TLS.
1827 * reloc.c: Add 386 and IA-64 TLS relocs.
1828 * section.c (SEC_THREAD_LOCAL): Define.
1829 (SEC_CONSTRUCTOR_TEXT, SEC_CONSTRUCTOR_DATA, SEC_CONSTRUCTOR_BSS):
1830 Remove.
1831 * elflink.h (elf_link_add_object_symbols): Support .tcommon.
1832 (size_dynamic_sections): If DF_STATIC_TLS, set DF_FLAGS
1833 unconditionally.
1834 (struct elf_final_link_info): Add first_tls_sec.
1835 (elf_bfd_final_link): Set first_tls_sec.
1836 Compute elf_hash_table (info)->tls_segment.
1837 (elf_link_output_extsym): Handle STT_TLS symbols.
1838 (elf_link_input_bfd): Likewise.
1839 * syms.c (BSF_THREAD_LOCAL): Define.
1840 * bfd-in2.h: Rebuilt.
1841 * libbfd.h: Rebuilt.
1842 * elf32-i386.c (elf_i386_tls_transition, dtpoff_base, tpoff,
1843 elf_i386_mkobject, elf_i386_object_p): New functions.
1844 (elf_howto_table): Add TLS relocs.
1845 (elf_i386_reloc_type_lookup): Support TLS relocs.
1846 (elf_i386_info_to_howto_rel): Likewise.
1847 (struct elf_i386_link_hash_entry): Add tls_type.
1848 (struct elf_i386_obj_tdata): New.
1849 (elf_i386_hash_entry, elf_i386_tdata, elf_i386_local_got_tls_type):
1850 New macros.
1851 (struct elf_i386_link_hash_table): Add tls_ldm_got.
1852 (link_hash_newfunc): Clear tls_type.
1853 (elf_i386_check_relocs): Support TLS relocs.
1854 (elf_i386_gc_sweep_hook): Likewise.
1855 (allocate_dynrelocs): Likewise.
1856 (elf_i386_size_dynamic_sections): Likewise.
1857 (elf_i386_relocate_section): Likewise.
1858 (elf_i386_finish_dynamic_symbol): Likewise.
1859 (bfd_elf32_mkobject, elf_backend_object_p): Define.
1860 * elfxx-ia64.c (struct elfNN_ia64_dyn_sym_info): Add tprel_offset,
1861 dtpmod_offset, dtprel_offset, tprel_done, dtpmod_done, dtprel_done,
1862 want_tprel, want_dtpmod, want_dtprel.
1863 (elfNN_ia64_tprel_base, elfNN_ia64_dtprel_base): New functions.
1864 (ia64_howto_table): Add TLS relocs, rename R_IA64_LTOFF_TP22 to
1865 R_IA64_LTOFF_TPREL22.
1866 (elf_code_to_howto_index): Add TLS relocs.
1867 (elfNN_ia64_check_relocs): Support TLS relocs.
1868 (allocate_global_data_got): Account for TLS .got data.
1869 (allocate_dynrel_entries): Account for TLS dynamic relocations.
1870 (elfNN_ia64_install_value): Supprt TLS relocs.
1871 (set_got_entry): Support TLS relocs.
1872 (elfNN_ia64_relocate_section): Likewise.
1873
c62e1cc3
NC
18742002-05-23 Nick Clifton <nickc@cambridge.redhat.com>
1875
1876 * elf32-arm.h (elf32_arm_final_link_relocate): For the Thumb
1877 BLX reloc round the relocation up rather than down.
1878 * coff-arm.c (coff_arm_relocate_section): Likewise.
1879
c5a43a5d
L
18802002-05-21 H.J. Lu (hjl@gnu.org)
1881
1882 * linker.c (_bfd_generic_link_add_one_symbol): Allow multiple
1883 definition.
1884
afbe61cf
AM
18852002-05-22 Alan Modra <amodra@bigpond.net.au>
1886
1887 * elf64-ppc.c (ppc64_elf_size_stubs): Don't strip .branch_lt.
1888 (ppc64_elf_relocate_section): Handle unresolved relocs in opd.
1889
9c07fe7c
AM
18902002-05-22 Alan Modra <amodra@bigpond.net.au>
1891
1892 * elf64-ppc.c (ppc64_elf_relocate_section): Return false for
1893 unresolved relocs.
1894 (ppc64_elf_size_dynamic_sections): Check for splt NULL.
1895
21611032
TS
18962002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1897
1898 * bfd/bfd.c (bfd_get_arch_size): Remove bfd_set_error call for
1899 non-ELF targets.
1900
41241523
TS
19012002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1902
1903 * elf-bfd.h (elf_backend_emit_relocs): Change prototype to return
1904 an error value.
1905 * elflink.h (elf_link_output_relocs): Likewise. Improve error message.
1906 return with false on error.
1907 (elf_link_input_bfd): Check reloc_emitter return value.
1908
658f2588
JT
19092002-05-21 Jason Thorpe <thorpej@wasabisystems.com>
1910
1911 * config.bfd (armeb-*-netbsdelf*): New target.
1912
c862ae31
AM
19132002-05-20 Alan Modra <amodra@bigpond.net.au>
1914
1915 * elf64-ppc.c (ppc_build_one_stub): Point undefined function syms
1916 at the plt call stub.
1917
6dd14845
TS
19182002-05-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1919
1920 * cpu-mips.c (mips_compatible): Don't try to check machine
1921 compatibility.
1922
a58d9c34
TR
19232002-05-18 Tom Rix <trix@redhat.com>
1924
1925 * coff64-rs6000.c (_bfd_xcoff64_swap_aux_out): Fix C_FILE auxent.
1926
ef60b7ff
AM
19272002-05-17 Alan Modra <amodra@bigpond.net.au>
1928
1929 * elf64-ppc.c (ppc64_elf_info_to_howto): Formatting.
1930 (ppc64_elf_relocate_section): Don't warn about reloc overflow when
1931 we've already warned about an undefined symbol. Report more
1932 detail on reloc errors.
1933
a703a6ea
AM
19342002-05-17 Alan Modra <amodra@bigpond.net.au>
1935
1936 * acinclude.m4 (AM_INSTALL_LIBBFD): New.
1937 * configure.in: Invoke AM_INSTALL_LIBBFD.
1938 * Makefile.am (install-data-local): Revert 2002-05-13. Move to..
1939 (install_libbfd): .. New target.
1940 (uninstall_libbfd): Likewise.
1941 (install-bfdlibLTLIBRARIES): Likewise.
1942 (uninstall-bfdlibLTLIBRARIES): Likewise.
1943 (bfdlibdir): New.
1944 (bfdincludedir): New.
1945 (lib_LTLIBRARIES): Rename to bfdlib_LTLIBRARIES.
1946 * aclocal.m4: Regenerate.
1947 * configure: Regenerate.
1948 * Makefile.in: Regenerate.
1949
2c13d98b
NC
19502002-05-17 Stuart Balfour <sbalfour@cisco.com>
1951
1952 * hash.c (bfd_hash_lookup): Remove computation of len from inside
1953 hash loop.
1954
629936c5
NC
19552002-05-16 Nick Clifton <nickc@cambridge.redhat.com>
1956
1957 * config.bfd: Add targets for sh64-linux (little endian and
1958 big endian).
1959
e4cf60a8
NC
19602002-05-15 Laurent Pinchart <laurent.pinchart@skynet.be>
1961
1962 * peXXigen.c (pe_print_idata): Do not assume that the first thunk
1963 is located in the same section as the import table. Instead
1964 check, and if necessary load the section containing the thunk.
1965
d1e66cd4
NC
19662002-05-15 Nick Clifton <nickc@cambridge.redhat.com>
1967
1968 * aix5ppc-core.c (xcoff64_core_p): Replace bfd_read with
ea1e4b0d
AM
1969 bfd_bread.
1970 (xcoff64_core_file_matches_executable_p): Replace bfd_read
1971 with bfd_bread.
d1e66cd4 1972
2d653fc7
AM
19732002-05-15 Alan Modra <amodra@bigpond.net.au>
1974
1975 * aix5ppc-core.c: Warning fixes.
1976 * aout-adobe.c (aout_32_bfd_link_just_syms): Define.
1977 * aout-target.h (MY_bfd_link_just_syms): Define.
1978 * aout-tic30.c (MY_bfd_link_just_syms): Define.
1979 * bfd.c (bfd_link_just_syms): Define.
1980 * binary.c (binary_bfd_link_just_syms): Define.
1981 * bout.c (b_out_bfd_link_just_syms): Define.
1982 * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Update initializer.
1983 * coff64-rs6000.c (rs6000coff64_vec, aix5coff64_vec): Likewise.
1984 * coffcode.h (coff_bfd_link_just_syms): Define.
1985 * elf-bfd.h (enum elf_link_info_type): Add ELF_INFO_TYPE_JUST_SYMS.
1986 (elf_discarded_section): Check for ELF_INFO_TYPE_JUST_SYMS.
1987 (_bfd_elf_link_just_syms): Declare.
1988 * elf.c (_bfd_elf_link_just_syms): New function.
1989 * elf-eh-frame.c (_bfd_elf_maybe_strip_eh_frame_hdr): Check that
1990 sections haven't already been discarded by the linker.
1991 * elflink.h (elf_link_add_object_symbols): Likewise for stab
1992 sections and SEC_MERGE sections.
1993 (elf_bfd_discard_info): Similarly here.
1994 * elfxx-target.h (bfd_elfNN_bfd_link_just_syms): Define.
1995 * i386msdos.c (msdos_bfd_link_just_syms): Define.
1996 * i386os9k.c (os9k_bfd_link_just_syms): Define.
1997 * ieee.c (ieee_bfd_link_just_syms): Define.
1998 * ihex.c (ihex_bfd_link_just_syms): Define.
1999 * libbfd-in.h (_bfd_nolink_bfd_link_just_syms): Define.
2000 (_bfd_generic_link_just_syms): Declare.
2001 * libecoff.h (_bfd_ecoff_bfd_link_just_syms): Define.
2002 * linker.c (_bfd_generic_link_just_syms): New function.
2003 * mmo.c (mmo_bfd_link_just_syms): Define.
2004 * nlm-target.h (nlm_bfd_link_just_syms): Define.
2005 * oasys.c (oasys_bfd_link_just_syms): Define.
2006 * ppcboot.c (ppcboot_bfd_link_just_syms): Define.
2007 * som.c (som_bfd_link_just_syms): Define.
2008 * srec.c (srec_bfd_link_just_syms): Define.
2009 * targets.c (struct bfd_target): Add _bfd_link_just_syms.
2010 (BFD_JUMP_TABLE_LINK): And here.
2011 * tekhex.c (tekhex_bfd_link_just_syms): Define.
2012 * versados.c (versados_bfd_link_just_syms): Define.
2013 * vms.c (vms_bfd_link_just_syms): Define.
2014 * libbfd.h: Regenerate.
2015 * bfd-in2.h: Regenerate.
2016
cb7394f2
TS
20172002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2018
2019 * elf32-mips.c: Remove superfluous definitions copied from
2020 elfxx-mips.c.
2021 (bfd_elf32_bigmips_vec,bfd_elf32_littlemips_vec): Use the
2022 SGIish vectors to check the special case.
2023 (mips_elf_hi16_reloc): Fix comment.
2024 (mips_elf_got16_reloc): Likewise.
2025 (_bfd_mips_elf32_gprel16_reloc): Likewise.
2026 (elf_reloc_map): Code cleanup.
2027 (mips_reloc_map): Add comment.
2028 (bfd_elf23_bfd_reloc_type_lookup): Code cleanup.
2029 (mips_elf32_rtype_to_howto): Likewise.
2030 (mips_elf32_discard_info): Likewise.
2031 (elf32_mips_irix_compat): Invert logic: Only SGIish vectors
2032 lead to IRIX compatibility now.
2033
8dc1a139
TS
20342002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2035
2036 * elfxx-mips.c: Call it IRIX, not Irix in comments.
2037
2051e1b5
JT
20382002-05-13 Jason Thorpe <thorpej@wasabisystems.com>
2039
2040 * config.bfd (shle-*-netbsdelf*): Add target which includes
2041 sh64 support.
2042
83954261
AM
20432002-05-13 David Edelsohn <edelsohn@gnu.org>
2044
2045 * configure.in: Revert 2002-04-07. Instead, auto-configure
2046 HAVE_ST_C_IMPL.
2047 * configure: Regenerate.
2048 * config.in: Regenerate.
2049 * rs6000-core.c (CNEW_IMPL): Guard use of c_impl with HAVE_ST_C_IMPL
2050 or AIX_5_CORE.
2051
a9bf1154
NC
20522002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
2053
2054 * configure.in (sparc*-*-openbsd*): Support sparc64-openbsd
2055 corefiles as well.2
2056 * configure: Regenerate.
2057
3129eb7a
AM
20582002-05-13 Alan Modra <amodra@bigpond.net.au>
2059
2060 * Makefile.am (install-data-local): Install headers to
2061 $(exec_prefix)/include.
2062 * Makefile.in: Regenerate.
2063
a9a32010
DJ
20642002-05-11 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
2065 Daniel Jacobowitz <drow@mvista.com>
2066
2067 * coff-sh.c (sh_reloc_map): Map to R_SH_IMM32 for non-PE. Don't
2068 map BFD_RELOC_RVA.
2069
20702002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
690cc98b
NC
2071
2072 * config.bfd (alpha*-*-openbsd*, sparc64*-*-openbsd*,
2073 hppa*-*-openbsd*): New targets.
2074 * configure.in (alpha*-*-openbsd*): Set COREFILE.
2075 * configure: Regenerate.
2076
f1f0d9ab
TR
20772002-05-10 Tom Rix <trix@redhat.com>
2078
ea1e4b0d 2079 * coff64-rs6000.c (xcoff64_reloc_type_br): New function for
f1f0d9ab
TR
2080 xcoff64_ppc_relocate_section.
2081 * coff-rs6000.c : Extern common xcoff_reloc_type functions.
2082 * libxcoff.h: Common xcoff_reloc_type function declaration.
2083
c432ba1a
AM
20842002-05-10 Alan Modra <amodra@bigpond.net.au>
2085
16a10388 2086 * elf32-i386.c (elf_i386_relocate_section): Remove overflow checks
90937f86 2087 added in 2002-05-09 commit.
16a10388 2088
c432ba1a
AM
2089 * elf32-hppa.c (elf32_hppa_size_stubs): Revert part of 2002-05-04,
2090 don't look for stubs on all undefined syms.
2091
4a335f3d
AM
20922002-05-09 Alan Modra <amodra@bigpond.net.au>
2093
8fc39d5d
AM
2094 * elf64-ppc.c (RA_REGISTER_MASK, RA_REGISTER_SHIFT): Delete.
2095 (ppc64_elf_howto_raw <R_PPC64_RELATIVE>): Not pc_relative or
2096 pcrel_offset.
2097
4a335f3d
AM
2098 * elf32-i386.c (elf_howto_table): Comments.
2099 (elf_i386_relocate_section): Handle more relocs for relocatable
2100 linking and against SEC_MERGE sections.
2101
41fcb14e
AM
21022002-05-08 Alan Modra <amodra@bigpond.net.au>
2103
2104 * elf32-ppc.c (ppc_elf_create_got): New function.
2105 (ppc_elf_create_dynamic_sections): Call ppc_elf_create_got before
ea1e4b0d 2106 _bfd_elf_create_dynamic_sections. Correct .plt flags.
41fcb14e
AM
2107 (ppc_elf_check_relocs): Use ppc_elf_create_got in place of
2108 _bfd_elf_create_got_section.
2109
b491616a
AM
21102002-05-07 Alan Modra <amodra@bigpond.net.au>
2111
2112 * elf-bfd.h (struct elf_backend_data): Add rela_normal.
2113 * elfxx-target.h (elf_backend_rela_normal): Define.
2114 (elfNN_bed): Init rela_normal.
2115 * elflink.h (elf_link_input_bfd <emit_relocs>): Handle adjustment
2116 for section symbols here if rela_normal. Simplify abs section test.
2117 * elf-m10200.c (mn10200_elf_relocate_section): If relocatable,
2118 return immediately. Remove code handling relocatable linking.
2119 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
2120 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
2121 * elf32-i370.c (i370_elf_relocate_section): Likewise.
2122 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
2123 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
2124 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
2125 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
2126 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
2127 * elf32-s390.c (elf_s390_relocate_section): Likewise.
2128 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
2129 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
2130 * elf64-s390.c (elf_s390_relocate_section): Likewise.
2131 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
2132 * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
2133 * elf32-arm.h (elf32_arm_relocate_section): Likewise #ifndef USE_REL.
2134 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
2135 * elf-m10200.c (elf_backend_rela_normal): Define.
2136 * elf-m10300.c (elf_backend_rela_normal): Define.
2137 * elf32-fr30.c (elf_backend_rela_normal): Define.
2138 * elf32-i370.c (elf_backend_rela_normal): Define.
2139 * elf32-i860.c (elf_backend_rela_normal): Define.
2140 * elf32-m68k.c (elf_backend_rela_normal): Define.
2141 * elf32-mcore.c (elf_backend_rela_normal): Define.
2142 * elf32-openrisc.c (elf_backend_rela_normal): Define.
2143 * elf32-ppc.c (elf_backend_rela_normal): Define.
2144 * elf32-s390.c (elf_backend_rela_normal): Define.
2145 * elf32-xstormy16.c (elf_backend_rela_normal): Define.
2146 * elf64-ppc.c (elf_backend_rela_normal): Define.
2147 * elf64-s390.c (elf_backend_rela_normal): Define.
2148 * elf64-x86-64.c (elf_backend_rela_normal): Define.
2149 * elfxx-ia64.c (elf_backend_rela_normal): Define.
2150 * elf32-arm.h (elf_backend_rela_normal): Define #ifndef USE_REL.
2151 * elf32-m32r.c (elf_backend_rela_normal): Likewise.
2152
df212a7e
NC
21532002-05-06 Nick Clifton <nickc@cambridge.redhat.com>
2154
2155 * elf32-arm.h (elf32_arm_final_link_relocate): Convert
2156 'reloc_signed_max' and 'reloc_signed_min' into half-word offsets.
2157
3decf53c
AM
21582002-05-06 Alan Modra <amodra@bigpond.net.au>
2159
2160 * elflink.h (elf_link_input_bfd <emit_relocs>): Adjust r_offset
2161 when not relocatable. Fix reloc_emitter call for K&R.
2162
f46c2da6
AM
21632002-05-04 Alan Modra <amodra@bigpond.net.au>
2164
2165 * elf64-ppc.c (ppc64_elf_relocate_section): Reinstate code
2166 reloading local sym addend mistakenly removed in 2002-05-01 change.
2167
2168 * dwarf2.c (struct line_head): Make prologue_length a bfd_vma.
2169 (read_abbrevs): Change "offset" param to bfd_vma.
2170 (parse_comp_unit): Change "version" and addr_size to unsigned ints.
2171 Change "abbrev_offset" to bfd_vma.
2172 (read_indirect_string): Use correct conversion chars in error
2173 message format string, cast bfd_vma's to unsigned long.
2174 (read_abbrevs): Likewise.
2175 (read_attribute_value): Likewise.
2176 (decode_line_info): Likewise.
2177 (scan_unit_for_functions): Likewise.
2178 (parse_comp_unit): Likewise.
2179
59862849
TR
21802002-05-04 Tom Rix <trix@redhat.com>
2181
2182 * coffswap.h (coff_swap_reloc_in): Remove XCOFF support.
2183 (coff_swap_reloc_out): Same.
2184 * coff-rs6000.c: (xcoff_swap_reloc_in): Moved from coffswap.h.
2185 (xcoff_swap_reloc_out): Same.
2186 (xcoff_rtype2howto): Renamed from _bfd_xcoff_rtype2howto. Special
2187 case some 16 bit relocs. Add reloc value to output.
2188 (xcoff_howto_table): Remove 64 bit R_POS, add 16 bit
ea1e4b0d 2189 R_RBR. Improve names.
59862849
TR
2190 (_bfd_xcoff_reloc_type_lookup): Adjust for removal of 64 bit R_POS.
2191 (bfd_xcoff_backend_data): Update with new reloc swap names.
2192 (bfd_pmac_xcoff_backend_data) : Same.
2193 * coff64-rs6000.c: (xcoff64_swap_reloc_in): Moved from coffswap.h.
2194 (xcoff64_swap_reloc_out): Same.
ea1e4b0d 2195 (xcoff64_rtype2howto): Special case some 16 bit relocs and 32 bit
59862849 2196 R_POS. Add reloc value to output.
ea1e4b0d
AM
2197 (xcoff64_howto_table): Move 64 bit R_POS to first entry. Add 16
2198 bit R_RBR. Improve names, masks.
59862849
TR
2199 (xcoff64_reloc_type_lookup): Adjust for move of 64 bit R_POS.
2200 (bfd_xcoff_backend_data): Update with new reloc swap names.
2201 (bfd_xcoff_aix5_backend_data) : Same.
2202
b4655ea9
AM
22032002-05-04 Alan Modra <amodra@bigpond.net.au>
2204
2205 * elf32-hppa.c (struct elf32_hppa_link_hash_table): Add
2206 bfd_count top_index, input_list, all_local_syms.
2207 (elf32_hppa_setup_section_lists): New function, split from
2208 elf32_hppa_size_stubs.
2209 (elf32_hppa_next_input_section): Likewise.
2210 (group_sections): Likewise.
2211 (get_local_syms): Likewise.
2212 (elf32_hppa_size_stubs): Adjust for split out functions. Look for
2213 stubs on undefined syms too.
2214 (elf32_hppa_set_gp): Use bfd_link_hash* instead of elf_link_hash*.
8fc39d5d 2215 Only access htab elf fields when we have an elf hash table.
b4655ea9
AM
2216 * elf32-hppa.h (elf32_hppa_setup_section_lists): Declare.
2217 (elf32_hppa_next_input_section): Declare.
2218
301e3139
AM
22192002-05-04 Bob Byrnes <byrnes@curl.com>
2220
2221 * opncls.c (_bfd_new_bfd_contained_in): Check return value of
2222 _bfd_new_bfd.
2223
7c5fcef7
L
22242002-05-03 H.J. Lu (hjl@gnu.org)
2225
2226 * elfxx-mips.c (mips_elf_link_hash_entry): Add forced_local.
2227 (mips_elf_link_hash_newfunc): Initialize forced_local to false.
2228 (mips_elf_record_global_got_symbol): Call _bfd_mips_elf_hide_symbol
2229 to hide a global symbol.
2230 (_bfd_mips_elf_hide_symbol): Return if forced_local is true. Set
ea1e4b0d 2231 forced_local to true.
7c5fcef7 2232
84de6048
RH
22332002-05-02 Richard Henderson <rth@redhat.com>
2234
2235 * elf64-alpha.c (elf64_alpha_relocate_section): Force relative relocs
2236 vs SHN_UNDEF to zero.
2237
805fc799
AM
22382002-05-02 Alan Modra <amodra@bigpond.net.au>
2239
c061c2d8
AM
2240 * elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_SECTOFF>): Change to a
2241 16 bit reloc.
2242 <R_PPC64_SECTOFF_DS>: Likewise.
2243 (ppc64_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
2244 SECTOFF reloc.
2245 * elf32-ppc.c (ppc_elf_howto_raw <R_PPC_SECTOFF>): Correct.
2246 (ppc_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
2247 SECTOFF reloc.
2248
805fc799
AM
2249 * elf64-ppc.c (ppc64_elf_addr16_ha_reloc): Delete.
2250 (ppc64_elf_ha_reloc): New function.
2251 (ppc64_elf_brtaken_reloc): New function.
2252 (ppc64_elf_sectoff_reloc): New function.
2253 (ppc64_elf_sectoff_ha_reloc): New function.
2254 (ppc64_elf_toc_reloc): New function.
2255 (ppc64_elf_toc_ha_reloc): New function.
2256 (ppc64_elf_toc64_reloc): New function.
2257 (ppc64_elf_unhandled_reloc): New function.
2258 (ppc64_elf_howto_raw): Use the above.
2259 <R_PPC64_RELATIVE>: Mark pc_relative, pcrel_offset.
2260 <R_PPC64_SECTOFF>: Not pc_relative or pcrel_offset. Fix dst_mask.
2261 <R_PPC64_SECTOFF_DS>: Likewise.
2262 (IS_ABSOLUTE_RELOC): Update.
2263 (struct ppc_link_hash_table): Add have_undefweak.
2264 (ppc64_elf_link_hash_table_create): Init.
2265 (func_desc_adjust): Set have_undefweak.
2266 (ppc64_elf_func_desc_adjust): Call func_desc_adjust earlier. Only
2267 add the .sfpr blr when have_undefweak.
2268 (ppc64_elf_setup_section_lists): Check hash table flavour.
2269 (ppc64_elf_next_input_section): Move output_section->owner test to
2270 ppc64elf.em.
2271 (ppc64_elf_set_toc): Rename to ppc64_elf_toc, remove info param
2272 and relocatable test. Return TOCstart and don't set elf_gp.
2273 (ppc64_elf_relocate_section): Correct BRTAKEN/BRNTAKEN branch
2274 offset calculation. Add assert on weak sym branch tweaks.
2275 * elf64-ppc.h (ppc64_elf_set_toc): Delete.
2276 (ppc64_elf_toc): Declare.
2277 (ppc64_elf_next_input_section): Update.
ea1e4b0d 2278
818c39a3
AM
22792002-05-01 Alan Modra <amodra@bigpond.net.au>
2280
2281 * syms.c (_bfd_stab_section_find_nearest_line): Don't bomb on NULL
2282 file_name.
2283
721956f4
AM
22842002-05-01 Alan Modra <amodra@bigpond.net.au>
2285
2286 * elf64-ppc.c (CROR_151515, CROR_313131): Define.
2287 (ppc64_elf_relocate_section): Use them. Don't look for plt calls
2288 on R_PPC64_ADDR24 relocs. Require a nop or no link reg on plt
2289 call branches. Correct undefined weak destination.
2290 (ppc64_elf_func_desc_adjust): Always create at least one blr in
2291 .sfpr, and correct case where either only savef* or restf* is
2292 needed.
2293
2294 Long branch stubs, multiple stub sections.
2295 * elf64-ppc.h (ppc64_elf_setup_section_lists): Declare.
2296 (ppc64_elf_next_input_section): Declare.
2297 * elf64-ppc.c: Move linker-only prototypes.
2298 (STUB_SUFFIX): Define.
2299 (enum ppc_stub_type): New.
2300 (struct ppc_stub_hash_entry): New.
2301 (struct ppc_branch_hash_entry): New.
2302 (struct ppc_link_hash_entry): Add stub_cache, oh.
2303 (struct ppc_link_hash_table): Add stub_hash_table etc. Remove
2304 sstub. Add sbrlt, srelbrlt, has_14bit_branch, stub_iteration.
2305 Rename plt_overflow to stub_error.
2306 (ppc_stub_hash_lookup): Define.
2307 (ppc_branch_hash_lookup): Define.
2308 (stub_hash_newfunc): New function.
2309 (branch_hash_newfunc): New function.
2310 (link_hash_newfunc): Init new fields.
2311 (ppc64_elf_link_hash_table_create): Likewise.
2312 (ppc64_elf_link_hash_table_free): New function.
2313 (ppc_stub_name): New function.
2314 (ppc_get_stub_entry): New function.
2315 (ppc_add_stub): New function.
2316 (create_linkage_sections): Use bfd_make_section_anyway. Create
2317 .branch_lt and .rela.branch_lt sections. Don't create .stub.
2318 (ppc64_elf_check_relocs): Set has_14bit_branch on R_PPC64_REL14*,
2319 and set up for plt call stubs. Link func and func desc syms.
2320 (ppc64_elf_gc_sweep_hook): Handle REL14* as per REL24.
2321 (func_desc_adjust): Avoid hash lookup when func desc sym available
2322 via shortcut, and set links when processing.
2323 (ppc64_elf_hide_symbol): Likewise.
2324 (allocate_dynrelocs): Don't allocate stub section here.
2325 (ppc64_elf_size_dynamic_sections): Handle sbrlt and srelbrlt.
2326 Remove sstub code.
2327 (ppc_type_of_stub): New function.
2328 (build_one_stub): Delete.
2329 (ppc_build_one_stub): New function.
2330 (ppc_size_one_stub): New function.
2331 (ppc64_elf_setup_section_lists): New function.
2332 (ppc64_elf_next_input_section): New function.
2333 (group_sections): New function.
2334 (get_local_syms): New function.
2335 (ppc64_elf_size_stubs): Rewrite.
2336 (ppc64_elf_build_stubs): Rewrite.
2337 (ppc64_elf_relocate_section): Look up stub entry for REL24
2338 relocs. Don't propagate REL14* to dynamic objects. Look for long
2339 branch stubs if REL14* or REL24 relocs won't reach.
2340 (bfd_elf64_bfd_link_hash_table_free): Define.
2341
09c2219b
MM
23422002-04-30 Mark Mitchell <mark@codesourcery.com>
2343
2344 * bfd/config.bfd: Add support for powerpc-*-windiss.
2345
07b678c0
TR
23462002-04-30 Tom Rix <trix@redhat.com>
2347
2348 * xcofflink.c (xcoff_link_add_symbols): Always copy undef C_EXT
2349 symbol names into the hash table.
2350
dbe341c6
TR
23512002-04-28 Tom Rix <trix@redhat.com>
2352
2353 * coff-rs6000.c (xcoff_calculate_relocation) : Function table for
ea1e4b0d 2354 calulating relocations.
dbe341c6 2355 (xcoff_complain_overflow) : Function table for relocation errors.
ea1e4b0d
AM
2356 (xcoff_ppc_relocate_section): Use relocation and complain function
2357 tables.
2358 (xcoff_complain_overflow_unsigned_func): New complain function.
dbe341c6
TR
2359 (xcoff_complain_overflow_signed_func): Same.
2360 (xcoff_complain_overflow_bitfield_func): Same.
2361 (xcoff_complain_overflow_dont_func): Same.
2362 (xcoff_reloc_type_crel): New recot function.
2363 (xcoff_reloc_type_br): Same.
2364 (xcoff_reloc_type_ba): Same.
2365 (xcoff_reloc_type_toc): Same.
2366 (xcoff_reloc_type_rel): Same.
2367 (xcoff_reloc_type_neg): Same.
2368 (xcoff_reloc_type_pos): Same.
2369 (xcoff_reloc_type_fail): Same.
2370 (xcoff_reloc_type_noop): Same.
2371 * libxcoff.h : Declare common parts for xcoff64.
2372 * coff64-rs6000.c (xcoff64_ppc_relocate_section): Use relocation
ea1e4b0d 2373 and complain function tables.
dbe341c6 2374
985142a4
AM
23752002-04-28 Alan Modra <amodra@bigpond.net.au>
2376
2377 * elf64-x86-64.c (struct elf64_x86_64_dyn_relocs): Comment typo.
2378 * elf32-hppa.c (elf32_hppa_final_link): Formatting.
2379
eba91044
AM
23802002-04-26 Alan Modra <amodra@bigpond.net.au>
2381
e54fdaa5
AM
2382 * opncls.c (bfd_make_readable): Call bfd_section_list_clear.
2383 * xcofflink.c (xcoff_link_add_dynamic_symbols): Likewise.
2384
a50c1845
AM
2385 * elflink.h (elf_bfd_final_link): Ensure input bfd class is the
2386 same as the output before calling elf_link_input_bfd.
2387
eba91044
AM
2388 * coffcode.h (coff_compute_section_file_positions): Set
2389 section_tail after shuffling section list.
2390
3c25c5f6
NC
23912002-04-24 Christian Groessler <chris@groessler.org>
2392
2393 * coff-z8k.c (extra_case): Fix R_IMM32 relocations: The
2394 addresses are 23bit with a special layout, not plain 32bit
2395 values. Prevent relocation of immediate values.
2396
40d32fc6
CD
23972002-04-24 Chris G. Demetriou <cgd@broadcom.com>
2398
2399 * elfxx-mips.c (_bfd_mips_elf_print_private_bfd_data): If MDMX or
2400 MIPS-16 ASE flags are set, print something to indicate that.
2401
067fa4a6
AM
24022002-04-23 Alan Modra <amodra@bigpond.net.au>
2403
2404 * elf32-hppa.c (hppa_type_of_stub): Correct and simplify condition
2405 under which a plt call stub is used.
2406 (final_link_relocate): Similarly.
2407 (allocate_plt_static): Clear h-plabel except when plt entry is
2408 exclusively used for a plabel.
2409 (allocate_dynrelocs): Use the above to simplify plt sizing.
2410 (struct elf32_hppa_link_hash_table): Add has_22bit_branch.
2411 (elf32_hppa_link_hash_table_create): Init.
2412 (BL22_RP): Define.
2413 (hppa_build_one_stub): Use BL22_RP if has_22bit_branch.
2414 (elf32_hppa_check_relocs): Set has_22bit_branch.
2415
2416 * elf32-hppa.c (elf32_hppa_check_relocs): Remove debug message.
2417 (final_link_relocate): Likewise.
2418
af40ce3c
JJ
24192002-04-22 Jakub Jelinek <jakub@redhat.com>
2420
2421 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't build
2422 search table if some FDE is DW_EH_PE_aligned encoded either.
2423 (_bfd_elf_write_section_eh_frame): Handle terminating FDE specially.
2424
09ae86c2
JJ
24252002-04-22 Richard Smith <richard@ex-parrot.com>
2426 Jakub Jelinek <jakub@redhat.com>
2427
2428 * elf-eh-frame.c (struct eh_cie_fde): Add per_encoding_relative.
2429 (_bfd_elf_discard_section_eh_frame): Set it for CIEs with pcrel
2430 encoded personality.
2431 (_bfd_elf_write_section_eh_frame): Adjust pcrel encoded personality
2432 for CIE/FDE removal.
2433
deeb2cd7
TR
24342002-04-20 Tom Rix <trix@redhat.com>
2435
2436 * coff64-rs6000.c (_bfd_xcoff64_swap_aux_in): Fix C_FILE auxent.
2437
99dc0092
AM
24382002-04-20 Alan Modra <amodra@bigpond.net.au>
2439
aa3d5824
AM
2440 * archures.c (bfd_lookup_arch): Move the list order comment..
2441 (struct bfd_arch_info): ..to where it belongs.
2442 * bfd-in2.h: Regenerate.
2443
99dc0092
AM
2444 * archures.c (bfd_lookup_arch): Add comment on list order.
2445 (bfd_default_set_arch_mach): Use bfd_lookup_arch.
2446 * cpu-powerpc.c (bfd_powerpc_archs): Re-order so that the default
2447 is always at head of list.
2448
7831a775
NC
24492002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
2450
2451 * coff-arm.c (coff_thumb_pcrel_12, coff_thumb_pcrel_9,
2452 insert_thumb_branch, record_thumb_to_arm_glue): Suppress
2453 definition of these functions for ARM_WINCE builds as they are
2454 not used.
ea1e4b0d 2455 (SWAP_IN_RELOC_OFFSET, SWAP_OUT_RELOC_OFFSET): Do not define
7831a775
NC
2456 for ARM_WINCE builds.
2457
24582002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
2459
ea1e4b0d 2460 * coff-arm.c (bfd_arm_process_before_allocation):
7831a775
NC
2461
24622002-04-17 J"orn Rennecke <joern.rennecke@superh.com>
a44d7f9c
JR
2463
2464 * cpu-sh.c (scan_mach): Delete.
2465 (arch_info_struct): Replace scan_mach with bfd_default_scan.
2466 (bfd_sh_arch): Likewise.
2467
3d8dbe36
NC
24682002-04-16 Nick Clifton <nickc@cambridge.redhat.com>
2469
2470 * ihex.c (ihex_write_object_contents): Fix check for records
2471 crossing 64K boundaries.
2472
4ab82700
AM
24732002-04-16 Alan Modra <amodra@bigpond.net.au>
2474
2475 * elf32-m32r.c (m32r_elf_add_symbol_hook): Check the hash table
2476 type rather than just assuming entries are ELF.
2477 * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
2478 * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
2479 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Likewise.
2480 * elf64-mmix.c (mmix_elf_add_symbol_hook): Use bfd_link_hash_entry
2481 rather than elf_link_hash_entry.
2482
036fe0fe
RH
24832002-04-15 Richard Henderson <rth@redhat.com>
2484
2485 * elf32-mips.c (mips_elf32_object_p): Revert 0404 fragment: allow
2486 n32 binaries.
2487
c4f3d130
NC
24882002-04-15 Michael Snyder <msnyder@redhat.com>
2489
2490 * opncls.c (bfd_close): Write contents if writeable.
2491 Minor formatting tidy-ups.
2492
4ab82700 24932002-04-15 Alan Modra <amodra@bigpond.net.au>
27242387
AM
2494
2495 * elf32-ppc.c (ppc_elf_add_symbol_hook): Check the hash table type.
2496
0c04d169
MS
24972002-04-12 Michael Snyder <msnyder@redhat.com>
2498
2499 * bfd-in.h (bfd_get_section_lma): New access macro.
2500 Minor white-space fix-up.
2501
89d4966f
AM
25022002-04-12 Alan Modra <amodra@bigpond.net.au>
2503
2504 * elf.c (prep_headers): Don't zero EI_OSABI, EI_ABIVERSION or
2505 header pad.
2506
8d0da3c2
DD
25072002-04-09 DJ Delorie <dj@redhat.com>
2508
2509 * elfarm-nabi.c (elf32_arm_howto_table): Fix ABS16 masks.
2510
05793179
NC
25112002-04-09 Casper S. Hornstrup <chorns@users.sourceforge.net>
2512
2513 * coffcode.h (coff_read_word): New.
2514 (coff_compute_checksum): New.
2515 (coff_apply_checksum): New.
2516 (coff_write_object_contents): Call coff_apply_checksum () to
2517 apply checksum to PE image.
2518
46fe4e66
AM
25192002-04-08 Randolph Chung <tausq@debian.org>
2520
2521 * elf32-hppa.c (hppa_unwind_entry_compare): Move to elf-hppa.h.
2522 (elf32_hppa_final_link): Split out sorting logic to..
2523 * elf-hppa.h (elf_hppa_sort_unwind): ..here.
2524 (elf_hppa_final_link): Call elf_hppa_sort_unwind.
2525
3b5b409c
AC
25262002-04-07 Andrew Cagney <ac131313@redhat.com>
2527
2528 * configure.in: Add missing ``|'' to powerpc-*-aix4.[4-9]*
2529 pattern.
2530 * configure: Re-generate.
2531
ac7b6ceb
AC
25322002-04-07 Andrew Cagney <ac131313@redhat.com>
2533
2534 * configure.in: Only define AIX_CORE_DUMPX_CORE when AIX version
2535 is greater or equal to 4.3.3.
2536 * configure: Regenerate.
2537 Fix PR gdb/344.
2538
44aa49bb
HPN
25392002-04-05 Hans-Peter Nilsson <hp@axis.com>
2540
2541 * elf32-cris.c (cris_elf_howto_table) <R_CRIS_16_PCREL,
2542 R_CRIS_32_PCREL>: Fix typo in name.
2543 (cris_elf_check_relocs): Always create .rela.got here when
2544 R_CRIS_16_GOTPLT or R_CRIS_32_GOTPLT is seen.
2545 (elf_cris_adjust_gotplt_to_got): Don't create .rela.got here;
2546 assume it's created.
2547
e2d34d7d
DJ
25482002-04-04 Daniel Jacobowitz <drow@mvista.com>
2549
2550 * aout-adobe.c (aout_32_bfd_link_hash_table_free): Define.
2551 * aout-target.h (MY_bfd_link_hash_table_free): Conditionally
2552 define.
2553 * aout-tic30.c (MY_bfd_link_hash_table_free): Likewise.
2554 * bfd.c (bfd_link_hash_table_free): Define.
2555 * binary.c (binary_bfd_link_hash_table_free): Define.
2556 * bout.c (b_out_bfd_link_hash_table_free): Define.
2557 * coff-rs6000.c (rs6000coff_vec): Include
2558 _bfd_generic_link_hash_table_free.
2559 (pmac_xcoff_vec): Likewise.
2560 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
2561 (aix5coff64_vec): Likewise.
2562 * coffcode.h (coff_bfd_link_hash_table_free): Conditionally define.
2563 * elf-m10300.c (elf32_mn10300_link_hash_table_free): New function.
2564 (bfd_elf32_bfd_link_hash_table_free): Define.
2565 * elf32-hppa.c (elf32_hppa_link_hash_table_free): New function.
2566 (bfd_elf32_bfd_link_hash_table_free): Define.
2567 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_free): Conditionally
2568 define.
2569 * i386msdos.c (msdos_bfd_link_hash_table_free): Define.
2570 * i386os9k.c (os9k_bfd_link_hash_table_free): Define.
2571 * ieee.c (ieee_bfd_link_hash_table_free): Define.
2572 * ihex.c (ihex_bfd_link_hash_table_free): Define.
2573 * libbfd-in.h (_bfd_nolink_bfd_link_hash_table_free): Define.
2574 (_bfd_generic_link_hash_table_free): Add prototype.
2575 * libcoff-in.h (_bfd_xcoff_bfd_link_hash_table_free): Add prototype.
2576 * libecoff.h (_bfd_ecoff_bfd_link_hash_table_free): Define.
2577 * linker.c (_bfd_generic_link_hash_table_free): New function.
2578 * mmo.c (mmo_bfd_link_hash_table_free): Define.
2579 * nlm-target.h (nlm_bfd_link_hash_table_free): Define.
2580 * oasys.c (oasys_bfd_link_hash_table_free): Define.
2581 * ppcboot.c (ppcboot_bfd_link_hash_table_free): Define.
2582 * som.c (som_bfd_link_hash_table_free): Define.
2583 * srec.c (srec_bfd_link_hash_table_free): Define.
2584 * tekhex.c (tekhex_bfd_link_hash_table_free): Define.
2585 * versados.c (versados_bfd_link_hash_table_free): Define.
2586 * vms.c (vms_bfd_link_hash_table_free): New function.
2587 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_free): New function.
2588
2589 * coff-arm.c (coff_arm_link_hash_table_create): Use bfd_malloc
2590 instead of bfd_alloc.
2591 * coff-h8300.c (h8300_coff_link_hash_table_create): Likewise.
2592 * coff-mcore.c (coff_mcore_link_hash_table_create): Likewise.
2593 * coff-ppc.c (ppc_coff_link_hash_table_create): Likewise.
2594 * cofflink.c (_bfd_coff_link_hash_table_create): Likewise.
2595 * ecoff.c (_bfd_ecoff_bfd_link_hash_table_create): Likewise.
2596 * elf-m10300.c (elf32_mn10300_link_hash_table_create): Likewise.
2597 * elf.c (_bfd_elf_link_hash_table_create): Likewise.
2598 * elf32-arm.h (elf32_arm_link_hash_table_create): Likewise.
2599 * elf32-cris.c (elf_cris_link_hash_table_create): Likewise.
2600 * elf32-hppa.c (elf32_hppa_link_hash_table_create): Likewise.
2601 * elf32-i386.c (elf_i386_link_hash_table_create): Likewise.
2602 * elf32-m68k.c (elf_m68k_link_hash_table_create): Likewise.
2603 * elf32-s390.c (elf_s390_link_hash_table_create): Likewise.
2604 * elf32-sh.c (sh_elf_link_hash_table_create): Likewise.
2605 * elf64-alpha.c (elf64_alpha_bfd_link_hash_table_create): Likewise.
2606 * elf64-ppc.c (ppc64_elf_link_hash_table_create): Likewise.
2607 * elf64-s390.c (elf_s390_link_hash_table_create): Likewise.
2608 * elf64-sh64.c (sh64_elf64_link_hash_table_create): Likewise.
2609 * elf64-sparc.c (sparc64_elf_bfd_link_hash_table_create): Likewise.
2610 * elf64-x86-64.c (elf64_x86_64_link_hash_table_create): Likewise.
2611 * elfxx-mips.c (_bfd_mips_elf_link_hash_table_create): Likewise.
2612 * linker.c (_bfd_generic_link_hash_table_create): Likewise.
2613 * m68klinux.c (linux_link_hash_table_create): Likewise.
2614 * sparclinux.c (linux_link_hash_table_create): Likewise.
2615 * sunos.c (sunos_link_hash_table_create): Likewise.
2616 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Likewise.
2617
2618 * targets.c: Add _bfd_link_hash_table_free to xvec.
2619
2620 * bfd-in2.h: Regenerate.
2621 * libbfd.h: Regenerate.
2622 * libcoff.h: Regenerate.
2623
830629ab
AM
26242002-04-04 Alan Modra <amodra@bigpond.net.au>
2625
2626 * dep-in.sed: Cope with absolute paths.
2627 * Makefile.am (dep.sed): Subst TOPDIR, and not INCDIR.
2628 Run "make dep-am".
2629 * Makefile.in: Regenerate.
2630 * coff-arm.c: Fix copyright date.
2631 * cpu-h8300.c: Likewise.
2632 * cpu-i370.c: Likewise.
2633 * cpu-s390.c: Likewise.
2634 * cpu-mips.c: Likewise.
2635 * po/SRC-POTFILES.in: Regenerate.
2636
c6e90b02
TS
26372002-04-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2638
2639 * Makefile.am: Add elfxx-mips.c to the known backends.
2640 (elf32-mips.lo): remove dependency to coff/external.h.
2641 * Makefile.in: Regenerate.
2642 * configure.in: Add elfxx-mips.lo to all vectors using elf32-mips.lo
2643 Remove elf32-mips.lo from 64 bit vectors. Update dependencies
2644 accordingly.
2645 * configure: Regenerate.
2646 * elf-bfd.h: Move all MIPS ELF specific prototypes to elfxx-mips.h.
2647 (irix_compat_t): IRIX compatibility level, moved from elf32-mips.c.
2648 (elf_backend_mips_irix_compat, elf_backend_mips_rtype_to_howto): New
2649 MIPS specific backend functions.
2650 * elf32-mips.c: Moved most code to elfxx-mips.c.
2651 (mips_elf_hi16_reloc): Rename from _bfd_mips_elf_hi16_reloc and make
2652 static.
2653 (mips_elf_lo16_reloc): Likewise, was _bfd_mips_elf_lo16_reloc.
2654 (mips_elf_got16_reloc): Likewise, was _bfd_mips_elf_got16_reloc.
2655 (mips_elf_gprel32_reloc): Likewise, was _bfd_mips_elf_gprel32_reloc.
2656 (mips_elf32_rtype_to_howto): Rename from mips_rtype_to_howto. Changed
2657 interface to allow selection of the right REL or RELA howto table.
2658 (mips_elf32_object_p): Rename from _bfd_mips_elf_object_p and made
2659 static. Let it refuse n32 objects.
2660 (elf32_mips_grok_prstatus): Rename from _bfd_elf32_mips_grok_prstatus.
2661 (elf32_mips_grok_psinfo): Rename from _bfd_elf32_mips_grok_psinfo.
2662 (elf32_mips_discard_info): Rename from _bfd_elf32_mips_discard_info.
2663 (elf32_mips_ignore_discarded_relocs): Rename from
2664 _bfd_elf32_mips_ignore_discarded_relocs.
2665 (elf32_mips_write_section): Rename from _bfd_elf32_mips_write_section.
2666 (elf32_mips_irix_compat): New function, replaces IRIX_COMPAT.
2667 (elf_mips_howto_table_rela): Remove.
2668 * elf64-mips.c: Moved most code to elfxx-mips.c.
2669 (bfd_elf64_bfd_reloc_type_lookup): Make static.
2670 (mips_elf64_rtype_to_howto): New function.
2671 (mips_elf64_object_p): Likewise.
2672 (elf64_mips_irix_compat): Likewise.
2673 * elfxx-mips.c: New file containing common code merged together from
2674 elf32-mips.c and elf64-mips.c.
2675 * elfxx-mips.h: New file containing MIPS specific prototypes from
2676 elf-bfd.h.
2677 * elfxx-target.h: Add handling for elf_backend_mips_irix_compat and
2678 elf_backend_mips_rtype_to_howto.
2679
d8dce692
AM
26802002-04-04 Alan Modra <amodra@bigpond.net.au>
2681
2682 * srec.c (MAXCHUNK, Chunk): Revise comments.
2683 (srec_write_record): Correct buffer size.
2684 (srec_write_header): Do without intermediate buffer.
2685 (srec_write_section): Validate Chunk.
2686 (srec_write_terminator): Pass NULL instead of dummy buffer.
2687 (srec_write_symbols): Pass file and symbol names directly to
2688 bfd_bwrite so sprintf won't overflow buffer.
2689
b88a866a
JJ
26902002-04-03 Jakub Jelinek <jakub@redhat.com>
2691
2692 * elf32-sparc.c (elf32_sparc_relocate_section): Don't emit dynamic
2693 PC relative relocs against hidden symbols.
2694 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
2695
d7866f04
AM
26962002-04-03 Alan Modra <amodra@bigpond.net.au>
2697
2698 * elf.c (_bfd_elf_make_section_from_shdr): When setting section
2699 LMAs, loop over segments until p_vaddr and p_memsz specify an
2700 extent enclosing the section.
2701
9e81ee67
NC
27022002-04-02 Nick Clifton <nickc@cambridge.redhat.com>
2703
2704 * ihex.c (ihex_write_object_contents): Do not allow records to
2705 cross a 64K boundary - wrap if necessary.
2706
d2b64500
JT
27072002-04-01 Nathan Williams <nathanw@wasabisystems.com>
2708
2709 * elf.c (elfcore_netbsd_get_lwpid): Fix off-by-one error
2710 which caused the returned LWP ID to always be 0.
2711
e36f7d53
RH
27122002-04-01 Richard Henderson <rth@redhat.com>
2713
2714 * elf32-sparc.c (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
2715 (elf32_sparc_relocate_section): Use it to figure out when to
2716 initialize .got entries.
2717 * elf64-sparc.c: Similarly.
2718
e92d460e
AM
27192002-03-28 Alan Modra <amodra@bigpond.net.au>
2720
2721 * linker.c (link_action): Ignore duplicate warning syms.
2722 (_bfd_generic_link_write_global_symbol): Follow warning symbol link.
2723 * elflink.h (elf_adjust_dynstr_offsets): Likewise.
2724 (elf_adjust_dynamic_symbol): Likewise.
2725 (elf_export_symbol): Likewise.
2726 (elf_link_find_version_dependencies): Likewise.
2727 (elf_link_assign_sym_version): Likewise.
2728 (elf_link_sec_merge_syms): Likewise.
2729 (elf_link_output_extsym): Likewise.
2730 (elf_gc_sweep_symbol): Likewise.
2731 (elf_gc_propagate_vtable_entries_used): Likewise.
2732 (elf_gc_smash_unused_vtentry_relocs): Likewise.
2733 (elf_gc_allocate_got_offsets): Likewise.
2734 (elf_collect_hash_codes): Likewise.
2735 * elflink.c (elf_link_renumber_hash_table_dynsyms): Likewise.
2736 * elf-hppa.h (elf_hppa_unmark_useless_dynamic_symbols): Likewise.
2737 (elf_hppa_remark_useless_dynamic_symbols): Likewise.
2738 * elf-m10300.c (elf32_mn10300_finish_hash_table_entry): Likewise.
2739 * elf32-arm.h (elf32_arm_discard_copies): Likewise.
2740 * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Likewise.
2741 (elf_cris_discard_excess_dso_dynamics): Likewise.
2742 * elf32-hppa.c (clobber_millicode_symbols): Likewise.
2743 (mark_PIC_calls): Likewise.
2744 (allocate_plt_static): Likewise.
2745 (allocate_dynrelocs): Likewise.
2746 (readonly_dynrelocs): Likewise.
2747 * elf32-i386.c (allocate_dynrelocs): Likewise.
2748 (readonly_dynrelocs): Likewise.
2749 * elf32-i370.c (i370_elf_adjust_dynindx): Likewise.
2750 * elf32-m68k.c (elf_m68k_discard_copies): Likewise.
2751 * elf32-mips.c (mips_elf_output_extsym): Likewise.
2752 (mips_elf_sort_hash_table_f): Likewise.
2753 (mips_elf_check_mips16_stubs): Likewise.
2754 * elf32-s390.c (allocate_dynrelocs): Likewise.
2755 (readonly_dynrelocs): Likewise.
2756 * elf32-sh.c (sh_elf_discard_copies): Likewise.
2757 * elf32-xstormy16.c (xstormy16_relax_plt_check): Likewise.
2758 (xstormy16_relax_plt_realloc): Likewise.
2759 * elf64-alpha.c (elf64_alpha_calc_got_offsets_for_symbol): Likewise.
2760 (elf64_alpha_output_extsym): Likewise.
2761 * elf64-hppa.c (elf64_hppa_mark_exported_functions): Likewise.
2762 * elf64-mips.c (mips_elf64_sort_hash_table_f): Likewise.
2763 (mips_elf64_check_mips16_stubs): Likewise.
2764 (mips_elf64_output_extsym): Likewise.
2765 * elf64-ppc.c (func_desc_adjust): Likewise.
2766 (allocate_dynrelocs): Likewise.
2767 (readonly_dynrelocs): Likewise.
2768 * elf64-s390.c (allocate_dynrelocs): Likewise.
2769 (readonly_dynrelocs): Likewise.
2770 * elf64-sh64.c (sh64_elf64_discard_copies): Likewise.
2771 * elf64-x86-64.c (allocate_dynrelocs): Likewise.
2772 (readonly_dynrelocs): Likewise.
2773 * elfxx-ia64.c (elfNN_ia64_global_dyn_sym_thunk): Likewise.
2774 * aoutx.h (aout_link_write_other_symbol): Likewise.
2775 * cofflink.c (_bfd_coff_write_task_globals): Likewise.
2776 (_bfd_coff_write_global_sym): Likewise.
2777 * i386linux.c (linux_tally_symbols): Likewise.
2778 * m68klinux.c (linux_tally_symbols): Likewise.
2779 * sparclinux.c (linux_tally_symbols): Likewise.
2780 * pdp11.c (aout_link_write_other_symbol): Likewise.
2781 * sunos.c (sunos_scan_dynamic_symbol): Likewise.
2782 * xcofflink.c (xcoff_build_ldsyms): Likewise.
2783 (xcoff_write_global_symbol): Likewise.
2784
2785 * cofflink.c (_bfd_coff_final_link): Formatting.
2786 * cpu-mips.c (mips_compatible): Make static, prototype.
2787 * elf32-i386.c (elf_i386_check_relocs): Formatting.
2788 * elf32-sh.c (sh_elf_size_dynamic_sections): Likewise.
2789 * elf64-alpha.c (elf64_alpha_output_extsym): Likewise.
2790 * elf64-mips.c (mips_elf64_sort_hash_table): Likewise.
2791 (mips_elf64_final_link): Likewise.
2792 * elflink.h (elf_link_find_version_dependencies): Remove duplicate
2793 prototype.
2794
2106126f
NC
27952002-03-27 Nick Clifton <nickc@cambridge.redhat.com>
2796
2797 * coff-arm.c (SWAP_IN_RELOC_OFFSET): Define.
2798 (SWAP_OUT_RELOC_OFFSET): Define.
2799
b99d1833
AM
28002002-03-27 Gregory Steuck <greg@nest.cx>
2801
2802 * elf.c (_bfd_elf_get_symtab_upper_bound): Leave space for
2803 terminating NULL if empty symbol table.
2804 (_bfd_elf_get_dynamic_symtab_upper_bound): Likewise.
2805
ad43ed4c
L
28062002-03-26 H.J. Lu (hjl@gnu.org)
2807
2808 * elflink.h (elf_link_input_bfd): Revert the last change since
2809 the gcc exception handling isn't fixed yet.
2810
3851fca4
L
28112002-03-26 H.J. Lu (hjl@gnu.org)
2812
2813 * elflink.h (elf_link_input_bfd): Complain about relocations
2814 against local symbols in discarded sections.
2815
b91afed7
AM
28162002-03-26 Alan Modra <amodra@bigpond.net.au>
2817
2818 * elflink.h (elf_gc_mark): Don't recurse into non-ELF sections.
2819
dba143ef
AM
28202002-03-23 Alan Modra <amodra@bigpond.net.au>
2821
2822 * elf.c (_bfd_elf_make_section_from_shdr): Don't set lma based on
2823 section file offset for !SEC_LOAD sections.
2824
ee29b9fb
RE
28252002-03-21 Richard Earnshaw <rearnsha@arm.com>
2826
830629ab
AM
2827 * elf32-arm.h (elf32_arm_final_link_relocate <case R_ARM_GOTOFF>,
2828 <case R_ARM_GOT>): Handle relocations to Thumb functions.
ee29b9fb 2829
54327882
AM
28302002-03-21 Alan Modra <amodra@bigpond.net.au>
2831
2832 * coff64-rs6000.c (_bfd_xcoff64_put_symbol_name): Prototype.
2833 Whitespace changes.
2834 * archive.c: Update copyright date.
2835 * bfd-in2.h: Regenerate.
2836 * libbfd.h: Regenerate.
2837 * Makefile.am: Run "make dep-am"
2838 * Makefile.in: Regenerate.
2839 * po/SRC-POTFILES.in: Regenerate.
2840
1ee24f27
DJ
28412002-03-20 Daniel Jacobowitz <drow@mvista.com>
2842
2843 * dwarf2.c (struct funcinfo): Move up.
2844 (lookup_address_in_function_table): New argument function_ptr.
2845 Set it.
2846 (lookup_address_in_line_table): New argument function. If function
2847 is non-NULL, use it to handle ``addr'' before the first line note of
2848 the function.
2849 (comp_unit_find_nearest_line): Update and swap calls to
2850 lookup_address_in_function_table and lookup_address_in_line_table.
2851 * syms.c (_bfd_stab_section_find_nearest_line): Use the first
2852 N_SLINE encountered if we see an N_FUN before any N_SLINE.
2853
51b9608c
TR
28542002-03-20 Tom Rix <trix@redhat.com>
2855
ea1e4b0d 2856 * coff-rs6000.c (_bfd_xcoff_stat_arch_elt): Renamed from
51b9608c 2857 _bfd_xcoff_generic_stat_arch_elt. Fix format check.
ea1e4b0d 2858 * coff64-rs6000.c : Use _bfd_xcoff_stat_arch_elt.
51b9608c 2859
789c90aa
TR
28602002-03-19 Tom Rix <trix@redhat.com>
2861
ea1e4b0d 2862 * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Look through all
789c90aa
TR
2863 dynamic objects in archives.
2864
1da54d81
HPN
28652002-03-19 Hans-Peter Nilsson <hp@bitrange.com>
2866
2867 * elflink.h (NAME(bfd_elf,record_link_assignment)): Don't set
2868 STT_NOTYPE symbols to STT_OBJECT.
2869
7831a775 28702002-03-18 Jan Hubicka <jh@suse.cz>
beb43bb9
JH
2871
2872 * cpu-i386.c (bfd_x86_64_arch): Rename to "i386:x86-64"
2873
eb1e0e80
NC
28742002-03-18 Tom Rix <trix@redhat.com>
2875
2876 * aix5ppc.core.c : New file for AIX 5 64 bit core support.
2877 * bfd-in.h : Add bfd_xcoff_ar_archive_set_magic declaration.
2878 * coff-rs6000 (do_pad) : New function for archive padding.
2879 (do_copy) : New function for object file copying in archives.
2880 (do_shared_object_padding) : New function for padding shared
2881 objects to their text section alignment in archives.
2882 (bfd_xcoff_ar_achive_set_magic) : Stub.
2883 (xcoff_write_armap_big) : Use do_copy and do_pad.
2884 (xcoff_write_archive_contents_big) : Use do_shared_object_padding,
2885 do_copy and do_pad.
2886 * coff64-rs6000.c (xcoff64_write_ojbect_contents) : Use
ea1e4b0d 2887 bfd_xcoff_magic_number.
eb1e0e80
NC
2888 (xcoff64_bad_format_hook) : New function for _bfd_bad_format_hook
2889 fop.
2890 (xcoff_backend_data_r) : Use xcoff64_bad_format_hook.
2891 (bfd_xcoff_aix5_backend_data) : New Aix 5 backend data.
2892 (aix5coff64_vec) : New Aix 5 target aix5coff64-rs6000.
2893 * rs6000-core.c : Update copyright date.
ea1e4b0d 2894 * xcofflink.c (bfd_xcoff_size_dynamic_sections): Check for NULL
eb1e0e80
NC
2895 csectpp.
2896 * coffcode.h (coff_new_section_hook) : Use new accessor macros.
2897 (coff_set_arch_mach_hook) : Add Aix 5 U64_TOCMAGIC magic #.
2898 (coff_set_flags) : Use bfd_xcoff_magic_number.
2899 * libxcoff.h (bfd_xcoff_is_xcoff64): Add U64_TOCMAGIC.
2900 * configure.in : Add powerpc-*-aix5 and rs6000-*-aix5 support.
2901 * Makefile.am : Same.
2902 * config.bfd : Same.
2903 * targets.c : Same.
2904 * configure : Regnerate.
2905 * Makefile.in : Same.
2906 * bfd-in2.h : Same.
2907
a1c259a1
NC
29082002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
2909
2910 * po/fr.po: Updated version.
2911
4dae1ae7
AM
29122002-03-18 Alan Modra <amodra@bigpond.net.au>
2913
2914 * libbfd.c (bfd_write_bigendian_4byte_int): Return true iff success.
2915 * libbfd.h: Regenerate.
2916 * archive.c (coff_write_armap): Pass on failures from
2917 bfd_write_bigendian_4byte_int.
2918
36b4f6e7
L
29192002-03-14 H.J. Lu <hjl@gnu.org>
2920
2921 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the BFD
2922 error to bfd_error_nonrepresentable_section for reinit_array
2923 section in DSO.
2924
a1aefc76
NC
29252002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
2926
a181be0a
NC
2927 * coffcode.h (coff_slurp_symbol_table): When adding BSF_WEAK flag,
2928 OR it in rather than replacing previously selected flags.
2929
a1aefc76
NC
2930 * elfxx-target.h (TARGET_BIG_SYM): Set ar_max_namelen to 15.
2931 (TARGET_LITTLE_SYM): Set ar_max_namelen to 15.
2932
c119f9b8
AM
29332002-03-14 Alan Modra <amodra@bigpond.net.au>
2934
2935 * cpu-mips.c (mips_compatible): New. Don't check bits_per_word.
2936 (N): Use the above.
2937 * elflink.h (elf_bfd_final_link): Revert last change. Instead,
2938 ensure reloc size matches before calling elf_link_input_bfd.
2939 Add an assert to check reloc size when counting output relocs.
2940
c295a511
NC
29412002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
2942
2943 * mmo.c (mmo_get_loc): Return NULL rather than false.
2944
9ce88e60
NC
29452002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
2946
2947 * po/fr.po: Updated version.
2948
4ddafab0
AM
29492002-03-13 Alan Modra <amodra@bigpond.net.au>
2950
b74fa2cd
AM
2951 * archures.c (bfd_default_compatible): Test bits_per_word.
2952 * cpu-i386.c (i386_compatible): Remove. Replace occurrences with
2953 bfd_default_compatible.
2954 * cpu-i370.c (i370_compatible): Likewise.
2955 * cpu-sparc.c (sparc_compatible): Likewise.
2956 * cpu-h8300.c (compatible): Test in->arch == out->arch.
2957
40b829d4
AM
2958 * elflink.h: Formatting fixes.
2959 (elf_link_output_extsym): Merge undefined and undef weak cases.
2960
4ddafab0
AM
2961 * elflink.h (elf_bfd_final_link): Only call elf_link_input_bfd
2962 when word size of input matches output word size.
2963
dd53c801
AJ
29642002-03-12 Andreas Jaeger <aj@suse.de>
2965
2966 * cpu-i386.c (i386_compatible): New. Use it instead of
2967 bfd_default_compatible.
2968
aa066ac8
L
29692002-03-07 H.J. Lu (hjl@gnu.org)
2970
2971 * coff-sh.c (shcoff_reloc_map): Use bfd_reloc_code_real_type
2972 as the type for bfd_reloc_val.
2973
1bf42538
JL
29742002-03-05 John David Anglin <dave@hiauly1.hia.nrc.ca>
2975
2976 * elf-hppa.h (elf_hppa_is_dynamic_loader_symbol): New function.
2977 (elf_hppa_relocate_section): Ignore undefined dynamic loader symbols.
2978 (elf_hppa_final_link_relocate): Correct relocations for indirect
2979 references to local data through the DLT. Fix .opd creation for
2980 local symbols using R_PARISC_LTOFF_FPTR32 and R_PARISC_FPTR64
2981 relocations. Use e_lsel selector for R_PARISC_DLTIND21L,
2982 R_PARISC_LTOFF_FPTR21L and R_PARISC_LTOFF_TP21L as per
2983 "Processor-Specific ELF for PA_RISC, Version 1.43" document.
2984 Similarly, use e_rsel for DLT and LTOFF 'R' relocations.
2985 * elf32-hppa.c (final_link_relocate): Revise relocation selectors
2986 as per "Processor-Specific ELF for PA_RISC, Version 1.43" document.
2987
86eaf01e
JJ
29882002-03-05 Jakub Jelinek <jakub@redhat.com>
2989
2990 * merge.c (_bfd_merge_sections): Don't segfault if there
2991 is nothing to merge due to GC.
2992
c44233aa
AM
29932002-03-05 Alan Modra <amodra@bigpond.net.au>
2994
039cc25f
AM
2995 * elf32-hppa.c (clobber_millicode_symbols): Remove hack to keep
2996 symbols that have been forced local.
2997
c44233aa
AM
2998 * elflink.h (elf_bfd_final_link): Call elf_link_output_extsym
2999 to output forced local syms for non-shared link.
3000 (elf_link_output_extsym): Tweak condition for calling backend
3001 adjust_dynamic_symbol so that previous behaviour is kept.
3002 Whitespace changes throughout file.
3003
25e27870
L
30042002-03-04 H.J. Lu <hjl@gnu.org>
3005
3006 * elf.c (bfd_section_from_shdr): Handle special sections,
3007 .init_array, .fini_array and .preinit_array.
3008 (elf_fake_sections): Likewise.
3009
3010 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Create the
3011 DT entry only if the section is in output for .init_array,
3012 .fini_array and .preinit_array. Complain about .preinit_array
3013 section in DSO.
3014 (elf_bfd_final_link): Warn zero size for .init_array,
3015 .fini_array and .preinit_array sections.
3016
3017 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Remove
3018 SHT_INIT_ARRAY, SHT_FINI_ARRAY and SHT_PREINIT_ARRAY.
3019 (elfNN_ia64_fake_sections): Remove .init_array, .fini_array and
3020 .preinit_array.
3021
bb2a49f2
AM
30222002-03-04 Alan Modra <amodra@bigpond.net.au>
3023
3024 * configure.in (WIN32LIBADD): Don't eval PICFLAG assignment.
3025 * configure: Regenerate.
3026
38487e5e
TR
30272002-03-02 Tom Rix <trix@redhat.com>
3028
c44233aa
AM
3029 * coff64-rs6000.c (xcoff64_howto_table): Replace howto types with
3030 symbolic equiv.
38487e5e
TR
3031 * coff-rs6000.c (xcoff_howto_table): Same.
3032
30831527
RH
30332002-03-01 David Mosberger <davidm@hpl.hp.com>
3034
3035 * elflink.h (size_dynamic_sections): If section named
3036 ".preinit_array" exists, create DT_PREINIT_ARRAY and
3037 DT_PREINIT_ARRAYSZ entries in dynamic table. Analogously for
3038 ".init_array" and ".fini_array".
3039 (elf_bfd_final_link): Handle DT_PREINIT_ARRAYSZ, DT_INIT_ARRAYSZ,
3040 DT_FINI_ARRAYSZ, DT_PREINIT_ARRAY, DT_INIT_ARRAY, and
3041 DT_FINI_ARRAY.
3042
c8e5ddc8
AM
30432002-02-26 Andrew Macleod <amacleod@cygnus.com>
3044
3045 * elflink.h (elf_bfd_final_link): Don't crash on SHN_UNDEF local
3046 dynsyms.
3047
96e0dda4
AM
30482002-02-25 Alan Modra <amodra@bigpond.net.au>
3049
1c5b6bf8
AM
3050 * elf64-hppa.h: Update copyright date.
3051
96e0dda4
AM
3052 * elf64-ppc.c (ppc64_elf_check_relocs): Warning fix.
3053 (ppc64_elf_relocate_section): Don't generate power4 style branch
3054 hints for *_BRTAKEN and *_BRNTAKEN relocs.
3055
0fb19cbc
JJ
30562002-02-22 Jakub Jelinek <jakub@redhat.com>
3057
3058 * elf64-sh64.c (sh_elf64_relocate_section): Fix a typo from my
3059 last patch.
3060 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
3061
c434dee6
AJ
30622002-02-21 Andreas Jaeger <aj@suse.de>
3063
3064 * elf64-x86-64.c: Major rework that introduces all recent changes
3065 to the x86-64 backend. Get a closer match to elf32-i386.
3066 (struct elf64_x86_64_dyn_relocs): Rename from
3067 elf64_x86_64_pcrel_relocs_copied, add additional fields. Change
3068 all users.
3069 (struct elf64_x86_64_link_hash_table): Add short cuts to some
3070 sections.
3071 (link_hash_newfunc): Rename from elf64_x86_64_link_hash_newfunc,
3072 remove casts, initialize new hash members.
3073 (create_got_section): New.
3074 (elf64_x86_64_create_dynamic_sections): New.
3075 (elf64_x86_64_copy_indirect_symbol): New.
3076 (elf64_x86_64_check_relocs): Don't allocate space for dynamic
3077 relocs, .got or .relgot here but do it in allocate_dynrelocs.
3078 Reference count possible .plt and .got entries. Don't test input
3079 section SEC_READONLY here to try to avoid copy relocs, and keep
3080 dyn_relocs regardless of ELF_LINK_NON_GOT_REF. Don't set
3081 DF_TEXTREL here. Delay setting of variables until needed. Cache
3082 pointer to "sreloc" section in elf_section_data. Tweak condition
3083 under which .got created. Report files with bad relocation
3084 section names.
3085 (elf64_x86_64_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
3086 Reference count possible .plt entries. Don't deallocate .got and
3087 .relgot space here.
3088 (elf64_x86_64_adjust_dynamic_symbol): Handle nocopyreloc. Don't
3089 do copy reloc processing for weakdefs. Remove redundant casts and
3090 aborts. Delay setting of vars until needed. Move creation of
3091 dynamic symbols and allocation of .plt and .rela.plt to
3092 allocate_dynrelocs. Replace BFD_ASSERT with abort.
3093 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
3094 (allocate_dynrelocs): New.
3095 (readonly_dynrelocs): New.
3096 (elf64_x86_64_size_dynamic_sections): Call readonly_dynrelocs.
3097 Allocate space for dyn relocs. Replace BFD_ASSERT with abort.
3098 Zero out the dynamic allocated content space.
3099 (elf64_x86_64_discard_copies): Removed.
3100 (elf64_x86_64_relocate_section): Make use of dynamic section
3101 short-cuts. Localise vars, and delay setting. Better error
3102 reporting, replace BFD_ASSERT with abort. Check
3103 ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined in the
3104 regular object file and tread the weak definition as the normal
3105 one. Don't discard relocs for undefweak or undefined symbols and
3106 check !DEF_REGULAR as well as DEF_DYNAMIC in test for avoided copy
3107 relocs.
3108 (elf64_x86_64_finish_dynamic_symbol): Don't copy relocs for
3109 symbols that have been forced local. Use same test to decide if
3110 we can use a relative reloc for got as relocate_section. Expand
3111 SHN_UNDEF comment. Move expressions out of function calls.
3112 Replace BFD_ASSERT with abort.
3113 (bfd_elf64_bfd_final_link): Removed.
3114 (elf_backend_copy_indirect_symbol): Define.
3115
ff3a6ee3
TR
31162002-02-20 Tom Rix <trix@redhat.com>
3117
3118 * coff-rs6000.c (xcoff_howto_table): Add 16 bit R_BA.
3119 (_bfd_xcoff_reloc_type_lookup): Use it.
3120 * coff64-rs6000.c (xcoff64_howto_table): Same.
3121 (xcoff64_reloc_type_lookup): Same.
c434dee6 3122
a68d41fb
AM
31232002-02-20 Peter Schauer <pes@regent.e-technik.tu-muenchen.de>
3124
3125 * osf-core.c (osf_core_vec): OSF/1 (Digital Unix) core files are
3126 little endian.
3127
befc3abb
MS
31282002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
3129
3130 * archures.c (bfd_mach_s390_esa): Rename to bfd_mach_s390_31.
3131 (bfd_mach_s390_esame): Rename to bfd_mach_s390_64.
3132 * bfd-in2.h: Regenerate.
3133 * cpu-s390.c (arch_info_struct): Use renamed architecture defines.
3134 Replace architecture name "s390" with "s390:31-bit" and "s390:esame"
3135 with "s390:64-bit".
3136 * elf32-s390.c (elf_howto_table): Add 32 bit pc relative relocations.
3137 (elf_s390_reloc_type_lookup): Likewise.
3138 (elf_s390_check_relocs): Likewise.
3139 (elf_s390_gc_sweep_hook): Likewise.
3140 (elf_s390_relocate_section): Likewise.
3141 (elf_s390_object_p): Use renamed architecture define.
3142 * elf64-s390.c (elf_s390_object_p): Use renamed architecture define.
3143
6eeeec9b
FCE
31442002-02-19 Frank Ch. Eigler <fche@redhat.com>
3145
3146 * syms.c (stt[]): Sorted. Added .init/.fini -> "t" mapping.
3147
0bb2d96a
JJ
31482002-02-19 Jakub Jelinek <jakub@redhat.com>
3149
3150 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Enable
3151 absptr -> pcrel optimization for shared libs.
3152 Only create minimal .eh_frame_hdr if absptr FDE encoding in shared
3153 library cannot be converted to pcrel.
3154 (_bfd_elf_eh_frame_section_offset): Return -2 if making absptr
3155 relative.
3156 * elf32-i386.c (elf_i386_relocate_section): If
3157 _bfd_elf_section_offset returned -2, skip, but make sure the
3158 relocation is installed.
3159 * elf32-arm.h (elf32_arm_final_link_relocate): Likewise.
3160 * elf32-cris.c (cris_elf_relocate_section): Likewise.
3161 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
3162 * elf32-i370.c (i370_elf_relocate_section): Likewise.
3163 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
3164 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
3165 * elf32-s390.c (elf_s390_relocate_section): Likewise.
3166 * elf32-sh.c (sh_elf_relocate_section): Likewise.
3167 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
3168 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
3169 * elf64-s390.c (elf_s390_relocate_section): Likewise.
3170 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
3171 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
3172 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
3173 * elf64-alpha.c (elf64_alpha_relocate_section): Handle
3174 _bfd_elf_section_offset returning -2 the same way as -1.
3175 * elfxx-ia64.c (elfNN_ia64_install_dyn_reloc): Likewise.
3176 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add FIXME
3177 and BFD_ASSERT.
3178 * elf64-mips.c (mips_elf64_create_dynamic_relocation): Likewise.
3179
69f284c7
TR
31802002-02-18 Tom Rix <trix@redhat.com>
3181
3182 * xcofflink.c (bfd_xcoff_link_gernate_rtinit): Add -brtl support.
3183 (bfd_xcoff_size_dynamic_sections): Same.
3184 * bfd-in.h (bfd_xcoff_link_generate_rtinit): Same.
3185 (bfd_xcoff_size_dynamic_sections): Same.
3186 * coff-rs6000.c (xcoff_generate_rtinit): Same.
3187 * coff-rs646000.c (xcoff64_generate_rtinit): Same.
3188 * libxcoff.h (struct xcoff_backend_data_rec): Same.
3189 * xcofflink.c (xcoff_build_ldsyms, xcoff_link_add_symbols): Clean.
3190 * bfd-in2.h: Regenerate.
3191
82bd7b59
AM
31922002-02-18 Alan Modra <amodra@bigpond.net.au>
3193
3194 * elf64-ppc.c (STFD_FR0_0R1, LFD_FR0_0R1, BLR): Define.
3195 (struct ppc_link_hash_table): Add sfpr.
3196 (ppc64_elf_link_hash_table_create): Init it.
3197 (ppc64_elf_create_dynamic_sections): Split creation of .stub and
3198 .glink out to..
3199 (create_linkage_sections): ..here. Make .sfpr too.
3200 (ppc64_elf_check_relocs): Call create_linkage_sections, and set
3201 dynobj early.
3202 (MIN_SAVE_FPR, MAX_SAVE_FPR): Define.
3203 (ppc64_elf_func_desc_adjust): Look for missing ._savef* and
3204 ._restf* functions, and create as needed.
3205 (func_desc_adjust): Only force_local for shared libs.
3206
ef1355e8
NC
32072002-02-18 David O'Brien <obrien@FreeBSD.org>
3208
3209 * configure.in: Bump version number post 2.12 branching.
3210 * configure: Regenerate.
3211
dfa36a69
HPN
32122002-02-17 Hans-Peter Nilsson <hp@bitrange.com>
3213
3214 * mmo.c: Correct and improve comments.
3215 (mmo_write_chunk): Store trailing byte in bfd buffer; don't
3216 zero-pad. Use input to fill up non-empty bfd buffer.
3217 (mmo_flush_chunk): New function.
3218 (mmo_write_loc_chunk): Add parameter last_vmap, all callers
3219 changed. Don't emit location specifier if VMA is same as
3220 *LAST_VMAP after omitting leading zero contents. Call
3221 mmo_flush_chunk before emitting location specifier.
3222 (mmo_write_loc_chunk_list): Call mmo_flush_chunk when finished
3223 with mmo_write_loc_chunk calls.
3224 (mmo_internal_write_section): Call mmo_flush_chunk after
3225 mmo_write_chunk.
3226 (mmo_write_symbols_and_terminator): Move :Main to first position
3227 in symbol array. Add faked one if it does not exist if there are
3228 other symbols. Don't add it if there are no symbols at all. Move
3229 out test for value of :Main from symbol loop. Rename table
3230 fakemain to maintable and variable mainsym to fakemain.
3231
ccf00ab6
RH
32322002-02-15 Richard Henderson <rth@redhat.com>
3233
3234 * elf64-alpha.c (elf64_alpha_relocate_section) [BRSGP]: A target
3235 section with no got matches any got. Simplify error generaion.
3236
88eaccc2
AM
32372002-02-15 Alan Modra <amodra@bigpond.net.au>
3238
fd96f80f
AM
3239 Support arbitrary length fill patterns.
3240 * linker.c (bfd_new_link_order): Zero all fields with bfd_zalloc.
3241 (_bfd_default_link_order): Remove bfd_fill_link_order code.
3242 Call default_data_link_order.
3243 (default_fill_link_order): Delete.
3244 (default_data_link_order): New function.
3245 * elf32-mips.c (_bfd_mips_elf_final_link): Replace occurrences
3246 of bfd_fill_link_order with bfd_data_link_order.
3247 * elf64-alpha.c (elf64_alpha_final_link): Likewise.
3248 * elf64-mips.c (mips_elf64_final_link): Likewise.
3249
88eaccc2
AM
3250 * bfd.c (bfd_scan_vma): Clamp overflows to max bfd_vma value.
3251 Correct value returned in "end" for "0x<non-hex>".
3252
e2fd756b
NC
32532002-02-14 Nick Clifton <nickc@cambridge.redhat.com>
3254
3255 * cpu-arm.c (processors): Replace 'arch' field with 'mach'.
3256 (scan): Test against 'mach' field in info structure.
3257
edd29cf9
AM
32582002-02-14 Alan Modra <amodra@bigpond.net.au>
3259
3260 * elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD.
3261
1e30956e 32622002-02-14 Matt Fredette <fredette@netbsd.org>
76f57f3a
JT
3263
3264 * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Recognize
3265 EF_M68000.
3266
bf36db18
NC
32672002-02-13 Nick Clifton <nickc@cambridge.redhat.com>
3268
3269 * elf.c (_bfd_elf_make_section_from_shdr): Do not insist on
edd29cf9
AM
3270 non-zero physical addresses when adjusting the LMAs of new
3271 sections.
bf36db18 3272
189c6563
AM
32732002-02-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
3274
3275 * elf-hppa.h (elf_hppa_reloc_final_type): New function stripped
3276 from _bfd_elf_hppa_gen_reloc_type.
3277 (_bfd_elf_hppa_gen_reloc_type): Remove duplicate prototype.
3278 * elf32-hppa.h (elf32_hppa_reloc_final_type): Add protptype.
3279 * elf32-hppa.c: Include elf32-hppa.h before elf-hppa.h.
3280 * elf64-hppa.h (elf64_hppa_reloc_final_type): Add protptype.
3281
e948afaf
AO
32822002-02-12 Alexandre Oliva <aoliva@redhat.com>
3283
3284 * elf-m10300.c (mn10300_elf_relax_section): Skip section before
3285 loading its contents if there's nothing to do in it.
3286
19397422
AM
32872002-02-12 Alan Modra <amodra@bigpond.net.au>
3288
0ad3a73b
AM
3289 * elf64-ppc.c (ppc64_elf_size_stubs): Correct test for crossing
3290 64k boundary.
3291
19397422
AM
3292 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Add dynamic
3293 DT_PPC64_OPD and DT_PPC64_OPDSZ tags.
3294 (ppc64_elf_finish_dynamic_sections): Set values for them.
3295
51316059
MS
32962002-02-11 Michael Snyder <msnyder@redhat.com>
3297
3298 * elf-bfd.h (elfcore_write_lwpstatus): Add prototype.
3299 * elf.c (elfcore_grok_pstatus): Add prototype.
3300 (elfcore_grok_lwpstatus): Add prototype.
3301 (elfcore_write_lwpstatus): New function.
3302 (elfcore_write_pstatus): Fix typo, eliminate unnecessary memcpy.
3303
518313c3
AO
33042002-02-11 Alexandre Oliva <aoliva@redhat.com>
3305
3306 * elf32-sh.c: Added missing prototypes.
3307 * elf32-sh64.c: Likewise.
3308 (sh_elf_align_loads): Mark unused args as such.
3309 * elf64-sh64.c: Added missing prototypes.
3310 (struct elf_sh64_link_hash_entry): Fix typo.
3311 (sh_elf64_relocate_section): Fix info argument passed to
3312 _bfd_elf_section_offset.
3313
2c73f9d8
AM
33142002-02-11 Alan Modra <amodra@bigpond.net.au>
3315
3316 * Makefile.am: "make dep-am".
3317 * Makefile.in: Regenerate.
3318 * aclocal.m4: Regenerate.
3319 * config.in: Regenerate.
3320 * configure: Regenerate.
3321
d426c6b0
DJ
33222002-02-10 Daniel Jacobowitz <drow@mvista.com>
3323
3324 * coff-rs6000.c (xcoff_generate_rtinit): Silence uninitialized
3325 variable warnings.
3326 * elf32-sh.c (sh_elf_relax_section): Silence signed/unsigned
3327 comparison warning.
3328 * trad-core.c (trad_unix_core_file_p): Silence pointer/integer
3329 cast warnings for the common case.
3330
e58ee0cd
HPN
33312002-02-10 Hans-Peter Nilsson <hp@bitrange.com>
3332
3333 * config.bfd (sh-*-linux*, sh-*-elf* | sh-*-rtemself*): Add sh64
3334 vectors.
3335 (sh-*-netbsdelf*): New, to trump sh*-*-netbsdelf* and add sh64
3336 vectors.
3337
7793f4d0
RH
33382002-02-09 Richard Henderson <rth@redhat.com>
3339
3340 * elf64-alpha.c (elf64_alpha_howto): Add R_ALPHA_BRSGP.
3341 (elf64_alpha_reloc_map, elf64_alpha_check_relocs): Likewise.
3342 (elf64_alpha_relocate_section): Likewise.
3343 * reloc.c (BFD_RELOC_ALPHA_BRSGP): New.
3344 * bfd-in2.h, libbfd.h: Rebuild.
3345
7e799044
HPN
33462002-02-09 Hans-Peter Nilsson <hp@bitrange.com>
3347
3348 * elf64-mmix.c (_bfd_mmix_finalize_linker_allocated_gregs): Check
3349 that base-plus-offset reloc accounting is consistent.
3350 (mmix_elf_relax_section): Keep base-plus-offset reloc accounting
3351 up to date for undefined symbols.
3352
027d73eb
EC
33532002-02-08 Eric Christopher <echristo@redhat.com>
3354
3355 From Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
3356
3357 * elf32-mips.c (_bfd_mips_elf_fake_sections): Don't create .rela
3358 sections for the O32 ABI.
3359
517662d4
CD
33602002-02-08 Chris Demetriou <cgd@broadcom.com>
3361
3362 * elf32-arm.h: Fix formatting of _("...").
3363 * elf32-d10v.c: Likewise.
3364 * elf32-m68k.c: Likewise.
3365 * elf32-mips.c: Likewise.
3366
5e37cc46
NC
33672002-02-08 Ivan Guzvinec <ivang@opencores.org>
3368
3369 * coff-or32.c: Fix compile time warning messages.
3370
fbca6ad9
AO
33712002-02-08 Alexandre Oliva <aoliva@redhat.com>
3372
3373 Contribute sh64-elf.
3374 2002-01-23 Alexandre Oliva <aoliva@redhat.com>
3375 * reloc.c (R_SH_GOTPLT32, R_SH_GOT_LOW16, R_SH_GOT_MEDLOW16,
3376 R_SH_GOT_MEDHI16, R_SH_GOT_HI16, R_SH_GOTPLT_LOW16,
3377 R_SH_GOTPLT_MEDLOW16, R_SH_GOTPLT_MEDHI16, R_SH_GOTPLT_HI16,
3378 R_SH_PLT_LOW16, R_SH_PLT_MEDLOW16, R_SH_PLT_MEDHI16,
3379 R_SH_PLT_HI16, R_SH_GOTOFF_LOW16, R_SH_GOTOFF_MEDLOW16,
3380 R_SH_GOTOFF_MEDHI16, R_SH_GOTOFF_HI16, R_SH_GOTPC_LOW16,
3381 R_SH_GOTPC_MEDLOW16, R_SH_GOTPC_MEDHI16, R_SH_GOTPC_HI16,
3382 R_SH_GOT10BY4, R_SH_GOTPLT10BY4, R_SH_GOT10BY8, R_SH_GOTPLT10BY8,
3383 R_SH_COPY64, R_SH_GLOB_DAT64, R_SH_JMP_SLOT64, R_SH_RELATIVE64):
3384 New relocs.
3385 * libbfd.h, bfd-in2.h: Rebuilt.
3386 * elf32-sh.c (sh_elf_howto_table): Define new relocs.
3387 (sh_reloc_map): Map them.
3388 (PLT_ENTRY_SIZE, elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
3389 elf_sh_plt_entry_be, elf_sh_plt_entry_le, elf_sh_pic_plt_entry_be,
3390 elf_sh_pic_plt_entry_le, elf_sh_plt0_entry, elf_sh_plt_entry,
3391 elf_sh_pic_plt_entry, elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
3392 elf_sh_plt0_gotplt_offset, elf_sh_plt_temp_offset,
3393 elf_sh_plt_symbol_offset, elf_sh_plt_reloc_offset,
3394 movi_shori_putval) [INCLUDE_SHMEDIA]: New.
3395 (elf_sh_link_hash_entry) [INCLUDE_SHMEDIA]: Add
3396 datalabel_got_offset.
3397 (sh_elf_link_hash_newfunc): Initialize it.
3398 (sh_elf_relocate_section): Augment the scope of
3399 seen_stt_datalabel. Introduce GOTPLT support. Extend GOTPC, PLT,
3400 GOT and GOTOFF handling to new SHmedia relocation types. Support
3401 GOT_BIAS.
3402 (sh_elf_check_relocs): Likewise.
3403 (sh_elf_finish_dynamic_symbol) [TARGET_SHMEDIA]: Set up values in
3404 PLT entries using movi_shori_putval. Support GOT_BIAS.
3405 (sh_elf_finish_dynamic_sections): Likewise.
3406 * elf32-sh64.c (shmedia_prepare_reloc): Do not add addend to
3407 relocation, it's now done by the caller.
3408 (GOT_BIAS): New.
3409 * elf64-sh64.c (GOT_BIAS, PLT_ENTRY_SIZE, elf_sh64_sizeof_plt,
3410 elf_sh64_plt_plt0_offset, elf_sh64_plt0_gotplt_offset,
3411 elf_sh64_plt_temp_offset, elf_sh64_plt_symbol_offset,
3412 elf_sh64_plt_reloc_offset, ELF_DYNAMIC_INTERPRETER,
3413 elf_sh64_pcrel_relocs_copied, elf_sh64_link_hash_entry,
3414 elf_sh64_link_hash_table, sh64_elf64_link_hash_traverse,
3415 sh64_elf64_hash_table): New.
3416 (sh_elf64_howto_table): Introduce new relocs.
3417 (sh_elf64_info_to_howto): Accept new PIC relocs.
3418 (sh_elf64_relocate_section): Augment the scope of
3419 seen_stt_datalabel. Support new PIC relocs.
3420 (sh_elf64_check_relocs): Support new PIC relocs.
3421 (elf_sh64_plt0_entry_be, elf_sh64_plt0_entry_le,
3422 elf_sh64_plt_entry_be, elf_sh64_plt_entry_le,
3423 elf_sh64_pic_plt_entry_be, elf_sh64_pic_plt_entry_le,
3424 elf_sh64_plt0_entry, elf_sh64_plt_entry, elf_sh64_pic_plt_entry,
3425 sh64_elf64_link_hash_newfunc, sh64_elf64_link_hash_table_create,
3426 movi_shori_putval, movi_3shori_putval,
3427 sh64_elf64_create_dynamic_sections,
3428 sh64_elf64_adjust_dynamic_symbol, sh64_elf64_discard_copies,
3429 sh64_elf64_size_dynamic_sections,
3430 sh64_elf64_finish_dynamic_symbol,
3431 sh64_elf64_finish_dynamic_sections): New.
3432 (elf_backend_create_dynamic-sections,
3433 bfd_elf64_bfd_link_hash_table_create,
3434 elf_backend_adjust_dynamic_symbol,
3435 elf_backend_size_dynamic_sections,
3436 elf_backend_finish_dynamic_symbol,
3437 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
3438 elf_backend_plt_readonly, elf_backend_want_plt_sym,
3439 elf_backend_got_header_size, elf_backend_plt_header_size):
3440 Define.
3441 2001-05-16 Alexandre Oliva <aoliva@redhat.com>
3442 * elf32-sh.c: Renumbered and renamed some SH5 relocations to
3443 match official numbers and names; moved unmaching ones to the
3444 range 0xf2-0xff.
3445 * elf32-sh64.c, elf64-sh64.c: Likewise.
3446 2001-03-12 DJ Delorie <dj@redhat.com>
3447 * elf32-sh.c (sh_elf_relax_section): Don't relax SHmedia
3448 sections.
3449 2001-03-12 DJ Delorie <dj@redhat.com>
3450 * elf32-sh64.c (shmedia_prepare_reloc): Validate relocs that must
3451 be aligned.
3452 * elf64-sh64.c (sh_elf64_relocate_section): Ditto.
3453 2001-01-14 Hans-Peter Nilsson <hpn@cygnus.com>
3454 * elf32-sh64.c (bfd_elf32_bfd_copy_private_section_data): Define.
3455 (sh64_elf_fake_sections): Set type to SHT_SH5_CR_SORTED for a
3456 .cranges section with SEC_SORT_ENTRIES set.
3457 (sh64_backend_section_from_shdr): Set SEC_SORT_ENTRIES on an
3458 incoming sorted .cranges section.
3459 (sh64_bfd_elf_copy_private_section_data): New.
3460 (sh64_elf_final_write_processing): Only sort .cranges and modify
3461 start address if called by linker.
3462 2001-01-08 Ben Elliston <bje@redhat.com>
3463 * elf32-sh64.c (sh64_elf_final_write_processing): Activate
3464 Hans-Peter Nilsson's set bit 0 patch from 2001-01-06.
3465 * elf64-sh64.c (sh64_elf64_final_write_processing): Ditto.
3466 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
3467 * elf64-sh64.c (sh_elf64_howto_table): No open brace at start of
3468 line. Add comments before all entries.
3469 <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct and clarify describing
3470 comment.
3471 (sh_elf64_reloc): Correct head comment.
3472 (sh_elf64_relocate_section): Correct spacing.
3473 <relocating for a local symbol>: Do not honour STO_SH5_ISA32;
3474 instead call reloc_dangerous callback.
3475 <case R_SH_SHMEDIA_CODE>: New case.
3476 (sh_elf64_gc_mark_hook): Correct spacing.
3477 (sh_elf64_check_relocs): Ditto.
3478 * elf32-sh64.c (shmedia_prepare_reloc) <case R_SH_SHMEDIA_CODE>:
3479 New case.
3480 * elf32-sh.c: Correct #endif comments for #ifndef-wrapped
3481 functions.
3482 (sh_elf_howto_table) <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct,
3483 clarify describing comment. Add comments before all entries.
3484 (sh_elf_relocate_section) <relocating for a local symbol>: Do not
3485 honour STO_SH5_ISA32; instead call reloc_dangerous callback.
3486 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
3487 Sort .cranges section in final link. Prepare to set bit 0 on
3488 entry address.
3489 * elf32-sh64.c (struct sh64_find_section_vma_data): New.
3490 (sh64_elf_link_output_symbol_hook): Fix typo in prototype.
3491 (sh64_elf_set_mach_from_flags): Set SEC_DEBUGGING on incoming
3492 .cranges section.
3493 (sh64_backend_section_from_shdr): New, to recognize
3494 SHT_SH5_CR_SORTED on incoming .cranges section.
3495 (elf_backend_section_from_shdr): Define.
3496 (sh64_elf_final_write_processing): Sort outgoing .cranges
3497 section. (New, temporarily disabled:) Set bit 0 on entry address
3498 according to ISA type.
3499 (sh64_find_section_for_address): New.
3500 (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb,
3501 crange_bsearch_cmpl): Move here from opcodes/sh64-dis.c.
3502 (sh64_address_in_cranges): Move here from opcodes/sh64-dis.c. Use
3503 bfd_malloc, not xmalloc.
3504 (sh64_get_contents_type): Move here from opcodes/sh64-dis.c. Make
3505 global.
3506 * elf32-sh64.c (sh64_elf64_final_write_processing): New, (but
3507 temporarily disabled) setting bit 0 on entry address.
3508 (elf_backend_final_write_processing): Define.
3509 2001-01-05 Hans-Peter Nilsson <hpn@cygnus.com>
3510 * elf32-sh.c (sh_elf_howto_table) <R_SH_PT_16>: Adjust fields to
3511 be a proper relocation for PTA and PTB rather than a marker.
3512 <R_SH_IMMU5, R_SH_IMMS6, R_SH_IMMU6, R_SH_IMMS10, R_SH_IMMS10BY2,
3513 R_SH_IMMS10BY4, R_SH_IMMS10BY8, R_SH_IMMS16, R_SH_IMMU16,
3514 R_SH_IMM_LOW16, R_SH_IMM_LOW16_PCREL, R_SH_IMM_MEDLOW16,
3515 R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16, R_SH_IMM_MEDHI16_PCREL,
3516 R_SH_IMM_HI16, R_SH_IMM_HI16_PCREL, R_SH_64, R_SH_64_PCREL>:
3517 Zero src_mask.
3518 * elf64-sh64.c: Ditto.
3519 (sh_elf64_relocate_section) <case R_SH_PT_16>: New case.
3520 * elf32-sh64.c: Include opcodes/sh64-opc.h
3521 (shmedia_prepare_reloc): Take a bfd_link_info pointer as first
3522 argument. Drop const qualifiers from "bfd *" and "bfd_byte *"
3523 parameters. No unused parameters. Caller changed.
3524 <case R_SH_PT_16>: New case.
3525 * Makefile.am (elf32-sh64.lo): Add dependency on sh64-opc.h.
3526 * Makefile.in: Regenerate.
3527 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
3528 * elf64-sh64.c (sh64_elf64_fake_sections): Set SHF_SH5_ISA32 for
3529 all code sections.
3530 (sh_elf64_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
3531 (sh64_elf_merge_private_data): Ditto.
3532 * elf32-sh64.c (sh64_elf_fake_sections): Use sh64_elf_section_data
3533 to access stored section flags.
3534 (sh64_elf_final_write_processing): Return immediately unless
3535 called by linker. Use sh64_elf_section_data (cranges) to get size
3536 of linker-generated cranges entries.
3537 (sh64_elf_copy_private_data): Add missing "return true".
3538 (sh64_elf_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
3539 (sh_elf64_merge_private_data): Ditto.
3540 2000-12-19 Hans-Peter Nilsson <hpn@cygnus.com>
3541 * elf64-sh64.c (sh64_elf64_fake_sections): New, copy of
3542 elf64-sh64.c:sh64_elf_fake_sections.
3543 (elf_backend_fake_sections): Define as sh64_elf64_fake_sections.
3544 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
3545 * elf32-sh64.c (sh64_elf_copy_private_data_internal): Delete.
3546 (sh64_elf_final_write_processing): New.
3547 (elf_backend_final_write_processing): Define.
3548 (sh64_elf_fake_sections): Get header flags from tdata field.
3549 (sh64_elf_copy_private_data): Do not call
3550 sh64_elf_copy_private_data_internal, just copy e_flags field.
3551 (sh64_elf_merge_private_data): Do not call
3552 sh64_elf_copy_private_data_internal.
3553 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
3554 Remove EF_SH64_ABI64, let ELF size make difference.
3555 Remove SH64-specific BFD section flag.
3556 * elf32-sh64.c (sh64_elf_fake_sections): Recognize section as
3557 containing SHmedia through elf_section_data (asect)->tdata
3558 non-zero, not using a BFD section flag.
3559 (sh64_elf_set_mach_from_flags): Don't recognize EF_SH64_ABI64.
3560 (sh64_elf_merge_private_data): Similar.
3561 (elf_backend_section_flags): Don't define.
3562 (sh64_elf_backend_section_flags): Delete.
3563 * elf64-sh64.c (sh_elf64_set_mach_from_flags): Recognize EF_SH64,
3564 not EF_SH64_ABI64.
3565 (sh_elf64_merge_private_data): Similar.
3566 * section.c (Section flags definitions): Don't define
3567 SEC_SH_ISA_SHMEDIA.
3568 (bfd-in2.h): Regenerate.
3569 2000-12-09 Hans-Peter Nilsson <hpn@cygnus.com>
3570 Make DataLabel references work with partial linking.
3571 * elf32-sh64.c: Fix formatting.
3572 (sh64_elf_link_output_symbol_hook): New.
3573 (elf_backend_link_output_symbol_hook): Define to
3574 sh64_elf_link_output_symbol_hook.
3575 (sh64_elf_add_symbol_hook): Make DataLabel symbol just global
3576 undefined if partial linking. Adjust sanity check.
3577 * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): New.
3578 (elf_backend_link_output_symbol_hook): Define to
3579 sh64_elf64_link_output_symbol_hook.
3580 (sh64_elf64_add_symbol_hook): Make DataLabel symbol just global
3581 undefined if partial linking. Adjust sanity check.
3582 2000-12-07 Hans-Peter Nilsson <hpn@cygnus.com>
3583 Implement semantics for inter-file DataLabel references.
3584 * elf64-sh64.c (DATALABEL_SUFFIX): Define.
3585 (sh64_elf64_add_symbol_hook): New.
3586 (sh_elf64_relocate_section): If passing an indirect symbol with
3587 st_type STT_DATALABEL on the way to a symbol with st_other
3588 STO_SH5_ISA32, do not bitor 1 to the relocation.
3589 (elf_backend_add_symbol_hook): Define to
3590 sh64_elf64_add_symbol_hook.
3591 * elf64-sh32.c: Tweak comments.
3592 (DATALABEL_SUFFIX): Define.
3593 (sh64_elf_add_symbol_hook): New.
3594 (elf_backend_add_symbol_hook): Define to sh64_elf_add_symbol_hook.
3595 * elf32-sh.c (sh_elf_relocate_section): If passing an indirect
3596 symbol with st_type STT_DATALABEL on the way to a symbol with
3597 st_other STO_SH5_ISA32, do not bitor 1 to the relocation.
3598 2000-12-05 Hans-Peter Nilsson <hpn@cygnus.com>
3599 Pass through STT_DATALABEL.
3600 * elf32-sh64.c (sh64_elf_get_symbol_type): New.
3601 (elf_backend_get_symbol_type): Define.
3602 * elf64-sh64.c (sh64_elf64_get_symbol_type): New.
3603 (elf_backend_get_symbol_type): Define.
3604 2000-11-30 Hans-Peter Nilsson <hpn@cygnus.com>
3605 * elf32-sh64.c: Tweak comments.
3606 (sh64_elf_copy_private_data_internal): Add prototype.
3607 (bfd_elf32_bfd_set_private_flags): Define.
3608 (sh64_elf_copy_private_data_internal): Compare machine name, not
3609 textual BFD target name, to check whether to copy section flag
3610 SHF_SH5_ISA32.
3611 (sh64_elf_merge_private_data): Validize bfd_get_arch_size.
3612 Tweak section-contents-type-mismatch message.
3613 (shmedia_prepare_reloc): Add ATTRIBUTE_UNUSED markers.
3614 Validize reloc-types.
3615 * elf64-sh64.c: New file.
3616 * targets.c (bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec): Declare.
3617 * Makefile.am (BFD64_BACKENDS): Add elf64-sh64.lo.
3618 (BFD64_BACKENDS_CFILES): Add elf64-sh64.c.
3619 Regenerate dependencies.
3620 * Makefile.in: Regenerate.
3621 * config.bfd (sh64-*-elf*): Add bfd_elf64_sh64_vec and
3622 bfd_elf64_sh64l_vec.
3623 * configure.in: Handle bfd_elf64_sh64_vec and
3624 bfd_elf64_sh64l_vec.
3625 * configure: Regenerate.
3626 * po/POTFILES.in: Regenerate.
3627 * po/bfd.pot: Regenerate.
3628 2000-11-29 Hans-Peter Nilsson <hpn@cygnus.com>
3629 * elf32-sh64.c (sh64_elf_set_mach_from_flags): Do not recognize
3630 anything else but EF_SH64 and EF_SH64_ABI64.
3631 (sh64_elf_merge_private_data): Emit error for anything else but
3632 EF_SH64 and EF_SH64_ABI64.
3633 * config.bfd: Remove bfd_elf32_shblin_vec and bfd_elf32_shlin_vec
3634 from targ_selvecs.
3635 * configure.in: Add cofflink.lo to bfd_elf32_sh64_vec and
3636 bfd_elf32_sh64l_vec as a temporary measure.
3637 * configure: Regenerate.
3638 2000-11-27 Hans-Peter Nilsson <hpn@cygnus.com>
3639 * cpu-sh.c (arch_info_struct): Include sh5 item
3640 unconditionalized.
3641 * config.bfd (sh64-*-elf*): Do not set targ_cflags.
3642 Add targ_selvecs bfd_elf32_sh_vec, bfd_elf32_shl_vec,
3643 bfd_elf32_shblin_vec and bfd_elf32_shlin_vec.
3644 * elf32-sh64.c: Tweak comments.
3645 (sh64_elf_set_mach_from_flags): Recognize all machine flags that
3646 are proper subsets of SH64 as bfd_mach_sh5. Add EF_SH64_ABI64.
3647 (sh64_elf_copy_private_data_internal): Wrap long line.
3648 (sh64_elf_merge_private_data): Rewrite to allow objects from
3649 SH64 subsets to be linked together.
3650 (INCLUDE_SHMEDIA): Define.
3651 * elf32-sh.c (sh_elf_relocate_section) <local symbol>:
3652 Parenthesize plus-expression inside or-expression.
3653 <global symbol>: Ditto.
3654 (sh_elf_set_mach_from_flags): Remove code refusing
3655 deleted EF_SH64_32BIT_ABI flag.
3656 2000-11-26 Hans-Peter Nilsson <hpn@cygnus.com>
3657 * elf32-sh.c (sh_elf_howto_table) <R_SH_IMM_LOW16_PCREL,
3658 R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16_PCREL,
3659 R_SH_IMM_HI16_PCREL, R_SH_64_PCREL>: Set pcrel_offset to true.
3660 (sh_elf_relocate_section) <local symbol>: Or 1 in
3661 calculation of relocation if sym->st_other & STO_SH5_ISA32.
3662 <global symbol>: Ditto if h->other & STO_SH5_ISA32.
3663 * elf32-sh64.c (shmedia_prepare_reloc): Add rel->r_addend to
3664 relocation.
3665 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
3666 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64.lo.
3667 (BFD32_BACKENDS_CFILES): Add elf32-sh64.c.
3668 Regenerate dependencies.
3669 * Makefile.in: Regenerate.
3670 * archures.c: Add bfd_mach_sh5.
3671 * config.bfd: Map targ_cpu sh* to bfd_sh_arch.
3672 Handle sh64-*-elf*. Set targ_cflags to -DINCLUDE_SHMEDIA.
3673 * configure.in: Handle bfd_elf32_sh64_vec and bfd_elf32_sh64l_vec.
3674 * configure: Regenerate.
3675 * reloc.c (BFD_RELOC_SH_SHMEDIA_CODE, BFD_RELOC_SH_IMMU5,
3676 BFD_RELOC_SH_IMMS6, BFD_RELOC_SH_IMMS6BY32, BFD_RELOC_SH_IMMU6,
3677 BFD_RELOC_SH_IMMS10, BFD_RELOC_SH_IMMS10BY2,
3678 BFD_RELOC_SH_IMMS10BY4, BFD_RELOC_SH_IMMS10BY8,
3679 BFD_RELOC_SH_IMMS16, BFD_RELOC_SH_IMMU16, BFD_RELOC_SH_IMM_LOW16,
3680 BFD_RELOC_SH_IMM_LOW16_PCREL, BFD_RELOC_SH_IMM_MEDLOW16,
3681 BFD_RELOC_SH_IMM_MEDLOW16_PCREL, BFD_RELOC_SH_IMM_MEDHI16,
3682 BFD_RELOC_SH_IMM_MEDHI16_PCREL, BFD_RELOC_SH_IMM_HI16,
3683 BFD_RELOC_SH_IMM_HI16_PCREL, BFD_RELOC_SH_PT_16): New relocations.
3684 * cpu-sh.c [INCLUDE_SHMEDIA] (arch_info_struct): Define and link
3685 in item for SH5.
3686 * elf32-sh.c [INCLUDE_SHMEDIA] (sh_elf_howto_table): Add howto items
3687 for SHmedia relocs.
3688 [INCLUDE_SHMEDIA] (sh_rel): Add mappings for SHmedia relocs.
3689 [INCLUDE_SHMEDIA] (sh_elf_relocate_section) [default]: Call
3690 shmedia_prepare_reloc, goto final_link_relocate if it returns
3691 non-zero, else fail as before.
3692 (sh_elf_set_mach_from_flags): Provide function only if not defined
3693 as macro. Do not recognize objects with EF_SH64_32BIT_ABI set.
3694 (sh_elf_set_private_flags): Provide function only if not defined
3695 as a macro.
3696 (sh_elf_copy_private_data): Similar.
3697 (sh_elf_merge_private_data): Similar.
3698 * section.c (SEC_SH_ISA_SHMEDIA): New.
3699 * targets.c (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec): Declare.
3700 * elf32-sh64.c: New file.
3701 * libbfd.h: Regenerate.
3702 * bfd-in2.h: Regenerate.
3703 * po/POTFILES.in: Regenerate.
3704 * po/bfd.pot: Regenerate.
3705 * bfd-in2.h: Regenerate.
3706 * libbfd.h: Regenerate.
3707
e108f470
DJ
37082002-02-07 Daniel Jacobowitz <drow@mvista.com>
3709
3710 * bfd-in.h: Update <stdbool.h> check to only see if <stdbool.h> has
3711 been included, not drag it in.
3712 * bfd-in2.h: Regenerate.
3713
259d18a3
L
37142002-02-06 H.J. Lu (hjl@gnu.org)
3715
3716 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Update
3717 the mach and ISA fields if necessary.
3718
f13b834e
NC
37192002-02-06 Nick Clifton <nickc@cambridge.redhat.com>
3720
3721 * coffcode.h (coff_set_arch_mach_hook): Select the highest known
3722 ARM architecture when an F_ARM_5 flag is detected, since we cannot
3723 be sure exactly which architecture this represents.
3724
82f6addb
NC
37252002-02-05 Nick Clifton <nickc@redhat.com>
3726
3727 * po/tr.po: Updated translation.
3728
899f54f5
AM
37292002-02-05 Alan Modra <amodra@bigpond.net.au>
3730
3731 From Jimi X <jimix@watson.ibm.com>
3732 * archures (bfd_mach_ppc64): Define.
3733 (bfd_powerpc_arch): Rename to bfd_powerpc_archs.
3734 (bfd_powerpc_arch): Define.
3735 * bfd-in2.h: Regenerate.
3736 * cpu-powerpc.c (arch_info_struct): Rename to bfd_powerpc_archs.
3737 (bfd_powerpc_arch): Move to tail of bfd_powerpc_archs.
3738 (bfd_powerpc_archs): Add default powerpc64 arch.
3739
248866a8
AM
37402002-02-05 Alan Modra <amodra@bigpond.net.au>
3741
3742 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Check for relocs
3743 against section syms in readonly sections. Don't do the global
3744 sym check if we find one.
3745 * elf64-s390.c (elf_s390_size_dynamic_sections): Likewise.
3746 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Likewise.
0a6958db 3747 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
248866a8
AM
3748 * elf32-s390.c (elf_s390_size_dynamic_sections): Likewise.
3749 (elf_s390_grok_prstatus): Add missing prototype.
3750
4fa5c2a8
HPN
37512002-02-04 Hans-Peter Nilsson <hp@bitrange.com>
3752
3753 * elf64-mmix.c (mmix_dump_bpo_gregs): New function.
3754 (mmix_elf_check_common_relocs) <case R_MMIX_BASE_PLUS_OFFSET>:
3755 Call bfd_get_section_by_name only once. Initialize
3756 bpodata->n_bpo_relocs_this_section.
3757 (_bfd_mmix_prepare_linker_allocated_gregs): Remove comment
3758 referring to DSOs.
3759 (bpo_reloc_request_sort_fn): Don't use difference of values as
3760 return-value.
3761
537c972e
DB
37622002-02-02 David O'Brien <obrien@FreeBSD>
3763
3764 * configure.in: Tweak the FreeBSD 4.x recognition more. Only treat
3765 version 4.5 and later the same as 5-CURRENT.
3766 * configure: Re-generate.
3767
006336b8
JT
37682002-02-02 Jason Thorpe <thorpej@wasabisystems.com>
3769
3770 * config.bfd (hppa*-*-netbsd*): New target.
3771
6c571f00
PT
37722002-01-31 Philipp Thomas <pthomas@suse.de>
3773
19397422
AM
3774 * coff-arm.c (coff_arm_merge_private_bfd_data): Move ERROR
3775 to front of message. Unify messages with elf32-arm.h. Use
3776 commas where neccessary.
3777 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Use all upcase
3778 ERROR in messages. Unify messages with coff-arm.c. Correct
3779 VFP/FPA error message.
3780 (elf32_arm_print_private_bfd_data): Don't mark APCS-26 and
3781 APCS-32 for translation.
6c571f00 3782
930b4cb2
HPN
37832002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
3784
3785 Perform on-demand global register allocation from
3786 R_MMIX_BASE_PLUS_OFFSET relocs.
3787 * elf64-mmix.c (struct bpo_reloc_section_info, struct
3788 bpo_reloc_request, struct bpo_greg_section_info): New.
3789 (mmix_elf_check_common_relocs, mmix_elf_gc_sweep_hook,
3790 bpo_reloc_request_sort_fn, mmix_elf_relax_section,
3791 _bfd_mmix_check_all_relocs,
3792 _bfd_mmix_prepare_linker_allocated_gregs,
3793 _bfd_mmix_finalize_linker_allocated_gregs): New functions.
3794 (elf_mmix_howto_table): Correct src_mask for most relocs.
3795 (mmix_elf_perform_relocation) <case R_MMIX_BASE_PLUS_OFFSET>: New
3796 case.
3797 (mmix_final_link_relocate) <case R_MMIX_BASE_PLUS_OFFSET>: New
3798 case. Fix typo in comment. New label do_mmix_reloc.
3799 (mmix_elf_check_relocs): Abuse bfd_link_info member base_file to
3800 store first object file with a base-plus-offset reloc. Call
3801 mmix_elf_check_common_relocs for the part common with mmo.
3802 (mmix_elf_final_link): Write out linker-allocated register
3803 contents section.
3804 (elf_backend_gc_sweep_hook): Define.
3805 (bfd_elf64_bfd_relax_section): Define.
3806
3807 * mmo.c: Don't include <ctype.h>
3808 (mmo_init): Correct init-once logic.
3809
3e36d993
TR
38102002-02-01 Tom Rix <trix@redhat.com>
3811
3812 * config.bfd: Conditionally support <aiaff> for pre AIX 4.3.
3813
ba323545
AM
38142002-02-01 Alan Modra <amodra@bigpond.net.au>
3815
3816 * Makefile.am: Run "make dep-am"
3817 * Makefile.in: Regenerate.
3818
012884d6
DB
38192002-01-31 David O'Brien <obrien@FreeBSD>
3820
3821 * configure.in: Recognize the differences in core files from FreeBSD
3822 4.{0,1} and later versions of 4.x. This treats 4.2+ the same as
3823 5-CURRENT.
3824 * configure: Regenerate.
3825
3b16e843
NC
38262002-01-31 Ivan Guzvinec <ivang@opencores.org>
3827
3828 * coff-or32.c: New file.
3829 * cpu-or32.c: New file.
3830 * elf32-or32.c: New file.
3831 * archures.c: Add support for or32.
3832 * targets.c: Add support for or32.
3833 * bfd-in2.h: Regenerate.
7dc0ab31 3834 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags,
3b16e843
NC
3835 coff_write_object_contents): Add support for or32.
3836 * config.bfd: Add target.
3837 * configure.in: Add support for or32.
3838 * configure: Regenerate.
3839 * Makefile.am: Add support for or32.
3840 * Makefile.in: Regenerate.
3b16e843
NC
3841 * po/SRC-POTFILES.in: Add or32 files.
3842 * po/bfd.pot: Regenerate.
7dc0ab31 3843
caf8ca8e
NC
38442002-01-31 Nick Clifton <nickc@cambridge.redhat.com>
3845 Don Lindsay <lindsayd@cisco.com>
3846
3847 * elf32-mips.c (mips_elf_calculate_relocation): Replace 'return
3848 false' with a return of a bfd_reloc_ error code.
3849
e5dfef09
HPN
38502002-01-31 Hans-Peter Nilsson <hp@axis.com>
3851
3852 * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Don't
3853 unexport unreferenced symbols when --export-dynamic. Call
3854 _bfd_elf_strtab_delref when unexporting.
3855
4e4770d0
DJ
38562002-01-30 Daniel Jacobowitz <drow@mvista.com>
3857
3858 * bfd-in.h: Include <stdbool.h> if it is available.
3859 * bfd-in2.h: Regenerated.
3860
e1fa50e7
AM
38612002-01-31 Alan Modra <amodra@bigpond.net.au>
3862
3863 * elf64-ppc.c (func_desc_adjust): STV_PROTECTED functions should
3864 not go via the plt.
3865
b5f79c76
NC
38662002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
3867
b5f79c76
NC
3868 * archures.c: Tidy up formatting of embedded comments.
3869 * bfd.c: Tidy up formatting of embedded comments.
7dc0ab31 3870 * bfd-in.h: Fix formatting of comments.
b5f79c76
NC
3871 * reloc.c: Tidy up formatting of ordinary & embedded comments.
3872 * section.c: Tidy up formatting of embedded comments.
3873 * syms.c: Tidy up formatting of embedded comments.
3874 * targets.c: Tidy up formatting of embedded comments.
3875
3876 * bfd-in2.h: Regenerate.
3877
ca09e32b
NC
38782002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
3879
3880 * vms-tir.c (cmd_name): New function.
3881 (tir_cmd_name): New function.
3882 (etir_sta, etir_sto, etir_opr, etir_stc): Use cmd_name().
3883 (tir_opr, tir_ctl, tir_cmd): use tir_cmd_name().
3884 Fix formatting.
7dc0ab31 3885
ca09e32b
NC
3886 * peXXigen.c (pe_print_idata): Rearrange message to aid in
3887 translation.
3888 (pe_print_pdata): Rearrange message to aid in translation.
3889
3890 * libbfd.c (warn_deprecated): Rearrange error message to aid in
3891 translation.
3892
3893 * ihex.c (ihex_write_object_contents): Fix spelling typo.
3894
3895 * ieee.c (ieee_slurp_external_symbols): Remove spurious space.
3896
3897 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Rearrange error
3898 message to aid in translation.
3899
3900 * elf64-mmix.c (mmix_final_link_relocate): Rearrange error message
3901 to aid in translation.
3902
3903 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix typo.
3904
7dc0ab31 39052002-01-30 Philipp Thomas <pthomas@suse.de>
ae1a89b7
PT
3906
3907 * coff-arm.c, elf32-elf.h: Unify messages.
3908
05f64ac6
NC
39092002-01-30 Nick Clifton <nickc@redhat.com>
3910
3911 * po/sv.po: Updated translation.
3912
f5a3e38a
NC
39132002-01-30 Philipp Thomas <pthomas@suse.de>
3914
3915 * dwarf2.c (read_abbrev): Use full section name in error message.
3916 (decode_line_info): Likewise.
661a3fd4
NC
3917
3918 * elf.c (_bfd_elf_symbol_from_bfd_symbol): Don't translate debugging
3919 message.
3920
d926e03d
AM
39212002-01-30 Alan Modra <amodra@bigpond.net.au>
3922
3923 * elf64-ppc.c (func_desc_adjust): Only provide missing function
3924 descriptor symbols for undefined function code syms. Clear
3925 ELF_LINK_NON_ELF so that they can stay weak.
3926
030d18fb 39272002-01-29 Chris Demetriou <cgd@broadcom.com>
7dc0ab31 3928 Mitch Lichtenberg <mpl@broadcom.com>
030d18fb
CD
3929
3930 * bfd-in.h (bfd_mips_elf32_create_embedded_relocs): New prototype.
3931 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): New function
3932 to handle 32-bit ELF embedded reloc (ld --embedded-relocs)
3933 generation.
3934 * bfd-in2.h: Regenerate.
3935
fcc76bea
CD
39362002-01-29 Chris Demetriou <cgd@broadcom.com>
3937
3938 * elf32-mips.c: Add additional comments about HI16 relocation
3939 processing.
3940 (_bfd_mips_elf_hi16_reloc): Don't subtract address here for
3941 pc-relative relocations. (Reverts change made on 2001-10-31.)
3942 (_bfd_mips_elf_lo16_reloc): Subtract address of LO16 part here
3943 for pc-relative relocations.
3944 (mips_elf_calculate_relocation): Add a comment about a kludge
3945 in the R_MIPS_GNU_REL_HI16 handling.
3946 (_bfd_mips_elf_relocate_section): Implement that kludge;
3947 adjust pc-relative HI16 relocation for difference in HI16 and
3948 LO16 addresses, since it can't easily be done in
3949 mips_elf_calculate_relocation.
3950
f9cd9119
MS
39512002-01-29 Martin Schwidefsky <schwidefsky@de.ibm.com>
3952
3953 * elf32-i386 (elf_i386_adjust_dynamic_symbol): Do not replace PLT32
3954 relocations with PC32 relocations for undefined or weak symbols.
3955 * elf32-s390 (elf_i386_adjust_dynamic_symbol): Likewise.
3956 * elf64-s390x (elf_i386_adjust_dynamic_symbol): Likewise.
3957
702248bb
JT
39582002-01-28 Jason Thorpe <thorpej@wasabisystems.com>
3959
3960 * elfcore.h (elf_core_file_p): Improve comment for last change.
3961
4867be41
DJ
39622002-01-27 Daniel Jacobowitz <drow@mvista.com>
3963
3964 * configure: Regenerated.
3965
a94cef6a
JT
39662002-01-27 Jason Thorpe <thorpej@wasabisystems.com>
3967
3968 * elfcore.h (elf_core_file_p): Set the machine architecture
3969 before processing the program headers.
3970
7562a296
HPN
39712002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
3972
966abd70
HPN
3973 * configure.in <64-bit configuration>: If using gcc, check and
3974 emit error for egcs-1.1.2.
3975 * configure: Regenerate.
3976
e8eab623
NC
39772002-01-26 Egor Duda <deo@logos-m.ru>
3978
3979 * elf.c (elfcore_grok_win32pstatus): Copy only as much information
3980 as possible to avoid stack corruption.
3981
73896efb
RH
39822002-01-26 Richard Henderson <rth@redhat.com>
3983
3984 * elf64-alpha.c (elf64_alpha_check_relocs): Don't set reltext
3985 for non-allocated sections.
3986
39872002-01-25 Mark Kettenis <kettenis@gnu.org>
c106e334
MK
3988
3989 * elf.c (elfcore_write_prstatus): Make sure we pass the address of
3990 prstat.pr_reg even if it is a struct.
3991
73896efb 39922002-01-25 Steve Ellcey <sje@cup.hp.com>
254ed743
NC
3993
3994 * bfd/elfxx-ia64.c: Reset AIX vector function overrides for HP-UX.
3995
3d66c4f7
NC
39962002-01-25 Philipp Thomas <pthomas@suse.de>
3997
3998 * coffgen.c (coff_print_symbol): Don't mark info message
3999 for translation.
4000
9460ecda
NC
40012002-01-25 Nick Clifton <nickc@redhat.com>
4002
4003 * po/fr.po: Updated translation.
4004 * po/es.po: Updated translation.
4005
cc9ff76a
AM
40062002-01-25 Philipp Thomas <pthomas@suse.de>
4007
4008 * coff-alpha.c (alpha_relocate_section): Unify warning message
4009 for GP relative relocations without GP defined.
4010 * coff-mips.c (mips_relocate_section): Likewise.
4011
c68836a9
AM
40122002-01-25 Alan Modra <amodra@bigpond.net.au>
4013
4014 * elf-eh-frame.c (_bfd_elf_eh_frame_section_offset): Avoid
4015 unsigned overflow when new_offset < old_offset.
4016
e8eab623 40172002-01-24 Philipp Thomas <pthomas@suse.de>
391154e9
NC
4018
4019 * bfd.c (_bfd_abort): Fix typo.
4020
8ba89f17
RH
40212002-01-23 Richard Henderson <rth@redhat.com>
4022
4023 * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't suppress
4024 plt entries for undefweak symbols.
4025
c6953948
NC
40262002-01-23 Steve Ellcey <sje@cup.hp.com>
4027
4028 * bfd/targets.c (bfd_elf32_ia64_hpux_big_vec): Add to
4029 DEFAULT_VECTOR.
4030 (bfd_elf64_ia64_hpux_big_vec): Ditto.
4031 (bfd_elf32_h8300_vec): Ditto.
4032
41bd81ab
AM
40332002-01-23 Alan Modra <amodra@bigpond.net.au>
4034
4035 * elf64-ppc.c: Remove stale part of ABI comment.
4036 (NO_OPD_RELOCS): Define.
4037 (ppc64_elf_check_relocs): Use it.
4038 (ppc64_elf_relocate_section): Here too.
4039 (build_one_stub): Don't point function syms at the stub. Instead,
4040 hijack plt.offset.
4041 (ppc64_elf_relocate_section): Check whether REL24 relocs should
4042 really go to the stub. Make all dynamic relocs in opd against
4043 locals.
4044 (ppc64_elf_finish_dynamic_symbol): Allow for non-standard use of
4045 plt.offset.
4046
f304919d
RH
40472002-01-22 Richard Henderson <rth@redhat.com>
4048
4049 * elf64-alpha.c (INSN_UNOP): Encode with RB as $sp.
4050
c0ef99a7
AM
40512002-01-22 Alan Modra <amodra@bigpond.net.au>
4052
60ee0d4a
AM
4053 * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Correct sign of
4054 TOC_BASE_OFF adjustment.
4055
c0ef99a7
AM
4056 * Makefile.am: Run "make dep-am".
4057 * Makefile.in: Regenerate.
4058 * po/SRC-POTFILES.in: Regenerate.
4059
64328b46
AM
40602002-01-22 John David Anglin <dave@hiauly1.hia.nrc.ca>
4061
4062 * configure.host (hppa*64*-*-hpux*, hppa*64*-*-linux*): Add new
4063 host defines.
4064
59953665 40652002-01-21 Hans-Peter Nilsson <hp@axis.com>
58255df3
HPN
4066
4067 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_32_GOTREL>:
4068 Check for and emit error if sgot is NULL at this point.
4069
9596feea
JT
40702002-01-21 Jason Thorpe <thorpej@wasabisystems.com>
4071
4072 * config.bfd (ia64*-*-netbsd*): New target.
4073
7b45c6e1
AM
40742002-01-21 Thomas Klausner <wiz@danbala.ifoer.tuwien.ac.at>
4075
4076 * som.c (som_write_space_strings): Comment typo fix.
4077
e5094212
AM
40782002-01-21 Alan Modra <amodra@bigpond.net.au>
4079
e86ce104
AM
4080 * elf64-ppc.c (struct ppc_link_hash_entry): Add is_func and
4081 is_func_descriptor fields.
4082 (link_hash_newfunc): Init them.
4083 (ppc64_elf_check_relocs): Only R_PPC24_REL24 syms starting with a
4084 dot are candidates for plt entries. When processing .opd relocs,
4085 set function descriptor strings to point inside function code
4086 string, and set new ppc_link_hash_entry fields.
4087 (ppc64_elf_gc_sweep_hook): Don't sweep R_PPC64_REL24 relocs.
4088 (ppc64_elf_adjust_dynamic_symbol): Remove most code dealing with
4089 function descriptors. It's now done in..
4090 (func_desc_adjust): New.
4091 (ppc64_elf_func_desc_adjust): New.
4092 (define elf_backend_always_size_sections): Define.
4093 (ppc64_elf_hide_symbol): New.
4094 (define elf_backend_hide_symbol): Define.
4095 (allocate_dynrelocs): Remove code looking up function descriptors
4096 as that has been done earlier.
4097 (ppc64_elf_size_dynamic_sections): Use htab shortcut to elf hash
4098 table.
4099 (ppc64_elf_finish_dynamic_symbol): Likewise. Remove code looking
4100 up function descriptor.
4101 (build_one_stub): Look up the function code sym. Check for
4102 invalid plt offsets.
4103 (ppc64_elf_relocate_section): Tweak calls to undefined weak syms.
4104 Convert R_PPC64_TOC relocs to R_PPC64_RELATIVE in shared libs.
4105
e5094212
AM
4106 * elf-bfd.h (elf_backend_data <elf_backend_hide_symbol>): Add
4107 boolean param.
4108 (_bfd_elf_link_hash_hide_symbol): Likewise.
4109 * elflink.h (elf_link_add_object_symbols): Adjust call to
4110 elf_backend_hide_symbol.
4111 (elf_fix_symbol_flags): Likewise.
4112 (elf_link_assign_sym_version): Likewise. Use bfd_malloc rather
4113 than bfd_alloc.
4114 * elf.c (_bfd_elf_link_hash_hide_symbol): Add "force_local" param.
4115 Set ELF_LINK_FORCED_LOCAL and call _bfd_elf_strtab_delref.
4116 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
4117 (clobber_millicode_symbols): Adjust to suit new hide_symbol.
4118 * elf32-cris.c (elf_cris_hide_symbol): Add "force_local" param
4119 and adjust to suit.
4120 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise, and call
4121 _bfd_elf_link_hash_hide_symbol rather than duplicating code.
4122 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
4123
40b8271b
AM
41242002-01-18 Alan Modra <amodra@bigpond.net.au>
4125
4126 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Test for a
4127 dynamic function descriptor symbol, not the associated function
4128 symbol.
4129
55baa95b
EC
41302002-01-17 Eric Christopher <echristo@redhat.com>
4131
4132 * elf32-mips.c (mips_elf_calculate_relocation): Fix typo.
4133
328577ad
NC
41342002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
4135
4136 * po/bfd.pot: Regenerate.
4137 * po/fr.po: Regenerate.
4138
af746e92
AM
41392002-01-17 Alan Modra <amodra@bigpond.net.au>
4140
4141 * elf-bfd.h (elf_backend_data <elf_backend_section_from_bfd_section>):
4142 Remove "Elf_Internal_Shdr *" param.
4143 (_bfd_mips_elf_section_from_bfd_section): Ditto.
4144 * elf32-mips.c (_bfd_mips_elf_section_from_bfd_section): Ditto.
4145 * elf32-m32r.c (_bfd_m32r_elf_section_from_bfd_section): Ditto.
4146 * elf32-v850.c (v850_elf_section_from_bfd_section): Ditto.
4147 * elf64-mmix.c (mmix_elf_section_from_bfd_section): Ditto.
4148 * elfxx-ia64.c (elfNN_hpux_backend_section_from_bfd_section): Ditto.
4149 * elf.c (_bfd_elf_section_from_bfd_section): Allow backend
4150 function to override special sections. Remove hdr arg from
4151 backend call, and don't loop.
4152
175e9962
EC
41532002-01-16 Eric Christopher <echristo@redhat.com>
4154
4155 * elf32-mips.c (mips_elf_calculate_relocation): Set require_jalxp
4156 on R_MIPS_26 and target is 16bit. Add R_MIPS16_GPREL to list of
4157 relocations requiring gp0 and gp.
4158
96a846ea
RE
41592002-01-16 Richard Earnshaw <rearnsha@arm.com>
4160
175e9962 4161 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Handle
96a846ea
RE
4162 EF_ARM_VFP_FLOAT.
4163 (elf32_arm_print_private_bfd_data): Likewise.
4164
af3ae48d
NC
41652002-01-16 Nick Clifton <nickc@cambridge.redhat.com>
4166
4167 * po/tr.po: Import new version.
4168
10ed1bba
AM
41692002-01-16 Alan Modra <amodra@bigpond.net.au>
4170
4171 * elf64-ppc.c (ppc64_elf_howto_raw): Remove stale FIXMEs.
4172 (ppc64_elf_reloc_type_lookup): Use proper CTOR reloc.
4173 (ORI_R0_R0_0): Correct.
4174
5d1634d7
AM
41752002-01-16 Alan Modra <amodra@bigpond.net.au>
4176
4177 * elflink.c (_bfd_elf_create_dynamic_sections): Don't set SEC_CODE
4178 when plt_not_loaded.
4179 * elf64-ppc.c (ppc64_elf_create_dynamic_sections): No need to
4180 clear .plt SEC_CODE here. Create .stub and correct .glink flags.
4181 (PLT_INITIAL_ENTRY_SIZE): Set to 24.
4182 (ppc64_elf_glink_code): Delete.
4183 (PPC64_ELF_GLINK_SIZE): Delete.
4184 (ADDIS_R12_R2, STD_R2_40R1, LD_R11_0R12, LD_R2_0R12, MTCTR_R11,
4185 BCTR, ADDIS_R12_R12_1, LD_R2_40R1, NOP, LI_R0_0, B_DOT, LIS_R0_0,
4186 ORI_R0_R0_0): Define.
4187 (PLT_CALL_STUB_SIZE, GLINK_CALL_STUB_SIZE): Define.
4188 (struct ppc_link_hash_table): Add sstub and plt_overflow.
4189 (ppc64_elf_link_hash_table_create): Init them.
4190 (ppc64_elf_check_relocs <R_PPC64_REL24>): Refcount .plt entry.
4191 Don't copy to shared lib.
4192 (ppc64_elf_check_relocs): Call bfd_set_error on errors.
4193 (ppc64_elf_gc_sweep_hook <R_PPC64_REL24>): Sweep plt refcount.
4194 (allocate_dynrelocs <plt>): Don't change function sym here. Make
4195 room for .stub and .glink code.
4196 (ppc64_elf_size_dynamic_sections): Handle .stub. Make entry for
4197 DT_PPC64_GLINK.
4198 (ppc64_elf_final_link): Rename to ppc64_elf_set_toc. Don't call
4199 bfd_elf64_bfd_final_link.
4200 (bfd_elf64_bfd_final_link): Don't define.
4201 (ppc64_elf_size_stubs): New.
4202 (build_plt_stub): New.
4203 (build_one_stub): New.
4204 (ppc64_elf_build_stubs): New.
4205 (ppc64_elf_relocate_section <toc relocs>): Remove assert.
4206 (ppc64_elf_relocate_section): Don't copy R_PPC64_REL24 relocs.
4207 (ppc64_elf_finish_dynamic_symbol): Don't build stubs here. Set
4208 DT_PPC64_GLINK entry. Tweak DT_PLTGOT, DT_JMPREL, DT_PLTRELSZ in
4209 case output sections not separate. Adjust DT_RELASZ to not
4210 include plt relocs. Set reserved got entry. Set got and plt
4211 entry size.
4212 (elf_backend_got_header_size): Set to 8.
4213 * elf64-ppc.h: New file.
4214
c601ffdb
AM
42152002-01-16 Alan Modra <amodra@bigpond.net.au>
4216
4217 * elf32-arm.h (elf32_arm_size_dynamic_sections): When removing
4218 sections, use bfd_section_list_remove.
4219 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
4220 * elflink.h (elf_link_add_object_symbols): When removing all
4221 sections, use bfd_section_list_clear.
4222
8fb4cb7f
NC
42232002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
4224
4225 * po/sv.po: New file: Swedish translation.
4226 * configure.in (ALL_LINGUAS): Add sv.
4227 * configure: Regenerate.
4228
d3c456e9
JJ
42292002-01-15 Jakub Jelinek <jakub@redhat.com>
4230
4231 * elflink.h (elf_link_input_bfd): Back out 2002-01-07 change.
4232 * elf.c (merge_sections_remove_hook): New function.
4233 (_bfd_elf_merge_sections): Pass it as 3rd argument to
4234 _bfd_merge_sections.
4235 * libbfd-in.h (_bfd_merge_sections): Add 3rd argument.
4236 * libbfd.h: Rebuilt.
4237 * merge.c (_bfd_merge_sections): Add remove_hook argument.
4238 Call remove_hook if a SEC_EXCLUDE section is encountered.
4239
1f7fd478
NC
42402002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
4241
4242 * elf32-xstormy16.c (xstormy16_reloc_map): Add new field 'table'.
4243 (xstormy16_reloc_map): Initialise new field with correct howto
4244 table.
4245 (xstormy16_reloc_type_lookup): Use 'table' field to locate correct
4246 howto entry.
4247
b87011e9
MS
42482002-01-10 Michael Snyder <msnyder@redhat.com>
4249
4250 * elf.c (elfcore_write_prstatus): Use long instead of pid_t;
4251 (elfcore_write_pstatus): Use long instead of pid_t;
4252 * elf-bfd.h: Change prototypes to use long instead of pid_t;
4253
175e9962 42542002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
b4db1224
JT
4255
4256 * elf.c: Update copyright years.
4257 (elfcore_grok_netbsd_note): Use NT_NETBSDCORE_PROCINFO
4258 and NT_NETBSDCORE_FIRSTMACH. Improve a comment.
4259
7c76fa91
MS
42602002-01-08 Michael Snyder <msnyder@redhat.com>
4261
4262 Add capability to write corefile note sections, for gdb.
4263 * elf.c (elfcore_write_note): New function.
4264 (elfcore_write_prpsinfo): New function.
4265 (elfcore_write_prstatus): New function.
4266 (elfcore_write_pstatus): New function.
4267 (elfcore_write_prfpreg): New function.
4268 (elfcore_write_prxfpreg): New function.
97996af6 4269 * elf-bfd.h: Add prototypes for above functions.
7c76fa91 4270
e1fddb6b
AO
42712002-01-08 Alexandre Oliva <aoliva@redhat.com>
4272
4273 * elf.c (elf_fake_sections): Propagate errors from
4274 elf_backend_fake_section.
4275
8d05742f
JT
42762002-01-07 Jason Thorpe <thorpej@wasabisystems.com>
4277
4278 * Makefile.am (BFD32_BACKENDS): Add elf32-sh-nbsd.lo.
4279 (BFD32_BACKENDS_CFILES): Add elf32-sh-nbsd.c.
4280 (elf32-sh-nbsd.lo): New rule.
4281 * Makefile.in: Regenerate.
4282 * config.bfd (sh*le-*-netbsdelf*): New target.
4283 (sh*-*-netbsdelf*): New target.
4284 * configure.in: Include netbsd-core.lo for native sh*-*-netbsd*.
4285 (bfd_elf32_shnbsd_vec): New vector.
4286 (bfd_elf32_shlnbsd_vec): New vector.
4287 * configure: Regenerate.
4288 * elf32-sh-nbsd.c: New file.
4289 * targets.c: Update copyright years.
175e9962 4290 (_bfd_target_vector): Add bfd_elf32_shlnbsd_vec and
8d05742f
JT
4291 bfd_elf32_shnbsd_vec.
4292
1dba4cb4
AH
42932002-01-07 Aldy Hernandez <aldyh@redhat.com>
4294
4295 * coff-rs6000.c (READ20): Use bfd_scan_vma.
4296
47b22aef
GK
42972002-01-07 Geoffrey Keating <geoffk@redhat.com>
4298
4299 * elflink.h (elf_link_input_bfd): Don't ask for the merged offset
4300 of a symbol in a section that will be deleted.
4301
be2d1673
NC
43022002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
4303
4304 * po/es.po: New file: Spanish translation.
4305 * configure.in (ALL_LINGUAS): Add es.
4306 * configure: Regenerate.
4307
d9cf1b54
AM
43082002-01-06 Steve Ellcey <sje@cup.hp.com>
4309
4310 * elfxx-ia64.c (is_unwind_section_name): Add target vector as
4311 argument so we can handle HP-UX specially.
4312 (elfNN_ia64_hpux_vec): New for use in is_unwind_section_name.
4313 (elfNN_hpux_backend_section_from_bfd_section): New for support
4314 of SHN_IA_64_ANSI_COMMON.
4315 (elfNN_ia64_relax_section): Add support for SHN_IA_64_ANSI_COMMON.
4316 (is_unwind_section_name): Add special HP-UX support.
4317 (elfNN_ia64_section_from_shdr): Add support for more sections.
4318 (elfNN_ia64_fake_sections): Modify is_unwind_section_name call and
4319 add support for more sections.
4320 (elfNN_ia64_additional_program_headers): Modify
4321 is_unwind_section_name call.
4322 (elfNN_ia64_modify_segment_map): Remove assumption that there is
4323 only one unwind section in segment.
4324
3f3c5c34
AM
43252002-01-06 Alan Modra <amodra@bigpond.net.au>
4326
4327 * syms.c (_bfd_generic_make_empty_symbol): New function.
4328 * libbfd-in.h (_bfd_nosymbols_make_empty_symbol): Define as
4329 _bfd_generic_make_empty_symbol.
4330 * libbfd.h: Regenerate.
4331 * bfd-in2.h: Regenerate.
4332 * hppabsd-core.c (hppabsd_core_make_empty_symbol): Delete function.
4333 (hppabsd_core_get_symtab_upper_bound): Don't define.
4334 (hppabsd_core_get_symtab): Likewise.
4335 (hppabsd_core_print_symbol): Likewise.
4336 (hppabsd_core_get_symbol_info): Likewise.
4337 (hppabsd_core_bfd_is_local_label_name): Likewise.
4338 (hppabsd_core_get_lineno): Likewise.
4339 (hppabsd_core_find_nearest_line): Likewise.
4340 (hppabsd_core_bfd_make_debug_symbol): Likewise.
4341 (hppabsd_core_read_minisymbols): Likewise.
4342 (hppabsd_core_minisymbol_to_symbol): Likewise.
4343 (hppabsd_core_vec): Use BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols).
4344 Formatting fixes.
4345 * hpux-core.c: Similarly.
4346 * irix-core.c: Similarly.
4347 * osf-core.c: Similarly.
4348 * sco5-core.c: Similarly.
4349 * binary.c (binary_make_empty_symbol): Remove function, define as
4350 _bfd_generic_make_empty_symbol.
4351 * ihex.c (ihex_make_empty_symbol): Likewise.
4352 * mmo.c (mmo_make_empty_symbol): Likewise.
4353 * ppcboot.c (ppcboot_make_empty_symbol): Likewise.
4354 * srec.c (srec_make_empty_symbol): Likewise.
4355 * versados.c (versados_make_empty_symbol): Likewise.
4356 * vms.c (_bfd_vms_make_empty_symbol): Remove.
4357 (vms_make_empty_symbol): Define as _bfd_generic_make_empty_symbol.
4358 * vms-gsd.c (_bfd_vms_slurp_gsd): Call bfd_make_empty_symbol
4359 rather than _bfd_vms_make_empty_symbol.
4360 * vms-misc.c (new_symbol): Likewise.
4361
3f0a7f7f
AM
43622002-01-05 Alan Modra <amodra@bigpond.net.au>
4363
9e7b37b3
AM
4364 * section.c (bfd_section_init): Remove unnecessary initialisations.
4365 (bfd_section_list_clear): New function.
4366 (bfd_section_list_remove, bfd_section_list_insert): New macros.
4367 (_bfd_strip_section_from_output): Use them.
4368 * coffcode.h (coff_set_alignment_hook): Likewise.
4369 * elf32-mips.c (_bfd_mips_elf_final_link): Likewise.
4370 * elf64-mips.c (mips_elf64_final_link): Likewise.
4371 * elf64-mmix.c (mmix_elf_final_link): Likewise.
4372 * sunos.c (sunos_add_dynamic_symbols): Likewise.
4373 * xcofflink.c (_bfd_xcoff_bfd_final_link): Likewise.
4374 * bfd-in2.h: Regenerate.
4375
4376 * netbsd-core.c (netbsd_core_file_p): Use bfd_make_section_anyway
4377 rather than doing our own section handling. Clean up after errors
4378 with bfd_release and bfd_section_list_clear. Handle unexpected
4379 flags.
4380 * aoutf1.h (sunos4_core_file_p): Likewise.
4381 * aix386-core.c (aix386_core_file_p): Likewise.
4382 * cisco-core.c (cisco_core_file_validate): Likewise.
4383 * ptrace-core.c (ptrace_unix_core_file_p): Likewise.
4384 * trad-core.c (trad_unix_core_file_p): Likewise.
4385
4386 * hppabsd-core.c (hppabsd_core_core_file_p): Clean up after errors
4387 with bfd_release and bfd_section_list_clear.
4388 * hpux-core.c (hpux_core_core_file_p): Likewise.
4389 * irix-core.c (irix_core_core_file_p): Likewise.
4390 * lynx-core.c (lynx_core_file_p): Likewise.
4391 * osf-core.c (osf_core_core_file_p): Likewise.
4392 * rs6000-core.c (rs6000coff_core_p): Likewise.
4393 * sco5-core.c (sco5_core_file_p): Likewise.
4394
3f0a7f7f
AM
4395 * elf32-mips.c (_bfd_mips_elf_lo16_reloc): Simplify, and perform
4396 sign extension adjustments without conditionals.
4397
a3aa38ee
JJ
43982002-01-04 Jakub Jelinek <jakub@redhat.com>
4399
4400 * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): Don't crash if
4401 CIE at .eh_frame start is removed due to no FDEs referencing it.
4402
8a8b2d4b
AJ
44032002-01-04 Jason Thorpe <thorpej@wasabisystems.com>
4404
4405 * config.bfd (x86_64-*-netbsd*): New target.
4406 * configure.in (x86_64-*-netbsd*): Set COREFILE
4407 to netbsd-core.lo.
4408 * configure: Regenerated.
4409
04b5af89
TR
44102002-01-03 Tom Rix <trix@redhat.com>
4411
4412 * xcofflink.c (_bfd_xcoff_bfd_final_link): Update .pad section ordering
4413 for recent bfd_make_section_anyway change.
4414
51c5503b
NC
44152002-01-03 Nick Clifton <nickc@cambridge.redhat.com>
4416
4417 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
4418 R_ARM_THM_PC11 reloc.
4419
07f7c046
NC
44202002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
4421
4422 * configure.in (LINGUAS): Add ja.
4423 * configure: Regenerate.
4424 * po/ja.po: Import from translation project's web site.
4425
5eefb65f
NC
44262002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
4427
4428 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Reformat error
4429 messages to ease translation into other languages.
4430
39e90f10 4431For older changes see ChangeLog-0001
56882138
AM
4432\f
4433Local Variables:
4434mode: change-log
4435left-margin: 8
4436fill-column: 74
4437version-control: never
4438End: