e41c153666e8f0eecbb8ffbdc9bb4eb02717490f
[deliverable/binutils-gdb.git] / bfd / ChangeLog
1 2001-10-24 Hans-Peter Nilsson <hp@axis.com>
2
3 * elf32-cris.c (cris_reloc_type_lookup): Change loop to use
4 unsigned, increasing index.
5
6 2001-10-23 H.J. Lu <hjl@gnu.org>
7
8 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Check
9 m != NULL before accessing it.
10
11 2001-10-23 Alan Modra <amodra@bigpond.net.au>
12
13 * elflink.h (elf_link_input_bfd): Zero the reloc instead of doing
14 bfd_reloc_type_lookup (bfd, BFD_RELOC_NONE) as bfd_reloc_type_lookup
15 doesn't accept BFD_RELOC_* on some targets, eg. hppa.
16
17 * elf32-hppa.c (elf32_hppa_link_hash_entry): Remove plt_abs.
18 (hppa_link_hash_newfunc): Likewise.
19 (elf32_hppa_finish_dynamic_symbol): Likewise.
20 (allocate_dynrelocs): Always allocate .got relocs if shared.
21 (elf32_hppa_relocate_section): Output them too. Similarly
22 consolidate .plt reloc code, and no longer initialise .plt
23 when a reloc is output.
24 (elf32_hppa_finish_dynamic_symbol): Only initialise .plt entries
25 when no reloc is output.
26
27 From Herbert Xu <herbert@gondor.apana.org.au>
28 * elf32-hppa.c (final_link_relocate): Call bfd_set_error for
29 unreachable branches.
30
31 2001-10-22 H.J. Lu <hjl@gnu.org>
32
33 * configure.in (WIN32LIBADD): Use -L../libiberty for
34 mips*-*-linux*.
35 * configure: Rebuild.
36
37 2001-10-21 H.J. Lu <hjl@gnu.org>
38
39 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
40 if shared library is enabled only for Linux hosts.
41 * configure: Rebuild.
42
43 2001-10-21 H.J. Lu <hjl@gnu.org>
44
45 * configure.in (WIN32LIBADD): Check if PICFLAG is defined in
46 ../libiberty/Makefile instead of $enable_shared.
47 * configure: Rebuild.
48
49 2001-10-21 H.J. Lu <hjl@gnu.org>
50
51 * elf32-cris.c (cris_reloc_type_lookup): Use int for index. Cover
52 index 0.
53
54 2001-10-20 H.J. Lu <hjl@gnu.org>
55
56 * configure.in (WIN32LIBADD): Include -L../libiberty/pic -liberty
57 if shared library is enabled.
58 * configure: Rebuild.
59
60 2001-10-20 H.J. Lu <hjl@gnu.org>
61
62 * elf32-cris.c (cris_reloc_type_lookup): Allow index 0.
63
64 2001-10-19 H.J. Lu <hjl@gnu.org>
65
66 * elfcode.h (elf_object_p): Don't clear D_PAGED if the section
67 size is empty.
68
69 2001-10-18 H.J. Lu <hjl@gnu.org>
70
71 * elf32-i370.c (i370_elf_relocate_section): Ignore R_XXX_NONE.
72 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
73
74 2001-10-18 Jakub Jelinek <jakub@redhat.com>
75
76 * section.c (_bfd_strip_section_from_output): Don't count
77 SEC_EXCLUDE sections as references. Set SEC_EXCLUDE.
78
79 2001-10-17 Alan Modra <amodra@bigpond.net.au>
80
81 * elf-m10200.c (mn10200_elf_relax_section): Cast assignment to
82 Elf_Internal_Shdr.contents now that it's no longer a PTR.
83 * elf-m10300.c (mn10300_elf_relax_section): Likewise.
84 * elf32-h8300.c (elf32_h8_relax_section): Likewise.
85 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
86 * elf32-sh.c (sh_elf_relax_section): Likewise.
87 * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
88 * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
89 * elf.c (setup_group): Warning fixes.
90 * elflink.h (elf_link_sort_relocs): Likewise.
91 * pdp11.c (slurp_reloc_table): Likewise.
92
93 2001-10-16 Jeff Holcomb <jeffh@redhat.com>
94
95 * elflink.h (elf_link_sort_relocs): Remove unnecessary pointer
96 casts.
97
98 2001-10-15 H.J. Lu <hjl@gnu.org>
99
100 * elflink.h (elf_link_input_bfd): Set type to BFD_RELOC_NONE
101 for relocations against discarded link-once section.
102
103 2001-10-15 Alan Modra <amodra@bigpond.net.au>
104
105 * elf32-i386.c (elf_i386_relocate_section): Report some detail on
106 bfd_reloc_outofrange and similar errors.
107
108 * elf.c (_bfd_elf_link_hash_copy_indirect): Test ind->root.type
109 rather than ind->weakdef.
110 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
111 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
112 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
113 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
114 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
115
116 2001-10-15 Alan Modra <amodra@bigpond.net.au>
117 H.J. Lu <hjl@gnu.org>
118
119 * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Merge dyn_reloc
120 counts for aliases instead of aborting.
121 * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
122 * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
123
124 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Set plt.offset
125 to -1 for non-function symbols.
126 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
127 * elf32-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
128 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
129 * elf64-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
130 * elf64-x86-64.c (elf64_x86_64_adjust_dynamic_symbol): Likewise.
131 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Refer to
132 plt.offset instead of plt.refcount when setting to -1.
133
134 2001-10-12 Nick Clifton <nickc@cambridge.redhat.com>
135
136 * elf32-arm.h (elf32_arm_relocate_section): Treat R_ARM_THM_PC22
137 like R_ARM_PC24. Include reloc number in error message about
138 unresolvable relocs.
139
140 2001-10-10 Jakub Jelinek <jakub@redhat.com>
141
142 * elflink.h (elf_link_sort_cmp2): Don't mix PLT and non-PLT
143 relocations against the same symbol in .rel{,a}.dyn section.
144
145 2001-10-10 Kazu Hirata <kazu@hxi.com>
146
147 * aout-encap.c: Fix comment typos.
148 * aoutx.h: Likewise.
149 * archive.c: Likewise.
150 * bout.c: Likewise.
151 * coff64-rs6000.c: Likewise.
152 * coffcode.h: Likewise.
153 * coffgen.c: Likewise.
154 * cofflink.c: Likewise.
155 * coff-mips.c: Likewise.
156 * ecoff.c: Likewise.
157 * elf32-m32r.c: Likewise.
158 * libcoff-in.h: Likewise.
159 * libecoff.h: Likewise.
160 * libxcoff.h: Likewise.
161 * nlm32-i386.c: Likewise.
162 * pdp11.c: Likewise.
163 * section.c: Likewise.
164 * som.c: Likewise.
165 * som.h: Likewise.
166 * bfd-in2.h: Regenerate.
167 * libcoff.h: Likewise.
168
169 2001-10-10 Alan Modra <amodra@bigpond.net.au>
170
171 * elf.c (elf_map_symbols): Don't create new section symbols; Use
172 existing section syms. Update comments.
173 (copy_private_bfd_data): Formatting fixes.
174 (elfcore_grok_win32pstatus): Likewise.
175 (swap_out_syms): Likewise. Remove unnecessary level of braces.
176
177 2001-10-09 Alan Modra <amodra@bigpond.net.au>
178
179 * elf-bfd.h (struct bfd_elf_section_data): Rename "group" to
180 "group_name".
181 (elf_group_name): Define.
182 (elf_next_in_group): Define.
183 * elf.c: Make use of elf_group_name and elf_next_in_group throughout.
184 (setup_group): Don't use sec->lineno for SHT_GROUP section to store
185 first member section; Instead use elf_next_in_group.
186 (bfd_section_from_shdr): Likewise.
187 (set_group_contents): Likewise. Use elf_section_syms, not sec->symbol.
188
189 2001-10-09 Alan Modra <amodra@bigpond.net.au>
190
191 * elf-bfd.h (struct bfd_elf_section_data): Add "group" and
192 "next_in_group". Fix gp and gp_size comments.
193 * elf.c (union elf_internal_group): New.
194 (setup_group): New function.
195 (_bfd_elf_make_section_from_shdr): Set BFD flags for SHT_GROUP.
196 Call setup_group for SHF_GROUP sections.
197 (bfd_section_from_shdr): Build a BFD section for SHT_GROUP.
198 (elf_fake_sections): Set header type for SEC_GROUP, and header
199 flags for sections in a group.
200 (set_group_contents): New function.
201 (_bfd_elf_compute_section_file_positions): Call it.
202 (assign_section_numbers): Set sh_link for SHT_GROUP.
203
204 * elflink.h (gc_mark_hook): Handle section groups.
205 * elfxx-target.h: Add SEC_GROUP to applicable_flags.
206 * section.c (SEC_GROUP): Define.
207 (struct sec): Comment fixes.
208 * bfd-in2.h: Regenerate.
209
210 * elf.c (bfd_elf_print_symbol): Formatting fix; migrate expression
211 out of function args.
212 (_bfd_elf_canonicalize_reloc): Similarly.
213 (_bfd_elf_get_symtab): Here too.
214 (_bfd_elf_canonicalize_dynamic_symtab): And here.
215 * elfcode.h (elf_slurp_symbol_table): Don't recalculate size for
216 bfd_bread, and remove unnecessary cast.
217
218 2001-10-08 Aldy Hernandez <aldyh@redhat.com>
219
220 * bfd/config.bfd (targ_cpu): Add arm9e-*-elf.
221
222 2001-10-06 Stephane Carrez <Stephane.Carrez@worldnet.fr>
223
224 * dwarf2.c (comp_unit_find_nearest_line): Check for end of
225 compilation unit.
226
227 2001-10-06 Alan Modra <amodra@bigpond.net.au>
228
229 * bfd.c (bfd_assert): Report bfd version.
230 (_bfd_abort): Likewise.
231
232 * elflink.h (elf_link_input_bfd): Don't zero discarded link-once
233 section sym values. Instead replace any relocs against them with
234 relocs against STN_UNDEF, which has a zero value.
235
236 * elf32-arc.c (elf_arc_howto_table): Set partial_inplace for all
237 relocs.
238
239 2001-10-05 Jeff Law <law@redhat.com>
240
241 * som.h (som_exec_data): New field "version_id".
242 * som.c (som_object_setup): Record the version_id if it
243 exists.
244 (som_prep_headers): Do not initialize version_id here.
245 (som_finish_writing): Initialize version_id here.
246
247 2000-10-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
248
249 * elf32-mips.c (elf_mips_howto_table): Fix some relocation howtos
250 according to the MIPS/SGI ELF64 ABI Draft.
251 (mips_elf_sort_hash_table): Typo.
252
253 2001-10-04 Alan Modra <amodra@bigpond.net.au>
254
255 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Comment typo.
256
257 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): Bail out after
258 copying flags if this is a weakdef.
259
260 2001-10-04 Alan Modra <amodra@bigpond.net.au>
261
262 * elf-bfd.h (struct elf_link_hash_entry): Reorganise for better
263 packing.
264
265 * elf32-mips.c (mips_elf_record_global_got_symbol): Set got.offset
266 to 1 rather than 0 to avoid confusing copy_indirect_symbol.
267 (mips_elf_sort_hash_table_f): Compare got.offset against 1.
268
269 * Makefile.am (BFD_H_DEPS): Add symcat.h. Ensure everything
270 depends on $(BFD_H) $(BFD_H_DEPS) $(LOCAL_H_DEPS), not just those
271 backends we configure. Run "make dep-am".
272 (install-data-local): Install symcat.h.
273 * dep-in.sed: Remove symcat.h from dependencies.
274 * Makefile.in: Regenerate.
275
276 2001-10-03 Vassili Karpov <malc@pulsesoft.com>
277
278 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Handle nocopyreloc.
279
280 2001-10-03 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
281
282 * elf64-mips.c (elf_backend_may_use_rela_p): New define.
283 (elf_backend_default_use_rela_p): New define.
284
285 2001-10-03 Alan Modra <amodra@bigpond.net.au>
286
287 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Fix typos in last
288 change.
289
290 * configure.in (AC_OUTPUT <bfd-in3.h>): Remove version.h.
291 * configure: Regenerate.
292 * Makefile.am (BFD_H_FILES): Add version.h.
293 * Makefile.in: Regenerate.
294 * po/SRC-POTFILES.in: Regenerate.
295
296 * elflink.h (elf_fix_symbol_flags): Copy flags to weakdef using
297 elf_backend_copy_indirect_symbol so that backend has a chance to
298 copy other necessary fields.
299 * elf-bfd.h (struct elf_backend_data): Update description of
300 elf_backend_copy_indirect_symbol.
301 * elf.c (_bfd_elf_link_hash_copy_indirect): Bail out after
302 copying flags if this is a weakdef.
303 * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
304 (elfNN_ia64_aix_add_symbol_hook): Use elf_link_hash_lookup rather
305 than bfd_link_hash_lookup.
306 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Don't do copy
307 reloc processing for weakdefs.
308 * elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise.
309 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
310
311 2001-10-02 Alan Modra <amodra@bigpond.net.au>
312
313 * elf64-ppc.c (ppc64_elf_check_relocs): Use a local var and cast
314 result of ELF64_R_TYPE to enum before using in a switch.
315 (ppc64_elf_gc_mark_hook): Likewise.
316 (ppc64_elf_gc_sweep_hook): Likewise.
317 (ppc64_elf_reloc_type_class): Likewise.
318
319 2001-10-02 Alan Modra <amodra@bigpond.net.au>
320
321 * version.h: New file.
322 * bfd-in.h: (BFD_VERSION): Substitute bfd_version.
323 (BFD_VERSION_DATE): Define.
324 (BFD_VERSION_STRING): Define.
325 * configure.in: AC_SUBST bfd_version, bfd_version_date and
326 bfd_version_string.
327 (AC_OUTPUT <bfd-in3.h>): Depend on version.h.
328 * bfd-in2.h: Regenerate.
329 * configure: Regenerate.
330 * Makefile.am: Run "make dep-am".
331 * Makefile.in: Regenerate.
332
333 * bfd-in.h: Include "symcat.h".
334 (CONCAT4): Redefine as for old CAT4.
335 * aout-arm.c: Use equivalent CONCAT* macro in place of CAT* macros.
336 Add warning regarding whitespace.
337 * aout-cris.c: Likewise.
338 * aout-ns32k.c: Likewise.
339 * aout-sparcle.c: Likewise.
340 * aout-tic30.c: Likewise.
341 * aout0.c: Likewise.
342 * armnetbsd.c: Likewise.
343 * demo64.c: Likewise.
344 * elf-bfd.h: Likewise.
345 * gen-aout.c: Likewise.
346 * host-aout.c: Likewise.
347 * hp300bsd.c: Likewise.
348 * hp300hpux.c: Likewise.
349 * i386aout.c: Likewise.
350 * i386bsd.c: Likewise.
351 * i386dynix.c: Likewise.
352 * i386freebsd.c: Likewise.
353 * i386linux.c: Likewise.
354 * i386lynx.c: Likewise.
355 * i386mach3.c: Likewise.
356 * i386netbsd.c: Likewise.
357 * libaout.h: Likewise.
358 * m68k4knetbsd.c: Likewise.
359 * m68klinux.c: Likewise.
360 * m68klynx.c: Likewise.
361 * m68knetbsd.c: Likewise.
362 * m88kmach3.c: Likewise.
363 * mipsbsd.c: Likewise.
364 * newsos3.c: Likewise.
365 * ns32knetbsd.c: Likewise.
366 * pc532-mach.c: Likewise.
367 * pdp11.c: Likewise.
368 * riscix.c: Likewise.
369 * sparclinux.c: Likewise.
370 * sparclynx.c: Likewise.
371 * sparcnetbsd.c: Likewise.
372 * sunos.c: Likewise.
373 * targets.c: Likewise.
374 * vaxnetbsd.c: Likewise.
375 * vms-hdr.c: Likewise.
376
377 2001-10-01 Alan Modra <amodra@bigpond.net.au>
378
379 * bfd-in.h: Remove comments regarding generated files.
380 * libbfd-in.h: Likewise.
381 * libcoff-in.h: Likewise.
382 * bfd-in2.h: Regenerate.
383 * libbfd.h: Likewise.
384 * libcoff.h: Likewise.
385
386 2001-09-30 kaz Kojima <kkojima@rr.iij4u.or.jp>
387 Hans-Peter Nilsson <hp@bitrange.com>
388
389 * elf32-sh.c (sh_elf_howto_table, R_SH_REL32): Make
390 partial_inplace, matching assembler output. Set src_mask to
391 all ones.
392 (sh_elf_relocate_section): Delete misplaced comment.
393 For relocatable linking against section symbol, call
394 _bfd_relocate_contents for partial_inplace relocs and adjust
395 rel->r_addend for others.
396 <case R_SH_DIR32, R_SH_REL32>: Fetch partial_inplace addend with
397 bfd_get_32, not at rel->r_addend.
398
399 2001-09-30 Alan Modra <amodra@bigpond.net.au>
400
401 * elf.c (_bfd_elf_link_hash_copy_indirect): Set ind refcounts to
402 the old dir refcount, so we indirectly set them to init_refcount.
403 Short-circuit asserts when we've just verified they are true.
404
405 2001-09-29 Alan Modra <amodra@bigpond.net.au>
406
407 * section.c (struct sec): Remove kept_section.
408 (STD_SECTION): Remove kept_section initialisation.
409 (bfd_make_section_anyway): Here too.
410 * ecoff.c (bfd_debug_section): Remove kept_section initialisation.
411 * cofflink.c (_bfd_coff_link_input_bfd): Don't test kept_section.
412 * elflink.h (elf_link_input_bfd): Set discarded link-once section
413 symbols to zero, and remove all code involved with kept_section
414 and tracking section symbol values.
415 * bfd-in2.h: Regenerate.
416 * configure.in: Bump version number.
417 * configure: Regenerate.
418
419 2001-09-29 Alan Modra <amodra@bigpond.net.au>
420
421 * elf64-ppc.c (struct ppc_dyn_relocs): New.
422 (IS_ABSOLUTE_RELOC): Define.
423 (struct ppc_link_hash_entry): New.
424 (struct ppc_link_hash_table): New.
425 (ppc_hash_table): Define.
426 (link_hash_newfunc): New function.
427 (ppc64_elf_link_hash_table_create): New function.
428 (create_got_section): New function.
429 (ppc64_elf_create_dynamic_sections): Call create_got_section. Stash
430 pointers to our dynamic sections in hash table.
431 (ppc64_elf_copy_indirect_symbol): New function.
432 (ppc64_elf_check_relocs): Remove DEBUG code. Use short-cuts to
433 dynamic sections. Localise vars. Modify code for refcounts
434 starting from zero. Don't allocate here, or force symbols dynamic.
435 Don't copy all relocs if shared, select ones we need. Add code
436 to track possible copy relocs for non-shared link.
437 (ppc64_elf_gc_mark_hook): Update comment.
438 (ppc64_elf_gc_sweep_hook): Sweep dynrelocs too.
439 (ppc64_elf_adjust_dynamic_symbol): Remove DEBUG code. Rewrite .plt
440 code for reference counting garbage collection. Don't create .plt
441 entries for functions that don't comply with ABI naming convention,
442 and don't allocate .plt space here. Use short-cuts to dynamic
443 sections. If possible, keep dynamic relocations instead of using
444 copy relocs. Remove confused comments.
445 (ppc_adjust_dynindx): Delete.
446 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
447 (allocate_dynrelocs): New function.
448 (readonly_dynrelocs): New function.
449 (ppc64_elf_size_dynamic_sections): Rewrite. Allocate local .got
450 space here, and call allocate_dynrelocs to allocate space for
451 global .plt, .got and reloc sections. Use short-cuts to dynamic
452 sections. Call readonly_dynrelocs to determine whether we need
453 DT_TEXTREL. Don't generate section symbols here, the generic
454 ELF linker code does it for us.
455 (ppc64_elf_final_link): Call regular ELF backend linker rather than
456 gc variety, since we do our own .got handling.
457 (ppc64_elf_relocate_section): Remove DEBUG code. Make use of
458 dynamic section short-cuts. Localise vars, and delay setting.
459 Handle unknown relocs in main switch statement. Replace ugly
460 complicated tests for unresolvable relocs with a simple direct
461 scheme using "unresolved_reloc" var. Test ELF_ST_VISIBILITY
462 before allowing an undefined sym in a shared lib. Do R_*_DS tests
463 after main switch, when we've set addend. Do non-addend insn
464 tweaks before main swithc. Ignore input_section->vma when
465 calculating reloc offsets as it's always zero. Rewrite dynamic
466 reloc handling. Consolidate R_*_HA handling. Handle more relocs.
467 (ppc64_elf_finish_dynamic_symbol): Remove DEBUG code. Make use
468 of dynamic section short-cuts. Reorganise .plt handling code.
469 Remove confused comments. Take note of ELF_LINK_FORCED_LOCAL.
470 Move expressions out of swap_reloca_out function calls.
471 (ppc64_elf_reloc_type_class): New function.
472 (ppc64_elf_info_to_howto): Move common expression to local var.
473 (ppc64_elf_finish_dynamic_sections): Remove DEBUG code. Make use
474 of dynamic section short-cuts. Don't fiddle with section syms
475 here as the ELF linker does it for us.
476 (elf_backend_can_refcount): Define.
477 (bfd_elf64_bfd_link_hash_table_create): Define.
478 (elf_backend_copy_indirect_symbol): Define.
479 (elf_backend_reloc_type_class): Define.
480 (elf_backend_*, bfd_elf64_bfd_* defines): Sort.
481
482 2001-09-29 Alan Modra <amodra@bigpond.net.au>
483
484 * elf-bfd.h (struct elf_link_local_dynamic_entry): Add init_refcount.
485 (struct elf_backend_data): Add can_refcount.
486 * elf.c (_bfd_elf_link_hash_newfunc): Get rid of a few casts. Set
487 got.refcount and plt.refcount from init_refcount.
488 (_bfd_elf_link_hash_table_init): Set up init_refcount.
489 (_bfd_elf_link_hash_copy_indirect): Reference got/plt.refcount
490 rather than got/plt.offset, and test for <= 0 rather than -1.
491 * elflink.h (size_dynamic_sections): Set init_refcount to -1.
492 * elfxx-target.h (elf_backend_can_refcount): Define.
493 (elfNN_bed): Init can_refcount.
494 * linker.c (_bfd_link_hash_newfunc): Get rid of a few casts.
495 (_bfd_generic_link_hash_newfunc): Likewise.
496 * elf32-cris.c (cris_elf_check_relocs): Modify for refcounts
497 starting from zero.
498 (elf_backend_can_refcount): Define.
499 * elf32-hppa.c (elf32_hppa_check_relocs): Modify for refcounts
500 starting from zero.
501 (elf32_hppa_copy_indirect_symbol): Make static to agree with
502 prototype.
503 (elf_backend_can_refcount): Define.
504 * elf32-i386.c (elf_i386_check_relocs): Modify for refcounts
505 starting from zero.
506 (allocate_dynrelocs): Set plt/got.offset rather than *.refcount.
507 (elf_i386_finish_dynamic_symbol): Expand SHN_UNDEF comment.
508 (elf_i386_finish_dynamic_sections): Use local var so line < 80 chars.
509 (elf_backend_can_refcount): Define.
510 (elf_i386_copy_indirect_symbol): Make static to agree with
511 prototype. Formatting fix.
512 * elf32-m68k.c (elf_m68k_check_relocs): Modify for refcounts
513 starting from zero.
514 (elf_backend_can_refcount): Define.
515 * elf32-ppc.c (ppc_elf_check_relocs): Modify for refcounts
516 starting from zero.
517 (elf_backend_can_refcount): Define.
518 * elf32-s390.c (elf_s390_check_relocs): Modify for refcounts
519 starting from zero.
520 (elf_backend_can_refcount): Define.
521 * elf64-s390.c (elf_s390_check_relocs): Modify for refcounts
522 starting from zero.
523 (elf_backend_can_refcount): Define.
524 * elf64-x86-64.c (elf64_x86_64_check_relocs): Modify for refcounts
525 starting from zero.
526 (elf_backend_can_refcount): Define.
527
528 * som.c (som_write_symbol_strings): Cast current_offset in
529 bfd_seek call to match param type.
530
531 2001-09-28 J. Brobecker <brobecker@gnat.com>
532
533 * som.c (som_write_symbol_strings): Fix incorrect type of
534 current_offset to match the function definition. Fixes a build
535 failure on HPUX-11.00.
536
537 2001-09-28 Richard Henderson <rth@redhat.com>
538
539 * elfxx-target.h [section_flags]: Add SEC_ARCH_BIT_0, SEC_SMALL_DATA,
540 SEC_MERGE, SEC_STRINGS.
541
542 * section.c (SEC_ARCH_BIT_0): New; replace unused SEC_BALIGN.
543 * bfd-in2.h: Rebuild.
544
545 2001-09-28 Alan Modra <amodra@bigpond.net.au>
546
547 * elf64-x86-64.c (elf64_x86_64_reloc_type_lookup): Don't map bfd
548 reloc code using x86_64_reloc_map.
549
550 * elf32-hppa.c (elf32_hppa_check_relocs): Update comment since we
551 no longer allocate here. Localise some vars to blocks where they
552 are used.
553 (elf32_hppa_adjust_dynamic_symbol): Correct a comment. Delay
554 setting of vars until needed.
555 (allocate_dynrelocs): Don't create a .plt entry without a reloc
556 when symbol visibilty makes a function local.
557 (elf32_hppa_finish_dynamic_symbol): Move expressions out of
558 swap_reloca_out function calls.
559 (elf32_hppa_relocate_section): Likewies. Comment typo fix.
560 (elf32_hppa_finish_dynamic_sections): Migrate common code out of
561 switch statement.
562
563 * elf32-i386.c (elf_i386_check_relocs): Update comment since we
564 no longer allocate here. Localise some vars to blocks where they
565 are used. Remove separate switch stmt for creating .got sec.
566 (elf_i386_adjust_dynamic_symbol): Correct a comment. Remove
567 redundant casts and aborts. Delay setting of vars until needed.
568 (allocate_dynrelocs): Remove redundant casts and aborts.
569 (elf_i386_size_dynamic_sections): Move comment.
570 (elf_i386_finish_dynamic_symbol): Move expressions out of function
571 calls.
572 (elf_i386_relocate_section): Likewise. Comment typo fix.
573 (elf_i386_finish_dynamic_sections): Migrate common code out of
574 switch statement.
575 (elf_backend_* defines): Sort.
576
577 * elf32-i386.c (allocate_dynrelocs): Don't create a .plt entry
578 without a reloc when symbol visibilty makes a function local.
579
580 2001-09-27 Nick Clifton <nickc@cambridge.redhat.com>
581
582 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix detection of
583 conflicting float flags.
584
585 2001-09-26 Alan Modra <amodra@bigpond.net.au>
586
587 * elf32-i386 (elf_i386_copy_indirect_symbol): New function.
588 (elf_backend_copy_indirect_symbol): Define.
589 (struct elf_i386_link_hash_entry): Rename "root" to "elf".
590 (struct elf_i386_link_hash_table): Likewise.
591 (link_hash_newfunc): Get rid of unnecessary casts.
592 (elf_i386_link_hash_table_create): Likewise.
593 (elf_i386_check_relocs): Initialise local_got_refcounts to 0.
594 Don't test input section SEC_READONLY here to try to avoid copy
595 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
596 (elf_i386_adjust_dynamic_symbol): Check output section SEC_READONLY
597 here to properly test whether we need copy relocs. Do so for weak
598 syms too.
599
600 * elf32-hppa (elf32_hppa_copy_indirect_symbol): New function.
601 (elf_backend_copy_indirect_symbol): Define.
602 (struct elf32_hppa_link_hash_table): Rename "root" to "elf".
603 (stub_hash_newfunc): Get rid of unnecessary casts.
604 (hppa_link_hash_newfunc): Likewise.
605 (elf32_hppa_check_relocs): Initialise local_got_refcounts to 0.
606 Don't test input section SEC_READONLY here to try to avoid copy
607 relocs, and keep dyn_relocs regardleas of ELF_LINK_NON_GOT_REF.
608 (elf32_hppa_adjust_dynamic_symbol): Check output section SEC_READONLY
609 here to properly test whether we need copy relocs. Do so for weak
610 syms too.
611
612 2001-09-26 Alan Modra <amodra@bigpond.net.au>
613
614 * bfd.c (_bfd_default_error_handlerl): Define using VPARAMS,
615 VA_OPEN, VA_FIXEDARG, VA_CLOSE.
616 (bfd_archive_filename): Cast bfd_malloc arg to the correct size.
617
618 2001-09-25 Jakub Jelinek <jakub@redhat.com>
619
620 * elf64-sparc.c (sparc64_elf_build_plt): Fix .plt[32768+] slot
621 computation.
622
623 2001-09-25 H.J. Lu <hjl@gnu.org>
624
625 * bfd-in2.h: Regenerated.
626
627 2001-09-25 Alan Modra <amodra@bigpond.net.au>
628
629 * elf32-i386.c: Add comment re linker function names and ordering.
630 (elf_i386_link_hash_newfunc): Rename to link_hash_newfunc.
631 (elf_i386_grok_prstatus): Move before linker functions.
632 (elf_i386_grok_psinfo): Likewise.
633 (elf_i386_fake_sections): Move so that functions are ordered.
634 (elf_i386_reloc_type_class): Likewise. Comment function purpose.
635
636 2001-09-25 Alan Modra <amodra@bigpond.net.au>
637
638 * elf32-hppa.c: Rename occurrences of "hplink" to "htab"
639 throughout file.
640
641 * elf32-hppa.c: (LONG_BRANCH_PIC_IN_SHLIB): Delete. Remove all
642 code handling this option.
643 (LONG_BRANCH_VIA_PLT): Likewise.
644 (RELATIVE_DYNRELOCS): Define as zero.
645 (struct elf32_hppa_dyn_reloc_entry): Add "sec", and
646 "pc_count" fields. Remove "section" field.
647 (elf32_hppa_link_hash_entry): Rename reloc_entries to dyn_relocs.
648 (elf32_hppa_check_relocs): Don't allocate space for dynamic
649 relocs here. Instead, record all needed dynamic relocs via
650 dyn_relocs and local_dynrel. Cache pointer to "sreloc" section
651 in elf_section_data.
652 (elf32_hppa_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
653 (allocate_plt_and_got_and_discard_relocs): Rename to
654 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
655 (readonly_dynrelocs): New function.
656 (elf32_hppa_size_dynamic_sections): Mark output_bfd unused.
657 Call readonly_dynrelocs to determine need for DT_TEXTREL.
658 Rename "i" to "ibfd". Allocate space for local dyn relocs.
659 (elf32_hppa_relocate_section): Make use of cached sreloc.
660 (elf32_hppa_reloc_type_class): New function.
661 (elf_backend_reloc_type_class): Define.
662
663 2001-09-25 Alan Modra <amodra@bigpond.net.au>
664
665 * elf-bfd.h (struct bfd_elf_section_data): Add "local_dynrel"
666 and "sreloc" fields.
667 * elf32-i386.c (struct elf_i386_dyn_relocs): Add "sec", and
668 "pc_count" fields. Remove "section" field.
669 (elf_i386_check_relocs): Don't set DF_TEXTREL here. Don't
670 allocate space for dynamic relocs here. Instead, record all
671 needed dynamic relocs via dyn_relocs and local_dynrel. Cache
672 pointer to "sreloc" section in elf_section_data.
673 (elf_i386_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
674 (allocate_plt_and_got_and_discard_relocs): Rename to
675 allocate_dynrelocs. Allocate rather than discarding dyn relocs.
676 (readonly_dynrelocs): New function.
677 (elf_i386_size_dynamic_sections): Call readonly_dynrelocs.
678 Rename "i" to "ibfd". Allocate space for local dyn relocs.
679 (elf_i386_relocate_section): Make use of cached sreloc.
680
681 2001-09-24 Alan Modra <amodra@bigpond.net.au>
682
683 * elf-bfd.h (elf_backend_reloc_type_class): Pass in the entire
684 reloc rather than just the type.
685 (_bfd_elf_reloc_type_class): Likewise.
686 * elf.c (_bfd_elf_reloc_type_class): Likewise.
687 * elf32-arm.h (elf32_arm_reloc_type_class): Likewise.
688 * elf32-cris.c (elf_cris_reloc_type_class): Likewise.
689 * elf32-i386.c (elf_i386_reloc_type_class): Likewise.
690 * elf32-m68k.c (elf32_m68k_reloc_type_class): Likewise.
691 * elf32-ppc.c (ppc_elf_reloc_type_class): Likewise.
692 * elf32-s390.c (elf_s390_reloc_type_class): Likewise.
693 * elf32-sh.c (sh_elf_reloc_type_class): Likewise.
694 * elf32-sparc.c (elf32_sparc_reloc_type_class): Likewise.
695 * elf64-alpha.c (elf64_alpha_reloc_type_class): Likewise.
696 * elf64-s390.c (elf_s390_reloc_type_class): Likewise.
697 * elf64-sparc.c (sparc64_elf_reloc_type_class): Likewise.
698 * elf64-x86-64.c (elf64_x86_64_reloc_type_class): Likewise.
699 * elfxx-ia64.c (elfNN_ia64_reloc_type_class): Likewise.
700 * elflink.h: Formatting fixes.
701 (elf_link_sort_relocs): Make "count" and "size" bfd_size_type.
702 Call bfd_zmalloc rather than calloc. Remove unnecessary cast of
703 o->contents to PTR. Update call to elf_backend_reloc_type_class.
704
705 2001-09-22 John Reiser <jreiser@BitWagon.com>
706
707 * elfcode.h (elf_object_p): Allow for no section header at all in
708 non-ET_REL files. Honor 0 for e_shnum, e_shstrndx, e_shoff.
709
710 2001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
711
712 * elfxx-ia64.c: Fix compile time warning messages.
713 * coff-mcore.c: Fix compile time warning messages.
714 * coff-ppc.c: Fix compile time warning messages.
715 * coffcode.h: Fix compile time warning messages.
716 * elf32-mips.c: Fix compile time warning messages.
717 * elf64-alpha.c: Fix compile time warning messages.
718 * libbfd.c: Fix compile time warning messages.
719 * bfd-in2.h: Regenerate.
720
721 2001-09-21 Alan Modra <amodra@bigpond.net.au>
722
723 * Makefile.am: Run "make dep-am".
724 * Makefile.in: Regenerate.
725
726 * aoutx.h: Formatting fixes.
727 * merge.c (_bfd_merged_section_offset): Break line at 80 chars.
728
729 * linker.c: Replace bfd_get_filename with bfd_archive_filename
730 in error message.
731
732 2001-09-21 Alan Modra <amodra@bigpond.net.au>
733
734 * bfd.c (bfd_archive_filename): New function.
735 * bfd-in2.h: Regenerate.
736 * aout-adobe.c: Replace bfd_get_filename with bfd_archive_filename
737 in error messages where the bfd is an input bfd.
738 * aout-cris.c: Likewise.
739 * coff-arm.c: Likewise.
740 * coff-mcore.c: Likewise.
741 * coff-ppc.c: Likewise.
742 * coff-rs6000.c: Likewise.
743 * coff-sh.c: Likewise.
744 * coff-tic54x.c: Likewise.
745 * coff-tic80.c: Likewise.
746 * coff64-rs6000.c: Likewise.
747 * coffcode.h: Likewise.
748 * coffgen.c: Likewise.
749 * cofflink.c: Likewise.
750 * ecofflink.c: Likewise.
751 * elf-hppa.h: Likewise.
752 * elf.c: Likewise.
753 * elf32-arm.h: Likewise.
754 * elf32-cris.c: Likewise.
755 * elf32-gen.c: Likewise.
756 * elf32-hppa.c: Likewise.
757 * elf32-i370.c: Likewise.
758 * elf32-i386.c: Likewise.
759 * elf32-m32r.c: Likewise.
760 * elf32-mcore.c: Likewise.
761 * elf32-mips.c: Likewise.
762 * elf32-ppc.c: Likewise.
763 * elf32-s390.c: Likewise.
764 * elf32-sh.c: Likewise.
765 * elf32-sparc.c: Likewise.
766 * elf32-v850.c: Likewise.
767 * elf64-alpha.c: Likewise.
768 * elf64-gen.c: Likewise.
769 * elf64-ppc.c: Likewise.
770 * elf64-s390.c: Likewise.
771 * elf64-sparc.c: Likewise.
772 * elf64-x86-64.c: Likewise.
773 * elflink.h: Likewise.
774 * elfxx-ia64.c: Likewise.
775 * ieee.c: Likewise.
776 * ihex.c: Likewise.
777 * libbfd.c: Likewise.
778 * pdp11.c: Likewise.
779 * pe-mips.c: Likewise.
780 * peicode.h: Likewise.
781 * srec.c: Likewise.
782 * xcofflink.c: Likewise.
783
784 * elf32-arm.h: Make _bfd_error_handler calls K&R compatible.
785
786 * elflink.c (_bfd_elf_create_linker_section): Better grammar for
787 error message.
788
789 * coff-mcore.c (coff_mcore_relocate_section): Internalionalise
790 error message.
791
792 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Constify stt_types.
793 Consolidate error messages, and split long messages to two lines.
794
795 2001-09-20 John Reiser <jreiser@BitWagon.com>
796
797 * elf32-i386.c (elf_i386_relocate_section): Coordinate info->symbolic
798 and info->allow_shlib_undefined.
799 * elf32-cris.c: Likewise.
800 * elf32-hppa.c: Likewise.
801 * elf32-m68k.c: Likewise.
802 * elf32-mips.c: Likewise.
803 * elf32-ppc.c: Likewise.
804 * elf32-s390.c: Likewise.
805 * elf32-sh.c: Likewise.
806 * elf32-sparc.c: Likewise.
807 * elf64-alpha.c: Likewise.
808 * elf64-hppa.c: Likewise.
809 * elf64-ppc.c: Likewise.
810 * elf64-s390.c: Likewise.
811 * elf64-sparc.c: Likewise.
812 * elf64-x86-64.c: Likewise.
813 * elfxx-ia64.c: Likewise.
814
815 2001-09-18 Bruno Haible <haible@clisp.cons.org>
816
817 * aoutx.h: Include "safe-ctype.h" instead of <ctype.h>.
818 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
819 * archive.c: Include "safe-ctype.h" instead of <ctype.h>.
820 (_bfd_generic_read_ar_hdr_mag): Use ISDIGIT instead of isdigit.
821 * archures.c: Include "safe-ctype.h" instead of <ctype.h>.
822 (bfd_default_scan): Use ISDIGIT instead of isdigit.
823 * bfd.c: Include "safe-ctype.h" instead of <ctype.h>.
824 (bfd_scan_vma): Use ISXDIGIT/ISDIGIT/ISLOWER instead of
825 isxdigit/isdigit/islower.
826 * binary.c: Include "safe-ctype.h" instead of <ctype.h>.
827 (mangle_name): Use ISALNUM instead of isalnum.
828 * cpu-v850.c: Include "safe-ctype.h" instead of <ctype.h>.
829 (scan): Use ISDIGIT instead of isdigit.
830 * hosts/alphavms.h: Don't include <ctype.h>.
831 * ieee.c: Include "safe-ctype.h" instead of <ctype.h>.
832 (ieee_object_p): Use TOUPPER instead of toupper.
833 * ihex.c: Include "safe-ctype.h" instead of <ctype.h>.
834 (ihex_bad_byte): Use ISPRINT instead of isprint.
835 * merge.c: Don't include <ctype.h>.
836 * oasys.c: Include "safe-ctype.h" instead of <ctype.h>.
837 (oasys_write_sections): Use ISDIGIT instead of isdigit.
838 * pdp11.c: Include "safe-ctype.h" instead of <ctype.h>.
839 (aout_link_write_symbols): Use ISDIGIT instead of isdigit.
840 * ppcboot.c: Include "safe-ctype.h" instead of <ctype.h>.
841 (mangle_name): Use ISALNUM instead of isalnum.
842 * som.c: Include "safe-ctype.h" instead of <ctype.h>.
843 (som_set_reloc_info): Use ISUPPER/ISLOWER/ISDIGIT instead of
844 isupper/islower/isdigit.
845 (som_decode_symclass): Use TOUPPER instead of toupper.
846 * srec.c: Include "safe-ctype.h" instead of <ctype.h>.
847 (srec_bad_byte): Use ISPRINT instead of isprint.
848 (srec_scan): Use ISSPACE instead of isspace.
849 * stabs.c: Include "safe-ctype.h" instead of <ctype.h>.
850 (_bfd_link_section_stabs): Use ISDIGIT instead of isdigit.
851 * syms.c: Include "safe-ctype.h"
852 (islower, toupper): Remove macro definitions.
853 (bfd_decode_symclass): Use TOUPPER instead of toupper.
854 * vms-gsd.c: Don't include <ctype.h>.
855 * vms-hdr.c: Include "safe-ctype.h" instead of <ctype.h>.
856 (_bfd_vms_write_hdr): Use ISLOWER/TOUPPER instead of
857 islower/toupper.
858 * vms-tir.c: Don't include <ctype.h>.
859
860 2001-09-18 Alan Modra <amodra@bigpond.net.au>
861
862 * libbfd.c (bfd_bread): New function replacing bfd_read without
863 redundant params. Allow reads up to (size_t) -2 in length.
864 (bfd_bwrite): Similarly for bfd_write.
865 (real_read): Return a size_t.
866 (bfd_read): Call bfd_bread.
867 (bfd_write): Call bfd_bwrite.
868 (warn_deprecated): New function to annoy everybody.
869 (bfd_get_file_window): Don't call bfd_set_error unnecessarily.
870 * bfd-in.h (bfd_bread, bfd_bwrite, warn_deprecated): Declare.
871 (bfd_read, bfd_write): Define as macro.
872 * aix386-core.c: Replace calls to bfd_read with bfd_bread, and
873 likewise for bfd_write. Ensure function args are correct size by
874 using casts or local vars. In some cases, remove unnecessary
875 casts. Formatting fixes, in some cases removing a large expression
876 from function args by using a local var. Replace CONST with const.
877 Modify variable types to avoid warings. Use casts to avoid
878 warnings when using negative numbers in unsigned expressions.
879 * aout-adobe.c: Likewise.
880 * aout-arm.c: Likewise.
881 * aout-cris.c: Likewise.
882 * aout-encap.c: Likewise.
883 * aout-ns32k.c: Likewise.
884 * aout-target.h: Likewise.
885 * aout-tic30.c: Likewise.
886 * aoutf1.h: Likewise.
887 * aoutx.h: Likewise.
888 * archive.c: Likewise.
889 * archures.c: Likewise.
890 * bfd-in.h: Likewise.
891 * bfd.c: Likewise.
892 * binary.c: Likewise.
893 * bout.c: Likewise.
894 * cache.c: Likewise.
895 * cisco-core.c: Likewise.
896 * coff-a29k.c: Likewise.
897 * coff-alpha.c: Likewise.
898 * coff-arm.c: Likewise.
899 * coff-h8300.c: Likewise.
900 * coff-h8500.c: Likewise.
901 * coff-i386.c: Likewise.
902 * coff-i860.c: Likewise.
903 * coff-i960.c: Likewise.
904 * coff-ia64.c: Likewise.
905 * coff-m68k.c: Likewise.
906 * coff-m88k.c: Likewise.
907 * coff-mcore.c: Likewise.
908 * coff-mips.c: Likewise.
909 * coff-ppc.c: Likewise.
910 * coff-rs6000.c: Likewise.
911 * coff-sh.c: Likewise.
912 * coff-sparc.c: Likewise.
913 * coff-stgo32.c: Likewise.
914 * coff-tic30.c: Likewise.
915 * coff-tic54x.c: Likewise.
916 * coff-tic80.c: Likewise.
917 * coff-w65.c: Likewise.
918 * coff-z8k.c: Likewise.
919 * coff64-rs6000.c: Likewise.
920 * coffcode.h: Likewise.
921 * coffgen.c: Likewise.
922 * cofflink.c: Likewise.
923 * coffswap.h: Likewise.
924 * corefile.c: Likewise.
925 * cpu-arc.c: Likewise.
926 * cpu-h8300.c: Likewise.
927 * cpu-h8500.c: Likewise.
928 * cpu-i960.c: Likewise.
929 * cpu-ia64-opc.c: Likewise.
930 * cpu-ns32k.c: Likewise.
931 * cpu-pdp11.c: Likewise.
932 * cpu-pj.c: Likewise.
933 * cpu-sh.c: Likewise.
934 * cpu-w65.c: Likewise.
935 * cpu-z8k.c: Likewise.
936 * dwarf1.c: Likewise.
937 * dwarf2.c: Likewise.
938 * ecoff.c: Likewise.
939 * ecofflink.c: Likewise.
940 * ecoffswap.h: Likewise.
941 * elf-bfd.h: Likewise.
942 * elf-hppa.h: Likewise.
943 * elf-m10200.c: Likewise.
944 * elf-m10300.c: Likewise.
945 * elf.c: Likewise.
946 * elf32-arc.c: Likewise.
947 * elf32-arm.h: Likewise.
948 * elf32-avr.c: Likewise.
949 * elf32-cris.c: Likewise.
950 * elf32-fr30.c: Likewise.
951 * elf32-gen.c: Likewise.
952 * elf32-h8300.c: Likewise.
953 * elf32-hppa.c: Likewise.
954 * elf32-i370.c: Likewise.
955 * elf32-i386.c: Likewise.
956 * elf32-i860.c: Likewise.
957 * elf32-m32r.c: Likewise.
958 * elf32-m68k.c: Likewise.
959 * elf32-mcore.c: Likewise.
960 * elf32-mips.c: Likewise.
961 * elf32-openrisc.c: Likewise.
962 * elf32-pj.c: Likewise.
963 * elf32-ppc.c: Likewise.
964 * elf32-s390.c: Likewise.
965 * elf32-sh-lin.c: Likewise.
966 * elf32-sh.c: Likewise.
967 * elf32-sparc.c: Likewise.
968 * elf32-v850.c: Likewise.
969 * elf64-alpha.c: Likewise.
970 * elf64-hppa.c: Likewise.
971 * elf64-mips.c: Likewise.
972 * elf64-ppc.c: Likewise.
973 * elf64-s390.c: Likewise.
974 * elf64-sparc.c: Likewise.
975 * elf64-x86-64.c: Likewise.
976 * elfarm-nabi.c: Likewise.
977 * elfcode.h: Likewise.
978 * elfcore.h: Likewise.
979 * elflink.c: Likewise.
980 * elflink.h: Likewise.
981 * elfxx-ia64.c: Likewise.
982 * elfxx-target.h: Likewise.
983 * format.c: Likewise.
984 * hash.c: Likewise.
985 * hp300hpux.c: Likewise.
986 * hppabsd-core.c: Likewise.
987 * hpux-core.c: Likewise.
988 * i386aout.c: Likewise.
989 * i386dynix.c: Likewise.
990 * i386linux.c: Likewise.
991 * i386lynx.c: Likewise.
992 * i386mach3.c: Likewise.
993 * i386msdos.c: Likewise.
994 * i386os9k.c: Likewise.
995 * ieee.c: Likewise.
996 * ihex.c: Likewise.
997 * irix-core.c: Likewise.
998 * libaout.h: Likewise.
999 * libbfd-in.h: Likewise.
1000 * libbfd.c: Likewise.
1001 * libcoff-in.h: Likewise.
1002 * libecoff.h: Likewise.
1003 * libieee.h: Likewise.
1004 * libnlm.h: Likewise.
1005 * libpei.h: Likewise.
1006 * libxcoff.h: Likewise.
1007 * linker.c: Likewise.
1008 * lynx-core.c: Likewise.
1009 * m68klinux.c: Likewise.
1010 * merge.c: Likewise.
1011 * mipsbsd.c: Likewise.
1012 * netbsd-core.c: Likewise.
1013 * nlm.c: Likewise.
1014 * nlm32-alpha.c: Likewise.
1015 * nlm32-i386.c: Likewise.
1016 * nlm32-ppc.c: Likewise.
1017 * nlm32-sparc.c: Likewise.
1018 * nlmcode.h: Likewise.
1019 * nlmswap.h: Likewise.
1020 * ns32k.h: Likewise.
1021 * oasys.c: Likewise.
1022 * opncls.c: Likewise.
1023 * osf-core.c: Likewise.
1024 * pc532-mach.c: Likewise.
1025 * pdp11.c: Likewise.
1026 * pe-mips.c: Likewise.
1027 * peXXigen.c: Likewise.
1028 * peicode.h: Likewise.
1029 * ppcboot.c: Likewise.
1030 * ptrace-core.c: Likewise.
1031 * reloc.c: Likewise.
1032 * reloc16.c: Likewise.
1033 * riscix.c: Likewise.
1034 * rs6000-core.c: Likewise.
1035 * sco5-core.c: Likewise.
1036 * section.c: Likewise.
1037 * som.c: Likewise.
1038 * sparclinux.c: Likewise.
1039 * sparclynx.c: Likewise.
1040 * srec.c: Likewise.
1041 * stabs.c: Likewise.
1042 * sunos.c: Likewise.
1043 * syms.c: Likewise.
1044 * targets.c: Likewise.
1045 * tekhex.c: Likewise.
1046 * trad-core.c: Likewise.
1047 * versados.c: Likewise.
1048 * vms-gsd.c: Likewise.
1049 * vms-hdr.c: Likewise.
1050 * vms-misc.c: Likewise.
1051 * vms-tir.c: Likewise.
1052 * vms.c: Likewise.
1053 * vms.h: Likewise.
1054 * xcofflink.c: Likewise.
1055 * bfd-in2.h: Regenerate.
1056 * libbfd.h: Regenerate.
1057 * libcoff.h: Regenerate.
1058
1059 * bfd.c (struct _bfd): Make "where" and "origin" unsigned.
1060 * bfd-in.h (file_ptr): Change from a long int to a bfd_signed_vma.
1061 (ufile_ptr): Define.
1062 (bfd_tell): Return a ufile_ptr.
1063 * libbfd.c (bfd_tell): Likewise.
1064 (bfd_seek): Use bfd_size_type locals. Don't call bfd_set_error
1065 unnecessarily.
1066 * aix386-core.c: Test != 0 for bfd_seek errors rather than < 0.
1067 * aoutf1.h: Likewise.
1068 * som.c: Likewise.
1069 * cache.c (bfd_cache_lookup_worker): Guard against abfd->where
1070 larger than unsigned long can represent.
1071
1072 * libbfd.c (bfd_malloc): Take a bfd_size_type arg. Error if
1073 size overflows size_t.
1074 (bfd_realloc): Likewise.
1075 (bfd_zmalloc): Likewise.
1076 * opncls.c (bfd_alloc): Likewise.
1077 (bfd_zalloc): Likewise.
1078 * libbfd-in.h (bfd_malloc, bfd_realloc, bfd_zmalloc): Update.
1079 (bfd_alloc, bfd_zalloc): Update.
1080
1081 * libbfd.c (bfd_get_8): Mask with 0xff in case char is more than
1082 8 bits.
1083 (bfd_get_signed_8): Likewise.
1084 (H_PUT_64, H_PUT_32, H_PUT_16, H_PUT_8,
1085 H_PUT_S64, H_PUT_S32, H_PUT_S16, H_PUT_S8,
1086 H_GET_64, H_GET_32, H_GET_16, H_GET_8,
1087 H_GET_S64, H_GET_S32, H_GET_S16, H_GET_S8): Define and use.
1088 * libaout.h: Likewise define and use here.
1089 * aout-adobe.c: Use H_GET_* and H_PUT_* macros.
1090 * aout-arm.c: Likewise.
1091 * aout-encap.c: Likewise.
1092 * aout-ns32k.c: Likewise.
1093 * aout-tic30.c: Likewise.
1094 * aoutf1.h: Likewise.
1095 * aoutx.h: Likewise.
1096 * bout.c: Likewise.
1097 * coff-alpha.c: Likewise.
1098 * coff-h8300.c: Likewise.
1099 * coff-h8500.c: Likewise.
1100 * coff-i960.c: Likewise.
1101 * coff-ia64.c: Likewise.
1102 * coff-m88k.c: Likewise.
1103 * coff-mips.c: Likewise.
1104 * coff-ppc.c: Likewise.
1105 * coff-rs6000.c: Likewise.
1106 * coff-sh.c: Likewise.
1107 * coff-sparc.c: Likewise.
1108 * coff-stgo32.c: Likewise.
1109 * coff-tic30.c: Likewise.
1110 * coff-tic80.c: Likewise.
1111 * coff-w65.c: Likewise.
1112 * coff-z8k.c: Likewise.
1113 * coff64-rs6000.c: Likewise.
1114 * coffgen.c: Likewise.
1115 * cofflink.c: Likewise.
1116 * coffswap.h: Likewise.
1117 * ecoff.c: Likewise.
1118 * ecoffswap.h: Likewise.
1119 * elf.c: Likewise.
1120 * elf32-mips.c: Likewise.
1121 * elf64-mips.c: Likewise.
1122 * hp300hpux.c: Likewise.
1123 * i386dynix.c: Likewise.
1124 * i386lynx.c: Likewise.
1125 * i386msdos.c: Likewise.
1126 * i386os9k.c: Likewise.
1127 * libpei.h: Likewise.
1128 * nlm32-alpha.c: Likewise.
1129 * nlm32-i386.c: Likewise.
1130 * nlm32-ppc.c: Likewise.
1131 * nlmcode.h: Likewise.
1132 * nlmswap.h: Likewise.
1133 * oasys.c: Likewise.
1134 * pdp11.c: Likewise.
1135 * pe-mips.c: Likewise.
1136 * peXXigen.c: Likewise.
1137 * peicode.h: Likewise.
1138 * riscix.c: Likewise.
1139 * sunos.c: Likewise.
1140 * xcofflink.c: Likewise.
1141 * elfcode.h: (put_word, get_word, put_signed_word, get_signed_word):
1142 Rename to H_PUT_WORD, H_GET_WORD, H_PUT_SIGNED_WORD, H_GET_SIGNED_WORD.
1143 * coff-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Don't define. Use
1144 equivalent H_PUT_* macro instead.
1145 (GETWORD, GETHALF, GETBYTE): Similarly.
1146 * coff64-rs6000.c (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1147 (GETWORD, GETHALF, GETBYTE): Likewise.
1148 * coffswap.h (PUTWORD, PUTHALF, PUTBYTE): Likewise.
1149
1150 * bfd-in.h (struct orl): Change "pos" to a union.
1151 * archive.c (_bfd_compute_and_write_armap): Use it instead of casts.
1152 (bsd_write_armap): Here too.
1153 (coff_write_armap): And here.
1154 * coff-rs6000.c (xcoff_write_armap_old): And here.
1155 (xcoff_write_one_armap_big): And here.
1156 (xcoff_write_armap_big): And here.
1157 * ecoff.c (_bfd_ecoff_write_armap): And here.
1158 * elf64-mips.c (mips_elf64_write_armap): And here.
1159
1160 * aoutf1.h (sunos_set_arch_mach): Make "mach" param an enum.
1161 * elf-m10300.c (elf_mn10300_mach): Return an unsigned long.
1162 * elf32-h8300.c (elf32_h8_mach): Likewise.
1163 * elf32-mips.c (elf_mips_mach): Likewise.
1164 * sparclynx.c (NAME(lynx,set_arch_mach)): Likewise.
1165
1166 * aix386-core.c (aix386_core_file_p): Remove redundant bfd_release
1167 calls.
1168 (aix386_core_vec): Typo fix.
1169
1170 * aout-arm.c: Include libaout.h and aout/aout64.h after N_TXTADDR
1171 etc. to avoid redefined macro warning.
1172 (MY(put_reloc)): Use bfd_vma for "value" rather than long.
1173 (MY(fix_pcrel_26)): Likewise.
1174 * aout-ns32k.c (MY(put_reloc)): Likewise.
1175 * aout-cris.c (MY(swap_ext_reloc_out)): Likewise for r_addend.
1176 * aoutx.h (NAME(aout,swap_ext_reloc_out)): Likewise.
1177 * coff-arm.c (coff_arm_relocate_section): Likewise for my_offset.
1178
1179 * aout-encap.c: Include "file", not <file> for binutils headers.
1180 (encap_object_p): Half baked attempt to fix compile errors in
1181 code dealing with "magic".
1182
1183 * aout-ns32k.c: Include "file", not <file> for binutils headers.
1184 (_bfd_ns32k_relocate_contents): get_data and put_data manipulate
1185 bfd_vma's rather than longs.
1186 * cpu-ns32k.c (ns32k_sign_extend): Delete.
1187 (_bfd_ns32k_get_displacement): Return a bfd_vma, don't pass in offset.
1188 (_bfd_ns32k_get_immediate): Likewise. Add code for 8 byte values,
1189 remove case 3.
1190 (_bfd_ns32k_put_displacement): Accept a bfd_vma, don't pass in offset.
1191 Use unsigned comparisons.
1192 (bfd_ns32k_put_immediate): Likewise, and add code for 8 byte values.
1193 (do_ns32k_reloc): get_data and put_data operate on bfd_vma's.
1194 (_bfd_do_ns32k_reloc_contents): Likewise.
1195 * ns32k.h (_bfd_ns32k_get_displacement): Update prototype.
1196 (_bfd_ns32k_get_immediate): Likewise.
1197 (_bfd_ns32k_put_displacement): Likewise.
1198 (_bfd_ns32k_put_immediate): Likewise.
1199 (bfd_reloc_status_type): Likewise.
1200
1201 * aoutx.h (NAME(aout,find_nearest_line)): Rename 'p' to 'colon'
1202 to avoid shadowing.
1203 * pdp11.c (NAME(aout,find_nearest_line)): Likewise.
1204 * coff-h8300.c (h8300_reloc16_extra_cases): Remove shadowing "value".
1205 * coff-ppc.c (enum ref_category): Rename "data" to "tocdata" to
1206 avoid shadowing.
1207 (record_toc): Use a bfd_signed_vma for our_toc_offset.
1208 * coffcode.h (coff_write_relocs): Rename "i" to avoid shadowing.
1209 * elf.c (bfd_elf_get_bfd_needed_list): Rename "link" var to avoid
1210 shadow warning.
1211 (_bfd_elfcore_strndup): Likewise for "dup".
1212 * elf32-cris.c (cris_elf_relocate_section): "symname" instead of
1213 "name" to avoid shadowing.
1214 * elf32-hppa.c (elf32_hppa_relocate_section): Remove duplicate
1215 definition of "off".
1216 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1217 * elf32-mips.c (_bfd_mips_elf_modify_segment_map): Remove duplicate
1218 definition of "s".
1219 (_bfd_mips_elf_final_link): Rename "i" to "j". Remove duplicate
1220 "secpp".
1221 * elf64-x86-64.c (elf64_x86_64_relocate_section): Rename inner "indx"
1222 to avoid shadowing.
1223 * elflink.h (elf_link_add_object_symbols): Rename "link" to "shlink"
1224 to avoid shadowing.
1225 (elf_link_input_bfd): Likewise.
1226 (elf_bfd_final_link): Remove duplicate innermost "off" var.
1227 * oasys.c (oasys_write_data): Rename innermost "p" to "sym".
1228 * reloc16.c (bfd_coff_reloc16_relax_section): Rename "i" param to
1229 "input_section".
1230 * som.c (som_prep_for_fixups): Rename inner "i" to "j".
1231 * sunos.c (sunos_add_dynamic_symbols): Localise "s" var.
1232 (sunos_write_dynamic_symbol): Remove unused vars.
1233 * syms.c (_bfd_stab_section_find_nearest_line): Remove duplicate
1234 innermost "directory_name" and "file_name" vars.
1235 * tekhex.c (first_phase): Rename local var "type" to "stype".
1236 (tekhex_write_object_contents): Rename innermost "s" to "sym".
1237 * vms-gsd.c (vms_secflag_by_name): Change "size" param to "hassize",
1238 doing comparison at caller.
1239 (vms_esecflag_by_name): Likewise.
1240 * vms-tir.c (etir_sto): Rename innermost "psect" to "psect1".
1241 * xcofflink.c (xcoff_link_input_bfd): Delete duplicate innermost "o".
1242 (xcoff_write_global_symbol): Rename "p" param to "inf".
1243
1244 * cisco-core.c: Add missing prototypes.
1245 (cisco_core_file_failing_command): Add ATTRIBUTE_UNUSED.
1246 (cisco_core_file_failing_signal): Likewise.
1247 (cisco_core_file_matches_executable_p): Likewise.
1248 * hpux-core.c (hpux_core_core_file_failing_signal): Likewise.
1249 * netbsd-core.c (netbsd_core_file_matches_executable_p): Likewise.
1250 * osf-core.c (osf_core_core_file_matches_executable_p): Likewise.
1251 * sco5-core.c (sco5_core_file_matches_executable_p): Likewise.
1252
1253 * coff-arm.c (coff_arm_link_hash_table): Use bfd_size_type for
1254 thumb_glue_size and arm_glue_size.
1255 * elf32-arm.h (elf32_arm_link_hash_table): Likewise here.
1256
1257 * coff64-rs6000.c: Group prototypes together.
1258
1259 * coffcode.h (coff_set_arch_mach): Add ATTRIBUTE_UNUSED.
1260 (buy_and_read): Remove "seek" param. Change "size" to bfd_size_type.
1261
1262 * cpu-arc.c: Add missing prototypes.
1263 * cpu-h8500.c: Likewise.
1264 * cpu-i960.c: Likewise.
1265 * cpu-pj.c: Likewise.
1266 * cpu-sh.c: Likewise.
1267 * cpu-w65.c: Likewise.
1268 * cpu-z8k.c: Likewise.
1269 * elf32-fr30.c: Likewise.
1270 * elf32-h8300.c: Likewise.
1271 * elf32-i370.c: Likewise.
1272 * hpux-core.c: Likewise.
1273 * versados.c: Likewise.
1274
1275 * cpu-h8300.c (bfd_default_scan_num_mach): Don't declare.
1276 * cpu-h8500.c: Likewise.
1277 * cpu-i960.c: Likewise.
1278 * cpu-z8k.c: Likewise.
1279
1280 * cpu-ia64-opc.c: Correct comment.
1281
1282 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Remove unused var.
1283
1284 * elf-bfd.h (elf_size_info): Change count param of write_out_phdrs
1285 to unsigned.
1286 (bfd_elf32_write_out_phdrs): Likewise.
1287 (bfd_elf64_write_out_phdrs): Likewise.
1288 (elf_linker_section_pointers): Change addend to bfd_vma.
1289 (_bfd_elf_find_pointer_linker_section): Likewise.
1290 (_bfd_elfcore_make_pseudosection): Change size param to size_t and
1291 filepos to unsigned file_ptr.
1292 (_bfd_elfcore_strndup): Change max param to size_t.
1293 * elf.c (_bfd_elfcore_make_pseudosection): As above.
1294 (_bfd_elfcore_strndup): Likewise.
1295 (_bfd_elf_find_pointer_linker_section): Likewise.
1296
1297 * elf-hppa.h (elf_hppa_relocate_insn): Return an int, and change
1298 insn and sym_value to ints.
1299
1300 * elf.c (elf_read): Make "offset" param a file_ptr, "size" a
1301 bfd_size_type.
1302 (elfcore_read_notes): Likewise.
1303
1304 * elf32-arm.h (elf32_arm_final_link_relocate): Change sym_flags
1305 param from unsigned char to int.
1306 (elf32_arm_relocate_section): If USE_REL, cast "rel" appropriately
1307 for info_to_howto call.
1308 (add_dynamic_entry): Define macro.
1309 (elf32_arm_size_dynamic_sections): Use add_dynamic_entry.
1310
1311 * elf32-cris.c (add_dynamic_entry): Define macro.
1312 (elf_cris_size_dynamic_sections): Use add_dynamic_entry.
1313
1314 * elf32-h8300.c (elf32_h8_final_write_processing): Make static.
1315 (elf32_h8_object_p): Likewise.
1316 (elf32_h8_merge_private_bfd_data): Likewise.
1317 (elf32_h8_relax_section): Cast gap to int so signed comparisons work.
1318
1319 * elf32-hppa.c (add_dynamic_entry): Define macro.
1320 (elf32_hppa_size_dynamic_sections): Use it.
1321 * elf32-i370.c (add_dynamic_entry): Define macro.
1322 (i370_elf_size_dynamic_sections): Use it.
1323 (i370_noop): Make static.
1324 * elf32-i386.c (add_dynamic_entry): Define macro.
1325 (elf_i386_size_dynamic_sections): Use it.
1326 * elf32-m68k.c (add_dynamic_entry): Define macro.
1327 (elf_m68k_size_dynamic_sections): Use it.
1328 * elf32-ppc.c (add_dynamic_entry): Define macro.
1329 (ppc_elf_size_dynamic_sections): Use it.
1330 * elf32-s390.c (add_dynamic_entry): Define macro.
1331 (elf_s390_size_dynamic_sections): Use it.
1332 * elf64-alpha.c (add_dynamic_entry): Define macro.
1333 (elf64_alpha_size_dynamic_sections): Use it.
1334 * elf64-hppa.c (add_dynamic_entry): Define macro.
1335 (elf64_hppa_size_dynamic_sections): Use it.
1336 * elf64-ppc.c (add_dynamic_entry): Define macro.
1337 (ppc64_elf_size_dynamic_sections): Use it.
1338 * elf64-s390.c (add_dynamic_entry): Define macro.
1339 (elf_s390_size_dynamic_sections): Use it.
1340 * elf64-sparc.c (add_dynamic_entry): Define macro.
1341 (sparc64_elf_size_dynamic_sections): Use it.
1342 * elf64-x86-64.c (add_dynamic_entry): Define macro.
1343 (elf64_x86_64_size_dynamic_sections): Use it.
1344 * elfxx-ia64.c (add_dynamic_entry): Define macro.
1345 (elfNN_ia64_size_dynamic_sections): Use it.
1346
1347 * elf32-v850.c (SEXT24): Modify to avoid signed/unsigned warning.
1348 (v850_elf_perform_relocation): Make "r_type" param unsigned.
1349
1350 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Just return
1351 false if the first malloc fails rather than going via error_return.
1352
1353 * elf64-sparc.c (sparc64_elf_plt_entry_offset): Use a bfd_vma for
1354 "index" param.
1355 (sparc64_elf_plt_ptr_offset): Likewise, and for "max" param too.
1356
1357 * elflink.h (elf_link_input_bfd): s/ingored/ignored/ in error message.
1358
1359 * elfxx-ia64.c (global_sym_index): Return a long.
1360
1361 * ieee.c (get_symbol): Use int rather than char param.
1362 (ieee_slurp_sections): Move "section" var to inner blocks.
1363 (copy_expression): Don't init "value" to zero or worry about
1364 clearing to zero after using.
1365 (ieee_write_debug_part): Rename "output_buffer" to "obuff" to avoid
1366 shadowing.
1367
1368 * ihex.c (ihex_write_record): Make "count" var a size_t, "addr" an
1369 unsigned int.
1370
1371 * libbfd-in.h (BFD_ALIGN): Add cast to avoid signed/unsigned warning.
1372 (bfd_write_bigendian_4byte_int): Pass an unsigned int value param.
1373
1374 * mipsbsd.c (mips_fix_jmp_addr): Add "error_message" param.
1375
1376 * pc532-mach.c (MYNSX): Delete.
1377 (ns32kaout_bfd_reloc_type_lookup): Define prototype without MYNSX.
1378 (write_object_contents): Correct prototype.
1379
1380 * peicode.h (pe_ILF_build_a_bfd): Use an unsigned int param rather
1381 than unsigned short.
1382
1383 * section.c (bfd_set_section_contents): Remove redundant
1384 "offset < 0" test. Check that "count" doesn't overflow size_t.
1385 (bfd_get_section_contents): Likewise.
1386
1387 * som.c (som_fixup_formats): Add missing braces.
1388 (som_reloc_addend): Pass a bfd_vma for "addend".
1389
1390 * srec.c (srec_write_record): Pass "type" as an unsigned int.
1391 (srec_write_symbols): Remove an unnecessary var.
1392
1393 * targets.c (_bfd_target_vector): Sort entries. Sort externs
1394 to match.
1395 * configure.in: Sort to match. Bump version number.
1396 * configure: Regenerate.
1397
1398 * tekhex.c (move_section_contents): Assert offset == 0.
1399
1400 * versados.c (new_symbol_string): Constify arg.
1401 (process_esd): Use bfd_und_section_ptr rather than &bfd_und_section.
1402 (versados_get_symbol_info): Make static.
1403 (versados_print_symbol): Likewise.
1404 (versados_get_reloc_upper_bound): Likewise.
1405 (versados_canonicalize_reloc): Likewise.
1406
1407 2001-09-18 Nick Clifton <nickc@cambridge.redhat.com>
1408
1409 * elflink.h (elf_link_input_bfd): Fix typo in error message.
1410
1411 2001-09-17 H.J. Lu <hjl@gnu.org>
1412
1413 * dwarf1.c (parse_die): Take a new arg for the end of the
1414 section. Return false if die is beyond the section.
1415 (parse_functions_in_unit): Pass the end of the section to
1416 parse_die ().
1417 (_bfd_dwarf1_find_nearest_line): Likewise.
1418
1419 2001-09-14 Michael Rauch <mrauch@netbsd.org>
1420
1421 * elf32-sparc.c (elf32_sparc_relocate_section): Treat R_SPARC_UA32
1422 just like R_SPARC_32.
1423
1424 2001-09-14 Kevin Lo <kevlo@openbsd.org>
1425
1426 * configure.bfd: Add arm-openbsd target.
1427
1428 2001-09-14 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1429
1430 * config.bfd: Change machine triplets from mips*el*-* to mips*el-*.
1431 Add support for mips64.
1432
1433 2001-09-13 Alexandre Oliva <aoliva@redhat.com>
1434
1435 * elf32-openrisc.c (ELF_MACHINE_ALT1): Define as EM_OPENRISC_OLD.
1436
1437 2001-09-12 Alexandre Oliva <aoliva@redhat.com>
1438
1439 * elf.c (prep_headers): Get the machine code from the elf
1440 backend data.
1441 * elf-m10200.c (ELF_MACHINE_CODE): Redefine to EM_MN10200.
1442 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10200.
1443 * elf-m10300.c (ELF_MACHINE_CODE): Redefine to EM_MN10300.
1444 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10300.
1445 * elf-arc.c (arc_elf_final_write_processing): Don't override
1446 e_machine, it's now properly set in prep_headers.
1447 * elf32-avr.c (elf32_avr_object_p): Accept both EM_AVR and
1448 EM_AVR_OLD.
1449 (ELF_MACHINE_ALT1): Define to EM_AVR_OLD.
1450 * elf-d10v.c (ELF_MACHINE_CODE): Redefine to EM_D10V.
1451 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D10V.
1452 * elf-d30v.c (ELF_MACHINE_CODE): Redefine to EM_D30V.
1453 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_D30V.
1454 * elf-fr30.c (ELF_MACHINE_CODE): Redefine to EM_FR30.
1455 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_FR30.
1456 * elf-m32r.c (ELF_MACHINE_CODE): Redefine to EM_M32R.
1457 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_M32R.
1458 * elf32-pj.c (ELF_MACHINE_ALT1): DEfine to EM_PJ_OLD.
1459 * elf-v850.c (ELF_MACHINE_CODE): Redefine to EM_V850.
1460 (ELF_MACHINE_ALT1): Define to EM_CYGNUS_V850.
1461
1462 2001-09-11 Richard Henderson <rth@redhat.com>
1463
1464 * elf64-alpha.c (elf64_alpha_section_flags): New.
1465 (elf64_alpha_fake_sections): Map SEC_SMALL_DATA to SHF_ALPHA_GPREL.
1466
1467 2001-09-11 Richard Henderson <rth@redhat.com>
1468
1469 * elf64-alpha.c (elf64_alpha_relocate_section): Do not
1470 apply HINT relocations against dynamic symbols.
1471
1472 2001-09-11 H.J. Lu <hjl@gnu.org>
1473
1474 * linker.c (link_action): Change COMMON_ROW\defw from CREF to COM.
1475
1476 2001-09-09 Richard Henderson <rth@redhat.com>
1477
1478 * elf64-alpha.c: Delete all unused ERIC_neverdef and rth_notdef code.
1479
1480 * elf64-alpha.c (elf64_alpha_relax_with_lituse): Nop out gpdisp
1481 following a call to a near function.
1482
1483 2001-09-08 Richard Henderson <rth@redhat.com>
1484
1485 * elf64-alpha.c (elf64_alpha_relocate_section): Soft fail
1486 relocation errors. Fail gp-relative relocations against
1487 dynamic symbols.
1488
1489 2001-09-08 Alan Modra <amodra@bigpond.net.au>
1490
1491 * elf32-i386.c (elf_i386_relocate_section): Check !DEF_REGULAR
1492 as well as DEF_DYNAMIC in test for avoided copy relocs.
1493 (allocate_plt_and_got_and_discard_relocs): Likewise.
1494 * elf32-hppa.c (elf_i386_relocate_section): Likewise.
1495 (allocate_plt_and_got_and_discard_relocs): Likewise.
1496
1497 2001-09-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1498
1499 * elf32-mips.c (mips_elf_calculate_relocation): Fix overflow handling
1500 of R_MIPS_PC16.
1501
1502 2001-09-06 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1503
1504 * elf64-mips.c (mips_elf64_howto_table_rel): Fix relocation HOWTO
1505 definitions.
1506 (mips_elf64_howto_table_rel): Likewise.
1507
1508 2001-09-05 Tom Rix <trix@redhat.com>
1509
1510 * xcofflink.c (bfd_xcoff_import_symbol): Handle import file XMC_XO
1511 and syscall symbols.
1512 (write_global_symbol) : Same.
1513 (bfd_xcoff_export_symbol): Remove unused syscall param.
1514 * libxcoff.h: Change prototype of bfd_xcoff_export symbol and
1515 bfd_xcoff_import_symbol.
1516 * bfd-in.h: Same.
1517 * bfd-in2.h : Regenerate.
1518
1519 2001-09-04 Richard Henderson <rth@redhat.com>
1520
1521 * elf64-alpha.c (SKIP_HOWTO): New.
1522 (elf64_alpha_howto_table): Use it to remove dead ECOFF relocs.
1523 Fix sizes of 16-bit mem format relocs.
1524 (elf64_alpha_reloc_map): Update to match.
1525 (elf64_alpha_relax_with_lituse): Use GPREL16 as appropriate.
1526 (elf64_alpha_relax_without_lituse): Likewise.
1527 (elf64_alpha_check_relocs): Handle GPREL16.
1528 (elf64_alpha_relocate_section): Likewise.
1529 * reloc.c (BFD_RELOC_ALPHA_USER_*): Remove.
1530 (BFD_RELOC_ALPHA_GPREL_HI16, BFD_RELOC_ALPHA_GPREL_LO16): New.
1531 * bfd-in2.h, libbfd.h: Rebuild.
1532
1533 2001-09-04 Jeff Law <law@redhat.com>
1534
1535 * elf32-h8300.c (elf32_h8_relax_section): New function.
1536 (elf32_h8_relax_delete_bytes): Likewise.
1537 (elf32_h8_symbol_address_p): Likewise.
1538 (elf32_h8_get_relocated_section_contents): Likewise.
1539 (bfd_elf32_bfd_relax_section): Define.
1540 (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
1541
1542 * elf32-h8300.c (special): New function.
1543 (h8_elf_howto_table): Use it for SPECIAL_FUNCTION field in
1544 all relocations.
1545 (elf32_h8_final_link_relocate): Treat R_H8_DIR24A8 like 32bit
1546 relocations. Fix problems with the true 24bit reloc R_H8_DIR24R8.
1547 Fix minor problems with 8bit and 16bit PC relative relocations.
1548
1549 2001-09-01 Andreas Jaeger <aj@suse.de>
1550
1551 * vms-tir.c: Add missing prototypes.
1552 * vms-hdr.c: Likewise.
1553 * vms-gsd.c: Likewise.
1554 * vms-misc.c: Likewise.
1555
1556 2001-08-31 H.J. Lu <hjl@gnu.org>
1557
1558 * elf32-mips.c (_bfd_mips_elf_check_relocs): Report filename
1559 with bad relocation.
1560
1561 2001-08-31 Eric Christopher <echristo@redhat.com>
1562 Jason Eckhardt <jle@redhat.com>
1563
1564 * bfd/archures.c: Add mipsisa32 and mipsisa64. Remove mips32,
1565 mips32_4k and mips64.
1566 * bfd/aoutx.h: Remove bfd_mach_mips32, bfd_mach_mips32_4k,
1567 bfd_mach_mips64. Add bfd_mach_mipsisa32, bfd_mach_mipsisa64.
1568 * bfd/cpu-mips.c: Ditto.
1569 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing): Ditto.
1570 * bfd/bfd-in2.h: Regenerate.
1571
1572 2001-08-31 Jakub Jelinek <jakub@redhat.com>
1573
1574 * elf64-alpha.c (elf64_alpha_relocate_section): Duplicate memory
1575 value into R_ALPHA_RELATIVE's addend.
1576 (elf64_alpha_finish_dynamic_symbol): Likewise.
1577
1578 2001-08-31 Nick Clifton <nickc@cambridge.redhat.com>
1579
1580 * elf32-arm.h (elf32_arm_relocate_section): Do not rightshift
1581 recomputed addend during relocatable link if not USE_REL.
1582
1583 * elflink.h (elf_gc_propagate_vtable_entries_used): Fix off-by-one
1584 error.
1585
1586 2001-08-30 H.J. Lu <hjl@gnu.org>
1587
1588 * elf32-mips.c (mips_elf_calculate_relocation): Revert the last
1589 2 changes.
1590 (_bfd_mips_elf_adjust_dynamic_symbol): Allocate dynamic
1591 relocations for weak definitions.
1592
1593 2001-08-30 H.J. Lu <hjl@gnu.org>
1594
1595 * Makefile.am (BFD32_BACKENDS): Add elf32-h8300.lo.
1596 (BFD32_BACKENDS_CFILES): Add elf32-h8300.c.
1597 * Makefile.in: Rebuild.
1598
1599 2001-08-30 H.J. Lu <hjl@gnu.org>
1600
1601 * elf32-mips.c (mips_elf_calculate_relocation): Don't create
1602 dynamic relocation for undefined weak symbols when creating
1603 executables. Check h->root.root.type, instead of h->root.type.
1604
1605 2001-08-29 Joel Sherrill <joel@OARcorp.com>
1606
1607 * config.bfd (i[3456]86-*-rtems*, m68*-*-rtems*): Change
1608 default from coff to elf.
1609
1610 2001-08-29 Jeff Law <law@redhat.com>
1611
1612 * elf32-h8300.c (h8_elf_howto_table): Add new PC relative
1613 relocations.
1614 (h8_reloc_map): Similarly.
1615 (elf32_h8_final_link_relocate): Remove incorrect overflow tests.
1616 Add support for PC relative relocations.
1617
1618 * elf32-h8300.c: Put all prototypes together.
1619 (elf32_h8_info_to_howto): Parameter elf_reloc is used.
1620 (elf32_h8_final_link_relocate): New function for linker.
1621 (elf32_h8_relocate_section): Similarly.
1622 (elf_backend_relocate_section): Define.
1623
1624 * cpu-h8300.c (h8300_scan, compatible): Prototype.
1625 (h8300_scan): Handle architecture:machine encodings typically
1626 found in linker scripts.
1627 * elf.c (prep_headers): Do not try to do H8 machine recognition
1628 here.
1629 * elf32-h8300.c: Add some missing prototypes.
1630 (elf32_h8_mach, elf32_h8_final_write_processing): New functions.
1631 (elf32_h8_object_p): Similarly.
1632
1633 2001-08-29 Tom Rix <trix@redhat.com>
1634
1635 * xcofflink.c (xcoff_link_add_symbols): Fix XTY_LD symbol that
1636 does not follow a XTY_SD.
1637
1638 2001-08-29 Alan Modra <amodra@bigpond.net.au>
1639
1640 * targmatch.sed: Delete case statements.
1641 * config.bfd <powerpc-*-aix* entry>: Select 64 bit xcoff for
1642 aix4.3 and above.
1643
1644 Wed Aug 29 02:27:36 2001 J"orn Rennecke <amylaar@redhat.com>
1645
1646 * Makefile.am (elf32-h8300.lo): New target.
1647 * config.bfd (h8300*-*-elf): New case.
1648 * configure.in (bfd_elf32_h8300_vec): New case.
1649 * elf.c (prep_headers): Add case for bfd_arch_h8300.
1650 * reloc.c (BFD_RELOC_H8_DIR16A8): New relocation.
1651 (BFD_RELOC_H8_DIR16R8, BFD_RELOC_H8_DIR24A8): Likewise.
1652 (BFD_RELOC_H8_DIR24R8, BFD_RELOC_H8_DIR32A16): Likewise.
1653 * targets.c (bfd_target bfd_elf32_h8300_vec): New extern declaration.
1654 * elf32-h8300.c: New file.
1655 * Makefile.in, bfd-in2.h, libbfd.h, configure: Regenerated.
1656
1657 2001-08-28 Nick Clifton <nickc@cambridge.redhat.com>
1658
1659 * sparclynx.c: Add missing prototypes.
1660 * coff-mcore.c: Add missing prototypes.
1661 * elf32-pj.c: Add missing prototypes.
1662 * nlm32-sparc.c: Add missing prototypes.
1663 * oasys.c: Add missing prototypes.
1664 * pdp11.c: Add missing prototypes.
1665 * pe-mips.c: Add missing prototypes.
1666 * riscix.c: Add missing prototypes.
1667
1668 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
1669
1670 * elf32-i386.c: Add missing prototypes.
1671 * elf32-ppc.c: Likewise.
1672 * elf32-sh-lin.c: Likewise.
1673 * elfarm-nabi.c: Likewise.
1674
1675 2001-08-27 Daniel Jacobowitz <drow@mvista.com>
1676
1677 * elf32-i386.c (elf_i386_grok_prstatus): New function.
1678 (elf_i386_grok_psinfo): New function.
1679 (elf_backend_grok_prstatus): Define.
1680 (elf_backend_grok_psinfo): Likewise.
1681 * elf32-ppc.c (ppc_elf_grok_prstatus): New function.
1682 (ppc_elf_grok_psinfo): New function.
1683 (elf_backend_grok_prstatus): Define.
1684 (elf_backend_grok_psinfo): Likewise.
1685 * elf32-sh-lin.c (elf32_shlin_grok_prstatus): New function.
1686 (elf32_shlin_grok_psinfo): New function.
1687 (elf_backend_grok_prstatus): Define.
1688 (elf_backend_grok_psinfo): Likewise.
1689 * elfarm-nabi.c (elf32_arm_nabi_grok_prstatus): New function.
1690 (elf32_arm_nabi_grok_psinfo): New function.
1691 (elf_backend_grok_prstatus): Define.
1692 (elf_backend_grok_psinfo): Likewise.
1693
1694 2001-08-27 H.J. Lu <hjl@gnu.org>
1695
1696 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add more
1697 sanity check.
1698 (mips_elf_calculate_relocation): Create dynamic relocation for
1699 symbols with weak definition or the ELF_LINK_HASH_DEF_REGULAR
1700 bit is not set.
1701
1702 2001-08-27 H.J. Lu <hjl@gnu.org>
1703
1704 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Add prototype.
1705 (_bfd_mips_elf_copy_indirect_symbol): Likewise.
1706 (_bfd_elf32_mips_grok_prstatus): Likewise.
1707 (_bfd_elf32_mips_grok_psinfo): Likewise.
1708 (_bfd_mips_elf_hide_symbol): Make it static and cast to
1709 `struct mips_elf_link_hash_entry *'.
1710 (_bfd_mips_elf_copy_indirect_symbol): Make it static.
1711
1712 2001-08-27 Nick Clifton <nickc@cambridge.redhat.com>
1713
1714 * mipsbsd.c: Add missing prototypes.
1715 * hp300hpux.c: Add missing prototypes.
1716 * i386aout.c: Add missing prototypes.
1717 * i386lynx.c: Add missing prototypes.
1718 * i386mach3.c: Add missing prototypes.
1719 * i386msdos.c: Add missing prototypes.
1720 * i386os9k.c: Add missing prototypes.
1721
1722 2001-08-27 Linus Nordberg <linus@swox.se>
1723 Torbjorn Granlund <tege@swox.com>
1724 Staffan Ulfberg <staffanu@swox.se>
1725 Alan Modra <amodra@bigpond.net.au>
1726
1727 * config.bfd: Add powerpc64 target. Add powerpc64 vectors to
1728 targ64_selvecs for 32 bit powerpc targets.
1729 * Makefile.am (BFD64_BACKENDS): Add elf64-ppc.lo.
1730 (BFD64_BACKENDS_CFILES): Add elf64-ppc.c.
1731 Run "make dep-am".
1732 * Makefile.in: Regenerate.
1733 * configure.in: Add elf64_powerpc vecs.
1734 * configure: Regenerate.
1735 * cpu-powerpc.c: Default to bfd_mach_ppc_620 entry for 64 bit.
1736 * elf.c (prep_headers): EM_PPC64 for 64 bit ppc elf target.
1737 * targets.c: Add bfd_elf64_powerpc_vec and bfd_elf64_powerpcle_vec.
1738 * elf64-ppc.c: New file.
1739 * reloc.c: Add powerpc64 relocs.
1740 * libbfd.h: Regenerate.
1741 * bfd-in2.h: Regenerate.
1742
1743 2001-08-27 Andreas Schwab <schwab@suse.de>
1744
1745 * elf32-m68k.c (elf32_m68k_check_relocs): Set DF_TEXTREL if the
1746 reloc is against read-only section.
1747 (elf32_m68k_size_dynamic_sections): Use DF_TEXTREL flag instead of
1748 looking up section names for DT_TEXTREL.
1749 (elf32_m68k_reloc_type_class): New function.
1750 (elf_backend_reloc_type_class): Define.
1751
1752 2001-08-27 Andreas Jaeger <aj@suse.de>
1753
1754 * elf64-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
1755 reloc is against read-only section.
1756 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
1757 looking up section names for DT_TEXTREL.
1758 (elf_s390_reloc_type_class): New.
1759 (elf_backend_reloc_type_class): Define.
1760
1761 * elf32-s390.c (elf_s390_check_relocs): Set DF_TEXTREL if the
1762 reloc is against read-only section.
1763 (elf_s390_size_dynamic_sections): Use DF_TEXTREL flag instead of
1764 looking up section names for DT_TEXTREL.
1765 (elf_s390_reloc_type_class): New.
1766 (elf_backend_reloc_type_class): Define.
1767
1768 * elf32-ppc.c (ppc_elf_check_relocs): Set DF_TEXTREL if the reloc
1769 is against read-only section.
1770 (ppc_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1771 looking up section names for DT_TEXTREL.
1772 (ppc_elf_reloc_type_class): New.
1773 (elf_backend_reloc_type_class): Define.
1774
1775 2001-08-26 Andreas Jaeger <aj@suse.de>
1776
1777 * elf32-cris.c (cris_elf_check_relocs): Set DF_TEXTREL if the
1778 reloc is against read-only section.
1779 (elf_cris_size_dynamic_sections): Use DF_TEXTREL flag instead of
1780 looking up section names for DT_TEXTREL.
1781 (elf_cris_reloc_type_class): New.
1782 (elf_backend_reloc_type_class): Define.
1783
1784 * elf32-sh.c (sh_elf_check_relocs): Set DF_TEXTREL if the reloc is
1785 against read-only section.
1786 (elf_backend_reloc_type_class): Define.
1787 (sh_elf_reloc_type_class): New.
1788 (sh_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1789 looking up section names for DT_TEXTREL.
1790
1791 * elf32-arm.h (elf32_arm_check_relocs): Set DF_TEXTREL if the
1792 reloc is against read-only section.
1793 (elf32_arm_size_dynamic_sections): Use DF_TEXTREL flag instead of
1794 looking up section names for DT_TEXTREL.
1795 (elf32_arm_reloc_type_class): New.
1796 (elf_backend_reloc_type_class): Define.
1797
1798 2001-08-25 Andreas Jaeger <aj@suse.de>
1799
1800 * oasys.c: Add missing prototypes.
1801
1802 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Add unused
1803 attribute for parameter.
1804 * elf.c (_bfd_elf_reloc_type_class): Likewise.
1805
1806 * versados.c (get_4): Make static.
1807 (get_10): Make static.
1808 Add missing prototypes.
1809 (process_esd): Fix call to versados_new_symbol.
1810
1811 2001-08-25 Nick Clifton <nickc@cambridge.redhat.com>
1812
1813 * coff-a29k.c: Add missing prototypes.
1814 * coff-apollo.c: Add missing prototypes.
1815 * coff-arm.c: Add missing prototypes.
1816 * coff-i860.c: Add missing prototypes.
1817 * coff-rs6000.c: Add missing prototypes.
1818 * coff-tic80.c: Add missing prototypes.
1819 * elf-m10200.c: Add missing prototypes.
1820 * elf-m10300.c: Add missing prototypes.
1821 * elf32-arm.h: Add missing prototypes.
1822 * elf32-d10v.c: Add missing prototypes.
1823 * elf32-m32r.c: Add missing prototypes.
1824 * elf32-mcore.c: Add missing prototypes.
1825 * elf32-openrisc.c: Add missing prototypes.
1826 * elf32-sh.c: Add missing prototypes.
1827 * elf32-sparc.c: Add missing prototypes.
1828 * elf32-v850.c: Add missing prototypes.
1829 * elfarm-nabi.c: Add missing prototypes.
1830 * elfarm-oabi.c: Add missing prototypes.
1831
1832 2001-08-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1833
1834 * elf32-mips.c (elf_mips_abi_name): Return the right ABI string for
1835 E_MIPS_ABI_O64 and E_MIPS_ABI_EABI64
1836
1837 2001-08-24 H.J. Lu <hjl@gnu.org>
1838
1839 * elf.c (_bfd_elf_merge_sections): Fail if not using an ELF
1840 hash structure.
1841
1842 2001-08-24 Nick Clifton <nickc@cambridge.redhat.com>
1843
1844 * elf-bfd.h (elf_hash_table): Revert definition.
1845 (is_elf_hash_table): New macro.
1846 * elflink.h (elf_link_add_object_symbols): Test
1847 is_elf_hash_table before accessing ELF only fields in hash
1848 structure.
1849 (elf_link_create_dynamic_sections): Fail if not using an ELF
1850 hash structure.
1851 (elf_add_dynamic_entry): Fail if not using an ELF hash
1852 structure.
1853 (elf_link_record_local_dynamic_symbol): Fail if not using an
1854 ELF hash structure.
1855 (size_dynamic_sections): Fail if not using an ELF hash
1856 structure.
1857 (elf_adjust_dynamic_symbol): Fail if not using an ELF
1858 hash structure.
1859 (elf_bfd_final_link): Fail if not using an ELF hash
1860 structure.
1861
1862 2001-08-24 H.J. Lu <hjl@gnu.org>
1863
1864 * elf-bfd.h (elf_hash_table): Return NULL if the linker hash
1865 table is not an ELF linker hash table.
1866
1867 * elf.c (_bfd_elf_link_hash_table_init): Set the linker hash
1868 table type to bfd_link_elf_hash_table.
1869
1870 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Revert
1871 the last change.
1872
1873 * linker.c (_bfd_link_hash_table_init): Set the linker hash
1874 table type to bfd_link_generic_hash_table.
1875
1876 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
1877
1878 * bfd.c (bfd_alt_mach_code): New function.
1879 * bfd-in2.h: Rebuilt.
1880
1881 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
1882
1883 * elf-m10300.c (mn10300_elf_relocate_section): Test the right
1884 `type' field in the hash entry when deciding whether to follow a
1885 link.
1886
1887 2001-08-24 Jakub Jelinek <jakub@redhat.com>
1888
1889 * elflink.h (elf_link_sort_cmp1): Sort RELATIVE relocs first, not
1890 last.
1891 (elf_link_sort_relocs): Adjust accordingly.
1892
1893 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Add reltext flag.
1894 (elf64_alpha_check_relocs): Set it if section this reloc is against
1895 is read-only. Set DF_TEXTREL if a RELATIVE reloc is needed against
1896 read-only section.
1897 (elf64_alpha_calc_dynrel_sizes): Set DF_TEXTREL flag if relocation
1898 is is against read-only section.
1899 (elf64_alpha_size_dynamic_sections): Use DF_TEXTREL flag, don't
1900 check section names.
1901 (elf64_alpha_reloc_type_class): New.
1902 (elf_backend_reloc_type_class): Define.
1903
1904 2001-08-24 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
1905
1906 * linker.c (_bfd_generic_link_add_archive_symbols): Replace alloca()
1907 by bfd_malloc().
1908
1909 2001-08-23 Andreas Jaeger <aj@suse.de>
1910
1911 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set DF_TEXTREL if
1912 the reloc is against read-only section.
1913 (elf64_x86_64_size_dynamic_sections): Use DF_TEXTREL flag instead
1914 of looking up section names for DT_TEXTREL.
1915 (elf64_x86_64_reloc_type_class): New.
1916 (elf_backend_reloc_type_class): Define.
1917
1918 2001-08-23 H.J. Lu <hjl@gnu.org>
1919
1920 * syms.c (bfd_print_symbol_vandf): Add abfd to arg.
1921 * bfd-in2.h (bfd_print_symbol_vandf): Regenerated.
1922
1923 * aoutx.h (NAME(aout,print_symbol)): Pass abfd to
1924 bfd_print_symbol_vandf.
1925 * coffgen.c (coff_print_symbol): Likewise.
1926 * elf.c (bfd_elf_print_symbol): Likewise.
1927 * ieee.c (ieee_print_symbol): Likewise.
1928 * nlmcode.h (nlm_print_symbol): Likewise.
1929 * oasys.c (oasys_print_symbol): Likewise.
1930 * pdp11.c (NAME(aout,print_symbol)): Likewise.
1931 * som.c (som_print_symbol): Likewise.
1932 * srec.c (srec_print_symbol): Likewise.
1933 * tekhex.c (tekhex_print_symbol): Likewise.
1934 * versados.c (versados_print_symbol): Likewise.
1935 * vms.c (vms_print_symbol): Likewise.
1936
1937 * elf.c (_bfd_elf_print_private_bfd_data): Replace fprintf_vma
1938 with bfd_fprintf_vma.
1939 (bfd_elf_print_symbol): Likewise.
1940 * syms.c (bfd_print_symbol_vandf): Likewise.
1941
1942 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
1943
1944 * aoutf1.h (sunos_write_object_contents): Silence compile time
1945 warning.
1946 * libaout.h (N_SET_DYNAMIC): Silence compile time warning.
1947
1948 * bout.c: Add missing function prototypes. Fix formatting.
1949 * coff-z8k.c: Add missing function prototypes. Fix formatting.
1950 * coff-w65.c: Add missing function prototypes. Fix formatting.
1951 * coff-h8500.c: Add missing function prototypes. Fix formatting.
1952 * coff-h8300.c: Add missing function prototypes. Fix formatting.
1953 * coff-tic54x.c: Add missing function prototypes. Fix formatting.
1954 * coff-tic30.c: Add missing function prototypes. Fix formatting.
1955 * coff-m68k.c: Add missing function prototypes. Fix formatting.
1956 * coff-rs6000.c: Add missing function prototypes. Fix formatting.
1957 * coff-sh.c: Add missing function prototypes. Fix formatting.
1958
1959 2001-08-23 Jakub Jelinek <jakub@redhat.com>
1960
1961 * elf-bfd.h (enum elf_reloc_type_class): New.
1962 (struct elf_backend_data): Add elf_backend_reloc_type_class.
1963 (_bfd_elf_reloc_type_class): New.
1964 * elfxx-target.h (elf_backend_reloc_type_class): Define.
1965 (elfNN_bed): Add elf_backend_reloc_type_class.
1966 * elf.c (_bfd_elf_reloc_type_class): New.
1967 * elf32-i386.c (elf_i386_check_relocs): Set DF_TEXTREL if the reloc
1968 is against read-only section.
1969 (elf_i386_size_dynamic_sections): Use DF_TEXTREL flag instead of
1970 looking up section names for DT_TEXTREL.
1971 (elf_i386_reloc_type_class): New.
1972 (elf_backend_reloc_type_class): Define.
1973 * elf32-sparc.c (elf32_sparc_check_relocs): Set DF_TEXTREL if the
1974 reloc is against read-only section.
1975 (elf32_sparc_size_dynamic_sections): Use DF_TEXTREL flag instead of
1976 looking up section names for DT_TEXTREL.
1977 (elf32_sparc_reloc_type_class): New.
1978 (elf_backend_reloc_type_class): Define.
1979 * elf64-sparc.c (sparc64_elf_check_relocs): Set DF_TEXTREL if the
1980 reloc is against read-only section.
1981 (sparc64_elf_size_dynamic_sections): Use DF_TEXTREL flag instead of
1982 looking up section names for DT_TEXTREL.
1983 (sparc64_elf_reloc_type_class): New.
1984 (elf_backend_reloc_type_class): Define.
1985 * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add reltext field.
1986 (elfNN_ia64_hash_table_create): Clear ia64_info.
1987 (get_reloc_section): Set DF_TEXTREL if the reloc is against read-only
1988 section.
1989 (elfNN_ia64_size_dynamic_sections): Use ia64_info->reltext flag
1990 instead of looking up section names for DT_TEXTREL.
1991 (elfNN_ia64_reloc_type_class): New.
1992 (elf_backend_reloc_type_class): Define.
1993 * elflink.h (size_dynamic_sections): Add spare DT_NULL tags.
1994 (struct elf_link_sort_rela): New.
1995 (elf_link_sort_cmp1, elf_link_sort_cmp2, elf_link_sort_relocs): New.
1996 (elf_bfd_final_link): Call elf_link_sort_relocs.
1997 Convert one spare DT_NULL into DT_RELCOUNT resp. DT_RELACOUNT if
1998 necessary.
1999
2000 2001-08-23 Nick Clifton <nickc@cambridge.redhat.com>
2001
2002 * configure.in (x86-bsdi): No corefile support.
2003 * configure: Regenerate.
2004
2005 2001-08-22 Nick Clifton <nickc@cambridge.redhat.com>
2006
2007 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add missing
2008 comma.
2009
2010 2001-08-21 Mark Elbrecht <snowball3@bigfoot.com>
2011
2012 * coff-go32.c: Make DWARF2 sections use an alignment of 0. Set
2013 the alignment of dwarf2 linkonce sections to 0.
2014 * coff-sto32.c: Likewise.
2015
2016 2001-08-20 Andreas Jaeger <aj@suse.de>
2017
2018 * coff-sparc.c: Add missing prototypes.
2019 * elf32-s390.c: Likewise.
2020 * elf32-i960.c: Likewise.
2021 * aout-target.h: Likewise.
2022
2023 2001-08-20 H.J. Lu <hjl@gnu.org>
2024
2025 * elf-bfd.h (elf_obj_tdata): Add num_section_syms.
2026 (elf_num_section_syms): New for num_section_syms.
2027
2028 * elf.c (elf_map_symbols): Set num_section_syms.
2029 (_bfd_elf_symbol_from_bfd_symbol): Check num_section_syms for
2030 the section symbol index.
2031
2032 2001-08-20 Nick Clifton <nickc@cambridge.redhat.com>
2033
2034 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_create): Never
2035 select the generic has table creator. All elf backends need elf
2036 specific fields in the hash table.
2037
2038 2001-08-20 Alan Modra <amodra@bigpond.net.au>
2039
2040 * archive.c (offsetof): Remove define.
2041 * elf.c: Likewise.
2042 * oasys.c: Likewise
2043 * sysdep.h (offsetof): Define.
2044
2045 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2046
2047 * bfd.c (bfd_get_gp_size): Return an unsigned int.
2048 (bfd_set_gp_size): Make param unsigned.
2049 * bfd-in2.h: Regenerate.
2050 * elf32-ppc.c (ppc_elf_add_symbol_hook): Use elf_gp_size rather
2051 than calling bfd_get_gp_size.
2052 * elf64-alpha.c (elf64_alpha_add_symbol_hook): Likewise.
2053 * elfxx-ia64.c (elfNN_ia64_add_symbol_hook): Likewise.
2054
2055 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2056
2057 * linker.c (default_fill_link_order): Handle four byte fill value.
2058
2059 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2060
2061 * elf64-sparc.c (sparc64_elf_output_arch_syms): Add missing
2062 prototype.
2063 * nlm32-alpha.c (nlm_alpha_write_external): Fix warning.
2064
2065 * elf64-mips.c (UNUSED_RELOC): Define.
2066 (mips_elf64_howto_table_rel): Use it.
2067 (mips_elf64_howto_table_rela): Here too.
2068 (mips_elf64_write_relocs): Fix signed/unsigned warning.
2069
2070 * coffcode.h (coff_write_object_contents): Add ATTRIBUTE_UNUSED to
2071 silence warning.
2072 * coffgen.c (coff_print_symbol): Fix warnings.
2073 (coff_find_nearest_line): Likewise.
2074 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
2075 * coff-alpha.c (alpha_convert_external_reloc): Likewise.
2076 * format.c (bfd_check_format_matches): Likewise.
2077 (bfd_set_format): Likewise.
2078 * coff-ia64.c: Add missing prototypes.
2079 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Make addend
2080 signed to silence warnings.
2081 (elf64_alpha_relocate_section): Likewise.
2082 (elf64_alpha_find_reloc_at_ofs): Fix warnings.
2083 (elf64_alpha_add_symbol_hook): Likewise.
2084 (elf64_alpha_final_link): Likewise.
2085 (elf64_alpha_relax_section): Remove redundant assign to info.gotent.
2086 (elf64_alpha_merge_gots): Add ATTRIBUTE_UNUSED to unused args.
2087 (elf64_alpha_size_got_sections): Likewise.
2088 * elfxx-ia64.c: Add missing prototypes.
2089 (elfNN_ia64_relocate_section): Fix warning.
2090 (elfNN_ia64_unwind_entry_compare): Make params const.
2091
2092 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2093
2094 * config.bfd (targ64_selvecs): New.
2095 <powerpc-*-aix* entry>: Use it here instead of ineffectual #ifdef.
2096
2097 * bfd-in.h (BFD_VERSION): Remove wrong comment.
2098 (BFD_DEFAULT_TARGET_SIZE): New.
2099 (BFD_ARCH_SIZE): Comment.
2100 * configure.in (target_size): New. Set instead of target64 in
2101 selvecs case statement. Set target64 from it.
2102 (bfd_default_target_size): New. Set from taget_size. AC_SUBST.
2103 * bfd-in2.h: Regenerate.
2104 * configure: Regenerate.
2105
2106 2001-08-17 Alan Modra <amodra@bigpond.net.au>
2107
2108 * bfd.c (enum bfd_error): Add bfd_error_wrong_object_format.
2109 (bfd_errmsgs): Add corresponding message.
2110 * archive.c (bfd_generic_archive_p): Don't release bfd_ardata when
2111 finding an archive that contains different format object files.
2112 Return bfd_error_wrong_object_format for this case.
2113 * format.c: Formatting fixes. s/CONST/const/.
2114 (bfd_check_format_matches): Accept archives that give
2115 bfd_error_wrong_object_format if no full match is found. Tidy
2116 code handling matching_vector. Don't return a pointer to freed
2117 memory in `matching'. Handle ambiguous matches as for partial
2118 archive matches.
2119 * bfd-in2.h: Regenerate.
2120
2121 2001-08-15 Alan Modra <amodra@bigpond.net.au>
2122
2123 * libieee.h (common_header_type): Add last_byte field.
2124
2125 * ieee.c: Add missing prototypes. Some format fixes.
2126 (struct output_buffer_struct): Move for availability to prototypes.
2127 (ieee_part_after): New function.
2128 (ieee_slurp_debug): Use it here.
2129 (ieee_seek): Pass in ieee_data_struct rather than bfd. Use
2130 ieee_part_after to set last_byte to one past end of current part.
2131 Update callers.
2132 (ieee_pos): Pass in ieee_data_struct rather than bfd.
2133 Update callers.
2134 (parse_expression): Don't go beyond the end of the current part.
2135 (ieee_slurp_external_symbols): Correct type passed to read_2bytes.
2136 (ieee_get_symtab_upper_bound, ieee_get_symtab,
2137 ieee_get_symbol_info, ieee_print_symbol, ieee_new_section_hook,
2138 ieee_get_reloc_upper_bound, ieee_canonicalize_reloc, block,
2139 ieee_set_section_contents, ieee_write_object_contents,
2140 ieee_make_empty_symbol): Make static.
2141 (ieee_archive_p): Correct comments regarding bfd_read.
2142 (ieee_object_p): Similarly.
2143 (ieee_mkobject): Move it. Clear output_ptr_start, output_ptr,
2144 output_ptr_end, input_ptr_start, input_ptr, input_ptr_end,
2145 input_bfd, output_bfd, output_buffer.
2146 (do_as_repeat): Write out ieee_set_current_pc_enum value as for
2147 do_with_relocs, ie. as a symbol for relocatable files.
2148 (ieee_vec): Add comments showing functions referenced by macros.
2149
2150 2001-08-14 Nick Clifton <nickc@cambridge.redhat.com>
2151
2152 * aout-tic30.c: Add missing prototypes. Fix formatting.
2153 * aout-ns32k.c: Add missing prototypes. Fix formatting.
2154 * peXXigen.c: Add missining prototypes. Fix formatting.
2155 * aout-adobe.c: Add missining prototypes. Fix formatting.
2156
2157 2001-08-13 Nick Clifton <nickc@cambridge.redhat.com>
2158
2159 * elf32-v850.c: Add missing function prototypes.
2160 Fix some formatting.
2161
2162 * cpu-v850.c: Add missing function prototype.
2163 Fix some formatting.
2164
2165 2001-08-11 Nick Clifton <nickc@cambridge.redhat.com>
2166
2167 * elf-bfd.h (struct elf_backend_data): Add new fields
2168 'elf_backend_sprintf_vma' and 'elf_backend_fprintf_vma'.
2169 (bfd_elf_sprintf_vma): Rename function prototype to
2170 '_bfd_elf_sprintf_vma'.
2171 (bfd_elf_fprintf_vma): Rename function prototype to
2172 '_bfd_elf_fprintf_vma'.
2173 * bfd.c (bfd_sprintf_vma): Do not invoke bfd_elf_sprintf_vma
2174 directly, instead indirect via the elf_backend_data structure.
2175 (bfd_fprintf_vma): Do not invoke bfd_elf_fprintf_vma directly,
2176 instead indirect via the elf_backend_data structure.
2177 * elf.c (bfd_elf_sprintf_vma): Rename to _bfd_elf_sprintf_vma.
2178 (bfd_elf_fprintf_vma): Rename to _bfd_elf_fprintf_vma.
2179 * elfxx-target.h (elf_backend_sprintf_vma): Initialise if not
2180 already defined.
2181 (elf_backend_fprintf_vma): Initialise if not already defined.
2182 (struct elf_backend_data): Initialise the
2183 elf_backend_sprintf_vma and elf_backend_fprintf_vma fields.
2184
2185 2001-08-10 Andreas Jaeger <aj@suse.de>
2186
2187 * elf64-sparc.c: Add missing prototypes.
2188 * elf32-cris.c: Likewise.
2189 * elf32-i370.c: Likewise.
2190 * elf64-hppa.c: Likewise.
2191 * elf64-s390.c: Likewise.
2192
2193 2001-08-10 Andreas Jaeger <aj@suse.de>
2194
2195 * elf64-x86-64.c (elf64_x86_64_elf_object_p): Make static.
2196 Add prototypes where needed.
2197
2198 2001-08-10 H.J. Lu <hjl@gnu.org>
2199
2200 * bfd.c (bfd_sprintf_vma): Fix a typo in the last change.
2201 (bfd_fprintf_vma): Likewise.
2202
2203 2001-08-10 H.J. Lu <hjl@gnu.org>
2204
2205 * bfd.c (bfd_sprintf_vma): Don't return void.
2206 (bfd_fprintf_vma): Likewise.
2207
2208 2001-08-10 Andreas Jaeger <aj@suse.de>
2209
2210 * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
2211 to build warnings.
2212 * configure: Regenerate.
2213
2214 2001-08-10 Alan Modra <amodra@bigpond.net.au>
2215
2216 * elf.c (bfd_elf_sprintf_vma): Add ATTRIBUTE_UNUSED to quiet
2217 warning if not BFD64. Add braces so emacs auto format works.
2218 (bfd_elf_fprintf_vma): Likewise.
2219
2220 * libxcoff.h (struct xcoff_backend_data_rec): Constify src param
2221 of _xcoff_swap_ld*.
2222 * coff-rs6000.c (xcoff_swap_ldhdr_in): Modify type of external
2223 param to agree with libxcoff.h.
2224 (xcoff_swap_ldhdr_out): Likewise.
2225 (xcoff_swap_ldsym_in): Likewise.
2226 (xcoff_swap_ldsym_out): Likewise.
2227 (xcoff_swap_ldrel_in): Likewise.
2228 (xcoff_swap_ldrel_out): Likewise.
2229 (xcoff_create_csect_from_smclas): Likewise.
2230 * coff64-rs6000.c: Add missing prototypes.
2231 (xcoff64_swap_ldhdr_in): Modify type of external param to agree
2232 with libxcoff.h.
2233 (xcoff64_swap_ldhdr_out): Likewise.
2234 (xcoff64_swap_ldsym_in): Likewise.
2235 (xcoff64_swap_ldsym_out): Likewise.
2236 (xcoff64_swap_ldrel_in): Likewise.
2237 (xcoff64_swap_ldrel_out): Likewise.
2238 (xcoff64_ppc_relocate_section): Make static.
2239 (xcoff64_slurp_armap): Likewise.
2240 (xcoff64_archive_p): Likewise.
2241 (xcoff64_openr_next_archived_file): Likewise.
2242 (xcoff64_sizeof_headers): Likewise.
2243 (xcoff64_is_lineno_count_overflow): Likewise.
2244 (xcoff64_is_reloc_count_overflow): Likewise.
2245 (xcoff64_loader_symbol_offset): Likewise.
2246 (xcoff64_loader_reloc_offset): Likewise.
2247 * elf64-gen.c: Add missing prototypes.
2248
2249 2001-08-09 H.J. Lu <hjl@gnu.org>
2250
2251 * elf.c (bfd_elf_sprintf_vma): Check ELFCLASS64 only in BFD64.
2252 (bfd_elf_fprintf_vma): Likewise.
2253
2254 2001-08-09 H.J. Lu <hjl@gnu.org>
2255
2256 * bfd-in.h (bfd_elf_sprintf_vma, bfd_elf_fprintf_vma): Moved
2257 to ...
2258 * elf-bfd.h: Here.
2259 * bfd-in2.h: Regenerated.
2260
2261 2001-08-09 H.J. Lu <hjl@gnu.org>
2262
2263 * bfd-in.h (bfd_sprintf_vma): New prototype.
2264 (bfd_fprintf_vma): Likewise.
2265 (bfd_elf_sprintf_vma): Likewise.
2266 (bfd_elf_fprintf_vma): Likewise.
2267 (bfd_printf_vma): New. Defined with bfd_fprintf_vma.
2268 * bfd-in2.h: Regenerated.
2269
2270 * bfd.c (bfd_sprintf_vma): New. Defined.
2271 (bfd_fprintf_vma): Likewise.
2272
2273 * elf.c (bfd_elf_sprintf_vma): New. Defined.
2274 (bfd_elf_fprintf_vma): Likewise.
2275
2276 2001-08-09 Alan Modra <amodra@bigpond.net.au>
2277
2278 * coff-rs6000.c: Add missing prototypes.
2279 (xcoff_ppc_relocate_section, xcoff_is_lineno_count_overflow,
2280 xcoff_is_reloc_count_overflow, xcoff_loader_symbol_offset,
2281 xcoff_loader_reloc_offset): Make static.
2282 * dwarf1.c: Add missing prototypes.
2283 * dwarf2.c: Add missing prototypes.
2284 (struct abbrev_info): Move definition.
2285 (struct attr_abbrev, ABBREV_HASH_SIZE, ATTR_ALLOC_CHUNK): Likewise.
2286 * elf.c: Add missing prototypes.
2287 * elf32-gen.c: Likewise.
2288 * elf32-i386.c: Likewise.
2289 * elf32-ppc.c: Likewise.
2290 (ppc_elf_sort_rela): Use PTR instead of "void *".
2291 * elflink.h: Add missing prototypes. Formatting fixes.
2292 * merge.c: Add missing prototypes.
2293 (last4_eq): Use PTR instead of "void *".
2294 (last_eq): Likewise.
2295 * syms.c: Add missing prototypes.
2296
2297 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2298
2299 * bfd.c: Fix formatting.
2300 * bfd-in2.h: Regenerate.
2301
2302 2001-08-09 Nick Clifton <nickc@cambridge.redhat.com>
2303
2304 * elf32-arc.c (R_ARC_B22_PCREL): Change 'partial_inplace' to
2305 true (this target uses REL relocations) and 'pcrel_offset' to
2306 false (the PC is implied, not stored in the offset).
2307
2308 2001-08-08 Alan Modra <amodra@bigpond.net.au>
2309
2310 1999-10-19 Linus Nordberg <linus@swox.se>
2311 * elf-bfd.h (struct elf_backend_data): Add want_got_sym.
2312 * elfxx-target.h (elf_backend_want_got_sym): Define.
2313 (elfNN_bed): Add elf_backend_want_got_sym.
2314 * elflink.c (_bfd_elf_create_got_section): Define
2315 _GLOBAL_OFFSET_TABLE_ only if bed->want_got_sym.
2316
2317 2001-08-08 Alexandre Oliva <aoliva@redhat.com>
2318
2319 * dwarf2.c (struct dwarf2_debug): Add sec, sec_info_ptr and syms.
2320 (find_rela_addend): New function.
2321 (parse_comp_unit): Call it to find the abbrev offset addend.
2322 (_bfd_dwarf2_find_nearest_line): Initialize and maintain the new
2323 members of dwarf2_debug as debugging information is read.
2324
2325 2001-08-07 Nick Clifton <nickc@cambridge.redhat.com>
2326
2327 * coff-sh.c (sh_coff_reloc_type_lookup): Provide for sh-coff
2328 targets as well as sh-pe.
2329
2330 2001-08-03 Ben Harris <bjh21@netbsd.org>
2331
2332 * elf32-arm.h (elf32_arm_final_link_relocate): Include offset of
2333 reloc from start of section when computing value for R_ARM_REL32
2334 reloc.
2335
2336 2001-08-03 Alan Modra <amodra@bigpond.net.au>
2337
2338 From H.J. Lu <hjl@gnu.org>
2339 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Don't
2340 keep relocs for undefined syms if there are no dynamic sections in
2341 executable.
2342 * elf32-hppa.c (allocate_plt_and_got_and_discard_relocs): Likewise.
2343
2344 2001-08-02 Paul Sokolovsky <paul.sokolovsky@technologist.com>
2345
2346 * cofflink.c (coff_link_check_ar_symbols): also search for
2347 __imp__symbol as well as _symbol.
2348 * linker.c (_bfd_generic_link_add_archive_symbols): also
2349 search for __imp__symbol as well as _symbol.
2350
2351 2001-08-01 Adam Nemet <anemet@lnxw.com>
2352
2353 * elf.c (elf_sort_sections): Return zero only as the last step.
2354
2355 2001-08-01 Nick Clifton <nickc@cambridge.redhat.com>
2356
2357 * config.bfd (arm-vxworks): Change name of define from VXWORKS to
2358 ARM_COFF_BUGFIX.
2359 (arm-epoc-pe): Define ARM_COFF_BUGFIX.
2360 coff-arm.c (coff_arm_relocate_section): Replace VXWORKS with
2361 ARM_COFF_BUGFIX.
2362
2363 2001-07-30 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
2364
2365 * libecoff.h (_bfd_ecoff_styp_to_sec_flags): Changed return type
2366 to match corresponding bfd_coff_backend data member.
2367
2368 2001-07-24 Alan Modra <amodra@bigpond.net.au>
2369
2370 * Makefile.am: Update dependencies with "make dep-am".
2371 * Makefile.in: Regenerate
2372
2373 2001-07-15 H.J. Lu <hjl@gnu.org>
2374
2375 * Makefile.am (po/SRC-POTFILES.in): Use tmp.src instead of tmp.
2376 (po/BLD-POTFILES.in): Use tmp.bld instead of tmp.
2377 * Makefile.in: Regenerate.
2378
2379 2001-07-11 H.J. Lu <hjl@gnu.org>
2380
2381 * elf64-alpha.c (elf64_alpha_check_relocs): Set the ALLOC|LOAD
2382 flags when creating the reloc section if the ALLOC flag in the
2383 source section is set.
2384
2385 2001-07-11 Steve Ellcey <sje@cup.hp.com>
2386
2387 * reloc.c (bfd_reloc_code_type): Add IA64 relocs
2388 BFD_RELOC_IA64_LTOFF_FPTR32MSB and BFD_RELOC_IA64_LTOFF_FPTR32LSB
2389 * bfd-in2.h: Regenerate.
2390 * libbfd.h: Regenerate.
2391 * elfxx-ia64.c (ia64_howto_table): Define how to handle
2392 new relocations.
2393 (elfNN_ia64_reloc_type_lookup): Handle new relocations.
2394 (elfNN_ia64_check_relocs): Likewise.
2395 (elfNN_ia64_install_value): Likewise.
2396 (elfNN_ia64_relocate_section): Likewise.
2397
2398 2001-07-11 Jakub Jelinek <jakub@redhat.com>
2399
2400 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Remove support for
2401 R_SPARC_UA64.
2402 (elf32_sparc_check_relocs): Likewise.
2403 Only create .rela section for alloced sections in shared libraries.
2404 (elf32_sparc_relocate_section): Likewise.
2405 Remove redundant check.
2406 Optimize unaligned reloc usage.
2407 * elf64-sparc.c (sparc64_elf_relocate_section): Remove redundant
2408 check.
2409
2410 2001-07-11 H.J. Lu <hjl@gnu.org>
2411
2412 * elf64-alpha.c (elf64_alpha_check_relocs): Only use the same
2413 ALLOC|LOAD flags as the source section for debugging sections
2414 when creating the reloc section.
2415
2416 2001-07-05 Jim Wilson <wilson@redhat.com>
2417
2418 * linker.c (_bfd_generic_link_add_one_symbol, case BIG): Use
2419 the section of the bigger symbol.
2420
2421 * syms.c (bfd_is_local_label): Return false if BSF_SECTION_SYM.
2422
2423 2001-07-05 Nick Clifton <nickc@cambridge.redhat.com>
2424
2425 * peicode.h (coff_swap_scnhdr_in): For sections containing
2426 uninitialised data, only set their size to s_paddr if this does
2427 not reset their size to zero. MS's latest compilers will set
2428 s_paddr to zero.
2429
2430 2001-07-04 H.J. Lu <hjl@gnu.org>
2431
2432 * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing):
2433 Handle bfd_mach_mips4400, bfd_mach_mips4600 and
2434 bfd_mach_mips5000.
2435
2436 2001-07-03 Mark Elbrecht <snowball3@softhome.net>
2437
2438 * bfd.c (bfd_get_sign_extend_vma): Support DJGPP COFF targets.
2439
2440 * cofflink.c (_bfd_coff_link_input_bfd): Skip section symbols from
2441 sections being discarded.
2442
2443 2001-06-30 Alan Modra <amodra@bigpond.net.au>
2444
2445 * elfcore.h (elf_core_file_p): Call bfd_section_from_phdr directly
2446 instead of _bfd_elfcore_section_from_phdr.
2447 * elf-bfd.h (_bfd_elfcore_section_from_phdr): Remove.
2448 * elf.c (_bfd_elfcore_section_from_phdr): Remove.
2449 (_bfd_elfcore_make_pseudosection): Expedite tail-call.
2450 (elfcore_grok_prstatus): Likewise.
2451 (elfcore_grok_lwpstatus): Likewise.
2452 (bfd_get_elf_phdr_upper_bound): Likewise.
2453 (elfcore_make_note_pseudosection): Formatting.
2454 (_bfd_elfcore_strndup): Formatting.
2455 * elf32-mips.c (mips_elf_sym_is_global): Formatting.
2456 (_bfd_elf32_mips_grok_prstatus): Expedite tail-call.
2457
2458 2001-06-29 Daniel Jacobowitz <drow@mvista.com>
2459
2460 * elf-bfd.h: Add prototypes for _bfd_elfcore_make_pseudosection
2461 and _bfd_elfcore_strndup.
2462 (struct elf_backend_data): Add elf_backend_grok_prstatus
2463 and elf_backend_grok_psinfo.
2464 * elf.c (_bfd_elfcore_make_pseudosection): New function.
2465 (elfcore_grok_prstatus): Use it.
2466 (elfcore_make_note_pseudosection): Likewise.
2467 (elfcore_strndup): Rename to...
2468 (_bfd_elfcore_strndup): Here, and make global.
2469 (elfcore_grok_psinfo): Use _bfd_elfcore_strndup.
2470 (elfcore_grok_note): Call elf_backend_grok_prstatus
2471 and elf_backend_grok_psinfo if available.
2472 * elf32-mips.c (_bfd_elf32_mips_grok_prstatus): New function.
2473 (_bfd_elf32_mips_grok_psinfo): New function.
2474 (elf_backend_grok_prstatus): Define.
2475 (elf_backend_grok_psinfo): Define.
2476 * elfxx-target.h (elf_backend_grok_prstatus): Default to NULL.
2477 (elf_backend_grok_psinfo): Likewise.
2478 (elfNN_bed): Include elf_backend_grok_prstatus and
2479 elf_backend_grok_psinfo.
2480
2481 2001-06-29 H.J. Lu <hjl@gnu.org>
2482
2483 * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Check if
2484 hplink->sgot is NULL before filling GOT. Check if hplink->splt
2485 is NULL before filling PLT.
2486
2487 2001-06-29 Alan Modra <amodra@bigpond.net.au>
2488
2489 * elflink.h (elf_link_output_extsym): Revert 1999-04-10.
2490
2491 2001-06-27 Alan Modra <amodra@bigpond.net.au>
2492
2493 * elf32-hppa.c (elf32_hppa_check_relocs): Don't make syms dynamic
2494 here..
2495 (elf32_hppa_adjust_dynamic_symbol): ..nor here..
2496 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2497 after gc has run.
2498
2499 * elf32-hppa.c (RELATIVE_DYNAMIC_RELOCS): Delete.
2500 (IS_ABSOLUTE_RELOC): Define.
2501 (elf32_hppa_link_hash_entry): Always include reloc_entries field.
2502 (hppa_link_hash_newfunc): Always init it.
2503 (elf32_hppa_check_relocs): Mark symbols as ELF_LINK_NON_GOT_REF to
2504 create COPY relocs only when the reloc is in a read-only section.
2505 Instead, allocate space for a dynamic reloc to reference the
2506 library symbol directly. Keep track of space we allocate using
2507 relocs_entries.
2508 (hppa_discard_copies): Delete, and move code to..
2509 (allocate_plt_and_got): ..here. Rename to
2510 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2511 relocs for non-shared link.
2512 (elf32_hppa_size_dynamic_sections): Update calls to above.
2513 (elf32_hppa_relocate_section): Write out the dynamic relocs used
2514 in lieu of COPY relocs.
2515
2516 * elf32-i386.c (elf_i386_check_relocs): Don't make syms dynamic
2517 here..
2518 (elf_i386_adjust_dynamic_symbol): ..nor here..
2519 (allocate_plt_and_got_and_discard_relocs): .. instead do so here
2520 after gc has run.
2521 (elf_i386_size_dynamic_sections): Fix a comment.
2522 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Rearrange code
2523 involved in writing reloc out.
2524
2525 2001-06-25 Alan Modra <amodra@bigpond.net.au>
2526
2527 * elf32-i386.c (elf_i386_check_relocs <R_386_32, R_386_PC32>):
2528 Ensure syms are dynamic if we might be emitting a reloc.
2529 (allocate_plt_and_got_and_discard_relocs): Don't discard relocs
2530 for undefweak or undefined syms..
2531 (elf_i386_relocate_section <R_386_32, R_386_PC32>): .. and emit.
2532
2533 * elf32-i386.c (allocate_plt_and_got_and_discard_relocs): Discard
2534 relocs without ELF_LINK_HASH_DEF_DYNAMIC set.
2535 (elf_i386_relocate_section <R_386_32, R_386_PC32>): Remove
2536 redundant bfd_link_hash_defined, bfd_link_hash_defweak test.
2537
2538 2001-06-24 H.J. Lu <hjl@gnu.org>
2539
2540 * cpu-i960.c (scan_960_mach): Don't modify const char *. Use
2541 strncasecmp/strcasecmp instead of strncmp/strcmp.
2542
2543 2001-06-23 H.J. Lu <hjl@gnu.org>
2544
2545 * elf32-i386.c (elf_i386_relocate_section <R_386_32, R_386_PC32>):
2546 Check ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined
2547 in the regular object file and treat the weak definition as
2548 the normal one.
2549
2550 2001-06-23 Alan Modra <amodra@bigpond.net.au>
2551
2552 * elf32-i386.c (elf_i386_relocate_section <R_386_GOT32>): Tighten
2553 unresolved_reloc test to exclude cases where we use "relocation"
2554 before setting it to point into the .got. Reinstate fudge for
2555 unresolved relocs in debugging sections.
2556
2557 * elf32-i386.c (elf_i386_relocate_section): Replace ugly
2558 complicated tests for unresolvable relocs with a simple direct
2559 scheme using "unresolved_reloc" var.
2560
2561 * elf32-i386.c (struct elf_i386_pcrel_relocs_copied): Rename to
2562 elf_i386_dyn_relocs. Update comment.
2563 (struct elf_i386_link_hash_entry): Rename pcrel_relocs_copied to
2564 dyn_relocs.
2565 (elf_i386_adjust_dynamic_symbol): Remove a BFD_ASSERT, change
2566 others to aborts.
2567 (allocate_plt_and_got_and_discard_relocs): Replace BFD_ASSERT with
2568 abort.
2569 (elf_i386_size_dynamic_sections): Likewise.
2570 (elf_i386_finish_dynamic_symbol): Likewise.
2571 (elf_i386_finish_dynamic_sections): Likewise.
2572 (elf_i386_relocate_section): Likewise. Tidy R_386_GOT32 and error
2573 handling code.
2574
2575 Avoid creating COPY relocs if possible.
2576 * elf32-i386.c (elf_i386_check_relocs): Tweak condition under
2577 which .got created. Mark symbols used by R_386_32 and R_386_PC32
2578 relocs as ELF_LINK_NON_GOT_REF to create COPY relocs only when the
2579 reloc is in a read-only section. Instead, allocate space for a
2580 dynamic reloc to reference the library symbol directly. Keep
2581 track of space we allocate using pcrel_relocs_copied.
2582 (discard_copies): Delete, and move code to ..
2583 (allocate_plt_and_got): ..here. Rename to
2584 allocate_plt_and_got_and_discard_relocs. Remove unneeded dynamic
2585 relocs for non-shared link.
2586 (elf_i386_size_dynamic_sections): Update calls to above functions.
2587 (elf_i386_relocate_section): Write out the dynamic relocs. Add
2588 more ugly logic to avoid "unresolvable relocation" error. Use
2589 htab shortcut in place of elf_hash_table macro.
2590 (elf_i386_finish_dynamic_sections): Allow that dynamic .got may
2591 not always be created now.
2592
2593 2001-06-20 Bo Thorsen <bo@suse.co.uk>
2594
2595 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix linking of
2596 shared libraries.
2597
2598 2001-06-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2599
2600 * configure.host (mips64-*-linux): Reformat.
2601
2602 2001-06-21 Alan Modra <amodra@bigpond.net.au>
2603
2604 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Always
2605 allocate local .got space. Use shortcuts from hash table for .got
2606 and .plt rather than comparing section names.
2607 (elf32_hppa_check_relocs): Use local_plt_refcounts var rather than
2608 adjusting index into local_got_refcounts to document what we are
2609 really doing.
2610 (elf32_hppa_relocate_section): Similarly for local_plt_offsets.
2611 Tidy .got and .plt error checking.
2612
2613 2001-06-20 Catherine Moore <clm@redhat.com>
2614
2615 * elf-bfd.h (struct elf_backend_data):
2616 elf_backend_emit_relocs: New field: Function for emitting
2617 relocs.
2618 elf_backend_count_relocs: New field: Function for determining
2619 the number of relocs to be emitted.
2620 * elfxx-target.h: Provide default (NULL) values for
2621 elf_backend_emit_relocs and elf_backend_count_relocs.
2622 * elflink.h (elf_link_size_reloc_section): Make the hash table
2623 big enough to hold the relocs counted by either reloc_count or
2624 o->reloc_count.
2625 (elf_bfd_final_link) emit_relocs: New boolean, set if relocs
2626 should be emitted, either because of a command line option
2627 stored in the info structure or because the target provides a
2628 special reloc emitting function.
2629 If the target provides a reloc counting function use it,
2630 unless performing a relocatable link or emitting all relocs.
2631 Also set the SEC_RELOC flag on any output section which will
2632 contain relocs.
2633 (elf_link_input_bfd): emit_relocs: New boolean, set if relocs
2634 should be emitted, either because of a command line option
2635 stored in the info structure or because the target provides a
2636 special reloc emitting function.
2637 If the target provides a reloc emitting function, use it,
2638 unless performing a relocatable link or emitting all relocs.
2639
2640 2001-06-20 H.J. Lu <hjl@gnu.org>
2641
2642 * elf32-i386.c (elf_i386_size_dynamic_sections): Always
2643 allocate local .got space.
2644
2645 2001-06-19 Andreas Jaeger <aj@suse.de>
2646
2647 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix creation of
2648 dynamic symbols.
2649
2650 2001-06-18 Hans-Peter Nilsson <hp@axis.com>
2651
2652 * elflink.h (struct elf_assign_sym_version_info): Remove member
2653 export_dynamic. All users changed to use info member.
2654 NAME(bfd_elf,size_dynamic_sections)): Remove parameter
2655 export_dynamic, instead use member in parameter info.
2656 * bfd-in.h (bfd_elf32_size_dynamic_sections,
2657 bfd_elf64_size_dynamic_sections): Update prototype.
2658 * bfd-in2.h: Regenerate.
2659
2660 2001-06-18 H.J. Lu <hjl@gnu.org>
2661
2662 * elflink.h (elf_info_failed): Add a new field, verdefs.
2663 (NAME(bfd_elf,size_dynamic_sections): Pass verdefs to
2664 elf_export_symbol.
2665 (elf_export_symbol): Check eif->verdefs to decide if a symbol
2666 should be exported.
2667
2668 2001-06-17 H.J. Lu <hjl@gnu.org>
2669
2670 * elf32-mips.c (mips_elf_link_hash_entry): Add a new field,
2671 readonly_reloc, to record if a relocation in the .rel.dyn
2672 section is against a read-only section.
2673 (mips_elf_link_hash_newfunc): Initialize the readonly_reloc
2674 field to false.
2675 (_bfd_mips_elf_check_relocs): Record if there is a relocation
2676 in the .rel.dyn section against a read-only section by setting
2677 DF_TEXTREL or readonly_reloc.
2678 (_bfd_mips_elf_copy_indirect_symbol): Copy readonly_reloc if
2679 it is true.
2680 (_bfd_mips_elf_adjust_dynamic_symbol): Record DF_TEXTREL if
2681 there is a relocation in the .rel.dyn section against a
2682 read-only section.
2683 (_bfd_mips_elf_size_dynamic_sections): Set DT_TEXTREL if
2684 DF_TEXTREL is set.
2685
2686 2001-06-12 Nick Clifton <nickc@cambridge.redhat.com>
2687
2688 * coffcode.h (styp_flags_to_sec_flags): Change to a boolean
2689 function. Move flagword result into parameter list. Remove
2690 comment about setting bfd_error_handler to intercept failure
2691 results.
2692 * coffgen.c (make_a_section_from_file): Examine result of
2693 calling bfd_coff_styp_to_sec_flags and pass a failure back to
2694 caller.
2695 * ecoff.h (styp_flags_to_sec_flags): Change to a boolean
2696 function. Move flagword result into parameter list.
2697 * libcoff.h: Regenerate.
2698 * libecoff.h: Regenerate.
2699
2700 2001-06-13 Nick Clifton <nickc@cambridge.redhat.com>
2701
2702 * aoutx.h (adjust_z_magic): Only pad the tesxt section if the data
2703 section is going to follow it.
2704
2705 2001-06-12 Catherine Moore <clm@redhat.com>
2706
2707 * elflink.h (elf_gc_propagate_vtable_entries): Replace FILE_ALIGN
2708 with the file_align entry from elf_backend_data.
2709 (elf_gc_smash_unused_vtentry_relocs): Likewise.
2710 (elf_gc_record_vtentry): Likewise.
2711
2712 2001-06-10 Alan Modra <amodra@bigpond.net.au>
2713
2714 * elflink.h: Whitespace changes.
2715 (elf_link_read_relocs_from_section): Use "unsigned int" iterator
2716 rather than "unsigned char".
2717 (elf_link_output_relocs): Likewise.
2718 (elf_link_input_bfd): Likewise.
2719 (elf_reloc_link_order): LIkewise.
2720 * elf.c: s/CONST/const/. Whitespace changes.
2721 * elf32-mips.c: Formatting fix.
2722
2723 * Makefile.am (SOURCE_HFILES): Include xcoff-target.h, remove xcoff.h.
2724 * Makefile.in: Regenerate.
2725 * po/Make-in: Remove trailing tab.
2726
2727 2001-06-09 Philip Blundell <philb@gnu.org>
2728
2729 * elf32-arm.h (elf32_arm_plt0_entry): Correct error in last
2730 change.
2731 (elf32_arm_plt_entry): Likewise.
2732
2733 2001-06-08 H.J. Lu <hjl@gnu.org>
2734
2735 * elf.c (swap_out_syms): Keep names for global section symbols.
2736
2737 2001-06-07 H.J. Lu <hjl@gnu.org>
2738
2739 * config.bfd: Put back ecoff for Linux/mips. Firmwares on some
2740 MIPS-based machines need it.
2741
2742 2001-06-07 H.J. Lu <hjl@gnu.org>
2743
2744 * elf32-mips.c (_bfd_mips_elf_object_p): Set the bad symtab
2745 for SGI only.
2746
2747 * config.bfd: Remove ecoff from Linux/mips.
2748
2749 2001-06-07 Andreas Jaeger <aj@suse.de>
2750
2751 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Add an
2752 assertion.
2753 (elf64_x86_64_check_relocs): Fix VTENTRY relocation; set an
2754 alignment of 8 for .rela sections; handle further relocations.
2755
2756 2001-06-06 Christian Groessler <cpg@aladdin.de>
2757
2758 * coff-z8k.c: Fix formatting.
2759 Fix howtos: howto->size was always 1.
2760
2761 2001-06-05 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2762
2763 * configure.host (mips64*-*-linux*): Define.
2764
2765 2001-06-05 Alan Modra <amodra@bigpond.net.au>
2766
2767 * elf32-i386.c (elf_i386_discard_copies): Rename to
2768 discard_copies, and use elf_link_hash_entry arg rather than
2769 elf_i386_link_hash_entry.
2770 (elf_i386_link_hash_traverse): Delete.
2771 (elf_i386_size_dynamic_sections): Adjust call to discard_copies.
2772 Tidy sizing of dynamic sections.
2773 (elf_i386_check_relocs <R_386_32, R_386_PC32>): Reference count
2774 possible .plt entries.
2775 (elf_i386_gc_sweep_hook): Likewise.
2776 (elf_i386_adjust_dynamic_symbol): Discard .plt entries for
2777 everything with plt.refcount <= 0.
2778
2779 * elf32-i386.c (elf_i386_check_relocs): Don't allocate .got and
2780 .relgot space here.
2781 (elf_i386_gc_sweep_hook): ..and no need to deallocate here..
2782 (elf_i386_adjust_dynamic_symbol): ..and don't allocate .plt and
2783 .rel.plt here..
2784 (allocate_plt_and_got): ..instead do it all here. New function.
2785 (elf_i386_size_dynamic_sections): Allocate local .got space and
2786 call allocate_plt_and_got. No need to zap .relgot if not dynamic.
2787 (bfd_elf32_bfd_final_link): Delete. (ie. use regular final link
2788 rather than gc variety).
2789 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2790 (elf_i386_relocate_section): Use it here and correct handling of
2791 R_386_GOT32. Provide section and offset for "unresolvable
2792 relocation" error message.
2793 (elf_i386_finish_dynamic_symbol): Correct handling of R_386_GOT32.
2794
2795 * elf32-i386.c (struct elf_i386_link_hash_table): Add sgot,
2796 sgotplt, srelgot, splt, srelplt, sdynbss, srelbss fields.
2797 (elf_i386_link_hash_table_create): Init them.
2798 (create_got_section): New function.
2799 (elf_i386_create_dynamic_sections): New function.
2800 (elf_backend_create_dynamic_sections): Set to above.
2801 (elf_i386_check_relocs): Use shortcuts from hash table rather than
2802 calling bfd_get_section_by_name.
2803 (elf_i386_gc_sweep_hook): Likewise.
2804 (elf_i386_adjust_dynamic_symbol): Likewise.
2805 (elf_i386_size_dynamic_sections): Likewise.
2806 (elf_i386_relocate_section): Likewise.
2807 (elf_i386_finish_dynamic_sections): Likewise.
2808
2809 * elf32-hppa.c (allocate_plt_and_got): Skip indirect and warning syms.
2810
2811 2001-06-02 H.J. Lu <hjl@gnu.org>
2812
2813 * elf32-hppa.c (elf32_hppa_object_p): Check ELFOSABI_LINUX
2814 and ELFOSABI_HPUX.
2815 * elf64-hppa.c (elf64_hppa_object_p): Likewise.
2816
2817 2001-06-02 H.J. Lu <hjl@gnu.org>
2818
2819 * aout-cris.c (MACHTYPE_OK): New. Defined.
2820
2821 2001-06-02 Hans-Peter Nilsson <hp@axis.com>
2822
2823 * section.c (_bfd_strip_section_from_output): Handle NULL
2824 output_section.
2825
2826 2001-06-02 H.J. Lu <hjl@gnu.org>
2827
2828 * config.bfd (powerpc-*-aix*, powerpc-*-beos*, rs6000-*-*): Add
2829 rs6000coff64_vec only if BFD64 is defined.
2830 (powerpc64-*-aix*): Enable only if BFD64 is defined.
2831
2832 2001-06-02 H.J. Lu <hjl@gnu.org>
2833
2834 * coff-ia64.c (ia64coff_object_p): Rewrite with
2835 external_PEI_DOS_hdr and external_PEI_IMAGE_hdr.
2836
2837 2001-06-01 Andreas Jaeger <aj@suse.de>
2838
2839 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add PC8
2840 relocation, small reformatting.
2841
2842 2001-05-29 Andreas Jaeger <aj@suse.de>
2843
2844 * elf64-x86-64.c (elf64_x86_64_check_relocs): Handle R_X86_64_64.
2845 (elf64_x86_64_relocate_section): Likewise.
2846
2847 2001-05-30 Alan Modra <amodra@one.net.au>
2848
2849 * elf32-hppa.c (elf32_hppa_check_relocs): Don't NEED_PLT for
2850 millicode. Don't allocate .got and .rela.got space here..
2851 (elf32_hppa_gc_sweep_hook): ..and no need to deallocate here..
2852 (elf32_hppa_adjust_dynamic_symbol): ..and don't allocate .plt and
2853 .rela.plt here..
2854 (hppa_handle_PIC_calls): ..nor here..
2855 (allocate_plt_and_got): ..instead do it all here. New function.
2856 (elf32_hppa_size_dynamic_sections): Allocate local .got space and
2857 call allocate_plt_and_got. No need to zap .got if not dynamic.
2858 (elf32_hppa_final_link): Call regular bfd_final_link instead of
2859 gc_common_final_link.
2860 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
2861 (elf32_hppa_relocate_section): Use it here.
2862 (elf32_hppa_finish_dynamic_symbol): Remove superfluous test of
2863 dynamic_sections_created.
2864 (hppa_type_of_stub): Don't LONG_BRANCH_VIA_PLT if millicode sym.
2865
2866 2001-05-28 Andreas Jaeger <aj@suse.de>
2867
2868 * elf64-x86-64.c (elf64_86_64_size_info): Remove, we can use the
2869 generic version since we want a hashsize of 4.
2870 (elf_backend_size_info): Likewise.
2871
2872 2001-05-28 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2873
2874 * elflink.h (elf_link_size_reloc_section): Use bfd_zmalloc instead of
2875 a zeroing loop.
2876 (elf_link_output_relocs): Handle MIPS ELF64 relocations correctly.
2877 (elf_link_input_bfd): Likewise.
2878 (elf_reloc_link_order): Likewise.
2879 (elf_finish_pointer_linker_section): Typo. Handle MIPS ELF64
2880 relocations correctly.
2881
2882 2001-05-28 Nicolas Pitre <nico@cam.org>
2883
2884 * elf32-arm.h: fix PLT generation for big endian ARM
2885
2886 2001-05-28 Alan Modra <amodra@one.net.au>
2887
2888 * elf32-hppa.c (elf32_hppa_relocate_section): Set up .plt entries
2889 for symbols forced local that need plabels.
2890 (elf32_hppa_adjust_dynamic_symbol): Don't allocate space in
2891 .plt.rela for local syms if non-shared.
2892 (hppa_build_one_stub): Mask lsb of plt.offset.
2893 (elf32_hppa_finish_dynamic_symbol): Abort if lsb of plt.offset set.
2894 (clobber_millicode_symbols): Correct comment.
2895 (elf32_hppa_relocate_section): Likewise.
2896 (elf32_hppa_finish_dynamic_symbol): Likewise.
2897
2898 2001-05-28 Jeff Sturm <jsturm@one-point.com>
2899
2900 * reloc.c: Add BFD_RELOC_SPARC_UA16 and BFD_RELOC_SPARC_UA64.
2901 * bfd-in2.h: Regenerate.
2902 * libbfd.h: Regenerate.
2903 * elf32-sparc.c: Enable BFD_RELOC_SPARC_UA16, BFD_RELOC_SPARC_UA32
2904 and BFD_RELOC_SPARC_UA64 mapping
2905 * elf64-sparc.c: Likewise.
2906
2907 2001-05-25 H.J. Lu <hjl@gnu.org>
2908
2909 * Makefile.am (BFD32_BACKENDS): Remove coff-pmac.lo.
2910 (BFD32_BACKENDS_CFILES): Remove coff-pmac.c.
2911 (coff-rs6000.lo): Remove the old dependency.
2912 * Makefile.in: Rebuild.
2913
2914 * configure.in (pmac_xcoff_vec): Replace coff-pmac.lo with
2915 coff-rs6000.lo.
2916
2917 2001-05-25 H.J. Lu <hjl@gnu.org>
2918
2919 * coff-rs6000.c (rs6000coff_vec): Use rs6000coff_core_p,
2920 rs6000coff_core_file_matches_executable_p,
2921 rs6000coff_core_file_failing_command and
2922 rs6000coff_core_file_failing_signal only if AIX_CORE is
2923 defined.
2924 (pmac_xcoff_vec): Likewise.
2925 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
2926
2927 2001-05-25 Timothy Wall <twall@redhat.com>
2928
2929 * elfxx-ia64.c (allocate_dynrel_entries): Don't allocate an entry
2930 for __GLOB_DATA_PTR on AIX5. Clean up some relocation bugs.
2931
2932 2001-05-25 H.J. Lu <hjl@gnu.org>
2933
2934 * bfd-in2.h: Regenerated.
2935 * libcoff.h: Likewise.
2936
2937 2001-05-25 Alan Modra <amodra@one.net.au>
2938
2939 * elf32-hppa.c (elf32_hppa_relocate_section): Don't allow
2940 undefined millicode syms in shared libs.
2941 (hppa_build_one_stub): Turn BFD_ASSERTs into aborts.
2942 (elf32_hppa_check_relocs): Likewise.
2943 (elf32_hppa_adjust_dynamic_symbol): Likewise.
2944 (elf32_hppa_size_dynamic_sections): Likewise.
2945 (elf32_hppa_relocate_section): Likewise.
2946 (elf32_hppa_finish_dynamic_symbol): Likewise.
2947 (elf32_hppa_finish_dynamic_sections): Likewise.
2948
2949 2001-05-24 Tom Rix <trix@redhat.com>
2950
2951 * Makefile.am coff-pmac bfd now defined in coff-rs6000.c
2952 xcoff-target.h not used to define rs6000 or ppc bfd.
2953 * Makefile.in same
2954
2955 * bfd-in.h : (struct lineno_cache_entry) promote element "offset"
2956 to 64 bit.
2957
2958 * coff-rs6000.c : Many changes for 64 bit support. Move common
2959 32/64 code to xcofflink.c. Explictly define the rs6000coff_vec
2960 and pmac_xcoff_vec
2961
2962 * coff64-rs6000.c : Many changes for 64 bit support. 64 bit
2963 linker now supported. Explictly define the rs6000coff64_vec.
2964
2965 * coffcode.h : (coff_set_arch_mach_hook) xcoff 64 bit support
2966 (coff_print_aux) same
2967 (coff_write_object_contents) same
2968 (coff_slurp_line_table) same
2969
2970 * coffgen.c : (coff_fix_symbol_name) formatting
2971 (coff_mangle_symbols) xcoff 64 bit support
2972 (coff_write_symbol) same
2973 (coff_write_alien_symbol) same
2974 (coff_write_native_symbol) same
2975 (coff_write_symbols) same
2976 (coff_get_symbol_info) same
2977 (bfd_coff_get_syment) same
2978 (coff_print_symbol) same
2979
2980 * config.bfd : add powerpc64-*-aix* target
2981
2982 * libcoff-in.h : formatting
2983
2984 * libcoff.h : move xcoff extern declarations to libxcoff.h
2985
2986 * libxcoff.h : New file
2987
2988 * xcofflink.c : Many changes for xcoff64 support. Move common
2989 structures to include/coff/xcoff.h. Move specific structure to
2990 backends coff-rs6000.c and coff64-rs6000.c. Use new backend
2991 functions, defined in libxcoff.h, to isolate 32/64 dependencies.
2992
2993 (bfd_xcoff_size_dynamic_sections) : special __rtinit symbol for
2994 aix4.2+ -binitfini.
2995
2996 (xcoff_build_ldsyms) : handle special __rtinit symbol.
2997
2998 2001-05-23 Alexandre Oliva <aoliva@redhat.com>
2999
3000 * elf64-sparc.c (sparc64_elf_slurp_reloc_table): Fix typo
3001 s/ENTIRES/ENTRIES/.
3002
3003 2001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3004
3005 * reloc.c (bfd_reloc_code_real): Add MIPS ELF64 relocations.
3006 * libbfd.h: Regenerate.
3007 * bfd-in2.h: Regenerate.
3008
3009 * aoutx.h (aout_@var{size}_machine_type): Add MIPS r12k support.
3010 * archures.c (bfd_mach_mips12000): Define.
3011 * cpu-mips.c (arch_info_struct): Add MIPS r12k support.
3012 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Add MIPS r12k
3013 support.
3014 (_bfd_mips_elf_size_dynamic_sections): Use official bfd typedef.
3015 * bfd-in2.h: Regenerate.
3016 * elfxx-target.h: Do not redefine bfd_elfNN_bfd_make_debug_symbol.
3017
3018 2001-05-23 kaz Kojima <kkojima@rr.iij4u.or.jp>
3019
3020 * elf32-sh.c (elf_sh_plt0_entry_be, elf_sh_plt0_entry,
3021 elf_sh_plt_entry_be, elf_sh_plt_entry, elf_sh_pic_plt_entry_be,
3022 elf_sh_pic_plt_entry): New PLT code, that does not use r2, since
3023 that is used by GCC.
3024
3025 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3026
3027 * elf-bfd.h (NUM_SHDR_ENTRIES): New macro: compute the number
3028 of entries in a structured section.
3029 * elf.c: Use new macro.
3030 * elf32-i386.c: Use new macro.
3031 * elf32-mips.c: Use new macro.
3032 * elf64-alpha.c: Use new macro.
3033 * elf64-sparc.c: Use new macro.
3034 * elfcode.h: Use new macro.
3035 * elflink.h: Use new macro.
3036
3037 2001-05-23 Nick Clifton <nickc@cambridge.redhat.com>
3038
3039 * bfdint.texi: Replace -oformat with --oformat.
3040
3041 2001-05-21 Andreas Jaeger <aj@suse.de>
3042
3043 * dwarf2.c (decode_line_info): Fix error message.
3044 (read_abbrevs): Fix test for offset as suggested by Alan Modra and
3045 adjust error message.
3046
3047 2001-05-18 H.J. Lu <hjl@gnu.org>
3048
3049 * elflink.h (elf_link_add_object_symbols): Revert the last
3050 change.
3051
3052 2001-05-17 Alan Modra <amodra@one.net.au>
3053
3054 * elf32-hppa.c (clobber_millicode_symbols): Temporarily set
3055 ELF_LINK_FORCED_LOCAL to suit 2001-04-30 change.
3056 (hppa_build_one_stub): Add an assert to check plt.offset.
3057
3058 2001-05-17 H.J. Lu <hjl@gnu.org>
3059
3060 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the
3061 version definition to basename of the output filename.
3062
3063 2001-05-17 H.J. Lu <hjl@gnu.org>
3064
3065 * elflink.h (elf_link_add_object_symbols): Set DT_NEEDED to
3066 basename of the bfd filename.
3067
3068 2001-05-16 Alan Modra <amodra@one.net.au>
3069
3070 * section.c (asection): Add linker_has_input field.
3071 (STD_SECTION): Adjust initialization to suit.
3072 * ecoff.c (bfd_debug_section): Likewise.
3073 * bfd-in2.h: Regenerate.
3074
3075 2001-05-15 Alexandre Oliva <aoliva@redhat.com>
3076
3077 * elf-m10300.c (mn10300_elf_relax_section): Don't relax
3078 negative 32-bit operands to 16 operands when the operand is
3079 going to be zero-extended by the modified opcode.
3080
3081 2001-05-12 Peter Targett <peter.targett@arccores.com>
3082
3083 * cpu-arc.c (arch_info_struct): Add entry 'base' representing old
3084 name for 'arc5' core versions.
3085 (bfd_arc_arch): Make bfd_mach_arc_6 default.
3086
3087 * elf32-arc.c (arc_elf_object_p): Make E_ARC_MACH_ARC6 default
3088 architecture.
3089 (arc_elf_final_write_processing): Make bfd_mach_arc_6 default.
3090
3091 2001-05-11 Jakub Jelinek <jakub@redhat.com>
3092
3093 * elfxx-ia64.c (is_unwind_section_name): Consider linkonce unwind
3094 sections as well.
3095 (elfNN_ia64_final_write_processing): Map .gnu.linkonce.ia64unw.FOO
3096 to .gnu.linkonce.t.FOO text section.
3097
3098 2001-05-11 Jakub Jelinek <jakub@redhat.com>
3099
3100 * merge.c (struct sec_merge_hash_entry): Add u.entsize and u.suffix
3101 fields, change sec into secinfo.
3102 (struct sec_merge_info): Add chain, remove last fields.
3103 (struct sec_merge_sec_info): Add next, sec, psecinfo fields.
3104 (sec_merge_hash_lookup): If lookup could not use a string only
3105 because it has bad alignment, mark the old string for deletion.
3106 (sec_merge_add): Add secinfo argument. Don't compute entry's
3107 position, instead record the section.
3108 (sec_merge_emit): Update for the sec into secinfo change in
3109 struct sec_merge_hash_entry.
3110 (_bfd_merge_section): Only record the section for merging, defer
3111 putting strings into the hash table.
3112 (cmplengthentry, last4_eq, last_eq, record_section, merge_strings,
3113 _bfd_merge_sections): New functions.
3114 (_bfd_merged_section_offset): Update for the sec_merge_hash_entry
3115 changes.
3116 * libbfd-in.h (_bfd_merge_sections): Add prototype.
3117 (_bfd_nolink_bfd_merge_sections): Define.
3118 * libbfd.h: Likewise.
3119 (bfd_generic_merge_sections): Add prototype.
3120 * targets.c (BFD_JUMP_TABLE_LINK): Add _bfd_merge_sections.
3121 (struct bfd_target): Likewise.
3122 * bfd.c (bfd_merge_sections): Define.
3123 * bfd-in2.h: Rebuilt.
3124 * elf.c (_bfd_elf_merge_sections): New function.
3125 * elf-bfd.h (_bfd_elf_merge_sections): Add prototype.
3126 * elfxx-target.h (bfd_elfNN_bfd_merge_sections): Define.
3127 * reloc.c (bfd_generic_merge_sections): New function.
3128 * vms.c (vms_bfd_merge_sections): New function.
3129 * aout-adobe.c (aout_32_bfd_merge_sections): Define.
3130 * aout-target.h (MY_bfd_merge_sections): Define.
3131 * aout-tic30.c (MY_bfd_merge_sections): Define.
3132 * binary.c (binary_bfd_merge_sections): Define.
3133 * bout.c (b_out_bfd_merge_sections): Define.
3134 * coff-alpha.c (_bfd_ecoff_bfd_merge_sections): Define.
3135 * coffcode.c (coff_bfd_merge_sections): Define.
3136 * coff-mips.c (_bfd_ecoff_bfd_merge_sections): Define.
3137 * i386msdos.c (msdos_bfd_merge_sections): Define.
3138 * i386os9k.c (os9k_bfd_merge_sections): Define.
3139 * ieee.c (ieee_bfd_merge_sections): Define.
3140 * ihex.c (ihex_bfd_merge_sections): Define.
3141 * nlm-target.h (nlm_bfd_merge_sections): Define.
3142 * oasys.c (oasys_bfd_merge_sections): Define.
3143 * ppcboot.c (ppcboot_bfd_merge_sections): Define.
3144 * som.c (som_bfd_merge_sections): Define.
3145 * srec.c (srec_bfd_merge_sections): Define.
3146 * tekhex.c (tekhex_bfd_merge_sections): Define.
3147 * versados.c (versados_bfd_merge_sections): Define.
3148 * xcoff-target.h (_bfd_xcoff_bfd_merge_sections): Define.
3149
3150 2001-05-11 Nick Clifton <nickc@cambridge.redhat.com>
3151
3152 * dwarf1.c (_bfd_dwarf1_find_nearest_line): Change type of 'addr'
3153 to be unsigned long, in order to match its use.
3154
3155 2001-05-10 H.J. Lu <hjl@gnu.org>
3156
3157 * linker.c (_bfd_generic_link_add_one_symbol): Check loop on
3158 indirect symbols.
3159
3160 2001-05-09 H.J. Lu <hjl@gnu.org>
3161
3162 * elflink.h (elf_link_add_object_symbols): Fix a typo. Allocate
3163 versymhdr->sh_size bytes for extversym instead of hdr->sh_size.
3164 Remove the unused veriable `dynver'.
3165
3166 2001-05-08 Ian Lance Taylor <ian@zembu.com>
3167
3168 * coff-i386.c (coff_i386_reloc): Don't dump core if output_bfd is
3169 NULL or is not COFF.
3170 (coff_i386_rtype_to_howto): Don't dump core if output section
3171 owner is not COFF.
3172
3173 2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
3174
3175 * ecoff.c (bfd_debug_section): Fix initialization.
3176 * elf.c (_bfd_elf_slurp_version_tables): Change maxidx to unsigned, it
3177 is always a positive integer. Cast away sign mismatch.
3178 * elf32-mips.c: Fix misleading comment and typo.
3179 (_bfd_mips_elf_section_from_bfd_section): Remove unused attribute, use
3180 correct data type.
3181 * elflink.c: Fix typo.
3182 (_bfd_elf_create_dynamic_sections): Remove superfluous initialization.
3183 * ecoffswap.h (ecoff_swap_fdr_in): Cast away sign mismatch.
3184
3185 2001-05-04 Richard Henderson <rth@redhat.com>
3186
3187 * elf64-alpha.c (SREL16, SREL32, SREL64): Set pcrel_offset true.
3188
3189 2001-05-04 Nick Clifton <nickc@cambridge.redhat.com>
3190
3191 * elf32-arm.h (elf32_arm_final_link_relocate): Set
3192 EF_ARM_HASENTRY if the start address is set.
3193
3194 2001-05-03 Nick Clifton <nickc@cambridge.redhat.com>
3195
3196 * targets.c (_bfd_target_vector_entries): Compute value based on
3197 the size of the _bfd_target_vector and not bfd_target_vector.
3198
3199 2001-05-03 H.J. Lu <hjl@gnu.org>
3200
3201 * elfcode.h: Include "libiberty.h".
3202
3203 * elflink.h (elf_link_add_object_symbols): Set
3204 elf_dt_name (abfd) to basename of the bfd filename.
3205 (NAME(bfd_elf,size_dynamic_sections)): Set vn_file to basename
3206 of the bfd filename.
3207
3208 2001-05-03 Andreas Jaeger <aj@suse.de>
3209
3210 * elf64-gen.c (elf_generic_info_to_howto): Add unused attribute.
3211 (elf_generic_info_to_howto_rel): Likewise.
3212 * coff-alpha.c (reloc_nil): Likewise.
3213 (alpha_ecoff_bad_format_hook): Likewise.
3214 (alpha_adjust_reloc_out): Likewise.
3215 (alpha_bfd_reloc_type_lookup): Likewise.
3216 (alpha_convert_external_reloc): Likewise.
3217 * elf64-alpha.c (elf64_alpha_reloc_nil): Likewise.
3218 (elf64_alpha_reloc_bad): Likewise.
3219 (elf64_alpha_reloc_gpdisp): Likewise.
3220 (elf64_alpha_bfd_reloc_type_lookup): Likewise.
3221 (elf64_alpha_info_to_howto): Likewise.
3222 (elf64_alpha_add_symbol_hook): Likewise.
3223 (elf64_alpha_create_got_section): Likewise.
3224 (elf64_alpha_is_local_label_name): Likewise.
3225 (elf64_alpha_merge_ind_symbols): Likewise.
3226 * elf64-mips.c (mips_elf64_reloc_type_lookup): Likewise.
3227 (mips_elf64_get_reloc_upper_bound): Likewise.
3228 * nlm32-alpha.c (nlm_alpha_mangle_relocs): Likewise.
3229 (nlm_alpha_get_public_offset): Likewise.
3230
3231 2001-05-02 Johan Rydberg <jrydberg@opencores.org>
3232
3233 * elf32-openrisc.c (openrisc_elf_howto_table): Do not complain
3234 about overflow in R_OPENRISC_LO_16_IN_INSN and
3235 R_OPENRISC_HI_16_IN_INSN.Index: bfd/elf32-openrisc.c
3236
3237 2001-04-30 H.J. Lu <hjl@gnu.org>
3238
3239 * elf.c (_bfd_elf_link_hash_hide_symbol): Set dynindx to -1
3240 only for ELF_LINK_FORCED_LOCAL.
3241 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
3242 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise.
3243 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
3244
3245 * elflink.h (elf_fix_symbol_flags): Set ELF_LINK_FORCED_LOCAL
3246 if the symbol has hidden or internal visibility.
3247
3248 2001-04-30 Alan Modra <amodra@one.net.au>
3249
3250 * elf32-hppa.c (final_link_relocate): Branch to .+8 for
3251 calls to undefined weak symbols.
3252
3253 2001-04-30 Andreas Jaeger <aj@suse.de>, Andreas Schwab <schwab@suse.de>
3254
3255 * elf64-x86-64.c (elf64_x86_64_relocate_section): Correct test for
3256 R_X86_64_GOTPCREL, don't use assignments instead of comparisons.
3257
3258 2001-04-27 Andreas Jaeger <aj@suse.de>
3259
3260 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_sections): Only swap
3261 out handled entries.
3262 (elf64_x86_64_finish_dynamic_symbol): Set up GOT entries.
3263 (elf64_x86_64_relocate_section): Fix GOTPCREL calculation.
3264 (elf64_x86_64_relocate_section): Merge entries for GOTPCREL and
3265 GOT32.
3266
3267 2001-04-27 Sean McNeil <sean@mcneil.com>
3268
3269 * config.bfd: Add arm-vxworks target.
3270 * coff-arm (coff_arm_relocate_section): Add in symbol value to
3271 addend (fro VXworks targets).
3272
3273 2001-04-26 H.J. Lu <hjl@gnu.org>
3274
3275 * elf32-i386.c (elf_i386_check_relocs): Verify if r_symndx is
3276 valid.
3277
3278 2001-04-25 Frank Ch. Eigler <fche@redhat.com>
3279
3280 * bfd-in.h (bfd_cache_close): Declare newly exported function.
3281 * bfd-in2.h: Regenerated.
3282
3283 2001-04-24 Jakub Jelinek <jakub@redhat.com>
3284
3285 * merge.c (struct sec_merge_hash_entry): Add alignment field.
3286 (struct sec_merge_hash): Remove alignment_power.
3287 (sec_merge_hash_newfunc): Clear alignment.
3288 (sec_merge_hash_lookup): Pass alignment as argument.
3289 Use hashp->root.next, not hashp->next to walk the hash chain.
3290 If a string already in the hashtable does not have required
3291 alignment, create a new hashtable entry.
3292 (sec_merge_init): Remove alignment_power argument.
3293 (sec_merge_add): Add alignment argument.
3294 (sec_merge_emit): Alignment is now a per-entity thing, not per
3295 section.
3296 (_bfd_merge_section): Sanity check even non-SEC_STRINGS sections
3297 for proper alignment.
3298 Pass alignment information to sec_merge_add.
3299
3300 2001-04-24 Christian Groessler <cpg@aladdin.de>
3301
3302 * coff-z8k.c (extra_case): added handler for R_DISP7, R_CALLR
3303 and R_REL16 reloc types; accept odd values for R_REL16 type
3304
3305 2001-04-24 Johan Rydberg <jrydberg@opencores.org>
3306
3307 * cpu-openrisc.c: New file.
3308 * elf32-openrisc.c: Likewise.
3309
3310 * Makefile.am (ALL_MACHINES): Add cpu-openrisc.lo.
3311 (ALL_MACHINES_CFILES): Add cpu-openrisc.c.
3312 (BFD32_BACKENDS): Add elf32-openrisc.lo.
3313 (BFD32_BACKENDS_CFILES): Add elf32-openrisc.c.
3314 (cpu-openrisc.lo, elf32-openrisc.lo): New rules.
3315 * Makefile.in: Regenerated.
3316 * config.bfd: (openrisc-*-elf): New target.
3317 * configure.in (bfd_elf32_openrisc_vec): New vector.
3318 * configure: Regenerated.
3319 * libbfd.h: Regenerated.
3320 * bfd-in2.h: Regenerated.
3321 * reloc.c: Add OpenRISC relocations.
3322 * targets.c (bfd_elf32_openrisc_vec): Declare.
3323 (bfd_target_vect): Add bfd_elf32_openrisc_vec.
3324 * archures.c (enum bfd_architecture): Add bfd_arch_openrisc.
3325 (bfd_openrisc_arch): Declare.
3326 (bfd_archures_list): Add bfd_openrisc_arch.
3327 * elf.c (prep_headers): Add bfd_arch_openrisc.
3328
3329 2001-04-23 Bo Thorsen <bo@suse.de>
3330
3331 * elf64-x86-64.c: Add c++ vtable hack.
3332 Small whitespace and comment changes.
3333
3334 2001-04-19 Andreas Jaeger <aj@suse.de>
3335
3336 * elf64-x86-64.c (elf64_x86_64_plt0_entry): Fix instructions.
3337 (elf64_x86_64_plt_entry): Likewise.
3338 (elf64_x86_64_finish_dynamic_sections): Fix PLT0 generation.
3339 (elf64_x86_64_finish_dynamic_symbol): Fix PLT generation.
3340
3341 2001-04-17 Hans-Peter Nilsson <hp@axis.com>
3342
3343 * elf32-cris.c: Tweak comments related to dynamic linking.
3344 (cris_elf_relocate_section): When not creating shared object, fill
3345 in the .got table for any symbol not in the dynamic symbol table.
3346 (elf_cris_finish_dynamic_symbol): When not creating shared object,
3347 only emit a .got.rela reloc if the symbol is in the dynamic symbol
3348 table.
3349 (cris_elf_check_relocs): Use variable r_type in all places rather
3350 than the original expression. Add default case in switch for
3351 reloc types.
3352 (elf_cris_size_dynamic_sections): Iterate over
3353 elf_cris_discard_excess_program_dynamics when not creating shared
3354 library.
3355 (elf_cris_discard_excess_dso_dynamics): Renamed from
3356 elf_cris_discard_copies. Correct typo, s/Rel/Rela/.
3357 (elf_cris_discard_excess_program_dynamics): New.
3358
3359 2001-04-14 Mark Elbrecht <snowball3@bigfoot.com>
3360
3361 * coffcode.h (coff_write_object_contents): Use
3362 bfd_coff_swap_filehdr_out instead of coff_swap_filehdr_out.
3363
3364 2001-04-14 H.J. Lu <hjl@gnu.org>
3365
3366 * bfd-in2.h: Regenerate.
3367
3368 2001-04-14 Jakub Jelinek <jakub@redhat.com>
3369
3370 * section.c (STD_SECTION): Add entsize.
3371
3372 2001-04-13 H.J. Lu <hjl@gnu.org>
3373
3374 * section.c (SEC_MERGE): Define new flag for merging.
3375 (SEC_STRINGS): Likewise.
3376 (entsize): New field.
3377
3378 2001-04-13 Roger Sayle <roger@metaphorics.com>
3379
3380 * coff-i386.c (TARGET_SYM): SEC_READONLY is an applicable section
3381 flag on pe-i386 targets.
3382
3383 2001-04-13 Jakub Jelinek <jakub@redhat.com>
3384
3385 * libbfd-in.h (_bfd_merge_section): New.
3386 (_bfd_write_merged_section): New.
3387 (_bfd_merged_section_offset): New.
3388 * libbfd.h: Rebuilt.
3389 * linker.c (_bfd_generic_link_output_symbols): Handle
3390 discard_sec_merge.
3391 * aoutx.h (aout_link_write_symbols): Likewise.
3392 * pdp11.c (aout_link_write_symbols): Likewise.
3393 * elflink.h (elf_link_add_object_symbols): Call _bfd_merge_section.
3394 (elf_bfd_final_link): Adjust global symbols pointing into SEC_MERGE
3395 sections.
3396 (elf_link_sec_merge_syms): New.
3397 (elf_link_input_bfd): Call _bfd_merged_section_offset
3398 and _bfd_write_merged_section.
3399 Handle discard_sec_merge.
3400 * elf-bfd.h (struct elf_link_hash_table): Add merge_info
3401 field.
3402 (struct bfd_elf_section_data): Likewise.
3403 * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_MERGE and
3404 SEC_STRINGS section flags and entsize from their ELF counterparts.
3405 (_bfd_elf_link_hash_table_init): Initialize merge_info.
3406 (elf_fake_sections): Set SHF_MERGE, SHF_STRINGS and sh_entsize
3407 from their BFD counterparts.
3408 * merge.c: New file.
3409 * Makefile.am: Add strtab.lo.
3410 * Makefile.in: Rebuilt.
3411
3412 2001-04-09 Hans-Peter Nilsson <hp@axis.com>
3413
3414 * elflink.h (elf_fix_symbol_flags): For non-default visibilities,
3415 only hide symbols marked STV_INTERNAL or STV_HIDDEN.
3416
3417 2001-04-05 Steven J. Hill <sjhill@cotw.com>
3418
3419 * config.bfd (mips*el*-*-linux-gnu*): Use traditional little
3420 endian MIPS ELF target.
3421 * config.bfd (mips*-*-linux-gnu*): Use traditional big endian
3422 MIPS ELF target.
3423
3424 * configure.in (bfd_elf64_tradbigmips_vec): New. Traditional
3425 64bit big endian MIPS ELF target.
3426 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3427 endian MIPS ELF target.
3428 * configure: Regenerated.
3429
3430 * elf32-mips.c (IRIX_COMPAT): Handle traditional 64bit and
3431 little endian targets.
3432 (mips_elf_sym_is_global): Handle traditional targets.
3433
3434 * elf64-mips.c (bfd_elf64_tradbigmips_vec): New. Traditional
3435 64bit big endian MIPS ELF target.
3436 (bfd_elf64_tradlittlemips_vec): New. Traditional 64bit little
3437 endian MIPS ELF target.
3438
3439 * targets.c: (_bfd_target_vector): Add bfd_elf64_tradbigmips_vec
3440 and bfd_elf64_tradlittlemips_vec.
3441
3442 2001-04-05 David Mosberger <davidm@hpl.hp.com>
3443
3444 * elf32-i386.c (elf_i386_fake_sections): Treat ".reloc" as an
3445 ordinary "progbits" section.
3446
3447 2001-04-04 Alan Modra <alan@linuxcare.com.au>
3448
3449 * elflink.h (elf_fix_symbol_flags): Call elf_backend_hide_symbol
3450 when -Bsymbolic causes a symbol to no longer need a .plt entry.
3451
3452 2001-04-03 David Mosberger <davidm@hpl.hp.com>
3453
3454 * efi-app-ia32.c (ALIGN_SECTIONS_IN_FILE): Deleted.
3455
3456 2001-03-30 H.J. Lu <hjl@gnu.org>
3457
3458 * efi-app-ia32.c (PEI_TARGET_SUBSYSTEM): Rename from ...
3459 (PEI_DEFAULT_TARGET_SUBSYSTEM): This.
3460
3461 2001-03-26 H.J. Lu <hjl@gnu.org>
3462
3463 * elf32-gen.c (elf32_generic_link_add_symbols): New. Check
3464 if there are any relocations for generic ELF.
3465 (bfd_elf32_bfd_link_add_symbols): Defined to
3466 elf32_generic_link_add_symbols.
3467 * elf64-gen.c (elf64_generic_link_add_symbols): New. Check
3468 if there are any relocations for generic ELF.
3469 (bfd_elf64_bfd_link_add_symbols): Defined to
3470 elf64_generic_link_add_symbols.
3471
3472 2001-03-23 Nick Clifton <nickc@redhat.com>
3473
3474 * Makefile.am (BUILD_CFILES): New variable: List of C source
3475 files created in build directory.
3476 (BUILD_HFILES): New variable: List of header files created in
3477 build directory.
3478 (POTFILES): Delete.
3479 (po/POTFILES.in): Replace rule with empty entry.
3480 (po/SRC-POTFILES.in): New rule: Create a list of source files
3481 in the source directory.
3482 (po/BLD-POTFILES.in): New rule: Create a list of source files
3483 in the build directory.
3484 (MOSTLYCLEAN): Do not delete source files created in build
3485 directory.
3486 * Makefile.in: Regenerate.
3487 * configure.in: Insert SRC-POTFILES.in and BLD-POTFILES.in
3488 into po/Makefile.
3489 * configure: Regenerate.
3490
3491 * po/Make-in: Replace occurrences of POTFILES with SRC-POTFILES
3492 and BLD_POTFILES.
3493 Add .. to the search path when building bfd.pot.
3494 Delete POTFILES when performing distclean.
3495 Add comment describing why distclean is broken in maintainer mode.
3496 * po/POTFILES.in: Delete.
3497 * po/SRC-POTFILES.in: New file.
3498 * po/BLD-POTFILES.in: New file.
3499 * po/bfd.pot: Regenerate.
3500
3501 2001-03-22 Hans-Peter Nilsson <hp@axis.com>
3502
3503 * elf32-cris.c: Shlib and PIC support. PCREL tweaks.
3504 (elf_cris_discard_copies, elf_cris_adjust_gotplt_to_got,
3505 elf_cris_try_fold_plt_to_got, elf_cris_link_hash_newfunc,
3506 elf_cris_link_hash_table_create, elf_cris_adjust_dynamic_symbol,
3507 elf_cris_size_dynamic_sections, elf_cris_finish_dynamic_symbol,
3508 elf_cris_finish_dynamic_sections,elf_cris_hide_symbol): New
3509 functions.
3510 (cris_elf_howto_table) <R_CRIS_8_PCREL, R_CRIS_16_PCREL,
3511 R_CRIS_32_PCREL>: Correct comments. Set pcrel_offset to false.
3512 <R_CRIS_COPY, R_CRIS_GLOB_DAT, R_CRIS_JUMP_SLOT, R_CRIS_RELATIVE,
3513 R_CRIS_16_GOT, R_CRIS_32_GOT, R_CRIS_16_GOTPLT, R_CRIS_32_GOTPLT,
3514 R_CRIS_32_GOTREL, R_CRIS_32_PLT_GOTREL, R_CRIS_32_PLT_PCREL>:
3515 New HOWTO members for new relocs.
3516 (cris_reloc_map): Map new relocs.
3517 (ELF_DYNAMIC_INTERPRETER): Define.
3518 (PLT_ENTRY_SIZE): Define.
3519 (elf_cris_plt0_entry, elf_cris_plt_entry, elf_cris_pic_plt0_entry,
3520 elf_cris_pic_plt_entry): New, PLT templates.
3521 (struct elf_cris_pcrel_relocs_copied, struct
3522 elf_cris_link_hash_entry, struct elf_cris_link_hash_table): New.
3523 (elf_cris_link_hash_traverse, elf_cris_hash_table): Define.
3524 (cris_final_link_relocate): Check that 16-bit GOT relocs have
3525 positive values. Adjust PCREL relocs to be relative to location
3526 after relocation.
3527 (cris_elf_relocate_section): Handle relocations to dynamic
3528 objects. Handle new relocations. Call error handler when seeing
3529 non-PIC relocation for read-only sections while generating shared
3530 object.
3531 (cris_elf_check_relocs): Set reference counts for GOT and PLT
3532 entries.
3533 (bfd_elf32_bfd_link_hash_table_create,
3534 elf_backend_adjust_dynamic_symbol,
3535 elf_backend_size_dynamic_sections,
3536 elf_backend_finish_dynamic_symbol,
3537 elf_backend_finish_dynamic_sections,
3538 elf_backend_create_dynamic_sections, bfd_elf32_bfd_final_link,
3539 elf_backend_hide_symbol, elf_backend_want_got_plt,
3540 elf_backend_plt_readonly, elf_backend_want_plt_sym,
3541 elf_backend_got_header_size, elf_backend_plt_header_size):
3542 Define.
3543
3544 * reloc.c: (BFD_RELOC_CRIS_COPY, BFD_RELOC_CRIS_GLOB_DAT,
3545 BFD_RELOC_CRIS_JUMP_SLOT, BFD_RELOC_CRIS_RELATIVE,
3546 BFD_RELOC_CRIS_32_GOT, BFD_RELOC_CRIS_16_GOT,
3547 BFD_RELOC_CRIS_32_GOTPLT, BFD_RELOC_CRIS_16_GOTPLT,
3548 BFD_RELOC_CRIS_32_GOTREL, BFD_RELOC_CRIS_32_PLT_GOTREL,
3549 BFD_RELOC_CRIS_32_PLT_PCREL): New relocs.
3550 * bfd-in2.h, libbfd.h: Regenerate.
3551
3552 2001-03-21 Diego Novillo <dnovillo@redhat.com>
3553
3554 (_bfd_mips_elf_relocate_section): Give a better error message when
3555 a relocation is not recognized.
3556
3557 2001-03-21 Alan Modra <alan@linuxcare.com.au>
3558
3559 * elf32-hppa.c (elf32_hppa_set_gp): Check sec->output_section
3560 non-NULL before attempting to dereference.
3561
3562 2001-03-20 H.J. Lu <hjl@gnu.org>
3563
3564 * configure.in: Remove the redundent AC_ARG_PROGRAM.
3565 * configure: Rebuild.
3566
3567 2001-03-20 Andreas Schwab <schwab@suse.de>
3568
3569 * elf32-m68k.c (elf_m68k_relocate_section): Don't need the
3570 relocation value when resolving a reference from a debugging
3571 section.
3572
3573 2001-03-16 Scott Thomason <SThomaso@hii.com>
3574
3575 * coff64-rs6000.c (xcoff64_swap_sym_out): Fix syntax errors.
3576 (xcoff64_swap_sym_out): Fix syntax errors.
3577
3578 2001-03-16 Richard Sandiford <rsandifo@redhat.com>
3579
3580 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix warning.
3581
3582 2001-03-15 Alan Modra <alan@linuxcare.com.au>
3583
3584 * elf32-hppa.c (elf32_hppa_link_hash_entry): Add maybe_pic_call.
3585 (hppa_link_hash_newfunc): Init it.
3586 (hppa_type_of_stub): Only use non-PIC to PIC call stub if caller
3587 section appears to be non-PIC.
3588 (final_link_relocate): Likewise.
3589 (elf32_hppa_adjust_dynamic_symbol): Set maybe_pic_call for any
3590 possible candidate function, and set pic_call for those that will
3591 only have a .plt entry for the PIC call stub.
3592 (hppa_handle_PIC_calls): Set maybe_pic_call.
3593
3594 2001-03-12 DJ Delorie <dj@redhat.com>
3595
3596 * elf32-sh.c (sh_elf_relocate_section): Only relocation
3597 R_SH_DIR8WP* relocs if they're against external symbols, else
3598 they're just for relaxing. Validate the reloc values.
3599
3600 2001-03-12 Stefan Geuken <mail@stefan-geuken.de>
3601
3602 * binary.c (bfd_external_binary_architecture): Declare.
3603 (binary_object_p): If bfd_external_binary_architecture is defined,
3604 set the architecture to this string.
3605
3606 2001-03-11 Philip Blundell <philb@gnu.org>
3607
3608 * elf32-arm.h (elf32_arm_finish_dynamic_symbol): Don't make PLT
3609 entries that could serve as a definition for a weak symbol.
3610
3611 2001-03-08 Nick Clifton <nickc@redhat.com>
3612
3613 * Most files: Update copyright notices using Perl script created
3614 by Kevin Buettner <kevinb@redhat.com>.
3615
3616 2001-03-07 Nick Clifton <nickc@redhat.com>
3617
3618 * elf32-arm.h (elf32_arm_final_link_relocate): Conditionalise
3619 prior patch on ! defined OLD_ARM_ABI.
3620
3621 2001-03-07 Andreas Jaeger <aj@suse.de>
3622
3623 * elf64-x86-64.c (elf64_x86_64_relocate_section): Fix handling of
3624 some relocation values.
3625
3626 2001-03-06 Nick Clifton <nickc@redhat.com>
3627
3628 * elf32-arm.h (elf32_arm_final_link_relocate): Clear bit zero
3629 of offset in BLX(1) instruction.
3630 * coff-arm.c (coff_arm_relocate_section): Clear bit zero of
3631 offset in BLX(1) instruction.
3632 Fix formatting.
3633
3634 2001-03-06 Nick Clifton <nickc@redhat.com>
3635
3636 * coff-arm.c (coff_arm_reloc_type_lookup): Add
3637 BFD_RELOC_THUMB_PCREL_BLX.
3638
3639 2001-03-06 Igor Shevlyakov <igor@windriver.com>
3640
3641 * archures.c (bfd_default_scan): Add Coldfire CPUs.
3642 * bfd-in2.h: Regenerate.
3643 * cpu-m68k.c: Add Coldfire CPUs for arch table.
3644 * ieee.c (ieee_write_processor): Set proper id for
3645 Coldfire CPUs.
3646
3647 2001-03-01 D.J. Barrow <djbarrow@de.ibm.com,barrow_dj@yahoo.com>
3648
3649 * configure.in: Add s390 target.
3650 * configure: Regenerate.
3651
3652 2001-02-28 Andreas Jaeger <aj@suse.de>
3653
3654 * elf64-x86-64.c (elf64_x86_64_relocate_section): Add relocation
3655 to addend.
3656
3657 2001-02-28 Philip Blundell <pb@futuretv.com>
3658
3659 * elf32-arm.h: Update mentions of renamed EF_xx constants.
3660 (elf32_arm_print_private_bfd_data): Handle ARM EABI version 2.
3661
3662 2001-02-27 H.J. Lu <hjl@gnu.org>
3663
3664 * aoutx.h (NAME(aout,bfd_free_cached_info)): Return true if
3665 abfd->tdata.aout_data == NULL.
3666
3667 2001-02-27 Alan Modra <alan@linuxcare.com.au>
3668
3669 * elf32-hppa.c: Correct field selector in stub comments.
3670 (clobber_millicode_symbols): Formatting fix.
3671
3672 * configure.in: Bump version to 2.11.90.
3673 * configure: Regenerate.
3674 * Makefile.am (CFILES): Rename to SOURCE_CFILES.
3675 (CFILES): $SOURCE_CFILES + generated C files.
3676 (POTFILES): Include $HFILES not $SOURCE_HFILES.
3677 Run "make dep-am"
3678 * Makefile.in: Regenerate.
3679 * doc/Makefile.in: This too.
3680
3681 2001-02-26 Timothy Wall <twall@cygnus.com>
3682
3683 * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Remove obsolete
3684 comments.
3685
3686 2001-02-26 Nick Clifton <nickc@redhat.com>
3687
3688 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Tidy
3689 up, replacing multiple if statements with a switch.
3690 (handle_COMDAT): New function.
3691
3692 2001-02-26 H.J. Lu <hjl@gnu.org>
3693
3694 * coffcode.h (styp_to_sec_flags) [COFF_WITH_PE version]: Issue
3695 a warning for section flags we do not handle instead of
3696 aborting.
3697
3698 2001-02-26 Andreas Jaeger <aj@suse.de>
3699
3700 * elf64-x86-64.c (x86_64_elf_howto_table): Fix order of entries.
3701
3702 2001-02-22 Timothy Wall <twall@cygnus.com>
3703
3704 * config.bfd (targ_cpu): Add vectors for ia64-*-aix* (aka Monterey).
3705 * configure.in: Add objects for elf64_ia64_aix vectors.
3706 * configure: Regenerated.
3707 * configure.host: Recognize ia64-*-aix*.
3708 * elfxx-ia64.c: Add hooks for ELF64 on AIX5. Define new vectors
3709 for AIX. AIX5 requires most relocations to be dynamic (*all*
3710 binaries are somewhat similar to shared libraries).
3711 * targets.c: Add elf64_ia64_aix vectors.
3712
3713 2001-02-21 David Mosberger <davidm@hpl.hp.com>
3714
3715 * cpu-ia64-opc.c (elf64_ia64_operands}: Fix typo: error string for
3716 C8 said "1" instead of "8". Clarify error string for IMM22:
3717 "signed integer" instead of just "integer".
3718
3719 2001-02-20 Andreas Jaeger <aj@suse.de>
3720
3721 * elf64-x86-64.c (elf64_x86_64_finish_dynamic_symbol): Don't make
3722 PLT entries that could serve as a definition for a weak symbol.
3723
3724 2001-02-19 Jakub Jelinek <jakub@redhat.com>
3725
3726 * elf32-sparc.c (elf32_sparc_finish_dynamic_symbol): Don't make PLT
3727 entries that could serve as a definition for a weak symbol.
3728 * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Likewise.
3729
3730 2001-02-18 David O'Brien <obrien@FreeBSD>
3731
3732 * configure.in: Recognize FreeBSD/arm, FreeBSD/PowerPC, and treat
3733 FreeBSD/i386-CURRENT differently until I can figure out the needed
3734 corefile changes.
3735 * configure: Regenerate.
3736 * config.bfd: Recognize FreeBSD/x86-64, FreeBSD/ia64, FreeBSD/arm,
3737 FreeBSD/PowerPC, and FreeBSD/sparc64.
3738
3739 2001-02-18 lars brinkhoff <lars@nocrew.org>
3740
3741 * Makefile.am: Add PDP-11 a.out target.
3742 * config.bfd: Likewise.
3743 * configure.in: Likewise.
3744 * targets.c: Likewise.
3745 * archures.c: Likewise.
3746 * bfd-in2.h: Likewise. Add PDP-11 relocations.
3747 * libbfd.h: Add PDP-11 relocations.
3748 * reloc.c: Likewise.
3749 * cpu-pdp11.c: New file.
3750 * pdp11.c: New file.
3751
3752 * libaout.h (GET_WORD) [ARCH_SIZE==16]: Define.
3753 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
3754 (GET_SWORD) [ARCH_SIZE==16]: Likewise.
3755 (PUT_WORD) [ARCH_SIZE==16]: Likewise.
3756 (GET_MAGIC): New macro.
3757 (PUT_MAGIC): Likewise.
3758 * aout-target.h (MY(object_p)): Use GET_MAGIC to read magic word.
3759
3760 2001-02-18 Jim Kingdon <jkingdon@engr.sgi.com>
3761
3762 * irix-core.c (irix_core_core_file_p): Set the architecture (GDB
3763 multiarch needs it).
3764
3765 2001-02-18 H.J. Lu <hjl@gnu.org>
3766
3767 * elflink.h (elf_link_input_bfd): Ignore invalid section symbol
3768 index.
3769
3770 2001-02-18 Kazu Hirata <kazu@hxi.com>
3771
3772 * vms-misc.c: Fix formatting.
3773
3774 2001-02-16 Kazu Hirata <kazu@hxi.com>
3775
3776 * vms.c: Fix formatting.
3777
3778 2001-02-14 H.J. Lu <hjl@gnu.org>
3779
3780 * elf.c (elf_find_function): New function.
3781 (_bfd_elf_find_nearest_line): Call elf_find_function () to find
3782 the file name and function name.
3783
3784 2001-02-14 Nick Clifton <nickc@redhat.com>
3785
3786 * ecoff.c (bfd_debug_section): Update to initialise new fields in
3787 asection structure.
3788
3789 * Makefile.am (BFD32_BACKENDS_CFILES): Remove peigen.c
3790 (BFD64_BACKENDS): Add pepigen.c
3791 Add rules to create peigen.c and pepigen.c from peXXigen.c.
3792
3793 * Makefile.in: Regenerate.
3794 * configure: Regenerate.
3795 * po/POTFILES.in: Regenerate.
3796 * po/bfd.pot: Regenerate.
3797
3798 2001-02-14 H.J. Lu <hjl@gnu.org>
3799
3800 * libcoff-in.h (pe_tdata): Add members target_subsystem and
3801 force_minimum_alignment.
3802
3803 2001-02-14 Bo Thorsen <bo@suse.de>
3804
3805 * elf64-x86-64.c: Small formatting fixes and rearrangements of code.
3806 (elf64_86_64_size_info): Struct added to fix a problem
3807 with the hashtable string entries.
3808 (elf64_x86_64_adjust_dynamic_symbol): Add generation of .got.plt.
3809 (elf64_x86_64_size_dynamic_sections): A FIXME removed.
3810 (elf64_x86_64_size_dynamic_sections): Fix a dynamic entry and
3811 remove the FIXME for this.
3812 (elf64_x86_64_adjust_dynamic_symbol): Fix check for unneeded .plt
3813 section. Also removed the FIXME for it.
3814 (x86_64_elf_howto_table): Use bfd_elf_generic_reloc.
3815 (ELF_DYNAMIC_INTERPRETER): Fix the name of the dynamic linker.
3816 (elf64_x86_64_finish_dynamic_sections): Enable .got.plt writing.
3817
3818 2001-02-13 Richard Henderson <rth@redhat.com>
3819
3820 * elfxx-ia64.c (elfNN_ia64_final_link): Set __gp if required
3821 and not user provided.
3822
3823 2001-02-13 Kazu Hirata <kazu@hxi.com>
3824
3825 * vms.c (vms_print_symbol): Remove unreachable code.
3826
3827 * rs6000-core.c: Fix formatting.
3828
3829 2001-02-13 David Mosberger <davidm@hpl.hp.com>
3830
3831 * peicode.h (coff_swap_filehdr_out) [COFF_IMAGE_WITH_PE]: Define
3832 as _bfd_XXi_only_swap_filehdr_out.
3833 (pe_mkobject) [PEI_FORCE_MINIMUM_ALIGNMENT]: Set
3834 pe->force_minimum_alignment to TRUE.
3835 (pe_mkobject) [PEI_TARGET_SUBSYSTEM]: Set pe->target_subsystem to
3836 PEI_TARGET_SUBSYSTEM.
3837 (pe_print_private_bfd_data): Call
3838 _bfd_XX_print_private_bfd_data_common() instead of
3839 _bfd_pe_print_private_bfd_data_common().
3840 (pe_bfd_copy_private_bfd_data): Call
3841 _bfd_XX_bfd_copy_private_bfd_data_common() instead of
3842 _bfd_pe_bfd_copy_private_bfd_data_common().
3843 (coff_bfd_copy_private_section_data): Define as
3844 _bfd_XX_bfd_copy_private_section_data instead of
3845 _bfd_pe_bfd_copy_private_section_data.
3846 (coff_get_symbol_info): Define as _bfd_XX_get_symbol_info instead
3847 of a _bfd_pe_get_symbol_info.
3848
3849 * peigen.c: Delete.
3850
3851 * peXXigen.c: Renamed from peigen.c.
3852 (COFF_WITH_XX): Define this macro (will get expanded into
3853 COFF_WITH_pep or COFF_WITH_pe, depending on whether this is being
3854 compiled as peigen.c or pepigen.c.
3855 [COFF_WITH_pep]: Include "coff/ia64.h" instead of "coff/i386.h" to
3856 define the canonical PEP structures and definitions.
3857 (_bfd_XXi_swap_aouthdr_out): If pe->force_minimum_alignment is in
3858 effect, enforce minimum file and section alignments. If
3859 extra->Subsystem is IMAGE_SUBSYSTEM_UNKNOWN, set it to
3860 pe->target_subsystem (this defaults to IMAGE_SUBSYSTEM_UNKNOWN,
3861 so, by default, this is a no-op).
3862
3863 * libpei.h: Rename COFF_WITH_PEP to COFF_WITH_pep.
3864 (_bfd_XX_bfd_copy_private_bfd_data_common): Add macros to map
3865 _bfd_XXfoo to _bfd_pepfoo if COFF_WIT_PEP is defined and to
3866 _bfd_pefoo if it's not defined. Use these macros to define
3867 coff swap macros.
3868
3869 * libcoff.h (pe_tdata): Add members target_subsystem and
3870 force_minimum_alignment.
3871
3872 * efi-app-ia64.c (COFF_WITH_pep): Rename COFF_WITH_PEP to
3873 COFF_WITH_pep.
3874 (PEI_TARGET_SUBSYSTEM): Rename from PEI_DEFAULT_TARGET_SUBSYSTEM.
3875
3876 * configure.in (bfd_efi_app_ia64_vec): Use pepigen.lo instead of
3877 peigen.lo.
3878
3879 * coff-ia64.c: Rename COFF_WITH_PEP to COFF_WITH_pep.
3880 (AOUTSZ): Rename PEP64AOUTSZ and PEP64AOUTHDR to PEPAOUTSZ and
3881 PEPAOUTHDR.
3882
3883 * Makefile.in (BFD64_BACKENDS): Mention pepigen.lo.
3884 (BFD64_BACKENDS_CFILES): Mention pepigen.c
3885 (peigen.c): Add rule to generate from peXXigen.c.
3886 (pepigen.c): Ditto.
3887 (pepigen.lo): List dependencies for pepigen.lo.
3888
3889 2001-02-13 Alan Modra <alan@linuxcare.com.au>
3890
3891 * elf32-hppa.c (elf32_hppa_set_gp): Handle weak $global$. If
3892 $global$ referenced but not defined, set its value here.
3893
3894 2001-02-09 Bo Thorsen <bo@suse.de>
3895
3896 * elf64-x86-64.c (elf64_x86_64_check_relocs): Set .rela.got section
3897 alignment to 3.
3898 (elf64_x86_64_check_relocs): Write R_X86_64_GOTPCREL GOT entry
3899 and relocation.
3900 (elf64_x86_64_relocate_section): Fix formatting.
3901 (elf64_x86_64_relocate_section): Fix addend for relocation of
3902 R_X86_64_(8|16|32|PC8|PC16|PC32).
3903
3904 2001-02-12 Jan Hubicka <jh@suse.cz>
3905
3906 * elf64-x86-64.c (x86_64_elf_howto): Fix name of R_X86_64_GOTPCREL.
3907
3908 2001-02-11 H.J. Lu <hjl@gnu.org>
3909
3910 * elflink.h (elf_bfd_final_link): Use file_align for SYMTAB
3911 alignment.
3912
3913 2001-02-11 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
3914
3915 * elf32-mips.c (mips_elf_create_dynamic_relocation): Undo patch
3916 from 2000-10-13. Do not add the symbol's value for R_MIPS_REL32
3917 relocations against dynsym symbols.
3918
3919 * elf32-mips.c (elf_mips_howto_table): Fix the comment on
3920 the R_MIPS_26 relocation.
3921 (mips_elf_calculate_relocation): Use (p + 4) instead of p for
3922 the R_MIPS_26 relocation.
3923 (mips_elf_perform_relocation): Fix the comment on the R_MIPS16_26
3924 relocation.
3925 * elf64-mips.c (mips_elf64_howto_table_rel): Fix the comment on
3926 the R_MIPS_26 relocation.
3927 (mips_elf64_howto_table_rela): Likewise.
3928
3929 * elf32-mips.c (struct mips_elf_link_hash_entry): Added no_fn_stub
3930 member to mark symbols that have non-CALL relocations against
3931 them.
3932 (mips_elf_link_hash_newfunc): Initialize no_fn_stub.
3933 (mips_elf_calculate_relocation): Handle R_MIPS_CALL16 like
3934 R_MIPS_GOT16.
3935 (_bfd_mips_elf_check_relocs): Set no_fn_stub for a symbol if a
3936 non-CALL relocation against it is encountered.
3937 (_bfd_mips_elf_copy_indirect_symbol): Merge no_fn_stub as well.
3938 (_bfd_mips_elf_adjust_dynamic_symbol): Only create a stub if
3939 no_fn_stub is not set.
3940
3941 * elf32-mips.c (mips_elf_output_extsym): Get the output section
3942 information from the real symbol for indirect ones.
3943 Check no_fn_stub to find out if a symbol has a function stub
3944 indeed.
3945
3946 2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
3947
3948 * Makefile.am (stamp-lib): ranlib the libbfd.a in the build directory.
3949 * Makefile.in: Regenerate.
3950
3951 2001-02-09 David Mosberger <davidm@hpl.hp.com>
3952
3953 * elfxx-ia64.c (is_unwind_section_name): New function. Returns
3954 true if section name is an unwind table section name.
3955 (elfNN_ia64_additional_program_headers): Count each unwind section
3956 separately.
3957 (elfNN_ia64_modify_segment_map): Install one unwind program header
3958 for each unwind separate section. Note: normally the linker
3959 script merges the unwind sections that go into a single segment,
3960 so this still generates at most one unwind program header per
3961 segment.
3962
3963 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Accept any section
3964 name for SHT_IA_64_UNWIND, not just .IA_64.unwind.
3965 (elfNN_ia64_fake_sections): Mark sections with names that start
3966 with .IA_64.unwind but not with .IA_64.unwind_info as an IA-64
3967 unwind section.
3968
3969 * elfxx-ia64.c (elfNN_ia64_final_write_processing): New function.
3970 Use it to make sh_info in unwind section point to the text section
3971 it applies to.
3972
3973 2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
3974
3975 * Makefile.am: Add linux target for S/390.
3976 * archures.c: Likewise.
3977 * bfd-in2.h: Likewise.
3978 * config.bfd: Likewise.
3979 * configure.in: Likewise.
3980 * elf.c: Likewise.
3981 * libbfd.h: Likewise.
3982 * targets.c: Likewise.
3983 * cpu-s390.c: New file.
3984 * elf32-s390.c: New file.
3985 * elf64-s390.c: New file.
3986
3987 2001-02-09 Nick Clifton <nickc@redhat.com>
3988
3989 * peigen.c (_bfd_pe_get_symbol_info): Suppress addition of
3990 ImageBase. This has already been done by coff_swap_hdr_in.
3991
3992 2001-02-09 Jakub Jelinek <jakub@redhat.com>
3993
3994 * elf64-sparc.c (sparc64_elf_copy_private_bfd_data): New function.
3995
3996 2001-02-09 Jakub Jelinek <jakub@redhat.com>
3997
3998 * elf64-sparc.c (sparc64_elf_check_relocs): Don't trust reloc_count.
3999 (sparc64_elf_relocate_section): Likewise.
4000
4001 2001-02-09 Mark Kettenis <kettenis@gnu.org>
4002
4003 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Treat R_SPARC_UA32
4004 similar to R_SPARC_32.
4005 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
4006
4007 2001-02-08 H.J. Lu <hjl@gnu.org>
4008
4009 * elf32-i386.c (elf_i386_check_relocs): Reserve R_386_PC32
4010 relocation entries for weak definitions when building DSO with
4011 -Bsymbolic.
4012
4013 2001-02-08 Richard Henderson <rth@redhat.com>
4014
4015 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Respect weakness
4016 before visibility. Locally defined protected symbols are not
4017 dynamic.
4018
4019 2001-02-08 Geoffrey Keating <geoffk@redhat.com>
4020
4021 * config.bfd: Enable coff64 for rs6000-*. Patch from
4022 <hzoli@austin.ibm.com>.
4023
4024 2001-02-07 Mark Elbrecht <snowball3@bigfoot.com>
4025
4026 * coffgen.c (coff_find_nearest_line): If stabs info is successfully
4027 found, do not attempt to find dwarf2 info before returning.
4028
4029 2001-02-07 Jakub Jelinek <jakub@redhat.com>
4030
4031 * elflink.h (is_global_symbol_definition): Rename to
4032 is_global_data_symbol_definition and have it reject function
4033 symbols.
4034 (elf_link_is_defined_archive_symbol): Use renamed function.
4035
4036 2001-02-07 Todd Vierling <tv@wasabisystems.com>
4037
4038 * libbfd-in.h (bfd_target_vector): Change extern array to pointer.
4039 * libbfd.h (bfd_target_vector): Likewise.
4040 * targets.c (bfd_target_vector): Rename to _bfd_target_vector and
4041 make static; create pointer reference named bfd_target_vector.
4042 (_bfd_target_vector_entries): Calculate this based on the array
4043 typed _bfd_target_vector.
4044
4045 2001-02-06 H.J. Lu <hjl@gnu.org>
4046
4047 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Only hidden and
4048 internal symbols are not dynamic.
4049 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
4050
4051 2001-02-06 Nick Clifton <nickc@redhat.com>
4052
4053 * Makefile.am (BFD64_BACKENDS_CFILES): Remove elf64-ia64.c, so
4054 that it will not be pulled into the list of files that make up
4055 po/POTFILES.in.
4056 * Makefile.in: Regenerate.
4057 * po/bfd.pot: Regenerate.
4058
4059 2001-02-06 H.J. Lu <hjl@gnu.org>
4060
4061 * peicode.h (coff_swap_filehdr_in): Remove the e_magic
4062 checking.
4063 (pe_bfd_object_p): Rewrite with external_PEI_DOS_hdr and
4064 external_PEI_IMAGE_hdr.
4065
4066 2001-02-06 Kazu Hirata <kazu@hxi.com>
4067
4068 * elf-m10200.c: Fix formatting.
4069
4070 2001-02-04 Nick Clifton <nickc@redhat.com>
4071
4072 * elf32-v850.c (v850_elf_reloc): Do not convert reloc addend to PC
4073 rel, it will be handled later on.
4074
4075 2001-02-02 Fred Fish <fnf@ninemoons.com>
4076
4077 * Makefile.in: Fix typo.
4078
4079 2001-02-01 Kazu Hirata <kazu@hxi.com>
4080
4081 * elf-m10300.c: Fix formatting.
4082
4083 2001-01-30 Alan Modra <alan@linuxcare.com.au>
4084
4085 * elf64-hppa.c (elf64_hppa_elf_get_symbol_type): New function.
4086 (elf_backend_get_symbol_type): Define.
4087 (elf64_hppa_object_p): Set architecture and machine from elf
4088 header flags.
4089
4090 2001-01-30 Curtis L. Janssen <cljanss@ca.sandia.gov>
4091
4092 * elf64-alpha.c (elf64_alpha_find_nearest_line): Query dwarf2
4093 before mdebug.
4094
4095 2001-01-26 Richard Henderson <rth@redhat.com>
4096
4097 * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Return false
4098 for non-default visibility.
4099 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise, but
4100 delete ugly macro and replace with pretty function.
4101
4102 2001-01-25 Mark Elbrecht <snowball3@bigfoot.com>
4103
4104 * coff-go32.c: Update copyright.
4105 * coff-stgo32.c: Likewise.
4106 * coff-go32.c (COFF_LONG_FILENAMES): Define.
4107 * coff-stgo32.c (COFF_LONG_FILENAMES): Likewise.
4108 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Remove .bss entry.
4109 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
4110
4111 2001-01-25 Kazu Hirata <kazu@hxi.com>
4112
4113 * bfd-in2.h: Rebuild.
4114 * libbfd.h: Likewise.
4115
4116 2001-01-23 H.J. Lu <hjl@gnu.org>
4117
4118 * bfd-in2.h: Rebuild.
4119
4120 2001-01-23 H.J. Lu <hjl@gnu.org>
4121
4122 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_buf)
4123 is NULL or PRIV(vms_rec) is outside of the buffer.
4124
4125 2001-01-23 Kazu Hirata <kazu@hxi.com>
4126
4127 * coff64-rs6000.c: Fix formatting.
4128 * coff-arm.c: Likewise.
4129 * coffgen.c: Likewise.
4130 * cofflink.c: Likewise.
4131 * coff-mcore.c: Likewise.
4132 * coff-mips.c: Likewise.
4133 * coff-pmac.c: Likewise.
4134 * coff-ppc.c: Likewise.
4135 * coff-rs6000.c: Likewise.
4136 * elf32.c: Likewise.
4137 * elf32-fr30.c: Likewise.
4138 * elf32-i370.c: Likewise.
4139 * elf32-i860.c: Likewise.
4140 * elf32-m32r.c: Likewise.
4141 * elf32-m68k.c: Likewise.
4142 * elf32-mcore.c: Likewise.
4143 * elf32-ppc.c: Likewise.
4144 * elf32-sh.c: Likewise.
4145 * elf32-v850.c: Likewise.
4146 * elf64-alpha.c: Likewise.
4147 * elf64-sparc.c: Likewise.
4148 * elflink.c: Likewise.
4149 * elflink.h: Likewise.
4150 * elf-m10200.c: Likewise.
4151 * elf-m10300.c: Likewise.
4152 * elfxx-ia64.c: Likewise.
4153
4154 * aoutx.h: Fix formatting.
4155 * bfd.c: Likewise.
4156 * bfd-in2.h: Likewise.
4157 * bfd-in.h: Likewise.
4158 * cpu-i386.c: Likewise.
4159 * cpu-m68hc11.c: Likewise.
4160 * dwarf2.c: Likewise.
4161 * elf64-x86-64.c: Likewise.
4162 * format.c: Likewise.
4163 * freebsd.h: Likewise.
4164 * hash.c: Likewise.
4165 * hp300hpux.c: Likewise.
4166 * hppabsd-core.c: Likewise.
4167 * hpux-core.c: Likewise.
4168
4169 2001-01-22 Bo Thorsen <bo@suse.de>
4170
4171 * elf64-x86-64.c: Added PIC support for X86-64.
4172 (elf64_x86_64_link_hash_newfunc): Function added.
4173 (elf64_x86_64_link_hash_table_create): Likewise.
4174 (elf64_x86_64_check_relocs): Likewise.
4175 (elf64_x86_64_gc_mark_hook): Likewise.
4176 (elf64_x86_64_gc_sweep_hook): Likewise.
4177 (elf64_x86_64_adjust_dynamic_symbol): Likewise.
4178 (elf64_x86_64_size_dynamic_sections): Likewise.
4179 (elf64_x86_64_discard_copies): Likewise.
4180 (elf64_x86_64_finish_dynamic_symbol): Likewise.
4181 (elf64_x86_64_finish_dynamic_sections): Likewise.
4182 (elf64_x86_64_relocate_section): Add relocation of PIC sections.
4183
4184 2001-01-21 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
4185
4186 * Makefile.am (install-data-local): Make use of $(DESTDIR).
4187 * Makefile.in: Regenerate.
4188
4189 2001-01-21 Kazu Hirata <kazu@hxi.com>
4190
4191 * coff-a29k.c: Fix formatting.
4192
4193 2001-01-19 H.J. Lu <hjl@gnu.org>
4194
4195 * elf32-i386.c (elf_i386_check_relocs): Report files with bad
4196 relocation section names.
4197 (elf_i386_relocate_section): Report files with bad relocation
4198 section names and return false.
4199
4200 2001-01-17 Bo Thorsen <bo@suse.de>
4201
4202 * targets.c: Alphabetize list of xvecs.
4203
4204 2001-01-14 Alan Modra <alan@linuxcare.com.au>
4205
4206 * config.bfd: Add linux target variant for elfxx-hppa.
4207 * configure.in: Recognize bfd_elf32_hppa_linux_vec and
4208 bfd_elf64_hppa_linux_vec.
4209 * configure: Regenerate.
4210 * elf64-hppa.c: Include elf64-target.h again to support linux
4211 target variant.
4212 (elf64_hppa_post_process_headers): Set ELFOSABI_LINUX for linux.
4213 * elf32-hppa.c: Include elf32-target.h again to support linux
4214 target variant.
4215 (elf32_hppa_post_process_headers): New function.
4216 (elf_backend_post_process_headers): Define.
4217 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_linux_vec and
4218 bfd_elf32_hppa_linux_vec.
4219
4220 * elf32-hppa.c (elf32_hppa_link_hash_table): Add text_segment_base,
4221 and data_segment_base fields.
4222 (elf32_hppa_link_hash_table_create ): Init them.
4223 (elf32_hppa_check_relocs): Update comments.
4224 (hppa_record_segment_addr): New function.
4225 (elf32_hppa_relocate_section): Call it.
4226 (final_link_relocate): Handle R_PARISC_SEGREL32.
4227 (elf32_hppa_final_link): New function.
4228 (bfd_elf32_bfd_final_link): Define to call it.
4229 (hppa_unwind_entry_compare): New function.
4230 * cache.c (bfd_open_file): Create files in write+read mode.
4231
4232 * elf-hppa.h (elf_hppa_howto_table): Set bitsize value for
4233 SEGREL32 and numerous other relocs. Change duplicate
4234 R_PARISC_NONE relocs to R_PARISC_UNIMPLEMENTED.
4235
4236 * opncls.c (bfd_fdopenr): Add parens like the comment says around
4237 O_ACCMODE.
4238
4239 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Don't create
4240 .plt entries for DT_INIT and DT_FINI.
4241 (elf32_hppa_finish_dynamic_sections): Remove special handling of
4242 DT_INIT and DT_FINI.
4243
4244 * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Use 16-bit
4245 offsets for stub .plt access if wide mode. Check offset in range.
4246
4247 2001-01-13 Nick Clifton <nickc@redhat.com>
4248
4249 * elf32-fr30.c (fr30_elf_howto_table): Remove spurious blank
4250 line.
4251
4252 * coffcode.h (coff_canonicalize_reloc): Remove spurious blank
4253 line.
4254
4255 2001-01-12 Alan Modra <alan@linuxcare.com.au>
4256
4257 * configure.in ([bfd_elf64_x86_64_vec]): Set target64.
4258 * configure: Regenerate.
4259
4260 2001-01-11 Peter Targett <peter.targett@arccores.com>
4261
4262 * bfd-in2.h (bfd_architecture): Add bfd_mach_arc_5,
4263 bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8 for ARC variants.
4264 * cpu-arc.c (arch_info_struct): Add entries for variants.
4265 (bfd_arc_arch) Set default to bfd_mach_arc_5.
4266 (arc_get_mach) Don't assume machine names prefixed arc- before
4267 testing.
4268 * elf32-arc.c (arc_elf_object_p): Set machine number based on new
4269 selections.
4270 (arc_elf_final_write_processing) Likewise.
4271 (ELF_MACHINE_CODE) Use EM_ARC.
4272
4273 2001-01-10 Nick Clifton <nickc@redhat.com>
4274
4275 * coff-arm.c (LOCAL_LABEL_PREFIX): Change definition to "".
4276
4277 2001-01-07 Philip Blundell <philb@gnu.org>
4278
4279 * README: Replace `bug-gnu-utils@gnu.org' with
4280 `bug-binutils@gnu.org'.
4281
4282 2001-01-04 Kazu Hirata <kazu@hxi.com>
4283
4284 * som.c: Fix formatting.
4285
4286 2001-01-03 Kazu Hirata <kazu@hxi.com>
4287
4288 * ecoffswap.h: Fix formatting.
4289 * elf-bfd.h: Likewise.
4290 * elfarm-nabi.c: Likewise.
4291 * elfarm-oabi.c: Likewise.
4292 * elfcode.h: Likewise.
4293 * elfcore.h: Likewise.
4294 * elflink.c: Likewise.
4295 * elflink.h: Likewise.
4296 * elfxx-ia64.c: Likewise.
4297 * elfxx-target.h: Likewise.
4298 * libbfd.c: Likewise
4299 * linker.c: Likewise.
4300 * lynx-core.c: Likewise.
4301
4302 2001-01-02 Kazu Hirata <kazu@hxi.com>
4303
4304 * pc532-mach.c: Fix formatting.
4305 * pe-arm.c: Likewise.
4306 * pe-i386.c: Likewise.
4307 * pe-mips.c: Likewise.
4308 * pe-ppc.c: Likewise.
4309 * pe-sh.c: Likewise.
4310 * pei-mips.c: Likewise.
4311 * pei-sh.c: Likewise.
4312 * peicode.h: Likewise.
4313 * ppcboot.c: Likewise.
4314 * ptrace-core.c: Likewise.
4315
4316 2001-01-01 Kazu Hirata <kazu@hxi.com>
4317
4318 * reloc.c: Fix formatting.
4319 * riscix.c: Likewise.
4320 * rs6000-core.c: Likewise.
4321 * xcoff-target.h: Likewise.
4322
4323 2000-12-29 Hans-Peter Nilsson <hp@bitrange.com>
4324
4325 * elfcode.h (elf_object_p): Also restore the bfd mach field on
4326 error, by calling bfd_default_set_arch_mach with incoming
4327 values.
4328
4329 2000-12-26 Kazu Hirata <kazu@hxi.com>
4330
4331 * vaxnetbsd.c: Fix formatting.
4332 * versados.c: Likewise.
4333 * vms-gsd.c: Likewise.
4334 * vms-hdr.c: Likewise.
4335 * vms-misc.c: Likewise.
4336
4337 2000-12-25 Alexandre Oliva <aoliva@redhat.com>
4338
4339 * archive.c (coff_write_armap): Don't write more than symbol_count
4340 `archive_member_file_ptr's.
4341
4342 2000-12-25 Kazu Hirata <kazu@hxi.com>
4343
4344 * vms-tir.c: Fix formatting.
4345
4346 2000-12-23 Kazu Hirata <kazu@hxi.com>
4347
4348 * vms.c: Fix formatting.
4349 * vms.h: Likewise.
4350
4351 2000-12-21 Santeri Paavolainen <santtu@ssh.com>
4352
4353 * vms-hdr.c: Include alloca.h if HAVE_ALLOCA_H is defined.
4354
4355 * peicode.h (pe_ILF_object_p): Add const to import of TARGET_LITTLE_SYM.
4356
4357 * elf32-m32r.c (m32r_elf_generic_reloc): Add cast to avoid (void *)
4358 arithmetic.
4359
4360 * elf32-fr30.c: Add casts to avoid (void *) arithmetic.
4361
4362 * coffcode.h (styp_to_sec_flags): Add empty statement after label.
4363
4364 2000-12-21 Richard Sandiford <rsandifo@redhat.com>
4365
4366 * libbfd.c (bfd_get_bits): Added
4367 (bfd_put_bits): Likewise
4368 * bfd-in.h: Declared the above.
4369 * bfd-in2.h: Regenerated.
4370
4371 2000-12-20 Kazu Hirata <kazu@hxi.com>
4372
4373 * targets.c: Fix formatting.
4374 * tekhex.c: Likewise.
4375 * trad-core.c: Likewise.
4376
4377 2000-12-19 Kazu Hirata <kazu@hxi.com>
4378
4379 * sco5-core.c: Fix formatting.
4380 * section.c: Likewise.
4381 * sparclinux.c: Likewise.
4382 * sparclynx.c: Likewise.
4383 * sparcnetbsd.c: Likewise.
4384 * srec.c: Likewise.
4385 * stabs.c: Likewise.
4386 * stab-syms.c: Likewise.
4387 * sunos.c: Likewise.
4388 * syms.c: Likewise.
4389 * sysdep.h: Likewise.
4390
4391 2000-12-18 Nick Clifton <nickc@redhat.com>
4392
4393 * coff-arm.c (EXTRA_S_FLAGS): Only define if not already
4394 defined.
4395 * epoc-pe-arm.c (EXTRA_S_FLAGS): Define.
4396 * epoc-pei-arm.c (EXTRA_S_FLAGS): Define.
4397
4398 2000-12-18 Nick Clifton <nickc@redhat.com>
4399
4400 * vms-misc.c (_bfd_vms_get_record): Add default case to
4401 file_format switch.
4402
4403 2000-12-15 Miloslav Trmac <mitr@volny.cz>
4404
4405 * elfcore.h (elf_core_file_p): Move to the start of the program
4406 headers before attempting to read them.
4407
4408 2000-12-14 Kazu Hirata <kazu@hxi.com>
4409
4410 * peigen.c: Fix formatting.
4411 * som.c: Likewise.
4412 * som.h: Likewise.
4413
4414 2000-12-13 Kazu Hirata <kazu@hxi.com>
4415
4416 * peigen.c: Fix formatting.
4417
4418 2000-12-12 Jim Wilson <wilson@redhat.com>
4419
4420 * elfxx-ia64.c (get_dyn_sym_info): Cast %p argument to void *.
4421
4422 2000-12-08 Mark Salter <msalter@redhat.com>
4423
4424 * binary.c (binary_set_section_contents): Ignore sections
4425 with zero size.
4426
4427 2000-12-12 Kazu Hirata <kazu@hxi.com>
4428
4429 * m68klinux.c: Fix formatting.
4430 * m68knetbsd.c: Likewise.
4431 * mipsbsd.c: Likewise.
4432 * netbsd-core.c: Likewise.
4433 * netbsd.h: Likewise.
4434 * newsos3.c: Likewise.
4435 * nlm32-alpha.c: Likewise.
4436 * nlm32-i386.c: Likewise.
4437 * nlm32-ppc.c: Likewise.
4438 * nlm32-sparc.c: Likewise.
4439 * nlmcode.h: Likewise.
4440 * nlmswap.h: Likewise.
4441 * nlm-target.h: Likewise.
4442 * ns32knetbsd.c: Likewise.
4443
4444 2000-12-10 Fred Fish <fnf@be.com>
4445
4446 * elflink.h (elf_link_output_extsym): Don't complain about undefined
4447 symbols in shared objects if allow_shlib_undefined is true.
4448
4449 2000-12-12 Nick Clifton <nickc@redhat.com>
4450
4451 * cpu-sh.c: Fix formattng.
4452 * elf.c: Fix formattng.
4453 * elf32-mips.c: Fix formattng.
4454 * elf32-sh.c: Fix formattng.
4455 * elf64-alpha.c: Fix formattng.
4456
4457 2000-12-09 Nick Clifton <nickc@redhat.com>
4458
4459 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Pass
4460 dwarf2_find_line_info as last parameter to invocation of
4461 _bfd_dwarf2_find_nearest_line.
4462 * elf32-arm.h (elf32_arm_find_nearest_line): Pass
4463 dwarf2_find_line_info as last parameter to invocation of
4464 _bfd_dwarf2_find_nearest_line.
4465
4466 2000-12-08 Mark Elbrecht <snowball3@bigfoot.com>
4467
4468 * Makefile.am (BFD32_BACKENDS): Move dwarf2.lo from here...
4469 (BFD_LIBS): ...to here.
4470 (BFD32_BACKENDS_CFILES): Move dwarf2.c from here...
4471 (BFD_LIBS_CFILES): ...to here.
4472 * Makefile.in: Regenerate.
4473 * configure.in: Remove dwarf.lo from the elf shell variable.
4474 * configure: Regenerate.
4475 * libcoff-in.h (coff_tdata): Add pointer dwarf2_find_line_info.
4476 * libcoff.h: Regenerate.
4477 * coffgen.c (coff_find_nearest_line): Call
4478 _bfd_dwarf2_find_nearest_line.
4479 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Add parameter. Update
4480 accordingly.
4481 (read_abbrevs): Likewise
4482 (decode_line_info): Likewise.
4483 (parse_comp_unit): Likewise.
4484 (comp_unit_find_nearest_line): Likewise.
4485 * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Update prototype.
4486 * libbfd.h: Regenerate.
4487 * elf.c (_bfd_elf_find_nearest_line): Update call.
4488 * elf-bfd.h (elf_obj_tdata): Change dwarf2_find_line_info to type PTR.
4489 * dwarf2.c (concat_filename): Use IS_ABSOLUTE_PATH.
4490 * coffcode.h (STYP_XCOFF_DEBUG, STYP_DEBUG_INFO): New macros.
4491 (sec_to_styp_flags): Use them. Handle DWARF2 sections.
4492 (styp_to_sec_flags): Handle DWARF2 sections.
4493 * elf32-arm.h (elf32_arm_find_nearest_line): Add parameter to call
4494 to _bfd_find_nearest_line.
4495 * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Add parameter to
4496 call to _bfd_find_nearest_line.
4497
4498 2000-12-08 Kazu Hirata <kazu@hxi.com>
4499
4500 * coffgen.c: Fix formatting.
4501 * elf-m10300.c: Likewise.
4502 * elf32-i386.c: Likewise.
4503 * elf32-i960.c: Likewise.
4504 * elf32-m68k.c: Likewise.
4505 * elf32-mcore.c: Likewise.
4506 * elf32-ppc.c: Likewise.
4507 * elf32-sh.c: Likewise.
4508 * elf32-sparc.c: Likewise.
4509 * elf32-v850.c: Likewise.
4510 * elf64-alpha.c: Likewise.
4511 * elf64-hppa.c: Likewise.
4512 * elf64-mips.c: Likewise.
4513 * elf64-sparc.c: Likewise.
4514
4515 2000-12-07 Kazu Hirata <kazu@hxi.com>
4516
4517 * elf32-ppc.c: Fix formatting.
4518 * elf64-x86-64.c: Likewise.
4519
4520 2000-12-06 Ulf Carlsson <ulfc@engr.sgi.com>
4521
4522 From Ralf Baechle <ralf@gnu.org>
4523
4524 * elf32-mips.c (elf32_mips_merge_private_bfd_data): Always permit
4525 BFDs containing no sections or empty .text, .data or .bss sections
4526 to be merged, regardless of their flags.
4527
4528 2000-12-06 Kazu Hirata <kazu@hxi.com>
4529
4530 * elf32-m32r.c: Fix formatting.
4531 * elf32-m68hc11.c: Likewise.
4532 * elf32-m68hc12.c: Likewise.
4533 * elf32-m68k.c: Likewise.
4534 * elf32-mcore.c: Likewise.
4535 * elf32-pj.c: Likewise.
4536 * elf32-ppc.c: Likewise.
4537
4538 2000-12-05 Kazu Hirata <kazu@hxi.com>
4539
4540 * elf32-fr30.c: Fix formatting.
4541 * elf32-hppa.c: Likewise.
4542 * elf32-i370.c: Likewise.
4543 * elf32-i386.c: Likewise.
4544 * elf32-i860.c: Likewise.
4545 * elf32-i960.c: Likewise.
4546
4547 2000-12-03 Kazu Hirata <kazu@hxi.com>
4548
4549 * elf32-arm.h: Fix formatting.
4550 * elf32-avr.c: Likewise.
4551 * elf32-cris.c: Likewise.
4552 * elf32-d10v.c: Likewise.
4553 * elf32-d30v.c: Likewise.
4554 * elf-hppa.h: Likewise.
4555 * elf-m10200.c: Likewise.
4556 * elf-m10300.c: Likewise.
4557
4558 2000-12-01 Chris Demetriou <cgd@sibyte.com>
4559
4560 * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mips32 and
4561 bfd_mach_mips32_4k. Update FIXME comment.
4562 * archures.c (bfd_mach_mips32): New constant.
4563 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4564 the latter, renumber it.
4565 * bfd-in2.h (bfd_mach_mips32): New constant.
4566 (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
4567 the latter, renumber it.
4568 * cpu-mips.c (I_mips32): New constant.
4569 (I_mips4K, I_mips32_4k): Rename the former to the latter.
4570 (arch_info_struct): Add bfd_mach_mips32 entry, replace
4571 bfd_mach_mips4K entry with bfd_mach_mips32_4k entry.
4572 * elf32-mips.c (elf_mips_isa): Add E_MIPS_ARCH_32 case.
4573 (elf_mips_mach): Likewise. Also, replace E_MIPS_MACH_MIPS32
4574 with E_MIPS_MACH_MIPS32_4K.
4575 (_bfd_mips_elf_final_write_processing): Replace
4576 bfd_mach_mips4K with bfd_mach_mips32_4k case, add
4577 bfd_mach_mips32 case.
4578 (_bfd_mips_elf_merge_private_bfd_data): Generalize ISA mixing
4579 comparison with support for MIPS32.
4580 (_bfd_mips_elf_print_private_bfd_data): Print ISA name for
4581 MIPS32.
4582
4583 * aoutx.h (NAME(aout,machine_type)): Add cases for
4584 bfd_mach_mips5 and bfd_mach_mips64.
4585 * archures.c (bfd_mach_mips5, bfd_mach_mips64): New constants.
4586 * bfd-in2.h (bfd_mach_mips5, bfd_mach_mips64): Likewise.
4587 * cpu_mips.c (I_mips5, I_mips64): New definitions.
4588 (arch_info_struct): Add entries for bfd_mach_mips5 and
4589 bfd_mach_mips64.
4590 * elf32-mips.c (elf_mips_isa, elf_mips_mach,
4591 _bfd_mips_elf_print_private_bfd_data): Add cases for
4592 E_MIPS_ARCH_5 and E_MIPS_ARCH_64.
4593 (_bfd_mips_elf_final_write_processing): Add cases for
4594 bfd_mach_mips5 and bfd_mach_mips64.
4595
4596 * aoutx.h (NAME(aout,machine_type)): Add a
4597 bfd_mach_mips_sb1 case.
4598 * archures.c (bfd_mach_mips_sb1): New constant.
4599 * bfd-in2.h (bfd_mach_mips_sb1): New constant.
4600 * cpu-mips.c (I_sb1): New constant.
4601 (arch_info_struct): Add entry for bfd_mach_mips_sb1.
4602 * elf32-mips.c (elf_mips_mach): Add case for
4603 E_MIPS_MACH_SB1.
4604 (_bfd_mips_elf_final_write_processing): Add case for
4605 bfd_mach_mips_sb1.
4606
4607 2000-12-01 Joel Sherrill <joel@OARcorp.com>
4608
4609 * config.bfd (arm-*-rtems*, a29k-*rtems*): New targets.
4610 (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
4611 (sparc*-*-rtems*): Switched from a.out to ELF.
4612
4613 2000-11-30 Jan Hubicka <jh@suse.cz>
4614
4615 * Makefile.am (BFD64_BACKENDS): Add elf64-x86-64.lo
4616 BFD64_BACKENDS_CFILES): Add elf64-x86-64.c
4617 (elf64-x86-64.lo): Add dependencies.
4618 * archures.c (DESCRIPTION): Add bfd_mach_x86_64,
4619 bfd_mach_x86_64_intel_syntax.
4620 * elf.c (prep_headers): Use EM_x86_64 for 64bit output.
4621 * config.bfd (x86_64): Add.
4622 * configure.in: Add support for bfd_elf64_x86_64_vec.
4623 * cpu-i386.c (bfd_x86_64_arch_intel_syntax, bfd_x86_64_arch): Add.
4624 (bfd_i386_arch, i8086_ar): Link in.
4625 * elf64-x86-64.c: New file.
4626 * reloc.c (ENUMDOC): Add BFD_RELOC_X86_64*.
4627 * targets.c (bfd_elf64_x86_64_vec): Add.
4628 (bfd_target_vect): Add bfd_elf64_x86_64_vec.
4629
4630 2000-11-30 Kazu Hirata <kazu@hxi.com>
4631
4632 * xcofflink.c: Fix formatting.
4633
4634 2000-11-28 Kazu Hirata <kazu@hxi.com>
4635
4636 * aoutx.h: Fix formatting.
4637 * bfd-in.h: Likewise.
4638 * bfd-in2.h: Likewise.
4639 * cache.c: Likewise.
4640 * cisco-core.c: Likewise.
4641 * coff64-rs6000.c: Likewise.
4642 * coffcode.h: Likewise.
4643 * coffswap.h: Likewise.
4644 * corefile.c: Likewise.
4645 * elf32-mips.c: Likewise.
4646
4647 2000-11-27 Kazu Hirata <kazu@hxi.com>
4648
4649 * aout-adobe.c: Fix formatting.
4650 * coff64-rs6000.c: Likewise.
4651 * coffgen.c: Likewise.
4652 * cofflink.c: Likewise.
4653
4654 2000-11-27 Philip Blundell <pb@futuretv.com>
4655
4656 * libcoff-in.h (coff_tdata): Add `strings_written' flag.
4657 (obj_coff_strings_written): New accessor macro for above.
4658 * libcoff.h: Regenerate.
4659 * cofflink.c (_bfd_coff_final_link): Say that we wrote the
4660 strings.
4661 * coffcode.h (coff_write_object_contents): No need to write out
4662 the string table if it's already been done.
4663
4664 2000-11-22 Philip Blundell <pb@futuretv.com>
4665
4666 * cofflink.c (_bfd_coff_generic_relocate_section): Don't object to
4667 weak undefined symbols.
4668
4669 2000-11-24 Nick Clifton <nickc@redhat.com>
4670
4671 * archures.c (bfd_mach_arm_5TE): Define.
4672 (bfd_mach_arm+XScale): Define.
4673 * bfd-in2.h: Regenerate.
4674
4675 * coff-arm.c (coff_arm_reloc_type_lookup): Accept
4676 BFD_RELOC_ARM_PCREL_BLX.
4677
4678 * coffcode.h (coff_set_flags): Set flags for 5t, 5te and
4679 XScale machine numbers.
4680
4681 * config.bfd (xscale-elf): Add target.
4682 (xscale-coff): Add target.
4683
4684 * cpu-arm.c: Add xscale machine name.
4685 Add v5t, v5te and XScale machine numbers.
4686
4687 2000-11-23 Kazu Hirata <kazu@hxi.com>
4688
4689 * aix386-core.c: Fix formatting.
4690
4691 2000-11-22 Jim Wilson <wilson@redhat.com>
4692
4693 * coff-ia64.c (howto_table): Use EMPTY_HOWTO.
4694 (in_reloc_p): Add ATTRIBUTE_UNUSED to unused parameters.
4695 * cpu-ia64-opc.c (ins_rsvd, ext_rsvd, ins_const, ext_const): Likewise.
4696 (ins_imms_scaled): Initialize sign_bit at function entry.
4697 (elf64_ia64_operands): Add missing initializers.
4698 * elfxx-ia64.c (elfNN_ia64_reloc, elfNN_ia64_reloc_type_lookup,
4699 elfNN_ia64_info_to_howto, elfNN_ia64_fake_sections,
4700 elfNN_ia64_add_symbol_hook, elfNN_ia64_is_local_label_name,
4701 elfNN_ia64_local_hash_table_init, get_fptr, get_pltoff,
4702 elfNN_ia64_adjust_dynamic_symbol): Add ATTRIBUTE_UNUSED for unused
4703 parameters.
4704 (elfNN_ia64_info_to_howto): Initialize free_relocs, free_contents,
4705 and free_extsyms at function entry.
4706 (elfNN_add_symbol_hook): Add unsigned cast to bfd_get_gp_size result.
4707 (elfNN_ia64_create_dynamic_sections): Delete unused local h.
4708 (get_got): Delete unused local srel.
4709 (elfNN_ia64_check_relocs): Initialize dynrel_type when declared.
4710 (elfNN_ia64_relocate_section): Delete unused local dynindx.
4711
4712 2000-11-21 Kazu Hirata <kazu@hxi.com>
4713
4714 * coff-a29k.c: Fix formatting.
4715 * coff-h8500.c: Likewise.
4716 * coff-i960.c: Likewise.
4717 * coff-ppc.c: Likewise.
4718 * coff-rs6000.c: Likewise.
4719 * coff-stgo32.c: Likewise.
4720 * coff-tic54x.c: Likewise.
4721 * coff-w65.c: Likewise.
4722 * cpu-h8500.c: Likewise.
4723 * cpu-hppa.c: Likewise.
4724 * cpu-ns32k.c: Likewise.
4725 * ecoff.c: Likewise.
4726 * ecofflink.c: Likewise.
4727
4728 2000-11-21 Nick Clifton <nickc@redhat.com>
4729
4730 * elf32-sh.c (sh_elf_reloc_loop): Fix compile time warning, and
4731 remove possibility of infinite loop.
4732
4733 2000-11-20 Kazu Hirata <kazu@hxi.com>
4734
4735 * aix386-core.c: Fix formatting.
4736 * aout-adobe.c: Likewise.
4737 * aout-arm.c: Likewise.
4738 * aout-encap.c: Likewise.
4739 * aout-ns32k.c: Likewise.
4740 * aout-target.h: Likewise.
4741 * aout-tic30.c: Likewise.
4742 * aoutf1.h: Likewise.
4743 * aoutx.h: Likewise.
4744 * archive.c: Likewise.
4745 * bfd-in.h: Likewise.
4746 * bfd-in2.h: Likewise.
4747 * bfd.c: Likewise.
4748 * bout.c: Likewise.
4749
4750 2000-11-17 H.J. Lu <hjl@gnu.org>
4751
4752 * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Don't create
4753 pltoff entries for DT_INIT and DT_FINI.
4754 (elfNN_ia64_final_link): Don't set DT_INIT/FINI entries.
4755 (elfNN_ia64_finish_dynamic_sections): Don't fill in DT_INIT/FINI
4756 entries.
4757
4758 2000-11-16 Richard Henderson <rth@redhat.com>
4759
4760 * elfxx-ia64.c (elfNN_ia64_check_relocs): Handle IPLT relocs.
4761 (allocate_dynrel_entries): Likewise.
4762 (elfNN_ia64_relocate_section): Likewise. Set REL addends correctly.
4763 (set_pltoff_entry): Likewise.
4764 (ia64_howto_table): Remove R_IA64_SEGBASE, and R_IA64_EPLT[ML]SB
4765 (elfNN_ia64_reloc_type_lookup): Likewise.
4766 (elfNN_ia64_install_value): Likewise.
4767 (elfNN_ia64_relocate_section): Likewise.
4768 * reloc.c (BFD_RELOC_IA64_SEGBASE): Remove.
4769 (BFD_RELOC_IA64_EPLTMSB, BFD_RELOC_IA64_EPLTLSB): Remove.
4770
4771 2000-11-16 Kazu Hirata <kazu@hxi.com>
4772
4773 * cpu-a29k.c: Fix formatting.
4774 * cpu-alpha.c: Likewise.
4775 * cpu-arm.c: Likewise.
4776 * cpu-avr.c: Likewise.
4777 * cpu-d10v.c: Likewise.
4778 * cpu-h8500.c: Likewise.
4779 * cpu-hppa.c: Likewise.
4780 * cpu-i370.c: Likewise.
4781 * cpu-i386.c: Likewise.
4782 * cpu-i960.c: Likewise.
4783 * cpu-ia64-opc.c: Likewise.
4784 * cpu-ia64.c: Likewise.
4785 * cpu-m32r.c: Likewise.
4786 * cpu-m68hc11.c: Likewise.
4787 * cpu-m68hc12.c: Likewise.
4788 * cpu-m68k.c: Likewise.
4789 * cpu-m88k.c: Likewise.
4790 * cpu-mips.c: Likewise.
4791 * cpu-ns32k.c: Likewise.
4792 * cpu-pj.c: Likewise.
4793 * cpu-powerpc.c: Likewise.
4794 * cpu-sh.c: Likewise.
4795 * cpu-sparc.c: Likewise.
4796 * cpu-tic54x.c: Likewise.
4797 * cpu-v850.c: Likewise.
4798 * cpu-vax.c: Likewise.
4799 * cpu-w65.c: Likewise.
4800 * cpu-we32k.c: Likewise.
4801 * cpu-z8k.c: Likewise.
4802 * dwarf1.c: Likewise.
4803 * dwarf2.c: Likewise.
4804
4805 2000-11-15 Kazu Hirata <kazu@hxi.com>
4806
4807 * coff-arm.c: Fix formatting.
4808 * coff-ppc.c: Likewise.
4809 * coff-rs6000.c: Likewise.
4810 * coff-sh.c: Likewise.
4811 * coff-sparc.c: Likewise.
4812 * coff-tic30.c: Likewise.
4813 * coff-tic54x.c: Likewise.
4814 * coff-tic80.c: Likewise.
4815 * coff-w65.c: Likewise.
4816 * coff-we32k.c: Likewise.
4817 * coff-z8k.c: Likewise.
4818
4819 2000-11-15 Richard Henderson <rth@redhat.com>
4820
4821 * elf64-alpha.c (elf64_alpha_check_relocs): Create the reloc
4822 section with the same ALLOC|LOAD flags as the source section.
4823
4824 2000-11-14 Jakub Jelinek <jakub@redhat.com>
4825
4826 * elf64-alpha.c (elf64_alpha_relax_opt_call): Only check bits used
4827 by STO_ALPHA constants.
4828
4829 2000-11-14 Kazu Hirata <kazu@hxi.com>
4830
4831 * coff-pmac.c: Fix formatting.
4832 * coff-ppc.c: Likewise.
4833
4834 2000-11-13 H.J. Lu <hjl@gnu.org>
4835
4836 * elflink.h (elf_link_add_object_symbols): Also add indirect
4837 symbols for common symbols with the default version.
4838
4839 2000-11-09 Philip Blundell <pb@futuretv.com>
4840
4841 * section.c (STD_SECTION): Set gc_mark flag.
4842
4843 2000-11-11 Kazu Hirata <kazu@hxi.com>
4844
4845 * coff-i960.c: Likewise.
4846 * coff-m68k.c: Likewise.
4847 * coff-m88k.c: Likewise.
4848 * coff-mcore.c: Likewise.
4849 * coff-mips.c: Likewise.
4850
4851 2000-11-11 Bernd Schmidt <bernds@cygnus.co.uk>
4852
4853 * elf32-sh.c (sh_elf_relocate_section): Ignore R_SH_NONE relocs.
4854
4855 2000-11-10 Kazu Hirata <kazu@hxi.com>
4856
4857 * coff-h8300.c: Fix formatting.
4858 * coff-h8500.c: Likewise.
4859 * coff-i386.c: Likewise.
4860 * coff-i860.c: Likewise.
4861 * coff-i960.c: Likewise.
4862 * coff-ia64.c: Likewise.
4863
4864 2000-11-09 Kazu Hirata <kazu@hxi.com>
4865
4866 * archive.c: Fix formatting.
4867 * archures.c: Likewise.
4868
4869 2000-11-07 Richard Henderson <rth@redhat.com>
4870
4871 * elfxx-ia64.c (elf64_ia64_final_link): New local unwind_output_sec.
4872 Set it before bfd_elf64_bfd_final_link call. Use it after the call.
4873 * section.c (bfd_set_section_contents): Call memcpy if
4874 section->contents set and location not equal to contents plus offset.
4875
4876 2000-11-08 Kazu Hirata <kazu@hxi.com>
4877
4878 * bfd-in.h: Fix formatting.
4879 * bfd-in2.h: Likewise.
4880 * bfd.c: Likewise.
4881 * binary.c: Likewise.
4882 * bout.c: Likewise.
4883 * coff-a29k.c: Likewise.
4884 * coff-alpha.c: Likewise.
4885 * coff-apollo.c: Likewise.
4886 * coff-aux.c: Likewise.
4887
4888 2000-11-07 Kazu Hirata <kazu@hxi.com>
4889
4890 * aix386-core.c: Fix formatting.
4891 * aoutf1.h: Likewise.
4892 * aoutx.h: Likewise.
4893 * archures.c: Likewise.
4894 * armnetbsd.c: Likewise.
4895
4896 2000-11-07 Alan Modra <alan@linuxcare.com.au>
4897
4898 * coff-h8300.c (special): Adjust reloc address.
4899
4900 2000-11-06 Steve Ellcey <sje@cup.hp.com>
4901
4902 * archures.c (bfd_mach_ia64_elf64, bfd_mach_ia64_elf32): Add defines
4903 to differentiate elf32 and elf64 on ia64.
4904 * bfd-in2.h: Regenerate.
4905 * config.bfd: Add target for "ia64*-*-hpux*".
4906 * configure.in: Add bfd_elf32_ia64_big_vec to selvecs switch.
4907 * configure: Regenerate.
4908 * cpu-ia64.c (bfd_ia64_elf32_arch): Add elf32 arch info structure.
4909 * targets.c: Add bfd_target bfd_elf32_ia64_big_vec.
4910
4911 * Makefile.am: Make elf32-ia64.c and elf64-ia64.c derived objects
4912 from elfxx-ia64.c. Add depenency rules for making elf32-ia64.lo.
4913 * Makefile.in: Regnerate.
4914 * elf64-ia64.c: Deleted.
4915 * elfxx-ia64.c: New file, paramaterized version of elf64-ia64.c.
4916
4917 2000-11-06 Kazu Hirata <kazu@hxi.com>
4918
4919 * aout-adobe.c: Fix formatting.
4920 * aout-arm.c: Likewise.
4921 * aout-cris.c: Likewise.
4922 * aout-encap.c: Likewise.
4923 * aout-ns32k.c: Likewise.
4924 * aout-target.h: Likewise.
4925 * aout-tic30.c: Likewise.
4926
4927 2000-11-05 Philip Blundell <philb@gnu.org>
4928
4929 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit
4930 BFDs containing no sections to be merged, regardless of their flags.
4931
4932 2000-11-04 Philip Blundell <philb@gnu.org>
4933
4934 * elf32-arm.h (elf32_arm_relocate_section): Suppress error message
4935 if a relocation for an undefined symbol also results in an
4936 overflow.
4937
4938 2000-11-06 Christopher Faylor <cgf@cygnus.com>
4939
4940 * config.bfd: Add support for Sun Chorus.
4941
4942 2000-11-05 David O'Brien <obrien@FreeBSD.org>
4943
4944 * configure.in: Recognize alpha-*-freebsd*.
4945 * configure: Regenerate.
4946
4947 2000-11-02 Luciano Gemme <ishitawa@yahoo.com>
4948
4949 * srec.c (CHUNK): Rename to DEFAULT_CHUNK.
4950 (Chunk): New global variable set by a parameter in objcopy.c.
4951 (S3Forced): New global variable set by a parameter in
4952 objcopy.c.
4953 (srec_set_section_contents): If S3Forced is true, always generate
4954 S3 records.
4955 (srec_write_section): Use 'Chunk' to limit maximum length of S
4956 records.
4957
4958 2000-11-02 Per Lundberg <plundis@chaosdev.org>
4959
4960 * config.bfd: Add support for i[3456]86-chaosdev-storm-chaos.
4961 * Makefile.in: Regenerate.
4962 * bfd-in2.h: Regenerate.
4963 * po/bfd.pot: Regenerate.
4964
4965 2000-10-31 Philip Blundell <philb@gnu.org>
4966
4967 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Only handle
4968 EF_SOFT_FLOAT if it is defined.
4969
4970 2000-10-27 Philip Blundell <philb@gnu.org>
4971
4972 * elf32-arm.h (elf32_arm_copy_private_bfd_data): Don't refuse
4973 attempts to mix PIC code with non-PIC, just mark the output as
4974 being position dependent.
4975 (elf32_arm_merge_private_bfd_data): Likewise. Print an error
4976 message for EF_SOFT_FLOAT mismatches. Display diagnostics for
4977 all mismatches, not just the first one.
4978
4979 2000-10-25 Chris Demetriou <cgd@sibyte.com>
4980
4981 * ieee.c (ieee_archive_p): Plug one of many possible
4982 memory leaks in error handling.
4983
4984 2000-10-20 Jakub Jelinek <jakub@redhat.com>
4985
4986 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data,
4987 elf32_sparc_object_p, elf32_sparc_final_write_processing):
4988 Support v8plusb.
4989 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data,
4990 sparc64_elf_object_p): Support v9b.
4991 * archures.c: Declare v8plusb and v9b machines.
4992 * bfd-in2.h: Ditto.
4993 * cpu-sparc.c: Ditto.
4994
4995 2000-10-16 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
4996
4997 * elf64-sparc.c (sparc64_elf_relocate_section): Clear the location
4998 of a GOT reloc.
4999
5000 * elf32-ppc.c (SYMBOL_REFERENCES_LOCAL): New macro.
5001 (SYMBOL_CALLS_LOCAL): New macro.
5002 (ppc_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
5003 (ppc_elf_check_relocs): Use SYMBOL_REFERENCES_LOCAL.
5004 (ppc_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
5005 (ppc_elf_relocate_section): Use flag variable to determine
5006 whether the relocation refers to a local symbol.
5007 Test whether a PLTREL24 reloc will produce a reloc by looking
5008 to see whether a PLT entry was made.
5009
5010 2000-10-14 Geoffrey Keating <geoffk@shoggoth.cygnus.com>
5011
5012 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make PLT
5013 entries that could serve as a definition for a weak symbol.
5014
5015 2000-10-13 Ulf Carlsson <ulfc@engr.sgi.com>
5016
5017 From Ralf Baechle <ralf@gnu.org>
5018
5019 * elf32-mips.c (mips_elf_create_dynamic_relocation): New argument
5020 local_p. Add symbol value only for non-R_MIPS_REL32 relocations
5021 against local symbols.
5022 (_bfd_mips_elf_finish_dynamic_sections): Undo patch from 2000-10-01.
5023
5024 2000-10-12 Alan Modra <alan@linuxcare.com.au>
5025
5026 * section.c (struct sec): Add kept_section.
5027 (struct bfd_comdat_info): Remove sec, we can use above.
5028 (STD_SECTION): Add initializer.
5029 (bfd_make_section_anyway): Init here too.
5030
5031 * bfd-in2.h: Regenerate.
5032
5033 * elflink.h (elf_link_add_object_symbols): Remove unnecessary
5034 zeroing of `flags'.
5035 (elf_link_input_bfd): Set all asection->symbol->value's here, and
5036 fudge values for discarded link-once section symbols.
5037
5038 * elf64-hppa.c: Include alloca-conf.h
5039
5040 2000-10-11 Alan Modra <alan@linuxcare.com.au>
5041
5042 * elf.c (swap_out_syms): Revert 2000-10-07 changes.
5043
5044 * ieee.c (ieee_make_empty_symbol): Oops, bfd_zalloc needs another arg.
5045
5046 2000-10-10 Alan Modra <alan@linuxcare.com.au>
5047
5048 * ieee.c (ieee_make_empty_symbol): Use bfd_zalloc, not bfd_zmalloc.
5049
5050 2000-10-10 Tom Rix <trix@redhat.com>
5051
5052 * section.c (bfd_make_section_anyway): Release newsect ptr when
5053 newsect->symbol fails to alloc. Use bfd_release instead of free.
5054
5055 2000-10-09 Richard Henderson <rth@cygnus.com
5056
5057 * elf64-ia64.c (elf64_ia64_unwind_entry_compare_bfd): New.
5058 (elf64_ia64_unwind_entry_compare): New.
5059 (elf64_ia64_final_link): Sort the .IA_64.unwind section.
5060
5061 2000-10-07 Alan Modra <alan@linuxcare.com.au>
5062
5063 * elflink.h (size_dynamic_sections): Don't create various tags if
5064 .dynstr is excluded from the link. Don't set first dynsym entry
5065 if dynsymcount is zero.
5066 (elf_bfd_final_link): Don't try to swap out dynamic syms if
5067 .dynsym excluded from the link. Don't try to write any dynamic
5068 sections excluded from the link.
5069
5070 * elf.c (swap_out_syms): Handle global section symbols.
5071
5072 2000-10-05 DJ Delorie <dj@redhat.com>
5073
5074 * peigen.c (_bfd_pei_swap_scnhdr_out): note extended relocs
5075 * coffcode.h (coff_set_alignment_hook): read extended reloc count
5076 (coff_write_relocs): write extended reloc count
5077 (coff_write_object_contents): account for extended relocs
5078
5079 2000-10-05 Jim Wilson <wilson@cygnus.com>
5080
5081 * elf-bfd.h (struct elf_backend_data): Add elf_backend_section_flags
5082 field.
5083 * elf.c (_bfd_elf_make_section_from_shdr): Call the
5084 elf_backend_section_flags function.
5085 * elf64-ia64.c (elf64_ia64_section_from_shdr): Delete flag conversion
5086 code.
5087 (elf64_ia64_section_flags): New function containing flag conversion
5088 code.
5089 (elf_backend_section_flags): Define to elf64_ia64_section_flags.
5090 * elfxx-target.h (elf_backend_section_flags): Define.
5091 (elfNN_bed): Initialize elf_backend_section_flags field.
5092
5093 2000-10-02 Alan Modra <alan@linuxcare.com.au>
5094
5095 * elf32-hppa.c (elf32_hppa_check_relocs): Correct call to
5096 _bfd_elf32_gc_record_vtable. Correct a comment.
5097
5098 2000-10-01 Ulf Carlsson <ulfc@engr.sgi.com>
5099
5100 From Ralf Baechle <ralf@gnu.org>
5101
5102 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Mark gld
5103 produces binaries with got[1] = 0x80000001 to differenciate them
5104 for the dynamic linker from the broken binaries produced by old
5105 versions.
5106
5107 2000-09-30 Petr Sorfa <petrs@sco.com>
5108
5109 * elf.c (elfcore_grok_pstatus): Check for size of pxstatus_t.
5110 (elfcore_grok_lwpstatus): Check for size of lwpxstatus_t.
5111 * configure.in: Add check for pxstatus_t and lwpxstatus_t.
5112 * configure: Regenerate.
5113
5114 2000-09-27 Hans-Peter Nilsson <hp@axis.com>
5115
5116 Define two bfd_targets for absence and presence of leading
5117 underscore on symbols. Make sure to only link same kind.
5118 * elf32-cris.c (cris_elf_object_p,
5119 cris_elf_final_write_processing, cris_elf_print_private_bfd_data,
5120 cris_elf_merge_private_bfd_data): New.
5121 (elf_backend_object_p, elf_backend_final_write_processing,
5122 bfd_elf32_bfd_print_private_bfd_data,
5123 bfd_elf32_bfd_merge_private_bfd_data): Define.
5124 <Target vector definition>: Include elf32-target.h twice with
5125 different macro settings:
5126 (TARGET_LITTLE_SYM): First as bfd_elf32_cris_vec, then as
5127 bfd_elf32_us_cris_vec.
5128 (TARGET_LITTLE_NAME): First as "elf32-cris", then "elf32-us-cris".
5129 (elf_symbol_leading_char): First as 0, then '_'.
5130 (INCLUDED_TARGET_FILE): Define for second include of elf32-target.h.
5131 * config.bfd (cris-*-*): Add bfd_elf32_us_cris_vec to targ_selvecs.
5132 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vector.
5133 * configure: Regenerate.
5134 * targets.c: Declare bfd_elf32_us_cris_vec.
5135 * po/bfd.pot: Regenerate.
5136
5137 2000-09-29 Momchil Velikov <velco@fadata.bg>
5138
5139 * elf32-arm.h (arm_add_to_rel): Correctly adjust the addend for
5140 R_ARM_THM_PC22 relocations.
5141
5142 2000-09-29 NIIBE Yutaka <gniibe@chroot.org>
5143
5144 * elflink.h (elf_link_add_object_symbols): Don't bfd_release runpath.
5145
5146 2000-09-29 Momchil Velikov <velco@fadata.bg>
5147
5148 * elf.c (elf_fake_sections): Do not mark the section SHT_NOBITS if
5149 is has the SEC_HAS_CONTENTS flag set.
5150
5151 2000-09-28 \81Örjan Friberg <orjanf@axis.com>
5152 Hans-Peter Nilsson <hp@axis.com>
5153
5154 * aout-cris.c (N_TXTADDR): Define.
5155
5156 2000-09-28 John David Anglin <dave@hiauly1.hia.nrc.ca>
5157
5158 * som.c: Include alloca-conf.h.
5159 * Makefile.am: "make dep-am"
5160 * Makefile.in: Regenerate.
5161
5162 2000-09-27 Alan Modra <alan@linuxcare.com.au>
5163
5164 * elf32-hppa.c (plt_stub): New.
5165 (PLT_STUB_ENTRY): Define.
5166 (elf32_hppa_link_hash_table): Change multi_subspace to packed
5167 boolean. Add need_plt_stub, has_12bit_branch and has_17bit_branch.
5168 (elf32_hppa_link_hash_table_create): Init to suit.
5169 (elf32_hppa_check_relocs): Set has_12bit_branch and
5170 has_17bit_branch as appropriate.
5171 (elf32_hppa_adjust_dynamic_symbol): Set need_plt_stub for
5172 non-local functions.
5173 (elf32_hppa_size_dynamic_sections): Correct setting of reltext.
5174 Add space for plt_stub as needed.
5175 (elf32_hppa_finish_dynamic_symbol): Point .plt entries for global
5176 functions at plt_stub.
5177 (elf32_hppa_finish_dynamic_sections): Write plt_stub.
5178 (elf32_hppa_create_dynamic_sections): Leave .plt executable.
5179
5180 * elf32-hppa.h (elf32_hppa_size_stubs): Add group_size param.
5181 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise. Use it instead
5182 of fixed size, and if negative, disable handling of input sections
5183 before stub section. Set up default stub group size depending
5184 on detected branch relocs.
5185 (hppa_build_one_stub): Use lrsel and rrsel for import stubs to
5186 ensure different offsets from sym_value aren't rounded to
5187 different 2k blocks. Use lrsel and rrsel for other stubs too for
5188 consistency rather than necessity.
5189 (elf32_hppa_check_relocs): Handle R_PARISC_DIR14F.
5190 (final_link_relocate): Likewise.
5191 (elf32_hppa_relocate_section): Likewise.
5192
5193 * elf-hppa.h (elf_hppa_howto_table): Add R_PARISC_DIR14F reloc.
5194 (_bfd_elf_hppa_gen_reloc_type): Generate them.
5195 (elf_hppa_final_link_relocate): Handle them.
5196 (elf_hppa_relocate_insn): Likewise.
5197 (_bfd_elf_hppa_gen_reloc_type): Add missing e_ldsel and e_rdsel cases.
5198
5199 2000-09-26 Hans-Peter Nilsson <hp@axis.com>
5200
5201 * elfcode.h (elf_object_p): Preserve and clear abfd section
5202 information. Restore at error.
5203
5204 2000-09-26 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
5205
5206 * peigen.c (_bfd_pei_swap_aouthdr_in): If some DataDirectory
5207 is empty, make sure that its rva also 0. NT loader dislikes
5208 having otherwise.
5209
5210 2000-09-26 Steve Ellcey <sje@cup.hp.com>
5211
5212 * som.c (som_bfd_derive_misc_symbol_info): Make weak symbols
5213 global by default.
5214
5215 2000-09-21 Alan Modra <alan@linuxcare.com.au>
5216
5217 * elf32-hppa.c (elf32_hppa_check_relocs): Fix weak sym handling in
5218 currently unused RELATIVE_DYNAMIC_RELOCS code.
5219 (hppa_discard_copies): Likewise.
5220 (elf32_hppa_size_stubs): Size `input_list' array correctly. Correct
5221 comments. Don't check non-code output sections for stub grouping.
5222
5223 2000-09-20 Alan Modra <alan@linuxcare.com.au>
5224
5225 * section.c (bfd_get_unique_section_name): Return NULL if
5226 bfd_malloc fails.
5227
5228 2000-09-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5229
5230 * elf32-m68k.c (elf_cpu32_plt0_entry): Change the PLT entry 0
5231 instruction sequence to actually work.
5232 (elf_m68k_finish_dynamic_sections): Change the patch-in offset
5233 accordingly.
5234
5235 2000-09-18 Alexandre Oliva <aoliva@redhat.com>
5236
5237 * elf32-sh.c (sh_elf_relocate_section): Use
5238 _bfd_final_link_relocate to apply the relocation against a section
5239 symbol, when doing relocatable links.
5240
5241 2000-09-18 Alan Modra <alan@linuxcare.com.au>
5242
5243 * elf32-hppa.c (elf32_hppa_stub_hash_entry): Rename input_section
5244 to id_sec.
5245 (stub_hash_newfunc): Here too.
5246 (hppa_add_stub): And here.
5247 (elf32_hppa_link_hash_table): Remove stub_section_created,
5248 reloc_section_created, first_init_sec and first_fini_sec. Add
5249 stub_group.
5250 (elf32_hppa_link_hash_table_create): Init to suit.
5251 (hppa_get_stub_entry): Add support for grouping stub sections.
5252 (hppa_add_stub): Likewise. Remove sec_count param and init/fini
5253 section code. Index stub vars by section->id.
5254 (elf32_hppa_size_stubs): Likewise. Remove duplicated function
5255 exit paths. Zap allocation of above removed vars. Refine
5256 link-once test.
5257
5258 * elf32-hppa.h (elf32_hppa_size_stubs): Add output_bfd param.
5259 * elf32-hppa.c (elf32_hppa_size_stubs): Likewise.
5260 (hppa_get_stub_entry): Pass in pointer to elf32_hppa_link_hash_table
5261 rather than pointer to bfd_link_info.
5262 (hppa_add_stub): Likewise.
5263 (final_link_relocate): Likewise.
5264
5265 2000-09-17 David Huggins-Daines <dhd@linuxcare.com>
5266
5267 (elf32_hppa_size_stubs): Don't try to build stubs for discarded
5268 link-once sections.
5269
5270 2000-09-16 Alexandre Oliva <aoliva@redhat.com>
5271
5272 * elf32-sh.c (ELF_MAXPAGESIZE): Define to 128, to match
5273 ld/emulparams/shelf.sh.
5274
5275 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5276
5277 * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): New function.
5278 * bfd-in.h (bfd_m68k_elf32_create_embedded_relocs): Add declaration.
5279 * bfd-in2.h: Regenerate.
5280
5281 2000-09-15 Kenneth Block <Kenneth.Block@compaq.com>
5282
5283 * elf64-alpha.c (elf64_alpha_relax_with_lituse): ld performs
5284 LITUSE relocations incorrectly if -relax is specified on the ld
5285 command line and the displacement field of the load or store
5286 instruction is non-zero. (Patch by paul.winalski@compaq.com)
5287
5288 2000-09-15 Alan Modra <alan@linuxcare.com.au>
5289
5290 * elf32-hppa.c (hppa_add_stub): Dont set first_init_sec and
5291 first_fini_sec here.
5292 (elf32_hppa_size_stubs): Instead correctly find the first .init
5293 and .fini section here.
5294
5295 2000-09-15 David Huggins-Daines <dhd@linuxcare.com>
5296
5297 * elf32-hppa.c (clobber_millicode_symbols): New function.
5298 (elf32_hppa_size_dynamic_sections): Call it.
5299
5300 2000-09-14 Alan Modra <alan@linuxcare.com.au>
5301
5302 * elf32-hppa.c (elf32_hppa_link_hash_entry): Make pic_call
5303 packed. Add plabel, plt_abs packed booleans.
5304 (hppa_link_hash_newfunc): Init new fields.
5305 (PLABEL_PLT_ENTRY_SIZE): Define.
5306 (hppa_stub_name): Use size_t len vars.
5307 (hppa_add_stub): Likewise.
5308 (elf32_hppa_build_stubs): Likewise.
5309 (hppa_build_one_stub): Kill some compiler warnings.
5310 (elf32_hppa_check_relocs): Always generate a plt entry for PLABELs
5311 if dynamic linking. Munge the local plt offsets into
5312 local_got_refcounts. Set h->plabel for all global PLABELs. Use
5313 size_t len vars. Add assert for plabel addend.
5314 (elf32_hppa_gc_sweep_hook): Sweep local plt entries too.
5315 (elf32_hppa_hide_symbol): New function.
5316 (elf_backend_hide_symbol): Define.
5317 (elf32_hppa_adjust_dynamic_symbol): Don't throw away plt entries
5318 with h->plabel set. Don't make plt entries to have dynamic syms
5319 when they have been forced local. If plt entry is used by a
5320 plabel, make it PLABEL_PLT_ENTRY_SIZE.
5321 (elf32_hppa_size_dynamic_sections): Set plt_abs for init fns.
5322 Set up .plt offsets for local syms.
5323 (elf32_hppa_relocate_section): Initialise plt entries for local
5324 syms. Leave weak undefined plabels zero. Make global plabel
5325 relocs against function symbol, and leave the addend zero.
5326 Use *ABS* DIR32 relocs instead of SEGREL32 for dynamic got relocs.
5327 (elf32_hppa_finish_dynamic_symbol): Set up IPLT relocs for
5328 non-dynamic syms. Init extra plt for plabels. Use *ABS* DIR32
5329 relocs instead of SEGREL32 for dynamic got relocs.
5330 (elf32_hppa_finish_dynamic_sections): Reserve one more .got entry.
5331 (elf_backend_got_header_size): Adjust.
5332 (elf32_hppa_set_gp): Calculate an "ideal" LTP.
5333
5334 * elf32-hppa.c (LONG_BRANCH_VIA_PLT): Define.
5335 (hppa_type_of_stub): Use it instead of #if 0
5336 (hppa_discard_copies): Use it here too.
5337 (elf32_hppa_size_dynamic_sections): And here.
5338
5339 * elf32-hppa.c (elf32_hppa_link_hash_table): Remove `offset' field.
5340 (elf32_hppa_link_hash_table_create): And here.
5341 (hppa_build_one_stub): And here. Instead keep track of stub
5342 offset using _raw_size.
5343 (elf32_hppa_size_stubs): Likewise.
5344 (elf32_hppa_build_stubs): Likewise.
5345 (hppa_size_one_stub): Likewise. Resize reloc section too.
5346
5347 * elf32-hppa.c (hppa_add_stub): Correct first_init_sec and
5348 first_fini_sec handling. Don't search for reloc section or set
5349 hplink->reloc_section_created here.
5350 (elf32_hppa_size_stubs): Instead search for reloc sections, and
5351 set reloc_section_created here.
5352 (hppa_handle_PIC_calls): Set ELF_LINK_HASH_NEEDS_PLT.
5353 (elf32_hppa_size_dynamic_sections): Make a .plt entry for DT_INIT
5354 and DT_FINI.
5355 (elf32_hppa_finish_dynamic_sections): Set DT_INIT and DT_FINI.
5356
5357 * elf32-hppa.c (hppa_build_one_stub): Replace `elf_hash_table (info)'
5358 with `hplink->root.'.
5359 (elf32_hppa_check_relocs): Likewise.
5360 (elf32_hppa_gc_sweep_hook): Likewise.
5361 (elf32_hppa_adjust_dynamic_symbol): Likewise.
5362 (hppa_handle_PIC_calls): Likewise.
5363 (elf32_hppa_size_dynamic_sections): Likewise.
5364 (elf32_hppa_set_gp): Likewise.
5365 (elf32_hppa_relocate_section): Likewise.
5366 (elf32_hppa_finish_dynamic_symbol): Likewise.
5367 (elf32_hppa_finish_dynamic_sections): Likewise.
5368
5369 From David Huggins-Daines <dhd@linuxcare.com>
5370 * elf32-hppa.c (hppa_type_of_stub): Generate import stubs for
5371 defined weak symbols in shared links.
5372 (final_link_relocate): Calls to defined weak symbols in shared
5373 objects must go via import stubs, as the target might not be known
5374 at link time.
5375
5376 2000-09-14 Alexandre Oliva <aoliva@redhat.com>
5377
5378 * elf32-sh.c (sh_elf_howto_table): Moved R_SH_GOT32, R_SH_PLT32,
5379 R_SH_COPY, R_SH_GLOB_DAT, R_SH_JMP_SLOT, R_SH_RELATIVE,
5380 R_SH_GOTOFF, R_SH_GOTPC) to the range from 160 to 167. Replaced
5381 the original entries with EMPTY_HOWTOs, and added new ones to fill
5382 in the gap.
5383 (sh_elf_info_to_howto): Make sure the new gap isn't used.
5384 (sh_elf_relocate_section): Likewise.
5385
5386 2000-09-13 Anders Norlander <anorland@acc.umu.se>
5387
5388 * cpu-mips.c (arch_info_struct): Add mips:4K
5389 * bfd-in2.h (bfd_mach_mips4K): New define.
5390 * archures.c: Add bfd_mach_mips4K to comment.
5391 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Return
5392 E_MIPS_ARCH_2 for bfd_mach_mips4K.
5393
5394 2000-09-13 Marco Franzen <marcof@thyron.com>
5395
5396 * som.c (som_write_symbol_strings): Do not used fixed buffers,
5397 use size_t as a counter.
5398 (som_write_space_strings): Similarly.
5399
5400 2000-09-12 Jason Eckhardt <jle@cygnus.com>
5401
5402 * elf32-i860.c (elf32_i860_relocate_pc26): New function
5403 and prototype.
5404 (elf32_i860_relocate_section): Invoke new function from here.
5405
5406 2000-09-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5407
5408 * elf.c (_bfd_elf_make_section_from_shdr): Make debug_sec_names
5409 static.
5410
5411 2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5412
5413 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): Emit 8 NULs for
5414 target section name instead of dumping core when the target symbol is
5415 undefined.
5416
5417 2000-09-09 Kazu Hirata <kazu@hxi.com>
5418
5419 * riscix.c: Remove DEFUN.
5420
5421 2000-09-08 Nick Clifton <nickc@redhat.com>
5422
5423 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Do not
5424 initialise flags in output bfd if the input bfd is the default
5425 architecture with the default flags.
5426
5427 2000-09-08 Kazu Hirata <kazu@hxi.com>
5428
5429 * archive.c: Fix formatting.
5430 * coff-arm.c: Likewise.
5431 * doc/chew.c: Likewise.
5432
5433 2000-09-08 Alan Modra <alan@linuxcare.com.au>
5434
5435 * section.c (bfd_get_unique_section_name): Put a dot before the
5436 numeric suffix.
5437
5438 2000-09-07 Kazu Hirata <kazu@hxi.com>
5439
5440 * doc/chew.c: Remove all uses of DEFUN and DEFUN_VOID.
5441 * elf.c: Fix formatting.
5442
5443 2000-09-07 Alexandre Oliva <aoliva@redhat.com>
5444
5445 * config.bfd (sh-*-linux*): Added.
5446 * configure.in (bfd_elf32_shlin_vec, bfd_elf32_shblin_vec): New.
5447 * targets.c: Declare them.
5448 * elf32-sh-lin.c: New file.
5449 * Makefile.am: Compile it.
5450 * elf32-sh.c: Don't override defines from elf32-sh-lin.c.
5451 * configure, Makefile.in: Rebuilt.
5452
5453 2000-09-06 Geoffrey Keating <geoffk@cygnus.com>
5454
5455 * xcofflink.c (xcoff_link_input_bfd): Include the .tocbss
5456 pseduo-section when determining where the TOC ends.
5457
5458 * coff-rs6000.c (_bfd_xcoff_swap_aux_out): Use bfd_h_put_16 to
5459 output x_tvndx as it is only two bytes wide.
5460
5461 * coff-rs6000.c (xcoff_howto_table): A modifiable branch-absolute
5462 reloc is 26 or 32 bits wide.
5463
5464 * coff-rs6000.c (_bfd_xcoff_rtype2howto): The bitsize is irrelevant
5465 for relocs that don't change anything. Also look at the full
5466 6 bits of bitsize.
5467
5468 2000-09-06 Philip Blundell <philb@gnu.org>
5469
5470 * config.bfd (arm*-*-uclinux*): New target.
5471
5472 2000-09-06 Alexandre Oliva <aoliva@redhat.com>
5473
5474 * configure: Rebuilt with new libtool.m4.
5475
5476 2000-09-06 Alan Modra <alan@linuxcare.com.au>
5477
5478 * section.c (bfd_get_unique_section_name): Avoid c++ reserved
5479 word for variable name.
5480 * bfd-in2.h: Regenerate.
5481
5482 2000-09-05 Nick Clifton <nickc@redhat.com>
5483
5484 * config.in: Regenerate.
5485 * libbfd.h: Regenerate.
5486 * po/bfd.pot: Regenerate.
5487 * doc/bfdint.texi: Remove CVS date string - it foils compares with
5488 local versions.
5489
5490 2000-09-05 Steven Johnson <sbjohnson@ozemail.com.au>
5491
5492 * cpu-powerpc.c (arch_info_struct): Added MPC860 Family entry.
5493
5494 2000-09-05 Alan Modra <alan@linuxcare.com.au>
5495
5496 Shared library and PIC support.
5497 * elf32-hppa.c (PLT_ENTRY_SIZE): New.
5498 (GOT_ENTRY_SIZE): New.
5499 (ELF_DYNAMIC_INTERPRETER): New.
5500 (STUB_SUFFIX): Define.
5501 (LONG_BRANCH_PIC_IN_SHLIB): Define.
5502 (RELATIVE_DYNAMIC_RELOCS): Define.
5503 (enum elf32_hppa_stub_type): New.
5504 (struct elf32_hppa_stub_hash_entry): Rename offset to
5505 stub_offset. Add a number of new fields.
5506 (struct elf32_hppa_link_hash_entry): New.
5507 (struct elf32_hppa_link_hash_table): Add numerous fields. Remove
5508 global_value.
5509 (elf32_hppa_hash_table): Rename to hppa_link_hash_table.
5510 (elf32_hppa_stub_hash_lookup): Rename to hppa_stub_hash_lookup.
5511 (elf32_hppa_stub_hash_newfunc): Rename to stub_hash_newfunc. Init
5512 new fields.
5513 (hppa_link_hash_newfunc): New function.
5514 (elf32_hppa_link_hash_table_create): Use above function. Init new
5515 fields.
5516 (elf32_hppa_stub_name): Rename to hppa_stub_name. Pass in reloc
5517 instead of addend, and remove sym_name from args. Don't use
5518 symbol name for local syms, instead use sym index.
5519 (elf32_hppa_size_of_stub): Rename to hppa_type_of_stub, and return
5520 stub type rather than size. Pass in hash and handle import stub
5521 case. Also pass in reloc instead of offset so we can calculate
5522 PCREL22F and PCREL12F branches properly.
5523 (elf32_hppa_build_one_stub): Rename to hppa_build_one_stub. Build
5524 import and export stubs too.
5525 (elf32_hppa_size_one_stub): Rename to hppa_size_one_stub. Handle
5526 import and export stub sizing.
5527 (elf32_hppa_check_relocs): New function.
5528 (elf32_hppa_adjust_dynamic_symbol): New function.
5529 (hppa_discard_copies): New function.
5530 (elf32_hppa_size_dynamic_sections): New function.
5531 (elf_backend_size_dynamic_sections): Define.
5532 (elf32_hppa_finish_dynamic_symbol): New function.
5533 (elf_backend_finish_dynamic_symbol): Define.
5534 (elf32_hppa_size_stubs): Stash params in link hash table, and move
5535 some local vars into the link hash table too. For shared links,
5536 trundle over function syms, generating export stubs. Handle
5537 PCREL22F branches. Break out stub creation code from here..
5538 (hppa_add_stub): .. to here. New function.
5539 (elf32_hppa_final_link): Rename to elf32_hppa_set_gp, and don't
5540 call the bfd linker. Use elf_gp to record global pointer.
5541 Calculate a value from sections if $global$ is missing.
5542 (bfd_elf32_bfd_final_link): Define as _bfd_elf32_gc_common_final_link.
5543 (elf32_hppa_gc_mark_hook): New function.
5544 (elf_backend_gc_mark_hook): Define.
5545 (elf32_hppa_gc_sweep_hook): New function.
5546 (elf_backend_gc_sweep_hook): Define.
5547 (elf32_hppa_bfd_final_link_relocate): Rename to final_link_relocate.
5548 Add rel to args, and remove howto, input_bfd, offset, addend,
5549 sym_name as we can recalculate these locally. Handle calls to
5550 dynamic objects, extra PIC relocs, PCREL22F branches. Change
5551 handling of undefined weak syms. Check that stubs are in range.
5552 Only look for import stubs on PCREL17F and PCREL22F relocs. Add
5553 message on hitting a DPREL21L reloc that needs fixing. Subtract
5554 off PC for PCREL14F. Break out code that does a stub lookup from
5555 here..
5556 (hppa_get_stub_entry): ..to here. New function.
5557 (elf32_hppa_relocate_insn): Merge into final_link_relocate.
5558 (elf32_hppa_relocate_section): Handle got and plt relocs, dynamic
5559 relocs, etc. etc.
5560 (elf32_hppa_finish_dynamic_sections): New function.
5561 (elf_backend_finish_dynamic_sections): Define.
5562 (elf_backend_final_write_processing) Define.
5563 (hppa_handle_PIC_calls): New function.
5564 (elf32_hppa_build_stubs): Call it. Pass link_info to
5565 hppa_build_one_stub.
5566 (elf32_hppa_create_dynamic_sections): New function
5567 to create .plt and .got then set .plt flags correctly.
5568 (elf_backend_create_dynamic_sections): Define.
5569 (elf32_hppa_object_p): New function.
5570 (elf_backend_object_p): Define.
5571 (elf32_hppa_elf_get_symbol_type): New function.
5572 (elf_backend_get_symbol_type): Define.
5573 (elf_backend_can_gc_sections): Define.
5574 (elf_backend_want_got_plt): Define.
5575 (elf_backend_plt_alignment): Set to 2.
5576 (elf_backend_plt_readonly): Define.
5577 (elf_backend_want_plt_sym): Define.
5578 (elf_backend_got_header_size): Reserve one entry.
5579
5580 * elf32-hppa.h (elf32_hppa_build_stubs): Don't pass stub bfd.
5581 (elf32_hppa_size_stubs): Pass in multi_subspace.
5582 (elf32_hppa_set_gp): Declare.
5583
5584 * section.c (SEC_HAS_GOT_REF): Define new flag for asection.
5585 (bfd_get_unique_section_name): New function.
5586 * bfd-in2.h: Regenerate.
5587
5588 * elf64-hppa.c (elf64_hppa_check_relocs): Handle R_PARISC_PCREL12F.
5589 (elf64_hppa_size_dynamic_sections): Remove the FIXME at bfd_zalloc
5590 comment.
5591
5592 From David Huggins-Daines <dhd@linuxcare.com>
5593 * elf64-hppa.c (elf64_hppa_check_relocs): Fix a warning.
5594 (elf64_hppa_mark_exported_functions): Set dyn_h->st_shndx.
5595 (elf64_hppa_link_output_symbol_hook): Test dyn_h->st_shndx has
5596 been updated in finish_dynamic_symbol before modifying function
5597 symbol.
5598
5599 * elf-hppa.h (elf_hppa_howto_table): Restructure into groups of
5600 eight entries. Replace NULL with bfd_elf_generic_reloc. Add
5601 R_PARISC_GNU_VTENTRY, R_PARISC_GNU_VTINHERIT and R_PARISC_PCREL12F.
5602 (_bfd_elf_hppa_gen_reloc_type): Handle R_PARISC_GNU_VT*. Add some
5603 comments. Handle format == 12 for R_HPPA_PCREL_CALL.
5604 (elf_hppa_final_link_relocate): Handle R_PARISC_PCREL12F.
5605 (elf_hppa_relocate_insn): Likewise. Reformat some comments.
5606 (elf_hppa_final_write_processing): Expose it for ARCH_SIZE == 32.
5607
5608 From David Huggins-Daines <dhd@linuxcare.com>
5609 * elf-hppa.h (elf_hppa_is_local_label_name): Accept the SysV/ELF
5610 style of local labels as well.
5611
5612 2000-09-03 Philip Blundell <philb@gnu.org>
5613
5614 * elf32-arm.h (elf32_arm_relocate_section): Don't try to relocate
5615 references to undefined symbols in debugging sections.
5616
5617 2000-09-02 H.J. Lu <hjl@gnu.org>
5618
5619 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
5620 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE,
5621 BFD_RELOC_SH_GOTPC): Move them from the MIPS section to the SH
5622 section.
5623
5624 2000-09-02 Jason Eckhardt <jle@cygnus.com>
5625
5626 * elf32-i860.c (bfd_elf32_bfd_is_local_label_name): Define macro.
5627 (elf32_i860_is_local_label_name): New function and prototype.
5628
5629 2000-09-02 Nick Clifton <nickc@redhat.com>
5630
5631 * configure.in: Increase version number to 2.10.91.
5632 * configure: Regenerate.
5633 * aclocal.m4: Regenerate.
5634 * config.in: Regenerate.
5635 * po/bfd.pot: Regenerate.
5636
5637 2000-09-02 Daniel Berlin <dberlin@redhat.com>
5638
5639 * elf.c (_bfd_elf_make_section_from_shdr): Add
5640 .gnu.linkobce.wi. to the list of debug section names.
5641
5642 2000-09-02 Nick Clifton <nickc@redhat.com>
5643
5644 * dwarf2.c (find_debug_info): New function: Locate a section
5645 containing dwarf2 debug information.
5646 (bfd_dwarf2_find_nearest_line): Find all sections containing
5647 debug information and include them in the stash.
5648
5649 2000-09-01 Niibe Yutaka <gniibe@m17n.org>, Kaz Kojima <kkojima@rr.iij4u.or.jp>, Alexandre Oliva <aoliva@redhat.com>
5650
5651 * elf32-sh.c (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
5652 R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): New.
5653 (sh_reloc_map): Add new relocs.
5654 (sh_elf_check_relocs, sh_elf_link_hash_newfunc,
5655 sh_elf_link_hash_table_create, sh_elf_adjust_dynamic_symbol,
5656 sh_elf_size_dynamic_sections, sh_elf_finish_dynamic_symbol,
5657 sh_elf_finishe_dynamic_sections, sh_elf_discard_copies): New
5658 functions.
5659 (ELF_DYNAMIC_INTERPRETER, PLT_ENTRY_SIZE): Define.
5660 (elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
5661 elf_sh_plt_entry_be, elf_sh_plt_entry_le,
5662 elf_sh_pic_plt_entry_be, elf_sh_pic_plt_entry_le):
5663 New array constants.
5664 (elf_sh_plt0_entry, elf_sh_plt_entry, elf_sh_pic_plt_entry):
5665 New variables.
5666 (elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
5667 elf_sh_plt0_linker_offset, elf_sh_plt0_gotid_offset,
5668 elf_sh_plt_temp_offset, elf_sh_plt_symbol_offset,
5669 elf_sh_plt_reloc_offset): Define.
5670 (elf_sh_pcrel_relocs_copied, elf_sh_link_hash_entry,
5671 elf_sh_link_hash_table): New structs.
5672 (sh_elf_link_hash_traverse, sh_elf_hash_table): New macros.
5673 (sh_elf_relocate_section, sh_elf_check_relocs): Handle new
5674 relocation types.
5675 (elf_backend_create_dynamic_sections,
5676 bfd_elf32_bfd_link_hash_table_create,
5677 elf_backend_adjust_dynamic_symbol,
5678 elf_backend_size_dynamic_sections,
5679 elf_backend_finish_dynamic_symbol,
5680 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
5681 elf_backend_plt_readonly, elf_backend_want_plt_sym,
5682 elf_backend_got_header_size, elf_backend_plt_header_size):
5683 Define.
5684 * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
5685 BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE, BFD_RELOC_SH_GOTPC):
5686 New relocs.
5687 * bfd-in2.h, libbfd.h: Rebuilt.
5688
5689 2000-09-01 Alan Modra <alan@linuxcare.com.au>
5690
5691 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Revert 2000-08-27
5692 change.
5693
5694 2000-08-31 J"orn Rennecke <amylaar@cygnus.co.uk>
5695
5696 * elf32-sh.c (sh_elf_merge_private_data): If ibfd's elf header flags
5697 not initialized, set them to indicate the SH1 instruction set.
5698
5699 2000-08-31 Alexandre Oliva <aoliva@redhat.com>
5700
5701 * acinclude.m4: Include libtool and gettext macros from the
5702 top level.
5703 * aclocal.m4, configure: Rebuilt.
5704
5705 2000-08-29 Michael Snyder <msnyder@seadog.cygnus.com>
5706
5707 * elf.c: Eliminate references to __sparcv9 macro; replace with
5708 autoconf variables HAVE_PSINFO32_T etc.
5709 * configure.in: Auto-configure HAVE_PSINFO_32_T, HAVE_PRPSINFO32_T,
5710 HAVE_PSTATUS32_T, HAVE_PRSTATUS32_T, HAVE_PRSTATUS32_T_PR_WHO.
5711 * config.in: Ditto.
5712 * acinclude.m4 (BFD_HAVE_SYS_PROCFS_TYPE) define _SYSCALL32 so it can
5713 detect the above typedefs. (BFD_HAVE_SYS_PROCFS_TYPE_MEMBER): Ditto.
5714 * aclocal.m4: Ditto.
5715 * configure: Regenerate.
5716
5717 2000-08-27 Alan Modra <alan@linuxcare.com.au>
5718
5719 * elf32-i386.c (elf_i386_check_relocs): Keep info on relocs copied
5720 for any shared link, not just shared -Bsymbolic.
5721 (elf_i386_size_dynamic_sections): Call elf_i386_discard_copies on
5722 any shared link, and pass link info to it.
5723 (elf_i386_size_dynamic_sections): Update comment.
5724 (elf_i386_discard_copies): Modify to discard relocs for symbols
5725 that have been forced local.
5726 (elf_i386_finish_dynamic_symbol): Don't copy relocs for symbols
5727 that have been forced local.
5728
5729 2000-08-24 Denis Chertykov <denisc@overta.ru> & Nick Clifton <nickc@redhat.com>
5730
5731 * elflink.h (elf_link_add_object_symbols): Allow common
5732 symbols to have an alignment of 1 if explicitly requested, and
5733 not overridden by other definitions.
5734
5735 2000-08-22 Doug Kwan <dkwan@transmeta.com>
5736
5737 * coff-w65.c (CREATE_LITTLE_COFF_TARGET): Fix typo.
5738 * coffcode.h (coff_set_flags): Add detection of w65 architecture.
5739
5740 2000-08-22 H.J. Lu <hjl@gnu.org>
5741
5742 * elf-bfd.h (elf_link_hash_table): Add runpath.
5743
5744 * bfd-in.h (bfd_elf_get_runpath_list): New prototype.
5745 * bfd-in2.h: Rebuilt.
5746
5747 * elf.c (_bfd_elf_link_hash_table_init): Initialize the
5748 "runpath" field to NULL.
5749 (bfd_elf_get_runpath_list): New function.
5750
5751 * elflink.h (elf_link_add_object_symbols): Record DT_RPATH and
5752 DT_RUNPATH entries.
5753
5754 2000-08-22 Alexandre Oliva <aoliva@redhat.com>
5755
5756 * elf32-sh.c (sh_elf_relocate_section) [R_SH_IND12W,
5757 R_SH_DIR8WPN, R_SH_DIR8WPZ, R_SH_DIR8WPL]: Handle them
5758 explicitly. Improve validation of r_type.
5759
5760 2000-08-21 H.J. Lu <hjl@gnu.org>
5761
5762 * elf32-i386.c (elf_i386_size_dynamic_sections): Zero out the
5763 dynamic allocated content space. Add a comment to remind us that
5764 one day this ought to be fixed.
5765 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
5766 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
5767 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
5768
5769 2000-08-21 Jason Eckhardt <jle@cygnus.com>
5770
5771 * elf32-i860.c (elf32_i860_relocate_pc16): Just write the immediate
5772 field with the newly relocated value instead of adding it to the
5773 existing immediate field.
5774 (elf32_i860_relocate_splitn): Likewise.
5775 (elf32_i860_relocate_highadj): Likewise.
5776
5777 2000-08-16 Jason Eckhardt <jle@cygnus.com>
5778
5779 * elf32-i860.c (elf32_i860_relocate_pc16): Implemented function (it
5780 was previously just a stub).
5781
5782 2000-08-16 Alexandre Oliva <aoliva@redhat.com>
5783
5784 * elflink.c (_bfd_elf_create_got_section): Don't abort().
5785 Formatting fixes.
5786 (_bfd_elf_create_dynamic_sections): Likewise.
5787
5788 2000-08-16 Andrew Macleod <amacleod@cygnus.com>
5789
5790 * elf64-sparc.c (sparc64_elf_relocate_section): Set relocation address
5791 for undefined symbols to be the beginning of the section.
5792
5793 * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Don't allocate
5794 four extra entries at the beginning of the .rela.plt section.
5795 (sparc64_elf_finish_dynamic_symbol): Adjust the offset in the .rela.plt
5796 section to account for the four reserved entries in the .plt section.
5797
5798 2000-08-15 Geoffrey Keating <geoffk@cygnus.com>
5799
5800 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Add ori r0,r0,0
5801 to the list of NOPs we recognize after a branch-and-link.
5802 Use the ori NOP when one is needed.
5803
5804 * coff-rs6000.c (_bfd_xcoff_slurp_armap): Finish implementation
5805 for large archives.
5806
5807 2000-08-14 Jim Wilson <wilson@cygnus.com>
5808
5809 * elf64-ia64.c (elf64_ia64_merge_private_bfd_data): Handle
5810 EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, and EF_IA_64_NOFUNCDESC_CONS_GP.
5811 (elf64_ia64_print_private_bfd_data): Likewise. Also handle
5812 EF_IA_64_ABSOLUTE.
5813
5814 2000-08-11 Alexandre Oliva <aoliva@redhat.com>
5815
5816 * elf32-sh.c (sh_elf_set_mach_from_flags): Make it static.
5817
5818 2000-08-10 Jason Eckhardt <jle@cygnus.com>
5819
5820 * elf32-i860.c (elf32_i860_relocate_section): New function.
5821 (i860_final_link_relocate): New function.
5822 (elf32_i860_relocate_splitn): New function.
5823 (elf32_i860_relocate_pc16): New function.
5824 (elf32_i860_relocate_highadj): New function.
5825 (elf32_i860_howto): Minor adjustments to some relocations.
5826 (elf_info_to_howto_rel): Define.
5827 (elf_backend_relocate_section): Define.
5828
5829 2000-08-10 Nick Clifton <nickc@cygnus.com>
5830
5831 * elf32-arm.h: Fix formatting.
5832
5833 2000-08-10 Bernd Schmidt <bernds@cygnus.co.uk>
5834
5835 * elf32-sh.c (sh_elf_reloc_loop): Make LAST_SYMBOL_SECTION static.
5836
5837 2000-08-08 Jason Eckhardt <jle@cygnus.com>
5838
5839 * elf32-i860.c (elf32_i860_howto_table): Updated some fields.
5840
5841 2000-08-07 Kazu Hirata <kazu@hxi.com>
5842
5843 * ieee.c (ieee_write_debug_part): Rewrite a comment.
5844 * elf64-ia64.c: Fix a typo.
5845
5846 2000-08-05 Jason Eckhardt <jle@cygnus.com>
5847
5848 * elf32-i860.c (elf32_i860_howto_table): New structure.
5849 (lookup_howto): New function.
5850 (elf32_i860_reloc_type_lookup): New function.
5851 (elf32_i860_info_to_howto_rela): New function.
5852 (elf_code_to_howto_index): New structure.
5853 (elf_info_to_howto): Re-define as elf32_i860_info_to_howto_rela.
5854 (bfd_elf32_bfd_reloc_type_lookup): Re-define as
5855 elf32_i860_reloc_type_lookup.
5856
5857 2000-08-04 Rodney Brown <RodneyBrown@pmsc.com>
5858
5859 * som.c (struct fixup_format): Constify `format'.
5860 (som_hppa_howto_table): Use SOM_HOWTO macro.
5861 (try_prev_fixup, hppa_som_reloc): Decorate unused parameter.
5862 (som_bfd_reloc_type_lookup): Likewise.
5863 (compare_subspaces): Remove unused `count1', `count2'.
5864 (som_begin_writing): Remove unused `total_reloc_size'.
5865 (som_bfd_derive_misc_symbol_info): Decorate unused parameter.
5866 (som_print_symbol, som_bfd_is_local_label_name): Likewise.
5867 (som_set_reloc_info): Constify `cp'. Remove unused `addend'.
5868 (som_find_nearest_line): Decorate unused parameter(s).
5869 (som_sizeof_headers, som_get_symbol_info, som_write_armap): Likewise.
5870 (som_bfd_link_split_section): Likewise.
5871
5872 2000-08-03 Nick Clifton <nickc@cygnus.com>
5873
5874 * section.c: Restore backed out code.
5875 * elf.c: Restore backed out code.
5876 (copy_private_bfd_data): Fix bug preventing stipped dynamic
5877 binaries from working.
5878 * bfd-in2.h: Regenerate.
5879
5880 2000-08-03 H.J. Lu <hjl@gnu.org>
5881
5882 * section.c: Back out the change made by Nick Clifton
5883 <nickc@cygnus.com> on 2000-07-31. It breaks stripping dynamic
5884 binaries.
5885 * bfd-in2.h: Likewise.
5886 * elf.c: Likewise.
5887
5888 2000-08-03 Alexandre Oliva <aoliva@redhat.com>
5889
5890 * elf32-sh.c (sh_elf_reloc_loop): Warning removal.
5891
5892 2000-07-31 Jason Eckhardt <jle@cygnus.com>
5893
5894 * reloc.c (BFD_RELOC_860_*): New bfd relocs for i860.
5895 * bfd-in2.h, libbfd.h: Regenerate.
5896
5897 2000-07-31 Nick Clifton <nickc@cygnus.com>
5898
5899 * section.c (struct sec): Add new boolean field 'segment_mark'.
5900 (STD_SECTION): Initialise new field to zero.
5901
5902 * bfd-in2.h: Regenerate.
5903
5904 * elf.c (copy_private_bfd_data): Reorganise section to segment
5905 mapping to cope with moved sections requiring new segments,
5906 and overlapping segments.
5907 (SEGMENT_END): New macro: Return the end address of a segment.
5908 (IS_CONTAINED_BY_VMA): New macro: Determine if a segment
5909 contains a section by comparing their VMA addresses.
5910 (IS_CONTAINED_BY_LMA): New macro: Determine if a segment
5911 contains a section by comparing their LMA addresses.
5912 (INCLUDE_SECTION_IN_SEGMENT): New macro: Determine if a
5913 section should be included in a segment.
5914 (SEGMENT_AFTER_SEGMENT): New macro: Determine if one segment
5915 follows another in memory.
5916 (SEGMENT_OVERLAPS_SEGMENT): New macro: Determine if two
5917 segments overlap.
5918
5919 2000-07-22 Jason Eckhardt <jle@cygnus.com>
5920
5921 * cpu-i860.c: Added comments.
5922
5923 * elf32-i860.c (TARGET_LITTLE_SYM): Defined to
5924 bfd_elf32_i860_little_vec.
5925 (TARGET_LITTLE_NAME): Defined to "elf32-i860-little".
5926 (ELF_MAXPAGESIZE): Changed to 4096.
5927
5928 * targets.c (bfd_elf32_i860_little_vec): Declaration of
5929 new target.
5930 (bfd_target_vector): Added bfd_elf32_i860_little_vec.
5931
5932 * config.bfd (i860-stardent-sysv4*, i860-stardent-elf*): Added
5933 config for little endian elf32 i860.
5934 (targ_defvec): Define for the new config above
5935 as "bfd_elf32_i860_little_vec".
5936 (targ_selvecs): Define for the new config above
5937 as "bfd_elf32_i860_vec bfd_elf32_i860_little_vec"
5938
5939 * configure.in (bfd_elf32_i860_little_vec): Added recognition
5940 of new target vec.
5941
5942 * configure: Regenerated.
5943
5944 2000-07-27 H.J. Lu <hjl@gnu.org>
5945
5946 * elflink.h (elf_merge_symbol): Take one more argument,
5947 dt_needed, to indicate if the symbol comes from a DT_NEEDED
5948 entry. Don't overide the existing weak definition if dt_needed
5949 is true.
5950 (elf_link_add_object_symbols): Pass dt_needed to
5951 elf_merge_symbol ().
5952
5953 2000-07-27 Nick Clifton <nickc@cygnus.com>
5954
5955 * elflink.h (elf_link_size_reloc_section): Zeroes the section's
5956 allocated contents.
5957
5958 2000-07-25 Geoffrey Keating <geoffk@cygnus.com>
5959
5960 * configure.host (*-*-aix*): AIX has 'long long' always.
5961
5962 * coff-rs6000.c (xcoff_write_one_armap_big): New procedure.
5963 (xcoff_write_armap_big): Write both 32-bit and 64-bit armaps.
5964 (xcoff_write_archive_contents_big): Don't update the offset
5965 of the symbol table, xcoff_write_armap will do it.
5966
5967 2000-07-23 Ulf Carlsson <ulfc@engr.sgi.com>
5968
5969 * elf32-mips.c (_bfd_mips_elf_check_relocs): Use abfd instead
5970 of dynobj for SGI_COMPAT checks.
5971
5972 2000-07-21 Michael Sokolov <msokolov@ivan.Harhan.ORG>
5973
5974 * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): New function.
5975 * bfd-in.h (bfd_m68k_coff_create_embedded_relocs): Add declaration.
5976 * bfd-in2.h: Regenerate.
5977
5978 2000-07-21 Nick Clifton <nickc@cygnus.com>
5979
5980 * elf32-mips.c (_bfd_mips_elf_check_relocs): Detect out of
5981 range symbol indices in relocs and issue an error message.
5982
5983 2000-07-20 H.J. Lu <hjl@gnu.org>
5984
5985 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Don't check
5986 info->new_dtags when setting DT_FLAGS_1. It will only be set
5987 by the new linker options. It shouldn't break anything.
5988
5989 2000-07-20 H.J. Lu <hjl@gnu.org>
5990
5991 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set DT_FLAGS_1
5992 only if info->new_dtags is true.
5993
5994 2000-07-20 H.J. Lu <hjl@gnu.org>
5995
5996 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set
5997 DT_RUNPATH and DT_FLAGS only if info->new_dtags is true.
5998
5999 2000-07-20 Hans-Peter Nilsson <hp@axis.com>
6000
6001 * Makefile.am (ALL_MACHINES): Add cpu-cris.lo.
6002 (ALL_MACHINES_CFILES): Add cpu-cris.c.
6003 (BFD32_BACKENDS): Add aout-cris.lo and elf32-cris.lo.
6004 (BFD32_BACKENDS_CFILES): Add aout-cris.c and elf32-cris.c.
6005 (cpu-cris.lo, aout-cris.lo, elf32-cris.lo): New rules.
6006 * Makefile.in: Rebuild.
6007 * aclocal.m4: Rebuild.
6008 * aoutx.h (NAME(aout,machine_type)): Add case for bfd_arch_cris.
6009 * archures.c (enum bfd_architecture): Add bfd_arch_cris.
6010 (bfd_cris_arch): Declare.
6011 (bfd_archures_list): Add bfd_cris_arch.
6012 * bfd-in2.h: Rebuild.
6013 * config.bfd: (cris-*-*): New target.
6014 * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vectors.
6015 * configure: Rebuild.
6016 * elf.c (prep_headers): Add bfd_arch_cris.
6017 * libbfd.h: Rebuild.
6018 * libaout.h (enum machine_type): Add M_CRIS.
6019 * reloc.c: Add CRIS relocations.
6020 * targets.c (bfd_elf32_cris_vec, cris_aout_vec): Declare.
6021 (bfd_target_vect): Add bfd_elf32_cris_vec and cris_aout_vec.
6022 * cpu-cris.c, aout-cris.c, elf32-cris.c: New files.
6023 * po/POTFILES.in, po/bfd.pot: Regenerate.
6024
6025 2000-07-19 H.J. Lu <hjl@gnu.org>
6026
6027 * elf32-arm.h (elf32_arm_size_dynamic_sections): Also set
6028 DF_TEXTREL if DT_TEXTREL is set.
6029 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
6030 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
6031 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
6032 * elf32-mips.c (_bfd_mips_elf_size_dynamic_sections): Likewise.
6033 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
6034 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
6035 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
6036 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
6037 * elf64-ia64.c (elf64_ia64_size_dynamic_sections): Likewise.
6038 * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Likewise.
6039
6040 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Also
6041 set DF_SYMBOLIC for symbolic link. Also set DT_RUNPATH if
6042 DT_RPATH is set.
6043 Set the DT_FLAGS and DT_FLAGS_1 entries if necessary.
6044
6045 2000-07-19 H.J. Lu <hjl@gnu.org>
6046
6047 * bfd-in.h (bfd_elf_set_dt_needed_soname): New.
6048 * bfd-in2.h: Rebuild.
6049
6050 * elf-bfd.h (elf_obj_tdata): Add dt_soname.
6051 (elf_dt_soname): New.
6052
6053 * elf.c (bfd_elf_set_dt_needed_soname): New.
6054
6055 * elflink.h (elf_link_add_object_symbols): Add the DT_NEEDED
6056 entry if the shared object loaded by DT_NEEDED is used to
6057 resolve the reference in a regular object.
6058
6059 2000-07-19 H.J. Lu <hjl@gnu.org>
6060
6061 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_CONFIG,
6062 DT_DEPAUDIT and DT_AUDIT as strings.
6063
6064 2000-07-19 Nick Clifton <nickc@cygnus.com>
6065
6066 * format.c: Fix formatting.
6067
6068 2000-07-19 H.J. Lu <hjl@gnu.org>
6069
6070 * elf.c (_bfd_elf_print_private_bfd_data): Fix DT_CHECKSUM.
6071
6072 2000-07-19 H.J. Lu <hjl@gnu.org>
6073
6074 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_BIND_NOW,
6075 DT_INIT_ARRAY, DT_FINI_ARRAY, DT_INIT_ARRAYSZ, DT_FINI_ARRAYSZ,
6076 DT_RUNPATH, DT_FLAGS, DT_PREINIT_ARRAY, DT_PREINIT_ARRAYSZ,
6077 DT_PLTPADSZ, DT_MOVEENT, DT_MOVESZ, DT_FEATURE, DT_POSFLAG_1,
6078 DT_SYMINSZ, DT_SYMINENT, DT_CONFIG, DT_DEPAUDIT, DT_AUDIT,
6079 DT_PLTPAD, DT_MOVETAB, DT_SYMINFO, DT_RELACOUNT, DT_RELCOUNT,
6080 DT_FLAGS_1, DT_USED and DT_CHECKSUM.
6081
6082 2000-07-18 Andrew Cagney <cagney@b1.cygnus.com>
6083
6084 * elf.c (bfd_elf_get_sign_extend_vma, bfd_elf_get_arch_size): Move
6085 renamed functions from here...
6086 (assign_section_numbers): Use renamed functions.
6087 (prep_headers): Use renamed functions.
6088
6089 * bfd.c (bfd_get_sign_extend_vma, bfd_get_arch_size): ...To here.
6090 * bfd-in.h (bfd_get_sign_extend_vma, bfd_get_arch_size): Update.
6091 * bfd-in2.h: Regenerate.
6092
6093 2000-07-18 Ulf Carlsson <ulfc@engr.sgi.com>
6094
6095 * elf32-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Add
6096 parenthesis in if statement.
6097
6098 2000-07-17 Koundinya K <kk@ddeorg.soft.net>
6099
6100 Enable the support for Traditional MIPS.
6101 * elf32-mips.c (IRIX_COMPAT): Recognize bfd_elf32_tradbigmips_vecand
6102 return ict_none appropriately for traditional mips targets.
6103 (STUB_LW): Change 0x8f998000 to 0x8f998010 for traditional mips.
6104 (STUB_MOVE): Conditionalize for traditonal mips.
6105 (STUB_LI16): Likewise.
6106 (_bfd_mips_elf_modify_segment_map): Conditionalize to avoid making
6107 room for RTPROC header.
6108 (_bfd_mips_elf_modify_segment_map): For a normal mips executable set
6109 the permission for the PT_DYNAMIC as read, write and execute.
6110 (mips_elf_calculate_relocation): Check for the symbol _DYNAMIC_LINKING
6111 for traditonal mips.
6112 (_bfd_mips_elf_create_dynamic_sections): Add the symbol
6113 _DYNAMIC_LINKING for traditonal mips.
6114 (_bfd_mips_elf_create_dynamic_sections): Add the symbol __RLD_MAP
6115 in case of traditonal mips.
6116 (_bfd_mips_elf_adjust_dynamic_symbol): Create a stub only if a PLT
6117 entry is required. For a function if PLT is not required then set the
6118 corresponding hash table entry to 0.
6119 (_bfd_mips_elf_size_dynamic_sections): Add DT_DEBUG entry for
6120 traditonal mips.
6121 (_bfd_mips_elf_finish_dynamic_symbol): for a undefined symbol in a
6122 shared object set the value to 0.
6123 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol
6124 _DYNAMIC_LINKING for traditonal mips.
6125 (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol __RLD_MAP
6126 for traditonal mips.
6127
6128 2000-07-15 H.J. Lu <hjl@gnu.org>
6129
6130 * aoutx.h (translate_to_native_sym_flags): Handle BSF_LOCAL.
6131
6132 2000-07-12 Charles Wilson <cwilson@ece.gatech.edu>
6133
6134 * libbfd.c (bfd_seek): fix 'seek beyond EOF' error when writing
6135 out a structure that is BFD_IN_MEMORY.
6136
6137 2000-07-11 Alan Modra <alan@linuxcare.com.au>
6138
6139 * elf64-hppa.c (get_dyn_name): Pass in section pointer instead of
6140 bfd pointer. Print section id instead of bfd pointer for local
6141 syms. Prefix addend with `+' for global syms as well as local.
6142 Correct calculation of name component lengths.
6143 (elf64_hppa_check_relocs): Update call to get_dyn_name.
6144
6145 From David Huggins-Daines <dhd@linuxcare.com>
6146 * elf-hppa.h (elf_hppa_relocate_section): Update calls here too.
6147 * elf64-hppa.c (elf64_hppa_check_relocs): Fix some warnings.
6148 (elf64_hppa_modify_segment_map): Likewise.
6149
6150 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6151
6152 * elf.c (bfd_elf_get_sign_extend_vma): Return tendency of VMA
6153 addresses to be "naturally" sign extended. Return -1 if unknown.
6154 * bfd-in.h (bfd_elf_get_sign_extend_vma): Add declaration.
6155 * bfd-in2.h: Regenerate.
6156
6157 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6158
6159 * ecoffswap.h (ecoff_get_off, ecoff_put_off): Add ECOFF_SIGNED_32
6160 and ECOF_SIGNED_64 to list ways to extract an offset.
6161 (ecoff_swap_fdr_in, ecoff_swap_fdr_out, ecoff_swap_pdr_in,
6162 ecoff_swap_pdr_out, ecoff_swap_ext_in, ecoff_swap_ext_out):
6163 Update.
6164 * elf64-mips.c (ECOFF_SIGNED_64): Define instead of ECOFF_64.
6165 * elf32-mips.c (ECOFF_SIGNED_32): Define instead of ECOFF_32.
6166
6167 2000-07-11 Andrew Cagney <cagney@b1.cygnus.com>
6168
6169 * elfcode.h (elf_object_p): Use bfd_set_start_address and not
6170 bfd_get_start_address.
6171 (elf_swap_ehdr_in): Sign extend e_entry when applicable.
6172 (elf_swap_ehdr_out): Ditto.
6173
6174 2000-07-10 Alexander Aganichev <AAganichev@hypercom.com>
6175
6176 * archures.c (bfd_default_scan): Add set of bfd_mach_ cases for
6177 compatibility with older binutils.
6178
6179 2000-07-10 Alan Modra <alan@linuxcare.com.au>
6180
6181 * section.c (bfd_make_section_anyway): Start section_id at 0x10.
6182 (STD_SECTION): Avoid negative ids, instead use 0 to 3.
6183
6184 From Ryan Bradetich <rbradetich@uswest.net>
6185 * dwarf1.c (parse_die): Cure signed/unsigned char warnings.
6186 (parse_line_table): Ditto.
6187 (_bfd_dwarf1_find_nearest_line): Ditto.
6188 * syms.c (cmpindexentry): Remove extra `*' from params.
6189
6190 2000-07-09 Koundinya K <kk@ddeorg.soft.net>
6191
6192 * elf32-mips.c (sort_dynamic_relocs): New Function.
6193 (_bfd_mips_elf_finish_dynamic_sections): Call sort_dynamic_relocs
6194 via qsort to sort the dynamic relocations in increasing r_symndx
6195 value.
6196
6197 2000-07-09 Alan Modra <alan@linuxcare.com.au>
6198
6199 * elf64-hppa.c (elf64_hppa_dyn_hash_table_init): Add
6200 ATTRIBUTE_UNUSED to unused args.
6201 (get_opd): Likewise.
6202 (get_plt): Likewise.
6203 (get_dlt): Likewise.
6204 (get_stub): Likewise.
6205 (elf64_hppa_adjust_dynamic_symbol): Likewise.
6206 (elf64_hppa_link_output_symbol_hook): Likewise.
6207 (elf64_hppa_check_relocs): Delete unused var.
6208 (elf64_hppa_size_dynamic_sections): Likewise.
6209 (elf64_hppa_finalize_opd): Likewise.
6210 (elf64_hppa_finalize_dynreloc): Likewise.
6211 (elf64_hppa_modify_segment_map): Likewise.
6212 (elf64_hppa_finish_dynamic_sections): Likewise.
6213
6214 * elf-hppa.h (elf_hppa_final_write_processing): Add
6215 ATTRIBUTE_UNUSED to unused args.
6216 (elf_hppa_final_link_relocate): Likewise.
6217 (elf_hppa_record_segment_addrs): Add paretheses.
6218 (elf_hppa_relocate_section): Constify dyn_name.
6219
6220 From David Huggins-Daines <dhd@linuxcare.com>
6221 * config.bfd: Add hppa*64*-*-linux-gnu 64-bit target, and
6222 rearrange case statement so that it gets preferred to 32-bit ones.
6223
6224 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Use
6225 asection->id instead of address of asection structure.
6226 (elf32_hppa_size_stubs): Likewise.
6227
6228 * elf32-hppa.c (elf32_hppa_size_stubs): Use just one stub section
6229 for .init* and .fini*.
6230
6231 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Mask pointers
6232 and addends used in stub names to 32 bits.
6233 (elf32_hppa_size_stubs): Likewise.
6234
6235 * elf-hppa.h (elf_hppa_final_link_relocate): Don't sum addend
6236 twice for R_PARISC_GPREL64. Use bfd_put_32 for R_PARISC_PCREL32,
6237 not bfd_put_64. Fix minor comment typo and formatting.
6238
6239 Changes to create multiple linker stubs, positioned immediately
6240 before the section where they are required.
6241 * elf32-hppa.c: Don't include hppa_stubs.h.
6242 (elf32_hppa_stub_hash_entry): Add a pointer to the stub section.
6243 (elf32_hppa_stub_hash_table): Delete.
6244 (elf32_hppa_link_hash_entry): Delete.
6245 (elf32_hppa_link_hash_table): Use plain bfd_hash_table for
6246 stub_hash_table, and store the struct here rather than a pointer.
6247 Delete output_symbol_count. Add offset array. Change
6248 global_value to a bfd_vma.
6249 (elf32_hppa_stub_hash_lookup): Use table instead of table->root.
6250 (elf32_hppa_stub_hash_traverse): Delete.
6251 (elf32_hppa_name_of_stub): Delete.
6252 (elf32_hppa_link_hash_lookup): Delete.
6253 (elf32_hppa_link_hash_traverse): Delete.
6254 (elf32_hppa_stub_hash_table_init): Delete.
6255 (elf32_hppa_size_of_stub): Pass input section and offset rather
6256 than location and calculate location here. Don't pass name as all
6257 stubs are now the same size.
6258 (elf32_hppa_stub_hash_newfunc): Init new fields.
6259 (elf32_hppa_link_hash_table_create): Likewise, and stub_hash_table
6260 too.
6261 (elf32_hppa_bfd_final_link_relocate): Cast enums to int before
6262 comparing against ints. Rewrite stub handling code.
6263 (elf32_hppa_relocate_section): Make r_type and r_symndx unsigned.
6264 Case enums to int before comparing against ints. Remove
6265 bfd_reloc_dangerous case.
6266 (elf32_hppa_build_one_stub): Rewrite.
6267 (elf32_hppa_size_one_stub): New function.
6268 (elf32_hppa_build_stubs): Rewrite.
6269 (elf32_hppa_size_stubs): Pass in linker call-back functions.
6270 Rewrite stub-handling specific code.
6271
6272 * elf32-hppa.h (elf32_hppa_size_stubs): Update prototype.
6273
6274 * elf64-hppa.c (elf64_hppa_dyn_hash_entry): Fix a comment typo.
6275
6276 * hppa_stubs.h: Delete.
6277 * Makefile.am (SOURCE_HFILES): Remove hppa_stubs.h
6278 (elf32-hppa.lo): Remove hppa_stubs.h from dependencies.
6279 * Makefile.in: Regenerate.
6280
6281 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Handle e_nlsel and
6282 e_nlrsel.
6283
6284 * libhppa.h (hppa_field_adjust): Correct e_nsel case.
6285
6286 * elf32-hppa.c (elf32_hppa_relocate_section): Mention the offset
6287 and section name for bfd_reloc_notsupported error message.
6288 (elf32_hppa_bfd_final_link_relocate): Print reasons for returning
6289 bfd_reloc_notsupported.
6290 (elf32_hppa_relocate_section): Add ATTRIBUTE_UNUSED to output_bfd.
6291
6292 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Handle
6293 undefined weak symbols for all relocs.
6294 (elf32_hppa_size_of_stub): Adjust calculation by 8 since branch
6295 offsets are relative to one past the delay slot.
6296 (elf32_hppa_size_stubs): Account for reloc addend when calculating
6297 branch destination. Put addend into stub name too.
6298 (elf32_hppa_bfd_final_link_relocate): Account for reloc addend and
6299 adjust by 8 when deciding whether a linker stub is needed. Put
6300 addend into stub name as for above.
6301
6302 * elf32-hppa.c (hppa_elf_relocate_insn): Change signed/unsigned on
6303 various args and vars.
6304 (elf32_hppa_bfd_final_link_relocate): Here too.
6305 (elf32_hppa_size_stubs): Rename index -> indx. Use e_indx for
6306 inner block var to avoid shadowing.
6307
6308 * elf32-hppa.h (_bfd_elf32_hppa_gen_reloc_type): Make `field' arg
6309 unsigned.
6310 * elf64-hppa.h (_bfd_elf64_hppa_gen_reloc_type): Ditto.
6311 * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Ditto.
6312 (elf_hppa_fake_sections): Rename local var to avoid shadowing.
6313
6314 * libhppa.h: Change practically all unsigned ints to plain ints.
6315 Remove tests on gcc version. Instead use ATTRIBUTE_UNUSED for
6316 prototypes.
6317
6318 From Ryan Bradetich <rbradetich@uswest.net>
6319 * libhppa.h (hppa_opcode_type): New enum to replace #define's.
6320 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Modify to
6321 suit above.
6322 From David Huggins-Daines <dhd@linuxcare.com>
6323 * elf-hppa.h (elf_hppa_relocate_insn): Update the opcode constants
6324 to the new OP_* ones.
6325
6326 * elf32-hppa.c (elf32_hppa_size_stubs): Consolidate freeing on
6327 error exit. Bail out earlier on plabel relocs that we aren't
6328 interested in. Don't tell elf32_hppa_stub_hash_lookup to copy
6329 string, and then don't free our copy.
6330 (elf32_hppa_build_one_stub): Make insn unsigned int.
6331
6332 * libhppa.h (bfd_hppa_insn2fmt): 22 bit branches are only
6333 available with BL, not BE and BLE.
6334
6335 * elf32-hppa.c (hppa_elf_relocate_insn): Add some more example
6336 code for elf arg relocs.
6337 (elf32_hppa_bfd_final_link_relocate): Replace boolean is_local
6338 argument with elf_link_hash_entry h. Handle undefined weak
6339 symbols. Move $global$ lookup from here...
6340 (elf32_hppa_relocate_section): ...to here. Return correct error
6341 message for non-handled relocs.
6342 (elf32_hppa_size_of_stub): Correctly test branch range. Previous
6343 wrong test was -0x3ffff to +0x40000.
6344
6345 * elf-hppa.h (elf_hppa_final_link_relocate): R_PARISC_DIR17R,
6346 R_PARISC_DIR17F, and R_PARISC_DIR21L are for absolute branches;
6347 Handle them as such.
6348 (elf_hppa_relocate_insn): Fix a typo.
6349
6350 * libhppa.h (GET_FIELD, GET_BIT, MASK, CATENATE, ELEVEN): Delete.
6351 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
6352 assemble_17, assemble_21): Delete.
6353 Supply defines for all 64 possible opcodes.
6354 (bfd_hppa_insn2fmt): Add bfd argument, and use to select wide mode
6355 formats. Handle COMICLR.
6356 (hppa_rebuild_insn): Delete bfd argument. Handle formats 10, -11,
6357 -10, -16, 16, 22.
6358
6359 * elf32-hppa.c (hppa_elf_relocate_insn): Complete rewrite.
6360 (elf32_hppa_bfd_final_link_relocate): Major rewrite.
6361 (elf32_hppa_build_one_stub): Modify hppa_elf_relocate_insn calls
6362 to suit.
6363 (elf32_hppa_size_stubs): Don't free stub_name twice. Read in all
6364 the local syms - did this code get deleted accidentally? Ignore
6365 undefined and undefweak syms.
6366
6367 * elf-hppa.h (elf_hppa_final_link): Move hppa_info to outermost
6368 block. Use it instead of elf64_hppa_hash_table (info).
6369 (elf_hppa_final_link_relocate): Use hppa_info instead of
6370 elf64_hppa_hash_table (info).
6371
6372 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
6373 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
6374 (hppa_rebuild_insn): Mask immediate bits here instead.
6375 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
6376
6377 2000-07-08 Alan Modra <alan@linuxcare.com.au>
6378
6379 * section.c (struct sec): Add id field. Tidy comment formatting.
6380 (bfd_make_section_anyway): Set id.
6381 (STD_SECTION): Init id too.
6382 Change CONST to const throughout.
6383 * archures.c (bfd_arch_info): Tidy comment.
6384 (bfd_arch_list): Change a CONST to const.
6385 * libbfd-in.h: Tidy comments and replace CONST with const.
6386 * elf-bfd.h: Likewise.
6387 * libbfd.h: Regenerate.
6388 * bfd-in2.h: Regenerate.
6389 * libcoff.h: Regenerate.
6390
6391 2000-07-07 DJ Delorie <dj@redhat.com>
6392
6393 * archive.c (_bfd_write_archive_contents): Add an informative
6394 comment.
6395
6396 2000-07-06 Kazu Hirata <kazu@hxi.com>
6397
6398 * srec.c: Fix formatting.
6399
6400 2000-06-05 DJ Delorie <dj@redhat.com>
6401
6402 * MAINTAINERS: new
6403
6404 2000-07-04 Alexandre Oliva <aoliva@redhat.com>
6405
6406 * coff-arm.c (coff_arm_relocate_section): Do not ignore the symbol
6407 value of PC-relative offsets.
6408
6409 2000-07-03 Jim Wilson <wilson@cygnus.com>
6410
6411 * elf64-alpha.c (alpha_elf_size_info): New.
6412 (elf_backend_size_info): Define to alpha_elf_size_info.
6413 * elfcode.h (elf_size_info): Change hash bucket size to 4.
6414
6415 2000-07-03 Ulf Carlsson <ulfc@engr.sgi.com>
6416
6417 * elf32-mips.c: Include elf32-target.h again for the traditional
6418 MIPS targets.
6419
6420 2000-07-03 Marek Michalkiewicz <marekm@linux.org.pl>
6421
6422 * elf32-avr.c (bfd_elf32_bfd_reloc_type_lookup):
6423 Add ATTRIBUTE_UNUSED to unused arguments to avoid warnings.
6424 (avr_info_to_howto_rela): Likewise.
6425 (elf32_avr_gc_mark_hook): Likewise.
6426 (elf32_avr_gc_sweep_hook): Likewise.
6427 (elf32_avr_relocate_section): Likewise.
6428
6429 2000-07-03 Mark Elbrecht <snowball3@bigfoot.com>
6430
6431 * cofflink.c (_bfd_coff_write_global_sym): Turn a weak symbol into
6432 an external symbol for a non-shared, non-relocatable link.
6433
6434 2000-07-03 Nick Clifton <nickc@redhat.com>
6435
6436 * cofflink.c (IS_EXTERNAL): New macro: Return true if the symbol
6437 is an external symbol.
6438 (IS_WEAK_EXTERNAL): New macro: Return true if the symbol is a weak
6439 external symbol.
6440
6441 2000-07-03 Kazu Hirata <kazu@hxi.com>
6442
6443 * reloc16.c: Fix formatting.
6444
6445 2000-07-01 Koundinya K <kk@ddeorg.soft.net>
6446
6447 * config.bfd: Change targ_defvec and targ_selvecs for mips*-*-sysv4*
6448 to add a new target for traditional mips i.e
6449 bfd_elf32_tradbigmips_vec and bfd_elf32_tradlittlemips_vec.
6450 * configure.in: Likewise.
6451 * configure: Rebuild.
6452 * targets.c (bfd_elf32_tradbigmips_vec): Declare and put in
6453 bfd_target_vector.
6454 (bfd_elf32_tradlittlemips_vec): Likewise.
6455 * elfxx-target.h: Add macro INCLUDED_TARGET_FILE which is more a test
6456 to see that elfNN_bed does not get redefined even if the target file
6457 is included twice for a chip. See elf32-mips.c.
6458
6459 2000-07-01 Alan Modra <alan@linuxcare.com.au>
6460
6461 * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
6462 (CLEANFILES): Add DEPA.
6463 * Makefile.in: Regenerate.
6464
6465 2000-06-30 DJ Delorie <dj@cygnus.com>
6466
6467 * peicode.h (coff_swap_filehdr_in): can't use e_magic because we
6468 can't assume the PE header is at 0x80.
6469
6470 2000-06-29 Mark Elbrecht <snowball3@bigfoot.com>
6471
6472 * syms.c (_bfd_stab_section_find_nearest_line): Use IS_ABSOLUTE_PATH.
6473
6474 2000-06-28 Mark Elbrecht <snowball3@bigfoot.com>
6475
6476 * go32stub.h: Update stub.
6477
6478 2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
6479
6480 * archures.c (bfd_mach_avr5): Define.
6481 * bfd-in2.h (bfd_mach_avr5): Define.
6482 * cpu-avr.c (arch_info_struct): Rename bfd_mach_avr4 to
6483 bfd_mach_avr5, add bfd_mach_avr4. Update comments.
6484 (compatible): Update comment. Add missing test.
6485 * elf32-avr.c (avr_final_link_relocate): Support 8K wrap
6486 for avr2 and avr4. Simplify 8K wrap code.
6487 (bfd_elf_avr_final_write_processing): Recognize bfd_mach_avr5.
6488 (elf32_avr_object_p): Recognize E_AVR_MACH_AVR5.
6489
6490 2000-06-26 Kazu Hirata <kazu@hxi.com>
6491
6492 * coff-h8300.c: Fix formatting.
6493 * cpu-h8300.c: Likewise.
6494
6495 2000-06-24 Alexandre Oliva <aoliva@redhat.com>
6496
6497 * elf32-arm.h (elf32_arm_final_link_relocate): Print `(local)'
6498 for local symbols whose names are unknown.
6499
6500 2000-06-22 Alan Modra <alan@linuxcare.com.au>
6501
6502 * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
6503 find one.
6504 * Makefile.in: Regenerate.
6505 * doc/Makefile.in: Regenerate.
6506
6507 2000-06-20 H.J. Lu <hjl@gnu.org>
6508
6509 * Makefile.am: Rebuild dependency.
6510 * Makefile.in: Rebuild.
6511
6512 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
6513
6514 * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): New function.
6515 (elf_backend_copy_indirect_symbol): Map to the new function.
6516
6517 2000-06-20 Alan Modra <alan@linuxcare.com.au>
6518
6519 * archive.c (normalize): Correct pointer comparison when checking
6520 for backslashes.
6521 (bfd_bsd_truncate_arname): Likewise.
6522 (bfd_gnu_truncate_arname): Likewise.
6523
6524 2000-06-20 Ulf Carlsson <ulfc@engr.sgi.com>
6525
6526 * elf-bfd.h (struct elf_obj_tdata): Define per BFD Irix 5 virtual
6527 sections elf_{text,data}_{section,symbol}.
6528 * elf32-mips.c: mips_elf_{text,data}_{section,symbol}{,_ptr}: Remove.
6529 (_bfd_mips_elf_hide_symbol): New function.
6530 (elf_backend_hide_symbol): Map to the new function.
6531 (_bfd_mips_elf_add_symbol_hook): Change to use new per BFD
6532 definitions of mips_elf_{text,data}_{section,symbol}.
6533 (mips_elf_local_relocation_p): Try to find the direct symbol
6534 based on new check_forced argument.
6535 (mips_elf_calculate_relocation): Use new version of
6536 mips_elf_local_relocation_p.
6537 (mips_elf_relocate_section): Likewise.
6538 (_bfd_mips_elf_relocate_section): Likewise.
6539 (mips_elf_sort_hash_table): Only assert that have enough GOT
6540 space.
6541 (mips_elf_got16_entry): Match all 32 bits to the existing GOT
6542 entry if the relocation based on the new external argument.
6543 (mips_elf_create_dynamic_relocation): Assert that we have a
6544 section contents allocated where we can swap out the dynamic
6545 relocations.
6546 (mips_elf_calculate_relocation): Find the real hash-table entry
6547 correctly by using h->root.root.type. Only create a dynamic
6548 relocation entry if the symbol is defined in a shared library.
6549 Create an external GOT entry for the GOT16 relocation if the
6550 symbol was forced local.
6551 (_bfd_mips_elf_finish_dynamic_symbol): Don't assert there is a
6552 dynamic index if the symbol was forced local.
6553
6554 2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
6555
6556 * elf32-mips.c: Fix typos in comments.
6557
6558 2000-06-19 Mark Kettenis <kettenis@gnu.org>
6559
6560 * rs6000-core.c: Wrap definition of `union VmInfo' within #ifdef
6561 CORE_VERSION_1.
6562
6563 2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
6564
6565 * Makefile.in, bfd-in2.h, libbfd.h, configure: Rebuild.
6566 * Makefile.am (ALL_MACHINES, ALL_MACHINES_CFILES, BFD32_BACKENDS,
6567 BFD32_BACKENDS_CFILES): Add 68hc12, 68hc11 files.
6568 * configure.in (bfd_elf32_m68hc12_vec): Recognize.
6569 (bfd_elf32_m68hc11_vec): Likewise.
6570 * config.bfd (targ_cpu): Recognize 68hc12 and 68hc11.
6571 Supports 68hc11 & 68hc12 at the same time.
6572 * targets.c (bfd_elf32_m68hc12_vec): Declare and put in
6573 bfd_target_vector.
6574 (bfd_elf32_m68hc11_vec): Likewise.
6575 * elf.c (prep_headers): Recognize bfd_arch_m68hc12 and 68hc11.
6576 * archures.c (bfd_m68hc12_arch): Define and register in global list
6577 (bfd_m68hc11_arch): Likewise.
6578 * reloc.c (BFD_RELOC_M68HC11_HI8, BFD_RELOC_M68HC11_LO8,
6579 BFD_RELOC_M68HC11_3B): Define.
6580 * cpu-m68hc12.c, elf32-m68hc12.c: New files for 68hc12 support.
6581 * cpu-m68hc11.c, elf32-m68hc11.c: New files for 68hc11 support.
6582
6583 2000-06-18 Ulf Carlsson <ulfc@engr.sgi.com>
6584
6585 * elf_bfd.h (struct elf_backend_data): Add info argument to
6586 elf_backend_hide_symbol.
6587 (_bfd_elf_link_hash_hide_symbol): Likewise.
6588 * elf.c (_bfd_elf_link_hash_hide_symbol): Likewise.
6589 * elf64-ia64.c (elf64_ia64_hash_hide_symbol): Likewise.
6590 * elflink.h (elf_link_add_object_symbols): Likewise.
6591 (elf_link_assign_sym_version): Likewise.
6592
6593 2000-06-18 H.J. Lu <hjl@gnu.org>
6594
6595 * coff-i386.c (coff_i386_reloc): Don't return in case of
6596 output_bfd == (bfd *) NULL if COFF_WITH_PE is defined.
6597 Compensate PE relocations when linking with non-PE object
6598 files to generate a non-PE executable.
6599
6600 2000-06-17 Ulf Carlsson <ulfc@engr.sgi.com>
6601
6602 * elf32-mips.c (mips_elf_calculate_relocation): Explicitly write
6603 GOT entries if we're doing a static link or -Bsymbolic link.
6604
6605 2000-06-15 Ulf Carlsson <ulfc@engr.sgi.com>
6606
6607 * elflink.h (elf_link_adjust_relocs): Check for and call backend
6608 specifific swap_reloc_{in,out} and swap_reloca_{in,out} if
6609 available.
6610 (elf_link_output_relocs): Likewise.
6611 (elf_reloc_link_order): Likewise.
6612
6613 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6614
6615 * archures.c (enum bfd_architecture): #define constants for
6616 PowerPc and RS6000 machine numbers.
6617 * bfd-in2.h: Regenerate.
6618 * coffcode.h (coff_set_arch_mach_hook): #ifdef XCOFF64, set arch
6619 to bfd_arch_powerpc instead of bfd_arch_rs6000. Refer to PowerPc
6620 and RS6000 machine numbers using #defined constants from
6621 archures.c.
6622 * cpu-powerpc.c (arch_info_struct): Refer to PowerPc and RS6000
6623 machine numbers using #defined constants from archures.c. Add
6624 entries for EC603e, 630, A35, RS64II, RS64III, 7400. Specify
6625 64-bit words in 620 entry.
6626 * cpu-rs6000.c (arch_info_struct): Create with entries for RS1,
6627 RSC, and RS2.
6628 (bfd_rs6000_arch): Change default machine to 0 (bfd_mach_rs6k).
6629
6630 2000-06-16 Nicholas Duffek <nsd@cygnus.com>
6631
6632 * coffcode.h (coff_mkobject_hook): Set xcoff_tdata.xcoff64.
6633 * libcoff-in.h (struct xcoff_tdata): Define xcoff64 field.
6634 * libcoff.h (struct xcoff_tdata): Define xcoff64 field.
6635
6636 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6637
6638 * bfd-in.h (bfd_family_coff): Define.
6639 * bfd-in2.h: Regenerate.
6640 * coffgen.c (coff_count_linenumbers, coff_symbol_from,
6641 coff_find_nearest_line): Check COFFness using bfd_family_coff()
6642 instead of bfd_target_coff_flavour.
6643 * cofflink.c (_bfd_coff_final_link): Likewise.
6644 * cpu-ns32k.c (do_ns32k_reloc): Don't strcmp() target name to
6645 exclude XCOFF files.
6646 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
6647 Likewise.
6648 * targets.c (enum bfd_flavour): Add bfd_target_xcoff_flavour.
6649 * xcoff-target.h (TARGET_SYM): Use bfd_target_xcoff_flavour.
6650 * xcofflink.c (XCOFF_XVECP): Delete.
6651 (bfd_xcoff_link_record_set, bfd_xcoff_import_symbol,
6652 bfd_xcoff_export_symbol, bfd_xcoff_link_count_reloc,
6653 bfd_xcoff_record_link_assignment,
6654 bfd_xcoff_size_dynamic_sections): Replace XCOFF_XVECP() with
6655 check for bfd_target_xcoff_flavour.
6656
6657 2000-06-16 Nicholas Duffek <nsd@redhat.com>
6658
6659 * rs6000-core.c: Support 64-bit core files, support pre-4.3 core
6660 files on AIX 4.3.
6661 (read_hdr): New function.
6662 (rs6000coff_core_p): Store mstsave or __context64 struct instead
6663 of trying to extract individual registers. Set abfd->arch_info
6664 to match the architecture that created the core file.
6665 (rs6000coff_get_section_contents): Delete.
6666 * xcoff-target.h (rs6000coff_get_section_contents): Delete.
6667
6668 2000-06-14 H.J. Lu <hjl@gnu.org>
6669
6670 * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_rec)
6671 is NULL.
6672
6673 2000-06-13 H.J. Lu <hjl@gnu.org>
6674
6675 * configure: Regenerate.
6676
6677 2000-06-13 J"orn Rennecke <amylaar@cygnus.co.uk>
6678
6679 * peicode.h (pe_ILF_object_p): Use TARGET_LITTLE_SYM instead of
6680 armpei_little_vec.
6681
6682 2000-06-08 David O'Brien <obrien@FreeBSD.org>
6683
6684 * configure.in (VERSION): Update to show this is the CVS mainline.
6685
6686 2000-06-07 Alan Modra <alan@linuxcare.com.au>
6687
6688 * elf32-d10v.c: Include elf/d10v.h
6689 (enum reloc_type): Delete.
6690 * elf32-d30v.c: Include elf/d30v.h
6691 (enum reloc_type): Delete.
6692
6693 * Makefile.am: Run "make dep-am" to regenerate dependencies.
6694 * Makefile.in: Regenerate.
6695
6696 * elf32-i386.c (elf_howto_table): Remove EMPTY_HOWTOs.
6697 (elf32_i386_vtinherit_howto, elf32_i386_vtentry_howto): Delete and
6698 move HOWTOs into elf_howto_table.
6699 (R_386_standard, R_386_ext_offset): Define.
6700 (R_386_ext, R_386_vt_offset, R_386_vt): Define.
6701 (elf_i386_reloc_type_lookup): Modify calculation of index into
6702 elf_howto_table since we've removed the padding.
6703 (elf_i386_info_to_howto_rel): Likewise.
6704 (elf_i386_relocate_section): Likewise.
6705
6706 2000-06-06 Michael Snyder <msnyder@seadog.cygnus.com>
6707
6708 * elf.c (elf_grok_pr_status): Eliminate reference to prgregset_t.
6709
6710 2000-06-05 H.J. Lu <hjl@gnu.org>
6711
6712 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Don't flag
6713 an error when seeing an undefined symbol with hidden/internal
6714 attribute. It is handled in *_relocate_section ().
6715
6716 2000-06-05 H.J. Lu <hjl@gnu.org>
6717
6718 * elflink.h (elf_fix_symbol_flags): Follow the link for the
6719 indirect symbol for the ELF_LINK_NON_ELF bit.
6720 (elf_link_output_extsym): Don't output the indirect symbol even
6721 if the ELF_LINK_NON_ELF bit is set.
6722
6723 2000-06-01 J.T. Conklin <jtc@redback.com>
6724
6725 * config.bfd (i[3456]86-*-netbsdelf*): New target.
6726 (i[3456]86-*-netbsdaout*): New target.
6727 (i[3456]86-*-netbsd*): Add bfd_elf32_i386_vec to targ_selvecs.
6728 (i[3456]86-*-openbsd*): Likewise.
6729
6730 2000-05-30 Andrew Cagney <cagney@b1.cygnus.com>
6731
6732 * trad-core.c: From hpux-core.c, include <dirent.h> or
6733 <sys/ndir.h> when possible.
6734
6735 2000-05-31 Ulrich Drepper <drepper@redhat.com>
6736
6737 * elf.c (_bfd_elf_slurp_version_tables): Correct reading of version
6738 definitions. We must not assume they are sorted in the file
6739 according to their index numbers.
6740
6741 2000-05-31 Alan Modra <alan@linuxcare.com.au>
6742
6743 * elf-hppa.h: (elf_hppa_final_link_relocate): Use e_rsel field
6744 selector for R_PARISC_PCREL17R. R_PARISC_DIR17R and
6745 R_PARISC_DIR17F are for absolute branches; Handle them as such.
6746
6747 2000-05-30 Nick Clifton <nickc@cygnus.com>
6748
6749 * cpu-i960.c (scan_960_mach): Accept 80960KA, 80960KB,
6750 80960CA, 80960MC as valid machine names.
6751
6752 2000-05-30 H.J. Lu <hjl@gnu.org>
6753
6754 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Clear the
6755 visibility bits if the symbol is undefined. Correctly handle
6756 weak undefined symbols with hidden and internal attributes.
6757
6758 * elflink.h (elf_link_add_object_symbols): Always turn the
6759 symbol into local if it has the hidden or internal attribute.
6760
6761 2000-05-29 Philip Blundell <philb@gnu.org>
6762
6763 * ppcboot.c: Add packed attribute if compiling with GCC.
6764
6765 2000-05-29 Anatoly Vorobey <mellon@pobox.com>
6766
6767 * elf.c (_bfd_elf_link_hash_table_init): Initialize dynlocal.
6768
6769 2000-05-26 Michael Snyder <msnyder@seadog.cygnus.com>
6770
6771 * elf.c (elfcore_grok_prstatus, elfcore_grok_pstatus,
6772 elfcore_grok_psinfo): Add code to allow debugging a 32-bit
6773 corefile on a 64-bit (Sparc Solaris) host. Also clean up
6774 a few old comments.
6775
6776 2000-05-26 Alan Modra <alan@linuxcare.com.au>
6777
6778 * Makefile.am: Update dependencies with "make dep-am"
6779 * Makefile.in: Regenerate.
6780
6781 * sysdep.h (gettext, dgettext, dcgettext, textdomain,
6782 bindtextdomain): Replace defines with those from intl/libgettext.h
6783 to quieten gcc warnings.
6784
6785 2000-05-26 Eli Zaretskii <eliz@is.elta.co.il>
6786
6787 * aoutx.h (find_nearest_line): Use IS_ABSOLUTE_PATH.
6788
6789 * archive.c (normalize, bfd_bsd_truncate_arname,
6790 bfd_gnu_truncate_arname) [HAVE_DOS_BASED_FILE_SYSTEM]: Support
6791 file names with backslashes.
6792
6793 * cache.c (bfd_open_file) [__MSDOS__]: Don't unlink the file
6794 before opening it.
6795
6796 * sysdep.h: Include filenames.h.
6797
6798 2000-05-26 Alan Modra <alan@linuxcare.com.au>
6799
6800 * opncls.c (bfd_close_all_done): Mask file perms with 0777 not 0x777.
6801
6802 2000-05-26 Jakub Jelinek <jakub@redhat.com>
6803
6804 * elf64-sparc.c (sparc64_elf_relax_section): New.
6805 (sparc64_elf_relocate_section): Optimize tail call into branch always
6806 if possible.
6807 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
6808 (elf32_sparc_relax_section): New.
6809
6810 2000-05-26 Jakub Jelinek <jakub@redhat.com>
6811
6812 * elf64-sparc.c: Add ATTRIBUTE_UNUSED to unused function parameters.
6813 Remove unusued variables.
6814 (sparc64_elf_relocate_section): Change r_symndx type to unsigned long.
6815 (sparc64_elf_merge_private_bfd_data): Fix shared library case from
6816 previous fix, so that shared libs really don't influence targets
6817 extension mask and memory model.
6818
6819 2000-05-23 H.J. Lu <hjl@gnu.org>
6820
6821 * elf64-alpha.c (elf64_alpha_relocate_section): Check
6822 h->root.other not h->other.
6823 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
6824
6825 * elf32-ppc.c (ppc_elf_relocate_section): Fix a typo.
6826
6827 2000-05-23 H.J. Lu <hjl@gnu.org>
6828
6829 * elf32-i386.c (elf_i386_relocate_section): Don't allow the
6830 undefined symbol with the non-default visibility attributes.
6831 * elf-hppa.h (elf_hppa_relocate_section): Likewise.
6832 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
6833 * elf32-i370.c (i370_elf_relocate_section): Likewise.
6834 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
6835 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
6836 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
6837 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
6838 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
6839 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
6840 * elf64-ia64.c (elf64_ia64_relocate_section): Likewise.
6841 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
6842
6843 2000-05-22 Richard Henderson <rth@cygnus.com>
6844
6845 * elf64-ia64.c (ia64_howto_table): Add PCREL60B, PCREL21BI,
6846 PCREL22, PCREL64I. Zero size of special relocs.
6847 (elf64_ia64_reloc_type_lookup): Likewise.
6848 (USE_BRL, oor_brl, oor_ip): New.
6849 (elf64_ia64_relax_section): New.
6850 (elf64_ia64_check_relocs): Handle PCREL60B, PCREL22, PCREL64I.
6851 (elf64_ia64_install_value): Likewise, plus PCREL21BI.
6852 (elf64_ia64_relocate_section): Likewise.
6853 (bfd_elf64_bfd_relax_section): New.
6854 * reloc.c (BFD_RELOC_IA64_PCREL21BI): New.
6855 (BFD_RELOC_IA64_{PCREL22,PCREL60B,PCREL64I}): New.
6856 * bfd-in2.h, libbfd.h: Regenerate.
6857
6858 2000-05-22 Nick Clifton <nickc@cygnus.com>
6859
6860 * configure.in : Add peigen.lo to MIPS PE targets.
6861 * configure: Regenerate.
6862
6863 2000-05-22 Momchil Velikov <velco@fadata.bg>
6864
6865 * libbfd.c (_bfd_generic_verify_endian_match): Compare endianess
6866 only if it is known for both input and output bfds. Separate
6867 error message strings as in some languages, it may be necessary
6868 to change more than one place in the string to change between
6869 'big' and 'little'.
6870
6871 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Remove inline
6872 endianess checks, call _bfd_generic_verify_endian_match() instead.
6873
6874 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Likewise.
6875
6876 * elf32-mcore.c (mcore_elf_merge_private_bfd_data): Likewise.
6877
6878 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Likewise. Verify
6879 endianess before checking bfd flavours.
6880
6881 2000-05-22 H.J. Lu <hjl@gnu.org>
6882
6883 * elflink.h (elf_link_output_extsym): Clear the visibility
6884 field for symbols not defined locally.
6885
6886 2000-05-18 Alan Modra <alan@linuxcare.com.au>
6887
6888 * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
6889 re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
6890 (hppa_rebuild_insn): Mask immediate bits here instead.
6891 * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
6892
6893 2000-05-18 Momchil Velikov <velco@fadata.bg>
6894
6895 * elflink.h (elf_bfd_final_link, elf_link_input_bfd): When emiting
6896 relocs for an executable, ensure that they are virtual addresses.
6897
6898 2000-05-18 Jeffrey A Law (law@cygnus.com)
6899
6900 * config.bfd (hppa*64*-*-hpux11*): New target triplet.
6901
6902 2000-05-17 S. Bharadwaj Yadavalli <sby@scrugs.lkg.dec.com>
6903 Rick Gorton <gorton@scrugs.lkg.dec.com>
6904
6905 * elflink.h: Add emitrelocations support: when enabled, relocation
6906 information and relocation sections are put into final output
6907 executables. If the emitrelocations flag is set, do the following:
6908 (elf_bfd_final_link): Emit relocation sections.
6909 (elf_link_input_bfd): Compute relocation section contents.
6910 (elf_gc_sections): Don't clean relocation sections.
6911
6912 2000-05-16 Catherine Moore <clm@cygnus.com>
6913
6914 * som.c (som_decode_symclass): Recognize weak symbols.
6915
6916 2000-05-16 Szabolcs Szakacsits <szaka@F-Secure.com>
6917
6918 * peigen.c (pe_print_idata): Undo part of 2000-05-12 change that
6919 read idata section only from dataoff.
6920 (pe_print_edata): Correctly check for valid eat_member.
6921
6922 2000-05-16 J"orn Rennecke <amylaar@cygnus.co.uk>
6923
6924 * elf32-sh.c (sh_elf_relax_delete_bytes): Handle R_SH_SWITCH8.
6925
6926 2000-05-14 Philip Blundell <philb@gnu.org>
6927
6928 * config.bfd (armeb-*-elf, arm*b-*-linux-gnu*): New targets.
6929
6930 2000-05-12 Alan Modra <alan@linuxcare.com.au>
6931
6932 * targets.c (bfd_target_vector): #ifdef BFD64 rs6000coff64_vec
6933
6934 * peigen.c (pe_print_idata): Look for .idata section and print
6935 info even if data directory has zero entries. Read idata section
6936 starting from dataoff, and adjust all data offsets to suit. Cast
6937 all bfd_vma vars to unsigned long before passing to fprintf.
6938 * peigen.c (pe_print_edata): Similarly, look for .edata section
6939 and print info even if data directory has zero entries. Cast
6940 all bfd_vma vars to unsigned long before passing to fprintf.
6941
6942 From Szabolcs Szakacsits <szaka@F-Secure.com>
6943 * peigen.c (pe_print_idata): Use bfd_section_size rather than data
6944 directory size which may be bogus.
6945 * peigen.c (pe_print_edata): Similarly.
6946
6947 2000-05-09 Alan Modra <alan@linuxcare.com.au>
6948
6949 * elf.c (bfd_section_from_shdr): Don't set use_rela_p if rela
6950 section is empty.
6951 (copy_private_bfd_data): Allow for space possibly taken up by elf
6952 headers when calculating segment physical address from lma.
6953
6954 2000-05-08 Alan Modra <alan@linuxcare.com.au>
6955
6956 * versados.c (versados_scan): Init stringlen and pass_2_done.
6957
6958 * trad-core.c (trad_unix_core_file_p): Return
6959 bfd_error_wrong_format rather than bfd_error_file_truncated.
6960
6961 * peigen.c (_bfd_pei_swap_aouthdr_out): Pass ImageBase to
6962 add_data_entry. DataDirectory virtual address is relative.
6963 (pe_print_idata): Account for relative DataDirectory virtual
6964 addresses. Don't trash datasize inside POWERPC_LE_PE code.
6965 (pe_print_edata): Similarly.
6966
6967 From Szabolcs Szakacsits <szaka@F-Secure.com>
6968 * peigen.c (dir_names): Add Delay Import Directory.
6969 (pe_print_idata): Always search for bfd section containing
6970 idata address rather than looking up section name. Print this
6971 section name rather than .idata.
6972 (pe_print_edata): Similarly. Also print some fields as %08lx.
6973 (_bfd_pe_print_private_bfd_data_common): Print Reserved1 field as
6974 Win32Version.
6975
6976 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
6977
6978 * xcoff.h: Rename to xcoff-target.h
6979 * Makefile.am: Change all instances of xcoff.h to xcoff-target.h
6980 * coff-rs6000.c: Ditto.
6981 * coff64-rs6000.c: Ditto.
6982 * coff-pmac.c: Ditto.
6983 * Makefile.in: Regenerate.
6984
6985 2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
6986
6987 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags):
6988 Change U802TOC64MAGIC to U803XTOCMAGIC.
6989
6990 2000-05-04 Michael Snyder <msnyder@seadog.cygnus.com>
6991
6992 * elf.c (bfd_elf_get_arch_size): New function, return 32 | 64 | -1.
6993 * bfd-in.h: Prototype bfd_elf_get_arch_size.
6994 * bfd-in2.h: Prototype bfd_elf_get_arch_size.
6995
6996 2000-05-04 Alan Modra <alan@linuxcare.com.au>
6997
6998 * libhppa.h (HPPA_R_CONSTANT): Cast argument to bfd_signed_vma.
6999
7000 2000-05-03 Martin v. L\81öwis <loewis@informatik.hu-berlin.de>
7001
7002 * elflink.h (elf_link_add_object_symbols): Reset dynindx for
7003 hidden and internal symbols.
7004 (elf_fix_symbol_flags): Clear NEEDS_PLT for symbols with
7005 visibility.
7006 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Do not
7007 assign a PLT or GOT entry to symbols with hidden and
7008 internal visibility.
7009
7010 2000-05-03 Mark Elbrecht <snowball3@bigfoot.com>
7011
7012 * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add entry for
7013 the .bss section.
7014 * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
7015
7016 2000-05-02 H.J. Lu <hjl@gnu.org>
7017
7018 * elf.c (prep_headers): Use ELFOSABI_NONE instead of
7019 ELFOSABI_SYSV.
7020
7021 2000-05-02 Alan Modra <alan@linuxcare.com.au>
7022
7023 * targets.c (bfd_target_vector): Restore bfd_elf32_hppa_vec.
7024 * Makefile.am (BFD32_BACKENDS): Restore elf32-hppa.lo. Regenerate
7025 dependencies.
7026 * Makefile.in: Regenerate.
7027
7028 2000-05-01 Jim Wilson <wilson@cygnus.com>
7029
7030 * Makefile.am (BFD32_BACKENDS): Add efi-app-ia32.lo.
7031 (BFD32_BACKENDS_CFILES): Add efi-app-ia32.c.
7032 (BFD64_BACKENDS): Delete coff-ia64.lo. Add efi-app-ia64.lo.
7033 (BFD64_BACKENDS_CFILES): Delete coff-ia64.c. Add efi-app-ia64.c.
7034 * Makefile.in: Rebuild.
7035
7036 2000-05-02 Alan Modra <alan@linuxcare.com.au>
7037
7038 * config.bfd: Re-enable elf32-hppa. It now compiles, even if it
7039 doesn't work very well.
7040
7041 * elf-hppa.h (elf_hppa_internal_shdr): Define.
7042 (elf_hppa_fake_sections): hdr is elf_hppa_internal_shdr.
7043 Set hdr->s_type to 1 if ARCH_SIZE == 32.
7044 (_bfd_elf_hppa_gen_reloc_type): Add prototype.
7045 (elf_hppa_info_to_howto): Likewise.
7046 (elf_hppa_info_to_howto_rel): Likewise.
7047 (elf_hppa_reloc_type_lookup): Likewise.
7048 (elf_hppa_is_local_label_name): Likewise.
7049 (elf_hppa_fake_sections): Likewise.
7050 (elf_hppa_final_write_processing): Likewise.
7051 (elf_hppa_howto_table): Fully initialise all entries.
7052 (_bfd_elf_hppa_gen_reloc_type): Add ATTRIBUTE_UNUSED to args.
7053 (elf_hppa_info_to_howto): Likewise.
7054 (elf_hppa_info_to_howto_rel): Likewise.
7055 (elf_hppa_reloc_type_lookup): Likewise.
7056 (elf_hppa_final_write_processing, elf_hppa_add_symbol_hook,
7057 elf_hppa_unmark_useless_dynamic_symbols,
7058 elf_hppa_remark_useless_dynamic_symbols,
7059 elf_hppa_record_segment_addrs, elf_hppa_final_link,
7060 elf_hppa_relocate_section, elf_hppa_final_link_relocate,
7061 elf_hppa_relocate_insn): Compile only if ARCH_SIZE == 64 until
7062 elf32-hppa.c mess is cleaned up.
7063 (elf_hppa_final_link_relocate): Make insn and r_type unsigned
7064 int. Delete r_field. In case R_PARISC_PCREL21L, don't set
7065 r_field then call hppa_field_adjust inline func with variable
7066 r_field arg, instead call hppa_field_adjust with fixed arg.
7067 In case R_PARISC_PCREL22F, don't set r_field.
7068 (elf_hppa_relocate_insn): Change args and return type to unsigned
7069 int. Call re_assemble_* funcs to do the work.
7070
7071 * elf32-hppa.c (hppa_elf_relocate_insn): Don't assume 32 bit when
7072 sign extending.
7073
7074 * libhppa.h (HPPA_R_CONSTANT): Don't assume 32 bit when sign
7075 extending.
7076 (sign_extend): Mask first before sign extending.
7077 (low_sign_extend): Rewrite without condition expression.
7078 (ones, dis_assemble_3, dis_assemble_12, dis_assemble_16,
7079 dis_assemble_17, dis_assemble_21, dis_assemble_22): Delete.
7080 (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
7081 assemble_17, assemble_21, sign_unext, low_sign_unext): Return
7082 result as function return value rather than through pointer arg.
7083 Accept unsigned int args, and return unsigned int.
7084 (re_assemble_3): New. Combines function of dis_assemble_3 with
7085 re-assembly of opcode and immediate.
7086 (re_assemble_12): Likewise.
7087 (re_assemble_16): Likewise.
7088 (re_assemble_17): Likewise.
7089 (re_assemble_21): Likewise.
7090 (re_assemble_22): Likewise.
7091 (hppa_field_adjust): Rewrite and document, paying attention to
7092 size of types and signed/unsigned issues.
7093 (get_opcode): Shift before masking.
7094 (FDLW): Rename to FLDW.
7095 (bfd_hppa_insn2fmt): Change arg to unsigned int. Delete fmt.
7096 (hppa_rebuild_insn): Change args and return value to unsigned
7097 int. Make use of re_assemble_*. Correct case 11.
7098
7099 * dep-in.sed: Handle ../opcodes/.
7100 * Makefile.am (SOURCE_HFILES): Add elf-hppa.h, elf32-hppa.h,
7101 elf64-hppa.h, hppa_stubs.h, xcoff.h.
7102 (BFD32_BACKENDS_CFILES): Restore elf32-hppa.c.
7103 Remove elf64-hppa.lo, cpu-ia64.lo, elf64-ia64.lo, elfarm-oabi.lo,
7104 elfarm-nabi.lo dependencies outside of auto-dependency area.
7105 Regenerate dependencies.
7106 * Makefile.in: Regenerate.
7107
7108 * configure.in (TRAD_HEADER): Test non-null before
7109 AC_DEFINE_UNQUOTED.
7110 * configure: Regenerate.
7111
7112 * reloc.c: Fix mis-spelling in comment.
7113
7114 2000-05-01 Alan Modra <alan@linuxcare.com.au>
7115
7116 * coff-sh.c (bfd_coff_small_swap_table): Fix Fri Apr 28 change.
7117 * vms.c (vms_openr_next_archived_file): Return NULL.
7118
7119 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7120
7121 * coffcode.h Copy changes mistakenly done to libcoff.h in
7122 4/24/2000 patch.
7123
7124 2000-04-29 Andreas Jaeger <aj@suse.de>
7125
7126 * libbfd-in.h: Correctly check GCC version.
7127 * bfd-in.h: Likewise.
7128 * libhppa.h: Likewise.
7129 * libbfd.h: Regenerate.
7130 * bfd-in2.h: Regenerate.
7131
7132 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7133
7134 * Makefile.am (BFD64_BACKENDS, BFD64_BACKENDS_CFILES): Add
7135 coffdu-rs6000.{lo,c}.
7136 (coff-pmac.lo, coff-rs6000.lo, coff64-rs6000.lo): Add dependency
7137 on xcoff.h
7138 * Makefile.in: Regenerate.
7139 * xcoff.h: New file.
7140 * coff-pmac.c: Use xcoff.h instead of coff-rs6000.c.
7141 * coff-rs6000.c: Move all declarations and defines that are
7142 common to the xcoff backends into xcoff.h
7143 * coff64-rs6000.c: Ditto,
7144
7145 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7146
7147 * coff-mips.c (mips_ecoff_backend_data): Add initialization of
7148 _bfd_coff_force_symnames in strings and
7149 _bfd_coff_debug_string_prefix_length to their default values.
7150 * coff-sh.c: (bfd_coff_small_swap_table): Ditto.
7151
7152 2000-04-28 Clinton Popetz <cpopetz@cygnus.com>
7153
7154 * coff-alpha.c (alpha_ecoff_backend_data): Add initialization of
7155 _bfd_coff_force_symnames in strings and
7156 _bfd_coff_debug_string_prefix_length to their default values.
7157
7158 2000-04-27 Alan Modra <alan@linuxcare.com.au>
7159
7160 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Return if dynobj NULL.
7161 Check local_got_refcounts before dereferencing.
7162
7163 * elf32-ppc.c (ppc_elf_relocate_section): Check splt != NULL
7164 before deciding we don't need R_PPC_PLT32 relocation.
7165 (ppc_elf_gc_sweep_hook): Check local_got_refcounts before
7166 dereferencing.
7167
7168 * elflink.h (elf_gc_common_finalize_got_offsets): Fix comment.
7169
7170 * elf32-i386.c (elf_i386_check_relocs): Reference count .got and
7171 .plt entries.
7172 (elf_i386_gc_sweep_hook): Garbage collect .got and .plt entries.
7173 (elf_i386_adjust_dynamic_symbol): Recognize unused .plt entries.
7174 (elf_i386_relocate_section): Allow for .plt to go missing.
7175 (elf_i386_finish_dynamic_symbol): Use same test to decide if we
7176 can use a relative reloc for got as elf_i386_relocate_section.
7177 (bfd_elf32_bfd_final_link): Define to use gc form of final link.
7178
7179 2000-04-26 Clinton Popetz <cpopetz@cygnus.com>
7180
7181 * config.bfd: Remove extraneous bfd_powerpc_64_arch.
7182
7183 2000-04-24 Clinton Popetz <cpopetz@cygnus.com>
7184
7185 * Makefile.am (coff64-rs6000.lo): New rule.
7186 * Makefile.in: Regenerate.
7187 * coff-rs6000.c (xcoff_mkobject, xcoff_copy_private_bfd_data,
7188 xcoff_is_local_label_name, xcoff_rtype2howto,
7189 xcoff_reloc_type_lookup, xcoff_slurp_armap, xcoff_archive_p,
7190 xcoff_read_ar_hdr, xcoff_openr_next_archived_file, xcoff_write_armap,
7191 xcoff_write_archive_contents): No longer static, and prefix with _bfd_.
7192 (NO_COFF_SYMBOLS): Define.
7193 (xcoff64_swap_sym_in, xcoff64_swap_sym_out, xcoff64_swap_aux_in,
7194 xcoff64_swap_aux_out): New functions; handle xcoff symbol tables
7195 internally.
7196 (MINUS_ONE): New macro.
7197 (xcoff_howto_tabl, xcoff_reloc_type_lookup): Add 64 bit POS
7198 relocation.
7199 (coff_SWAP_sym_in, coff_SWAP_sym_out, coff_SWAP_aux_in,
7200 coff_SWAP_aux_out): Map to the new functions.
7201 * coff64-rs6000.c: New file.
7202 * libcoff.h (bfd_coff_backend_data): Add new fields
7203 _bfd_coff_force_symnames_in_strings and
7204 _bfd_coff_debug_string_prefix_length.
7205 (bfd_coff_force_symnames_in_strings,
7206 bfd_coff_debug_string_prefix_length): New macros for above fields.
7207 * coffcode.h (coff_set_arch_mach_hook): Handle XCOFF64 magic.
7208 Set machine to 620 for XCOFF64. Use bfd_coff_swap_sym_in instead
7209 of using coff_swap_sym_in directly.
7210 (FORCE_SYMNAMES_IN_STRINGS): New macro, defined for XCOFF64.
7211 (coff_set_flags) Set magic for XCOFF64.
7212 (coff_compute_section_file_positions): Add symbol name length to
7213 string section length if bfd_coff_debug_string_prefix_length is
7214 true.
7215 (coff_write_object_contents): Don't do reloc overflow for XCOFF64.
7216 (coff_slurp_line_table): Use bfd_coff_swap_lineno_in instead of
7217 using coff_swap_lineno_in directly.
7218 (bfd_coff_backend_data): Add _bfd_coff_force_symnames_in_strings
7219 and _bfd_coff_debug_string_prefix_length fields.
7220 * coffgen.c (coff_fix_symbol_name, coff_write_symbols): Force
7221 symbol names into strings table when
7222 bfd_coff_force_symnames_in_strings is true.
7223 * coffswap.h (MAX_SCNHDR_NRELOC, MAX_SCNHDR_NLNNO, GET_RELOC_VADDR,
7224 SET_RELOC_VADDR): New macros.
7225 (coff_swap_reloc_in, coff_swap_reloc_out): Use above macros.
7226 (coff_swap_aux_in, coff_swap_aux_out): Remove RS6000COFF_C
7227 code.
7228 (coff_swap_aouthdr_in, coff_swap_aouthdr_out): Handle XCOFF64
7229 changes within RS6000COFF_C specific code.
7230 (coff_swap_scnhdr_out): Use PUT_SCNHDR_NLNNO, PUT_SCNHDR_NRELOC,
7231 MAX_SCNHDR_NRELOC, and MAX_SCNHDR_NLNNO.
7232 * reloc.c (bfd_perform_relocation, bfd_install_relocation):
7233 Extend existing hack on target name.
7234 * xcofflink.c (XCOFF_XVECP): Extend existing hack on
7235 target name.
7236 * coff-tic54x.c (ticof): Keep up to date with new fields
7237 in bfd_coff_backend_data.
7238 * config.bfd: Add bfd_powerpc_64_arch to targ_arch and define
7239 targ_selvecs to include rs6000coff64_vec for rs6000.
7240 * configure.in: Add rs6000coff64_vec case.
7241 * cpu-powerpc.c: New bfd_arch_info_type.
7242
7243 2000-04-24 Jeffrey A Law (law@cygnus.com)
7244
7245 * config.bfd: Only disable elf32-hppa vectors, not all of the
7246 BSD and OSF configuration support. Provide (disabled) clauses
7247 for PA64 support.
7248 * configure.in: Add clause for PA64 support.
7249 * configure: Rebuilt.
7250
7251 * targets.c (bfd_target_vector): Add bfd_elf64_hppa_vec.
7252 (bfd_elf64_hppa_vec): Declare.
7253
7254 * Makefile.am (BFD64_BACKENDS): Add elf64-hppa.lo
7255 (BFD64_BACKENDS_CFILES): Add elf64-hppa.c
7256 (elf64-hppa.lo): Add dependencies.
7257 * Makefile.in: Rebuilt.
7258
7259 * elf64-hppa.c, elf64-hppa.h: New files with PA64 support.
7260
7261 2000-04-24 Jason Eckhardt <jle@cygnus.com>
7262
7263 * libhppa.h (dis_assemble_16): New function.
7264 (pa_arch): Added pa20w element.
7265
7266 2000-04-24 Ulrich Drepper <drepper@cygnus.com>
7267
7268 * elf-bfd.h: Add prototypes for bfd_elf32_write_relocs,
7269 bfd_elf32_slurp_reloc_table, bfd_elf64_write_relocs, and
7270 bfd_elf64_slurp_reloc_table.
7271
7272 * elfcode.h (elf_write_relocs, elf_slurp_reloc_table): New
7273 definitions to get external names.
7274 (elf_write_relocs): Renamed from write_relocs and make global.
7275 (elf_slurp_reloc_table): Make global.
7276 (_bfd_elf,size_info): Use elf_write_relocs instead of write_relocs.
7277
7278 * archive.c (hpux_uid_gid_encode): New function.
7279 (bfd_ar_hdr_from_filesystem): Use it if HPUX_LARGE_AR_IDS is
7280 defined and the ID is greater than 99999.
7281 (bfd_generic_stat_arch_elt): If HPUX_LARGE_AR_IDS is defined decode
7282 special uid/gid fields into 32 bit values.
7283
7284 2000-04-21 Matthew Green <mrg@cygnus.com>
7285
7286 * config.bfd: Add NetBSD/sparc64 support.
7287
7288 Fri Apr 21 13:20:53 2000 Richard Henderson <rth@cygnus.com>
7289 David Mosberger <davidm@hpl.hp.com>
7290 Timothy Wall <twall@cygnus.com>
7291 Jim Wilson <wilson@cygnus.com>
7292
7293 * Makefile.am (ALL_MACHINES): Add cpu-ia64.lo.
7294 (ALL_MACHINES_CFILES): Add cpu-ia64.c.
7295 (BFD64_BACKENDS): Add elf64-ia64.lo.
7296 (BFD64_BACKENDS_CFILES): Add elf64-ia64.c.
7297 (cpu-ia64.lo, elf64-ia64.lo): New rules.
7298 * Makefile.in: Rebuild.
7299 * archures.c (enum bfd_architecture): Add bfd_arch_ia64.
7300 (bfd_ia64_arch): Declare.
7301 (bfd_archures_list): Add bfd_ia64_arch.
7302 * bfd-in2.h: Rebuild.
7303 * config.bfd: (ia64*-*-linux-gnu*, ia64*-*-elf*): New targets.
7304 * configure: Rebuild.
7305 * configure.host: (ia64-*-linux*): New host.
7306 * configure.in (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec,
7307 bfd_efi_app_ia64_vec, bfd_efi_app_ia64_vec): New vectors.
7308 * elf.c (prep_headers): Add bfd_arch_ia64.
7309 * libbfd.h: Rebuild.
7310 * reloc.c: Add IA-64 relocations.
7311 * targets.c (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec):
7312 Declare.
7313 (bfd_target_vect): Add bfd_elf64_ia64_little_vec.
7314 * cpu-ia64-opc.c, cpu-ia64.c, elf64-ia64.c: New files.
7315
7316 2000-04-21 Richard Henderson <rth@cygnus.com>
7317
7318 * elf32-d30v.c (bfd_elf_d30v_reloc): Don't modify section
7319 contents when performing a partial link.
7320 (bfd_elf_d30v_reloc_21): Likewise.
7321
7322 2000-04-20 H.J. Lu <hjl@gnu.org>
7323
7324 * elf32-i386.c (elf_i386_relocate_section): Restrict 1998-12-10
7325 patch to symbols defined by a shared object.
7326 * elf32-ppc.c (ppc_elf_relocate_section): Similarly.
7327
7328 2000-04-19 Michael Sokolov <msokolov@ivan.Harhan.ORG>
7329
7330 K&R compiler fixes.
7331 * dwarf2.c (concat_filename): Avoid string literal concatenation.
7332 * ieee.c (ieee_get_symtab): Don't initialise union in struct.
7333
7334 Mon Apr 17 19:14:36 2000 David Mosberger <davidm@hpl.hp.com>
7335
7336 * Makefile.am (BFD64_BACKENDS): Mention coff-ia64.lo.
7337 (BFD64_BACKENDS_CFILES): Mention coff-ia64.c
7338 (coff-ia64.lo): Add dependency.
7339 * Makefile.in: Regenerate.
7340 * coff-ia64.c: New file.
7341 * efi-app-ia32.c: Ditto.
7342 * efi-app-ia64.c: Ditto.
7343 * coffcode.h (coff_set_arch_mach_hook): Handle IA64MAGIC.
7344 (coff_set_flags): Ditto.
7345 (coff_write_object_contents) [IA64]: Set magic number to ZMAGIC.
7346 * config.bfd (i[3456]86-*-linux-gnu*): Mention bfd_efi_app_ia32_vec.
7347 * configure.in (elf): Handle bfd_efi_app_ia32 and bfd_efi_app_ia64_vec.
7348 * configure: Regenerate.
7349 * libpei.h (GET_OPTHDR_IMAGE_BASE): New macro.
7350 (PUT_OPTHDR_IMAGE_BASE): Ditto.
7351 (GET_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
7352 (PUT_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
7353 (GET_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
7354 (PUT_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
7355 (GET_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
7356 (PUT_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
7357 (GET_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
7358 (PUT_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
7359 (GET_PDATA_ENTRY): Ditto.
7360 * peigen.c (_bfd_pei_swap_aouthdr_in) [COFF_WITH_PEP64]: Don't read
7361 data_start. Use above macros to read fields that are 64 bit wide for
7362 COFF_WITH_PEP64. Don't truncate entry and text_start to 32 bits.
7363 (_bfd_pei_swap_aouthdr_out) [PEI_FORCE_MINIMUM_ALIGNMENT]: Force
7364 FileAlignment and SectionAlignment to minimum alignment if they
7365 are zero.
7366 (_bfd_pei_swap_aouthdr_out) [PEI_DEFAULT_TARGET_SUBSYSTEM]: Set
7367 Subsystem to default PEI_DEFAULT_TARGET_SUBSYSTEM.
7368 (_bfd_pei_swap_aouthdr_out) [COFF_WITH_PEP64]: Don't set data_start.
7369 Use above macros to write fields that are 64 bit wide for
7370 COFF_WITH_PEP64.
7371 (pe_print_pdata): Set PDATA_ROW_SIZE to 3*8 for COFF_WITH_PEP64,
7372 5*4 otherwise. This should be right for IA-32 and IA-64, but may
7373 be wrong for platforms. Use PDATA_ROW_SIZE instead of hardcoded
7374 value of 20 bytes. Modify printing for COFF_WITH_PEP64 to print
7375 begin address, end address, and unwind info address only. Use
7376 GET_PDATA_ENTRY() to read .pdata entries. Use fprintf_vma() to
7377 print addresses.
7378 (tbl): Add SECTION, REL32, RESERVED1, MIPS_JMPADDR16, DIR64, and
7379 HIGH3ADJ relocation names.
7380 (_bfd_pe_print_private_bfd_data): Print Subsystem name in legible form.
7381 * targets.c: Declare bfd_efi_app_ia32_vec and
7382 bfd_efi_app_ia64_vec.
7383 (bfd_target_vector): Mention bfd_efi_app_ia32_vec and
7384 bfd_efi_app_ia64_vec.
7385
7386 2000-04-17 Timothy Wall <twall@cygnus.com>
7387
7388 * bfd-in2.h: Add prototypes for tic54x load page access.
7389 * bfd-in.h: Regenerate.
7390 * coff-tic54x.c: Add load page functions; allow bfd_arch_unknown
7391 in customized _set_arch_mach function.
7392 * coffcode.h (coff_set_alignment_hook): Set section load page if
7393 the appropriate macro is defined.
7394 (write_object_contents): Read section load page.
7395
7396 2000-04-13 Alan Modra <alan@linuxcare.com.au>
7397
7398 * elf32-hppa.h: Update copyright date.
7399
7400 * elf32-fr30.c (fr30_elf_i20_reloc): Don't use U suffix.
7401 * elf32-mips.c (_bfd_mips_elf_relocate_section): And here.
7402
7403 * elf32-d30v.c (MAX32): Don't use LL suffix.
7404 (MIN32): Define in terms of MAX32.
7405 (bfd_elf_d30v_reloc): Make relocation a bfd_signed_vma.
7406
7407 * coff-a29k.c (SIGN_EXTEND_HWORD): Replace with more concise
7408 expression.
7409
7410 * peicode.h (pe_ILF_build_a_bfd): Remove UL from hex constants.
7411
7412 2000-04-12 Alan Modra <alan@linuxcare.com.au>
7413
7414 * dep-in.sed: Match space before file name, not after.
7415 * Makefile.am: Regenerate dependencies.
7416 * Makefile.in: Regenerate.
7417
7418 * reloc.c (_bfd_relocate_contents): In complain_overflow_bitfield
7419 case, allow address wrap-around stupidly removed 2000-03-17. Sign
7420 extend without an if statement.
7421
7422 2000-04-11 Alan Modra <alan@linuxcare.com.au>
7423
7424 * coff-mips.c (mips_gprel_reloc): Test for 16 bit range using
7425 signed quantites.
7426 * elf32-mips.c (gprel16_with_gp): Likewise.
7427 * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Test range
7428 here using -0x40000, not (int)0xfffc0000.
7429 (elf32_hppa_size_of_stub): Likewise.
7430
7431 2000-04-11 Timothy Wall <twall@cygnus.com>
7432
7433 * coff-tic54x.c: Now builds with all targets.
7434 * Makefile.am: Add coff/tic54x.h to coff-tic54x.o dependencies.
7435 * Makefile.in: Regenerate.
7436 * coffcode.h (coff_set_arch_mach_hook): Eliminate warning on
7437 unitialized variable.
7438
7439 Fri Apr 7 15:56:57 2000 Andrew Cagney <cagney@b1.cygnus.com>
7440
7441 * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
7442 --enable-build-warnings option.
7443 * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
7444 * Makefile.in, configure: Re-generate.
7445
7446 2000-04-07 Nick Clifton <nickc@cygnus.com>
7447
7448 * reloc.c: Add BFD_RELOC_ARM_PCREL_BLX and
7449 BFD_RELOC_THUMB_PCREL_BLX.
7450
7451 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
7452 R_ARM_XPC25 and R_ARM_THM_PC22.
7453
7454 * elfarm-nabi.c (elf32_arm_howto_): Fix definitions of
7455 R_ARM_XPC25 and R_ARM_THM_XPC22.
7456 (elf32_arm_reloc_map): Make BFD_RELOC_{ARM|THUMB}_PCREL_BLX to
7457 R_ARM_[XPC25|THM_XPC22].
7458
7459 * elfarm-oabi.c: Define OLD_ARM_ABI and change include from
7460 elf/arm-oabi.h to elf/arm.h
7461
7462 * Makefile.am: Fix dependency for elfarm-oabi.c
7463 * Makefile.in: Regenerate.
7464
7465 * bfd-in2.h: Regenerate.
7466 * libbfd.h: Regenerate.
7467
7468 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
7469
7470 * elfcore.h (elf_core_file_p): preserve value of tdata at entry,
7471 and restore it on failure. Release newly allocated tdata on
7472 failure.
7473
7474 Fri Apr 7 11:33:47 2000 Jim Wilson <wilson@cygnus.com>
7475
7476 * dwarf2.c (struct dwarf2_debug): New field dwarf_line_size.
7477 (decode_line_info): Set it. Report error if unit->line_offset is
7478 equal to or larger than it.
7479
7480 2000-04-07 Timothy Wall <twall@cygnus.com>
7481
7482 * targets.c: Added vecs for tic54x.
7483 * reloc.c: Added relocs for tic54x.
7484 * libbfd.h: Regenerated.
7485 * configure: Add TI COFF vecs for tic54x.
7486 * configure.in: Ditto.
7487 * config.bfd (targ_cpu): Recognize new tic54x target.
7488 * coffcode.h (coff_slurp_symbol_table): Additions for TI COFF handling.
7489 * bfd-in2.h: Add tic54x target and relocations.
7490 * Makefile.am, Makefile.in: Add tic54x target.
7491 * archures.c (bfd_archures_list): Add tic54x target.
7492 * coff-tic54x.c: New.
7493 * cpu-tic54x.c: New.
7494
7495 2000-04-06 Michael Snyder <msnyder@seadog.cygnus.com>
7496
7497 * elfcore.h (elf_core_file_p): call backend_object_p which
7498 thereby gets an opportunity to update the arch/machine type.
7499
7500 2000-04-06 Timothy Wall <twall@cygnus.com>
7501
7502 * coffcode.h (coff_slurp_symbol_table): Handle C_STATLAB storage
7503 class. Handle SEC_CLINK and SEC_BLOCK flags.
7504 * section.c: Add SEC_CLINK and SEC_BLOCK flags.
7505 * bfd-in2.h: Add SEC_CLINK and SEC_BLOCK flags.
7506
7507 2000-04-06 Nick Clifton <nickc@cygnus.com>
7508
7509 * elf32-arm.h (elf32_arm_set_private_flags): Only check for
7510 EF_INTERWORK if this is an unknown EABI.
7511 (elf32_arm_merge_private_bfd_data): Check EABI version
7512 numbers. Only check EF_xxx flags if the EABI version number
7513 is unknown.
7514 (elf32_arm_check_private_bfd_data): Only check EF_xxx flags
7515 if the EABI version number is unknown.
7516 (elf32_arm_print_private_bfd_data): Only decode EF_xxx flags
7517 if the EABI version number is unknown.
7518
7519 Wed Apr 5 22:04:20 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
7520
7521 * reloc.c (_bfd_relocate_contents): Add BFD_RELOC_SH_LOOP_START and
7522 BFD_RELOC_SH_LOOP_END.
7523 * elf32-sh.c (sh_elf_howto_tab): Change special_func to
7524 sh_elf_ignore_reloc for all entries that sh_elf_reloc used to ignore.
7525 Add entries for R_SH_LOOP_START and R_SH_LOOP_END.
7526 (sh_elf_reloc_loop): New function.
7527 (sh_elf_reloc): No need to test for always-to-be-ignored relocs
7528 any more.
7529 (sh_rel): Add entries for BFD_RELOC_SH_LOOP_{START,END}.
7530 (sh_elf_relocate_section): Handle BFD_RELOC_SH_LOOP_{START,END}.
7531 * bfd-in2.h, libbfd.h: Regenerate.
7532
7533 2000-04-04 Alan Modra <alan@linuxcare.com.au>
7534
7535 * po/bfd.pot: Regenerate.
7536
7537 * Makefile.am: Remove extraneous mkdep comment.
7538 (MKDEP): Use gcc -MM rather than mkdep.
7539 (DEP): Quote when passing vars to sub-make. Add warning
7540 message to end.
7541 (DEP1): Rewrite for "gcc -MM".
7542 (CLEANFILES): Add DEP2.
7543 Update dependencies.
7544 * Makefile.in: Regenerate.
7545
7546 2000-04-03 Kevin Buettner <kevinb@redhat.com>
7547
7548 * configure.in: Added corefile support for AIX 4.3. In particular,
7549 AIX_CORE_DUMPX_CORE will be defined in addition to AIX_CORE when
7550 compiling rs6000-core.c.
7551 * configure: Regenerated.
7552
7553 2000-04-03 H.J. Lu <hjl@gnu.org>
7554
7555 * cache.c (bfd_open_file): Unlink the output file only if
7556 it has non-zero size.
7557
7558 2000-04-01 Ken Block USG <block@zk3.dec.com>
7559
7560 * elf64-alpha.c (elf64_alpha_relocate_section): Don't emit
7561 relative relocations for non-loaded sections in shared objects.
7562 (elf64_alpha_check_relocs): Similarly.
7563
7564 Mon Apr 3 13:37:15 2000 Hans-Peter Nilsson <hp@axis.com>
7565
7566 * aoutx.h (NAME(aout,reloc_type_lookup)): Add BFD_RELOC_8 and
7567 BFD_RELOC_16 to switch for extended relocs.
7568 (MY_swap_ext_reloc_in): New.
7569 (MY_swap_ext_reloc_out): New.
7570 (NAME(aout,slurp_reloc_table)): Use MY_swap_ext_reloc_in rather
7571 than NAME(aout,swap_ext_reloc_in) for extended relocs.
7572 (NAME(aout,squirt_out_relocs)): Similarly use
7573 MY_swap_ext_reloc_out.
7574 (aout_link_reloc_link_order): Use MY_put_ext_reloc if defined.
7575
7576 2000-04-03 Kazu Hirata <kazu@hxi.com>
7577
7578 * coff-h8300.c (h8300_reloc16_extra_cases): Add bsr:16 -> bsr:8 to
7579 the R_PCRWORD_B case.
7580
7581 2000-03-31 Thomas de Lellis <tdel@wrs.com>
7582
7583 * srec.c : Set CHUNK size to 16 bytes to prevent download failures
7584 on some targets.
7585 * ihex.c : Ditto.
7586
7587 Wed Mar 30 15:28:00 2000 Donald Lindsay <dlindsay@cygnus.com>
7588
7589 * elf32-m32r.c (m32r_elf_generic_reloc): new function. All
7590 HOWTO references to bfd_elf_generic_reloc, that have
7591 partial_inplace == true, now use the new function. The function
7592 is based on the recent rewrite of m32r_elf_lo16_reloc(), and
7593 extends its fixes to the R_M32R_{16,24,32} relocs.
7594 The new logic in m32r_elf_lo16_reloc() has been removed, and
7595 it instead calls the new routine to obtain that functionality.
7596
7597 2000-03-27 Alan Modra <alan@linuxcare.com.au>
7598
7599 * elf32-avr.c (elf32_avr_gc_mark_hook, elf32_avr_gc_sweep_hook,
7600 elf32_avr_check_relocs, avr_final_link_relocate,
7601 elf32_avr_relocate_section, bfd_elf_avr_final_write_processing,
7602 elf32_avr_object_p): Add prototypes.
7603 (elf32_avr_gc_mark_hook): Add default for h->root.type.
7604 (bfd_elf_avr_final_write_processing): Make static.
7605
7606 2000-03-27 Denis Chertykov <denisc@overta.ru>
7607
7608 * cpu-avr.c: New file. BFD support routines for AVR architecture.
7609 * archures.c (bfd_architecture): Add AVR architecture.
7610 (bfd_archures_list): Add reference to AVR architecture info.
7611 * elf.c (prep_headers): Handle bfd_arch_avr.
7612 * reloc.c: Add various AVR relocation enums.
7613 * targets.c (bfd_elf32_avr_vec): Declare and add to target vector
7614 list.
7615 * Makefile.am: Add support for AVR elf.
7616 * configure.in: Likewise.
7617 * config.bfd: Likewise.
7618 * Makefile.in: Regenerate.
7619 * configure: This too.
7620 * bfd-in2.h: And this.
7621 * libbfd.h: And this.
7622
7623 2000-03-24 H.J. Lu <hjl@gnu.org>
7624
7625 * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Add prototype.
7626 (elf64_alpha_find_reloc_at_ofs): Likewise.
7627
7628 2000-03-17 Alan Modra <alan@linuxcare.com.au>
7629
7630 * reloc.c (bfd_check_overflow): In case complain_overflow_bitfield,
7631 flag an overflow if the bitfield is outside -2**n to 2**n-1. The
7632 allowable range used to be -2**(n-1) to 2**n-1.
7633 * reloc.c (_bfd_relocate_contents): Same here. Also replace
7634 "boolean overflow" with "bfd_reloc_status_type flag".
7635
7636 2000-03-14 Doug Evans <dje@casey.transmeta.com>
7637
7638 * elf32-m32r.c (m32r_elf_lo16_reloc): Rewrite.
7639
7640 2000-03-14 Kazu Hirata <kazu@hxi.com>
7641
7642 * reloc16.c (bfd_coff_reloc16_relax_section): Count the total number
7643 of shrinks properly, including the last reloc.
7644
7645 2000-03-13 Kazu Hirata <kazu@hxi.com>
7646
7647 * coff-h8300.c (h8300_reloc16_extra_cases): Fix the sanity
7648 check for R_MOVL2.
7649
7650 2000-03-11 Alan Modra <alan@linuxcare.com.au>
7651
7652 * ieee.c (ieee_archive_p): Return bfd_error_wrong_format on
7653 a format mismatch rather than an "error" from bfd_read such as
7654 bfd_error_file_truncated.
7655
7656 2000-03-10 Geoff Keating <geoffk@cygnus.com>
7657
7658 * elf32-mips.c (_bfd_mips_elf_relocate_section): Do proper
7659 sign-extension and big-endian compensation for
7660 R_MIPS_64 even in ld -r.
7661
7662 2000-03-10 Geoffrey Keating <geoffk@cygnus.com>
7663
7664 * elf32-mips.c (mips_elf_next_relocation): Rename from
7665 mips_elf_next_lo16_relocation, and generalize to look
7666 for any relocation type.
7667 (elf_mips_howto_table): Make R_MIPS_PC16 pcrel_offset.
7668 (elf_mips_gnu_rel_hi16): Howto for R_MIPS_GNU_REL_HI16.
7669 (elf_mips_gnu_rel_lo16): Howto for R_MIPS_GNU_REL_LO16.
7670 (elf_mips_gnu_rel16_s2): Howto for R_MIPS_GNU_REL16_S2.
7671 (elf_mips_gnu_pcrel64): Howto for R_MIPS_PC64.
7672 (elf_mips_gnu_pcrel32): Howto for R_MIPS_PC32.
7673 (bfd_elf32_bfd_reloc_type_lookup): Add new relocs.
7674 (mips_rtype_to_howto): Likewise.
7675 (mips_elf_calculate_relocation): Handle new relocs.
7676 (_bfd_mips_elf_relocate_section): REL_HI16/REL_LO16 relocs
7677 are paired. The addend for R_MIPS_GNU_REL16_S2
7678 is shifted right two bits.
7679
7680 2000-03-10 Alan Modra <alan@linuxcare.com.au>
7681
7682 * reloc.c (bfd_perform_relocation): Undo emacs formatting of
7683 comment, and ensure it doesn't happen again.
7684 (bfd_install_relocation): Same here.
7685 (_bfd_relocate_contents): Don't bother assigning unused signmask
7686 shift result. Fix typos in comments.
7687 Remove trailing whitespace throughout file.
7688
7689 2000-03-07 Doug Evans <dje@casey.transmeta.com>
7690
7691 * reloc.c (reloc_howto_struct): Fix partial_inplace comment.
7692 * bfd-in2.h: Rebuild.
7693
7694 2000-03-06 Nick Clifton <nickc@cygnus.com>
7695
7696 * peicode.h (struct pe_ILF_vars): Add sym_ptr_table and
7697 sym_ptr_ptr fields.
7698 (SIZEOF_ILF_SYM_PTR_TABLE): Define.
7699 (SIZEOF_ILF_STRINGS): Redefine.
7700 (pe_ILF_make_a_symbol-reloc): New function. Creates a symbol
7701 relative reloc, as opposed to a section relative reloc.
7702 (pe_ILF_make_a_symbol): Set the class of local symbols to C_STAT
7703 not C_LABEL.
7704 Add length of symbol's prefix to string pointer.
7705 Store a pointer to the symbol in the symbol pointer table.
7706 (pe_ILF_build_a_bfd): Do not build .idata$2 or .idata$7.
7707 Initialise the symbol pointer table.
7708 Store the hint in the Hint/Name table.
7709 Make the jump reloc be symbol realtive, not section relative.
7710 Create an import symbol for imported code.
7711
7712 2000-03-06 Catherine Moore <clm@cygnus.com>
7713
7714 * elf.c (swap_out_syms): Check for null type_ptr.
7715
7716 2000-03-01 Hans-Peter Nilsson <hp@axis.com>
7717
7718 * aout-target.h (MY(write_object_contents)): Remove unused
7719 and unusable "#if CHOOSE_RELOC_SIZE".
7720 * pc532-mach.c (MY(write_object_contents)): Ditto.
7721 * netbsd.h (MY(write_object_contents)): Ditto.
7722 * hp300hpux.c (MY(write_object_contents)): Ditto.
7723 * freebsd.h (MY(write_object_contents)): Ditto.
7724 * aout-tic30.c (tic30_aout_write_object_contents): Ditto.
7725
7726 2000-02-29 H.J. Lu <hjl@gnu.org>
7727
7728 * peicode.h (jtab): Make it static.
7729
7730 * coff-sh.c (sh_align_load_span): Declared if COFF_WITH_PE is
7731 defined and COFF_IMAGE_WITH_PE is not defined.
7732 (_bfd_sh_align_load_span): Defined as sh_align_load_span if
7733 COFF_WITH_PE is defined and COFF_IMAGE_WITH_PE is not defined.
7734
7735 2000-03-01 Nick Clifton <nickc@cygnus.com>
7736
7737 * coff-arm.c (bfd_arm_process_before_allocation): Make
7738 'symndx' signed to prevent compile time warning.
7739
7740 * coff-mcore.c: Remove unused prototype for pe_object_p.
7741
7742 * coff-sh.c: Add "#ifndef COFF_IMAGE_WITH_PE" around static
7743 functions that are not used when COFF_IMAGE_WITH_PE is
7744 defined.
7745 (struct sh_opcode): Change type of 'flags' field to unsigned
7746 long so that it can hold the USESAS flag.
7747
7748 * coffcode.h (styp_to_sec_flags): Initialise 'target_name'.
7749
7750 * elf-m10300.c (mn10300_elf_relax_section): Initialise
7751 'sym_sec'.
7752
7753 * elf32-i370.c: Add ATTRIBUTE_UNUSED to unused function
7754 parameters.
7755 Remove unusued variables and code.
7756 (elf_backend_add_symbol_hook): Fix prototype.
7757
7758 * elf32-m68k.c (elf_m68k_gc_sweep_hook): Initialise 'sgot' and
7759 'srelgot'.
7760
7761 * elf32-mcore.c (mcore_elf_relocate_section): Initialise
7762 'oldinst'.
7763
7764 * elf32-mips.c: Add ATTRIBUTE_UNUSED to unused function
7765 parameters.
7766 Remove unusued variables and code.
7767 (elf_backend_add_symbol_hook): Fix prototype.
7768
7769 * elf32-sh.c (sh_elf_set_mach_from_flags): Use 'flags'.
7770
7771 * elflink.h (elf_bfd_link_add_symbols): Add ATTRIBUTE_UNUSED
7772 to unused function parameter.
7773
7774 * pe-mips.c: Add ATTRIBUTE_UNUSED to unused function
7775 parameters.
7776 Use EMPTY_HOWTO to initialise empty howto slots.
7777 Remove unused variables.
7778
7779 * peicode.h (pe_ILF_build_a_bfd): Initialise id6.
7780
7781 2000-03-01 H.J. Lu <hjl@gnu.org>
7782
7783 * aoutx.h (aout_link_input_section_std): Pass "true" to
7784 the undefined_symbol callback.
7785 (aout_link_input_section_ext): Likewise.
7786 * bout.c (get_value): Likewise.
7787 * coff-a29k.c (coff_a29k_relocate_section): Likewise.
7788 * coff-alpha.c (alpha_ecoff_get_relocated_section_conten):
7789 Likewise.
7790 (alpha_relocate_section): Likewise.
7791 * coff-arm.c (coff_arm_relocate_section): Likewise.
7792 * coff-i960.c (coff_i960_relocate_section): Likewise.
7793 * coff-mcore.c (coff_mcore_relocate_section): Likewise.
7794 * coff-mips.c (mips_relocate_section): Likewise.
7795 * coff-ppc.c (coff_ppc_relocate_section): Likewise.
7796 * coff-sh.c (sh_relocate_section): Likewise.
7797 * coff-tic80.c (coff_tic80_relocate_section): Likewise.
7798 * cofflink.c (_bfd_coff_generic_relocate_section): Likewise.
7799 * elf-m10200.c (mn10200_elf_relocate_section): Likewise.
7800 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
7801 * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
7802 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
7803 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
7804 * elf32-i370.c (i370_elf_relocate_section): Likewise.
7805 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
7806 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
7807 * elf32-sh.c (sh_elf_relocate_section): Likewise.
7808 * elf32-v850.c (v850_elf_relocate_section): Likewise.
7809 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
7810 * elflink.h (elf_link_output_extsym): Likewise.
7811 * pe-mips.c (coff_pe_mips_relocate_section): Likewise.
7812 * reloc.c (bfd_generic_get_relocated_section_conten): Likewise.
7813 * reloc16.c (_bfd_ppc_xcoff_relocate_section): Likewise.
7814
7815 * elf-hppa.h (elf_hppa_relocate_section): Pass "false" to the
7816 undefined_symbol callback when building shared library with
7817 -Bsymbolic and undefined symbols are allowed. Otherwise, pass
7818 "true".
7819 * elf32-arm.h (elf32_arm_relocate_section): Likewise.
7820 * elf32-i386.c (elf_i386_relocate_section): Likewise.
7821 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
7822 * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
7823 (elf32_mips_get_relocated_section_content): Likewise.
7824 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
7825 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
7826 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
7827 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
7828
7829 2000-02-28 Nick Clifton <nickc@cygnus.com>
7830
7831 * Makefile.am: Add rules to build pe[i]-{sh|mips}.lo objects.
7832 * Makefile.in: Regenerate.
7833
7834 * configure.in: Add support for mips and sh pe vectors.
7835 * configure: regenerate.
7836
7837 * config.bfd: Add support for arm-wince, mips-pe and sh-pe
7838 targets.
7839
7840 * targets.c: Add mips and sh pe vectors.
7841
7842 * libpei.h (coff_final_link_postscript): Only define if not
7843 already defined.
7844
7845 * coffcode.h: Add support for WinCE magic numbers.
7846
7847 * peigen.c (pe_print_reloc): Update comment and rearrange
7848 appending of newline character.
7849
7850 * peicode.h: Add support for Image Library Format.
7851 (pe_ILF_vars): Structure containing data used by ILF code.
7852 (pe_ILF_make_a_section): New function. Create a section based
7853 on ILF data.
7854 (pe_ILF_make_a_reloc): New function. Create a reloc based on
7855 ILF data.
7856 (pe_ILF_make_a_symbol): New function. Create a symbol based
7857 on ILF data.
7858 (pe_ILF_save_relocs): New function. Store the relocs created
7859 by pe_ILF_make_a_reloc in a section.
7860 (pe_ILF_build_a_bfd): New function. Create a BFD describing
7861 an ILF object.
7862 (pe_ILF_object_p): New function. Return a bfd_target pointer
7863 for an ILF object.
7864 (pe_bfd_object_p): If an ILF object is detected call
7865 pe_ILF_object_p on it.
7866
7867 * coff-arm.c: Add support for WinCE relocs which are different
7868 from normal ARM COFF relocs.
7869 * pe-arm.c: Unset TARGET_UNDERSCORE for a WinCE target.
7870
7871 * coff-sh.c: Add support for sh-pe target.
7872 * pe-sh.c: New file. Support code for sh-pe target.
7873 * pei-sh.c: New file. Support code for sh-pe target.
7874
7875 * pe-mips.c: New file. Support code for mips-pe target.
7876 * pei-mips.c: New file. Support code for mips-pe target.
7877
7878 2000-02-27 Jakub Jelinek <jakub@redhat.com>
7879
7880 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Don't bump
7881 architecture if the object causing the bump is dynamic.
7882 * elf64-sparc.c (sparc64_elf_merge_private_bfd_data): Likewise,
7883 and also don't it for memory ordering.
7884 (sparc64_elf_write_relocs): Take src_rela out of the loop.
7885
7886 2000-02-27 Ian Lance Taylor <ian@zembu.com>
7887
7888 * dwarf2.c (read_abbrevs): Use _raw_size directly rather than
7889 calling bfd_get_section_size_before_reloc.
7890 (decode_line_info): Likewise.
7891 (_bfd_dwarf2_find_nearest_line): Likewise.
7892
7893 2000-02-27 Eli Zaretskii <eliz@is.elta.co.il>
7894
7895 * Makefile.am (stamp-lib): Use $(LIBTOOL) --config to get the
7896 name of the libtool directory.
7897 * Makefile.in: Rebuild.
7898
7899 Fri Feb 25 18:39:26 2000 Rodney Brown (RodneyBrown@pmsc.com)
7900
7901 * som.c (SOM_HOWTO): Define.
7902 (som_hppa_howto_table): Use it.
7903
7904 2000-02-25 Alexandre Oliva <oliva@lsd.ic.unicamp.br>
7905
7906 * config.bfd: Enable 64 bit support for GNU/Linux/sparc.
7907
7908 * config.bfd: Enable 64 bit support for Solaris7+/sparc.
7909
7910 2000-02-24 Catherine Moore <clm@cygnus.com>
7911
7912 * som.c (som_misc_symbol_info): Add field
7913 secondary_def.
7914 (som_bfd_derive_misc_symbol_info): Initialize
7915 secondary_def.
7916 (som_build_and_write_symbol_table): Keep track
7917 of secondary_def field.
7918 (som_slurp_symbol_table): Set BSF_WEAK symbol flag
7919 if secondary_def field is set.
7920 (som_bfd_ar_write_symbol_stuff): Initialize
7921 secondary_def.
7922
7923 2000-02-23 Stephane Carrez <stcarrez@worldnet.fr>
7924
7925 * dwarf2.c (read_address): Read 16-bits addresses.
7926 (parse_comp_unit): Accept addr_size == 2.
7927
7928 2000-02-23 Alan Modra <alan@spri.levels.unisa.edu.au>
7929
7930 * bfd-in.h: Update copyright date.
7931
7932 2000-02-23 Linas Vepstas <linas@linas.org>
7933
7934 * cpu-i370.c: New file.
7935 * elf32-i370.c: New file.
7936 * archures.c (enum bfd_architecture): Add bfd_arch_i370.
7937 (bfd_i370_arch): New.
7938 (bfd_archures_list): Add bfd_i370_arch.
7939 * elf.c (prep_headers): Add bfd_arch_i370.
7940 * Makefile.am: Add support for IBM 370 elf.
7941 * config.bfd: Likewise.
7942 * configure.in: Likewise.
7943 * libbfd.h (bfd_reloc_code_real_names): Likewise.
7944 * reloc.c (bfd_reloc_code_type): Likewise.
7945 * targets.c: Likewise.
7946
7947 * Makefile.in: Regenerate.
7948 * configure: Regenerate.
7949 * bfd-in2.h: Regenerate.
7950
7951 2000-02-22 Ian Lance Taylor <ian@zembu.com>
7952
7953 * elf32-i386.c (elf_i386_info_to_howto_rel): Give a warning for
7954 invalid relocation types, and change them to R_386_NONE.
7955
7956 2000-02-22 H.J. Lu <hjl@gnu.org>
7957
7958 * elflink.h (elf_link_add_object_symbols): If a version symbol is
7959 not defined, don't add a second ELF_VER_CHR.
7960
7961 * elflink.h (elf_bfd_final_link): Call output_extsym for global
7962 symbols converted to local symbols even when stripping all
7963 symbols.
7964 (elf_link_output_extsym): Process global symbols converted to
7965 local symbols even if they are being stripped.
7966
7967 2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
7968
7969 * archures.c (bfd_octets_per_byte): Return unsigned int.
7970 (bfd_arch_mach_octets_per_byte): Ditto.
7971 * libbfd.c (bfd_read, bfd_seek): Quell signed vs. unsigned
7972 comparison warning.
7973 * section.c (bfd_get_section_size_before_reloc): Quell signed
7974 vs. unsigned comparison warning.
7975 (bfd_get_section_size_after_reloc): Same here. Fix parentheses too.
7976 * trad-core.c (trad_unix_core_file_p): Correct 2000-01-27
7977 change. What was I thinking?
7978 * bfd-in2.h: Regenerate.
7979
7980 * elflink.h (elf_gc_sweep): Skip non-elf input bfds.
7981 (elf_gc_sections): Same here.
7982 (elf_gc_common_finalize_got_offsets): And here.
7983
7984 2000-02-21 Ian Lance Taylor <ian@zembu.com>
7985
7986 ELF HPPA doesn't work at present; remove it until it does.
7987 * config.bfd: Comment out setting targ_defvec to
7988 bfd_elf32_hppa_vec.
7989 * Makefile.am: Rebuild dependencies.
7990 (BFD32_BACKENDS): Remove elf32-hppa.lo.
7991 (BFD32_BACKENDS_CFILES): Remove elf32-hppa.c.
7992 (SOURCE_HFILES): Remove elf32-hppa.h and hppa_stubs.h.
7993 * Makefile.in: Rebuild.
7994 * targets.c (bfd_target_vector): Comment out bfd_elf32_hppa_vec.
7995
7996 2000-02-18 Geoff Keating <geoffk@cygnus.com>
7997
7998 * coffcode.h (coff_set_arch_mach_hook): Use free(), because there
7999 is no bfd_free(). Revert bfd_free part of previous change.
8000
8001 2000-02-18 Geoff Keating <geoffk@cygnus.com>
8002
8003 * coffcode.h (coff_set_arch_mach_hook): Don't use variable-size
8004 arrays.
8005 (coff_compute_section_file_positions): Use bfd_free to pair
8006 bfd_malloc.
8007 (coff_write_object_contents): Likewise.
8008
8009 * coff-rs6000.c (xcoff_howto_table_16): New variable.
8010 (xcoff_rtype2howto): Handle 16-bit variants of 32-bit relocs.
8011
8012 2000-02-18 Ulrich Drepper <drepper@cygnus.com>
8013
8014 * coff-rs6000.c (XCOFFARMAGBIG): New macro.
8015 (xcoff_ar_file_hdr_big): New structure.
8016 (SIZEOF_AR_FILE_HDR_BIG): New macro.
8017 (xcoff_ar_hdr_big): New structure.
8018 (SIZEOF_AR_HDR_BIG): New macro.
8019 (xcoff_big_format_p): New macro.
8020 (xcoff_ardata_big): New macro.
8021 (arch_xhdr_big): New macro.
8022 (xcoff_slurp_armap): Handle large archives.
8023 (xcoff_archive_p): Detect large archives.
8024 (xcoff_read_ar_hdr): Handle large archives.
8025 (xcoff_openr_next_archived_file): Handle large archives.
8026 (xcoff_generic_stat_arch_elt): Handle large archives.
8027 (xcoff_write_armap_old): Rename from xcoff_write_armap.
8028 (xcoff_write_armap_big): New function.
8029 (xcoff_write_armap): New function, dispatch to _old or _big.
8030 (xcoff_write_archive_contents_old): Rename from
8031 xcoff_write_archive_contents.
8032 (xcoff_write_archive_contents_big): New function.
8033 (xcoff_write_archive_contents): New function, dispatch to _old or
8034 _big.
8035
8036 2000-02-18 Richard Henderson <rth@cygnus.com>
8037
8038 * elf-bfd.h (struct elf_link_hash_table): Remove copy_indirect
8039 and hide_symbol members.
8040 (elf_link_hash_copy_indirect): Remove.
8041 (elf_link_hash_hide_symbol): Remove.
8042 (struct elf_backend_data): Add elf_backend_copy_indirect_symbol
8043 and elf_backend_hide_symbol.
8044 (_bfd_elf_link_hash_copy_indirect): Declare.
8045 (_bfd_elf_link_hash_hide_symbol): Declare.
8046 * elf.c (_bfd_elf_link_hash_copy_indirect): Remove table argument.
8047 (_bfd_elf_link_hash_hide_symbol): Likewise.
8048 (_bfd_elf_link_hash_table_init): Don't init killed members.
8049 * elflink.h (elf_link_add_object_symbols): Use the bed function
8050 pointers not elf_link_hash_{copy_indirect,hide_symbol}.
8051 (elf_link_assign_sym_version): Likewise.
8052 * elfxx-target.h (elf_backend_copy_indirect_symbol): Default.
8053 (elf_backend_hide_symbol): Likewise.
8054 (elfNN_bed): Update for new members.
8055
8056 2000-02-17 Kevin Buettner <kevinb@redhat.com>
8057
8058 * rs6000-core.c (CORE_DATA_SIZE_FIELD, CORE_COMM_FIELD, SAVE_FIELD,
8059 STACK_END_ADDR): Define for new core file format.
8060 (LOADER_OFFSET_FIELD, LOADER_REGION_SIZE, CORE_DUMP): New defines
8061 for handling the vagaries of the various core file structures used
8062 by AIX over the years.
8063 (rs6000coff_core_p, rs6000coff_core_file_matches_executable,
8064 Rs6kCorData): Use above defines to adapt code to use AIX 4.3's
8065 core_dumpx structure.
8066
8067 Thu Feb 17 00:04:48 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
8068
8069 * archures.c (bfd_mach_sh2, bfd_mach_sh_dsp): New macros.
8070 (bfd_mach_sh3_dsp): Likewise.
8071 (bfd_mach_sh4): Reinstate.
8072 (bfd_default_scan): Recognize 7410, 7708, 7729 and 7750.
8073 * bfd-in2.h: Regenerate.
8074 * coff-sh.c (struct sh_opcode): flags is no longer short.
8075 (USESAS, USESAS_REG, USESR8, SETSAS, SETSAS_REG): New macros.
8076 (sh_opcode41, sh_opcode42): Integrate as sh_opcode41.
8077 (sh_opcode01, sh_opcode02, sh_opcode40): Add sh-dsp opcodes.
8078 (sh_opcode41, sh_opcode4, sh_opcode80): Likewise.
8079 (sh_opcodes): No longer const.
8080 (sh_dsp_opcodef0, sh_dsp_opcodef): New arrays.
8081 (sh_insn_uses_reg): Check for USESAS and USESR8.
8082 (sh_insn_sets_reg, sh_insns_conflict): Check for SETSAS.
8083 (_bfd_sh_align_load_span): Return early for SH4.
8084 Modify sh_opcodes lookup table for sh-dsp / sh3-dsp.
8085 Take into account that field b of a parallel processing insn
8086 could be mistaken for a separate insn.
8087 * cpu-sh.c (arch_info_struct): New array elements for
8088 sh2, sh-dsp and sh3-dsp.
8089 Reinstate element for sh4.
8090 (SH2_NEXT, SH_DSP_NEXT, SH3_DSP_NEXT): New macros.
8091 (SH4_NEXT): Reinstate.
8092 (SH3_NEXT, SH3E_NEXT): Adjust.
8093 * elf-bfd.h (_sh_elf_set_mach_from_flags): Declare.
8094 * elf32-sh.c (sh_elf_set_private_flags): New function.
8095 (sh_elf_copy_private_data, sh_elf_set_mach_from_flags): Likewise.
8096 (sh_elf_merge_private_data): New function.
8097 (elf_backend_object_p, bfd_elf32_bfd_set_private_bfd_flags): Define.
8098 (bfd_elf32_bfd_copy_private_bfd_data): Define.
8099 (bfd_elf32_bfd_merge_private_bfd_data): Change to
8100 sh_elf_merge_private_data.
8101
8102 2000-02-13 Richard Henderson <rth@cygnus.com>
8103
8104 * elf-bfd.h (struct elf_link_hash_table): Add copy_indirect and
8105 hide_symbol members.
8106 (elf_link_hash_copy_indirect): New.
8107 (elf_link_hash_hide_symbol): New.
8108 * elflink.h (elf_link_add_object_symbols): Break out copy from
8109 indirect new new symbol to elf.c.
8110 (elf_link_assign_sym_version): Break out privatization of
8111 non-exported symbol to elf.c.
8112 * elf.c (_bfd_elf_link_hash_copy_indirect): New.
8113 (_bfd_elf_link_hash_hide_symbol): New.
8114 (_bfd_elf_link_hash_table_init): Init copy_indirect and hide_symbol.
8115
8116 2000-02-13 Ian Lance Taylor <ian@zembu.com>
8117
8118 * section.c (_bfd_strip_section_from_output): Add info parameter.
8119 If it passed as non-NULL, use it to check whether any input BFD
8120 has an input section which uses this output section. Change all
8121 callers.
8122 * bfd-in2.h: Rebuild.
8123
8124 * bfd-in.h: Move declarations of bfd_get_elf_phdr_upper_bound and
8125 bfd_get_elf_phdrs in from bfd-in2.h, correcting patch of
8126 1999-11-29.
8127 * bfd-in2.h: Rebuild.
8128
8129 2000-02-10 Timothy Wall <twall@cygnus.com>
8130
8131 * coffswap.h (coff_swap_sym_in): Add hook SWAP_SYM_IN_POST to
8132 allow final modifications of swapped-in symbol.
8133 (coff_swap_sym_out): Ditto with SWAP_SYM_OUT_POST.
8134 * coffcode.h (coff_write_relocs): Use macro
8135 SECTION_RELATIVE_ABSOLUTE_SYMBOL_P if defined to determine whether
8136 symbol index should be set to -1.
8137
8138 Thu Feb 10 20:07:50 GMT 2000 Toshiyasu Morita (toshi.morita@sega.com)
8139
8140 * coff-sh.c (USES1_REG, USES2_REG, SETS1_REG, SETS2_REG,
8141 USESF1_REG, USESF2_REG, SETSF1_REG, SETSF2_REG): New macros.
8142 * (sh_insn_sets_reg, sh_insn_sets_freg): New prototypes.
8143 * (sh_insn_sets_reg, sh_insn_uses_or_sets_reg, sh_insns_sets_freg,
8144 sh_insns_uses_or_sets_freg): New functions.
8145 * (sh_insn_uses_reg, sh_insn_uses_freg): Use new macros.
8146 * (sh_insns_conflict): Use new functions and new macros to
8147 detect conflicts when two instructions both set same integer registers,
8148 both set same fp register, and both set special register.
8149
8150 2000-02-09 Timothy Wall <twall@cygnus.com>
8151
8152 * coffgen.c (coff_real_object_p): Set arch/mach info prior to
8153 swapping in sections, so that the swapping routines have access to
8154 the arch/mach info.
8155
8156 2000-02-08 Mark Elbrecht <snowball3@bigfoot.com>
8157
8158 * coff-go32.c: Update comment. Update copyright.
8159
8160 2000-01-27 Thomas de Lellis <tdel@windriver.com>
8161
8162 * syms.c (bfd_decode_symclass)
8163 Two new class characters were added - 'V' and 'v'. The
8164 meaning of 'W' is now restricted to just weak non-object
8165 symbols. This allows differentiation between, for example,
8166 weak functions vs weak objects. nm for example now dumps:
8167 'W' = weak global
8168 'w' = weak unresolved
8169 'V' = weak global object
8170 'v' = weak unresolved object
8171
8172 (bfd_is_undefined_symclass): New function. Return true if the
8173 given symbol class represents and undefined/unresolved symbol.
8174
8175 (bfd_symbol_info): Use bfd_is_undefined_symclass to check for
8176 unresolved symbols.
8177
8178 * bfd-in2.h: Add prototype for bfd_is_undefined_symbol().
8179
8180 * elf32-arm.h (elf32_arm_get_symbol_type): If a symbol has the
8181 STT_ARM_16BIT flag set, but it is not attached to a data object
8182 return STT_ARM_16BIT so that it will be treated as code by the
8183 disassembler.
8184
8185 2000-01-27 Alan Modra <alan@spri.levels.unisa.edu.au>
8186
8187 * coff-i386.c (i3coff_object_p): Remove prototype.
8188 Update copyright.
8189
8190 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Add const
8191 to name. Update copyright.
8192
8193 * trad-core.c (trad_unix_core_file_p): Cast core_regsec
8194 assignment to avoid warning. Update copyright.
8195
8196 2000-01-24 Robert Lipe (robertl@sco.com)
8197
8198 * coffcode.h (coff_write_object_contents): Get buff via bfd_malloc
8199 instead of using GNU C extension.
8200
8201 2000-01-21 Nick Clifton <nickc@cygnus.com>
8202
8203 * libbfd.c (bfd_read): Do not attempt to get a negativly sized
8204 amount from a bfd_in_memory structure.
8205 (bfd_seek): Do not allow seeks past the end of a bfd_in_memory
8206 structure.
8207
8208 2000-01-14 Nick Clifton <nickc@cygnus.com>
8209
8210 * linker.c (default_indirect_link_order): oops - fix incorrectly
8211 applied patch from Tim Wall.
8212
8213 2000-01-13 Timothy Wall (twall@tiac.net>
8214
8215 * coffcode.h: Use bfd_coff_xxx instead of the macro XXX (where xxx
8216 = scnhsz, filhsz, relsz, aoutsz, etc)
8217
8218 * coffswap.h: Ditto.
8219
8220 2000-01-13 Nick Clifton <nickc@cygnus.com>
8221
8222 * elf32-arm.h (elf32_thumb_to_arm_stub): Fix offset in branch to
8223 interwork thumb to arm stub.
8224
8225 2000-01-13 Timothy Wall (twall@tiac.net>
8226
8227 * archures.c (bfd_octets_per_byte): New function: Return
8228 target byte size.
8229 (bfd_arch_mach_octets_per_byte): New function: Return target
8230 byte size.
8231
8232 * section.c: Distinguish between octets and bytes for usage of
8233 _cooked_size, _raw_size, and output_offset. Clarify
8234 description of bfd_set_section_contents.
8235
8236 * bfd-in2.h: Regenerate.
8237
8238 * coffgen.c: Indicate that the offset parameter is in bytes, not
8239 octets.
8240
8241 * cofflink.c (bfd_coff_link_input_bfd): Use bfd_octets_per_byte
8242 where appropriate to get the octet offset when calling
8243 bfd_set_section_contents.
8244 (bfd_coff_reloc_link_order): Ditto.
8245
8246 * linker.c (bfd_generic_reloc_link_order): Ditto.
8247 (_bfd_default_link_order): Ditto.
8248
8249 * reloc.c (bfd_perform_relocation): Distinguish between octets
8250 and bytes. Use octets when indexing into octet data; use bytes
8251 when calculating target addresses.
8252 (bfd_install_relocation): Ditto.
8253
8254 * srec.c (srec_write_section): Ditto.
8255
8256 2000-01-13 Nick Clifton <nickc@cygnus.com>
8257
8258 * coff-mcore.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Change from
8259 3 to 2. This allows 4 byte sized sections, which is necessary for
8260 dlltool to build functioning DLLs.
8261
8262 2000-01-10 Philip Blundell <pb@futuretv.com>
8263
8264 * config.bfd (arm*-*-linux-gnu*): Match instead of arm*-*-linux-gnu.
8265 (arm*-*-conix*): New target.
8266
8267 2000-01-10 Egor Duda <deo@logos-m.ru>
8268
8269 * config.bfd: Include elf32_i386 vector to target list for cygwin
8270 and mingw.
8271
8272 * config.in: Undefine HAVE_WIN32_PSTATUS_T.
8273 * configure.in: Test for structure win32_pstatus_t in
8274 <sys/procfs.h>
8275 * configure: Regenerate.
8276
8277 * elf.c (elfcore_grok_win32pstatus): New function: process
8278 win32_pstatus_t notes in elf core file.
8279 (elfcore_grok_note): Detect win32_pstatus notes.
8280
8281 2000-01-03 Martin v. Loewis <loewis@informatik.hu-berlin.de>
8282
8283 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Process symbol
8284 visibility.
8285 * elflink.h (elf_link_add_object_symbols): Combine visibilities.
8286 * elf.c (bfd_elf_print_symbol): Interpret st_other as visibility.
8287
8288 For older changes see ChangeLog-9899
8289 \f
8290 Local Variables:
8291 mode: change-log
8292 left-margin: 8
8293 fill-column: 74
8294 version-control: never
8295 End:
This page took 0.2225 seconds and 4 git commands to generate.