* dwarf2.c (struct line_head) [total_length]: Change type to
[deliverable/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
d03ba2a1
JJ
12001-11-14 Jakub Jelinek <jakub@redhat.com>
2
3 * dwarf2.c (struct line_head) [total_length]: Change type to
4 bfd_vma.
5 (struct dwarf2_debug): Add dwarf_str_buffer and dwarf_str_size.
6 (struct comp_unit): Add stash and offset_size.
7 (read_8_bytes): Return bfd_vma.
8 (read_indirect_string): New.
9 (read_attribute): Handle DW_FORM_strp.
10 (decode_line_info): Support 64-bit DWARF format.
11 (_bfd_dwarf2_find_nearest_line): Likewise.
12 (parse_comp_unit): Set offset_size and stash.
13
cf716c56
RH
142001-11-13 Keith Walker <keith.walker@arm.com>
15
16 * dwarf2.c (read_attribute_value): New function to handle
17 DW_FORM_indirect.
18 (read_attribute): Use it.
19
1a509dcc
GK
202001-11-13 Geoffrey Keating <geoffk@redhat.com>
21
22 * dwarf2.c (decode_line_info): Properly deal with unknown standard
23 opcodes.
24
4e6bfe8a
AM
252001-11-13 John Marshall <jmarshall@acm.org>
26 Alan Modra <amodra@bigpond.net.au>
27
28 * section.c (bfd_make_section_anyway): Don't increment section_id
29 and the BFD's section_count if adding the section failed.
30 * vms.c (vms_new_section_hook): Adjust for bfd_make_section_anyway
31 change.
32
bc0d28ee
HPN
332001-11-12 Orjan Friberg <orjanf@axis.com>
34
35 * elf32-cris.c (cris_elf_grok_prstatus): Adjust values to match new
36 core dump format.
37
350836e3
L
382001-11-11 H.J. Lu <hjl@gnu.org>
39
40 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Call
41 _bfd_elf_strtab_size instead of _bfd_stringtab_size.
42
43 * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Change
44 dynstr type to `struct elf_strtab_hash *'.
45
b959dc73
HPN
462001-11-11 Hans-Peter Nilsson <hp@bitrange.com>
47
48 * elf-strtab.c (_bfd_elf_strtab_finalize): Make first variable i
49 size_t. Rename second i to j.
50
7e250b6c
JL
51Sat Nov 10 08:56:02 2001 Jeffrey A Law (law@cygnus.com)
52
53 * binary.c: Include safe-ctype.h after bfd.h and sysdep.h.
54
ec338859
AM
552001-11-10 Alan Modra <amodra@bigpond.net.au>
56
57 * elf32-arm.h (elf32_arm_final_link_relocate): Don't copy STN_UNDEF
58 relocs into shared libs.
59 * elf32-cris.c (cris_elf_relocate_section): Likewise.
60 * elf32-i370.c (i370_elf_relocate_section): Likewise.
61 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
62 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
63 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
64 * elf32-sh.c (sh_elf_relocate_section): Likewise.
65 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
66 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
67 * elf64-s390.c (elf_s390_relocate_section): Likewise.
68 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
69 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
70 * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
71
72 * elf.c (bfd_section_from_r_symndx): New function.
73 * elf-bfd.h (LOCAL_SYM_CACHE_SIZE): Define.
74 (struct sym_sec_cache): New.
75 (bfd_section_from_r_symndx): Declare.
76 (struct bfd_elf_section_data): Change local_dynrel type to PTR.
77 * elflink.h (elf_link_input_bfd): Don't test for removed linkonce
78 relocs when relocatable. Don't zero entire reloc, just zero the
79 addend and sym.
80 * elf32-hppa.c (struct elf32_hppa_link_hash_table): Add sym_sec.
81 (elf32_hppa_link_hash_table_create): Init it.
82 (elf32_hppa_check_relocs): Track dynamic relocs needed for local
83 syms on a per-section basis as we do for globals.
84 (elf32_hppa_gc_sweep_hook): Update for local_dynrel change.
85 (allocate_dynrelocs): Warning fix.
86 (elf32_hppa_size_dynamic_sections): Don't allocate relocs when
87 section has been discarded.
88 (elf32_hppa_relocate_section): Don't copy STN_UNDEF relocs
89 into shared libs.
90 * elf32-i386.c (struct elf_i386_link_hash_table): Add sym_sec.
91 (elf_i386_link_hash_table_create): Init it.
92 (elf_i386_check_relocs): Track dynamic relocs needed for local
93 syms on a per-section basis as we do for globals.
94 (elf_i386_gc_sweep_hook): Update for local_dynrel change.
95 Remove dead code.
96 (allocate_dynrelocs): Warning fix.
97 (elf_i386_size_dynamic_sections): Don't allocate relocs when
98 section has been discarded.
99 (elf_i386_relocate_section): Don't copy STN_UNDEF relocs
100 into shared libs.
101 * elf32-s390.c (struct elf_s390_link_hash_table): Add sym_sec.
102 (elf_s390_link_hash_table_create): Init it.
103 (elf_s390_check_relocs): Track dynamic relocs needed for local
104 syms on a per-section basis as we do for globals.
105 (elf_s390_gc_sweep_hook): Update for local_dynrel change.
106 Remove dead code.
107 (allocate_dynrelocs): Warning fix.
108 (elf_s390_size_dynamic_sections): Don't allocate relocs when
109 section has been discarded.
110 (elf_s390_relocate_section): Don't copy STN_UNDEF relocs
111 into shared libs.
112 * elf64-ppc.c (struct ppc_link_hash_table): Add sym_sec.
113 (ppc64_link_hash_table_create): Init it.
114 (ppc64_elf_check_relocs): Track dynamic relocs needed for local
115 syms on a per-section basis as we do for globals.
116 (ppc64_elf_gc_sweep_hook): Update for local_dynrel change.
117 (allocate_dynrelocs): Call the correct record_dynamic_dymbol
118 function. Warning fix.
119 (ppc64_elf_size_dynamic_sections): Don't allocate relocs when
120 section has been discarded.
121 (ppc64_elf_relocate_section): Don't copy STN_UNDEF relocs
122 into shared libs.
123 * elf64-s390.c (struct elf_s390_link_hash_table): Add sym_sec.
124 (elf_s390_link_hash_table_create): Init it.
125 (elf_s390_check_relocs): Track dynamic relocs needed for local
126 syms on a per-section basis as we do for globals.
127 (elf_s390_gc_sweep_hook): Update for local_dynrel change.
128 Remove dead code.
129 (allocate_dynrelocs): Warning fix.
130 (elf_s390_size_dynamic_sections): Don't allocate relocs when
131 section has been discarded.
132 (elf_s390_relocate_section): Don't copy STN_UNDEF relocs
133 into shared libs.
134
0451c93c
MS
1352001-11-08 Martin Schwidefsky <schwidefsky@de.ibm.com>
136
137 * elf32-s390: Major rework that introduces all recent changes to
138 the s390 backends. Get a closer match to elf32-i386.
139 (elf_s390_relocate_section): Make use of dynamic section short-cuts.
140 Localise vars, and delay setting. Better error reporting, replace
141 BFD_ASSERT with abort. Check ELF_LINK_HASH_DEF_DYNAMIC to see if a
142 symbol is not defined in the regular object file and tread the weak
143 definition as the normal one. Don't discard relocs for undefweak or
144 undefined symbols and check !DEF_REGULAR as well as DEF_DYNAMIC in
145 test for avoided copy relocs. Reinstate fudge for unresolved relocs
146 in debugging sections.
147 (elf32_s390_adjust_dynamic_symbol): Handle nocopyreloc. Don't do copy
148 reloc processing for weakdefs. Remove redundant casts and aborts.
149 Delay setting of vars until needed. Move creation of dynamic symbols
150 and allocation of .plt and .rela.plt to allocate_dynrelocs. Replace
151 BFD_ASSERT with abort. Discard .plt entries for everything with
152 plt.refcount <= 0.
153 (elf_s390_check_relocs): Don't allocate space for dynamic relocs,
154 .got or .relgot here but do it in allocate_dynrelocs. Reference count
155 possible .plt and .got entries. Don't test input section SEC_READONLY
156 here to try to avoid copy relocs, and keep dyn_relocs regardless of
157 ELF_LINK_NON_GOT_REF. Don't set DF_TEXTREL here. Delay setting of
158 variables until needed. Remove separate switch stmt for creating .got
159 section. Initialise local_got_refcounts to 0. Cache pointer to
160 "sreloc" section in elf_section_data. Tweak condition under which .got
161 created. Report files with bad relocation section names.
162 (elf_s390_finish_dynamic_symbol): Don't copy relocs for symbols that
163 have been forced local. Use same test to decide if we can use a
164 relative reloc for got as elf_s390_relocate_section. Expand SHN_UNDEF
165 comment. Move expressions out of function calls. Replace BFD_ASSERT
166 with abort.
167 (elf_s390_finish_dynamic_sections): Migrate common code out of switch
168 statement. Replace BFD_ASSERT with abort.
169 (elf_s390_size_dynamic_sections): Call readonly_dynrelocs. Rename "i"
170 to "ibfd". Allocate space for local dyn relocs. Use DF_TEXTREL flag
171 instead of looking up section names for DT_TEXTREL. Replace
172 BFD_ASSERT with abort. Zero out the dynamic allocated content space.
173 Add a comment to remind us that one day this ought to be fixed.
174 (struct elf_s390_link_hash_entry): Rename "root" to "elf".
175 (struct elf_s390_link_hash_table): Likewise.
176 (elf_s390_link_hash_newfunc): Rename to link_hash_newfunc and get
177 rid of unnecessary casts.
178 (struct elf_s390_dyn_relocs): Add "sec", and "pc_count" fields.
179 Remove "section" field.
180 (elf_s390_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
181 Reference count possible .plt entries. Don't deallocate .got and
182 .relgot space here.
183 (struct elf_s390_pcrel_relocs_copied): Rename to elf_s390_dyn_relocs.
184 Update comment.
185 (struct elf_s390_link_hash_entry): Rename pcrel_relocs_copied to
186 dyn_relocs.
187 (elf_s390_discard_copies): Delete.
188 (elf_s390_link_hash_traverse): Delete.
189 (bfd_elf32_bfd_final_link): Delete. (ie. use regular final link
190 rather than gc variety).
191 (struct elf_s390_link_hash_table): Add sgot, sgotplt, srelgot, splt,
192 srelplt, sdynbss, srelbss fields.
193 (elf_s390_link_hash_table_create): Init them.
194 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
195 (allocate_dynrelocs): New function.
196 (create_got_section): New function.
197 (elf_backend_can_refcount): Define.
198 (elf_backend_copy_indirect_symbol): Define.
199 (elf_s390_copy_indirect_symbol): New function.
200 (elf_s390_create_dynamic_sections): New function.
201 (readonly_dynrelocs): New function.
ec338859 202 * elf64-s390.c: Likewise.
0451c93c 203
2b0f7ef9
JJ
2042001-11-07 Jakub Jelinek <jakub@redhat.com>
205
206 * Makefile.am (BFD32_BACKENDS): Add elf-strtab.lo.
207 (BFD32_BACKENDS_CFILES): Add elf-strtab.c.
208 (elf-strtab.lo): Add rule.
209 * Makefile.in: Rebuilt.
210 * configure.in (elf): Add elf-strtab.lo.
211 * configure: Rebuilt.
212 * elf-bfd.h (elf_strtab_hash): Forward declare.
213 (struct elf_link_hash_table): Change dynstr type to
214 struct elf_strtab_hash *.
215 (struct elf_obj_tdata): Change strtab_ptr type to
216 struct elf_strtab_hash *.
217 (_bfd_elf_strtab_init, _bfd_elf_strtab_free, _bfd_elf_strtab_add,
218 _bfd_elf_strtab_addref, _bfd_elf_strtab_delref,
219 _bfd_elf_strtab_clear_all_refs, _bfd_elf_strtab_size,
220 _bfd_elf_strtab_offset, _bfd_elf_strtab_emit,
221 _bfd_elf_strtab_finalize): New prototypes.
222 * elf-strtab.c: New file.
223 * elflink.h (elf_link_add_object_symbols): Use _bfd_elf_strtab_add
224 and _bfd_elf_strtab_size instead of _bfd_stringtab calls.
225 Call _bfd_elf_strtab_delref if DT_NEEDED entry is not needed or
226 when forcing dynamic symbol to local.
227 (elf_link_create_dynamic_sections): Call
228 _bfd_elf_strtab_init instead of elf_stringtab_init.
229 (elf_link_record_local_dynamic_symbol): Likewise, change
230 dynstr type. Use _bfd_elf_strtab functions instead of
231 _bfd_stringtab calls.
232 (size_dynamic_sections): Use _bfd_elf_strtab functions instead of
233 _bfd_stringtab calls. For DT_RUNPATH and Verdaux vda_name fields,
234 call _bfd_elf_strtab_addref. Call elf_finalize_dynstr.
235 (elf_adjust_dynstr_offsets, elf_finalize_dynstr): New functions.
236 (elf_fix_symbol_flags): Call _bfd_elf_strtab_delref when forcing
237 dynamic symbol to local.
238 (elf_link_assign_sym_version): Likewise.
239 (elf_bfd_final_link): Call _bfd_elf_strtab_emit instead of
240 _bfd_stringtab_emit.
241 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Change dynstr
242 type. Call _bfd_elf_strtab functions instead of
243 _bfd_stringtab functions.
244 * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Likewise.
245 * elf.c (_bfd_elf_init_reloc_shdr): Likewise.
246 (elf_fake_sections): Likewise.
247 (assign_section_numbers): Call _bfd_elf_strtab_clear_all_refs
248 on shstrtab hash table, call _bfd_elf_strtab_addref on each section
249 name in the output. Call _bfd_elf_strtab_finalize and
250 use _bfd_elf_strtab_offset to finalize sh_name section header fields.
251 (_bfd_elf_compute_section_file_positions): Use _bfd_elf_strtab_size
252 instead of _bfd_stringtab_size.
253 (prep_headers): Change shstrtab type.
254 Use _bfd_elf_strtab calls instead of _bfd_stringtab calls.
255
1d761fc5
AM
2562001-11-07 Alan Modra <amodra@bigpond.net.au>
257
258 * elflink.h (elf_link_input_bfd <removed linkonce relocs>): Fix
259 bad symtab segfault. Formatting and warning fixes. Improve
260 error message for internationalisation.
261
f8deed93
L
2622001-11-06 H.J. Lu (hjl@gnu.org)
263
1d761fc5 264 * elflink.h (elf_link_input_bfd): Complain about relocs against
f8deed93
L
265 discarded sections.
266
7fda6dbc
AM
2672001-11-03 Alan Modra <amodra@bigpond.net.au>
268
269 * elfxx-target.h (elfNN_bed): Correct want_got_sym, want_dynbss order.
270
d918dd35
L
2712001-11-02 H.J. Lu <hjl@gnu.org>
272
273 * elf32-mips.c (mips_elf_calculate_relocation): Don't create
274 dynamic relocation for symbols defined in regular objects when
275 creating executables.
276
b8819ab2
NC
2772001-11-02 Nick Clifton <nickc@cambridge.redhat.com>
278
3c62831e
NC
279 * configure.in (ALL_LINGUAS): Add "fr".
280 * configure: Regenerate.
281 * po/fr.po: New file.
282
b8819ab2
NC
283 * coffgen.c (coff_object_p): Add comment to H.J.'s recent patch.
284
21da9f89
NC
2852001-11-02 John David Anglin <dave@hiauly1.hia.nrc.ca>
286
287 * som.c (setup_sections): Initialize subspace_sections.
288
95f7d9f7
L
2892001-11-02 H.J. Lu (hjl@gnu.org)
290
291 * coffgen.c (coff_object_p): Return 0 if the header is too big.
292
12e1f53e
HPN
2932001-11-02 Hans-Peter Nilsson <hp@axis.com>
294
295 * elfcore.h (elf_core_file_p): Preserve and clear abfd section
296 information. Save bfd arch and mach values. Restore on error.
297
a8d02d66
AM
2982001-11-02 Alan Modra <amodra@bigpond.net.au>
299
300 * elf32-hppa.c (hppa_handle_PIC_calls): Rename to mark_PIC_calls.
301 (allocate_PIC_calls): New function.
302 (allocate_dynrelocs): Don't allocate pic_call plt entries here.
303 (elf32_hppa_size_dynamic_sections): Call allocate_PIC_calls.
304 (elf32_hppa_finish_dynamic_symbol): Remove dead code.
305
72209a1f
HPN
3062001-11-02 Hans-Peter Nilsson <hp@axis.com>
307
308 * elf32-cris.c (cris_elf_grok_prstatus): New function.
4a15251e 309 (cris_elf_grok_psinfo): New function.
72209a1f
HPN
310 (elf_backend_grok_prstatus): Define.
311 (elf_backend_grok_psinfo): Define.
312
86c76c7b
AM
3132001-11-01 Alan Modra <amodra@bigpond.net.au>
314
315 * elf64-ppc.c (ppc64_elf_relocate_section): Correct branch
316 prediction bits.
317
afdbd6d0
CD
3182001-10-31 Chris Demetriou <cgd@demetriou.com>
319
320 * elf32-mips.c (_bfd_mips_elf_hi16_reloc): Handle PC-relative
321 relocations properly.
322
2cd533b7
L
3232001-10-31 H.J. Lu <hjl@gnu.org>
324
325 * elflink.h (elf_link_output_extsym): Don't clear the visibility
326 field for relocateable.
327
4578e0a7
AM
3282001-11-01 Alan Modra <amodra@bigpond.net.au>
329
4e12ff7f
AM
330 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Don't count
331 .plt relocs in DT_RELASZ.
4578e0a7 332
7649aa50
NC
3332001-10-29 NIIBE Yutaka <gniibe@m17n.org>
334
335 * config.bfd: Supports sh3/sh4/sh3eb/sh4eb-unknown-linux-gnu
336 targets.
337
a53ecf01
NC
3382001-10-31 Nick Clifton <nickc@cambridge.redhat.com>
339
340 * targets.c: Fix typo: bfd_mmo_mmix_vec => bfd_mmo_vec.
341
3c3bdf30
NC
3422001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
343
344 * Makefile.am (ALL_MACHINES): Add cpu-mmix.lo.
345 (BFD64_BACKENDS): Add elf64-mmix.lo and mmo.lo.
346 (BFD64_BACKENDS_CFILES): Add elf64-mmix.c and mmo.c.
347 Regenerate dependencies.
348 * configure.in (bfd_elf64_mmix_vec, bfd_mmo_vec): New vectors.
349 * config.bfd: [BFD64] (mmix-*-*): New case.
350 * cpu-mmix.c, mmo.c, elf64-mmix.c: New files.
351 * archures.c (enum bfd_architecture): Add bfd_arch_mmix.
352 (bfd_mmix_arch): Declare.
353 (bfd_archures_list): Add bfd_mmix_arch.
354 * targets.c (enum bfd_flavour): Add bfd_target_mmo_flavour.
355 (bfd_elf64_mmix_vec, bfd_mmo_vec): Declare.
356 (bfd_target_vect) [BFD64]: Add bfd_elf64_mmix_vec and
357 bfd_mmo_mmix_vec.
358 * reloc.c: Add MMIX relocations.
359 * bfd.c (struct _bfd, tdata): Add mmo_data.
360 * Makefile.in: Regenerate.
361 * configure: Regenerate.
362 * libbfd.h: Regenerate.
363 * bfd-in2.h: Regenerate.
364 * configure: Rebuild.
365
e0e8c97f
NC
3662001-10-30 Richard Earnshaw (rearnsha@arm.com)
367
368 * elf.c (_bfd_elf_make_section_from_shdr): Set the LMA based on the
369 p_paddr of the segment that contains it.
f5ffc919
NC
370 (copy_private_bfd_data): If the LMA for a segment is known, use it
371 for matching sections to segments.
372 (assign_file_positions_for_segments): Use the LMA when adjusting
373 for inter-section alignment padding.
e0e8c97f 374
5b74f489
KH
3752001-10-29 Kazu Hirata <kazu@hxi.com>
376
377 * README: Fix a typo.
378
0b6488e2
RH
3792001-10-24 Richard Henderson <rth@redhat.com>
380
381 * peXXigen.c (_bfd_XX_print_private_bfd_data_common): Copy
382 timestamp to time_t for ctime.
383
908d94bf
HPN
3842001-10-24 Hans-Peter Nilsson <hp@axis.com>
385
386 * elf32-cris.c (cris_reloc_type_lookup): Change loop to use
387 unsigned, increasing index.
388
1b58be7e
L
3892001-10-23 H.J. Lu <hjl@gnu.org>
390
391 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Check
392 m != NULL before accessing it.
393
ce757d15
AM
3942001-10-23 Alan Modra <amodra@bigpond.net.au>
395
396 * elflink.h (elf_link_input_bfd): Zero the reloc instead of doing
397 bfd_reloc_type_lookup (bfd, BFD_RELOC_NONE) as bfd_reloc_type_lookup
398 doesn't accept BFD_RELOC_* on some targets, eg. hppa.
399
400 * elf32-hppa.c (elf32_hppa_link_hash_entry): Remove plt_abs.
401 (hppa_link_hash_newfunc): Likewise.
402 (elf32_hppa_finish_dynamic_symbol): Likewise.
403 (allocate_dynrelocs): Always allocate .got relocs if shared.
404 (elf32_hppa_relocate_section): Output them too. Similarly
405 consolidate .plt reloc code, and no longer initialise .plt
406 when a reloc is output.
407 (elf32_hppa_finish_dynamic_symbol): Only initialise .plt entries
408 when no reloc is output.
409
410 From Herbert Xu <herbert@gondor.apana.org.au>
411 * elf32-hppa.c (final_link_relocate): Call bfd_set_error for
412 unreachable branches.
413
ca51bfff
L
4142001-10-22 H.J. Lu <hjl@gnu.org>
415
416 * configure.in (WIN32LIBADD): Use -L../libiberty for
417 mips*-*-linux*.
418 * configure: Rebuild.
419
78be1d6e
L
4202001-10-21 H.J. Lu <hjl@gnu.org>
421
422 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
423 if shared library is enabled only for Linux hosts.
424 * configure: Rebuild.
425
1b90af26
L
4262001-10-21 H.J. Lu <hjl@gnu.org>
427
428 * configure.in (WIN32LIBADD): Check if PICFLAG is defined in
429 ../libiberty/Makefile instead of $enable_shared.
430 * configure: Rebuild.
431
ebe7507a
L
4322001-10-21 H.J. Lu <hjl@gnu.org>
433
908d94bf
HPN
434 * elf32-cris.c (cris_reloc_type_lookup): Use int for index. Cover
435 index 0.
ebe7507a 436
39691762
L
4372001-10-20 H.J. Lu <hjl@gnu.org>
438
439 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
440 if shared library is enabled.
441 * configure: Rebuild.
442
6a7805b5
L
4432001-10-20 H.J. Lu <hjl@gnu.org>
444
445 * elf32-cris.c (cris_reloc_type_lookup): Allow index 0.
446
e0740195
L
4472001-10-19 H.J. Lu <hjl@gnu.org>
448
449 * elfcode.h (elf_object_p): Don't clear D_PAGED if the section
450 size is empty.
451
7595d193
L
4522001-10-18 H.J. Lu <hjl@gnu.org>
453
454 * elf32-i370.c (i370_elf_relocate_section): Ignore R_XXX_NONE.
455 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
456
25263aad
JJ
4572001-10-18 Jakub Jelinek <jakub@redhat.com>
458
459 * section.c (_bfd_strip_section_from_output): Don't count
460 SEC_EXCLUDE sections as references. Set SEC_EXCLUDE.
461
973ffd63
AM
4622001-10-17 Alan Modra <amodra@bigpond.net.au>
463
464 * elf-m10200.c (mn10200_elf_relax_section): Cast assignment to
465 Elf_Internal_Shdr.contents now that it's no longer a PTR.
466 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
467 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
468 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
469 * elf32-sh.c (sh_elf_relax_section): Likewise.
470 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
471 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
472 * elf.c (setup_group): Warning fixes.
473 * elflink.h (elf_link_sort_relocs): Likewise.
474 * pdp11.c (slurp_reloc_table): Likewise.
475
df22989b
JH
4762001-10-16 Jeff Holcomb <jeffh@redhat.com>
477
478 * elflink.h (elf_link_sort_relocs): Remove unnecessary pointer
479 casts.
480
1e09179f
L
4812001-10-15 H.J. Lu <hjl@gnu.org>
482
483 * elflink.h (elf_link_input_bfd): Set type to BFD_RELOC_NONE
484 for relocations against discarded link-once section.
485
1e370bd2
AM
4862001-10-15 Alan Modra <amodra@bigpond.net.au>
487
cf5c0c5b
AM
488 * elf32-i386.c (elf_i386_relocate_section): Report some detail on
489 bfd_reloc_outofrange and similar errors.
490
1e370bd2
AM
491 * elf.c (_bfd_elf_link_hash_copy_indirect): Test ind->root.type
492 rather than ind->weakdef.
493 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
494 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
495 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
496 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
497 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
498
bbd7ec4a
AM
4992001-10-15 Alan Modra <amodra@bigpond.net.au>
500 H.J. Lu <hjl@gnu.org>
501
502 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Merge dyn_reloc
503 counts for aliases instead of aborting.
504 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
505 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
506
507 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Set plt.offset
508 to -1 for non-function symbols.
509 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
510 * elf32-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
511 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
512 * elf64-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
513 * elf64-x86-64.c (elf64_x86_64_adjust_dynamic_symbol): Likewise.
514 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Refer to
515 plt.offset instead of plt.refcount when setting to -1.
516
6a360bf4
NC
5172001-10-12 Nick Clifton <nickc@cambridge.redhat.com>
518
519 * elf32-arm.h (elf32_arm_relocate_section): Treat R_ARM_THM_PC22
520 like R_ARM_PC24. Include reloc number in error message about
521 unresolvable relocs.
522
290394d6
JJ
5232001-10-10 Jakub Jelinek <jakub@redhat.com>
524
525 * elflink.h (elf_link_sort_cmp2): Don't mix PLT and non-PLT
526 relocations against the same symbol in .rel{,a}.dyn section.
527
08da05b0
KH
5282001-10-10 Kazu Hirata <kazu@hxi.com>
529
530 * aout-encap.c: Fix comment typos.
531 * aoutx.h: Likewise.
532 * archive.c: Likewise.
533 * bout.c: Likewise.
534 * coff64-rs6000.c: Likewise.
535 * coffcode.h: Likewise.
536 * coffgen.c: Likewise.
537 * cofflink.c: Likewise.
538 * coff-mips.c: Likewise.
539 * ecoff.c: Likewise.
540 * elf32-m32r.c: Likewise.
541 * libcoff-in.h: Likewise.
542 * libecoff.h: Likewise.
543 * libxcoff.h: Likewise.
544 * nlm32-i386.c: Likewise.
545 * pdp11.c: Likewise.
546 * section.c: Likewise.
547 * som.c: Likewise.
548 * som.h: Likewise.
549 * bfd-in2.h: Regenerate.
550 * libcoff.h: Likewise.
551
079e9a2f
AM
5522001-10-10 Alan Modra <amodra@bigpond.net.au>
553
554 * elf.c (elf_map_symbols): Don't create new section symbols; Use
555 existing section syms. Update comments.
556 (copy_private_bfd_data): Formatting fixes.
557 (elfcore_grok_win32pstatus): Likewise.
558 (swap_out_syms): Likewise. Remove unnecessary level of braces.
559
945906ff
AM
5602001-10-09 Alan Modra <amodra@bigpond.net.au>
561
562 * elf-bfd.h (struct bfd_elf_section_data): Rename "group" to
563 "group_name".
564 (elf_group_name): Define.
565 (elf_next_in_group): Define.
566 * elf.c: Make use of elf_group_name and elf_next_in_group throughout.
567 (setup_group): Don't use sec->lineno for SHT_GROUP section to store
568 first member section; Instead use elf_next_in_group.
569 (bfd_section_from_shdr): Likewise.
570 (set_group_contents): Likewise. Use elf_section_syms, not sec->symbol.
571
dbb410c3
AM
5722001-10-09 Alan Modra <amodra@bigpond.net.au>
573
574 * elf-bfd.h (struct bfd_elf_section_data): Add "group" and
575 "next_in_group". Fix gp and gp_size comments.
576 * elf.c (union elf_internal_group): New.
577 (setup_group): New function.
578 (_bfd_elf_make_section_from_shdr): Set BFD flags for SHT_GROUP.
579 Call setup_group for SHF_GROUP sections.
580 (bfd_section_from_shdr): Build a BFD section for SHT_GROUP.
581 (elf_fake_sections): Set header type for SEC_GROUP, and header
582 flags for sections in a group.
583 (set_group_contents): New function.
584 (_bfd_elf_compute_section_file_positions): Call it.
585 (assign_section_numbers): Set sh_link for SHT_GROUP.
945906ff 586
dbb410c3
AM
587 * elflink.h (gc_mark_hook): Handle section groups.
588 * elfxx-target.h: Add SEC_GROUP to applicable_flags.
589 * section.c (SEC_GROUP): Define.
590 (struct sec): Comment fixes.
591 * bfd-in2.h: Regenerate.
592
593 * elf.c (bfd_elf_print_symbol): Formatting fix; migrate expression
594 out of function args.
595 (_bfd_elf_canonicalize_reloc): Similarly.
596 (_bfd_elf_get_symtab): Here too.
597 (_bfd_elf_canonicalize_dynamic_symtab): And here.
598 * elfcode.h (elf_slurp_symbol_table): Don't recalculate size for
599 bfd_bread, and remove unnecessary cast.
600
24c603fa
AH
6012001-10-08 Aldy Hernandez <aldyh@redhat.com>
602
bbd7ec4a 603 * bfd/config.bfd (targ_cpu): Add arm9e-*-elf.
24c603fa 604
3f5864e1
SC
6052001-10-06 Stephane Carrez <Stephane.Carrez@worldnet.fr>
606
607 * dwarf2.c (comp_unit_find_nearest_line): Check for end of
608 compilation unit.
609
fb9ceeac
AM
6102001-10-06 Alan Modra <amodra@bigpond.net.au>
611
aec2f561
AM
612 * bfd.c (bfd_assert): Report bfd version.
613 (_bfd_abort): Likewise.
614
50b4d486
AM
615 * elflink.h (elf_link_input_bfd): Don't zero discarded link-once
616 section sym values. Instead replace any relocs against them with
617 relocs against STN_UNDEF, which has a zero value.
618
fb9ceeac
AM
619 * elf32-arc.c (elf_arc_howto_table): Set partial_inplace for all
620 relocs.
621
17617495
JL
6222001-10-05 Jeff Law <law@redhat.com>
623
624 * som.h (som_exec_data): New field "version_id".
625 * som.c (som_object_setup): Record the version_id if it
626 exists.
627 (som_prep_headers): Do not initialize version_id here.
628 (som_finish_writing): Initialize version_id here.
629
6302000-10-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
7e766c3b
TS
631
632 * elf32-mips.c (elf_mips_howto_table): Fix some relocation howtos
633 according to the MIPS/SGI ELF64 ABI Draft.
634 (mips_elf_sort_hash_table): Typo.
635
58e3d09d
AM
6362001-10-04 Alan Modra <amodra@bigpond.net.au>
637
8ea52284
AM
638 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Comment typo.
639
58e3d09d
AM
640 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Bail out after
641 copying flags if this is a weakdef.
642
b13c7b49
AM
6432001-10-04 Alan Modra <amodra@bigpond.net.au>
644
a90b9fca
AM
645 * elf-bfd.h (struct elf_link_hash_entry): Reorganise for better
646 packing.
647
bbd7ec4a 648 * elf32-mips.c (mips_elf_record_global_got_symbol): Set got.offset
3a6b8597
AM
649 to 1 rather than 0 to avoid confusing copy_indirect_symbol.
650 (mips_elf_sort_hash_table_f): Compare got.offset against 1.
651
b13c7b49
AM
652 * Makefile.am (BFD_H_DEPS): Add symcat.h. Ensure everything
653 depends on $(BFD_H) $(BFD_H_DEPS) $(LOCAL_H_DEPS), not just those
654 backends we configure. Run "make dep-am".
655 (install-data-local): Install symcat.h.
656 * dep-in.sed: Remove symcat.h from dependencies.
657 * Makefile.in: Regenerate.
658
8bd621d8
AM
6592001-10-03 Vassili Karpov <malc@pulsesoft.com>
660
661 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Handle nocopyreloc.
662
1e2be829
TS
6632001-10-03 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
664
665 * elf64-mips.c (elf_backend_may_use_rela_p): New define.
666 (elf_backend_default_use_rela_p): New define.
667
0a991dfe
AM
6682001-10-03 Alan Modra <amodra@bigpond.net.au>
669
57c7194e
AM
670 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Fix typos in last
671 change.
672
87b632fc
AM
673 * configure.in (AC_OUTPUT <bfd-in3.h>): Remove version.h.
674 * configure: Regenerate.
675 * Makefile.am (BFD_H_FILES): Add version.h.
676 * Makefile.in: Regenerate.
677 * po/SRC-POTFILES.in: Regenerate.
678
0a991dfe
AM
679 * elflink.h (elf_fix_symbol_flags): Copy flags to weakdef using
680 elf_backend_copy_indirect_symbol so that backend has a chance to
681 copy other necessary fields.
682 * elf-bfd.h (struct elf_backend_data): Update description of
683 elf_backend_copy_indirect_symbol.
684 * elf.c (_bfd_elf_link_hash_copy_indirect): Bail out after
685 copying flags if this is a weakdef.
686 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
687 (elfNN_ia64_aix_add_symbol_hook): Use elf_link_hash_lookup rather
688 than bfd_link_hash_lookup.
bbd7ec4a 689 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Don't do copy
0a991dfe
AM
690 reloc processing for weakdefs.
691 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise.
692 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
693
a33d1f77
AM
6942001-10-02 Alan Modra <amodra@bigpond.net.au>
695
696 * elf64-ppc.c (ppc64_elf_check_relocs): Use a local var and cast
697 result of ELF64_R_TYPE to enum before using in a switch.
698 (ppc64_elf_gc_mark_hook): Likewise.
699 (ppc64_elf_gc_sweep_hook): Likewise.
700 (ppc64_elf_reloc_type_class): Likewise.
701
e43d48cc
AM
7022001-10-02 Alan Modra <amodra@bigpond.net.au>
703
704 * version.h: New file.
705 * bfd-in.h: (BFD_VERSION): Substitute bfd_version.
706 (BFD_VERSION_DATE): Define.
707 (BFD_VERSION_STRING): Define.
708 * configure.in: AC_SUBST bfd_version, bfd_version_date and
709 bfd_version_string.
710 (AC_OUTPUT <bfd-in3.h>): Depend on version.h.
711 * bfd-in2.h: Regenerate.
712 * configure: Regenerate.
713 * Makefile.am: Run "make dep-am".
714 * Makefile.in: Regenerate.
715
716 * bfd-in.h: Include "symcat.h".
717 (CONCAT4): Redefine as for old CAT4.
718 * aout-arm.c: Use equivalent CONCAT* macro in place of CAT* macros.
719 Add warning regarding whitespace.
720 * aout-cris.c: Likewise.
721 * aout-ns32k.c: Likewise.
722 * aout-sparcle.c: Likewise.
723 * aout-tic30.c: Likewise.
724 * aout0.c: Likewise.
725 * armnetbsd.c: Likewise.
726 * demo64.c: Likewise.
727 * elf-bfd.h: Likewise.
728 * gen-aout.c: Likewise.
729 * host-aout.c: Likewise.
730 * hp300bsd.c: Likewise.
731 * hp300hpux.c: Likewise.
732 * i386aout.c: Likewise.
733 * i386bsd.c: Likewise.
734 * i386dynix.c: Likewise.
735 * i386freebsd.c: Likewise.
736 * i386linux.c: Likewise.
737 * i386lynx.c: Likewise.
738 * i386mach3.c: Likewise.
739 * i386netbsd.c: Likewise.
740 * libaout.h: Likewise.
741 * m68k4knetbsd.c: Likewise.
742 * m68klinux.c: Likewise.
743 * m68klynx.c: Likewise.
744 * m68knetbsd.c: Likewise.
745 * m88kmach3.c: Likewise.
746 * mipsbsd.c: Likewise.
747 * newsos3.c: Likewise.
748 * ns32knetbsd.c: Likewise.
749 * pc532-mach.c: Likewise.
750 * pdp11.c: Likewise.
751 * riscix.c: Likewise.
752 * sparclinux.c: Likewise.
753 * sparclynx.c: Likewise.
754 * sparcnetbsd.c: Likewise.
755 * sunos.c: Likewise.
756 * targets.c: Likewise.
757 * vaxnetbsd.c: Likewise.
758 * vms-hdr.c: Likewise.
759
4eef72c7
AM
7602001-10-01 Alan Modra <amodra@bigpond.net.au>
761
762 * bfd-in.h: Remove comments regarding generated files.
763 * libbfd-in.h: Likewise.
764 * libcoff-in.h: Likewise.
765 * bfd-in2.h: Regenerate.
766 * libbfd.h: Likewise.
767 * libcoff.h: Likewise.
768
146be91a 7692001-09-30 kaz Kojima <kkojima@rr.iij4u.or.jp>
bbd7ec4a 770 Hans-Peter Nilsson <hp@bitrange.com>
146be91a
HPN
771
772 * elf32-sh.c (sh_elf_howto_table, R_SH_REL32): Make
773 partial_inplace, matching assembler output. Set src_mask to
774 all ones.
775 (sh_elf_relocate_section): Delete misplaced comment.
776 For relocatable linking against section symbol, call
777 _bfd_relocate_contents for partial_inplace relocs and adjust
778 rel->r_addend for others.
779 <case R_SH_DIR32, R_SH_REL32>: Fetch partial_inplace addend with
780 bfd_get_32, not at rel->r_addend.
781
3c3e9281
AM
7822001-09-30 Alan Modra <amodra@bigpond.net.au>
783
784 * elf.c (_bfd_elf_link_hash_copy_indirect): Set ind refcounts to
785 the old dir refcount, so we indirectly set them to init_refcount.
786 Short-circuit asserts when we've just verified they are true.
787
862517b6
AM
7882001-09-29 Alan Modra <amodra@bigpond.net.au>
789
790 * section.c (struct sec): Remove kept_section.
791 (STD_SECTION): Remove kept_section initialisation.
792 (bfd_make_section_anyway): Here too.
793 * ecoff.c (bfd_debug_section): Remove kept_section initialisation.
794 * cofflink.c (_bfd_coff_link_input_bfd): Don't test kept_section.
795 * elflink.h (elf_link_input_bfd): Set discarded link-once section
796 symbols to zero, and remove all code involved with kept_section
797 and tracking section symbol values.
798 * bfd-in2.h: Regenerate.
799 * configure.in: Bump version number.
800 * configure: Regenerate.
801
65f38f15
AM
8022001-09-29 Alan Modra <amodra@bigpond.net.au>
803
804 * elf64-ppc.c (struct ppc_dyn_relocs): New.
805 (IS_ABSOLUTE_RELOC): Define.
806 (struct ppc_link_hash_entry): New.
807 (struct ppc_link_hash_table): New.
808 (ppc_hash_table): Define.
809 (link_hash_newfunc): New function.
810 (ppc64_elf_link_hash_table_create): New function.
811 (create_got_section): New function.
812 (ppc64_elf_create_dynamic_sections): Call create_got_section. Stash
813 pointers to our dynamic sections in hash table.
814 (ppc64_elf_copy_indirect_symbol): New function.
815 (ppc64_elf_check_relocs): Remove DEBUG code. Use short-cuts to
816 dynamic sections. Localise vars. Modify code for refcounts
817 starting from zero. Don't allocate here, or force symbols dynamic.
818 Don't copy all relocs if shared, select ones we need. Add code
819 to track possible copy relocs for non-shared link.
820 (ppc64_elf_gc_mark_hook): Update comment.
821 (ppc64_elf_gc_sweep_hook): Sweep dynrelocs too.
822 (ppc64_elf_adjust_dynamic_symbol): Remove DEBUG code. Rewrite .plt
823 code for reference counting garbage collection. Don't create .plt
824 entries for functions that don't comply with ABI naming convention,
825 and don't allocate .plt space here. Use short-cuts to dynamic
826 sections. If possible, keep dynamic relocations instead of using
827 copy relocs. Remove confused comments.
828 (ppc_adjust_dynindx): Delete.
829 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
830 (allocate_dynrelocs): New function.
831 (readonly_dynrelocs): New function.
832 (ppc64_elf_size_dynamic_sections): Rewrite. Allocate local .got
833 space here, and call allocate_dynrelocs to allocate space for
834 global .plt, .got and reloc sections. Use short-cuts to dynamic
835 sections. Call readonly_dynrelocs to determine whether we need
836 DT_TEXTREL. Don't generate section symbols here, the generic
837 ELF linker code does it for us.
838 (ppc64_elf_final_link): Call regular ELF backend linker rather than
839 gc variety, since we do our own .got handling.
840 (ppc64_elf_relocate_section): Remove DEBUG code. Make use of
841 dynamic section short-cuts. Localise vars, and delay setting.
842 Handle unknown relocs in main switch statement. Replace ugly
843 complicated tests for unresolvable relocs with a simple direct
844 scheme using "unresolved_reloc" var. Test ELF_ST_VISIBILITY
845 before allowing an undefined sym in a shared lib. Do R_*_DS tests
846 after main switch, when we've set addend. Do non-addend insn
847 tweaks before main swithc. Ignore input_section->vma when
848 calculating reloc offsets as it's always zero. Rewrite dynamic
849 reloc handling. Consolidate R_*_HA handling. Handle more relocs.
850 (ppc64_elf_finish_dynamic_symbol): Remove DEBUG code. Make use
851 of dynamic section short-cuts. Reorganise .plt handling code.
852 Remove confused comments. Take note of ELF_LINK_FORCED_LOCAL.
853 Move expressions out of swap_reloca_out function calls.
854 (ppc64_elf_reloc_type_class): New function.
855 (ppc64_elf_info_to_howto): Move common expression to local var.
856 (ppc64_elf_finish_dynamic_sections): Remove DEBUG code. Make use
857 of dynamic section short-cuts. Don't fiddle with section syms
858 here as the ELF linker does it for us.
859 (elf_backend_can_refcount): Define.
860 (bfd_elf64_bfd_link_hash_table_create): Define.
861 (elf_backend_copy_indirect_symbol): Define.
862 (elf_backend_reloc_type_class): Define.
863 (elf_backend_*, bfd_elf64_bfd_* defines): Sort.
864
21d17a58
AM
8652001-09-29 Alan Modra <amodra@bigpond.net.au>
866
51b64d56
AM
867 * elf-bfd.h (struct elf_link_local_dynamic_entry): Add init_refcount.
868 (struct elf_backend_data): Add can_refcount.
869 * elf.c (_bfd_elf_link_hash_newfunc): Get rid of a few casts. Set
870 got.refcount and plt.refcount from init_refcount.
871 (_bfd_elf_link_hash_table_init): Set up init_refcount.
872 (_bfd_elf_link_hash_copy_indirect): Reference got/plt.refcount
873 rather than got/plt.offset, and test for <= 0 rather than -1.
874 * elflink.h (size_dynamic_sections): Set init_refcount to -1.
875 * elfxx-target.h (elf_backend_can_refcount): Define.
876 (elfNN_bed): Init can_refcount.
877 * linker.c (_bfd_link_hash_newfunc): Get rid of a few casts.
878 (_bfd_generic_link_hash_newfunc): Likewise.
879 * elf32-cris.c (cris_elf_check_relocs): Modify for refcounts
880 starting from zero.
881 (elf_backend_can_refcount): Define.
882 * elf32-hppa.c (elf32_hppa_check_relocs): Modify for refcounts
883 starting from zero.
884 (elf32_hppa_copy_indirect_symbol): Make static to agree with
885 prototype.
886 (elf_backend_can_refcount): Define.
887 * elf32-i386.c (elf_i386_check_relocs): Modify for refcounts
888 starting from zero.
889 (allocate_dynrelocs): Set plt/got.offset rather than *.refcount.
890 (elf_i386_finish_dynamic_symbol): Expand SHN_UNDEF comment.
891 (elf_i386_finish_dynamic_sections): Use local var so line < 80 chars.
892 (elf_backend_can_refcount): Define.
893 (elf_i386_copy_indirect_symbol): Make static to agree with
894 prototype. Formatting fix.
895 * elf32-m68k.c (elf_m68k_check_relocs): Modify for refcounts
896 starting from zero.
897 (elf_backend_can_refcount): Define.
898 * elf32-ppc.c (ppc_elf_check_relocs): Modify for refcounts
899 starting from zero.
900 (elf_backend_can_refcount): Define.
901 * elf32-s390.c (elf_s390_check_relocs): Modify for refcounts
902 starting from zero.
903 (elf_backend_can_refcount): Define.
904 * elf64-s390.c (elf_s390_check_relocs): Modify for refcounts
905 starting from zero.
906 (elf_backend_can_refcount): Define.
907 * elf64-x86-64.c (elf64_x86_64_check_relocs): Modify for refcounts
908 starting from zero.
909 (elf_backend_can_refcount): Define.
910
21d17a58
AM
911 * som.c (som_write_symbol_strings): Cast current_offset in
912 bfd_seek call to match param type.
913
78ae4cb9
JB
9142001-09-28 J. Brobecker <brobecker@gnat.com>
915
916 * som.c (som_write_symbol_strings): Fix incorrect type of
917 current_offset to match the function definition. Fixes a build
918 failure on HPUX-11.00.
919
65db3b0d
RH
9202001-09-28 Richard Henderson <rth@redhat.com>
921
e0aae569
RH
922 * elfxx-target.h [section_flags]: Add SEC_ARCH_BIT_0, SEC_SMALL_DATA,
923 SEC_MERGE, SEC_STRINGS.
924
65db3b0d
RH
925 * section.c (SEC_ARCH_BIT_0): New; replace unused SEC_BALIGN.
926 * bfd-in2.h: Rebuild.
927
ced53ee5
AM
9282001-09-28 Alan Modra <amodra@bigpond.net.au>
929
ffaef159
AM
930 * elf64-x86-64.c (elf64_x86_64_reloc_type_lookup): Don't map bfd
931 reloc code using x86_64_reloc_map.
932
3ac8354b
AM
933 * elf32-hppa.c (elf32_hppa_check_relocs): Update comment since we
934 no longer allocate here. Localise some vars to blocks where they
935 are used.
936 (elf32_hppa_adjust_dynamic_symbol): Correct a comment. Delay
937 setting of vars until needed.
938 (allocate_dynrelocs): Don't create a .plt entry without a reloc
939 when symbol visibilty makes a function local.
940 (elf32_hppa_finish_dynamic_symbol): Move expressions out of
941 swap_reloca_out function calls.
942 (elf32_hppa_relocate_section): Likewies. Comment typo fix.
943 (elf32_hppa_finish_dynamic_sections): Migrate common code out of
944 switch statement.
945
0ac8d2ca
AM
946 * elf32-i386.c (elf_i386_check_relocs): Update comment since we
947 no longer allocate here. Localise some vars to blocks where they
948 are used. Remove separate switch stmt for creating .got sec.
949 (elf_i386_adjust_dynamic_symbol): Correct a comment. Remove
950 redundant casts and aborts. Delay setting of vars until needed.
951 (allocate_dynrelocs): Remove redundant casts and aborts.
952 (elf_i386_size_dynamic_sections): Move comment.
953 (elf_i386_finish_dynamic_symbol): Move expressions out of function
954 calls.
955 (elf_i386_relocate_section): Likewise. Comment typo fix.
956 (elf_i386_finish_dynamic_sections): Migrate common code out of
957 switch statement.
958 (elf_backend_* defines): Sort.
959
ced53ee5
AM
960 * elf32-i386.c (allocate_dynrelocs): Don't create a .plt entry
961 without a reloc when symbol visibilty makes a function local.
962
63b0f745
NC
9632001-09-27 Nick Clifton <nickc@cambridge.redhat.com>
964
06317a27
NC
965 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix detection of
966 conflicting float flags.
63b0f745 967
ebe50bae
AM
9682001-09-26 Alan Modra <amodra@bigpond.net.au>
969
970 * elf32-i386 (elf_i386_copy_indirect_symbol): New function.
971 (elf_backend_copy_indirect_symbol): Define.
972 (struct elf_i386_link_hash_entry): Rename "root" to "elf".
973 (struct elf_i386_link_hash_table): Likewise.
974 (link_hash_newfunc): Get rid of unnecessary casts.
975 (elf_i386_link_hash_table_create): Likewise.
976 (elf_i386_check_relocs): Initialise local_got_refcounts to 0.
977 Don't test input section SEC_READONLY here to try to avoid copy
978 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
979 (elf_i386_adjust_dynamic_symbol): Check output section SEC_READONLY
980 here to properly test whether we need copy relocs. Do so for weak
981 syms too.
982
983 * elf32-hppa (elf32_hppa_copy_indirect_symbol): New function.
984 (elf_backend_copy_indirect_symbol): Define.
985 (struct elf32_hppa_link_hash_table): Rename "root" to "elf".
986 (stub_hash_newfunc): Get rid of unnecessary casts.
987 (hppa_link_hash_newfunc): Likewise.
988 (elf32_hppa_check_relocs): Initialise local_got_refcounts to 0.
989 Don't test input section SEC_READONLY here to try to avoid copy
990 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
991 (elf32_hppa_adjust_dynamic_symbol): Check output section SEC_READONLY
992 here to properly test whether we need copy relocs. Do so for weak
993 syms too.
994
af6166c0
AM
9952001-09-26 Alan Modra <amodra@bigpond.net.au>
996
997 * bfd.c (_bfd_default_error_handlerl): Define using VPARAMS,
998 VA_OPEN, VA_FIXEDARG, VA_CLOSE.
999 (bfd_archive_filename): Cast bfd_malloc arg to the correct size.
1000
e62de969
JJ
10012001-09-25 Jakub Jelinek <jakub@redhat.com>
1002
1003 * elf64-sparc.c (sparc64_elf_build_plt): Fix .plt[32768+] slot
1004 computation.
1005
09c1cc88
L
10062001-09-25 H.J. Lu <hjl@gnu.org>
1007
1008 * bfd-in2.h: Regenerated.
1009
38701953
AM
10102001-09-25 Alan Modra <amodra@bigpond.net.au>
1011
1012 * elf32-i386.c: Add comment re linker function names and ordering.
1013 (elf_i386_link_hash_newfunc): Rename to link_hash_newfunc.
1014 (elf_i386_grok_prstatus): Move before linker functions.
1015 (elf_i386_grok_psinfo): Likewise.
1016 (elf_i386_fake_sections): Move so that functions are ordered.
1017 (elf_i386_reloc_type_class): Likewise. Comment function purpose.
1018
98ceb8ce
AM
10192001-09-25 Alan Modra <amodra@bigpond.net.au>
1020
0ac8d2ca 1021 * elf32-hppa.c: Rename occurrences of "hplink" to "htab"
83c81bfe
AM
1022 throughout file.
1023
98ceb8ce
AM
1024 * elf32-hppa.c: (LONG_BRANCH_PIC_IN_SHLIB): Delete. Remove all
1025 code handling this option.
1026 (LONG_BRANCH_VIA_PLT): Likewise.
1027 (RELATIVE_DYNRELOCS): Define as zero.
1028 (struct elf32_hppa_dyn_reloc_entry): Add "sec", and
1029 "pc_count" fields. Remove "section" field.
1030 (elf32_hppa_link_hash_entry): Rename reloc_entries to dyn_relocs.
1031 (elf32_hppa_check_relocs): Don't allocate space for dynamic
1032 relocs here. Instead, record all needed dynamic relocs via
1033 dyn_relocs and local_dynrel. Cache pointer to "sreloc" section
1034 in elf_section_data.
1035 (elf32_hppa_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
1036 (allocate_plt_and_got_and_discard_relocs): Rename to
1037 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
1038 (readonly_dynrelocs): New function.
1039 (elf32_hppa_size_dynamic_sections): Mark output_bfd unused.
1040 Call readonly_dynrelocs to determine need for DT_TEXTREL.
1041 Rename "i" to "ibfd". Allocate space for local dyn relocs.
1042 (elf32_hppa_relocate_section): Make use of cached sreloc.
1043 (elf32_hppa_reloc_type_class): New function.
1044 (elf_backend_reloc_type_class): Define.
1045
0c715baa
AM
10462001-09-25 Alan Modra <amodra@bigpond.net.au>
1047
1048 * elf-bfd.h (struct bfd_elf_section_data): Add "local_dynrel"
1049 and "sreloc" fields.
1050 * elf32-i386.c (struct elf_i386_dyn_relocs): Add "sec", and
1051 "pc_count" fields. Remove "section" field.
1052 (elf_i386_check_relocs): Don't set DF_TEXTREL here. Don't
1053 allocate space for dynamic relocs here. Instead, record all
1054 needed dynamic relocs via dyn_relocs and local_dynrel. Cache
1055 pointer to "sreloc" section in elf_section_data.
1056 (elf_i386_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
1057 (allocate_plt_and_got_and_discard_relocs): Rename to
1058 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
1059 (readonly_dynrelocs): New function.
1060 (elf_i386_size_dynamic_sections): Call readonly_dynrelocs.
1061 Rename "i" to "ibfd". Allocate space for local dyn relocs.
1062 (elf_i386_relocate_section): Make use of cached sreloc.
1063
f51e552e
AM
10642001-09-24 Alan Modra <amodra@bigpond.net.au>
1065
1066 * elf-bfd.h (elf_backend_reloc_type_class): Pass in the entire
1067 reloc rather than just the type.
1068 (_bfd_elf_reloc_type_class): Likewise.
1069 * elf.c (_bfd_elf_reloc_type_class): Likewise.
1070 * elf32-arm.h (elf32_arm_reloc_type_class): Likewise.
1071 * elf32-cris.c (elf_cris_reloc_type_class): Likewise.
1072 * elf32-i386.c (elf_i386_reloc_type_class): Likewise.
1073 * elf32-m68k.c (elf32_m68k_reloc_type_class): Likewise.
1074 * elf32-ppc.c (ppc_elf_reloc_type_class): Likewise.
1075 * elf32-s390.c (elf_s390_reloc_type_class): Likewise.
1076 * elf32-sh.c (sh_elf_reloc_type_class): Likewise.
1077 * elf32-sparc.c (elf32_sparc_reloc_type_class): Likewise.
1078 * elf64-alpha.c (elf64_alpha_reloc_type_class): Likewise.
1079 * elf64-s390.c (elf_s390_reloc_type_class): Likewise.
1080 * elf64-sparc.c (sparc64_elf_reloc_type_class): Likewise.
1081 * elf64-x86-64.c (elf64_x86_64_reloc_type_class): Likewise.
1082 * elfxx-ia64.c (elfNN_ia64_reloc_type_class): Likewise.
1083 * elflink.h: Formatting fixes.
1084 (elf_link_sort_relocs): Make "count" and "size" bfd_size_type.
1085 Call bfd_zmalloc rather than calloc. Remove unnecessary cast of
1086 o->contents to PTR. Update call to elf_backend_reloc_type_class.
1087
0c35f01a
AM
10882001-09-22 John Reiser <jreiser@BitWagon.com>
1089
1090 * elfcode.h (elf_object_p): Allow for no section header at all in
1091 non-ET_REL files. Honor 0 for e_shnum, e_shstrndx, e_shoff.
1092
1e738b87
NC
10932001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
1094
1095 * elfxx-ia64.c: Fix compile time warning messages.
09c1cc88
L
1096 * coff-mcore.c: Fix compile time warning messages.
1097 * coff-ppc.c: Fix compile time warning messages.
1098 * coffcode.h: Fix compile time warning messages.
1099 * elf32-mips.c: Fix compile time warning messages.
1100 * elf64-alpha.c: Fix compile time warning messages.
1101 * libbfd.c: Fix compile time warning messages.
1102 * bfd-in2.h: Regenerate.
1e738b87 1103
923f08ff
AM
11042001-09-21 Alan Modra <amodra@bigpond.net.au>
1105
1106 * Makefile.am: Run "make dep-am".
1107 * Makefile.in: Regenerate.
1108
1109 * aoutx.h: Formatting fixes.
1110 * merge.c (_bfd_merged_section_offset): Break line at 80 chars.
1111
1112 * linker.c: Replace bfd_get_filename with bfd_archive_filename
1113 in error message.
1114
8f615d07
AM
11152001-09-21 Alan Modra <amodra@bigpond.net.au>
1116
1117 * bfd.c (bfd_archive_filename): New function.
1118 * bfd-in2.h: Regenerate.
1119 * aout-adobe.c: Replace bfd_get_filename with bfd_archive_filename
1120 in error messages where the bfd is an input bfd.
1121 * aout-cris.c: Likewise.
1122 * coff-arm.c: Likewise.
1123 * coff-mcore.c: Likewise.
1124 * coff-ppc.c: Likewise.
1125 * coff-rs6000.c: Likewise.
1126 * coff-sh.c: Likewise.
1127 * coff-tic54x.c: Likewise.
1128 * coff-tic80.c: Likewise.
1129 * coff64-rs6000.c: Likewise.
1130 * coffcode.h: Likewise.
1131 * coffgen.c: Likewise.
1132 * cofflink.c: Likewise.
1133 * ecofflink.c: Likewise.
1134 * elf-hppa.h: Likewise.
1135 * elf.c: Likewise.
1136 * elf32-arm.h: Likewise.
1137 * elf32-cris.c: Likewise.
1138 * elf32-gen.c: Likewise.
1139 * elf32-hppa.c: Likewise.
1140 * elf32-i370.c: Likewise.
1141 * elf32-i386.c: Likewise.
1142 * elf32-m32r.c: Likewise.
1143 * elf32-mcore.c: Likewise.
1144 * elf32-mips.c: Likewise.
1145 * elf32-ppc.c: Likewise.
1146 * elf32-s390.c: Likewise.
1147 * elf32-sh.c: Likewise.
1148 * elf32-sparc.c: Likewise.
1149 * elf32-v850.c: Likewise.
1150 * elf64-alpha.c: Likewise.
1151 * elf64-gen.c: Likewise.
1152 * elf64-ppc.c: Likewise.
1153 * elf64-s390.c: Likewise.
1154 * elf64-sparc.c: Likewise.
1155 * elf64-x86-64.c: Likewise.
1156 * elflink.h: Likewise.
1157 * elfxx-ia64.c: Likewise.
1158 * ieee.c: Likewise.
1159 * ihex.c: Likewise.
1160 * libbfd.c: Likewise.
1161 * pdp11.c: Likewise.
1162 * pe-mips.c: Likewise.
1163 * peicode.h: Likewise.
1164 * srec.c: Likewise.
1165 * xcofflink.c: Likewise.
1166
1167 * elf32-arm.h: Make _bfd_error_handler calls K&R compatible.
1168
1169 * elflink.c (_bfd_elf_create_linker_section): Better grammar for
1170 error message.
1171
1172 * coff-mcore.c (coff_mcore_relocate_section): Internalionalise
1173 error message.
1174
1175 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Constify stt_types.
1176 Consolidate error messages, and split long messages to two lines.
1177
671bae9c 11782001-09-20 John Reiser <jreiser@BitWagon.com>
83c81bfe 1179
f51e552e
AM
1180 * elf32-i386.c (elf_i386_relocate_section): Coordinate info->symbolic
1181 and info->allow_shlib_undefined.
1182 * elf32-cris.c: Likewise.
1183 * elf32-hppa.c: Likewise.
1184 * elf32-m68k.c: Likewise.
1185 * elf32-mips.c: Likewise.
1186 * elf32-ppc.c: Likewise.
1187 * elf32-s390.c: Likewise.
1188 * elf32-sh.c: Likewise.
1189 * elf32-sparc.c: Likewise.
1190 * elf64-alpha.c: Likewise.
1191 * elf64-hppa.c: Likewise.
1192 * elf64-ppc.c: Likewise.
1193 * elf64-s390.c: Likewise.
1194 * elf64-sparc.c: Likewise.
1195 * elf64-x86-64.c: Likewise.
1196 * elfxx-ia64.c: Likewise.
671bae9c 1197
3882b010
L
11982001-09-18 Bruno Haible <haible@clisp.cons.org>
1199
1200 * aoutx.h: Include "safe-ctype.h" instead of <ctype.h>.
1201 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
1202 * archive.c: Include "safe-ctype.h" instead of <ctype.h>.
1203 (_bfd_generic_read_ar_hdr_mag): Use ISDIGIT instead of isdigit.
1204 * archures.c: Include "safe-ctype.h" instead of <ctype.h>.
1205 (bfd_default_scan): Use ISDIGIT instead of isdigit.
1206 * bfd.c: Include "safe-ctype.h" instead of <ctype.h>.
1207 (bfd_scan_vma): Use ISXDIGIT/ISDIGIT/ISLOWER instead of
1208 isxdigit/isdigit/islower.
1209 * binary.c: Include "safe-ctype.h" instead of <ctype.h>.
1210 (mangle_name): Use ISALNUM instead of isalnum.
1211 * cpu-v850.c: Include "safe-ctype.h" instead of <ctype.h>.
1212 (scan): Use ISDIGIT instead of isdigit.
1213 * hosts/alphavms.h: Don't include <ctype.h>.
1214 * ieee.c: Include "safe-ctype.h" instead of <ctype.h>.
1215 (ieee_object_p): Use TOUPPER instead of toupper.
1216 * ihex.c: Include "safe-ctype.h" instead of <ctype.h>.
1217 (ihex_bad_byte): Use ISPRINT instead of isprint.
1218 * merge.c: Don't include <ctype.h>.
1219 * oasys.c: Include "safe-ctype.h" instead of <ctype.h>.
1220 (oasys_write_sections): Use ISDIGIT instead of isdigit.
1221 * pdp11.c: Include "safe-ctype.h" instead of <ctype.h>.
1222 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
1223 * ppcboot.c: Include "safe-ctype.h" instead of <ctype.h>.
1224 (mangle_name): Use ISALNUM instead of isalnum.
1225 * som.c: Include "safe-ctype.h" instead of <ctype.h>.
1226 (som_set_reloc_info): Use ISUPPER/ISLOWER/ISDIGIT instead of
1227 isupper/islower/isdigit.
1228 (som_decode_symclass): Use TOUPPER instead of toupper.
1229 * srec.c: Include "safe-ctype.h" instead of <ctype.h>.
1230 (srec_bad_byte): Use ISPRINT instead of isprint.
1231 (srec_scan): Use ISSPACE instead of isspace.
1232 * stabs.c: Include "safe-ctype.h" instead of <ctype.h>.
1233 (_bfd_link_section_stabs): Use ISDIGIT instead of isdigit.
1234 * syms.c: Include "safe-ctype.h"
1235 (islower, toupper): Remove macro definitions.
1236 (bfd_decode_symclass): Use TOUPPER instead of toupper.
1237 * vms-gsd.c: Don't include <ctype.h>.
1238 * vms-hdr.c: Include "safe-ctype.h" instead of <ctype.h>.
1239 (_bfd_vms_write_hdr): Use ISLOWER/TOUPPER instead of
1240 islower/toupper.
1241 * vms-tir.c: Don't include <ctype.h>.
1242
dc810e39
AM
12432001-09-18 Alan Modra <amodra@bigpond.net.au>
1244
1245 * libbfd.c (bfd_bread): New function replacing bfd_read without
1246 redundant params. Allow reads up to (size_t) -2 in length.
1247 (bfd_bwrite): Similarly for bfd_write.
1248 (real_read): Return a size_t.
1249 (bfd_read): Call bfd_bread.
1250 (bfd_write): Call bfd_bwrite.
1251 (warn_deprecated): New function to annoy everybody.
1252 (bfd_get_file_window): Don't call bfd_set_error unnecessarily.
1253 * bfd-in.h (bfd_bread, bfd_bwrite, warn_deprecated): Declare.
1254 (bfd_read, bfd_write): Define as macro.
1255 * aix386-core.c: Replace calls to bfd_read with bfd_bread, and
1256 likewise for bfd_write. Ensure function args are correct size by
1257 using casts or local vars. In some cases, remove unnecessary
1258 casts. Formatting fixes, in some cases removing a large expression
1259 from function args by using a local var. Replace CONST with const.
1260 Modify variable types to avoid warings. Use casts to avoid
1261 warnings when using negative numbers in unsigned expressions.
1262 * aout-adobe.c: Likewise.
1263 * aout-arm.c: Likewise.
1264 * aout-cris.c: Likewise.
1265 * aout-encap.c: Likewise.
1266 * aout-ns32k.c: Likewise.
1267 * aout-target.h: Likewise.
1268 * aout-tic30.c: Likewise.
1269 * aoutf1.h: Likewise.
1270 * aoutx.h: Likewise.
1271 * archive.c: Likewise.
1272 * archures.c: Likewise.
1273 * bfd-in.h: Likewise.
1274 * bfd.c: Likewise.
1275 * binary.c: Likewise.
1276 * bout.c: Likewise.
1277 * cache.c: Likewise.
1278 * cisco-core.c: Likewise.
1279 * coff-a29k.c: Likewise.
1280 * coff-alpha.c: Likewise.
1281 * coff-arm.c: Likewise.
1282 * coff-h8300.c: Likewise.
1283 * coff-h8500.c: Likewise.
1284 * coff-i386.c: Likewise.
1285 * coff-i860.c: Likewise.
1286 * coff-i960.c: Likewise.
1287 * coff-ia64.c: Likewise.
1288 * coff-m68k.c: Likewise.
1289 * coff-m88k.c: Likewise.
1290 * coff-mcore.c: Likewise.
1291 * coff-mips.c: Likewise.
1292 * coff-ppc.c: Likewise.
1293 * coff-rs6000.c: Likewise.
1294 * coff-sh.c: Likewise.
1295 * coff-sparc.c: Likewise.
1296 * coff-stgo32.c: Likewise.
1297 * coff-tic30.c: Likewise.
1298 * coff-tic54x.c: Likewise.
1299 * coff-tic80.c: Likewise.
1300 * coff-w65.c: Likewise.
1301 * coff-z8k.c: Likewise.
1302 * coff64-rs6000.c: Likewise.
1303 * coffcode.h: Likewise.
1304 * coffgen.c: Likewise.
1305 * cofflink.c: Likewise.
1306 * coffswap.h: Likewise.
1307 * corefile.c: Likewise.
1308 * cpu-arc.c: Likewise.
1309 * cpu-h8300.c: Likewise.
1310 * cpu-h8500.c: Likewise.
1311 * cpu-i960.c: Likewise.
1312 * cpu-ia64-opc.c: Likewise.
1313 * cpu-ns32k.c: Likewise.
1314 * cpu-pdp11.c: Likewise.
1315 * cpu-pj.c: Likewise.
1316 * cpu-sh.c: Likewise.
1317 * cpu-w65.c: Likewise.
1318 * cpu-z8k.c: Likewise.
1319 * dwarf1.c: Likewise.
1320 * dwarf2.c: Likewise.
1321 * ecoff.c: Likewise.
1322 * ecofflink.c: Likewise.
1323 * ecoffswap.h: Likewise.
1324 * elf-bfd.h: Likewise.
1325 * elf-hppa.h: Likewise.
1326 * elf-m10200.c: Likewise.
1327 * elf-m10300.c: Likewise.
1328 * elf.c: Likewise.
1329 * elf32-arc.c: Likewise.
1330 * elf32-arm.h: Likewise.
1331 * elf32-avr.c: Likewise.
1332 * elf32-cris.c: Likewise.
1333 * elf32-fr30.c: Likewise.
1334 * elf32-gen.c: Likewise.
1335 * elf32-h8300.c: Likewise.
1336 * elf32-hppa.c: Likewise.
1337 * elf32-i370.c: Likewise.
1338 * elf32-i386.c: Likewise.
1339 * elf32-i860.c: Likewise.
1340 * elf32-m32r.c: Likewise.
1341 * elf32-m68k.c: Likewise.
1342 * elf32-mcore.c: Likewise.
1343 * elf32-mips.c: Likewise.
1344 * elf32-openrisc.c: Likewise.
1345 * elf32-pj.c: Likewise.
1346 * elf32-ppc.c: Likewise.
1347 * elf32-s390.c: Likewise.
1348 * elf32-sh-lin.c: Likewise.
1349 * elf32-sh.c: Likewise.
1350 * elf32-sparc.c: Likewise.
1351 * elf32-v850.c: Likewise.
1352 * elf64-alpha.c: Likewise.
1353 * elf64-hppa.c: Likewise.
1354 * elf64-mips.c: Likewise.
1355 * elf64-ppc.c: Likewise.
1356 * elf64-s390.c: Likewise.
1357 * elf64-sparc.c: Likewise.
1358 * elf64-x86-64.c: Likewise.
1359 * elfarm-nabi.c: Likewise.
1360 * elfcode.h: Likewise.
1361 * elfcore.h: Likewise.
1362 * elflink.c: Likewise.
1363 * elflink.h: Likewise.
1364 * elfxx-ia64.c: Likewise.
1365 * elfxx-target.h: Likewise.
1366 * format.c: Likewise.
1367 * hash.c: Likewise.
1368 * hp300hpux.c: Likewise.
1369 * hppabsd-core.c: Likewise.
1370 * hpux-core.c: Likewise.
1371 * i386aout.c: Likewise.
1372 * i386dynix.c: Likewise.
1373 * i386linux.c: Likewise.
1374 * i386lynx.c: Likewise.
1375 * i386mach3.c: Likewise.
1376 * i386msdos.c: Likewise.
1377 * i386os9k.c: Likewise.
1378 * ieee.c: Likewise.
1379 * ihex.c: Likewise.
1380 * irix-core.c: Likewise.
1381 * libaout.h: Likewise.
1382 * libbfd-in.h: Likewise.
1383 * libbfd.c: Likewise.
1384 * libcoff-in.h: Likewise.
1385 * libecoff.h: Likewise.
1386 * libieee.h: Likewise.
1387 * libnlm.h: Likewise.
1388 * libpei.h: Likewise.
1389 * libxcoff.h: Likewise.
1390 * linker.c: Likewise.
1391 * lynx-core.c: Likewise.
1392 * m68klinux.c: Likewise.
1393 * merge.c: Likewise.
1394 * mipsbsd.c: Likewise.
1395 * netbsd-core.c: Likewise.
1396 * nlm.c: Likewise.
1397 * nlm32-alpha.c: Likewise.
1398 * nlm32-i386.c: Likewise.
1399 * nlm32-ppc.c: Likewise.
1400 * nlm32-sparc.c: Likewise.
1401 * nlmcode.h: Likewise.
1402 * nlmswap.h: Likewise.
1403 * ns32k.h: Likewise.
1404 * oasys.c: Likewise.
1405 * opncls.c: Likewise.
1406 * osf-core.c: Likewise.
1407 * pc532-mach.c: Likewise.
1408 * pdp11.c: Likewise.
1409 * pe-mips.c: Likewise.
1410 * peXXigen.c: Likewise.
1411 * peicode.h: Likewise.
1412 * ppcboot.c: Likewise.
1413 * ptrace-core.c: Likewise.
1414 * reloc.c: Likewise.
1415 * reloc16.c: Likewise.
1416 * riscix.c: Likewise.
1417 * rs6000-core.c: Likewise.
1418 * sco5-core.c: Likewise.
1419 * section.c: Likewise.
1420 * som.c: Likewise.
1421 * sparclinux.c: Likewise.
1422 * sparclynx.c: Likewise.
1423 * srec.c: Likewise.
1424 * stabs.c: Likewise.
1425 * sunos.c: Likewise.
1426 * syms.c: Likewise.
1427 * targets.c: Likewise.
1428 * tekhex.c: Likewise.
1429 * trad-core.c: Likewise.
1430 * versados.c: Likewise.
1431 * vms-gsd.c: Likewise.
1432 * vms-hdr.c: Likewise.
1433 * vms-misc.c: Likewise.
1434 * vms-tir.c: Likewise.
1435 * vms.c: Likewise.
1436 * vms.h: Likewise.
1437 * xcofflink.c: Likewise.
1438 * bfd-in2.h: Regenerate.
1439 * libbfd.h: Regenerate.
1440 * libcoff.h: Regenerate.
1441
1442 * bfd.c (struct _bfd): Make "where" and "origin" unsigned.
1443 * bfd-in.h (file_ptr): Change from a long int to a bfd_signed_vma.
1444 (ufile_ptr): Define.
1445 (bfd_tell): Return a ufile_ptr.
1446 * libbfd.c (bfd_tell): Likewise.
1447 (bfd_seek): Use bfd_size_type locals. Don't call bfd_set_error
1448 unnecessarily.
1449 * aix386-core.c: Test != 0 for bfd_seek errors rather than < 0.
1450 * aoutf1.h: Likewise.
1451 * som.c: Likewise.
1452 * cache.c (bfd_cache_lookup_worker): Guard against abfd->where
1453 larger than unsigned long can represent.
1454
1455 * libbfd.c (bfd_malloc): Take a bfd_size_type arg. Error if
1456 size overflows size_t.
1457 (bfd_realloc): Likewise.
1458 (bfd_zmalloc): Likewise.
1459 * opncls.c (bfd_alloc): Likewise.
1460 (bfd_zalloc): Likewise.
1461 * libbfd-in.h (bfd_malloc, bfd_realloc, bfd_zmalloc): Update.
1462 (bfd_alloc, bfd_zalloc): Update.
1463
1464 * libbfd.c (bfd_get_8): Mask with 0xff in case char is more than
1465 8 bits.
1466 (bfd_get_signed_8): Likewise.
1467 (H_PUT_64, H_PUT_32, H_PUT_16, H_PUT_8,
1468 H_PUT_S64, H_PUT_S32, H_PUT_S16, H_PUT_S8,
1469 H_GET_64, H_GET_32, H_GET_16, H_GET_8,
1470 H_GET_S64, H_GET_S32, H_GET_S16, H_GET_S8): Define and use.
1471 * libaout.h: Likewise define and use here.
1472 * aout-adobe.c: Use H_GET_* and H_PUT_* macros.
1473 * aout-arm.c: Likewise.
1474 * aout-encap.c: Likewise.
1475 * aout-ns32k.c: Likewise.
1476 * aout-tic30.c: Likewise.
1477 * aoutf1.h: Likewise.
1478 * aoutx.h: Likewise.
1479 * bout.c: Likewise.
1480 * coff-alpha.c: Likewise.
1481 * coff-h8300.c: Likewise.
1482 * coff-h8500.c: Likewise.
1483 * coff-i960.c: Likewise.
1484 * coff-ia64.c: Likewise.
1485 * coff-m88k.c: Likewise.
1486 * coff-mips.c: Likewise.
1487 * coff-ppc.c: Likewise.
1488 * coff-rs6000.c: Likewise.
1489 * coff-sh.c: Likewise.
1490 * coff-sparc.c: Likewise.
1491 * coff-stgo32.c: Likewise.
1492 * coff-tic30.c: Likewise.
1493 * coff-tic80.c: Likewise.
1494 * coff-w65.c: Likewise.
1495 * coff-z8k.c: Likewise.
1496 * coff64-rs6000.c: Likewise.
1497 * coffgen.c: Likewise.
1498 * cofflink.c: Likewise.
1499 * coffswap.h: Likewise.
1500 * ecoff.c: Likewise.
1501 * ecoffswap.h: Likewise.
1502 * elf.c: Likewise.
1503 * elf32-mips.c: Likewise.
1504 * elf64-mips.c: Likewise.
1505 * hp300hpux.c: Likewise.
1506 * i386dynix.c: Likewise.
1507 * i386lynx.c: Likewise.
1508 * i386msdos.c: Likewise.
1509 * i386os9k.c: Likewise.
1510 * libpei.h: Likewise.
1511 * nlm32-alpha.c: Likewise.
1512 * nlm32-i386.c: Likewise.
1513 * nlm32-ppc.c: Likewise.
1514 * nlmcode.h: Likewise.
1515 * nlmswap.h: Likewise.
1516 * oasys.c: Likewise.
1517 * pdp11.c: Likewise.
1518 * pe-mips.c: Likewise.
1519 * peXXigen.c: Likewise.
1520 * peicode.h: Likewise.
1521 * riscix.c: Likewise.
1522 * sunos.c: Likewise.
1523 * xcofflink.c: Likewise.
1524 * elfcode.h: (put_word, get_word, put_signed_word, get_signed_word):
1525 Rename to H_PUT_WORD, H_GET_WORD, H_PUT_SIGNED_WORD, H_GET_SIGNED_WORD.
1526 * coff-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Don't define. Use
1527 equivalent H_PUT_* macro instead.
1528 (GETWORD, GETHALF, GETBYTE): Similarly.
1529 * coff64-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1530 (GETWORD, GETHALF, GETBYTE): Likewise.
1531 * coffswap.h (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1532
1533 * bfd-in.h (struct orl): Change "pos" to a union.
1534 * archive.c (_bfd_compute_and_write_armap): Use it instead of casts.
1535 (bsd_write_armap): Here too.
1536 (coff_write_armap): And here.
1537 * coff-rs6000.c (xcoff_write_armap_old): And here.
1538 (xcoff_write_one_armap_big): And here.
1539 (xcoff_write_armap_big): And here.
1540 * ecoff.c (_bfd_ecoff_write_armap): And here.
1541 * elf64-mips.c (mips_elf64_write_armap): And here.
1542
1543 * aoutf1.h (sunos_set_arch_mach): Make "mach" param an enum.
1544 * elf-m10300.c (elf_mn10300_mach): Return an unsigned long.
1545 * elf32-h8300.c (elf32_h8_mach): Likewise.
1546 * elf32-mips.c (elf_mips_mach): Likewise.
1547 * sparclynx.c (NAME(lynx,set_arch_mach)): Likewise.
1548
1549 * aix386-core.c (aix386_core_file_p): Remove redundant bfd_release
1550 calls.
1551 (aix386_core_vec): Typo fix.
1552
1553 * aout-arm.c: Include libaout.h and aout/aout64.h after N_TXTADDR
1554 etc. to avoid redefined macro warning.
1555 (MY(put_reloc)): Use bfd_vma for "value" rather than long.
1556 (MY(fix_pcrel_26)): Likewise.
1557 * aout-ns32k.c (MY(put_reloc)): Likewise.
1558 * aout-cris.c (MY(swap_ext_reloc_out)): Likewise for r_addend.
1559 * aoutx.h (NAME(aout,swap_ext_reloc_out)): Likewise.
1560 * coff-arm.c (coff_arm_relocate_section): Likewise for my_offset.
1561
1562 * aout-encap.c: Include "file", not <file> for binutils headers.
1563 (encap_object_p): Half baked attempt to fix compile errors in
1564 code dealing with "magic".
1565
1566 * aout-ns32k.c: Include "file", not <file> for binutils headers.
1567 (_bfd_ns32k_relocate_contents): get_data and put_data manipulate
1568 bfd_vma's rather than longs.
1569 * cpu-ns32k.c (ns32k_sign_extend): Delete.
1570 (_bfd_ns32k_get_displacement): Return a bfd_vma, don't pass in offset.
1571 (_bfd_ns32k_get_immediate): Likewise. Add code for 8 byte values,
1572 remove case 3.
1573 (_bfd_ns32k_put_displacement): Accept a bfd_vma, don't pass in offset.
1574 Use unsigned comparisons.
1575 (bfd_ns32k_put_immediate): Likewise, and add code for 8 byte values.
1576 (do_ns32k_reloc): get_data and put_data operate on bfd_vma's.
1577 (_bfd_do_ns32k_reloc_contents): Likewise.
1578 * ns32k.h (_bfd_ns32k_get_displacement): Update prototype.
1579 (_bfd_ns32k_get_immediate): Likewise.
1580 (_bfd_ns32k_put_displacement): Likewise.
1581 (_bfd_ns32k_put_immediate): Likewise.
1582 (bfd_reloc_status_type): Likewise.
1583
1584 * aoutx.h (NAME(aout,find_nearest_line)): Rename 'p' to 'colon'
1585 to avoid shadowing.
1586 * pdp11.c (NAME(aout,find_nearest_line)): Likewise.
1587 * coff-h8300.c (h8300_reloc16_extra_cases): Remove shadowing "value".
1588 * coff-ppc.c (enum ref_category): Rename "data" to "tocdata" to
1589 avoid shadowing.
1590 (record_toc): Use a bfd_signed_vma for our_toc_offset.
1591 * coffcode.h (coff_write_relocs): Rename "i" to avoid shadowing.
1592 * elf.c (bfd_elf_get_bfd_needed_list): Rename "link" var to avoid
1593 shadow warning.
1594 (_bfd_elfcore_strndup): Likewise for "dup".
1595 * elf32-cris.c (cris_elf_relocate_section): "symname" instead of
1596 "name" to avoid shadowing.
1597 * elf32-hppa.c (elf32_hppa_relocate_section): Remove duplicate
1598 definition of "off".
1599 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1600 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Remove duplicate
1601 definition of "s".
1602 (_bfd_mips_elf_final_link): Rename "i" to "j". Remove duplicate
1603 "secpp".
1604 * elf64-x86-64.c (elf64_x86_64_relocate_section): Rename inner "indx"
1605 to avoid shadowing.
1606 * elflink.h (elf_link_add_object_symbols): Rename "link" to "shlink"
1607 to avoid shadowing.
1608 (elf_link_input_bfd): Likewise.
1609 (elf_bfd_final_link): Remove duplicate innermost "off" var.
1610 * oasys.c (oasys_write_data): Rename innermost "p" to "sym".
1611 * reloc16.c (bfd_coff_reloc16_relax_section): Rename "i" param to
1612 "input_section".
1613 * som.c (som_prep_for_fixups): Rename inner "i" to "j".
1614 * sunos.c (sunos_add_dynamic_symbols): Localise "s" var.
1615 (sunos_write_dynamic_symbol): Remove unused vars.
1616 * syms.c (_bfd_stab_section_find_nearest_line): Remove duplicate
1617 innermost "directory_name" and "file_name" vars.
1618 * tekhex.c (first_phase): Rename local var "type" to "stype".
1619 (tekhex_write_object_contents): Rename innermost "s" to "sym".
1620 * vms-gsd.c (vms_secflag_by_name): Change "size" param to "hassize",
1621 doing comparison at caller.
1622 (vms_esecflag_by_name): Likewise.
1623 * vms-tir.c (etir_sto): Rename innermost "psect" to "psect1".
1624 * xcofflink.c (xcoff_link_input_bfd): Delete duplicate innermost "o".
1625 (xcoff_write_global_symbol): Rename "p" param to "inf".
1626
1627 * cisco-core.c: Add missing prototypes.
1628 (cisco_core_file_failing_command): Add ATTRIBUTE_UNUSED.
1629 (cisco_core_file_failing_signal): Likewise.
1630 (cisco_core_file_matches_executable_p): Likewise.
1631 * hpux-core.c (hpux_core_core_file_failing_signal): Likewise.
1632 * netbsd-core.c (netbsd_core_file_matches_executable_p): Likewise.
1633 * osf-core.c (osf_core_core_file_matches_executable_p): Likewise.
1634 * sco5-core.c (sco5_core_file_matches_executable_p): Likewise.
1635
1636 * coff-arm.c (coff_arm_link_hash_table): Use bfd_size_type for
1637 thumb_glue_size and arm_glue_size.
1638 * elf32-arm.h (elf32_arm_link_hash_table): Likewise here.
1639
1640 * coff64-rs6000.c: Group prototypes together.
1641
1642 * coffcode.h (coff_set_arch_mach): Add ATTRIBUTE_UNUSED.
1643 (buy_and_read): Remove "seek" param. Change "size" to bfd_size_type.
1644
1645 * cpu-arc.c: Add missing prototypes.
1646 * cpu-h8500.c: Likewise.
1647 * cpu-i960.c: Likewise.
1648 * cpu-pj.c: Likewise.
1649 * cpu-sh.c: Likewise.
1650 * cpu-w65.c: Likewise.
1651 * cpu-z8k.c: Likewise.
1652 * elf32-fr30.c: Likewise.
1653 * elf32-h8300.c: Likewise.
1654 * elf32-i370.c: Likewise.
1655 * hpux-core.c: Likewise.
1656 * versados.c: Likewise.
1657
1658 * cpu-h8300.c (bfd_default_scan_num_mach): Don't declare.
1659 * cpu-h8500.c: Likewise.
1660 * cpu-i960.c: Likewise.
1661 * cpu-z8k.c: Likewise.
1662
1663 * cpu-ia64-opc.c: Correct comment.
1664
1665 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Remove unused var.
1666
1667 * elf-bfd.h (elf_size_info): Change count param of write_out_phdrs
1668 to unsigned.
1669 (bfd_elf32_write_out_phdrs): Likewise.
1670 (bfd_elf64_write_out_phdrs): Likewise.
1671 (elf_linker_section_pointers): Change addend to bfd_vma.
1672 (_bfd_elf_find_pointer_linker_section): Likewise.
1673 (_bfd_elfcore_make_pseudosection): Change size param to size_t and
1674 filepos to unsigned file_ptr.
1675 (_bfd_elfcore_strndup): Change max param to size_t.
1676 * elf.c (_bfd_elfcore_make_pseudosection): As above.
1677 (_bfd_elfcore_strndup): Likewise.
1678 (_bfd_elf_find_pointer_linker_section): Likewise.
1679
1680 * elf-hppa.h (elf_hppa_relocate_insn): Return an int, and change
1681 insn and sym_value to ints.
1682
1683 * elf.c (elf_read): Make "offset" param a file_ptr, "size" a
1684 bfd_size_type.
1685 (elfcore_read_notes): Likewise.
1686
1687 * elf32-arm.h (elf32_arm_final_link_relocate): Change sym_flags
1688 param from unsigned char to int.
1689 (elf32_arm_relocate_section): If USE_REL, cast "rel" appropriately
1690 for info_to_howto call.
1691 (add_dynamic_entry): Define macro.
1692 (elf32_arm_size_dynamic_sections): Use add_dynamic_entry.
1693
1694 * elf32-cris.c (add_dynamic_entry): Define macro.
1695 (elf_cris_size_dynamic_sections): Use add_dynamic_entry.
1696
1697 * elf32-h8300.c (elf32_h8_final_write_processing): Make static.
1698 (elf32_h8_object_p): Likewise.
1699 (elf32_h8_merge_private_bfd_data): Likewise.
1700 (elf32_h8_relax_section): Cast gap to int so signed comparisons work.
1701
1702 * elf32-hppa.c (add_dynamic_entry): Define macro.
1703 (elf32_hppa_size_dynamic_sections): Use it.
1704 * elf32-i370.c (add_dynamic_entry): Define macro.
1705 (i370_elf_size_dynamic_sections): Use it.
1706 (i370_noop): Make static.
1707 * elf32-i386.c (add_dynamic_entry): Define macro.
1708 (elf_i386_size_dynamic_sections): Use it.
1709 * elf32-m68k.c (add_dynamic_entry): Define macro.
1710 (elf_m68k_size_dynamic_sections): Use it.
1711 * elf32-ppc.c (add_dynamic_entry): Define macro.
1712 (ppc_elf_size_dynamic_sections): Use it.
1713 * elf32-s390.c (add_dynamic_entry): Define macro.
1714 (elf_s390_size_dynamic_sections): Use it.
1715 * elf64-alpha.c (add_dynamic_entry): Define macro.
1716 (elf64_alpha_size_dynamic_sections): Use it.
1717 * elf64-hppa.c (add_dynamic_entry): Define macro.
1718 (elf64_hppa_size_dynamic_sections): Use it.
1719 * elf64-ppc.c (add_dynamic_entry): Define macro.
1720 (ppc64_elf_size_dynamic_sections): Use it.
1721 * elf64-s390.c (add_dynamic_entry): Define macro.
1722 (elf_s390_size_dynamic_sections): Use it.
1723 * elf64-sparc.c (add_dynamic_entry): Define macro.
1724 (sparc64_elf_size_dynamic_sections): Use it.
1725 * elf64-x86-64.c (add_dynamic_entry): Define macro.
1726 (elf64_x86_64_size_dynamic_sections): Use it.
1727 * elfxx-ia64.c (add_dynamic_entry): Define macro.
1728 (elfNN_ia64_size_dynamic_sections): Use it.
1729
1730 * elf32-v850.c (SEXT24): Modify to avoid signed/unsigned warning.
1731 (v850_elf_perform_relocation): Make "r_type" param unsigned.
1732
1733 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Just return
1734 false if the first malloc fails rather than going via error_return.
1735
1736 * elf64-sparc.c (sparc64_elf_plt_entry_offset): Use a bfd_vma for
1737 "index" param.
1738 (sparc64_elf_plt_ptr_offset): Likewise, and for "max" param too.
1739
1740 * elflink.h (elf_link_input_bfd): s/ingored/ignored/ in error message.
1741
1742 * elfxx-ia64.c (global_sym_index): Return a long.
1743
1744 * ieee.c (get_symbol): Use int rather than char param.
1745 (ieee_slurp_sections): Move "section" var to inner blocks.
1746 (copy_expression): Don't init "value" to zero or worry about
1747 clearing to zero after using.
1748 (ieee_write_debug_part): Rename "output_buffer" to "obuff" to avoid
1749 shadowing.
1750
1751 * ihex.c (ihex_write_record): Make "count" var a size_t, "addr" an
1752 unsigned int.
1753
1754 * libbfd-in.h (BFD_ALIGN): Add cast to avoid signed/unsigned warning.
1755 (bfd_write_bigendian_4byte_int): Pass an unsigned int value param.
1756
1757 * mipsbsd.c (mips_fix_jmp_addr): Add "error_message" param.
1758
1759 * pc532-mach.c (MYNSX): Delete.
1760 (ns32kaout_bfd_reloc_type_lookup): Define prototype without MYNSX.
1761 (write_object_contents): Correct prototype.
1762
1763 * peicode.h (pe_ILF_build_a_bfd): Use an unsigned int param rather
1764 than unsigned short.
1765
1766 * section.c (bfd_set_section_contents): Remove redundant
1767 "offset < 0" test. Check that "count" doesn't overflow size_t.
1768 (bfd_get_section_contents): Likewise.
1769
1770 * som.c (som_fixup_formats): Add missing braces.
1771 (som_reloc_addend): Pass a bfd_vma for "addend".
1772
1773 * srec.c (srec_write_record): Pass "type" as an unsigned int.
1774 (srec_write_symbols): Remove an unnecessary var.
1775
1776 * targets.c (_bfd_target_vector): Sort entries. Sort externs
1777 to match.
1778 * configure.in: Sort to match. Bump version number.
1779 * configure: Regenerate.
1780
1781 * tekhex.c (move_section_contents): Assert offset == 0.
1782
1783 * versados.c (new_symbol_string): Constify arg.
1784 (process_esd): Use bfd_und_section_ptr rather than &bfd_und_section.
1785 (versados_get_symbol_info): Make static.
1786 (versados_print_symbol): Likewise.
1787 (versados_get_reloc_upper_bound): Likewise.
1788 (versados_canonicalize_reloc): Likewise.
1789
417412a2
NC
17902001-09-18 Nick Clifton <nickc@cambridge.redhat.com>
1791
1792 * elflink.h (elf_link_input_bfd): Fix typo in error message.
1793
bb731fb6
L
17942001-09-17 H.J. Lu <hjl@gnu.org>
1795
1796 * dwarf1.c (parse_die): Take a new arg for the end of the
1797 section. Return false if die is beyond the section.
1798 (parse_functions_in_unit): Pass the end of the section to
1799 parse_die ().
1800 (_bfd_dwarf1_find_nearest_line): Likewise.
1801
841989d6
NC
18022001-09-14 Michael Rauch <mrauch@netbsd.org>
1803
1804 * elf32-sparc.c (elf32_sparc_relocate_section): Treat R_SPARC_UA32
1805 just like R_SPARC_32.
1806
056a1d49
NC
18072001-09-14 Kevin Lo <kevlo@openbsd.org>
1808
1809 * configure.bfd: Add arm-openbsd target.
1810
4008bd9b
TS
18112001-09-14 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1812
1813 * config.bfd: Change machine triplets from mips*el*-* to mips*el-*.
1814 Add support for mips64.
1815
c11cc227
AO
18162001-09-13 Alexandre Oliva <aoliva@redhat.com>
1817
1818 * elf32-openrisc.c (ELF_MACHINE_ALT1): Define as EM_OPENRISC_OLD.
1819
aa4f99bb
AO
18202001-09-12 Alexandre Oliva <aoliva@redhat.com>
1821
1822 * elf.c (prep_headers): Get the machine code from the elf
1823 backend data.
1824 * elf-m10200.c (ELF_MACHINE_CODE): Redefine to EM_MN10200.
1825 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10200.
1826 * elf-m10300.c (ELF_MACHINE_CODE): Redefine to EM_MN10300.
1827 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10300.
1828 * elf-arc.c (arc_elf_final_write_processing): Don't override
1829 e_machine, it's now properly set in prep_headers.
1830 * elf32-avr.c (elf32_avr_object_p): Accept both EM_AVR and
1831 EM_AVR_OLD.
1832 (ELF_MACHINE_ALT1): Define to EM_AVR_OLD.
1833 * elf-d10v.c (ELF_MACHINE_CODE): Redefine to EM_D10V.
1834 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D10V.
1835 * elf-d30v.c (ELF_MACHINE_CODE): Redefine to EM_D30V.
1836 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D30V.
1837 * elf-fr30.c (ELF_MACHINE_CODE): Redefine to EM_FR30.
1838 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_FR30.
1839 * elf-m32r.c (ELF_MACHINE_CODE): Redefine to EM_M32R.
1840 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_M32R.
1841 * elf32-pj.c (ELF_MACHINE_ALT1): DEfine to EM_PJ_OLD.
1842 * elf-v850.c (ELF_MACHINE_CODE): Redefine to EM_V850.
1843 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_V850.
1844
204692d7
RH
18452001-09-11 Richard Henderson <rth@redhat.com>
1846
1847 * elf64-alpha.c (elf64_alpha_section_flags): New.
1848 (elf64_alpha_fake_sections): Map SEC_SMALL_DATA to SHF_ALPHA_GPREL.
1849
f94952df
RH
18502001-09-11 Richard Henderson <rth@redhat.com>
1851
1852 * elf64-alpha.c (elf64_alpha_relocate_section): Do not
1853 apply HINT relocations against dynamic symbols.
1854
146f1a87
L
18552001-09-11 H.J. Lu <hjl@gnu.org>
1856
f94952df 1857 * linker.c (link_action): Change COMMON_ROW\defw from CREF to COM.
146f1a87 1858
1cd6895c
RH
18592001-09-09 Richard Henderson <rth@redhat.com>
1860
96e2734b
RH
1861 * elf64-alpha.c: Delete all unused ERIC_neverdef and rth_notdef code.
1862
1cd6895c
RH
1863 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Nop out gpdisp
1864 following a call to a near function.
1865
f16fbd61
RH
18662001-09-08 Richard Henderson <rth@redhat.com>
1867
1868 * elf64-alpha.c (elf64_alpha_relocate_section): Soft fail
1869 relocation errors. Fail gp-relative relocations against
1870 dynamic symbols.
1871
56882138
AM
18722001-09-08 Alan Modra <amodra@bigpond.net.au>
1873
1874 * elf32-i386.c (elf_i386_relocate_section): Check !DEF_REGULAR
1875 as well as DEF_DYNAMIC in test for avoided copy relocs.
1876 (allocate_plt_and_got_and_discard_relocs): Likewise.
1877 * elf32-hppa.c (elf_i386_relocate_section): Likewise.
1878 (allocate_plt_and_got_and_discard_relocs): Likewise.
1879
cb56d3d3
TS
18802001-09-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1881
1882 * elf32-mips.c (mips_elf_calculate_relocation): Fix overflow handling
1883 of R_MIPS_PC16.
56882138
AM
1884
18852001-09-06 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1886
1887 * elf64-mips.c (mips_elf64_howto_table_rel): Fix relocation HOWTO
1888 definitions.
1889 (mips_elf64_howto_table_rel): Likewise.
1890
18912001-09-05 Tom Rix <trix@redhat.com>
1892
1893 * xcofflink.c (bfd_xcoff_import_symbol): Handle import file XMC_XO
1894 and syscall symbols.
1895 (write_global_symbol) : Same.
1896 (bfd_xcoff_export_symbol): Remove unused syscall param.
1897 * libxcoff.h: Change prototype of bfd_xcoff_export symbol and
1898 bfd_xcoff_import_symbol.
1899 * bfd-in.h: Same.
1900 * bfd-in2.h : Regenerate.
1901
19022001-09-04 Richard Henderson <rth@redhat.com>
1903
1904 * elf64-alpha.c (SKIP_HOWTO): New.
1905 (elf64_alpha_howto_table): Use it to remove dead ECOFF relocs.
1906 Fix sizes of 16-bit mem format relocs.
1907 (elf64_alpha_reloc_map): Update to match.
1908 (elf64_alpha_relax_with_lituse): Use GPREL16 as appropriate.
1909 (elf64_alpha_relax_without_lituse): Likewise.
1910 (elf64_alpha_check_relocs): Handle GPREL16.
1911 (elf64_alpha_relocate_section): Likewise.
1912 * reloc.c (BFD_RELOC_ALPHA_USER_*): Remove.
1913 (BFD_RELOC_ALPHA_GPREL_HI16, BFD_RELOC_ALPHA_GPREL_LO16): New.
1914 * bfd-in2.h, libbfd.h: Rebuild.
1915
19162001-09-04 Jeff Law <law@redhat.com>
1917
1918 * elf32-h8300.c (elf32_h8_relax_section): New function.
1919 (elf32_h8_relax_delete_bytes): Likewise.
1920 (elf32_h8_symbol_address_p): Likewise.
1921 (elf32_h8_get_relocated_section_contents): Likewise.
1922 (bfd_elf32_bfd_relax_section): Define.
1923 (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
1924
1925 * elf32-h8300.c (special): New function.
1926 (h8_elf_howto_table): Use it for SPECIAL_FUNCTION field in
1927 all relocations.
1928 (elf32_h8_final_link_relocate): Treat R_H8_DIR24A8 like 32bit
1929 relocations. Fix problems with the true 24bit reloc R_H8_DIR24R8.
1930 Fix minor problems with 8bit and 16bit PC relative relocations.
1931
19322001-09-01 Andreas Jaeger <aj@suse.de>
1933
1934 * vms-tir.c: Add missing prototypes.
1935 * vms-hdr.c: Likewise.
1936 * vms-gsd.c: Likewise.
1937 * vms-misc.c: Likewise.
1938
19392001-08-31 H.J. Lu <hjl@gnu.org>
1940
1941 * elf32-mips.c (_bfd_mips_elf_check_relocs): Report filename
1942 with bad relocation.
1943
19442001-08-31 Eric Christopher <echristo@redhat.com>
1945 Jason Eckhardt <jle@redhat.com>
1946
1947 * bfd/archures.c: Add mipsisa32 and mipsisa64. Remove mips32,
1948 mips32_4k and mips64.
1949 * bfd/aoutx.h: Remove bfd_mach_mips32, bfd_mach_mips32_4k,
1950 bfd_mach_mips64. Add bfd_mach_mipsisa32, bfd_mach_mipsisa64.
1951 * bfd/cpu-mips.c: Ditto.
1952 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing): Ditto.
1953 * bfd/bfd-in2.h: Regenerate.
1954
19552001-08-31 Jakub Jelinek <jakub@redhat.com>
1956
1957 * elf64-alpha.c (elf64_alpha_relocate_section): Duplicate memory
1958 value into R_ALPHA_RELATIVE's addend.
1959 (elf64_alpha_finish_dynamic_symbol): Likewise.
1960
19612001-08-31 Nick Clifton <nickc@cambridge.redhat.com>
1962
1963 * elf32-arm.h (elf32_arm_relocate_section): Do not rightshift
1964 recomputed addend during relocatable link if not USE_REL.
1965
1966 * elflink.h (elf_gc_propagate_vtable_entries_used): Fix off-by-one
1967 error.
1968
19692001-08-30 H.J. Lu <hjl@gnu.org>
1970
1971 * elf32-mips.c (mips_elf_calculate_relocation): Revert the last
1972 2 changes.
1973 (_bfd_mips_elf_adjust_dynamic_symbol): Allocate dynamic
1974 relocations for weak definitions.
1975
19762001-08-30 H.J. Lu <hjl@gnu.org>
1977
1978 * Makefile.am (BFD32_BACKENDS): Add elf32-h8300.lo.
1979 (BFD32_BACKENDS_CFILES): Add elf32-h8300.c.
1980 * Makefile.in: Rebuild.
1981
19822001-08-30 H.J. Lu <hjl@gnu.org>
1983
1984 * elf32-mips.c (mips_elf_calculate_relocation): Don't create
1985 dynamic relocation for undefined weak symbols when creating
1986 executables. Check h->root.root.type, instead of h->root.type.
1987
19882001-08-29 Joel Sherrill <joel@OARcorp.com>
1989
1990 * config.bfd (i[3456]86-*-rtems*, m68*-*-rtems*): Change
1991 default from coff to elf.
1992
19932001-08-29 Jeff Law <law@redhat.com>
1994
1995 * elf32-h8300.c (h8_elf_howto_table): Add new PC relative
1996 relocations.
1997 (h8_reloc_map): Similarly.
1998 (elf32_h8_final_link_relocate): Remove incorrect overflow tests.
1999 Add support for PC relative relocations.
2000
2001 * elf32-h8300.c: Put all prototypes together.
2002 (elf32_h8_info_to_howto): Parameter elf_reloc is used.
2003 (elf32_h8_final_link_relocate): New function for linker.
2004 (elf32_h8_relocate_section): Similarly.
2005 (elf_backend_relocate_section): Define.
2006
2007 * cpu-h8300.c (h8300_scan, compatible): Prototype.
2008 (h8300_scan): Handle architecture:machine encodings typically
2009 found in linker scripts.
2010 * elf.c (prep_headers): Do not try to do H8 machine recognition
2011 here.
2012 * elf32-h8300.c: Add some missing prototypes.
2013 (elf32_h8_mach, elf32_h8_final_write_processing): New functions.
2014 (elf32_h8_object_p): Similarly.
2015
20162001-08-29 Tom Rix <trix@redhat.com>
2017
2018 * xcofflink.c (xcoff_link_add_symbols): Fix XTY_LD symbol that
2019 does not follow a XTY_SD.
2020
20212001-08-29 Alan Modra <amodra@bigpond.net.au>
2022
2023 * targmatch.sed: Delete case statements.
2024 * config.bfd <powerpc-*-aix* entry>: Select 64 bit xcoff for
2025 aix4.3 and above.
2026
2027Wed Aug 29 02:27:36 2001 J"orn Rennecke <amylaar@redhat.com>
2028
2029 * Makefile.am (elf32-h8300.lo): New target.
2030 * config.bfd (h8300*-*-elf): New case.
2031 * configure.in (bfd_elf32_h8300_vec): New case.
2032 * elf.c (prep_headers): Add case for bfd_arch_h8300.
2033 * reloc.c (BFD_RELOC_H8_DIR16A8): New relocation.
2034 (BFD_RELOC_H8_DIR16R8, BFD_RELOC_H8_DIR24A8): Likewise.
2035 (BFD_RELOC_H8_DIR24R8, BFD_RELOC_H8_DIR32A16): Likewise.
2036 * targets.c (bfd_target bfd_elf32_h8300_vec): New extern declaration.
2037 * elf32-h8300.c: New file.
2038 * Makefile.in, bfd-in2.h, libbfd.h, configure: Regenerated.
2039
20402001-08-28 Nick Clifton <nickc@cambridge.redhat.com>
2041
2042 * sparclynx.c: Add missing prototypes.
2043 * coff-mcore.c: Add missing prototypes.
2044 * elf32-pj.c: Add missing prototypes.
2045 * nlm32-sparc.c: Add missing prototypes.
2046 * oasys.c: Add missing prototypes.
2047 * pdp11.c: Add missing prototypes.
2048 * pe-mips.c: Add missing prototypes.
2049 * riscix.c: Add missing prototypes.
2050
20512001-08-27 Daniel Jacobowitz <drow@mvista.com>
2052
2053 * elf32-i386.c: Add missing prototypes.
2054 * elf32-ppc.c: Likewise.
2055 * elf32-sh-lin.c: Likewise.
2056 * elfarm-nabi.c: Likewise.
2057
20582001-08-27 Daniel Jacobowitz <drow@mvista.com>
2059
2060 * elf32-i386.c (elf_i386_grok_prstatus): New function.
2061 (elf_i386_grok_psinfo): New function.
2062 (elf_backend_grok_prstatus): Define.
2063 (elf_backend_grok_psinfo): Likewise.
2064 * elf32-ppc.c (ppc_elf_grok_prstatus): New function.
2065 (ppc_elf_grok_psinfo): New function.
2066 (elf_backend_grok_prstatus): Define.
2067 (elf_backend_grok_psinfo): Likewise.
2068 * elf32-sh-lin.c (elf32_shlin_grok_prstatus): New function.
2069 (elf32_shlin_grok_psinfo): New function.
2070 (elf_backend_grok_prstatus): Define.
2071 (elf_backend_grok_psinfo): Likewise.
2072 * elfarm-nabi.c (elf32_arm_nabi_grok_prstatus): New function.
2073 (elf32_arm_nabi_grok_psinfo): New function.
2074 (elf_backend_grok_prstatus): Define.
2075 (elf_backend_grok_psinfo): Likewise.
2076
20772001-08-27 H.J. Lu <hjl@gnu.org>
2078
2079 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add more
2080 sanity check.
2081 (mips_elf_calculate_relocation): Create dynamic relocation for
2082 symbols with weak definition or the ELF_LINK_HASH_DEF_REGULAR
2083 bit is not set.
2084
20852001-08-27 H.J. Lu <hjl@gnu.org>
2086
2087 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Add prototype.
2088 (_bfd_mips_elf_copy_indirect_symbol): Likewise.
2089 (_bfd_elf32_mips_grok_prstatus): Likewise.
2090 (_bfd_elf32_mips_grok_psinfo): Likewise.
2091 (_bfd_mips_elf_hide_symbol): Make it static and cast to
2092 `struct mips_elf_link_hash_entry *'.
2093 (_bfd_mips_elf_copy_indirect_symbol): Make it static.
2094
20952001-08-27 Nick Clifton <nickc@cambridge.redhat.com>
2096
2097 * mipsbsd.c: Add missing prototypes.
2098 * hp300hpux.c: Add missing prototypes.
2099 * i386aout.c: Add missing prototypes.
2100 * i386lynx.c: Add missing prototypes.
2101 * i386mach3.c: Add missing prototypes.
2102 * i386msdos.c: Add missing prototypes.
2103 * i386os9k.c: Add missing prototypes.
2104
21052001-08-27 Linus Nordberg <linus@swox.se>
2106 Torbjorn Granlund <tege@swox.com>
2107 Staffan Ulfberg <staffanu@swox.se>
2108 Alan Modra <amodra@bigpond.net.au>
2109
2110 * config.bfd: Add powerpc64 target. Add powerpc64 vectors to
2111 targ64_selvecs for 32 bit powerpc targets.
2112 * Makefile.am (BFD64_BACKENDS): Add elf64-ppc.lo.
2113 (BFD64_BACKENDS_CFILES): Add elf64-ppc.c.
2114 Run "make dep-am".
2115 * Makefile.in: Regenerate.
2116 * configure.in: Add elf64_powerpc vecs.
2117 * configure: Regenerate.
2118 * cpu-powerpc.c: Default to bfd_mach_ppc_620 entry for 64 bit.
2119 * elf.c (prep_headers): EM_PPC64 for 64 bit ppc elf target.
2120 * targets.c: Add bfd_elf64_powerpc_vec and bfd_elf64_powerpcle_vec.
2121 * elf64-ppc.c: New file.
2122 * reloc.c: Add powerpc64 relocs.
2123 * libbfd.h: Regenerate.
2124 * bfd-in2.h: Regenerate.
2125
21262001-08-27 Andreas Schwab <schwab@suse.de>
2127
2128 * elf32-m68k.c (elf32_m68k_check_relocs): Set DF_TEXTREL if the
2129 reloc is against read-only section.
2130 (elf32_m68k_size_dynamic_sections): Use DF_TEXTREL flag instead of
2131 looking up section names for DT_TEXTREL.
2132 (elf32_m68k_reloc_type_class): New function.
2133 (elf_backend_reloc_type_class): Define.
2134
21352001-08-27 Andreas Jaeger <aj@suse.de>
2136
2137 * elf64-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
2138 reloc is against read-only section.
2139 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
2140 looking up section names for DT_TEXTREL.
2141 (elf_s390_reloc_type_class): New.
2142 (elf_backend_reloc_type_class): Define.
2143
2144 * elf32-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
2145 reloc is against read-only section.
2146 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
2147 looking up section names for DT_TEXTREL.
2148 (elf_s390_reloc_type_class): New.
2149 (elf_backend_reloc_type_class): Define.
2150
2151 * elf32-ppc.c (ppc_elf_check_relocs): Set DF_TEXTREL if the reloc
2152 is against read-only section.
2153 (ppc_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
2154 looking up section names for DT_TEXTREL.
2155 (ppc_elf_reloc_type_class): New.
2156 (elf_backend_reloc_type_class): Define.
2157
21582001-08-26 Andreas Jaeger <aj@suse.de>
2159
2160 * elf32-cris.c (cris_elf_check_relocs): Set DF_TEXTREL if the
2161 reloc is against read-only section.
2162 (elf_cris_size_dynamic_sections): Use DF_TEXTREL flag instead of
2163 looking up section names for DT_TEXTREL.
2164 (elf_cris_reloc_type_class): New.
2165 (elf_backend_reloc_type_class): Define.
2166
2167 * elf32-sh.c (sh_elf_check_relocs): Set DF_TEXTREL if the reloc is
2168 against read-only section.
2169 (elf_backend_reloc_type_class): Define.
2170 (sh_elf_reloc_type_class): New.
2171 (sh_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
2172 looking up section names for DT_TEXTREL.
2173
2174 * elf32-arm.h (elf32_arm_check_relocs): Set DF_TEXTREL if the
2175 reloc is against read-only section.
2176 (elf32_arm_size_dynamic_sections): Use DF_TEXTREL flag instead of
2177 looking up section names for DT_TEXTREL.
2178 (elf32_arm_reloc_type_class): New.
2179 (elf_backend_reloc_type_class): Define.
2180
21812001-08-25 Andreas Jaeger <aj@suse.de>
2182
2183 * oasys.c: Add missing prototypes.
2184
2185 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Add unused
2186 attribute for parameter.
2187 * elf.c (_bfd_elf_reloc_type_class): Likewise.
2188
2189 * versados.c (get_4): Make static.
2190 (get_10): Make static.
2191 Add missing prototypes.
2192 (process_esd): Fix call to versados_new_symbol.
2193
21942001-08-25 Nick Clifton <nickc@cambridge.redhat.com>
2195
2196 * coff-a29k.c: Add missing prototypes.
2197 * coff-apollo.c: Add missing prototypes.
2198 * coff-arm.c: Add missing prototypes.
2199 * coff-i860.c: Add missing prototypes.
2200 * coff-rs6000.c: Add missing prototypes.
2201 * coff-tic80.c: Add missing prototypes.
2202 * elf-m10200.c: Add missing prototypes.
2203 * elf-m10300.c: Add missing prototypes.
2204 * elf32-arm.h: Add missing prototypes.
2205 * elf32-d10v.c: Add missing prototypes.
2206 * elf32-m32r.c: Add missing prototypes.
2207 * elf32-mcore.c: Add missing prototypes.
2208 * elf32-openrisc.c: Add missing prototypes.
2209 * elf32-sh.c: Add missing prototypes.
2210 * elf32-sparc.c: Add missing prototypes.
2211 * elf32-v850.c: Add missing prototypes.
2212 * elfarm-nabi.c: Add missing prototypes.
2213 * elfarm-oabi.c: Add missing prototypes.
2214
22152001-08-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2216
2217 * elf32-mips.c (elf_mips_abi_name): Return the right ABI string for
2218 E_MIPS_ABI_O64 and E_MIPS_ABI_EABI64
2219
22202001-08-24 H.J. Lu <hjl@gnu.org>
2221
2222 * elf.c (_bfd_elf_merge_sections): Fail if not using an ELF
2223 hash structure.
2224
22252001-08-24 Nick Clifton <nickc@cambridge.redhat.com>
2226
2227 * elf-bfd.h (elf_hash_table): Revert definition.
2228 (is_elf_hash_table): New macro.
2229 * elflink.h (elf_link_add_object_symbols): Test
2230 is_elf_hash_table before accessing ELF only fields in hash
2231 structure.
2232 (elf_link_create_dynamic_sections): Fail if not using an ELF
2233 hash structure.
2234 (elf_add_dynamic_entry): Fail if not using an ELF hash
2235 structure.
2236 (elf_link_record_local_dynamic_symbol): Fail if not using an
2237 ELF hash structure.
2238 (size_dynamic_sections): Fail if not using an ELF hash
2239 structure.
2240 (elf_adjust_dynamic_symbol): Fail if not using an ELF
2241 hash structure.
2242 (elf_bfd_final_link): Fail if not using an ELF hash
2243 structure.
2244
22452001-08-24 H.J. Lu <hjl@gnu.org>
2246
2247 * elf-bfd.h (elf_hash_table): Return NULL if the linker hash
2248 table is not an ELF linker hash table.
2249
2250 * elf.c (_bfd_elf_link_hash_table_init): Set the linker hash
2251 table type to bfd_link_elf_hash_table.
2252
2253 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Revert
2254 the last change.
2255
2256 * linker.c (_bfd_link_hash_table_init): Set the linker hash
2257 table type to bfd_link_generic_hash_table.
2258
22592001-08-24 Alexandre Oliva <aoliva@redhat.com>
2260
2261 * bfd.c (bfd_alt_mach_code): New function.
2262 * bfd-in2.h: Rebuilt.
2263
22642001-08-24 Alexandre Oliva <aoliva@redhat.com>
2265
2266 * elf-m10300.c (mn10300_elf_relocate_section): Test the right
2267 `type' field in the hash entry when deciding whether to follow a
2268 link.
2269
22702001-08-24 Jakub Jelinek <jakub@redhat.com>
2271
2272 * elflink.h (elf_link_sort_cmp1): Sort RELATIVE relocs first, not
2273 last.
2274 (elf_link_sort_relocs): Adjust accordingly.
2275
2276 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Add reltext flag.
2277 (elf64_alpha_check_relocs): Set it if section this reloc is against
2278 is read-only. Set DF_TEXTREL if a RELATIVE reloc is needed against
2279 read-only section.
2280 (elf64_alpha_calc_dynrel_sizes): Set DF_TEXTREL flag if relocation
2281 is is against read-only section.
2282 (elf64_alpha_size_dynamic_sections): Use DF_TEXTREL flag, don't
2283 check section names.
2284 (elf64_alpha_reloc_type_class): New.
2285 (elf_backend_reloc_type_class): Define.
2286
22872001-08-24 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2288
2289 * linker.c (_bfd_generic_link_add_archive_symbols): Replace alloca()
2290 by bfd_malloc().
2291
22922001-08-23 Andreas Jaeger <aj@suse.de>
2293
2294 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set DF_TEXTREL if
2295 the reloc is against read-only section.
2296 (elf64_x86_64_size_dynamic_sections): Use DF_TEXTREL flag instead
2297 of looking up section names for DT_TEXTREL.
2298 (elf64_x86_64_reloc_type_class): New.
2299 (elf_backend_reloc_type_class): Define.
2300
23012001-08-23 H.J. Lu <hjl@gnu.org>
2302
2303 * syms.c (bfd_print_symbol_vandf): Add abfd to arg.
2304 * bfd-in2.h (bfd_print_symbol_vandf): Regenerated.
2305
2306 * aoutx.h (NAME(aout,print_symbol)): Pass abfd to
2307 bfd_print_symbol_vandf.
2308 * coffgen.c (coff_print_symbol): Likewise.
2309 * elf.c (bfd_elf_print_symbol): Likewise.
2310 * ieee.c (ieee_print_symbol): Likewise.
2311 * nlmcode.h (nlm_print_symbol): Likewise.
2312 * oasys.c (oasys_print_symbol): Likewise.
2313 * pdp11.c (NAME(aout,print_symbol)): Likewise.
2314 * som.c (som_print_symbol): Likewise.
2315 * srec.c (srec_print_symbol): Likewise.
2316 * tekhex.c (tekhex_print_symbol): Likewise.
2317 * versados.c (versados_print_symbol): Likewise.
2318 * vms.c (vms_print_symbol): Likewise.
2319
2320 * elf.c (_bfd_elf_print_private_bfd_data): Replace fprintf_vma
2321 with bfd_fprintf_vma.
2322 (bfd_elf_print_symbol): Likewise.
2323 * syms.c (bfd_print_symbol_vandf): Likewise.
2324
23252001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
2326
2327 * aoutf1.h (sunos_write_object_contents): Silence compile time
2328 warning.
2329 * libaout.h (N_SET_DYNAMIC): Silence compile time warning.
2330
2331 * bout.c: Add missing function prototypes. Fix formatting.
2332 * coff-z8k.c: Add missing function prototypes. Fix formatting.
2333 * coff-w65.c: Add missing function prototypes. Fix formatting.
2334 * coff-h8500.c: Add missing function prototypes. Fix formatting.
2335 * coff-h8300.c: Add missing function prototypes. Fix formatting.
2336 * coff-tic54x.c: Add missing function prototypes. Fix formatting.
2337 * coff-tic30.c: Add missing function prototypes. Fix formatting.
2338 * coff-m68k.c: Add missing function prototypes. Fix formatting.
2339 * coff-rs6000.c: Add missing function prototypes. Fix formatting.
2340 * coff-sh.c: Add missing function prototypes. Fix formatting.
2341
23422001-08-23 Jakub Jelinek <jakub@redhat.com>
2343
2344 * elf-bfd.h (enum elf_reloc_type_class): New.
2345 (struct elf_backend_data): Add elf_backend_reloc_type_class.
2346 (_bfd_elf_reloc_type_class): New.
2347 * elfxx-target.h (elf_backend_reloc_type_class): Define.
2348 (elfNN_bed): Add elf_backend_reloc_type_class.
2349 * elf.c (_bfd_elf_reloc_type_class): New.
2350 * elf32-i386.c (elf_i386_check_relocs): Set DF_TEXTREL if the reloc
2351 is against read-only section.
2352 (elf_i386_size_dynamic_sections): Use DF_TEXTREL flag instead of
2353 looking up section names for DT_TEXTREL.
2354 (elf_i386_reloc_type_class): New.
2355 (elf_backend_reloc_type_class): Define.
2356 * elf32-sparc.c (elf32_sparc_check_relocs): Set DF_TEXTREL if the
2357 reloc is against read-only section.
2358 (elf32_sparc_size_dynamic_sections): Use DF_TEXTREL flag instead of
2359 looking up section names for DT_TEXTREL.
2360 (elf32_sparc_reloc_type_class): New.
2361 (elf_backend_reloc_type_class): Define.
2362 * elf64-sparc.c (sparc64_elf_check_relocs): Set DF_TEXTREL if the
2363 reloc is against read-only section.
2364 (sparc64_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
2365 looking up section names for DT_TEXTREL.
2366 (sparc64_elf_reloc_type_class): New.
2367 (elf_backend_reloc_type_class): Define.
2368 * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add reltext field.
2369 (elfNN_ia64_hash_table_create): Clear ia64_info.
2370 (get_reloc_section): Set DF_TEXTREL if the reloc is against read-only
2371 section.
2372 (elfNN_ia64_size_dynamic_sections): Use ia64_info->reltext flag
2373 instead of looking up section names for DT_TEXTREL.
2374 (elfNN_ia64_reloc_type_class): New.
2375 (elf_backend_reloc_type_class): Define.
2376 * elflink.h (size_dynamic_sections): Add spare DT_NULL tags.
2377 (struct elf_link_sort_rela): New.
2378 (elf_link_sort_cmp1, elf_link_sort_cmp2, elf_link_sort_relocs): New.
2379 (elf_bfd_final_link): Call elf_link_sort_relocs.
2380 Convert one spare DT_NULL into DT_RELCOUNT resp. DT_RELACOUNT if
2381 necessary.
2382
23832001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
2384
2385 * configure.in (x86-bsdi): No corefile support.
2386 * configure: Regenerate.
2387
23882001-08-22 Nick Clifton <nickc@cambridge.redhat.com>
2389
2390 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add missing
2391 comma.
2392
23932001-08-21 Mark Elbrecht <snowball3@bigfoot.com>
2394
2395 * coff-go32.c: Make DWARF2 sections use an alignment of 0. Set
2396 the alignment of dwarf2 linkonce sections to 0.
2397 * coff-sto32.c: Likewise.
2398
23992001-08-20 Andreas Jaeger <aj@suse.de>
2400
2401 * coff-sparc.c: Add missing prototypes.
2402 * elf32-s390.c: Likewise.
2403 * elf32-i960.c: Likewise.
2404 * aout-target.h: Likewise.
2405
24062001-08-20 H.J. Lu <hjl@gnu.org>
2407
2408 * elf-bfd.h (elf_obj_tdata): Add num_section_syms.
2409 (elf_num_section_syms): New for num_section_syms.
2410
2411 * elf.c (elf_map_symbols): Set num_section_syms.
2412 (_bfd_elf_symbol_from_bfd_symbol): Check num_section_syms for
2413 the section symbol index.
2414
24152001-08-20 Nick Clifton <nickc@cambridge.redhat.com>
2416
2417 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Never
2418 select the generic has table creator. All elf backends need elf
2419 specific fields in the hash table.
2420
24212001-08-20 Alan Modra <amodra@bigpond.net.au>
2422
2423 * archive.c (offsetof): Remove define.
2424 * elf.c: Likewise.
2425 * oasys.c: Likewise
2426 * sysdep.h (offsetof): Define.
2427
24282001-08-17 Alan Modra <amodra@bigpond.net.au>
2429
2430 * bfd.c (bfd_get_gp_size): Return an unsigned int.
2431 (bfd_set_gp_size): Make param unsigned.
2432 * bfd-in2.h: Regenerate.
2433 * elf32-ppc.c (ppc_elf_add_symbol_hook): Use elf_gp_size rather
2434 than calling bfd_get_gp_size.
2435 * elf64-alpha.c (elf64_alpha_add_symbol_hook): Likewise.
2436 * elfxx-ia64.c (elfNN_ia64_add_symbol_hook): Likewise.
2437
24382001-08-17 Alan Modra <amodra@bigpond.net.au>
2439
2440 * linker.c (default_fill_link_order): Handle four byte fill value.
2441
24422001-08-17 Alan Modra <amodra@bigpond.net.au>
2443
2444 * elf64-sparc.c (sparc64_elf_output_arch_syms): Add missing
2445 prototype.
2446 * nlm32-alpha.c (nlm_alpha_write_external): Fix warning.
2447
2448 * elf64-mips.c (UNUSED_RELOC): Define.
2449 (mips_elf64_howto_table_rel): Use it.
2450 (mips_elf64_howto_table_rela): Here too.
2451 (mips_elf64_write_relocs): Fix signed/unsigned warning.
2452
2453 * coffcode.h (coff_write_object_contents): Add ATTRIBUTE_UNUSED to
2454 silence warning.
2455 * coffgen.c (coff_print_symbol): Fix warnings.
2456 (coff_find_nearest_line): Likewise.
2457 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
2458 * coff-alpha.c (alpha_convert_external_reloc): Likewise.
2459 * format.c (bfd_check_format_matches): Likewise.
2460 (bfd_set_format): Likewise.
2461 * coff-ia64.c: Add missing prototypes.
2462 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Make addend
2463 signed to silence warnings.
2464 (elf64_alpha_relocate_section): Likewise.
2465 (elf64_alpha_find_reloc_at_ofs): Fix warnings.
2466 (elf64_alpha_add_symbol_hook): Likewise.
2467 (elf64_alpha_final_link): Likewise.
2468 (elf64_alpha_relax_section): Remove redundant assign to info.gotent.
2469 (elf64_alpha_merge_gots): Add ATTRIBUTE_UNUSED to unused args.
2470 (elf64_alpha_size_got_sections): Likewise.
2471 * elfxx-ia64.c: Add missing prototypes.
2472 (elfNN_ia64_relocate_section): Fix warning.
2473 (elfNN_ia64_unwind_entry_compare): Make params const.
2474
24752001-08-17 Alan Modra <amodra@bigpond.net.au>
2476
2477 * config.bfd (targ64_selvecs): New.
2478 <powerpc-*-aix* entry>: Use it here instead of ineffectual #ifdef.
2479
2480 * bfd-in.h (BFD_VERSION): Remove wrong comment.
2481 (BFD_DEFAULT_TARGET_SIZE): New.
2482 (BFD_ARCH_SIZE): Comment.
2483 * configure.in (target_size): New. Set instead of target64 in
2484 selvecs case statement. Set target64 from it.
2485 (bfd_default_target_size): New. Set from taget_size. AC_SUBST.
2486 * bfd-in2.h: Regenerate.
2487 * configure: Regenerate.
2488
24892001-08-17 Alan Modra <amodra@bigpond.net.au>
2490
2491 * bfd.c (enum bfd_error): Add bfd_error_wrong_object_format.
2492 (bfd_errmsgs): Add corresponding message.
2493 * archive.c (bfd_generic_archive_p): Don't release bfd_ardata when
2494 finding an archive that contains different format object files.
2495 Return bfd_error_wrong_object_format for this case.
2496 * format.c: Formatting fixes. s/CONST/const/.
2497 (bfd_check_format_matches): Accept archives that give
2498 bfd_error_wrong_object_format if no full match is found. Tidy
2499 code handling matching_vector. Don't return a pointer to freed
2500 memory in `matching'. Handle ambiguous matches as for partial
2501 archive matches.
2502 * bfd-in2.h: Regenerate.
2503
25042001-08-15 Alan Modra <amodra@bigpond.net.au>
2505
2506 * libieee.h (common_header_type): Add last_byte field.
2507
2508 * ieee.c: Add missing prototypes. Some format fixes.
2509 (struct output_buffer_struct): Move for availability to prototypes.
2510 (ieee_part_after): New function.
2511 (ieee_slurp_debug): Use it here.
2512 (ieee_seek): Pass in ieee_data_struct rather than bfd. Use
2513 ieee_part_after to set last_byte to one past end of current part.
2514 Update callers.
2515 (ieee_pos): Pass in ieee_data_struct rather than bfd.
2516 Update callers.
2517 (parse_expression): Don't go beyond the end of the current part.
2518 (ieee_slurp_external_symbols): Correct type passed to read_2bytes.
2519 (ieee_get_symtab_upper_bound, ieee_get_symtab,
2520 ieee_get_symbol_info, ieee_print_symbol, ieee_new_section_hook,
2521 ieee_get_reloc_upper_bound, ieee_canonicalize_reloc, block,
2522 ieee_set_section_contents, ieee_write_object_contents,
2523 ieee_make_empty_symbol): Make static.
2524 (ieee_archive_p): Correct comments regarding bfd_read.
2525 (ieee_object_p): Similarly.
2526 (ieee_mkobject): Move it. Clear output_ptr_start, output_ptr,
2527 output_ptr_end, input_ptr_start, input_ptr, input_ptr_end,
2528 input_bfd, output_bfd, output_buffer.
2529 (do_as_repeat): Write out ieee_set_current_pc_enum value as for
2530 do_with_relocs, ie. as a symbol for relocatable files.
2531 (ieee_vec): Add comments showing functions referenced by macros.
2532
25332001-08-14 Nick Clifton <nickc@cambridge.redhat.com>
2534
2535 * aout-tic30.c: Add missing prototypes. Fix formatting.
2536 * aout-ns32k.c: Add missing prototypes. Fix formatting.
2537 * peXXigen.c: Add missining prototypes. Fix formatting.
2538 * aout-adobe.c: Add missining prototypes. Fix formatting.
2539
25402001-08-13 Nick Clifton <nickc@cambridge.redhat.com>
2541
2542 * elf32-v850.c: Add missing function prototypes.
2543 Fix some formatting.
2544
2545 * cpu-v850.c: Add missing function prototype.
2546 Fix some formatting.
2547
25482001-08-11 Nick Clifton <nickc@cambridge.redhat.com>
2549
2550 * elf-bfd.h (struct elf_backend_data): Add new fields
2551 'elf_backend_sprintf_vma' and 'elf_backend_fprintf_vma'.
2552 (bfd_elf_sprintf_vma): Rename function prototype to
2553 '_bfd_elf_sprintf_vma'.
2554 (bfd_elf_fprintf_vma): Rename function prototype to
2555 '_bfd_elf_fprintf_vma'.
2556 * bfd.c (bfd_sprintf_vma): Do not invoke bfd_elf_sprintf_vma
2557 directly, instead indirect via the elf_backend_data structure.
2558 (bfd_fprintf_vma): Do not invoke bfd_elf_fprintf_vma directly,
2559 instead indirect via the elf_backend_data structure.
2560 * elf.c (bfd_elf_sprintf_vma): Rename to _bfd_elf_sprintf_vma.
2561 (bfd_elf_fprintf_vma): Rename to _bfd_elf_fprintf_vma.
2562 * elfxx-target.h (elf_backend_sprintf_vma): Initialise if not
2563 already defined.
2564 (elf_backend_fprintf_vma): Initialise if not already defined.
2565 (struct elf_backend_data): Initialise the
2566 elf_backend_sprintf_vma and elf_backend_fprintf_vma fields.
2567
25682001-08-10 Andreas Jaeger <aj@suse.de>
2569
2570 * elf64-sparc.c: Add missing prototypes.
2571 * elf32-cris.c: Likewise.
2572 * elf32-i370.c: Likewise.
2573 * elf64-hppa.c: Likewise.
2574 * elf64-s390.c: Likewise.
2575
25762001-08-10 Andreas Jaeger <aj@suse.de>
2577
2578 * elf64-x86-64.c (elf64_x86_64_elf_object_p): Make static.
2579 Add prototypes where needed.
2580
25812001-08-10 H.J. Lu <hjl@gnu.org>
2582
2583 * bfd.c (bfd_sprintf_vma): Fix a typo in the last change.
2584 (bfd_fprintf_vma): Likewise.
2585
25862001-08-10 H.J. Lu <hjl@gnu.org>
2587
2588 * bfd.c (bfd_sprintf_vma): Don't return void.
2589 (bfd_fprintf_vma): Likewise.
2590
25912001-08-10 Andreas Jaeger <aj@suse.de>
2592
2593 * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
2594 to build warnings.
2595 * configure: Regenerate.
2596
25972001-08-10 Alan Modra <amodra@bigpond.net.au>
2598
2599 * elf.c (bfd_elf_sprintf_vma): Add ATTRIBUTE_UNUSED to quiet
2600 warning if not BFD64. Add braces so emacs auto format works.
2601 (bfd_elf_fprintf_vma): Likewise.
2602
2603 * libxcoff.h (struct xcoff_backend_data_rec): Constify src param
2604 of _xcoff_swap_ld*.
2605 * coff-rs6000.c (xcoff_swap_ldhdr_in): Modify type of external
2606 param to agree with libxcoff.h.
2607 (xcoff_swap_ldhdr_out): Likewise.
2608 (xcoff_swap_ldsym_in): Likewise.
2609 (xcoff_swap_ldsym_out): Likewise.
2610 (xcoff_swap_ldrel_in): Likewise.
2611 (xcoff_swap_ldrel_out): Likewise.
2612 (xcoff_create_csect_from_smclas): Likewise.
2613 * coff64-rs6000.c: Add missing prototypes.
2614 (xcoff64_swap_ldhdr_in): Modify type of external param to agree
2615 with libxcoff.h.
2616 (xcoff64_swap_ldhdr_out): Likewise.
2617 (xcoff64_swap_ldsym_in): Likewise.
2618 (xcoff64_swap_ldsym_out): Likewise.
2619 (xcoff64_swap_ldrel_in): Likewise.
2620 (xcoff64_swap_ldrel_out): Likewise.
2621 (xcoff64_ppc_relocate_section): Make static.
2622 (xcoff64_slurp_armap): Likewise.
2623 (xcoff64_archive_p): Likewise.
2624 (xcoff64_openr_next_archived_file): Likewise.
2625 (xcoff64_sizeof_headers): Likewise.
2626 (xcoff64_is_lineno_count_overflow): Likewise.
2627 (xcoff64_is_reloc_count_overflow): Likewise.
2628 (xcoff64_loader_symbol_offset): Likewise.
2629 (xcoff64_loader_reloc_offset): Likewise.
2630 * elf64-gen.c: Add missing prototypes.
2631
26322001-08-09 H.J. Lu <hjl@gnu.org>
2633
2634 * elf.c (bfd_elf_sprintf_vma): Check ELFCLASS64 only in BFD64.
2635 (bfd_elf_fprintf_vma): Likewise.
2636
26372001-08-09 H.J. Lu <hjl@gnu.org>
2638
2639 * bfd-in.h (bfd_elf_sprintf_vma, bfd_elf_fprintf_vma): Moved
2640 to ...
2641 * elf-bfd.h: Here.
2642 * bfd-in2.h: Regenerated.
2643
26442001-08-09 H.J. Lu <hjl@gnu.org>
2645
2646 * bfd-in.h (bfd_sprintf_vma): New prototype.
2647 (bfd_fprintf_vma): Likewise.
2648 (bfd_elf_sprintf_vma): Likewise.
2649 (bfd_elf_fprintf_vma): Likewise.
2650 (bfd_printf_vma): New. Defined with bfd_fprintf_vma.
2651 * bfd-in2.h: Regenerated.
2652
2653 * bfd.c (bfd_sprintf_vma): New. Defined.
2654 (bfd_fprintf_vma): Likewise.
2655
2656 * elf.c (bfd_elf_sprintf_vma): New. Defined.
2657 (bfd_elf_fprintf_vma): Likewise.
2658
26592001-08-09 Alan Modra <amodra@bigpond.net.au>
2660
2661 * coff-rs6000.c: Add missing prototypes.
2662 (xcoff_ppc_relocate_section, xcoff_is_lineno_count_overflow,
2663 xcoff_is_reloc_count_overflow, xcoff_loader_symbol_offset,
2664 xcoff_loader_reloc_offset): Make static.
2665 * dwarf1.c: Add missing prototypes.
2666 * dwarf2.c: Add missing prototypes.
2667 (struct abbrev_info): Move definition.
2668 (struct attr_abbrev, ABBREV_HASH_SIZE, ATTR_ALLOC_CHUNK): Likewise.
2669 * elf.c: Add missing prototypes.
2670 * elf32-gen.c: Likewise.
2671 * elf32-i386.c: Likewise.
2672 * elf32-ppc.c: Likewise.
2673 (ppc_elf_sort_rela): Use PTR instead of "void *".
2674 * elflink.h: Add missing prototypes. Formatting fixes.
2675 * merge.c: Add missing prototypes.
2676 (last4_eq): Use PTR instead of "void *".
2677 (last_eq): Likewise.
2678 * syms.c: Add missing prototypes.
2679
26802001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2681
2682 * bfd.c: Fix formatting.
2683 * bfd-in2.h: Regenerate.
2684
26852001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2686
2687 * elf32-arc.c (R_ARC_B22_PCREL): Change 'partial_inplace' to
2688 true (this target uses REL relocations) and 'pcrel_offset' to
2689 false (the PC is implied, not stored in the offset).
2690
26912001-08-08 Alan Modra <amodra@bigpond.net.au>
2692
2693 1999-10-19 Linus Nordberg <linus@swox.se>
2694 * elf-bfd.h (struct elf_backend_data): Add want_got_sym.
2695 * elfxx-target.h (elf_backend_want_got_sym): Define.
2696 (elfNN_bed): Add elf_backend_want_got_sym.
2697 * elflink.c (_bfd_elf_create_got_section): Define
2698 _GLOBAL_OFFSET_TABLE_ only if bed->want_got_sym.
2699
27002001-08-08 Alexandre Oliva <aoliva@redhat.com>
2701
2702 * dwarf2.c (struct dwarf2_debug): Add sec, sec_info_ptr and syms.
2703 (find_rela_addend): New function.
2704 (parse_comp_unit): Call it to find the abbrev offset addend.
2705 (_bfd_dwarf2_find_nearest_line): Initialize and maintain the new
2706 members of dwarf2_debug as debugging information is read.
2707
27082001-08-07 Nick Clifton <nickc@cambridge.redhat.com>
2709
2710 * coff-sh.c (sh_coff_reloc_type_lookup): Provide for sh-coff
2711 targets as well as sh-pe.
2712
27132001-08-03 Ben Harris <bjh21@netbsd.org>
2714
2715 * elf32-arm.h (elf32_arm_final_link_relocate): Include offset of
2716 reloc from start of section when computing value for R_ARM_REL32
2717 reloc.
2718
27192001-08-03 Alan Modra <amodra@bigpond.net.au>
2720
2721 From H.J. Lu <hjl@gnu.org>
2722 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Don't
2723 keep relocs for undefined syms if there are no dynamic sections in
2724 executable.
2725 * elf32-hppa.c (allocate_plt_and_got_and_discard_relocs): Likewise.
2726
27272001-08-02 Paul Sokolovsky <paul.sokolovsky@technologist.com>
2728
2729 * cofflink.c (coff_link_check_ar_symbols): also search for
2730 __imp__symbol as well as _symbol.
2731 * linker.c (_bfd_generic_link_add_archive_symbols): also
2732 search for __imp__symbol as well as _symbol.
2733
27342001-08-01 Adam Nemet <anemet@lnxw.com>
2735
2736 * elf.c (elf_sort_sections): Return zero only as the last step.
2737
27382001-08-01 Nick Clifton <nickc@cambridge.redhat.com>
2739
2740 * config.bfd (arm-vxworks): Change name of define from VXWORKS to
2741 ARM_COFF_BUGFIX.
2742 (arm-epoc-pe): Define ARM_COFF_BUGFIX.
2743 coff-arm.c (coff_arm_relocate_section): Replace VXWORKS with
2744 ARM_COFF_BUGFIX.
2745
27462001-07-30 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
2747
2748 * libecoff.h (_bfd_ecoff_styp_to_sec_flags): Changed return type
2749 to match corresponding bfd_coff_backend data member.
2750
27512001-07-24 Alan Modra <amodra@bigpond.net.au>
2752
2753 * Makefile.am: Update dependencies with "make dep-am".
2754 * Makefile.in: Regenerate
2755
27562001-07-15 H.J. Lu <hjl@gnu.org>
2757
2758 * Makefile.am (po/SRC-POTFILES.in): Use tmp.src instead of tmp.
2759 (po/BLD-POTFILES.in): Use tmp.bld instead of tmp.
2760 * Makefile.in: Regenerate.
2761
27622001-07-11 H.J. Lu <hjl@gnu.org>
2763
2764 * elf64-alpha.c (elf64_alpha_check_relocs): Set the ALLOC|LOAD
2765 flags when creating the reloc section if the ALLOC flag in the
2766 source section is set.
2767
27682001-07-11 Steve Ellcey <sje@cup.hp.com>
2769
2770 * reloc.c (bfd_reloc_code_type): Add IA64 relocs
2771 BFD_RELOC_IA64_LTOFF_FPTR32MSB and BFD_RELOC_IA64_LTOFF_FPTR32LSB
2772 * bfd-in2.h: Regenerate.
2773 * libbfd.h: Regenerate.
2774 * elfxx-ia64.c (ia64_howto_table): Define how to handle
2775 new relocations.
2776 (elfNN_ia64_reloc_type_lookup): Handle new relocations.
2777 (elfNN_ia64_check_relocs): Likewise.
2778 (elfNN_ia64_install_value): Likewise.
2779 (elfNN_ia64_relocate_section): Likewise.
2780
27812001-07-11 Jakub Jelinek <jakub@redhat.com>
2782
2783 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Remove support for
2784 R_SPARC_UA64.
2785 (elf32_sparc_check_relocs): Likewise.
2786 Only create .rela section for alloced sections in shared libraries.
2787 (elf32_sparc_relocate_section): Likewise.
2788 Remove redundant check.
2789 Optimize unaligned reloc usage.
2790 * elf64-sparc.c (sparc64_elf_relocate_section): Remove redundant
2791 check.
2792
27932001-07-11 H.J. Lu <hjl@gnu.org>
2794
2795 * elf64-alpha.c (elf64_alpha_check_relocs): Only use the same
2796 ALLOC|LOAD flags as the source section for debugging sections
2797 when creating the reloc section.
2798
27992001-07-05 Jim Wilson <wilson@redhat.com>
2800
2801 * linker.c (_bfd_generic_link_add_one_symbol, case BIG): Use
2802 the section of the bigger symbol.
2803
2804 * syms.c (bfd_is_local_label): Return false if BSF_SECTION_SYM.
2805
28062001-07-05 Nick Clifton <nickc@cambridge.redhat.com>
2807
2808 * peicode.h (coff_swap_scnhdr_in): For sections containing
2809 uninitialised data, only set their size to s_paddr if this does
2810 not reset their size to zero. MS's latest compilers will set
2811 s_paddr to zero.
2812
28132001-07-04 H.J. Lu <hjl@gnu.org>
2814
2815 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing):
2816 Handle bfd_mach_mips4400, bfd_mach_mips4600 and
2817 bfd_mach_mips5000.
2818
28192001-07-03 Mark Elbrecht <snowball3@softhome.net>
2820
2821 * bfd.c (bfd_get_sign_extend_vma): Support DJGPP COFF targets.
2822
2823 * cofflink.c (_bfd_coff_link_input_bfd): Skip section symbols from
2824 sections being discarded.
2825
28262001-06-30 Alan Modra <amodra@bigpond.net.au>
2827
2828 * elfcore.h (elf_core_file_p): Call bfd_section_from_phdr directly
2829 instead of _bfd_elfcore_section_from_phdr.
2830 * elf-bfd.h (_bfd_elfcore_section_from_phdr): Remove.
2831 * elf.c (_bfd_elfcore_section_from_phdr): Remove.
2832 (_bfd_elfcore_make_pseudosection): Expedite tail-call.
2833 (elfcore_grok_prstatus): Likewise.
2834 (elfcore_grok_lwpstatus): Likewise.
2835 (bfd_get_elf_phdr_upper_bound): Likewise.
2836 (elfcore_make_note_pseudosection): Formatting.
2837 (_bfd_elfcore_strndup): Formatting.
2838 * elf32-mips.c (mips_elf_sym_is_global): Formatting.
2839 (_bfd_elf32_mips_grok_prstatus): Expedite tail-call.
2840
28412001-06-29 Daniel Jacobowitz <drow@mvista.com>
2842
2843 * elf-bfd.h: Add prototypes for _bfd_elfcore_make_pseudosection
2844 and _bfd_elfcore_strndup.
2845 (struct elf_backend_data): Add elf_backend_grok_prstatus
2846 and elf_backend_grok_psinfo.
2847 * elf.c (_bfd_elfcore_make_pseudosection): New function.
2848 (elfcore_grok_prstatus): Use it.
2849 (elfcore_make_note_pseudosection): Likewise.
2850 (elfcore_strndup): Rename to...
2851 (_bfd_elfcore_strndup): Here, and make global.
2852 (elfcore_grok_psinfo): Use _bfd_elfcore_strndup.
2853 (elfcore_grok_note): Call elf_backend_grok_prstatus
2854 and elf_backend_grok_psinfo if available.
2855 * elf32-mips.c (_bfd_elf32_mips_grok_prstatus): New function.
2856 (_bfd_elf32_mips_grok_psinfo): New function.
2857 (elf_backend_grok_prstatus): Define.
2858 (elf_backend_grok_psinfo): Define.
2859 * elfxx-target.h (elf_backend_grok_prstatus): Default to NULL.
2860 (elf_backend_grok_psinfo): Likewise.
2861 (elfNN_bed): Include elf_backend_grok_prstatus and
2862 elf_backend_grok_psinfo.
2863
28642001-06-29 H.J. Lu <hjl@gnu.org>
2865
2866 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Check if
2867 hplink->sgot is NULL before filling GOT. Check if hplink->splt
2868 is NULL before filling PLT.
2869
28702001-06-29 Alan Modra <amodra@bigpond.net.au>
2871
2872 * elflink.h (elf_link_output_extsym): Revert 1999-04-10.
2873
28742001-06-27 Alan Modra <amodra@bigpond.net.au>
2875
2876 * elf32-hppa.c (elf32_hppa_check_relocs): Don't make syms dynamic
2877 here..
2878 (elf32_hppa_adjust_dynamic_symbol): ..nor here..
2879 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2880 after gc has run.
2881
2882 * elf32-hppa.c (RELATIVE_DYNAMIC_RELOCS): Delete.
2883 (IS_ABSOLUTE_RELOC): Define.
2884 (elf32_hppa_link_hash_entry): Always include reloc_entries field.
2885 (hppa_link_hash_newfunc): Always init it.
2886 (elf32_hppa_check_relocs): Mark symbols as ELF_LINK_NON_GOT_REF to
2887 create COPY relocs only when the reloc is in a read-only section.
2888 Instead, allocate space for a dynamic reloc to reference the
2889 library symbol directly. Keep track of space we allocate using
2890 relocs_entries.
2891 (hppa_discard_copies): Delete, and move code to..
2892 (allocate_plt_and_got): ..here. Rename to
2893 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2894 relocs for non-shared link.
2895 (elf32_hppa_size_dynamic_sections): Update calls to above.
2896 (elf32_hppa_relocate_section): Write out the dynamic relocs used
2897 in lieu of COPY relocs.
2898
2899 * elf32-i386.c (elf_i386_check_relocs): Don't make syms dynamic
2900 here..
2901 (elf_i386_adjust_dynamic_symbol): ..nor here..
2902 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2903 after gc has run.
2904 (elf_i386_size_dynamic_sections): Fix a comment.
2905 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Rearrange code
2906 involved in writing reloc out.
2907
29082001-06-25 Alan Modra <amodra@bigpond.net.au>
2909
2910 * elf32-i386.c (elf_i386_check_relocs <R_386_32, R_386_PC32>):
2911 Ensure syms are dynamic if we might be emitting a reloc.
2912 (allocate_plt_and_got_and_discard_relocs): Don't discard relocs
2913 for undefweak or undefined syms..
2914 (elf_i386_relocate_section <R_386_32, R_386_PC32>): .. and emit.
2915
2916 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Discard
2917 relocs without ELF_LINK_HASH_DEF_DYNAMIC set.
2918 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Remove
2919 redundant bfd_link_hash_defined, bfd_link_hash_defweak test.
2920
29212001-06-24 H.J. Lu <hjl@gnu.org>
2922
2923 * cpu-i960.c (scan_960_mach): Don't modify const char *. Use
2924 strncasecmp/strcasecmp instead of strncmp/strcmp.
2925
29262001-06-23 H.J. Lu <hjl@gnu.org>
2927
2928 * elf32-i386.c (elf_i386_relocate_section <R_386_32, R_386_PC32>):
2929 Check ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined
2930 in the regular object file and treat the weak definition as
2931 the normal one.
2932
29332001-06-23 Alan Modra <amodra@bigpond.net.au>
2934
2935 * elf32-i386.c (elf_i386_relocate_section <R_386_GOT32>): Tighten
2936 unresolved_reloc test to exclude cases where we use "relocation"
2937 before setting it to point into the .got. Reinstate fudge for
2938 unresolved relocs in debugging sections.
2939
2940 * elf32-i386.c (elf_i386_relocate_section): Replace ugly
2941 complicated tests for unresolvable relocs with a simple direct
2942 scheme using "unresolved_reloc" var.
2943
2944 * elf32-i386.c (struct elf_i386_pcrel_relocs_copied): Rename to
2945 elf_i386_dyn_relocs. Update comment.
2946 (struct elf_i386_link_hash_entry): Rename pcrel_relocs_copied to
2947 dyn_relocs.
2948 (elf_i386_adjust_dynamic_symbol): Remove a BFD_ASSERT, change
2949 others to aborts.
2950 (allocate_plt_and_got_and_discard_relocs): Replace BFD_ASSERT with
2951 abort.
2952 (elf_i386_size_dynamic_sections): Likewise.
2953 (elf_i386_finish_dynamic_symbol): Likewise.
2954 (elf_i386_finish_dynamic_sections): Likewise.
2955 (elf_i386_relocate_section): Likewise. Tidy R_386_GOT32 and error
2956 handling code.
2957
2958 Avoid creating COPY relocs if possible.
2959 * elf32-i386.c (elf_i386_check_relocs): Tweak condition under
2960 which .got created. Mark symbols used by R_386_32 and R_386_PC32
2961 relocs as ELF_LINK_NON_GOT_REF to create COPY relocs only when the
2962 reloc is in a read-only section. Instead, allocate space for a
2963 dynamic reloc to reference the library symbol directly. Keep
2964 track of space we allocate using pcrel_relocs_copied.
2965 (discard_copies): Delete, and move code to ..
2966 (allocate_plt_and_got): ..here. Rename to
2967 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2968 relocs for non-shared link.
2969 (elf_i386_size_dynamic_sections): Update calls to above functions.
2970 (elf_i386_relocate_section): Write out the dynamic relocs. Add
2971 more ugly logic to avoid "unresolvable relocation" error. Use
2972 htab shortcut in place of elf_hash_table macro.
2973 (elf_i386_finish_dynamic_sections): Allow that dynamic .got may
2974 not always be created now.
2975
29762001-06-20 Bo Thorsen <bo@suse.co.uk>
2977
2978 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix linking of
2979 shared libraries.
2980
29812001-06-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2982
2983 * configure.host (mips64-*-linux): Reformat.
2984
29852001-06-21 Alan Modra <amodra@bigpond.net.au>
2986
2987 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Always
2988 allocate local .got space. Use shortcuts from hash table for .got
2989 and .plt rather than comparing section names.
2990 (elf32_hppa_check_relocs): Use local_plt_refcounts var rather than
2991 adjusting index into local_got_refcounts to document what we are
2992 really doing.
2993 (elf32_hppa_relocate_section): Similarly for local_plt_offsets.
2994 Tidy .got and .plt error checking.
2995
29962001-06-20 Catherine Moore <clm@redhat.com>
2997
2998 * elf-bfd.h (struct elf_backend_data):
2999 elf_backend_emit_relocs: New field: Function for emitting
3000 relocs.
3001 elf_backend_count_relocs: New field: Function for determining
3002 the number of relocs to be emitted.
3003 * elfxx-target.h: Provide default (NULL) values for
3004 elf_backend_emit_relocs and elf_backend_count_relocs.
3005 * elflink.h (elf_link_size_reloc_section): Make the hash table
3006 big enough to hold the relocs counted by either reloc_count or
3007 o->reloc_count.
3008 (elf_bfd_final_link) emit_relocs: New boolean, set if relocs
3009 should be emitted, either because of a command line option
3010 stored in the info structure or because the target provides a
3011 special reloc emitting function.
3012 If the target provides a reloc counting function use it,
3013 unless performing a relocatable link or emitting all relocs.
3014 Also set the SEC_RELOC flag on any output section which will
3015 contain relocs.
3016 (elf_link_input_bfd): emit_relocs: New boolean, set if relocs
3017 should be emitted, either because of a command line option
3018 stored in the info structure or because the target provides a
3019 special reloc emitting function.
3020 If the target provides a reloc emitting function, use it,
3021 unless performing a relocatable link or emitting all relocs.
3022
30232001-06-20 H.J. Lu <hjl@gnu.org>
3024
3025 * elf32-i386.c (elf_i386_size_dynamic_sections): Always
3026 allocate local .got space.
3027
30282001-06-19 Andreas Jaeger <aj@suse.de>
3029
3030 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix creation of
3031 dynamic symbols.
3032
30332001-06-18 Hans-Peter Nilsson <hp@axis.com>
3034
3035 * elflink.h (struct elf_assign_sym_version_info): Remove member
3036 export_dynamic. All users changed to use info member.
3037 NAME(bfd_elf,size_dynamic_sections)): Remove parameter
3038 export_dynamic, instead use member in parameter info.
3039 * bfd-in.h (bfd_elf32_size_dynamic_sections,
3040 bfd_elf64_size_dynamic_sections): Update prototype.
3041 * bfd-in2.h: Regenerate.
3042
30432001-06-18 H.J. Lu <hjl@gnu.org>
3044
3045 * elflink.h (elf_info_failed): Add a new field, verdefs.
3046 (NAME(bfd_elf,size_dynamic_sections): Pass verdefs to
3047 elf_export_symbol.
3048 (elf_export_symbol): Check eif->verdefs to decide if a symbol
3049 should be exported.
3050
30512001-06-17 H.J. Lu <hjl@gnu.org>
3052
3053 * elf32-mips.c (mips_elf_link_hash_entry): Add a new field,
3054 readonly_reloc, to record if a relocation in the .rel.dyn
3055 section is against a read-only section.
3056 (mips_elf_link_hash_newfunc): Initialize the readonly_reloc
3057 field to false.
3058 (_bfd_mips_elf_check_relocs): Record if there is a relocation
3059 in the .rel.dyn section against a read-only section by setting
3060 DF_TEXTREL or readonly_reloc.
3061 (_bfd_mips_elf_copy_indirect_symbol): Copy readonly_reloc if
3062 it is true.
3063 (_bfd_mips_elf_adjust_dynamic_symbol): Record DF_TEXTREL if
3064 there is a relocation in the .rel.dyn section against a
3065 read-only section.
3066 (_bfd_mips_elf_size_dynamic_sections): Set DT_TEXTREL if
3067 DF_TEXTREL is set.
3068
30692001-06-12 Nick Clifton <nickc@cambridge.redhat.com>
3070
3071 * coffcode.h (styp_flags_to_sec_flags): Change to a boolean
3072 function. Move flagword result into parameter list. Remove
3073 comment about setting bfd_error_handler to intercept failure
3074 results.
3075 * coffgen.c (make_a_section_from_file): Examine result of
3076 calling bfd_coff_styp_to_sec_flags and pass a failure back to
3077 caller.
3078 * ecoff.h (styp_flags_to_sec_flags): Change to a boolean
3079 function. Move flagword result into parameter list.
3080 * libcoff.h: Regenerate.
3081 * libecoff.h: Regenerate.
3082
30832001-06-13 Nick Clifton <nickc@cambridge.redhat.com>
3084
3085 * aoutx.h (adjust_z_magic): Only pad the tesxt section if the data
3086 section is going to follow it.
3087
30882001-06-12 Catherine Moore <clm@redhat.com>
3089
3090 * elflink.h (elf_gc_propagate_vtable_entries): Replace FILE_ALIGN
3091 with the file_align entry from elf_backend_data.
3092 (elf_gc_smash_unused_vtentry_relocs): Likewise.
3093 (elf_gc_record_vtentry): Likewise.
3094
30952001-06-10 Alan Modra <amodra@bigpond.net.au>
3096
3097 * elflink.h: Whitespace changes.
3098 (elf_link_read_relocs_from_section): Use "unsigned int" iterator
3099 rather than "unsigned char".
3100 (elf_link_output_relocs): Likewise.
3101 (elf_link_input_bfd): Likewise.
3102 (elf_reloc_link_order): LIkewise.
3103 * elf.c: s/CONST/const/. Whitespace changes.
3104 * elf32-mips.c: Formatting fix.
3105
3106 * Makefile.am (SOURCE_HFILES): Include xcoff-target.h, remove xcoff.h.
3107 * Makefile.in: Regenerate.
3108 * po/Make-in: Remove trailing tab.
3109
31102001-06-09 Philip Blundell <philb@gnu.org>
3111
3112 * elf32-arm.h (elf32_arm_plt0_entry): Correct error in last
3113 change.
3114 (elf32_arm_plt_entry): Likewise.
3115
31162001-06-08 H.J. Lu <hjl@gnu.org>
3117
3118 * elf.c (swap_out_syms): Keep names for global section symbols.
3119
31202001-06-07 H.J. Lu <hjl@gnu.org>
3121
3122 * config.bfd: Put back ecoff for Linux/mips. Firmwares on some
3123 MIPS-based machines need it.
3124
31252001-06-07 H.J. Lu <hjl@gnu.org>
3126
3127 * elf32-mips.c (_bfd_mips_elf_object_p): Set the bad symtab
3128 for SGI only.
3129
3130 * config.bfd: Remove ecoff from Linux/mips.
3131
31322001-06-07 Andreas Jaeger <aj@suse.de>
3133
3134 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Add an
3135 assertion.
3136 (elf64_x86_64_check_relocs): Fix VTENTRY relocation; set an
3137 alignment of 8 for .rela sections; handle further relocations.
3138
31392001-06-06 Christian Groessler <cpg@aladdin.de>
3140
3141 * coff-z8k.c: Fix formatting.
3142 Fix howtos: howto->size was always 1.
3143
31442001-06-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3145
3146 * configure.host (mips64*-*-linux*): Define.
3147
31482001-06-05 Alan Modra <amodra@bigpond.net.au>
3149
3150 * elf32-i386.c (elf_i386_discard_copies): Rename to
3151 discard_copies, and use elf_link_hash_entry arg rather than
3152 elf_i386_link_hash_entry.
3153 (elf_i386_link_hash_traverse): Delete.
3154 (elf_i386_size_dynamic_sections): Adjust call to discard_copies.
3155 Tidy sizing of dynamic sections.
3156 (elf_i386_check_relocs <R_386_32, R_386_PC32>): Reference count
3157 possible .plt entries.
3158 (elf_i386_gc_sweep_hook): Likewise.
3159 (elf_i386_adjust_dynamic_symbol): Discard .plt entries for
3160 everything with plt.refcount <= 0.
3161
3162 * elf32-i386.c (elf_i386_check_relocs): Don't allocate .got and
3163 .relgot space here.
3164 (elf_i386_gc_sweep_hook): ..and no need to deallocate here..
3165 (elf_i386_adjust_dynamic_symbol): ..and don't allocate .plt and
3166 .rel.plt here..
3167 (allocate_plt_and_got): ..instead do it all here. New function.
3168 (elf_i386_size_dynamic_sections): Allocate local .got space and
3169 call allocate_plt_and_got. No need to zap .relgot if not dynamic.
3170 (bfd_elf32_bfd_final_link): Delete. (ie. use regular final link
3171 rather than gc variety).
3172 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
3173 (elf_i386_relocate_section): Use it here and correct handling of
3174 R_386_GOT32. Provide section and offset for "unresolvable
3175 relocation" error message.
3176 (elf_i386_finish_dynamic_symbol): Correct handling of R_386_GOT32.
3177
3178 * elf32-i386.c (struct elf_i386_link_hash_table): Add sgot,
3179 sgotplt, srelgot, splt, srelplt, sdynbss, srelbss fields.
3180 (elf_i386_link_hash_table_create): Init them.
3181 (create_got_section): New function.
3182 (elf_i386_create_dynamic_sections): New function.
3183 (elf_backend_create_dynamic_sections): Set to above.
3184 (elf_i386_check_relocs): Use shortcuts from hash table rather than
3185 calling bfd_get_section_by_name.
3186 (elf_i386_gc_sweep_hook): Likewise.
3187 (elf_i386_adjust_dynamic_symbol): Likewise.
3188 (elf_i386_size_dynamic_sections): Likewise.
3189 (elf_i386_relocate_section): Likewise.
3190 (elf_i386_finish_dynamic_sections): Likewise.
3191
3192 * elf32-hppa.c (allocate_plt_and_got): Skip indirect and warning syms.
3193
31942001-06-02 H.J. Lu <hjl@gnu.org>
3195
3196 * elf32-hppa.c (elf32_hppa_object_p): Check ELFOSABI_LINUX
3197 and ELFOSABI_HPUX.
3198 * elf64-hppa.c (elf64_hppa_object_p): Likewise.
3199
32002001-06-02 H.J. Lu <hjl@gnu.org>
3201
3202 * aout-cris.c (MACHTYPE_OK): New. Defined.
3203
32042001-06-02 Hans-Peter Nilsson <hp@axis.com>
3205
3206 * section.c (_bfd_strip_section_from_output): Handle NULL
3207 output_section.
3208
32092001-06-02 H.J. Lu <hjl@gnu.org>
3210
3211 * config.bfd (powerpc-*-aix*, powerpc-*-beos*, rs6000-*-*): Add
3212 rs6000coff64_vec only if BFD64 is defined.
3213 (powerpc64-*-aix*): Enable only if BFD64 is defined.
3214
32152001-06-02 H.J. Lu <hjl@gnu.org>
3216
3217 * coff-ia64.c (ia64coff_object_p): Rewrite with
3218 external_PEI_DOS_hdr and external_PEI_IMAGE_hdr.
3219
32202001-06-01 Andreas Jaeger <aj@suse.de>
3221
3222 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add PC8
3223 relocation, small reformatting.
3224
32252001-05-29 Andreas Jaeger <aj@suse.de>
3226
3227 * elf64-x86-64.c (elf64_x86_64_check_relocs): Handle R_X86_64_64.
3228 (elf64_x86_64_relocate_section): Likewise.
3229
32302001-05-30 Alan Modra <amodra@one.net.au>
3231
3232 * elf32-hppa.c (elf32_hppa_check_relocs): Don't NEED_PLT for
3233 millicode. Don't allocate .got and .rela.got space here..
3234 (elf32_hppa_gc_sweep_hook): ..and no need to deallocate here..
3235 (elf32_hppa_adjust_dynamic_symbol): ..and don't allocate .plt and
3236 .rela.plt here..
3237 (hppa_handle_PIC_calls): ..nor here..
3238 (allocate_plt_and_got): ..instead do it all here. New function.
3239 (elf32_hppa_size_dynamic_sections): Allocate local .got space and
3240 call allocate_plt_and_got. No need to zap .got if not dynamic.
3241 (elf32_hppa_final_link): Call regular bfd_final_link instead of
3242 gc_common_final_link.
3243 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
3244 (elf32_hppa_relocate_section): Use it here.
3245 (elf32_hppa_finish_dynamic_symbol): Remove superfluous test of
3246 dynamic_sections_created.
3247 (hppa_type_of_stub): Don't LONG_BRANCH_VIA_PLT if millicode sym.
3248
32492001-05-28 Andreas Jaeger <aj@suse.de>
3250
3251 * elf64-x86-64.c (elf64_86_64_size_info): Remove, we can use the
3252 generic version since we want a hashsize of 4.
3253 (elf_backend_size_info): Likewise.
3254
32552001-05-28 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3256
3257 * elflink.h (elf_link_size_reloc_section): Use bfd_zmalloc instead of
3258 a zeroing loop.
3259 (elf_link_output_relocs): Handle MIPS ELF64 relocations correctly.
3260 (elf_link_input_bfd): Likewise.
3261 (elf_reloc_link_order): Likewise.
3262 (elf_finish_pointer_linker_section): Typo. Handle MIPS ELF64
3263 relocations correctly.
3264
32652001-05-28 Nicolas Pitre <nico@cam.org>
3266
3267 * elf32-arm.h: fix PLT generation for big endian ARM
3268
32692001-05-28 Alan Modra <amodra@one.net.au>
3270
3271 * elf32-hppa.c (elf32_hppa_relocate_section): Set up .plt entries
3272 for symbols forced local that need plabels.
3273 (elf32_hppa_adjust_dynamic_symbol): Don't allocate space in
3274 .plt.rela for local syms if non-shared.
3275 (hppa_build_one_stub): Mask lsb of plt.offset.
3276 (elf32_hppa_finish_dynamic_symbol): Abort if lsb of plt.offset set.
3277 (clobber_millicode_symbols): Correct comment.
3278 (elf32_hppa_relocate_section): Likewise.
3279 (elf32_hppa_finish_dynamic_symbol): Likewise.
3280
32812001-05-28 Jeff Sturm <jsturm@one-point.com>
3282
3283 * reloc.c: Add BFD_RELOC_SPARC_UA16 and BFD_RELOC_SPARC_UA64.
3284 * bfd-in2.h: Regenerate.
3285 * libbfd.h: Regenerate.
3286 * elf32-sparc.c: Enable BFD_RELOC_SPARC_UA16, BFD_RELOC_SPARC_UA32
3287 and BFD_RELOC_SPARC_UA64 mapping
3288 * elf64-sparc.c: Likewise.
3289
32902001-05-25 H.J. Lu <hjl@gnu.org>
3291
3292 * Makefile.am (BFD32_BACKENDS): Remove coff-pmac.lo.
3293 (BFD32_BACKENDS_CFILES): Remove coff-pmac.c.
3294 (coff-rs6000.lo): Remove the old dependency.
3295 * Makefile.in: Rebuild.
3296
3297 * configure.in (pmac_xcoff_vec): Replace coff-pmac.lo with
3298 coff-rs6000.lo.
3299
33002001-05-25 H.J. Lu <hjl@gnu.org>
3301
3302 * coff-rs6000.c (rs6000coff_vec): Use rs6000coff_core_p,
3303 rs6000coff_core_file_matches_executable_p,
3304 rs6000coff_core_file_failing_command and
3305 rs6000coff_core_file_failing_signal only if AIX_CORE is
3306 defined.
3307 (pmac_xcoff_vec): Likewise.
3308 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
3309
33102001-05-25 Timothy Wall <twall@redhat.com>
3311
3312 * elfxx-ia64.c (allocate_dynrel_entries): Don't allocate an entry
3313 for __GLOB_DATA_PTR on AIX5. Clean up some relocation bugs.
3314
33152001-05-25 H.J. Lu <hjl@gnu.org>
3316
3317 * bfd-in2.h: Regenerated.
3318 * libcoff.h: Likewise.
3319
33202001-05-25 Alan Modra <amodra@one.net.au>
3321
3322 * elf32-hppa.c (elf32_hppa_relocate_section): Don't allow
3323 undefined millicode syms in shared libs.
3324 (hppa_build_one_stub): Turn BFD_ASSERTs into aborts.
3325 (elf32_hppa_check_relocs): Likewise.
3326 (elf32_hppa_adjust_dynamic_symbol): Likewise.
3327 (elf32_hppa_size_dynamic_sections): Likewise.
3328 (elf32_hppa_relocate_section): Likewise.
3329 (elf32_hppa_finish_dynamic_symbol): Likewise.
3330 (elf32_hppa_finish_dynamic_sections): Likewise.
3331
33322001-05-24 Tom Rix <trix@redhat.com>
3333
3334 * Makefile.am coff-pmac bfd now defined in coff-rs6000.c
3335 xcoff-target.h not used to define rs6000 or ppc bfd.
3336 * Makefile.in same
3337
3338 * bfd-in.h : (struct lineno_cache_entry) promote element "offset"
3339 to 64 bit.
3340
3341 * coff-rs6000.c : Many changes for 64 bit support. Move common
3342 32/64 code to xcofflink.c. Explictly define the rs6000coff_vec
3343 and pmac_xcoff_vec
3344
3345 * coff64-rs6000.c : Many changes for 64 bit support. 64 bit
3346 linker now supported. Explictly define the rs6000coff64_vec.
3347
3348 * coffcode.h : (coff_set_arch_mach_hook) xcoff 64 bit support
3349 (coff_print_aux) same
3350 (coff_write_object_contents) same
3351 (coff_slurp_line_table) same
3352
3353 * coffgen.c : (coff_fix_symbol_name) formatting
3354 (coff_mangle_symbols) xcoff 64 bit support
3355 (coff_write_symbol) same
3356 (coff_write_alien_symbol) same
3357 (coff_write_native_symbol) same
3358 (coff_write_symbols) same
3359 (coff_get_symbol_info) same
3360 (bfd_coff_get_syment) same
3361 (coff_print_symbol) same
3362
3363 * config.bfd : add powerpc64-*-aix* target
3364
3365 * libcoff-in.h : formatting
3366
3367 * libcoff.h : move xcoff extern declarations to libxcoff.h
3368
3369 * libxcoff.h : New file
3370
3371 * xcofflink.c : Many changes for xcoff64 support. Move common
3372 structures to include/coff/xcoff.h. Move specific structure to
3373 backends coff-rs6000.c and coff64-rs6000.c. Use new backend
3374 functions, defined in libxcoff.h, to isolate 32/64 dependencies.
3375
3376 (bfd_xcoff_size_dynamic_sections) : special __rtinit symbol for
3377 aix4.2+ -binitfini.
3378
3379 (xcoff_build_ldsyms) : handle special __rtinit symbol.
3380
33812001-05-23 Alexandre Oliva <aoliva@redhat.com>
3382
3383 * elf64-sparc.c (sparc64_elf_slurp_reloc_table): Fix typo
3384 s/ENTIRES/ENTRIES/.
3385
33862001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3387
3388 * reloc.c (bfd_reloc_code_real): Add MIPS ELF64 relocations.
3389 * libbfd.h: Regenerate.
3390 * bfd-in2.h: Regenerate.
3391
3392 * aoutx.h (aout_@var{size}_machine_type): Add MIPS r12k support.
3393 * archures.c (bfd_mach_mips12000): Define.
3394 * cpu-mips.c (arch_info_struct): Add MIPS r12k support.
3395 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Add MIPS r12k
3396 support.
3397 (_bfd_mips_elf_size_dynamic_sections): Use official bfd typedef.
3398 * bfd-in2.h: Regenerate.
3399 * elfxx-target.h: Do not redefine bfd_elfNN_bfd_make_debug_symbol.
3400
34012001-05-23 kaz Kojima <kkojima@rr.iij4u.or.jp>
3402
3403 * elf32-sh.c (elf_sh_plt0_entry_be, elf_sh_plt0_entry,
3404 elf_sh_plt_entry_be, elf_sh_plt_entry, elf_sh_pic_plt_entry_be,
3405 elf_sh_pic_plt_entry): New PLT code, that does not use r2, since
3406 that is used by GCC.
3407
34082001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3409
3410 * elf-bfd.h (NUM_SHDR_ENTRIES): New macro: compute the number
3411 of entries in a structured section.
3412 * elf.c: Use new macro.
3413 * elf32-i386.c: Use new macro.
3414 * elf32-mips.c: Use new macro.
3415 * elf64-alpha.c: Use new macro.
3416 * elf64-sparc.c: Use new macro.
3417 * elfcode.h: Use new macro.
3418 * elflink.h: Use new macro.
3419
34202001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3421
3422 * bfdint.texi: Replace -oformat with --oformat.
3423
34242001-05-21 Andreas Jaeger <aj@suse.de>
3425
3426 * dwarf2.c (decode_line_info): Fix error message.
3427 (read_abbrevs): Fix test for offset as suggested by Alan Modra and
3428 adjust error message.
3429
34302001-05-18 H.J. Lu <hjl@gnu.org>
3431
3432 * elflink.h (elf_link_add_object_symbols): Revert the last
3433 change.
3434
34352001-05-17 Alan Modra <amodra@one.net.au>
3436
3437 * elf32-hppa.c (clobber_millicode_symbols): Temporarily set
3438 ELF_LINK_FORCED_LOCAL to suit 2001-04-30 change.
3439 (hppa_build_one_stub): Add an assert to check plt.offset.
3440
34412001-05-17 H.J. Lu <hjl@gnu.org>
3442
3443 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the
3444 version definition to basename of the output filename.
3445
34462001-05-17 H.J. Lu <hjl@gnu.org>
3447
3448 * elflink.h (elf_link_add_object_symbols): Set DT_NEEDED to
3449 basename of the bfd filename.
3450
34512001-05-16 Alan Modra <amodra@one.net.au>
3452
3453 * section.c (asection): Add linker_has_input field.
3454 (STD_SECTION): Adjust initialization to suit.
3455 * ecoff.c (bfd_debug_section): Likewise.
3456 * bfd-in2.h: Regenerate.
3457
34582001-05-15 Alexandre Oliva <aoliva@redhat.com>
3459
3460 * elf-m10300.c (mn10300_elf_relax_section): Don't relax
3461 negative 32-bit operands to 16 operands when the operand is
3462 going to be zero-extended by the modified opcode.
3463
34642001-05-12 Peter Targett <peter.targett@arccores.com>
3465
3466 * cpu-arc.c (arch_info_struct): Add entry 'base' representing old
3467 name for 'arc5' core versions.
3468 (bfd_arc_arch): Make bfd_mach_arc_6 default.
3469
3470 * elf32-arc.c (arc_elf_object_p): Make E_ARC_MACH_ARC6 default
3471 architecture.
3472 (arc_elf_final_write_processing): Make bfd_mach_arc_6 default.
3473
34742001-05-11 Jakub Jelinek <jakub@redhat.com>
3475
3476 * elfxx-ia64.c (is_unwind_section_name): Consider linkonce unwind
3477 sections as well.
3478 (elfNN_ia64_final_write_processing): Map .gnu.linkonce.ia64unw.FOO
3479 to .gnu.linkonce.t.FOO text section.
3480
34812001-05-11 Jakub Jelinek <jakub@redhat.com>
3482
3483 * merge.c (struct sec_merge_hash_entry): Add u.entsize and u.suffix
3484 fields, change sec into secinfo.
3485 (struct sec_merge_info): Add chain, remove last fields.
3486 (struct sec_merge_sec_info): Add next, sec, psecinfo fields.
3487 (sec_merge_hash_lookup): If lookup could not use a string only
3488 because it has bad alignment, mark the old string for deletion.
3489 (sec_merge_add): Add secinfo argument. Don't compute entry's
3490 position, instead record the section.
3491 (sec_merge_emit): Update for the sec into secinfo change in
3492 struct sec_merge_hash_entry.
3493 (_bfd_merge_section): Only record the section for merging, defer
3494 putting strings into the hash table.
3495 (cmplengthentry, last4_eq, last_eq, record_section, merge_strings,
3496 _bfd_merge_sections): New functions.
3497 (_bfd_merged_section_offset): Update for the sec_merge_hash_entry
3498 changes.
3499 * libbfd-in.h (_bfd_merge_sections): Add prototype.
3500 (_bfd_nolink_bfd_merge_sections): Define.
3501 * libbfd.h: Likewise.
3502 (bfd_generic_merge_sections): Add prototype.
3503 * targets.c (BFD_JUMP_TABLE_LINK): Add _bfd_merge_sections.
3504 (struct bfd_target): Likewise.
3505 * bfd.c (bfd_merge_sections): Define.
3506 * bfd-in2.h: Rebuilt.
3507 * elf.c (_bfd_elf_merge_sections): New function.
3508 * elf-bfd.h (_bfd_elf_merge_sections): Add prototype.
3509 * elfxx-target.h (bfd_elfNN_bfd_merge_sections): Define.
3510 * reloc.c (bfd_generic_merge_sections): New function.
3511 * vms.c (vms_bfd_merge_sections): New function.
3512 * aout-adobe.c (aout_32_bfd_merge_sections): Define.
3513 * aout-target.h (MY_bfd_merge_sections): Define.
3514 * aout-tic30.c (MY_bfd_merge_sections): Define.
3515 * binary.c (binary_bfd_merge_sections): Define.
3516 * bout.c (b_out_bfd_merge_sections): Define.
3517 * coff-alpha.c (_bfd_ecoff_bfd_merge_sections): Define.
3518 * coffcode.c (coff_bfd_merge_sections): Define.
3519 * coff-mips.c (_bfd_ecoff_bfd_merge_sections): Define.
3520 * i386msdos.c (msdos_bfd_merge_sections): Define.
3521 * i386os9k.c (os9k_bfd_merge_sections): Define.
3522 * ieee.c (ieee_bfd_merge_sections): Define.
3523 * ihex.c (ihex_bfd_merge_sections): Define.
3524 * nlm-target.h (nlm_bfd_merge_sections): Define.
3525 * oasys.c (oasys_bfd_merge_sections): Define.
3526 * ppcboot.c (ppcboot_bfd_merge_sections): Define.
3527 * som.c (som_bfd_merge_sections): Define.
3528 * srec.c (srec_bfd_merge_sections): Define.
3529 * tekhex.c (tekhex_bfd_merge_sections): Define.
3530 * versados.c (versados_bfd_merge_sections): Define.
3531 * xcoff-target.h (_bfd_xcoff_bfd_merge_sections): Define.
3532
35332001-05-11 Nick Clifton <nickc@cambridge.redhat.com>
3534
3535 * dwarf1.c (_bfd_dwarf1_find_nearest_line): Change type of 'addr'
3536 to be unsigned long, in order to match its use.
3537
35382001-05-10 H.J. Lu <hjl@gnu.org>
3539
3540 * linker.c (_bfd_generic_link_add_one_symbol): Check loop on
3541 indirect symbols.
3542
35432001-05-09 H.J. Lu <hjl@gnu.org>
3544
3545 * elflink.h (elf_link_add_object_symbols): Fix a typo. Allocate
3546 versymhdr->sh_size bytes for extversym instead of hdr->sh_size.
3547 Remove the unused veriable `dynver'.
3548
35492001-05-08 Ian Lance Taylor <ian@zembu.com>
3550
3551 * coff-i386.c (coff_i386_reloc): Don't dump core if output_bfd is
3552 NULL or is not COFF.
3553 (coff_i386_rtype_to_howto): Don't dump core if output section
3554 owner is not COFF.
3555
35562001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3557
3558 * ecoff.c (bfd_debug_section): Fix initialization.
3559 * elf.c (_bfd_elf_slurp_version_tables): Change maxidx to unsigned, it
3560 is always a positive integer. Cast away sign mismatch.
3561 * elf32-mips.c: Fix misleading comment and typo.
3562 (_bfd_mips_elf_section_from_bfd_section): Remove unused attribute, use
3563 correct data type.
3564 * elflink.c: Fix typo.
3565 (_bfd_elf_create_dynamic_sections): Remove superfluous initialization.
3566 * ecoffswap.h (ecoff_swap_fdr_in): Cast away sign mismatch.
3567
35682001-05-04 Richard Henderson <rth@redhat.com>
3569
3570 * elf64-alpha.c (SREL16, SREL32, SREL64): Set pcrel_offset true.
3571
35722001-05-04 Nick Clifton <nickc@cambridge.redhat.com>
3573
3574 * elf32-arm.h (elf32_arm_final_link_relocate): Set
3575 EF_ARM_HASENTRY if the start address is set.
3576
35772001-05-03 Nick Clifton <nickc@cambridge.redhat.com>
3578
3579 * targets.c (_bfd_target_vector_entries): Compute value based on
3580 the size of the _bfd_target_vector and not bfd_target_vector.
3581
35822001-05-03 H.J. Lu <hjl@gnu.org>
3583
3584 * elfcode.h: Include "libiberty.h".
3585
3586 * elflink.h (elf_link_add_object_symbols): Set
3587 elf_dt_name (abfd) to basename of the bfd filename.
3588 (NAME(bfd_elf,size_dynamic_sections)): Set vn_file to basename
3589 of the bfd filename.
3590
35912001-05-03 Andreas Jaeger <aj@suse.de>
3592
3593 * elf64-gen.c (elf_generic_info_to_howto): Add unused attribute.
3594 (elf_generic_info_to_howto_rel): Likewise.
3595 * coff-alpha.c (reloc_nil): Likewise.
3596 (alpha_ecoff_bad_format_hook): Likewise.
3597 (alpha_adjust_reloc_out): Likewise.
3598 (alpha_bfd_reloc_type_lookup): Likewise.
3599 (alpha_convert_external_reloc): Likewise.
3600 * elf64-alpha.c (elf64_alpha_reloc_nil): Likewise.
3601 (elf64_alpha_reloc_bad): Likewise.
3602 (elf64_alpha_reloc_gpdisp): Likewise.
3603 (elf64_alpha_bfd_reloc_type_lookup): Likewise.
3604 (elf64_alpha_info_to_howto): Likewise.
3605 (elf64_alpha_add_symbol_hook): Likewise.
3606 (elf64_alpha_create_got_section): Likewise.
3607 (elf64_alpha_is_local_label_name): Likewise.
3608 (elf64_alpha_merge_ind_symbols): Likewise.
3609 * elf64-mips.c (mips_elf64_reloc_type_lookup): Likewise.
3610 (mips_elf64_get_reloc_upper_bound): Likewise.
3611 * nlm32-alpha.c (nlm_alpha_mangle_relocs): Likewise.
3612 (nlm_alpha_get_public_offset): Likewise.
3613
36142001-05-02 Johan Rydberg <jrydberg@opencores.org>
3615
3616 * elf32-openrisc.c (openrisc_elf_howto_table): Do not complain
3617 about overflow in R_OPENRISC_LO_16_IN_INSN and
3618 R_OPENRISC_HI_16_IN_INSN.Index: bfd/elf32-openrisc.c
3619
36202001-04-30 H.J. Lu <hjl@gnu.org>
3621
3622 * elf.c (_bfd_elf_link_hash_hide_symbol): Set dynindx to -1
3623 only for ELF_LINK_FORCED_LOCAL.
3624 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
3625 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise.
3626 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
3627
3628 * elflink.h (elf_fix_symbol_flags): Set ELF_LINK_FORCED_LOCAL
3629 if the symbol has hidden or internal visibility.
3630
36312001-04-30 Alan Modra <amodra@one.net.au>
3632
3633 * elf32-hppa.c (final_link_relocate): Branch to .+8 for
3634 calls to undefined weak symbols.
3635
36362001-04-30 Andreas Jaeger <aj@suse.de>, Andreas Schwab <schwab@suse.de>
3637
3638 * elf64-x86-64.c (elf64_x86_64_relocate_section): Correct test for
3639 R_X86_64_GOTPCREL, don't use assignments instead of comparisons.
3640
36412001-04-27 Andreas Jaeger <aj@suse.de>
3642
3643 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_sections): Only swap
3644 out handled entries.
3645 (elf64_x86_64_finish_dynamic_symbol): Set up GOT entries.
3646 (elf64_x86_64_relocate_section): Fix GOTPCREL calculation.
3647 (elf64_x86_64_relocate_section): Merge entries for GOTPCREL and
3648 GOT32.
3649
36502001-04-27 Sean McNeil <sean@mcneil.com>
3651
3652 * config.bfd: Add arm-vxworks target.
3653 * coff-arm (coff_arm_relocate_section): Add in symbol value to
3654 addend (fro VXworks targets).
3655
36562001-04-26 H.J. Lu <hjl@gnu.org>
3657
3658 * elf32-i386.c (elf_i386_check_relocs): Verify if r_symndx is
3659 valid.
3660
36612001-04-25 Frank Ch. Eigler <fche@redhat.com>
3662
3663 * bfd-in.h (bfd_cache_close): Declare newly exported function.
3664 * bfd-in2.h: Regenerated.
3665
36662001-04-24 Jakub Jelinek <jakub@redhat.com>
3667
3668 * merge.c (struct sec_merge_hash_entry): Add alignment field.
3669 (struct sec_merge_hash): Remove alignment_power.
3670 (sec_merge_hash_newfunc): Clear alignment.
3671 (sec_merge_hash_lookup): Pass alignment as argument.
3672 Use hashp->root.next, not hashp->next to walk the hash chain.
3673 If a string already in the hashtable does not have required
3674 alignment, create a new hashtable entry.
3675 (sec_merge_init): Remove alignment_power argument.
3676 (sec_merge_add): Add alignment argument.
3677 (sec_merge_emit): Alignment is now a per-entity thing, not per
3678 section.
3679 (_bfd_merge_section): Sanity check even non-SEC_STRINGS sections
3680 for proper alignment.
3681 Pass alignment information to sec_merge_add.
3682
36832001-04-24 Christian Groessler <cpg@aladdin.de>
3684
3685 * coff-z8k.c (extra_case): added handler for R_DISP7, R_CALLR
3686 and R_REL16 reloc types; accept odd values for R_REL16 type
3687
36882001-04-24 Johan Rydberg <jrydberg@opencores.org>
3689
3690 * cpu-openrisc.c: New file.
3691 * elf32-openrisc.c: Likewise.
3692
3693 * Makefile.am (ALL_MACHINES): Add cpu-openrisc.lo.
3694 (ALL_MACHINES_CFILES): Add cpu-openrisc.c.
3695 (BFD32_BACKENDS): Add elf32-openrisc.lo.
3696 (BFD32_BACKENDS_CFILES): Add elf32-openrisc.c.
3697 (cpu-openrisc.lo, elf32-openrisc.lo): New rules.
3698 * Makefile.in: Regenerated.
3699 * config.bfd: (openrisc-*-elf): New target.
3700 * configure.in (bfd_elf32_openrisc_vec): New vector.
3701 * configure: Regenerated.
3702 * libbfd.h: Regenerated.
3703 * bfd-in2.h: Regenerated.
3704 * reloc.c: Add OpenRISC relocations.
3705 * targets.c (bfd_elf32_openrisc_vec): Declare.
3706 (bfd_target_vect): Add bfd_elf32_openrisc_vec.
3707 * archures.c (enum bfd_architecture): Add bfd_arch_openrisc.
3708 (bfd_openrisc_arch): Declare.
3709 (bfd_archures_list): Add bfd_openrisc_arch.
3710 * elf.c (prep_headers): Add bfd_arch_openrisc.
3711
37122001-04-23 Bo Thorsen <bo@suse.de>
3713
3714 * elf64-x86-64.c: Add c++ vtable hack.
3715 Small whitespace and comment changes.
3716
37172001-04-19 Andreas Jaeger <aj@suse.de>
3718
3719 * elf64-x86-64.c (elf64_x86_64_plt0_entry): Fix instructions.
3720 (elf64_x86_64_plt_entry): Likewise.
3721 (elf64_x86_64_finish_dynamic_sections): Fix PLT0 generation.
3722 (elf64_x86_64_finish_dynamic_symbol): Fix PLT generation.
3723
37242001-04-17 Hans-Peter Nilsson <hp@axis.com>
3725
3726 * elf32-cris.c: Tweak comments related to dynamic linking.
3727 (cris_elf_relocate_section): When not creating shared object, fill
3728 in the .got table for any symbol not in the dynamic symbol table.
3729 (elf_cris_finish_dynamic_symbol): When not creating shared object,
3730 only emit a .got.rela reloc if the symbol is in the dynamic symbol
3731 table.
3732 (cris_elf_check_relocs): Use variable r_type in all places rather
3733 than the original expression. Add default case in switch for
3734 reloc types.
3735 (elf_cris_size_dynamic_sections): Iterate over
3736 elf_cris_discard_excess_program_dynamics when not creating shared
3737 library.
3738 (elf_cris_discard_excess_dso_dynamics): Renamed from
3739 elf_cris_discard_copies. Correct typo, s/Rel/Rela/.
3740 (elf_cris_discard_excess_program_dynamics): New.
3741
37422001-04-14 Mark Elbrecht <snowball3@bigfoot.com>
3743
3744 * coffcode.h (coff_write_object_contents): Use
3745 bfd_coff_swap_filehdr_out instead of coff_swap_filehdr_out.
3746
37472001-04-14 H.J. Lu <hjl@gnu.org>
3748
3749 * bfd-in2.h: Regenerate.
3750
37512001-04-14 Jakub Jelinek <jakub@redhat.com>
3752
3753 * section.c (STD_SECTION): Add entsize.
3754
37552001-04-13 H.J. Lu <hjl@gnu.org>
3756
3757 * section.c (SEC_MERGE): Define new flag for merging.
3758 (SEC_STRINGS): Likewise.
3759 (entsize): New field.
3760
37612001-04-13 Roger Sayle <roger@metaphorics.com>
3762
3763 * coff-i386.c (TARGET_SYM): SEC_READONLY is an applicable section
3764 flag on pe-i386 targets.
3765
37662001-04-13 Jakub Jelinek <jakub@redhat.com>
3767
3768 * libbfd-in.h (_bfd_merge_section): New.
3769 (_bfd_write_merged_section): New.
3770 (_bfd_merged_section_offset): New.
3771 * libbfd.h: Rebuilt.
3772 * linker.c (_bfd_generic_link_output_symbols): Handle
3773 discard_sec_merge.
3774 * aoutx.h (aout_link_write_symbols): Likewise.
3775 * pdp11.c (aout_link_write_symbols): Likewise.
3776 * elflink.h (elf_link_add_object_symbols): Call _bfd_merge_section.
3777 (elf_bfd_final_link): Adjust global symbols pointing into SEC_MERGE
3778 sections.
3779 (elf_link_sec_merge_syms): New.
3780 (elf_link_input_bfd): Call _bfd_merged_section_offset
3781 and _bfd_write_merged_section.
3782 Handle discard_sec_merge.
3783 * elf-bfd.h (struct elf_link_hash_table): Add merge_info
3784 field.
3785 (struct bfd_elf_section_data): Likewise.
3786 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_MERGE and
3787 SEC_STRINGS section flags and entsize from their ELF counterparts.
3788 (_bfd_elf_link_hash_table_init): Initialize merge_info.
3789 (elf_fake_sections): Set SHF_MERGE, SHF_STRINGS and sh_entsize
3790 from their BFD counterparts.
3791 * merge.c: New file.
3792 * Makefile.am: Add strtab.lo.
3793 * Makefile.in: Rebuilt.
3794
37952001-04-09 Hans-Peter Nilsson <hp@axis.com>
3796
3797 * elflink.h (elf_fix_symbol_flags): For non-default visibilities,
3798 only hide symbols marked STV_INTERNAL or STV_HIDDEN.
3799
38002001-04-05 Steven J. Hill <sjhill@cotw.com>
3801
3802 * config.bfd (mips*el*-*-linux-gnu*): Use traditional little
3803 endian MIPS ELF target.
3804 * config.bfd (mips*-*-linux-gnu*): Use traditional big endian
3805 MIPS ELF target.
3806
3807 * configure.in (bfd_elf64_tradbigmips_vec): New. Traditional
3808 64bit big endian MIPS ELF target.
3809 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3810 endian MIPS ELF target.
3811 * configure: Regenerated.
3812
3813 * elf32-mips.c (IRIX_COMPAT): Handle traditional 64bit and
3814 little endian targets.
3815 (mips_elf_sym_is_global): Handle traditional targets.
3816
3817 * elf64-mips.c (bfd_elf64_tradbigmips_vec): New. Traditional
3818 64bit big endian MIPS ELF target.
3819 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3820 endian MIPS ELF target.
3821
3822 * targets.c: (_bfd_target_vector): Add bfd_elf64_tradbigmips_vec
3823 and bfd_elf64_tradlittlemips_vec.
3824
38252001-04-05 David Mosberger <davidm@hpl.hp.com>
3826
3827 * elf32-i386.c (elf_i386_fake_sections): Treat ".reloc" as an
3828 ordinary "progbits" section.
3829
38302001-04-04 Alan Modra <alan@linuxcare.com.au>
3831
3832 * elflink.h (elf_fix_symbol_flags): Call elf_backend_hide_symbol
3833 when -Bsymbolic causes a symbol to no longer need a .plt entry.
3834
38352001-04-03 David Mosberger <davidm@hpl.hp.com>
3836
3837 * efi-app-ia32.c (ALIGN_SECTIONS_IN_FILE): Deleted.
3838
38392001-03-30 H.J. Lu <hjl@gnu.org>
3840
3841 * efi-app-ia32.c (PEI_TARGET_SUBSYSTEM): Rename from ...
3842 (PEI_DEFAULT_TARGET_SUBSYSTEM): This.
3843
38442001-03-26 H.J. Lu <hjl@gnu.org>
3845
3846 * elf32-gen.c (elf32_generic_link_add_symbols): New. Check
3847 if there are any relocations for generic ELF.
3848 (bfd_elf32_bfd_link_add_symbols): Defined to
3849 elf32_generic_link_add_symbols.
3850 * elf64-gen.c (elf64_generic_link_add_symbols): New. Check
3851 if there are any relocations for generic ELF.
3852 (bfd_elf64_bfd_link_add_symbols): Defined to
3853 elf64_generic_link_add_symbols.
3854
38552001-03-23 Nick Clifton <nickc@redhat.com>
3856
3857 * Makefile.am (BUILD_CFILES): New variable: List of C source
3858 files created in build directory.
3859 (BUILD_HFILES): New variable: List of header files created in
3860 build directory.
3861 (POTFILES): Delete.
3862 (po/POTFILES.in): Replace rule with empty entry.
3863 (po/SRC-POTFILES.in): New rule: Create a list of source files
3864 in the source directory.
3865 (po/BLD-POTFILES.in): New rule: Create a list of source files
3866 in the build directory.
3867 (MOSTLYCLEAN): Do not delete source files created in build
3868 directory.
3869 * Makefile.in: Regenerate.
3870 * configure.in: Insert SRC-POTFILES.in and BLD-POTFILES.in
3871 into po/Makefile.
3872 * configure: Regenerate.
3873
3874 * po/Make-in: Replace occurrences of POTFILES with SRC-POTFILES
3875 and BLD_POTFILES.
3876 Add .. to the search path when building bfd.pot.
3877 Delete POTFILES when performing distclean.
3878 Add comment describing why distclean is broken in maintainer mode.
3879 * po/POTFILES.in: Delete.
3880 * po/SRC-POTFILES.in: New file.
3881 * po/BLD-POTFILES.in: New file.
3882 * po/bfd.pot: Regenerate.
3883
38842001-03-22 Hans-Peter Nilsson <hp@axis.com>
3885
3886 * elf32-cris.c: Shlib and PIC support. PCREL tweaks.
3887 (elf_cris_discard_copies, elf_cris_adjust_gotplt_to_got,
3888 elf_cris_try_fold_plt_to_got, elf_cris_link_hash_newfunc,
3889 elf_cris_link_hash_table_create, elf_cris_adjust_dynamic_symbol,
3890 elf_cris_size_dynamic_sections, elf_cris_finish_dynamic_symbol,
3891 elf_cris_finish_dynamic_sections,elf_cris_hide_symbol): New
3892 functions.
3893 (cris_elf_howto_table) <R_CRIS_8_PCREL, R_CRIS_16_PCREL,
3894 R_CRIS_32_PCREL>: Correct comments. Set pcrel_offset to false.
3895 <R_CRIS_COPY, R_CRIS_GLOB_DAT, R_CRIS_JUMP_SLOT, R_CRIS_RELATIVE,
3896 R_CRIS_16_GOT, R_CRIS_32_GOT, R_CRIS_16_GOTPLT, R_CRIS_32_GOTPLT,
3897 R_CRIS_32_GOTREL, R_CRIS_32_PLT_GOTREL, R_CRIS_32_PLT_PCREL>:
3898 New HOWTO members for new relocs.
3899 (cris_reloc_map): Map new relocs.
3900 (ELF_DYNAMIC_INTERPRETER): Define.
3901 (PLT_ENTRY_SIZE): Define.
3902 (elf_cris_plt0_entry, elf_cris_plt_entry, elf_cris_pic_plt0_entry,
3903 elf_cris_pic_plt_entry): New, PLT templates.
3904 (struct elf_cris_pcrel_relocs_copied, struct
3905 elf_cris_link_hash_entry, struct elf_cris_link_hash_table): New.
3906 (elf_cris_link_hash_traverse, elf_cris_hash_table): Define.
3907 (cris_final_link_relocate): Check that 16-bit GOT relocs have
3908 positive values. Adjust PCREL relocs to be relative to location
3909 after relocation.
3910 (cris_elf_relocate_section): Handle relocations to dynamic
3911 objects. Handle new relocations. Call error handler when seeing
3912 non-PIC relocation for read-only sections while generating shared
3913 object.
3914 (cris_elf_check_relocs): Set reference counts for GOT and PLT
3915 entries.
3916 (bfd_elf32_bfd_link_hash_table_create,
3917 elf_backend_adjust_dynamic_symbol,
3918 elf_backend_size_dynamic_sections,
3919 elf_backend_finish_dynamic_symbol,
3920 elf_backend_finish_dynamic_sections,
3921 elf_backend_create_dynamic_sections, bfd_elf32_bfd_final_link,
3922 elf_backend_hide_symbol, elf_backend_want_got_plt,
3923 elf_backend_plt_readonly, elf_backend_want_plt_sym,
3924 elf_backend_got_header_size, elf_backend_plt_header_size):
3925 Define.
3926
3927 * reloc.c: (BFD_RELOC_CRIS_COPY, BFD_RELOC_CRIS_GLOB_DAT,
3928 BFD_RELOC_CRIS_JUMP_SLOT, BFD_RELOC_CRIS_RELATIVE,
3929 BFD_RELOC_CRIS_32_GOT, BFD_RELOC_CRIS_16_GOT,
3930 BFD_RELOC_CRIS_32_GOTPLT, BFD_RELOC_CRIS_16_GOTPLT,
3931 BFD_RELOC_CRIS_32_GOTREL, BFD_RELOC_CRIS_32_PLT_GOTREL,
3932 BFD_RELOC_CRIS_32_PLT_PCREL): New relocs.
3933 * bfd-in2.h, libbfd.h: Regenerate.
3934
39352001-03-21 Diego Novillo <dnovillo@redhat.com>
3936
3937 (_bfd_mips_elf_relocate_section): Give a better error message when
3938 a relocation is not recognized.
3939
39402001-03-21 Alan Modra <alan@linuxcare.com.au>
3941
3942 * elf32-hppa.c (elf32_hppa_set_gp): Check sec->output_section
3943 non-NULL before attempting to dereference.
3944
39452001-03-20 H.J. Lu <hjl@gnu.org>
3946
3947 * configure.in: Remove the redundent AC_ARG_PROGRAM.
3948 * configure: Rebuild.
3949
39502001-03-20 Andreas Schwab <schwab@suse.de>
3951
3952 * elf32-m68k.c (elf_m68k_relocate_section): Don't need the
3953 relocation value when resolving a reference from a debugging
3954 section.
3955
39562001-03-16 Scott Thomason <SThomaso@hii.com>
3957
3958 * coff64-rs6000.c (xcoff64_swap_sym_out): Fix syntax errors.
3959 (xcoff64_swap_sym_out): Fix syntax errors.
3960
39612001-03-16 Richard Sandiford <rsandifo@redhat.com>
3962
3963 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix warning.
3964
39652001-03-15 Alan Modra <alan@linuxcare.com.au>
3966
3967 * elf32-hppa.c (elf32_hppa_link_hash_entry): Add maybe_pic_call.
3968 (hppa_link_hash_newfunc): Init it.
3969 (hppa_type_of_stub): Only use non-PIC to PIC call stub if caller
3970 section appears to be non-PIC.
3971 (final_link_relocate): Likewise.
3972 (elf32_hppa_adjust_dynamic_symbol): Set maybe_pic_call for any
3973 possible candidate function, and set pic_call for those that will
3974 only have a .plt entry for the PIC call stub.
3975 (hppa_handle_PIC_calls): Set maybe_pic_call.
3976
39772001-03-12 DJ Delorie <dj@redhat.com>
3978
3979 * elf32-sh.c (sh_elf_relocate_section): Only relocation
3980 R_SH_DIR8WP* relocs if they're against external symbols, else
3981 they're just for relaxing. Validate the reloc values.
3982
39832001-03-12 Stefan Geuken <mail@stefan-geuken.de>
3984
3985 * binary.c (bfd_external_binary_architecture): Declare.
3986 (binary_object_p): If bfd_external_binary_architecture is defined,
3987 set the architecture to this string.
3988
39892001-03-11 Philip Blundell <philb@gnu.org>
3990
3991 * elf32-arm.h (elf32_arm_finish_dynamic_symbol): Don't make PLT
3992 entries that could serve as a definition for a weak symbol.
3993
39942001-03-08 Nick Clifton <nickc@redhat.com>
3995
3996 * Most files: Update copyright notices using Perl script created
3997 by Kevin Buettner <kevinb@redhat.com>.
3998
39992001-03-07 Nick Clifton <nickc@redhat.com>
4000
4001 * elf32-arm.h (elf32_arm_final_link_relocate): Conditionalise
4002 prior patch on ! defined OLD_ARM_ABI.
4003
40042001-03-07 Andreas Jaeger <aj@suse.de>
4005
4006 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix handling of
4007 some relocation values.
4008
40092001-03-06 Nick Clifton <nickc@redhat.com>
4010
4011 * elf32-arm.h (elf32_arm_final_link_relocate): Clear bit zero
4012 of offset in BLX(1) instruction.
4013 * coff-arm.c (coff_arm_relocate_section): Clear bit zero of
4014 offset in BLX(1) instruction.
4015 Fix formatting.
4016
40172001-03-06 Nick Clifton <nickc@redhat.com>
4018
4019 * coff-arm.c (coff_arm_reloc_type_lookup): Add
4020 BFD_RELOC_THUMB_PCREL_BLX.
4021
40222001-03-06 Igor Shevlyakov <igor@windriver.com>
4023
4024 * archures.c (bfd_default_scan): Add Coldfire CPUs.
4025 * bfd-in2.h: Regenerate.
4026 * cpu-m68k.c: Add Coldfire CPUs for arch table.
4027 * ieee.c (ieee_write_processor): Set proper id for
4028 Coldfire CPUs.
4029
40302001-03-01 D.J. Barrow <djbarrow@de.ibm.com,barrow_dj@yahoo.com>
4031
4032 * configure.in: Add s390 target.
4033 * configure: Regenerate.
4034
40352001-02-28 Andreas Jaeger <aj@suse.de>
4036
4037 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add relocation
4038 to addend.
4039
40402001-02-28 Philip Blundell <pb@futuretv.com>
4041
4042 * elf32-arm.h: Update mentions of renamed EF_xx constants.
4043 (elf32_arm_print_private_bfd_data): Handle ARM EABI version 2.
4044
40452001-02-27 H.J. Lu <hjl@gnu.org>
4046
4047 * aoutx.h (NAME(aout,bfd_free_cached_info)): Return true if
4048 abfd->tdata.aout_data == NULL.
4049
40502001-02-27 Alan Modra <alan@linuxcare.com.au>
4051
4052 * elf32-hppa.c: Correct field selector in stub comments.
4053 (clobber_millicode_symbols): Formatting fix.
4054
4055 * configure.in: Bump version to 2.11.90.
4056 * configure: Regenerate.
4057 * Makefile.am (CFILES): Rename to SOURCE_CFILES.
4058 (CFILES): $SOURCE_CFILES + generated C files.
4059 (POTFILES): Include $HFILES not $SOURCE_HFILES.
4060 Run "make dep-am"
4061 * Makefile.in: Regenerate.
4062 * doc/Makefile.in: This too.
4063
40642001-02-26 Timothy Wall <twall@cygnus.com>
4065
4066 * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Remove obsolete
4067 comments.
4068
40692001-02-26 Nick Clifton <nickc@redhat.com>
4070
4071 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Tidy
4072 up, replacing multiple if statements with a switch.
4073 (handle_COMDAT): New function.
4074
40752001-02-26 H.J. Lu <hjl@gnu.org>
4076
4077 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Issue
4078 a warning for section flags we do not handle instead of
4079 aborting.
4080
40812001-02-26 Andreas Jaeger <aj@suse.de>
4082
4083 * elf64-x86-64.c (x86_64_elf_howto_table): Fix order of entries.
4084
40852001-02-22 Timothy Wall <twall@cygnus.com>
4086
4087 * config.bfd (targ_cpu): Add vectors for ia64-*-aix* (aka Monterey).
4088 * configure.in: Add objects for elf64_ia64_aix vectors.
4089 * configure: Regenerated.
4090 * configure.host: Recognize ia64-*-aix*.
4091 * elfxx-ia64.c: Add hooks for ELF64 on AIX5. Define new vectors
4092 for AIX. AIX5 requires most relocations to be dynamic (*all*
4093 binaries are somewhat similar to shared libraries).
4094 * targets.c: Add elf64_ia64_aix vectors.
4095
40962001-02-21 David Mosberger <davidm@hpl.hp.com>
4097
4098 * cpu-ia64-opc.c (elf64_ia64_operands}: Fix typo: error string for
4099 C8 said "1" instead of "8". Clarify error string for IMM22:
4100 "signed integer" instead of just "integer".
4101
41022001-02-20 Andreas Jaeger <aj@suse.de>
4103
4104 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Don't make
4105 PLT entries that could serve as a definition for a weak symbol.
4106
41072001-02-19 Jakub Jelinek <jakub@redhat.com>
4108
4109 * elf32-sparc.c (elf32_sparc_finish_dynamic_symbol): Don't make PLT
4110 entries that could serve as a definition for a weak symbol.
4111 * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Likewise.
4112
41132001-02-18 David O'Brien <obrien@FreeBSD>
4114
4115 * configure.in: Recognize FreeBSD/arm, FreeBSD/PowerPC, and treat
4116 FreeBSD/i386-CURRENT differently until I can figure out the needed
4117 corefile changes.
4118 * configure: Regenerate.
4119 * config.bfd: Recognize FreeBSD/x86-64, FreeBSD/ia64, FreeBSD/arm,
4120 FreeBSD/PowerPC, and FreeBSD/sparc64.
4121
41222001-02-18 lars brinkhoff <lars@nocrew.org>
4123
4124 * Makefile.am: Add PDP-11 a.out target.
4125 * config.bfd: Likewise.
4126 * configure.in: Likewise.
4127 * targets.c: Likewise.
4128 * archures.c: Likewise.
4129 * bfd-in2.h: Likewise. Add PDP-11 relocations.
4130 * libbfd.h: Add PDP-11 relocations.
4131 * reloc.c: Likewise.
4132 * cpu-pdp11.c: New file.
4133 * pdp11.c: New file.
4134
4135 * libaout.h (GET_WORD) [ARCH_SIZE==16]: Define.
4136 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
4137 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
4138 (PUT_WORD) [ARCH_SIZE==16]: Likewise.
4139 (GET_MAGIC): New macro.
4140 (PUT_MAGIC): Likewise.
4141 * aout-target.h (MY(object_p)): Use GET_MAGIC to read magic word.
4142
41432001-02-18 Jim Kingdon <jkingdon@engr.sgi.com>
4144
4145 * irix-core.c (irix_core_core_file_p): Set the architecture (GDB
4146 multiarch needs it).
4147
41482001-02-18 H.J. Lu <hjl@gnu.org>
4149
4150 * elflink.h (elf_link_input_bfd): Ignore invalid section symbol
4151 index.
4152
41532001-02-18 Kazu Hirata <kazu@hxi.com>
4154
4155 * vms-misc.c: Fix formatting.
4156
41572001-02-16 Kazu Hirata <kazu@hxi.com>
4158
4159 * vms.c: Fix formatting.
4160
41612001-02-14 H.J. Lu <hjl@gnu.org>
4162
4163 * elf.c (elf_find_function): New function.
4164 (_bfd_elf_find_nearest_line): Call elf_find_function () to find
4165 the file name and function name.
4166
41672001-02-14 Nick Clifton <nickc@redhat.com>
4168
4169 * ecoff.c (bfd_debug_section): Update to initialise new fields in
4170 asection structure.
4171
4172 * Makefile.am (BFD32_BACKENDS_CFILES): Remove peigen.c
4173 (BFD64_BACKENDS): Add pepigen.c
4174 Add rules to create peigen.c and pepigen.c from peXXigen.c.
4175
4176 * Makefile.in: Regenerate.
4177 * configure: Regenerate.
4178 * po/POTFILES.in: Regenerate.
4179 * po/bfd.pot: Regenerate.
4180
41812001-02-14 H.J. Lu <hjl@gnu.org>
4182
4183 * libcoff-in.h (pe_tdata): Add members target_subsystem and
4184 force_minimum_alignment.
4185
41862001-02-14 Bo Thorsen <bo@suse.de>
4187
4188 * elf64-x86-64.c: Small formatting fixes and rearrangements of code.
4189 (elf64_86_64_size_info): Struct added to fix a problem
4190 with the hashtable string entries.
4191 (elf64_x86_64_adjust_dynamic_symbol): Add generation of .got.plt.
4192 (elf64_x86_64_size_dynamic_sections): A FIXME removed.
4193 (elf64_x86_64_size_dynamic_sections): Fix a dynamic entry and
4194 remove the FIXME for this.
4195 (elf64_x86_64_adjust_dynamic_symbol): Fix check for unneeded .plt
4196 section. Also removed the FIXME for it.
4197 (x86_64_elf_howto_table): Use bfd_elf_generic_reloc.
4198 (ELF_DYNAMIC_INTERPRETER): Fix the name of the dynamic linker.
4199 (elf64_x86_64_finish_dynamic_sections): Enable .got.plt writing.
4200
42012001-02-13 Richard Henderson <rth@redhat.com>
4202
4203 * elfxx-ia64.c (elfNN_ia64_final_link): Set __gp if required
4204 and not user provided.
4205
42062001-02-13 Kazu Hirata <kazu@hxi.com>
4207
4208 * vms.c (vms_print_symbol): Remove unreachable code.
4209
4210 * rs6000-core.c: Fix formatting.
4211
42122001-02-13 David Mosberger <davidm@hpl.hp.com>
4213
4214 * peicode.h (coff_swap_filehdr_out) [COFF_IMAGE_WITH_PE]: Define
4215 as _bfd_XXi_only_swap_filehdr_out.
4216 (pe_mkobject) [PEI_FORCE_MINIMUM_ALIGNMENT]: Set
4217 pe->force_minimum_alignment to TRUE.
4218 (pe_mkobject) [PEI_TARGET_SUBSYSTEM]: Set pe->target_subsystem to
4219 PEI_TARGET_SUBSYSTEM.
4220 (pe_print_private_bfd_data): Call
4221 _bfd_XX_print_private_bfd_data_common() instead of
4222 _bfd_pe_print_private_bfd_data_common().
4223 (pe_bfd_copy_private_bfd_data): Call
4224 _bfd_XX_bfd_copy_private_bfd_data_common() instead of
4225 _bfd_pe_bfd_copy_private_bfd_data_common().
4226 (coff_bfd_copy_private_section_data): Define as
4227 _bfd_XX_bfd_copy_private_section_data instead of
4228 _bfd_pe_bfd_copy_private_section_data.
4229 (coff_get_symbol_info): Define as _bfd_XX_get_symbol_info instead
4230 of a _bfd_pe_get_symbol_info.
4231
4232 * peigen.c: Delete.
4233
4234 * peXXigen.c: Renamed from peigen.c.
4235 (COFF_WITH_XX): Define this macro (will get expanded into
4236 COFF_WITH_pep or COFF_WITH_pe, depending on whether this is being
4237 compiled as peigen.c or pepigen.c.
4238 [COFF_WITH_pep]: Include "coff/ia64.h" instead of "coff/i386.h" to
4239 define the canonical PEP structures and definitions.
4240 (_bfd_XXi_swap_aouthdr_out): If pe->force_minimum_alignment is in
4241 effect, enforce minimum file and section alignments. If
4242 extra->Subsystem is IMAGE_SUBSYSTEM_UNKNOWN, set it to
4243 pe->target_subsystem (this defaults to IMAGE_SUBSYSTEM_UNKNOWN,
4244 so, by default, this is a no-op).
4245
4246 * libpei.h: Rename COFF_WITH_PEP to COFF_WITH_pep.
4247 (_bfd_XX_bfd_copy_private_bfd_data_common): Add macros to map
4248 _bfd_XXfoo to _bfd_pepfoo if COFF_WIT_PEP is defined and to
4249 _bfd_pefoo if it's not defined. Use these macros to define
4250 coff swap macros.
4251
4252 * libcoff.h (pe_tdata): Add members target_subsystem and
4253 force_minimum_alignment.
4254
4255 * efi-app-ia64.c (COFF_WITH_pep): Rename COFF_WITH_PEP to
4256 COFF_WITH_pep.
4257 (PEI_TARGET_SUBSYSTEM): Rename from PEI_DEFAULT_TARGET_SUBSYSTEM.
4258
4259 * configure.in (bfd_efi_app_ia64_vec): Use pepigen.lo instead of
4260 peigen.lo.
4261
4262 * coff-ia64.c: Rename COFF_WITH_PEP to COFF_WITH_pep.
4263 (AOUTSZ): Rename PEP64AOUTSZ and PEP64AOUTHDR to PEPAOUTSZ and
4264 PEPAOUTHDR.
4265
4266 * Makefile.in (BFD64_BACKENDS): Mention pepigen.lo.
4267 (BFD64_BACKENDS_CFILES): Mention pepigen.c
4268 (peigen.c): Add rule to generate from peXXigen.c.
4269 (pepigen.c): Ditto.
4270 (pepigen.lo): List dependencies for pepigen.lo.
4271
42722001-02-13 Alan Modra <alan@linuxcare.com.au>
4273
4274 * elf32-hppa.c (elf32_hppa_set_gp): Handle weak $global$. If
4275 $global$ referenced but not defined, set its value here.
4276
42772001-02-09 Bo Thorsen <bo@suse.de>
4278
4279 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set .rela.got section
4280 alignment to 3.
4281 (elf64_x86_64_check_relocs): Write R_X86_64_GOTPCREL GOT entry
4282 and relocation.
4283 (elf64_x86_64_relocate_section): Fix formatting.
4284 (elf64_x86_64_relocate_section): Fix addend for relocation of
4285 R_X86_64_(8|16|32|PC8|PC16|PC32).
4286
42872001-02-12 Jan Hubicka <jh@suse.cz>
4288
4289 * elf64-x86-64.c (x86_64_elf_howto): Fix name of R_X86_64_GOTPCREL.
4290
42912001-02-11 H.J. Lu <hjl@gnu.org>
4292
4293 * elflink.h (elf_bfd_final_link): Use file_align for SYMTAB
4294 alignment.
4295
42962001-02-11 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
4297
4298 * elf32-mips.c (mips_elf_create_dynamic_relocation): Undo patch
4299 from 2000-10-13. Do not add the symbol's value for R_MIPS_REL32
4300 relocations against dynsym symbols.
4301
4302 * elf32-mips.c (elf_mips_howto_table): Fix the comment on
4303 the R_MIPS_26 relocation.
4304 (mips_elf_calculate_relocation): Use (p + 4) instead of p for
4305 the R_MIPS_26 relocation.
4306 (mips_elf_perform_relocation): Fix the comment on the R_MIPS16_26
4307 relocation.
4308 * elf64-mips.c (mips_elf64_howto_table_rel): Fix the comment on
4309 the R_MIPS_26 relocation.
4310 (mips_elf64_howto_table_rela): Likewise.
4311
4312 * elf32-mips.c (struct mips_elf_link_hash_entry): Added no_fn_stub
4313 member to mark symbols that have non-CALL relocations against
4314 them.
4315 (mips_elf_link_hash_newfunc): Initialize no_fn_stub.
4316 (mips_elf_calculate_relocation): Handle R_MIPS_CALL16 like
4317 R_MIPS_GOT16.
4318 (_bfd_mips_elf_check_relocs): Set no_fn_stub for a symbol if a
4319 non-CALL relocation against it is encountered.
4320 (_bfd_mips_elf_copy_indirect_symbol): Merge no_fn_stub as well.
4321 (_bfd_mips_elf_adjust_dynamic_symbol): Only create a stub if
4322 no_fn_stub is not set.
4323
4324 * elf32-mips.c (mips_elf_output_extsym): Get the output section
4325 information from the real symbol for indirect ones.
4326 Check no_fn_stub to find out if a symbol has a function stub
4327 indeed.
4328
43292001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
4330
4331 * Makefile.am (stamp-lib): ranlib the libbfd.a in the build directory.
4332 * Makefile.in: Regenerate.
4333
43342001-02-09 David Mosberger <davidm@hpl.hp.com>
4335
4336 * elfxx-ia64.c (is_unwind_section_name): New function. Returns
4337 true if section name is an unwind table section name.
4338 (elfNN_ia64_additional_program_headers): Count each unwind section
4339 separately.
4340 (elfNN_ia64_modify_segment_map): Install one unwind program header
4341 for each unwind separate section. Note: normally the linker
4342 script merges the unwind sections that go into a single segment,
4343 so this still generates at most one unwind program header per
4344 segment.
4345
4346 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Accept any section
4347 name for SHT_IA_64_UNWIND, not just .IA_64.unwind.
4348 (elfNN_ia64_fake_sections): Mark sections with names that start
4349 with .IA_64.unwind but not with .IA_64.unwind_info as an IA-64
4350 unwind section.
4351
4352 * elfxx-ia64.c (elfNN_ia64_final_write_processing): New function.
4353 Use it to make sh_info in unwind section point to the text section
4354 it applies to.
4355
43562001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
4357
4358 * Makefile.am: Add linux target for S/390.
4359 * archures.c: Likewise.
4360 * bfd-in2.h: Likewise.
4361 * config.bfd: Likewise.
4362 * configure.in: Likewise.
4363 * elf.c: Likewise.
4364 * libbfd.h: Likewise.
4365 * targets.c: Likewise.
4366 * cpu-s390.c: New file.
4367 * elf32-s390.c: New file.
4368 * elf64-s390.c: New file.
4369
43702001-02-09 Nick Clifton <nickc@redhat.com>
4371
4372 * peigen.c (_bfd_pe_get_symbol_info): Suppress addition of
4373 ImageBase. This has already been done by coff_swap_hdr_in.
4374
43752001-02-09 Jakub Jelinek <jakub@redhat.com>
4376
4377 * elf64-sparc.c (sparc64_elf_copy_private_bfd_data): New function.
4378
43792001-02-09 Jakub Jelinek <jakub@redhat.com>
4380
4381 * elf64-sparc.c (sparc64_elf_check_relocs): Don't trust reloc_count.
4382 (sparc64_elf_relocate_section): Likewise.
4383
43842001-02-09 Mark Kettenis <kettenis@gnu.org>
4385
4386 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Treat R_SPARC_UA32
4387 similar to R_SPARC_32.
4388 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
4389
43902001-02-08 H.J. Lu <hjl@gnu.org>
4391
4392 * elf32-i386.c (elf_i386_check_relocs): Reserve R_386_PC32
4393 relocation entries for weak definitions when building DSO with
4394 -Bsymbolic.
4395
43962001-02-08 Richard Henderson <rth@redhat.com>
4397
4398 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Respect weakness
4399 before visibility. Locally defined protected symbols are not
4400 dynamic.
4401
44022001-02-08 Geoffrey Keating <geoffk@redhat.com>
4403
4404 * config.bfd: Enable coff64 for rs6000-*. Patch from
4405 <hzoli@austin.ibm.com>.
4406
44072001-02-07 Mark Elbrecht <snowball3@bigfoot.com>
4408
4409 * coffgen.c (coff_find_nearest_line): If stabs info is successfully
4410 found, do not attempt to find dwarf2 info before returning.
4411
44122001-02-07 Jakub Jelinek <jakub@redhat.com>
4413
4414 * elflink.h (is_global_symbol_definition): Rename to
4415 is_global_data_symbol_definition and have it reject function
4416 symbols.
4417 (elf_link_is_defined_archive_symbol): Use renamed function.
4418
44192001-02-07 Todd Vierling <tv@wasabisystems.com>
4420
4421 * libbfd-in.h (bfd_target_vector): Change extern array to pointer.
4422 * libbfd.h (bfd_target_vector): Likewise.
4423 * targets.c (bfd_target_vector): Rename to _bfd_target_vector and
4424 make static; create pointer reference named bfd_target_vector.
4425 (_bfd_target_vector_entries): Calculate this based on the array
4426 typed _bfd_target_vector.
4427
44282001-02-06 H.J. Lu <hjl@gnu.org>
4429
4430 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Only hidden and
4431 internal symbols are not dynamic.
4432 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
4433
44342001-02-06 Nick Clifton <nickc@redhat.com>
4435
4436 * Makefile.am (BFD64_BACKENDS_CFILES): Remove elf64-ia64.c, so
4437 that it will not be pulled into the list of files that make up
4438 po/POTFILES.in.
4439 * Makefile.in: Regenerate.
4440 * po/bfd.pot: Regenerate.
4441
44422001-02-06 H.J. Lu <hjl@gnu.org>
4443
4444 * peicode.h (coff_swap_filehdr_in): Remove the e_magic
4445 checking.
4446 (pe_bfd_object_p): Rewrite with external_PEI_DOS_hdr and
4447 external_PEI_IMAGE_hdr.
4448
44492001-02-06 Kazu Hirata <kazu@hxi.com>
4450
4451 * elf-m10200.c: Fix formatting.
4452
44532001-02-04 Nick Clifton <nickc@redhat.com>
4454
4455 * elf32-v850.c (v850_elf_reloc): Do not convert reloc addend to PC
4456 rel, it will be handled later on.
4457
44582001-02-02 Fred Fish <fnf@ninemoons.com>
4459
4460 * Makefile.in: Fix typo.
4461
44622001-02-01 Kazu Hirata <kazu@hxi.com>
4463
4464 * elf-m10300.c: Fix formatting.
4465
44662001-01-30 Alan Modra <alan@linuxcare.com.au>
4467
4468 * elf64-hppa.c (elf64_hppa_elf_get_symbol_type): New function.
4469 (elf_backend_get_symbol_type): Define.
4470 (elf64_hppa_object_p): Set architecture and machine from elf
4471 header flags.
4472
44732001-01-30 Curtis L. Janssen <cljanss@ca.sandia.gov>
4474
4475 * elf64-alpha.c (elf64_alpha_find_nearest_line): Query dwarf2
4476 before mdebug.
4477
44782001-01-26 Richard Henderson <rth@redhat.com>
4479
4480 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Return false
4481 for non-default visibility.
4482 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise, but
4483 delete ugly macro and replace with pretty function.
4484
44852001-01-25 Mark Elbrecht <snowball3@bigfoot.com>
4486
4487 * coff-go32.c: Update copyright.
4488 * coff-stgo32.c: Likewise.
4489 * coff-go32.c (COFF_LONG_FILENAMES): Define.
4490 * coff-stgo32.c (COFF_LONG_FILENAMES): Likewise.
4491 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Remove .bss entry.
4492 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
4493
44942001-01-25 Kazu Hirata <kazu@hxi.com>
4495
4496 * bfd-in2.h: Rebuild.
4497 * libbfd.h: Likewise.
4498
44992001-01-23 H.J. Lu <hjl@gnu.org>
4500
4501 * bfd-in2.h: Rebuild.
4502
45032001-01-23 H.J. Lu <hjl@gnu.org>
4504
4505 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_buf)
4506 is NULL or PRIV(vms_rec) is outside of the buffer.
4507
45082001-01-23 Kazu Hirata <kazu@hxi.com>
4509
4510 * coff64-rs6000.c: Fix formatting.
4511 * coff-arm.c: Likewise.
4512 * coffgen.c: Likewise.
4513 * cofflink.c: Likewise.
4514 * coff-mcore.c: Likewise.
4515 * coff-mips.c: Likewise.
4516 * coff-pmac.c: Likewise.
4517 * coff-ppc.c: Likewise.
4518 * coff-rs6000.c: Likewise.
4519 * elf32.c: Likewise.
4520 * elf32-fr30.c: Likewise.
4521 * elf32-i370.c: Likewise.
4522 * elf32-i860.c: Likewise.
4523 * elf32-m32r.c: Likewise.
4524 * elf32-m68k.c: Likewise.
4525 * elf32-mcore.c: Likewise.
4526 * elf32-ppc.c: Likewise.
4527 * elf32-sh.c: Likewise.
4528 * elf32-v850.c: Likewise.
4529 * elf64-alpha.c: Likewise.
4530 * elf64-sparc.c: Likewise.
4531 * elflink.c: Likewise.
4532 * elflink.h: Likewise.
4533 * elf-m10200.c: Likewise.
4534 * elf-m10300.c: Likewise.
4535 * elfxx-ia64.c: Likewise.
4536
4537 * aoutx.h: Fix formatting.
4538 * bfd.c: Likewise.
4539 * bfd-in2.h: Likewise.
4540 * bfd-in.h: Likewise.
4541 * cpu-i386.c: Likewise.
4542 * cpu-m68hc11.c: Likewise.
4543 * dwarf2.c: Likewise.
4544 * elf64-x86-64.c: Likewise.
4545 * format.c: Likewise.
4546 * freebsd.h: Likewise.
4547 * hash.c: Likewise.
4548 * hp300hpux.c: Likewise.
4549 * hppabsd-core.c: Likewise.
4550 * hpux-core.c: Likewise.
4551
45522001-01-22 Bo Thorsen <bo@suse.de>
4553
4554 * elf64-x86-64.c: Added PIC support for X86-64.
4555 (elf64_x86_64_link_hash_newfunc): Function added.
4556 (elf64_x86_64_link_hash_table_create): Likewise.
4557 (elf64_x86_64_check_relocs): Likewise.
4558 (elf64_x86_64_gc_mark_hook): Likewise.
4559 (elf64_x86_64_gc_sweep_hook): Likewise.
4560 (elf64_x86_64_adjust_dynamic_symbol): Likewise.
4561 (elf64_x86_64_size_dynamic_sections): Likewise.
4562 (elf64_x86_64_discard_copies): Likewise.
4563 (elf64_x86_64_finish_dynamic_symbol): Likewise.
4564 (elf64_x86_64_finish_dynamic_sections): Likewise.
4565 (elf64_x86_64_relocate_section): Add relocation of PIC sections.
4566
45672001-01-21 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
4568
4569 * Makefile.am (install-data-local): Make use of $(DESTDIR).
4570 * Makefile.in: Regenerate.
4571
45722001-01-21 Kazu Hirata <kazu@hxi.com>
4573
4574 * coff-a29k.c: Fix formatting.
4575
45762001-01-19 H.J. Lu <hjl@gnu.org>
4577
4578 * elf32-i386.c (elf_i386_check_relocs): Report files with bad
4579 relocation section names.
4580 (elf_i386_relocate_section): Report files with bad relocation
4581 section names and return false.
4582
45832001-01-17 Bo Thorsen <bo@suse.de>
4584
4585 * targets.c: Alphabetize list of xvecs.
4586
45872001-01-14 Alan Modra <alan@linuxcare.com.au>
4588
4589 * config.bfd: Add linux target variant for elfxx-hppa.
4590 * configure.in: Recognize bfd_elf32_hppa_linux_vec and
4591 bfd_elf64_hppa_linux_vec.
4592 * configure: Regenerate.
4593 * elf64-hppa.c: Include elf64-target.h again to support linux
4594 target variant.
4595 (elf64_hppa_post_process_headers): Set ELFOSABI_LINUX for linux.
4596 * elf32-hppa.c: Include elf32-target.h again to support linux
4597 target variant.
4598 (elf32_hppa_post_process_headers): New function.
4599 (elf_backend_post_process_headers): Define.
4600 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_linux_vec and
4601 bfd_elf32_hppa_linux_vec.
4602
4603 * elf32-hppa.c (elf32_hppa_link_hash_table): Add text_segment_base,
4604 and data_segment_base fields.
4605 (elf32_hppa_link_hash_table_create ): Init them.
4606 (elf32_hppa_check_relocs): Update comments.
4607 (hppa_record_segment_addr): New function.
4608 (elf32_hppa_relocate_section): Call it.
4609 (final_link_relocate): Handle R_PARISC_SEGREL32.
4610 (elf32_hppa_final_link): New function.
4611 (bfd_elf32_bfd_final_link): Define to call it.
4612 (hppa_unwind_entry_compare): New function.
4613 * cache.c (bfd_open_file): Create files in write+read mode.
4614
4615 * elf-hppa.h (elf_hppa_howto_table): Set bitsize value for
4616 SEGREL32 and numerous other relocs. Change duplicate
4617 R_PARISC_NONE relocs to R_PARISC_UNIMPLEMENTED.
4618
4619 * opncls.c (bfd_fdopenr): Add parens like the comment says around
4620 O_ACCMODE.
4621
4622 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Don't create
4623 .plt entries for DT_INIT and DT_FINI.
4624 (elf32_hppa_finish_dynamic_sections): Remove special handling of
4625 DT_INIT and DT_FINI.
4626
4627 * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Use 16-bit
4628 offsets for stub .plt access if wide mode. Check offset in range.
4629
46302001-01-13 Nick Clifton <nickc@redhat.com>
4631
4632 * elf32-fr30.c (fr30_elf_howto_table): Remove spurious blank
4633 line.
4634
4635 * coffcode.h (coff_canonicalize_reloc): Remove spurious blank
4636 line.
4637
46382001-01-12 Alan Modra <alan@linuxcare.com.au>
4639
4640 * configure.in ([bfd_elf64_x86_64_vec]): Set target64.
4641 * configure: Regenerate.
4642
46432001-01-11 Peter Targett <peter.targett@arccores.com>
4644
4645 * bfd-in2.h (bfd_architecture): Add bfd_mach_arc_5,
4646 bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8 for ARC variants.
4647 * cpu-arc.c (arch_info_struct): Add entries for variants.
4648 (bfd_arc_arch) Set default to bfd_mach_arc_5.
4649 (arc_get_mach) Don't assume machine names prefixed arc- before
4650 testing.
4651 * elf32-arc.c (arc_elf_object_p): Set machine number based on new
4652 selections.
4653 (arc_elf_final_write_processing) Likewise.
4654 (ELF_MACHINE_CODE) Use EM_ARC.
4655
46562001-01-10 Nick Clifton <nickc@redhat.com>
4657
4658 * coff-arm.c (LOCAL_LABEL_PREFIX): Change definition to "".
4659
46602001-01-07 Philip Blundell <philb@gnu.org>
4661
4662 * README: Replace `bug-gnu-utils@gnu.org' with
4663 `bug-binutils@gnu.org'.
4664
46652001-01-04 Kazu Hirata <kazu@hxi.com>
4666
4667 * som.c: Fix formatting.
4668
46692001-01-03 Kazu Hirata <kazu@hxi.com>
4670
4671 * ecoffswap.h: Fix formatting.
4672 * elf-bfd.h: Likewise.
4673 * elfarm-nabi.c: Likewise.
4674 * elfarm-oabi.c: Likewise.
4675 * elfcode.h: Likewise.
4676 * elfcore.h: Likewise.
4677 * elflink.c: Likewise.
4678 * elflink.h: Likewise.
4679 * elfxx-ia64.c: Likewise.
4680 * elfxx-target.h: Likewise.
4681 * libbfd.c: Likewise
4682 * linker.c: Likewise.
4683 * lynx-core.c: Likewise.
4684
46852001-01-02 Kazu Hirata <kazu@hxi.com>
4686
4687 * pc532-mach.c: Fix formatting.
4688 * pe-arm.c: Likewise.
4689 * pe-i386.c: Likewise.
4690 * pe-mips.c: Likewise.
4691 * pe-ppc.c: Likewise.
4692 * pe-sh.c: Likewise.
4693 * pei-mips.c: Likewise.
4694 * pei-sh.c: Likewise.
4695 * peicode.h: Likewise.
4696 * ppcboot.c: Likewise.
4697 * ptrace-core.c: Likewise.
4698
46992001-01-01 Kazu Hirata <kazu@hxi.com>
4700
4701 * reloc.c: Fix formatting.
4702 * riscix.c: Likewise.
4703 * rs6000-core.c: Likewise.
4704 * xcoff-target.h: Likewise.
4705
47062000-12-29 Hans-Peter Nilsson <hp@bitrange.com>
4707
4708 * elfcode.h (elf_object_p): Also restore the bfd mach field on
4709 error, by calling bfd_default_set_arch_mach with incoming
4710 values.
4711
47122000-12-26 Kazu Hirata <kazu@hxi.com>
4713
4714 * vaxnetbsd.c: Fix formatting.
4715 * versados.c: Likewise.
4716 * vms-gsd.c: Likewise.
4717 * vms-hdr.c: Likewise.
4718 * vms-misc.c: Likewise.
4719
47202000-12-25 Alexandre Oliva <aoliva@redhat.com>
4721
4722 * archive.c (coff_write_armap): Don't write more than symbol_count
4723 `archive_member_file_ptr's.
4724
47252000-12-25 Kazu Hirata <kazu@hxi.com>
4726
4727 * vms-tir.c: Fix formatting.
4728
47292000-12-23 Kazu Hirata <kazu@hxi.com>
4730
4731 * vms.c: Fix formatting.
4732 * vms.h: Likewise.
4733
47342000-12-21 Santeri Paavolainen <santtu@ssh.com>
4735
4736 * vms-hdr.c: Include alloca.h if HAVE_ALLOCA_H is defined.
4737
4738 * peicode.h (pe_ILF_object_p): Add const to import of TARGET_LITTLE_SYM.
4739
4740 * elf32-m32r.c (m32r_elf_generic_reloc): Add cast to avoid (void *)
4741 arithmetic.
4742
4743 * elf32-fr30.c: Add casts to avoid (void *) arithmetic.
4744
4745 * coffcode.h (styp_to_sec_flags): Add empty statement after label.
4746
47472000-12-21 Richard Sandiford <rsandifo@redhat.com>
4748
4749 * libbfd.c (bfd_get_bits): Added
4750 (bfd_put_bits): Likewise
4751 * bfd-in.h: Declared the above.
4752 * bfd-in2.h: Regenerated.
4753
47542000-12-20 Kazu Hirata <kazu@hxi.com>
4755
4756 * targets.c: Fix formatting.
4757 * tekhex.c: Likewise.
4758 * trad-core.c: Likewise.
4759
47602000-12-19 Kazu Hirata <kazu@hxi.com>
4761
4762 * sco5-core.c: Fix formatting.
4763 * section.c: Likewise.
4764 * sparclinux.c: Likewise.
4765 * sparclynx.c: Likewise.
4766 * sparcnetbsd.c: Likewise.
4767 * srec.c: Likewise.
4768 * stabs.c: Likewise.
4769 * stab-syms.c: Likewise.
4770 * sunos.c: Likewise.
4771 * syms.c: Likewise.
4772 * sysdep.h: Likewise.
4773
47742000-12-18 Nick Clifton <nickc@redhat.com>
4775
4776 * coff-arm.c (EXTRA_S_FLAGS): Only define if not already
4777 defined.
4778 * epoc-pe-arm.c (EXTRA_S_FLAGS): Define.
4779 * epoc-pei-arm.c (EXTRA_S_FLAGS): Define.
4780
47812000-12-18 Nick Clifton <nickc@redhat.com>
4782
4783 * vms-misc.c (_bfd_vms_get_record): Add default case to
4784 file_format switch.
4785
47862000-12-15 Miloslav Trmac <mitr@volny.cz>
4787
4788 * elfcore.h (elf_core_file_p): Move to the start of the program
4789 headers before attempting to read them.
4790
47912000-12-14 Kazu Hirata <kazu@hxi.com>
4792
4793 * peigen.c: Fix formatting.
4794 * som.c: Likewise.
4795 * som.h: Likewise.
4796
47972000-12-13 Kazu Hirata <kazu@hxi.com>
4798
4799 * peigen.c: Fix formatting.
4800
48012000-12-12 Jim Wilson <wilson@redhat.com>
4802
4803 * elfxx-ia64.c (get_dyn_sym_info): Cast %p argument to void *.
4804
48052000-12-08 Mark Salter <msalter@redhat.com>
4806
4807 * binary.c (binary_set_section_contents): Ignore sections
4808 with zero size.
4809
48102000-12-12 Kazu Hirata <kazu@hxi.com>
4811
4812 * m68klinux.c: Fix formatting.
4813 * m68knetbsd.c: Likewise.
4814 * mipsbsd.c: Likewise.
4815 * netbsd-core.c: Likewise.
4816 * netbsd.h: Likewise.
4817 * newsos3.c: Likewise.
4818 * nlm32-alpha.c: Likewise.
4819 * nlm32-i386.c: Likewise.
4820 * nlm32-ppc.c: Likewise.
4821 * nlm32-sparc.c: Likewise.
4822 * nlmcode.h: Likewise.
4823 * nlmswap.h: Likewise.
4824 * nlm-target.h: Likewise.
4825 * ns32knetbsd.c: Likewise.
4826
48272000-12-10 Fred Fish <fnf@be.com>
4828
4829 * elflink.h (elf_link_output_extsym): Don't complain about undefined
4830 symbols in shared objects if allow_shlib_undefined is true.
4831
48322000-12-12 Nick Clifton <nickc@redhat.com>
4833
4834 * cpu-sh.c: Fix formattng.
4835 * elf.c: Fix formattng.
4836 * elf32-mips.c: Fix formattng.
4837 * elf32-sh.c: Fix formattng.
4838 * elf64-alpha.c: Fix formattng.
4839
48402000-12-09 Nick Clifton <nickc@redhat.com>
4841
4842 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Pass
4843 dwarf2_find_line_info as last parameter to invocation of
4844 _bfd_dwarf2_find_nearest_line.
4845 * elf32-arm.h (elf32_arm_find_nearest_line): Pass
4846 dwarf2_find_line_info as last parameter to invocation of
4847 _bfd_dwarf2_find_nearest_line.
4848
48492000-12-08 Mark Elbrecht <snowball3@bigfoot.com>
4850
4851 * Makefile.am (BFD32_BACKENDS): Move dwarf2.lo from here...
4852 (BFD_LIBS): ...to here.
4853 (BFD32_BACKENDS_CFILES): Move dwarf2.c from here...
4854 (BFD_LIBS_CFILES): ...to here.
4855 * Makefile.in: Regenerate.
4856 * configure.in: Remove dwarf.lo from the elf shell variable.
4857 * configure: Regenerate.
4858 * libcoff-in.h (coff_tdata): Add pointer dwarf2_find_line_info.
4859 * libcoff.h: Regenerate.
4860 * coffgen.c (coff_find_nearest_line): Call
4861 _bfd_dwarf2_find_nearest_line.
4862 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Add parameter. Update
4863 accordingly.
4864 (read_abbrevs): Likewise
4865 (decode_line_info): Likewise.
4866 (parse_comp_unit): Likewise.
4867 (comp_unit_find_nearest_line): Likewise.
4868 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Update prototype.
4869 * libbfd.h: Regenerate.
4870 * elf.c (_bfd_elf_find_nearest_line): Update call.
4871 * elf-bfd.h (elf_obj_tdata): Change dwarf2_find_line_info to type PTR.
4872 * dwarf2.c (concat_filename): Use IS_ABSOLUTE_PATH.
4873 * coffcode.h (STYP_XCOFF_DEBUG, STYP_DEBUG_INFO): New macros.
4874 (sec_to_styp_flags): Use them. Handle DWARF2 sections.
4875 (styp_to_sec_flags): Handle DWARF2 sections.
4876 * elf32-arm.h (elf32_arm_find_nearest_line): Add parameter to call
4877 to _bfd_find_nearest_line.
4878 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Add parameter to
4879 call to _bfd_find_nearest_line.
4880
48812000-12-08 Kazu Hirata <kazu@hxi.com>
4882
4883 * coffgen.c: Fix formatting.
4884 * elf-m10300.c: Likewise.
4885 * elf32-i386.c: Likewise.
4886 * elf32-i960.c: Likewise.
4887 * elf32-m68k.c: Likewise.
4888 * elf32-mcore.c: Likewise.
4889 * elf32-ppc.c: Likewise.
4890 * elf32-sh.c: Likewise.
4891 * elf32-sparc.c: Likewise.
4892 * elf32-v850.c: Likewise.
4893 * elf64-alpha.c: Likewise.
4894 * elf64-hppa.c: Likewise.
4895 * elf64-mips.c: Likewise.
4896 * elf64-sparc.c: Likewise.
4897
48982000-12-07 Kazu Hirata <kazu@hxi.com>
4899
4900 * elf32-ppc.c: Fix formatting.
4901 * elf64-x86-64.c: Likewise.
4902
49032000-12-06 Ulf Carlsson <ulfc@engr.sgi.com>
4904
4905 From Ralf Baechle <ralf@gnu.org>
4906
4907 * elf32-mips.c (elf32_mips_merge_private_bfd_data): Always permit
4908 BFDs containing no sections or empty .text, .data or .bss sections
4909 to be merged, regardless of their flags.
4910
49112000-12-06 Kazu Hirata <kazu@hxi.com>
4912
4913 * elf32-m32r.c: Fix formatting.
4914 * elf32-m68hc11.c: Likewise.
4915 * elf32-m68hc12.c: Likewise.
4916 * elf32-m68k.c: Likewise.
4917 * elf32-mcore.c: Likewise.
4918 * elf32-pj.c: Likewise.
4919 * elf32-ppc.c: Likewise.
4920
49212000-12-05 Kazu Hirata <kazu@hxi.com>
4922
4923 * elf32-fr30.c: Fix formatting.
4924 * elf32-hppa.c: Likewise.
4925 * elf32-i370.c: Likewise.
4926 * elf32-i386.c: Likewise.
4927 * elf32-i860.c: Likewise.
4928 * elf32-i960.c: Likewise.
4929
49302000-12-03 Kazu Hirata <kazu@hxi.com>
4931
4932 * elf32-arm.h: Fix formatting.
4933 * elf32-avr.c: Likewise.
4934 * elf32-cris.c: Likewise.
4935 * elf32-d10v.c: Likewise.
4936 * elf32-d30v.c: Likewise.
4937 * elf-hppa.h: Likewise.
4938 * elf-m10200.c: Likewise.
4939 * elf-m10300.c: Likewise.
4940
49412000-12-01 Chris Demetriou <cgd@sibyte.com>
4942
4943 * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mips32 and
4944 bfd_mach_mips32_4k. Update FIXME comment.
4945 * archures.c (bfd_mach_mips32): New constant.
4946 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4947 the latter, renumber it.
4948 * bfd-in2.h (bfd_mach_mips32): New constant.
4949 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4950 the latter, renumber it.
4951 * cpu-mips.c (I_mips32): New constant.
4952 (I_mips4K, I_mips32_4k): Rename the former to the latter.
4953 (arch_info_struct): Add bfd_mach_mips32 entry, replace
4954 bfd_mach_mips4K entry with bfd_mach_mips32_4k entry.
4955 * elf32-mips.c (elf_mips_isa): Add E_MIPS_ARCH_32 case.
4956 (elf_mips_mach): Likewise. Also, replace E_MIPS_MACH_MIPS32
4957 with E_MIPS_MACH_MIPS32_4K.
4958 (_bfd_mips_elf_final_write_processing): Replace
4959 bfd_mach_mips4K with bfd_mach_mips32_4k case, add
4960 bfd_mach_mips32 case.
4961 (_bfd_mips_elf_merge_private_bfd_data): Generalize ISA mixing
4962 comparison with support for MIPS32.
4963 (_bfd_mips_elf_print_private_bfd_data): Print ISA name for
4964 MIPS32.
4965
4966 * aoutx.h (NAME(aout,machine_type)): Add cases for
4967 bfd_mach_mips5 and bfd_mach_mips64.
4968 * archures.c (bfd_mach_mips5, bfd_mach_mips64): New constants.
4969 * bfd-in2.h (bfd_mach_mips5, bfd_mach_mips64): Likewise.
4970 * cpu_mips.c (I_mips5, I_mips64): New definitions.
4971 (arch_info_struct): Add entries for bfd_mach_mips5 and
4972 bfd_mach_mips64.
4973 * elf32-mips.c (elf_mips_isa, elf_mips_mach,
4974 _bfd_mips_elf_print_private_bfd_data): Add cases for
4975 E_MIPS_ARCH_5 and E_MIPS_ARCH_64.
4976 (_bfd_mips_elf_final_write_processing): Add cases for
4977 bfd_mach_mips5 and bfd_mach_mips64.
4978
4979 * aoutx.h (NAME(aout,machine_type)): Add a
4980 bfd_mach_mips_sb1 case.
4981 * archures.c (bfd_mach_mips_sb1): New constant.
4982 * bfd-in2.h (bfd_mach_mips_sb1): New constant.
4983 * cpu-mips.c (I_sb1): New constant.
4984 (arch_info_struct): Add entry for bfd_mach_mips_sb1.
4985 * elf32-mips.c (elf_mips_mach): Add case for
4986 E_MIPS_MACH_SB1.
4987 (_bfd_mips_elf_final_write_processing): Add case for
4988 bfd_mach_mips_sb1.
4989
49902000-12-01 Joel Sherrill <joel@OARcorp.com>
4991
4992 * config.bfd (arm-*-rtems*, a29k-*rtems*): New targets.
4993 (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
4994 (sparc*-*-rtems*): Switched from a.out to ELF.
4995
49962000-11-30 Jan Hubicka <jh@suse.cz>
4997
4998 * Makefile.am (BFD64_BACKENDS): Add elf64-x86-64.lo
4999 BFD64_BACKENDS_CFILES): Add elf64-x86-64.c
5000 (elf64-x86-64.lo): Add dependencies.
5001 * archures.c (DESCRIPTION): Add bfd_mach_x86_64,
5002 bfd_mach_x86_64_intel_syntax.
5003 * elf.c (prep_headers): Use EM_x86_64 for 64bit output.
5004 * config.bfd (x86_64): Add.
5005 * configure.in: Add support for bfd_elf64_x86_64_vec.
5006 * cpu-i386.c (bfd_x86_64_arch_intel_syntax, bfd_x86_64_arch): Add.
5007 (bfd_i386_arch, i8086_ar): Link in.
5008 * elf64-x86-64.c: New file.
5009 * reloc.c (ENUMDOC): Add BFD_RELOC_X86_64*.
5010 * targets.c (bfd_elf64_x86_64_vec): Add.
5011 (bfd_target_vect): Add bfd_elf64_x86_64_vec.
5012
50132000-11-30 Kazu Hirata <kazu@hxi.com>
5014
5015 * xcofflink.c: Fix formatting.
5016
50172000-11-28 Kazu Hirata <kazu@hxi.com>
5018
5019 * aoutx.h: Fix formatting.
5020 * bfd-in.h: Likewise.
5021 * bfd-in2.h: Likewise.
5022 * cache.c: Likewise.
5023 * cisco-core.c: Likewise.
5024 * coff64-rs6000.c: Likewise.
5025 * coffcode.h: Likewise.
5026 * coffswap.h: Likewise.
5027 * corefile.c: Likewise.
5028 * elf32-mips.c: Likewise.
5029
50302000-11-27 Kazu Hirata <kazu@hxi.com>
5031
5032 * aout-adobe.c: Fix formatting.
5033 * coff64-rs6000.c: Likewise.
5034 * coffgen.c: Likewise.
5035 * cofflink.c: Likewise.
5036
50372000-11-27 Philip Blundell <pb@futuretv.com>
5038
5039 * libcoff-in.h (coff_tdata): Add `strings_written' flag.
5040 (obj_coff_strings_written): New accessor macro for above.
5041 * libcoff.h: Regenerate.
5042 * cofflink.c (_bfd_coff_final_link): Say that we wrote the
5043 strings.
5044 * coffcode.h (coff_write_object_contents): No need to write out
5045 the string table if it's already been done.
5046
50472000-11-22 Philip Blundell <pb@futuretv.com>
5048
5049 * cofflink.c (_bfd_coff_generic_relocate_section): Don't object to
5050 weak undefined symbols.
5051
50522000-11-24 Nick Clifton <nickc@redhat.com>
5053
5054 * archures.c (bfd_mach_arm_5TE): Define.
5055 (bfd_mach_arm+XScale): Define.
5056 * bfd-in2.h: Regenerate.
5057
5058 * coff-arm.c (coff_arm_reloc_type_lookup): Accept
5059 BFD_RELOC_ARM_PCREL_BLX.
5060
5061 * coffcode.h (coff_set_flags): Set flags for 5t, 5te and
5062 XScale machine numbers.
5063
5064 * config.bfd (xscale-elf): Add target.
5065 (xscale-coff): Add target.
5066
5067 * cpu-arm.c: Add xscale machine name.
5068 Add v5t, v5te and XScale machine numbers.
5069
50702000-11-23 Kazu Hirata <kazu@hxi.com>
5071
5072 * aix386-core.c: Fix formatting.
5073
50742000-11-22 Jim Wilson <wilson@redhat.com>
5075
5076 * coff-ia64.c (howto_table): Use EMPTY_HOWTO.
5077 (in_reloc_p): Add ATTRIBUTE_UNUSED to unused parameters.
5078 * cpu-ia64-opc.c (ins_rsvd, ext_rsvd, ins_const, ext_const): Likewise.
5079 (ins_imms_scaled): Initialize sign_bit at function entry.
5080 (elf64_ia64_operands): Add missing initializers.
5081 * elfxx-ia64.c (elfNN_ia64_reloc, elfNN_ia64_reloc_type_lookup,
5082 elfNN_ia64_info_to_howto, elfNN_ia64_fake_sections,
5083 elfNN_ia64_add_symbol_hook, elfNN_ia64_is_local_label_name,
5084 elfNN_ia64_local_hash_table_init, get_fptr, get_pltoff,
5085 elfNN_ia64_adjust_dynamic_symbol): Add ATTRIBUTE_UNUSED for unused
5086 parameters.
5087 (elfNN_ia64_info_to_howto): Initialize free_relocs, free_contents,
5088 and free_extsyms at function entry.
5089 (elfNN_add_symbol_hook): Add unsigned cast to bfd_get_gp_size result.
5090 (elfNN_ia64_create_dynamic_sections): Delete unused local h.
5091 (get_got): Delete unused local srel.
5092 (elfNN_ia64_check_relocs): Initialize dynrel_type when declared.
5093 (elfNN_ia64_relocate_section): Delete unused local dynindx.
5094
50952000-11-21 Kazu Hirata <kazu@hxi.com>
5096
5097 * coff-a29k.c: Fix formatting.
5098 * coff-h8500.c: Likewise.
5099 * coff-i960.c: Likewise.
5100 * coff-ppc.c: Likewise.
5101 * coff-rs6000.c: Likewise.
5102 * coff-stgo32.c: Likewise.
5103 * coff-tic54x.c: Likewise.
5104 * coff-w65.c: Likewise.
5105 * cpu-h8500.c: Likewise.
5106 * cpu-hppa.c: Likewise.
5107 * cpu-ns32k.c: Likewise.
5108 * ecoff.c: Likewise.
5109 * ecofflink.c: Likewise.
5110
51112000-11-21 Nick Clifton <nickc@redhat.com>
5112
5113 * elf32-sh.c (sh_elf_reloc_loop): Fix compile time warning, and
5114 remove possibility of infinite loop.
5115
51162000-11-20 Kazu Hirata <kazu@hxi.com>
5117
5118 * aix386-core.c: Fix formatting.
5119 * aout-adobe.c: Likewise.
5120 * aout-arm.c: Likewise.
5121 * aout-encap.c: Likewise.
5122 * aout-ns32k.c: Likewise.
5123 * aout-target.h: Likewise.
5124 * aout-tic30.c: Likewise.
5125 * aoutf1.h: Likewise.
5126 * aoutx.h: Likewise.
5127 * archive.c: Likewise.
5128 * bfd-in.h: Likewise.
5129 * bfd-in2.h: Likewise.
5130 * bfd.c: Likewise.
5131 * bout.c: Likewise.
5132
51332000-11-17 H.J. Lu <hjl@gnu.org>
5134
5135 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Don't create
5136 pltoff entries for DT_INIT and DT_FINI.
5137 (elfNN_ia64_final_link): Don't set DT_INIT/FINI entries.
5138 (elfNN_ia64_finish_dynamic_sections): Don't fill in DT_INIT/FINI
5139 entries.
5140
51412000-11-16 Richard Henderson <rth@redhat.com>
5142
5143 * elfxx-ia64.c (elfNN_ia64_check_relocs): Handle IPLT relocs.
5144 (allocate_dynrel_entries): Likewise.
5145 (elfNN_ia64_relocate_section): Likewise. Set REL addends correctly.
5146 (set_pltoff_entry): Likewise.
5147 (ia64_howto_table): Remove R_IA64_SEGBASE, and R_IA64_EPLT[ML]SB
5148 (elfNN_ia64_reloc_type_lookup): Likewise.
5149 (elfNN_ia64_install_value): Likewise.
5150 (elfNN_ia64_relocate_section): Likewise.
5151 * reloc.c (BFD_RELOC_IA64_SEGBASE): Remove.
5152 (BFD_RELOC_IA64_EPLTMSB, BFD_RELOC_IA64_EPLTLSB): Remove.
5153
51542000-11-16 Kazu Hirata <kazu@hxi.com>
5155
5156 * cpu-a29k.c: Fix formatting.
5157 * cpu-alpha.c: Likewise.
5158 * cpu-arm.c: Likewise.
5159 * cpu-avr.c: Likewise.
5160 * cpu-d10v.c: Likewise.
5161 * cpu-h8500.c: Likewise.
5162 * cpu-hppa.c: Likewise.
5163 * cpu-i370.c: Likewise.
5164 * cpu-i386.c: Likewise.
5165 * cpu-i960.c: Likewise.
5166 * cpu-ia64-opc.c: Likewise.
5167 * cpu-ia64.c: Likewise.
5168 * cpu-m32r.c: Likewise.
5169 * cpu-m68hc11.c: Likewise.
5170 * cpu-m68hc12.c: Likewise.
5171 * cpu-m68k.c: Likewise.
5172 * cpu-m88k.c: Likewise.
5173 * cpu-mips.c: Likewise.
5174 * cpu-ns32k.c: Likewise.
5175 * cpu-pj.c: Likewise.
5176 * cpu-powerpc.c: Likewise.
5177 * cpu-sh.c: Likewise.
5178 * cpu-sparc.c: Likewise.
5179 * cpu-tic54x.c: Likewise.
5180 * cpu-v850.c: Likewise.
5181 * cpu-vax.c: Likewise.
5182 * cpu-w65.c: Likewise.
5183 * cpu-we32k.c: Likewise.
5184 * cpu-z8k.c: Likewise.
5185 * dwarf1.c: Likewise.
5186 * dwarf2.c: Likewise.
5187
51882000-11-15 Kazu Hirata <kazu@hxi.com>
5189
5190 * coff-arm.c: Fix formatting.
5191 * coff-ppc.c: Likewise.
5192 * coff-rs6000.c: Likewise.
5193 * coff-sh.c: Likewise.
5194 * coff-sparc.c: Likewise.
5195 * coff-tic30.c: Likewise.
5196 * coff-tic54x.c: Likewise.
5197 * coff-tic80.c: Likewise.
5198 * coff-w65.c: Likewise.
5199 * coff-we32k.c: Likewise.
5200 * coff-z8k.c: Likewise.
5201
52022000-11-15 Richard Henderson <rth@redhat.com>
5203
5204 * elf64-alpha.c (elf64_alpha_check_relocs): Create the reloc
5205 section with the same ALLOC|LOAD flags as the source section.
5206
52072000-11-14 Jakub Jelinek <jakub@redhat.com>
5208
5209 * elf64-alpha.c (elf64_alpha_relax_opt_call): Only check bits used
5210 by STO_ALPHA constants.
5211
52122000-11-14 Kazu Hirata <kazu@hxi.com>
5213
5214 * coff-pmac.c: Fix formatting.
5215 * coff-ppc.c: Likewise.
5216
52172000-11-13 H.J. Lu <hjl@gnu.org>
5218
5219 * elflink.h (elf_link_add_object_symbols): Also add indirect
5220 symbols for common symbols with the default version.
5221
52222000-11-09 Philip Blundell <pb@futuretv.com>
5223
5224 * section.c (STD_SECTION): Set gc_mark flag.
5225
52262000-11-11 Kazu Hirata <kazu@hxi.com>
5227
5228 * coff-i960.c: Likewise.
5229 * coff-m68k.c: Likewise.
5230 * coff-m88k.c: Likewise.
5231 * coff-mcore.c: Likewise.
5232 * coff-mips.c: Likewise.
5233
52342000-11-11 Bernd Schmidt <bernds@cygnus.co.uk>
5235
5236 * elf32-sh.c (sh_elf_relocate_section): Ignore R_SH_NONE relocs.
5237
52382000-11-10 Kazu Hirata <kazu@hxi.com>
5239
5240 * coff-h8300.c: Fix formatting.
5241 * coff-h8500.c: Likewise.
5242 * coff-i386.c: Likewise.
5243 * coff-i860.c: Likewise.
5244 * coff-i960.c: Likewise.
5245 * coff-ia64.c: Likewise.
5246
52472000-11-09 Kazu Hirata <kazu@hxi.com>
5248
5249 * archive.c: Fix formatting.
5250 * archures.c: Likewise.
5251
52522000-11-07 Richard Henderson <rth@redhat.com>
5253
5254 * elfxx-ia64.c (elf64_ia64_final_link): New local unwind_output_sec.
5255 Set it before bfd_elf64_bfd_final_link call. Use it after the call.
5256 * section.c (bfd_set_section_contents): Call memcpy if
5257 section->contents set and location not equal to contents plus offset.
5258
52592000-11-08 Kazu Hirata <kazu@hxi.com>
5260
5261 * bfd-in.h: Fix formatting.
5262 * bfd-in2.h: Likewise.
5263 * bfd.c: Likewise.
5264 * binary.c: Likewise.
5265 * bout.c: Likewise.
5266 * coff-a29k.c: Likewise.
5267 * coff-alpha.c: Likewise.
5268 * coff-apollo.c: Likewise.
5269 * coff-aux.c: Likewise.
5270
52712000-11-07 Kazu Hirata <kazu@hxi.com>
5272
5273 * aix386-core.c: Fix formatting.
5274 * aoutf1.h: Likewise.
5275 * aoutx.h: Likewise.
5276 * archures.c: Likewise.
5277 * armnetbsd.c: Likewise.
5278
52792000-11-07 Alan Modra <alan@linuxcare.com.au>
5280
5281 * coff-h8300.c (special): Adjust reloc address.
5282
52832000-11-06 Steve Ellcey <sje@cup.hp.com>
5284
5285 * archures.c (bfd_mach_ia64_elf64, bfd_mach_ia64_elf32): Add defines
5286 to differentiate elf32 and elf64 on ia64.
5287 * bfd-in2.h: Regenerate.
5288 * config.bfd: Add target for "ia64*-*-hpux*".
5289 * configure.in: Add bfd_elf32_ia64_big_vec to selvecs switch.
5290 * configure: Regenerate.
5291 * cpu-ia64.c (bfd_ia64_elf32_arch): Add elf32 arch info structure.
5292 * targets.c: Add bfd_target bfd_elf32_ia64_big_vec.
5293
5294 * Makefile.am: Make elf32-ia64.c and elf64-ia64.c derived objects
5295 from elfxx-ia64.c. Add depenency rules for making elf32-ia64.lo.
5296 * Makefile.in: Regnerate.
5297 * elf64-ia64.c: Deleted.
5298 * elfxx-ia64.c: New file, paramaterized version of elf64-ia64.c.
5299
53002000-11-06 Kazu Hirata <kazu@hxi.com>
5301
5302 * aout-adobe.c: Fix formatting.
5303 * aout-arm.c: Likewise.
5304 * aout-cris.c: Likewise.
5305 * aout-encap.c: Likewise.
5306 * aout-ns32k.c: Likewise.
5307 * aout-target.h: Likewise.
5308 * aout-tic30.c: Likewise.
5309
53102000-11-05 Philip Blundell <philb@gnu.org>
5311
5312 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit
5313 BFDs containing no sections to be merged, regardless of their flags.
5314
53152000-11-04 Philip Blundell <philb@gnu.org>
5316
5317 * elf32-arm.h (elf32_arm_relocate_section): Suppress error message
5318 if a relocation for an undefined symbol also results in an
5319 overflow.
5320
53212000-11-06 Christopher Faylor <cgf@cygnus.com>
5322
5323 * config.bfd: Add support for Sun Chorus.
5324
53252000-11-05 David O'Brien <obrien@FreeBSD.org>
5326
5327 * configure.in: Recognize alpha-*-freebsd*.
5328 * configure: Regenerate.
5329
53302000-11-02 Luciano Gemme <ishitawa@yahoo.com>
5331
5332 * srec.c (CHUNK): Rename to DEFAULT_CHUNK.
5333 (Chunk): New global variable set by a parameter in objcopy.c.
5334 (S3Forced): New global variable set by a parameter in
5335 objcopy.c.
5336 (srec_set_section_contents): If S3Forced is true, always generate
5337 S3 records.
5338 (srec_write_section): Use 'Chunk' to limit maximum length of S
5339 records.
5340
53412000-11-02 Per Lundberg <plundis@chaosdev.org>
5342
5343 * config.bfd: Add support for i[3456]86-chaosdev-storm-chaos.
5344 * Makefile.in: Regenerate.
5345 * bfd-in2.h: Regenerate.
5346 * po/bfd.pot: Regenerate.
5347
53482000-10-31 Philip Blundell <philb@gnu.org>
5349
5350 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Only handle
5351 EF_SOFT_FLOAT if it is defined.
5352
53532000-10-27 Philip Blundell <philb@gnu.org>
5354
5355 * elf32-arm.h (elf32_arm_copy_private_bfd_data): Don't refuse
5356 attempts to mix PIC code with non-PIC, just mark the output as
5357 being position dependent.
5358 (elf32_arm_merge_private_bfd_data): Likewise. Print an error
5359 message for EF_SOFT_FLOAT mismatches. Display diagnostics for
5360 all mismatches, not just the first one.
5361
53622000-10-25 Chris Demetriou <cgd@sibyte.com>
5363
5364 * ieee.c (ieee_archive_p): Plug one of many possible
5365 memory leaks in error handling.
5366
53672000-10-20 Jakub Jelinek <jakub@redhat.com>
5368
5369 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data,
5370 elf32_sparc_object_p, elf32_sparc_final_write_processing):
5371 Support v8plusb.
5372 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data,
5373 sparc64_elf_object_p): Support v9b.
5374 * archures.c: Declare v8plusb and v9b machines.
5375 * bfd-in2.h: Ditto.
5376 * cpu-sparc.c: Ditto.
5377
53782000-10-16 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5379
5380 * elf64-sparc.c (sparc64_elf_relocate_section): Clear the location
5381 of a GOT reloc.
5382
5383 * elf32-ppc.c (SYMBOL_REFERENCES_LOCAL): New macro.
5384 (SYMBOL_CALLS_LOCAL): New macro.
5385 (ppc_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
5386 (ppc_elf_check_relocs): Use SYMBOL_REFERENCES_LOCAL.
5387 (ppc_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
5388 (ppc_elf_relocate_section): Use flag variable to determine
5389 whether the relocation refers to a local symbol.
5390 Test whether a PLTREL24 reloc will produce a reloc by looking
5391 to see whether a PLT entry was made.
5392
53932000-10-14 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5394
5395 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make PLT
5396 entries that could serve as a definition for a weak symbol.
5397
53982000-10-13 Ulf Carlsson <ulfc@engr.sgi.com>
5399
5400 From Ralf Baechle <ralf@gnu.org>
5401
5402 * elf32-mips.c (mips_elf_create_dynamic_relocation): New argument
5403 local_p. Add symbol value only for non-R_MIPS_REL32 relocations
5404 against local symbols.
5405 (_bfd_mips_elf_finish_dynamic_sections): Undo patch from 2000-10-01.
5406
54072000-10-12 Alan Modra <alan@linuxcare.com.au>
5408
5409 * section.c (struct sec): Add kept_section.
5410 (struct bfd_comdat_info): Remove sec, we can use above.
5411 (STD_SECTION): Add initializer.
5412 (bfd_make_section_anyway): Init here too.
5413
5414 * bfd-in2.h: Regenerate.
5415
5416 * elflink.h (elf_link_add_object_symbols): Remove unnecessary
5417 zeroing of `flags'.
5418 (elf_link_input_bfd): Set all asection->symbol->value's here, and
5419 fudge values for discarded link-once section symbols.
5420
5421 * elf64-hppa.c: Include alloca-conf.h
5422
54232000-10-11 Alan Modra <alan@linuxcare.com.au>
5424
5425 * elf.c (swap_out_syms): Revert 2000-10-07 changes.
5426
5427 * ieee.c (ieee_make_empty_symbol): Oops, bfd_zalloc needs another arg.
5428
54292000-10-10 Alan Modra <alan@linuxcare.com.au>
5430
5431 * ieee.c (ieee_make_empty_symbol): Use bfd_zalloc, not bfd_zmalloc.
5432
54332000-10-10 Tom Rix <trix@redhat.com>
5434
5435 * section.c (bfd_make_section_anyway): Release newsect ptr when
5436 newsect->symbol fails to alloc. Use bfd_release instead of free.
5437
54382000-10-09 Richard Henderson <rth@cygnus.com
5439
5440 * elf64-ia64.c (elf64_ia64_unwind_entry_compare_bfd): New.
5441 (elf64_ia64_unwind_entry_compare): New.
5442 (elf64_ia64_final_link): Sort the .IA_64.unwind section.
5443
54442000-10-07 Alan Modra <alan@linuxcare.com.au>
5445
5446 * elflink.h (size_dynamic_sections): Don't create various tags if
5447 .dynstr is excluded from the link. Don't set first dynsym entry
5448 if dynsymcount is zero.
5449 (elf_bfd_final_link): Don't try to swap out dynamic syms if
5450 .dynsym excluded from the link. Don't try to write any dynamic
5451 sections excluded from the link.
5452
5453 * elf.c (swap_out_syms): Handle global section symbols.
5454
54552000-10-05 DJ Delorie <dj@redhat.com>
5456
5457 * peigen.c (_bfd_pei_swap_scnhdr_out): note extended relocs
5458 * coffcode.h (coff_set_alignment_hook): read extended reloc count
5459 (coff_write_relocs): write extended reloc count
5460 (coff_write_object_contents): account for extended relocs
5461
54622000-10-05 Jim Wilson <wilson@cygnus.com>
5463
5464 * elf-bfd.h (struct elf_backend_data): Add elf_backend_section_flags
5465 field.
5466 * elf.c (_bfd_elf_make_section_from_shdr): Call the
5467 elf_backend_section_flags function.
5468 * elf64-ia64.c (elf64_ia64_section_from_shdr): Delete flag conversion
5469 code.
5470 (elf64_ia64_section_flags): New function containing flag conversion
5471 code.
5472 (elf_backend_section_flags): Define to elf64_ia64_section_flags.
5473 * elfxx-target.h (elf_backend_section_flags): Define.
5474 (elfNN_bed): Initialize elf_backend_section_flags field.
5475
54762000-10-02 Alan Modra <alan@linuxcare.com.au>
5477
5478 * elf32-hppa.c (elf32_hppa_check_relocs): Correct call to
5479 _bfd_elf32_gc_record_vtable. Correct a comment.
5480
54812000-10-01 Ulf Carlsson <ulfc@engr.sgi.com>
5482
5483 From Ralf Baechle <ralf@gnu.org>
5484
5485 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Mark gld
5486 produces binaries with got[1] = 0x80000001 to differenciate them
5487 for the dynamic linker from the broken binaries produced by old
5488 versions.
5489
54902000-09-30 Petr Sorfa <petrs@sco.com>
5491
5492 * elf.c (elfcore_grok_pstatus): Check for size of pxstatus_t.
5493 (elfcore_grok_lwpstatus): Check for size of lwpxstatus_t.
5494 * configure.in: Add check for pxstatus_t and lwpxstatus_t.
5495 * configure: Regenerate.
5496
54972000-09-27 Hans-Peter Nilsson <hp@axis.com>
5498
5499 Define two bfd_targets for absence and presence of leading
5500 underscore on symbols. Make sure to only link same kind.
5501 * elf32-cris.c (cris_elf_object_p,
5502 cris_elf_final_write_processing, cris_elf_print_private_bfd_data,
5503 cris_elf_merge_private_bfd_data): New.
5504 (elf_backend_object_p, elf_backend_final_write_processing,
5505 bfd_elf32_bfd_print_private_bfd_data,
5506 bfd_elf32_bfd_merge_private_bfd_data): Define.
5507 <Target vector definition>: Include elf32-target.h twice with
5508 different macro settings:
5509 (TARGET_LITTLE_SYM): First as bfd_elf32_cris_vec, then as
5510 bfd_elf32_us_cris_vec.
5511 (TARGET_LITTLE_NAME): First as "elf32-cris", then "elf32-us-cris".
5512 (elf_symbol_leading_char): First as 0, then '_'.
5513 (INCLUDED_TARGET_FILE): Define for second include of elf32-target.h.
5514 * config.bfd (cris-*-*): Add bfd_elf32_us_cris_vec to targ_selvecs.
5515 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vector.
5516 * configure: Regenerate.
5517 * targets.c: Declare bfd_elf32_us_cris_vec.
5518 * po/bfd.pot: Regenerate.
5519
55202000-09-29 Momchil Velikov <velco@fadata.bg>
5521
5522 * elf32-arm.h (arm_add_to_rel): Correctly adjust the addend for
5523 R_ARM_THM_PC22 relocations.
5524
55252000-09-29 NIIBE Yutaka <gniibe@chroot.org>
5526
5527 * elflink.h (elf_link_add_object_symbols): Don't bfd_release runpath.
5528
55292000-09-29 Momchil Velikov <velco@fadata.bg>
5530
5531 * elf.c (elf_fake_sections): Do not mark the section SHT_NOBITS if
5532 is has the SEC_HAS_CONTENTS flag set.
5533