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