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