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