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