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