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