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