]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - bfd/ChangeLog
* config/tc-s390.c (md_apply_fix3): Emit error message for relocations
[thirdparty/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
a823975a
JJ
12003-01-18 Jakub Jelinek <jakub@redhat.com>
2
3 * elfxx-ia64.c (elfNN_ia64_relocate_section): Handle
4 R_IA64_TPREL64[LM]SB against non-global symbol properly.
5
b3dfd7fe
JJ
62003-01-16 Jakub Jelinek <jakub@redhat.com>
7
8 * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add
9 self_dtpmod_done and self_dtpmod_offset.
10 (allocate_global_data_got): Only use one got entry for all
11 dtpmod relocs against local symbols.
12 (allocate_dynrel_entries): Only need .rela.got entry for
13 dtpmod against global symbol.
14 (elfNN_ia64_size_dynamic_sections): Initialize self_dtpmod_offset.
15 Reserve space in .rela.got for the local dtpmod entry.
16 (set_got_entry): Initialize the common local dtpmod .got entry.
17 (elfNN_ia64_relocate_section): Handle R_IA_64_DTPREL64LSB
18 and R_IA_64_DTPREL64MSB.
19
04c9666a
AM
202003-01-16 Alan Modra <amodra@bigpond.net.au>
21
22 * elf64-ppc.c: Include elf/ppc64.h rather than elf/ppc.h.
23 (R_PPC_*): Rename all occurrences to R_PPC64_*.
24 (R_PPC64_ADDR30): Rename all occurrences to R_PPC64_REL30.
25 (enum elf_ppc_reloc_type): Ditto to enum elf_ppc64_reloc_type.
26 (ppc64_elf_gc_sweep_hook): Handle R_PPC64_REL30 along with other
27 relative relocs, not with absolute ones.
28 * Makefile.am: Run "make dep-am".
29 * Makefile.in: Regenerate.
30 * po/SRC-POTFILES.in: Regenerate.
31
c87f1ff7
AS
322003-01-15 Andreas Schwab <schwab@suse.de>
33
34 * elf32-ppc.c (ppc_elf_check_relocs): Don't set DF_TEXTREL for a
35 relocation against a non-allocated readonly section.
36
86bbe32f
AM
372003-01-10 Alan Modra <amodra@bigpond.net.au>
38
39 * elf32-ppc.c (ppc_elf_relocate_section): Adjust addend for GOT16_HA.
40 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise. PLTGOT16_HA too.
41
32d95f29
KD
422002-01-08 Klee Dienes <kdienes@apple.com>
43
44 * Makefile.am (ALL_MACHINES): Use cpu-msp430.lo, not cpu-msp430.c.
45 (BFD32_BACKENDS): Use elf32-msp430.lo, not elf32-msp430.c.
46 * Makefile.in: Regenerate.
47
ab7d0aa0
AO
482003-01-08 Alexandre Oliva <aoliva@redhat.com>
49
50 * elfn32-mips.c (prev_reloc_section): New.
51 (GET_RELOC_ADDEND): Use it. Parenthesize macro arguments.
52 (SET_RELOC_ADDEND): Parenthesize macro argument.
53
95d0f04a
DA
542003-01-07 John David Anglin <dave.anglin@nrc.gc.ca>
55
56 * elf32-hppa.c (final_link_relocate): For all DP relative relocations,
57 adjust addil instructions if the symbol has no section.
58
5c9e189c
DD
592003-01-07 DJ Delorie <dj@redhat.com>
60
61 * elf32-xstormy16.c (xstormy16_elf_howto_table): Make REL_12 not
62 partial_inplace.
63
3e829b4a
AS
642003-01-07 Andreas Schwab <schwab@suse.de>
65
66 * elf32-m68k.c (elf_m68k_check_relocs): Don't set DF_TEXTREL for
67 PC relative relocations.
68 (elf_m68k_discard_copies): Set it here instead.
69
a75473eb
SC
702002-01-02 Ben Elliston <bje@redhat.com>
71 Jeff Johnston <jjohnstn@redhat.com>
72
73 * Makefile.am (ALL_MACHINES): Add cpu-iq2000.lo.
74 (ALL_MACHINES_CFILES): Add cpu-iq2000.c.
75 (BFD32_BACKENDS): Add elf32-iq2000.lo.
76 (BFD32_BACKENDS_CFILES): Add elf32-iq2000.c.
77 (cpu-iq2000.lo): New target.
78 * Makefile.in: Regenerate.
79 * config.bfd: Handle iq2000-*-elf.
80 * archures.c (bfd_architecture): Add bfd_{arch,mach}_iq2000.
81 (bfd_archures_list): Add bfd_iq2000_arch.
82 * configure.in: Handle bfd_elf32_iq2000_vec.
83 * configure: Regenerate.
84 * reloc.c: Add BFD_RELOC_IQ2000_OFFSET_16, BFD_RELOC_IQ2000_OFFSET_21,
85 and BFD_RELOC_IQ2000_UHI16.
86 * targets.c (bfd_elf32_iq2000_vec): Declare.
87 (bfd_target_vector): Add bfd_elf32_iq2000_vec.
88 * elf.c (prep_headers): Set e_machine to EM_IQ2000.
89 * cpu-iq2000.c: New file.
90 * elf32-iq2000.c: Likewise.
91 * libbfd.h: Regenerate.
92 * bfd-in2.h: Likewise.
93
64543e1a
RS
942003-01-02 Richard Sandiford <rsandifo@redhat.com>
95
96 * elfxx-mips.c: Include libiberty.h.
97 (elf_mips_isa, _bfd_mips_elf_mach_extends_p): Remove.
98 (mips_set_isa_flags): New function, split out from...
99 (_bfd_mips_elf_final_write_processing): ...here. Only call
100 mips_set_isa_flags if the EF_MIPS_MACH bits are clear.
101 (mips_mach_extensions): New array.
102 (mips_32bit_flags_p): New function.
103 (_bfd_mips_elf_merge_private_bfd_data): Rework architecture checks.
104 Use mips_32bit_flags_p to check if one binary is 32-bit and the
105 other is 64-bit. When adopting IBFD's architecture, adopt the
106 bfd_mach as well as the flags.
107
4852a44e
NC
1082003-01-02 Nick Kelsey <nickk@ubicom.com>
109
110 * elf32-ip2k.c: Re-work of linker relaxation code for the ip2k to
111 fix internal errors, fix bad code generation, fix incorrect stabs
112 information, and improve ability to eliminate redundant page
113 instructions. Added code to ip2k_final_link_relocate to self-verify
114 the linker relaxation. Fix formatting problems.
115
af7ee8bf
CD
1162002-12-30 Chris Demetriou <cgd@broadcom.com>
117
118 * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mipsisa32r2 case.
119 * archures.c (bfd_mach_mipsisa32r2): New define.
120 * bfd-in2.h: Regenerate.
121 * cpu-mips.c (I_mipsisa32r2): New enum value.
122 (arch_info_struct): Add entry for I_mipsisa32r2.
123 * elfxx-mips.c (elf_mips_isa, _bfd_elf_mips_mach)
124 (_bfd_mips_elf_print_private_bfd_data): Handle E_MIPS_ARCH_32R2.
125 (_bfd_mips_elf_final_write_processing): Add
126 bfd_mach_mipsisa32r2 case.
127 (_bfd_mips_elf_merge_private_bfd_data): Handle merging of
128 binaries marked as using MIPS32 Release 2.
129
2469cfa2
NC
1302002-12-30 Dmitry Diky <diwil@mail.ru>
131
132 * Makefile.am: Add msp430 target.
133 * configure.in: Likewise.
134 * Makefile.in: Regenerate.
135 * configure: Regenerate.
136 * archures.c: Add msp430 architecture vector.
137 * config.bfd: Likewise.
138 * reloc.c: Add msp430 relocs.
139 * targets.c: Add msp320 target.
140 * cpu-msp430.c: New file: msp430 cpu detection.
141 * elf32-msp430.c: New file: msp430 reloc processing.
142 * bfd-in2.h: Regenerate.
143 * libbfd.h: Regenerate.
144
eecdbe52
JJ
1452002-12-28 Jakub Jelinek <jakub@redhat.com>
146
147 * elf.c (elf_sort_sections): Don't reorder .tbss.
148 (assign_file_positions_for_segments): Only adjust off/voff
149 for increased alignment in PT_LOAD or PT_NOTE segment,
150 but adjust p_filesz for .tbss too. in PT_LOAD consider
151 .tbss to have zero memory size.
152 (copy_private_bfd_data) [SECTION_SIZE]: Define.
153 [IS_CONTAINED_BY_VMA, IS_CONTAINED_BY_LMA]: Use it.
154 [INCLUDE_SECTION_IN_SEGMENT]: Only put SHF_TLS sections
155 into PT_TLS segment. Never put SHF_TLS sections in
156 segments other than PT_TLS or PT_LOAD.
157
158 * elf64-alpha.c (elf64_alpha_finish_dynamic_sections): Clear .plt
159 sh_entsize.
160
213e90f4
DD
1612002-12-23 DJ Delorie <dj@redhat.com>
162
163 * coff64-rs6000.c (xcoff64_ppc_relocate_section): Fix logic reversal.
164
75828352
AM
1652002-12-23 Alan Modra <amodra@bigpond.net.au>
166
167 * elflink.h (elf_link_output_extsym): Heed strip_discarded.
168
312b768e
NC
1692002-12-23 Nick Clifton <nickc@redhat.com>
170
171 * archures.c (bfd_arch_get_compatible): Add third parameter
172 'accept_unknowns'. Only accept unknown format BFDs if
173 accept_unknowns is true, or if the format is "binary".
174 * bfd-in2.h: Regenerate.
175
63222ec9
NC
1762002-12-21 Nick Clifton <nickc@redhat.com>
177
178 * coff-arm.c (coff_arm_relocate_section): Disable WINCE workaround
179 that subtracted 8 from pc relative relocations.
180
19852a2a
KH
1812002-12-20 Kazu Hirata <kazu@cs.umass.edu>
182
183 * coff-h8300.c: Fix comment typos.
184 * coffcode.h: Likewise.
185 * cpu-cris.c: Likewise.
186 * elf32-vax.c: Likewise.
187 * genlink.h: Likewise.
188 * linker.c: Likewise.
189 * som.c: Likewise.
190 * tekhex.c: Likewise.
191 * vms-misc.c: Likewise.
192
5fd63999
DD
1932002-12-20 DJ Delorie <dj@redhat.com>
194
195 * reloc.c: Add BFD_RELOC_XSTORMY16_12.
196 * libbfd.h: Regenerate.
197 * bfd-in2.h: Regenerate.
198 * elf32-xstormy16.c (xstormy16_elf_howto): Add R_XSTORMY16_12.
199 (xstormy16_reloc_map): Add R_XSTORMY16_12.
200
4ee79850
KH
2012002-12-19 Kazu Hirata <kazu@cs.umass.edu>
202
203 * doc/bfdint.texi: Fix typos.
204
66e25bab
AM
2052002-12-20 Paul Eggert <eggert@twinsun.com>
206
207 Port to POSIX 1003.1-2001.
208 * acinclude.m4 (AM_INSTALL_LIBBFD): Do not rely on "test -o".
209 * configure.in (build-warnings): Likewise.
210 (Horrible hacks to build DLLs on Windows): Do not rely on "tail -1".
211 * aclocal.m4: Regenerate.
212 * config.in: Regenerate.
213 * configure: Regenerate.
214
7dc77aaa
AM
2152002-12-19 Alan Modra <amodra@bigpond.net.au>
216
0171ee92
AM
217 * coff-h8300.c: Include libiberty.h.
218 (h8300_reloc16_extra_cases): Check the hash table creator before
219 referencing h8300 specific fields. Stash the hash table pointer
220 in a local var. Comment typo fixes.
221 (h8300_bfd_link_add_symbols): Likewise.
222
7dc77aaa
AM
223 * bfd/reloc.c (struct reloc_howto_struct): Revise src_mask and
224 dst_mask comments.
225 * bfd-in2.h: Regenerate.
226
47388f4c
AM
2272002-12-18 Alan Modra <amodra@bigpond.net.au>
228
229 * elf32-ppc.c (ppc_elf_relocate_section): Reorganize dynamic reloc
230 code a little. Comment on dynamic relocs against section symbols.
231
1b3e3744
AM
2322002-12-17 Roger Sayle <roger@eyesopen.com>
233
234 * configure.host (ia64-*-hpux*): Support 64 bit targets using
235 the HP compiler's "long long".
236
46f2b541
DD
2372002-12-16 Andrew MacLeod <amacleod@redhat.com>
238
239 * elf32-xstormy16.c (xstormy16_elf_howto): Add R_XSTORMY16_LO16
240 and R_XSTORMY16_HI16) howto entries.
241 (xstormy16_reloc_map): Map R_XSTORMY16_{LO,HI}16 to BFD_RELOC_{LO,HI}16.
1b3e3744 242 (xstormy16_info_to_howto_rela): Use R_XSTORMY16_GNU_VTINHERIT to
46f2b541
DD
243 determine the start of the second reloc table.
244
af738ea7
NC
2452002-12-16 Nathan Tallent <eraxxon@alumni.rice.edu>
246
247 * ecofflink.c: Fix the reading of the debugging information
248 of Tru64/Alpha binaries that are produced by recent Compaq
249 compilers.
250 (mk_fdrtab): Fix error in creating the FDR (file descriptor)
251 table.
252 (lookup_line): Because of the strange information sometimes
253 generated by Compaq's recent compilers, change how the FDR
254 table is searched so that PDRs (procedure descriptors) are
255 correctly found. Note that this change is really more of a hack;
256 however, I have included extensive documentation as to why
257 this is the best solution short of an extensive rewrite or
258 another hack.
259 (fdrtab_lookup): Add comments to explain the algorithm.
260
5354b572
AO
2612002-12-12 Alexandre Oliva <aoliva@redhat.com>
262
263 * elf-m10300.c (elf32_mn10300_link_hash_newfunc): Reorder
264 initializers to match struct declaration.
265
ab3acfbe
AM
2662002-12-12 Alan Modra <amodra@bigpond.net.au>
267
268 * dwarf2.c (comp_unit_contains_address): Comment typo fix.
269 * elf.c (get_program_header_size): Likewise.
270 * elf32-m32r.c (m32r_elf_lo16_reloc): Likewise.
271 (m32r_elf_generic_reloc): Likewise.
272 * elf32-ppc.c (ppc_elf_howto_init): Likewise.
273 * elflink.h (elf_bfd_discard_info): Likewise.
274
6348e046
AM
2752002-12-12 Alan Modra <amodra@bigpond.net.au>
276
277 * elf32-i386.c (elf_i386_finish_dynamic_sections): Add output_offset
278 to DT_JMPREL. Use srelplt input section size for DT_PLTRELSZ and
279 DT_RELSZ adjustment, not output section. Avoid writing tags when
280 unchanged. Don't assume linker script is sane, adjust DT_REL too.
281 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Just use raw
282 size of srelplt for DT_PLTRELSZ. Use srelplt input section size for
283 DT_RELASZ adjustment, not output section. Avoid writing tags when
284 unchanged. Adjust DT_RELA.
285 * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Tweaks for better
286 formatting. Avoid writing tags when unchanged. Adjust DT_RELA.
287
2e7a68a8
AO
2882002-12-12 Alexandre Oliva <aoliva@redhat.com>
289
290 * elfxx-mips.c (mips_elf_calculate_relocation): Don't divide
291 addend by 4.
292
b15e6682
AO
2932002-12-12 Alexandre Oliva <aoliva@redhat.com>
294
295 * elfxx-mips.c (struct mips_got_entry): New.
296 (struct mips_got_info): Added got_entries field.
297 (mips_elf_got_entry_hash, mips_elf_got_entry_eq): New functions.
298 (mips_elf_local_got_index, mips_elf_got_page,
299 mips_elf_got16_entry): Re-implement in terms of new...
300 (mips_elf_create_local_got_entry): Rewrite to use got_entries.
301 Change return type.
302 (mips_elf_highest): Warning clean-up.
303 (mips_elf_create_got_section): Initialize got_entries.
304 (_bfd_mips_elf_check_relocs): Use got_entries to estimate
305 local got size.
306 (_bfd_mips_elf_size_dynamic_sections): Do not account for
307 GOT_PAGE entries, since we now reuse GOT16 entries.
308
e6af3a53
NC
3092002-12-10 Jason Thorpe <thorpej@wasabisystems.com>
310
311 * aoutx.h (set_section_contents): Allow an otherwise unrepresentable
312 read-only section that lies after .text and before .data to be
313 written into the output file and included in a_text.
314 (translate_to_native_sym_flags): If an otherwise unrepresentable
315 section was merged with .text, convert its symbols to N_TEXT
316 symbols.
317 * libaout.h (aout_section_merge_with_text_p): New macro.
318
cf3d882d
AM
3192002-12-08 Alan Modra <amodra@bigpond.net.au>
320
321 * bfd-in.h: Comment typo fix. Formatting.
322 * bfd-in2.h: Regenerate.
323 * coff64-rs6000.c (xcoff64_openr_next_archived_file): Warning fix.
324 * elf32-m68hc12.c (m68hc12_elf_set_mach_from_flags): Prototype.
325 * elf64-mmix.c (mmix_dump_bpo_gregs): Warning fix.
326
2f9bd3f6
RH
3272002-12-05 Richard Henderson <rth@redhat.com>
328
329 * elfxx-ia64.c (elfNN_ia64_relax_section): Handle PCREL21BI.
330 Only send PCREL21B though the plt. Fix installed reloc type.
331 (elfNN_ia64_relocate_section): Give error for dynamic reloc
332 against PCREL22 or PCREL64I; clean up error messages for
333 branch relocs.
334
d0112f73
KB
3352002-12-04 Kevin Buettner <kevinb@redhat.com>
336
337 * elf64-mips.c (elf64_mips_grok_prstatus, elf64_mips_grok_psinfo):
338 New functions.
339 (elf_backend_grok_prstatus, elf_backend_grok_psinfo): Define.
340
c10d9d8f
JW
3412002-12-04 David Mosberger <davidm@hpl.hp.com>
342
343 * cpu-ia64-opc.c: Add operand constant "ar.csd".
344
d48770d4
L
3452002-12-04 H.J. Lu <hjl@gnu.org>
346
347 * elfxx-ia64.c (get_local_sym_hash): Use section ID instead of
348 BFD address when constructing local name.
349
b6152c34
AS
3502002-12-04 Andreas Schwab <schwab@suse.de>
351
352 * elf32-m68k.c (struct elf_m68k_link_hash_table): Add sym_sec
353 member.
354 (elf_m68k_link_hash_table_create): Initialize it.
355 (elf_m68k_check_relocs): Handle symbols that are forced to be
356 local due to visibility changes.
357 (elf_m68k_adjust_dynamic_symbol): Likewise.
358 (elf_m68k_size_dynamic_sections): Likewise.
359 (elf_m68k_discard_copies): Likewise.
360 (elf_m68k_relocate_section): Likewise.
361
73374ef1
AM
3622002-12-04 Alan Modra <amodra@bigpond.net.au>
363
364 * elf64-ppc.c (ppc64_elf_edit_opd): Correct typo.
365
c5c1944d
AM
3662002-12-04 Alan Modra <amodra@bigpond.net.au>
367
368 * srec.c (srec_write_symbols): Restore '$' prefix to address
369 accidentally removed in 2002-04-04 change.
370 (srec_get_symtab): Use 0 instead of `(long) FALSE'.
371
e1a9cb8e
NC
3722002-12-03 Nick Clifton <nickc@redhat.com>
373
374 * elf32-ppc.c (apuinfo_list_init): New function.
73374ef1
AM
375 (apuinfo_list_add): New function: Add a value to the list.
376 (apuinfo_list_length): New function: Return the number of
377 values on the list.
378 (apuinfo_list_element): New function: Return a value on the
379 list.
380 (apuinfo_list_finish): New function: Free the resources used
381 by the list.
382 (ppc_elf_begin_write_processing): New function. Scan the
383 input bfds for apuinfo sections.
384 (ppc_elf_write_section): New function: Delay the creation of
385 the contents of an apuinfo section in an output bfd.
386 (ppc_elf_final_write_processing): New function. Create the
387 contents of an apuinfo section in an output bfd.
388 (elf_backend_begin_write_processing): Define.
389 (elf_backend_final_write_processing): Define.
390 (elf_backend_write_section): Define.
e1a9cb8e 391
a823923b
RH
3922002-12-03 Richard Henderson <rth@redhat.com>
393
394 * cpu-ia64-opc.c (elf64_ia64_operands): Add ldxmov entry.
395
30491647
SC
3962002-12-01 Stephane Carrez <stcarrez@nerim.fr>
397
398 Fix PR savannah/1417:
399 * elf32-m68hc11.c (m68hc11_elf_relax_delete_bytes): Don't adjust
400 branch if it goes to the start of the deleted region.
401
bc7c6a90
SC
4022002-12-01 Stephane Carrez <stcarrez@nerim.fr>
403
404 * bfd-in2.h (bfd_mach_m6812): Rebuild.
405 * archures.c (bfd_mach_m6812_default, bfd_mach_m6812,
406 bfd_mach_m6812s): Declare.
407
408 * elf32-m68hc12.c (m68hc12_elf_set_mach_from_flags): New function.
409 (_bfd_m68hc12_elf_set_private_flags): Call it.
410 (_bfd_m68hc12_elf_print_private_bfd_data): Report processor version.
411 (_bfd_m68hc12_elf_merge_private_bfd_data): Merge the flags and
412 report microcontroller incompatibilities (HC12 vs HCS12).
413 (elf_backend_object_p): Update.
414
b34976b6
AM
4152002-11-30 Alan Modra <amodra@bigpond.net.au>
416
417 * bfd-in.h (TRUE_FALSE_ALREADY_DEFINED, BFD_TRUE_FALSE): Delete.
418 (enum bfd_boolean, boolean): Delete.
419 (bfd_boolean): Typedef to an int.
420 (FALSE, TRUE): Define.
421 * aix386-core.c, aix5ppc-core.c, aout-adobe.c, aout-arm.c, aout-cris.c,
422 aout-encap.c, aout-ns32k.c, aout-target.h, aout-tic30.c, aoutf1.h,
423 aoutx.h, archive.c, archive64.c, archures.c, bfd-in.h, bfd.c, bfdwin.c,
424 binary.c, bout.c, cache.c, cisco-core.c, coff-a29k.c, coff-alpha.c,
425 coff-apollo.c, coff-arm.c, coff-aux.c, coff-h8300.c, coff-h8500.c,
426 coff-i386.c, coff-i860.c, coff-i960.c, coff-ia64.c, coff-m68k.c,
427 coff-m88k.c, coff-mcore.c, coff-mips.c, coff-or32.c, coff-ppc.c,
428 coff-rs6000.c, coff-sh.c, coff-sparc.c, coff-stgo32.c, coff-tic30.c,
429 coff-tic4x.c, coff-tic54x.c, coff-tic80.c, coff-w65.c, coff-we32k.c,
430 coff-z8k.c, coff64-rs6000.c, coffcode.h, coffgen.c, cofflink.c,
431 corefile.c, cpu-a29k.c, cpu-alpha.c, cpu-arc.c, cpu-arm.c, cpu-avr.c,
432 cpu-cris.c, cpu-d10v.c, cpu-d30v.c, cpu-dlx.c, cpu-fr30.c, cpu-frv.c,
433 cpu-h8300.c, cpu-h8500.c, cpu-hppa.c, cpu-i370.c, cpu-i386.c,
434 cpu-i860.c, cpu-i960.c, cpu-ia64.c, cpu-ip2k.c, cpu-m10200.c,
435 cpu-m10300.c, cpu-m32r.c, cpu-m68hc11.c, cpu-m68hc12.c, cpu-m68k.c,
436 cpu-m88k.c, cpu-mcore.c, cpu-mips.c, cpu-mmix.c, cpu-ns32k.c,
437 cpu-openrisc.c, cpu-or32.c, cpu-pdp11.c, cpu-pj.c, cpu-powerpc.c,
438 cpu-rs6000.c, cpu-s390.c, cpu-sh.c, cpu-sparc.c, cpu-tic30.c,
439 cpu-tic4x.c, cpu-tic54x.c, cpu-tic80.c, cpu-v850.c, cpu-vax.c,
440 cpu-w65.c, cpu-we32k.c, cpu-xstormy16.c, cpu-z8k.c, dwarf1.c,
441 dwarf2.c, ecoff.c, ecofflink.c, efi-app-ia32.c, efi-app-ia64.c,
442 elf-bfd.h, elf-eh-frame.c, elf-hppa.h, elf-m10200.c, elf-m10300.c,
443 elf-strtab.c, elf.c, elf32-arc.c, elf32-arm.h, elf32-avr.c,
444 elf32-cris.c, elf32-d10v.c, elf32-d30v.c, elf32-dlx.c, elf32-fr30.c,
445 elf32-frv.c, elf32-gen.c, elf32-h8300.c, elf32-hppa.c, elf32-hppa.h,
446 elf32-i370.c, elf32-i386.c, elf32-i860.c, elf32-i960.c, elf32-ip2k.c,
447 elf32-m32r.c, elf32-m68hc11.c, elf32-m68hc12.c, elf32-m68k.c,
448 elf32-mcore.c, elf32-mips.c, elf32-openrisc.c, elf32-or32.c,
449 elf32-pj.c, elf32-ppc.c, elf32-s390.c, elf32-sh.c, elf32-sh64-com.c,
450 elf32-sh64.c, elf32-sparc.c, elf32-v850.c, elf32-vax.c,
451 elf32-xstormy16.c, elf64-alpha.c, elf64-gen.c, elf64-hppa.c,
452 elf64-mips.c, elf64-mmix.c, elf64-ppc.c, elf64-ppc.h, elf64-s390.c,
453 elf64-sh64.c, elf64-sparc.c, elf64-x86-64.c, elfarm-nabi.c,
454 elfarm-oabi.c, elfcode.h, elfcore.h, elflink.c, elflink.h,
455 elfn32-mips.c, elfxx-ia64.c, elfxx-mips.c, elfxx-mips.h,
456 elfxx-target.h, format.c, freebsd.h, genlink.h, hash.c, hp300hpux.c,
457 hppabsd-core.c, hpux-core.c, i386aout.c, i386linux.c, i386lynx.c,
458 i386mach3.c, i386msdos.c, i386os9k.c, ieee.c, ihex.c, irix-core.c,
459 libaout.h, libbfd-in.h, libbfd.c, libcoff-in.h, libecoff.h, libieee.h,
460 libnlm.h, liboasys.h, libpei.h, libxcoff.h, linker.c, lynx-core.c,
461 m68klinux.c, m68klynx.c, mach-o.c, mach-o.h, merge.c, mipsbsd.c,
462 mmo.c, netbsd-core.c, netbsd.h, nlm.c, nlm32-alpha.c, nlm32-i386.c,
463 nlm32-ppc.c, nlm32-sparc.c, nlmcode.h, oasys.c, opncls.c, osf-core.c,
464 pc532-mach.c, pdp11.c, pe-arm.c, pe-i386.c, pe-mcore.c, pe-mips.c,
465 pe-sh.c, peXXigen.c, pef.c, pei-arm.c, pei-i386.c, pei-mcore.c,
466 pei-mips.c, pei-sh.c, peicode.h, ppcboot.c, ptrace-core.c, reloc.c,
467 reloc16.c, riscix.c, rs6000-core.c, sco5-core.c, section.c, simple.c,
468 som.c, som.h, sparclinux.c, sparclynx.c, srec.c, stabs.c, sunos.c,
73374ef1 469 syms.c, targets.c, tekhex.c, ticoff.h, trad-core.c, versados.c,
b34976b6
AM
470 vms-gsd.c, vms-hdr.c, vms-misc.c, vms-tir.c, vms.c, vms.h,
471 xcoff-target.h, xcofflink.c, xsym.c, xsym.h: Replace boolean with
472 bfd_boolean, true with TRUE, false with FALSE. Simplify comparisons
473 of bfd_boolean vars with TRUE/FALSE. Formatting.
474 * bfd-in2.h, libbfd.h, libcoff.h: Regenerate
475
947216bf
AM
4762002-11-28 Alan Modra <amodra@bigpond.net.au>
477
478 * elf-bfd.h: Replace occurrences of Elf32_Internal_* and
479 Elf64_Internal_* with Elf_Internal_*. Replace Elf_Internal_Rel
480 with Elf_Internal_Rela.
481 * elf-hppa.h, elf-m10200.c, elf-m10300.c, elf32-arc.c, elf32-arm.h,
482 elf32-avr.c, elf32-cris.c, elf32-d10v.c, elf32-d30v.c, elf32-dlx.c,
483 elf32-fr30.c, elf32-frv.c, elf32-gen.c, elf32-h8300.c, elf32-hppa.c,
484 elf32-i370.c, elf32-i386.c, elf32-i860.c, elf32-i960.c, elf32-ip2k.c,
485 elf32-m32r.c, elf32-m68hc11.c, elf32-m68hc12.c, elf32-m68k.c,
486 elf32-mcore.c, elf32-mips.c, elf32-openrisc.c, elf32-or32.c,
487 elf32-ppc.c, elf32-s390.c, elf32-sh.c, elf32-v850.c, elf32-vax.c,
488 elf32-xstormy16.c, elf64-alpha.c, elf64-gen.c, elf64-hppa.c,
489 elf64-mips.c, elf64-mmix.c, elf64-ppc.c, elf64-s390.c, elf64-sh64.c,
490 elf64-sparc.c, elf64-x86-64.c, elfarm-nabi.c, elfarm-oabi.c,
491 elfcode.h, elflink.h, elfn32-mips.c, elfxx-ia64.c, elfxx-mips.c: Ditto.
492 * elf-hppa.h (elf_hppa_internal_shdr): Delete. Use Elf_Internal_Shdr
493 throughout instead.
494 * elf.c (_bfd_elf_no_info_to_howto_rel): Delete.
495 * elfcode.h (elf_swap_reloca_in): Pass source operand as a bfd_byte *.
496 Remove INLINE keyword.
497 (elf_swap_reloc_in): Likewise. Also clear r_addend.
498 (elf_swap_reloc_out, elf_swap_reloca_out): Pass destination operand
499 as a bfd_byte *.
500 (elf_write_relocs): Consolidate REL and RELA code.
501 (elf_slurp_reloc_table_from_section): Simplify REL code.
502 (NAME(_bfd_elf,size_info)): Populate reloc swap entries.
503 * elf-bfd.h (MAX_INT_RELS_PER_EXT_REL): Define.
504 * elflink.h (elf_link_read_relocs_from_section): Consolidate REL and
505 RELA code.
506 (elf_link_adjust_relocs): Likewise. Don't malloc space for temp
507 reloc array, use a fixed size of MAX_INT_RELS_PER_EXT_REL.
508 (elf_link_output_relocs): Likewise.
509 (elf_reloc_link_order): Likewise.
510 (elf_finish_pointer_linker_section): Likewise.
511 (struct elf_link_sort_rela): Remove union.
512 (elf_link_sort_cmp1): Update to suit.
513 (elf_link_sort_cmp2): Here too.
514 (elf_link_sort_relocs): Consolidate REL and RELA code. Fix memory
515 over-allocation for int_rels_per_ext_rel != 1 case.
516 * elf32-arm.h: Update all bfd_elf32_swap_reloc_out calls.
517 * elf32-i386.c: Likewise.
518 * elf32-cris.c: Likewise for bfd_elf32_swap_reloca_out.
519 * elf32-hppa.c, elf32-i370.c, elf32-m68k.c, elf32-ppc.c, elf32-s390.c,
520 elf32-sh.c, elf32-vax.c, elfxx-mips.c: Likewise.
521 * elf64-alpha.c: Likewise for bfd_elf64_swap_reloca_out.
522 * elf64-hppa.c, elf64-mips.c, elf64-ppc.c, elf64-s390.c, elf64-sh64.c,
523 elf64-sparc.c, elf64-x86-64.c: Likewise.
524 * elfxx-ia64.c: Likewise for bfd_elfNN_swap_reloca_out.
525 * elfxx-mips.c (sort_dynamic_relocs): Likewise for
526 bfd_elf32_swap_reloc_in.
527
528 * elf32-arm.h: Update elf32_arm_info_to_howto calls.
529 * elf32-mips.c: Likewise for mips_info_to_howto_rel.
530 (mips_elf64_swap_reloc_in): Zero r_addend.
531 (mips_elf64_be_swap_reloc_in): Likewise.
532 (mips_elf64_slurp_one_reloc_table): Simplify.
533
534 * elf64-alpha.c (alpha_elf_size_info): Populate reloc swap entries.
535 * elf64-hppa.c (hppa64_elf_size_info): Likewise.
536 * elf64-sparc.c (sparc64_elf_size_info): Likewise.
537
1448fa32
KK
5382002-11-28 Kaz Kojima <kkojima@rr.iij4u.or.jp>
539
540 * elf32-sh.c (sh_elf_relocate_section): Don't complain about
73374ef1 541 unresolved debugging relocs in dynamic applications.
1448fa32
KK
542 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
543
73722af0
AM
5442002-11-26 Alan Modra <amodra@bigpond.net.au>
545
546 * elf-eh-frame.c (ENSURE_NO_RELOCS): Disregard R_*_NONE relocs.
547 (_bfd_elf_discard_section_eh_frame): Don't discard duplicate CIEs
548 on a relocatable link. Comment typos.
549 * elf.c (_bfd_elf_link_hash_newfunc): Assign elements of structure
550 in the order they are declared. Clear elf_hash_value too.
551 (_bfd_elf_link_hash_table_init): Likewise assign in order. Clear
552 eh_info and tls_segment.
553 * elflink.h (elf_link_input_bfd <emit_relocs>): Keep reloc offsets
554 sorted when discarding relocs by turning them into R_*_NONE.
555
556 * libbfd.c (warn_deprecated): Comment spelling.
557 * po/SRC-POTFILES.in: Regenerate.
558
7c25b72c
RH
5592002-11-21 Richard Henderson <rth@redhat.com>
560
561 * elflink.h (elf_link_add_object_symbols): Don't overwrite the
562 arch's st_other bits when merging visibilities.
563 (elf_link_output_extsym): Tidy clearing of visibility field.
564
dc12c51f
AM
5652002-11-21 Alan Modra <amodra@bigpond.net.au>
566
567 * coff-mcore.c (SWAP_IN_RELOC_OFFSET): Define.
568 (SWAP_OUT_RELOC_OFFSET): Define.
569
963f13ec
AO
5702002-11-20 Alexandre Oliva <aoliva@redhat.com>
571
572 * elf.c (_bfd_elf_link_hash_table_init): Make sure
573 can_refcount is properly extended to the type of
574 init_refcount.
575
ee6423ed
AO
5762002-11-19 Alexandre Oliva <aoliva@redhat.com>
577
4ffba85c
AO
578 * elfxx-mips.c (MIPS_RELOC_RELA_P): New macro.
579 (_bfd_mips_elf_relocate_section): Use it.
580
ee6423ed
AO
581 * elfxx-mips.c (MNAME): New macro.
582 (_bfd_mips_elf_check_relocs): Use it.
583 (_bfd_mips_elf_discard_info): Likewise.
584 (_bfd_mips_elf_final_link): Likewise.
585
cdcf6e38
AM
5862002-11-19 Alan Modra <amodra@bigpond.net.au>
587
588 * elf64-ppc.c (ppc64_elf_edit_opd): When deleting relocs, adjust
589 rel_hdr.sh_size too.
590
93509525
KD
5912002-11-18 Klee Dienes <kdienes@apple.com>
592
593 * Makefile.am (BFD32_LIBS): Add bfdwin.lo, bfdio.lo.
594 (BFD32_LIBS_CFILES): Add bfdwin.c, bfdio.c.
595 (BFD_H_FILES): Add bfdwin.c, bfdio.c.
596 (LIBBFD_H_FILES): Add bfdwin.c, bfdio.c.
597 Add dependencies for bfdwin.c, bfdio.c.
598 * bfd.c: Remove bfd_get_mtime, bfd_get_size.
599 * libbfd.c: Remove real_read, bfd_bread, _bfd_window_internal,
600 bfd_init_window, bfd_free_window, bfd_get_file_window, bfd_bwrite,
601 bfd_tell, bfd_flush, bfd_stat, bfd_seek.
602 * bfdio.c: New file. Contains real_read, bfd_bread, bfd_write,
603 bfd_tell, bfd_flush, bfd_stat, bfd_seek, bfd_ge_mtime,
604 bfd_get_size (moved from libbfd.c and bfd.c).
605 * bfdwin.c New file. Contains _bfd_window_internal,
606 bfd_init_window, bfd_free_window, bfd_get_file_window (moved from
607 libbfd.c and bfd.c).
608 * po/SRC-POTFILES.in: Regenerate.
609 * po/bfd.pot: Regenerate.
610 * libbfd.h: Regenerate.
611 * bfd-in2.h: Regenerate.
612 * aclocal.m4: Regenerate.
613 * Makefile.in: Regenerate.
614 * configure: Regenerate.
615
3ae41454
AM
6162002-11-18 Klee Dienes <kdienes@apple.com>
617
618 * bfd.c (bfd_preserve_save): Don't zero BFD_IN_MEMORY.
619
e514ac71
NC
6202002-11-15 Kazu Hirata <kazu@cs.umass.edu>
621
622 * coff-h8300.c (h8300_reloc16_estimate): Do not optimize away
623 jsr after a short jump.
624 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
625
eddc4f81
KD
6262002-11-15 Klee Dienes <kdienes@apple.com>
627
628 * pef.c (bfd_pef_convert_architecture): Move declaration of
629 ARCH_POWERPC and ARCH_M68K to the start of the function.
630
51908eee
SS
6312002-11-14 Svein E. Seldal <Svein.Seldal@solidas.com>
632
633 * coff-tic4x.c (tic4x_howto_table): Formatting fixup
634
3416d2e7
HPN
6352002-11-14 Hans-Peter Nilsson <hp@bitrange.com>
636
637 * elf64-mmix.c (_bfd_mmix_finalize_linker_allocated_gregs):
638 For bpo_gregs_section->contents, allocate _raw_size, not
639 _cooked_size.
640
b1c58715
AM
6412002-11-13 Klee Dienes <kdienes@apple.com>
642
643 * config.bfd: Add entries for powerpc-*-darwin and cousins.
644
077ca68b
L
6452002-11-13 H.J. Lu <hjl@gnu.org>
646
647 * elfcode.h (elf_object_p): Don't restore abfd->arch_info.
648
e84d6fca
AM
6492002-11-13 Klee Dienes <kdienes@apple.com>
650 Alan Modra <amodra@bigpond.net.au>
651
652 * bfd.c (struct bfd_preserve): New.
653 (bfd_preserve_save): New function.
654 (bfd_preserve_restore): Ditto.
655 (bfd_preserve_finish): Ditto.
656 * bfd-in2.h: Regenerate.
657 * mach-o.c: Formatting.
658 (bfd_mach_o_scan_read_symtab_symbol): Make "value" unsigned.
659 (bfd_mach_o_object_p): Use bfd_preserve_save/restore/finish.
660 (bfd_mach_o_core_p): Ditto.
661 (bfd_mach_o_scan): Pass in mdata.
662 * mach-o.h (bfd_mach_o_scan): Update prototype.
663 * pef.c: Formatting.
664 (bfd_pef_object_p): Use bfd_preserve_save/restore/finish.
665 (bfd_pef_xlib_object_p): Ditto.
666 (bfd_pef_scan): Pass in mdata. Move version check to bfd_pef_object_p.
667 * pef.h (bfd_pef_scan): Update prototype.
668 * xsym.c: Formatting, K&R fixes.
669 (bfd_sym_object_p): Use bfd_preserve_save/restore/finish.
670 (bfd_sym_scan): New function split out from bfd_sym_object_p.
671 * xsym.h (bfd_sym_scan): Declare.
672 * elfcode.h (elf_object_p): Use bfd_preserve_save/restore/finish.
a7f84125 673 * elfcore.h (elf_core_file_p): Likewise.
e84d6fca
AM
674 * targets.c (_bfd_target_vector): Revert 2002-11-08 change.
675
cd24c222
NC
6762002-11-12 Nick Clifton <nickc@redhat.com>
677
678 * po/da.po: Updated Danish translation.
679
99eb2ac8
AM
6802002-11-12 Alan Modra <amodra@bigpond.net.au>
681
d6fe2dc1
AM
682 * elflink.h (elf_link_add_object_symbols): Optimize stabs for
683 relocatable link too.
684 (elf_link_input_bfd): When emitting relocs, adjust offsets for
685 eh_frame and stab sections. Zap deleted relocs.
686 (elf_reloc_symbol_deleted_p): Return true for zero r_symndx.
687 (elf_bfd_discard_info): Run for relocatable link too.
688 * elf64-ppc.c (ppc64_elf_edit_opd): Rename from edit_opd. Make global.
689 Handle ld -r case.
690 (ppc64_elf_size_dynamic_sections): Don't call edit_opd from here.
691 * elf64-ppc.h (ppc64_elf_edit_opd): Declare.
692
126495ed
AM
693 * elf-bfd.h (struct cie_header): Move from elf_eh-frame.c.
694 (struct cie, struct eh_cie_fde, struct eh_frame_sec_info): Likewise.
695 (struct eh_frame_array_ent, struct eh_frame_hdr_info): Likewise.
696 (enum elf_link_info_type): Remove ELF_INFO_TYPE_EH_FRAME_HDR.
697 (struct eh_frame_hdr_info): Add "hdr_sec", remove "split".
698 (struct elf_link_hash_table): Add eh_info.
699 (struct elf_obj_tdata): Change eh_frame_hdr to an asection *.
700 (_bfd_elf_discard_section_eh_frame): Update prototype.
701 (_bfd_elf_discard_section_eh_frame_hdr): Likewise.
702 (_bfd_elf_write_section_eh_frame): Likewise.
703 (_bfd_elf_write_section_eh_frame_hdr): Likewise.
704 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Remove "ehdrsec"
705 param. Get "hdr_info" from link hash table.
706 (_bfd_elf_discard_section_eh_frame_hdr): Remove "sec" param. Get
707 header section from link hash table. Save header section to elf_tdata.
708 (_bfd_elf_maybe_strip_eh_frame_hdr): Remove local "sec". Use
709 header section from link hash table. Don't alloc hdr_info. Clear
710 hdr_sec instead of setting "strip".
711 (_bfd_elf_eh_frame_section_offset): Formatting.
712 (_bfd_elf_write_section_eh_frame): Remove "ehdrsec", add "info" param.
713 Get header section from link hash table.
714 (_bfd_elf_write_section_eh_frame_hdr): Remove "sec", add "info" param.
715 Get header section from link hash table.
716 * elf.c (map_sections_to_segments): Use cached eh_frame_hdr.
717 (get_program_header_size): Likewise.
718 (_bfd_elf_section_offset): Formatting.
719 * elflink.h (elf_link_create_dynamic_sections): Stash eh frame header
720 section pointer in link hash table.
721 (elf_bfd_final_link): Adjust _bfd_elf_write_section_eh_frame_hdr
722 and _bfd_elf_write_section_eh_frame calls. Update comment about
723 eh_frame entries.
724 (elf_bfd_discard_info): Adjust _bfd_elf_discard_section_eh_frame and
725 _bfd_elf_discard_section_eh_frame_hdr calls. Remove "ehdr".
726
727 * po/SRC-POTFILES.in: Regenerate.
728
99eb2ac8
AM
729 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't zero
730 relocs for discarded FDEs. Remove dead code.
731 (_bfd_elf_write_section_eh_frame_hdr): Remove dead code.
732 * elflink.h (elf_bfd_discard_info): Don't save edited relocs.
733 Tidy conditions under which stabs are edited. Formatting.
734 * elf64-sparc.c (sparc64_elf_relocate_section): Ignore overflows
735 from discarded relocs.
736 * elfxx-ia64.c (elfNN_ia64_install_dyn_reloc): Add reloc output
737 section adjustments after testing magic values.
738
7c319a27
AM
7392002-11-12 Thomas Moestl <tmm@FreeBSD.org>
740
741 * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Correct
742 references to large plt symbols.
743
a95a4550
AM
7442002-11-12 Klee Dienes <kdienes@apple.com>
745
746 * mach-o.c (bfd_mach_o_scan_read_thread): Don't re-use 'i' when
747 looking for an unused section name.
748
bc7eab72
KH
7492002-11-11 Kazu Hirata <kazu@cs.umass.edu>
750
751 * coff-h8300.c: Fix formatting.
752 * elf32-h8300.c: Likewise.
753 * reloc16.c: Likewise.
754
52585bb8
AM
7552002-11-09 Jeroen Dobbelaere <jeroen.dobbelaere@acunia.com>
756
757 * elf32-arm.h (elf32_arm_size_dynamic_sections): Don't strip output
758 section when dynamic section unused; _bfd_strip_section_from_output
759 instead.
760
9f632188
AM
7612002-11-08 Alan Modra <amodra@bigpond.net.au>
762
207b304b
AM
763 * targets.c (_bfd_target_vector): Disable pef_vec, pef_xlib_vec
764 and sym_vec.
3b029f65 765
9f632188
AM
766 * dwarf2.c: Revert last change.
767
ec4530b5
NC
7682002-11-07 Michal Ludvig <mludvig@suse.cz>
769
770 * dwarf2.c (read_indirect_string, read_abbrevs, decode_line_info,
771 _bfd_dwarf2_find_nearest_line): Use
772 bfd_simple_get_relocated_section_contents() instead of
773 bfd_get_section_contents().
774 * reloc.c (bfd_perform_relocation): Add sanity check.
775 * simple.c (simple_get_relocated_section_contents): If the section
776 does not have any relocs associated with it, just return the
777 unadjusted contents.
778
205cfeb0
HPN
7792002-11-07 Hans-Peter Nilsson <hp@axis.com>
780
781 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_16_GOT,
782 case R_CRIS_32_GOT>: Correct test for filling in constant .got
783 contents, enabling for a non-DSO, for symbols defined in the
784 program with --export-dynamic.
785
87e226ce
AM
7862002-11-07 Alan Modra <amodra@bigpond.net.au>
787
788 * elf64-ppc.c: Comment typo fixes.
789 (ppc64_elf_merge_private_bfd_data): Allow BFD_ENDIAN_UNKNOWN input.
790
235c4794
NC
7912002-11-07 Nick Clifton <nickc@redhat.com>
792
793 * po/da.po: Updated Danish translation.
794
49179469
AO
7952002-11-06 Alexandre Oliva <aoliva@redhat.com>
796
797 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Generate
798 exactly three internal relocs per external reloc. Set reloc_count
799 to the external reloc count.
800
246178f2
NC
8012002-11-06 Klee Dienes <kdienes@apple.com>
802
3ae41454 803 * coff-stgo32.c (stub_bytes): Mark as const.
246178f2
NC
804 Fix comment formatting.
805
3af9a47b
NC
8062002-11-06 Klee Dienes <kdienes@apple.com>
807
3ae41454 808 * Makefile.am (BFD32_BACKENDS): Add mach-o.lo, pef.lo, and
3af9a47b
NC
809 xsym.lo.
810 (BFD32_BACKENDS_CFILES): Add mach-o.c, pef.c, and xsym.c.
811 (SOURCE_HFILES): Add mach-o.h, pef.h, pef-traceback.h, xsym.h
812 * archures.c (enum bfd_architecture): Add bfd_arch_m98k.
813 * bfd.c (struct bfd): Add private data for mach-o, pef, and sym.
814 * targets.c (enum bfd_flavour): Add flavours for mach-o, pef, and
815 sym.
3ae41454 816 (_bfd_target_vector): Add target vectors for mach-o, pef, and sym.
3af9a47b
NC
817 * Makefile.in: Regenerate.
818 * doc/Makefile.in: Regenerate.
3ae41454 819 * bfd-in2.h: Regenerate.
3af9a47b
NC
820 * xsym.c: New file. Contains support for the Apple/Metrowerks
821 xSYM debugging format.
822 * xsym.h: New file.
823 * pef.c: New file. Contains support for the Apple Code Fragment
824 Manager Preferred Executable Format
825 * pef.h: New file.
826 * pef-traceback.h: New file. Contains support for parsing PowerPC
827 traceback tables as used by PEF executables (and perhaps other
828 systems as well).
3ae41454 829 * mach-o.c: New file. Contains support for the Mach-O object file
3af9a47b
NC
830 format.
831 * mach-o.h: New file.
832 * mach-o-target.c: New file. Declares the mach-o targets
833 themselves. Included three times by mach-o.c; each time with a
834 different set of macros set.
3ae41454 835
b6821651 8362002-11-06 Graeme Peterson <gp@qnx.com>
911b232a
AM
837
838 * Makefile.am: Remove entries for elf32-qnx.[ch].
839 * Makefile.in: Regenerate.
840 * config.bfd: Change arm-nto to use bfd_elf32_{big|little}arm_vec,
841 ppc-nto to use bfd_elf32_powerpc{le}_vec, sh-nto to use
842 bfd_elf32_sh{l}_vec, and i386-nto to use bfd_elf32_i386_vec.
843 * configure.in: Remove support for bfd_elf32_sh{l}qnx_vec,
844 bfd_elf32_powerpc{le}qnx_vec, bfd_elf32_{big|little}armqnx_vec,
845 and bfd_elf32_i386qnx_vec, and removed elf32-qnx.lo from other targets.
846 bfd_elf32_sh{l}_vec, and i386-nto to use bfd_elf32_i386_vec.
847 * configure: Regenerate.
848 * elf32-qnx.c: Remove.
849 * elf32-qnx.h: Remove.
850 * elf.c: Remove calls to QNX specific set_nonloadable_filepos,
851 is_contained_by_filepos, and copy_private_bfd_data_p.
ad12c1c5
AM
852 * elf-bfd.h (struct elf_backend_data): Remove set_nonloadable_filepos,
853 is_contained_by_filepos, and copy_private_bfd_data_p.
911b232a
AM
854 * elf32-i386.c: Remove QNX extended bfd support.
855 * elf32-ppc.c: Remove QNX extended bfd support.
856 * elf32-sh.c: Remove QNX extended bfd support.
857 * elfarm-nabi.c: Remove QNX extended bfd support.
858 * targets.c: Remove qnx vectors.
859 * elfxx-target.h (elf_backend_set_nonloadable_filepos): Remove
860 (elf_backend_is_contained_by_filepos): Remove.
861 (elf_backend_copy_private_bfd_data_p): Remove.
862 * po/SRC-POTFILES.in: Regenerate.
863
b6821651
AM
8642002-11-06 David O'Brien <obrien@FreeBSD.org>
865 Alan Modra <amodra@bigpond.net.au>
866
867 * elf64-sparc.c (sparc64_elf_relocate_section): Adjust addend of
868 dynamic relocs against section symbols for the output section vma.
869
8702002-11-05 Alan Modra <amodra@bigpond.net.au>
871
872 * elf32-arm.h (t2a1_push_insn, t2a2_ldr_insn, t2a3_mov_insn,
873 t2a4_bx_insn, t2a5_pop_insn, t2a6_bx_insn): Remove.
874
08f74004
AM
8752002-11-05 Kaz Kojima <kkojima@rr.iij4u.or.jp>
876 Alan Modra <amodra@bigpond.net.au>
877
878 * config.bfd (sh-*-linux*): Use bfd_elf*_sh64*lin_vec as sh64
879 vectors in target_selvecs.
880 (shle-*-netbsdelf*): Use bfd_elf*_sh64*nbsd_vec as sh64 vectors
881 in target_selvecs.
882 (sh-*-netbsdelf*): Likewise.
883 * configure.in (assocvecs): New variable. Handle assocvecs like
884 selvecs.
885 * configure: Regenerate.
886 * format.c (bfd_check_format_matches): Store bfd_target pointers
887 in matching_vector instead of target names. Select first target
888 from bfd_associated_vector that matches a list of ambiguous targets.
889 * targets.c (_bfd_associated_vector): New array.
890 (bfd_associated_vector): New variable.
891 (_bfd_target_vector): Add bfd_elf*_sh64*lin_vec.
892 * libbfd-in.h (bfd_associated_vector): Declare.
893 * libbfd.h: Regenerate.
894
89117aab
AM
8952002-11-05 Elias Athanasopoulos <eathan@otenet.gr>
896
897 * vms-gsd.c (_bfd_vms_write_gsd): Check that symbol->udata.p is
898 non-NULL before dereferencing.
899
5e9aae3e
KK
9002002-11-04 Kaz Kojima <kkojima@rr.iij4u.or.jp>
901
902 * vms.c (vms_object_p): Restore the start address when returning
903 NULL.
904
c97e73dd
AM
9052002-11-04 Alan Modra <amodra@bigpond.net.au>
906 Hans-Peter Nilsson <hp@axis.com>
907
908 * elflink.h (struct elf_final_link_info): Add shndxbuf_size.
909 (elf_bfd_final_link): Don't bother zeroing symtab_hdr fields.
910 Set up a larger symshndxbuf, and write it out. Free it on
911 exit rather than freeing symbuf twice. Correct section index
912 on output section symbol loop.
913 (elf_link_output_sym): Accumulate symbol extension section
914 indices, reallocating symshndxbuf rather than writing it out.
915 (elf_link_flush_output_syms): Don't flush symshndxbuf.
916 * elf.c (assign_section_numbers): Init i_shdrp to all zero.
917 Use bfd_zalloc to clear i_shdrp[0] too.
918
3463048e
SC
9192002-11-03 Stephen Clarke <stephen.clarke@earthling.net>
920
921 * elf32-sh64-com.c (sh64_address_in_cranges): Use
922 _raw_size of cranges section if _cooked_size not yet set.
923
63a23799
HPN
9242002-11-03 Hans-Peter Nilsson <hp@axis.com>
925
926 * elf32-v850.c (v850_elf_relax_delete_bytes): Correct parameters
927 for bfd_elf32_swap_symbol_out.
928
e68cc12e
DB
9292002-10-31 David O'Brien <obrien@FreeBSD.org>
930
931 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't mix
932 signed and unsigned in comparison.
933
db4b6d01
DJ
9342002-10-30 Daniel Jacobowitz <drow@mvista.com>
935
936 * coffcode.h: Remove extraneous '\'.
937
840f0243
L
9382002-10-28 H.J. Lu <hjl@gnu.org>
939
940 * Makefile.am (targets.lo): Depend on Makefile instead of
941 config.status.
942 (archures.lo): Likewise.
943 * Makefile.in: Regenerated.
944
05a7e2db
JT
9452002-10-25 Jason Thorpe <thorpej@wasabisystems.com>
946
947 * config.bfd (mips*el-*-netbsd*, mips*-*-netbsd*): Add
948 bfd_elf64_bigmips_vec and bfd_elf64_littlemips_vec to
949 targ_selvecs.
950
a0087177
JW
9512002-10-25 Jim Wilson <wilson@redhat.com>
952
953 * elf64-sh64.c (sh_elf64_relocate_section): Call
954 _bfd_elf_rela_local_sym. Handle relocs against STT_SECTION symbol
955 of SHF_MERGE section.
956
8718ac9c
HPN
9572002-10-25 Hans-Peter Nilsson <hp@axis.com>
958
959 * simple.c: Correct placement of ATTRIBUTE_UNUSED.
960
d45913a0
DA
9612002-10-24 John David Anglin <dave@hiauly1.hia.nrc.ca>
962
963 * aoutx.h (NAME(aout,swap_ext_reloc_in)): Cast bytes->r_index to
964 unsigned int. Cast RELOC_BASE10, RELOC_BASE13 and RELOC_BASE22 to
965 unsigned int.
966 (NAME(aout,final_link)): Cast enum used in assignment.
967 (aout_link_write_symbols): Cast enums in comparisons, int values to
968 boolean, enums in assignments to int.
969 (aout_link_input_section_std): Cast rel->r_index to unsigned int.
970 (aout_link_input_section_ext): Likewise. Cast enums used in comparisons
971 with unsigned ints.
972 (aout_link_reloc_link_order): Cast enum to int in assignment.
973 * archive.c (_bfd_generic_read_ar_hdr_mag): Cast result of memchr
974 calls to char *.
975 * bfd-in.h (bfd_set_section_vma): Cast enum true to unsigned int in
976 assignment.
977 * bfd-in2.h (bfd_set_section_vma): Likewise.
978 * bfd.c (bfd_record_phdr): Cast enums in assignments.
979 * binary.c (bfd_alloc): Cast enum to long.
980 * coffgen.c (_bfd_coff_is_local_label_name): Cast return to boolean.
981 * dwarf2.c (read_abbrevs): Add casts to enum types.
982 (read_attribute_value): Likewise.
983 (arange_add): Cast result of bfd_zalloc call.
984 (comp_unit_contains_address): Return true and false.
985 (comp_unit_find_nearest_line): Cast return to boolean.
986 * format.c (bfd_check_format_matches, bfd_set_format): Likewise.
987 * gen-aout.c: define macro '_' if not defined.
988 * libbfd.c (bfd_realloc): Cast malloc and realloc to PTR.
989 (bfd_bwrite): Cast bfd_realloc to bfd_byte *.
990 (bfd_write_bigendian_4byte_int): Cast return to boolean.
991 (bfd_seek): Cast bfd_realloc to bfd_byte *.
992 (bfd_generic_is_local_label_name): Cast return to boolean.
993 * libcoff.h (_bfd_coff_adjust_symndx): Remove extraneous '\'.
994 * linker.c (_bfd_link_hash_newfunc): Cast bfd_hash_allocate result to
995 struct bfd_hash_entry *.
996 (_bfd_generic_link_hash_newfunc): likewise.
997 (_bfd_generic_final_link): Cast enum to unsigned int.
998 * merge.c (sec_merge_emit): Cast return to boolean.
999 (merge_strings): Add casts to const unsigned char *.
1000 * reloc.c (bfd_get_reloc_code_name): Cast enums in comparison to int.
1001 (bfd_generic_get_relocated_section_content): Cast enum to unsigned int.
1002 * section.c (bfd_section_hash_newfunc): Cast bfd_hash_allocate result to
1003 struct bfd_hash_entry *.
1004 (bfd_set_section_content): Add cast to PTR in comparison.
1005 * simple.c (simple_dummy_warning, simple_dummy_undefined_symbol,
1006 simple_dummy_reloc_overflow, simple_dummy_reloc_dangerous,
1007 simple_dummy_unattached_reloc,
1008 bfd_simple_get_relocated_section_contents): Add K&R declarations and
1009 function definitions.
1010 * srec.c (S3Forced): Initialize to false.
1011 (srec_get_symtab): Cast return value from bfd_alloc to asymbol *.
1012 * stabs.c (_bfd_link_section_stabs): Cast enum to int in comparisons.
1013 (_bfd_discard_section_stabs): Likewise. Also cast return to boolean.
1014 * syms.c (bfd_is_undefined_symclass): Cast return to boolean.
1015 (_bfd_stab_section_find_nearest_line): Cast enum to bfd_byte in
1016 comparisons.
1017
475c2a7e
JJ
10182002-10-23 Jakub Jelinek <jakub@redhat.com>
1019
1020 * elf64-alpha.c (elf64_alpha_check_relocs): Only put maybe_dynamic
1021 relocs into shared lib non-allocated reloc sections.
1022
e82ce529
AM
10232002-10-23 Nathan Tallent <eraxxon@alumni.rice.edu>
1024
1025 * dwarf2.c (add_line_info): Ensure that the line_info_table is
1026 sorted even when given an out-of-order line sequence.
1027 (lookup_address_in_line_info_table): When an exact VMA match is
1028 not found, return line information with the closest VMA.
1029
f2482cb2
NC
10302002-10-23 Ross Alexander <ross.alexander@uk.neceur.com>
1031
1032 * elf64-hppa.c: Force DT_FLAGS to always be set. Required by
1033 HPUX 11.00 patch PHSS_26559.
1034
c1fd6598
AO
10352002-10-22 Alexandre Oliva <aoliva@redhat.com>
1036
1037 * elfxx-mips.c (_bfd_mips_elf_modify_segment_map): Don't move
1038 the options section into a separate section unless IRIX 6
1039 compatibility is enabled.
1040
033fd5f9
AO
10412002-10-22 Alexandre Oliva <aoliva@redhat.com>
1042
1043 * elflink.h (struct elf_link_sort_rela): Turn rel and rela
1044 into arrays.
1045 (elf_link_sort_cmp1, elf_link_sort_cmp2): Adjust.
1046 (elf_link_sort_relocs): Likewise. Take int_rels_per_ext_rel
1047 into account.
1048 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Compose
1049 R_MIPS_REL32 with R_MIPS64 if ABI_64_P.
1050
ef485c01
AM
10512002-10-21 Graeme Peterson <gp@qnx.com>
1052
1053 * targets.c (_bfd_target_vector): Add missing qnx vectors.
1054
b50afec9
AM
10552002-10-21 Alan Modra <amodra@bigpond.net.au>
1056
1057 * targets.c (bfd_target_list): Don't return the default target twice.
1058
5fe39cae
AM
10592002-10-21 Elias Athanasopoulos <eathan@otenet.gr>
1060
1061 * archive.c (_bfd_archive_bsd_update_armap_timestamp): Replace
1062 perror with bfd_perror.
1063
5d603aa9
L
10642002-10-19 H.J. Lu <hjl@gnu.org>
1065
1066 * elflink.h (elf_link_add_object_symbols): Correctly handle
1067 DT_RPATH and DT_RUNPATH.
1068
e377ab71
MK
10692002-10-19 Mark Kettenis <kettenis@gnu.org>
1070
1071 * elf.c (elfcore_grok_note): Fix recognition on NT_PRXFPREG notes.
1072
0d09fec6
DC
10732002-10-17 Denis Chertykov <denisc@overta.ru>
1074
1075 * elf32-ip2k.c (ELF_MACHINE_ALT1): Define alternate machine code
1076 for ip2k port.
1077
acf8aed4
AM
10782002-10-17 Alan Modra <amodra@bigpond.net.au>
1079
1080 * elfxx-target.h (USE_REL): Don't define as 1.
1081 * elf32-arm.h (USE_REL): Provide a default define of 0.
1082 Use #if rather than #ifdef when testing USE_REL.
1083 * elf32-m32r.c: Likewise.
1084
1085 * elf32-arc.c (USE_REL): Define as 1.
1086 * elf32-d10v.c (USE_REL): Likewise.
1087 * elf32-m32r.c (USE_REL): Likewise.
1088 * elf32-m68hc11.c (USE_REL): Likewise.
1089 * elf32-m68hc12.c (USE_REL): Likewise.
1090 * elf32-or32.c (USE_REL): Likewise.
1091 * elfarm-nabi.c (USE_REL): Likewise.
1092
f52d1d64
JJ
10932002-10-16 Jakub Jelinek <jakub@redhat.com>
1094
1095 * config.bfd (s390-*-linux*): Add targ64_selvecs.
1096 (s390x-*-linux*): Add targ_selvecs.
1097
2bc3c89a
AM
10982002-10-16 Alan Modra <amodra@bigpond.net.au>
1099
1100 * Makefile.am (BFD32_BACKENDS): Remove elfarmqnx-nabi.lo,
5fe39cae 1101 elf32-i386-fbsd.lo, elf32-i386qnx.lo, elf32-ppcqnx.lo,
2bc3c89a
AM
1102 elf32-sh-lin.lo, elf32-sh64-lin.lo, elf32-sh-nbsd.lo,
1103 elf32-sh64-nbsd.lo, elf32-shqnx.lo. Add elf32-qnx.lo.
1104 (BFD32_BACKENDS_CFILES): Likewise for corresponding C files.
1105 (BFD64_BACKENDS): Remove elf64-sh64-lin.lo, elf64-sh64-nbsd.lo.
1106 (BFD64_BACKENDS_CFILES): Likewise for corresponding C files.
1107 (SOURCE_HFILES): Add elf32-qnx.h.
1108 (BUILD_HFILES): Add bfdver.h.
1109 Run "make dep-am".
1110 * Makefile.in: Regenerate.
1111 * configure.in Update bfd vector dependencies.
1112 * configure: Regenerate.
1113 * elf32-i386-fbsd.c: Delete. Move code to elf32-i386.c.
1114 * elf32-i386qnx.c: Likewise.
1115 * elf32-ppcqnx.c: Delete. Move code to elf32-ppc.c.
1116 * elf32-sh-nbsd.c: Delete. Move code to elf32-sh.c.
1117 * elf32-sh-lin.c: Likewise.
1118 * elf32-shqnx.c: Likewise.
1119 * elf32-sh64-lin.c: Delete. Move code to elf32-sh64.c.
1120 * elf32-sh64-nbsd.c: Likewise.
1121 * elf64-sh64-lin.c: Delete. Move code to elf64-sh64.c.
1122 * elf64-sh64-nbsd.c: Likewise.
1123 * elfarmqnx-nabi.c: Delete. Move code to elfarm-nabi.c.
1124 * elf32-arm.h (ELF_MAXPAGESIZE): Always define.
1125 * elf32-i386.c: Remove ELF_ARCH and ELF32_I386_C_INCLUDED tests.
1126 * elf32-ppc.c: Remove ELF32_PPC_C_INCLUDED tests.
1127 * elf32-qnx.h (elf_backend_set_nonloadable_filepos): Always define.
1128 (elf_backend_is_contained_by_filepos): Likewise.
1129 (elf_backend_copy_private_bfd_data_p): Likewise.
1130 Globalize and move functions to..
1131 * elf32-qnx.c: ..here. New file.
1132 * elf32-sh.c: Remove ELF_ARCH and ELF32_SH_C_INCLUDED tests. Don't
1133 emit target vectors when INCLUDE_SHMEDIA.
1134 * elf32-sh64.c: Remove ELF_ARCH test. Move TARGET_* etc. defines to
1135 end of file.
1136 * elf64-sh64.c: Remove ELF_ARCH test.
1137 * elfarm-nabi.c: Remove ELFARM_NABI_C_INCLUDED test.
1138 * po/BLD-POTFILES.in: Regenerate.
1139 * po/SRC-POTFILES.in: Regenerate.
1140
90c9df85
AM
11412002-10-16 Alan Modra <amodra@bigpond.net.au>
1142
366f2964
AM
1143 * elflink.h (elf_link_add_object_symbols): Error out on dynamic objects
1144 loaded with --just-symbols.
1145
90c9df85
AM
1146 * elf32-i386qnx.c (TARGET_LITTLE_NAME): Define.
1147 * elf32-ppcqnx.c (TARGET_LITTLE_NAME, TARGET_BIG_NAME): Define.
1148 * elf32-shqnx.c (TARGET_LITTLE_NAME, TARGET_BIG_NAME): Define.
1149 * elfarmqnx-nabi.c (TARGET_LITTLE_NAME, TARGET_BIG_NAME): Define.
1150
2238051f
RH
11512002-10-15 Richard Henderson <rth@redhat.com>
1152
1153 * Makefile.am (BFD64_BACKENDS): Remove elf64-alpha-fbsd.
1154 (BFD64_BACKENDS_CFILES): Likewise.
1155 * configure.in (bfd_elf64_alpha_freebsd_vec): Use elf64-alpha.
1156 * elf64-alpha-fbsd.c: Remove file, move code ...
1157 * elf64-alpha.c: ... here.
1158 * Makefile.in, configure: Rebuild.
1159
64e04ecd
RH
11602002-10-14 Richard Henderson <rth@redhat.com>
1161
1162 * elf64-alpha.c (elf64_alpha_relocate_section) [BRSGP]: Increment
1163 VALUE, not ADDEND.
1164
396a6083
SC
11652002-10-14 Stephen Clarke <stephen.clarke@superh.com>
1166
1167 * elf32-sh.c (elf_sh_link_hash_entry): Replace
1168 datalabel_got_offset with union of datalabel_got
1169 offset and refcount.
1170 (sh_elf_link_hash_newfunc): Initialize datalabel_got.refcount.
1171 (allocate_dynrelocs): Delete unnecessary code for
1172 STT_DATALABEL type. Create entry in got for
1173 datalabel version of symbol if datalabel_got.refcount > 0.
1174 (sh_elf_relocate_section): Use datalabel_got union.
1175 (sh_elf_gc_sweep_hook): Pull common code to initialize
1176 h and eh out of switch statement. Declare seen_stt_datalabel.
1177 Initialize it. Decrement datalabel_got.refcount for
1178 got relocs when seen_stt_datalabel is true.
1179 Decrement local_got_refcounts entry for datalabel got relocs
1180 of local symbols.
1181 (sh_elf_copy_indirect_symbol): Copy datalabel_got field over.
1182 (sh_elf_check_relocs): Declare seen_stt_datalabel.
1183 Initialize it. When seen_stt_datalabel is true, increment
1184 datalabel_got refcount rather than got.refcount.
1185 (sh_elf_finish_dynamic_symbol): Create relocs to
1186 initialize got entry for datalabel version of symbol.
1187
6a0735ef
AM
11882002-10-14 Alan Modra <amodra@bigpond.net.au>
1189
1190 * Makefile.am: Run "make dep-am".
1191 (BFD_H_FILES): Remove version.h.
1192 * bfd-in.h (BFD_VERSION, BFD_VERSION_DATE, BFD_VERSION_STRING): Move..
1193 * version.h: ..to here.
1194 * configure.in (bfd_version_date): Remove.
1195 (AC_OUTPUT): Make bfdver.h from version.h.
1196 * bfd.c: #include "bfdver.h".
1197 * vms-hdr.c: Likewise.
1198 * Makefile.in: Regenerate.
1199 * bfd-in2.h: Regenerate.
1200 * configure: Regenerate.
1201 * po/SRC-POTFILES.in: Regenerate.
1202
686e4055
AM
12032002-10-14 Alan Modra <amodra@bigpond.net.au>
1204
1205 * archures.c (bfd_mach_i386_i386, bfd_mach_i386_i8086,
1206 bfd_mach_i386_i386_intel_syntax, bfd_mach_x86_64,
1207 bfd_mach_x86_64_intel_syntax bfd_mach_ppc, bfd_mach_ppc64,
1208 bfd_mach_rs6k, bfd_mach_d10v, bfd_mach_sh, bfd_mach_v850,
1209 bfd_mach_arc_5, bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8,
1210 bfd_mach_m32r, bfd_mach_frv, bfd_mach_frvsimple,
1211 bfd_mach_ia64_elf64, bfd_mach_ia64_elf32,
1212 bfd_mach_ip2022, bfd_mach_ip2022ext,
1213 bfd_mach_s390_31, bfd_mach_s390_64, bfd_mach_xstormy16): Renumber.
1214 * bfd-in2.h: Regenerate.
1215
019dca2b
KK
12162002-10-14 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1217
1218 * config.bfd (sh*eb-*-linux*, sh*-*-linux*): Add the alternative
1219 endian vector to targ_selvecs.
1220
bce03d3d
AO
12212002-10-13 Alexandre Oliva <aoliva@redhat.com>
1222
1223 * elfxx-mips.c (mips_elf_calculate_relocation): Take
1224 save_addend argument. Don't apply the 32-bit mask to a
1225 GPREL32 value if it's to be used in another relocation. Don't
1226 use forced-check computation of local_p to decide whether to
1227 add gp0 to GPREL16 value. Don't use only the lowest 16 bits
1228 of the addend of a non-in-place GPREL16 relocation.
1229 (_bfd_mips_elf_relocate_section): Pass use_saved_addend_p to
1230 mips_elf_calculate_relocation().
1231
9b691193
SC
12322002-10-12 Stephane Carrez <stcarrez@nerim.fr>
1233
1234 * elf32-m68hc11.c (m68hc11_elf_relax_section): Don't treat relocs
1235 with symbols in other sections if we relaxed something; the sections
1236 output offsets must be re-computed before.
1237
1f4c5b47
SC
12382002-10-12 Stephane Carrez <stcarrez@nerim.fr>
1239
1240 * elf32-m68hc11.c (m68hc11_elf_relax_section): Update symbols
1241 handling to use Elf_Internal_Sym.
1242 (m68hc11_elf_relax_delete_bytes): Likewise.
1243
5dc97655
KK
12442002-10-11 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1245
1246 * elf32-sh.c (sh_elf_optimized_tls_reloc, sh_elf_mkobject,
1247 sh_elf_object_p, dtpoff_base): New functions.
1248 (sh_elf_howto_table): Add TLS relocs.
1249 (sh_reloc_map): Likewise.
1250 (sh_elf_info_to_howto): Support TLS relocs.
1251 (elf_sh_link_hash_entry): Add tls_type and tls_tpoff32.
1252 (sh_elf_hash_entry, sh_elf_tdata, sh_elf_local_got_tls_type):
1253 New macros.
1254 (sh_elf_obj_tdata): New.
1255 (elf_sh_link_hash_table): Add tls_ldm_got.
1256 (sh_elf_link_hash_table_create): Clear refcount of tls_ldm_got.
1257 (allocate_dynrelocs): Support TLS relocs.
1258 (sh_elf_size_dynamic_sections): Likewise.
1259 (sh_elf_relocate_section): Support TLS relocs. Don't try to find
1260 .rela.got section when found already. Return false after printing
1261 error about unresolvable relocation.
1262 (sh_elf_gc_sweep_hook): Support TLS relocs.
1263 (sh_elf_check_relocs): Likewise.
1264 (sh_elf_finish_dynamic_symbol): Likewise.
1265 (bfd_elf32_mkobject, elf_backend_object_p): Define for TLS case.
1266 * reloc.c: Add SH TLS relocs.
1267 * bfd-in2.h, libbfd.h: Regenerate.
1268
6a0735ef
AM
12692002-10-11 Daniel Jacobowitz <drow@mvista.com>
1270
1271 * Makefile.in: Regenerated.
1272
af39267e
DJ
12732002-10-11 Daniel Jacobowitz <drow@mvista.com>
1274
1275 * Makefile.am: Run dep-am.
6a0735ef 1276 (BFD_H_DEP): Add simple.c and linker.c.
af39267e
DJ
1277 (BFD32_LIBS): Add simple.lo.
1278 (BFD32_LIBS_CFILES): Add simple.c.
1279 * Makefile.in: Regenerated.
1280 * bfd-in2.h: Regenerated.
1281 * simple.c: New file.
1282
0be617ce
AM
12832002-10-11 Alan Modra <amodra@bigpond.net.au>
1284
14a793b2
AM
1285 * coff-arm.c (record_arm_to_thumb_glue): Avoid type-punned pointers.
1286 (record_thumb_to_arm_glue): Likewise.
1287 * ecoff.c (ecoff_link_add_externals): Likewise.
1288 * elf32-arm.h (record_arm_to_thumb_glue): Likewise.
1289 (record_thumb_to_arm_glue): Likewise.
1290 * elf32-m32r.c (m32r_elf_add_symbol_hook): Likewise.
1291 * elf32-sh.c (sh_elf_create_dynamic_sections): Likewise.
1292 * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
1293 * elf64-alpha.c (elf64_alpha_create_dynamic_sections): Likewise.
1294 * elf64-ppc.c (func_desc_adjust): Likewise.
1295 * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
1296 (sh64_elf64_create_dynamic_sections): Likewise.
1297 * elflink.c (_bfd_elf_create_got_section): Likewise.
1298 (_bfd_elf_create_dynamic_sections): Likewise.
1299 (_bfd_elf_create_linker_section): Likewise.
1300 * elflink.h (elf_add_default_symbol): Likewise.
1301 (elf_link_create_dynamic_sections): Likewise.
1302 (NAME(bfd_elf,size_dynamic_sections)): Likewise.
1303 * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Likewise.
1304 * elfxx-mips.c (mips_elf_create_got_section): Likewise.
1305 (_bfd_mips_elf_add_symbol_hook): Likewise.
1306 (_bfd_mips_elf_create_dynamic_sections): Likewise.
1307 * linker.c (generic_link_add_symbol_list): Likewise.
1308 * xcofflink.c (xcoff_link_add_symbols): Likewise.
1309
1310 * elfxx-ia64.c (oor_brl, oor_ip): Conditionally define.
1311
0be617ce 1312 * elf64-ppc.c (edit_opd): Only zero opd syms when function is
7f6a7663 1313 completely removed. Correct local sym adjustment.
0be617ce 1314
0a4ef3f4
SC
13152002-10-10 Stephen Clarke <stephen.clarke@superh.com>
1316
1317 * elf32-sh.c (elf_sh_pic_plt_entry_be, elf_sh_pic_plt_entry_le):
1318 Correct mistake in calculation of address of .got.
1319 * elf64-sh64.c (elf_sh64_pic_plt_entry_be,
1320 elf_sh64_pic_plt_entry_le): Likewise.
1321
efacd36e
SC
13222002-10-09 Richard Shann <richard.shann@superh.com>
1323 Stephen Clarke <stephen.clarke@superh.com>
1324
1325 * Makefile.am: Add entries for elf32-sh64-lin.c and
1326 elf64-sh64-lin.c. Regenerate.
1327 * Makefile.in: Regenerate.
1328 * config.bfd: Change sh64eb-*-linux* and sh64-*-linux*
1329 to use sh64 vectors rather than sh vectors.
1330 * configure.in: Add bfd_elf32_sh64lin_vec, bfd_elf32_sh64blin_vec,
1331 bfd_elf64_sh64lin_vec, bfd_elf64_sh64blin_vec.
1332 * configure: Regenerate.
1333 * elf32-sh64-lin.c: New file.
1334 * elf64-sh64-lin.c: New file.
1335 * targets.c: Add bfd_elf32_sh64lin_vec, bfd_elf32_sh64blin_vec,
5fe39cae
AM
1336 bfd_elf64_sh64lin_vec, bfd_elf64_sh64blin_vec.
1337
299bf759
L
13382002-10-08 H.J. Lu <hjl@gnu.org>
1339
1340 * elf32-i386.c (elf_i386_relocate_section): Re-arrange the
1341 IE->LE transition for R_386_TLS_IE.
1342
51020317
AM
13432002-10-08 Alan Modra <amodra@bigpond.net.au>
1344
1345 * elf64-ppc.c (edit_opd): Correct test for discarded sections.
1346
a8fcf378
NC
13472002-10-07 Mark Elbrecht <snowball3@softhome.net>
1348
51020317
AM
1349 * cofflink.c (mark_relocs): Don't mark relocations in excluded
1350 sections.
a8fcf378 1351
a16d5acb
AM
13522002-10-07 Alan Modra <amodra@bigpond.net.au>
1353
a6b511bd
AM
1354 * elflink.h (elf_link_input_bfd): Remove BFD_VERSION_DATE dependent
1355 code.
1356
a16d5acb
AM
1357 * elf64-ppc.c (ppc64_elf_build_stubs): Increment .glink indx.
1358
7c4a37eb
AM
13592002-10-06 Alan Modra <amodra@bigpond.net.au>
1360
1361 * opncls.c: Formatting.
1362 (_bfd_new_bfd): Use a smaller section hash table.
1363
7c4ca42d
AO
13642002-10-05 Alexandre Oliva <aoliva@redhat.com>
1365
1366 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Set the type
1367 of the other two relocations packed with a REL32 to NONE.
1368
4989d792
SC
13692002-10-02 Stephen Clarke <stephen.clarke@superh.com>
1370
1371 * elf32-sh.c (elf_sh_link_hash_entry): Add gotplt_refcount.
1372 (sh_elf_link_hash_newfunc): Initialize it.
1373 (allocate_dynrelocs): Transfer gotplt refs from plt.refcount
1374 to got.refcount for symbols that are forced local or when
1375 we have direct got refs.
1376 (sh_elf_gc_sweep_hook): Adjust gotplt_refcount. Use it
1377 to correctly adjust got.refcount and plt.refcount.
1378 (sh_elf_copy_indirect_symbol): Copy gotplt_refcount across.
1379 (sh_elf_check_relocs): Increment gotplt_refcount.
51020317 1380
7c445aa3
JJ
13812002-10-01 Jakub Jelinek <jakub@redhat.com>
1382
1383 * elf32-i386.c (elf_i386_relocate_section): Fix
1384 movl foo@indntpoff, %eax IE->LE transition.
1385
abcf1d52
JJ
13862002-10-01 Jakub Jelinek <jakub@redhat.com>
1387
1388 * elf64-x86-64.c (elf64_x86_64_relocate_section): Change TLSGD
1389 sequence and its transitions.
1390
a45bb67d
JJ
13912002-10-01 Jakub Jelinek <jakub@redhat.com>
1392
1393 * elf32-i386.c (elf_i386_relocate_section): Resolve R_386_TLS_LDO_32
1394 to st_value + addend in non-code sections.
1395 * elf64-x86-64.c (elf64_x86_64_relocate_section): Resolve
1396 R_X86_64_DTPOFF32 to st_value + addend in non-code sections.
1397
00707a0e 13982002-09-30 Gavin Romig-Koch <gavin@redhat.com>
51020317
AM
1399 Ken Raeburn <raeburn@cygnus.com>
1400 Aldy Hernandez <aldyh@redhat.com>
1401 Eric Christopher <echristo@redhat.com>
1402 Richard Sandiford <rsandifo@redhat.com>
00707a0e
RS
1403
1404 * archures.c (bfd_mach_mips4120, bfd_mach_mips5400): New.
1405 (bfd_mach_mips5500): New.
1406 * cpu-mips.c (I_mips4120, I_mips5400, I_mips5500): New.
1407 (arch_info_struct): Add corresponding entries here.
1408 * elfxx-mips.c (_bfd_elf_mips_mach): Handle E_MIPS_MACH_4120,
1409 E_MIPS_MACH_5400 and E_MIPS_MACH_5500.
1410 (_bfd_mips_elf_final_write_processing): Handle bfd_mach_mips4120,
1411 bfd_mach_mips5400 and bfd_mach_mips5500.
1412 (_bfd_mips_elf_mach_extends_p): New function.
1413 (_bfd_mips_elf_merge_private_bfd_data): Use it to help merge
1414 the EF_MIPS_MACH flags.
1415 * bfd-in2.h: Regenerate.
1416
624f0b25
JT
14172002-09-28 Jason Thorpe <thorpej@wasabisystems.com>
1418
1419 * elf32-vax.c (elf_vax_size_dynamic_section): Don't strip
1420 .got sections.
1421
b89fe0ee
AM
14222002-09-28 Alan Modra <amodra@bigpond.net.au>
1423
1424 * elf.c (map_sections_to_segments): Correct test for start of
1425 writable section in the same page as end of read-only section.
1426
b29635ba
JT
14272002-09-27 Matt Thomas <matt@3am-software.com>
1428
1429 * elf32-vax.c (elf_vax_check_relocs): Remove unused
1430 local_got_refcounts usage. Remove allocation of got slot.
1431 (elf_vax_gc_sweep_hook): Remove unused local_got_refcounts usage.
1432 Remove de-allocation of got slot.
1433 (elf_vax_size_dynamic_section): Fix some indentation. Add hash
1434 traversal for elf_vax_instantiate_got_entries. Allow empty .got
1435 sections to be GC'ed.
1436 (elf_vax_instantiate_got_entries): New function.
1437 (elf_vax_relocate_section): Simplify R_VAX_GOT32 handling. Remove
1438 tests that are now handled by elf_vax_instantiate_got_entries.
1439 Assert GOT entry falls within .got section size. Remove redundant
1440 comparisions. Fix comments.
1441
bffbf940
JJ
14422002-09-27 Jakub Jelinek <jakub@redhat.com>
1443
1444 * reloc.c: Add x86-64 TLS relocs.
1445 * bfd-in2.h, libbfd.h: Rebuilt.
1446 * elf64-x86-64.c (x86_64_elf_howto): Fix size fields for 32-bit
1447 relocs. Add TLS relocs.
1448 (x86_64_reloc_map): Add TLS relocs.
1449 (elf64_x86_64_info_to_howto): Adjust for added TLS relocs.
1450 (struct elf64_x86_64_link_hash_entry): Add tls_type field.
1451 (GOT_UNKNOWN, GOT_NORMAL, GOT_TLS_GD, GOT_TLS_IE): Define.
1452 (elf64_x86_64_hash_entry): Define.
1453 (struct elf64_x86_64_obj_tdata): New.
1454 (elf64_x86_64_tdata, elf64_x86_64_local_got_tls_type): Define.
1455 (struct elf64_x86_64_link_hash_table): Add tls_ld_got.
1456 (link_hash_newfunc): Initialize tls_type.
1457 (elf64_x86_64_link_hash_table_create): Initialize tls_ld_got.
1458 (elf64_x86_64_copy_indirect_symbol): Swap tls_type if necessary.
1459 (elf64_x86_64_mkobject): New.
1460 (elf64_x86_64_elf_object_p): Allocate struct elf64_x86_64_obj_tdata.
1461 (elf64_x86_64_tls_transition): New.
1462 (elf64_x86_64_check_relocs): Add r_type variable and use it.
1463 Handle TLS relocs.
1464 (elf64_x86_64_gc_sweep_hook): Handle TLS relocs.
1465 (allocate_dynrelocs): Allocate GOT space for TLS relocs.
1466 (elf64_x86_64_size_dynamic_sections): Likewise.
1467 (dtpoff_base, tpoff): New.
1468 (elf64_x86_64_relocate_section): Handle TLS relocs.
1469 (elf64_x86_64_finish_dynamic_symbol): Only handle non-TLS GOT
1470 entries.
1471 (bfd_elf64_mkobject): Define.
1472
1473 * elf32-i386.c (elf_i386_check_relocs) [R_386_TLS_LE]: Set
1474 DF_STATIC_TLS if shared.
1475
14366460
TS
14762002-09-26 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1477
1478 * elfxx-mips.c (_bfd_mips_elf_fake_sections): Don't emit unneeded
1479 empty relocation sections.
1480
9f951329
AM
14812002-09-26 Alan Modra <amodra@bigpond.net.au>
1482
1483 * elf64-ppc.c (ppc_build_one_stub): Don't build glink stubs here.
1484 (ppc64_elf_build_stubs): Build them here instead.
1485
6b3ac709
JJ
14862002-09-24 Jakub Jelinek <jakub@redhat.com>
1487
1488 * elf32-sparc.c (elf32_sparc_relocate_section): Put R_SPARC_RELATIVE
1489 addend into r_addend, not *r_offset.
1490 (elf32_sparc_finish_dynamic_symbol): Likewise.
1491 * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Clear xword at
1492 R_SPARC_RELATIVE's r_offset.
1493
e2f6d277
NC
14942002-09-23 Nathan Tallent <eraxxon@alumni.rice.edu>
1495
1496 * dwarf2.c (decode_line_info): Update to correctly decode
1497 the (non-standard DWARF2) out-of-order address sequences
1498 generated by the Intel C++ 6.0 compiler for ia64-Linux.
1499
f3961b2b
DD
15002002-09-23 Mark Elbrecht <snowball3@softhome.net>
1501
1502 * config.bfd: For DJGPP targets, match with any cpu and any machine.
1503
ad34bc37
AM
15042002-09-23 Alan Modra <amodra@bigpond.net.au>
1505
1506 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Zero relocs
1507 for discarded FDEs. Remove redundant assignment.
1508 * elflink.h (elf_bfd_discard_info): Save edited relocs.
1509
82988bff
L
15102002-09-22 H.J. Lu <hjl@gnu.org>
1511
1512 * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Don't merge
1513 the relocation count between different .reloc sections.
1514
5ad8645c
AM
15152002-09-21 Alan Modra <amodra@bigpond.net.au>
1516
5f819128
AM
1517 * elf32-ppc.c (ppc_elf_relocate_section): Allow ".sbss.*" and
1518 ".sdata.*" for R_PPC_SDAREL16, ".sbss2*" and ".sdata2*" for
1519 R_PPC_EMB_SDA2REL. Similarly for R_PPC_EMB_SDA21 and
1520 R_PPC_EMB_RELSDA.
1521
5ad8645c
AM
1522 * elfcode.h (elf_slurp_reloc_table_from_section): Make "symcount"
1523 unsigned. Move "symcount" assignment out of loop.
1524 * Makefile.am: Run "make dep-am".
1525 * Makefile.in: Regenerate.
1526 * configure: Regenerate.
1527 * po/SRC-POTFILES.in: Regnerate.
1528
75936555
NC
15292002-09-19 Nathan Tallent <eraxxon@alumni.rice.edu>
1530
1531 * dwarf2.c (_bfd_dwarf2_find_nearest_line): If address length is
1532 zero, set it to 8 for (non-standard) 64-bit DWARF2 formats
1533 (e.g. IRIX64).
1534
2243deae
L
15352002-09-19 Jakub Jelinek <jakub@redhat.com>
1536
1537 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Clear .got word
1538 even if generating R_PPC_RELATIVE reloc.
1539 (ppc_elf_relocate_section): Make sure relocation is performed
1540 if skip == -2. Clear memory at r_offset when creating dynamic
1541 relocation.
1542
37e55690
JJ
15432002-09-19 Jakub Jelinek <jakub@redhat.com>
1544
1545 * reloc.c (BFD_RELOC_386_TLS_TPOFF, BFD_RELOC_386_TLS_IE,
1546 BFD_RELOC_386_TLS_GOTIE): Add.
1547 * bfd-in2.h, libbfd.h: Rebuilt.
1548 * elf32-i386.c (elf_howto_table): Add R_386_TLS_TPOFF, R_386_TLS_IE
1549 and R_386_TLS_GOTIE.
1550 (elf_i386_reloc_type_lookup): Handle it.
1551 (struct elf_i386_link_hash_entry): Change tls_type type to unsigned
1552 char instead of enum, change GOT_* into defines.
1553 (GOT_TLS_IE_POS, GOT_TLS_IE_NEG, GOT_TLS_IE_BOTH): Define.
1554 (elf_i386_tls_transition): Handle R_386_TLS_IE and R_386_TLS_GOTIE.
1555 (elf_i386_check_relocs): Likewise. Avoid crash if local symbol is
1556 accessed both as normal and TLS symbol. Move R_386_TLS_LDM and
1557 R_386_PLT32 cases so that R_386_TLS_IE can fall through.
1558 Handle R_386_TLS_LE_32 and R_386_TLS_LE in shared libs.
1559 (elf_i386_gc_sweep_hook): Handle R_386_TLS_IE and R_386_TLS_GOTIE.
1560 Handle R_386_TLS_LE_32 and R_386_TLS_LE in shared libs.
1561 (allocate_dynrelocs): Allocate 2 .got and 2 .rel.got entries if
1562 tls_type is GOT_TLS_IE_BOTH.
1563 (elf_i386_size_dynamic_sections): Likewise.
1564 (elf_i386_relocate_section): Handle R_386_TLS_IE and R_386_TLS_GOTIE.
1565 Handle R_386_TLS_LE_32 and R_386_TLS_LE in shared libs.
1566 (elf_i386_finish_dynamic_symbol): Use tls_type & GOT_TLS_IE to catch
1567 all 4 GOT_TLS_* TLS types.
1568
8e67855b
NC
15692002-09-19 Nick Clifton <nickc@redhat.com>
1570
1571 * elflink.h (elf_fix_symbol_flags): When examining weak symbols,
1572 follow indirect links.
1573
1c59ba3f
NC
15742002-09-19 Nathan Tallent <eraxxon@alumni.rice.edu>
1575
1576 * ecoffswap.h (ecoff_swap_pdr_in) <isym, iline>: Update to
1577 correctly sign-extend 32-bit ECOFF null values (0xffffffff, -1)
1578 on 64 bit machines.
1579 (ecoff_swap_sym_in) <iss>: Likewise.
0e327d91
NC
1580 * ecoff.c (_bfd_ecoff_slurp_symbolic_info): Fix error reading
1581 ECOFF information: 'ioptMax' refers to the actual *size*
1582 of the optimization symtab, not the number of entries.
1c59ba3f 1583
9d7404b7
NC
15842002-09-19 Daniel Jacobowitz <drow@mvista.com>
1585
1586 * elf32-arm.h (elf32_arm_adjust_dynamic_symbol): Update
1587 ELF_LINK_HASH_NEEDS_PLT logic.
1588
05a487dc
DJ
15892002-09-18 Daniel Jacobowitz <drow@mvista.com>
1590
1591 * elfcode.h (elf_slurp_reloc_table_from_section): Check
1592 correct relocation count.
1593
1f70368c
DJ
15942002-09-17 Daniel Jacobowitz <drow@mvista.com>
1595
1596 * bfd-in.h (bfd_get_dynamic_symcount): Define.
1597 * bfd.c (struct _bfd): Add dynsymcount.
1598 * bfd-in2.h: Regenerated.
1599 * elf.c (_bfd_elf_canonicalize_dynamic_symtab): Set
1600 abfd->dynsymcount.
1601 * elfcode.h (elf_slurp_reloc_table_from_section): Check
1602 for overflow.
1603
51020317 16042002-09-17 Stan Cox <scox@redhat.com>
a902ee94
SC
1605
1606 * elf64-mips.c (mips_elf64_be_swap_reloca_out): Handle type2 and type3.
1607 (mips_elf64_final_gp): Don't make up gp value.
1608 * elfn32-mips.c (mips_elf_final_gp): Likewise.
1609 * elfxx-mips.c (_bfd_mips_elf_final_link): Always create
1610 .MIPS.options/.options section.
1611
290062cc
DB
16122002-09-17 David O'Brien <obrien@FreeBSD.org>
1613
1614 * elf32-i386-fbsd.c: Always label using the EI_OSABI method.
1615 It is benign for FreeBSD < 4.1. Minor reformatting.
1616 * elf64-alpha-fbsd.c: Likewise.
1617
c5c1f40c
JJ
16182002-09-17 Jakub Jelinek <jakub@redhat.com>
1619
ca1eb0ba
JJ
1620 * elf32-i386.c (elf_i386_relocate_section) [R_386_TLS_TPOFF32]: Negate
1621 addend.
c5c1f40c 1622
562ace6b
AM
16232002-09-17 Alan Modra <amodra@bigpond.net.au>
1624
1625 * elf64-alpha.c (alpha_elf_size_info): Make static.
1626
5af6ead6
AM
16272002-09-17 Svein E. Seldal <Svein.Seldal@solidas.com>
1628
1629 * coff-tic4x.c: Add function declarations and ATTRIBUTE_UNUSED.
1630 * cpu-tic4x.c: Ditto.
1631
cb9512fc
TS
16322002-09-17 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1633
1634 * elf64-mips.c (define elf_backend_ignore_discarded_relocs): Remove
1635 duplicate define.
1636
4ada7262
DB
16372002-09-16 Bruno Haible <bruno@clisp.org>
1638
1639 * elf32-i386.c: Don't defined ELF_ARCH etc. if this file is included
1640 by a target variant implementation.
1641 * elf64-alpha.c: Likewise.
1642 * elf32-i386-fbsd.c: New file.
1643 * elf64-alpha-fbsd.c: New file.
1644 * targets.c: Support bfd_elf32_i386_freebsd_vec and
1645 bfd_elf64_alpha_freebsd_vec.
1646 * configure.in: Accept the vectors bfd_elf32_i386_freebsd_vec,
1647 bfd_elf64_alpha_freebsd_vec.
1648 * Makefile.am (BFD32_BACKENDS): Add elf32-i386-fbsd.lo.
1649 (BFD32_BACKENDS_CFILES): Add elf32-i386-fbsd.c.
1650 (BFD64_BACKENDS): Add elf64-alpha-fbsd.lo.
1651 (BFD64_BACKENDS_CFILES): Add elf64-alpha-fbsd.c.
1652 (elf32-i386-fbsd.lo, elf64-alpha-fbsd.lo): Add dependencies.
1653 * config.bfd: For FreeBSD targets, set targ_defvec to a FreeBSD
1654 specific targets. Define OLD_FREEBSD_ABI_LABEL if appropriate.
1655
6a30718d
JJ
16562002-09-12 Jakub Jelinek <jakub@redhat.com>
1657
1658 * elf32-i386.c (dtpoff_base, tpoff): Don't crash if tls_segment is
1659 NULL.
1660 (elf_i386_relocate_section): Return false after printing error about
1661 unresolvable relocation.
1662
6cf9e9fe
NC
16632002-09-12 Nick Clifton <nickc@redhat.com>
1664
1665 * elf32-arm.h (elf32_arm_final_link_relocate): Fix handling of
1666 R_ARM_THM_PC11.
1667
10f469bf
DJ
16682002-09-11 Jeffrey Law <law@redhat.com>
1669
1670 * elf32-h8300.c (elf32_h8_relax_section): Fix typo.
1671
dc43ada5
NC
16722002-09-11 Andrew Haley <aph@cambridge.redhat.com>
1673
1674 * elf.c (_bfd_elf_find_nearest_line): Check functionname_ptr and
1675 line_ptr before deciding we've found a symbol.
1676
e09f4395
NC
16772002-09-11 Nick Clifton <nickc@redhat.com>
1678
1679 * po/da.po: New Danish translation file.
1680 * configure.in (LINGUAS): Add 'da'.
1681 * configure: Regenerate.
1682
b3018b5f
NC
16832002-09-10 Michael Snyder <msnyder@redhat.com>
1684
1685 * irix-core.c (do_sections, do_sections64): New functions.
51020317 1686 (irix_core_core_file_p): Call new functions do_sections,
b3018b5f
NC
1687 do_sections64, depending on corefile (32-bit or 64-bit).
1688
2f21f25e
RH
16892002-09-09 Richard Henderson <rth@redhat.com>
1690
1691 * elfxx-ia64.c (elfNN_ia64_relax_section): Handle PCREL21M
1692 and PCREL21F like PCREL21B.
1693
28b94e7c
KB
16942002-09-04 Kevin Buettner <kevinb@redhat.com>
1695
51020317
AM
1696 * config.bfd (mips*-*-irix6*): Add new ABI vectors. Make n32 default
1697 vector.
28b94e7c 1698
5cec6941
NC
16992002-09-02 Nick Clifton <nickc@redhat.com>
1700
1701 * elf32-v850.c (v850_elf_final_link_relocate): Use helpful
1702 names instead of cryptically overloaded bfd_reloc error
1703 codes.
1704 (v850_elf_relocate_section): Likewise.
1705 (v850_elf_relax_section): Replace caching of external symbols
1706 with caching of internal symbols obtained from calling
1707 bfd_elf_get_elf_syms().
51020317 1708 Fixup problems with freeing cached allocated memory blocks.
5cec6941 1709
3b77b1d5
AM
17102002-09-02 Alan Modra <amodra@bigpond.net.au>
1711
638524b5
AM
1712 * cpu-pj.c (scan_mach, compatible, arch_info_struct): Remove.
1713 (bfd_pj_arch): Use bfd_default_scan.
1714 * cpu-v850.c (scan): Remove.
1715 (N): Use bfd_default_scan.
1716 * cpu-z8k.c (scan_mach): Remove.
1717 (arch_info_struct, bfd_z8k_arch): Reorganize so that the default is
1718 first. Use bfd_default_scan.
1719
250d94fd
AM
1720 * ecoff.c (_bfd_ecoff_set_arch_mach_hook): Don't use hard-coded
1721 bfd_mach constants.
1722 (ecoff_get_magic): Likewise.
1723 * elf32-v850.c (v850_elf_object_p): Likewise.
1724 (v850_elf_final_write_processing): Likewise.
1725 * mipsbsd.c (MY(set_arch_mach)): Likewise.
1726 (MY(write_object_contents)): Likewise.
1727 * coff64-rs6000.c (xcoff64_write_object_contents): Likewise.
1728 * coffcode.h (coff_write_object_contents): Likewise.
1729 (coff_set_arch_mach_hook): Add comment describing machine == 0.
1730 Remove unnecessary "machine" assignments.
1731 (coff_write_relocs): Test for the absolute section sym by testing
1732 section and flags.
1733
3b77b1d5
AM
1734 * aoutx.h (NAME(aout,machine_type)): Recognize bfd_mach_i386_i386
1735 and bfd_mach_i386_i386_intel_syntax.
250d94fd 1736 * pdp11.c (NAME(aout,machine_type)): Likewise.
3b77b1d5 1737
e5b45b83
DA
17382002-08-30 John David Anglin <dave@hiauly1.hia.nrc.ca>
1739
1740 * bfd-in.h (align_power): Cast constants to bfd_vma type.
1741 * bfd-in2.h (align_power): Likewise.
1742
37f45cf8
AM
17432002-08-30 Alan Modra <amodra@bigpond.net.au>
1744
1745 * Makefile.am: Run "make dep-am".
1746 * Makefile.in: Regenerate.
1747
1748 * cpu-avr.c (compatible): Don't use hard-coded mach constants.
1749 * cpu-powerpc.c (powerpc_compatible): Likewise.
1750 * cpu-rs6000.c (rs6000_compatible): Likewise.
1751
86aba9db
NC
17522002-08-28 Catherine Moore <clm@redhat.com>
1753
1754 * elf32-v850.c (v850_elf_reloc_map): Add new relocs.
1755 (v850-elf-reloc): Don't resolve pc relative relocs.
1756 (v850_elf_ignore_reloc): New routine.
1757 (v850_elf_final_link_relocate): Handle new relocs.
1758 (v850_elf_relax_delete_bytes ): New routine.
1759 (v850_elf_relax_section): New routine.
1760 (bfd_elf32_bfd_relax_section): Define.
1761 (HOWTO): New entries for new relocs.
1762 * reloc.c (BFD_RELOC_V850_LONGCALL): New reloc.
1763 (BFD_RELOC_V850_LONGJUMP): New reloc.
1764 (BFD_RELOC_V850_ALIGN): New reloc.
1765 * archures.c: Remove redundant v850ea architecture.
1766 * cpu-v850.c: Remove redundant v850ea support.
1767 * libbfd.h: Regenerate.
1768 * bfd-in2.h: Regenerated.
1769
026df7c5
NC
17702002-08-28 Svein E. Seldal <Svein.Seldal@solidas.com>
1771
1772 * config.bfd: Add tic4x-*-*coff* and c4x-*-*coff* target.
1773 * configure.in: Add tic4x_coff vector files.
1774 * configure: Regenerate.
1775 * Makefile.am: Add tic4x target.
1776 * Makefile.in: Regenerate.
1777
17782002-08-27 Michael Hayes <m.hayes@elec.canterbury.ac.nz>
1779
1780 * archures.c: Add the BFD arch type tic4x.
1781 * bfd-in.h: Add BFD_IN_MEMORY flag.
1782 * coff-tic4x.c: New file.
1783 * coffswap.h (coff_swap_sym_out): Add preadjuster.
1784 * cpu-tic4x.c: New file.
1785 * targets.c: Added tic4x- in list of xvecs.
1786 * ticoff.h: New file.
1787 * bfd-in2.h: Regenerate.
1788
88f7bcd5
NC
17892002-08-27 Adam Nemet <anemet@lnxw.com>
1790
1791 * elf32-arm.h (elf32_arm_finish_dynamic_sections): Set the last
1792 bit of DT_INIT and DT_FINI for Thumb functions.
1793
c8e48751
AM
17942002-08-26 Alan Modra <amodra@bigpond.net.au>
1795
1796 * coffcode.h (coff_set_arch_mach_hook): Handle W65MAGIC.
1797
2846975a
AM
17982002-08-26 Alan Modra <amodra@bigpond.net.au>
1799
1800 * aoutx.h (NAME(aout,reloc_type_lookup)): Handle BFD_RELOC_8.
1801
067653c5
AM
18022002-08-24 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1803
1804 * elf32-sh.c (sh_elf_copy_indirect_symbol): New.
1805 (create_got_section, allocate_dynrelocs, readonly_dynrelocs):
1806 Likewise.
1807 (struct elf_sh_pcrel_relocs_copied): Removed.
1808 (struct elf_sh_dyn_relocs): New.
1809 (struct elf_sh_link_hash_entry): Replace pcrel_relocs_copied
1810 field with dyn_relocs.
1811 (struct elf_sh_link_hash_table): Add short-cuts to get dynamic
1812 sections and sym_sec.
1813 (sh_elf_link_hash_newfunc): Clear dyn_relocs.
1814 (sh_elf_link_hash_table_create): Clear shorts-cuts and sym_sec.
1815 (sh_elf_create_dynamic_sections): Use create_got_section instead
1816 of _bfd_elf_create_got_section.
1817 (sh_elf_check_relocs): Likewise.
1818 (sh_elf_create_dynamic_sections): Use short-cuts to the dynamic
1819 sections.
1820 (sh_elf_adjust_dynamic_symbol, sh_elf_size_dynamic_sections,
1821 sh_elf_relocate_section, sh_elf_check_relocs,
1822 sh_elf_finish_dynamic_symbol, sh_elf_finish_dynamic_sections):
1823 Likewise.
1824 (sh_elf_adjust_dynamic_symbol): Handle nocopyreloc. Keep the
1825 dynamic relocations and avoiding the copy relocation when we
1826 didn't find any dynamic relocations in the section which has
1827 contents or is read-only.
1828 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
1829 (sh_elf_size_dynamic_sections): Don't reset the size of
1830 .rela.got section even if dynamic_sections_created flag is off.
1831 Don't use sh_elf_discard_copies. Scan all input bfd and use
1832 allocate_dynrelocs. Call readonly_dynrelocs to determine
1833 whether we need DT_TEXTREL.
1834 (sh_elf_adjust_dynamic_symbol): Use plt.refcount to determine
1835 whether the symbol was never referred to.
1836 (sh_elf_relocate_section): Use WILL_CALL_FINISH_DYNAMIC_SYMBOL.
1837 (sh_elf_gc_sweep_hook): Fill with the real sweep function.
1838 (sh_elf_check_relocs): Call create_got_section if the short-cut
1839 to .got is null. Increment reference counters only instead of
1840 allocating space on dynamic sections here. Don't conditionalize
1841 uninitialized got.offset value when marking the symbol as a
1842 global offset table entry. Keep relocations for symbols satisfied
1843 by a dynamic library to avoid copy relocations for the symbol.
1844 Set dynobj field of an elf hash table if needed.
1845 (sh_elf_finish_dynamic_sections): Handle null section pointer
1846 correctly.
1847 (elf_backend_copy_indirect_symbol): Defined.
1848 (elf_backend_can_refcount): Defined.
1849
7e326afc
NC
18502002-08-23 Nick Clifton <nickc@redhat.com>
1851
1852 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Undo
1853 previous change. Add comment explaining why.
1854
c8614e8e
AM
18552002-08-23 Stephen Clarke <stephen.clarke@superh.com>
1856
1857 * elf32-sh.c (elf_sh_plt0_entry_be, elf_sh_plt0_entry_le): Copy
1858 contents of .got.plt[2] to tr0, not address of .got.plt.
1859 (sh_elf_finish_dynamic_symbol): Do not apply GOT_BIAS when
1860 patching absolute plt entry. For shmedia plt entry, set bottom bit
1861 of branch to plt0 as this is a branch to an shmedia instruction.
1862 * elf64-sh64.c (elf_sh64_plt0_entry_be, elf_sh64_plt0_entry_le):
1863 Copy contents of .got.plt[2] to tr0, not address of .got.plt.
1864 (elf_sh64_plt_entry_be, elf_sh64_plt_entry_le): Use ptrel to
1865 branch to plt0.
1866 (sh64_elf64_finish_dynamic_symbol): Do not apply GOT_BIAS when
1867 patching absolute plt entry. For shmedia plt entry, branch to
1868 plt0 is now ptrel, so use relative offset. Set bottom bit of
1869 branch target as it is a branch to an shmedia instruction.
1870
3b587c71
AM
18712002-08-23 Stephen Clarke <stephen.clarke@superh.com>,
1872 Richard Shann <richard.shann@superh.com>
1873
1874 * elf32-sh.c (sh_elf_finish_dynamic_sections): Set LSB of DT_INIT
1875 value if .init is an SHmedia function. Similarly for DT_FINI.
1876 * elf64-sh64.c (sh64_elf64_finish_dynamic_sections): Likewise.
51020317 1877
957dcaa8
AM
18782002-08-23 Stephen Clarke <stephen.clarke@superh.com>
1879
3b587c71 1880 * elf32-sh.c (sh_elf_size_dynamic_sections): Zero initialize
957dcaa8 1881 dynamic section.
3b587c71 1882 * elf64-sh64.c (sh64_elf64_size_dynamic_sections): Likewise.
957dcaa8 1883
a4263c47
NC
18842002-08-22 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1885
1886 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Use a simple
51020317 1887 byte read when reading the return address register column.
a4263c47 1888
db4ed121
NC
18892002-08-22 Nick Clifton <nickc@redhat.com>
1890
1891 * config.bfd: Add powepc64-*-*bsd* target.
1892
ed71e111
NC
18932002-08-22 Graeme Peterson <gp@qnx.com>
1894
1895 * Makefile.am: Add entries for elf32-shqnx.c
1896 * Makefile.in: Regenerate.
1897 * config.bfd: Add support sh-*-nto* target.
1898 * configure.in: Add support for bfd_elf32_sh{l}qnx_vec.
1899 * configure: Regenerate.
1900 * elf32-qnx.h: Changed typo "elf_i386qnx_*" to "elf_qnx_*" .
1901 * elf32-sh.c: Do not include elf32-target.h if
1902 ELF32_SH_C_INCLUDED is defined.
1903 * elf32-shqnx.c: New file: Support for QNX.
1904 * targets.c: Add bfd_elf32_sh{l}qnx_vec.
1905
0ab72ee2
NC
19062002-08-22 Nick Clifton <nickc@redhat.com>
1907
75c83283
NC
1908 * po/tr.po: Updated Turkish translation.
1909
0ab72ee2
NC
1910 * syms.c (_bfd_generic_read_minisymbols): Set bfd_error if the
1911 symbols are not read.
1912
56780f18
AM
19132002-08-22 Alan Modra <amodra@bigpond.net.au>
1914
1915 * elf32-m68hc11.c: Formatting fixes.
1916 (elf32_m68hc11_gc_mark_hook): Correct params. Remove unnecessary test.
1917 * elf32-m68hc12.c: Formatting fixes.
1918 (elf32_m68hc11_gc_mark_hook): Correct params. Remove unnecessary test.
1919
b48fa14c
AM
19202002-08-22 Alan Modra <amodra@bigpond.net.au>
1921
a7c71b0c
AM
1922 * coff-rs6000.c (rs6000coff_vec <object_flags>): Add SEC_CODE and
1923 SEC_DATA.
1924 (pmac_xcoff_vec): Likewise.
1925 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
1926 (aix5coff64_vec): Likewise.
1927
56780f18
AM
19282002-08-22 Alan Modra <amodra@bigpond.net.au>
1929
b48fa14c
AM
1930 * elf-bfd.h (struct elf_backend_data): Add struct elf_backend_data
1931 param to elf_backend_copy_indirect_symbol.
1932 (_bfd_elf_link_hash_copy_indirect): Likewise.
1933 * elflink.h (elf_add_default_symbol, elf_fix_symbol_flags): Adjust
1934 calls to copy_indirect_symbol.
1935 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
1936 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
1937 * elf32-s390.c (elf_s390_copy_indirect_symbol): Likewise.
1938 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
1939 * elf64-s390.c (elf_s390_copy_indirect_symbol): Likewise.
1940 * elf64-x86-64.c (elf64_x86_64_copy_indirect_symbol): Likewise.
1941 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
1942 * elfxx-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
1943 * elfxx-mips.h (_bfd_mips_elf_copy_indirect_symbol): Likewise.
1944 * elf.c (_bfd_elf_link_hash_copy_indirect): Likewise. Properly
1945 test refcounts for "used" values.
1946
8c2ab17d
AM
19472002-08-21 John David Anglin <dave@hiauly1.hia.nrc.ca>
1948
1949 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Add PARAMS to
1950 argument declaration.
1951
d62b1198 19522002-08-19 Elena Zannoni <ezannoni@redhat.com>
51020317
AM
1953
1954 * archures.c (bfd_mach_ppc_e500): Added.
1955 * bfd-in2.h: Rebuilt.
d62b1198
EZ
1956 * cpu-powerpc.c (bfd_powerpc_archs): Added e500.
1957
9f88ba09
AM
19582002-08-19 Alan Modra <amodra@bigpond.net.au>
1959
1960 * elf32-m68hc12.c (elf_backend_can_gc_sections): False.
1961
df622259
AC
19622002-08-17 Andrew Cagney <ac131313@redhat.com>
1963
1964 * elf.c (bfd_elf_get_elf_syms): Change type of `esym' to
51020317 1965 `bfd_byte'.
df622259 1966
44c410de
SC
19672002-08-17 Stan Cox <scox@redhat.com>
1968
1969 * elfxx-mips.c (_bfd_mips_elf_modify_segment_map): Use the
1970 IRIX 6 segment layout for NEWABI.
1971
4972a8e9
SC
19722002-08-16 Stephen Clarke <stephen.clarke@superh.com>
1973
1974 * bfd/elf32-sh.c (sh_elf_gc_mark_hook): For sh64, skip indirect
1975 symbols when looking for section referred to by a relocation.
1976 * bfd/elf64-sh.c (sh_elf64_gc_mark_hook): Likewise.
51020317 1977
c5cd6d62
AM
19782002-08-15 Alan Modra <amodra@bigpond.net.au>
1979
1980 * elf32-i370.c: Move reloc enum to include/elf/i370.h.
1981
0741c7be
HPN
19822002-08-15 Hans-Peter Nilsson <hp@axis.com>
1983
1984 * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Add
1985 missing check for whether the symbol is referenced by DSO before
1986 unexporting it as an unneeded dynamic symbol.
1987
e8d5d179
L
19882002-08-14 H.J. Lu <hjl@gnu.org>
1989
1990 * libbfd.h: Regenerate.
1991
e9229007
L
19922002-08-14 H.J. Lu <hjl@gnu.org>
1993
1994 * config.bfd: Always add 64bit vectors to 32bit Linux/mips.
1995
1fd03b5a
SC
19962002-08-14 Stephane Carrez <stcarrez@nerim.fr>
1997
1998 * elf32-m68hc11.c (m68hc11_relax_group): New to relax group of
1999 instructions.
2000 (m68hc11_direct_relax): New to define table of relaxable instructions.
2001 (find_relaxable_insn): New, find a relaxable insn.
2002 (compare_reloc): New to compare two relocs.
2003 (m68hc11_elf_relax_section): New, relax text sections.
2004 (m68hc11_elf_relax_delete_bytes): New, delete bytes and adjust branchs.
2005 (elf32_m68hc11_check_relocs): New function for GC support.
2006 (elf32_m68hc11_relocate_section): New function for GC support.
2007 (bfd_elf32_bfd_relax_section): Define to support linker relaxation.
2008 (elf_backend_check_relocs): Likewise.
2009 (elf_backend_relocate_section): Likewise.
2010
c828c771
L
20112002-08-13 H.J. Lu <hjl@gnu.org>
2012
2013 * elflink.h (NAME(bfd_elf,size_dynamic_sections): Don't count
2014 definitions in shared objects when checking symbol with
2015 undefined version.
2016
9b701e44
SC
20172002-08-13 Stephane Carrez <stcarrez@nerim.fr>
2018
2019 * elf32-m68hc11.c (elf32_m68hc11_gc_mark_hook): New for section GC.
2020 (elf32_m68hc11_gc_sweep_hook): Likewise.
2021 (elf_backend_gc_mark_hook): Define for GC section support.
2022 (elf_backend_gc_sweep_hook): Likewise.
2023 (elf_backend_can_gc_sections): Likewise.
2024
2025 * elf32-m68hc12.c: Likewise.
2026
96405e3c
SC
20272002-08-13 Stephane Carrez <stcarrez@nerim.fr>
2028
2029 * elf32-m68hc11.c (_bfd_m68hc11_elf_print_private_bfd_data): New.
2030 (_bfd_m68hc11_elf_merge_private_bfd_data): New function.
2031 (_bfd_m68hc11_elf_set_private_flags): New function.
2032 Use them to set/check/print ELF flags specific to 68HC11.
2033
2034 * elf32-m68hc12.c (_bfd_m68hc12_elf_print_private_bfd_data): New.
2035 (_bfd_m68hc12_elf_merge_private_bfd_data): New function.
2036 (_bfd_m68hc12_elf_set_private_flags): New function.
2037 Use them to set/check/print ELF flags specific to 68HC12.
2038
dae78fb0
SC
20392002-08-13 Stephane Carrez <stcarrez@nerim.fr>
2040
2041 * elf32-m68hc11.c (elf_m68hc11_howto_table): Add the new relocs;
2042 fix masks for PC-rel relocs.
2043 (m68hc11_elf_ignore_reloc): New function.
2044
2045 * elf32-m68hc12.c (m68hc12_elf_special_reloc): New to handle specific
2046 68HC12 banked addressing relocs.
2047 (m68hc12_phys_addr): New to compute physical address of banked memory.
2048 (m68hc12_phys_page): Likewise for page.
2049 (m68hc12_addr_is_banked): New to see if address is in banked area.
2050 (elf_m68hc12_howto_table): Add new relocs and rename to xx12.
2051
3dbfec86
SC
20522002-08-13 Stephane Carrez <stcarrez@nerim.fr>
2053
2054 * reloc.c (BFD_RELOC_M68HC11_RL_JUMP, BFD_RELOC_M68HC11_RL_GROUP,
2055 BFD_RELOC_M68HC11_LO16, BFD_RELOC_M68HC11_PAGE,
2056 BFD_RELOC_M68HC11_24): New relocs for 68HC11/68HC12.
2057 * bfd-in2.h: Regenerate.
2058
871da94f
L
20592002-08-12 H.J. Lu <hjl@gnu.org>
2060
2061 * elflink.h (elf_add_default_symbol): Preserve section across
2062 elf_merge_symbol.
2063
59bc061d
NC
20642002-08-09 Graeme Peterson <gp@qnx.com>
2065
51020317 2066 * Makefile.am: Add entries for elf32-ppcqnx.c, and add
59bc061d
NC
2067 elf32-qnx.h dependency to elfarmqnx-nabi.c and elf32-i386qnx.c.
2068 * Makefile.in: Regenerate.
2069 * config.bfd: Add support for powerpc{le}-*-nto targets.
2070 * configure.in: Add support for bfd_elf32_powerpc{le}qnx_vec.
2071 * configure: Regenerate.
2072 * elf32-i386qnx.c: Moved backend functions into a QNX specific
2073 common file "elf32-qnx.h", and now include that file.
2074 * elf32-qnx.h: New file: QNX specific common elf backend.
2075 * elf32-ppc.c: Do not include elf32-target.h if
2076 ELF32_PPC_C_INCLUDED is defined.
2077 * elf32-ppcqnx.c: New file: Support for QNX.
2078 * elfarmqnx-nabi.c: Include elf32-qnx.h for qnx elf backend.
2079 * targets.c: Add bfd_elf32_powerpc{le}qnx_vec.
2080
2b692c59
NC
20812002-08-09 Nick Clifton <nickc@redhat.com>
2082
2083 * po/sv.po: Updated Swedish translation.
2084
d0c7ff07
TS
20852002-08-09 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2086
2087 * elfxx-mips.c (mips_elf_global_got_index): Avoid segfault if
2088 g->global_gotsym is NULL.
2089
d8bbe778
L
20902002-08-08 H.J. Lu <hjl@gnu.org>
2091
c5cd6d62 2092 * elflink.h (elf_add_default_symbol): Don't warn if a definition
d8bbe778
L
2093 overrides an indirect versioned symbol.
2094
c366c25e
JJ
20952002-08-08 Jakub Jelinek <jakub@redhat.com>
2096
2097 * elf32-i386.c (elf_i386_relocate_section): Fill in proper addend
2098 for R_386_TLS_TPOFF32 relocs against symndx 0.
2099
31941635
L
21002002-08-07 H.J. Lu <hjl@gnu.org>
2101
2102 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Check symbol
2103 with undefined version if needed.
2104 (elf_link_assign_sym_version): Match a default symbol with a
2105 version without definition. No need to hide the default
2106 definition separately.
2107
0f3bd64f
AM
21082002-08-08 Alan Modra <amodra@bigpond.net.au>
2109
7330fb86
AM
2110 * elflink.h (elf_link_output_extsym): Don't output symbols from
2111 SEC_EXCLUDE sections.
2112
0f3bd64f
AM
2113 * aoutx.h (aout_link_write_symbols): Correct handling of warning syms.
2114
a4aa0fb7
AM
21152002-08-07 Alan Modra <amodra@bigpond.net.au>
2116
2117 * elf64-ppc.c (edit_opd): Arrange to drop symbols for discarded .opd
2118 entries.
2119
34ea4a36
TS
21202002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2121
2122 * elfxx-mips.c (mips_elf_create_dynamic_relocation): Cast signedness
2123 mismatch.
2124
141ff970
TS
21252002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2126
2127 * elfxx-mips.c (ABI_64_P): Remove superfluous check.
2128
28458e7e
TS
21292002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2130
2131 * elf32-mips.c (mips_reloc_map): Fix typo.
2132
0121a3da
AM
21332002-08-06 Alan Modra <amodra@bigpond.net.au>
2134
2135 * xcofflink.c (xcoff_write_global_symbol): Set n_scnum for abs_section.
2136
d006db6c
AM
21372002-08-06 Alan Modra <amodra@bigpond.net.au>
2138
2139 * elf64-ppc.c (ppc64_elf_howto_raw): Zero all src_mask entries.
2140
8ea80f08
AM
21412002-08-06 Alan Modra <amodra@bigpond.net.au>
2142
2a52da53
AM
2143 * libxcoff.h: Use PARAMS on function declarations.
2144 * coff-rs6000.c (xcoff_generate_rtinit): Simplify size calc.
2145 * coff64-rs6000.c (xcoff64_generate_rtinit): Likewise.
2146
8ea80f08
AM
2147 * coff-rs6000.c: (xcoff_rtype2howto): Don't place reloc address in
2148 addend.
2149 * coff64-rs6000.c: (xcoff64_rtype2howto): Likewise.
2150
cf9ab45b
AM
21512002-08-06 Alan Modra <amodra@bigpond.net.au>
2152
2153 * coff-rs6000.c: Formatting fixes.
2154 (xcoff_calculate_relocation): Use PARAMS in declaration.
2155 (xcoff_complain_overflow): Likewise.
2156 (xcoff_ppc_relocate_section): Use old-style function pointer call.
2157 (bfd_xcoff_backend_data): Remove useless comments.
2158 (rs6000coff_vec): Likewise.
2159 (bfd_pmac_xcoff_backend_data): Likewise.
2160 (pmac_xcoff_vec): Likewise.
8ea80f08 2161
cf9ab45b
AM
2162 * coff64-rs6000.c: Formatting fixes.
2163 (xcoff64_calculate_relocation): Use PARAMS in declaration.
2164 (xcoff64_ppc_relocate_section): Use old-style function pointer call.
2165 (bfd_xcoff_backend_data): Remove useless comments.
2166 (rs6000coff64_vec): Likewise.
2167 (bfd_xcoff_aix5_backend_data): Likewise.
2168 (aix5coff64_vec): Likewise.
2169
48bfecdd
AM
21702002-08-06 Alan Modra <amodra@bigpond.net.au>
2171
a78eab4e
AM
2172 * coff-rs6000.c (xcoff_howto_table): Revert some of last change to
2173 mask entries. Use complain_overflow_dont for R_REF.
2174 (xcoff_reloc_type_ba): Revert last change.
2175 (xcoff_reloc_type_br): Likewise.
2176 (xcoff_reloc_type_crel): Likewise.
2177 (xcoff_ppc_relocate_section): Likewise.
2178 * coff64-rs6000.c (xcoff64_reloc_type_br): Likewise.
2179 (xcoff64_ppc_relocate_section): Likewise.
2180 (xcoff64_howto_table): Revert some of last change to mask entries.
2181 Use complain_overflow_dont for R_REF.
2182
48bfecdd
AM
2183 * coff-rs6000.c (xcoff_howto_table): Fix src_mask entries. Make all
2184 relocs with bitsize == 16 have size = 1.
2185 (xcoff_reloc_type_ba): Correct src_mask and dst_mask adjustment.
2186 (xcoff_reloc_type_br): Likewise.
2187 (xcoff_reloc_type_crel): Likewise.
2188 (xcoff_ppc_relocate_section): Set up src_mask and dst_mask correctly.
2189 * coff64-rs6000.c (xcoff64_reloc_type_br): Correct src_mask and
2190 dst_mask adjustment.
2191 (xcoff64_ppc_relocate_section): Set up src_mask and dst_mask correctly.
2192 (xcoff64_howto_table): Fix src_mask entries. Make all relocs with
2193 bitsize == 16 have size = 1.
2194
fd13ed0c
DC
21952002-08-01 Denis Chertykov <denisc@overta.ru>
2196
2197 * elf32-ip2k.c: Processor manufacturer changed to Ubicom.
2198 (struct misc): New field isymbuf. All free_* fields removed.
2199 (symbol_value): Pass in internal syms. No need to swap syms in.
2200 (ip2k_elf_relax_section): Use bfd_elf_get_elf_syms. Properly free
2201 possibly cached info.
2202 (tidyup_after_error): Removed.
2203 (ip2k_elf_relax_section_pass1): Don't use removed fields of struct
2204 misc. Use new field.
2205 (adjust_all_relocations): Use internal syms. No need to swap syms
2206 in and out.
2207 (add_page_insn): Don't use removed fields of struct misc.
2208
24a1ba0f
NC
22092002-08-01 Nick Clifton <nickc@redhat.com>
2210
2211 * elf32-arm.h: Revert previous delta.
2212
a6903459
NC
22132002-08-01 Nick Clifton <nickc@redhat.com>
2214
2215 * configure.in (AM_INIT_AUTOMAKE): Bump version number.
2216 * configure: Regenerate.
2217
39a2a3eb
L
22182002-07-31 H.J. Lu <hjl@gnu.org>
2219
2220 * config.bfd: Add x86-64 vector to Linux/i386 if 64bit BFD is
2221 selected.
2222
a0dfa6a8
L
22232002-07-31 H.J. Lu <hjl@gnu.org>
2224
2225 * config.bfd: Add n32 vectors to 32bit Linux/mips if 64bit BFD
2226 is selected.
2227
cd67d266
JJ
22282002-07-31 Jakub Jelinek <jakub@redhat.com>
2229
2230 * elf32-i386.c (elf_i386_copy_indirect_symbol): Swap tls_type
2231 if _bfd_elf_link_hash_copy_indirect will swap got.refcount.
2232
4eb6b71c
NC
22332002-07-31 Ian Dall <ian@sibyl.beware.dropbear.id.au>
2234
2235 * cpu-ns32k.c (_bfd_ns32k_put_immdeiate, _bfd_ns32k_get_immediate):
2236 There is no 8 byte relocation type for this architecture.
2237 (do_ns32k_reloc): Use bfd_vma instead of native types.
2238 (bfd_ns32k_put_immediate, _bfd_ns32k_relocate_contents) put_data
2239 returns void.
2240 (_bfd_ns32k_put_displacement): Don't check for overflow. We can
2241 rely on generic code to do that.
2242 * aout-ns32k.c (howto_table): Add appropriate overflow detection
2243 to all table entries.
2244 (_bfd_ns32k_relocate_contents): put_data returns void.
2245 * ns32k.h: (_bfd_ns32k_put_displacement, _bfd_ns32k_put_immediate)
2246 (_bfd_do_ns32k_reloc_contents): Fix prototypes. put data functions
2247 return void.
2248
f7c33884
NC
22492002-07-31 Ian Dall <ian@sibyl.beware.dropbear.id.au>
2250
2251 * aoutx.h (aout_link_check_ar_symbols): Whether to include an
2252 archive object is target dependant.
2253
8f64befb
NC
22542002-07-31 Adam Nemet <anemet@lnxw.com>
2255
2256 * elf32-arm.h (ARM_PLT_ENTRY_SIZE): Rename PLT_ENTRY_SIZE.
2257 (THUMB_PLT_ENTRY_SIZE): New macro.
2258 (PLT_ENTRY_SIZE): Return the appropriate *_PLT_ENTRY_SIZE.
2259 (elf32_arm_plt0_entry): Rename PLT_ENTRY_SIZE to
2260 ARM_PLT_ENTRY_SIZE.
2261 (elf32_arm_plt_entry): Likewise.
2262 (elf_backend_plt_header_size): Likewise.
2263 (elf32_thumb_plt0_entry): New global.
2264 (elf32_arm_finish_dynamic_sections): Use it. Put Thumb entries
2265 into .plt.thumb.
2266 (elf32_thumb_plt_entry): New global.
2267 (elf32_arm_finish_dynamic_symbol): Use it. Use .thumb.plt for
2268 Thumb entries. Set the bottom bit of the corresponding GOT entry
2269 for a Thumb PLT entry.
2270 (struct elf32_arm_plt_entry_info): New structure.
2271 (struct elf32_arm_link_hash_entry, plt_info): New member of this
2272 type.
2273 (elf32_arm_link_hash_newfunc): Initialize new member.
2274 (elf32_arm_final_link_relocate, R_ARM_THM_PC22 case): Handle
2275 relocations against the PLT.
2276 (elf32_arm_check_relocs, case R_ARM_PLT32 case): Set
2277 first_rel_type if this is the first time we encounter the symbol.
2278 (elf32_arm_check_relocs, case R_ARM_THM_PC22 case): New case.
2279 Determine if relocation needs a PLT entry. Set first_rel_type if
2280 this is the first time we encounter the symbol
2281 (elf32_arm_adjust_dynamic_symbol): Create PLT entries for Thumb
2282 functions as well.
2283 (elf32_arm_size_dynamic_sections): Handle .plt.thumb like .plt.
2284 (elf32_arm_create_dynamic_sections): New function. Create the
2285 .plt.thumb section.
2286 (elf_backend_create_dynamic_sections): Call it.
2287
47badb7b
NC
22882002-07-31 Nick Clifton <nickc@redhat.com>
2289
2290 * bfd.c (bfd_alt_mach_code): Rename parameter 'index' to
2291 'alternative' in order to avoid shadowing global symbol of the
2292 same name.
2293 * bfd-in2.h: Regenerate.
2294 * libbfd.h: Regenerate.
2295 * libcoff.h: Regenerate.
2296
8a397dad
TS
22972002-07-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2298
2299 * Makefile.am: Add n32 ABI support.
2300 * Makefile.in: Regenerate.
2301 * config.bfd: Add n32 vectors to mips64*-*-linux* targets. Treat 64
2302 bit vectors for mips*-*-linux targets as optional.
2303 * configure.in: Add n32 ABI vectors.
2304 * configure: Regenerate.
2305 * elf32-mips.c (mips_elf32_object_p): Reject n32 ABI files.
2306 * elfn32-mips.c: New file, n32 ABI support.
2307 * targets.c: Add n32 ABI vectors.
2308
7e392df6 23092002-07-30 Graeme Peterson <gp@qnx.com>
83e1617e 2310
7e392df6
NC
2311 * elfarmqnx-nabi.c: New file: Support for QNX.
2312 * config.bfd: Add support for arm-*-nto target.
2313 * configure.in: Add support for bfd_elf32_{big|little}armqnx_vec.
2314 * configure: Regenerate.
2315 * Makefile.am: Add entries for elfarmqnx-nabi.c.
2316 * Makefile.in: Regenerate.
2317 * elf32-arm.h (ELF_MAXPAGESIZE): Do not define if already defined.
2318 Do not define global function if ELFARM_NABI_C_INCLUDED is defined.
2319 * elfarm-nabi.c: Do not include elf32-arm.h if
2320 ELFARM_NABI_C_INCLUDED is defined.
2321 * targets.c: Add bfd_elf32_{big|little}armqnx_vec.
7330fb86 2322
7e392df6 23232002-07-30 Nick Clifton <nickc@redhat.com>
7330fb86 2324
83e1617e
NC
2325 * po/sv.po: Updated Swedish translation.
2326
704afa60
JJ
23272002-07-30 Jakub Jelinek <jakub@redhat.com>
2328
2329 * elf.c (elf_fake_sections): Fix up .tbss sh_size and sh_type.
2330
487e54f2
AM
23312002-07-30 Alan Modra <amodra@bigpond.net.au>
2332
2333 * aoutx.h (some_aout_object_p): Clean up tdata properly on error.
2334 * archive.c (bfd_generic_archive_p): Likewise.
2335 * coff-rs6000.c (_bfd_xcoff_archive_p): Likewise.
2336 (_bfd_xcoff_archive_p): Use bfd_scan_vma in place of strtol.
2337 * coff64-rs6000.c (xcoff64_slurp_armap): Likewise.
2338 (xcoff64_archive_p): Likewise.
2339 (xcoff64_openr_next_archived_file): Likewise.
2340 (xcoff64_archive_p): Clean up tdata properly on error.
2341 * coffgen.c (coff_real_object_p): Likewise.
2342 (coff_object_p): Release filehdr and opthdr.
2343 * ecoff.c (_bfd_ecoff_archive_p): Clean up tdata properly on error.
2344 * ieee.c (ieee_archive_p): Likewise.
2345 * ihex.c (ihex_object_p): Likewise.
2346 (ihex_mkobject): Always allocate tdata.
2347 * peicode.h (pe_ILF_object_p): Release bfd_alloc'd buffer on error.
2348 * srec.c (srec_mkobject): Always allocate tdata.
2349 (srec_object_p): Clean up tdata properly on error.
2350 (symbolsrec_object_p): Likewise.
2351 * versados.c (versados_object_p): Likewise.
2352 * vms-misc.c (_bfd_vms_get_record): Use bfd_malloc instead of malloc,
2353 and bfd_realloc instead of realloc.
2354 (add_new_contents): Use bfd_alloc instead of bfd_malloc for sections.
2355 * vms.c (vms_initialize): Always allocate tdata. Use bfd_alloc in
2356 place of bfd_malloc, simplifying error freeing. Free hash table too.
2357 (vms_object_p): Clean up tdata on error.
2358 (vms_mkobject): Don't complain on stderr if vms_initialize fails.
2359 (vms_close_and_cleanup): Adjust for bfd_alloc use.
2360
9d46020e
AM
23612002-07-30 Alan Modra <amodra@bigpond.net.au>
2362
2363 * elfxx-ia64.c (elfNN_ia64_final_write_processing): Set e_flags.
2364
fb39dac1
RS
23652002-07-26 Chris Demetriou <cgd@broadcom.com>
2366
2367 * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Merge ASE
2368 flags into resulting BFD.
2369
7a624474
AM
23702002-07-26 Alan Modra <amodra@bigpond.net.au>
2371
2372 From John Reiser <jreiser@BitWagon.com>
2373 * elf32-i386.c (elf_i386_link_hash_table_create): Clear
2374 tls_ldm_got.refcount.
2375
a4382ec6
TS
23762002-07-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2377
2378 * elf64-mips.c: Update TODO comment.
2379 (mips_elf64_higher_reloc,mips_elf64_highest_reloc,
2380 mips_elf64_gprel16_reloca): Remove prototypes.
2381 (mips16_jump_reloc,mips16_gprel_reloc): Add functions.
2382 (UNUSED_RELOC): Replace by EMPTY_RELOC.
2383 (mips_elf64_howto_table_rel): Use special R_MIPS_HI16 handling. Remove
2384 wrong comments. Remove disfunctional support of R_MIPS_HIGHER and
2385 R_MIPS_HIGHEST.
2386 (mips_elf64_howto_table_rela): Fix handling of R_MIPS_GPREL16 and
2387 R_MIPS_GOT16. Remove wrong comments.
2388 (elf_mips16_jump_howto,elf_mips16_gprel_howto,
2389 elf_mips_gnu_vtinherit_howto,elf_mips_gnu_vtentry_howto): New, code
2390 from elf32-mips.c.
2391 (mips_elf64_hi16_reloc): Fix formatting.
2392 (mips_elf64_higher_reloc,mips_elf64_highest_reloc): Remove.
2393 (mips_elf64_got16_reloc): Fix formatting. Remove superfluous code.
2394 Better comment. Fall back to R_MIPS_GOT_DISP instead of abort().
2395 (mips_elf64_gprel16_reloc): Make static. Add check for
2396 partial_inplace.
2397 (mips_elf64_gprel16_reloca): Remove.
2398 (mips_elf64_literal_reloc): New function.
2399 (mips_elf64_gprel32_reloc): Fix formatting.
2400 (mips_elf64_shift6_reloc): Fix comment. Make static.
2401 (mips16_jump_reloc,mips16_gprel_reloc): New functions, code from
2402 elf32-mips.c.
2403 (elf_reloc_map,mips_reloc_map): New mapping table, similiar as in
2404 elf32-mips.c
2405 (bfd_elf64_bfd_reloc_type_lookup): Use the mapping table. Enable GNU
2406 specific relocations.
2407 (mips_elf64_rtype_to_howto): Enable GNU specific relocations.
2408 (mips_elf64_object_p): Invert logic to check for SGI-ish ABI.
2409 (ELF_MAXPAGESIZE): Add comment.
2410
219576a4
NC
24112002-07-25 Nick Clifton <nickc@redhat.com>
2412
2413 * po/sv.po: Updated Swedish translation.
2414 * po/es.po: Updated Spanish translation.
2415 * po/fr.po: Updated French translation.
2416
8c58d23b
AM
24172002-07-25 Alan Modra <amodra@bigpond.net.au>
2418
2419 * elf-bfd.h (_bfd_elf32_link_record_local_dynamic_symbol): Define
2420 as elf_link_record_local_dynamic_symbol.
2421 (_bfd_elf64_link_record_local_dynamic_symbol): Likewise.
2422 (elf_link_record_local_dynamic_symbol): Declare. Now returns int.
2423 * elflink.h (elf_link_record_local_dynamic_symbol): Move to..
2424 * elflink.c: .. here. Use bfd_elf_get_elf_syms. Check whether an
2425 attempt is made to record a symbol in a discarded section, and
2426 return `2' in that case.
2427
ff3063f5
NC
24282002-07-24 Nick Clifton <nickc@redhat.com>
2429
2430 * po/sv.po: Updated Swedish translation.
2431 * po/es.po: Updated Spanish translation.
2432
f0fe0e16
AM
24332002-07-23 Alan Modra <amodra@bigpond.net.au>
2434
c1fb5f8a
AM
2435 * po/SRC-POTFILES.in: Regenerate.
2436
f0fe0e16
AM
2437 * elf-hppa.h (elf_hppa_relocate_section): If relocatable, return
2438 immediately. Remove code handling relocatable linking.
2439 * elf32-avr.c (elf32_avr_relocate_section): Likewise.
2440 * elf32-cris.c (cris_elf_relocate_section): Likewise.
2441 * elf32-fr30.c (elf32_frv_relocate_section): Likewise.
de2d743e 2442 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
f0fe0e16
AM
2443 * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
2444 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
2445 * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
2446 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
2447 * elf32-v850.c (v850_elf_relocate_section): Likewise.
2448 * elf32-vax.c (elf_vax_relocate_section): Likewise.
2449 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
2450 * elf32-avr.c (elf_backend_rela_normal): Define.
2451 * elf32-cris.c: Likewise.
2452 * elf32-fr30.c: Likewise.
de2d743e 2453 * elf32-frv.c: Likewise.
f0fe0e16
AM
2454 * elf32-h8300.c: Likewise.
2455 * elf32-hppa.c: Likewise.
2456 * elf32-ip2k.c: Likewise.
2457 * elf32-sparc.c: Likewise.
2458 * elf32-v850.c: Likewise.
2459 * elf32-vax.c: Likewise.
2460 * elf64-hppa.c: Likewise.
2461 * elf64-sparc.c: Likewise.
2462 * elf32-fr30.c (elf32_frv_relocate_section): Edit comment.
de2d743e 2463 * elf32-frv.c (elf32_frv_relocate_section): Likewise.
f0fe0e16
AM
2464 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
2465 * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
2466 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
2467 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
2468 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
2469 * elf-m10200.c (USE_RELA): Don't define.
2470 * elf-m10300.c: Likewise.
de2d743e 2471 * elfarm-oabi.c: Likewise.
f0fe0e16
AM
2472 * elf32-i370.c: Likewise.
2473 * elf32-ip2k.c: Likewise.
2474 * elf32-m68k.c: Likewise.
2475 * elf32-mcore.c: Likewise.
2476 * elf32-ppc.c: Likewise.
2477 * elf32-s390.c: Likewise.
2478 * elf32-vax.c: Likewise.
2479 * elf64-ppc.c: Likewise.
2480 * elf64-s390.c: Likewise.
2481 * elf64-x86-64.c: Likewise.
2482 * elfxx-ia64.c: Likewise.
2483 * elf32-avr.c (USE_REL): Don't undef.
2484 * elf32-ip2k.c: Likewise.
2485
5e8d7549
NC
24862002-07-23 Nick Clifton <nickc@redhat.com>
2487
2488 * elf-bfd.h (struct elf_backend_data): Add new bitfield
2489 'want_p_paddr_set_to_zero'.
2490 * elfxx-target.h: Set default value for want_p_paddr_set_to_zero
2491 to false;
2492 * elfxx-ia64.c: Set want_p_paddr_set_zero for HPUX target.
2493 * elf.c (copy_private_bfd_data): Test want_p_paddr_set_zero.
2494
9e12c7db
NC
24952002-07-23 Gabor Keresztfalvi <keresztg@mail.com>
2496
2497 * nlmcode.h (nlm_swap_auxiliary_headers_out): Swapped the order of
2498 the MeSsAgEs and CoPyRiGhT tags to make >=NW4.x NLM loaders to
2499 show the Copyright string.
2500 Minor formatting tidy ups.
2501
0461a601
NC
25022002-07-23 Nick Clifton <nickc@redhat.com>
2503
ff3063f5
NC
2504 * po/fr.po: Updated French translation.
2505 * po/sv.po: Updated Swedish translation.
0461a601 2506
fad2542d
AM
25072002-07-23 Alan Modra <amodra@bigpond.net.au>
2508
2509 * elflink.h (elf_link_input_bfd): Don't change internal symbols
2510 when outputting relocs.
2511
c0647bfc
JT
25122002-07-20 Jason Thorpe <thorpej@wasabisystems.com>
2513
2514 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Only insert
2515 DT_PLTGOT into the dynamic section if there is a PLT.
2516
d01414a5
TS
25172002-07-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2518
2519 * elfxx-mips.c (_bfd_mips_elf_discard_info): New function, code from
2520 elf32-mips.c.
2521 (_bfd_mips_elf_write_section): Likewise.
2522 * elfxx-mips.h (_bfd_mips_elf_discard_info): New prototype.
2523 (_bfd_mips_elf_write_section): Likewise.
2524 * elf32-mips.c (elf32_mips_discard_info): Move to elfxx-mips.c.
2525 (elf32_mips_write_section): Likewise.
2526 * elf64-mips.c (_bfd_mips_elf_ignore_discarded_relocs): Use it.
2527 (_bfd_mips_elf_write_section): Likewise.
2528
40c97fc6
AM
25292002-07-19 Alan Modra <amodra@bigpond.net.au>
2530
2531 * elfxx-ia64.c: (elfNN_ia64_modify_segment_map): Properly scan
2532 PT_IA_64_UNWIND segments for a given section.
2533
58378160
L
25342002-07-17 H.J. Lu <hjl@gnu.org>
2535
2536 * Makefile.am: Fix a typo.
2537 * Makefile.in: Regenerate.
2538
cf88bb9f
NC
25392002-07-15 Denis Chertykov <denisc@overta.ru>
2540 Frank Ch. Eigler <fche@redhat.com>
2541 Ben Elliston <bje@redhat.com>
2542 Alan Lehotsky <alehotsky@cygnus.com>
2543 John Healy <jhealy@redhat.com>
2544 Graham Stott <grahams@redhat.com>
2545 Jeff Johnston <jjohnstn@redhat.com>
2546
2547 * Makefile.am: Add support for ip2k.
2548 * Makefile.in: Regenerate.
2549 * doc/Makefile.in: Regenerate.
2550 * archures.c: Add support for ip2k.
2551 * config.bfd: Add support for ip2k.
2552 * configure.in: Add support for ip2k.
2553 * configure: Regenerate.
2554 * reloc.c: Add support for ip2k.
2555 * targets.c: Add support for ip2k.
2556 * bfd-in2.h: Regenerate.
2557 * libbfd.h: Regenerate.
2558 * cpu-ip2k.c: New file.
2559 * elf32-ip2k.c: New file.
2560
0dafd5f6
RE
25612002-07-17 Ian Rickards <irickard@arm.com>
2562
40c97fc6 2563 * dwarf2.c (concat_filename): If we can't establish the directory
0dafd5f6
RE
2564 just return the filename.
2565
36b08f12
AM
25662002-07-16 Moritz Jodeit <moritz@jodeit.org>
2567
2568 * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Correct order of memset args.
2569
58821868
AM
25702002-07-16 Alan Modra <amodra@bigpond.net.au>
2571
2572 * elflink.h: Formatting fixes, tidy prototypes.
2573 (elf_link_assign_sym_version): Move common code out of loop.
2574
c89583f8
AM
25752002-07-16 Alan Modra <amodra@bigpond.net.au>
2576
2577 * elflink.h (elf_link_input_bfd): Don't call reloc_emitter when
2578 reloc section size is zero. Correct reloc output location.
2579
ba94744e
AM
25802002-07-16 John David Anglin <dave@hiauly1.hia.nrc.ca>
2581
2582 * elf-hppa.h (elf_hppa_reloc_final_type): Use R_PARISC_PCREL16F as
2583 the final type for the e_fsel selector when generating PA2.0W code.
2584 (elf_hppa_relocate_insn): Provide support for PA2.0W 16-bit format 1
2585 relocations.
2586
96a94295
L
25872002-07-14 H.J. Lu <hjl@gnu.org>
2588
2589 * elflink.h (elf_link_assign_sym_version): Hide the default
2590 definition if there is a hidden versioned definition.
2591
6849c52f
HPN
25922002-07-12 Hans-Peter Nilsson <hp@axis.com>
2593
2594 * elf32-cris.c (cris_elf_relocate_section): Drop nonsensical
2595 dynamic reference test in assertion when initializing GOT with
2596 static contents. Just assert that there are either no dynamic
2597 sections, the symbol is defined in the regular objects or that the
2598 symbol is undef weak. Tweak comment.
2599 (elf_cris_finish_dynamic_symbol): Emit .got reloc for a program
2600 only if the symbol isn't defined in the program and isn't undef
2601 weak.
2602 (elf_cris_adjust_dynamic_symbol): Simplify condition for getting
2603 rid of PLT entry: only do it if the symbol isn't defined in a DSO.
2604 When doing so, clear ELF_LINK_HASH_NEEDS_PLT. Tweak comments.
2605 (elf_cris_discard_excess_program_dynamics): Don't consider
2606 ELF_LINK_HASH_REF_DYNAMIC when omitting .got runtime relocs.
2607
239e1f3a
AM
26082002-07-11 Alan Modra <amodra@bigpond.net.au>
2609
2610 * elf32-i386.c (elf_i386_relocate_section): Don't complain about
2611 unresolved debugging relocs in dynamic applications.
2612 * elf32-s390.c (elf_s390_relocate_section): Likewise.
2613 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
2614 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
2615 * elf64-s390.c (elf_s390_relocate_section): Likewise.
2616 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
2617 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
2618
2f6d9989
AM
26192002-07-10 Alan Modra <amodra@bigpond.net.au>
2620
f5e87a1d
AM
2621 * elf64-ppc.c (ONES): Define.
2622 (ppc64_elf_howto_table): Use ONES here to avoid warnings. Fill in
2623 missing src_mask fields. Tweak R_PPC64_NONE, R_PPC64_COPY. Fill
2624 in missing dst_mask fields on R_PPC64_PLT32, R_PPC64_PLTREL32.
2625
2f6d9989
AM
2626 * elf64-ppc.c (ppc64_elf_get_symbol_info): Delete.
2627 (ppc64_elf_set_private_flags): Delete.
2628 (ppc64_elf_section_from_shdr): Delete.
2629 (ppc64_elf_merge_private_bfd_data): Remove flag checking/merging code.
2630 (ppc64_elf_fake_sections): Delete.
2631 (bfd_elf64_bfd_set_private_flags): Don't define.
2632 (bfd_elf64_get_symbol_info): Likewise.
2633 (elf_backend_section_from_shdr): Likewise.
2634 (elf_backend_fake_sections): Likewise.
2635
0594c12d
AM
26362002-07-10 Marco Walther <Marco.Walther@sun.com>
2637
2638 * elf.c: (assign_section_numbers) Set sh_entsize for .stab only
2639 when not already set.
2640 * elf64-sparc.c: (sparc64_elf_fake_sections): New function.
2641 (elf_backend_fake_sections): Define.
2642
699cb9b8
AM
26432002-07-10 Alan Modra <amodra@bigpond.net.au>
2644
2645 * merge.c (_bfd_merge_section): Remove redundant output_section check.
2646 Formatting.
2647 (_bfd_merge_sections): Don't set SEC_EXCLUDE on unused sections.
2648
0a4787a0
HPN
26492002-07-09 Hans-Peter Nilsson <hp@axis.com>
2650
2651 * elf32-cris.c (cris_elf_relocate_section): Move sanity-check for
2652 NULL sym_hashes to just before use.
2653 <case R_CRIS_32_GOTREL>: In test for local symbol, accept also
2654 symbol with non-default visibility.
2655 <case R_CRIS_32_GOTREL, case R_CRIS_32_PLT_GOTREL>: Ditto.
2656 <case R_CRIS_8_PCREL, case R_CRIS_16_PCREL, case R_CRIS_32_PCREL>:
2657 Ditto.
2658 (cris_elf_gc_sweep_hook): Only decrease h->plt.refcount for
2659 symbol with non-default visibility.
2660 (cris_elf_check_relocs): At tests for local symbol before
2661 increasing h->plt.refcount, also check for non-default
2662 visibility. Ditto when checking for local symbol to eliminate
2663 pc-relative runtime relocs.
2664
aecc8f8a
AM
26652002-07-08 Alan Modra <amodra@bigpond.net.au>
2666
2667 * elf.c: Formatting.
2668 (IS_SOLARIS_PT_INTERP): Add p_paddr and p_memsz checks.
2669 (INCLUDE_SECTION_IN_SEGMENT): Remove IS_SOLARIS_PT_INTERP.
2670 (copy_private_bfd_data): Set p_vaddr on broken Solaris PT_INTERP
2671 segments.
2672
e9168c1e
MM
26732002-07-07 Mark Mitchell <mark@codesourcery.com>
2674 Alan Modra <amodra@bigpond.net.au>
2675
2676 * cofflink.c (_bfd_coff_final_link): On PE COFF systems, take into
2677 account the impact of relocation count overflow when computing
2678 section offsets.
2679 * coffcode.h (coff_write_relocs): Use obj_pe when deciding whether
2680 or not to apply the PE COFF reloc overflow handling. Fix a
2681 fencepost error in deciding whether or not to use that technique.
2682
6cdc0ccc
AM
26832002-07-07 Alan Modra <amodra@bigpond.net.au>
2684
2685 * elf-bfd.h (struct elf_reloc_cookie): Remove locsym_shndx,
2686 change type of locsyms.
2687 (bfd_elf_get_elf_syms): Declare.
2688 * elf.c (bfd_elf_get_elf_syms): New function.
2689 (group_signature): Use bfd_elf_get_elf_syms.
2690 (bfd_section_from_r_symndx): Likewise.
2691 * elfcode.h (elf_slurp_symbol_table): Likewise.
2692 * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
2693 (elf_link_add_object_symbols): Likewise. Reorganise to increase
2694 locality of various data structures. Properly free internal relocs.
2695 (elf_bfd_final_link): Properly free internal relocs.
2696 (elf_link_check_versioned_symbol): Use bfd_elf_get_elf_syms.
2697 (elf_link_input_bfd): Likewise.
2698 (elf_gc_mark): Likewise. Properly free internal relocs.
2699 (elf_gc_sweep): Properly free internal relocs.
2700 (elf_reloc_symbol_deleted_p): No need to swap syms in.
2701 (elf_bfd_discard_info): Use bfd_elf_get_elf_syms. Properly free
2702 internal relocs.
2703 * elf-m10200.c (mn10200_elf_relax_section): Use bfd_elf_get_elf_syms.
2704 Properly free possibly cached info.
2705 (mn10200_elf_relax_delete_bytes): Remove symbol swapping code.
2706 (mn10200_elf_symbol_address_p): Pass in internal syms. Remove
2707 symbol swapping code.
2708 (mn10200_elf_get_relocated_section_contents): Use bfd_elf_get_elf_syms.
2709 Properly free possibly cached info.
2710 * elf-m10300.c (mn10300_elf_relax_section): As above for elf-m10200.c.
2711 (mn10300_elf_relax_delete_bytes): Likewise.
2712 (mn10300_elf_symbol_address_p): Likewise.
2713 (mn10300_elf_get_relocated_section_contents): Likewise.
2714 * elf32-h8300.c (elf32_h8_relax_section): As above for elf-m10200.c.
2715 (elf32_h8_relax_delete_bytes): Likewise.
2716 (elf32_h8_symbol_address_p): Likewise.
2717 (elf32_h8_get_relocated_section_contents): Likewise.
2718 * elf32-m32r.c (m32r_elf_relax_section): As above for elf-m10200.c.
2719 (m32r_elf_relax_delete_bytes): Likewise.
2720 (m32r_elf_get_relocated_section_contents): Likewise.
2721 * elf32-sh.c (sh_elf_reloc_loop): Free section contents using
2722 elf_section_data to determine whether cached.
2723 (sh_elf_relax_section): As above for elf-m10200.c.
2724 (sh_elf_relax_delete_bytes): Likewise.
2725 (sh_elf_get_relocated_section_contents): Likewise.
2726 * elf32-xstormy16.c (xstormy16_elf_relax_section): As above.
2727 * elf64-alpha.c (elf64_alpha_relax_section): As above. Also delay
2728 reading of local syms.
2729 * elf64-mmix.c (mmix_elf_relax_section): Likewise.
2730 * elf64-sh64.c (sh_elf64_get_relocated_section_contents): As above.
2731 * elfxx-ia64.c (elfNN_ia64_relax_section): As above.
2732 * elfxx-mips.c (_bfd_mips_elf_check_relocs): Properly free internal
2733 relocs.
2734 * elf32-arm.h (bfd_elf32_arm_process_before_allocation): Properly
2735 free internal relocs and section contents. Don't read symbols.
2736 * elf32-hppa.c (get_local_syms): Use bfd_elf_get_elf_syms.
2737 (elf32_hppa_size_stubs): Don't free local syms.
2738 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Delay
2739 reading of local syms. Use bfd_elf_get_elf_syms. Properly free
2740 possibly cached info.
2741 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
2742 * elf64-hppa.c (elf64_hppa_check_relocs): Use bfd_elf_get_elf_syms.
2743 * elf64-ppc.c (struct ppc_link_hash_table): Delete bfd_count and
2744 all_local_syms.
2745 (get_local_syms): Delete function.
2746 (edit_opd): Use bfd_elf_get_elf_syms. Free on error exit. Cache
2747 on exit.
2748 (ppc64_elf_size_stubs): Use bfd_elf_get_elf_syms. Free/cache on exit.
2749
b3212001
JW
27502002-07-05 Jim Wilson <wilson@redhat.com>
2751
2752 * syms.c (decode_section_type): New.
2753 (bfd_decode_symclass): Call decode_section_type.
2754
894bb1ee
JJ
27552002-07-04 Jakub Jelinek <jakub@redhat.com>
2756
2757 * merge.c (_bfd_merged_section_offset): Avoid accessing byte before
2758 section content start.
2759 Reported by Michael Schumacher <mike@hightec-rt.com>.
2760
bc0ba537
AM
27612002-07-04 Alan Modra <amodra@bigpond.net.au>
2762
2763 * section.c (_bfd_strip_section_from_output): Remove unnecessary
2764 link order code. Don't actually remove the output section here;
2765 Just set a flag for the linker to do so.
2766 * elflink.c (_bfd_elf_link_renumber_dynsyms): Test for removed
2767 sections when setting up output section dynsyms.
2768
797fc050
AM
27692002-07-04 Alan Modra <amodra@bigpond.net.au>
2770
2771 * elflink.h (elf_link_add_object_symbols): Revert 1999-09-02 hpux
2772 fudge.
2773 * elf.c (bfd_section_from_shdr): Work around broken hpux shared
2774 libs here instead.
2775
99881371
MS
27762002-07-02 Martin Schwidefsky <schwidefsky@de.ibm.com>
2777
2778 * elf64-s390.c (create_got_section): Set .got section alignment to
2779 8 bytes.
2780 (elf_s390_check_relocs): Set .rela.dyn section alignment to 8 bytes.
2781
47d9a591
AM
27822002-07-02 Alan Modra <amodra@bigpond.net.au>
2783
2784 * elf.c (_bfd_elf_reloc_type_class): Fix comment grammar.
2785
179d3252
JT
27862002-07-01 Matt Thomas <matt@3am-software.com>
2787
2788 * elf32-vax.c (elf32_vax_print_private_bfd_data): Change EF_*
2789 to EF_VAX_*.
2790
4a14403c
TS
27912002-07-01 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2792
2793 * elfxx-mips.c (ABI_64_P): Fix comment.
2794 (MIPS_ELF_OPTIONS_SECTION_NAME,MIPS_ELF_STUB_SECTION_NAME): Use the
2795 new section names for N64 ABI.
2796 (mips_elf_output_extsym): No special _gp_disp handling for NewABI.
2797 (mips_elf_calculate_relocation): Code formatting.
2798 (mips_elf_create_dynamic_relocation): Likewise.
2799 (_bfd_mips_elf_fake_sections): IRIX6 needs this hack, too.
2800 (_bfd_mips_elf_size_dynamic_sections): Handle GOT_PAGE for any NewABI.
2801 (_bfd_mips_elf_relocate_section): No special handling for R_MIPS_64
2802 in any NewABI.
2803 (_bfd_mips_elf_finish_dynamic_symbol): No special _gp_disp handling
2804 for NewABI.
2805 (_bfd_mips_elf_modify_segment_map): Handle any N64 ABI.
2806 (_bfd_mips_elf_gc_sweep_hook): NewABI GOT relocs should be handled
2807 here, too.
2808
607c0e09
AS
28092002-07-01 Andreas Schwab <schwab@suse.de>
2810
2811 * elf64-x86-64.c (elf64_x86_64_relocate_section): Only convert
2812 R_X86_64_64 to R_X86_64_RELATIVE.
2813
ba26fd96
AM
28142002-07-01 John David Anglin <dave@hiauly1.hia.nrc.ca>
2815
2816 * vaxbsd.c: New BFD backend for VAX BSD and Ultrix.
2817 * Makefile.am (BFD32_BACKENDS, BFD32_BACKENDS_CFILES): Add new backend.
2818 Run "make dep-am".
2819 * config.bfd (vax-*-bsd* | vax-*-ultrix*): Use vaxbsd_vec instead of
2820 host_aout_vec.
2821 * configure.in (vaxbsd_vec): Add.
2822 * targets.c (vaxbsd_vec): Add.
2823 * Makefile.in: Rebuild.
2824 * configure: Rebuild.
2825 * po/SRC-POTFILES.in: Rebuild.
2826
1e2f5b6e
AM
28272002-07-01 Alan Modra <amodra@bigpond.net.au>
2828
2829 * elflink.h (elf_gc_mark): Pass in the section whose relocs we are
2830 examining to gc_mark_hook, rather than the bfd.
2831 (elf_gc_sections): Adjust.
2832 * elf-bfd.h (struct elf_backend_data <gc_mark_hook>): Likewise.
2833 * elf-m10300.c (mn10300_elf_gc_mark_hook): Likewise.
2834 * elf32-arm.h (elf32_arm_gc_mark_hook): Likewise.
2835 * elf32-avr.c (elf32_avr_gc_mark_hook): Likewise.
2836 * elf32-cris.c (cris_elf_gc_mark_hook): Likewise.
2837 * elf32-d10v.c (elf32_d10v_gc_mark_hook): Likewise.
2838 * elf32-fr30.c (fr30_elf_gc_mark_hook): Likewise.
2839 * elf32-hppa.c (elf32_hppa_gc_mark_hook): Likewise.
2840 * elf32-i386.c (elf_i386_gc_mark_hook): Likewise.
2841 * elf32-m32r.c (m32r_elf_gc_mark_hook): Likewise.
2842 * elf32-m68k.c (elf_m68k_gc_mark_hook): Likewise.
2843 * elf32-mcore.c (mcore_elf_gc_mark_hook): Likewise.
2844 * elf32-openrisc.c (openrisc_elf_gc_mark_hook): Likewise.
2845 * elf32-ppc.c (ppc_elf_gc_mark_hook): Likewise.
2846 * elf32-s390.c (elf_s390_gc_mark_hook): Likewise.
2847 * elf32-sh.c (sh_elf_gc_mark_hook): Likewise.
2848 * elf32-sparc.c (elf32_sparc_gc_mark_hook): Likewise.
2849 * elf32-v850.c (v850_elf_gc_mark_hook): Likewise.
2850 * elf32-vax.c (elf_vax_gc_mark_hook): Likewise.
2851 * elf32-xstormy16.c (xstormy16_elf_gc_mark_hook): Likewise.
2852 * elf64-mmix.c (mmix_elf_gc_mark_hook): Likewise.
2853 * elf64-ppc.c (ppc64_elf_gc_mark_hook): Likewise.
2854 * elf64-s390.c (elf_s390_gc_mark_hook): Likewise.
2855 * elf64-sh64.c (sh_elf64_gc_mark_hook): Likewise.
2856 * elfxx-mips.c (_bfd_mips_elf_gc_mark_hook): Likewise.
2857 * elfxx-mips.h (_bfd_mips_elf_gc_mark_hook): Likewise.
2858 * elf64-x86-64.c (elf64_x86_64_gc_mark_hook): Likewise.
2859 * elf32-frv.c (elf32_frv_gc_mark_hook): Likewise. Also remove
2860 redundant local sym tests.
2861 * elf64-ppc.c (struct ppc_link_hash_entry): Add is_entry.
2862 (link_hash_newfunc): Init is_entry.
2863 (ppc64_elf_copy_indirect_symbol): Copy is_entry.
2864 (ppc64_elf_link_hash_table_create): Init all_local_syms.
2865 (create_linkage_sections): Use bfd_make_section_anyway rather than
2866 bfd_make_section.
2867 (ppc64_elf_mark_entry_syms): New function.
2868 (ppc64_elf_check_relocs): Don't bother testing elf_bad_symtab. Set
2869 up opd entry to function section map.
2870 (ppc64_elf_gc_mark_hook): Special case opd section relocs, and
2871 relocs that reference the opd section.
2872 (edit_opd): New function.
2873 (ppc64_elf_size_dynamic_sections): Call get_local_syms and edit_opd.
2874 (ppc64_elf_setup_section_lists): Don't calculate htab->bfd_count here.
2875 (get_local_syms): Do so here. Exit if we already have local syms.
2876 Remove bogus comment imported from elf32-hppa.c. Don't attempt to
2877 read local syms on non-ELF input.
2878 (ppc64_elf_size_stubs): Call _bfd_elf64_link_read_relocs rather
2879 than duplicating it's function here. Adjust free of internal
2880 relocs to suit.
2881 (ppc64_elf_relocate_section): Adjust local syms in opd section.
2882 * elf64-ppc.h (ppc64_elf_mark_entry_syms): Declare.
2883 * elf32-hppa.c (elf32_hppa_size_stubs): Call
2884 _bfd_elf32_link_read_relocs rather than duplicating it's function
2885 here. Adjust free of internal relocs to suit.
2886
1b71fb54
AJ
28872002-07-01 Andreas Jaeger <aj@suse.de>
2888
2889 * elf64-x86-64.c (elf64_x86_64_check_relocs): Certain relocations
2890 are not allowed in shared libs code, enforce -fPIC.
2891
8d28f606
HPN
28922002-06-29 Hans-Peter Nilsson <hp@bitrange.com>
2893
2894 * mmo.c (mmo_write_loc_chunk): Don't eliminate leading and
2895 trailing zero-sequences when there's previous left-over data.
2896
5ac81c74
JL
28972002-06-27 John David Anglin <dave@hiauly1.hia.nrc.ca>
2898
2899 * elf64-hppa.c (elf64_hppa_reloc_type_class): New function.
2900 (elf64_hppa_finish_dynamic_sections): Check other_rel_sec, dlt_rel_sec
2901 and opd_rel_sec in order for starting rela section. Check _raw_size.
2902 (elf_backend_reloc_type_class): Define.
2903
91a4d569
AM
29042002-06-27 Kevin Buettner <kevinb@redhat.com>
2905
2906 * dwarf2.c (decode_line_info): Handle older, non-standard, 64-bit
2907 DWARF2 formats.
2908
feee612b
AM
29092002-06-27 Alan Modra <amodra@bigpond.net.au>
2910
2911 * cpu-powerpc.c: Comment on ordering of arch_info.
2912 * elf32-ppc.c (ppc_elf_object_p): New function.
2913 (elf_backend_object_p): Define.
2914 * elf64-ppc.c (ppc64_elf_object_p): New function.
2915 (elf_backend_object_p): Define.
2916
a4e6cefc
JT
29172002-06-26 Jason Thorpe <thorpej@wasabisystems.com>
2918
2919 * configure.in (vax-*-netbsd*): Set COREFILE to netbsd-core.lo.
2920 * configure: Regenerate.
2921
dae2dd0d
NC
29222002-06-25 Jason Eckhardt <jle@rice.edu>
2923
2924 * dwarf2.c (decode_line_info): Check unit->addr_size
2925 to read in the proper number of prologue bytes.
2926
680f9d5c
NC
29272002-06-25 Nick Clifton <nickc@cambridge.redhat.com>
2928
2929 * config.bfd (powerpc-*-aix5*): Only create a selvecs for
2930 aix5coff64_vec if 64-bit bfd support has been enabled.
91a4d569
AM
2931 (powerpc64-*-aix5*): Only define if 64-bit bfd support has
2932 been enabled.
dae2dd0d 2933
680f9d5c
NC
2934 * targets.c (_bfd_target_vector[]): Only include
2935 aix5coff64_vec if 64-bit bfd support has been enabled.
2936
d4c88bbb
AM
29372002-06-25 Alan Modra <amodra@bigpond.net.au>
2938
2939 * elf64-ppc.c (ppc_add_stub): Replace strcpy/strncpy with memcpy.
2940 * elf32-hppa.c (hppa_add_stub): Likewise.
2941 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
2942 * elflink.h (elf_add_default_symbol): Fix comment typo.
2943 (elf_add_default_symbol): Replace strcpy and strncpy with memcpy.
2944 (elf_link_add_object_symbols): Likewise.
2945 (elf_link_assign_sym_version): Likewise.
2946 * hash.c (bfd_hash_lookup): Likewise.
2947 * linker.c (_bfd_generic_link_add_one_symbol): Likewise.
2948 * section.c (bfd_get_unique_section_name): Likewise.
2949 * syms.c (_bfd_stab_section_find_nearest_line): Likewise.
2950 * elf.c (_bfd_elf_make_section_from_phdr): Likewise.
2951 (assign_section_numbers): Likewise.
2952 (_bfd_elfcore_make_pseudosection): Likewise.
2953 (elfcore_grok_lwpstatus): Likewise.
2954 (elfcore_grok_win32pstatus): Likewise.
2955 (elfcore_write_note): Constify input params. Use PTR instead of
2956 void *. Include terminating NUL in namesz. Correct padding.
2957 Support NULL "name" param. Use memcpy instead of strcpy.
2958 (elfcore_write_prpsinfo): Constify input params.
2959 (elfcore_write_prstatus): Likewise. Use PTR instead of void *.
2960 (elfcore_write_lwpstatus): Likewise.
2961 (elfcore_write_pstatus): Likewise.
2962 (elfcore_write_prfpreg): Likewise.
2963 (elfcore_write_prxfpreg): Likewise.
2964 * elf-bfd.h (elfcore_write_note): Update declaration.
2965 (elfcore_write_prpsinfo): Likewise.
2966 (elfcore_write_prstatus): Likewise.
2967 (elfcore_write_pstatus): Likewise.
2968 (elfcore_write_prfpreg): Likewise.
2969 (elfcore_write_prxfpreg): Likewise.
2970 (elfcore_write_lwpstatus): Likewise.
2971
b0ac09d2
NC
29722002-06-25 Jason Eckhardt <jle@rice.edu>
2973
2974 * ecoff.c (ecoff_set_symbol_info): Set BSF_FUNCTION for
2975 symbols of type stProc and stStaticProc.
2976
29772002-06-25 Nick Clifton <nickc@redhat.com>
2978
2979 * ecoff.c: VArious formatting fixes.
2980
021d6096
AM
29812002-06-25 Alan Modra <amodra@bigpond.net.au>
2982
2983 * coff-rs6000.c (xcoff_generate_rtinit): Fix typo.
2984
82e51918
AM
29852002-06-25 Alan Modra <amodra@bigpond.net.au>
2986
2987 * aout-adobe.c: Don't compare against "true" or "false.
2988 * aout-target.h: Likewise.
2989 * aoutx.h: Likewise.
2990 * archive.c: Likewise.
2991 * bout.c: Likewise.
2992 * cache.c: Likewise.
2993 * coff-a29k.c: Likewise.
2994 * coff-alpha.c: Likewise.
2995 * coff-i386.c: Likewise.
2996 * coff-mips.c: Likewise.
2997 * coff-or32.c: Likewise.
2998 * coff64-rs6000.c: Likewise.
2999 * coffcode.h: Likewise.
3000 * coffgen.c: Likewise.
3001 * cpu-ns32k.c: Likewise.
3002 * ecoff.c: Likewise.
3003 * ecofflink.c: Likewise.
3004 * elf.c: Likewise.
3005 * elf32-arm.h: Likewise.
3006 * elf32-cris.c: Likewise.
3007 * elf32-d30v.c: Likewise.
3008 * elf32-i386.c: Likewise.
3009 * elf32-mcore.c: Likewise.
3010 * elf32-ppc.c: Likewise.
3011 * elf32-sh.c: Likewise.
3012 * elf32-sh64.c: Likewise.
3013 * elf32-v850.c: Likewise.
3014 * elf64-alpha.c: Likewise.
3015 * elf64-sh64.c: Likewise.
3016 * elfcode.h: Likewise.
3017 * elfcore.h: Likewise.
3018 * elflink.h: Likewise.
3019 * elfxx-mips.c: Likewise.
3020 * i386os9k.c: Likewise.
3021 * ieee.c: Likewise.
3022 * libbfd.c: Likewise.
3023 * linker.c: Likewise.
3024 * mmo.c: Likewise.
3025 * nlm32-alpha.c: Likewise.
3026 * nlm32-i386.c: Likewise.
3027 * nlm32-ppc.c: Likewise.
3028 * nlm32-sparc.c: Likewise.
3029 * nlmcode.h: Likewise.
3030 * oasys.c: Likewise.
3031 * pdp11.c: Likewise.
3032 * peicode.h: Likewise.
3033 * reloc.c: Likewise.
3034 * som.c: Likewise.
3035 * srec.c: Likewise.
3036 * tekhex.c: Likewise.
3037 * vms.c: Likewise.
3038 * xcofflink.c: Likewise.
3039 * elf64-sparc.c: Edit comment to not use "== false".
3040
3041 * aoutf1.h: Don't use "? true : false".
3042 * ecoff.c: Likewise.
3043 * format.c: Likewise.
3044 * ieee.c: Likewise.
3045 * linker.c: Likewise.
3046 * mmo.c: Likewise.
3047 * oasys.c: Likewise.
3048
48fc70a2
AM
30492002-06-23 H.J. Lu <hjl@gnu.org>
3050
3051 * elflink.h (elf_link_add_archive_symbols): For the default
3052 version, check references with only one `@' first.
3053
47b7c2db
AM
30542002-06-23 John David Anglin <dave@hiauly1.hia.nrc.ca>
3055
3056 * elf64-hppa.c (elf64_hppa_mark_milli_and_exported_functions): New
3057 function.
3058 (allocate_global_data_dlt): Don't add millicode symbols to dynamic
3059 symbol table.
3060 (allocate_global_data_opd, allocate_dynrel_entries): Likewise.
3061 (elf64_hppa_size_dynamic_sections): Revise to use
3062 elf64_hppa_mark_milli_and_exported_functions.
3063 (elf64_hppa_finish_dynamic_symbol): Remove code to keep millicode
3064 symbols out of dynamic symbol table.
3065
f5d44ba0
AM
30662002-06-23 Alan Modra <amodra@bigpond.net.au>
3067
bb3fff1e
AM
3068 * Makefile.in: Regenerate.
3069 * libbfd.h: Regenerate.
3070 * bfd-in2.h: Regenerate.
3071 * configure: Regenerate.
3072 * po/SRC-POTFILES.in: Regenerate.
3073
f5d44ba0
AM
3074 * elflink.h: Comment typo fixes.
3075
30762002-06-23 H.J. Lu <hjl@gnu.org>
3077
3078 * elf-bfd.h (elf_link_loaded_list): New structure.
3079 (elf_link_hash_table): Add "loaded".
3080 * elf.c (_bfd_elf_link_hash_table_init): Initialize "loaded".
3081 * elflink.h (elf_link_check_versioned_symbol): New function.
3082 (elf_link_output_extsym): Call elf_link_check_versioned_symbol.
3083
cc36acdf
NC
30842002-06-19 Nick Clifton <nickc@cambridge.redhat.com>
3085
3086 * elflink.h (size_dynamic_sections): If the target does not
f5d44ba0 3087 support an ELF style hash table, return true, indicating that
cc36acdf
NC
3088 nothing needed to be done, rather than false, indicating that the
3089 section's size could not be computed.
3090
4e5ba5b7
DB
30912002-06-18 Dave Brolley <brolley@redhat.com>
3092
3093 From Catherine Moore, Michael Meissner, Dave Brolley:
3094 * po/SRC-POTFILES.in: Add cpu-frv.c and elf32-frv.c
3095 * targets.c: Support bfd_elf32_frv_vec.
3096 * reloc.c: Add FRV relocs.
3097 * configure.in: Add support for bfd-elf32-frv-vec.
3098 * config.bfd (targ_cpu): Add support for frv-*-elf.
3099 * archures.c: Add frv arch and machines.
3100 * Makefile.am (ALL_MACHINES): Add cpu-frv.lo.
3101 (ALL_MACHINES_CFILES): Add cpu-frv.c.
3102 (BFD32_BACKENDS): Add elf32-frv.lo.
3103 (BFD32_BACKENDS_CFILES): Add elf32-frv.c
3104 (cpu-frv.lo): New target.
3105 (elf32-frv.lo): New target.
3106 * cpu-frv.c: New file.
3107 * elf32-frv.c: New file.
3108
7ece0d85
JJ
31092002-06-18 Jakub Jelinek <jakub@redhat.com>
3110
3111 * elfcode.h (elf_object_p): Sanity check eh_shoff == 0 implies
3112 e_shnum == 0.
3113 Only read the first section header if e_shoff is non-zero.
3114 Don't consider e_shstrndx if there are no sections.
3115
57fb03ac
TR
31162002-06-17 Tom Rix <trix@redhat.com>
3117
3118 * elf32-d10v.c (elf_d10v_howto_table): Change R_D10V_10_PCREL_R,
f5d44ba0 3119 R_D10V_10_PCREL_L and R_D10V_18_PCREL to use
57fb03ac
TR
3120 complain_overflow_bitfield.
3121
341ca622
AM
31222002-06-17 Alan Modra <amodra@bigpond.net.au>
3123
767e34d1
AM
3124 * opncls.c (bfd_openr): Remove redundant bfd_set_error.
3125 (bfd_fdopenr): Likewise.
3126 (bfd_openstreamr): Likewise.
3127 (bfd_openw): Likewise.
3128
341ca622
AM
3129 * targets.c: Sort target vecs.
3130 (_bfd_target_vector): Add aix5coff64_vec, bfd_elf32_sh64_vec,
3131 bfd_elf32_sh64l_vec, bfd_elf32_sh64lnbsd_vec,
3132 bfd_elf32_sh64nbsd_vec, bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec,
3133 bfd_elf64_sh64lnbsd_vec, bfd_elf64_sh64nbsd_vec.
3134 * configure.in: Sort target vecs. Add m88kmach3_vec.
3135 * configure: Regenerate.
3136
dfbbae4c
HPN
31372002-06-16 Hans-Peter Nilsson <hp@bitrange.com>
3138
3139 * elf64-mmix.c (bpo_reloc_request_sort_fn): Use member
3140 bpo_reloc_no to break sort order ties, not address of items.
3141
d663e1cd
JL
31422002-06-16 John David Anglin <dave@hiauly1.hia.nrc.ca>
3143
3144 * elf-hppa.h (elf_hppa_final_link): Fix formatting in comment.
3145 Skip excluded sections in determing __gp value.
3146 (elf_hppa_final_link_relocate): Use the symbol's address in
3147 R_PARISC_FPTR64 relocations that don't need an opd entry.
3148 * elf64-hppa.c (allocate_dynrel_entries): Simplify code.
3149 (elf64_hppa_finalize_dynreloc): Likewise.
3150 (elf64_hppa_size_dynamic_sections): Move comments and fix typo.
3151 (elf64_hppa_finish_dynamic_symbol): Break up assert.
3152
a8295218
NC
31532002-06-14 Sergey Grigoriev <serge@leopold.Physik.Uni-Augsburg.DE>
3154
3155 * pei-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Enable 16 byte
3156 alignment for .bss, .data and .text sections so that sse and sse2
3157 code will work.
3158 * pe-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
3159
31602002-06013 J"orn Rennecke <joern.rennecke@superh.com>
5d9b5481
JR
3161
3162 config.bfd: Add support for sh[1234]l*-*-elf* | sh3el*-*-elf*,
3163 sh[1234]*-elf*.
3164
3db4b612
JL
31652002-06-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
3166
2cb69dd3
JL
3167 * elflink.h (elf_bfd_final_link): Improve error handling for missing
3168 dynamic sections.
3169
3db4b612
JL
3170 * elf64-hppa.c (allocate_global_data_opd): We don't need an opd entry
3171 for a symbol that has no output section.
3172 (allocate_dynrel_entries): Correct comment.
3173 (elf64_hppa_finalize_dynreloc): Likewise. Don't create an opd entry
3174 unless we want one.
3175 (elf64_hppa_finalize_opd): Prevent segfault if dyn_h is NULL.
3176 (elf64_hppa_finalize_dlt): Likewise. Prevent segfault for symbols
3177 with no section. Remove unnecessary parentheses.
3178
f3813499
TR
31792002-06-11 Tom Rix <trix@redhat.com>
3180
3181 * coffcode.h (coff_compute_section_file_positions): Add data
3182 section to AIX loader alignment check.
3183
f5d44ba0 3184 * coff-rs6000.c (_bfd_xcoff_mkobject): Set default text section
f3813499
TR
3185 alignment to 4 bytes.
3186 (_bfd_xcoff_copy_private_bfd_data): Use text and data alignment
3187 power accessor macro.
3188 (do_shared_object_padding): Remove invalid assertion.
3189
0ebaf185
RS
31902002-06-10 Richard Sandiford <rsandifo@redhat.com>
3191
3192 * section.c (_bfd_strip_section_from_output): Set SEC_EXCLUDE
3193 for removed output sections.
3194
ebe3e2d1
NC
31952002-06-10 Geoffrey Keating <geoffk@redhat.com>
3196
3197 * merge.c (merge_strings): Use htab_create_alloc with calloc, not
3198 htab_alloc.
3199 * elf-strtab.c (_bfd_elf_strtab_finalize): Likewise.
3200
0b14c2aa
L
32012002-06-08 H.J. Lu <hjl@gnu.org>
3202
3203 * elf.c (copy_private_bfd_data): Don't cast to bfd_size_type to
3204 work around a long long bug in gcc 2.96 on mips.
3205
3c2bfad6
JT
32062002-06-08 Jason Thorpe <thorpej@wasabisystems.com>
3207
3208 * Makefile.am (BFD32_BACKENDS): Add vax1knetbsd.lo.
3209 (BFD32_BACKENDS_CFILES): Add vax1knetbsd.c.
3210 Regenerate dependency lists.
3211 * Makefile.in: Regenerate.
3212 * config.bfd (vax-*-netbsdelf*, vax-*-netbsdaout*): Add
3213 vax1knetbsd_vec to targ_selvecs.
3214 * configure.in: Add vax1knetbsd_vec.
3215 * configure: Regenerate.
3216 * targets.c (_bfd_target_vector): Add vax1knetbsd_vec.
3217 * vax1knetbsd.c: New file.
3218 * vaxnetbsd.c: Update copyright years.
3219 (TARGET_PAGE_SIZE): Set to 0x1000.
3220 (DEFAULT_MID): Set to M_VAX4K_NETBSD.
3221
91149be3
JT
32222002-06-08 Matt Thomas <matt@3am-software.com>
3223
3224 * libaout.h (enum machine_type): Add M_VAX4K_NETBSD.
3225
21e15248
AM
32262002-06-08 Alan Modra <amodra@bigpond.net.au>
3227
3228 * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): Make static.
3229
986b7daa
AM
32302002-06-08 Alan Modra <amodra@bigpond.net.au>
3231
e90b95f6
AM
3232 * Makefile.am: Run "make dep-am".
3233 * Makefile.in: Regenerate.
3234
3f9c735e
AM
3235 * armnetbsd.c: Replace CONST with const.
3236 * corefile.c: Likewise.
3237 * elf32-dlx.c: Likewise.
3238 * elf64-mips.c: Likewise.
3239 * mmo.c: Likewise.
3240 * ns32knetbsd.c: Likewise.
3241
986b7daa
AM
3242 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Check the hash
3243 table is elf64-sparc.
3244
5a659663
TS
32452002-06-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3246
3247 * elfxx-mips.c (_bfd_mips_elf_relocate_section): Simplify code.
3248 Fix RELA addends to get not shifted in the result. Don't do special
3249 handling of R_MIPS_64 for NewABI.
3250
9bab7074
AM
32512002-06-07 Alan Modra <amodra@bigpond.net.au>
3252
3253 * aoutx.h (NAME(aout,slurp_symbol_table)): Use bfd_zmalloc.
3254 (NAME(aout,slurp_reloc_table)): Likewise.
3255 * coff-mips.c (mips_relax_section): Use bfd_zalloc.
3256 * coff-rs6000.c (xcoff_write_armap_big): Use bfd_zmalloc.
3257 (xcoff_write_archive_contents_big): Likewise.
3258 (xcoff_generate_rtinit): Likewise.
3259 (xcoff_generate_rtinit): Likewise, and check error return.
3260 * coff64-rs6000.c (xcoff64_generate_rtinit): Likewise.
3261 * coffgen.c (coff_section_symbol): Use bfd_zalloc.
3262 (coff_get_normalized_symtab): Likewise.
3263 (coff_make_empty_symbol): Likewise.
3264 (bfd_coff_set_symbol_class): Likewise.
3265 * cofflink.c (coff_link_add_symbols): Likewise.
3266 * ecoff.c (_bfd_ecoff_make_empty_symbol): Likewise.
3267 * ecofflink.c (ecoff_write_shuffle): Use bfd_zmalloc.
3268 (bfd_ecoff_write_accumulated_debug): Likewise.
3269 * elf64-alpha.c (get_got_entry): Use bfd_zalloc.
3270 * i386linux.c (bfd_i386linux_size_dynamic_sections): Likewise.
3271 * i386lynx.c (NAME(lynx,slurp_reloc_table)): Use bfd_zmalloc.
3272 * ieee.c (do_with_relocs): Use bfd_zalloc.
3273 * m68klinux.c (bfd_m68klinux_size_dynamic_sections): Likewise.
3274 * pdp11.c (NAME(aout,slurp_symbol_table)): Use bfd_zmalloc.
3275 (NAME(aout,slurp_reloc_table)): Likewise.
3276 (NAME(aout,squirt_out_relocs)): Don't memset when zalloc'd.
3277 * reloc16.c (bfd_coff_reloc16_relax_section): Use bfd_zmalloc.
3278 * som.c (som_build_and_write_symbol_table): Likewise.
3279 (som_slurp_string_table): Likewise.
3280 (som_slurp_symbol_table): Likewise.
3281 (som_bfd_ar_write_symbol_stuff): Likewise.
3282 * sparclinux.c (bfd_sparclinux_size_dynamic_sections): Use bfd_zalloc.
3283 * sunos.c (bfd_sunos_size_dynamic_sections): Likewise.
3284 * tekhex.c (find_chunk): Likewise. Get rid of unused "sname".
3285 * vms-gsd.c (_bfd_vms_slurp_gsd): Use bfd_zmalloc.
3286 * xcofflink.c (xcoff_link_add_symbols): Use bfd_zalloc/bfd_zmalloc.
3287
1126897b
AM
32882002-06-07 Alan Modra <amodra@bigpond.net.au>
3289
3290 * elf-bfd.h (struct bfd_elf_section_data <group_name>): Replace with
3291 "group" union.
3292 (elf_group_name): Update.
3293 (elf_group_id): Define.
3294 (bfd_elf_set_group_contents): Declare.
3295 * elf.c (elf_fake_sections): Qualify use of elf_group_name.
3296 (set_group_contents): Rename to bfd_elf_set_group_contents. Remove
3297 ATTRIBUTE_UNUSED from failedptrarg. If elf_group_id is set, use
3298 that sym for the signature.
3299 (_bfd_elf_compute_section_file_positions): Don't call
3300 set_group_contents for "ld -r" case.
3301 (swap_out_syms): Use bfd_zalloc.
3302 * elflink.h (elf_link_add_archive_symbols): Likewise.
3303 (NAME(bfd_elf,size_dynamic_sections)): Likewise.
3304 (elf_bfd_final_link): Call bfd_elf_set_group_contents.
3305
3fad3c7c
AM
33062002-06-07 Alan Modra <amodra@bigpond.net.au>
3307
3308 * elf64-ppc.c (ppc64_elf_relocate_section): Allow unresolved
3309 relocs in opd for non-shared too.
3310
10f469bf 33112002-06-06 Jeffrey Law <law@redhat.com>
76f99c63
JL
3312
3313 * elf32-h8300.c (elf32_h8_relax_section): Ignore uninteresting
3314 relocations.
3315
7217313c
NC
33162002-06-06 Nick Clifton <nickc@cambridge.redhat.com>
3317
3318 * merge.c: Include libiberty.h.
3319 * elf-strtab.c: Include libiberty.h.
3320
6cb22815
AM
33212002-06-06 Elias Athanasopoulos <eathan@otenet.gr>
3322
3323 * peXXigen.c (pe_print_idata): Remove unused variable.
3324
1ed89aa9
NC
33252002-06-06 David Heine <dlheine@tensilica.com>
3326
3327 * elf.c (assign_file_positions_for_segments): Remove unallocated
3328 sections from the section to segment mapping for PT_LOAD segments.
3329 Update comment about empty loadable segments.
3330
644c4c80
RS
33312002-06-06 Richard Sandiford <rsandifo@redhat.com>
3332
3333 * stabs.c (_bfd_link_section_stabs): Check that the symbol offset
3334 is within the .stabstr section.
3335
f8ecb12b
AM
33362002-06-06 Alan Modra <amodra@bigpond.net.au>
3337
3338 * elf-bfd.h (struct elf_size_info <swap_symbol_in>): Function args
3339 are "const PTR", not "const PTR *".
3340 (bfd_elf32_swap_symbol_in): Likewise.
3341 (bfd_elf64_swap_symbol_in): Likewise.
3342 * elfcode.h (elf_swap_symbol_in): Change input args to const PTR.
3343 (elf_slurp_symbol_table): Adjust call to elf_swap_symbol_in.
3344 * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
3345 (elf_link_add_object_symbols): Likewise.
3346 (elf_link_record_local_dynamic_symbol): Likewise.
3347 (elf_link_input_bfd): Likewise.
3348 (elf_gc_mark): Likewise.
3349 (elf_reloc_symbol_deleted_p): Likewise.
3350 * elf-m10200.c (mn10200_elf_relax_section): Likewise.
3351 (mn10200_elf_relax_delete_bytes): Likewise.
3352 (mn10200_elf_symbol_address_p): Likewise.
3353 (mn10200_elf_get_relocated_section_contents): Likewise.
3354 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
3355 (mn10300_elf_relax_section): Likewise.
3356 (mn10300_elf_relax_delete_bytes): Likewise.
3357 (mn10300_elf_symbol_address_p): Likewise.
3358 (mn10300_elf_get_relocated_section_contents): Likewise.
3359 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
3360 (elf32_h8_relax_delete_bytes): Likewise.
3361 (elf32_h8_symbol_address_p): Likewise.
3362 (elf32_h8_get_relocated_section_contents): Likewise.
3363 * elf32-hppa.c (get_local_syms): Likewise.
3364 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
3365 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
3366 * elf32-sh.c (sh_elf_relax_section): Likewise.
3367 (sh_elf_relax_delete_bytes): Likewise.
3368 (sh_elf_get_relocated_section_contents): Likewise.
3369 * elf32-xstormy16.c (xstormy16_elf_relax_section): Likewise.
3370 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
3371 * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
3372 * elf64-mmix.c (mmix_elf_relax_section): Likewise.
3373 * elf64-ppc.c (get_local_syms): Likewise.
3374 * elf64-sh64.c (sh_elf64_get_relocated_section_contents): Likewise.
3375 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
3376
1ed89aa9 33772002-06-05 J"orn Rennecke <joern.rennecke@superh.com>
7a33bc10
JR
3378
3379 * config.bfd (sh64l*-*-elf*, shl*-*-elf*): New configurations.
3380
73ff0d56
AM
33812002-06-05 Alan Modra <amodra@bigpond.net.au>
3382
9dce4196
AM
3383 * elf.c (group_signature): Swap in the whole symbol, and handle
3384 extracting section symbol names.
3385 (setup_group): Add comment.
3386 (set_group_contents): When called from objcopy or ld, arrange for
3387 section contents to be written. Write group member output section
3388 indices to allow objcopy to reorganize sections.
3389 (_bfd_elf_copy_private_section_data): Copy group info.
3390
73ff0d56
AM
3391 * elf-bfd.h (struct elf_size_info): Add swap_symbol_in field.
3392 (bfd_elf32_swap_symbol_in): Update prototype.
3393 (bfd_elf64_swap_symbol_in): Likewise.
3394 * elfcode.h (elf_swap_symbol_in): Change input args to const PTR *.
3395 (elf_slurp_symbol_table): Adjust call to elf_swap_symbol_in.
3396 * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
3397 (elf_link_add_object_symbols): Likewise.
3398 (elf_link_record_local_dynamic_symbol): Likewise.
3399 (elf_link_input_bfd): Likewise.
3400 (elf_gc_mark): Likewise.
3401 (elf_reloc_symbol_deleted_p): Likewise.
3402 * elf-m10200.c (mn10200_elf_relax_section): Likewise.
3403 (mn10200_elf_relax_delete_bytes): Likewise.
3404 (mn10200_elf_symbol_address_p): Likewise.
3405 (mn10200_elf_get_relocated_section_contents): Likewise.
3406 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
3407 (mn10300_elf_relax_section): Likewise.
3408 (mn10300_elf_relax_delete_bytes): Likewise.
3409 (mn10300_elf_symbol_address_p): Likewise.
3410 (mn10300_elf_get_relocated_section_contents): Likewise.
3411 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
3412 (elf32_h8_relax_delete_bytes): Likewise.
3413 (elf32_h8_symbol_address_p): Likewise.
3414 (elf32_h8_get_relocated_section_contents): Likewise.
3415 * elf32-hppa.c (get_local_syms): Likewise.
3416 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
3417 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
3418 * elf32-sh.c (sh_elf_relax_section): Likewise.
3419 (sh_elf_relax_delete_bytes): Likewise.
3420 (sh_elf_get_relocated_section_contents): Likewise.
3421 * elf32-xstormy16.c (xstormy16_elf_relax_section): Likewise.
3422 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
3423 * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
3424 * elf64-mmix.c (mmix_elf_relax_section): Likewise.
3425 * elf64-ppc.c (get_local_syms): Likewise.
3426 * elf64-sh64.c (sh_elf64_get_relocated_section_contents): Likewise.
3427 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
3428 * elfcode.h (NAME(_bfd_elf,size_info)): Update initialiser.
3429 * elf64-alpha.c (alpha_elf_size_info): Likewise.
3430 * elf64-hppa.c (hppa64_elf_size_info): Likewise.
3431 * elf64-mips.c (mips_elf64_size_info): Likewise.
3432 * elf64-s390.c (s390_elf64_size_info): Likewise.
3433 * elf64-sparc.c (sparc64_elf_size_info): Likewise.
3434
53bfd6b4
MR
34352002-06-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
3436
3437 * elf32-mips.c (elf32_mips_ignore_discarded_relocs): Move to...
3438 elfxx-mips.c (_bfd_mips_elf_ignore_discarded_relocs): ... here.
3439 elf64-mips.c (elf_backend_ignore_discarded_relocs): Use
3440 _bfd_mips_elf_ignore_discarded_relocs.
3441 elfxx-mips.h (_bfd_mips_elf_ignore_discarded_relocs): Declare.
3442
d4df96e6
L
34432002-06-05 H.J. Lu <hjl@gnu.org>
3444
3445 * elfxx-mips.c (mips_elf_calculate_relocation): Call
3446 _bfd_elf_rel_local_sym for STT_SECTION relocations against
3447 the SEC_MERGE section.
3448
e61463e1
AM
34492002-06-05 Alan Modra <amodra@bigpond.net.au>
3450
3cac74d0
AM
3451 * coff-alpha.c: Update copyright date.
3452 * coff-mips.c: Likewise.
3453 * xcoff-target.h: Likewise.
3454
e61463e1
AM
3455 * bfd-in.h: Remove "taken from the source" comment.
3456 * libbfd-in.h: Likewise.
3457 * libcoff-in.h: Likewise.
3458 * bfd-in2.h: Regenerate.
3459 * libbfd.h: Regenerate.
3460 * libcoff.h: Regenerate.
3461
3462 * elf.c (bfd_elf_discard_group): Return true.
3463 * elf-bfd.h (bfd_elf_discard_group): Declare.
3464 * bfd-in.h (bfd_elf_discard_group): Don't declare here.
3465 * section.c (bfd_discard_group): Rename to bfd_generic_discard_group.
3466 * bfd.c (bfd_discard_group): Define.
3467 * targets.c (struct bfd_target): Add _bfd_discard_group.
3468 (BFD_JUMP_TABLE_LINK): Here too.
3469 * libbfd-in.h (_bfd_nolink_bfd_discard_group): Define.
3470 * aout-adobe.c (aout_32_bfd_discard_group): Define.
3471 * aout-target.h (MY_bfd_discard_group): Define.
3472 * aout-tic30.c (MY_bfd_discard_group): Define.
3473 * binary.c (binary_bfd_discard_group): Define.
3474 * bout.c (b_out_bfd_discard_group): Define.
3475 * coff-alpha.c (_bfd_ecoff_bfd_discard_group): Define.
3476 * coffcode.h (coff_bfd_discard_group): Define.
3477 * coff-mips.c (_bfd_ecoff_bfd_discard_group): Define.
3478 * elfxx-target.h (bfd_elfNN_bfd_discard_group): Define.
3479 * i386msdos.c (msdos_bfd_discard_group): Define.
3480 * i386os9k.c (os9k_bfd_discard_group): Define.
3481 * ieee.c (ieee_bfd_discard_group): Define.
3482 * ihex.c (ihex_bfd_discard_group): Define.
3483 * mmo.c (mmo_bfd_discard_group): Define.
3484 * nlm-target.h (nlm_bfd_discard_group): Define.
3485 * oasys.c (oasys_bfd_discard_group): Define.
3486 * ppcboot.c (ppcboot_bfd_discard_group): Define.
3487 * som.c (som_bfd_discard_group): Define.
3488 * srec.c (srec_bfd_discard_group): Define.
3489 * tekhex.c (tekhex_bfd_discard_group): Define.
3490 * versados.c (versados_bfd_discard_group): Define.
3491 * vms.c (vms_bfd_discard_group): Define.
3492 * xcoff-target.h (_bfd_xcoff_bfd_discard_group): Define.
3493 * coff64-rs6000.c (rs6000coff64_vec): Update initialiser.
3494 (aix5coff64_vec): Likewise.
3495 * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Likewise.
3496
9cba27b2
JT
34972002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
3498
3499 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64-com.lo.
3500 (BFD32_BACKENDS_CFILES): Add elf32-sh64-com.c.
3501 (elf32-sh64-com.lo): New dependency list.
3502 * Makefile.in: Regenerate.
3503 * configure.in (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec)
3504 (bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec): Add
3505 elf32-sh64-com.lo.
3506 * configure: Regenerate.
3507 * elf32-sh64.c (sh64_address_in_cranges)
3508 (sh64_get_contents_type, sh64_address_is_shmedia): Move to...
3509 (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb):
3510 (crange_bsearch_cmpl): Prepend _bfd_sh64_ to name and move to...
3511 * elf32-sh64-com.c: ...here. New file.
3512
8d2c33be
AM
35132002-06-04 Alan Modra <amodra@bigpond.net.au>
3514
3515 * elf32-openrisc.c (openrisc_elf_gc_mark_hook): Remove
3516 ATTRIBUTE_UNUSED on used params.
3517 * elf32-vax.c (elf_vax_gc_mark_hook): Remove unnecessary checks
3518 before calling bfd_section_from_elf_index on local syms.
3519 * elf64-sh64.c (sh_elf64_gc_mark_hook): Likewise.
3520
5b0e55b6
JT
35212002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
3522
3523 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64-nbsd.lo.
3524 (BFD32_BACKENDS_CFILES): Add elf32-sh64-nbsd.c.
3525 (BFD64_BACKENDS): Add elf64-sh64-nbsd.lo.
3526 (BFD64_BACKENDS_CFILES): Add elf64-sh64-nbsd.c.
3527 (elf32-sh64-nbsd.lo, elf64-sh64-nbsd.lo): New rules.
3528 * Makefile.in: Regenerate.
3529 * config.bfd (sh5le-*-netbsd*, sh5-*-netbsd*, sh64le-*-netbsd*)
3530 (sh64-*-netbsd*): New targets.
3531 * configure.in: Add bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec,
3532 bfd_elf64_sh64nbsd_vec, and bfd_elf64_sh64lnbsd_vec.
3533 * configure: Regenerate.
3534 * elf32-sh64-nbsd.c: New file.
3535 * elf64-sh64-nbsd.c: New file.
3536 * targets.c: Add extern decls for bfd_elf32_sh64nbsd_vec,
3537 bfd_elf32_sh64lnbsd_vec, bfd_elf64_sh64nbsd_vec, and
3538 bfd_elf64_sh64lnbsd_vec.
3539
b885599b
AM
35402002-06-04 Alan Modra <amodra@bigpond.net.au>
3541
3542 * elf.c (setup_group): Set SEC_LINK_ONCE on GRP_COMDAT groups.
3543 (bfd_section_from_shdr): Likewise. Set section name of group
3544 sections from signature.
3545 (group_signature): Split out from setup_group. Ensure symbol table
3546 is available.
3547 (bfd_elf_discard_group): New function.
3548 (_bfd_elf_make_section_from_shdr): Don't set SEC_LINK_ONCE on
3549 .gnu.linkonce* sections if they are members of a group.
3550 (set_group_contents): Set GRP_COMDAT flag.
3551 * section.c (bfd_discard_group): New function.
3552 * bfd-in.h (bfd_elf_discard_group): Declare.
3553 * bfd-in2.h: Regenerate.
3554 * elf-bfd.h (struct bfd_elf_section_data): Add linkonce_p field.
3555 (elf_linkonce_p): Define.
3556
90937f86
AM
35572002-06-04 Alan Modra <amodra@bigpond.net.au>
3558
3559 * elf.c (bfd_section_from_shdr): Make "name" const.
3560 * elf-bfd.h (elf_backend_section_from_shdr): Likewise.
3561 * elf32-i370.c (i370_elf_section_from_shdr): Likewise.
3562 * elf32-ppc.c (ppc_elf_section_from_shdr): Likewise.
3563 * elf32-sh64.c (sh64_backend_section_from_shdr): Likewise.
3564 * elf32-v850.c (v850_elf_section_from_shdr): Likewise.
3565 * elf64-alpha.c (elf64_alpha_section_from_shdr): Likewise.
3566 * elf64-hppa.c (elf64_hppa_section_from_shdr): Likewise.
3567 * elf64-ppc.c (ppc64_elf_section_from_shdr): Likewise.
3568 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Likewise.
3569 * elfxx-mips.c (_bfd_mips_elf_section_from_shdr): Likewise.
3570 * elfxx-mips.h (_bfd_mips_elf_section_from_shdr): Likewise.
3571
cf6fb9ce
MR
35722002-06-03 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
3573
3574 * elfxx-mips.c (ABI_64_P): Use backend's data to determine the
3575 ABI.
3576
cedb70c5
KH
35772002-06-02 Kazu Hirata <kazu@cs.umass.edu>
3578
3579 * elf32-arc.c: Fix formatting.
3580 * elf32-arm.h: Likewise.
3581 * elf32-cris.c: Likewise.
3582 * elf32-dlx.c: Likewise.
3583 * elf32-hppa.c: Likewise.
3584 * elf32-i386.c: Likewise.
3585 * elf32-i386qnx.c: Likewise.
3586 * elf32-or32.c: Likewise.
3587 * elf32-s390.c: Likewise.
3588 * elf32-sh64.c: Likewise.
3589 * elf32-vax.c: Likewise.
3590 * elf32-xstormy16.c: Likewise.
3591 * elf64-alpha.c: Likewise.
3592 * elf64-mmix.c: Likewise.
3593 * elf64-ppc.c: Likewise.
3594 * elf64-s390.c: Likewise.
3595 * elf64-sh64.c: Likewise.
3596 * elf64-x86-64.c: Likewise.
3597
048d873d
RH
35982002-06-02 Richard Henderson <rth@redhat.com>
3599
3600 * elf64-alpha.c (elf64_alpha_relocate_section): Don't dereference
3601 null when there are no got entries for a symbol.
3602 (elf64_alpha_relax_find_tls_segment): Rearrange to avoid
3603 uninitialized variable warning.
3604
4a67a098
RH
36052002-06-01 Richard Henderson <rth@redhat.com>
3606
3607 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Don't test for
3608 undefined symbols here.
3609 (elf64_alpha_relax_section): Do it here. Also test for not
3610 defined in the current module.
3611 (elf64_alpha_relocate_section_r): Split out of ...
3612 (elf64_alpha_relocate_section): ... here. Don't dereference
3613 NULL when looking up local got entries.
3614
f44f99a5
RH
36152002-06-01 Richard Henderson <rth@redhat.com>
3616
3617 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Reject undefined
3618 symbols from JSR relaxation.
3619 (elf64_alpha_size_plt_section_1): New.
3620 (elf64_alpha_calc_dynrel_sizes): Split out .rela.got bits ...
3621 (elf64_alpha_size_rela_got_1): ... here.
3622 (elf64_alpha_size_dynamic_sections): Split out .rela.got bits ...
3623 (elf64_alpha_size_rela_got_section): ... here.
3624 (elf64_alpha_size_plt_section): New.
3625 (elf64_alpha_relax_section): Call them.
3626 (elf64_alpha_size_got_sections): Remove output_bfd arg.
3627 (elf64_alpha_finish_dynamic_symbol): Check gotent use_count.
3628
9e756d64
RH
36292002-06-01 Richard Henderson <rth@redhat.com>
3630
3631 * elf64-alpha.c (alpha_get_dtprel_base, alpha_get_tprel_base): New.
3632 (elf64_alpha_relocate_section): Use them. Reject LE TLS relocs
3633 in shared libraries. Fix DTPRELHI and TPRELHI value.
3634 (INSN_ADDQ, INSN_RDUNIQ): New.
3635 (struct alpha_relax_info): Add symtab_hdr, tls_segment, first_gotent.
3636 (elf64_alpha_relax_with_lituse): Return boolean. Remove irelend
3637 argument. Reject dynamic symbols. Use LITUSE symbolic constants.
3638 (elf64_alpha_relax_got_load): Rename from relax_without_lituse.
3639 Handle GOTDTPREL and GOTTPREL relocations.
3640 (elf64_alpha_relax_gprelhilo): New.
3641 (elf64_alpha_relax_tls_get_addr): New.
3642 (elf64_alpha_relax_find_tls_segment): New.
3643 (elf64_alpha_relax_section): Handle TLS relocations.
3644 (ALPHA_ELF_LINK_HASH_TLS_IE): New.
3645 (elf64_alpha_check_relocs): Set it.
3646
c853d7f6
RH
36472002-06-01 Richard Henderson <rth@redhat.com>
3648
b646261c
RH
3649 * elf64-alpha.c (elf64_alpha_relax_section): Don't store computed gp.
3650
c853d7f6
RH
3651 * elf64-alpha.c (elf64_alpha_check_relocs): Fix typo on maybe_dynamic
3652 check; don't suppress dynamic relocs for non-allocated sections.
3653
d7e41a96
RH
3654 * elf64-alpha.c: Remove dead code.
3655
5f333394
AM
36562002-05-31 Alan Modra <amodra@bigpond.net.au>
3657
08e0ee05
AM
3658 * bfd-in2.h: Regenerate.
3659 * libbfd.h: Regenerate.
3660 * po/SRC-POTFILES.in: Regenerate.
3661
5f333394
AM
3662 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Don't allocate
3663 space for bss .plt.
3664
caf47ea6
AM
36652002-05-31 Graeme Peterson <gp@qnx.com>
3666
3667 * Makefile.am (BFD32_BACKENDS): Add elf32-i386qnx.lo.
3668 (BFD32_BACKENDS_CFILES): Add elf32-i386qnx.c.
3669 Run "make dep-am".
3670 * Makefile.in: Regenerate.
3671 * config.bfd: Add i[3456]86-*-nto-qnx* support.
3672 * configure.in: Add bfd_elf32_i386qnx_vec support.
3673 * configure: Regenerate.
3674 * elf-bfd.h (struct elf_backend_data): Add set_nonloadable_filepos,
3675 is_contained_by_filepos, and copy_private_bfd_data_p.
3676 * elf.c (assign_file_positions_for_segments): Call backend
3677 set_nonloadable_filepos. Fix non-K&R call to _bfd_error_handler.
3678 (IS_CONTAINED_BY_FILEPOS): Define.
3679 (INCLUDE_SECTION_IN_SEGMENT): Also test IS_CONTAINED_BY_FILEPOS.
3680 (copy_private_bfd_data): Use IS_CONTAINED_BY_FILEPOS. Typo fix.
3681 Fix non-K&R call to _bfd_error_handler.
3682 (_bfd_elf_copy_private_section_data): Use backend
3683 copy_private_bfd_data_p.
3684 * elf32-i386.c: Don't include elfxx-target.h when
3685 ELF32_I386_C_INCLUDED is defined.
3686 * elf32-i386qnx.c: New QNX elf backend file.
3687 * elfxx-target.h: Add elf_backend_set_nonloadable_filepos,
3688 elf_backend_is_contained_by_filepos, and
3689 elf_backend_do_copy_private_bfd_data.
3690 * targets.c: Add bfd_target bfd_elf32_i386qnx_vec.
3691
5bc56484
AM
36922002-05-31 Alan Modra <amodra@bigpond.net.au>
3693
3694 * elfarm-oabi.c (bfd_elf32_arm_add_glue_sections_to_bfd): Define.
3695 Move other similar defines to start of file.
3696
1b164155
TR
36972002-05-30 Tom Rix <trix@redhat.com>
3698
3699 * coff-rs6000.c (xcoff_rtype2howto): Handle 16 bit R_RBA.
3700 * coff64-rs6000.c (xcoff64_rtype2howto): Same.
3701
3765b1be
RH
37022002-05-30 Richard Henderson <rth@redhat.com>
3703
3704 * elf64-alpha.c (ALPHA_ELF_LINK_HASH_LU_TLSGD,
3705 ALPHA_ELF_LINK_HASH_LU_TLSLDM, ALPHA_ELF_LINK_HASH_LU_FUNC): New.
3706 (ALPHA_ELF_GOT_ENTRY_RELOCS_DONE): Remove.
3707 (ALPHA_ELF_GOT_ENTRY_RELOCS_XLATED): Remove.
3708 (struct alpha_elf_got_entry): Add reloc_type, reloc_done, reloc_xlated.
3709 (struct alpha_elf_obj_tdata): Rename total_got_entries and
3710 n_local_got_entries to total_got_size and local_got_size.
3711 (elf64_alpha_howto, elf64_alpha_reloc_map): Update for TLS relocs.
3712 (alpha_got_entry_size): New.
3713 (elf64_alpha_relax_with_lituse): Use it.
3714 (elf64_alpha_relax_without_lituse): Likewise.
3715 (MAX_GOT_SIZE): Rename from MAX_GOT_ENTRIES.
3716 (get_got_entry): New.
3717 (elf64_alpha_check_relocs): Handle TLS relocs. Reorganize.
3718 (elf64_alpha_adjust_dynamic_symbol): Test LU_FUNC as a mask.
3719 (elf64_alpha_merge_ind_symbols): Check gotent->reloc_type.
3720 (elf64_alpha_can_merge_gots, elf64_alpha_merge_gots): Likewise.
3721 (elf64_alpha_calc_got_offsets_for_symbol): Use alpha_got_entry_size.
3722 (elf64_alpha_calc_got_offsets): Likewise.
3723 (alpha_dynamic_entries_for_reloc): New.
3724 (elf64_alpha_calc_dynrel_sizes): Use it.
3725 (elf64_alpha_size_dynamic_sections): Likewise.
3726 (elf64_alpha_relocate_section): Handle TLS relocations.
3727 * reloc.c: Add Alpha TLS relocations.
3728 * bfd-in2.h, libbfd.h: Rebuild.
3729
5e226794
NC
37302002-05-29 Ralf Habacker <ralf.habacker@freenet.de>
3731
3732 * peXXigen.c (pe_print_idata): Remove double printed
3733 import table lines; add Bound-To comment.
3734
90ace9e9
JT
37352002-05-29 Matt Thomas <matt@3am-software.com>
3736
3737 * Makefile.am (BFD32_BACKENDS): Add elf32-vax.lo.
3738 (BFD32_BACKENDS_CFILES): Add elf32-vax.c.
3739 (elf32-vax.lo): New rule.
3740 * Makefile.in: Regenerate.
3741 * configure.in (bfd_elf32_vax_vec)
3742 (vaxnetbsd_vec): New vectors.
3743 * configure: Regenerate.
3744 * config.bfd (vax-*-netbsdelf*)
3745 (vax-*-netbsdaout*)
3746 (vax-*-netbsd*): New targets.
3747 * elf32-vax.c: New file.
3748 * reloc.c: Add VAX relocations.
3749 * bfd-in2.h: Regenerate.
3750 * targets.c (_bfd_target_vector): Add bfd_elf32_vax_vec.
3751
4a253e81
JT
37522002-05-29 Jason Thorpe <thorpej@wasabisystems.com>
3753
3754 * config.bfd (arm-*-netbsd*): Add bfd_elf32_littlearm_vec
3755 and bfd_elf32_bigarm_vec to targ_selvecs.
3756
6e7c73dd
CF
37572002-05-29 Ralf Habacker <ralf.habacker@freenet.de>
3758
3759 * peXXigen.c (pe_print_idata): Fix seg faults on printing import tables
3760 with auto-imported symbols.
3761
8afb0e02
NC
37622002-05-29 Adam Nemet <anemet@lnxw.com>
3763
3764 * elf32-arm.h (bfd_elf32_arm_get_bfd_for_interworking): Don't add glue
3765 sections only record bfd.
9bab7074 3766 (bfd_elf32_arm_add_glue_sections_to_bfd): New function.
8afb0e02 3767 * bfd-in.h (bfd_elf32_arm_add_glue_sections_to_bfd): Declare it.
9bab7074 3768 * bfd-in2.h: Regenerate.
8afb0e02 3769
a95653f5
NC
37702002-05-28 Nick Clifton <nickc@cambridge.redhat.com>
3771
3772 * syms.c (_bfd_stab_section_find_nearest_line): Move
3773 declaration and initialisation of saw_line and saw_func out of
3774 for loop.
3775
7cdc5bba
AM
37762002-05-29 Alan Modra <amodra@bigpond.net.au>
3777
3778 * elf64-ppc.c (ppc64_elf_get_symbol_info): New function.
3779 (bfd_elf64_get_symbol_info): Define.
3780 * elfxx-target.h (bfd_elfNN_get_symbol_info): Only define if undef.
3781
4c7aad1c
AM
37822002-05-29 Andrey Volkov <avolkov@transas.com>
3783
3784 * cpu-h8300.c: Make default h8300 machine first in machine list.
3785
d172d4ba
NC
37862002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
3787
3788 * config.bfd: Added DLX configuraton.
3789 * Makefile.am: Added DLX configuraton.
3790 * configure.in: Added DLX configuraton.
3791 * archures.c: Add DLX architecure.
3792 * reloc.c: Add DLX relocs.
3793 * targets.c: Added DLX target vector.
3794 * configure: Regenerate.
3795 * Makefile.in: Regenreate.
3796 * bfd-in2.h: Regenreate.
3797 * elf32-dlx.c: New file: Support DLX target.
3798 * cpu-dlx.c: New file: Support DLX target.
3799
d1329ca3
AM
38002002-05-25 Alan Modra <amodra@bigpond.net.au>
3801
428d0de3
AM
3802 * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Formatting.
3803
d1329ca3
AM
3804 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Revert last change.
3805 (ppc64_elf_check_relocs): Don't set up function descriptor symbol
3806 strings to point inside function code sym string.
3807 (func_desc_adjust): Likewise.
3808 (ppc64_elf_hide_symbol): Rewrite code to look up function code sym.
3809
3bab7989
ML
38102002-05-24 Michal Ludvig <mludvig@suse.cz>
3811
3812 * elf64-x86-64.c (elf64_x86_64_grok_prstatus): Added.
3813 (elf64_x86_64_grok_psinfo): Added.
3814
436e8db0
NC
38152002-05-24 TAMURA Kent <kent@netbsd.org>
3816
3817 * config.bfd: Add a target for i386-netbsdpe.
3818
ea1e4b0d
AM
38192002-05-24 Alan Modra <amodra@bigpond.net.au>
3820
3821 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Don't copy is_func
3822 and is_func_descriptor.
3823 (func_desc_adjust): Hide function code sym in shared libs unless
3824 there is a matching exported function descriptor sym.
3825
13ae64f3
JJ
38262002-05-23 Jakub Jelinek <jakub@redhat.com>
3827
3828 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_THREAD_LOCAL
3829 for symbols from SHF_TLS section.
3830 (_bfd_elf_print_private_bfd_data): Add PT_TLS.
3831 (elf_fake_sections): Set SHF_TLS for SEC_THREAD_LOCAL sections.
3832 (map_sections_to_segments): Build PT_TLS segment if necessary.
3833 (assign_file_positions_for_segments): Likewise.
3834 (get_program_header_size): Account for PT_TLS segment.
3835 (swap_out_syms): Set type of BSF_THREAD_LOCAL symbols and symbols from
3836 SEC_THREAD_LOCAL sections to STT_TLS.
3837 * reloc.c: Add 386 and IA-64 TLS relocs.
3838 * section.c (SEC_THREAD_LOCAL): Define.
3839 (SEC_CONSTRUCTOR_TEXT, SEC_CONSTRUCTOR_DATA, SEC_CONSTRUCTOR_BSS):
3840 Remove.
3841 * elflink.h (elf_link_add_object_symbols): Support .tcommon.
3842 (size_dynamic_sections): If DF_STATIC_TLS, set DF_FLAGS
3843 unconditionally.
3844 (struct elf_final_link_info): Add first_tls_sec.
3845 (elf_bfd_final_link): Set first_tls_sec.
3846 Compute elf_hash_table (info)->tls_segment.
3847 (elf_link_output_extsym): Handle STT_TLS symbols.
3848 (elf_link_input_bfd): Likewise.
3849 * syms.c (BSF_THREAD_LOCAL): Define.
3850 * bfd-in2.h: Rebuilt.
3851 * libbfd.h: Rebuilt.
3852 * elf32-i386.c (elf_i386_tls_transition, dtpoff_base, tpoff,
3853 elf_i386_mkobject, elf_i386_object_p): New functions.
3854 (elf_howto_table): Add TLS relocs.
3855 (elf_i386_reloc_type_lookup): Support TLS relocs.
3856 (elf_i386_info_to_howto_rel): Likewise.
3857 (struct elf_i386_link_hash_entry): Add tls_type.
3858 (struct elf_i386_obj_tdata): New.
3859 (elf_i386_hash_entry, elf_i386_tdata, elf_i386_local_got_tls_type):
3860 New macros.
3861 (struct elf_i386_link_hash_table): Add tls_ldm_got.
3862 (link_hash_newfunc): Clear tls_type.
3863 (elf_i386_check_relocs): Support TLS relocs.
3864 (elf_i386_gc_sweep_hook): Likewise.
3865 (allocate_dynrelocs): Likewise.
3866 (elf_i386_size_dynamic_sections): Likewise.
3867 (elf_i386_relocate_section): Likewise.
3868 (elf_i386_finish_dynamic_symbol): Likewise.
3869 (bfd_elf32_mkobject, elf_backend_object_p): Define.
3870 * elfxx-ia64.c (struct elfNN_ia64_dyn_sym_info): Add tprel_offset,
3871 dtpmod_offset, dtprel_offset, tprel_done, dtpmod_done, dtprel_done,
3872 want_tprel, want_dtpmod, want_dtprel.
3873 (elfNN_ia64_tprel_base, elfNN_ia64_dtprel_base): New functions.
3874 (ia64_howto_table): Add TLS relocs, rename R_IA64_LTOFF_TP22 to
3875 R_IA64_LTOFF_TPREL22.
3876 (elf_code_to_howto_index): Add TLS relocs.
3877 (elfNN_ia64_check_relocs): Support TLS relocs.
3878 (allocate_global_data_got): Account for TLS .got data.
3879 (allocate_dynrel_entries): Account for TLS dynamic relocations.
3880 (elfNN_ia64_install_value): Supprt TLS relocs.
3881 (set_got_entry): Support TLS relocs.
3882 (elfNN_ia64_relocate_section): Likewise.
3883
c62e1cc3
NC
38842002-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3885
3886 * elf32-arm.h (elf32_arm_final_link_relocate): For the Thumb
3887 BLX reloc round the relocation up rather than down.
3888 * coff-arm.c (coff_arm_relocate_section): Likewise.
3889
c5a43a5d
L
38902002-05-21 H.J. Lu (hjl@gnu.org)
3891
3892 * linker.c (_bfd_generic_link_add_one_symbol): Allow multiple
3893 definition.
3894
afbe61cf
AM
38952002-05-22 Alan Modra <amodra@bigpond.net.au>
3896
3897 * elf64-ppc.c (ppc64_elf_size_stubs): Don't strip .branch_lt.
3898 (ppc64_elf_relocate_section): Handle unresolved relocs in opd.
3899
9c07fe7c
AM
39002002-05-22 Alan Modra <amodra@bigpond.net.au>
3901
3902 * elf64-ppc.c (ppc64_elf_relocate_section): Return false for
3903 unresolved relocs.
3904 (ppc64_elf_size_dynamic_sections): Check for splt NULL.
3905
21611032
TS
39062002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3907
c5cd6d62 3908 * bfd.c (bfd_get_arch_size): Remove bfd_set_error call for
21611032
TS
3909 non-ELF targets.
3910
41241523
TS
39112002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3912
3913 * elf-bfd.h (elf_backend_emit_relocs): Change prototype to return
3914 an error value.
3915 * elflink.h (elf_link_output_relocs): Likewise. Improve error message.
3916 return with false on error.
3917 (elf_link_input_bfd): Check reloc_emitter return value.
3918
658f2588
JT
39192002-05-21 Jason Thorpe <thorpej@wasabisystems.com>
3920
3921 * config.bfd (armeb-*-netbsdelf*): New target.
3922
c862ae31
AM
39232002-05-20 Alan Modra <amodra@bigpond.net.au>
3924
3925 * elf64-ppc.c (ppc_build_one_stub): Point undefined function syms
3926 at the plt call stub.
3927
6dd14845
TS
39282002-05-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3929
3930 * cpu-mips.c (mips_compatible): Don't try to check machine
3931 compatibility.
3932
a58d9c34
TR
39332002-05-18 Tom Rix <trix@redhat.com>
3934
3935 * coff64-rs6000.c (_bfd_xcoff64_swap_aux_out): Fix C_FILE auxent.
3936
ef60b7ff
AM
39372002-05-17 Alan Modra <amodra@bigpond.net.au>
3938
3939 * elf64-ppc.c (ppc64_elf_info_to_howto): Formatting.
3940 (ppc64_elf_relocate_section): Don't warn about reloc overflow when
3941 we've already warned about an undefined symbol. Report more
3942 detail on reloc errors.
3943
a703a6ea
AM
39442002-05-17 Alan Modra <amodra@bigpond.net.au>
3945
3946 * acinclude.m4 (AM_INSTALL_LIBBFD): New.
3947 * configure.in: Invoke AM_INSTALL_LIBBFD.
3948 * Makefile.am (install-data-local): Revert 2002-05-13. Move to..
3949 (install_libbfd): .. New target.
3950 (uninstall_libbfd): Likewise.
3951 (install-bfdlibLTLIBRARIES): Likewise.
3952 (uninstall-bfdlibLTLIBRARIES): Likewise.
3953 (bfdlibdir): New.
3954 (bfdincludedir): New.
3955 (lib_LTLIBRARIES): Rename to bfdlib_LTLIBRARIES.
3956 * aclocal.m4: Regenerate.
3957 * configure: Regenerate.
3958 * Makefile.in: Regenerate.
3959
2c13d98b
NC
39602002-05-17 Stuart Balfour <sbalfour@cisco.com>
3961
3962 * hash.c (bfd_hash_lookup): Remove computation of len from inside
3963 hash loop.
3964
629936c5
NC
39652002-05-16 Nick Clifton <nickc@cambridge.redhat.com>
3966
3967 * config.bfd: Add targets for sh64-linux (little endian and
3968 big endian).
3969
e4cf60a8
NC
39702002-05-15 Laurent Pinchart <laurent.pinchart@skynet.be>
3971
3972 * peXXigen.c (pe_print_idata): Do not assume that the first thunk
3973 is located in the same section as the import table. Instead
3974 check, and if necessary load the section containing the thunk.
3975
d1e66cd4
NC
39762002-05-15 Nick Clifton <nickc@cambridge.redhat.com>
3977
3978 * aix5ppc-core.c (xcoff64_core_p): Replace bfd_read with
ea1e4b0d
AM
3979 bfd_bread.
3980 (xcoff64_core_file_matches_executable_p): Replace bfd_read
3981 with bfd_bread.
d1e66cd4 3982
2d653fc7
AM
39832002-05-15 Alan Modra <amodra@bigpond.net.au>
3984
3985 * aix5ppc-core.c: Warning fixes.
3986 * aout-adobe.c (aout_32_bfd_link_just_syms): Define.
3987 * aout-target.h (MY_bfd_link_just_syms): Define.
3988 * aout-tic30.c (MY_bfd_link_just_syms): Define.
3989 * bfd.c (bfd_link_just_syms): Define.
3990 * binary.c (binary_bfd_link_just_syms): Define.
3991 * bout.c (b_out_bfd_link_just_syms): Define.
3992 * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Update initializer.
3993 * coff64-rs6000.c (rs6000coff64_vec, aix5coff64_vec): Likewise.
3994 * coffcode.h (coff_bfd_link_just_syms): Define.
3995 * elf-bfd.h (enum elf_link_info_type): Add ELF_INFO_TYPE_JUST_SYMS.
3996 (elf_discarded_section): Check for ELF_INFO_TYPE_JUST_SYMS.
3997 (_bfd_elf_link_just_syms): Declare.
3998 * elf.c (_bfd_elf_link_just_syms): New function.
3999 * elf-eh-frame.c (_bfd_elf_maybe_strip_eh_frame_hdr): Check that
4000 sections haven't already been discarded by the linker.
4001 * elflink.h (elf_link_add_object_symbols): Likewise for stab
4002 sections and SEC_MERGE sections.
4003 (elf_bfd_discard_info): Similarly here.
4004 * elfxx-target.h (bfd_elfNN_bfd_link_just_syms): Define.
4005 * i386msdos.c (msdos_bfd_link_just_syms): Define.
4006 * i386os9k.c (os9k_bfd_link_just_syms): Define.
4007 * ieee.c (ieee_bfd_link_just_syms): Define.
4008 * ihex.c (ihex_bfd_link_just_syms): Define.
4009 * libbfd-in.h (_bfd_nolink_bfd_link_just_syms): Define.
4010 (_bfd_generic_link_just_syms): Declare.
4011 * libecoff.h (_bfd_ecoff_bfd_link_just_syms): Define.
4012 * linker.c (_bfd_generic_link_just_syms): New function.
4013 * mmo.c (mmo_bfd_link_just_syms): Define.
4014 * nlm-target.h (nlm_bfd_link_just_syms): Define.
4015 * oasys.c (oasys_bfd_link_just_syms): Define.
4016 * ppcboot.c (ppcboot_bfd_link_just_syms): Define.
4017 * som.c (som_bfd_link_just_syms): Define.
4018 * srec.c (srec_bfd_link_just_syms): Define.
4019 * targets.c (struct bfd_target): Add _bfd_link_just_syms.
4020 (BFD_JUMP_TABLE_LINK): And here.
4021 * tekhex.c (tekhex_bfd_link_just_syms): Define.
4022 * versados.c (versados_bfd_link_just_syms): Define.
4023 * vms.c (vms_bfd_link_just_syms): Define.
4024 * libbfd.h: Regenerate.
4025 * bfd-in2.h: Regenerate.
4026
cb7394f2
TS
40272002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
4028
4029 * elf32-mips.c: Remove superfluous definitions copied from
4030 elfxx-mips.c.
4031 (bfd_elf32_bigmips_vec,bfd_elf32_littlemips_vec): Use the
4032 SGIish vectors to check the special case.
4033 (mips_elf_hi16_reloc): Fix comment.
4034 (mips_elf_got16_reloc): Likewise.
4035 (_bfd_mips_elf32_gprel16_reloc): Likewise.
4036 (elf_reloc_map): Code cleanup.
4037 (mips_reloc_map): Add comment.
4038 (bfd_elf23_bfd_reloc_type_lookup): Code cleanup.
4039 (mips_elf32_rtype_to_howto): Likewise.
4040 (mips_elf32_discard_info): Likewise.
4041 (elf32_mips_irix_compat): Invert logic: Only SGIish vectors
4042 lead to IRIX compatibility now.
4043
8dc1a139
TS
40442002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
4045
4046 * elfxx-mips.c: Call it IRIX, not Irix in comments.
4047
2051e1b5
JT
40482002-05-13 Jason Thorpe <thorpej@wasabisystems.com>
4049
4050 * config.bfd (shle-*-netbsdelf*): Add target which includes
4051 sh64 support.
4052
83954261
AM
40532002-05-13 David Edelsohn <edelsohn@gnu.org>
4054
4055 * configure.in: Revert 2002-04-07. Instead, auto-configure
4056 HAVE_ST_C_IMPL.
4057 * configure: Regenerate.
4058 * config.in: Regenerate.
4059 * rs6000-core.c (CNEW_IMPL): Guard use of c_impl with HAVE_ST_C_IMPL
4060 or AIX_5_CORE.
4061
a9bf1154
NC
40622002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
4063
4064 * configure.in (sparc*-*-openbsd*): Support sparc64-openbsd
4065 corefiles as well.2
4066 * configure: Regenerate.
4067
3129eb7a
AM
40682002-05-13 Alan Modra <amodra@bigpond.net.au>
4069
4070 * Makefile.am (install-data-local): Install headers to
4071 $(exec_prefix)/include.
4072 * Makefile.in: Regenerate.
4073
a9a32010
DJ
40742002-05-11 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
4075 Daniel Jacobowitz <drow@mvista.com>
4076
4077 * coff-sh.c (sh_reloc_map): Map to R_SH_IMM32 for non-PE. Don't
4078 map BFD_RELOC_RVA.
4079
40802002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
690cc98b
NC
4081
4082 * config.bfd (alpha*-*-openbsd*, sparc64*-*-openbsd*,
4083 hppa*-*-openbsd*): New targets.
4084 * configure.in (alpha*-*-openbsd*): Set COREFILE.
4085 * configure: Regenerate.
4086
f1f0d9ab
TR
40872002-05-10 Tom Rix <trix@redhat.com>
4088
ea1e4b0d 4089 * coff64-rs6000.c (xcoff64_reloc_type_br): New function for
f1f0d9ab
TR
4090 xcoff64_ppc_relocate_section.
4091 * coff-rs6000.c : Extern common xcoff_reloc_type functions.
4092 * libxcoff.h: Common xcoff_reloc_type function declaration.
4093
c432ba1a
AM
40942002-05-10 Alan Modra <amodra@bigpond.net.au>
4095
16a10388 4096 * elf32-i386.c (elf_i386_relocate_section): Remove overflow checks
90937f86 4097 added in 2002-05-09 commit.
16a10388 4098
c432ba1a
AM
4099 * elf32-hppa.c (elf32_hppa_size_stubs): Revert part of 2002-05-04,
4100 don't look for stubs on all undefined syms.
4101
4a335f3d
AM
41022002-05-09 Alan Modra <amodra@bigpond.net.au>
4103
8fc39d5d
AM
4104 * elf64-ppc.c (RA_REGISTER_MASK, RA_REGISTER_SHIFT): Delete.
4105 (ppc64_elf_howto_raw <R_PPC64_RELATIVE>): Not pc_relative or
4106 pcrel_offset.
4107
4a335f3d
AM
4108 * elf32-i386.c (elf_howto_table): Comments.
4109 (elf_i386_relocate_section): Handle more relocs for relocatable
4110 linking and against SEC_MERGE sections.
4111
41fcb14e
AM
41122002-05-08 Alan Modra <amodra@bigpond.net.au>
4113
4114 * elf32-ppc.c (ppc_elf_create_got): New function.
4115 (ppc_elf_create_dynamic_sections): Call ppc_elf_create_got before
ea1e4b0d 4116 _bfd_elf_create_dynamic_sections. Correct .plt flags.
41fcb14e
AM
4117 (ppc_elf_check_relocs): Use ppc_elf_create_got in place of
4118 _bfd_elf_create_got_section.
4119
b491616a
AM
41202002-05-07 Alan Modra <amodra@bigpond.net.au>
4121
4122 * elf-bfd.h (struct elf_backend_data): Add rela_normal.
4123 * elfxx-target.h (elf_backend_rela_normal): Define.
4124 (elfNN_bed): Init rela_normal.
4125 * elflink.h (elf_link_input_bfd <emit_relocs>): Handle adjustment
4126 for section symbols here if rela_normal. Simplify abs section test.
4127 * elf-m10200.c (mn10200_elf_relocate_section): If relocatable,
4128 return immediately. Remove code handling relocatable linking.
4129 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
4130 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
4131 * elf32-i370.c (i370_elf_relocate_section): Likewise.
4132 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
4133 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
4134 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
4135 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
4136 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
4137 * elf32-s390.c (elf_s390_relocate_section): Likewise.
4138 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
4139 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
4140 * elf64-s390.c (elf_s390_relocate_section): Likewise.
4141 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
4142 * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
4143 * elf32-arm.h (elf32_arm_relocate_section): Likewise #ifndef USE_REL.
4144 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
4145 * elf-m10200.c (elf_backend_rela_normal): Define.
4146 * elf-m10300.c (elf_backend_rela_normal): Define.
4147 * elf32-fr30.c (elf_backend_rela_normal): Define.
4148 * elf32-i370.c (elf_backend_rela_normal): Define.
4149 * elf32-i860.c (elf_backend_rela_normal): Define.
4150 * elf32-m68k.c (elf_backend_rela_normal): Define.
4151 * elf32-mcore.c (elf_backend_rela_normal): Define.
4152 * elf32-openrisc.c (elf_backend_rela_normal): Define.
4153 * elf32-ppc.c (elf_backend_rela_normal): Define.
4154 * elf32-s390.c (elf_backend_rela_normal): Define.
4155 * elf32-xstormy16.c (elf_backend_rela_normal): Define.
4156 * elf64-ppc.c (elf_backend_rela_normal): Define.
4157 * elf64-s390.c (elf_backend_rela_normal): Define.
4158 * elf64-x86-64.c (elf_backend_rela_normal): Define.
4159 * elfxx-ia64.c (elf_backend_rela_normal): Define.
4160 * elf32-arm.h (elf_backend_rela_normal): Define #ifndef USE_REL.
4161 * elf32-m32r.c (elf_backend_rela_normal): Likewise.
4162
df212a7e
NC
41632002-05-06 Nick Clifton <nickc@cambridge.redhat.com>
4164
4165 * elf32-arm.h (elf32_arm_final_link_relocate): Convert
4166 'reloc_signed_max' and 'reloc_signed_min' into half-word offsets.
4167
3decf53c
AM
41682002-05-06 Alan Modra <amodra@bigpond.net.au>
4169
4170 * elflink.h (elf_link_input_bfd <emit_relocs>): Adjust r_offset
4171 when not relocatable. Fix reloc_emitter call for K&R.
4172
f46c2da6
AM
41732002-05-04 Alan Modra <amodra@bigpond.net.au>
4174
4175 * elf64-ppc.c (ppc64_elf_relocate_section): Reinstate code
4176 reloading local sym addend mistakenly removed in 2002-05-01 change.
4177
4178 * dwarf2.c (struct line_head): Make prologue_length a bfd_vma.
4179 (read_abbrevs): Change "offset" param to bfd_vma.
4180 (parse_comp_unit): Change "version" and addr_size to unsigned ints.
4181 Change "abbrev_offset" to bfd_vma.
4182 (read_indirect_string): Use correct conversion chars in error
4183 message format string, cast bfd_vma's to unsigned long.
4184 (read_abbrevs): Likewise.
4185 (read_attribute_value): Likewise.
4186 (decode_line_info): Likewise.
4187 (scan_unit_for_functions): Likewise.
4188 (parse_comp_unit): Likewise.
4189
59862849
TR
41902002-05-04 Tom Rix <trix@redhat.com>
4191
4192 * coffswap.h (coff_swap_reloc_in): Remove XCOFF support.
4193 (coff_swap_reloc_out): Same.
4194 * coff-rs6000.c: (xcoff_swap_reloc_in): Moved from coffswap.h.
4195 (xcoff_swap_reloc_out): Same.
4196 (xcoff_rtype2howto): Renamed from _bfd_xcoff_rtype2howto. Special
4197 case some 16 bit relocs. Add reloc value to output.
4198 (xcoff_howto_table): Remove 64 bit R_POS, add 16 bit
ea1e4b0d 4199 R_RBR. Improve names.
59862849
TR
4200 (_bfd_xcoff_reloc_type_lookup): Adjust for removal of 64 bit R_POS.
4201 (bfd_xcoff_backend_data): Update with new reloc swap names.
4202 (bfd_pmac_xcoff_backend_data) : Same.
4203 * coff64-rs6000.c: (xcoff64_swap_reloc_in): Moved from coffswap.h.
4204 (xcoff64_swap_reloc_out): Same.
ea1e4b0d 4205 (xcoff64_rtype2howto): Special case some 16 bit relocs and 32 bit
59862849 4206 R_POS. Add reloc value to output.
ea1e4b0d
AM
4207 (xcoff64_howto_table): Move 64 bit R_POS to first entry. Add 16
4208 bit R_RBR. Improve names, masks.
59862849
TR
4209 (xcoff64_reloc_type_lookup): Adjust for move of 64 bit R_POS.
4210 (bfd_xcoff_backend_data): Update with new reloc swap names.
4211 (bfd_xcoff_aix5_backend_data) : Same.
4212
b4655ea9
AM
42132002-05-04 Alan Modra <amodra@bigpond.net.au>
4214
4215 * elf32-hppa.c (struct elf32_hppa_link_hash_table): Add
4216 bfd_count top_index, input_list, all_local_syms.
4217 (elf32_hppa_setup_section_lists): New function, split from
4218 elf32_hppa_size_stubs.
4219 (elf32_hppa_next_input_section): Likewise.
4220 (group_sections): Likewise.
4221 (get_local_syms): Likewise.
4222 (elf32_hppa_size_stubs): Adjust for split out functions. Look for
4223 stubs on undefined syms too.
4224 (elf32_hppa_set_gp): Use bfd_link_hash* instead of elf_link_hash*.
8fc39d5d 4225 Only access htab elf fields when we have an elf hash table.
b4655ea9
AM
4226 * elf32-hppa.h (elf32_hppa_setup_section_lists): Declare.
4227 (elf32_hppa_next_input_section): Declare.
4228
301e3139
AM
42292002-05-04 Bob Byrnes <byrnes@curl.com>
4230
4231 * opncls.c (_bfd_new_bfd_contained_in): Check return value of
4232 _bfd_new_bfd.
4233
7c5fcef7
L
42342002-05-03 H.J. Lu (hjl@gnu.org)
4235
4236 * elfxx-mips.c (mips_elf_link_hash_entry): Add forced_local.
4237 (mips_elf_link_hash_newfunc): Initialize forced_local to false.
4238 (mips_elf_record_global_got_symbol): Call _bfd_mips_elf_hide_symbol
4239 to hide a global symbol.
4240 (_bfd_mips_elf_hide_symbol): Return if forced_local is true. Set
ea1e4b0d 4241 forced_local to true.
7c5fcef7 4242
84de6048
RH
42432002-05-02 Richard Henderson <rth@redhat.com>
4244
4245 * elf64-alpha.c (elf64_alpha_relocate_section): Force relative relocs
4246 vs SHN_UNDEF to zero.
4247
805fc799
AM
42482002-05-02 Alan Modra <amodra@bigpond.net.au>
4249
c061c2d8
AM
4250 * elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_SECTOFF>): Change to a
4251 16 bit reloc.
4252 <R_PPC64_SECTOFF_DS>: Likewise.
4253 (ppc64_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
4254 SECTOFF reloc.
4255 * elf32-ppc.c (ppc_elf_howto_raw <R_PPC_SECTOFF>): Correct.
4256 (ppc_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
4257 SECTOFF reloc.
4258
805fc799
AM
4259 * elf64-ppc.c (ppc64_elf_addr16_ha_reloc): Delete.
4260 (ppc64_elf_ha_reloc): New function.
4261 (ppc64_elf_brtaken_reloc): New function.
4262 (ppc64_elf_sectoff_reloc): New function.
4263 (ppc64_elf_sectoff_ha_reloc): New function.
4264 (ppc64_elf_toc_reloc): New function.
4265 (ppc64_elf_toc_ha_reloc): New function.
4266 (ppc64_elf_toc64_reloc): New function.
4267 (ppc64_elf_unhandled_reloc): New function.
4268 (ppc64_elf_howto_raw): Use the above.
4269 <R_PPC64_RELATIVE>: Mark pc_relative, pcrel_offset.
4270 <R_PPC64_SECTOFF>: Not pc_relative or pcrel_offset. Fix dst_mask.
4271 <R_PPC64_SECTOFF_DS>: Likewise.
4272 (IS_ABSOLUTE_RELOC): Update.
4273 (struct ppc_link_hash_table): Add have_undefweak.
4274 (ppc64_elf_link_hash_table_create): Init.
4275 (func_desc_adjust): Set have_undefweak.
4276 (ppc64_elf_func_desc_adjust): Call func_desc_adjust earlier. Only
4277 add the .sfpr blr when have_undefweak.
4278 (ppc64_elf_setup_section_lists): Check hash table flavour.
4279 (ppc64_elf_next_input_section): Move output_section->owner test to
4280 ppc64elf.em.
4281 (ppc64_elf_set_toc): Rename to ppc64_elf_toc, remove info param
4282 and relocatable test. Return TOCstart and don't set elf_gp.
4283 (ppc64_elf_relocate_section): Correct BRTAKEN/BRNTAKEN branch
4284 offset calculation. Add assert on weak sym branch tweaks.
4285 * elf64-ppc.h (ppc64_elf_set_toc): Delete.
4286 (ppc64_elf_toc): Declare.
4287 (ppc64_elf_next_input_section): Update.
ea1e4b0d 4288
818c39a3
AM
42892002-05-01 Alan Modra <amodra@bigpond.net.au>
4290
4291 * syms.c (_bfd_stab_section_find_nearest_line): Don't bomb on NULL
4292 file_name.
4293
721956f4
AM
42942002-05-01 Alan Modra <amodra@bigpond.net.au>
4295
4296 * elf64-ppc.c (CROR_151515, CROR_313131): Define.
4297 (ppc64_elf_relocate_section): Use them. Don't look for plt calls
4298 on R_PPC64_ADDR24 relocs. Require a nop or no link reg on plt
4299 call branches. Correct undefined weak destination.
4300 (ppc64_elf_func_desc_adjust): Always create at least one blr in
4301 .sfpr, and correct case where either only savef* or restf* is
4302 needed.
4303
4304 Long branch stubs, multiple stub sections.
4305 * elf64-ppc.h (ppc64_elf_setup_section_lists): Declare.
4306 (ppc64_elf_next_input_section): Declare.
4307 * elf64-ppc.c: Move linker-only prototypes.
4308 (STUB_SUFFIX): Define.
4309 (enum ppc_stub_type): New.
4310 (struct ppc_stub_hash_entry): New.
4311 (struct ppc_branch_hash_entry): New.
4312 (struct ppc_link_hash_entry): Add stub_cache, oh.
4313 (struct ppc_link_hash_table): Add stub_hash_table etc. Remove
4314 sstub. Add sbrlt, srelbrlt, has_14bit_branch, stub_iteration.
4315 Rename plt_overflow to stub_error.
4316 (ppc_stub_hash_lookup): Define.
4317 (ppc_branch_hash_lookup): Define.
4318 (stub_hash_newfunc): New function.
4319 (branch_hash_newfunc): New function.
4320 (link_hash_newfunc): Init new fields.
4321 (ppc64_elf_link_hash_table_create): Likewise.
4322 (ppc64_elf_link_hash_table_free): New function.
4323 (ppc_stub_name): New function.
4324 (ppc_get_stub_entry): New function.
4325 (ppc_add_stub): New function.
4326 (create_linkage_sections): Use bfd_make_section_anyway. Create
4327 .branch_lt and .rela.branch_lt sections. Don't create .stub.
4328 (ppc64_elf_check_relocs): Set has_14bit_branch on R_PPC64_REL14*,
4329 and set up for plt call stubs. Link func and func desc syms.
4330 (ppc64_elf_gc_sweep_hook): Handle REL14* as per REL24.
4331 (func_desc_adjust): Avoid hash lookup when func desc sym available
4332 via shortcut, and set links when processing.
4333 (ppc64_elf_hide_symbol): Likewise.
4334 (allocate_dynrelocs): Don't allocate stub section here.
4335 (ppc64_elf_size_dynamic_sections): Handle sbrlt and srelbrlt.
4336 Remove sstub code.
4337 (ppc_type_of_stub): New function.
4338 (build_one_stub): Delete.
4339 (ppc_build_one_stub): New function.
4340 (ppc_size_one_stub): New function.
4341 (ppc64_elf_setup_section_lists): New function.
4342 (ppc64_elf_next_input_section): New function.
4343 (group_sections): New function.
4344 (get_local_syms): New function.
4345 (ppc64_elf_size_stubs): Rewrite.
4346 (ppc64_elf_build_stubs): Rewrite.
4347 (ppc64_elf_relocate_section): Look up stub entry for REL24
4348 relocs. Don't propagate REL14* to dynamic objects. Look for long
4349 branch stubs if REL14* or REL24 relocs won't reach.
4350 (bfd_elf64_bfd_link_hash_table_free): Define.
4351
09c2219b
MM
43522002-04-30 Mark Mitchell <mark@codesourcery.com>
4353
c5cd6d62 4354 * config.bfd: Add support for powerpc-*-windiss.
09c2219b 4355
07b678c0
TR
43562002-04-30 Tom Rix <trix@redhat.com>
4357
4358 * xcofflink.c (xcoff_link_add_symbols): Always copy undef C_EXT
4359 symbol names into the hash table.
4360
dbe341c6
TR
43612002-04-28 Tom Rix <trix@redhat.com>
4362
4363 * coff-rs6000.c (xcoff_calculate_relocation) : Function table for
ea1e4b0d 4364 calulating relocations.
dbe341c6 4365 (xcoff_complain_overflow) : Function table for relocation errors.
ea1e4b0d
AM
4366 (xcoff_ppc_relocate_section): Use relocation and complain function
4367 tables.
4368 (xcoff_complain_overflow_unsigned_func): New complain function.
dbe341c6
TR
4369 (xcoff_complain_overflow_signed_func): Same.
4370 (xcoff_complain_overflow_bitfield_func): Same.
4371 (xcoff_complain_overflow_dont_func): Same.
4372 (xcoff_reloc_type_crel): New recot function.
4373 (xcoff_reloc_type_br): Same.
4374 (xcoff_reloc_type_ba): Same.
4375 (xcoff_reloc_type_toc): Same.
4376 (xcoff_reloc_type_rel): Same.
4377 (xcoff_reloc_type_neg): Same.
4378 (xcoff_reloc_type_pos): Same.
4379 (xcoff_reloc_type_fail): Same.
4380 (xcoff_reloc_type_noop): Same.
4381 * libxcoff.h : Declare common parts for xcoff64.
4382 * coff64-rs6000.c (xcoff64_ppc_relocate_section): Use relocation
ea1e4b0d 4383 and complain function tables.
dbe341c6 4384
985142a4
AM
43852002-04-28 Alan Modra <amodra@bigpond.net.au>
4386
4387 * elf64-x86-64.c (struct elf64_x86_64_dyn_relocs): Comment typo.
4388 * elf32-hppa.c (elf32_hppa_final_link): Formatting.
4389
eba91044
AM
43902002-04-26 Alan Modra <amodra@bigpond.net.au>
4391
e54fdaa5
AM
4392 * opncls.c (bfd_make_readable): Call bfd_section_list_clear.
4393 * xcofflink.c (xcoff_link_add_dynamic_symbols): Likewise.
4394
a50c1845
AM
4395 * elflink.h (elf_bfd_final_link): Ensure input bfd class is the
4396 same as the output before calling elf_link_input_bfd.
4397
eba91044
AM
4398 * coffcode.h (coff_compute_section_file_positions): Set
4399 section_tail after shuffling section list.
4400
3c25c5f6
NC
44012002-04-24 Christian Groessler <chris@groessler.org>
4402
4403 * coff-z8k.c (extra_case): Fix R_IMM32 relocations: The
4404 addresses are 23bit with a special layout, not plain 32bit
4405 values. Prevent relocation of immediate values.
4406
40d32fc6
CD
44072002-04-24 Chris G. Demetriou <cgd@broadcom.com>
4408
4409 * elfxx-mips.c (_bfd_mips_elf_print_private_bfd_data): If MDMX or
4410 MIPS-16 ASE flags are set, print something to indicate that.
4411
067fa4a6
AM
44122002-04-23 Alan Modra <amodra@bigpond.net.au>
4413
4414 * elf32-hppa.c (hppa_type_of_stub): Correct and simplify condition
4415 under which a plt call stub is used.
4416 (final_link_relocate): Similarly.
4417 (allocate_plt_static): Clear h-plabel except when plt entry is
4418 exclusively used for a plabel.
4419 (allocate_dynrelocs): Use the above to simplify plt sizing.
4420 (struct elf32_hppa_link_hash_table): Add has_22bit_branch.
4421 (elf32_hppa_link_hash_table_create): Init.
4422 (BL22_RP): Define.
4423 (hppa_build_one_stub): Use BL22_RP if has_22bit_branch.
4424 (elf32_hppa_check_relocs): Set has_22bit_branch.
4425
4426 * elf32-hppa.c (elf32_hppa_check_relocs): Remove debug message.
4427 (final_link_relocate): Likewise.
4428
af40ce3c
JJ
44292002-04-22 Jakub Jelinek <jakub@redhat.com>
4430
4431 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't build
4432 search table if some FDE is DW_EH_PE_aligned encoded either.
4433 (_bfd_elf_write_section_eh_frame): Handle terminating FDE specially.
4434
09ae86c2
JJ
44352002-04-22 Richard Smith <richard@ex-parrot.com>
4436 Jakub Jelinek <jakub@redhat.com>
4437
4438 * elf-eh-frame.c (struct eh_cie_fde): Add per_encoding_relative.
4439 (_bfd_elf_discard_section_eh_frame): Set it for CIEs with pcrel
4440 encoded personality.
4441 (_bfd_elf_write_section_eh_frame): Adjust pcrel encoded personality
4442 for CIE/FDE removal.
4443
deeb2cd7
TR
44442002-04-20 Tom Rix <trix@redhat.com>
4445
4446 * coff64-rs6000.c (_bfd_xcoff64_swap_aux_in): Fix C_FILE auxent.
4447
99dc0092
AM
44482002-04-20 Alan Modra <amodra@bigpond.net.au>
4449
aa3d5824
AM
4450 * archures.c (bfd_lookup_arch): Move the list order comment..
4451 (struct bfd_arch_info): ..to where it belongs.
4452 * bfd-in2.h: Regenerate.
4453
99dc0092
AM
4454 * archures.c (bfd_lookup_arch): Add comment on list order.
4455 (bfd_default_set_arch_mach): Use bfd_lookup_arch.
4456 * cpu-powerpc.c (bfd_powerpc_archs): Re-order so that the default
4457 is always at head of list.
4458
7831a775
NC
44592002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
4460
4461 * coff-arm.c (coff_thumb_pcrel_12, coff_thumb_pcrel_9,
4462 insert_thumb_branch, record_thumb_to_arm_glue): Suppress
4463 definition of these functions for ARM_WINCE builds as they are
4464 not used.
ea1e4b0d 4465 (SWAP_IN_RELOC_OFFSET, SWAP_OUT_RELOC_OFFSET): Do not define
7831a775
NC
4466 for ARM_WINCE builds.
4467
44682002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
4469
ea1e4b0d 4470 * coff-arm.c (bfd_arm_process_before_allocation):
7831a775
NC
4471
44722002-04-17 J"orn Rennecke <joern.rennecke@superh.com>
a44d7f9c
JR
4473
4474 * cpu-sh.c (scan_mach): Delete.
4475 (arch_info_struct): Replace scan_mach with bfd_default_scan.
4476 (bfd_sh_arch): Likewise.
4477
3d8dbe36
NC
44782002-04-16 Nick Clifton <nickc@cambridge.redhat.com>
4479
4480 * ihex.c (ihex_write_object_contents): Fix check for records
4481 crossing 64K boundaries.
4482
4ab82700
AM
44832002-04-16 Alan Modra <amodra@bigpond.net.au>
4484
4485 * elf32-m32r.c (m32r_elf_add_symbol_hook): Check the hash table
4486 type rather than just assuming entries are ELF.
4487 * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
4488 * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
4489 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Likewise.
4490 * elf64-mmix.c (mmix_elf_add_symbol_hook): Use bfd_link_hash_entry
4491 rather than elf_link_hash_entry.
4492
036fe0fe
RH
44932002-04-15 Richard Henderson <rth@redhat.com>
4494
4495 * elf32-mips.c (mips_elf32_object_p): Revert 0404 fragment: allow
4496 n32 binaries.
4497
c4f3d130
NC
44982002-04-15 Michael Snyder <msnyder@redhat.com>
4499
4500 * opncls.c (bfd_close): Write contents if writeable.
4501 Minor formatting tidy-ups.
4502
4ab82700 45032002-04-15 Alan Modra <amodra@bigpond.net.au>
27242387
AM
4504
4505 * elf32-ppc.c (ppc_elf_add_symbol_hook): Check the hash table type.
4506
0c04d169
MS
45072002-04-12 Michael Snyder <msnyder@redhat.com>
4508
4509 * bfd-in.h (bfd_get_section_lma): New access macro.
4510 Minor white-space fix-up.
4511
89d4966f
AM
45122002-04-12 Alan Modra <amodra@bigpond.net.au>
4513
4514 * elf.c (prep_headers): Don't zero EI_OSABI, EI_ABIVERSION or
4515 header pad.
4516
8d0da3c2
DD
45172002-04-09 DJ Delorie <dj@redhat.com>
4518
4519 * elfarm-nabi.c (elf32_arm_howto_table): Fix ABS16 masks.
4520
05793179
NC
45212002-04-09 Casper S. Hornstrup <chorns@users.sourceforge.net>
4522
4523 * coffcode.h (coff_read_word): New.
4524 (coff_compute_checksum): New.
4525 (coff_apply_checksum): New.
4526 (coff_write_object_contents): Call coff_apply_checksum () to
4527 apply checksum to PE image.
4528
46fe4e66
AM
45292002-04-08 Randolph Chung <tausq@debian.org>
4530
4531 * elf32-hppa.c (hppa_unwind_entry_compare): Move to elf-hppa.h.
4532 (elf32_hppa_final_link): Split out sorting logic to..
4533 * elf-hppa.h (elf_hppa_sort_unwind): ..here.
4534 (elf_hppa_final_link): Call elf_hppa_sort_unwind.
4535
3b5b409c
AC
45362002-04-07 Andrew Cagney <ac131313@redhat.com>
4537
4538 * configure.in: Add missing ``|'' to powerpc-*-aix4.[4-9]*
4539 pattern.
4540 * configure: Re-generate.
4541
ac7b6ceb
AC
45422002-04-07 Andrew Cagney <ac131313@redhat.com>
4543
4544 * configure.in: Only define AIX_CORE_DUMPX_CORE when AIX version
4545 is greater or equal to 4.3.3.
4546 * configure: Regenerate.
4547 Fix PR gdb/344.
4548
44aa49bb
HPN
45492002-04-05 Hans-Peter Nilsson <hp@axis.com>
4550
4551 * elf32-cris.c (cris_elf_howto_table) <R_CRIS_16_PCREL,
4552 R_CRIS_32_PCREL>: Fix typo in name.
4553 (cris_elf_check_relocs): Always create .rela.got here when
4554 R_CRIS_16_GOTPLT or R_CRIS_32_GOTPLT is seen.
4555 (elf_cris_adjust_gotplt_to_got): Don't create .rela.got here;
4556 assume it's created.
4557
e2d34d7d
DJ
45582002-04-04 Daniel Jacobowitz <drow@mvista.com>
4559
4560 * aout-adobe.c (aout_32_bfd_link_hash_table_free): Define.
4561 * aout-target.h (MY_bfd_link_hash_table_free): Conditionally
4562 define.
4563 * aout-tic30.c (MY_bfd_link_hash_table_free): Likewise.
4564 * bfd.c (bfd_link_hash_table_free): Define.
4565 * binary.c (binary_bfd_link_hash_table_free): Define.
4566 * bout.c (b_out_bfd_link_hash_table_free): Define.
4567 * coff-rs6000.c (rs6000coff_vec): Include
4568 _bfd_generic_link_hash_table_free.
4569 (pmac_xcoff_vec): Likewise.
4570 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
4571 (aix5coff64_vec): Likewise.
4572 * coffcode.h (coff_bfd_link_hash_table_free): Conditionally define.
4573 * elf-m10300.c (elf32_mn10300_link_hash_table_free): New function.
4574 (bfd_elf32_bfd_link_hash_table_free): Define.
4575 * elf32-hppa.c (elf32_hppa_link_hash_table_free): New function.
4576 (bfd_elf32_bfd_link_hash_table_free): Define.
4577 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_free): Conditionally
4578 define.
4579 * i386msdos.c (msdos_bfd_link_hash_table_free): Define.
4580 * i386os9k.c (os9k_bfd_link_hash_table_free): Define.
4581 * ieee.c (ieee_bfd_link_hash_table_free): Define.
4582 * ihex.c (ihex_bfd_link_hash_table_free): Define.
4583 * libbfd-in.h (_bfd_nolink_bfd_link_hash_table_free): Define.
4584 (_bfd_generic_link_hash_table_free): Add prototype.
4585 * libcoff-in.h (_bfd_xcoff_bfd_link_hash_table_free): Add prototype.
4586 * libecoff.h (_bfd_ecoff_bfd_link_hash_table_free): Define.
4587 * linker.c (_bfd_generic_link_hash_table_free): New function.
4588 * mmo.c (mmo_bfd_link_hash_table_free): Define.
4589 * nlm-target.h (nlm_bfd_link_hash_table_free): Define.
4590 * oasys.c (oasys_bfd_link_hash_table_free): Define.
4591 * ppcboot.c (ppcboot_bfd_link_hash_table_free): Define.
4592 * som.c (som_bfd_link_hash_table_free): Define.
4593 * srec.c (srec_bfd_link_hash_table_free): Define.
4594 * tekhex.c (tekhex_bfd_link_hash_table_free): Define.
4595 * versados.c (versados_bfd_link_hash_table_free): Define.
4596 * vms.c (vms_bfd_link_hash_table_free): New function.
4597 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_free): New function.
4598
4599 * coff-arm.c (coff_arm_link_hash_table_create): Use bfd_malloc
4600 instead of bfd_alloc.
4601 * coff-h8300.c (h8300_coff_link_hash_table_create): Likewise.
4602 * coff-mcore.c (coff_mcore_link_hash_table_create): Likewise.
4603 * coff-ppc.c (ppc_coff_link_hash_table_create): Likewise.
4604 * cofflink.c (_bfd_coff_link_hash_table_create): Likewise.
4605 * ecoff.c (_bfd_ecoff_bfd_link_hash_table_create): Likewise.
4606 * elf-m10300.c (elf32_mn10300_link_hash_table_create): Likewise.
4607 * elf.c (_bfd_elf_link_hash_table_create): Likewise.
4608 * elf32-arm.h (elf32_arm_link_hash_table_create): Likewise.
4609 * elf32-cris.c (elf_cris_link_hash_table_create): Likewise.
4610 * elf32-hppa.c (elf32_hppa_link_hash_table_create): Likewise.
4611 * elf32-i386.c (elf_i386_link_hash_table_create): Likewise.
4612 * elf32-m68k.c (elf_m68k_link_hash_table_create): Likewise.
4613 * elf32-s390.c (elf_s390_link_hash_table_create): Likewise.
4614 * elf32-sh.c (sh_elf_link_hash_table_create): Likewise.
4615 * elf64-alpha.c (elf64_alpha_bfd_link_hash_table_create): Likewise.
4616 * elf64-ppc.c (ppc64_elf_link_hash_table_create): Likewise.
4617 * elf64-s390.c (elf_s390_link_hash_table_create): Likewise.
4618 * elf64-sh64.c (sh64_elf64_link_hash_table_create): Likewise.
4619 * elf64-sparc.c (sparc64_elf_bfd_link_hash_table_create): Likewise.
4620 * elf64-x86-64.c (elf64_x86_64_link_hash_table_create): Likewise.
4621 * elfxx-mips.c (_bfd_mips_elf_link_hash_table_create): Likewise.
4622 * linker.c (_bfd_generic_link_hash_table_create): Likewise.
4623 * m68klinux.c (linux_link_hash_table_create): Likewise.
4624 * sparclinux.c (linux_link_hash_table_create): Likewise.
4625 * sunos.c (sunos_link_hash_table_create): Likewise.
4626 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Likewise.
4627
4628 * targets.c: Add _bfd_link_hash_table_free to xvec.
4629
4630 * bfd-in2.h: Regenerate.
4631 * libbfd.h: Regenerate.
4632 * libcoff.h: Regenerate.
4633
830629ab
AM
46342002-04-04 Alan Modra <amodra@bigpond.net.au>
4635
4636 * dep-in.sed: Cope with absolute paths.
4637 * Makefile.am (dep.sed): Subst TOPDIR, and not INCDIR.
4638 Run "make dep-am".
4639 * Makefile.in: Regenerate.
4640 * coff-arm.c: Fix copyright date.
4641 * cpu-h8300.c: Likewise.
4642 * cpu-i370.c: Likewise.
4643 * cpu-s390.c: Likewise.
4644 * cpu-mips.c: Likewise.
4645 * po/SRC-POTFILES.in: Regenerate.
4646
c6e90b02
TS
46472002-04-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
4648
4649 * Makefile.am: Add elfxx-mips.c to the known backends.
4650 (elf32-mips.lo): remove dependency to coff/external.h.
4651 * Makefile.in: Regenerate.
4652 * configure.in: Add elfxx-mips.lo to all vectors using elf32-mips.lo
4653 Remove elf32-mips.lo from 64 bit vectors. Update dependencies
4654 accordingly.
4655 * configure: Regenerate.
4656 * elf-bfd.h: Move all MIPS ELF specific prototypes to elfxx-mips.h.
4657 (irix_compat_t): IRIX compatibility level, moved from elf32-mips.c.
4658 (elf_backend_mips_irix_compat, elf_backend_mips_rtype_to_howto): New
4659 MIPS specific backend functions.
4660 * elf32-mips.c: Moved most code to elfxx-mips.c.
4661 (mips_elf_hi16_reloc): Rename from _bfd_mips_elf_hi16_reloc and make
4662 static.
4663 (mips_elf_lo16_reloc): Likewise, was _bfd_mips_elf_lo16_reloc.
4664 (mips_elf_got16_reloc): Likewise, was _bfd_mips_elf_got16_reloc.
4665 (mips_elf_gprel32_reloc): Likewise, was _bfd_mips_elf_gprel32_reloc.
4666 (mips_elf32_rtype_to_howto): Rename from mips_rtype_to_howto. Changed
4667 interface to allow selection of the right REL or RELA howto table.
4668 (mips_elf32_object_p): Rename from _bfd_mips_elf_object_p and made
4669 static. Let it refuse n32 objects.
4670 (elf32_mips_grok_prstatus): Rename from _bfd_elf32_mips_grok_prstatus.
4671 (elf32_mips_grok_psinfo): Rename from _bfd_elf32_mips_grok_psinfo.
4672 (elf32_mips_discard_info): Rename from _bfd_elf32_mips_discard_info.
4673 (elf32_mips_ignore_discarded_relocs): Rename from
4674 _bfd_elf32_mips_ignore_discarded_relocs.
4675 (elf32_mips_write_section): Rename from _bfd_elf32_mips_write_section.
4676 (elf32_mips_irix_compat): New function, replaces IRIX_COMPAT.
4677 (elf_mips_howto_table_rela): Remove.
4678 * elf64-mips.c: Moved most code to elfxx-mips.c.
4679 (bfd_elf64_bfd_reloc_type_lookup): Make static.
4680 (mips_elf64_rtype_to_howto): New function.
4681 (mips_elf64_object_p): Likewise.
4682 (elf64_mips_irix_compat): Likewise.
4683 * elfxx-mips.c: New file containing common code merged together from
4684 elf32-mips.c and elf64-mips.c.
4685 * elfxx-mips.h: New file containing MIPS specific prototypes from
4686 elf-bfd.h.
4687 * elfxx-target.h: Add handling for elf_backend_mips_irix_compat and
4688 elf_backend_mips_rtype_to_howto.
4689
d8dce692
AM
46902002-04-04 Alan Modra <amodra@bigpond.net.au>
4691
4692 * srec.c (MAXCHUNK, Chunk): Revise comments.
4693 (srec_write_record): Correct buffer size.
4694 (srec_write_header): Do without intermediate buffer.
4695 (srec_write_section): Validate Chunk.
4696 (srec_write_terminator): Pass NULL instead of dummy buffer.
4697 (srec_write_symbols): Pass file and symbol names directly to
4698 bfd_bwrite so sprintf won't overflow buffer.
4699
b88a866a
JJ
47002002-04-03 Jakub Jelinek <jakub@redhat.com>
4701
4702 * elf32-sparc.c (elf32_sparc_relocate_section): Don't emit dynamic
4703 PC relative relocs against hidden symbols.
4704 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
4705
d7866f04
AM
47062002-04-03 Alan Modra <amodra@bigpond.net.au>
4707
4708 * elf.c (_bfd_elf_make_section_from_shdr): When setting section
4709 LMAs, loop over segments until p_vaddr and p_memsz specify an
4710 extent enclosing the section.
4711
9e81ee67
NC
47122002-04-02 Nick Clifton <nickc@cambridge.redhat.com>
4713
4714 * ihex.c (ihex_write_object_contents): Do not allow records to
4715 cross a 64K boundary - wrap if necessary.
4716
d2b64500
JT
47172002-04-01 Nathan Williams <nathanw@wasabisystems.com>
4718
4719 * elf.c (elfcore_netbsd_get_lwpid): Fix off-by-one error
4720 which caused the returned LWP ID to always be 0.
4721
e36f7d53
RH
47222002-04-01 Richard Henderson <rth@redhat.com>
4723
4724 * elf32-sparc.c (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
4725 (elf32_sparc_relocate_section): Use it to figure out when to
4726 initialize .got entries.
4727 * elf64-sparc.c: Similarly.
4728
e92d460e
AM
47292002-03-28 Alan Modra <amodra@bigpond.net.au>
4730
4731 * linker.c (link_action): Ignore duplicate warning syms.
4732 (_bfd_generic_link_write_global_symbol): Follow warning symbol link.
4733 * elflink.h (elf_adjust_dynstr_offsets): Likewise.
4734 (elf_adjust_dynamic_symbol): Likewise.
4735 (elf_export_symbol): Likewise.
4736 (elf_link_find_version_dependencies): Likewise.
4737 (elf_link_assign_sym_version): Likewise.
4738 (elf_link_sec_merge_syms): Likewise.
4739 (elf_link_output_extsym): Likewise.
4740 (elf_gc_sweep_symbol): Likewise.
4741 (elf_gc_propagate_vtable_entries_used): Likewise.
4742 (elf_gc_smash_unused_vtentry_relocs): Likewise.
4743 (elf_gc_allocate_got_offsets): Likewise.
4744 (elf_collect_hash_codes): Likewise.
4745 * elflink.c (elf_link_renumber_hash_table_dynsyms): Likewise.
4746 * elf-hppa.h (elf_hppa_unmark_useless_dynamic_symbols): Likewise.
4747 (elf_hppa_remark_useless_dynamic_symbols): Likewise.
4748 * elf-m10300.c (elf32_mn10300_finish_hash_table_entry): Likewise.
4749 * elf32-arm.h (elf32_arm_discard_copies): Likewise.
4750 * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Likewise.
4751 (elf_cris_discard_excess_dso_dynamics): Likewise.
4752 * elf32-hppa.c (clobber_millicode_symbols): Likewise.
4753 (mark_PIC_calls): Likewise.
4754 (allocate_plt_static): Likewise.
4755 (allocate_dynrelocs): Likewise.
4756 (readonly_dynrelocs): Likewise.
4757 * elf32-i386.c (allocate_dynrelocs): Likewise.
4758 (readonly_dynrelocs): Likewise.
4759 * elf32-i370.c (i370_elf_adjust_dynindx): Likewise.
4760 * elf32-m68k.c (elf_m68k_discard_copies): Likewise.
4761 * elf32-mips.c (mips_elf_output_extsym): Likewise.
4762 (mips_elf_sort_hash_table_f): Likewise.
4763 (mips_elf_check_mips16_stubs): Likewise.
4764 * elf32-s390.c (allocate_dynrelocs): Likewise.
4765 (readonly_dynrelocs): Likewise.
4766 * elf32-sh.c (sh_elf_discard_copies): Likewise.
4767 * elf32-xstormy16.c (xstormy16_relax_plt_check): Likewise.
4768 (xstormy16_relax_plt_realloc): Likewise.
4769 * elf64-alpha.c (elf64_alpha_calc_got_offsets_for_symbol): Likewise.
4770 (elf64_alpha_output_extsym): Likewise.
4771 * elf64-hppa.c (elf64_hppa_mark_exported_functions): Likewise.
4772 * elf64-mips.c (mips_elf64_sort_hash_table_f): Likewise.
4773 (mips_elf64_check_mips16_stubs): Likewise.
4774 (mips_elf64_output_extsym): Likewise.
4775 * elf64-ppc.c (func_desc_adjust): Likewise.
4776 (allocate_dynrelocs): Likewise.
4777 (readonly_dynrelocs): Likewise.
4778 * elf64-s390.c (allocate_dynrelocs): Likewise.
4779 (readonly_dynrelocs): Likewise.
4780 * elf64-sh64.c (sh64_elf64_discard_copies): Likewise.
4781 * elf64-x86-64.c (allocate_dynrelocs): Likewise.
4782 (readonly_dynrelocs): Likewise.
4783 * elfxx-ia64.c (elfNN_ia64_global_dyn_sym_thunk): Likewise.
4784 * aoutx.h (aout_link_write_other_symbol): Likewise.
4785 * cofflink.c (_bfd_coff_write_task_globals): Likewise.
4786 (_bfd_coff_write_global_sym): Likewise.
4787 * i386linux.c (linux_tally_symbols): Likewise.
4788 * m68klinux.c (linux_tally_symbols): Likewise.
4789 * sparclinux.c (linux_tally_symbols): Likewise.
4790 * pdp11.c (aout_link_write_other_symbol): Likewise.
4791 * sunos.c (sunos_scan_dynamic_symbol): Likewise.
4792 * xcofflink.c (xcoff_build_ldsyms): Likewise.
4793 (xcoff_write_global_symbol): Likewise.
4794
4795 * cofflink.c (_bfd_coff_final_link): Formatting.
4796 * cpu-mips.c (mips_compatible): Make static, prototype.
4797 * elf32-i386.c (elf_i386_check_relocs): Formatting.
4798 * elf32-sh.c (sh_elf_size_dynamic_sections): Likewise.
4799 * elf64-alpha.c (elf64_alpha_output_extsym): Likewise.
4800 * elf64-mips.c (mips_elf64_sort_hash_table): Likewise.
4801 (mips_elf64_final_link): Likewise.
4802 * elflink.h (elf_link_find_version_dependencies): Remove duplicate
4803 prototype.
4804
2106126f
NC
48052002-03-27 Nick Clifton <nickc@cambridge.redhat.com>
4806
4807 * coff-arm.c (SWAP_IN_RELOC_OFFSET): Define.
4808 (SWAP_OUT_RELOC_OFFSET): Define.
4809
b99d1833
AM
48102002-03-27 Gregory Steuck <greg@nest.cx>
4811
4812 * elf.c (_bfd_elf_get_symtab_upper_bound): Leave space for
4813 terminating NULL if empty symbol table.
4814 (_bfd_elf_get_dynamic_symtab_upper_bound): Likewise.
4815
ad43ed4c
L
48162002-03-26 H.J. Lu (hjl@gnu.org)
4817
4818 * elflink.h (elf_link_input_bfd): Revert the last change since
4819 the gcc exception handling isn't fixed yet.
4820
3851fca4
L
48212002-03-26 H.J. Lu (hjl@gnu.org)
4822
4823 * elflink.h (elf_link_input_bfd): Complain about relocations
4824 against local symbols in discarded sections.
4825
b91afed7
AM
48262002-03-26 Alan Modra <amodra@bigpond.net.au>
4827
4828 * elflink.h (elf_gc_mark): Don't recurse into non-ELF sections.
4829
dba143ef
AM
48302002-03-23 Alan Modra <amodra@bigpond.net.au>
4831
4832 * elf.c (_bfd_elf_make_section_from_shdr): Don't set lma based on
4833 section file offset for !SEC_LOAD sections.
4834
ee29b9fb
RE
48352002-03-21 Richard Earnshaw <rearnsha@arm.com>
4836
830629ab
AM
4837 * elf32-arm.h (elf32_arm_final_link_relocate <case R_ARM_GOTOFF>,
4838 <case R_ARM_GOT>): Handle relocations to Thumb functions.
ee29b9fb 4839
54327882
AM
48402002-03-21 Alan Modra <amodra@bigpond.net.au>
4841
4842 * coff64-rs6000.c (_bfd_xcoff64_put_symbol_name): Prototype.
4843 Whitespace changes.
4844 * archive.c: Update copyright date.
4845 * bfd-in2.h: Regenerate.
4846 * libbfd.h: Regenerate.
4847 * Makefile.am: Run "make dep-am"
4848 * Makefile.in: Regenerate.
4849 * po/SRC-POTFILES.in: Regenerate.
4850
1ee24f27
DJ
48512002-03-20 Daniel Jacobowitz <drow@mvista.com>
4852
4853 * dwarf2.c (struct funcinfo): Move up.
4854 (lookup_address_in_function_table): New argument function_ptr.
4855 Set it.
4856 (lookup_address_in_line_table): New argument function. If function
4857 is non-NULL, use it to handle ``addr'' before the first line note of
4858 the function.
4859 (comp_unit_find_nearest_line): Update and swap calls to
4860 lookup_address_in_function_table and lookup_address_in_line_table.
4861 * syms.c (_bfd_stab_section_find_nearest_line): Use the first
4862 N_SLINE encountered if we see an N_FUN before any N_SLINE.
4863
51b9608c
TR
48642002-03-20 Tom Rix <trix@redhat.com>
4865
ea1e4b0d 4866 * coff-rs6000.c (_bfd_xcoff_stat_arch_elt): Renamed from
51b9608c 4867 _bfd_xcoff_generic_stat_arch_elt. Fix format check.
ea1e4b0d 4868 * coff64-rs6000.c : Use _bfd_xcoff_stat_arch_elt.
51b9608c 4869
789c90aa
TR
48702002-03-19 Tom Rix <trix@redhat.com>
4871
ea1e4b0d 4872 * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Look through all
789c90aa
TR
4873 dynamic objects in archives.
4874
1da54d81
HPN
48752002-03-19 Hans-Peter Nilsson <hp@bitrange.com>
4876
4877 * elflink.h (NAME(bfd_elf,record_link_assignment)): Don't set
4878 STT_NOTYPE symbols to STT_OBJECT.
4879
7831a775 48802002-03-18 Jan Hubicka <jh@suse.cz>
beb43bb9
JH
4881
4882 * cpu-i386.c (bfd_x86_64_arch): Rename to "i386:x86-64"
4883
eb1e0e80
NC
48842002-03-18 Tom Rix <trix@redhat.com>
4885
4886 * aix5ppc.core.c : New file for AIX 5 64 bit core support.
4887 * bfd-in.h : Add bfd_xcoff_ar_archive_set_magic declaration.
4888 * coff-rs6000 (do_pad) : New function for archive padding.
4889 (do_copy) : New function for object file copying in archives.
4890 (do_shared_object_padding) : New function for padding shared
4891 objects to their text section alignment in archives.
4892 (bfd_xcoff_ar_achive_set_magic) : Stub.
4893 (xcoff_write_armap_big) : Use do_copy and do_pad.
4894 (xcoff_write_archive_contents_big) : Use do_shared_object_padding,
4895 do_copy and do_pad.
4896 * coff64-rs6000.c (xcoff64_write_ojbect_contents) : Use
ea1e4b0d 4897 bfd_xcoff_magic_number.
eb1e0e80
NC
4898 (xcoff64_bad_format_hook) : New function for _bfd_bad_format_hook
4899 fop.
4900 (xcoff_backend_data_r) : Use xcoff64_bad_format_hook.
4901 (bfd_xcoff_aix5_backend_data) : New Aix 5 backend data.
4902 (aix5coff64_vec) : New Aix 5 target aix5coff64-rs6000.
4903 * rs6000-core.c : Update copyright date.
ea1e4b0d 4904 * xcofflink.c (bfd_xcoff_size_dynamic_sections): Check for NULL
eb1e0e80
NC
4905 csectpp.
4906 * coffcode.h (coff_new_section_hook) : Use new accessor macros.
4907 (coff_set_arch_mach_hook) : Add Aix 5 U64_TOCMAGIC magic #.
4908 (coff_set_flags) : Use bfd_xcoff_magic_number.
4909 * libxcoff.h (bfd_xcoff_is_xcoff64): Add U64_TOCMAGIC.
4910 * configure.in : Add powerpc-*-aix5 and rs6000-*-aix5 support.
4911 * Makefile.am : Same.
4912 * config.bfd : Same.
4913 * targets.c : Same.
4914 * configure : Regnerate.
4915 * Makefile.in : Same.
4916 * bfd-in2.h : Same.
4917
a1c259a1
NC
49182002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
4919
4920 * po/fr.po: Updated version.
4921
4dae1ae7
AM
49222002-03-18 Alan Modra <amodra@bigpond.net.au>
4923
4924 * libbfd.c (bfd_write_bigendian_4byte_int): Return true iff success.
4925 * libbfd.h: Regenerate.
4926 * archive.c (coff_write_armap): Pass on failures from
4927 bfd_write_bigendian_4byte_int.
4928
36b4f6e7
L
49292002-03-14 H.J. Lu <hjl@gnu.org>
4930
4931 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the BFD
4932 error to bfd_error_nonrepresentable_section for reinit_array
4933 section in DSO.
4934
a1aefc76
NC
49352002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
4936
a181be0a
NC
4937 * coffcode.h (coff_slurp_symbol_table): When adding BSF_WEAK flag,
4938 OR it in rather than replacing previously selected flags.
4939
a1aefc76
NC
4940 * elfxx-target.h (TARGET_BIG_SYM): Set ar_max_namelen to 15.
4941 (TARGET_LITTLE_SYM): Set ar_max_namelen to 15.
4942
c119f9b8
AM
49432002-03-14 Alan Modra <amodra@bigpond.net.au>
4944
4945 * cpu-mips.c (mips_compatible): New. Don't check bits_per_word.
4946 (N): Use the above.
4947 * elflink.h (elf_bfd_final_link): Revert last change. Instead,
4948 ensure reloc size matches before calling elf_link_input_bfd.
4949 Add an assert to check reloc size when counting output relocs.
4950
c295a511
NC
49512002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
4952
4953 * mmo.c (mmo_get_loc): Return NULL rather than false.
4954
9ce88e60
NC
49552002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
4956
4957 * po/fr.po: Updated version.
4958
4ddafab0
AM
49592002-03-13 Alan Modra <amodra@bigpond.net.au>
4960
b74fa2cd
AM
4961 * archures.c (bfd_default_compatible): Test bits_per_word.
4962 * cpu-i386.c (i386_compatible): Remove. Replace occurrences with
4963 bfd_default_compatible.
4964 * cpu-i370.c (i370_compatible): Likewise.
4965 * cpu-sparc.c (sparc_compatible): Likewise.
4966 * cpu-h8300.c (compatible): Test in->arch == out->arch.
4967
40b829d4
AM
4968 * elflink.h: Formatting fixes.
4969 (elf_link_output_extsym): Merge undefined and undef weak cases.
4970
4ddafab0
AM
4971 * elflink.h (elf_bfd_final_link): Only call elf_link_input_bfd
4972 when word size of input matches output word size.
4973
dd53c801
AJ
49742002-03-12 Andreas Jaeger <aj@suse.de>
4975
4976 * cpu-i386.c (i386_compatible): New. Use it instead of
4977 bfd_default_compatible.
4978
aa066ac8
L
49792002-03-07 H.J. Lu (hjl@gnu.org)
4980
4981 * coff-sh.c (shcoff_reloc_map): Use bfd_reloc_code_real_type
4982 as the type for bfd_reloc_val.
4983
1bf42538
JL
49842002-03-05 John David Anglin <dave@hiauly1.hia.nrc.ca>
4985
4986 * elf-hppa.h (elf_hppa_is_dynamic_loader_symbol): New function.
4987 (elf_hppa_relocate_section): Ignore undefined dynamic loader symbols.
4988 (elf_hppa_final_link_relocate): Correct relocations for indirect
4989 references to local data through the DLT. Fix .opd creation for
4990 local symbols using R_PARISC_LTOFF_FPTR32 and R_PARISC_FPTR64
4991 relocations. Use e_lsel selector for R_PARISC_DLTIND21L,
4992 R_PARISC_LTOFF_FPTR21L and R_PARISC_LTOFF_TP21L as per
4993 "Processor-Specific ELF for PA_RISC, Version 1.43" document.
4994 Similarly, use e_rsel for DLT and LTOFF 'R' relocations.
4995 * elf32-hppa.c (final_link_relocate): Revise relocation selectors
4996 as per "Processor-Specific ELF for PA_RISC, Version 1.43" document.
4997
86eaf01e
JJ
49982002-03-05 Jakub Jelinek <jakub@redhat.com>
4999
5000 * merge.c (_bfd_merge_sections): Don't segfault if there
5001 is nothing to merge due to GC.
5002
c44233aa
AM
50032002-03-05 Alan Modra <amodra@bigpond.net.au>
5004
039cc25f
AM
5005 * elf32-hppa.c (clobber_millicode_symbols): Remove hack to keep
5006 symbols that have been forced local.
5007
c44233aa
AM
5008 * elflink.h (elf_bfd_final_link): Call elf_link_output_extsym
5009 to output forced local syms for non-shared link.
5010 (elf_link_output_extsym): Tweak condition for calling backend
5011 adjust_dynamic_symbol so that previous behaviour is kept.
5012 Whitespace changes throughout file.
5013
25e27870
L
50142002-03-04 H.J. Lu <hjl@gnu.org>
5015
5016 * elf.c (bfd_section_from_shdr): Handle special sections,
5017 .init_array, .fini_array and .preinit_array.
5018 (elf_fake_sections): Likewise.
5019
5020 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Create the
5021 DT entry only if the section is in output for .init_array,
5022 .fini_array and .preinit_array. Complain about .preinit_array
5023 section in DSO.
5024 (elf_bfd_final_link): Warn zero size for .init_array,
5025 .fini_array and .preinit_array sections.
5026
5027 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Remove
5028 SHT_INIT_ARRAY, SHT_FINI_ARRAY and SHT_PREINIT_ARRAY.
5029 (elfNN_ia64_fake_sections): Remove .init_array, .fini_array and
5030 .preinit_array.
5031
bb2a49f2
AM
50322002-03-04 Alan Modra <amodra@bigpond.net.au>
5033
5034 * configure.in (WIN32LIBADD): Don't eval PICFLAG assignment.
5035 * configure: Regenerate.
5036
38487e5e
TR
50372002-03-02 Tom Rix <trix@redhat.com>
5038
c44233aa
AM
5039 * coff64-rs6000.c (xcoff64_howto_table): Replace howto types with
5040 symbolic equiv.
38487e5e
TR
5041 * coff-rs6000.c (xcoff_howto_table): Same.
5042
30831527
RH
50432002-03-01 David Mosberger <davidm@hpl.hp.com>
5044
5045 * elflink.h (size_dynamic_sections): If section named
5046 ".preinit_array" exists, create DT_PREINIT_ARRAY and
5047 DT_PREINIT_ARRAYSZ entries in dynamic table. Analogously for
5048 ".init_array" and ".fini_array".
5049 (elf_bfd_final_link): Handle DT_PREINIT_ARRAYSZ, DT_INIT_ARRAYSZ,
5050 DT_FINI_ARRAYSZ, DT_PREINIT_ARRAY, DT_INIT_ARRAY, and
5051 DT_FINI_ARRAY.
5052
c8e5ddc8
AM
50532002-02-26 Andrew Macleod <amacleod@cygnus.com>
5054
5055 * elflink.h (elf_bfd_final_link): Don't crash on SHN_UNDEF local
5056 dynsyms.
5057
96e0dda4
AM
50582002-02-25 Alan Modra <amodra@bigpond.net.au>
5059
1c5b6bf8
AM
5060 * elf64-hppa.h: Update copyright date.
5061
96e0dda4
AM
5062 * elf64-ppc.c (ppc64_elf_check_relocs): Warning fix.
5063 (ppc64_elf_relocate_section): Don't generate power4 style branch
5064 hints for *_BRTAKEN and *_BRNTAKEN relocs.
5065
0fb19cbc
JJ
50662002-02-22 Jakub Jelinek <jakub@redhat.com>
5067
5068 * elf64-sh64.c (sh_elf64_relocate_section): Fix a typo from my
5069 last patch.
5070 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
5071
c434dee6
AJ
50722002-02-21 Andreas Jaeger <aj@suse.de>
5073
5074 * elf64-x86-64.c: Major rework that introduces all recent changes
5075 to the x86-64 backend. Get a closer match to elf32-i386.
5076 (struct elf64_x86_64_dyn_relocs): Rename from
5077 elf64_x86_64_pcrel_relocs_copied, add additional fields. Change
5078 all users.
5079 (struct elf64_x86_64_link_hash_table): Add short cuts to some
5080 sections.
5081 (link_hash_newfunc): Rename from elf64_x86_64_link_hash_newfunc,
5082 remove casts, initialize new hash members.
5083 (create_got_section): New.
5084 (elf64_x86_64_create_dynamic_sections): New.
5085 (elf64_x86_64_copy_indirect_symbol): New.
5086 (elf64_x86_64_check_relocs): Don't allocate space for dynamic
5087 relocs, .got or .relgot here but do it in allocate_dynrelocs.
5088 Reference count possible .plt and .got entries. Don't test input
5089 section SEC_READONLY here to try to avoid copy relocs, and keep
5090 dyn_relocs regardless of ELF_LINK_NON_GOT_REF. Don't set
5091 DF_TEXTREL here. Delay setting of variables until needed. Cache
5092 pointer to "sreloc" section in elf_section_data. Tweak condition
5093 under which .got created. Report files with bad relocation
5094 section names.
5095 (elf64_x86_64_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
5096 Reference count possible .plt entries. Don't deallocate .got and
5097 .relgot space here.
5098 (elf64_x86_64_adjust_dynamic_symbol): Handle nocopyreloc. Don't
5099 do copy reloc processing for weakdefs. Remove redundant casts and
5100 aborts. Delay setting of vars until needed. Move creation of
5101 dynamic symbols and allocation of .plt and .rela.plt to
5102 allocate_dynrelocs. Replace BFD_ASSERT with abort.
5103 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
5104 (allocate_dynrelocs): New.
5105 (readonly_dynrelocs): New.
5106 (elf64_x86_64_size_dynamic_sections): Call readonly_dynrelocs.
5107 Allocate space for dyn relocs. Replace BFD_ASSERT with abort.
5108 Zero out the dynamic allocated content space.
5109 (elf64_x86_64_discard_copies): Removed.
5110 (elf64_x86_64_relocate_section): Make use of dynamic section
5111 short-cuts. Localise vars, and delay setting. Better error
5112 reporting, replace BFD_ASSERT with abort. Check
5113 ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined in the
5114 regular object file and tread the weak definition as the normal
5115 one. Don't discard relocs for undefweak or undefined symbols and
5116 check !DEF_REGULAR as well as DEF_DYNAMIC in test for avoided copy
5117 relocs.
5118 (elf64_x86_64_finish_dynamic_symbol): Don't copy relocs for
5119 symbols that have been forced local. Use same test to decide if
5120 we can use a relative reloc for got as relocate_section. Expand
5121 SHN_UNDEF comment. Move expressions out of function calls.
5122 Replace BFD_ASSERT with abort.
5123 (bfd_elf64_bfd_final_link): Removed.
5124 (elf_backend_copy_indirect_symbol): Define.
5125
ff3a6ee3
TR
51262002-02-20 Tom Rix <trix@redhat.com>
5127
5128 * coff-rs6000.c (xcoff_howto_table): Add 16 bit R_BA.
5129 (_bfd_xcoff_reloc_type_lookup): Use it.
5130 * coff64-rs6000.c (xcoff64_howto_table): Same.
5131 (xcoff64_reloc_type_lookup): Same.
c434dee6 5132
a68d41fb
AM
51332002-02-20 Peter Schauer <pes@regent.e-technik.tu-muenchen.de>
5134
5135 * osf-core.c (osf_core_vec): OSF/1 (Digital Unix) core files are
5136 little endian.
5137
befc3abb
MS
51382002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
5139
5140 * archures.c (bfd_mach_s390_esa): Rename to bfd_mach_s390_31.
5141 (bfd_mach_s390_esame): Rename to bfd_mach_s390_64.
5142 * bfd-in2.h: Regenerate.
5143 * cpu-s390.c (arch_info_struct): Use renamed architecture defines.
5144 Replace architecture name "s390" with "s390:31-bit" and "s390:esame"
5145 with "s390:64-bit".
5146 * elf32-s390.c (elf_howto_table): Add 32 bit pc relative relocations.
5147 (elf_s390_reloc_type_lookup): Likewise.
5148 (elf_s390_check_relocs): Likewise.
5149 (elf_s390_gc_sweep_hook): Likewise.
5150 (elf_s390_relocate_section): Likewise.
5151 (elf_s390_object_p): Use renamed architecture define.
5152 * elf64-s390.c (elf_s390_object_p): Use renamed architecture define.
5153
6eeeec9b
FCE
51542002-02-19 Frank Ch. Eigler <fche@redhat.com>
5155
5156 * syms.c (stt[]): Sorted. Added .init/.fini -> "t" mapping.
5157
0bb2d96a
JJ
51582002-02-19 Jakub Jelinek <jakub@redhat.com>
5159
5160 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Enable
5161 absptr -> pcrel optimization for shared libs.
5162 Only create minimal .eh_frame_hdr if absptr FDE encoding in shared
5163 library cannot be converted to pcrel.
5164 (_bfd_elf_eh_frame_section_offset): Return -2 if making absptr
5165 relative.
5166 * elf32-i386.c (elf_i386_relocate_section): If
5167 _bfd_elf_section_offset returned -2, skip, but make sure the
5168 relocation is installed.
5169 * elf32-arm.h (elf32_arm_final_link_relocate): Likewise.
5170 * elf32-cris.c (cris_elf_relocate_section): Likewise.
5171 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
5172 * elf32-i370.c (i370_elf_relocate_section): Likewise.
5173 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
5174 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
5175 * elf32-s390.c (elf_s390_relocate_section): Likewise.
5176 * elf32-sh.c (sh_elf_relocate_section): Likewise.
5177 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
5178 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
5179 * elf64-s390.c (elf_s390_relocate_section): Likewise.
5180 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
5181 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
5182 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
5183 * elf64-alpha.c (elf64_alpha_relocate_section): Handle
5184 _bfd_elf_section_offset returning -2 the same way as -1.
5185 * elfxx-ia64.c (elfNN_ia64_install_dyn_reloc): Likewise.
5186 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add FIXME
5187 and BFD_ASSERT.
5188 * elf64-mips.c (mips_elf64_create_dynamic_relocation): Likewise.
5189
69f284c7
TR
51902002-02-18 Tom Rix <trix@redhat.com>
5191
5192 * xcofflink.c (bfd_xcoff_link_gernate_rtinit): Add -brtl support.
5193 (bfd_xcoff_size_dynamic_sections): Same.
5194 * bfd-in.h (bfd_xcoff_link_generate_rtinit): Same.
5195 (bfd_xcoff_size_dynamic_sections): Same.
5196 * coff-rs6000.c (xcoff_generate_rtinit): Same.
5197 * coff-rs646000.c (xcoff64_generate_rtinit): Same.
5198 * libxcoff.h (struct xcoff_backend_data_rec): Same.
5199 * xcofflink.c (xcoff_build_ldsyms, xcoff_link_add_symbols): Clean.
5200 * bfd-in2.h: Regenerate.
5201
82bd7b59
AM
52022002-02-18 Alan Modra <amodra@bigpond.net.au>
5203
5204 * elf64-ppc.c (STFD_FR0_0R1, LFD_FR0_0R1, BLR): Define.
5205 (struct ppc_link_hash_table): Add sfpr.
5206 (ppc64_elf_link_hash_table_create): Init it.
5207 (ppc64_elf_create_dynamic_sections): Split creation of .stub and
5208 .glink out to..
5209 (create_linkage_sections): ..here. Make .sfpr too.
5210 (ppc64_elf_check_relocs): Call create_linkage_sections, and set
5211 dynobj early.
5212 (MIN_SAVE_FPR, MAX_SAVE_FPR): Define.
5213 (ppc64_elf_func_desc_adjust): Look for missing ._savef* and
5214 ._restf* functions, and create as needed.
5215 (func_desc_adjust): Only force_local for shared libs.
5216
ef1355e8
NC
52172002-02-18 David O'Brien <obrien@FreeBSD.org>
5218
5219 * configure.in: Bump version number post 2.12 branching.
5220 * configure: Regenerate.
5221
dfa36a69
HPN
52222002-02-17 Hans-Peter Nilsson <hp@bitrange.com>
5223
5224 * mmo.c: Correct and improve comments.
5225 (mmo_write_chunk): Store trailing byte in bfd buffer; don't
5226 zero-pad. Use input to fill up non-empty bfd buffer.
5227 (mmo_flush_chunk): New function.
5228 (mmo_write_loc_chunk): Add parameter last_vmap, all callers
5229 changed. Don't emit location specifier if VMA is same as
5230 *LAST_VMAP after omitting leading zero contents. Call
5231 mmo_flush_chunk before emitting location specifier.
5232 (mmo_write_loc_chunk_list): Call mmo_flush_chunk when finished
5233 with mmo_write_loc_chunk calls.
5234 (mmo_internal_write_section): Call mmo_flush_chunk after
5235 mmo_write_chunk.
5236 (mmo_write_symbols_and_terminator): Move :Main to first position
5237 in symbol array. Add faked one if it does not exist if there are
5238 other symbols. Don't add it if there are no symbols at all. Move
5239 out test for value of :Main from symbol loop. Rename table
5240 fakemain to maintable and variable mainsym to fakemain.
5241
ccf00ab6
RH
52422002-02-15 Richard Henderson <rth@redhat.com>
5243
5244 * elf64-alpha.c (elf64_alpha_relocate_section) [BRSGP]: A target
5245 section with no got matches any got. Simplify error generaion.
5246
88eaccc2
AM
52472002-02-15 Alan Modra <amodra@bigpond.net.au>
5248
fd96f80f
AM
5249 Support arbitrary length fill patterns.
5250 * linker.c (bfd_new_link_order): Zero all fields with bfd_zalloc.
5251 (_bfd_default_link_order): Remove bfd_fill_link_order code.
5252 Call default_data_link_order.
5253 (default_fill_link_order): Delete.
5254 (default_data_link_order): New function.
5255 * elf32-mips.c (_bfd_mips_elf_final_link): Replace occurrences
5256 of bfd_fill_link_order with bfd_data_link_order.
5257 * elf64-alpha.c (elf64_alpha_final_link): Likewise.
5258 * elf64-mips.c (mips_elf64_final_link): Likewise.
5259
88eaccc2
AM
5260 * bfd.c (bfd_scan_vma): Clamp overflows to max bfd_vma value.
5261 Correct value returned in "end" for "0x<non-hex>".
5262
e2fd756b
NC
52632002-02-14 Nick Clifton <nickc@cambridge.redhat.com>
5264
5265 * cpu-arm.c (processors): Replace 'arch' field with 'mach'.
5266 (scan): Test against 'mach' field in info structure.
5267
edd29cf9
AM
52682002-02-14 Alan Modra <amodra@bigpond.net.au>
5269
5270 * elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD.
5271
1e30956e 52722002-02-14 Matt Fredette <fredette@netbsd.org>
76f57f3a
JT
5273
5274 * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Recognize
5275 EF_M68000.
5276
bf36db18
NC
52772002-02-13 Nick Clifton <nickc@cambridge.redhat.com>
5278
5279 * elf.c (_bfd_elf_make_section_from_shdr): Do not insist on
edd29cf9
AM
5280 non-zero physical addresses when adjusting the LMAs of new
5281 sections.
bf36db18 5282
189c6563
AM
52832002-02-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
5284
5285 * elf-hppa.h (elf_hppa_reloc_final_type): New function stripped
5286 from _bfd_elf_hppa_gen_reloc_type.
5287 (_bfd_elf_hppa_gen_reloc_type): Remove duplicate prototype.
5288 * elf32-hppa.h (elf32_hppa_reloc_final_type): Add protptype.
5289 * elf32-hppa.c: Include elf32-hppa.h before elf-hppa.h.
5290 * elf64-hppa.h (elf64_hppa_reloc_final_type): Add protptype.
5291
e948afaf
AO
52922002-02-12 Alexandre Oliva <aoliva@redhat.com>
5293
5294 * elf-m10300.c (mn10300_elf_relax_section): Skip section before
5295 loading its contents if there's nothing to do in it.
5296
19397422
AM
52972002-02-12 Alan Modra <amodra@bigpond.net.au>
5298
0ad3a73b
AM
5299 * elf64-ppc.c (ppc64_elf_size_stubs): Correct test for crossing
5300 64k boundary.
5301
19397422
AM
5302 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Add dynamic
5303 DT_PPC64_OPD and DT_PPC64_OPDSZ tags.
5304 (ppc64_elf_finish_dynamic_sections): Set values for them.
5305
51316059
MS
53062002-02-11 Michael Snyder <msnyder@redhat.com>
5307
5308 * elf-bfd.h (elfcore_write_lwpstatus): Add prototype.
5309 * elf.c (elfcore_grok_pstatus): Add prototype.
5310 (elfcore_grok_lwpstatus): Add prototype.
5311 (elfcore_write_lwpstatus): New function.
5312 (elfcore_write_pstatus): Fix typo, eliminate unnecessary memcpy.
5313
518313c3
AO
53142002-02-11 Alexandre Oliva <aoliva@redhat.com>
5315
5316 * elf32-sh.c: Added missing prototypes.
5317 * elf32-sh64.c: Likewise.
5318 (sh_elf_align_loads): Mark unused args as such.
5319 * elf64-sh64.c: Added missing prototypes.
5320 (struct elf_sh64_link_hash_entry): Fix typo.
5321 (sh_elf64_relocate_section): Fix info argument passed to
5322 _bfd_elf_section_offset.
5323
2c73f9d8
AM
53242002-02-11 Alan Modra <amodra@bigpond.net.au>
5325
5326 * Makefile.am: "make dep-am".
5327 * Makefile.in: Regenerate.
5328 * aclocal.m4: Regenerate.
5329 * config.in: Regenerate.
5330 * configure: Regenerate.
5331
d426c6b0
DJ
53322002-02-10 Daniel Jacobowitz <drow@mvista.com>
5333
5334 * coff-rs6000.c (xcoff_generate_rtinit): Silence uninitialized
5335 variable warnings.
5336 * elf32-sh.c (sh_elf_relax_section): Silence signed/unsigned
5337 comparison warning.
5338 * trad-core.c (trad_unix_core_file_p): Silence pointer/integer
5339 cast warnings for the common case.
5340
e58ee0cd
HPN
53412002-02-10 Hans-Peter Nilsson <hp@bitrange.com>
5342
5343 * config.bfd (sh-*-linux*, sh-*-elf* | sh-*-rtemself*): Add sh64
5344 vectors.
5345 (sh-*-netbsdelf*): New, to trump sh*-*-netbsdelf* and add sh64
5346 vectors.
5347
7793f4d0
RH
53482002-02-09 Richard Henderson <rth@redhat.com>
5349
5350 * elf64-alpha.c (elf64_alpha_howto): Add R_ALPHA_BRSGP.
5351 (elf64_alpha_reloc_map, elf64_alpha_check_relocs): Likewise.
5352 (elf64_alpha_relocate_section): Likewise.
5353 * reloc.c (BFD_RELOC_ALPHA_BRSGP): New.
5354 * bfd-in2.h, libbfd.h: Rebuild.
5355
7e799044
HPN
53562002-02-09 Hans-Peter Nilsson <hp@bitrange.com>
5357
5358 * elf64-mmix.c (_bfd_mmix_finalize_linker_allocated_gregs): Check
5359 that base-plus-offset reloc accounting is consistent.
5360 (mmix_elf_relax_section): Keep base-plus-offset reloc accounting
5361 up to date for undefined symbols.
5362
027d73eb
EC
53632002-02-08 Eric Christopher <echristo@redhat.com>
5364
5365 From Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
5366
5367 * elf32-mips.c (_bfd_mips_elf_fake_sections): Don't create .rela
5368 sections for the O32 ABI.
5369
517662d4
CD
53702002-02-08 Chris Demetriou <cgd@broadcom.com>
5371
5372 * elf32-arm.h: Fix formatting of _("...").
5373 * elf32-d10v.c: Likewise.
5374 * elf32-m68k.c: Likewise.
5375 * elf32-mips.c: Likewise.
5376
5e37cc46
NC
53772002-02-08 Ivan Guzvinec <ivang@opencores.org>
5378
5379 * coff-or32.c: Fix compile time warning messages.
5380
fbca6ad9
AO
53812002-02-08 Alexandre Oliva <aoliva@redhat.com>
5382
5383 Contribute sh64-elf.
5384 2002-01-23 Alexandre Oliva <aoliva@redhat.com>
5385 * reloc.c (R_SH_GOTPLT32, R_SH_GOT_LOW16, R_SH_GOT_MEDLOW16,
5386 R_SH_GOT_MEDHI16, R_SH_GOT_HI16, R_SH_GOTPLT_LOW16,
5387 R_SH_GOTPLT_MEDLOW16, R_SH_GOTPLT_MEDHI16, R_SH_GOTPLT_HI16,
5388 R_SH_PLT_LOW16, R_SH_PLT_MEDLOW16, R_SH_PLT_MEDHI16,
5389 R_SH_PLT_HI16, R_SH_GOTOFF_LOW16, R_SH_GOTOFF_MEDLOW16,
5390 R_SH_GOTOFF_MEDHI16, R_SH_GOTOFF_HI16, R_SH_GOTPC_LOW16,
5391 R_SH_GOTPC_MEDLOW16, R_SH_GOTPC_MEDHI16, R_SH_GOTPC_HI16,
5392 R_SH_GOT10BY4, R_SH_GOTPLT10BY4, R_SH_GOT10BY8, R_SH_GOTPLT10BY8,
5393 R_SH_COPY64, R_SH_GLOB_DAT64, R_SH_JMP_SLOT64, R_SH_RELATIVE64):
5394 New relocs.
5395 * libbfd.h, bfd-in2.h: Rebuilt.
5396 * elf32-sh.c (sh_elf_howto_table): Define new relocs.
5397 (sh_reloc_map): Map them.
5398 (PLT_ENTRY_SIZE, elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
5399 elf_sh_plt_entry_be, elf_sh_plt_entry_le, elf_sh_pic_plt_entry_be,
5400 elf_sh_pic_plt_entry_le, elf_sh_plt0_entry, elf_sh_plt_entry,
5401 elf_sh_pic_plt_entry, elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
5402 elf_sh_plt0_gotplt_offset, elf_sh_plt_temp_offset,
5403 elf_sh_plt_symbol_offset, elf_sh_plt_reloc_offset,
5404 movi_shori_putval) [INCLUDE_SHMEDIA]: New.
5405 (elf_sh_link_hash_entry) [INCLUDE_SHMEDIA]: Add
5406 datalabel_got_offset.
5407 (sh_elf_link_hash_newfunc): Initialize it.
5408 (sh_elf_relocate_section): Augment the scope of
5409 seen_stt_datalabel. Introduce GOTPLT support. Extend GOTPC, PLT,
5410 GOT and GOTOFF handling to new SHmedia relocation types. Support
5411 GOT_BIAS.
5412 (sh_elf_check_relocs): Likewise.
5413 (sh_elf_finish_dynamic_symbol) [TARGET_SHMEDIA]: Set up values in
5414 PLT entries using movi_shori_putval. Support GOT_BIAS.
5415 (sh_elf_finish_dynamic_sections): Likewise.
5416 * elf32-sh64.c (shmedia_prepare_reloc): Do not add addend to
5417 relocation, it's now done by the caller.
5418 (GOT_BIAS): New.
5419 * elf64-sh64.c (GOT_BIAS, PLT_ENTRY_SIZE, elf_sh64_sizeof_plt,
5420 elf_sh64_plt_plt0_offset, elf_sh64_plt0_gotplt_offset,
5421 elf_sh64_plt_temp_offset, elf_sh64_plt_symbol_offset,
5422 elf_sh64_plt_reloc_offset, ELF_DYNAMIC_INTERPRETER,
5423 elf_sh64_pcrel_relocs_copied, elf_sh64_link_hash_entry,
5424 elf_sh64_link_hash_table, sh64_elf64_link_hash_traverse,
5425 sh64_elf64_hash_table): New.
5426 (sh_elf64_howto_table): Introduce new relocs.
5427 (sh_elf64_info_to_howto): Accept new PIC relocs.
5428 (sh_elf64_relocate_section): Augment the scope of
5429 seen_stt_datalabel. Support new PIC relocs.
5430 (sh_elf64_check_relocs): Support new PIC relocs.
5431 (elf_sh64_plt0_entry_be, elf_sh64_plt0_entry_le,
5432 elf_sh64_plt_entry_be, elf_sh64_plt_entry_le,
5433 elf_sh64_pic_plt_entry_be, elf_sh64_pic_plt_entry_le,
5434 elf_sh64_plt0_entry, elf_sh64_plt_entry, elf_sh64_pic_plt_entry,
5435 sh64_elf64_link_hash_newfunc, sh64_elf64_link_hash_table_create,
5436 movi_shori_putval, movi_3shori_putval,
5437 sh64_elf64_create_dynamic_sections,
5438 sh64_elf64_adjust_dynamic_symbol, sh64_elf64_discard_copies,
5439 sh64_elf64_size_dynamic_sections,
5440 sh64_elf64_finish_dynamic_symbol,
5441 sh64_elf64_finish_dynamic_sections): New.
5442 (elf_backend_create_dynamic-sections,
5443 bfd_elf64_bfd_link_hash_table_create,
5444 elf_backend_adjust_dynamic_symbol,
5445 elf_backend_size_dynamic_sections,
5446 elf_backend_finish_dynamic_symbol,
5447 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
5448 elf_backend_plt_readonly, elf_backend_want_plt_sym,
5449 elf_backend_got_header_size, elf_backend_plt_header_size):
5450 Define.
5451 2001-05-16 Alexandre Oliva <aoliva@redhat.com>
5452 * elf32-sh.c: Renumbered and renamed some SH5 relocations to
5453 match official numbers and names; moved unmaching ones to the
5454 range 0xf2-0xff.
5455 * elf32-sh64.c, elf64-sh64.c: Likewise.
5456 2001-03-12 DJ Delorie <dj@redhat.com>
5457 * elf32-sh.c (sh_elf_relax_section): Don't relax SHmedia
5458 sections.
5459 2001-03-12 DJ Delorie <dj@redhat.com>
5460 * elf32-sh64.c (shmedia_prepare_reloc): Validate relocs that must
5461 be aligned.
5462 * elf64-sh64.c (sh_elf64_relocate_section): Ditto.
5463 2001-01-14 Hans-Peter Nilsson <hpn@cygnus.com>
5464 * elf32-sh64.c (bfd_elf32_bfd_copy_private_section_data): Define.
5465 (sh64_elf_fake_sections): Set type to SHT_SH5_CR_SORTED for a
5466 .cranges section with SEC_SORT_ENTRIES set.
5467 (sh64_backend_section_from_shdr): Set SEC_SORT_ENTRIES on an
5468 incoming sorted .cranges section.
5469 (sh64_bfd_elf_copy_private_section_data): New.
5470 (sh64_elf_final_write_processing): Only sort .cranges and modify
5471 start address if called by linker.
5472 2001-01-08 Ben Elliston <bje@redhat.com>
5473 * elf32-sh64.c (sh64_elf_final_write_processing): Activate
5474 Hans-Peter Nilsson's set bit 0 patch from 2001-01-06.
5475 * elf64-sh64.c (sh64_elf64_final_write_processing): Ditto.
5476 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
5477 * elf64-sh64.c (sh_elf64_howto_table): No open brace at start of
5478 line. Add comments before all entries.
5479 <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct and clarify describing
5480 comment.
5481 (sh_elf64_reloc): Correct head comment.
5482 (sh_elf64_relocate_section): Correct spacing.
5483 <relocating for a local symbol>: Do not honour STO_SH5_ISA32;
5484 instead call reloc_dangerous callback.
5485 <case R_SH_SHMEDIA_CODE>: New case.
5486 (sh_elf64_gc_mark_hook): Correct spacing.
5487 (sh_elf64_check_relocs): Ditto.
5488 * elf32-sh64.c (shmedia_prepare_reloc) <case R_SH_SHMEDIA_CODE>:
5489 New case.
5490 * elf32-sh.c: Correct #endif comments for #ifndef-wrapped
5491 functions.
5492 (sh_elf_howto_table) <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct,
5493 clarify describing comment. Add comments before all entries.
5494 (sh_elf_relocate_section) <relocating for a local symbol>: Do not
5495 honour STO_SH5_ISA32; instead call reloc_dangerous callback.
5496 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
5497 Sort .cranges section in final link. Prepare to set bit 0 on
5498 entry address.
5499 * elf32-sh64.c (struct sh64_find_section_vma_data): New.
5500 (sh64_elf_link_output_symbol_hook): Fix typo in prototype.
5501 (sh64_elf_set_mach_from_flags): Set SEC_DEBUGGING on incoming
5502 .cranges section.
5503 (sh64_backend_section_from_shdr): New, to recognize
5504 SHT_SH5_CR_SORTED on incoming .cranges section.
5505 (elf_backend_section_from_shdr): Define.
5506 (sh64_elf_final_write_processing): Sort outgoing .cranges
5507 section. (New, temporarily disabled:) Set bit 0 on entry address
5508 according to ISA type.
5509 (sh64_find_section_for_address): New.
5510 (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb,
5511 crange_bsearch_cmpl): Move here from opcodes/sh64-dis.c.
5512 (sh64_address_in_cranges): Move here from opcodes/sh64-dis.c. Use
5513 bfd_malloc, not xmalloc.
5514 (sh64_get_contents_type): Move here from opcodes/sh64-dis.c. Make
5515 global.
5516 * elf32-sh64.c (sh64_elf64_final_write_processing): New, (but
5517 temporarily disabled) setting bit 0 on entry address.
5518 (elf_backend_final_write_processing): Define.
5519 2001-01-05 Hans-Peter Nilsson <hpn@cygnus.com>
5520 * elf32-sh.c (sh_elf_howto_table) <R_SH_PT_16>: Adjust fields to
5521 be a proper relocation for PTA and PTB rather than a marker.
5522 <R_SH_IMMU5, R_SH_IMMS6, R_SH_IMMU6, R_SH_IMMS10, R_SH_IMMS10BY2,
5523 R_SH_IMMS10BY4, R_SH_IMMS10BY8, R_SH_IMMS16, R_SH_IMMU16,
5524 R_SH_IMM_LOW16, R_SH_IMM_LOW16_PCREL, R_SH_IMM_MEDLOW16,
5525 R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16, R_SH_IMM_MEDHI16_PCREL,
5526 R_SH_IMM_HI16, R_SH_IMM_HI16_PCREL, R_SH_64, R_SH_64_PCREL>:
5527 Zero src_mask.
5528 * elf64-sh64.c: Ditto.
5529 (sh_elf64_relocate_section) <case R_SH_PT_16>: New case.
5530 * elf32-sh64.c: Include opcodes/sh64-opc.h
5531 (shmedia_prepare_reloc): Take a bfd_link_info pointer as first
5532 argument. Drop const qualifiers from "bfd *" and "bfd_byte *"
5533 parameters. No unused parameters. Caller changed.
5534 <case R_SH_PT_16>: New case.
5535 * Makefile.am (elf32-sh64.lo): Add dependency on sh64-opc.h.
5536 * Makefile.in: Regenerate.
5537 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
5538 * elf64-sh64.c (sh64_elf64_fake_sections): Set SHF_SH5_ISA32 for
5539 all code sections.
5540 (sh_elf64_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
5541 (sh64_elf_merge_private_data): Ditto.
5542 * elf32-sh64.c (sh64_elf_fake_sections): Use sh64_elf_section_data
5543 to access stored section flags.
5544 (sh64_elf_final_write_processing): Return immediately unless
5545 called by linker. Use sh64_elf_section_data (cranges) to get size
5546 of linker-generated cranges entries.
5547 (sh64_elf_copy_private_data): Add missing "return true".
5548 (sh64_elf_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
5549 (sh_elf64_merge_private_data): Ditto.
5550 2000-12-19 Hans-Peter Nilsson <hpn@cygnus.com>
5551 * elf64-sh64.c (sh64_elf64_fake_sections): New, copy of
5552 elf64-sh64.c:sh64_elf_fake_sections.
5553 (elf_backend_fake_sections): Define as sh64_elf64_fake_sections.
5554 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
5555 * elf32-sh64.c (sh64_elf_copy_private_data_internal): Delete.
5556 (sh64_elf_final_write_processing): New.
5557 (elf_backend_final_write_processing): Define.
5558 (sh64_elf_fake_sections): Get header flags from tdata field.
5559 (sh64_elf_copy_private_data): Do not call
5560 sh64_elf_copy_private_data_internal, just copy e_flags field.
5561 (sh64_elf_merge_private_data): Do not call
5562 sh64_elf_copy_private_data_internal.
5563 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
5564 Remove EF_SH64_ABI64, let ELF size make difference.
5565 Remove SH64-specific BFD section flag.
5566 * elf32-sh64.c (sh64_elf_fake_sections): Recognize section as
5567 containing SHmedia through elf_section_data (asect)->tdata
5568 non-zero, not using a BFD section flag.
5569 (sh64_elf_set_mach_from_flags): Don't recognize EF_SH64_ABI64.
5570 (sh64_elf_merge_private_data): Similar.
5571 (elf_backend_section_flags): Don't define.
5572 (sh64_elf_backend_section_flags): Delete.
5573 * elf64-sh64.c (sh_elf64_set_mach_from_flags): Recognize EF_SH64,
5574 not EF_SH64_ABI64.
5575 (sh_elf64_merge_private_data): Similar.
5576 * section.c (Section flags definitions): Don't define
5577 SEC_SH_ISA_SHMEDIA.
5578 (bfd-in2.h): Regenerate.
5579 2000-12-09 Hans-Peter Nilsson <hpn@cygnus.com>
5580 Make DataLabel references work with partial linking.
5581 * elf32-sh64.c: Fix formatting.
5582 (sh64_elf_link_output_symbol_hook): New.
5583 (elf_backend_link_output_symbol_hook): Define to
5584 sh64_elf_link_output_symbol_hook.
5585 (sh64_elf_add_symbol_hook): Make DataLabel symbol just global
5586 undefined if partial linking. Adjust sanity check.
5587 * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): New.
5588 (elf_backend_link_output_symbol_hook): Define to
5589 sh64_elf64_link_output_symbol_hook.
5590 (sh64_elf64_add_symbol_hook): Make DataLabel symbol just global
5591 undefined if partial linking. Adjust sanity check.
5592 2000-12-07 Hans-Peter Nilsson <hpn@cygnus.com>
5593 Implement semantics for inter-file DataLabel references.
5594 * elf64-sh64.c (DATALABEL_SUFFIX): Define.
5595 (sh64_elf64_add_symbol_hook): New.
5596 (sh_elf64_relocate_section): If passing an indirect symbol with
5597 st_type STT_DATALABEL on the way to a symbol with st_other
5598 STO_SH5_ISA32, do not bitor 1 to the relocation.
5599 (elf_backend_add_symbol_hook): Define to
5600 sh64_elf64_add_symbol_hook.
5601 * elf64-sh32.c: Tweak comments.
5602 (DATALABEL_SUFFIX): Define.
5603 (sh64_elf_add_symbol_hook): New.
5604 (elf_backend_add_symbol_hook): Define to sh64_elf_add_symbol_hook.
5605 * elf32-sh.c (sh_elf_relocate_section): If passing an indirect
5606 symbol with st_type STT_DATALABEL on the way to a symbol with
5607 st_other STO_SH5_ISA32, do not bitor 1 to the relocation.
5608 2000-12-05 Hans-Peter Nilsson <hpn@cygnus.com>
5609 Pass through STT_DATALABEL.
5610 * elf32-sh64.c (sh64_elf_get_symbol_type): New.
5611 (elf_backend_get_symbol_type): Define.
5612 * elf64-sh64.c (sh64_elf64_get_symbol_type): New.
5613 (elf_backend_get_symbol_type): Define.
5614 2000-11-30 Hans-Peter Nilsson <hpn@cygnus.com>
5615 * elf32-sh64.c: Tweak comments.
5616 (sh64_elf_copy_private_data_internal): Add prototype.
5617 (bfd_elf32_bfd_set_private_flags): Define.
5618 (sh64_elf_copy_private_data_internal): Compare machine name, not
5619 textual BFD target name, to check whether to copy section flag
5620 SHF_SH5_ISA32.
5621 (sh64_elf_merge_private_data): Validize bfd_get_arch_size.
5622 Tweak section-contents-type-mismatch message.
5623 (shmedia_prepare_reloc): Add ATTRIBUTE_UNUSED markers.
5624 Validize reloc-types.
5625 * elf64-sh64.c: New file.
5626 * targets.c (bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec): Declare.
5627 * Makefile.am (BFD64_BACKENDS): Add elf64-sh64.lo.
5628 (BFD64_BACKENDS_CFILES): Add elf64-sh64.c.
5629 Regenerate dependencies.
5630 * Makefile.in: Regenerate.
5631 * config.bfd (sh64-*-elf*): Add bfd_elf64_sh64_vec and
5632 bfd_elf64_sh64l_vec.
5633 * configure.in: Handle bfd_elf64_sh64_vec and
5634 bfd_elf64_sh64l_vec.
5635 * configure: Regenerate.
5636 * po/POTFILES.in: Regenerate.
5637 * po/bfd.pot: Regenerate.
5638 2000-11-29 Hans-Peter Nilsson <hpn@cygnus.com>
5639 * elf32-sh64.c (sh64_elf_set_mach_from_flags): Do not recognize
5640 anything else but EF_SH64 and EF_SH64_ABI64.
5641 (sh64_elf_merge_private_data): Emit error for anything else but
5642 EF_SH64 and EF_SH64_ABI64.
5643 * config.bfd: Remove bfd_elf32_shblin_vec and bfd_elf32_shlin_vec
5644 from targ_selvecs.
5645 * configure.in: Add cofflink.lo to bfd_elf32_sh64_vec and
5646 bfd_elf32_sh64l_vec as a temporary measure.
5647 * configure: Regenerate.
5648 2000-11-27 Hans-Peter Nilsson <hpn@cygnus.com>
5649 * cpu-sh.c (arch_info_struct): Include sh5 item
5650 unconditionalized.
5651 * config.bfd (sh64-*-elf*): Do not set targ_cflags.
5652 Add targ_selvecs bfd_elf32_sh_vec, bfd_elf32_shl_vec,
5653 bfd_elf32_shblin_vec and bfd_elf32_shlin_vec.
5654 * elf32-sh64.c: Tweak comments.
5655 (sh64_elf_set_mach_from_flags): Recognize all machine flags that
5656 are proper subsets of SH64 as bfd_mach_sh5. Add EF_SH64_ABI64.
5657 (sh64_elf_copy_private_data_internal): Wrap long line.
5658 (sh64_elf_merge_private_data): Rewrite to allow objects from
5659 SH64 subsets to be linked together.
5660 (INCLUDE_SHMEDIA): Define.
5661 * elf32-sh.c (sh_elf_relocate_section) <local symbol>:
5662 Parenthesize plus-expression inside or-expression.
5663 <global symbol>: Ditto.
5664 (sh_elf_set_mach_from_flags): Remove code refusing
5665 deleted EF_SH64_32BIT_ABI flag.
5666 2000-11-26 Hans-Peter Nilsson <hpn@cygnus.com>
5667 * elf32-sh.c (sh_elf_howto_table) <R_SH_IMM_LOW16_PCREL,
5668 R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16_PCREL,
5669 R_SH_IMM_HI16_PCREL, R_SH_64_PCREL>: Set pcrel_offset to true.
5670 (sh_elf_relocate_section) <local symbol>: Or 1 in
5671 calculation of relocation if sym->st_other & STO_SH5_ISA32.
5672 <global symbol>: Ditto if h->other & STO_SH5_ISA32.
5673 * elf32-sh64.c (shmedia_prepare_reloc): Add rel->r_addend to
5674 relocation.
5675 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
5676 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64.lo.
5677 (BFD32_BACKENDS_CFILES): Add elf32-sh64.c.
5678 Regenerate dependencies.
5679 * Makefile.in: Regenerate.
5680 * archures.c: Add bfd_mach_sh5.
5681 * config.bfd: Map targ_cpu sh* to bfd_sh_arch.
5682 Handle sh64-*-elf*. Set targ_cflags to -DINCLUDE_SHMEDIA.
5683 * configure.in: Handle bfd_elf32_sh64_vec and bfd_elf32_sh64l_vec.
5684 * configure: Regenerate.
5685 * reloc.c (BFD_RELOC_SH_SHMEDIA_CODE, BFD_RELOC_SH_IMMU5,
5686 BFD_RELOC_SH_IMMS6, BFD_RELOC_SH_IMMS6BY32, BFD_RELOC_SH_IMMU6,
5687 BFD_RELOC_SH_IMMS10, BFD_RELOC_SH_IMMS10BY2,
5688 BFD_RELOC_SH_IMMS10BY4, BFD_RELOC_SH_IMMS10BY8,
5689 BFD_RELOC_SH_IMMS16, BFD_RELOC_SH_IMMU16, BFD_RELOC_SH_IMM_LOW16,
5690 BFD_RELOC_SH_IMM_LOW16_PCREL, BFD_RELOC_SH_IMM_MEDLOW16,
5691 BFD_RELOC_SH_IMM_MEDLOW16_PCREL, BFD_RELOC_SH_IMM_MEDHI16,
5692 BFD_RELOC_SH_IMM_MEDHI16_PCREL, BFD_RELOC_SH_IMM_HI16,
5693 BFD_RELOC_SH_IMM_HI16_PCREL, BFD_RELOC_SH_PT_16): New relocations.
5694 * cpu-sh.c [INCLUDE_SHMEDIA] (arch_info_struct): Define and link
5695 in item for SH5.
5696 * elf32-sh.c [INCLUDE_SHMEDIA] (sh_elf_howto_table): Add howto items
5697 for SHmedia relocs.
5698 [INCLUDE_SHMEDIA] (sh_rel): Add mappings for SHmedia relocs.
5699 [INCLUDE_SHMEDIA] (sh_elf_relocate_section) [default]: Call
5700 shmedia_prepare_reloc, goto final_link_relocate if it returns
5701 non-zero, else fail as before.
5702 (sh_elf_set_mach_from_flags): Provide function only if not defined
5703 as macro. Do not recognize objects with EF_SH64_32BIT_ABI set.
5704 (sh_elf_set_private_flags): Provide function only if not defined
5705 as a macro.
5706 (sh_elf_copy_private_data): Similar.
5707 (sh_elf_merge_private_data): Similar.
5708 * section.c (SEC_SH_ISA_SHMEDIA): New.
5709 * targets.c (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec): Declare.
5710 * elf32-sh64.c: New file.
5711 * libbfd.h: Regenerate.
5712 * bfd-in2.h: Regenerate.
5713 * po/POTFILES.in: Regenerate.
5714 * po/bfd.pot: Regenerate.
5715 * bfd-in2.h: Regenerate.
5716 * libbfd.h: Regenerate.
5717
e108f470
DJ
57182002-02-07 Daniel Jacobowitz <drow@mvista.com>
5719
5720 * bfd-in.h: Update <stdbool.h> check to only see if <stdbool.h> has
5721 been included, not drag it in.
5722 * bfd-in2.h: Regenerate.
5723
259d18a3
L
57242002-02-06 H.J. Lu (hjl@gnu.org)
5725
5726 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Update
5727 the mach and ISA fields if necessary.
5728
f13b834e
NC
57292002-02-06 Nick Clifton <nickc@cambridge.redhat.com>
5730
5731 * coffcode.h (coff_set_arch_mach_hook): Select the highest known
5732 ARM architecture when an F_ARM_5 flag is detected, since we cannot
5733 be sure exactly which architecture this represents.
5734
82f6addb
NC
57352002-02-05 Nick Clifton <nickc@redhat.com>
5736
5737 * po/tr.po: Updated translation.
5738
899f54f5
AM
57392002-02-05 Alan Modra <amodra@bigpond.net.au>
5740
5741 From Jimi X <jimix@watson.ibm.com>
5742 * archures (bfd_mach_ppc64): Define.
5743 (bfd_powerpc_arch): Rename to bfd_powerpc_archs.
5744 (bfd_powerpc_arch): Define.
5745 * bfd-in2.h: Regenerate.
5746 * cpu-powerpc.c (arch_info_struct): Rename to bfd_powerpc_archs.
5747 (bfd_powerpc_arch): Move to tail of bfd_powerpc_archs.
5748 (bfd_powerpc_archs): Add default powerpc64 arch.
5749
248866a8
AM
57502002-02-05 Alan Modra <amodra@bigpond.net.au>
5751
5752 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Check for relocs
5753 against section syms in readonly sections. Don't do the global
5754 sym check if we find one.
5755 * elf64-s390.c (elf_s390_size_dynamic_sections): Likewise.
5756 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Likewise.
0a6958db 5757 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
248866a8
AM
5758 * elf32-s390.c (elf_s390_size_dynamic_sections): Likewise.
5759 (elf_s390_grok_prstatus): Add missing prototype.
5760
4fa5c2a8
HPN
57612002-02-04 Hans-Peter Nilsson <hp@bitrange.com>
5762
5763 * elf64-mmix.c (mmix_dump_bpo_gregs): New function.
5764 (mmix_elf_check_common_relocs) <case R_MMIX_BASE_PLUS_OFFSET>:
5765 Call bfd_get_section_by_name only once. Initialize
5766 bpodata->n_bpo_relocs_this_section.
5767 (_bfd_mmix_prepare_linker_allocated_gregs): Remove comment
5768 referring to DSOs.
5769 (bpo_reloc_request_sort_fn): Don't use difference of values as
5770 return-value.
5771
537c972e
DB
57722002-02-02 David O'Brien <obrien@FreeBSD>
5773
5774 * configure.in: Tweak the FreeBSD 4.x recognition more. Only treat
5775 version 4.5 and later the same as 5-CURRENT.
5776 * configure: Re-generate.
5777
006336b8
JT
57782002-02-02 Jason Thorpe <thorpej@wasabisystems.com>
5779
5780 * config.bfd (hppa*-*-netbsd*): New target.
5781
6c571f00
PT
57822002-01-31 Philipp Thomas <pthomas@suse.de>
5783
19397422
AM
5784 * coff-arm.c (coff_arm_merge_private_bfd_data): Move ERROR
5785 to front of message. Unify messages with elf32-arm.h. Use
5786 commas where neccessary.
5787 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Use all upcase
5788 ERROR in messages. Unify messages with coff-arm.c. Correct
5789 VFP/FPA error message.
5790 (elf32_arm_print_private_bfd_data): Don't mark APCS-26 and
5791 APCS-32 for translation.
6c571f00 5792
930b4cb2
HPN
57932002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
5794
5795 Perform on-demand global register allocation from
5796 R_MMIX_BASE_PLUS_OFFSET relocs.
5797 * elf64-mmix.c (struct bpo_reloc_section_info, struct
5798 bpo_reloc_request, struct bpo_greg_section_info): New.
5799 (mmix_elf_check_common_relocs, mmix_elf_gc_sweep_hook,
5800 bpo_reloc_request_sort_fn, mmix_elf_relax_section,
5801 _bfd_mmix_check_all_relocs,
5802 _bfd_mmix_prepare_linker_allocated_gregs,
5803 _bfd_mmix_finalize_linker_allocated_gregs): New functions.
5804 (elf_mmix_howto_table): Correct src_mask for most relocs.
5805 (mmix_elf_perform_relocation) <case R_MMIX_BASE_PLUS_OFFSET>: New
5806 case.
5807 (mmix_final_link_relocate) <case R_MMIX_BASE_PLUS_OFFSET>: New
5808 case. Fix typo in comment. New label do_mmix_reloc.
5809 (mmix_elf_check_relocs): Abuse bfd_link_info member base_file to
5810 store first object file with a base-plus-offset reloc. Call
5811 mmix_elf_check_common_relocs for the part common with mmo.
5812 (mmix_elf_final_link): Write out linker-allocated register
5813 contents section.
5814 (elf_backend_gc_sweep_hook): Define.
5815 (bfd_elf64_bfd_relax_section): Define.
5816
5817 * mmo.c: Don't include <ctype.h>
5818 (mmo_init): Correct init-once logic.
5819
3e36d993
TR
58202002-02-01 Tom Rix <trix@redhat.com>
5821
5822 * config.bfd: Conditionally support <aiaff> for pre AIX 4.3.
5823
ba323545
AM
58242002-02-01 Alan Modra <amodra@bigpond.net.au>
5825
5826 * Makefile.am: Run "make dep-am"
5827 * Makefile.in: Regenerate.
5828
012884d6
DB
58292002-01-31 David O'Brien <obrien@FreeBSD>
5830
5831 * configure.in: Recognize the differences in core files from FreeBSD
5832 4.{0,1} and later versions of 4.x. This treats 4.2+ the same as
5833 5-CURRENT.
5834 * configure: Regenerate.
5835
3b16e843
NC
58362002-01-31 Ivan Guzvinec <ivang@opencores.org>
5837
5838 * coff-or32.c: New file.
5839 * cpu-or32.c: New file.
5840 * elf32-or32.c: New file.
5841 * archures.c: Add support for or32.
5842 * targets.c: Add support for or32.
5843 * bfd-in2.h: Regenerate.
7dc0ab31 5844 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags,
3b16e843
NC
5845 coff_write_object_contents): Add support for or32.
5846 * config.bfd: Add target.
5847 * configure.in: Add support for or32.
5848 * configure: Regenerate.
5849 * Makefile.am: Add support for or32.
5850 * Makefile.in: Regenerate.
3b16e843
NC
5851 * po/SRC-POTFILES.in: Add or32 files.
5852 * po/bfd.pot: Regenerate.
7dc0ab31 5853
caf8ca8e
NC
58542002-01-31 Nick Clifton <nickc@cambridge.redhat.com>
5855 Don Lindsay <lindsayd@cisco.com>
5856
5857 * elf32-mips.c (mips_elf_calculate_relocation): Replace 'return
5858 false' with a return of a bfd_reloc_ error code.
5859
e5dfef09
HPN
58602002-01-31 Hans-Peter Nilsson <hp@axis.com>
5861
5862 * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Don't
5863 unexport unreferenced symbols when --export-dynamic. Call
5864 _bfd_elf_strtab_delref when unexporting.
5865
4e4770d0
DJ
58662002-01-30 Daniel Jacobowitz <drow@mvista.com>
5867
5868 * bfd-in.h: Include <stdbool.h> if it is available.
5869 * bfd-in2.h: Regenerated.
5870
e1fa50e7
AM
58712002-01-31 Alan Modra <amodra@bigpond.net.au>
5872
5873 * elf64-ppc.c (func_desc_adjust): STV_PROTECTED functions should
5874 not go via the plt.
5875
b5f79c76
NC
58762002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
5877
b5f79c76
NC
5878 * archures.c: Tidy up formatting of embedded comments.
5879 * bfd.c: Tidy up formatting of embedded comments.
7dc0ab31 5880 * bfd-in.h: Fix formatting of comments.
b5f79c76
NC
5881 * reloc.c: Tidy up formatting of ordinary & embedded comments.
5882 * section.c: Tidy up formatting of embedded comments.
5883 * syms.c: Tidy up formatting of embedded comments.
5884 * targets.c: Tidy up formatting of embedded comments.
5885
5886 * bfd-in2.h: Regenerate.
5887
ca09e32b
NC
58882002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
5889
5890 * vms-tir.c (cmd_name): New function.
5891 (tir_cmd_name): New function.
5892 (etir_sta, etir_sto, etir_opr, etir_stc): Use cmd_name().
5893 (tir_opr, tir_ctl, tir_cmd): use tir_cmd_name().
5894 Fix formatting.
7dc0ab31 5895
ca09e32b
NC
5896 * peXXigen.c (pe_print_idata): Rearrange message to aid in
5897 translation.
5898 (pe_print_pdata): Rearrange message to aid in translation.
5899
5900 * libbfd.c (warn_deprecated): Rearrange error message to aid in
5901 translation.
5902
5903 * ihex.c (ihex_write_object_contents): Fix spelling typo.
5904
5905 * ieee.c (ieee_slurp_external_symbols): Remove spurious space.
5906
5907 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Rearrange error
5908 message to aid in translation.
5909
5910 * elf64-mmix.c (mmix_final_link_relocate): Rearrange error message
5911 to aid in translation.
5912
5913 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix typo.
5914
7dc0ab31 59152002-01-30 Philipp Thomas <pthomas@suse.de>
ae1a89b7
PT
5916
5917 * coff-arm.c, elf32-elf.h: Unify messages.
5918
05f64ac6
NC
59192002-01-30 Nick Clifton <nickc@redhat.com>
5920
5921 * po/sv.po: Updated translation.
5922
f5a3e38a
NC
59232002-01-30 Philipp Thomas <pthomas@suse.de>
5924
5925 * dwarf2.c (read_abbrev): Use full section name in error message.
5926 (decode_line_info): Likewise.
661a3fd4
NC
5927
5928 * elf.c (_bfd_elf_symbol_from_bfd_symbol): Don't translate debugging
5929 message.
5930
d926e03d
AM
59312002-01-30 Alan Modra <amodra@bigpond.net.au>
5932
5933 * elf64-ppc.c (func_desc_adjust): Only provide missing function
5934 descriptor symbols for undefined function code syms. Clear
5935 ELF_LINK_NON_ELF so that they can stay weak.
5936
030d18fb 59372002-01-29 Chris Demetriou <cgd@broadcom.com>
7dc0ab31 5938 Mitch Lichtenberg <mpl@broadcom.com>
030d18fb
CD
5939
5940 * bfd-in.h (bfd_mips_elf32_create_embedded_relocs): New prototype.
5941 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): New function
5942 to handle 32-bit ELF embedded reloc (ld --embedded-relocs)
5943 generation.
5944 * bfd-in2.h: Regenerate.
5945
fcc76bea
CD
59462002-01-29 Chris Demetriou <cgd@broadcom.com>
5947
5948 * elf32-mips.c: Add additional comments about HI16 relocation
5949 processing.
5950 (_bfd_mips_elf_hi16_reloc): Don't subtract address here for
5951 pc-relative relocations. (Reverts change made on 2001-10-31.)
5952 (_bfd_mips_elf_lo16_reloc): Subtract address of LO16 part here
5953 for pc-relative relocations.
5954 (mips_elf_calculate_relocation): Add a comment about a kludge
5955 in the R_MIPS_GNU_REL_HI16 handling.
5956 (_bfd_mips_elf_relocate_section): Implement that kludge;
5957 adjust pc-relative HI16 relocation for difference in HI16 and
5958 LO16 addresses, since it can't easily be done in
5959 mips_elf_calculate_relocation.
5960
f9cd9119
MS
59612002-01-29 Martin Schwidefsky <schwidefsky@de.ibm.com>
5962
5963 * elf32-i386 (elf_i386_adjust_dynamic_symbol): Do not replace PLT32
5964 relocations with PC32 relocations for undefined or weak symbols.
5965 * elf32-s390 (elf_i386_adjust_dynamic_symbol): Likewise.
5966 * elf64-s390x (elf_i386_adjust_dynamic_symbol): Likewise.
5967
702248bb
JT
59682002-01-28 Jason Thorpe <thorpej@wasabisystems.com>
5969
5970 * elfcore.h (elf_core_file_p): Improve comment for last change.
5971
4867be41
DJ
59722002-01-27 Daniel Jacobowitz <drow@mvista.com>
5973
5974 * configure: Regenerated.
5975
a94cef6a
JT
59762002-01-27 Jason Thorpe <thorpej@wasabisystems.com>
5977
5978 * elfcore.h (elf_core_file_p): Set the machine architecture
5979 before processing the program headers.
5980
7562a296
HPN
59812002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
5982
966abd70
HPN
5983 * configure.in <64-bit configuration>: If using gcc, check and
5984 emit error for egcs-1.1.2.
5985 * configure: Regenerate.
5986
e8eab623
NC
59872002-01-26 Egor Duda <deo@logos-m.ru>
5988
5989 * elf.c (elfcore_grok_win32pstatus): Copy only as much information
5990 as possible to avoid stack corruption.
5991
73896efb
RH
59922002-01-26 Richard Henderson <rth@redhat.com>
5993
5994 * elf64-alpha.c (elf64_alpha_check_relocs): Don't set reltext
5995 for non-allocated sections.
5996
59972002-01-25 Mark Kettenis <kettenis@gnu.org>
c106e334
MK
5998
5999 * elf.c (elfcore_write_prstatus): Make sure we pass the address of
6000 prstat.pr_reg even if it is a struct.
6001
73896efb 60022002-01-25 Steve Ellcey <sje@cup.hp.com>
254ed743 6003
c5cd6d62 6004 * elfxx-ia64.c: Reset AIX vector function overrides for HP-UX.
254ed743 6005
3d66c4f7
NC
60062002-01-25 Philipp Thomas <pthomas@suse.de>
6007
6008 * coffgen.c (coff_print_symbol): Don't mark info message
6009 for translation.
6010
9460ecda
NC
60112002-01-25 Nick Clifton <nickc@redhat.com>
6012
6013 * po/fr.po: Updated translation.
6014 * po/es.po: Updated translation.
6015
cc9ff76a
AM
60162002-01-25 Philipp Thomas <pthomas@suse.de>
6017
6018 * coff-alpha.c (alpha_relocate_section): Unify warning message
6019 for GP relative relocations without GP defined.
6020 * coff-mips.c (mips_relocate_section): Likewise.
6021
c68836a9
AM
60222002-01-25 Alan Modra <amodra@bigpond.net.au>
6023
6024 * elf-eh-frame.c (_bfd_elf_eh_frame_section_offset): Avoid
6025 unsigned overflow when new_offset < old_offset.
6026
e8eab623 60272002-01-24 Philipp Thomas <pthomas@suse.de>
391154e9
NC
6028
6029 * bfd.c (_bfd_abort): Fix typo.
6030
8ba89f17
RH
60312002-01-23 Richard Henderson <rth@redhat.com>
6032
6033 * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't suppress
6034 plt entries for undefweak symbols.
6035
c6953948
NC
60362002-01-23 Steve Ellcey <sje@cup.hp.com>
6037
c5cd6d62 6038 * targets.c (bfd_elf32_ia64_hpux_big_vec): Add to DEFAULT_VECTOR.
c6953948
NC
6039 (bfd_elf64_ia64_hpux_big_vec): Ditto.
6040 (bfd_elf32_h8300_vec): Ditto.
6041
41bd81ab
AM
60422002-01-23 Alan Modra <amodra@bigpond.net.au>
6043
6044 * elf64-ppc.c: Remove stale part of ABI comment.
6045 (NO_OPD_RELOCS): Define.
6046 (ppc64_elf_check_relocs): Use it.
6047 (ppc64_elf_relocate_section): Here too.
6048 (build_one_stub): Don't point function syms at the stub. Instead,
6049 hijack plt.offset.
6050 (ppc64_elf_relocate_section): Check whether REL24 relocs should
6051 really go to the stub. Make all dynamic relocs in opd against
6052 locals.
6053 (ppc64_elf_finish_dynamic_symbol): Allow for non-standard use of
6054 plt.offset.
6055
f304919d
RH
60562002-01-22 Richard Henderson <rth@redhat.com>
6057
6058 * elf64-alpha.c (INSN_UNOP): Encode with RB as $sp.
6059
c0ef99a7
AM
60602002-01-22 Alan Modra <amodra@bigpond.net.au>
6061
60ee0d4a
AM
6062 * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Correct sign of
6063 TOC_BASE_OFF adjustment.
6064
c0ef99a7
AM
6065 * Makefile.am: Run "make dep-am".
6066 * Makefile.in: Regenerate.
6067 * po/SRC-POTFILES.in: Regenerate.
6068
64328b46
AM
60692002-01-22 John David Anglin <dave@hiauly1.hia.nrc.ca>
6070
6071 * configure.host (hppa*64*-*-hpux*, hppa*64*-*-linux*): Add new
6072 host defines.
6073
59953665 60742002-01-21 Hans-Peter Nilsson <hp@axis.com>
58255df3
HPN
6075
6076 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_32_GOTREL>:
6077 Check for and emit error if sgot is NULL at this point.
6078
9596feea
JT
60792002-01-21 Jason Thorpe <thorpej@wasabisystems.com>
6080
6081 * config.bfd (ia64*-*-netbsd*): New target.
6082
7b45c6e1
AM
60832002-01-21 Thomas Klausner <wiz@danbala.ifoer.tuwien.ac.at>
6084
6085 * som.c (som_write_space_strings): Comment typo fix.
6086
e5094212
AM
60872002-01-21 Alan Modra <amodra@bigpond.net.au>
6088
e86ce104
AM
6089 * elf64-ppc.c (struct ppc_link_hash_entry): Add is_func and
6090 is_func_descriptor fields.
6091 (link_hash_newfunc): Init them.
6092 (ppc64_elf_check_relocs): Only R_PPC24_REL24 syms starting with a
6093 dot are candidates for plt entries. When processing .opd relocs,
6094 set function descriptor strings to point inside function code
6095 string, and set new ppc_link_hash_entry fields.
6096 (ppc64_elf_gc_sweep_hook): Don't sweep R_PPC64_REL24 relocs.
6097 (ppc64_elf_adjust_dynamic_symbol): Remove most code dealing with
6098 function descriptors. It's now done in..
6099 (func_desc_adjust): New.
6100 (ppc64_elf_func_desc_adjust): New.
6101 (define elf_backend_always_size_sections): Define.
6102 (ppc64_elf_hide_symbol): New.
6103 (define elf_backend_hide_symbol): Define.
6104 (allocate_dynrelocs): Remove code looking up function descriptors
6105 as that has been done earlier.
6106 (ppc64_elf_size_dynamic_sections): Use htab shortcut to elf hash
6107 table.
6108 (ppc64_elf_finish_dynamic_symbol): Likewise. Remove code looking
6109 up function descriptor.
6110 (build_one_stub): Look up the function code sym. Check for
6111 invalid plt offsets.
6112 (ppc64_elf_relocate_section): Tweak calls to undefined weak syms.
6113 Convert R_PPC64_TOC relocs to R_PPC64_RELATIVE in shared libs.
6114
e5094212
AM
6115 * elf-bfd.h (elf_backend_data <elf_backend_hide_symbol>): Add
6116 boolean param.
6117 (_bfd_elf_link_hash_hide_symbol): Likewise.
6118 * elflink.h (elf_link_add_object_symbols): Adjust call to
6119 elf_backend_hide_symbol.
6120 (elf_fix_symbol_flags): Likewise.
6121 (elf_link_assign_sym_version): Likewise. Use bfd_malloc rather
6122 than bfd_alloc.
6123 * elf.c (_bfd_elf_link_hash_hide_symbol): Add "force_local" param.
6124 Set ELF_LINK_FORCED_LOCAL and call _bfd_elf_strtab_delref.
6125 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
6126 (clobber_millicode_symbols): Adjust to suit new hide_symbol.
6127 * elf32-cris.c (elf_cris_hide_symbol): Add "force_local" param
6128 and adjust to suit.
6129 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise, and call
6130 _bfd_elf_link_hash_hide_symbol rather than duplicating code.
6131 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
6132
40b8271b
AM
61332002-01-18 Alan Modra <amodra@bigpond.net.au>
6134
6135 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Test for a
6136 dynamic function descriptor symbol, not the associated function
6137 symbol.
6138
55baa95b
EC
61392002-01-17 Eric Christopher <echristo@redhat.com>
6140
6141 * elf32-mips.c (mips_elf_calculate_relocation): Fix typo.
6142
328577ad
NC
61432002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
6144
6145 * po/bfd.pot: Regenerate.
6146 * po/fr.po: Regenerate.
6147
af746e92
AM
61482002-01-17 Alan Modra <amodra@bigpond.net.au>
6149
6150 * elf-bfd.h (elf_backend_data <elf_backend_section_from_bfd_section>):
6151 Remove "Elf_Internal_Shdr *" param.
6152 (_bfd_mips_elf_section_from_bfd_section): Ditto.
6153 * elf32-mips.c (_bfd_mips_elf_section_from_bfd_section): Ditto.
6154 * elf32-m32r.c (_bfd_m32r_elf_section_from_bfd_section): Ditto.
6155 * elf32-v850.c (v850_elf_section_from_bfd_section): Ditto.
6156 * elf64-mmix.c (mmix_elf_section_from_bfd_section): Ditto.
6157 * elfxx-ia64.c (elfNN_hpux_backend_section_from_bfd_section): Ditto.
6158 * elf.c (_bfd_elf_section_from_bfd_section): Allow backend
6159 function to override special sections. Remove hdr arg from
6160 backend call, and don't loop.
6161
175e9962
EC
61622002-01-16 Eric Christopher <echristo@redhat.com>
6163
6164 * elf32-mips.c (mips_elf_calculate_relocation): Set require_jalxp
6165 on R_MIPS_26 and target is 16bit. Add R_MIPS16_GPREL to list of
6166 relocations requiring gp0 and gp.
6167
96a846ea
RE
61682002-01-16 Richard Earnshaw <rearnsha@arm.com>
6169
175e9962 6170 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Handle
96a846ea
RE
6171 EF_ARM_VFP_FLOAT.
6172 (elf32_arm_print_private_bfd_data): Likewise.
6173
af3ae48d
NC
61742002-01-16 Nick Clifton <nickc@cambridge.redhat.com>
6175
6176 * po/tr.po: Import new version.
6177
10ed1bba
AM
61782002-01-16 Alan Modra <amodra@bigpond.net.au>
6179
6180 * elf64-ppc.c (ppc64_elf_howto_raw): Remove stale FIXMEs.
6181 (ppc64_elf_reloc_type_lookup): Use proper CTOR reloc.
6182 (ORI_R0_R0_0): Correct.
6183
5d1634d7
AM
61842002-01-16 Alan Modra <amodra@bigpond.net.au>
6185
6186 * elflink.c (_bfd_elf_create_dynamic_sections): Don't set SEC_CODE
6187 when plt_not_loaded.
6188 * elf64-ppc.c (ppc64_elf_create_dynamic_sections): No need to
6189 clear .plt SEC_CODE here. Create .stub and correct .glink flags.
6190 (PLT_INITIAL_ENTRY_SIZE): Set to 24.
6191 (ppc64_elf_glink_code): Delete.
6192 (PPC64_ELF_GLINK_SIZE): Delete.
6193 (ADDIS_R12_R2, STD_R2_40R1, LD_R11_0R12, LD_R2_0R12, MTCTR_R11,
6194 BCTR, ADDIS_R12_R12_1, LD_R2_40R1, NOP, LI_R0_0, B_DOT, LIS_R0_0,
6195 ORI_R0_R0_0): Define.
6196 (PLT_CALL_STUB_SIZE, GLINK_CALL_STUB_SIZE): Define.
6197 (struct ppc_link_hash_table): Add sstub and plt_overflow.
6198 (ppc64_elf_link_hash_table_create): Init them.
6199 (ppc64_elf_check_relocs <R_PPC64_REL24>): Refcount .plt entry.
6200 Don't copy to shared lib.
6201 (ppc64_elf_check_relocs): Call bfd_set_error on errors.
6202 (ppc64_elf_gc_sweep_hook <R_PPC64_REL24>): Sweep plt refcount.
6203 (allocate_dynrelocs <plt>): Don't change function sym here. Make
6204 room for .stub and .glink code.
6205 (ppc64_elf_size_dynamic_sections): Handle .stub. Make entry for
6206 DT_PPC64_GLINK.
6207 (ppc64_elf_final_link): Rename to ppc64_elf_set_toc. Don't call
6208 bfd_elf64_bfd_final_link.
6209 (bfd_elf64_bfd_final_link): Don't define.
6210 (ppc64_elf_size_stubs): New.
6211 (build_plt_stub): New.
6212 (build_one_stub): New.
6213 (ppc64_elf_build_stubs): New.
6214 (ppc64_elf_relocate_section <toc relocs>): Remove assert.
6215 (ppc64_elf_relocate_section): Don't copy R_PPC64_REL24 relocs.
6216 (ppc64_elf_finish_dynamic_symbol): Don't build stubs here. Set
6217 DT_PPC64_GLINK entry. Tweak DT_PLTGOT, DT_JMPREL, DT_PLTRELSZ in
6218 case output sections not separate. Adjust DT_RELASZ to not
6219 include plt relocs. Set reserved got entry. Set got and plt
6220 entry size.
6221 (elf_backend_got_header_size): Set to 8.
6222 * elf64-ppc.h: New file.
6223
c601ffdb
AM
62242002-01-16 Alan Modra <amodra@bigpond.net.au>
6225
6226 * elf32-arm.h (elf32_arm_size_dynamic_sections): When removing
6227 sections, use bfd_section_list_remove.
6228 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
6229 * elflink.h (elf_link_add_object_symbols): When removing all
6230 sections, use bfd_section_list_clear.
6231
8fb4cb7f
NC
62322002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
6233
6234 * po/sv.po: New file: Swedish translation.
6235 * configure.in (ALL_LINGUAS): Add sv.
6236 * configure: Regenerate.
6237
d3c456e9
JJ
62382002-01-15 Jakub Jelinek <jakub@redhat.com>
6239
6240 * elflink.h (elf_link_input_bfd): Back out 2002-01-07 change.
6241 * elf.c (merge_sections_remove_hook): New function.
6242 (_bfd_elf_merge_sections): Pass it as 3rd argument to
6243 _bfd_merge_sections.
6244 * libbfd-in.h (_bfd_merge_sections): Add 3rd argument.
6245 * libbfd.h: Rebuilt.
6246 * merge.c (_bfd_merge_sections): Add remove_hook argument.
6247 Call remove_hook if a SEC_EXCLUDE section is encountered.
6248
1f7fd478
NC
62492002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
6250
6251 * elf32-xstormy16.c (xstormy16_reloc_map): Add new field 'table'.
6252 (xstormy16_reloc_map): Initialise new field with correct howto
6253 table.
6254 (xstormy16_reloc_type_lookup): Use 'table' field to locate correct
6255 howto entry.
6256
b87011e9
MS
62572002-01-10 Michael Snyder <msnyder@redhat.com>
6258
6259 * elf.c (elfcore_write_prstatus): Use long instead of pid_t;
6260 (elfcore_write_pstatus): Use long instead of pid_t;
6261 * elf-bfd.h: Change prototypes to use long instead of pid_t;
6262
175e9962 62632002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
b4db1224
JT
6264
6265 * elf.c: Update copyright years.
6266 (elfcore_grok_netbsd_note): Use NT_NETBSDCORE_PROCINFO
6267 and NT_NETBSDCORE_FIRSTMACH. Improve a comment.
6268
7c76fa91
MS
62692002-01-08 Michael Snyder <msnyder@redhat.com>
6270
6271 Add capability to write corefile note sections, for gdb.
6272 * elf.c (elfcore_write_note): New function.
6273 (elfcore_write_prpsinfo): New function.
6274 (elfcore_write_prstatus): New function.
6275 (elfcore_write_pstatus): New function.
6276 (elfcore_write_prfpreg): New function.
6277 (elfcore_write_prxfpreg): New function.
97996af6 6278 * elf-bfd.h: Add prototypes for above functions.
7c76fa91 6279
e1fddb6b
AO
62802002-01-08 Alexandre Oliva <aoliva@redhat.com>
6281
6282 * elf.c (elf_fake_sections): Propagate errors from
6283 elf_backend_fake_section.
6284
8d05742f
JT
62852002-01-07 Jason Thorpe <thorpej@wasabisystems.com>
6286
6287 * Makefile.am (BFD32_BACKENDS): Add elf32-sh-nbsd.lo.
6288 (BFD32_BACKENDS_CFILES): Add elf32-sh-nbsd.c.
6289 (elf32-sh-nbsd.lo): New rule.
6290 * Makefile.in: Regenerate.
6291 * config.bfd (sh*le-*-netbsdelf*): New target.
6292 (sh*-*-netbsdelf*): New target.
6293 * configure.in: Include netbsd-core.lo for native sh*-*-netbsd*.
6294 (bfd_elf32_shnbsd_vec): New vector.
6295 (bfd_elf32_shlnbsd_vec): New vector.
6296 * configure: Regenerate.
6297 * elf32-sh-nbsd.c: New file.
6298 * targets.c: Update copyright years.
175e9962 6299 (_bfd_target_vector): Add bfd_elf32_shlnbsd_vec and
8d05742f
JT
6300 bfd_elf32_shnbsd_vec.
6301
1dba4cb4
AH
63022002-01-07 Aldy Hernandez <aldyh@redhat.com>
6303
6304 * coff-rs6000.c (READ20): Use bfd_scan_vma.
6305
47b22aef
GK
63062002-01-07 Geoffrey Keating <geoffk@redhat.com>
6307
6308 * elflink.h (elf_link_input_bfd): Don't ask for the merged offset
6309 of a symbol in a section that will be deleted.
6310
be2d1673
NC
63112002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
6312
6313 * po/es.po: New file: Spanish translation.
6314 * configure.in (ALL_LINGUAS): Add es.
6315 * configure: Regenerate.
6316
d9cf1b54
AM
63172002-01-06 Steve Ellcey <sje@cup.hp.com>
6318
6319 * elfxx-ia64.c (is_unwind_section_name): Add target vector as
6320 argument so we can handle HP-UX specially.
6321 (elfNN_ia64_hpux_vec): New for use in is_unwind_section_name.
6322 (elfNN_hpux_backend_section_from_bfd_section): New for support
6323 of SHN_IA_64_ANSI_COMMON.
6324 (elfNN_ia64_relax_section): Add support for SHN_IA_64_ANSI_COMMON.
6325 (is_unwind_section_name): Add special HP-UX support.
6326 (elfNN_ia64_section_from_shdr): Add support for more sections.
6327 (elfNN_ia64_fake_sections): Modify is_unwind_section_name call and
6328 add support for more sections.
6329 (elfNN_ia64_additional_program_headers): Modify
6330 is_unwind_section_name call.
6331 (elfNN_ia64_modify_segment_map): Remove assumption that there is
6332 only one unwind section in segment.
6333
3f3c5c34
AM
63342002-01-06 Alan Modra <amodra@bigpond.net.au>
6335
6336 * syms.c (_bfd_generic_make_empty_symbol): New function.
6337 * libbfd-in.h (_bfd_nosymbols_make_empty_symbol): Define as
6338 _bfd_generic_make_empty_symbol.
6339 * libbfd.h: Regenerate.
6340 * bfd-in2.h: Regenerate.
6341 * hppabsd-core.c (hppabsd_core_make_empty_symbol): Delete function.
6342 (hppabsd_core_get_symtab_upper_bound): Don't define.
6343 (hppabsd_core_get_symtab): Likewise.
6344 (hppabsd_core_print_symbol): Likewise.
6345 (hppabsd_core_get_symbol_info): Likewise.
6346 (hppabsd_core_bfd_is_local_label_name): Likewise.
6347 (hppabsd_core_get_lineno): Likewise.
6348 (hppabsd_core_find_nearest_line): Likewise.
6349 (hppabsd_core_bfd_make_debug_symbol): Likewise.
6350 (hppabsd_core_read_minisymbols): Likewise.
6351 (hppabsd_core_minisymbol_to_symbol): Likewise.
6352 (hppabsd_core_vec): Use BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols).
6353 Formatting fixes.
6354 * hpux-core.c: Similarly.
6355 * irix-core.c: Similarly.
6356 * osf-core.c: Similarly.
6357 * sco5-core.c: Similarly.
6358 * binary.c (binary_make_empty_symbol): Remove function, define as
6359 _bfd_generic_make_empty_symbol.
6360 * ihex.c (ihex_make_empty_symbol): Likewise.
6361 * mmo.c (mmo_make_empty_symbol): Likewise.
6362 * ppcboot.c (ppcboot_make_empty_symbol): Likewise.
6363 * srec.c (srec_make_empty_symbol): Likewise.
6364 * versados.c (versados_make_empty_symbol): Likewise.
6365 * vms.c (_bfd_vms_make_empty_symbol): Remove.
6366 (vms_make_empty_symbol): Define as _bfd_generic_make_empty_symbol.
6367 * vms-gsd.c (_bfd_vms_slurp_gsd): Call bfd_make_empty_symbol
6368 rather than _bfd_vms_make_empty_symbol.
6369 * vms-misc.c (new_symbol): Likewise.
6370
3f0a7f7f
AM
63712002-01-05 Alan Modra <amodra@bigpond.net.au>
6372
9e7b37b3
AM
6373 * section.c (bfd_section_init): Remove unnecessary initialisations.
6374 (bfd_section_list_clear): New function.
6375 (bfd_section_list_remove, bfd_section_list_insert): New macros.
6376 (_bfd_strip_section_from_output): Use them.
6377 * coffcode.h (coff_set_alignment_hook): Likewise.
6378 * elf32-mips.c (_bfd_mips_elf_final_link): Likewise.
6379 * elf64-mips.c (mips_elf64_final_link): Likewise.
6380 * elf64-mmix.c (mmix_elf_final_link): Likewise.
6381 * sunos.c (sunos_add_dynamic_symbols): Likewise.
6382 * xcofflink.c (_bfd_xcoff_bfd_final_link): Likewise.
6383 * bfd-in2.h: Regenerate.
6384
6385 * netbsd-core.c (netbsd_core_file_p): Use bfd_make_section_anyway
6386 rather than doing our own section handling. Clean up after errors
6387 with bfd_release and bfd_section_list_clear. Handle unexpected
6388 flags.
6389 * aoutf1.h (sunos4_core_file_p): Likewise.
6390 * aix386-core.c (aix386_core_file_p): Likewise.
6391 * cisco-core.c (cisco_core_file_validate): Likewise.
6392 * ptrace-core.c (ptrace_unix_core_file_p): Likewise.
6393 * trad-core.c (trad_unix_core_file_p): Likewise.
6394
6395 * hppabsd-core.c (hppabsd_core_core_file_p): Clean up after errors
6396 with bfd_release and bfd_section_list_clear.
6397 * hpux-core.c (hpux_core_core_file_p): Likewise.
6398 * irix-core.c (irix_core_core_file_p): Likewise.
6399 * lynx-core.c (lynx_core_file_p): Likewise.
6400 * osf-core.c (osf_core_core_file_p): Likewise.
6401 * rs6000-core.c (rs6000coff_core_p): Likewise.
6402 * sco5-core.c (sco5_core_file_p): Likewise.
6403
3f0a7f7f
AM
6404 * elf32-mips.c (_bfd_mips_elf_lo16_reloc): Simplify, and perform
6405 sign extension adjustments without conditionals.
6406
a3aa38ee
JJ
64072002-01-04 Jakub Jelinek <jakub@redhat.com>
6408
6409 * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): Don't crash if
6410 CIE at .eh_frame start is removed due to no FDEs referencing it.
6411
8a8b2d4b
AJ
64122002-01-04 Jason Thorpe <thorpej@wasabisystems.com>
6413
6414 * config.bfd (x86_64-*-netbsd*): New target.
6415 * configure.in (x86_64-*-netbsd*): Set COREFILE
6416 to netbsd-core.lo.
6417 * configure: Regenerated.
6418
04b5af89
TR
64192002-01-03 Tom Rix <trix@redhat.com>
6420
6421 * xcofflink.c (_bfd_xcoff_bfd_final_link): Update .pad section ordering
6422 for recent bfd_make_section_anyway change.
6423
51c5503b
NC
64242002-01-03 Nick Clifton <nickc@cambridge.redhat.com>
6425
6426 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
6427 R_ARM_THM_PC11 reloc.
6428
07f7c046
NC
64292002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
6430
6431 * configure.in (LINGUAS): Add ja.
6432 * configure: Regenerate.
6433 * po/ja.po: Import from translation project's web site.
6434
5eefb65f
NC
64352002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
6436
6437 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Reformat error
6438 messages to ease translation into other languages.
6439
39e90f10 6440For older changes see ChangeLog-0001
56882138
AM
6441\f
6442Local Variables:
6443mode: change-log
6444left-margin: 8
6445fill-column: 74
6446version-control: never
6447End: