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