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