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