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