2001-02-06 H.J. Lu <hjl@gnu.org>
[external/binutils.git] / bfd / ChangeLog
1 2001-02-06  H.J. Lu  <hjl@gnu.org>
2
3         * bfd/peicode.h (coff_swap_filehdr_in): Remove the e_magic
4         checking.
5         (pe_bfd_object_p): Rewrite with external_PEI_DOS_hdr and
6         external_PEI_IMAGE_hdr.
7
8 2001-02-06  Kazu Hirata  <kazu@hxi.com>
9
10         * elf-m10200.c: Fix formatting.
11
12 2001-02-04  Nick Clifton  <nickc@redhat.com>
13
14         * elf32-v850.c (v850_elf_reloc): Do not convert reloc addend to PC
15         rel, it will be handled later on.
16
17 2001-02-02  Fred Fish  <fnf@ninemoons.com>
18
19         * Makefile.in: Fix typo.
20
21 2001-02-01  Kazu Hirata  <kazu@hxi.com>
22
23         * elf-m10300.c: Fix formatting.
24
25 2001-01-30  Alan Modra  <alan@linuxcare.com.au>
26
27         * elf64-hppa.c (elf64_hppa_elf_get_symbol_type): New function.
28         (elf_backend_get_symbol_type): Define.
29         (elf64_hppa_object_p): Set architecture and machine from elf
30         header flags.
31
32 2001-01-30  Curtis L. Janssen  <cljanss@ca.sandia.gov>
33
34         * elf64-alpha.c (elf64_alpha_find_nearest_line): Query dwarf2
35         before mdebug.
36
37 2001-01-26  Richard Henderson  <rth@redhat.com>
38
39         * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Return false
40         for non-default visibility.
41         * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise, but
42         delete ugly macro and replace with pretty function.
43
44 2001-01-25  Mark Elbrecht  <snowball3@bigfoot.com>
45
46         * coff-go32.c: Update copyright.
47         * coff-stgo32.c: Likewise.
48         * coff-go32.c (COFF_LONG_FILENAMES): Define.
49         * coff-stgo32.c (COFF_LONG_FILENAMES): Likewise.
50         * coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Remove .bss entry.
51         * coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
52
53 2001-01-25  Kazu Hirata  <kazu@hxi.com>
54
55         * bfd-in2.h: Rebuild.
56         * libbfd.h: Likewise.
57
58 2001-01-23  H.J. Lu  <hjl@gnu.org>
59
60         * bfd-in2.h: Rebuild.
61
62 2001-01-23  H.J. Lu  <hjl@gnu.org>
63
64         * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_buf)
65         is NULL or PRIV(vms_rec) is outside of the buffer.
66
67 2001-01-23  Kazu Hirata  <kazu@hxi.com>
68
69         * coff64-rs6000.c: Fix formatting.
70         * coff-arm.c: Likewise.
71         * coffgen.c: Likewise.
72         * cofflink.c: Likewise.
73         * coff-mcore.c: Likewise.
74         * coff-mips.c: Likewise.
75         * coff-pmac.c: Likewise.
76         * coff-ppc.c: Likewise.
77         * coff-rs6000.c: Likewise.
78         * elf32.c: Likewise.
79         * elf32-fr30.c: Likewise.
80         * elf32-i370.c: Likewise.
81         * elf32-i860.c: Likewise.
82         * elf32-m32r.c: Likewise.
83         * elf32-m68k.c: Likewise.
84         * elf32-mcore.c: Likewise.
85         * elf32-ppc.c: Likewise.
86         * elf32-sh.c: Likewise.
87         * elf32-v850.c: Likewise.
88         * elf64-alpha.c: Likewise.
89         * elf64-sparc.c: Likewise.
90         * elflink.c: Likewise.
91         * elflink.h: Likewise.
92         * elf-m10200.c: Likewise.
93         * elf-m10300.c: Likewise.
94         * elfxx-ia64.c: Likewise.
95
96         * aoutx.h: Fix formatting.
97         * bfd.c: Likewise.
98         * bfd-in2.h: Likewise.
99         * bfd-in.h: Likewise.
100         * cpu-i386.c: Likewise.
101         * cpu-m68hc11.c: Likewise.
102         * dwarf2.c: Likewise.
103         * elf64-x86-64.c: Likewise.
104         * format.c: Likewise.
105         * freebsd.h: Likewise.
106         * hash.c: Likewise.
107         * hp300hpux.c: Likewise.
108         * hppabsd-core.c: Likewise.
109         * hpux-core.c: Likewise.
110
111 2001-01-22  Bo Thorsen  <bo@suse.de>
112
113         * elf64-x86-64.c: Added PIC support for X86-64.
114         (elf64_x86_64_link_hash_newfunc): Function added.
115         (elf64_x86_64_link_hash_table_create): Likewise.
116         (elf64_x86_64_check_relocs): Likewise.
117         (elf64_x86_64_gc_mark_hook): Likewise.
118         (elf64_x86_64_gc_sweep_hook): Likewise.
119         (elf64_x86_64_adjust_dynamic_symbol): Likewise.
120         (elf64_x86_64_size_dynamic_sections): Likewise.
121         (elf64_x86_64_discard_copies): Likewise.
122         (elf64_x86_64_finish_dynamic_symbol): Likewise.
123         (elf64_x86_64_finish_dynamic_sections): Likewise.
124         (elf64_x86_64_relocate_section): Add relocation of PIC sections.
125
126 2001-01-21  Maciej W. Rozycki  <macro@ds2.pg.gda.pl>
127
128         * Makefile.am (install-data-local): Make use of $(DESTDIR).
129         * Makefile.in: Regenerate.
130
131 2001-01-21  Kazu Hirata  <kazu@hxi.com>
132
133         * coff-a29k.c: Fix formatting.
134
135 2001-01-19  H.J. Lu  <hjl@gnu.org>
136
137         * elf32-i386.c (elf_i386_check_relocs): Report files with bad
138         relocation section names.
139         (elf_i386_relocate_section): Report files with bad relocation
140         section names and return false.
141
142 2001-01-17  Bo Thorsen  <bo@suse.de>
143
144         * targets.c: Alphabetize list of xvecs.
145
146 2001-01-14  Alan Modra  <alan@linuxcare.com.au>
147
148         * config.bfd: Add linux target variant for elfxx-hppa.
149         * configure.in: Recognize bfd_elf32_hppa_linux_vec and
150         bfd_elf64_hppa_linux_vec.
151         * configure: Regenerate.
152         * elf64-hppa.c: Include elf64-target.h again to support linux
153         target variant.
154         (elf64_hppa_post_process_headers): Set ELFOSABI_LINUX for linux.
155         * elf32-hppa.c: Include elf32-target.h again to support linux
156         target variant.
157         (elf32_hppa_post_process_headers): New function.
158         (elf_backend_post_process_headers): Define.
159         * targets.c (bfd_target_vector): Add bfd_elf64_hppa_linux_vec and
160         bfd_elf32_hppa_linux_vec.
161
162         * elf32-hppa.c (elf32_hppa_link_hash_table): Add text_segment_base,
163         and data_segment_base fields.
164         (elf32_hppa_link_hash_table_create ): Init them.
165         (elf32_hppa_check_relocs): Update comments.
166         (hppa_record_segment_addr): New function.
167         (elf32_hppa_relocate_section): Call it.
168         (final_link_relocate): Handle R_PARISC_SEGREL32.
169         (elf32_hppa_final_link): New function.
170         (bfd_elf32_bfd_final_link): Define to call it.
171         (hppa_unwind_entry_compare): New function.
172         * cache.c (bfd_open_file): Create files in write+read mode.
173
174         * elf-hppa.h (elf_hppa_howto_table): Set bitsize value for
175         SEGREL32 and numerous other relocs.  Change duplicate
176         R_PARISC_NONE relocs to R_PARISC_UNIMPLEMENTED.
177
178         * opncls.c (bfd_fdopenr): Add parens like the comment says around
179         O_ACCMODE.
180
181         * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Don't create
182         .plt entries for DT_INIT and DT_FINI.
183         (elf32_hppa_finish_dynamic_sections): Remove special handling of
184         DT_INIT and DT_FINI.
185
186         * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Use 16-bit
187         offsets for stub .plt access if wide mode.  Check offset in range.
188
189 2001-01-13  Nick Clifton  <nickc@redhat.com>
190
191         * elf32-fr30.c (fr30_elf_howto_table): Remove spurious blank
192         line.
193
194         * coffcode.h (coff_canonicalize_reloc): Remove spurious blank
195         line.
196
197 2001-01-12  Alan Modra  <alan@linuxcare.com.au>
198
199         * configure.in ([bfd_elf64_x86_64_vec]): Set target64.
200         * configure: Regenerate.
201
202 2001-01-11  Peter Targett  <peter.targett@arccores.com>
203
204         * bfd-in2.h (bfd_architecture): Add bfd_mach_arc_5,
205         bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8 for ARC variants.
206         * cpu-arc.c (arch_info_struct): Add entries for variants.
207         (bfd_arc_arch) Set default to bfd_mach_arc_5.
208         (arc_get_mach) Don't assume machine names prefixed arc- before
209         testing.
210         * elf32-arc.c (arc_elf_object_p): Set machine number based on new
211         selections.
212         (arc_elf_final_write_processing) Likewise.
213         (ELF_MACHINE_CODE) Use EM_ARC.
214
215 2001-01-10  Nick Clifton  <nickc@redhat.com>
216
217         * coff-arm.c (LOCAL_LABEL_PREFIX): Change definition to "".
218
219 2001-01-07  Philip Blundell  <philb@gnu.org>
220
221         * README: Replace `bug-gnu-utils@gnu.org' with
222         `bug-binutils@gnu.org'.
223
224 2001-01-04  Kazu Hirata  <kazu@hxi.com>
225
226         * som.c: Fix formatting.
227
228 2001-01-03  Kazu Hirata  <kazu@hxi.com>
229
230         * ecoffswap.h: Fix formatting.
231         * elf-bfd.h: Likewise.
232         * elfarm-nabi.c: Likewise.
233         * elfarm-oabi.c: Likewise.
234         * elfcode.h: Likewise.
235         * elfcore.h: Likewise.
236         * elflink.c: Likewise.
237         * elflink.h: Likewise.
238         * elfxx-ia64.c: Likewise.
239         * elfxx-target.h: Likewise.
240         * libbfd.c: Likewise
241         * linker.c: Likewise.
242         * lynx-core.c: Likewise.
243
244 2001-01-02  Kazu Hirata  <kazu@hxi.com>
245
246         * pc532-mach.c: Fix formatting.
247         * pe-arm.c: Likewise.
248         * pe-i386.c: Likewise.
249         * pe-mips.c: Likewise.
250         * pe-ppc.c: Likewise.
251         * pe-sh.c: Likewise.
252         * pei-mips.c: Likewise.
253         * pei-sh.c: Likewise.
254         * peicode.h: Likewise.
255         * ppcboot.c: Likewise.
256         * ptrace-core.c: Likewise.
257
258 2001-01-01  Kazu Hirata  <kazu@hxi.com>
259
260         * reloc.c: Fix formatting.
261         * riscix.c: Likewise.
262         * rs6000-core.c: Likewise.
263         * xcoff-target.h: Likewise.
264
265 2000-12-29  Hans-Peter Nilsson  <hp@bitrange.com>
266
267         * elfcode.h (elf_object_p): Also restore the bfd mach field on
268         error, by calling bfd_default_set_arch_mach with incoming
269         values.
270
271 2000-12-26  Kazu Hirata  <kazu@hxi.com>
272
273         * vaxnetbsd.c: Fix formatting.
274         * versados.c: Likewise.
275         * vms-gsd.c: Likewise.
276         * vms-hdr.c: Likewise.
277         * vms-misc.c: Likewise.
278
279 2000-12-25  Alexandre Oliva  <aoliva@redhat.com>
280
281         * archive.c (coff_write_armap): Don't write more than symbol_count
282         `archive_member_file_ptr's.
283
284 2000-12-25  Kazu Hirata  <kazu@hxi.com>
285
286         * vms-tir.c: Fix formatting.
287
288 2000-12-23  Kazu Hirata  <kazu@hxi.com>
289
290         * vms.c: Fix formatting.
291         * vms.h: Likewise.
292
293 2000-12-21  Santeri Paavolainen <santtu@ssh.com>
294
295         * vms-hdr.c: Include alloca.h if HAVE_ALLOCA_H is defined.
296
297         * peicode.h (pe_ILF_object_p): Add const to import of TARGET_LITTLE_SYM.
298
299         * elf32-m32r.c (m32r_elf_generic_reloc): Add cast to avoid (void *)
300         arithmetic.
301
302         * elf32-fr30.c: Add casts to avoid (void *) arithmetic.
303
304         * coffcode.h (styp_to_sec_flags): Add empty statement after label.
305
306 2000-12-21  Richard Sandiford  <rsandifo@redhat.com>
307
308         * libbfd.c (bfd_get_bits): Added
309         (bfd_put_bits): Likewise
310         * bfd-in.h: Declared the above.
311         * bfd-in2.h: Regenerated.
312
313 2000-12-20  Kazu Hirata  <kazu@hxi.com>
314
315         * targets.c: Fix formatting.
316         * tekhex.c: Likewise.
317         * trad-core.c: Likewise.
318
319 2000-12-19  Kazu Hirata  <kazu@hxi.com>
320
321         * sco5-core.c: Fix formatting.
322         * section.c: Likewise.
323         * sparclinux.c: Likewise.
324         * sparclynx.c: Likewise.
325         * sparcnetbsd.c: Likewise.
326         * srec.c: Likewise.
327         * stabs.c: Likewise.
328         * stab-syms.c: Likewise.
329         * sunos.c: Likewise.
330         * syms.c: Likewise.
331         * sysdep.h: Likewise.
332
333 2000-12-18  Nick Clifton  <nickc@redhat.com>
334
335         * coff-arm.c (EXTRA_S_FLAGS): Only define if not already
336         defined.
337         * epoc-pe-arm.c (EXTRA_S_FLAGS): Define.
338         * epoc-pei-arm.c (EXTRA_S_FLAGS): Define.
339
340 2000-12-18  Nick Clifton  <nickc@redhat.com>
341
342         * vms-misc.c (_bfd_vms_get_record): Add default case to
343         file_format switch.
344
345 2000-12-15  Miloslav Trmac <mitr@volny.cz>
346
347         * elfcore.h (elf_core_file_p): Move to the start of the program
348         headers before attempting to read them.
349
350 2000-12-14  Kazu Hirata  <kazu@hxi.com>
351
352         * peigen.c: Fix formatting.
353         * som.c: Likewise.
354         * som.h: Likewise.
355
356 2000-12-13  Kazu Hirata  <kazu@hxi.com>
357
358         * peigen.c: Fix formatting.
359
360 2000-12-12  Jim Wilson  <wilson@redhat.com>
361
362         *  elfxx-ia64.c (get_dyn_sym_info): Cast %p argument to void *.
363
364 2000-12-08  Mark Salter  <msalter@redhat.com>
365
366         * binary.c (binary_set_section_contents): Ignore sections
367         with zero size.
368
369 2000-12-12  Kazu Hirata  <kazu@hxi.com>
370
371         * m68klinux.c: Fix formatting.
372         * m68knetbsd.c: Likewise.
373         * mipsbsd.c: Likewise.
374         * netbsd-core.c: Likewise.
375         * netbsd.h: Likewise.
376         * newsos3.c: Likewise.
377         * nlm32-alpha.c: Likewise.
378         * nlm32-i386.c: Likewise.
379         * nlm32-ppc.c: Likewise.
380         * nlm32-sparc.c: Likewise.
381         * nlmcode.h: Likewise.
382         * nlmswap.h: Likewise.
383         * nlm-target.h: Likewise.
384         * ns32knetbsd.c: Likewise.
385
386 2000-12-10  Fred Fish  <fnf@be.com>
387
388         * elflink.h (elf_link_output_extsym): Don't complain about undefined
389         symbols in shared objects if allow_shlib_undefined is true.
390
391 2000-12-12  Nick Clifton  <nickc@redhat.com>
392
393         * cpu-sh.c: Fix formattng.
394         * elf.c: Fix formattng.
395         * elf32-mips.c: Fix formattng.
396         * elf32-sh.c: Fix formattng.
397         * elf64-alpha.c: Fix formattng.
398
399 2000-12-09  Nick Clifton  <nickc@redhat.com>
400
401         * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Pass
402         dwarf2_find_line_info as last parameter to invocation of
403         _bfd_dwarf2_find_nearest_line.
404         * elf32-arm.h (elf32_arm_find_nearest_line): Pass
405         dwarf2_find_line_info as last parameter to invocation of
406         _bfd_dwarf2_find_nearest_line.
407
408 2000-12-08  Mark Elbrecht  <snowball3@bigfoot.com>
409
410         * Makefile.am (BFD32_BACKENDS): Move dwarf2.lo from here...
411         (BFD_LIBS): ...to here.
412         (BFD32_BACKENDS_CFILES): Move dwarf2.c from here...
413         (BFD_LIBS_CFILES): ...to here.
414         * Makefile.in: Regenerate.
415         * configure.in: Remove dwarf.lo from the elf shell variable.
416         * configure: Regenerate.
417         * libcoff-in.h (coff_tdata): Add pointer dwarf2_find_line_info.
418         * libcoff.h: Regenerate.
419         * coffgen.c (coff_find_nearest_line): Call
420         _bfd_dwarf2_find_nearest_line.
421         * dwarf2.c (_bfd_dwarf2_find_nearest_line): Add parameter. Update
422         accordingly.
423         (read_abbrevs): Likewise
424         (decode_line_info): Likewise.
425         (parse_comp_unit): Likewise.
426         (comp_unit_find_nearest_line): Likewise.
427         * libbfd-in.h (_bfd_dwarf2_find_nearest_line): Update prototype.
428         * libbfd.h: Regenerate.
429         * elf.c (_bfd_elf_find_nearest_line): Update call.
430         * elf-bfd.h (elf_obj_tdata): Change dwarf2_find_line_info to type PTR.
431         * dwarf2.c (concat_filename): Use IS_ABSOLUTE_PATH.
432         * coffcode.h (STYP_XCOFF_DEBUG, STYP_DEBUG_INFO): New macros.
433         (sec_to_styp_flags): Use them. Handle DWARF2 sections.
434         (styp_to_sec_flags): Handle DWARF2 sections.
435         * elf32-arm.h (elf32_arm_find_nearest_line): Add parameter to call
436         to _bfd_find_nearest_line.
437         * elf32-mips.c (_bfd_mips_elf_find_nearest_line): Add parameter to
438         call to _bfd_find_nearest_line.
439
440 2000-12-08  Kazu Hirata  <kazu@hxi.com>
441
442         * coffgen.c: Fix formatting.
443         * elf-m10300.c: Likewise.
444         * elf32-i386.c: Likewise.
445         * elf32-i960.c: Likewise.
446         * elf32-m68k.c: Likewise.
447         * elf32-mcore.c: Likewise.
448         * elf32-ppc.c: Likewise.
449         * elf32-sh.c: Likewise.
450         * elf32-sparc.c: Likewise.
451         * elf32-v850.c: Likewise.
452         * elf64-alpha.c: Likewise.
453         * elf64-hppa.c: Likewise.
454         * elf64-mips.c: Likewise.
455         * elf64-sparc.c: Likewise.
456
457 2000-12-07  Kazu Hirata  <kazu@hxi.com>
458
459         * elf32-ppc.c: Fix formatting.
460         * elf64-x86-64.c: Likewise.
461
462 2000-12-06  Ulf Carlsson  <ulfc@engr.sgi.com>
463
464         From  Ralf Baechle  <ralf@gnu.org>
465
466         * elf32-mips.c (elf32_mips_merge_private_bfd_data): Always permit
467         BFDs containing no sections or empty .text, .data or .bss sections
468         to be merged, regardless of their flags.
469
470 2000-12-06  Kazu Hirata  <kazu@hxi.com>
471
472         * elf32-m32r.c: Fix formatting.
473         * elf32-m68hc11.c: Likewise.
474         * elf32-m68hc12.c: Likewise.
475         * elf32-m68k.c: Likewise.
476         * elf32-mcore.c: Likewise.
477         * elf32-pj.c: Likewise.
478         * elf32-ppc.c: Likewise.
479
480 2000-12-05  Kazu Hirata  <kazu@hxi.com>
481
482         * elf32-fr30.c: Fix formatting.
483         * elf32-hppa.c: Likewise.
484         * elf32-i370.c: Likewise.
485         * elf32-i386.c: Likewise.
486         * elf32-i860.c: Likewise.
487         * elf32-i960.c: Likewise.
488
489 2000-12-03  Kazu Hirata  <kazu@hxi.com>
490
491         * elf32-arm.h: Fix formatting.
492         * elf32-avr.c: Likewise.
493         * elf32-cris.c: Likewise.
494         * elf32-d10v.c: Likewise.
495         * elf32-d30v.c: Likewise.
496         * elf-hppa.h: Likewise.
497         * elf-m10200.c: Likewise.
498         * elf-m10300.c: Likewise.
499
500 2000-12-01  Chris Demetriou  <cgd@sibyte.com>
501
502         * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mips32 and
503         bfd_mach_mips32_4k.  Update FIXME comment.
504         * archures.c (bfd_mach_mips32): New constant.
505         (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
506         the latter, renumber it.
507         * bfd-in2.h (bfd_mach_mips32): New constant.
508         (bfd_mach_mips4K, bfd_mach_mips32_4k) Rename the former to
509         the latter, renumber it.
510         * cpu-mips.c (I_mips32): New constant.
511         (I_mips4K, I_mips32_4k): Rename the former to the latter.
512         (arch_info_struct): Add bfd_mach_mips32 entry, replace
513         bfd_mach_mips4K entry with bfd_mach_mips32_4k entry.
514         * elf32-mips.c (elf_mips_isa): Add E_MIPS_ARCH_32 case.
515         (elf_mips_mach): Likewise.  Also, replace E_MIPS_MACH_MIPS32
516         with E_MIPS_MACH_MIPS32_4K.
517         (_bfd_mips_elf_final_write_processing): Replace
518         bfd_mach_mips4K with bfd_mach_mips32_4k case, add
519         bfd_mach_mips32 case.
520         (_bfd_mips_elf_merge_private_bfd_data): Generalize ISA mixing
521         comparison with support for MIPS32.
522         (_bfd_mips_elf_print_private_bfd_data): Print ISA name for
523         MIPS32.
524
525         * aoutx.h (NAME(aout,machine_type)): Add cases for
526         bfd_mach_mips5 and bfd_mach_mips64.
527         * archures.c (bfd_mach_mips5, bfd_mach_mips64): New constants.
528         * bfd-in2.h (bfd_mach_mips5, bfd_mach_mips64): Likewise.
529         * cpu_mips.c (I_mips5, I_mips64): New definitions.
530         (arch_info_struct): Add entries for bfd_mach_mips5 and
531         bfd_mach_mips64.
532         * elf32-mips.c (elf_mips_isa, elf_mips_mach,
533         _bfd_mips_elf_print_private_bfd_data): Add cases for
534         E_MIPS_ARCH_5 and E_MIPS_ARCH_64.
535         (_bfd_mips_elf_final_write_processing): Add cases for
536         bfd_mach_mips5 and bfd_mach_mips64.
537
538         * bfd/aoutx.h (NAME(aout,machine_type)): Add a
539         bfd_mach_mips_sb1 case.
540         * bfd/archures.c (bfd_mach_mips_sb1): New constant.
541         * bfd/bfd-in2.h (bfd_mach_mips_sb1): New constant.
542         * bfd/cpu-mips.c (I_sb1): New constant.
543         (arch_info_struct): Add entry for bfd_mach_mips_sb1.
544         * bfd/elf32-mips.c (elf_mips_mach): Add case for
545         E_MIPS_MACH_SB1.
546         (_bfd_mips_elf_final_write_processing): Add case for
547         bfd_mach_mips_sb1.
548
549 2000-12-01  Joel Sherrill <joel@OARcorp.com>
550
551         * config.bfd (arm-*-rtems*, a29k-*rtems*): New targets.
552         (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
553         (sparc*-*-rtems*): Switched from a.out to ELF.
554
555 2000-11-30  Jan Hubicka  <jh@suse.cz>
556
557         * Makefile.am (BFD64_BACKENDS): Add elf64-x86-64.lo
558         BFD64_BACKENDS_CFILES): Add elf64-x86-64.c
559         (elf64-x86-64.lo): Add dependencies.
560         * archures.c (DESCRIPTION): Add bfd_mach_x86_64,
561         bfd_mach_x86_64_intel_syntax.
562         * elf.c (prep_headers): Use EM_x86_64 for 64bit output.
563         * config.bfd (x86_64): Add.
564         * configure.in: Add support for bfd_elf64_x86_64_vec.
565         * cpu-i386.c (bfd_x86_64_arch_intel_syntax, bfd_x86_64_arch): Add.
566         (bfd_i386_arch, i8086_ar): Link in.
567         * elf64-x86-64.c: New file.
568         * reloc.c (ENUMDOC): Add BFD_RELOC_X86_64*.
569         * targets.c (bfd_elf64_x86_64_vec): Add.
570         (bfd_target_vect): Add bfd_elf64_x86_64_vec.
571
572 2000-11-30  Kazu Hirata  <kazu@hxi.com>
573
574         * xcofflink.c: Fix formatting.
575
576 2000-11-28  Kazu Hirata  <kazu@hxi.com>
577
578         * aoutx.h: Fix formatting.
579         * bfd-in.h: Likewise.
580         * bfd-in2.h: Likewise.
581         * cache.c: Likewise.
582         * cisco-core.c: Likewise.
583         * coff64-rs6000.c: Likewise.
584         * coffcode.h: Likewise.
585         * coffswap.h: Likewise.
586         * corefile.c: Likewise.
587         * elf32-mips.c: Likewise.
588
589 2000-11-27  Kazu Hirata  <kazu@hxi.com>
590
591         * aout-adobe.c: Fix formatting.
592         * coff64-rs6000.c: Likewise.
593         * coffgen.c: Likewise.
594         * cofflink.c: Likewise.
595
596 2000-11-27  Philip Blundell  <pb@futuretv.com>
597
598         * libcoff-in.h (coff_tdata): Add `strings_written' flag.
599         (obj_coff_strings_written): New accessor macro for above.
600         * libcoff.h: Regenerate.
601         * cofflink.c (_bfd_coff_final_link): Say that we wrote the
602         strings.
603         * coffcode.h (coff_write_object_contents): No need to write out
604         the string table if it's already been done.
605
606 2000-11-22  Philip Blundell  <pb@futuretv.com>
607
608         * cofflink.c (_bfd_coff_generic_relocate_section): Don't object to
609         weak undefined symbols.
610
611 2000-11-24  Nick Clifton  <nickc@redhat.com>
612
613         * archures.c (bfd_mach_arm_5TE): Define.
614         (bfd_mach_arm+XScale): Define.
615         * bfd-in2.h: Regenerate.
616
617         * coff-arm.c (coff_arm_reloc_type_lookup): Accept
618         BFD_RELOC_ARM_PCREL_BLX.
619
620         * coffcode.h (coff_set_flags): Set flags for 5t, 5te and
621         XScale machine numbers.
622
623         * config.bfd (xscale-elf): Add target.
624         (xscale-coff): Add target.
625
626         * cpu-arm.c: Add xscale machine name.
627         Add v5t, v5te and XScale machine numbers.
628
629 2000-11-23  Kazu Hirata  <kazu@hxi.com>
630
631         * aix386-core.c: Fix formatting.
632
633 2000-11-22  Jim Wilson  <wilson@redhat.com>
634
635         * coff-ia64.c (howto_table): Use EMPTY_HOWTO.
636         (in_reloc_p): Add ATTRIBUTE_UNUSED to unused parameters.
637         * cpu-ia64-opc.c (ins_rsvd, ext_rsvd, ins_const, ext_const): Likewise.
638         (ins_imms_scaled): Initialize sign_bit at function entry.
639         (elf64_ia64_operands): Add missing initializers.
640         * elfxx-ia64.c (elfNN_ia64_reloc, elfNN_ia64_reloc_type_lookup,
641         elfNN_ia64_info_to_howto, elfNN_ia64_fake_sections,
642         elfNN_ia64_add_symbol_hook, elfNN_ia64_is_local_label_name,
643         elfNN_ia64_local_hash_table_init, get_fptr, get_pltoff,
644         elfNN_ia64_adjust_dynamic_symbol): Add ATTRIBUTE_UNUSED for unused
645         parameters.
646         (elfNN_ia64_info_to_howto): Initialize free_relocs, free_contents,
647         and free_extsyms at function entry.
648         (elfNN_add_symbol_hook): Add unsigned cast to bfd_get_gp_size result.
649         (elfNN_ia64_create_dynamic_sections): Delete unused local h.
650         (get_got): Delete unused local srel.
651         (elfNN_ia64_check_relocs): Initialize dynrel_type when declared.
652         (elfNN_ia64_relocate_section): Delete unused local dynindx.
653
654 2000-11-21  Kazu Hirata  <kazu@hxi.com>
655
656         * coff-a29k.c: Fix formatting.
657         * coff-h8500.c: Likewise.
658         * coff-i960.c: Likewise.
659         * coff-ppc.c: Likewise.
660         * coff-rs6000.c: Likewise.
661         * coff-stgo32.c: Likewise.
662         * coff-tic54x.c: Likewise.
663         * coff-w65.c: Likewise.
664         * cpu-h8500.c: Likewise.
665         * cpu-hppa.c: Likewise.
666         * cpu-ns32k.c: Likewise.
667         * ecoff.c: Likewise.
668         * ecofflink.c: Likewise.
669
670 2000-11-21  Nick Clifton  <nickc@redhat.com>
671
672         * elf32-sh.c (sh_elf_reloc_loop): Fix compile time warning, and
673         remove possibility of infinite loop.
674
675 2000-11-20  Kazu Hirata  <kazu@hxi.com>
676
677         * aix386-core.c: Fix formatting.
678         * aout-adobe.c: Likewise.
679         * aout-arm.c: Likewise.
680         * aout-encap.c: Likewise.
681         * aout-ns32k.c: Likewise.
682         * aout-target.h: Likewise.
683         * aout-tic30.c: Likewise.
684         * aoutf1.h: Likewise.
685         * aoutx.h: Likewise.
686         * archive.c: Likewise.
687         * bfd-in.h: Likewise.
688         * bfd-in2.h: Likewise.
689         * bfd.c: Likewise.
690         * bout.c: Likewise.
691
692 2000-11-17  H.J. Lu  <hjl@gnu.org>
693
694         * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Don't create
695         pltoff entries for DT_INIT and DT_FINI.
696         (elfNN_ia64_final_link): Don't set DT_INIT/FINI entries.
697         (elfNN_ia64_finish_dynamic_sections): Don't fill in DT_INIT/FINI
698         entries.
699
700 2000-11-16  Richard Henderson  <rth@redhat.com>
701
702         * elfxx-ia64.c (elfNN_ia64_check_relocs): Handle IPLT relocs.
703         (allocate_dynrel_entries): Likewise.
704         (elfNN_ia64_relocate_section): Likewise.  Set REL addends correctly.
705         (set_pltoff_entry): Likewise.
706         (ia64_howto_table): Remove R_IA64_SEGBASE, and R_IA64_EPLT[ML]SB
707         (elfNN_ia64_reloc_type_lookup): Likewise.
708         (elfNN_ia64_install_value): Likewise.
709         (elfNN_ia64_relocate_section): Likewise.
710         * reloc.c (BFD_RELOC_IA64_SEGBASE): Remove.
711         (BFD_RELOC_IA64_EPLTMSB, BFD_RELOC_IA64_EPLTLSB): Remove.
712
713 2000-11-16  Kazu Hirata  <kazu@hxi.com>
714
715         * cpu-a29k.c: Fix formatting.
716         * cpu-alpha.c: Likewise.
717         * cpu-arm.c: Likewise.
718         * cpu-avr.c: Likewise.
719         * cpu-d10v.c: Likewise.
720         * cpu-h8500.c: Likewise.
721         * cpu-hppa.c: Likewise.
722         * cpu-i370.c: Likewise.
723         * cpu-i386.c: Likewise.
724         * cpu-i960.c: Likewise.
725         * cpu-ia64-opc.c: Likewise.
726         * cpu-ia64.c: Likewise.
727         * cpu-m32r.c: Likewise.
728         * cpu-m68hc11.c: Likewise.
729         * cpu-m68hc12.c: Likewise.
730         * cpu-m68k.c: Likewise.
731         * cpu-m88k.c: Likewise.
732         * cpu-mips.c: Likewise.
733         * cpu-ns32k.c: Likewise.
734         * cpu-pj.c: Likewise.
735         * cpu-powerpc.c: Likewise.
736         * cpu-sh.c: Likewise.
737         * cpu-sparc.c: Likewise.
738         * cpu-tic54x.c: Likewise.
739         * cpu-v850.c: Likewise.
740         * cpu-vax.c: Likewise.
741         * cpu-w65.c: Likewise.
742         * cpu-we32k.c: Likewise.
743         * cpu-z8k.c: Likewise.
744         * dwarf1.c: Likewise.
745         * dwarf2.c: Likewise.
746
747 2000-11-15  Kazu Hirata  <kazu@hxi.com>
748
749         * coff-arm.c: Fix formatting.
750         * coff-ppc.c: Likewise.
751         * coff-rs6000.c: Likewise.
752         * coff-sh.c: Likewise.
753         * coff-sparc.c: Likewise.
754         * coff-tic30.c: Likewise.
755         * coff-tic54x.c: Likewise.
756         * coff-tic80.c: Likewise.
757         * coff-w65.c: Likewise.
758         * coff-we32k.c: Likewise.
759         * coff-z8k.c: Likewise.
760
761 2000-11-15  Richard Henderson  <rth@redhat.com>
762
763         * elf64-alpha.c (elf64_alpha_check_relocs): Create the reloc
764         section with the same ALLOC|LOAD flags as the source section.
765
766 2000-11-14  Jakub Jelinek  <jakub@redhat.com>
767
768         * elf64-alpha.c (elf64_alpha_relax_opt_call): Only check bits used
769         by STO_ALPHA constants.
770
771 2000-11-14  Kazu Hirata  <kazu@hxi.com>
772
773         * coff-pmac.c: Fix formatting.
774         * coff-ppc.c: Likewise.
775
776 2000-11-13  H.J. Lu  <hjl@gnu.org>
777
778         * elflink.h (elf_link_add_object_symbols): Also add indirect
779         symbols for common symbols with the default version.
780
781 2000-11-09  Philip Blundell  <pb@futuretv.com>
782
783         * section.c (STD_SECTION): Set gc_mark flag.
784
785 2000-11-11  Kazu Hirata  <kazu@hxi.com>
786
787         * coff-i960.c: Likewise.
788         * coff-m68k.c: Likewise.
789         * coff-m88k.c: Likewise.
790         * coff-mcore.c: Likewise.
791         * coff-mips.c: Likewise.
792
793 2000-11-11  Bernd Schmidt  <bernds@cygnus.co.uk>
794
795         * elf32-sh.c (sh_elf_relocate_section): Ignore R_SH_NONE relocs.
796
797 2000-11-10  Kazu Hirata  <kazu@hxi.com>
798
799         * coff-h8300.c: Fix formatting.
800         * coff-h8500.c: Likewise.
801         * coff-i386.c: Likewise.
802         * coff-i860.c: Likewise.
803         * coff-i960.c: Likewise.
804         * coff-ia64.c: Likewise.
805
806 2000-11-09  Kazu Hirata  <kazu@hxi.com>
807
808         * archive.c: Fix formatting.
809         * archures.c: Likewise.
810
811 2000-11-07  Richard Henderson  <rth@redhat.com>
812
813         * elfxx-ia64.c (elf64_ia64_final_link): New local unwind_output_sec.
814         Set it before bfd_elf64_bfd_final_link call.  Use it after the call.
815         * section.c (bfd_set_section_contents): Call memcpy if
816         section->contents set and location not equal to contents plus offset.
817
818 2000-11-08  Kazu Hirata  <kazu@hxi.com>
819
820         * bfd-in.h: Fix formatting.
821         * bfd-in2.h: Likewise.
822         * bfd.c: Likewise.
823         * binary.c: Likewise.
824         * bout.c: Likewise.
825         * coff-a29k.c: Likewise.
826         * coff-alpha.c: Likewise.
827         * coff-apollo.c: Likewise.
828         * coff-aux.c: Likewise.
829
830 2000-11-07  Kazu Hirata  <kazu@hxi.com>
831
832         * aix386-core.c: Fix formatting.
833         * aoutf1.h: Likewise.
834         * aoutx.h: Likewise.
835         * archures.c: Likewise.
836         * armnetbsd.c: Likewise.
837
838 2000-11-07  Alan Modra  <alan@linuxcare.com.au>
839
840         * coff-h8300.c (special): Adjust reloc address.
841
842 2000-11-06  Steve Ellcey <sje@cup.hp.com>
843
844         * archures.c (bfd_mach_ia64_elf64, bfd_mach_ia64_elf32): Add defines
845         to differentiate elf32 and elf64 on ia64.
846         * bfd-in2.h: Regenerate.
847         * config.bfd: Add target for "ia64*-*-hpux*".
848         * configure.in: Add bfd_elf32_ia64_big_vec to selvecs switch.
849         * configure: Regenerate.
850         * cpu-ia64.c (bfd_ia64_elf32_arch): Add elf32 arch info structure.
851         * targets.c: Add bfd_target bfd_elf32_ia64_big_vec.
852
853         * Makefile.am: Make elf32-ia64.c and elf64-ia64.c derived objects
854         from elfxx-ia64.c.  Add depenency rules for making elf32-ia64.lo.
855         * Makefile.in: Regnerate.
856         * elf64-ia64.c: Deleted.
857         * elfxx-ia64.c: New file, paramaterized version of elf64-ia64.c.
858
859 2000-11-06  Kazu Hirata  <kazu@hxi.com>
860
861         * aout-adobe.c: Fix formatting.
862         * aout-arm.c: Likewise.
863         * aout-cris.c: Likewise.
864         * aout-encap.c: Likewise.
865         * aout-ns32k.c: Likewise.
866         * aout-target.h: Likewise.
867         * aout-tic30.c: Likewise.
868
869 2000-11-05  Philip Blundell  <philb@gnu.org>
870
871         * elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit
872         BFDs containing no sections to be merged, regardless of their flags.
873
874 2000-11-04  Philip Blundell  <philb@gnu.org>
875
876         * elf32-arm.h (elf32_arm_relocate_section): Suppress error message
877         if a relocation for an undefined symbol also results in an
878         overflow.
879
880 2000-11-06  Christopher Faylor <cgf@cygnus.com>
881
882         * config.bfd: Add support for Sun Chorus.
883
884 2000-11-05  David O'Brien  <obrien@FreeBSD.org>
885
886         * configure.in: Recognize alpha-*-freebsd*.
887         * configure: Regenerate.
888
889 2000-11-02  Luciano Gemme <ishitawa@yahoo.com>
890
891         * srec.c (CHUNK): Rename to DEFAULT_CHUNK.
892         (Chunk): New global variable set by a parameter in objcopy.c.
893         (S3Forced): New global variable set by a parameter in
894         objcopy.c.
895         (srec_set_section_contents): If S3Forced is true, always generate
896         S3 records.
897         (srec_write_section): Use 'Chunk' to limit maximum length of S
898         records.
899
900 2000-11-02  Per Lundberg  <plundis@chaosdev.org>
901
902         * config.bfd: Add support for i[3456]86-chaosdev-storm-chaos.
903         * Makefile.in: Regenerate.
904         * bfd-in2.h: Regenerate.
905         * po/bfd.pot: Regenerate.
906
907 2000-10-31  Philip Blundell  <philb@gnu.org>
908
909         * elf32-arm.h (elf32_arm_merge_private_bfd_data): Only handle
910         EF_SOFT_FLOAT if it is defined.
911
912 2000-10-27  Philip Blundell  <philb@gnu.org>
913
914         * elf32-arm.h (elf32_arm_copy_private_bfd_data): Don't refuse
915         attempts to mix PIC code with non-PIC, just mark the output as
916         being position dependent.
917         (elf32_arm_merge_private_bfd_data): Likewise.  Print an error
918         message for EF_SOFT_FLOAT mismatches.  Display diagnostics for
919         all mismatches, not just the first one.
920
921 2000-10-25  Chris Demetriou  <cgd@sibyte.com>
922
923         * ieee.c (ieee_archive_p): Plug one of many possible
924         memory leaks in error handling.
925
926 2000-10-20  Jakub Jelinek  <jakub@redhat.com>
927
928         * elf32-sparc.c (elf32_sparc_merge_private_bfd_data,
929         elf32_sparc_object_p, elf32_sparc_final_write_processing):
930         Support v8plusb.
931         * elf64-sparc.c (sparc64_elf_merge_private_bfd_data,
932         sparc64_elf_object_p): Support v9b.
933         * archures.c: Declare v8plusb and v9b machines.
934         * bfd-in2.h: Ditto.
935         * cpu-sparc.c: Ditto.
936
937 2000-10-16  Geoffrey Keating  <geoffk@shoggoth.cygnus.com>
938
939         * elf64-sparc.c (sparc64_elf_relocate_section): Clear the location
940         of a GOT reloc.
941
942         * elf32-ppc.c (SYMBOL_REFERENCES_LOCAL): New macro.
943         (SYMBOL_CALLS_LOCAL): New macro.
944         (ppc_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
945         (ppc_elf_check_relocs): Use SYMBOL_REFERENCES_LOCAL.
946         (ppc_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
947         (ppc_elf_relocate_section): Use flag variable to determine
948         whether the relocation refers to a local symbol.
949         Test whether a PLTREL24 reloc will produce a reloc by looking
950         to see whether a PLT entry was made.
951
952 2000-10-14  Geoffrey Keating  <geoffk@shoggoth.cygnus.com>
953
954         * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Don't make PLT
955         entries that could serve as a definition for a weak symbol.
956
957 2000-10-13  Ulf Carlsson  <ulfc@engr.sgi.com>
958
959         From  Ralf Baechle  <ralf@gnu.org>
960
961         * elf32-mips.c (mips_elf_create_dynamic_relocation): New argument
962         local_p.  Add symbol value only for non-R_MIPS_REL32 relocations
963         against local symbols.
964         (_bfd_mips_elf_finish_dynamic_sections): Undo patch from 2000-10-01.
965
966 2000-10-12  Alan Modra  <alan@linuxcare.com.au>
967
968         * section.c (struct sec): Add kept_section.
969         (struct bfd_comdat_info): Remove sec, we can use above.
970         (STD_SECTION): Add initializer.
971         (bfd_make_section_anyway): Init here too.
972
973         * bfd-in2.h: Regenerate.
974
975         * elflink.h (elf_link_add_object_symbols): Remove unnecessary
976         zeroing of `flags'.
977         (elf_link_input_bfd): Set all asection->symbol->value's here, and
978         fudge values for discarded link-once section symbols.
979
980         * elf64-hppa.c: Include alloca-conf.h
981
982 2000-10-11  Alan Modra  <alan@linuxcare.com.au>
983
984         * elf.c (swap_out_syms): Revert 2000-10-07 changes.
985
986         * ieee.c (ieee_make_empty_symbol): Oops, bfd_zalloc needs another arg.
987
988 2000-10-10  Alan Modra  <alan@linuxcare.com.au>
989
990         * ieee.c (ieee_make_empty_symbol): Use bfd_zalloc, not bfd_zmalloc.
991
992 2000-10-10  Tom Rix <trix@redhat.com>
993
994         * section.c (bfd_make_section_anyway): Release newsect ptr when
995         newsect->symbol fails to alloc.  Use bfd_release instead of free.
996
997 2000-10-09  Richard Henderson  <rth@cygnus.com
998
999         * elf64-ia64.c (elf64_ia64_unwind_entry_compare_bfd): New.
1000         (elf64_ia64_unwind_entry_compare): New.
1001         (elf64_ia64_final_link): Sort the .IA_64.unwind section.
1002
1003 2000-10-07  Alan Modra  <alan@linuxcare.com.au>
1004
1005         * elflink.h (size_dynamic_sections): Don't create various tags if
1006         .dynstr is excluded from the link.  Don't set first dynsym entry
1007         if dynsymcount is zero.
1008         (elf_bfd_final_link): Don't try to swap out dynamic syms if
1009         .dynsym excluded from the link.  Don't try to write any dynamic
1010         sections excluded from the link.
1011
1012         * elf.c (swap_out_syms): Handle global section symbols.
1013
1014 2000-10-05  DJ Delorie  <dj@redhat.com>
1015
1016         * peigen.c (_bfd_pei_swap_scnhdr_out): note extended relocs
1017         * coffcode.h (coff_set_alignment_hook): read extended reloc count
1018         (coff_write_relocs): write extended reloc count
1019         (coff_write_object_contents): account for extended relocs
1020
1021 2000-10-05  Jim Wilson  <wilson@cygnus.com>
1022
1023         * elf-bfd.h (struct elf_backend_data): Add elf_backend_section_flags
1024         field.
1025         * elf.c (_bfd_elf_make_section_from_shdr): Call the
1026         elf_backend_section_flags function.
1027         * elf64-ia64.c (elf64_ia64_section_from_shdr): Delete flag conversion
1028         code.
1029         (elf64_ia64_section_flags): New function containing flag conversion
1030         code.
1031         (elf_backend_section_flags): Define to elf64_ia64_section_flags.
1032         * elfxx-target.h (elf_backend_section_flags): Define.
1033         (elfNN_bed): Initialize elf_backend_section_flags field.
1034
1035 2000-10-02  Alan Modra  <alan@linuxcare.com.au>
1036
1037         * elf32-hppa.c (elf32_hppa_check_relocs): Correct call to
1038         _bfd_elf32_gc_record_vtable.  Correct a comment.
1039
1040 2000-10-01  Ulf Carlsson  <ulfc@engr.sgi.com>
1041
1042         From  Ralf Baechle  <ralf@gnu.org>
1043
1044         * elf32-mips.c (_bfd_mips_elf_finish_dynamic_sections): Mark gld
1045         produces binaries with got[1] = 0x80000001 to differenciate them
1046         for the dynamic linker from the broken binaries produced by old
1047         versions.
1048
1049 2000-09-30  Petr Sorfa <petrs@sco.com>
1050
1051         * elf.c (elfcore_grok_pstatus): Check for size of pxstatus_t.
1052         (elfcore_grok_lwpstatus): Check for size of lwpxstatus_t.
1053         * configure.in: Add check for pxstatus_t and lwpxstatus_t.
1054         * configure: Regenerate.
1055
1056 2000-09-27  Hans-Peter Nilsson  <hp@axis.com>
1057
1058         Define two bfd_targets for absence and presence of leading
1059         underscore on symbols.  Make sure to only link same kind.
1060         * elf32-cris.c (cris_elf_object_p,
1061         cris_elf_final_write_processing, cris_elf_print_private_bfd_data,
1062         cris_elf_merge_private_bfd_data): New.
1063         (elf_backend_object_p, elf_backend_final_write_processing,
1064         bfd_elf32_bfd_print_private_bfd_data,
1065         bfd_elf32_bfd_merge_private_bfd_data): Define.
1066         <Target vector definition>: Include elf32-target.h twice with
1067         different macro settings:
1068         (TARGET_LITTLE_SYM): First as bfd_elf32_cris_vec, then as
1069         bfd_elf32_us_cris_vec.
1070         (TARGET_LITTLE_NAME): First as "elf32-cris", then "elf32-us-cris".
1071         (elf_symbol_leading_char): First as 0, then '_'.
1072         (INCLUDED_TARGET_FILE): Define for second include of elf32-target.h.
1073         * config.bfd (cris-*-*): Add bfd_elf32_us_cris_vec to targ_selvecs.
1074         * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vector.
1075         * configure: Regenerate.
1076         * targets.c: Declare bfd_elf32_us_cris_vec.
1077         * po/bfd.pot: Regenerate.
1078
1079 2000-09-29  Momchil Velikov  <velco@fadata.bg>
1080
1081         * elf32-arm.h (arm_add_to_rel): Correctly adjust the addend for
1082         R_ARM_THM_PC22 relocations.
1083
1084 2000-09-29  NIIBE Yutaka <gniibe@chroot.org>
1085
1086         * elflink.h (elf_link_add_object_symbols): Don't bfd_release runpath.
1087
1088 2000-09-29  Momchil Velikov <velco@fadata.bg>
1089
1090         * elf.c (elf_fake_sections): Do not mark the section SHT_NOBITS if
1091         is has the SEC_HAS_CONTENTS flag set.
1092
1093 2000-09-28  Ã–rjan Friberg  <orjanf@axis.com>
1094             Hans-Peter Nilsson  <hp@axis.com>
1095
1096         * aout-cris.c (N_TXTADDR): Define.
1097
1098 2000-09-28  John David Anglin <dave@hiauly1.hia.nrc.ca>
1099
1100         * som.c: Include alloca-conf.h.
1101         * Makefile.am: "make dep-am"
1102         * Makefile.in: Regenerate.
1103
1104 2000-09-27  Alan Modra  <alan@linuxcare.com.au>
1105
1106         * elf32-hppa.c (plt_stub): New.
1107         (PLT_STUB_ENTRY): Define.
1108         (elf32_hppa_link_hash_table): Change multi_subspace to packed
1109         boolean.  Add need_plt_stub, has_12bit_branch and has_17bit_branch.
1110         (elf32_hppa_link_hash_table_create): Init to suit.
1111         (elf32_hppa_check_relocs): Set has_12bit_branch and
1112         has_17bit_branch as appropriate.
1113         (elf32_hppa_adjust_dynamic_symbol): Set need_plt_stub for
1114         non-local functions.
1115         (elf32_hppa_size_dynamic_sections): Correct setting of reltext.
1116         Add space for plt_stub as needed.
1117         (elf32_hppa_finish_dynamic_symbol): Point .plt entries for global
1118         functions at plt_stub.
1119         (elf32_hppa_finish_dynamic_sections): Write plt_stub.
1120         (elf32_hppa_create_dynamic_sections): Leave .plt executable.
1121
1122         * elf32-hppa.h (elf32_hppa_size_stubs): Add group_size param.
1123         * elf32-hppa.c (elf32_hppa_size_stubs): Likewise.  Use it instead
1124         of fixed size, and if negative, disable handling of input sections
1125         before stub section.  Set up default stub group size depending
1126         on detected branch relocs.
1127         (hppa_build_one_stub): Use lrsel and rrsel for import stubs to
1128         ensure different offsets from sym_value aren't rounded to
1129         different 2k blocks.  Use lrsel and rrsel for other stubs too for
1130         consistency rather than necessity.
1131         (elf32_hppa_check_relocs): Handle R_PARISC_DIR14F.
1132         (final_link_relocate): Likewise.
1133         (elf32_hppa_relocate_section): Likewise.
1134
1135         * elf-hppa.h (elf_hppa_howto_table): Add R_PARISC_DIR14F reloc.
1136         (_bfd_elf_hppa_gen_reloc_type): Generate them.
1137         (elf_hppa_final_link_relocate): Handle them.
1138         (elf_hppa_relocate_insn): Likewise.
1139         (_bfd_elf_hppa_gen_reloc_type): Add missing e_ldsel and e_rdsel cases.
1140
1141 2000-09-26  Hans-Peter Nilsson  <hp@axis.com>
1142
1143         * elfcode.h (elf_object_p): Preserve and clear abfd section
1144         information.  Restore at error.
1145
1146 2000-09-26  Paul Sokolovsky  <Paul.Sokolovsky@technologist.com>
1147
1148         * peigen.c (_bfd_pei_swap_aouthdr_in): If some DataDirectory
1149         is empty, make sure that its rva also 0. NT loader dislikes
1150         having otherwise.
1151
1152 2000-09-26  Steve Ellcey <sje@cup.hp.com>
1153
1154         * som.c (som_bfd_derive_misc_symbol_info): Make weak symbols
1155         global by default.
1156
1157 2000-09-21  Alan Modra  <alan@linuxcare.com.au>
1158
1159         * elf32-hppa.c (elf32_hppa_check_relocs): Fix weak sym handling in
1160         currently unused RELATIVE_DYNAMIC_RELOCS code.
1161         (hppa_discard_copies): Likewise.
1162         (elf32_hppa_size_stubs): Size `input_list' array correctly.  Correct
1163         comments.  Don't check non-code output sections for stub grouping.
1164
1165 2000-09-20  Alan Modra  <alan@linuxcare.com.au>
1166
1167         * section.c (bfd_get_unique_section_name): Return NULL if
1168         bfd_malloc fails.
1169
1170 2000-09-19  Michael Sokolov  <msokolov@ivan.Harhan.ORG>
1171
1172         * elf32-m68k.c (elf_cpu32_plt0_entry): Change the PLT entry 0
1173         instruction sequence to actually work.
1174         (elf_m68k_finish_dynamic_sections): Change the patch-in offset
1175         accordingly.
1176
1177 2000-09-18  Alexandre Oliva  <aoliva@redhat.com>
1178
1179         * elf32-sh.c (sh_elf_relocate_section): Use
1180         _bfd_final_link_relocate to apply the relocation against a section
1181         symbol, when doing relocatable links.
1182
1183 2000-09-18  Alan Modra  <alan@linuxcare.com.au>
1184
1185         * elf32-hppa.c (elf32_hppa_stub_hash_entry): Rename input_section
1186         to id_sec.
1187         (stub_hash_newfunc): Here too.
1188         (hppa_add_stub): And here.
1189         (elf32_hppa_link_hash_table): Remove stub_section_created,
1190         reloc_section_created, first_init_sec and first_fini_sec.  Add
1191         stub_group.
1192         (elf32_hppa_link_hash_table_create): Init to suit.
1193         (hppa_get_stub_entry): Add support for grouping stub sections.
1194         (hppa_add_stub): Likewise.  Remove sec_count param and init/fini
1195         section code.  Index stub vars by section->id.
1196         (elf32_hppa_size_stubs): Likewise.  Remove duplicated function
1197         exit paths.  Zap allocation of above removed vars.  Refine
1198         link-once test.
1199
1200         * elf32-hppa.h (elf32_hppa_size_stubs): Add output_bfd param.
1201         * elf32-hppa.c (elf32_hppa_size_stubs): Likewise.
1202         (hppa_get_stub_entry): Pass in pointer to elf32_hppa_link_hash_table
1203         rather than pointer to bfd_link_info.
1204         (hppa_add_stub): Likewise.
1205         (final_link_relocate): Likewise.
1206
1207 2000-09-17  David Huggins-Daines  <dhd@linuxcare.com>
1208
1209         (elf32_hppa_size_stubs): Don't try to build stubs for discarded
1210         link-once sections.
1211
1212 2000-09-16  Alexandre Oliva  <aoliva@redhat.com>
1213
1214         * elf32-sh.c (ELF_MAXPAGESIZE): Define to 128, to match
1215         ld/emulparams/shelf.sh.
1216
1217 2000-09-10  Michael Sokolov  <msokolov@ivan.Harhan.ORG>
1218
1219         * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): New function.
1220         * bfd-in.h (bfd_m68k_elf32_create_embedded_relocs): Add declaration.
1221         * bfd-in2.h: Regenerate.
1222
1223 2000-09-15  Kenneth Block  <Kenneth.Block@compaq.com>
1224
1225         * bfd/elf64-alpha.c (elf64_alpha_relax_with_lituse): ld performs
1226         LITUSE relocations incorrectly if -relax is specified on the ld
1227         command line and the displacement field of the load or store
1228         instruction is non-zero. (Patch by paul.winalski@compaq.com)
1229
1230 2000-09-15  Alan Modra  <alan@linuxcare.com.au>
1231
1232         * elf32-hppa.c (hppa_add_stub): Dont set first_init_sec and
1233         first_fini_sec here.
1234         (elf32_hppa_size_stubs): Instead correctly find the first .init
1235         and .fini section here.
1236
1237 2000-09-15  David Huggins-Daines  <dhd@linuxcare.com>
1238
1239         * elf32-hppa.c (clobber_millicode_symbols): New function.
1240         (elf32_hppa_size_dynamic_sections): Call it.
1241
1242 2000-09-14  Alan Modra  <alan@linuxcare.com.au>
1243
1244         * elf32-hppa.c (elf32_hppa_link_hash_entry): Make pic_call
1245         packed.  Add plabel, plt_abs packed booleans.
1246         (hppa_link_hash_newfunc): Init new fields.
1247         (PLABEL_PLT_ENTRY_SIZE): Define.
1248         (hppa_stub_name): Use size_t len vars.
1249         (hppa_add_stub): Likewise.
1250         (elf32_hppa_build_stubs): Likewise.
1251         (hppa_build_one_stub): Kill some compiler warnings.
1252         (elf32_hppa_check_relocs): Always generate a plt entry for PLABELs
1253         if dynamic linking.  Munge the local plt offsets into
1254         local_got_refcounts.  Set h->plabel for all global PLABELs.  Use
1255         size_t len vars.  Add assert for plabel addend.
1256         (elf32_hppa_gc_sweep_hook): Sweep local plt entries too.
1257         (elf32_hppa_hide_symbol): New function.
1258         (elf_backend_hide_symbol): Define.
1259         (elf32_hppa_adjust_dynamic_symbol): Don't throw away plt entries
1260         with h->plabel set.  Don't make plt entries to have dynamic syms
1261         when they have been forced local.  If plt entry is used by a
1262         plabel, make it PLABEL_PLT_ENTRY_SIZE.
1263         (elf32_hppa_size_dynamic_sections): Set plt_abs for init fns.
1264         Set up .plt offsets for local syms.
1265         (elf32_hppa_relocate_section): Initialise plt entries for local
1266         syms.  Leave weak undefined plabels zero.  Make global plabel
1267         relocs against function symbol, and leave the addend zero.
1268         Use *ABS* DIR32 relocs instead of SEGREL32 for dynamic got relocs.
1269         (elf32_hppa_finish_dynamic_symbol): Set up IPLT relocs for
1270         non-dynamic syms.  Init extra plt for plabels.  Use *ABS* DIR32
1271         relocs instead of SEGREL32 for dynamic got relocs.
1272         (elf32_hppa_finish_dynamic_sections): Reserve one more .got entry.
1273         (elf_backend_got_header_size): Adjust.
1274         (elf32_hppa_set_gp): Calculate an "ideal" LTP.
1275
1276         * elf32-hppa.c (LONG_BRANCH_VIA_PLT): Define.
1277         (hppa_type_of_stub): Use it instead of #if 0
1278         (hppa_discard_copies): Use it here too.
1279         (elf32_hppa_size_dynamic_sections): And here.
1280
1281         * elf32-hppa.c (elf32_hppa_link_hash_table): Remove `offset' field.
1282         (elf32_hppa_link_hash_table_create): And here.
1283         (hppa_build_one_stub): And here.  Instead keep track of stub
1284         offset using _raw_size.
1285         (elf32_hppa_size_stubs): Likewise.
1286         (elf32_hppa_build_stubs): Likewise.
1287         (hppa_size_one_stub): Likewise.  Resize reloc section too.
1288
1289         * elf32-hppa.c (hppa_add_stub): Correct first_init_sec and
1290         first_fini_sec handling.  Don't search for reloc section or set
1291         hplink->reloc_section_created here.
1292         (elf32_hppa_size_stubs): Instead search for reloc sections, and
1293         set reloc_section_created here.
1294         (hppa_handle_PIC_calls): Set ELF_LINK_HASH_NEEDS_PLT.
1295         (elf32_hppa_size_dynamic_sections): Make a .plt entry for DT_INIT
1296         and DT_FINI.
1297         (elf32_hppa_finish_dynamic_sections): Set DT_INIT and DT_FINI.
1298
1299         * elf32-hppa.c (hppa_build_one_stub): Replace `elf_hash_table (info)'
1300         with `hplink->root.'.
1301         (elf32_hppa_check_relocs): Likewise.
1302         (elf32_hppa_gc_sweep_hook): Likewise.
1303         (elf32_hppa_adjust_dynamic_symbol): Likewise.
1304         (hppa_handle_PIC_calls): Likewise.
1305         (elf32_hppa_size_dynamic_sections): Likewise.
1306         (elf32_hppa_set_gp): Likewise.
1307         (elf32_hppa_relocate_section): Likewise.
1308         (elf32_hppa_finish_dynamic_symbol): Likewise.
1309         (elf32_hppa_finish_dynamic_sections): Likewise.
1310
1311         From  David Huggins-Daines  <dhd@linuxcare.com>
1312         * elf32-hppa.c (hppa_type_of_stub): Generate import stubs for
1313         defined weak symbols in shared links.
1314         (final_link_relocate): Calls to defined weak symbols in shared
1315         objects must go via import stubs, as the target might not be known
1316         at link time.
1317
1318 2000-09-14  Alexandre Oliva  <aoliva@redhat.com>
1319
1320         * elf32-sh.c (sh_elf_howto_table): Moved R_SH_GOT32, R_SH_PLT32,
1321         R_SH_COPY, R_SH_GLOB_DAT, R_SH_JMP_SLOT, R_SH_RELATIVE,
1322         R_SH_GOTOFF, R_SH_GOTPC) to the range from 160 to 167.  Replaced
1323         the original entries with EMPTY_HOWTOs, and added new ones to fill
1324         in the gap.
1325         (sh_elf_info_to_howto): Make sure the new gap isn't used.
1326         (sh_elf_relocate_section): Likewise.
1327
1328 2000-09-13  Anders Norlander  <anorland@acc.umu.se>
1329
1330         * cpu-mips.c (arch_info_struct): Add mips:4K
1331         * bfd-in2.h (bfd_mach_mips4K): New define.
1332         * archures.c: Add bfd_mach_mips4K to comment.
1333         * elf32-mips.c (_bfd_mips_elf_final_write_processing): Return
1334         E_MIPS_ARCH_2 for bfd_mach_mips4K.
1335
1336 2000-09-13  Marco Franzen <marcof@thyron.com>
1337
1338         * som.c (som_write_symbol_strings): Do not used fixed buffers,
1339         use size_t as a counter.
1340         (som_write_space_strings): Similarly.
1341
1342 2000-09-12  Jason Eckhardt  <jle@cygnus.com>
1343
1344         * elf32-i860.c (elf32_i860_relocate_pc26): New function
1345         and prototype.
1346         (elf32_i860_relocate_section): Invoke new function from here.
1347
1348 2000-09-11  Michael Sokolov  <msokolov@ivan.Harhan.ORG>
1349
1350         * elf.c (_bfd_elf_make_section_from_shdr): Make debug_sec_names
1351         static.
1352
1353 2000-09-10  Michael Sokolov  <msokolov@ivan.Harhan.ORG>
1354
1355         * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): Emit 8 NULs for
1356         target section name instead of dumping core when the target symbol is
1357         undefined.
1358
1359 2000-09-09  Kazu Hirata  <kazu@hxi.com>
1360
1361         * riscix.c: Remove DEFUN.
1362
1363 2000-09-08  Nick Clifton  <nickc@redhat.com>
1364
1365         * elf32-arm.h (elf32_arm_merge_private_bfd_data): Do not
1366         initialise flags in output bfd if the input bfd is the default
1367         architecture with the default flags.
1368
1369 2000-09-08  Kazu Hirata  <kazu@hxi.com>
1370
1371         * archive.c: Fix formatting.
1372         * coff-arm.c: Likewise.
1373         * doc/chew.c: Likewise.
1374
1375 2000-09-08  Alan Modra  <alan@linuxcare.com.au>
1376
1377         * section.c (bfd_get_unique_section_name): Put a dot before the
1378         numeric suffix.
1379
1380 2000-09-07  Kazu Hirata  <kazu@hxi.com>
1381
1382         * doc/chew.c: Remove all uses of DEFUN and DEFUN_VOID.
1383         * elf.c: Fix formatting.
1384
1385 2000-09-07  Alexandre Oliva  <aoliva@redhat.com>
1386
1387         * config.bfd (sh-*-linux*): Added.
1388         * configure.in (bfd_elf32_shlin_vec, bfd_elf32_shblin_vec): New.
1389         * targets.c: Declare them.
1390         * elf32-sh-lin.c: New file.
1391         * Makefile.am: Compile it.
1392         * elf32-sh.c: Don't override defines from elf32-sh-lin.c.
1393         * configure, Makefile.in: Rebuilt.
1394
1395 2000-09-06  Geoffrey Keating  <geoffk@cygnus.com>
1396
1397         * xcofflink.c (xcoff_link_input_bfd): Include the .tocbss
1398         pseduo-section when determining where the TOC ends.
1399
1400         * coff-rs6000.c (_bfd_xcoff_swap_aux_out): Use bfd_h_put_16 to
1401         output x_tvndx as it is only two bytes wide.
1402
1403         * coff-rs6000.c (xcoff_howto_table): A modifiable branch-absolute
1404         reloc is 26 or 32 bits wide.
1405
1406         * coff-rs6000.c (_bfd_xcoff_rtype2howto): The bitsize is irrelevant
1407         for relocs that don't change anything.  Also look at the full
1408         6 bits of bitsize.
1409
1410 2000-09-06  Philip Blundell  <philb@gnu.org>
1411
1412         * config.bfd (arm*-*-uclinux*): New target.
1413
1414 2000-09-06  Alexandre Oliva  <aoliva@redhat.com>
1415
1416         * configure: Rebuilt with new libtool.m4.
1417
1418 2000-09-06  Alan Modra  <alan@linuxcare.com.au>
1419
1420         * section.c (bfd_get_unique_section_name): Avoid c++ reserved
1421         word for variable name.
1422         * bfd-in2.h: Regenerate.
1423
1424 2000-09-05  Nick Clifton  <nickc@redhat.com>
1425
1426         * config.in: Regenerate.
1427         * libbfd.h: Regenerate.
1428         * po/bfd.pot: Regenerate.
1429         * doc/bfdint.texi: Remove CVS date string - it foils compares with
1430         local versions.
1431
1432 2000-09-05  Steven Johnson  <sbjohnson@ozemail.com.au>
1433
1434         * cpu-powerpc.c  (arch_info_struct): Added MPC860 Family entry.
1435
1436 2000-09-05  Alan Modra  <alan@linuxcare.com.au>
1437
1438         Shared library and PIC support.
1439         * elf32-hppa.c (PLT_ENTRY_SIZE): New.
1440         (GOT_ENTRY_SIZE): New.
1441         (ELF_DYNAMIC_INTERPRETER): New.
1442         (STUB_SUFFIX): Define.
1443         (LONG_BRANCH_PIC_IN_SHLIB): Define.
1444         (RELATIVE_DYNAMIC_RELOCS): Define.
1445         (enum elf32_hppa_stub_type): New.
1446         (struct elf32_hppa_stub_hash_entry): Rename offset to
1447         stub_offset.  Add a number of new fields.
1448         (struct elf32_hppa_link_hash_entry): New.
1449         (struct elf32_hppa_link_hash_table): Add numerous fields.  Remove
1450         global_value.
1451         (elf32_hppa_hash_table): Rename to hppa_link_hash_table.
1452         (elf32_hppa_stub_hash_lookup): Rename to hppa_stub_hash_lookup.
1453         (elf32_hppa_stub_hash_newfunc): Rename to stub_hash_newfunc.  Init
1454         new fields.
1455         (hppa_link_hash_newfunc): New function.
1456         (elf32_hppa_link_hash_table_create): Use above function. Init new
1457         fields.
1458         (elf32_hppa_stub_name): Rename to hppa_stub_name.  Pass in reloc
1459         instead of addend, and remove sym_name from args.  Don't use
1460         symbol name for local syms, instead use sym index.
1461         (elf32_hppa_size_of_stub): Rename to hppa_type_of_stub, and return
1462         stub type rather than size.  Pass in hash and handle import stub
1463         case.  Also pass in reloc instead of offset so we can calculate
1464         PCREL22F and PCREL12F branches properly.
1465         (elf32_hppa_build_one_stub): Rename to hppa_build_one_stub.  Build
1466         import and export stubs too.
1467         (elf32_hppa_size_one_stub): Rename to hppa_size_one_stub.  Handle
1468         import and export stub sizing.
1469         (elf32_hppa_check_relocs): New function.
1470         (elf32_hppa_adjust_dynamic_symbol): New function.
1471         (hppa_discard_copies): New function.
1472         (elf32_hppa_size_dynamic_sections): New function.
1473         (elf_backend_size_dynamic_sections): Define.
1474         (elf32_hppa_finish_dynamic_symbol): New function.
1475         (elf_backend_finish_dynamic_symbol): Define.
1476         (elf32_hppa_size_stubs): Stash params in link hash table, and move
1477         some local vars into the link hash table too.  For shared links,
1478         trundle over function syms, generating export stubs.  Handle
1479         PCREL22F branches.  Break out stub creation code from here..
1480         (hppa_add_stub): .. to here.  New function.
1481         (elf32_hppa_final_link): Rename to elf32_hppa_set_gp, and don't
1482         call the bfd linker.  Use elf_gp to record global pointer.
1483         Calculate a value from sections if $global$ is missing.
1484         (bfd_elf32_bfd_final_link): Define as _bfd_elf32_gc_common_final_link.
1485         (elf32_hppa_gc_mark_hook): New function.
1486         (elf_backend_gc_mark_hook): Define.
1487         (elf32_hppa_gc_sweep_hook): New function.
1488         (elf_backend_gc_sweep_hook): Define.
1489         (elf32_hppa_bfd_final_link_relocate): Rename to final_link_relocate.
1490         Add rel to args, and remove howto, input_bfd, offset, addend,
1491         sym_name as we can recalculate these locally.  Handle calls to
1492         dynamic objects, extra PIC relocs, PCREL22F branches.  Change
1493         handling of undefined weak syms.  Check that stubs are in range.
1494         Only look for import stubs on PCREL17F and PCREL22F relocs.  Add
1495         message on hitting a DPREL21L reloc that needs fixing.  Subtract
1496         off PC for PCREL14F.  Break out code that does a stub lookup from
1497         here..
1498         (hppa_get_stub_entry): ..to here.  New function.
1499         (elf32_hppa_relocate_insn): Merge into final_link_relocate.
1500         (elf32_hppa_relocate_section): Handle got and plt relocs, dynamic
1501         relocs, etc. etc.
1502         (elf32_hppa_finish_dynamic_sections): New function.
1503         (elf_backend_finish_dynamic_sections): Define.
1504         (elf_backend_final_write_processing) Define.
1505         (hppa_handle_PIC_calls): New function.
1506         (elf32_hppa_build_stubs): Call it.  Pass link_info to
1507         hppa_build_one_stub.
1508         (elf32_hppa_create_dynamic_sections): New function
1509         to create .plt and .got then set .plt flags correctly.
1510         (elf_backend_create_dynamic_sections): Define.
1511         (elf32_hppa_object_p): New function.
1512         (elf_backend_object_p): Define.
1513         (elf32_hppa_elf_get_symbol_type): New function.
1514         (elf_backend_get_symbol_type): Define.
1515         (elf_backend_can_gc_sections): Define.
1516         (elf_backend_want_got_plt): Define.
1517         (elf_backend_plt_alignment): Set to 2.
1518         (elf_backend_plt_readonly): Define.
1519         (elf_backend_want_plt_sym): Define.
1520         (elf_backend_got_header_size): Reserve one entry.
1521
1522         * elf32-hppa.h (elf32_hppa_build_stubs): Don't pass stub bfd.
1523         (elf32_hppa_size_stubs): Pass in multi_subspace.
1524         (elf32_hppa_set_gp): Declare.
1525
1526         * section.c (SEC_HAS_GOT_REF): Define new flag for asection.
1527         (bfd_get_unique_section_name): New function.
1528         * bfd_in2.h: Regenerate.
1529
1530         * elf64-hppa.c (elf64_hppa_check_relocs): Handle R_PARISC_PCREL12F.
1531         (elf64_hppa_size_dynamic_sections): Remove the FIXME at bfd_zalloc
1532         comment.
1533
1534         From  David Huggins-Daines  <dhd@linuxcare.com>
1535         * elf64-hppa.c (elf64_hppa_check_relocs): Fix a warning.
1536         (elf64_hppa_mark_exported_functions): Set dyn_h->st_shndx.
1537         (elf64_hppa_link_output_symbol_hook): Test dyn_h->st_shndx has
1538         been updated in finish_dynamic_symbol before modifying function
1539         symbol.
1540
1541         * elf-hppa.h (elf_hppa_howto_table): Restructure into groups of
1542         eight entries.  Replace NULL with bfd_elf_generic_reloc.  Add
1543         R_PARISC_GNU_VTENTRY, R_PARISC_GNU_VTINHERIT and R_PARISC_PCREL12F.
1544         (_bfd_elf_hppa_gen_reloc_type): Handle R_PARISC_GNU_VT*.  Add some
1545         comments.  Handle format == 12 for R_HPPA_PCREL_CALL.
1546         (elf_hppa_final_link_relocate): Handle R_PARISC_PCREL12F.
1547         (elf_hppa_relocate_insn): Likewise.  Reformat some comments.
1548         (elf_hppa_final_write_processing): Expose it for ARCH_SIZE == 32.
1549
1550         From David Huggins-Daines  <dhd@linuxcare.com>
1551         * elf-hppa.h (elf_hppa_is_local_label_name): Accept the SysV/ELF
1552         style of local labels as well.
1553
1554 2000-09-03  Philip Blundell  <philb@gnu.org>
1555
1556         * elf32-arm.h (elf32_arm_relocate_section): Don't try to relocate
1557         references to undefined symbols in debugging sections.
1558
1559 2000-09-02  H.J. Lu  <hjl@gnu.org>
1560
1561         * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
1562         BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE,
1563         BFD_RELOC_SH_GOTPC): Move them from the MIPS section to the SH
1564         section.
1565
1566 2000-09-02  Jason Eckhardt  <jle@cygnus.com>
1567
1568         * elf32-i860.c (bfd_elf32_bfd_is_local_label_name): Define macro.
1569         (elf32_i860_is_local_label_name): New function and prototype.
1570
1571 2000-09-02  Nick Clifton  <nickc@redhat.com>
1572
1573         * configure.in: Increase version number to 2.10.91.
1574         * configure: Regenerate.
1575         * aclocal.m4: Regenerate.
1576         * config.in: Regenerate.
1577         * po/bfd.pot: Regenerate.
1578
1579 2000-09-02  Daniel Berlin <dberlin@redhat.com>
1580
1581         * elf.c (_bfd_elf_make_section_from_shdr): Add
1582         .gnu.linkobce.wi. to the list of debug section names.
1583
1584 2000-09-02  Nick Clifton  <nickc@redhat.com>
1585
1586         * dwarf2.c (find_debug_info): New function: Locate a section
1587         containing dwarf2 debug information.
1588         (bfd_dwarf2_find_nearest_line): Find all sections containing
1589         debug information and include them in the stash.
1590
1591 2000-09-01  Niibe Yutaka  <gniibe@m17n.org>, Kaz Kojima  <kkojima@rr.iij4u.or.jp>, Alexandre Oliva  <aoliva@redhat.com>
1592
1593         * elf32-sh.c (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
1594         R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): New.
1595         (sh_reloc_map): Add new relocs.
1596         (sh_elf_check_relocs, sh_elf_link_hash_newfunc,
1597         sh_elf_link_hash_table_create, sh_elf_adjust_dynamic_symbol,
1598         sh_elf_size_dynamic_sections, sh_elf_finish_dynamic_symbol,
1599         sh_elf_finishe_dynamic_sections, sh_elf_discard_copies): New
1600         functions.
1601         (ELF_DYNAMIC_INTERPRETER, PLT_ENTRY_SIZE): Define.
1602         (elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
1603         elf_sh_plt_entry_be, elf_sh_plt_entry_le,
1604         elf_sh_pic_plt_entry_be, elf_sh_pic_plt_entry_le):
1605         New array constants.
1606         (elf_sh_plt0_entry, elf_sh_plt_entry, elf_sh_pic_plt_entry):
1607         New variables.
1608         (elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
1609         elf_sh_plt0_linker_offset, elf_sh_plt0_gotid_offset,
1610         elf_sh_plt_temp_offset, elf_sh_plt_symbol_offset,
1611         elf_sh_plt_reloc_offset): Define.
1612         (elf_sh_pcrel_relocs_copied, elf_sh_link_hash_entry,
1613         elf_sh_link_hash_table): New structs.
1614         (sh_elf_link_hash_traverse, sh_elf_hash_table): New macros.
1615         (sh_elf_relocate_section, sh_elf_check_relocs): Handle new
1616         relocation types.
1617         (elf_backend_create_dynamic_sections,
1618         bfd_elf32_bfd_link_hash_table_create,
1619         elf_backend_adjust_dynamic_symbol,
1620         elf_backend_size_dynamic_sections,
1621         elf_backend_finish_dynamic_symbol,
1622         elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
1623         elf_backend_plt_readonly, elf_backend_want_plt_sym,
1624         elf_backend_got_header_size, elf_backend_plt_header_size):
1625         Define.
1626         * reloc.c (BFD_RELOC_SH_COPY, BFD_RELOC_SH_GLOB_DAT,
1627         BFD_RELOC_SH_JMP_SLOT, BFD_RELOC_SH_RELATIVE, BFD_RELOC_SH_GOTPC):
1628         New relocs.
1629         * bfd-in2.h, libbfd.h: Rebuilt.
1630
1631 2000-09-01  Alan Modra  <alan@linuxcare.com.au>
1632
1633         * elf32-i386.c (elf_i386_finish_dynamic_symbol): Revert 2000-08-27
1634         change.
1635
1636 2000-08-31  J"orn Rennecke <amylaar@cygnus.co.uk>
1637
1638         * elf32-sh.c (sh_elf_merge_private_data): If ibfd's elf header flags
1639         not initialized, set them to indicate the SH1 instruction set.
1640
1641 2000-08-31  Alexandre Oliva  <aoliva@redhat.com>
1642
1643         * acinclude.m4: Include libtool and gettext macros from the
1644         top level.
1645         * aclocal.m4, configure: Rebuilt.
1646
1647 2000-08-29  Michael Snyder  <msnyder@seadog.cygnus.com>
1648
1649         * elf.c: Eliminate references to __sparcv9 macro; replace with
1650         autoconf variables HAVE_PSINFO32_T etc.
1651         * configure.in: Auto-configure HAVE_PSINFO_32_T, HAVE_PRPSINFO32_T,
1652         HAVE_PSTATUS32_T, HAVE_PRSTATUS32_T, HAVE_PRSTATUS32_T_PR_WHO.
1653         * config.in: Ditto.
1654         * acinclude.m4 (BFD_HAVE_SYS_PROCFS_TYPE) define _SYSCALL32 so it can
1655         detect the above typedefs.  (BFD_HAVE_SYS_PROCFS_TYPE_MEMBER): Ditto.
1656         * aclocal.m4: Ditto.
1657         * configure: Regenerate.
1658
1659 2000-08-27  Alan Modra  <alan@linuxcare.com.au>
1660
1661         * elf32-i386.c (elf_i386_check_relocs): Keep info on relocs copied
1662         for any shared link, not just shared -Bsymbolic.
1663         (elf_i386_size_dynamic_sections): Call elf_i386_discard_copies on
1664         any shared link, and pass link info to it.
1665         (elf_i386_size_dynamic_sections): Update comment.
1666         (elf_i386_discard_copies): Modify to discard relocs for symbols
1667         that have been forced local.
1668         (elf_i386_finish_dynamic_symbol): Don't copy relocs for symbols
1669         that have been forced local.
1670
1671 2000-08-24  Denis Chertykov  <denisc@overta.ru> & Nick Clifton  <nickc@redhat.com>
1672
1673         * elflink.h (elf_link_add_object_symbols): Allow common
1674         symbols to have an alignment of 1 if explicitly requested, and
1675         not overridden by other definitions.
1676
1677 2000-08-22  Doug Kwan <dkwan@transmeta.com>
1678
1679         * coff-w65.c (CREATE_LITTLE_COFF_TARGET): Fix typo.
1680         * coffcode.h (coff_set_flags): Add detection of w65 architecture.
1681
1682 2000-08-22  H.J. Lu  <hjl@gnu.org>
1683
1684         * elf-bfd.h (elf_link_hash_table): Add runpath.
1685
1686         * bfd-in.h (bfd_elf_get_runpath_list): New prototype.
1687         * bfd-in2.h: Rebuilt.
1688
1689         * elf.c (_bfd_elf_link_hash_table_init): Initialize the
1690         "runpath" field to NULL.
1691         (bfd_elf_get_runpath_list): New function.
1692
1693         * elflink.h (elf_link_add_object_symbols): Record DT_RPATH and
1694         DT_RUNPATH entries.
1695
1696 2000-08-22  Alexandre Oliva  <aoliva@redhat.com>
1697
1698         * elf32-sh.c (sh_elf_relocate_section) [R_SH_IND12W,
1699         R_SH_DIR8WPN, R_SH_DIR8WPZ, R_SH_DIR8WPL]: Handle them
1700         explicitly.  Improve validation of r_type.
1701
1702 2000-08-21  H.J. Lu  <hjl@gnu.org>
1703
1704         * elf32-i386.c (elf_i386_size_dynamic_sections): Zero out the
1705         dynamic allocated content space.  Add a comment to remind us that
1706         one day this ought to be fixed.
1707         * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
1708         * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
1709         * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
1710
1711 2000-08-21  Jason Eckhardt  <jle@cygnus.com>
1712
1713         * elf32-i860.c (elf32_i860_relocate_pc16): Just write the immediate
1714         field with the newly relocated value instead of adding it to the
1715         existing immediate field.
1716         (elf32_i860_relocate_splitn): Likewise.
1717         (elf32_i860_relocate_highadj): Likewise.
1718
1719 2000-08-16  Jason Eckhardt  <jle@cygnus.com>
1720
1721         * elf32-i860.c (elf32_i860_relocate_pc16): Implemented function (it
1722         was previously just a stub).
1723
1724 2000-08-16  Alexandre Oliva  <aoliva@redhat.com>
1725
1726         * elflink.c (_bfd_elf_create_got_section): Don't abort().
1727         Formatting fixes.
1728         (_bfd_elf_create_dynamic_sections): Likewise.
1729
1730 2000-08-16  Andrew Macleod  <amacleod@cygnus.com>
1731
1732         * elf64-sparc.c (sparc64_elf_relocate_section): Set relocation address
1733         for undefined symbols to be the beginning of the section.
1734
1735         * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Don't allocate
1736         four extra entries at the beginning of the .rela.plt section.
1737         (sparc64_elf_finish_dynamic_symbol): Adjust the offset in the .rela.plt
1738         section to account for the four reserved entries in the .plt section.
1739
1740 2000-08-15  Geoffrey Keating  <geoffk@cygnus.com>
1741
1742         * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Add ori r0,r0,0
1743         to the list of NOPs we recognize after a branch-and-link.
1744         Use the ori NOP when one is needed.
1745
1746         * coff-rs6000.c (_bfd_xcoff_slurp_armap): Finish implementation
1747         for large archives.
1748
1749 2000-08-14  Jim Wilson  <wilson@cygnus.com>
1750
1751         * elf64-ia64.c (elf64_ia64_merge_private_bfd_data): Handle
1752         EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, and EF_IA_64_NOFUNCDESC_CONS_GP.
1753         (elf64_ia64_print_private_bfd_data): Likewise.  Also handle
1754         EF_IA_64_ABSOLUTE.
1755
1756 2000-08-11  Alexandre Oliva  <aoliva@redhat.com>
1757
1758         * elf32-sh.c (sh_elf_set_mach_from_flags): Make it static.
1759
1760 2000-08-10  Jason Eckhardt  <jle@cygnus.com>
1761
1762         * elf32-i860.c (elf32_i860_relocate_section): New function.
1763         (i860_final_link_relocate): New function.
1764         (elf32_i860_relocate_splitn): New function.
1765         (elf32_i860_relocate_pc16): New function.
1766         (elf32_i860_relocate_highadj): New function.
1767         (elf32_i860_howto): Minor adjustments to some relocations.
1768         (elf_info_to_howto_rel): Define.
1769         (elf_backend_relocate_section): Define.
1770
1771 2000-08-10  Nick Clifton  <nickc@cygnus.com>
1772
1773         * elf32-arm.h: Fix formatting.
1774
1775 2000-08-10  Bernd Schmidt  <bernds@cygnus.co.uk>
1776
1777         * elf32-sh.c (sh_elf_reloc_loop): Make LAST_SYMBOL_SECTION static.
1778
1779 2000-08-08  Jason Eckhardt  <jle@cygnus.com>
1780
1781         * elf32-i860.c (elf32_i860_howto_table): Updated some fields.
1782
1783 2000-08-07  Kazu Hirata  <kazu@hxi.com>
1784
1785         * ieee.c (ieee_write_debug_part): Rewrite a comment.
1786         * elf64-ia64.c: Fix a typo.
1787
1788 2000-08-05  Jason Eckhardt  <jle@cygnus.com>
1789
1790         * elf32-i860 (elf32_i860_howto_table): New structure.
1791         (lookup_howto): New function.
1792         (elf32_i860_reloc_type_lookup): New function.
1793         (elf32_i860_info_to_howto_rela): New function.
1794         (elf_code_to_howto_index): New structure.
1795         (elf_info_to_howto): Re-define as elf32_i860_info_to_howto_rela.
1796         (bfd_elf32_bfd_reloc_type_lookup): Re-define as
1797         elf32_i860_reloc_type_lookup.
1798
1799 2000-08-04  Rodney Brown  <RodneyBrown@pmsc.com>
1800
1801         * som.c (struct fixup_format): Constify `format'.
1802         (som_hppa_howto_table): Use SOM_HOWTO macro.
1803         (try_prev_fixup, hppa_som_reloc): Decorate unused parameter.
1804         (som_bfd_reloc_type_lookup): Likewise.
1805         (compare_subspaces): Remove unused `count1', `count2'.
1806         (som_begin_writing): Remove unused `total_reloc_size'.
1807         (som_bfd_derive_misc_symbol_info): Decorate unused parameter.
1808         (som_print_symbol, som_bfd_is_local_label_name): Likewise.
1809         (som_set_reloc_info): Constify `cp'. Remove unused `addend'.
1810         (som_find_nearest_line): Decorate unused parameter(s).
1811         (som_sizeof_headers, som_get_symbol_info, som_write_armap): Likewise.
1812         (som_bfd_link_split_section): Likewise.
1813
1814 2000-08-03  Nick Clifton  <nickc@cygnus.com>
1815
1816         * section.c: Restore backed out code.
1817         * elf.c: Restore backed out code.
1818         (copy_private_bfd_data): Fix bug preventing stipped dynamic
1819         binaries from working.
1820         * bfd-in2.h: Regenerate.
1821
1822 2000-08-03  H.J. Lu  <hjl@gnu.org>
1823
1824         * section.c: Back out the change made by Nick Clifton
1825         <nickc@cygnus.com> on 2000-07-31. It breaks stripping dynamic
1826         binaries.
1827         * bfd-in2.h: Likewise.
1828         * elf.c: Likewise.
1829
1830 2000-08-03  Alexandre Oliva  <aoliva@redhat.com>
1831
1832         * elf32-sh.c (sh_elf_reloc_loop): Warning removal.
1833
1834 2000-07-31  Jason Eckhardt  <jle@cygnus.com>
1835
1836         * reloc.c (BFD_RELOC_860_*): New bfd relocs for i860.
1837         * bfd-in2.h, libbfd.h: Regenerate.
1838
1839 2000-07-31  Nick Clifton  <nickc@cygnus.com>
1840
1841         * section.c (struct sec): Add new boolean field 'segment_mark'.
1842         (STD_SECTION): Initialise new field to zero.
1843
1844         * bfd-in2.h: Regenerate.
1845
1846         * elf.c (copy_private_bfd_data): Reorganise section to segment
1847         mapping to cope with moved sections requiring new segments,
1848         and overlapping segments.
1849         (SEGMENT_END): New macro: Return the end address of a segment.
1850         (IS_CONTAINED_BY_VMA): New macro: Determine if a segment
1851         contains a section by comparing their VMA addresses.
1852         (IS_CONTAINED_BY_LMA): New macro: Determine if a segment
1853         contains a section by comparing their LMA addresses.
1854         (INCLUDE_SECTION_IN_SEGMENT): New macro: Determine if a
1855         section should be included in a segment.
1856         (SEGMENT_AFTER_SEGMENT): New macro: Determine if one segment
1857         follows another in memory.
1858         (SEGMENT_OVERLAPS_SEGMENT): New macro: Determine if two
1859         segments overlap.
1860
1861 2000-07-22  Jason Eckhardt  <jle@cygnus.com>
1862
1863         * cpu-i860.c: Added comments.
1864
1865         * elf32-i860.c (TARGET_LITTLE_SYM): Defined to
1866         bfd_elf32_i860_little_vec.
1867         (TARGET_LITTLE_NAME): Defined to "elf32-i860-little".
1868         (ELF_MAXPAGESIZE): Changed to 4096.
1869
1870         * targets.c (bfd_elf32_i860_little_vec): Declaration of
1871         new target.
1872         (bfd_target_vector): Added bfd_elf32_i860_little_vec.
1873
1874         * config.bfd (i860-stardent-sysv4*, i860-stardent-elf*): Added
1875         config for little endian elf32 i860.
1876         (targ_defvec): Define for the new config above
1877         as "bfd_elf32_i860_little_vec".
1878         (targ_selvecs): Define for the new config above
1879         as "bfd_elf32_i860_vec bfd_elf32_i860_little_vec"
1880
1881         * configure.in (bfd_elf32_i860_little_vec): Added recognition
1882         of new target vec.
1883
1884         * configure: Regenerated.
1885
1886 2000-07-27  H.J. Lu  <hjl@gnu.org>
1887
1888         * elflink.h (elf_merge_symbol): Take one more argument,
1889         dt_needed, to indicate if the symbol comes from a DT_NEEDED
1890         entry. Don't overide the existing weak definition if dt_needed
1891         is true.
1892         (elf_link_add_object_symbols): Pass dt_needed to
1893         elf_merge_symbol ().
1894
1895 2000-07-27  Nick Clifton  <nickc@cygnus.com>
1896
1897         * elflink.h (elf_link_size_reloc_section): Zeroes the section's
1898         allocated contents.
1899
1900 2000-07-25  Geoffrey Keating  <geoffk@cygnus.com>
1901
1902         * configure.host (*-*-aix*): AIX has 'long long' always.
1903
1904         * coff-rs6000.c (xcoff_write_one_armap_big): New procedure.
1905         (xcoff_write_armap_big): Write both 32-bit and 64-bit armaps.
1906         (xcoff_write_archive_contents_big): Don't update the offset
1907         of the symbol table, xcoff_write_armap will do it.
1908
1909 2000-07-23  Ulf Carlsson  <ulfc@engr.sgi.com>
1910
1911         * elf32-mips.c (_bfd_mips_elf_check_relocs): Use abfd instead
1912         of dynobj for SGI_COMPAT checks.
1913
1914 2000-07-21  Michael Sokolov  <msokolov@ivan.Harhan.ORG>
1915
1916         * coff-m68k.c (bfd_m68k_coff_create_embedded_relocs): New function.
1917         * bfd-in.h (bfd_m68k_coff_create_embedded_relocs): Add declaration.
1918         * bfd-in2.h: Regenerate.
1919
1920 2000-07-21  Nick Clifton  <nickc@cygnus.com>
1921
1922         * elf32-mips.c (_bfd_mips_elf_check_relocs): Detect out of
1923         range symbol indices in relocs and issue an error message.
1924
1925 2000-07-20  H.J. Lu  <hjl@gnu.org>
1926
1927         * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Don't check
1928         info->new_dtags when setting DT_FLAGS_1. It will only be set
1929         by the new linker options. It shouldn't break anything.
1930
1931 2000-07-20  H.J. Lu  <hjl@gnu.org>
1932
1933         * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set DT_FLAGS_1
1934         only if info->new_dtags is true.
1935
1936 2000-07-20  H.J. Lu  <hjl@gnu.org>
1937
1938         * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set
1939         DT_RUNPATH and DT_FLAGS only if info->new_dtags is true.
1940
1941 2000-07-20  Hans-Peter Nilsson  <hp@axis.com>
1942
1943         * Makefile.am (ALL_MACHINES): Add cpu-cris.lo.
1944         (ALL_MACHINES_CFILES): Add cpu-cris.c.
1945         (BFD32_BACKENDS): Add aout-cris.lo and elf32-cris.lo.
1946         (BFD32_BACKENDS_CFILES): Add aout-cris.c and elf32-cris.c.
1947         (cpu-cris.lo, aout-cris.lo, elf32-cris.lo): New rules.
1948         * Makefile.in: Rebuild.
1949         * aclocal.m4: Rebuild.
1950         * aoutx.h (NAME(aout,machine_type)): Add case for bfd_arch_cris.
1951         * archures.c (enum bfd_architecture): Add bfd_arch_cris.
1952         (bfd_cris_arch): Declare.
1953         (bfd_archures_list): Add bfd_cris_arch.
1954         * bfd-in2.h: Rebuild.
1955         * config.bfd: (cris-*-*): New target.
1956         * configure.in (bfd_elf32_cris_vec, cris_aout_vec): New vectors.
1957         * configure: Rebuild.
1958         * elf.c (prep_headers): Add bfd_arch_cris.
1959         * libbfd.h: Rebuild.
1960         * libaout.h (enum machine_type): Add M_CRIS.
1961         * reloc.c: Add CRIS relocations.
1962         * targets.c (bfd_elf32_cris_vec, cris_aout_vec): Declare.
1963         (bfd_target_vect): Add bfd_elf32_cris_vec and cris_aout_vec.
1964         * cpu-cris.c, aout-cris.c, elf32-cris.c: New files.
1965         * po/POTFILES.in, po/bfd.pot: Regenerate.
1966
1967 2000-07-19  H.J. Lu  <hjl@gnu.org>
1968
1969         * elf32-arm.h (elf32_arm_size_dynamic_sections): Also set
1970         DF_TEXTREL if DT_TEXTREL is set.
1971         * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
1972         * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
1973         * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
1974         * elf32-mips.c (_bfd_mips_elf_size_dynamic_sections): Likewise.
1975         * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
1976         * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
1977         * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
1978         * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
1979         * elf64-ia64.c (elf64_ia64_size_dynamic_sections): Likewise.
1980         * elf64-sparc.c (sparc64_elf_size_dynamic_sections): Likewise.
1981
1982         * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Also
1983         set DF_SYMBOLIC for symbolic link. Also set DT_RUNPATH if
1984         DT_RPATH is set.
1985         Set the DT_FLAGS and DT_FLAGS_1 entries if necessary.
1986
1987 2000-07-19  H.J. Lu  <hjl@gnu.org>
1988
1989         * bfd-in.h (bfd_elf_set_dt_needed_soname): New.
1990         * bfd-in2.h: Rebuild.
1991
1992         * elf-bfd.h (elf_obj_tdata): Add dt_soname.
1993         (elf_dt_soname): New.
1994
1995         * elf.c (bfd_elf_set_dt_needed_soname): New.
1996
1997         * elflink.h (elf_link_add_object_symbols): Add the DT_NEEDED
1998         entry if the shared object loaded by DT_NEEDED is used to
1999         resolve the reference in a regular object.
2000
2001 2000-07-19  H.J. Lu  <hjl@gnu.org>
2002
2003         * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_CONFIG,
2004         DT_DEPAUDIT and DT_AUDIT as strings.
2005
2006 2000-07-19  Nick Clifton  <nickc@cygnus.com>
2007
2008         * format.c: Fix formatting.
2009
2010 2000-07-19  H.J. Lu  <hjl@gnu.org>
2011
2012         * elf.c (_bfd_elf_print_private_bfd_data): Fix DT_CHECKSUM.
2013
2014 2000-07-19  H.J. Lu  <hjl@gnu.org>
2015
2016         * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_BIND_NOW,
2017         DT_INIT_ARRAY, DT_FINI_ARRAY, DT_INIT_ARRAYSZ, DT_FINI_ARRAYSZ,
2018         DT_RUNPATH, DT_FLAGS, DT_PREINIT_ARRAY, DT_PREINIT_ARRAYSZ,
2019         DT_PLTPADSZ, DT_MOVEENT, DT_MOVESZ, DT_FEATURE, DT_POSFLAG_1,
2020         DT_SYMINSZ, DT_SYMINENT, DT_CONFIG, DT_DEPAUDIT, DT_AUDIT,
2021         DT_PLTPAD, DT_MOVETAB, DT_SYMINFO, DT_RELACOUNT, DT_RELCOUNT,
2022         DT_FLAGS_1, DT_USED and DT_CHECKSUM.
2023
2024 2000-07-18  Andrew Cagney  <cagney@b1.cygnus.com>
2025
2026         * elf.c (bfd_elf_get_sign_extend_vma, bfd_elf_get_arch_size): Move
2027         renamed functions from here...
2028         (assign_section_numbers): Use renamed functions.
2029         (prep_headers): Use renamed functions.
2030
2031         * bfd.c (bfd_get_sign_extend_vma, bfd_get_arch_size): ...To here.
2032         * bfd-in.h (bfd_get_sign_extend_vma, bfd_get_arch_size): Update.
2033         * bfd-in2.h: Regenerate.
2034
2035 2000-07-18  Ulf Carlsson  <ulfc@engr.sgi.com>
2036
2037         * elf32-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Add
2038         parenthesis in if statement.
2039
2040 2000-07-17  Koundinya K  <kk@ddeorg.soft.net>
2041
2042         Enable the support for Traditional MIPS.
2043         * elf32-mips.c (IRIX_COMPAT): Recognize bfd_elf32_tradbigmips_vecand
2044         return ict_none appropriately for traditional mips targets.
2045         (STUB_LW): Change 0x8f998000 to 0x8f998010 for traditional mips.
2046         (STUB_MOVE): Conditionalize for traditonal mips.
2047         (STUB_LI16): Likewise.
2048         (_bfd_mips_elf_modify_segment_map): Conditionalize to avoid making
2049         room for RTPROC header.
2050         (_bfd_mips_elf_modify_segment_map): For a normal mips executable set
2051         the permission for the PT_DYNAMIC as read, write and execute.
2052         (mips_elf_calculate_relocation): Check for the symbol _DYNAMIC_LINKING
2053         for traditonal mips.
2054         (_bfd_mips_elf_create_dynamic_sections): Add the symbol
2055         _DYNAMIC_LINKING for traditonal mips.
2056         (_bfd_mips_elf_create_dynamic_sections): Add the symbol __RLD_MAP
2057         in case of traditonal mips.
2058         (_bfd_mips_elf_adjust_dynamic_symbol): Create a stub only if a PLT
2059         entry is required. For a function if PLT is not required then set the
2060         corresponding hash table entry to 0.
2061         (_bfd_mips_elf_size_dynamic_sections): Add DT_DEBUG entry for
2062         traditonal mips.
2063         (_bfd_mips_elf_finish_dynamic_symbol): for a undefined symbol in a
2064         shared object set the value to 0.
2065         (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol
2066         _DYNAMIC_LINKING for traditonal mips.
2067         (_bfd_mips_elf_finish_dynamic_symbol): Check for the symbol __RLD_MAP
2068         for traditonal mips.
2069
2070 2000-07-15  H.J. Lu  <hjl@gnu.org>
2071
2072         * aoutx.h (translate_to_native_sym_flags): Handle BSF_LOCAL.
2073
2074 2000-07-12  Charles Wilson  <cwilson@ece.gatech.edu>
2075
2076         * libbfd.c (bfd_seek): fix 'seek beyond EOF' error when writing
2077         out a structure that is BFD_IN_MEMORY.
2078
2079 2000-07-11  Alan Modra  <alan@linuxcare.com.au>
2080
2081         * elf64-hppa.c (get_dyn_name): Pass in section pointer instead of
2082         bfd pointer.  Print section id instead of bfd pointer for local
2083         syms.  Prefix addend with `+' for global syms as well as local.
2084         Correct calculation of name component lengths.
2085         (elf64_hppa_check_relocs): Update call to get_dyn_name.
2086
2087         From David Huggins-Daines  <dhd@linuxcare.com>
2088         * elf-hppa.h (elf_hppa_relocate_section): Update calls here too.
2089         * elf64-hppa.c (elf64_hppa_check_relocs): Fix some warnings.
2090         (elf64_hppa_modify_segment_map): Likewise.
2091
2092 2000-07-11  Andrew Cagney  <cagney@b1.cygnus.com>
2093
2094         * elf.c (bfd_elf_get_sign_extend_vma): Return tendency of VMA
2095         addresses to be "naturally" sign extended.  Return -1 if unknown.
2096         * bfd-in.h (bfd_elf_get_sign_extend_vma): Add declaration.
2097         * bfd-in2.h: Regenerate.
2098
2099 2000-07-11  Andrew Cagney  <cagney@b1.cygnus.com>
2100
2101         * ecoffswap.h (ecoff_get_off, ecoff_put_off): Add ECOFF_SIGNED_32
2102         and ECOF_SIGNED_64 to list ways to extract an offset.
2103         (ecoff_swap_fdr_in, ecoff_swap_fdr_out, ecoff_swap_pdr_in,
2104         ecoff_swap_pdr_out, ecoff_swap_ext_in, ecoff_swap_ext_out):
2105         Update.
2106         * elf64-mips.c (ECOFF_SIGNED_64): Define instead of ECOFF_64.
2107         * elf32-mips.c (ECOFF_SIGNED_32): Define instead of ECOFF_32.
2108
2109 2000-07-11  Andrew Cagney  <cagney@b1.cygnus.com>
2110
2111         * elfcode.h (elf_object_p): Use bfd_set_start_address and not
2112         bfd_get_start_address.
2113         (elf_swap_ehdr_in): Sign extend e_entry when applicable.
2114         (elf_swap_ehdr_out): Ditto.
2115
2116 2000-07-10  Alexander Aganichev  <AAganichev@hypercom.com>
2117
2118         * archures.c (bfd_default_scan): Add set of bfd_mach_ cases for
2119         compatibility with older binutils.
2120
2121 2000-07-10  Alan Modra  <alan@linuxcare.com.au>
2122
2123         * section.c (bfd_make_section_anyway): Start section_id at 0x10.
2124         (STD_SECTION): Avoid negative ids, instead use 0 to 3.
2125
2126         From Ryan Bradetich  <rbradetich@uswest.net>
2127         * dwarf1.c (parse_die): Cure signed/unsigned char warnings.
2128         (parse_line_table): Ditto.
2129         (_bfd_dwarf1_find_nearest_line): Ditto.
2130         * syms.c (cmpindexentry): Remove extra `*' from params.
2131
2132 2000-07-09  Koundinya K  <kk@ddeorg.soft.net>
2133
2134         * elf32-mips.c (sort_dynamic_relocs): New Function.
2135         (_bfd_mips_elf_finish_dynamic_sections): Call sort_dynamic_relocs
2136         via qsort to sort the dynamic relocations in increasing r_symndx
2137         value.
2138
2139 2000-07-09  Alan Modra  <alan@linuxcare.com.au>
2140
2141         * elf64-hppa.c (elf64_hppa_dyn_hash_table_init): Add
2142         ATTRIBUTE_UNUSED to unused args.
2143         (get_opd): Likewise.
2144         (get_plt): Likewise.
2145         (get_dlt): Likewise.
2146         (get_stub): Likewise.
2147         (elf64_hppa_adjust_dynamic_symbol): Likewise.
2148         (elf64_hppa_link_output_symbol_hook): Likewise.
2149         (elf64_hppa_check_relocs): Delete unused var.
2150         (elf64_hppa_size_dynamic_sections): Likewise.
2151         (elf64_hppa_finalize_opd): Likewise.
2152         (elf64_hppa_finalize_dynreloc): Likewise.
2153         (elf64_hppa_modify_segment_map): Likewise.
2154         (elf64_hppa_finish_dynamic_sections): Likewise.
2155
2156         * elf-hppa.h (elf_hppa_final_write_processing): Add
2157         ATTRIBUTE_UNUSED to unused args.
2158         (elf_hppa_final_link_relocate): Likewise.
2159         (elf_hppa_record_segment_addrs): Add paretheses.
2160         (elf_hppa_relocate_section): Constify dyn_name.
2161
2162         From  David Huggins-Daines  <dhd@linuxcare.com>
2163         * config.bfd: Add hppa*64*-*-linux-gnu 64-bit target, and
2164         rearrange case statement so that it gets preferred to 32-bit ones.
2165
2166         * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Use
2167         asection->id instead of address of asection structure.
2168         (elf32_hppa_size_stubs): Likewise.
2169
2170         * elf32-hppa.c (elf32_hppa_size_stubs): Use just one stub section
2171         for .init* and .fini*.
2172
2173         * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Mask pointers
2174         and addends used in stub names to 32 bits.
2175         (elf32_hppa_size_stubs): Likewise.
2176
2177         * elf-hppa.h (elf_hppa_final_link_relocate): Don't sum addend
2178         twice for R_PARISC_GPREL64.  Use bfd_put_32 for R_PARISC_PCREL32,
2179         not bfd_put_64.  Fix minor comment typo and formatting.
2180
2181         Changes to create multiple linker stubs, positioned immediately
2182         before the section where they are required.
2183         * elf32-hppa.c: Don't include hppa_stubs.h.
2184         (elf32_hppa_stub_hash_entry): Add a pointer to the stub section.
2185         (elf32_hppa_stub_hash_table): Delete.
2186         (elf32_hppa_link_hash_entry): Delete.
2187         (elf32_hppa_link_hash_table): Use plain bfd_hash_table for
2188         stub_hash_table, and store the struct here rather than a pointer.
2189         Delete output_symbol_count.  Add offset array.  Change
2190         global_value to a bfd_vma.
2191         (elf32_hppa_stub_hash_lookup): Use table instead of table->root.
2192         (elf32_hppa_stub_hash_traverse): Delete.
2193         (elf32_hppa_name_of_stub): Delete.
2194         (elf32_hppa_link_hash_lookup): Delete.
2195         (elf32_hppa_link_hash_traverse): Delete.
2196         (elf32_hppa_stub_hash_table_init): Delete.
2197         (elf32_hppa_size_of_stub): Pass input section and offset rather
2198         than location and calculate location here.  Don't pass name as all
2199         stubs are now the same size.
2200         (elf32_hppa_stub_hash_newfunc): Init new fields.
2201         (elf32_hppa_link_hash_table_create): Likewise, and stub_hash_table
2202         too.
2203         (elf32_hppa_bfd_final_link_relocate): Cast enums to int before
2204         comparing against ints.  Rewrite stub handling code.
2205         (elf32_hppa_relocate_section): Make r_type and r_symndx unsigned.
2206         Case enums to int before comparing against ints.  Remove
2207         bfd_reloc_dangerous case.
2208         (elf32_hppa_build_one_stub): Rewrite.
2209         (elf32_hppa_size_one_stub): New function.
2210         (elf32_hppa_build_stubs): Rewrite.
2211         (elf32_hppa_size_stubs): Pass in linker call-back functions.
2212         Rewrite stub-handling specific code.
2213
2214         * elf32-hppa.h (elf32_hppa_size_stubs): Update prototype.
2215
2216         * elf64-hppa.c (elf64_hppa_dyn_hash_entry): Fix a comment typo.
2217
2218         * hppa_stubs.h: Delete.
2219         * Makefile.am (SOURCE_HFILES): Remove hppa_stubs.h
2220         (elf32-hppa.lo): Remove hppa_stubs.h from dependencies.
2221         * Makefile.in: Regenerate.
2222
2223         * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Handle e_nlsel and
2224         e_nlrsel.
2225
2226         * libhppa.h (hppa_field_adjust): Correct e_nsel case.
2227
2228         * elf32-hppa.c (elf32_hppa_relocate_section): Mention the offset
2229         and section name for bfd_reloc_notsupported error message.
2230         (elf32_hppa_bfd_final_link_relocate): Print reasons for returning
2231         bfd_reloc_notsupported.
2232         (elf32_hppa_relocate_section): Add ATTRIBUTE_UNUSED to output_bfd.
2233
2234         * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Handle
2235         undefined weak symbols for all relocs.
2236         (elf32_hppa_size_of_stub): Adjust calculation by 8 since branch
2237         offsets are relative to one past the delay slot.
2238         (elf32_hppa_size_stubs): Account for reloc addend when calculating
2239         branch destination.  Put addend into stub name too.
2240         (elf32_hppa_bfd_final_link_relocate): Account for reloc addend and
2241         adjust by 8 when deciding whether a linker stub is needed.  Put
2242         addend into stub name as for above.
2243
2244         * elf32-hppa.c (hppa_elf_relocate_insn): Change signed/unsigned on
2245         various args and vars.
2246         (elf32_hppa_bfd_final_link_relocate): Here too.
2247         (elf32_hppa_size_stubs): Rename index -> indx.  Use e_indx for
2248         inner block var to avoid shadowing.
2249
2250         * elf32-hppa.h (_bfd_elf32_hppa_gen_reloc_type):  Make `field' arg
2251         unsigned.
2252         * elf64-hppa.h (_bfd_elf64_hppa_gen_reloc_type): Ditto.
2253         * elf-hppa.h (_bfd_elf_hppa_gen_reloc_type): Ditto.
2254         (elf_hppa_fake_sections): Rename local var to avoid shadowing.
2255
2256         * libhppa.h: Change practically all unsigned ints to plain ints.
2257         Remove tests on gcc version.  Instead use ATTRIBUTE_UNUSED for
2258         prototypes.
2259
2260         From Ryan Bradetich  <rbradetich@uswest.net>
2261         * libhppa.h (hppa_opcode_type): New enum to replace #define's.
2262         * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Modify to
2263         suit above.
2264         From  David Huggins-Daines  <dhd@linuxcare.com>
2265         * elf-hppa.h (elf_hppa_relocate_insn): Update the opcode constants
2266         to the new OP_* ones.
2267
2268         * elf32-hppa.c (elf32_hppa_size_stubs): Consolidate freeing on
2269         error exit.  Bail out earlier on plabel relocs that we aren't
2270         interested in.  Don't tell elf32_hppa_stub_hash_lookup to copy
2271         string, and then don't free our copy.
2272         (elf32_hppa_build_one_stub): Make insn unsigned int.
2273
2274         * libhppa.h (bfd_hppa_insn2fmt): 22 bit branches are only
2275         available with BL, not BE and BLE.
2276
2277         * elf32-hppa.c (hppa_elf_relocate_insn): Add some more example
2278         code for elf arg relocs.
2279         (elf32_hppa_bfd_final_link_relocate): Replace boolean is_local
2280         argument with elf_link_hash_entry h.  Handle undefined weak
2281         symbols.  Move $global$ lookup from here...
2282         (elf32_hppa_relocate_section): ...to here.  Return correct error
2283         message for non-handled relocs.
2284         (elf32_hppa_size_of_stub): Correctly test branch range.  Previous
2285         wrong test was -0x3ffff to +0x40000.
2286
2287         * elf-hppa.h (elf_hppa_final_link_relocate): R_PARISC_DIR17R,
2288         R_PARISC_DIR17F, and R_PARISC_DIR21L are for absolute branches;
2289         Handle them as such.
2290         (elf_hppa_relocate_insn): Fix a typo.
2291
2292         * libhppa.h (GET_FIELD, GET_BIT, MASK, CATENATE, ELEVEN): Delete.
2293         (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
2294         assemble_17, assemble_21): Delete.
2295         Supply defines for all 64 possible opcodes.
2296         (bfd_hppa_insn2fmt): Add bfd argument, and use to select wide mode
2297         formats.  Handle COMICLR.
2298         (hppa_rebuild_insn): Delete bfd argument.  Handle formats 10, -11,
2299         -10, -16, 16, 22.
2300
2301         * elf32-hppa.c (hppa_elf_relocate_insn): Complete rewrite.
2302         (elf32_hppa_bfd_final_link_relocate): Major rewrite.
2303         (elf32_hppa_build_one_stub): Modify hppa_elf_relocate_insn calls
2304         to suit.
2305         (elf32_hppa_size_stubs): Don't free stub_name twice.  Read in all
2306         the local syms - did this code get deleted accidentally?  Ignore
2307         undefined and undefweak syms.
2308
2309         * elf-hppa.h (elf_hppa_final_link): Move hppa_info to outermost
2310         block.  Use it instead of elf64_hppa_hash_table (info).
2311         (elf_hppa_final_link_relocate): Use hppa_info instead of
2312         elf64_hppa_hash_table (info).
2313
2314         * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
2315         re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
2316         (hppa_rebuild_insn): Mask immediate bits here instead.
2317         * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
2318
2319 2000-07-08  Alan Modra  <alan@linuxcare.com.au>
2320
2321         * section.c (struct sec): Add id field.  Tidy comment formatting.
2322         (bfd_make_section_anyway): Set id.
2323         (STD_SECTION): Init id too.
2324         Change CONST to const throughout.
2325         * archures.c (bfd_arch_info): Tidy comment.
2326         (bfd_arch_list): Change a CONST to const.
2327         * libbfd-in.h: Tidy comments and replace CONST with const.
2328         * elf-bfd.h: Likewise.
2329         * libbfd.h: Regenerate.
2330         * bfd-in2.h: Regenerate.
2331         * libcoff.h: Regenerate.
2332
2333 2000-07-07  DJ Delorie  <dj@redhat.com>
2334
2335         * archive.c (_bfd_write_archive_contents): Add an informative
2336         comment.
2337
2338 2000-07-06  Kazu Hirata  <kazu@hxi.com>
2339
2340         * srec.c: Fix formatting.
2341
2342 2000-06-05  DJ Delorie  <dj@redhat.com>
2343
2344         * MAINTAINERS: new
2345
2346 2000-07-04  Alexandre Oliva  <aoliva@redhat.com>
2347
2348         * coff-arm.c (coff_arm_relocate_section): Do not ignore the symbol
2349         value of PC-relative offsets.
2350
2351 2000-07-03  Jim Wilson  <wilson@cygnus.com>
2352
2353         * elf64-alpha.c (alpha_elf_size_info): New.
2354         (elf_backend_size_info): Define to alpha_elf_size_info.
2355         * elfcode.h (elf_size_info): Change hash bucket size to 4.
2356
2357 2000-07-03  Ulf Carlsson  <ulfc@engr.sgi.com>
2358
2359         * elf32-mips.c: Include elf32-target.h again for the traditional
2360         MIPS targets.
2361
2362 2000-07-03  Marek Michalkiewicz  <marekm@linux.org.pl>
2363
2364         * elf32-avr.c (bfd_elf32_bfd_reloc_type_lookup):
2365         Add ATTRIBUTE_UNUSED to unused arguments to avoid warnings.
2366         (avr_info_to_howto_rela): Likewise.
2367         (elf32_avr_gc_mark_hook): Likewise.
2368         (elf32_avr_gc_sweep_hook): Likewise.
2369         (elf32_avr_relocate_section): Likewise.
2370
2371 2000-07-03  Mark Elbrecht  <snowball3@bigfoot.com>
2372
2373         * cofflink.c (_bfd_coff_write_global_sym): Turn a weak symbol into
2374         an external symbol for a non-shared, non-relocatable link.
2375
2376 2000-07-03  Nick Clifton  <nickc@redhat.com>
2377
2378         * cofflink.c (IS_EXTERNAL): New macro: Return true if the symbol
2379         is an external symbol.
2380         (IS_WEAK_EXTERNAL): New macro: Return true if the symbol is a weak
2381         external symbol.
2382
2383 2000-07-03  Kazu Hirata  <kazu@hxi.com>
2384
2385         * reloc16.c: Fix formatting.
2386
2387 2000-07-01  Koundinya K  <kk@ddeorg.soft.net>
2388
2389         * config.bfd: Change targ_defvec and targ_selvecs for mips*-*-sysv4*
2390         to add a new target for traditional mips i.e
2391         bfd_elf32_tradbigmips_vec and bfd_elf32_tradlittlemips_vec.
2392         * configure.in: Likewise.
2393         * configure: Rebuild.
2394         * targets.c (bfd_elf32_tradbigmips_vec): Declare and put in
2395         bfd_target_vector.
2396         (bfd_elf32_tradlittlemips_vec): Likewise.
2397         * elfxx-target.h: Add macro INCLUDED_TARGET_FILE which is more a test
2398         to see that elfNN_bed does not get redefined even if the target file
2399         is included twice for a chip. See elf32-mips.c.
2400
2401 2000-07-01  Alan Modra  <alan@linuxcare.com.au>
2402
2403         * Makefile.am (DEP): Fix 2000-06-22.  grep after running dep.sed
2404         (CLEANFILES): Add DEPA.
2405         * Makefile.in: Regenerate.
2406
2407 2000-06-30  DJ Delorie  <dj@cygnus.com>
2408
2409         * peicode.h (coff_swap_filehdr_in): can't use e_magic because we
2410         can't assume the PE header is at 0x80.
2411
2412 2000-06-29  Mark Elbrecht  <snowball3@bigfoot.com>
2413
2414         * syms.c (_bfd_stab_section_find_nearest_line): Use IS_ABSOLUTE_PATH.
2415
2416 2000-06-28  Mark Elbrecht  <snowball3@bigfoot.com>
2417
2418         * go32stub.h: Update stub.
2419
2420 2000-06-26  Marek Michalkiewicz  <marekm@linux.org.pl>
2421
2422         * archures.c (bfd_mach_avr5): Define.
2423         * bfd-in2.h (bfd_mach_avr5): Define.
2424         * cpu-avr.c (arch_info_struct): Rename bfd_mach_avr4 to
2425         bfd_mach_avr5, add bfd_mach_avr4.  Update comments.
2426         (compatible): Update comment.  Add missing test.
2427         * elf32-avr.c (avr_final_link_relocate): Support 8K wrap
2428         for avr2 and avr4.  Simplify 8K wrap code.
2429         (bfd_elf_avr_final_write_processing): Recognize bfd_mach_avr5.
2430         (elf32_avr_object_p): Recognize E_AVR_MACH_AVR5.
2431
2432 2000-06-26  Kazu Hirata  <kazu@hxi.com>
2433
2434         * coff-h8300.c: Fix formatting.
2435         * cpu-h8300.c: Likewise.
2436
2437 2000-06-24  Alexandre Oliva  <aoliva@redhat.com>
2438
2439         * elf32-arm.h (elf32_arm_final_link_relocate): Print `(local)'
2440         for local symbols whose names are unknown.
2441
2442 2000-06-22  Alan Modra  <alan@linuxcare.com.au>
2443
2444         * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
2445         find one.
2446         * Makefile.in: Regenerate.
2447         * doc/Makefile.in: Regenerate.
2448
2449 2000-06-20  H.J. Lu  <hjl@gnu.org>
2450
2451         * Makefile.am: Rebuild dependency.
2452         * Makefile.in: Rebuild.
2453
2454 2000-06-20  Maciej W. Rozycki  <macro@ds2.pg.gda.pl>
2455
2456         * elf32-mips.c (_bfd_mips_elf_copy_indirect_symbol): New function.
2457         (elf_backend_copy_indirect_symbol): Map to the new function.
2458
2459 2000-06-20  Alan Modra  <alan@linuxcare.com.au>
2460
2461         * archive.c (normalize): Correct pointer comparison when checking
2462         for backslashes.
2463         (bfd_bsd_truncate_arname): Likewise.
2464         (bfd_gnu_truncate_arname): Likewise.
2465
2466 2000-06-20  Ulf Carlsson  <ulfc@engr.sgi.com>
2467
2468         * elf-bfd.h (struct elf_obj_tdata): Define per BFD Irix 5 virtual
2469         sections elf_{text,data}_{section,symbol}.
2470         * elf32-mips.c: mips_elf_{text,data}_{section,symbol}{,_ptr}: Remove.
2471         (_bfd_mips_elf_hide_symbol): New function.
2472         (elf_backend_hide_symbol): Map to the new function.
2473         (_bfd_mips_elf_add_symbol_hook): Change to use new per BFD
2474         definitions of mips_elf_{text,data}_{section,symbol}.
2475         (mips_elf_local_relocation_p): Try to find the direct symbol
2476         based on new check_forced argument.
2477         (mips_elf_calculate_relocation): Use new version of
2478         mips_elf_local_relocation_p.
2479         (mips_elf_relocate_section): Likewise.
2480         (_bfd_mips_elf_relocate_section): Likewise.
2481         (mips_elf_sort_hash_table): Only assert that have enough GOT
2482         space.
2483         (mips_elf_got16_entry): Match all 32 bits to the existing GOT
2484         entry if the relocation based on the new external argument.
2485         (mips_elf_create_dynamic_relocation): Assert that we have a
2486         section contents allocated where we can swap out the dynamic
2487         relocations.
2488         (mips_elf_calculate_relocation): Find the real hash-table entry
2489         correctly by using h->root.root.type.  Only create a dynamic
2490         relocation entry if the symbol is defined in a shared library.
2491         Create an external GOT entry for the GOT16 relocation if the
2492         symbol was forced local.
2493         (_bfd_mips_elf_finish_dynamic_symbol): Don't assert there is a
2494         dynamic index if the symbol was forced local.
2495
2496 2000-06-20  Maciej W. Rozycki  <macro@ds2.pg.gda.pl>
2497
2498         * elf32-mips.c: Fix typos in comments.
2499
2500 2000-06-19  Mark Kettenis  <kettenis@gnu.org>
2501
2502         * rs6000-core.c: Wrap definition of `union VmInfo' within #ifdef
2503         CORE_VERSION_1.
2504
2505 2000-06-18  Stephane Carrez  <stcarrez@worldnet.fr>
2506
2507         * Makefile.in, bfd-in2.h, libbfd.h, configure: Rebuild.
2508         * Makefile.am (ALL_MACHINES, ALL_MACHINES_CFILES, BFD32_BACKENDS,
2509         BFD32_BACKENDS_CFILES): Add 68hc12, 68hc11 files.
2510         * configure.in (bfd_elf32_m68hc12_vec): Recognize.
2511         (bfd_elf32_m68hc11_vec): Likewise.
2512         * config.bfd (targ_cpu): Recognize 68hc12 and 68hc11.
2513         Supports 68hc11 & 68hc12  at the same time.
2514         * targets.c (bfd_elf32_m68hc12_vec): Declare and put in
2515         bfd_target_vector.
2516         (bfd_elf32_m68hc11_vec): Likewise.
2517         * elf.c (prep_headers): Recognize bfd_arch_m68hc12 and 68hc11.
2518         * archures.c (bfd_m68hc12_arch): Define and register in global list
2519         (bfd_m68hc11_arch): Likewise.
2520         * reloc.c (BFD_RELOC_M68HC11_HI8, BFD_RELOC_M68HC11_LO8,
2521         BFD_RELOC_M68HC11_3B): Define.
2522         * cpu-m68hc12.c, elf32-m68hc12.c: New files for 68hc12 support.
2523         * cpu-m68hc11.c, elf32-m68hc11.c: New files for 68hc11 support.
2524
2525 2000-06-18  Ulf Carlsson  <ulfc@engr.sgi.com>
2526
2527         * elf_bfd.h (struct elf_backend_data): Add info argument to
2528         elf_backend_hide_symbol.
2529         (_bfd_elf_link_hash_hide_symbol): Likewise.
2530         * elf.c (_bfd_elf_link_hash_hide_symbol): Likewise.
2531         * elf64-ia64.c (elf64_ia64_hash_hide_symbol): Likewise.
2532         * elflink.h (elf_link_add_object_symbols): Likewise.
2533         (elf_link_assign_sym_version): Likewise.
2534
2535 2000-06-18  H.J. Lu  <hjl@gnu.org>
2536
2537         * coff-i386.c (coff_i386_reloc): Don't return in case of
2538         output_bfd == (bfd *) NULL if COFF_WITH_PE is defined.
2539         Compensate PE relocations when linking with non-PE object
2540         files to generate a non-PE executable.
2541
2542 2000-06-17  Ulf Carlsson  <ulfc@engr.sgi.com>
2543
2544         * elf32-mips.c (mips_elf_calculate_relocation): Explicitly write
2545         GOT entries if we're doing a static link or -Bsymbolic link.
2546
2547 2000-06-15  Ulf Carlsson  <ulfc@engr.sgi.com>
2548
2549         * elflink.h (elf_link_adjust_relocs): Check for and call backend
2550         specifific swap_reloc_{in,out} and swap_reloca_{in,out} if
2551         available.
2552         (elf_link_output_relocs): Likewise.
2553         (elf_reloc_link_order): Likewise.
2554
2555 2000-06-16  Nicholas Duffek  <nsd@redhat.com>
2556
2557         * archures.c (enum bfd_architecture): #define constants for
2558         PowerPc and RS6000 machine numbers.
2559         * bfd-in2.h: Regenerate.
2560         * coffcode.h (coff_set_arch_mach_hook): #ifdef XCOFF64, set arch
2561         to bfd_arch_powerpc instead of bfd_arch_rs6000.  Refer to PowerPc
2562         and RS6000 machine numbers using #defined constants from
2563         archures.c.
2564         * cpu-powerpc.c (arch_info_struct): Refer to PowerPc and RS6000
2565         machine numbers using #defined constants from archures.c.  Add
2566         entries for EC603e, 630, A35, RS64II, RS64III, 7400.  Specify
2567         64-bit words in 620 entry.
2568         * cpu-rs6000.c (arch_info_struct): Create with entries for RS1,
2569         RSC, and RS2.
2570         (bfd_rs6000_arch): Change default machine to 0 (bfd_mach_rs6k).
2571
2572 2000-06-16  Nicholas Duffek  <nsd@cygnus.com>
2573
2574         * coffcode.h (coff_mkobject_hook): Set xcoff_tdata.xcoff64.
2575         * libcoff-in.h (struct xcoff_tdata): Define xcoff64 field.
2576         * libcoff.h (struct xcoff_tdata): Define xcoff64 field.
2577
2578 2000-06-16  Nicholas Duffek  <nsd@redhat.com>
2579
2580         * bfd-in.h (bfd_family_coff): Define.
2581         * bfd-in2.h: Regenerate.
2582         * coffgen.c (coff_count_linenumbers, coff_symbol_from,
2583         coff_find_nearest_line): Check COFFness using bfd_family_coff()
2584         instead of bfd_target_coff_flavour.
2585         * cofflink.c (_bfd_coff_final_link): Likewise.
2586         * cpu-ns32k.c (do_ns32k_reloc): Don't strcmp() target name to
2587         exclude XCOFF files.
2588         * reloc.c (bfd_perform_relocation, bfd_install_relocation):
2589         Likewise.
2590         * targets.c (enum bfd_flavour): Add bfd_target_xcoff_flavour.
2591         * xcoff-target.h (TARGET_SYM): Use bfd_target_xcoff_flavour.
2592         * xcofflink.c (XCOFF_XVECP): Delete.
2593         (bfd_xcoff_link_record_set, bfd_xcoff_import_symbol,
2594         bfd_xcoff_export_symbol, bfd_xcoff_link_count_reloc,
2595         bfd_xcoff_record_link_assignment,
2596         bfd_xcoff_size_dynamic_sections): Replace XCOFF_XVECP() with
2597         check for bfd_target_xcoff_flavour.
2598
2599 2000-06-16  Nicholas Duffek  <nsd@redhat.com>
2600
2601         * rs6000-core.c: Support 64-bit core files, support pre-4.3 core
2602         files on AIX 4.3.
2603         (read_hdr): New function.
2604         (rs6000coff_core_p): Store mstsave or __context64 struct instead
2605         of trying to extract individual registers.  Set abfd->arch_info
2606         to match the architecture that created the core file.
2607         (rs6000coff_get_section_contents): Delete.
2608         * xcoff-target.h (rs6000coff_get_section_contents): Delete.
2609
2610 2000-06-14  H.J. Lu  <hjl@gnu.org>
2611
2612         * vms-misc.c (_bfd_vms_next_record): Return -1 if PRIV(vms_rec)
2613         is NULL.
2614
2615 2000-06-13  H.J. Lu  <hjl@gnu.org>
2616
2617         * configure: Regenerate.
2618
2619 2000-06-13  J"orn Rennecke <amylaar@cygnus.co.uk>
2620
2621         * peicode.h (pe_ILF_object_p): Use TARGET_LITTLE_SYM instead of
2622         armpei_little_vec.
2623
2624 2000-06-08  David O'Brien  <obrien@FreeBSD.org>
2625
2626         * configure.in (VERSION): Update to show this is the CVS mainline.
2627
2628 2000-06-07  Alan Modra  <alan@linuxcare.com.au>
2629
2630         * elf32-d10v.c: Include elf/d10v.h
2631         (enum reloc_type): Delete.
2632         * elf32-d30v.c: Include elf/d30v.h
2633         (enum reloc_type): Delete.
2634
2635         * Makefile.am: Run "make dep-am" to regenerate dependencies.
2636         * Makefile.in: Regenerate.
2637
2638         * elf32-i386.c (elf_howto_table): Remove EMPTY_HOWTOs.
2639         (elf32_i386_vtinherit_howto, elf32_i386_vtentry_howto): Delete and
2640         move HOWTOs into elf_howto_table.
2641         (R_386_standard, R_386_ext_offset): Define.
2642         (R_386_ext, R_386_vt_offset, R_386_vt): Define.
2643         (elf_i386_reloc_type_lookup): Modify calculation of index into
2644         elf_howto_table since we've removed the padding.
2645         (elf_i386_info_to_howto_rel): Likewise.
2646         (elf_i386_relocate_section): Likewise.
2647
2648 2000-06-06  Michael Snyder  <msnyder@seadog.cygnus.com>
2649
2650         * elf.c (elf_grok_pr_status): Eliminate reference to prgregset_t.
2651
2652 2000-06-05  H.J. Lu  <hjl@gnu.org>
2653
2654         * elflink.c (_bfd_elf_link_record_dynamic_symbol): Don't flag
2655         an error when seeing an undefined symbol with hidden/internal
2656         attribute. It is handled in *_relocate_section ().
2657
2658 2000-06-05  H.J. Lu  <hjl@gnu.org>
2659
2660         * elflink.h (elf_fix_symbol_flags): Follow the link for the
2661         indirect symbol for the ELF_LINK_NON_ELF bit.
2662         (elf_link_output_extsym): Don't output the indirect symbol even
2663         if the ELF_LINK_NON_ELF bit is set.
2664
2665 2000-06-01  J.T. Conklin  <jtc@redback.com>
2666
2667         * config.bfd (i[3456]86-*-netbsdelf*): New target.
2668         (i[3456]86-*-netbsdaout*): New target.
2669         (i[3456]86-*-netbsd*): Add bfd_elf32_i386_vec to targ_selvecs.
2670         (i[3456]86-*-openbsd*): Likewise.
2671
2672 2000-05-30  Andrew Cagney  <cagney@b1.cygnus.com>
2673
2674         * trad-core.c: From hpux-core.c, include <dirent.h> or
2675         <sys/ndir.h> when possible.
2676
2677 2000-05-31  Nick Clifton  <nickc@cygnus.com>
2678
2679         * opintl.h (_(String)): Explain why dgettext is used instead
2680         of gettext.
2681
2682 2000-05-31  Ulrich Drepper  <drepper@redhat.com>
2683
2684         * elf.c (_bfd_elf_slurp_version_tables): Correct reading of version
2685         definitions.  We must not assume they are sorted in the file
2686         according to their index numbers.
2687
2688 2000-05-31  Alan Modra  <alan@linuxcare.com.au>
2689
2690         * elf-hppa.h: (elf_hppa_final_link_relocate): Use e_rsel field
2691         selector for R_PARISC_PCREL17R.  R_PARISC_DIR17R and
2692         R_PARISC_DIR17F are for absolute branches; Handle them as such.
2693
2694 2000-05-30  Nick Clifton  <nickc@cygnus.com>
2695
2696         * cpu-i960.c (scan_960_mach): Accept 80960KA, 80960KB,
2697         80960CA, 80960MC as valid machine names.
2698
2699 2000-05-30  H.J. Lu  <hjl@gnu.org>
2700
2701         * elflink.c (_bfd_elf_link_record_dynamic_symbol): Clear the
2702         visibility bits if the symbol is undefined. Correctly handle
2703         weak undefined symbols with hidden and internal attributes.
2704
2705         * elflink.h (elf_link_add_object_symbols): Always turn the
2706         symbol into local if it has the hidden or internal attribute.
2707
2708 2000-05-29  Philip Blundell  <philb@gnu.org>
2709
2710         * ppcboot.c:  Add packed attribute if compiling with GCC.
2711
2712 2000-05-29  Anatoly Vorobey  <mellon@pobox.com>
2713
2714         * elf.c (_bfd_elf_link_hash_table_init): Initialize dynlocal.
2715
2716 2000-05-26  Michael Snyder  <msnyder@seadog.cygnus.com>
2717
2718         * elf.c (elfcore_grok_prstatus, elfcore_grok_pstatus,
2719         elfcore_grok_psinfo): Add code to allow debugging a 32-bit
2720         corefile on a 64-bit (Sparc Solaris) host.  Also clean up
2721         a few old comments.
2722
2723 2000-05-26  Alan Modra  <alan@linuxcare.com.au>
2724
2725         * Makefile.am: Update dependencies with "make dep-am"
2726         * Makefile.in: Regenerate.
2727
2728         * sysdep.h (gettext, dgettext, dcgettext, textdomain,
2729         bindtextdomain): Replace defines with those from intl/libgettext.h
2730         to quieten gcc warnings.
2731
2732 2000-05-26  Eli Zaretskii  <eliz@is.elta.co.il>
2733
2734         * aoutx.h (find_nearest_line): Use IS_ABSOLUTE_PATH.
2735
2736         * archive.c (normalize, bfd_bsd_truncate_arname,
2737         bfd_gnu_truncate_arname) [HAVE_DOS_BASED_FILE_SYSTEM]: Support
2738         file names with backslashes.
2739
2740         * cache.c (bfd_open_file) [__MSDOS__]: Don't unlink the file
2741         before opening it.
2742
2743         * sysdep.h: Include filenames.h.
2744
2745 2000-05-26  Alan Modra  <alan@linuxcare.com.au>
2746
2747         * opncls.c (bfd_close_all_done): Mask file perms with 0777 not 0x777.
2748
2749 2000-05-26  Jakub Jelinek  <jakub@redhat.com>
2750
2751         * elf64-sparc.c (sparc64_elf_relax_section): New.
2752         (sparc64_elf_relocate_section): Optimize tail call into branch always
2753         if possible.
2754         * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
2755         (elf32_sparc_relax_section): New.
2756
2757 2000-05-26  Jakub Jelinek  <jakub@redhat.com>
2758
2759         * elf64-sparc.c: Add ATTRIBUTE_UNUSED to unused function parameters.
2760         Remove unusued variables.
2761         (sparc64_elf_relocate_section): Change r_symndx type to unsigned long.
2762         (sparc64_elf_merge_private_bfd_data): Fix shared library case from
2763         previous fix, so that shared libs really don't influence targets
2764         extension mask and memory model.
2765
2766 2000-05-23  H.J. Lu  <hjl@gnu.org>
2767
2768         * elf64-alpha.c (elf64_alpha_relocate_section): Check
2769         h->root.other not h->other.
2770         * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
2771
2772         * elf32-ppc.c (ppc_elf_relocate_section): Fix a typo.
2773
2774 2000-05-23  H.J. Lu  <hjl@gnu.org>
2775
2776         * elf32-i386.c (elf_i386_relocate_section): Don't allow the
2777         undefined symbol with the non-default visibility attributes.
2778         * elf-hppa.h (elf_hppa_relocate_section): Likewise.
2779         * elf32-arm.h (elf32_arm_relocate_section): Likewise.
2780         * elf32-i370.c (i370_elf_relocate_section): Likewise.
2781         * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
2782         * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
2783         * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
2784         * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
2785         * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
2786         * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
2787         * elf64-ia64.c (elf64_ia64_relocate_section): Likewise.
2788         * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
2789
2790 2000-05-22  Richard Henderson  <rth@cygnus.com>
2791
2792         * elf64-ia64.c (ia64_howto_table): Add PCREL60B, PCREL21BI,
2793         PCREL22, PCREL64I.  Zero size of special relocs.
2794         (elf64_ia64_reloc_type_lookup): Likewise.
2795         (USE_BRL, oor_brl, oor_ip): New.
2796         (elf64_ia64_relax_section): New.
2797         (elf64_ia64_check_relocs): Handle PCREL60B, PCREL22, PCREL64I.
2798         (elf64_ia64_install_value): Likewise, plus PCREL21BI.
2799         (elf64_ia64_relocate_section): Likewise.
2800         (bfd_elf64_bfd_relax_section): New.
2801         * reloc.c (BFD_RELOC_IA64_PCREL21BI): New.
2802         (BFD_RELOC_IA64_{PCREL22,PCREL60B,PCREL64I}): New.
2803         * bfd-in2.h, libbfd.h: Regenerate.
2804
2805 2000-05-22  Nick Clifton  <nickc@cygnus.com>
2806
2807         * configure.in : Add peigen.lo to MIPS PE targets.
2808         * configure: Regenerate.
2809
2810 2000-05-22  Momchil Velikov  <velco@fadata.bg>
2811
2812         * libbfd.c (_bfd_generic_verify_endian_match): Compare endianess
2813         only if it is known for both input and output bfds. Separate
2814         error message strings as in some languages, it may be necessary
2815         to change more than one place in the string to change between
2816         'big' and 'little'.
2817
2818         * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Remove inline
2819         endianess checks, call _bfd_generic_verify_endian_match() instead.
2820
2821         * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Likewise.
2822
2823         * elf32-mcore.c (mcore_elf_merge_private_bfd_data): Likewise.
2824
2825         * elf32-arm.h (elf32_arm_merge_private_bfd_data): Likewise. Verify
2826         endianess before checking bfd flavours.
2827
2828 2000-05-22  H.J. Lu  <hjl@gnu.org>
2829
2830         * elflink.h (elf_link_output_extsym): Clear the visibility
2831         field for symbols not defined locally.
2832
2833 2000-05-18  Alan Modra  <alan@linuxcare.com.au>
2834
2835         * libhppa.h (re_assemble_3, re_assemble_12, re_assemble_16,
2836         re_assemble_17, re_assemble_21, re_assemble_22): Don't mask insn.
2837         (hppa_rebuild_insn): Mask immediate bits here instead.
2838         * elf-hppa.h (elf_hppa_relocate_insn): Mask here too.
2839
2840 2000-05-18  Momchil Velikov <velco@fadata.bg>
2841
2842         * elflink.h (elf_bfd_final_link, elf_link_input_bfd): When emiting
2843         relocs for an executable, ensure that they are virtual addresses.
2844
2845 2000-05-18  Jeffrey A Law  (law@cygnus.com)
2846
2847         * config.bfd (hppa*64*-*-hpux11*): New target triplet.
2848
2849 2000-05-17  S. Bharadwaj Yadavalli  <sby@scrugs.lkg.dec.com>
2850             Rick Gorton             <gorton@scrugs.lkg.dec.com>
2851
2852         * elflink.h: Add emitrelocations support: when enabled, relocation
2853         information and relocation sections are put into final output
2854         executables.  If the emitrelocations flag is set, do the following:
2855         (elf_bfd_final_link): Emit relocation sections.
2856         (elf_link_input_bfd): Compute relocation section contents.
2857         (elf_gc_sections): Don't clean relocation sections.
2858
2859 2000-05-16  Catherine Moore  <clm@cygnus.com>
2860
2861         * som.c (som_decode_symclass):  Recognize weak symbols.
2862
2863 2000-05-16  Szabolcs Szakacsits <szaka@F-Secure.com>
2864
2865         * peigen.c (pe_print_idata): Undo part of 2000-05-12 change that
2866         read idata section only from dataoff.
2867         (pe_print_edata): Correctly check for valid eat_member.
2868
2869 2000-05-16  J"orn Rennecke <amylaar@cygnus.co.uk>
2870
2871         * elf32-sh.c (sh_elf_relax_delete_bytes): Handle R_SH_SWITCH8.
2872
2873 2000-05-14  Philip Blundell  <philb@gnu.org>
2874
2875         * config.bfd (armeb-*-elf, arm*b-*-linux-gnu*): New targets.
2876
2877 2000-05-12  Alan Modra  <alan@linuxcare.com.au>
2878
2879         * targets.c (bfd_target_vector): #ifdef BFD64 rs6000coff64_vec
2880
2881         * peigen.c (pe_print_idata): Look for .idata section and print
2882         info even if data directory has zero entries.  Read idata section
2883         starting from dataoff, and adjust all data offsets to suit.  Cast
2884         all bfd_vma vars to unsigned long before passing to fprintf.
2885         * peigen.c (pe_print_edata): Similarly, look for .edata section
2886         and print info even if data directory has zero entries.  Cast
2887         all bfd_vma vars to unsigned long before passing to fprintf.
2888
2889         From Szabolcs Szakacsits <szaka@F-Secure.com>
2890         * peigen.c (pe_print_idata): Use bfd_section_size rather than data
2891         directory size which may be bogus.
2892         * peigen.c (pe_print_edata): Similarly.
2893
2894 2000-05-09  Alan Modra  <alan@linuxcare.com.au>
2895
2896         * elf.c (bfd_section_from_shdr): Don't set use_rela_p if rela
2897         section is empty.
2898         (copy_private_bfd_data): Allow for space possibly taken up by elf
2899         headers when calculating segment physical address from lma.
2900
2901 2000-05-08  Alan Modra  <alan@linuxcare.com.au>
2902
2903         * versados.c (versados_scan): Init stringlen and pass_2_done.
2904
2905         * trad-core.c (trad_unix_core_file_p): Return
2906         bfd_error_wrong_format rather than bfd_error_file_truncated.
2907
2908         * peigen.c (_bfd_pei_swap_aouthdr_out): Pass ImageBase to
2909         add_data_entry.  DataDirectory virtual address is relative.
2910         (pe_print_idata): Account for relative DataDirectory virtual
2911         addresses.  Don't trash datasize inside POWERPC_LE_PE code.
2912         (pe_print_edata): Similarly.
2913
2914         From Szabolcs Szakacsits <szaka@F-Secure.com>
2915         * peigen.c (dir_names): Add Delay Import Directory.
2916         (pe_print_idata):  Always search for bfd section containing
2917         idata address rather than looking up section name.  Print this
2918         section name rather than .idata.
2919         (pe_print_edata): Similarly.  Also print some fields as %08lx.
2920         (_bfd_pe_print_private_bfd_data_common): Print Reserved1 field as
2921         Win32Version.
2922
2923 2000-05-05  Clinton Popetz  <cpopetz@cygnus.com>
2924
2925         * xcoff.h: Rename to xcoff-target.h
2926         * Makefile.am: Change all instances of xcoff.h to xcoff-target.h
2927         * coff-rs6000.c: Ditto.
2928         * coff64-rs6000.c: Ditto.
2929         * coff-pmac.c: Ditto.
2930         * Makefile.in: Regenerate.
2931
2932 2000-05-05  Clinton Popetz  <cpopetz@cygnus.com>
2933
2934         * coffcode.h (coff_set_arch_mach_hook, coff_set_flags):
2935         Change U802TOC64MAGIC to U803XTOCMAGIC.
2936
2937 2000-05-04  Michael Snyder  <msnyder@seadog.cygnus.com>
2938
2939         * elf.c (bfd_elf_get_arch_size): New function, return 32 | 64 | -1.
2940         * bfd-in.h: Prototype bfd_elf_get_arch_size.
2941         * bfd-in2.h: Prototype bfd_elf_get_arch_size.
2942
2943 2000-05-04  Alan Modra  <alan@linuxcare.com.au>
2944
2945         * libhppa.h (HPPA_R_CONSTANT): Cast argument to bfd_signed_vma.
2946
2947 2000-05-03  Martin v. Löwis  <loewis@informatik.hu-berlin.de>
2948
2949         * elflink.h (elf_link_add_object_symbols): Reset dynindx for
2950         hidden and internal symbols.
2951         (elf_fix_symbol_flags): Clear NEEDS_PLT for symbols with
2952         visibility.
2953         * elflink.c (_bfd_elf_link_record_dynamic_symbol): Do not
2954         assign a PLT or GOT entry to symbols with hidden and
2955         internal visibility.
2956
2957 2000-05-03  Mark Elbrecht  <snowball3@bigfoot.com>
2958
2959         * bfd/coff-go32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Add entry for
2960         the .bss section.
2961         * bfd/coff-stgo32.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
2962
2963 2000-05-02  H.J. Lu  <hjl@gnu.org>
2964
2965         * elf.c (prep_headers): Use ELFOSABI_NONE instead of
2966         ELFOSABI_SYSV.
2967
2968 2000-05-02  Alan Modra  <alan@linuxcare.com.au>
2969
2970         * targets.c (bfd_target_vector): Restore bfd_elf32_hppa_vec.
2971         * Makefile.am (BFD32_BACKENDS): Restore elf32-hppa.lo.  Regenerate
2972         dependencies.
2973         * Makefile.in: Regenerate.
2974
2975 2000-05-01  Jim Wilson  <wilson@cygnus.com>
2976
2977         * Makefile.am (BFD32_BACKENDS): Add efi-app-ia32.lo.
2978         (BFD32_BACKENDS_CFILES): Add efi-app-ia32.c.
2979         (BFD64_BACKENDS): Delete coff-ia64.lo.  Add efi-app-ia64.lo.
2980         (BFD64_BACKENDS_CFILES): Delete coff-ia64.c.  Add efi-app-ia64.c.
2981         * Makefile.in: Rebuild.
2982
2983 2000-05-02  Alan Modra  <alan@linuxcare.com.au>
2984
2985         * config.bfd: Re-enable elf32-hppa.  It now compiles, even if it
2986         doesn't work very well.
2987
2988         * elf-hppa.h (elf_hppa_internal_shdr): Define.
2989         (elf_hppa_fake_sections): hdr is elf_hppa_internal_shdr.
2990         Set hdr->s_type to 1 if ARCH_SIZE == 32.
2991         (_bfd_elf_hppa_gen_reloc_type): Add prototype.
2992         (elf_hppa_info_to_howto): Likewise.
2993         (elf_hppa_info_to_howto_rel): Likewise.
2994         (elf_hppa_reloc_type_lookup): Likewise.
2995         (elf_hppa_is_local_label_name): Likewise.
2996         (elf_hppa_fake_sections): Likewise.
2997         (elf_hppa_final_write_processing): Likewise.
2998         (elf_hppa_howto_table): Fully initialise all entries.
2999         (_bfd_elf_hppa_gen_reloc_type): Add ATTRIBUTE_UNUSED to args.
3000         (elf_hppa_info_to_howto): Likewise.
3001         (elf_hppa_info_to_howto_rel): Likewise.
3002         (elf_hppa_reloc_type_lookup): Likewise.
3003         (elf_hppa_final_write_processing, elf_hppa_add_symbol_hook,
3004         elf_hppa_unmark_useless_dynamic_symbols,
3005         elf_hppa_remark_useless_dynamic_symbols,
3006         elf_hppa_record_segment_addrs, elf_hppa_final_link,
3007         elf_hppa_relocate_section, elf_hppa_final_link_relocate,
3008         elf_hppa_relocate_insn): Compile only if ARCH_SIZE == 64 until
3009         elf32-hppa.c mess is cleaned up.
3010         (elf_hppa_final_link_relocate): Make insn and r_type unsigned
3011         int.  Delete r_field.  In case R_PARISC_PCREL21L, don't set
3012         r_field then call hppa_field_adjust inline func with variable
3013         r_field arg, instead call hppa_field_adjust with fixed arg.
3014         In case R_PARISC_PCREL22F, don't set r_field.
3015         (elf_hppa_relocate_insn): Change args and return type to unsigned
3016         int.  Call re_assemble_* funcs to do the work.
3017
3018         * elf32-hppa.c (hppa_elf_relocate_insn): Don't assume 32 bit when
3019         sign extending.
3020
3021         * libhppa.h (HPPA_R_CONSTANT): Don't assume 32 bit when sign
3022         extending.
3023         (sign_extend): Mask first before sign extending.
3024         (low_sign_extend): Rewrite without condition expression.
3025         (ones, dis_assemble_3, dis_assemble_12, dis_assemble_16,
3026         dis_assemble_17, dis_assemble_21, dis_assemble_22): Delete.
3027         (assemble_3, assemble_6, assemble_12, assemble_16, assemble_16a,
3028         assemble_17, assemble_21, sign_unext, low_sign_unext): Return
3029         result as function return value rather than through pointer arg.
3030         Accept unsigned int args, and return unsigned int.
3031         (re_assemble_3): New.  Combines function of dis_assemble_3 with
3032         re-assembly of opcode and immediate.
3033         (re_assemble_12): Likewise.
3034         (re_assemble_16): Likewise.
3035         (re_assemble_17): Likewise.
3036         (re_assemble_21): Likewise.
3037         (re_assemble_22): Likewise.
3038         (hppa_field_adjust): Rewrite and document, paying attention to
3039         size of types and signed/unsigned issues.
3040         (get_opcode): Shift before masking.
3041         (FDLW): Rename to FLDW.
3042         (bfd_hppa_insn2fmt): Change arg to unsigned int.  Delete fmt.
3043         (hppa_rebuild_insn): Change args and return value to unsigned
3044         int.  Make use of re_assemble_*.  Correct case 11.
3045
3046         * dep-in.sed: Handle ../opcodes/.
3047         * Makefile.am (SOURCE_HFILES): Add elf-hppa.h, elf32-hppa.h,
3048         elf64-hppa.h, hppa_stubs.h, xcoff.h.
3049         (BFD32_BACKENDS_CFILES): Restore elf32-hppa.c.
3050         Remove elf64-hppa.lo, cpu-ia64.lo, elf64-ia64.lo, elfarm-oabi.lo,
3051         elfarm-nabi.lo dependencies outside of auto-dependency area.
3052         Regenerate dependencies.
3053         * Makefile.in: Regenerate.
3054
3055         * configure.in (TRAD_HEADER): Test non-null before
3056         AC_DEFINE_UNQUOTED.
3057         * configure: Regenerate.
3058
3059         * reloc.c: Fix mis-spelling in comment.
3060
3061 2000-05-01  Alan Modra  <alan@linuxcare.com.au>
3062
3063         * coff-sh.c (bfd_coff_small_swap_table): Fix Fri Apr 28 change.
3064         * vms.c (vms_openr_next_archived_file): Return NULL.
3065
3066 2000-04-28  Clinton Popetz  <cpopetz@cygnus.com>
3067
3068         * coffcode.h Copy changes mistakenly done to libcoff.h in
3069         4/24/2000 patch.
3070
3071 2000-04-29  Andreas Jaeger  <aj@suse.de>
3072
3073         * libbfd-in.h: Correctly check GCC version.
3074         * bfd-in.h: Likewise.
3075         * libhppa.h: Likewise.
3076         * libbfd.h: Regenerate.
3077         * bfd-in2.h: Regenerate.
3078
3079 2000-04-28  Clinton Popetz  <cpopetz@cygnus.com>
3080
3081         * Makefile.am (BFD64_BACKENDS, BFD64_BACKENDS_CFILES): Add
3082         coffdu-rs6000.{lo,c}.
3083         (coff-pmac.lo, coff-rs6000.lo, coff64-rs6000.lo): Add dependency
3084         on xcoff.h
3085         * Makefile.in: Regenerate.
3086         * xcoff.h: New file.
3087         * coff-pmac.c: Use xcoff.h instead of coff-rs6000.c.
3088         * coff-rs6000.c: Move all declarations and defines that are
3089         common to the xcoff backends into xcoff.h
3090         * coff64-rs6000.c: Ditto,
3091
3092 2000-04-28  Clinton Popetz  <cpopetz@cygnus.com>
3093
3094         * coff-mips.c (mips_ecoff_backend_data):  Add initialization of
3095         _bfd_coff_force_symnames in strings and
3096         _bfd_coff_debug_string_prefix_length to their default values.
3097         * coff-sh.c: (bfd_coff_small_swap_table): Ditto.
3098
3099 2000-04-28  Clinton Popetz  <cpopetz@cygnus.com>
3100
3101         * coff-alpha.c (alpha_ecoff_backend_data): Add initialization of
3102         _bfd_coff_force_symnames in strings and
3103         _bfd_coff_debug_string_prefix_length to their default values.
3104
3105 2000-04-27  Alan Modra  <alan@linuxcare.com.au>
3106
3107         * elf32-m68k.c (elf_m68k_gc_sweep_hook):  Return if dynobj NULL.
3108         Check local_got_refcounts before dereferencing.
3109
3110         * elf32-ppc.c (ppc_elf_relocate_section): Check splt != NULL
3111         before deciding we don't need R_PPC_PLT32 relocation.
3112         (ppc_elf_gc_sweep_hook): Check local_got_refcounts before
3113         dereferencing.
3114
3115         * elflink.h (elf_gc_common_finalize_got_offsets): Fix comment.
3116
3117         * elf32-i386.c (elf_i386_check_relocs): Reference count .got and
3118         .plt entries.
3119         (elf_i386_gc_sweep_hook): Garbage collect .got and .plt entries.
3120         (elf_i386_adjust_dynamic_symbol): Recognize unused .plt entries.
3121         (elf_i386_relocate_section): Allow for .plt to go missing.
3122         (elf_i386_finish_dynamic_symbol): Use same test to decide if we
3123         can use a relative reloc for got as elf_i386_relocate_section.
3124         (bfd_elf32_bfd_final_link): Define to use gc form of final link.
3125
3126 2000-04-26  Clinton Popetz  <cpopetz@cygnus.com>
3127
3128         * config.bfd: Remove extraneous bfd_powerpc_64_arch.
3129
3130 2000-04-24  Clinton Popetz  <cpopetz@cygnus.com>
3131
3132         * Makefile.am (coff64-rs6000.lo): New rule.
3133         * Makefile.in: Regenerate.
3134         * coff-rs6000.c (xcoff_mkobject, xcoff_copy_private_bfd_data,
3135         xcoff_is_local_label_name, xcoff_rtype2howto,
3136         xcoff_reloc_type_lookup, xcoff_slurp_armap, xcoff_archive_p,
3137         xcoff_read_ar_hdr, xcoff_openr_next_archived_file, xcoff_write_armap,
3138         xcoff_write_archive_contents): No longer static, and prefix with _bfd_.
3139         (NO_COFF_SYMBOLS): Define.
3140         (xcoff64_swap_sym_in, xcoff64_swap_sym_out, xcoff64_swap_aux_in,
3141         xcoff64_swap_aux_out): New functions; handle xcoff symbol tables
3142         internally.
3143         (MINUS_ONE): New macro.
3144         (xcoff_howto_tabl, xcoff_reloc_type_lookup): Add 64 bit POS
3145         relocation.
3146         (coff_SWAP_sym_in, coff_SWAP_sym_out, coff_SWAP_aux_in,
3147         coff_SWAP_aux_out): Map to the new functions.
3148         * coff64-rs6000.c: New file.
3149         * libcoff.h (bfd_coff_backend_data): Add new fields
3150         _bfd_coff_force_symnames_in_strings and
3151         _bfd_coff_debug_string_prefix_length.
3152         (bfd_coff_force_symnames_in_strings,
3153         bfd_coff_debug_string_prefix_length): New macros for above fields.
3154         * coffcode.h (coff_set_arch_mach_hook): Handle XCOFF64 magic.
3155         Set machine to 620 for XCOFF64.  Use bfd_coff_swap_sym_in instead
3156         of using coff_swap_sym_in directly.
3157         (FORCE_SYMNAMES_IN_STRINGS): New macro, defined for XCOFF64.
3158         (coff_set_flags) Set magic for XCOFF64.
3159         (coff_compute_section_file_positions): Add symbol name length to
3160         string section length if bfd_coff_debug_string_prefix_length is
3161         true.
3162         (coff_write_object_contents): Don't do reloc overflow for XCOFF64.
3163         (coff_slurp_line_table): Use bfd_coff_swap_lineno_in instead of
3164         using coff_swap_lineno_in directly.
3165         (bfd_coff_backend_data): Add _bfd_coff_force_symnames_in_strings
3166         and _bfd_coff_debug_string_prefix_length fields.
3167         * coffgen.c (coff_fix_symbol_name, coff_write_symbols): Force
3168         symbol names into strings table when
3169         bfd_coff_force_symnames_in_strings is true.
3170         * coffswap.h (MAX_SCNHDR_NRELOC, MAX_SCNHDR_NLNNO, GET_RELOC_VADDR,
3171         SET_RELOC_VADDR): New macros.
3172         (coff_swap_reloc_in, coff_swap_reloc_out): Use above macros.
3173         (coff_swap_aux_in, coff_swap_aux_out): Remove RS6000COFF_C
3174         code.
3175         (coff_swap_aouthdr_in, coff_swap_aouthdr_out): Handle XCOFF64
3176         changes within RS6000COFF_C specific code.
3177         (coff_swap_scnhdr_out): Use PUT_SCNHDR_NLNNO, PUT_SCNHDR_NRELOC,
3178         MAX_SCNHDR_NRELOC, and MAX_SCNHDR_NLNNO.
3179         * reloc.c (bfd_perform_relocation, bfd_install_relocation):
3180         Extend existing hack on target name.
3181         * xcofflink.c (XCOFF_XVECP): Extend existing hack on
3182         target name.
3183         * coff-tic54x.c (ticof): Keep up to date with new fields
3184         in bfd_coff_backend_data.
3185         * config.bfd: Add bfd_powerpc_64_arch to targ_arch and define
3186         targ_selvecs to include rs6000coff64_vec for rs6000.
3187         * configure.in: Add rs6000coff64_vec case.
3188         * cpu-powerpc.c: New bfd_arch_info_type.
3189
3190 2000-04-24  Jeffrey A Law  (law@cygnus.com)
3191
3192         * config.bfd: Only disable elf32-hppa vectors, not all of the
3193         BSD and OSF configuration support.  Provide (disabled) clauses
3194         for PA64 support.
3195         * configure.in: Add clause for PA64 support.
3196         * configure: Rebuilt.
3197
3198         * targets.c (bfd_target_vector): Add bfd_elf64_hppa_vec.
3199         (bfd_elf64_hppa_vec): Declare.
3200
3201         * Makefile.am (BFD64_BACKENDS): Add elf64-hppa.lo
3202         (BFD64_BACKENDS_CFILES): Add elf64-hppa.c
3203         (elf64-hppa.lo): Add dependencies.
3204         * Makefile.in: Rebuilt.
3205
3206         * elf64-hppa.c, elf64-hppa.h: New files with PA64 support.
3207
3208 2000-04-24  Jason Eckhardt  <jle@cygnus.com>
3209
3210         * libhppa.h (dis_assemble_16): New function.
3211         (pa_arch): Added pa20w element.
3212
3213 2000-04-24  Ulrich Drepper  <drepper@cygnus.com>
3214
3215         * elf-bfd.h: Add prototypes for bfd_elf32_write_relocs,
3216         bfd_elf32_slurp_reloc_table, bfd_elf64_write_relocs, and
3217         bfd_elf64_slurp_reloc_table.
3218
3219         * elfcode.h (elf_write_relocs, elf_slurp_reloc_table): New
3220         definitions to get external names.
3221         (elf_write_relocs): Renamed from write_relocs and make global.
3222         (elf_slurp_reloc_table): Make global.
3223         (_bfd_elf,size_info): Use elf_write_relocs instead of write_relocs.
3224
3225         * archive.c (hpux_uid_gid_encode): New function.
3226         (bfd_ar_hdr_from_filesystem): Use it if HPUX_LARGE_AR_IDS is
3227         defined and the ID is greater than 99999.
3228         (bfd_generic_stat_arch_elt): If HPUX_LARGE_AR_IDS is defined decode
3229         special uid/gid fields into 32 bit values.
3230
3231 2000-04-21  Matthew Green  <mrg@cygnus.com>
3232
3233         * config.bfd: Add NetBSD/sparc64 support.
3234
3235 Fri Apr 21 13:20:53 2000  Richard Henderson  <rth@cygnus.com>
3236                           David Mosberger  <davidm@hpl.hp.com>
3237                           Timothy Wall <twall@cygnus.com>
3238                           Jim Wilson  <wilson@cygnus.com>
3239
3240         * Makefile.am (ALL_MACHINES): Add cpu-ia64.lo.
3241         (ALL_MACHINES_CFILES): Add cpu-ia64.c.
3242         (BFD64_BACKENDS): Add elf64-ia64.lo.
3243         (BFD64_BACKENDS_CFILES): Add elf64-ia64.c.
3244         (cpu-ia64.lo, elf64-ia64.lo): New rules.
3245         * Makefile.in: Rebuild.
3246         * archures.c (enum bfd_architecture): Add bfd_arch_ia64.
3247         (bfd_ia64_arch): Declare.
3248         (bfd_archures_list): Add bfd_ia64_arch.
3249         * bfd-in2.h: Rebuild.
3250         * config.bfd: (ia64*-*-linux-gnu*, ia64*-*-elf*): New targets.
3251         * configure: Rebuild.
3252         * configure.host: (ia64-*-linux*): New host.
3253         * configure.in (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec,
3254         bfd_efi_app_ia64_vec, bfd_efi_app_ia64_vec): New vectors.
3255         * elf.c (prep_headers): Add bfd_arch_ia64.
3256         * libbfd.h: Rebuild.
3257         * reloc.c: Add IA-64 relocations.
3258         * targets.c (bfd_elf64_ia64_little_vec, bfd_elf64_ia64_big_vec):
3259         Declare.
3260         (bfd_target_vect): Add bfd_elf64_ia64_little_vec.
3261         * cpu-ia64-opc.c, cpu-ia64.c, elf64-ia64.c: New files.
3262
3263 2000-04-21  Richard Henderson  <rth@cygnus.com>
3264
3265         * elf32-d30v.c (bfd_elf_d30v_reloc): Don't modify section
3266         contents when performing a partial link.
3267         (bfd_elf_d30v_reloc_21): Likewise.
3268
3269 2000-04-20  H.J. Lu  <hjl@gnu.org>
3270
3271         * elf32-i386.c (elf_i386_relocate_section): Restrict 1998-12-10
3272         patch to symbols defined by a shared object.
3273         * elf32-ppc.c (ppc_elf_relocate_section): Similarly.
3274
3275 2000-04-19  Michael Sokolov  <msokolov@ivan.Harhan.ORG>
3276
3277         K&R compiler fixes.
3278         * dwarf2.c (concat_filename): Avoid string literal concatenation.
3279         * ieee.c (ieee_get_symtab): Don't initialise union in struct.
3280
3281 Mon Apr 17 19:14:36 2000  David Mosberger  <davidm@hpl.hp.com>
3282
3283         * Makefile.am (BFD64_BACKENDS): Mention coff-ia64.lo.
3284         (BFD64_BACKENDS_CFILES): Mention coff-ia64.c
3285         (coff-ia64.lo): Add dependency.
3286         * Makefile.in: Regenerate.
3287         * coff-ia64.c: New file.
3288         * efi-app-ia32.c: Ditto.
3289         * efi-app-ia64.c: Ditto.
3290         * coffcode.h (coff_set_arch_mach_hook): Handle IA64MAGIC.
3291         (coff_set_flags): Ditto.
3292         (coff_write_object_contents) [IA64]: Set magic number to ZMAGIC.
3293         * config.bfd (i[3456]86-*-linux-gnu*): Mention bfd_efi_app_ia32_vec.
3294         * configure.in (elf): Handle bfd_efi_app_ia32 and bfd_efi_app_ia64_vec.
3295         * configure: Regenerate.
3296         * libpei.h (GET_OPTHDR_IMAGE_BASE): New macro.
3297         (PUT_OPTHDR_IMAGE_BASE): Ditto.
3298         (GET_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
3299         (PUT_OPTHDR_SIZE_OF_STACK_RESERVE): Ditto.
3300         (GET_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
3301         (PUT_OPTHDR_SIZE_OF_STACK_COMMIT): Ditto.
3302         (GET_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
3303         (PUT_OPTHDR_SIZE_OF_HEAP_RESERVE): Ditto.
3304         (GET_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
3305         (PUT_OPTHDR_SIZE_OF_HEAP_COMMIT): Ditto.
3306         (GET_PDATA_ENTRY): Ditto.
3307         * peigen.c (_bfd_pei_swap_aouthdr_in) [COFF_WITH_PEP64]: Don't read
3308         data_start.  Use above macros to read fields that are 64 bit wide for
3309         COFF_WITH_PEP64.  Don't truncate entry and text_start to 32 bits.
3310         (_bfd_pei_swap_aouthdr_out) [PEI_FORCE_MINIMUM_ALIGNMENT]: Force
3311         FileAlignment and SectionAlignment to minimum alignment if they
3312         are zero.
3313         (_bfd_pei_swap_aouthdr_out) [PEI_DEFAULT_TARGET_SUBSYSTEM]: Set
3314         Subsystem to default PEI_DEFAULT_TARGET_SUBSYSTEM.
3315         (_bfd_pei_swap_aouthdr_out) [COFF_WITH_PEP64]: Don't set data_start.
3316         Use above macros to write fields that are 64 bit wide for
3317         COFF_WITH_PEP64.
3318         (pe_print_pdata): Set PDATA_ROW_SIZE to 3*8 for COFF_WITH_PEP64,
3319         5*4 otherwise.  This should be right for IA-32 and IA-64, but may
3320         be wrong for platforms.  Use PDATA_ROW_SIZE instead of hardcoded
3321         value of 20 bytes.  Modify printing for COFF_WITH_PEP64 to print
3322         begin address, end address, and unwind info address only.  Use
3323         GET_PDATA_ENTRY() to read .pdata entries.  Use fprintf_vma() to
3324         print addresses.
3325         (tbl): Add SECTION, REL32, RESERVED1, MIPS_JMPADDR16, DIR64, and
3326         HIGH3ADJ relocation names.
3327         (_bfd_pe_print_private_bfd_data): Print Subsystem name in legible form.
3328         * targets.c: Declare bfd_efi_app_ia32_vec and
3329         bfd_efi_app_ia64_vec.
3330         (bfd_target_vector): Mention bfd_efi_app_ia32_vec and
3331         bfd_efi_app_ia64_vec.
3332
3333 2000-04-17  Timothy Wall  <twall@cygnus.com>
3334
3335         * bfd-in2.h: Add prototypes for tic54x load page access.
3336         * bfd-in.h: Regenerate.
3337         * coff-tic54x.c: Add load page functions; allow bfd_arch_unknown
3338         in customized _set_arch_mach function.
3339         * coffcode.h (coff_set_alignment_hook): Set section load page if
3340         the appropriate macro is defined.
3341         (write_object_contents): Read section load page.
3342
3343 2000-04-13  Alan Modra  <alan@linuxcare.com.au>
3344
3345         * elf32-hppa.h: Update copyright date.
3346
3347         * elf32-fr30.c (fr30_elf_i20_reloc): Don't use U suffix.
3348         * elf32-mips.c (_bfd_mips_elf_relocate_section): And here.
3349
3350         * elf32-d30v.c (MAX32): Don't use LL suffix.
3351         (MIN32): Define in terms of MAX32.
3352         (bfd_elf_d30v_reloc): Make relocation a bfd_signed_vma.
3353
3354         * coff-a29k.c (SIGN_EXTEND_HWORD): Replace with more concise
3355         expression.
3356
3357         * peicode.h (pe_ILF_build_a_bfd): Remove UL from hex constants.
3358
3359 2000-04-12  Alan Modra  <alan@linuxcare.com.au>
3360
3361         * dep-in.sed: Match space before file name, not after.
3362         * Makefile.am: Regenerate dependencies.
3363         * Makefile.in: Regenerate.
3364
3365         * reloc.c (_bfd_relocate_contents): In complain_overflow_bitfield
3366         case, allow address wrap-around stupidly removed 2000-03-17.  Sign
3367         extend without an if statement.
3368
3369 2000-04-11  Alan Modra  <alan@linuxcare.com.au>
3370
3371         * coff-mips.c (mips_gprel_reloc): Test for 16 bit range using
3372         signed quantites.
3373         * elf32-mips.c (gprel16_with_gp): Likewise.
3374         * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Test range
3375         here using -0x40000, not (int)0xfffc0000.
3376         (elf32_hppa_size_of_stub): Likewise.
3377
3378 2000-04-11  Timothy Wall  <twall@cygnus.com>
3379
3380         * coff-tic54x.c: Now builds with all targets.
3381         * Makefile.am: Add coff/tic54x.h to coff-tic54x.o dependencies.
3382         * Makefile.in: Regenerate.
3383         * coffcode.h (coff_set_arch_mach_hook): Eliminate warning on
3384         unitialized variable.
3385
3386 Fri Apr  7 15:56:57 2000  Andrew Cagney  <cagney@b1.cygnus.com>
3387
3388         * configure.in (WARN_CFLAGS): Set to -W -Wall by default.  Add
3389         --enable-build-warnings option.
3390         * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
3391         * Makefile.in, configure: Re-generate.
3392
3393 2000-04-07  Nick Clifton  <nickc@cygnus.com>
3394
3395         * reloc.c: Add BFD_RELOC_ARM_PCREL_BLX and
3396         BFD_RELOC_THUMB_PCREL_BLX.
3397
3398         * elf32-arm.h (elf32_arm_final_link_relocate): Handle
3399         R_ARM_XPC25 and R_ARM_THM_PC22.
3400
3401         * elfarm-nabi.c (elf32_arm_howto_): Fix definitions of
3402         R_ARM_XPC25 and R_ARM_THM_XPC22.
3403         (elf32_arm_reloc_map): Make BFD_RELOC_{ARM|THUMB}_PCREL_BLX to
3404         R_ARM_[XPC25|THM_XPC22].
3405
3406         * elfarm-oabi.c: Define OLD_ARM_ABI and change include from
3407         elf/arm-oabi.h to elf/arm.h
3408
3409         * Makefile.am: Fix dependency for elfarm-oabi.c
3410         * Makefile.in: Regenerate.
3411
3412         * bfd-in2.h: Regenerate.
3413         * libbfd.h: Regenerate.
3414
3415 2000-04-06  Michael Snyder  <msnyder@seadog.cygnus.com>
3416
3417         * elfcore.h (elf_core_file_p): preserve value of tdata at entry,
3418         and restore it on failure.  Release newly allocated tdata on
3419         failure.
3420
3421 Fri Apr  7 11:33:47 2000  Jim Wilson  <wilson@cygnus.com>
3422
3423         * dwarf2.c (struct dwarf2_debug): New field dwarf_line_size.
3424         (decode_line_info): Set it.  Report error if unit->line_offset is
3425         equal to or larger than it.
3426
3427 2000-04-07  Timothy Wall  <twall@cygnus.com>
3428
3429         * targets.c: Added vecs for tic54x.
3430         * reloc.c: Added relocs for tic54x.
3431         * libbfd.h: Regenerated.
3432         * configure: Add TI COFF vecs for tic54x.
3433         * configure.in: Ditto.
3434         * config.bfd (targ_cpu): Recognize new tic54x target.
3435         * coffcode.h (coff_slurp_symbol_table): Additions for TI COFF handling.
3436         * bfd-in2.h: Add tic54x target and relocations.
3437         * Makefile.am, Makefile.in: Add tic54x target.
3438         * archures.c (bfd_archures_list): Add tic54x target.
3439         * coff-tic54x.c: New.
3440         * cpu-tic54x.c: New.
3441
3442 2000-04-06  Michael Snyder  <msnyder@seadog.cygnus.com>
3443
3444         * elfcore.h (elf_core_file_p): call backend_object_p which
3445         thereby gets an opportunity to update the arch/machine type.
3446
3447 2000-04-06  Timothy Wall  <twall@cygnus.com>
3448
3449         * coffcode.h (coff_slurp_symbol_table): Handle C_STATLAB storage
3450         class.  Handle SEC_CLINK and SEC_BLOCK flags.
3451         * section.c: Add SEC_CLINK and SEC_BLOCK flags.
3452         * bfd-in2.h: Add SEC_CLINK and SEC_BLOCK flags.
3453
3454 2000-04-06  Nick Clifton  <nickc@cygnus.com>
3455
3456         * elf32-arm.h (elf32_arm_set_private_flags): Only check for
3457         EF_INTERWORK if this is an unknown EABI.
3458         (elf32_arm_merge_private_bfd_data): Check EABI version
3459         numbers.  Only check EF_xxx flags if the EABI version number
3460         is unknown.
3461         (elf32_arm_check_private_bfd_data): Only check EF_xxx flags
3462         if the EABI version number is unknown.
3463         (elf32_arm_print_private_bfd_data): Only decode EF_xxx flags
3464         if the EABI version number is unknown.
3465
3466 Wed Apr  5 22:04:20 2000  J"orn Rennecke <amylaar@cygnus.co.uk>
3467
3468         * reloc.c (_bfd_relocate_contents): Add BFD_RELOC_SH_LOOP_START and
3469         BFD_RELOC_SH_LOOP_END.
3470         * elf32-sh.c (sh_elf_howto_tab): Change special_func to
3471         sh_elf_ignore_reloc for all entries that sh_elf_reloc used to ignore.
3472         Add entries for R_SH_LOOP_START and R_SH_LOOP_END.
3473         (sh_elf_reloc_loop): New function.
3474         (sh_elf_reloc): No need to test for always-to-be-ignored relocs
3475         any more.
3476         (sh_rel): Add entries for BFD_RELOC_SH_LOOP_{START,END}.
3477         (sh_elf_relocate_section): Handle BFD_RELOC_SH_LOOP_{START,END}.
3478         * bfd-in2.h, libbfd.h: Regenerate.
3479
3480 2000-04-04  Alan Modra  <alan@linuxcare.com.au>
3481
3482         * po/bfd.pot: Regenerate.
3483
3484         * Makefile.am: Remove extraneous mkdep comment.
3485         (MKDEP): Use gcc -MM rather than mkdep.
3486         (DEP): Quote when passing vars to sub-make.  Add warning
3487         message to end.
3488         (DEP1): Rewrite for "gcc -MM".
3489         (CLEANFILES): Add DEP2.
3490         Update dependencies.
3491         * Makefile.in: Regenerate.
3492
3493 2000-04-03  Kevin Buettner  <kevinb@redhat.com>
3494
3495         * configure.in: Added corefile support for AIX 4.3.  In particular,
3496         AIX_CORE_DUMPX_CORE will be defined in addition to AIX_CORE when
3497         compiling rs6000-core.c.
3498         * configure: Regenerated.
3499
3500 2000-04-03  H.J. Lu  <hjl@gnu.org>
3501
3502         * cache.c (bfd_open_file): Unlink the output file only if
3503         it has non-zero size.
3504
3505 2000-04-01  Ken Block USG  <block@zk3.dec.com>
3506
3507         * elf64-alpha.c (elf64_alpha_relocate_section): Don't emit
3508         relative relocations for non-loaded sections in shared objects.
3509         (elf64_alpha_check_relocs): Similarly.
3510
3511 Mon Apr  3 13:37:15 2000  Hans-Peter Nilsson  <hp@axis.com>
3512
3513         * aoutx.h (NAME(aout,reloc_type_lookup)): Add BFD_RELOC_8 and
3514         BFD_RELOC_16 to switch for extended relocs.
3515         (MY_swap_ext_reloc_in): New.
3516         (MY_swap_ext_reloc_out): New.
3517         (NAME(aout,slurp_reloc_table)): Use MY_swap_ext_reloc_in rather
3518         than NAME(aout,swap_ext_reloc_in) for extended relocs.
3519         (NAME(aout,squirt_out_relocs)): Similarly use
3520         MY_swap_ext_reloc_out.
3521         (aout_link_reloc_link_order): Use MY_put_ext_reloc if defined.
3522
3523 2000-04-03  Kazu Hirata  <kazu@hxi.com>
3524
3525         * coff-h8300.c (h8300_reloc16_extra_cases): Add bsr:16 -> bsr:8 to
3526         the R_PCRWORD_B case.
3527
3528 2000-03-31  Thomas de Lellis  <tdel@wrs.com>
3529
3530         * srec.c : Set CHUNK size to 16 bytes to prevent download failures
3531         on some targets.
3532         * ihex.c : Ditto.
3533
3534 Wed Mar 30 15:28:00 2000  Donald Lindsay  <dlindsay@cygnus.com>
3535
3536         * elf32-m32r.c (m32r_elf_generic_reloc): new function.  All
3537         HOWTO references to bfd_elf_generic_reloc, that have
3538         partial_inplace == true, now use the new function.  The function
3539         is based on the recent rewrite of m32r_elf_lo16_reloc(), and
3540         extends its fixes to the R_M32R_{16,24,32} relocs.
3541         The new logic in m32r_elf_lo16_reloc() has been removed, and
3542         it instead calls the new routine to obtain that functionality.
3543
3544 2000-03-27  Alan Modra  <alan@linuxcare.com.au>
3545
3546         * elf32-avr.c (elf32_avr_gc_mark_hook, elf32_avr_gc_sweep_hook,
3547         elf32_avr_check_relocs, avr_final_link_relocate,
3548         elf32_avr_relocate_section, bfd_elf_avr_final_write_processing,
3549         elf32_avr_object_p): Add prototypes.
3550         (elf32_avr_gc_mark_hook): Add default for h->root.type.
3551         (bfd_elf_avr_final_write_processing): Make static.
3552
3553 2000-03-27  Denis Chertykov  <denisc@overta.ru>
3554
3555         * cpu-avr.c: New file.  BFD support routines for AVR architecture.
3556         * archures.c (bfd_architecture): Add AVR architecture.
3557         (bfd_archures_list): Add reference to AVR architecture info.
3558         * elf.c (prep_headers): Handle bfd_arch_avr.
3559         * reloc.c: Add various AVR relocation enums.
3560         * targets.c (bfd_elf32_avr_vec): Declare and add to target vector
3561         list.
3562         * Makefile.am: Add support for AVR elf.
3563         * configure.in: Likewise.
3564         * config.bfd: Likewise.
3565         * Makefile.in: Regenerate.
3566         * configure: This too.
3567         * bfd-in2.h: And this.
3568         * libbfd.h: And this.
3569
3570 2000-03-24  H.J. Lu  <hjl@gnu.org>
3571
3572         * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Add prototype.
3573         (elf64_alpha_find_reloc_at_ofs): Likewise.
3574
3575 2000-03-17  Alan Modra  <alan@linuxcare.com.au>
3576
3577         * reloc.c (bfd_check_overflow): In case complain_overflow_bitfield,
3578         flag an overflow if the bitfield is outside -2**n to 2**n-1.  The
3579         allowable range used to be -2**(n-1) to 2**n-1.
3580         * reloc.c (_bfd_relocate_contents): Same here.  Also replace
3581         "boolean overflow" with "bfd_reloc_status_type flag".
3582
3583 2000-03-14  Doug Evans  <dje@casey.transmeta.com>
3584
3585         * elf32-m32r.c (m32r_elf_lo16_reloc): Rewrite.
3586
3587 2000-03-14  Kazu Hirata  <kazu@hxi.com>
3588
3589         * reloc16.c (bfd_coff_reloc16_relax_section): Count the total number
3590         of shrinks properly, including the last reloc.
3591
3592 2000-03-13  Kazu Hirata  <kazu@hxi.com>
3593
3594         * coff-h8300.c (h8300_reloc16_extra_cases): Fix the sanity
3595         check for R_MOVL2.
3596
3597 2000-03-11  Alan Modra  <alan@linuxcare.com.au>
3598
3599         * ieee.c (ieee_archive_p): Return bfd_error_wrong_format on
3600         a format mismatch rather than an "error" from bfd_read such as
3601         bfd_error_file_truncated.
3602
3603 2000-03-10  Geoff Keating  <geoffk@cygnus.com>
3604
3605         * elf32-mips.c (_bfd_mips_elf_relocate_section): Do proper
3606         sign-extension and big-endian compensation for
3607         R_MIPS_64 even in ld -r.
3608
3609 2000-03-10  Geoffrey Keating  <geoffk@cygnus.com>
3610
3611         * elf32-mips.c (mips_elf_next_relocation): Rename from
3612         mips_elf_next_lo16_relocation, and generalize to look
3613         for any relocation type.
3614         (elf_mips_howto_table): Make R_MIPS_PC16 pcrel_offset.
3615         (elf_mips_gnu_rel_hi16): Howto for R_MIPS_GNU_REL_HI16.
3616         (elf_mips_gnu_rel_lo16): Howto for R_MIPS_GNU_REL_LO16.
3617         (elf_mips_gnu_rel16_s2): Howto for R_MIPS_GNU_REL16_S2.
3618         (elf_mips_gnu_pcrel64): Howto for R_MIPS_PC64.
3619         (elf_mips_gnu_pcrel32): Howto for R_MIPS_PC32.
3620         (bfd_elf32_bfd_reloc_type_lookup): Add new relocs.
3621         (mips_rtype_to_howto): Likewise.
3622         (mips_elf_calculate_relocation): Handle new relocs.
3623         (_bfd_mips_elf_relocate_section): REL_HI16/REL_LO16 relocs
3624         are paired.  The addend for R_MIPS_GNU_REL16_S2
3625         is shifted right two bits.
3626
3627 2000-03-10  Alan Modra  <alan@linuxcare.com.au>
3628
3629         * reloc.c (bfd_perform_relocation): Undo emacs formatting of
3630         comment, and ensure it doesn't happen again.
3631         (bfd_install_relocation): Same here.
3632         (_bfd_relocate_contents): Don't bother assigning unused signmask
3633         shift result.  Fix typos in comments.
3634         Remove trailing whitespace throughout file.
3635
3636 2000-03-07  Doug Evans  <dje@casey.transmeta.com>
3637
3638         * reloc.c (reloc_howto_struct): Fix partial_inplace comment.
3639         * bfd-in2.h: Rebuild.
3640
3641 2000-03-06  Nick Clifton  <nickc@cygnus.com>
3642
3643         * peicode.h (struct pe_ILF_vars): Add sym_ptr_table and
3644         sym_ptr_ptr fields.
3645         (SIZEOF_ILF_SYM_PTR_TABLE): Define.
3646         (SIZEOF_ILF_STRINGS): Redefine.
3647         (pe_ILF_make_a_symbol-reloc): New function.  Creates a symbol
3648         relative reloc, as opposed to a section relative reloc.
3649         (pe_ILF_make_a_symbol): Set the class of local symbols to C_STAT
3650         not C_LABEL.
3651         Add length of symbol's prefix to string pointer.
3652         Store a pointer to the symbol in the symbol pointer table.
3653         (pe_ILF_build_a_bfd): Do not build .idata$2 or .idata$7.
3654         Initialise the symbol pointer table.
3655         Store the hint in the Hint/Name table.
3656         Make the jump reloc be symbol realtive, not section relative.
3657         Create an import symbol for imported code.
3658
3659 2000-03-06  Catherine Moore  <clm@cygnus.com>
3660
3661         * elf.c (swap_out_syms):  Check for null type_ptr.
3662
3663 2000-03-01  Hans-Peter Nilsson  <hp@axis.com>
3664
3665         * aout-target.h (MY(write_object_contents)): Remove unused
3666         and unusable "#if CHOOSE_RELOC_SIZE".
3667         * pc532-mach.c (MY(write_object_contents)): Ditto.
3668         * netbsd.h (MY(write_object_contents)): Ditto.
3669         * hp300hpux.c (MY(write_object_contents)): Ditto.
3670         * freebsd.h (MY(write_object_contents)): Ditto.
3671         * aout-tic30.c (tic30_aout_write_object_contents): Ditto.
3672
3673 2000-02-29  H.J. Lu  <hjl@gnu.org>
3674
3675         * peicode.h (jtab): Make it static.
3676
3677         * coff-sh.c (sh_align_load_span): Declared if COFF_WITH_PE is
3678         defined and COFF_IMAGE_WITH_PE is not defined.
3679         (_bfd_sh_align_load_span): Defined as sh_align_load_span if
3680         COFF_WITH_PE is defined and COFF_IMAGE_WITH_PE is not defined.
3681
3682 2000-03-01  Nick Clifton  <nickc@cygnus.com>
3683
3684         * coff-arm.c (bfd_arm_process_before_allocation): Make
3685         'symndx' signed to prevent compile time warning.
3686
3687         * coff-mcore.c: Remove unused prototype for pe_object_p.
3688
3689         * coff-sh.c: Add "#ifndef COFF_IMAGE_WITH_PE" around static
3690         functions that are not used when COFF_IMAGE_WITH_PE is
3691         defined.
3692         (struct sh_opcode): Change type of 'flags' field to unsigned
3693         long so that it can hold the USESAS flag.
3694
3695         * coffcode.h (styp_to_sec_flags): Initialise 'target_name'.
3696
3697         * elf-m10300.c (mn10300_elf_relax_section): Initialise
3698         'sym_sec'.
3699
3700         * elf32-i370.c: Add ATTRIBUTE_UNUSED to unused function
3701         parameters.
3702         Remove unusued variables and code.
3703         (elf_backend_add_symbol_hook): Fix prototype.
3704
3705         * elf32-m68k.c (elf_m68k_gc_sweep_hook): Initialise 'sgot' and
3706         'srelgot'.
3707
3708         * elf32-mcore.c (mcore_elf_relocate_section): Initialise
3709         'oldinst'.
3710
3711         * elf32-mips.c: Add ATTRIBUTE_UNUSED to unused function
3712         parameters.
3713         Remove unusued variables and code.
3714         (elf_backend_add_symbol_hook): Fix prototype.
3715
3716         * elf32-sh.c (sh_elf_set_mach_from_flags): Use 'flags'.
3717
3718         * elflink.h (elf_bfd_link_add_symbols): Add ATTRIBUTE_UNUSED
3719         to unused function parameter.
3720
3721         * pe-mips.c: Add ATTRIBUTE_UNUSED to unused function
3722         parameters.
3723         Use EMPTY_HOWTO to initialise empty howto slots.
3724         Remove unused variables.
3725
3726         * peicode.h (pe_ILF_build_a_bfd): Initialise id6.
3727
3728 2000-03-01  H.J. Lu  <hjl@gnu.org>
3729
3730         * aoutx.h (aout_link_input_section_std): Pass "true" to
3731         the undefined_symbol callback.
3732         (aout_link_input_section_ext): Likewise.
3733         * bout.c (get_value): Likewise.
3734         * coff-a29k.c (coff_a29k_relocate_section): Likewise.
3735         * coff-alpha.c (alpha_ecoff_get_relocated_section_conten):
3736         Likewise.
3737         (alpha_relocate_section): Likewise.
3738         * coff-arm.c (coff_arm_relocate_section): Likewise.
3739         * coff-i960.c (coff_i960_relocate_section): Likewise.
3740         * coff-mcore.c (coff_mcore_relocate_section): Likewise.
3741         * coff-mips.c (mips_relocate_section): Likewise.
3742         * coff-ppc.c (coff_ppc_relocate_section): Likewise.
3743         * coff-sh.c (sh_relocate_section): Likewise.
3744         * coff-tic80.c (coff_tic80_relocate_section): Likewise.
3745         * cofflink.c (_bfd_coff_generic_relocate_section): Likewise.
3746         * elf-m10200.c (mn10200_elf_relocate_section): Likewise.
3747         * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
3748         * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
3749         * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
3750         * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
3751         * elf32-i370.c (i370_elf_relocate_section): Likewise.
3752         * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
3753         * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
3754         * elf32-sh.c (sh_elf_relocate_section): Likewise.
3755         * elf32-v850.c (v850_elf_relocate_section): Likewise.
3756         * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
3757         * elflink.h (elf_link_output_extsym): Likewise.
3758         * pe-mips.c (coff_pe_mips_relocate_section): Likewise.
3759         * reloc.c (bfd_generic_get_relocated_section_conten): Likewise.
3760         * reloc16.c (_bfd_ppc_xcoff_relocate_section): Likewise.
3761
3762         * elf-hppa.h (elf_hppa_relocate_section): Pass "false" to the
3763         undefined_symbol callback when building shared library with
3764         -Bsymbolic and undefined symbols are allowed. Otherwise, pass
3765         "true".
3766         * elf32-arm.h (elf32_arm_relocate_section): Likewise.
3767         * elf32-i386.c (elf_i386_relocate_section): Likewise.
3768         * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
3769         * elf32-mips.c (mips_elf_calculate_relocation): Likewise.
3770         (elf32_mips_get_relocated_section_content): Likewise.
3771         * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
3772         * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
3773         * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
3774         * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
3775
3776 2000-02-28  Nick Clifton  <nickc@cygnus.com>
3777
3778         * Makefile.am: Add rules to build pe[i]-{sh|mips}.lo objects.
3779         * Makefile.in: Regenerate.
3780
3781         * configure.in: Add support for mips and sh pe vectors.
3782         * configure: regenerate.
3783
3784         * config.bfd: Add support for arm-wince, mips-pe and sh-pe
3785         targets.
3786
3787         * targets.c: Add mips and sh pe vectors.
3788
3789         * libpei.h (coff_final_link_postscript): Only define if not
3790         already defined.
3791
3792         * coffcode.h: Add support for WinCE magic numbers.
3793
3794         * peigen.c (pe_print_reloc): Update comment and rearrange
3795         appending of newline character.
3796
3797         * peicode.h: Add support for Image Library Format.
3798         (pe_ILF_vars): Structure containing data used by ILF code.
3799         (pe_ILF_make_a_section): New function.  Create a section based
3800         on ILF data.
3801         (pe_ILF_make_a_reloc): New function.  Create a reloc based on
3802         ILF data.
3803         (pe_ILF_make_a_symbol): New function.  Create a symbol based
3804         on ILF data.
3805         (pe_ILF_save_relocs): New function.  Store the relocs created
3806         by pe_ILF_make_a_reloc in a section.
3807         (pe_ILF_build_a_bfd): New function.  Create a BFD describing
3808         an ILF object.
3809         (pe_ILF_object_p): New function.  Return a bfd_target pointer
3810         for an ILF object.
3811         (pe_bfd_object_p): If an ILF object is detected call
3812         pe_ILF_object_p on it.
3813
3814         * coff-arm.c: Add support for WinCE relocs which are different
3815         from normal ARM COFF relocs.
3816         * pe-arm.c: Unset TARGET_UNDERSCORE for a WinCE target.
3817
3818         * coff-sh.c: Add support for sh-pe target.
3819         * pe-sh.c: New file.  Support code for sh-pe target.
3820         * pei-sh.c: New file.  Support code for sh-pe target.
3821
3822         * pe-mips.c: New file.  Support code for mips-pe target.
3823         * pei-mips.c: New file.  Support code for mips-pe target.
3824
3825 2000-02-27  Jakub Jelinek  <jakub@redhat.com>
3826
3827         * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Don't bump
3828         architecture if the object causing the bump is dynamic.
3829         * elf64-sparc.c (sparc64_elf_merge_private_bfd_data): Likewise,
3830         and also don't it for memory ordering.
3831         (sparc64_elf_write_relocs): Take src_rela out of the loop.
3832
3833 2000-02-27  Ian Lance Taylor  <ian@zembu.com>
3834
3835         * dwarf2.c (read_abbrevs): Use _raw_size directly rather than
3836         calling bfd_get_section_size_before_reloc.
3837         (decode_line_info): Likewise.
3838         (_bfd_dwarf2_find_nearest_line): Likewise.
3839
3840 2000-02-27  Eli Zaretskii  <eliz@is.elta.co.il>
3841
3842         * Makefile.am (stamp-lib): Use $(LIBTOOL) --config to get the
3843         name of the libtool directory.
3844         * Makefile.in: Rebuild.
3845
3846 Fri Feb 25 18:39:26 2000  Rodney Brown (RodneyBrown@pmsc.com)
3847
3848         * som.c (SOM_HOWTO): Define.
3849         (som_hppa_howto_table): Use it.
3850
3851 2000-02-25  Alexandre Oliva  <oliva@lsd.ic.unicamp.br>
3852
3853         * config.bfd: Enable 64 bit support for GNU/Linux/sparc.
3854
3855         * config.bfd: Enable 64 bit support for Solaris7+/sparc.
3856
3857 2000-02-24  Catherine Moore  <clm@cygnus.com>
3858
3859         * som.c (som_misc_symbol_info):  Add field
3860         secondary_def.
3861         (som_bfd_derive_misc_symbol_info):  Initialize
3862         secondary_def.
3863         (som_build_and_write_symbol_table): Keep track
3864         of secondary_def field.
3865         (som_slurp_symbol_table): Set BSF_WEAK symbol flag
3866         if secondary_def field is set.
3867         (som_bfd_ar_write_symbol_stuff): Initialize
3868         secondary_def.
3869
3870 2000-02-23  Stephane Carrez  <stcarrez@worldnet.fr>
3871
3872         * dwarf2.c (read_address): Read 16-bits addresses.
3873         (parse_comp_unit): Accept addr_size == 2.
3874
3875 2000-02-23  Alan Modra  <alan@spri.levels.unisa.edu.au>
3876
3877         * bfd-in.h: Update copyright date.
3878
3879 2000-02-23  Linas Vepstas <linas@linas.org>
3880
3881         * cpu-i370.c: New file.
3882         * elf32-i370.c:  New file.
3883         * archures.c (enum bfd_architecture): Add bfd_arch_i370.
3884         (bfd_i370_arch): New.
3885         (bfd_archures_list): Add bfd_i370_arch.
3886         * elf.c (prep_headers): Add bfd_arch_i370.
3887         * Makefile.am: Add support for IBM 370 elf.
3888         * config.bfd: Likewise.
3889         * configure.in: Likewise.
3890         * libbfd.h (bfd_reloc_code_real_names): Likewise.
3891         * reloc.c (bfd_reloc_code_type): Likewise.
3892         * targets.c: Likewise.
3893
3894         * Makefile.in: Regenerate.
3895         * configure: Regenerate.
3896         * bfd-in2.h: Regenerate.
3897
3898 2000-02-22  Ian Lance Taylor  <ian@zembu.com>
3899
3900         * elf32-i386.c (elf_i386_info_to_howto_rel): Give a warning for
3901         invalid relocation types, and change them to R_386_NONE.
3902
3903 2000-02-22  H.J. Lu  <hjl@gnu.org>
3904
3905         * elflink.h (elf_link_add_object_symbols): If a version symbol is
3906         not defined, don't add a second ELF_VER_CHR.
3907
3908         * elflink.h (elf_bfd_final_link): Call output_extsym for global
3909         symbols converted to local symbols even when stripping all
3910         symbols.
3911         (elf_link_output_extsym): Process global symbols converted to
3912         local symbols even if they are being stripped.
3913
3914 2000-02-21  Alan Modra  <alan@spri.levels.unisa.edu.au>
3915
3916         * archures.c (bfd_octets_per_byte): Return unsigned int.
3917         (bfd_arch_mach_octets_per_byte): Ditto.
3918         * libbfd.c (bfd_read, bfd_seek): Quell signed vs. unsigned
3919         comparison warning.
3920         * section.c (bfd_get_section_size_before_reloc): Quell signed
3921         vs. unsigned comparison warning.
3922         (bfd_get_section_size_after_reloc): Same here.  Fix parentheses too.
3923         * trad-core.c (trad_unix_core_file_p): Correct 2000-01-27
3924         change.  What was I thinking?
3925         * bfd-in2.h: Regenerate.
3926
3927         * elflink.h (elf_gc_sweep): Skip non-elf input bfds.
3928         (elf_gc_sections): Same here.
3929         (elf_gc_common_finalize_got_offsets): And here.
3930
3931 2000-02-21  Ian Lance Taylor  <ian@zembu.com>
3932
3933         ELF HPPA doesn't work at present; remove it until it does.
3934         * config.bfd: Comment out setting targ_defvec to
3935         bfd_elf32_hppa_vec.
3936         * Makefile.am: Rebuild dependencies.
3937         (BFD32_BACKENDS): Remove elf32-hppa.lo.
3938         (BFD32_BACKENDS_CFILES): Remove elf32-hppa.c.
3939         (SOURCE_HFILES): Remove elf32-hppa.h and hppa_stubs.h.
3940         * Makefile.in: Rebuild.
3941         * targets.c (bfd_target_vector): Comment out bfd_elf32_hppa_vec.
3942
3943 2000-02-18  Geoff Keating  <geoffk@cygnus.com>
3944
3945         * coffcode.h (coff_set_arch_mach_hook): Use free(), because there
3946         is no bfd_free().  Revert bfd_free part of previous change.
3947
3948 2000-02-18  Geoff Keating  <geoffk@cygnus.com>
3949
3950         * coffcode.h (coff_set_arch_mach_hook): Don't use variable-size
3951         arrays.
3952         (coff_compute_section_file_positions): Use bfd_free to pair
3953         bfd_malloc.
3954         (coff_write_object_contents): Likewise.
3955
3956         * coff-rs6000.c (xcoff_howto_table_16): New variable.
3957         (xcoff_rtype2howto): Handle 16-bit variants of 32-bit relocs.
3958
3959 2000-02-18  Ulrich Drepper  <drepper@cygnus.com>
3960
3961         * coff-rs6000.c (XCOFFARMAGBIG): New macro.
3962         (xcoff_ar_file_hdr_big): New structure.
3963         (SIZEOF_AR_FILE_HDR_BIG): New macro.
3964         (xcoff_ar_hdr_big): New structure.
3965         (SIZEOF_AR_HDR_BIG): New macro.
3966         (xcoff_big_format_p): New macro.
3967         (xcoff_ardata_big): New macro.
3968         (arch_xhdr_big): New macro.
3969         (xcoff_slurp_armap): Handle large archives.
3970         (xcoff_archive_p): Detect large archives.
3971         (xcoff_read_ar_hdr): Handle large archives.
3972         (xcoff_openr_next_archived_file): Handle large archives.
3973         (xcoff_generic_stat_arch_elt): Handle large archives.
3974         (xcoff_write_armap_old): Rename from xcoff_write_armap.
3975         (xcoff_write_armap_big): New function.
3976         (xcoff_write_armap): New function, dispatch to _old or _big.
3977         (xcoff_write_archive_contents_old): Rename from
3978         xcoff_write_archive_contents.
3979         (xcoff_write_archive_contents_big): New function.
3980         (xcoff_write_archive_contents): New function, dispatch to _old or
3981         _big.
3982
3983 2000-02-18  Richard Henderson  <rth@cygnus.com>
3984
3985         * elf-bfd.h (struct elf_link_hash_table): Remove copy_indirect
3986         and hide_symbol members.
3987         (elf_link_hash_copy_indirect): Remove.
3988         (elf_link_hash_hide_symbol): Remove.
3989         (struct elf_backend_data): Add elf_backend_copy_indirect_symbol
3990         and elf_backend_hide_symbol.
3991         (_bfd_elf_link_hash_copy_indirect): Declare.
3992         (_bfd_elf_link_hash_hide_symbol): Declare.
3993         * elf.c (_bfd_elf_link_hash_copy_indirect): Remove table argument.
3994         (_bfd_elf_link_hash_hide_symbol): Likewise.
3995         (_bfd_elf_link_hash_table_init): Don't init killed members.
3996         * elflink.h (elf_link_add_object_symbols): Use the bed function
3997         pointers not elf_link_hash_{copy_indirect,hide_symbol}.
3998         (elf_link_assign_sym_version): Likewise.
3999         * elfxx-target.h (elf_backend_copy_indirect_symbol): Default.
4000         (elf_backend_hide_symbol): Likewise.
4001         (elfNN_bed): Update for new members.
4002
4003 2000-02-17  Kevin Buettner  <kevinb@redhat.com>
4004
4005         * rs6000-core.c (CORE_DATA_SIZE_FIELD, CORE_COMM_FIELD, SAVE_FIELD,
4006         STACK_END_ADDR): Define for new core file format.
4007         (LOADER_OFFSET_FIELD, LOADER_REGION_SIZE, CORE_DUMP): New defines
4008         for handling the vagaries of the various core file structures used
4009         by AIX over the years.
4010         (rs6000coff_core_p, rs6000coff_core_file_matches_executable,
4011         Rs6kCorData): Use above defines to adapt code to use AIX 4.3's
4012         core_dumpx structure.
4013
4014 Thu Feb 17 00:04:48 2000  J"orn Rennecke <amylaar@cygnus.co.uk>
4015
4016         * archures.c (bfd_mach_sh2, bfd_mach_sh_dsp): New macros.
4017         (bfd_mach_sh3_dsp): Likewise.
4018         (bfd_mach_sh4): Reinstate.
4019         (bfd_default_scan): Recognize 7410, 7708, 7729 and 7750.
4020         * bfd-in2.h: Regenerate.
4021         * coff-sh.c (struct sh_opcode): flags is no longer short.
4022         (USESAS, USESAS_REG, USESR8, SETSAS, SETSAS_REG): New macros.
4023         (sh_opcode41, sh_opcode42): Integrate as sh_opcode41.
4024         (sh_opcode01, sh_opcode02, sh_opcode40): Add sh-dsp opcodes.
4025         (sh_opcode41, sh_opcode4, sh_opcode80): Likewise.
4026         (sh_opcodes): No longer const.
4027         (sh_dsp_opcodef0, sh_dsp_opcodef): New arrays.
4028         (sh_insn_uses_reg): Check for USESAS and USESR8.
4029         (sh_insn_sets_reg, sh_insns_conflict): Check for SETSAS.
4030         (_bfd_sh_align_load_span): Return early for SH4.
4031         Modify sh_opcodes lookup table for sh-dsp / sh3-dsp.
4032         Take into account that field b of a parallel processing insn
4033         could be mistaken for a separate insn.
4034         * cpu-sh.c (arch_info_struct): New array elements for
4035         sh2, sh-dsp and sh3-dsp.
4036         Reinstate element for sh4.
4037         (SH2_NEXT, SH_DSP_NEXT, SH3_DSP_NEXT): New macros.
4038         (SH4_NEXT): Reinstate.
4039         (SH3_NEXT, SH3E_NEXT): Adjust.
4040         * elf-bfd.h (_sh_elf_set_mach_from_flags): Declare.
4041         * elf32-sh.c (sh_elf_set_private_flags): New function.
4042         (sh_elf_copy_private_data, sh_elf_set_mach_from_flags): Likewise.
4043         (sh_elf_merge_private_data): New function.
4044         (elf_backend_object_p, bfd_elf32_bfd_set_private_bfd_flags): Define.
4045         (bfd_elf32_bfd_copy_private_bfd_data): Define.
4046         (bfd_elf32_bfd_merge_private_bfd_data): Change to
4047         sh_elf_merge_private_data.
4048
4049 2000-02-13  Richard Henderson  <rth@cygnus.com>
4050
4051         * elf-bfd.h (struct elf_link_hash_table): Add copy_indirect and
4052         hide_symbol members.
4053         (elf_link_hash_copy_indirect): New.
4054         (elf_link_hash_hide_symbol): New.
4055         * elflink.h (elf_link_add_object_symbols): Break out copy from
4056         indirect new new symbol to elf.c.
4057         (elf_link_assign_sym_version): Break out privatization of
4058         non-exported symbol to elf.c.
4059         * elf.c (_bfd_elf_link_hash_copy_indirect): New.
4060         (_bfd_elf_link_hash_hide_symbol): New.
4061         (_bfd_elf_link_hash_table_init): Init copy_indirect and hide_symbol.
4062
4063 2000-02-13  Ian Lance Taylor  <ian@zembu.com>
4064
4065         * section.c (_bfd_strip_section_from_output): Add info parameter.
4066         If it passed as non-NULL, use it to check whether any input BFD
4067         has an input section which uses this output section.  Change all
4068         callers.
4069         * bfd-in2.h: Rebuild.
4070
4071         * bfd-in.h: Move declarations of bfd_get_elf_phdr_upper_bound and
4072         bfd_get_elf_phdrs in from bfd-in2.h, correcting patch of
4073         1999-11-29.
4074         * bfd-in2.h: Rebuild.
4075
4076 2000-02-10  Timothy Wall  <twall@cygnus.com>
4077
4078         * coffswap.h (coff_swap_sym_in): Add hook SWAP_SYM_IN_POST to
4079         allow final modifications of swapped-in symbol.
4080         (coff_swap_sym_out): Ditto with SWAP_SYM_OUT_POST.
4081         * coffcode.h (coff_write_relocs): Use macro
4082         SECTION_RELATIVE_ABSOLUTE_SYMBOL_P if defined to determine whether
4083         symbol index should be set to -1.
4084
4085 Thu Feb 10 20:07:50 GMT 2000  Toshiyasu Morita (toshi.morita@sega.com)
4086
4087         * coff-sh.c (USES1_REG, USES2_REG, SETS1_REG, SETS2_REG,
4088         USESF1_REG, USESF2_REG, SETSF1_REG, SETSF2_REG): New macros.
4089         * (sh_insn_sets_reg, sh_insn_sets_freg): New prototypes.
4090         * (sh_insn_sets_reg, sh_insn_uses_or_sets_reg, sh_insns_sets_freg,
4091         sh_insns_uses_or_sets_freg): New functions.
4092         * (sh_insn_uses_reg, sh_insn_uses_freg): Use new macros.
4093         * (sh_insns_conflict): Use new functions and new macros to
4094         detect conflicts when two instructions both set same integer registers,
4095         both set same fp register, and both set special register.
4096
4097 2000-02-09  Timothy Wall  <twall@cygnus.com>
4098
4099         * coffgen.c (coff_real_object_p): Set arch/mach info prior to
4100         swapping in sections, so that the swapping routines have access to
4101         the arch/mach info.
4102
4103 2000-02-08 Mark Elbrecht <snowball3@bigfoot.com>
4104
4105         * coff-go32.c: Update comment. Update copyright.
4106
4107 2000-01-27  Thomas de Lellis  <tdel@windriver.com>
4108
4109         * syms.c (bfd_decode_symclass)
4110         Two new class characters were added - 'V' and 'v'.  The
4111         meaning of 'W' is now restricted to just weak non-object
4112         symbols.  This allows differentiation between, for example,
4113         weak functions vs weak objects.  nm for example now dumps:
4114         'W' = weak global
4115         'w' = weak unresolved
4116         'V' = weak global object
4117         'v' = weak unresolved object
4118
4119         (bfd_is_undefined_symclass): New function.  Return true if the
4120         given symbol class represents and undefined/unresolved symbol.
4121
4122         (bfd_symbol_info): Use bfd_is_undefined_symclass to check for
4123         unresolved symbols.
4124
4125         * bfd-in2.h: Add prototype for bfd_is_undefined_symbol().
4126
4127         * elf32-arm.h (elf32_arm_get_symbol_type): If a symbol has the
4128         STT_ARM_16BIT flag set, but it is not attached to a data object
4129         return STT_ARM_16BIT so that it will be treated as code by the
4130         disassembler.
4131
4132 2000-01-27  Alan Modra  <alan@spri.levels.unisa.edu.au>
4133
4134         * coff-i386.c (i3coff_object_p): Remove prototype.
4135         Update copyright.
4136
4137         * elflink.c (_bfd_elf_link_record_dynamic_symbol): Add const
4138         to name.  Update copyright.
4139
4140         * trad-core.c (trad_unix_core_file_p): Cast core_regsec
4141         assignment to avoid warning.  Update copyright.
4142
4143 2000-01-24  Robert Lipe  (robertl@sco.com)
4144
4145         * coffcode.h (coff_write_object_contents): Get buff via bfd_malloc
4146         instead of using GNU C extension.
4147
4148 2000-01-21  Nick Clifton  <nickc@cygnus.com>
4149
4150         * libbfd.c (bfd_read): Do not attempt to get a negativly sized
4151         amount from a bfd_in_memory structure.
4152         (bfd_seek): Do not allow seeks past the end of a bfd_in_memory
4153         structure.
4154
4155 2000-01-14  Nick Clifton  <nickc@cygnus.com>
4156
4157         * linker.c (default_indirect_link_order): oops - fix incorrectly
4158         applied patch from Tim Wall.
4159
4160 2000-01-13  Timothy Wall (twall@tiac.net>
4161
4162         * coffcode.h: Use bfd_coff_xxx instead of the macro XXX (where xxx
4163         = scnhsz, filhsz, relsz, aoutsz, etc)
4164
4165         * coffswap.h: Ditto.
4166
4167 2000-01-13  Nick Clifton  <nickc@cygnus.com>
4168
4169         * elf32-arm.h (elf32_thumb_to_arm_stub): Fix offset in branch to
4170         interwork thumb to arm stub.
4171
4172 2000-01-13  Timothy Wall (twall@tiac.net>
4173
4174         * archures.c (bfd_octets_per_byte): New function: Return
4175         target byte size.
4176         (bfd_arch_mach_octets_per_byte): New function: Return target
4177         byte size.
4178
4179         * section.c: Distinguish between octets and bytes for usage of
4180         _cooked_size,  _raw_size, and output_offset.  Clarify
4181         description of bfd_set_section_contents.
4182
4183         * bfd-in2.h: Regenerate.
4184
4185         * coffgen.c: Indicate that the offset parameter is in bytes, not
4186         octets.
4187
4188         * cofflink.c (bfd_coff_link_input_bfd): Use bfd_octets_per_byte
4189         where appropriate to get the octet offset when calling
4190         bfd_set_section_contents.
4191         (bfd_coff_reloc_link_order): Ditto.
4192
4193         * linker.c (bfd_generic_reloc_link_order): Ditto.
4194         (_bfd_default_link_order): Ditto.
4195
4196         * reloc.c (bfd_perform_relocation):  Distinguish between octets
4197         and bytes.  Use octets when indexing into octet data; use bytes
4198         when calculating target addresses.
4199         (bfd_install_relocation): Ditto.
4200
4201         * srec.c (srec_write_section): Ditto.
4202
4203 2000-01-13  Nick Clifton  <nickc@cygnus.com>
4204
4205         * coff-mcore.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Change from
4206         3 to 2.  This allows 4 byte sized sections, which is necessary for
4207         dlltool to build functioning DLLs.
4208
4209 2000-01-10  Philip Blundell  <pb@futuretv.com>
4210
4211         * config.bfd (arm*-*-linux-gnu*): Match instead of arm*-*-linux-gnu.
4212         (arm*-*-conix*): New target.
4213
4214 2000-01-10  Egor Duda  <deo@logos-m.ru>
4215
4216         * config.bfd: Include elf32_i386 vector to target list for cygwin
4217         and mingw.
4218
4219         * config.in: Undefine HAVE_WIN32_PSTATUS_T.
4220         * configure.in: Test for structure win32_pstatus_t in
4221         <sys/procfs.h>
4222         * configure: Regenerate.
4223
4224         * elf.c (elfcore_grok_win32pstatus): New function: process
4225         win32_pstatus_t notes in elf core file.
4226         (elfcore_grok_note): Detect win32_pstatus notes.
4227
4228 2000-01-03  Martin v. Loewis  <loewis@informatik.hu-berlin.de>
4229
4230         * elflink.c (_bfd_elf_link_record_dynamic_symbol): Process symbol
4231         visibility.
4232         * elflink.h (elf_link_add_object_symbols): Combine visibilities.
4233         * elf.c (bfd_elf_print_symbol): Interpret st_other as visibility.
4234
4235 For older changes see ChangeLog-9899
4236 \f
4237 Local Variables:
4238 mode: change-log
4239 left-margin: 8
4240 fill-column: 74
4241 version-control: never
4242 End: