]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - bfd/ChangeLog
* config/tc-mips.c (macro): Warn about wrong la/dla use.
[thirdparty/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
8dc1a139
TS
12002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
2
3 * elfxx-mips.c: Call it IRIX, not Irix in comments.
4
2051e1b5
JT
52002-05-13 Jason Thorpe <thorpej@wasabisystems.com>
6
7 * config.bfd (shle-*-netbsdelf*): Add target which includes
8 sh64 support.
9
83954261
AM
102002-05-13 David Edelsohn <edelsohn@gnu.org>
11
12 * configure.in: Revert 2002-04-07. Instead, auto-configure
13 HAVE_ST_C_IMPL.
14 * configure: Regenerate.
15 * config.in: Regenerate.
16 * rs6000-core.c (CNEW_IMPL): Guard use of c_impl with HAVE_ST_C_IMPL
17 or AIX_5_CORE.
18
a9bf1154
NC
192002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
20
21 * configure.in (sparc*-*-openbsd*): Support sparc64-openbsd
22 corefiles as well.2
23 * configure: Regenerate.
24
3129eb7a
AM
252002-05-13 Alan Modra <amodra@bigpond.net.au>
26
27 * Makefile.am (install-data-local): Install headers to
28 $(exec_prefix)/include.
29 * Makefile.in: Regenerate.
30
a9a32010
DJ
312002-05-11 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
32 Daniel Jacobowitz <drow@mvista.com>
33
34 * coff-sh.c (sh_reloc_map): Map to R_SH_IMM32 for non-PE. Don't
35 map BFD_RELOC_RVA.
36
372002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
690cc98b
NC
38
39 * config.bfd (alpha*-*-openbsd*, sparc64*-*-openbsd*,
40 hppa*-*-openbsd*): New targets.
41 * configure.in (alpha*-*-openbsd*): Set COREFILE.
42 * configure: Regenerate.
43
f1f0d9ab
TR
442002-05-10 Tom Rix <trix@redhat.com>
45
46 * coff64-rs6000.c (xcoff64_reloc_type_br): New function for
47 xcoff64_ppc_relocate_section.
48 * coff-rs6000.c : Extern common xcoff_reloc_type functions.
49 * libxcoff.h: Common xcoff_reloc_type function declaration.
50
c432ba1a
AM
512002-05-10 Alan Modra <amodra@bigpond.net.au>
52
16a10388
AM
53 * elf32-i386.c (elf_i386_relocate_section): Remove overflow checks
54 addend in 2002-05-09 commit.
55
c432ba1a
AM
56 * elf32-hppa.c (elf32_hppa_size_stubs): Revert part of 2002-05-04,
57 don't look for stubs on all undefined syms.
58
4a335f3d
AM
592002-05-09 Alan Modra <amodra@bigpond.net.au>
60
8fc39d5d
AM
61 * elf64-ppc.c (RA_REGISTER_MASK, RA_REGISTER_SHIFT): Delete.
62 (ppc64_elf_howto_raw <R_PPC64_RELATIVE>): Not pc_relative or
63 pcrel_offset.
64
4a335f3d
AM
65 * elf32-i386.c (elf_howto_table): Comments.
66 (elf_i386_relocate_section): Handle more relocs for relocatable
67 linking and against SEC_MERGE sections.
68
41fcb14e
AM
692002-05-08 Alan Modra <amodra@bigpond.net.au>
70
71 * elf32-ppc.c (ppc_elf_create_got): New function.
72 (ppc_elf_create_dynamic_sections): Call ppc_elf_create_got before
73 _bfd_elf_create_dynamic_sections. Correct .plt flags.
74 (ppc_elf_check_relocs): Use ppc_elf_create_got in place of
75 _bfd_elf_create_got_section.
76
b491616a
AM
772002-05-07 Alan Modra <amodra@bigpond.net.au>
78
79 * elf-bfd.h (struct elf_backend_data): Add rela_normal.
80 * elfxx-target.h (elf_backend_rela_normal): Define.
81 (elfNN_bed): Init rela_normal.
82 * elflink.h (elf_link_input_bfd <emit_relocs>): Handle adjustment
83 for section symbols here if rela_normal. Simplify abs section test.
84 * elf-m10200.c (mn10200_elf_relocate_section): If relocatable,
85 return immediately. Remove code handling relocatable linking.
86 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
87 * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
88 * elf32-i370.c (i370_elf_relocate_section): Likewise.
89 * elf32-i860.c (elf32_i860_relocate_section): Likewise.
90 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
91 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
92 * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
93 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
94 * elf32-s390.c (elf_s390_relocate_section): Likewise.
95 * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
96 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
97 * elf64-s390.c (elf_s390_relocate_section): Likewise.
98 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
99 * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
100 * elf32-arm.h (elf32_arm_relocate_section): Likewise #ifndef USE_REL.
101 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
102 * elf-m10200.c (elf_backend_rela_normal): Define.
103 * elf-m10300.c (elf_backend_rela_normal): Define.
104 * elf32-fr30.c (elf_backend_rela_normal): Define.
105 * elf32-i370.c (elf_backend_rela_normal): Define.
106 * elf32-i860.c (elf_backend_rela_normal): Define.
107 * elf32-m68k.c (elf_backend_rela_normal): Define.
108 * elf32-mcore.c (elf_backend_rela_normal): Define.
109 * elf32-openrisc.c (elf_backend_rela_normal): Define.
110 * elf32-ppc.c (elf_backend_rela_normal): Define.
111 * elf32-s390.c (elf_backend_rela_normal): Define.
112 * elf32-xstormy16.c (elf_backend_rela_normal): Define.
113 * elf64-ppc.c (elf_backend_rela_normal): Define.
114 * elf64-s390.c (elf_backend_rela_normal): Define.
115 * elf64-x86-64.c (elf_backend_rela_normal): Define.
116 * elfxx-ia64.c (elf_backend_rela_normal): Define.
117 * elf32-arm.h (elf_backend_rela_normal): Define #ifndef USE_REL.
118 * elf32-m32r.c (elf_backend_rela_normal): Likewise.
119
df212a7e
NC
1202002-05-06 Nick Clifton <nickc@cambridge.redhat.com>
121
122 * elf32-arm.h (elf32_arm_final_link_relocate): Convert
123 'reloc_signed_max' and 'reloc_signed_min' into half-word offsets.
124
3decf53c
AM
1252002-05-06 Alan Modra <amodra@bigpond.net.au>
126
127 * elflink.h (elf_link_input_bfd <emit_relocs>): Adjust r_offset
128 when not relocatable. Fix reloc_emitter call for K&R.
129
f46c2da6
AM
1302002-05-04 Alan Modra <amodra@bigpond.net.au>
131
132 * elf64-ppc.c (ppc64_elf_relocate_section): Reinstate code
133 reloading local sym addend mistakenly removed in 2002-05-01 change.
134
135 * dwarf2.c (struct line_head): Make prologue_length a bfd_vma.
136 (read_abbrevs): Change "offset" param to bfd_vma.
137 (parse_comp_unit): Change "version" and addr_size to unsigned ints.
138 Change "abbrev_offset" to bfd_vma.
139 (read_indirect_string): Use correct conversion chars in error
140 message format string, cast bfd_vma's to unsigned long.
141 (read_abbrevs): Likewise.
142 (read_attribute_value): Likewise.
143 (decode_line_info): Likewise.
144 (scan_unit_for_functions): Likewise.
145 (parse_comp_unit): Likewise.
146
59862849
TR
1472002-05-04 Tom Rix <trix@redhat.com>
148
149 * coffswap.h (coff_swap_reloc_in): Remove XCOFF support.
150 (coff_swap_reloc_out): Same.
151 * coff-rs6000.c: (xcoff_swap_reloc_in): Moved from coffswap.h.
152 (xcoff_swap_reloc_out): Same.
153 (xcoff_rtype2howto): Renamed from _bfd_xcoff_rtype2howto. Special
154 case some 16 bit relocs. Add reloc value to output.
155 (xcoff_howto_table): Remove 64 bit R_POS, add 16 bit
156 R_RBR. Improve names.
157 (_bfd_xcoff_reloc_type_lookup): Adjust for removal of 64 bit R_POS.
158 (bfd_xcoff_backend_data): Update with new reloc swap names.
159 (bfd_pmac_xcoff_backend_data) : Same.
160 * coff64-rs6000.c: (xcoff64_swap_reloc_in): Moved from coffswap.h.
161 (xcoff64_swap_reloc_out): Same.
162 (xcoff64_rtype2howto): Special case some 16 bit relocs and 32 bit
163 R_POS. Add reloc value to output.
164 (xcoff64_howto_table): Move 64 bit R_POS to first entry. Add 16
165 bit R_RBR. Improve names, masks.
166 (xcoff64_reloc_type_lookup): Adjust for move of 64 bit R_POS.
167 (bfd_xcoff_backend_data): Update with new reloc swap names.
168 (bfd_xcoff_aix5_backend_data) : Same.
169
b4655ea9
AM
1702002-05-04 Alan Modra <amodra@bigpond.net.au>
171
172 * elf32-hppa.c (struct elf32_hppa_link_hash_table): Add
173 bfd_count top_index, input_list, all_local_syms.
174 (elf32_hppa_setup_section_lists): New function, split from
175 elf32_hppa_size_stubs.
176 (elf32_hppa_next_input_section): Likewise.
177 (group_sections): Likewise.
178 (get_local_syms): Likewise.
179 (elf32_hppa_size_stubs): Adjust for split out functions. Look for
180 stubs on undefined syms too.
181 (elf32_hppa_set_gp): Use bfd_link_hash* instead of elf_link_hash*.
8fc39d5d 182 Only access htab elf fields when we have an elf hash table.
b4655ea9
AM
183 * elf32-hppa.h (elf32_hppa_setup_section_lists): Declare.
184 (elf32_hppa_next_input_section): Declare.
185
301e3139
AM
1862002-05-04 Bob Byrnes <byrnes@curl.com>
187
188 * opncls.c (_bfd_new_bfd_contained_in): Check return value of
189 _bfd_new_bfd.
190
7c5fcef7
L
1912002-05-03 H.J. Lu (hjl@gnu.org)
192
193 * elfxx-mips.c (mips_elf_link_hash_entry): Add forced_local.
194 (mips_elf_link_hash_newfunc): Initialize forced_local to false.
195 (mips_elf_record_global_got_symbol): Call _bfd_mips_elf_hide_symbol
196 to hide a global symbol.
197 (_bfd_mips_elf_hide_symbol): Return if forced_local is true. Set
198 forced_local to true.
199
84de6048
RH
2002002-05-02 Richard Henderson <rth@redhat.com>
201
202 * elf64-alpha.c (elf64_alpha_relocate_section): Force relative relocs
203 vs SHN_UNDEF to zero.
204
805fc799
AM
2052002-05-02 Alan Modra <amodra@bigpond.net.au>
206
c061c2d8
AM
207 * elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_SECTOFF>): Change to a
208 16 bit reloc.
209 <R_PPC64_SECTOFF_DS>: Likewise.
210 (ppc64_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
211 SECTOFF reloc.
212 * elf32-ppc.c (ppc_elf_howto_raw <R_PPC_SECTOFF>): Correct.
213 (ppc_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
214 SECTOFF reloc.
215
805fc799
AM
216 * elf64-ppc.c (ppc64_elf_addr16_ha_reloc): Delete.
217 (ppc64_elf_ha_reloc): New function.
218 (ppc64_elf_brtaken_reloc): New function.
219 (ppc64_elf_sectoff_reloc): New function.
220 (ppc64_elf_sectoff_ha_reloc): New function.
221 (ppc64_elf_toc_reloc): New function.
222 (ppc64_elf_toc_ha_reloc): New function.
223 (ppc64_elf_toc64_reloc): New function.
224 (ppc64_elf_unhandled_reloc): New function.
225 (ppc64_elf_howto_raw): Use the above.
226 <R_PPC64_RELATIVE>: Mark pc_relative, pcrel_offset.
227 <R_PPC64_SECTOFF>: Not pc_relative or pcrel_offset. Fix dst_mask.
228 <R_PPC64_SECTOFF_DS>: Likewise.
229 (IS_ABSOLUTE_RELOC): Update.
230 (struct ppc_link_hash_table): Add have_undefweak.
231 (ppc64_elf_link_hash_table_create): Init.
232 (func_desc_adjust): Set have_undefweak.
233 (ppc64_elf_func_desc_adjust): Call func_desc_adjust earlier. Only
234 add the .sfpr blr when have_undefweak.
235 (ppc64_elf_setup_section_lists): Check hash table flavour.
236 (ppc64_elf_next_input_section): Move output_section->owner test to
237 ppc64elf.em.
238 (ppc64_elf_set_toc): Rename to ppc64_elf_toc, remove info param
239 and relocatable test. Return TOCstart and don't set elf_gp.
240 (ppc64_elf_relocate_section): Correct BRTAKEN/BRNTAKEN branch
241 offset calculation. Add assert on weak sym branch tweaks.
242 * elf64-ppc.h (ppc64_elf_set_toc): Delete.
243 (ppc64_elf_toc): Declare.
244 (ppc64_elf_next_input_section): Update.
245
818c39a3
AM
2462002-05-01 Alan Modra <amodra@bigpond.net.au>
247
248 * syms.c (_bfd_stab_section_find_nearest_line): Don't bomb on NULL
249 file_name.
250
721956f4
AM
2512002-05-01 Alan Modra <amodra@bigpond.net.au>
252
253 * elf64-ppc.c (CROR_151515, CROR_313131): Define.
254 (ppc64_elf_relocate_section): Use them. Don't look for plt calls
255 on R_PPC64_ADDR24 relocs. Require a nop or no link reg on plt
256 call branches. Correct undefined weak destination.
257 (ppc64_elf_func_desc_adjust): Always create at least one blr in
258 .sfpr, and correct case where either only savef* or restf* is
259 needed.
260
261 Long branch stubs, multiple stub sections.
262 * elf64-ppc.h (ppc64_elf_setup_section_lists): Declare.
263 (ppc64_elf_next_input_section): Declare.
264 * elf64-ppc.c: Move linker-only prototypes.
265 (STUB_SUFFIX): Define.
266 (enum ppc_stub_type): New.
267 (struct ppc_stub_hash_entry): New.
268 (struct ppc_branch_hash_entry): New.
269 (struct ppc_link_hash_entry): Add stub_cache, oh.
270 (struct ppc_link_hash_table): Add stub_hash_table etc. Remove
271 sstub. Add sbrlt, srelbrlt, has_14bit_branch, stub_iteration.
272 Rename plt_overflow to stub_error.
273 (ppc_stub_hash_lookup): Define.
274 (ppc_branch_hash_lookup): Define.
275 (stub_hash_newfunc): New function.
276 (branch_hash_newfunc): New function.
277 (link_hash_newfunc): Init new fields.
278 (ppc64_elf_link_hash_table_create): Likewise.
279 (ppc64_elf_link_hash_table_free): New function.
280 (ppc_stub_name): New function.
281 (ppc_get_stub_entry): New function.
282 (ppc_add_stub): New function.
283 (create_linkage_sections): Use bfd_make_section_anyway. Create
284 .branch_lt and .rela.branch_lt sections. Don't create .stub.
285 (ppc64_elf_check_relocs): Set has_14bit_branch on R_PPC64_REL14*,
286 and set up for plt call stubs. Link func and func desc syms.
287 (ppc64_elf_gc_sweep_hook): Handle REL14* as per REL24.
288 (func_desc_adjust): Avoid hash lookup when func desc sym available
289 via shortcut, and set links when processing.
290 (ppc64_elf_hide_symbol): Likewise.
291 (allocate_dynrelocs): Don't allocate stub section here.
292 (ppc64_elf_size_dynamic_sections): Handle sbrlt and srelbrlt.
293 Remove sstub code.
294 (ppc_type_of_stub): New function.
295 (build_one_stub): Delete.
296 (ppc_build_one_stub): New function.
297 (ppc_size_one_stub): New function.
298 (ppc64_elf_setup_section_lists): New function.
299 (ppc64_elf_next_input_section): New function.
300 (group_sections): New function.
301 (get_local_syms): New function.
302 (ppc64_elf_size_stubs): Rewrite.
303 (ppc64_elf_build_stubs): Rewrite.
304 (ppc64_elf_relocate_section): Look up stub entry for REL24
305 relocs. Don't propagate REL14* to dynamic objects. Look for long
306 branch stubs if REL14* or REL24 relocs won't reach.
307 (bfd_elf64_bfd_link_hash_table_free): Define.
308
09c2219b
MM
3092002-04-30 Mark Mitchell <mark@codesourcery.com>
310
311 * bfd/config.bfd: Add support for powerpc-*-windiss.
312
07b678c0
TR
3132002-04-30 Tom Rix <trix@redhat.com>
314
315 * xcofflink.c (xcoff_link_add_symbols): Always copy undef C_EXT
316 symbol names into the hash table.
317
dbe341c6
TR
3182002-04-28 Tom Rix <trix@redhat.com>
319
320 * coff-rs6000.c (xcoff_calculate_relocation) : Function table for
321 calulating relocations.
322 (xcoff_complain_overflow) : Function table for relocation errors.
323 (xcoff_ppc_relocate_section): Use relocation and complain function
324 tables.
325 (xcoff_complain_overflow_unsigned_func): New complain function.
326 (xcoff_complain_overflow_signed_func): Same.
327 (xcoff_complain_overflow_bitfield_func): Same.
328 (xcoff_complain_overflow_dont_func): Same.
329 (xcoff_reloc_type_crel): New recot function.
330 (xcoff_reloc_type_br): Same.
331 (xcoff_reloc_type_ba): Same.
332 (xcoff_reloc_type_toc): Same.
333 (xcoff_reloc_type_rel): Same.
334 (xcoff_reloc_type_neg): Same.
335 (xcoff_reloc_type_pos): Same.
336 (xcoff_reloc_type_fail): Same.
337 (xcoff_reloc_type_noop): Same.
338 * libxcoff.h : Declare common parts for xcoff64.
339 * coff64-rs6000.c (xcoff64_ppc_relocate_section): Use relocation
340 and complain function tables.
341
985142a4
AM
3422002-04-28 Alan Modra <amodra@bigpond.net.au>
343
344 * elf64-x86-64.c (struct elf64_x86_64_dyn_relocs): Comment typo.
345 * elf32-hppa.c (elf32_hppa_final_link): Formatting.
346
eba91044
AM
3472002-04-26 Alan Modra <amodra@bigpond.net.au>
348
e54fdaa5
AM
349 * opncls.c (bfd_make_readable): Call bfd_section_list_clear.
350 * xcofflink.c (xcoff_link_add_dynamic_symbols): Likewise.
351
a50c1845
AM
352 * elflink.h (elf_bfd_final_link): Ensure input bfd class is the
353 same as the output before calling elf_link_input_bfd.
354
eba91044
AM
355 * coffcode.h (coff_compute_section_file_positions): Set
356 section_tail after shuffling section list.
357
3c25c5f6
NC
3582002-04-24 Christian Groessler <chris@groessler.org>
359
360 * coff-z8k.c (extra_case): Fix R_IMM32 relocations: The
361 addresses are 23bit with a special layout, not plain 32bit
362 values. Prevent relocation of immediate values.
363
40d32fc6
CD
3642002-04-24 Chris G. Demetriou <cgd@broadcom.com>
365
366 * elfxx-mips.c (_bfd_mips_elf_print_private_bfd_data): If MDMX or
367 MIPS-16 ASE flags are set, print something to indicate that.
368
067fa4a6
AM
3692002-04-23 Alan Modra <amodra@bigpond.net.au>
370
371 * elf32-hppa.c (hppa_type_of_stub): Correct and simplify condition
372 under which a plt call stub is used.
373 (final_link_relocate): Similarly.
374 (allocate_plt_static): Clear h-plabel except when plt entry is
375 exclusively used for a plabel.
376 (allocate_dynrelocs): Use the above to simplify plt sizing.
377 (struct elf32_hppa_link_hash_table): Add has_22bit_branch.
378 (elf32_hppa_link_hash_table_create): Init.
379 (BL22_RP): Define.
380 (hppa_build_one_stub): Use BL22_RP if has_22bit_branch.
381 (elf32_hppa_check_relocs): Set has_22bit_branch.
382
383 * elf32-hppa.c (elf32_hppa_check_relocs): Remove debug message.
384 (final_link_relocate): Likewise.
385
af40ce3c
JJ
3862002-04-22 Jakub Jelinek <jakub@redhat.com>
387
388 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't build
389 search table if some FDE is DW_EH_PE_aligned encoded either.
390 (_bfd_elf_write_section_eh_frame): Handle terminating FDE specially.
391
09ae86c2
JJ
3922002-04-22 Richard Smith <richard@ex-parrot.com>
393 Jakub Jelinek <jakub@redhat.com>
394
395 * elf-eh-frame.c (struct eh_cie_fde): Add per_encoding_relative.
396 (_bfd_elf_discard_section_eh_frame): Set it for CIEs with pcrel
397 encoded personality.
398 (_bfd_elf_write_section_eh_frame): Adjust pcrel encoded personality
399 for CIE/FDE removal.
400
deeb2cd7
TR
4012002-04-20 Tom Rix <trix@redhat.com>
402
403 * coff64-rs6000.c (_bfd_xcoff64_swap_aux_in): Fix C_FILE auxent.
404
99dc0092
AM
4052002-04-20 Alan Modra <amodra@bigpond.net.au>
406
aa3d5824
AM
407 * archures.c (bfd_lookup_arch): Move the list order comment..
408 (struct bfd_arch_info): ..to where it belongs.
409 * bfd-in2.h: Regenerate.
410
99dc0092
AM
411 * archures.c (bfd_lookup_arch): Add comment on list order.
412 (bfd_default_set_arch_mach): Use bfd_lookup_arch.
413 * cpu-powerpc.c (bfd_powerpc_archs): Re-order so that the default
414 is always at head of list.
415
7831a775
NC
4162002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
417
418 * coff-arm.c (coff_thumb_pcrel_12, coff_thumb_pcrel_9,
419 insert_thumb_branch, record_thumb_to_arm_glue): Suppress
420 definition of these functions for ARM_WINCE builds as they are
421 not used.
422 (SWAP_IN_RELOC_OFFSET, SWAP_OUT_RELOC_OFFSET): Do not define
423 for ARM_WINCE builds.
424
4252002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
426
427 * coff-arm.c (bfd_arm_process_before_allocation):
428
4292002-04-17 J"orn Rennecke <joern.rennecke@superh.com>
a44d7f9c
JR
430
431 * cpu-sh.c (scan_mach): Delete.
432 (arch_info_struct): Replace scan_mach with bfd_default_scan.
433 (bfd_sh_arch): Likewise.
434
3d8dbe36
NC
4352002-04-16 Nick Clifton <nickc@cambridge.redhat.com>
436
437 * ihex.c (ihex_write_object_contents): Fix check for records
438 crossing 64K boundaries.
439
4ab82700
AM
4402002-04-16 Alan Modra <amodra@bigpond.net.au>
441
442 * elf32-m32r.c (m32r_elf_add_symbol_hook): Check the hash table
443 type rather than just assuming entries are ELF.
444 * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
445 * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
446 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Likewise.
447 * elf64-mmix.c (mmix_elf_add_symbol_hook): Use bfd_link_hash_entry
448 rather than elf_link_hash_entry.
449
036fe0fe
RH
4502002-04-15 Richard Henderson <rth@redhat.com>
451
452 * elf32-mips.c (mips_elf32_object_p): Revert 0404 fragment: allow
453 n32 binaries.
454
c4f3d130
NC
4552002-04-15 Michael Snyder <msnyder@redhat.com>
456
457 * opncls.c (bfd_close): Write contents if writeable.
458 Minor formatting tidy-ups.
459
4ab82700 4602002-04-15 Alan Modra <amodra@bigpond.net.au>
27242387
AM
461
462 * elf32-ppc.c (ppc_elf_add_symbol_hook): Check the hash table type.
463
0c04d169
MS
4642002-04-12 Michael Snyder <msnyder@redhat.com>
465
466 * bfd-in.h (bfd_get_section_lma): New access macro.
467 Minor white-space fix-up.
468
89d4966f
AM
4692002-04-12 Alan Modra <amodra@bigpond.net.au>
470
471 * elf.c (prep_headers): Don't zero EI_OSABI, EI_ABIVERSION or
472 header pad.
473
8d0da3c2
DD
4742002-04-09 DJ Delorie <dj@redhat.com>
475
476 * elfarm-nabi.c (elf32_arm_howto_table): Fix ABS16 masks.
477
05793179
NC
4782002-04-09 Casper S. Hornstrup <chorns@users.sourceforge.net>
479
480 * coffcode.h (coff_read_word): New.
481 (coff_compute_checksum): New.
482 (coff_apply_checksum): New.
483 (coff_write_object_contents): Call coff_apply_checksum () to
484 apply checksum to PE image.
485
46fe4e66
AM
4862002-04-08 Randolph Chung <tausq@debian.org>
487
488 * elf32-hppa.c (hppa_unwind_entry_compare): Move to elf-hppa.h.
489 (elf32_hppa_final_link): Split out sorting logic to..
490 * elf-hppa.h (elf_hppa_sort_unwind): ..here.
491 (elf_hppa_final_link): Call elf_hppa_sort_unwind.
492
3b5b409c
AC
4932002-04-07 Andrew Cagney <ac131313@redhat.com>
494
495 * configure.in: Add missing ``|'' to powerpc-*-aix4.[4-9]*
496 pattern.
497 * configure: Re-generate.
498
ac7b6ceb
AC
4992002-04-07 Andrew Cagney <ac131313@redhat.com>
500
501 * configure.in: Only define AIX_CORE_DUMPX_CORE when AIX version
502 is greater or equal to 4.3.3.
503 * configure: Regenerate.
504 Fix PR gdb/344.
505
44aa49bb
HPN
5062002-04-05 Hans-Peter Nilsson <hp@axis.com>
507
508 * elf32-cris.c (cris_elf_howto_table) <R_CRIS_16_PCREL,
509 R_CRIS_32_PCREL>: Fix typo in name.
510 (cris_elf_check_relocs): Always create .rela.got here when
511 R_CRIS_16_GOTPLT or R_CRIS_32_GOTPLT is seen.
512 (elf_cris_adjust_gotplt_to_got): Don't create .rela.got here;
513 assume it's created.
514
e2d34d7d
DJ
5152002-04-04 Daniel Jacobowitz <drow@mvista.com>
516
517 * aout-adobe.c (aout_32_bfd_link_hash_table_free): Define.
518 * aout-target.h (MY_bfd_link_hash_table_free): Conditionally
519 define.
520 * aout-tic30.c (MY_bfd_link_hash_table_free): Likewise.
521 * bfd.c (bfd_link_hash_table_free): Define.
522 * binary.c (binary_bfd_link_hash_table_free): Define.
523 * bout.c (b_out_bfd_link_hash_table_free): Define.
524 * coff-rs6000.c (rs6000coff_vec): Include
525 _bfd_generic_link_hash_table_free.
526 (pmac_xcoff_vec): Likewise.
527 * coff64-rs6000.c (rs6000coff64_vec): Likewise.
528 (aix5coff64_vec): Likewise.
529 * coffcode.h (coff_bfd_link_hash_table_free): Conditionally define.
530 * elf-m10300.c (elf32_mn10300_link_hash_table_free): New function.
531 (bfd_elf32_bfd_link_hash_table_free): Define.
532 * elf32-hppa.c (elf32_hppa_link_hash_table_free): New function.
533 (bfd_elf32_bfd_link_hash_table_free): Define.
534 * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_free): Conditionally
535 define.
536 * i386msdos.c (msdos_bfd_link_hash_table_free): Define.
537 * i386os9k.c (os9k_bfd_link_hash_table_free): Define.
538 * ieee.c (ieee_bfd_link_hash_table_free): Define.
539 * ihex.c (ihex_bfd_link_hash_table_free): Define.
540 * libbfd-in.h (_bfd_nolink_bfd_link_hash_table_free): Define.
541 (_bfd_generic_link_hash_table_free): Add prototype.
542 * libcoff-in.h (_bfd_xcoff_bfd_link_hash_table_free): Add prototype.
543 * libecoff.h (_bfd_ecoff_bfd_link_hash_table_free): Define.
544 * linker.c (_bfd_generic_link_hash_table_free): New function.
545 * mmo.c (mmo_bfd_link_hash_table_free): Define.
546 * nlm-target.h (nlm_bfd_link_hash_table_free): Define.
547 * oasys.c (oasys_bfd_link_hash_table_free): Define.
548 * ppcboot.c (ppcboot_bfd_link_hash_table_free): Define.
549 * som.c (som_bfd_link_hash_table_free): Define.
550 * srec.c (srec_bfd_link_hash_table_free): Define.
551 * tekhex.c (tekhex_bfd_link_hash_table_free): Define.
552 * versados.c (versados_bfd_link_hash_table_free): Define.
553 * vms.c (vms_bfd_link_hash_table_free): New function.
554 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_free): New function.
555
556 * coff-arm.c (coff_arm_link_hash_table_create): Use bfd_malloc
557 instead of bfd_alloc.
558 * coff-h8300.c (h8300_coff_link_hash_table_create): Likewise.
559 * coff-mcore.c (coff_mcore_link_hash_table_create): Likewise.
560 * coff-ppc.c (ppc_coff_link_hash_table_create): Likewise.
561 * cofflink.c (_bfd_coff_link_hash_table_create): Likewise.
562 * ecoff.c (_bfd_ecoff_bfd_link_hash_table_create): Likewise.
563 * elf-m10300.c (elf32_mn10300_link_hash_table_create): Likewise.
564 * elf.c (_bfd_elf_link_hash_table_create): Likewise.
565 * elf32-arm.h (elf32_arm_link_hash_table_create): Likewise.
566 * elf32-cris.c (elf_cris_link_hash_table_create): Likewise.
567 * elf32-hppa.c (elf32_hppa_link_hash_table_create): Likewise.
568 * elf32-i386.c (elf_i386_link_hash_table_create): Likewise.
569 * elf32-m68k.c (elf_m68k_link_hash_table_create): Likewise.
570 * elf32-s390.c (elf_s390_link_hash_table_create): Likewise.
571 * elf32-sh.c (sh_elf_link_hash_table_create): Likewise.
572 * elf64-alpha.c (elf64_alpha_bfd_link_hash_table_create): Likewise.
573 * elf64-ppc.c (ppc64_elf_link_hash_table_create): Likewise.
574 * elf64-s390.c (elf_s390_link_hash_table_create): Likewise.
575 * elf64-sh64.c (sh64_elf64_link_hash_table_create): Likewise.
576 * elf64-sparc.c (sparc64_elf_bfd_link_hash_table_create): Likewise.
577 * elf64-x86-64.c (elf64_x86_64_link_hash_table_create): Likewise.
578 * elfxx-mips.c (_bfd_mips_elf_link_hash_table_create): Likewise.
579 * linker.c (_bfd_generic_link_hash_table_create): Likewise.
580 * m68klinux.c (linux_link_hash_table_create): Likewise.
581 * sparclinux.c (linux_link_hash_table_create): Likewise.
582 * sunos.c (sunos_link_hash_table_create): Likewise.
583 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Likewise.
584
585 * targets.c: Add _bfd_link_hash_table_free to xvec.
586
587 * bfd-in2.h: Regenerate.
588 * libbfd.h: Regenerate.
589 * libcoff.h: Regenerate.
590
830629ab
AM
5912002-04-04 Alan Modra <amodra@bigpond.net.au>
592
593 * dep-in.sed: Cope with absolute paths.
594 * Makefile.am (dep.sed): Subst TOPDIR, and not INCDIR.
595 Run "make dep-am".
596 * Makefile.in: Regenerate.
597 * coff-arm.c: Fix copyright date.
598 * cpu-h8300.c: Likewise.
599 * cpu-i370.c: Likewise.
600 * cpu-s390.c: Likewise.
601 * cpu-mips.c: Likewise.
602 * po/SRC-POTFILES.in: Regenerate.
603
c6e90b02
TS
6042002-04-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
605
606 * Makefile.am: Add elfxx-mips.c to the known backends.
607 (elf32-mips.lo): remove dependency to coff/external.h.
608 * Makefile.in: Regenerate.
609 * configure.in: Add elfxx-mips.lo to all vectors using elf32-mips.lo
610 Remove elf32-mips.lo from 64 bit vectors. Update dependencies
611 accordingly.
612 * configure: Regenerate.
613 * elf-bfd.h: Move all MIPS ELF specific prototypes to elfxx-mips.h.
614 (irix_compat_t): IRIX compatibility level, moved from elf32-mips.c.
615 (elf_backend_mips_irix_compat, elf_backend_mips_rtype_to_howto): New
616 MIPS specific backend functions.
617 * elf32-mips.c: Moved most code to elfxx-mips.c.
618 (mips_elf_hi16_reloc): Rename from _bfd_mips_elf_hi16_reloc and make
619 static.
620 (mips_elf_lo16_reloc): Likewise, was _bfd_mips_elf_lo16_reloc.
621 (mips_elf_got16_reloc): Likewise, was _bfd_mips_elf_got16_reloc.
622 (mips_elf_gprel32_reloc): Likewise, was _bfd_mips_elf_gprel32_reloc.
623 (mips_elf32_rtype_to_howto): Rename from mips_rtype_to_howto. Changed
624 interface to allow selection of the right REL or RELA howto table.
625 (mips_elf32_object_p): Rename from _bfd_mips_elf_object_p and made
626 static. Let it refuse n32 objects.
627 (elf32_mips_grok_prstatus): Rename from _bfd_elf32_mips_grok_prstatus.
628 (elf32_mips_grok_psinfo): Rename from _bfd_elf32_mips_grok_psinfo.
629 (elf32_mips_discard_info): Rename from _bfd_elf32_mips_discard_info.
630 (elf32_mips_ignore_discarded_relocs): Rename from
631 _bfd_elf32_mips_ignore_discarded_relocs.
632 (elf32_mips_write_section): Rename from _bfd_elf32_mips_write_section.
633 (elf32_mips_irix_compat): New function, replaces IRIX_COMPAT.
634 (elf_mips_howto_table_rela): Remove.
635 * elf64-mips.c: Moved most code to elfxx-mips.c.
636 (bfd_elf64_bfd_reloc_type_lookup): Make static.
637 (mips_elf64_rtype_to_howto): New function.
638 (mips_elf64_object_p): Likewise.
639 (elf64_mips_irix_compat): Likewise.
640 * elfxx-mips.c: New file containing common code merged together from
641 elf32-mips.c and elf64-mips.c.
642 * elfxx-mips.h: New file containing MIPS specific prototypes from
643 elf-bfd.h.
644 * elfxx-target.h: Add handling for elf_backend_mips_irix_compat and
645 elf_backend_mips_rtype_to_howto.
646
d8dce692
AM
6472002-04-04 Alan Modra <amodra@bigpond.net.au>
648
649 * srec.c (MAXCHUNK, Chunk): Revise comments.
650 (srec_write_record): Correct buffer size.
651 (srec_write_header): Do without intermediate buffer.
652 (srec_write_section): Validate Chunk.
653 (srec_write_terminator): Pass NULL instead of dummy buffer.
654 (srec_write_symbols): Pass file and symbol names directly to
655 bfd_bwrite so sprintf won't overflow buffer.
656
b88a866a
JJ
6572002-04-03 Jakub Jelinek <jakub@redhat.com>
658
659 * elf32-sparc.c (elf32_sparc_relocate_section): Don't emit dynamic
660 PC relative relocs against hidden symbols.
661 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
662
d7866f04
AM
6632002-04-03 Alan Modra <amodra@bigpond.net.au>
664
665 * elf.c (_bfd_elf_make_section_from_shdr): When setting section
666 LMAs, loop over segments until p_vaddr and p_memsz specify an
667 extent enclosing the section.
668
9e81ee67
NC
6692002-04-02 Nick Clifton <nickc@cambridge.redhat.com>
670
671 * ihex.c (ihex_write_object_contents): Do not allow records to
672 cross a 64K boundary - wrap if necessary.
673
d2b64500
JT
6742002-04-01 Nathan Williams <nathanw@wasabisystems.com>
675
676 * elf.c (elfcore_netbsd_get_lwpid): Fix off-by-one error
677 which caused the returned LWP ID to always be 0.
678
e36f7d53
RH
6792002-04-01 Richard Henderson <rth@redhat.com>
680
681 * elf32-sparc.c (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
682 (elf32_sparc_relocate_section): Use it to figure out when to
683 initialize .got entries.
684 * elf64-sparc.c: Similarly.
685
e92d460e
AM
6862002-03-28 Alan Modra <amodra@bigpond.net.au>
687
688 * linker.c (link_action): Ignore duplicate warning syms.
689 (_bfd_generic_link_write_global_symbol): Follow warning symbol link.
690 * elflink.h (elf_adjust_dynstr_offsets): Likewise.
691 (elf_adjust_dynamic_symbol): Likewise.
692 (elf_export_symbol): Likewise.
693 (elf_link_find_version_dependencies): Likewise.
694 (elf_link_assign_sym_version): Likewise.
695 (elf_link_sec_merge_syms): Likewise.
696 (elf_link_output_extsym): Likewise.
697 (elf_gc_sweep_symbol): Likewise.
698 (elf_gc_propagate_vtable_entries_used): Likewise.
699 (elf_gc_smash_unused_vtentry_relocs): Likewise.
700 (elf_gc_allocate_got_offsets): Likewise.
701 (elf_collect_hash_codes): Likewise.
702 * elflink.c (elf_link_renumber_hash_table_dynsyms): Likewise.
703 * elf-hppa.h (elf_hppa_unmark_useless_dynamic_symbols): Likewise.
704 (elf_hppa_remark_useless_dynamic_symbols): Likewise.
705 * elf-m10300.c (elf32_mn10300_finish_hash_table_entry): Likewise.
706 * elf32-arm.h (elf32_arm_discard_copies): Likewise.
707 * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Likewise.
708 (elf_cris_discard_excess_dso_dynamics): Likewise.
709 * elf32-hppa.c (clobber_millicode_symbols): Likewise.
710 (mark_PIC_calls): Likewise.
711 (allocate_plt_static): Likewise.
712 (allocate_dynrelocs): Likewise.
713 (readonly_dynrelocs): Likewise.
714 * elf32-i386.c (allocate_dynrelocs): Likewise.
715 (readonly_dynrelocs): Likewise.
716 * elf32-i370.c (i370_elf_adjust_dynindx): Likewise.
717 * elf32-m68k.c (elf_m68k_discard_copies): Likewise.
718 * elf32-mips.c (mips_elf_output_extsym): Likewise.
719 (mips_elf_sort_hash_table_f): Likewise.
720 (mips_elf_check_mips16_stubs): Likewise.
721 * elf32-s390.c (allocate_dynrelocs): Likewise.
722 (readonly_dynrelocs): Likewise.
723 * elf32-sh.c (sh_elf_discard_copies): Likewise.
724 * elf32-xstormy16.c (xstormy16_relax_plt_check): Likewise.
725 (xstormy16_relax_plt_realloc): Likewise.
726 * elf64-alpha.c (elf64_alpha_calc_got_offsets_for_symbol): Likewise.
727 (elf64_alpha_output_extsym): Likewise.
728 * elf64-hppa.c (elf64_hppa_mark_exported_functions): Likewise.
729 * elf64-mips.c (mips_elf64_sort_hash_table_f): Likewise.
730 (mips_elf64_check_mips16_stubs): Likewise.
731 (mips_elf64_output_extsym): Likewise.
732 * elf64-ppc.c (func_desc_adjust): Likewise.
733 (allocate_dynrelocs): Likewise.
734 (readonly_dynrelocs): Likewise.
735 * elf64-s390.c (allocate_dynrelocs): Likewise.
736 (readonly_dynrelocs): Likewise.
737 * elf64-sh64.c (sh64_elf64_discard_copies): Likewise.
738 * elf64-x86-64.c (allocate_dynrelocs): Likewise.
739 (readonly_dynrelocs): Likewise.
740 * elfxx-ia64.c (elfNN_ia64_global_dyn_sym_thunk): Likewise.
741 * aoutx.h (aout_link_write_other_symbol): Likewise.
742 * cofflink.c (_bfd_coff_write_task_globals): Likewise.
743 (_bfd_coff_write_global_sym): Likewise.
744 * i386linux.c (linux_tally_symbols): Likewise.
745 * m68klinux.c (linux_tally_symbols): Likewise.
746 * sparclinux.c (linux_tally_symbols): Likewise.
747 * pdp11.c (aout_link_write_other_symbol): Likewise.
748 * sunos.c (sunos_scan_dynamic_symbol): Likewise.
749 * xcofflink.c (xcoff_build_ldsyms): Likewise.
750 (xcoff_write_global_symbol): Likewise.
751
752 * cofflink.c (_bfd_coff_final_link): Formatting.
753 * cpu-mips.c (mips_compatible): Make static, prototype.
754 * elf32-i386.c (elf_i386_check_relocs): Formatting.
755 * elf32-sh.c (sh_elf_size_dynamic_sections): Likewise.
756 * elf64-alpha.c (elf64_alpha_output_extsym): Likewise.
757 * elf64-mips.c (mips_elf64_sort_hash_table): Likewise.
758 (mips_elf64_final_link): Likewise.
759 * elflink.h (elf_link_find_version_dependencies): Remove duplicate
760 prototype.
761
2106126f
NC
7622002-03-27 Nick Clifton <nickc@cambridge.redhat.com>
763
764 * coff-arm.c (SWAP_IN_RELOC_OFFSET): Define.
765 (SWAP_OUT_RELOC_OFFSET): Define.
766
b99d1833
AM
7672002-03-27 Gregory Steuck <greg@nest.cx>
768
769 * elf.c (_bfd_elf_get_symtab_upper_bound): Leave space for
770 terminating NULL if empty symbol table.
771 (_bfd_elf_get_dynamic_symtab_upper_bound): Likewise.
772
ad43ed4c
L
7732002-03-26 H.J. Lu (hjl@gnu.org)
774
775 * elflink.h (elf_link_input_bfd): Revert the last change since
776 the gcc exception handling isn't fixed yet.
777
3851fca4
L
7782002-03-26 H.J. Lu (hjl@gnu.org)
779
780 * elflink.h (elf_link_input_bfd): Complain about relocations
781 against local symbols in discarded sections.
782
b91afed7
AM
7832002-03-26 Alan Modra <amodra@bigpond.net.au>
784
785 * elflink.h (elf_gc_mark): Don't recurse into non-ELF sections.
786
dba143ef
AM
7872002-03-23 Alan Modra <amodra@bigpond.net.au>
788
789 * elf.c (_bfd_elf_make_section_from_shdr): Don't set lma based on
790 section file offset for !SEC_LOAD sections.
791
ee29b9fb
RE
7922002-03-21 Richard Earnshaw <rearnsha@arm.com>
793
830629ab
AM
794 * elf32-arm.h (elf32_arm_final_link_relocate <case R_ARM_GOTOFF>,
795 <case R_ARM_GOT>): Handle relocations to Thumb functions.
ee29b9fb 796
54327882
AM
7972002-03-21 Alan Modra <amodra@bigpond.net.au>
798
799 * coff64-rs6000.c (_bfd_xcoff64_put_symbol_name): Prototype.
800 Whitespace changes.
801 * archive.c: Update copyright date.
802 * bfd-in2.h: Regenerate.
803 * libbfd.h: Regenerate.
804 * Makefile.am: Run "make dep-am"
805 * Makefile.in: Regenerate.
806 * po/SRC-POTFILES.in: Regenerate.
807
1ee24f27
DJ
8082002-03-20 Daniel Jacobowitz <drow@mvista.com>
809
810 * dwarf2.c (struct funcinfo): Move up.
811 (lookup_address_in_function_table): New argument function_ptr.
812 Set it.
813 (lookup_address_in_line_table): New argument function. If function
814 is non-NULL, use it to handle ``addr'' before the first line note of
815 the function.
816 (comp_unit_find_nearest_line): Update and swap calls to
817 lookup_address_in_function_table and lookup_address_in_line_table.
818 * syms.c (_bfd_stab_section_find_nearest_line): Use the first
819 N_SLINE encountered if we see an N_FUN before any N_SLINE.
820
51b9608c
TR
8212002-03-20 Tom Rix <trix@redhat.com>
822
823 * coff-rs6000.c (_bfd_xcoff_stat_arch_elt): Renamed from
824 _bfd_xcoff_generic_stat_arch_elt. Fix format check.
825 * coff64-rs6000.c : Use _bfd_xcoff_stat_arch_elt.
826
789c90aa
TR
8272002-03-19 Tom Rix <trix@redhat.com>
828
829 * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Look through all
830 dynamic objects in archives.
831
1da54d81
HPN
8322002-03-19 Hans-Peter Nilsson <hp@bitrange.com>
833
834 * elflink.h (NAME(bfd_elf,record_link_assignment)): Don't set
835 STT_NOTYPE symbols to STT_OBJECT.
836
7831a775 8372002-03-18 Jan Hubicka <jh@suse.cz>
beb43bb9
JH
838
839 * cpu-i386.c (bfd_x86_64_arch): Rename to "i386:x86-64"
840
eb1e0e80
NC
8412002-03-18 Tom Rix <trix@redhat.com>
842
843 * aix5ppc.core.c : New file for AIX 5 64 bit core support.
844 * bfd-in.h : Add bfd_xcoff_ar_archive_set_magic declaration.
845 * coff-rs6000 (do_pad) : New function for archive padding.
846 (do_copy) : New function for object file copying in archives.
847 (do_shared_object_padding) : New function for padding shared
848 objects to their text section alignment in archives.
849 (bfd_xcoff_ar_achive_set_magic) : Stub.
850 (xcoff_write_armap_big) : Use do_copy and do_pad.
851 (xcoff_write_archive_contents_big) : Use do_shared_object_padding,
852 do_copy and do_pad.
853 * coff64-rs6000.c (xcoff64_write_ojbect_contents) : Use
854 bfd_xcoff_magic_number.
855 (xcoff64_bad_format_hook) : New function for _bfd_bad_format_hook
856 fop.
857 (xcoff_backend_data_r) : Use xcoff64_bad_format_hook.
858 (bfd_xcoff_aix5_backend_data) : New Aix 5 backend data.
859 (aix5coff64_vec) : New Aix 5 target aix5coff64-rs6000.
860 * rs6000-core.c : Update copyright date.
861 * xcofflink.c (bfd_xcoff_size_dynamic_sections): Check for NULL
862 csectpp.
863 * coffcode.h (coff_new_section_hook) : Use new accessor macros.
864 (coff_set_arch_mach_hook) : Add Aix 5 U64_TOCMAGIC magic #.
865 (coff_set_flags) : Use bfd_xcoff_magic_number.
866 * libxcoff.h (bfd_xcoff_is_xcoff64): Add U64_TOCMAGIC.
867 * configure.in : Add powerpc-*-aix5 and rs6000-*-aix5 support.
868 * Makefile.am : Same.
869 * config.bfd : Same.
870 * targets.c : Same.
871 * configure : Regnerate.
872 * Makefile.in : Same.
873 * bfd-in2.h : Same.
874
a1c259a1
NC
8752002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
876
877 * po/fr.po: Updated version.
878
4dae1ae7
AM
8792002-03-18 Alan Modra <amodra@bigpond.net.au>
880
881 * libbfd.c (bfd_write_bigendian_4byte_int): Return true iff success.
882 * libbfd.h: Regenerate.
883 * archive.c (coff_write_armap): Pass on failures from
884 bfd_write_bigendian_4byte_int.
885
36b4f6e7
L
8862002-03-14 H.J. Lu <hjl@gnu.org>
887
888 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the BFD
889 error to bfd_error_nonrepresentable_section for reinit_array
890 section in DSO.
891
a1aefc76
NC
8922002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
893
a181be0a
NC
894 * coffcode.h (coff_slurp_symbol_table): When adding BSF_WEAK flag,
895 OR it in rather than replacing previously selected flags.
896
a1aefc76
NC
897 * elfxx-target.h (TARGET_BIG_SYM): Set ar_max_namelen to 15.
898 (TARGET_LITTLE_SYM): Set ar_max_namelen to 15.
899
c119f9b8
AM
9002002-03-14 Alan Modra <amodra@bigpond.net.au>
901
902 * cpu-mips.c (mips_compatible): New. Don't check bits_per_word.
903 (N): Use the above.
904 * elflink.h (elf_bfd_final_link): Revert last change. Instead,
905 ensure reloc size matches before calling elf_link_input_bfd.
906 Add an assert to check reloc size when counting output relocs.
907
c295a511
NC
9082002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
909
910 * mmo.c (mmo_get_loc): Return NULL rather than false.
911
9ce88e60
NC
9122002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
913
914 * po/fr.po: Updated version.
915
4ddafab0
AM
9162002-03-13 Alan Modra <amodra@bigpond.net.au>
917
b74fa2cd
AM
918 * archures.c (bfd_default_compatible): Test bits_per_word.
919 * cpu-i386.c (i386_compatible): Remove. Replace occurrences with
920 bfd_default_compatible.
921 * cpu-i370.c (i370_compatible): Likewise.
922 * cpu-sparc.c (sparc_compatible): Likewise.
923 * cpu-h8300.c (compatible): Test in->arch == out->arch.
924
40b829d4
AM
925 * elflink.h: Formatting fixes.
926 (elf_link_output_extsym): Merge undefined and undef weak cases.
927
4ddafab0
AM
928 * elflink.h (elf_bfd_final_link): Only call elf_link_input_bfd
929 when word size of input matches output word size.
930
dd53c801
AJ
9312002-03-12 Andreas Jaeger <aj@suse.de>
932
933 * cpu-i386.c (i386_compatible): New. Use it instead of
934 bfd_default_compatible.
935
aa066ac8
L
9362002-03-07 H.J. Lu (hjl@gnu.org)
937
938 * coff-sh.c (shcoff_reloc_map): Use bfd_reloc_code_real_type
939 as the type for bfd_reloc_val.
940
1bf42538
JL
9412002-03-05 John David Anglin <dave@hiauly1.hia.nrc.ca>
942
943 * elf-hppa.h (elf_hppa_is_dynamic_loader_symbol): New function.
944 (elf_hppa_relocate_section): Ignore undefined dynamic loader symbols.
945 (elf_hppa_final_link_relocate): Correct relocations for indirect
946 references to local data through the DLT. Fix .opd creation for
947 local symbols using R_PARISC_LTOFF_FPTR32 and R_PARISC_FPTR64
948 relocations. Use e_lsel selector for R_PARISC_DLTIND21L,
949 R_PARISC_LTOFF_FPTR21L and R_PARISC_LTOFF_TP21L as per
950 "Processor-Specific ELF for PA_RISC, Version 1.43" document.
951 Similarly, use e_rsel for DLT and LTOFF 'R' relocations.
952 * elf32-hppa.c (final_link_relocate): Revise relocation selectors
953 as per "Processor-Specific ELF for PA_RISC, Version 1.43" document.
954
86eaf01e
JJ
9552002-03-05 Jakub Jelinek <jakub@redhat.com>
956
957 * merge.c (_bfd_merge_sections): Don't segfault if there
958 is nothing to merge due to GC.
959
c44233aa
AM
9602002-03-05 Alan Modra <amodra@bigpond.net.au>
961
039cc25f
AM
962 * elf32-hppa.c (clobber_millicode_symbols): Remove hack to keep
963 symbols that have been forced local.
964
c44233aa
AM
965 * elflink.h (elf_bfd_final_link): Call elf_link_output_extsym
966 to output forced local syms for non-shared link.
967 (elf_link_output_extsym): Tweak condition for calling backend
968 adjust_dynamic_symbol so that previous behaviour is kept.
969 Whitespace changes throughout file.
970
25e27870
L
9712002-03-04 H.J. Lu <hjl@gnu.org>
972
973 * elf.c (bfd_section_from_shdr): Handle special sections,
974 .init_array, .fini_array and .preinit_array.
975 (elf_fake_sections): Likewise.
976
977 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Create the
978 DT entry only if the section is in output for .init_array,
979 .fini_array and .preinit_array. Complain about .preinit_array
980 section in DSO.
981 (elf_bfd_final_link): Warn zero size for .init_array,
982 .fini_array and .preinit_array sections.
983
984 * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Remove
985 SHT_INIT_ARRAY, SHT_FINI_ARRAY and SHT_PREINIT_ARRAY.
986 (elfNN_ia64_fake_sections): Remove .init_array, .fini_array and
987 .preinit_array.
988
bb2a49f2
AM
9892002-03-04 Alan Modra <amodra@bigpond.net.au>
990
991 * configure.in (WIN32LIBADD): Don't eval PICFLAG assignment.
992 * configure: Regenerate.
993
38487e5e
TR
9942002-03-02 Tom Rix <trix@redhat.com>
995
c44233aa
AM
996 * coff64-rs6000.c (xcoff64_howto_table): Replace howto types with
997 symbolic equiv.
38487e5e
TR
998 * coff-rs6000.c (xcoff_howto_table): Same.
999
30831527
RH
10002002-03-01 David Mosberger <davidm@hpl.hp.com>
1001
1002 * elflink.h (size_dynamic_sections): If section named
1003 ".preinit_array" exists, create DT_PREINIT_ARRAY and
1004 DT_PREINIT_ARRAYSZ entries in dynamic table. Analogously for
1005 ".init_array" and ".fini_array".
1006 (elf_bfd_final_link): Handle DT_PREINIT_ARRAYSZ, DT_INIT_ARRAYSZ,
1007 DT_FINI_ARRAYSZ, DT_PREINIT_ARRAY, DT_INIT_ARRAY, and
1008 DT_FINI_ARRAY.
1009
c8e5ddc8
AM
10102002-02-26 Andrew Macleod <amacleod@cygnus.com>
1011
1012 * elflink.h (elf_bfd_final_link): Don't crash on SHN_UNDEF local
1013 dynsyms.
1014
96e0dda4
AM
10152002-02-25 Alan Modra <amodra@bigpond.net.au>
1016
1c5b6bf8
AM
1017 * elf64-hppa.h: Update copyright date.
1018
96e0dda4
AM
1019 * elf64-ppc.c (ppc64_elf_check_relocs): Warning fix.
1020 (ppc64_elf_relocate_section): Don't generate power4 style branch
1021 hints for *_BRTAKEN and *_BRNTAKEN relocs.
1022
0fb19cbc
JJ
10232002-02-22 Jakub Jelinek <jakub@redhat.com>
1024
1025 * elf64-sh64.c (sh_elf64_relocate_section): Fix a typo from my
1026 last patch.
1027 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
1028
c434dee6
AJ
10292002-02-21 Andreas Jaeger <aj@suse.de>
1030
1031 * elf64-x86-64.c: Major rework that introduces all recent changes
1032 to the x86-64 backend. Get a closer match to elf32-i386.
1033 (struct elf64_x86_64_dyn_relocs): Rename from
1034 elf64_x86_64_pcrel_relocs_copied, add additional fields. Change
1035 all users.
1036 (struct elf64_x86_64_link_hash_table): Add short cuts to some
1037 sections.
1038 (link_hash_newfunc): Rename from elf64_x86_64_link_hash_newfunc,
1039 remove casts, initialize new hash members.
1040 (create_got_section): New.
1041 (elf64_x86_64_create_dynamic_sections): New.
1042 (elf64_x86_64_copy_indirect_symbol): New.
1043 (elf64_x86_64_check_relocs): Don't allocate space for dynamic
1044 relocs, .got or .relgot here but do it in allocate_dynrelocs.
1045 Reference count possible .plt and .got entries. Don't test input
1046 section SEC_READONLY here to try to avoid copy relocs, and keep
1047 dyn_relocs regardless of ELF_LINK_NON_GOT_REF. Don't set
1048 DF_TEXTREL here. Delay setting of variables until needed. Cache
1049 pointer to "sreloc" section in elf_section_data. Tweak condition
1050 under which .got created. Report files with bad relocation
1051 section names.
1052 (elf64_x86_64_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
1053 Reference count possible .plt entries. Don't deallocate .got and
1054 .relgot space here.
1055 (elf64_x86_64_adjust_dynamic_symbol): Handle nocopyreloc. Don't
1056 do copy reloc processing for weakdefs. Remove redundant casts and
1057 aborts. Delay setting of vars until needed. Move creation of
1058 dynamic symbols and allocation of .plt and .rela.plt to
1059 allocate_dynrelocs. Replace BFD_ASSERT with abort.
1060 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
1061 (allocate_dynrelocs): New.
1062 (readonly_dynrelocs): New.
1063 (elf64_x86_64_size_dynamic_sections): Call readonly_dynrelocs.
1064 Allocate space for dyn relocs. Replace BFD_ASSERT with abort.
1065 Zero out the dynamic allocated content space.
1066 (elf64_x86_64_discard_copies): Removed.
1067 (elf64_x86_64_relocate_section): Make use of dynamic section
1068 short-cuts. Localise vars, and delay setting. Better error
1069 reporting, replace BFD_ASSERT with abort. Check
1070 ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined in the
1071 regular object file and tread the weak definition as the normal
1072 one. Don't discard relocs for undefweak or undefined symbols and
1073 check !DEF_REGULAR as well as DEF_DYNAMIC in test for avoided copy
1074 relocs.
1075 (elf64_x86_64_finish_dynamic_symbol): Don't copy relocs for
1076 symbols that have been forced local. Use same test to decide if
1077 we can use a relative reloc for got as relocate_section. Expand
1078 SHN_UNDEF comment. Move expressions out of function calls.
1079 Replace BFD_ASSERT with abort.
1080 (bfd_elf64_bfd_final_link): Removed.
1081 (elf_backend_copy_indirect_symbol): Define.
1082
ff3a6ee3
TR
10832002-02-20 Tom Rix <trix@redhat.com>
1084
1085 * coff-rs6000.c (xcoff_howto_table): Add 16 bit R_BA.
1086 (_bfd_xcoff_reloc_type_lookup): Use it.
1087 * coff64-rs6000.c (xcoff64_howto_table): Same.
1088 (xcoff64_reloc_type_lookup): Same.
c434dee6 1089
a68d41fb
AM
10902002-02-20 Peter Schauer <pes@regent.e-technik.tu-muenchen.de>
1091
1092 * osf-core.c (osf_core_vec): OSF/1 (Digital Unix) core files are
1093 little endian.
1094
befc3abb
MS
10952002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
1096
1097 * archures.c (bfd_mach_s390_esa): Rename to bfd_mach_s390_31.
1098 (bfd_mach_s390_esame): Rename to bfd_mach_s390_64.
1099 * bfd-in2.h: Regenerate.
1100 * cpu-s390.c (arch_info_struct): Use renamed architecture defines.
1101 Replace architecture name "s390" with "s390:31-bit" and "s390:esame"
1102 with "s390:64-bit".
1103 * elf32-s390.c (elf_howto_table): Add 32 bit pc relative relocations.
1104 (elf_s390_reloc_type_lookup): Likewise.
1105 (elf_s390_check_relocs): Likewise.
1106 (elf_s390_gc_sweep_hook): Likewise.
1107 (elf_s390_relocate_section): Likewise.
1108 (elf_s390_object_p): Use renamed architecture define.
1109 * elf64-s390.c (elf_s390_object_p): Use renamed architecture define.
1110
6eeeec9b
FCE
11112002-02-19 Frank Ch. Eigler <fche@redhat.com>
1112
1113 * syms.c (stt[]): Sorted. Added .init/.fini -> "t" mapping.
1114
0bb2d96a
JJ
11152002-02-19 Jakub Jelinek <jakub@redhat.com>
1116
1117 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Enable
1118 absptr -> pcrel optimization for shared libs.
1119 Only create minimal .eh_frame_hdr if absptr FDE encoding in shared
1120 library cannot be converted to pcrel.
1121 (_bfd_elf_eh_frame_section_offset): Return -2 if making absptr
1122 relative.
1123 * elf32-i386.c (elf_i386_relocate_section): If
1124 _bfd_elf_section_offset returned -2, skip, but make sure the
1125 relocation is installed.
1126 * elf32-arm.h (elf32_arm_final_link_relocate): Likewise.
1127 * elf32-cris.c (cris_elf_relocate_section): Likewise.
1128 * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
1129 * elf32-i370.c (i370_elf_relocate_section): Likewise.
1130 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
1131 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
1132 * elf32-s390.c (elf_s390_relocate_section): Likewise.
1133 * elf32-sh.c (sh_elf_relocate_section): Likewise.
1134 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
1135 * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
1136 * elf64-s390.c (elf_s390_relocate_section): Likewise.
1137 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
1138 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
1139 * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
1140 * elf64-alpha.c (elf64_alpha_relocate_section): Handle
1141 _bfd_elf_section_offset returning -2 the same way as -1.
1142 * elfxx-ia64.c (elfNN_ia64_install_dyn_reloc): Likewise.
1143 * elf32-mips.c (mips_elf_create_dynamic_relocation): Add FIXME
1144 and BFD_ASSERT.
1145 * elf64-mips.c (mips_elf64_create_dynamic_relocation): Likewise.
1146
69f284c7
TR
11472002-02-18 Tom Rix <trix@redhat.com>
1148
1149 * xcofflink.c (bfd_xcoff_link_gernate_rtinit): Add -brtl support.
1150 (bfd_xcoff_size_dynamic_sections): Same.
1151 * bfd-in.h (bfd_xcoff_link_generate_rtinit): Same.
1152 (bfd_xcoff_size_dynamic_sections): Same.
1153 * coff-rs6000.c (xcoff_generate_rtinit): Same.
1154 * coff-rs646000.c (xcoff64_generate_rtinit): Same.
1155 * libxcoff.h (struct xcoff_backend_data_rec): Same.
1156 * xcofflink.c (xcoff_build_ldsyms, xcoff_link_add_symbols): Clean.
1157 * bfd-in2.h: Regenerate.
1158
82bd7b59
AM
11592002-02-18 Alan Modra <amodra@bigpond.net.au>
1160
1161 * elf64-ppc.c (STFD_FR0_0R1, LFD_FR0_0R1, BLR): Define.
1162 (struct ppc_link_hash_table): Add sfpr.
1163 (ppc64_elf_link_hash_table_create): Init it.
1164 (ppc64_elf_create_dynamic_sections): Split creation of .stub and
1165 .glink out to..
1166 (create_linkage_sections): ..here. Make .sfpr too.
1167 (ppc64_elf_check_relocs): Call create_linkage_sections, and set
1168 dynobj early.
1169 (MIN_SAVE_FPR, MAX_SAVE_FPR): Define.
1170 (ppc64_elf_func_desc_adjust): Look for missing ._savef* and
1171 ._restf* functions, and create as needed.
1172 (func_desc_adjust): Only force_local for shared libs.
1173
ef1355e8
NC
11742002-02-18 David O'Brien <obrien@FreeBSD.org>
1175
1176 * configure.in: Bump version number post 2.12 branching.
1177 * configure: Regenerate.
1178
dfa36a69
HPN
11792002-02-17 Hans-Peter Nilsson <hp@bitrange.com>
1180
1181 * mmo.c: Correct and improve comments.
1182 (mmo_write_chunk): Store trailing byte in bfd buffer; don't
1183 zero-pad. Use input to fill up non-empty bfd buffer.
1184 (mmo_flush_chunk): New function.
1185 (mmo_write_loc_chunk): Add parameter last_vmap, all callers
1186 changed. Don't emit location specifier if VMA is same as
1187 *LAST_VMAP after omitting leading zero contents. Call
1188 mmo_flush_chunk before emitting location specifier.
1189 (mmo_write_loc_chunk_list): Call mmo_flush_chunk when finished
1190 with mmo_write_loc_chunk calls.
1191 (mmo_internal_write_section): Call mmo_flush_chunk after
1192 mmo_write_chunk.
1193 (mmo_write_symbols_and_terminator): Move :Main to first position
1194 in symbol array. Add faked one if it does not exist if there are
1195 other symbols. Don't add it if there are no symbols at all. Move
1196 out test for value of :Main from symbol loop. Rename table
1197 fakemain to maintable and variable mainsym to fakemain.
1198
ccf00ab6
RH
11992002-02-15 Richard Henderson <rth@redhat.com>
1200
1201 * elf64-alpha.c (elf64_alpha_relocate_section) [BRSGP]: A target
1202 section with no got matches any got. Simplify error generaion.
1203
88eaccc2
AM
12042002-02-15 Alan Modra <amodra@bigpond.net.au>
1205
fd96f80f
AM
1206 Support arbitrary length fill patterns.
1207 * linker.c (bfd_new_link_order): Zero all fields with bfd_zalloc.
1208 (_bfd_default_link_order): Remove bfd_fill_link_order code.
1209 Call default_data_link_order.
1210 (default_fill_link_order): Delete.
1211 (default_data_link_order): New function.
1212 * elf32-mips.c (_bfd_mips_elf_final_link): Replace occurrences
1213 of bfd_fill_link_order with bfd_data_link_order.
1214 * elf64-alpha.c (elf64_alpha_final_link): Likewise.
1215 * elf64-mips.c (mips_elf64_final_link): Likewise.
1216
88eaccc2
AM
1217 * bfd.c (bfd_scan_vma): Clamp overflows to max bfd_vma value.
1218 Correct value returned in "end" for "0x<non-hex>".
1219
e2fd756b
NC
12202002-02-14 Nick Clifton <nickc@cambridge.redhat.com>
1221
1222 * cpu-arm.c (processors): Replace 'arch' field with 'mach'.
1223 (scan): Test against 'mach' field in info structure.
1224
edd29cf9
AM
12252002-02-14 Alan Modra <amodra@bigpond.net.au>
1226
1227 * elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD.
1228
1e30956e 12292002-02-14 Matt Fredette <fredette@netbsd.org>
76f57f3a
JT
1230
1231 * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Recognize
1232 EF_M68000.
1233
bf36db18
NC
12342002-02-13 Nick Clifton <nickc@cambridge.redhat.com>
1235
1236 * elf.c (_bfd_elf_make_section_from_shdr): Do not insist on
edd29cf9
AM
1237 non-zero physical addresses when adjusting the LMAs of new
1238 sections.
bf36db18 1239
189c6563
AM
12402002-02-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
1241
1242 * elf-hppa.h (elf_hppa_reloc_final_type): New function stripped
1243 from _bfd_elf_hppa_gen_reloc_type.
1244 (_bfd_elf_hppa_gen_reloc_type): Remove duplicate prototype.
1245 * elf32-hppa.h (elf32_hppa_reloc_final_type): Add protptype.
1246 * elf32-hppa.c: Include elf32-hppa.h before elf-hppa.h.
1247 * elf64-hppa.h (elf64_hppa_reloc_final_type): Add protptype.
1248
e948afaf
AO
12492002-02-12 Alexandre Oliva <aoliva@redhat.com>
1250
1251 * elf-m10300.c (mn10300_elf_relax_section): Skip section before
1252 loading its contents if there's nothing to do in it.
1253
19397422
AM
12542002-02-12 Alan Modra <amodra@bigpond.net.au>
1255
0ad3a73b
AM
1256 * elf64-ppc.c (ppc64_elf_size_stubs): Correct test for crossing
1257 64k boundary.
1258
19397422
AM
1259 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Add dynamic
1260 DT_PPC64_OPD and DT_PPC64_OPDSZ tags.
1261 (ppc64_elf_finish_dynamic_sections): Set values for them.
1262
51316059
MS
12632002-02-11 Michael Snyder <msnyder@redhat.com>
1264
1265 * elf-bfd.h (elfcore_write_lwpstatus): Add prototype.
1266 * elf.c (elfcore_grok_pstatus): Add prototype.
1267 (elfcore_grok_lwpstatus): Add prototype.
1268 (elfcore_write_lwpstatus): New function.
1269 (elfcore_write_pstatus): Fix typo, eliminate unnecessary memcpy.
1270
518313c3
AO
12712002-02-11 Alexandre Oliva <aoliva@redhat.com>
1272
1273 * elf32-sh.c: Added missing prototypes.
1274 * elf32-sh64.c: Likewise.
1275 (sh_elf_align_loads): Mark unused args as such.
1276 * elf64-sh64.c: Added missing prototypes.
1277 (struct elf_sh64_link_hash_entry): Fix typo.
1278 (sh_elf64_relocate_section): Fix info argument passed to
1279 _bfd_elf_section_offset.
1280
2c73f9d8
AM
12812002-02-11 Alan Modra <amodra@bigpond.net.au>
1282
1283 * Makefile.am: "make dep-am".
1284 * Makefile.in: Regenerate.
1285 * aclocal.m4: Regenerate.
1286 * config.in: Regenerate.
1287 * configure: Regenerate.
1288
d426c6b0
DJ
12892002-02-10 Daniel Jacobowitz <drow@mvista.com>
1290
1291 * coff-rs6000.c (xcoff_generate_rtinit): Silence uninitialized
1292 variable warnings.
1293 * elf32-sh.c (sh_elf_relax_section): Silence signed/unsigned
1294 comparison warning.
1295 * trad-core.c (trad_unix_core_file_p): Silence pointer/integer
1296 cast warnings for the common case.
1297
e58ee0cd
HPN
12982002-02-10 Hans-Peter Nilsson <hp@bitrange.com>
1299
1300 * config.bfd (sh-*-linux*, sh-*-elf* | sh-*-rtemself*): Add sh64
1301 vectors.
1302 (sh-*-netbsdelf*): New, to trump sh*-*-netbsdelf* and add sh64
1303 vectors.
1304
7793f4d0
RH
13052002-02-09 Richard Henderson <rth@redhat.com>
1306
1307 * elf64-alpha.c (elf64_alpha_howto): Add R_ALPHA_BRSGP.
1308 (elf64_alpha_reloc_map, elf64_alpha_check_relocs): Likewise.
1309 (elf64_alpha_relocate_section): Likewise.
1310 * reloc.c (BFD_RELOC_ALPHA_BRSGP): New.
1311 * bfd-in2.h, libbfd.h: Rebuild.
1312
7e799044
HPN
13132002-02-09 Hans-Peter Nilsson <hp@bitrange.com>
1314
1315 * elf64-mmix.c (_bfd_mmix_finalize_linker_allocated_gregs): Check
1316 that base-plus-offset reloc accounting is consistent.
1317 (mmix_elf_relax_section): Keep base-plus-offset reloc accounting
1318 up to date for undefined symbols.
1319
027d73eb
EC
13202002-02-08 Eric Christopher <echristo@redhat.com>
1321
1322 From Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
1323
1324 * elf32-mips.c (_bfd_mips_elf_fake_sections): Don't create .rela
1325 sections for the O32 ABI.
1326
517662d4
CD
13272002-02-08 Chris Demetriou <cgd@broadcom.com>
1328
1329 * elf32-arm.h: Fix formatting of _("...").
1330 * elf32-d10v.c: Likewise.
1331 * elf32-m68k.c: Likewise.
1332 * elf32-mips.c: Likewise.
1333
5e37cc46
NC
13342002-02-08 Ivan Guzvinec <ivang@opencores.org>
1335
1336 * coff-or32.c: Fix compile time warning messages.
1337
fbca6ad9
AO
13382002-02-08 Alexandre Oliva <aoliva@redhat.com>
1339
1340 Contribute sh64-elf.
1341 2002-01-23 Alexandre Oliva <aoliva@redhat.com>
1342 * reloc.c (R_SH_GOTPLT32, R_SH_GOT_LOW16, R_SH_GOT_MEDLOW16,
1343 R_SH_GOT_MEDHI16, R_SH_GOT_HI16, R_SH_GOTPLT_LOW16,
1344 R_SH_GOTPLT_MEDLOW16, R_SH_GOTPLT_MEDHI16, R_SH_GOTPLT_HI16,
1345 R_SH_PLT_LOW16, R_SH_PLT_MEDLOW16, R_SH_PLT_MEDHI16,
1346 R_SH_PLT_HI16, R_SH_GOTOFF_LOW16, R_SH_GOTOFF_MEDLOW16,
1347 R_SH_GOTOFF_MEDHI16, R_SH_GOTOFF_HI16, R_SH_GOTPC_LOW16,
1348 R_SH_GOTPC_MEDLOW16, R_SH_GOTPC_MEDHI16, R_SH_GOTPC_HI16,
1349 R_SH_GOT10BY4, R_SH_GOTPLT10BY4, R_SH_GOT10BY8, R_SH_GOTPLT10BY8,
1350 R_SH_COPY64, R_SH_GLOB_DAT64, R_SH_JMP_SLOT64, R_SH_RELATIVE64):
1351 New relocs.
1352 * libbfd.h, bfd-in2.h: Rebuilt.
1353 * elf32-sh.c (sh_elf_howto_table): Define new relocs.
1354 (sh_reloc_map): Map them.
1355 (PLT_ENTRY_SIZE, elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
1356 elf_sh_plt_entry_be, elf_sh_plt_entry_le, elf_sh_pic_plt_entry_be,
1357 elf_sh_pic_plt_entry_le, elf_sh_plt0_entry, elf_sh_plt_entry,
1358 elf_sh_pic_plt_entry, elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
1359 elf_sh_plt0_gotplt_offset, elf_sh_plt_temp_offset,
1360 elf_sh_plt_symbol_offset, elf_sh_plt_reloc_offset,
1361 movi_shori_putval) [INCLUDE_SHMEDIA]: New.
1362 (elf_sh_link_hash_entry) [INCLUDE_SHMEDIA]: Add
1363 datalabel_got_offset.
1364 (sh_elf_link_hash_newfunc): Initialize it.
1365 (sh_elf_relocate_section): Augment the scope of
1366 seen_stt_datalabel. Introduce GOTPLT support. Extend GOTPC, PLT,
1367 GOT and GOTOFF handling to new SHmedia relocation types. Support
1368 GOT_BIAS.
1369 (sh_elf_check_relocs): Likewise.
1370 (sh_elf_finish_dynamic_symbol) [TARGET_SHMEDIA]: Set up values in
1371 PLT entries using movi_shori_putval. Support GOT_BIAS.
1372 (sh_elf_finish_dynamic_sections): Likewise.
1373 * elf32-sh64.c (shmedia_prepare_reloc): Do not add addend to
1374 relocation, it's now done by the caller.
1375 (GOT_BIAS): New.
1376 * elf64-sh64.c (GOT_BIAS, PLT_ENTRY_SIZE, elf_sh64_sizeof_plt,
1377 elf_sh64_plt_plt0_offset, elf_sh64_plt0_gotplt_offset,
1378 elf_sh64_plt_temp_offset, elf_sh64_plt_symbol_offset,
1379 elf_sh64_plt_reloc_offset, ELF_DYNAMIC_INTERPRETER,
1380 elf_sh64_pcrel_relocs_copied, elf_sh64_link_hash_entry,
1381 elf_sh64_link_hash_table, sh64_elf64_link_hash_traverse,
1382 sh64_elf64_hash_table): New.
1383 (sh_elf64_howto_table): Introduce new relocs.
1384 (sh_elf64_info_to_howto): Accept new PIC relocs.
1385 (sh_elf64_relocate_section): Augment the scope of
1386 seen_stt_datalabel. Support new PIC relocs.
1387 (sh_elf64_check_relocs): Support new PIC relocs.
1388 (elf_sh64_plt0_entry_be, elf_sh64_plt0_entry_le,
1389 elf_sh64_plt_entry_be, elf_sh64_plt_entry_le,
1390 elf_sh64_pic_plt_entry_be, elf_sh64_pic_plt_entry_le,
1391 elf_sh64_plt0_entry, elf_sh64_plt_entry, elf_sh64_pic_plt_entry,
1392 sh64_elf64_link_hash_newfunc, sh64_elf64_link_hash_table_create,
1393 movi_shori_putval, movi_3shori_putval,
1394 sh64_elf64_create_dynamic_sections,
1395 sh64_elf64_adjust_dynamic_symbol, sh64_elf64_discard_copies,
1396 sh64_elf64_size_dynamic_sections,
1397 sh64_elf64_finish_dynamic_symbol,
1398 sh64_elf64_finish_dynamic_sections): New.
1399 (elf_backend_create_dynamic-sections,
1400 bfd_elf64_bfd_link_hash_table_create,
1401 elf_backend_adjust_dynamic_symbol,
1402 elf_backend_size_dynamic_sections,
1403 elf_backend_finish_dynamic_symbol,
1404 elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
1405 elf_backend_plt_readonly, elf_backend_want_plt_sym,
1406 elf_backend_got_header_size, elf_backend_plt_header_size):
1407 Define.
1408 2001-05-16 Alexandre Oliva <aoliva@redhat.com>
1409 * elf32-sh.c: Renumbered and renamed some SH5 relocations to
1410 match official numbers and names; moved unmaching ones to the
1411 range 0xf2-0xff.
1412 * elf32-sh64.c, elf64-sh64.c: Likewise.
1413 2001-03-12 DJ Delorie <dj@redhat.com>
1414 * elf32-sh.c (sh_elf_relax_section): Don't relax SHmedia
1415 sections.
1416 2001-03-12 DJ Delorie <dj@redhat.com>
1417 * elf32-sh64.c (shmedia_prepare_reloc): Validate relocs that must
1418 be aligned.
1419 * elf64-sh64.c (sh_elf64_relocate_section): Ditto.
1420 2001-01-14 Hans-Peter Nilsson <hpn@cygnus.com>
1421 * elf32-sh64.c (bfd_elf32_bfd_copy_private_section_data): Define.
1422 (sh64_elf_fake_sections): Set type to SHT_SH5_CR_SORTED for a
1423 .cranges section with SEC_SORT_ENTRIES set.
1424 (sh64_backend_section_from_shdr): Set SEC_SORT_ENTRIES on an
1425 incoming sorted .cranges section.
1426 (sh64_bfd_elf_copy_private_section_data): New.
1427 (sh64_elf_final_write_processing): Only sort .cranges and modify
1428 start address if called by linker.
1429 2001-01-08 Ben Elliston <bje@redhat.com>
1430 * elf32-sh64.c (sh64_elf_final_write_processing): Activate
1431 Hans-Peter Nilsson's set bit 0 patch from 2001-01-06.
1432 * elf64-sh64.c (sh64_elf64_final_write_processing): Ditto.
1433 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
1434 * elf64-sh64.c (sh_elf64_howto_table): No open brace at start of
1435 line. Add comments before all entries.
1436 <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct and clarify describing
1437 comment.
1438 (sh_elf64_reloc): Correct head comment.
1439 (sh_elf64_relocate_section): Correct spacing.
1440 <relocating for a local symbol>: Do not honour STO_SH5_ISA32;
1441 instead call reloc_dangerous callback.
1442 <case R_SH_SHMEDIA_CODE>: New case.
1443 (sh_elf64_gc_mark_hook): Correct spacing.
1444 (sh_elf64_check_relocs): Ditto.
1445 * elf32-sh64.c (shmedia_prepare_reloc) <case R_SH_SHMEDIA_CODE>:
1446 New case.
1447 * elf32-sh.c: Correct #endif comments for #ifndef-wrapped
1448 functions.
1449 (sh_elf_howto_table) <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct,
1450 clarify describing comment. Add comments before all entries.
1451 (sh_elf_relocate_section) <relocating for a local symbol>: Do not
1452 honour STO_SH5_ISA32; instead call reloc_dangerous callback.
1453 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
1454 Sort .cranges section in final link. Prepare to set bit 0 on
1455 entry address.
1456 * elf32-sh64.c (struct sh64_find_section_vma_data): New.
1457 (sh64_elf_link_output_symbol_hook): Fix typo in prototype.
1458 (sh64_elf_set_mach_from_flags): Set SEC_DEBUGGING on incoming
1459 .cranges section.
1460 (sh64_backend_section_from_shdr): New, to recognize
1461 SHT_SH5_CR_SORTED on incoming .cranges section.
1462 (elf_backend_section_from_shdr): Define.
1463 (sh64_elf_final_write_processing): Sort outgoing .cranges
1464 section. (New, temporarily disabled:) Set bit 0 on entry address
1465 according to ISA type.
1466 (sh64_find_section_for_address): New.
1467 (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb,
1468 crange_bsearch_cmpl): Move here from opcodes/sh64-dis.c.
1469 (sh64_address_in_cranges): Move here from opcodes/sh64-dis.c. Use
1470 bfd_malloc, not xmalloc.
1471 (sh64_get_contents_type): Move here from opcodes/sh64-dis.c. Make
1472 global.
1473 * elf32-sh64.c (sh64_elf64_final_write_processing): New, (but
1474 temporarily disabled) setting bit 0 on entry address.
1475 (elf_backend_final_write_processing): Define.
1476 2001-01-05 Hans-Peter Nilsson <hpn@cygnus.com>
1477 * elf32-sh.c (sh_elf_howto_table) <R_SH_PT_16>: Adjust fields to
1478 be a proper relocation for PTA and PTB rather than a marker.
1479 <R_SH_IMMU5, R_SH_IMMS6, R_SH_IMMU6, R_SH_IMMS10, R_SH_IMMS10BY2,
1480 R_SH_IMMS10BY4, R_SH_IMMS10BY8, R_SH_IMMS16, R_SH_IMMU16,
1481 R_SH_IMM_LOW16, R_SH_IMM_LOW16_PCREL, R_SH_IMM_MEDLOW16,
1482 R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16, R_SH_IMM_MEDHI16_PCREL,
1483 R_SH_IMM_HI16, R_SH_IMM_HI16_PCREL, R_SH_64, R_SH_64_PCREL>:
1484 Zero src_mask.
1485 * elf64-sh64.c: Ditto.
1486 (sh_elf64_relocate_section) <case R_SH_PT_16>: New case.
1487 * elf32-sh64.c: Include opcodes/sh64-opc.h
1488 (shmedia_prepare_reloc): Take a bfd_link_info pointer as first
1489 argument. Drop const qualifiers from "bfd *" and "bfd_byte *"
1490 parameters. No unused parameters. Caller changed.
1491 <case R_SH_PT_16>: New case.
1492 * Makefile.am (elf32-sh64.lo): Add dependency on sh64-opc.h.
1493 * Makefile.in: Regenerate.
1494 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
1495 * elf64-sh64.c (sh64_elf64_fake_sections): Set SHF_SH5_ISA32 for
1496 all code sections.
1497 (sh_elf64_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
1498 (sh64_elf_merge_private_data): Ditto.
1499 * elf32-sh64.c (sh64_elf_fake_sections): Use sh64_elf_section_data
1500 to access stored section flags.
1501 (sh64_elf_final_write_processing): Return immediately unless
1502 called by linker. Use sh64_elf_section_data (cranges) to get size
1503 of linker-generated cranges entries.
1504 (sh64_elf_copy_private_data): Add missing "return true".
1505 (sh64_elf_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
1506 (sh_elf64_merge_private_data): Ditto.
1507 2000-12-19 Hans-Peter Nilsson <hpn@cygnus.com>
1508 * elf64-sh64.c (sh64_elf64_fake_sections): New, copy of
1509 elf64-sh64.c:sh64_elf_fake_sections.
1510 (elf_backend_fake_sections): Define as sh64_elf64_fake_sections.
1511 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
1512 * elf32-sh64.c (sh64_elf_copy_private_data_internal): Delete.
1513 (sh64_elf_final_write_processing): New.
1514 (elf_backend_final_write_processing): Define.
1515 (sh64_elf_fake_sections): Get header flags from tdata field.
1516 (sh64_elf_copy_private_data): Do not call
1517 sh64_elf_copy_private_data_internal, just copy e_flags field.
1518 (sh64_elf_merge_private_data): Do not call
1519 sh64_elf_copy_private_data_internal.
1520 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
1521 Remove EF_SH64_ABI64, let ELF size make difference.
1522 Remove SH64-specific BFD section flag.
1523 * elf32-sh64.c (sh64_elf_fake_sections): Recognize section as
1524 containing SHmedia through elf_section_data (asect)->tdata
1525 non-zero, not using a BFD section flag.
1526 (sh64_elf_set_mach_from_flags): Don't recognize EF_SH64_ABI64.
1527 (sh64_elf_merge_private_data): Similar.
1528 (elf_backend_section_flags): Don't define.
1529 (sh64_elf_backend_section_flags): Delete.
1530 * elf64-sh64.c (sh_elf64_set_mach_from_flags): Recognize EF_SH64,
1531 not EF_SH64_ABI64.
1532 (sh_elf64_merge_private_data): Similar.
1533 * section.c (Section flags definitions): Don't define
1534 SEC_SH_ISA_SHMEDIA.
1535 (bfd-in2.h): Regenerate.
1536 2000-12-09 Hans-Peter Nilsson <hpn@cygnus.com>
1537 Make DataLabel references work with partial linking.
1538 * elf32-sh64.c: Fix formatting.
1539 (sh64_elf_link_output_symbol_hook): New.
1540 (elf_backend_link_output_symbol_hook): Define to
1541 sh64_elf_link_output_symbol_hook.
1542 (sh64_elf_add_symbol_hook): Make DataLabel symbol just global
1543 undefined if partial linking. Adjust sanity check.
1544 * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): New.
1545 (elf_backend_link_output_symbol_hook): Define to
1546 sh64_elf64_link_output_symbol_hook.
1547 (sh64_elf64_add_symbol_hook): Make DataLabel symbol just global
1548 undefined if partial linking. Adjust sanity check.
1549 2000-12-07 Hans-Peter Nilsson <hpn@cygnus.com>
1550 Implement semantics for inter-file DataLabel references.
1551 * elf64-sh64.c (DATALABEL_SUFFIX): Define.
1552 (sh64_elf64_add_symbol_hook): New.
1553 (sh_elf64_relocate_section): If passing an indirect symbol with
1554 st_type STT_DATALABEL on the way to a symbol with st_other
1555 STO_SH5_ISA32, do not bitor 1 to the relocation.
1556 (elf_backend_add_symbol_hook): Define to
1557 sh64_elf64_add_symbol_hook.
1558 * elf64-sh32.c: Tweak comments.
1559 (DATALABEL_SUFFIX): Define.
1560 (sh64_elf_add_symbol_hook): New.
1561 (elf_backend_add_symbol_hook): Define to sh64_elf_add_symbol_hook.
1562 * elf32-sh.c (sh_elf_relocate_section): If passing an indirect
1563 symbol with st_type STT_DATALABEL on the way to a symbol with
1564 st_other STO_SH5_ISA32, do not bitor 1 to the relocation.
1565 2000-12-05 Hans-Peter Nilsson <hpn@cygnus.com>
1566 Pass through STT_DATALABEL.
1567 * elf32-sh64.c (sh64_elf_get_symbol_type): New.
1568 (elf_backend_get_symbol_type): Define.
1569 * elf64-sh64.c (sh64_elf64_get_symbol_type): New.
1570 (elf_backend_get_symbol_type): Define.
1571 2000-11-30 Hans-Peter Nilsson <hpn@cygnus.com>
1572 * elf32-sh64.c: Tweak comments.
1573 (sh64_elf_copy_private_data_internal): Add prototype.
1574 (bfd_elf32_bfd_set_private_flags): Define.
1575 (sh64_elf_copy_private_data_internal): Compare machine name, not
1576 textual BFD target name, to check whether to copy section flag
1577 SHF_SH5_ISA32.
1578 (sh64_elf_merge_private_data): Validize bfd_get_arch_size.
1579 Tweak section-contents-type-mismatch message.
1580 (shmedia_prepare_reloc): Add ATTRIBUTE_UNUSED markers.
1581 Validize reloc-types.
1582 * elf64-sh64.c: New file.
1583 * targets.c (bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec): Declare.
1584 * Makefile.am (BFD64_BACKENDS): Add elf64-sh64.lo.
1585 (BFD64_BACKENDS_CFILES): Add elf64-sh64.c.
1586 Regenerate dependencies.
1587 * Makefile.in: Regenerate.
1588 * config.bfd (sh64-*-elf*): Add bfd_elf64_sh64_vec and
1589 bfd_elf64_sh64l_vec.
1590 * configure.in: Handle bfd_elf64_sh64_vec and
1591 bfd_elf64_sh64l_vec.
1592 * configure: Regenerate.
1593 * po/POTFILES.in: Regenerate.
1594 * po/bfd.pot: Regenerate.
1595 2000-11-29 Hans-Peter Nilsson <hpn@cygnus.com>
1596 * elf32-sh64.c (sh64_elf_set_mach_from_flags): Do not recognize
1597 anything else but EF_SH64 and EF_SH64_ABI64.
1598 (sh64_elf_merge_private_data): Emit error for anything else but
1599 EF_SH64 and EF_SH64_ABI64.
1600 * config.bfd: Remove bfd_elf32_shblin_vec and bfd_elf32_shlin_vec
1601 from targ_selvecs.
1602 * configure.in: Add cofflink.lo to bfd_elf32_sh64_vec and
1603 bfd_elf32_sh64l_vec as a temporary measure.
1604 * configure: Regenerate.
1605 2000-11-27 Hans-Peter Nilsson <hpn@cygnus.com>
1606 * cpu-sh.c (arch_info_struct): Include sh5 item
1607 unconditionalized.
1608 * config.bfd (sh64-*-elf*): Do not set targ_cflags.
1609 Add targ_selvecs bfd_elf32_sh_vec, bfd_elf32_shl_vec,
1610 bfd_elf32_shblin_vec and bfd_elf32_shlin_vec.
1611 * elf32-sh64.c: Tweak comments.
1612 (sh64_elf_set_mach_from_flags): Recognize all machine flags that
1613 are proper subsets of SH64 as bfd_mach_sh5. Add EF_SH64_ABI64.
1614 (sh64_elf_copy_private_data_internal): Wrap long line.
1615 (sh64_elf_merge_private_data): Rewrite to allow objects from
1616 SH64 subsets to be linked together.
1617 (INCLUDE_SHMEDIA): Define.
1618 * elf32-sh.c (sh_elf_relocate_section) <local symbol>:
1619 Parenthesize plus-expression inside or-expression.
1620 <global symbol>: Ditto.
1621 (sh_elf_set_mach_from_flags): Remove code refusing
1622 deleted EF_SH64_32BIT_ABI flag.
1623 2000-11-26 Hans-Peter Nilsson <hpn@cygnus.com>
1624 * elf32-sh.c (sh_elf_howto_table) <R_SH_IMM_LOW16_PCREL,
1625 R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16_PCREL,
1626 R_SH_IMM_HI16_PCREL, R_SH_64_PCREL>: Set pcrel_offset to true.
1627 (sh_elf_relocate_section) <local symbol>: Or 1 in
1628 calculation of relocation if sym->st_other & STO_SH5_ISA32.
1629 <global symbol>: Ditto if h->other & STO_SH5_ISA32.
1630 * elf32-sh64.c (shmedia_prepare_reloc): Add rel->r_addend to
1631 relocation.
1632 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
1633 * Makefile.am (BFD32_BACKENDS): Add elf32-sh64.lo.
1634 (BFD32_BACKENDS_CFILES): Add elf32-sh64.c.
1635 Regenerate dependencies.
1636 * Makefile.in: Regenerate.
1637 * archures.c: Add bfd_mach_sh5.
1638 * config.bfd: Map targ_cpu sh* to bfd_sh_arch.
1639 Handle sh64-*-elf*. Set targ_cflags to -DINCLUDE_SHMEDIA.
1640 * configure.in: Handle bfd_elf32_sh64_vec and bfd_elf32_sh64l_vec.
1641 * configure: Regenerate.
1642 * reloc.c (BFD_RELOC_SH_SHMEDIA_CODE, BFD_RELOC_SH_IMMU5,
1643 BFD_RELOC_SH_IMMS6, BFD_RELOC_SH_IMMS6BY32, BFD_RELOC_SH_IMMU6,
1644 BFD_RELOC_SH_IMMS10, BFD_RELOC_SH_IMMS10BY2,
1645 BFD_RELOC_SH_IMMS10BY4, BFD_RELOC_SH_IMMS10BY8,
1646 BFD_RELOC_SH_IMMS16, BFD_RELOC_SH_IMMU16, BFD_RELOC_SH_IMM_LOW16,
1647 BFD_RELOC_SH_IMM_LOW16_PCREL, BFD_RELOC_SH_IMM_MEDLOW16,
1648 BFD_RELOC_SH_IMM_MEDLOW16_PCREL, BFD_RELOC_SH_IMM_MEDHI16,
1649 BFD_RELOC_SH_IMM_MEDHI16_PCREL, BFD_RELOC_SH_IMM_HI16,
1650 BFD_RELOC_SH_IMM_HI16_PCREL, BFD_RELOC_SH_PT_16): New relocations.
1651 * cpu-sh.c [INCLUDE_SHMEDIA] (arch_info_struct): Define and link
1652 in item for SH5.
1653 * elf32-sh.c [INCLUDE_SHMEDIA] (sh_elf_howto_table): Add howto items
1654 for SHmedia relocs.
1655 [INCLUDE_SHMEDIA] (sh_rel): Add mappings for SHmedia relocs.
1656 [INCLUDE_SHMEDIA] (sh_elf_relocate_section) [default]: Call
1657 shmedia_prepare_reloc, goto final_link_relocate if it returns
1658 non-zero, else fail as before.
1659 (sh_elf_set_mach_from_flags): Provide function only if not defined
1660 as macro. Do not recognize objects with EF_SH64_32BIT_ABI set.
1661 (sh_elf_set_private_flags): Provide function only if not defined
1662 as a macro.
1663 (sh_elf_copy_private_data): Similar.
1664 (sh_elf_merge_private_data): Similar.
1665 * section.c (SEC_SH_ISA_SHMEDIA): New.
1666 * targets.c (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec): Declare.
1667 * elf32-sh64.c: New file.
1668 * libbfd.h: Regenerate.
1669 * bfd-in2.h: Regenerate.
1670 * po/POTFILES.in: Regenerate.
1671 * po/bfd.pot: Regenerate.
1672 * bfd-in2.h: Regenerate.
1673 * libbfd.h: Regenerate.
1674
e108f470
DJ
16752002-02-07 Daniel Jacobowitz <drow@mvista.com>
1676
1677 * bfd-in.h: Update <stdbool.h> check to only see if <stdbool.h> has
1678 been included, not drag it in.
1679 * bfd-in2.h: Regenerate.
1680
259d18a3
L
16812002-02-06 H.J. Lu (hjl@gnu.org)
1682
1683 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Update
1684 the mach and ISA fields if necessary.
1685
f13b834e
NC
16862002-02-06 Nick Clifton <nickc@cambridge.redhat.com>
1687
1688 * coffcode.h (coff_set_arch_mach_hook): Select the highest known
1689 ARM architecture when an F_ARM_5 flag is detected, since we cannot
1690 be sure exactly which architecture this represents.
1691
82f6addb
NC
16922002-02-05 Nick Clifton <nickc@redhat.com>
1693
1694 * po/tr.po: Updated translation.
1695
899f54f5
AM
16962002-02-05 Alan Modra <amodra@bigpond.net.au>
1697
1698 From Jimi X <jimix@watson.ibm.com>
1699 * archures (bfd_mach_ppc64): Define.
1700 (bfd_powerpc_arch): Rename to bfd_powerpc_archs.
1701 (bfd_powerpc_arch): Define.
1702 * bfd-in2.h: Regenerate.
1703 * cpu-powerpc.c (arch_info_struct): Rename to bfd_powerpc_archs.
1704 (bfd_powerpc_arch): Move to tail of bfd_powerpc_archs.
1705 (bfd_powerpc_archs): Add default powerpc64 arch.
1706
248866a8
AM
17072002-02-05 Alan Modra <amodra@bigpond.net.au>
1708
1709 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Check for relocs
1710 against section syms in readonly sections. Don't do the global
1711 sym check if we find one.
1712 * elf64-s390.c (elf_s390_size_dynamic_sections): Likewise.
1713 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Likewise.
0a6958db 1714 * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
248866a8
AM
1715 * elf32-s390.c (elf_s390_size_dynamic_sections): Likewise.
1716 (elf_s390_grok_prstatus): Add missing prototype.
1717
4fa5c2a8
HPN
17182002-02-04 Hans-Peter Nilsson <hp@bitrange.com>
1719
1720 * elf64-mmix.c (mmix_dump_bpo_gregs): New function.
1721 (mmix_elf_check_common_relocs) <case R_MMIX_BASE_PLUS_OFFSET>:
1722 Call bfd_get_section_by_name only once. Initialize
1723 bpodata->n_bpo_relocs_this_section.
1724 (_bfd_mmix_prepare_linker_allocated_gregs): Remove comment
1725 referring to DSOs.
1726 (bpo_reloc_request_sort_fn): Don't use difference of values as
1727 return-value.
1728
537c972e
DB
17292002-02-02 David O'Brien <obrien@FreeBSD>
1730
1731 * configure.in: Tweak the FreeBSD 4.x recognition more. Only treat
1732 version 4.5 and later the same as 5-CURRENT.
1733 * configure: Re-generate.
1734
006336b8
JT
17352002-02-02 Jason Thorpe <thorpej@wasabisystems.com>
1736
1737 * config.bfd (hppa*-*-netbsd*): New target.
1738
6c571f00
PT
17392002-01-31 Philipp Thomas <pthomas@suse.de>
1740
19397422
AM
1741 * coff-arm.c (coff_arm_merge_private_bfd_data): Move ERROR
1742 to front of message. Unify messages with elf32-arm.h. Use
1743 commas where neccessary.
1744 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Use all upcase
1745 ERROR in messages. Unify messages with coff-arm.c. Correct
1746 VFP/FPA error message.
1747 (elf32_arm_print_private_bfd_data): Don't mark APCS-26 and
1748 APCS-32 for translation.
6c571f00 1749
930b4cb2
HPN
17502002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
1751
1752 Perform on-demand global register allocation from
1753 R_MMIX_BASE_PLUS_OFFSET relocs.
1754 * elf64-mmix.c (struct bpo_reloc_section_info, struct
1755 bpo_reloc_request, struct bpo_greg_section_info): New.
1756 (mmix_elf_check_common_relocs, mmix_elf_gc_sweep_hook,
1757 bpo_reloc_request_sort_fn, mmix_elf_relax_section,
1758 _bfd_mmix_check_all_relocs,
1759 _bfd_mmix_prepare_linker_allocated_gregs,
1760 _bfd_mmix_finalize_linker_allocated_gregs): New functions.
1761 (elf_mmix_howto_table): Correct src_mask for most relocs.
1762 (mmix_elf_perform_relocation) <case R_MMIX_BASE_PLUS_OFFSET>: New
1763 case.
1764 (mmix_final_link_relocate) <case R_MMIX_BASE_PLUS_OFFSET>: New
1765 case. Fix typo in comment. New label do_mmix_reloc.
1766 (mmix_elf_check_relocs): Abuse bfd_link_info member base_file to
1767 store first object file with a base-plus-offset reloc. Call
1768 mmix_elf_check_common_relocs for the part common with mmo.
1769 (mmix_elf_final_link): Write out linker-allocated register
1770 contents section.
1771 (elf_backend_gc_sweep_hook): Define.
1772 (bfd_elf64_bfd_relax_section): Define.
1773
1774 * mmo.c: Don't include <ctype.h>
1775 (mmo_init): Correct init-once logic.
1776
3e36d993
TR
17772002-02-01 Tom Rix <trix@redhat.com>
1778
1779 * config.bfd: Conditionally support <aiaff> for pre AIX 4.3.
1780
ba323545
AM
17812002-02-01 Alan Modra <amodra@bigpond.net.au>
1782
1783 * Makefile.am: Run "make dep-am"
1784 * Makefile.in: Regenerate.
1785
012884d6
DB
17862002-01-31 David O'Brien <obrien@FreeBSD>
1787
1788 * configure.in: Recognize the differences in core files from FreeBSD
1789 4.{0,1} and later versions of 4.x. This treats 4.2+ the same as
1790 5-CURRENT.
1791 * configure: Regenerate.
1792
3b16e843
NC
17932002-01-31 Ivan Guzvinec <ivang@opencores.org>
1794
1795 * coff-or32.c: New file.
1796 * cpu-or32.c: New file.
1797 * elf32-or32.c: New file.
1798 * archures.c: Add support for or32.
1799 * targets.c: Add support for or32.
1800 * bfd-in2.h: Regenerate.
7dc0ab31 1801 * coffcode.h (coff_set_arch_mach_hook, coff_set_flags,
3b16e843
NC
1802 coff_write_object_contents): Add support for or32.
1803 * config.bfd: Add target.
1804 * configure.in: Add support for or32.
1805 * configure: Regenerate.
1806 * Makefile.am: Add support for or32.
1807 * Makefile.in: Regenerate.
3b16e843
NC
1808 * po/SRC-POTFILES.in: Add or32 files.
1809 * po/bfd.pot: Regenerate.
7dc0ab31 1810
caf8ca8e
NC
18112002-01-31 Nick Clifton <nickc@cambridge.redhat.com>
1812 Don Lindsay <lindsayd@cisco.com>
1813
1814 * elf32-mips.c (mips_elf_calculate_relocation): Replace 'return
1815 false' with a return of a bfd_reloc_ error code.
1816
e5dfef09
HPN
18172002-01-31 Hans-Peter Nilsson <hp@axis.com>
1818
1819 * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Don't
1820 unexport unreferenced symbols when --export-dynamic. Call
1821 _bfd_elf_strtab_delref when unexporting.
1822
4e4770d0
DJ
18232002-01-30 Daniel Jacobowitz <drow@mvista.com>
1824
1825 * bfd-in.h: Include <stdbool.h> if it is available.
1826 * bfd-in2.h: Regenerated.
1827
e1fa50e7
AM
18282002-01-31 Alan Modra <amodra@bigpond.net.au>
1829
1830 * elf64-ppc.c (func_desc_adjust): STV_PROTECTED functions should
1831 not go via the plt.
1832
b5f79c76
NC
18332002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
1834
b5f79c76
NC
1835 * archures.c: Tidy up formatting of embedded comments.
1836 * bfd.c: Tidy up formatting of embedded comments.
7dc0ab31 1837 * bfd-in.h: Fix formatting of comments.
b5f79c76
NC
1838 * reloc.c: Tidy up formatting of ordinary & embedded comments.
1839 * section.c: Tidy up formatting of embedded comments.
1840 * syms.c: Tidy up formatting of embedded comments.
1841 * targets.c: Tidy up formatting of embedded comments.
1842
1843 * bfd-in2.h: Regenerate.
1844
ca09e32b
NC
18452002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
1846
1847 * vms-tir.c (cmd_name): New function.
1848 (tir_cmd_name): New function.
1849 (etir_sta, etir_sto, etir_opr, etir_stc): Use cmd_name().
1850 (tir_opr, tir_ctl, tir_cmd): use tir_cmd_name().
1851 Fix formatting.
7dc0ab31 1852
ca09e32b
NC
1853 * peXXigen.c (pe_print_idata): Rearrange message to aid in
1854 translation.
1855 (pe_print_pdata): Rearrange message to aid in translation.
1856
1857 * libbfd.c (warn_deprecated): Rearrange error message to aid in
1858 translation.
1859
1860 * ihex.c (ihex_write_object_contents): Fix spelling typo.
1861
1862 * ieee.c (ieee_slurp_external_symbols): Remove spurious space.
1863
1864 * elf64-sparc.c (sparc64_elf_add_symbol_hook): Rearrange error
1865 message to aid in translation.
1866
1867 * elf64-mmix.c (mmix_final_link_relocate): Rearrange error message
1868 to aid in translation.
1869
1870 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix typo.
1871
7dc0ab31 18722002-01-30 Philipp Thomas <pthomas@suse.de>
ae1a89b7
PT
1873
1874 * coff-arm.c, elf32-elf.h: Unify messages.
1875
05f64ac6
NC
18762002-01-30 Nick Clifton <nickc@redhat.com>
1877
1878 * po/sv.po: Updated translation.
1879
f5a3e38a
NC
18802002-01-30 Philipp Thomas <pthomas@suse.de>
1881
1882 * dwarf2.c (read_abbrev): Use full section name in error message.
1883 (decode_line_info): Likewise.
661a3fd4
NC
1884
1885 * elf.c (_bfd_elf_symbol_from_bfd_symbol): Don't translate debugging
1886 message.
1887
d926e03d
AM
18882002-01-30 Alan Modra <amodra@bigpond.net.au>
1889
1890 * elf64-ppc.c (func_desc_adjust): Only provide missing function
1891 descriptor symbols for undefined function code syms. Clear
1892 ELF_LINK_NON_ELF so that they can stay weak.
1893
030d18fb 18942002-01-29 Chris Demetriou <cgd@broadcom.com>
7dc0ab31 1895 Mitch Lichtenberg <mpl@broadcom.com>
030d18fb
CD
1896
1897 * bfd-in.h (bfd_mips_elf32_create_embedded_relocs): New prototype.
1898 * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): New function
1899 to handle 32-bit ELF embedded reloc (ld --embedded-relocs)
1900 generation.
1901 * bfd-in2.h: Regenerate.
1902
fcc76bea
CD
19032002-01-29 Chris Demetriou <cgd@broadcom.com>
1904
1905 * elf32-mips.c: Add additional comments about HI16 relocation
1906 processing.
1907 (_bfd_mips_elf_hi16_reloc): Don't subtract address here for
1908 pc-relative relocations. (Reverts change made on 2001-10-31.)
1909 (_bfd_mips_elf_lo16_reloc): Subtract address of LO16 part here
1910 for pc-relative relocations.
1911 (mips_elf_calculate_relocation): Add a comment about a kludge
1912 in the R_MIPS_GNU_REL_HI16 handling.
1913 (_bfd_mips_elf_relocate_section): Implement that kludge;
1914 adjust pc-relative HI16 relocation for difference in HI16 and
1915 LO16 addresses, since it can't easily be done in
1916 mips_elf_calculate_relocation.
1917
f9cd9119
MS
19182002-01-29 Martin Schwidefsky <schwidefsky@de.ibm.com>
1919
1920 * elf32-i386 (elf_i386_adjust_dynamic_symbol): Do not replace PLT32
1921 relocations with PC32 relocations for undefined or weak symbols.
1922 * elf32-s390 (elf_i386_adjust_dynamic_symbol): Likewise.
1923 * elf64-s390x (elf_i386_adjust_dynamic_symbol): Likewise.
1924
702248bb
JT
19252002-01-28 Jason Thorpe <thorpej@wasabisystems.com>
1926
1927 * elfcore.h (elf_core_file_p): Improve comment for last change.
1928
4867be41
DJ
19292002-01-27 Daniel Jacobowitz <drow@mvista.com>
1930
1931 * configure: Regenerated.
1932
a94cef6a
JT
19332002-01-27 Jason Thorpe <thorpej@wasabisystems.com>
1934
1935 * elfcore.h (elf_core_file_p): Set the machine architecture
1936 before processing the program headers.
1937
7562a296
HPN
19382002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
1939
966abd70
HPN
1940 * configure.in <64-bit configuration>: If using gcc, check and
1941 emit error for egcs-1.1.2.
1942 * configure: Regenerate.
1943
e8eab623
NC
19442002-01-26 Egor Duda <deo@logos-m.ru>
1945
1946 * elf.c (elfcore_grok_win32pstatus): Copy only as much information
1947 as possible to avoid stack corruption.
1948
73896efb
RH
19492002-01-26 Richard Henderson <rth@redhat.com>
1950
1951 * elf64-alpha.c (elf64_alpha_check_relocs): Don't set reltext
1952 for non-allocated sections.
1953
19542002-01-25 Mark Kettenis <kettenis@gnu.org>
c106e334
MK
1955
1956 * elf.c (elfcore_write_prstatus): Make sure we pass the address of
1957 prstat.pr_reg even if it is a struct.
1958
73896efb 19592002-01-25 Steve Ellcey <sje@cup.hp.com>
254ed743
NC
1960
1961 * bfd/elfxx-ia64.c: Reset AIX vector function overrides for HP-UX.
1962
3d66c4f7
NC
19632002-01-25 Philipp Thomas <pthomas@suse.de>
1964
1965 * coffgen.c (coff_print_symbol): Don't mark info message
1966 for translation.
1967
9460ecda
NC
19682002-01-25 Nick Clifton <nickc@redhat.com>
1969
1970 * po/fr.po: Updated translation.
1971 * po/es.po: Updated translation.
1972
cc9ff76a
AM
19732002-01-25 Philipp Thomas <pthomas@suse.de>
1974
1975 * coff-alpha.c (alpha_relocate_section): Unify warning message
1976 for GP relative relocations without GP defined.
1977 * coff-mips.c (mips_relocate_section): Likewise.
1978
c68836a9
AM
19792002-01-25 Alan Modra <amodra@bigpond.net.au>
1980
1981 * elf-eh-frame.c (_bfd_elf_eh_frame_section_offset): Avoid
1982 unsigned overflow when new_offset < old_offset.
1983
e8eab623 19842002-01-24 Philipp Thomas <pthomas@suse.de>
391154e9
NC
1985
1986 * bfd.c (_bfd_abort): Fix typo.
1987
8ba89f17
RH
19882002-01-23 Richard Henderson <rth@redhat.com>
1989
1990 * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't suppress
1991 plt entries for undefweak symbols.
1992
c6953948
NC
19932002-01-23 Steve Ellcey <sje@cup.hp.com>
1994
1995 * bfd/targets.c (bfd_elf32_ia64_hpux_big_vec): Add to
1996 DEFAULT_VECTOR.
1997 (bfd_elf64_ia64_hpux_big_vec): Ditto.
1998 (bfd_elf32_h8300_vec): Ditto.
1999
41bd81ab
AM
20002002-01-23 Alan Modra <amodra@bigpond.net.au>
2001
2002 * elf64-ppc.c: Remove stale part of ABI comment.
2003 (NO_OPD_RELOCS): Define.
2004 (ppc64_elf_check_relocs): Use it.
2005 (ppc64_elf_relocate_section): Here too.
2006 (build_one_stub): Don't point function syms at the stub. Instead,
2007 hijack plt.offset.
2008 (ppc64_elf_relocate_section): Check whether REL24 relocs should
2009 really go to the stub. Make all dynamic relocs in opd against
2010 locals.
2011 (ppc64_elf_finish_dynamic_symbol): Allow for non-standard use of
2012 plt.offset.
2013
f304919d
RH
20142002-01-22 Richard Henderson <rth@redhat.com>
2015
2016 * elf64-alpha.c (INSN_UNOP): Encode with RB as $sp.
2017
c0ef99a7
AM
20182002-01-22 Alan Modra <amodra@bigpond.net.au>
2019
60ee0d4a
AM
2020 * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Correct sign of
2021 TOC_BASE_OFF adjustment.
2022
c0ef99a7
AM
2023 * Makefile.am: Run "make dep-am".
2024 * Makefile.in: Regenerate.
2025 * po/SRC-POTFILES.in: Regenerate.
2026
64328b46
AM
20272002-01-22 John David Anglin <dave@hiauly1.hia.nrc.ca>
2028
2029 * configure.host (hppa*64*-*-hpux*, hppa*64*-*-linux*): Add new
2030 host defines.
2031
59953665 20322002-01-21 Hans-Peter Nilsson <hp@axis.com>
58255df3
HPN
2033
2034 * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_32_GOTREL>:
2035 Check for and emit error if sgot is NULL at this point.
2036
9596feea
JT
20372002-01-21 Jason Thorpe <thorpej@wasabisystems.com>
2038
2039 * config.bfd (ia64*-*-netbsd*): New target.
2040
7b45c6e1
AM
20412002-01-21 Thomas Klausner <wiz@danbala.ifoer.tuwien.ac.at>
2042
2043 * som.c (som_write_space_strings): Comment typo fix.
2044
e5094212
AM
20452002-01-21 Alan Modra <amodra@bigpond.net.au>
2046
e86ce104
AM
2047 * elf64-ppc.c (struct ppc_link_hash_entry): Add is_func and
2048 is_func_descriptor fields.
2049 (link_hash_newfunc): Init them.
2050 (ppc64_elf_check_relocs): Only R_PPC24_REL24 syms starting with a
2051 dot are candidates for plt entries. When processing .opd relocs,
2052 set function descriptor strings to point inside function code
2053 string, and set new ppc_link_hash_entry fields.
2054 (ppc64_elf_gc_sweep_hook): Don't sweep R_PPC64_REL24 relocs.
2055 (ppc64_elf_adjust_dynamic_symbol): Remove most code dealing with
2056 function descriptors. It's now done in..
2057 (func_desc_adjust): New.
2058 (ppc64_elf_func_desc_adjust): New.
2059 (define elf_backend_always_size_sections): Define.
2060 (ppc64_elf_hide_symbol): New.
2061 (define elf_backend_hide_symbol): Define.
2062 (allocate_dynrelocs): Remove code looking up function descriptors
2063 as that has been done earlier.
2064 (ppc64_elf_size_dynamic_sections): Use htab shortcut to elf hash
2065 table.
2066 (ppc64_elf_finish_dynamic_symbol): Likewise. Remove code looking
2067 up function descriptor.
2068 (build_one_stub): Look up the function code sym. Check for
2069 invalid plt offsets.
2070 (ppc64_elf_relocate_section): Tweak calls to undefined weak syms.
2071 Convert R_PPC64_TOC relocs to R_PPC64_RELATIVE in shared libs.
2072
e5094212
AM
2073 * elf-bfd.h (elf_backend_data <elf_backend_hide_symbol>): Add
2074 boolean param.
2075 (_bfd_elf_link_hash_hide_symbol): Likewise.
2076 * elflink.h (elf_link_add_object_symbols): Adjust call to
2077 elf_backend_hide_symbol.
2078 (elf_fix_symbol_flags): Likewise.
2079 (elf_link_assign_sym_version): Likewise. Use bfd_malloc rather
2080 than bfd_alloc.
2081 * elf.c (_bfd_elf_link_hash_hide_symbol): Add "force_local" param.
2082 Set ELF_LINK_FORCED_LOCAL and call _bfd_elf_strtab_delref.
2083 * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
2084 (clobber_millicode_symbols): Adjust to suit new hide_symbol.
2085 * elf32-cris.c (elf_cris_hide_symbol): Add "force_local" param
2086 and adjust to suit.
2087 * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise, and call
2088 _bfd_elf_link_hash_hide_symbol rather than duplicating code.
2089 * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
2090
40b8271b
AM
20912002-01-18 Alan Modra <amodra@bigpond.net.au>
2092
2093 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Test for a
2094 dynamic function descriptor symbol, not the associated function
2095 symbol.
2096
55baa95b
EC
20972002-01-17 Eric Christopher <echristo@redhat.com>
2098
2099 * elf32-mips.c (mips_elf_calculate_relocation): Fix typo.
2100
328577ad
NC
21012002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
2102
2103 * po/bfd.pot: Regenerate.
2104 * po/fr.po: Regenerate.
2105
af746e92
AM
21062002-01-17 Alan Modra <amodra@bigpond.net.au>
2107
2108 * elf-bfd.h (elf_backend_data <elf_backend_section_from_bfd_section>):
2109 Remove "Elf_Internal_Shdr *" param.
2110 (_bfd_mips_elf_section_from_bfd_section): Ditto.
2111 * elf32-mips.c (_bfd_mips_elf_section_from_bfd_section): Ditto.
2112 * elf32-m32r.c (_bfd_m32r_elf_section_from_bfd_section): Ditto.
2113 * elf32-v850.c (v850_elf_section_from_bfd_section): Ditto.
2114 * elf64-mmix.c (mmix_elf_section_from_bfd_section): Ditto.
2115 * elfxx-ia64.c (elfNN_hpux_backend_section_from_bfd_section): Ditto.
2116 * elf.c (_bfd_elf_section_from_bfd_section): Allow backend
2117 function to override special sections. Remove hdr arg from
2118 backend call, and don't loop.
2119
175e9962
EC
21202002-01-16 Eric Christopher <echristo@redhat.com>
2121
2122 * elf32-mips.c (mips_elf_calculate_relocation): Set require_jalxp
2123 on R_MIPS_26 and target is 16bit. Add R_MIPS16_GPREL to list of
2124 relocations requiring gp0 and gp.
2125
96a846ea
RE
21262002-01-16 Richard Earnshaw <rearnsha@arm.com>
2127
175e9962 2128 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Handle
96a846ea
RE
2129 EF_ARM_VFP_FLOAT.
2130 (elf32_arm_print_private_bfd_data): Likewise.
2131
af3ae48d
NC
21322002-01-16 Nick Clifton <nickc@cambridge.redhat.com>
2133
2134 * po/tr.po: Import new version.
2135
10ed1bba
AM
21362002-01-16 Alan Modra <amodra@bigpond.net.au>
2137
2138 * elf64-ppc.c (ppc64_elf_howto_raw): Remove stale FIXMEs.
2139 (ppc64_elf_reloc_type_lookup): Use proper CTOR reloc.
2140 (ORI_R0_R0_0): Correct.
2141
5d1634d7
AM
21422002-01-16 Alan Modra <amodra@bigpond.net.au>
2143
2144 * elflink.c (_bfd_elf_create_dynamic_sections): Don't set SEC_CODE
2145 when plt_not_loaded.
2146 * elf64-ppc.c (ppc64_elf_create_dynamic_sections): No need to
2147 clear .plt SEC_CODE here. Create .stub and correct .glink flags.
2148 (PLT_INITIAL_ENTRY_SIZE): Set to 24.
2149 (ppc64_elf_glink_code): Delete.
2150 (PPC64_ELF_GLINK_SIZE): Delete.
2151 (ADDIS_R12_R2, STD_R2_40R1, LD_R11_0R12, LD_R2_0R12, MTCTR_R11,
2152 BCTR, ADDIS_R12_R12_1, LD_R2_40R1, NOP, LI_R0_0, B_DOT, LIS_R0_0,
2153 ORI_R0_R0_0): Define.
2154 (PLT_CALL_STUB_SIZE, GLINK_CALL_STUB_SIZE): Define.
2155 (struct ppc_link_hash_table): Add sstub and plt_overflow.
2156 (ppc64_elf_link_hash_table_create): Init them.
2157 (ppc64_elf_check_relocs <R_PPC64_REL24>): Refcount .plt entry.
2158 Don't copy to shared lib.
2159 (ppc64_elf_check_relocs): Call bfd_set_error on errors.
2160 (ppc64_elf_gc_sweep_hook <R_PPC64_REL24>): Sweep plt refcount.
2161 (allocate_dynrelocs <plt>): Don't change function sym here. Make
2162 room for .stub and .glink code.
2163 (ppc64_elf_size_dynamic_sections): Handle .stub. Make entry for
2164 DT_PPC64_GLINK.
2165 (ppc64_elf_final_link): Rename to ppc64_elf_set_toc. Don't call
2166 bfd_elf64_bfd_final_link.
2167 (bfd_elf64_bfd_final_link): Don't define.
2168 (ppc64_elf_size_stubs): New.
2169 (build_plt_stub): New.
2170 (build_one_stub): New.
2171 (ppc64_elf_build_stubs): New.
2172 (ppc64_elf_relocate_section <toc relocs>): Remove assert.
2173 (ppc64_elf_relocate_section): Don't copy R_PPC64_REL24 relocs.
2174 (ppc64_elf_finish_dynamic_symbol): Don't build stubs here. Set
2175 DT_PPC64_GLINK entry. Tweak DT_PLTGOT, DT_JMPREL, DT_PLTRELSZ in
2176 case output sections not separate. Adjust DT_RELASZ to not
2177 include plt relocs. Set reserved got entry. Set got and plt
2178 entry size.
2179 (elf_backend_got_header_size): Set to 8.
2180 * elf64-ppc.h: New file.
2181
c601ffdb
AM
21822002-01-16 Alan Modra <amodra@bigpond.net.au>
2183
2184 * elf32-arm.h (elf32_arm_size_dynamic_sections): When removing
2185 sections, use bfd_section_list_remove.
2186 * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
2187 * elflink.h (elf_link_add_object_symbols): When removing all
2188 sections, use bfd_section_list_clear.
2189
8fb4cb7f
NC
21902002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
2191
2192 * po/sv.po: New file: Swedish translation.
2193 * configure.in (ALL_LINGUAS): Add sv.
2194 * configure: Regenerate.
2195
d3c456e9
JJ
21962002-01-15 Jakub Jelinek <jakub@redhat.com>
2197
2198 * elflink.h (elf_link_input_bfd): Back out 2002-01-07 change.
2199 * elf.c (merge_sections_remove_hook): New function.
2200 (_bfd_elf_merge_sections): Pass it as 3rd argument to
2201 _bfd_merge_sections.
2202 * libbfd-in.h (_bfd_merge_sections): Add 3rd argument.
2203 * libbfd.h: Rebuilt.
2204 * merge.c (_bfd_merge_sections): Add remove_hook argument.
2205 Call remove_hook if a SEC_EXCLUDE section is encountered.
2206
1f7fd478
NC
22072002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
2208
2209 * elf32-xstormy16.c (xstormy16_reloc_map): Add new field 'table'.
2210 (xstormy16_reloc_map): Initialise new field with correct howto
2211 table.
2212 (xstormy16_reloc_type_lookup): Use 'table' field to locate correct
2213 howto entry.
2214
b87011e9
MS
22152002-01-10 Michael Snyder <msnyder@redhat.com>
2216
2217 * elf.c (elfcore_write_prstatus): Use long instead of pid_t;
2218 (elfcore_write_pstatus): Use long instead of pid_t;
2219 * elf-bfd.h: Change prototypes to use long instead of pid_t;
2220
175e9962 22212002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
b4db1224
JT
2222
2223 * elf.c: Update copyright years.
2224 (elfcore_grok_netbsd_note): Use NT_NETBSDCORE_PROCINFO
2225 and NT_NETBSDCORE_FIRSTMACH. Improve a comment.
2226
7c76fa91
MS
22272002-01-08 Michael Snyder <msnyder@redhat.com>
2228
2229 Add capability to write corefile note sections, for gdb.
2230 * elf.c (elfcore_write_note): New function.
2231 (elfcore_write_prpsinfo): New function.
2232 (elfcore_write_prstatus): New function.
2233 (elfcore_write_pstatus): New function.
2234 (elfcore_write_prfpreg): New function.
2235 (elfcore_write_prxfpreg): New function.
97996af6 2236 * elf-bfd.h: Add prototypes for above functions.
7c76fa91 2237
e1fddb6b
AO
22382002-01-08 Alexandre Oliva <aoliva@redhat.com>
2239
2240 * elf.c (elf_fake_sections): Propagate errors from
2241 elf_backend_fake_section.
2242
8d05742f
JT
22432002-01-07 Jason Thorpe <thorpej@wasabisystems.com>
2244
2245 * Makefile.am (BFD32_BACKENDS): Add elf32-sh-nbsd.lo.
2246 (BFD32_BACKENDS_CFILES): Add elf32-sh-nbsd.c.
2247 (elf32-sh-nbsd.lo): New rule.
2248 * Makefile.in: Regenerate.
2249 * config.bfd (sh*le-*-netbsdelf*): New target.
2250 (sh*-*-netbsdelf*): New target.
2251 * configure.in: Include netbsd-core.lo for native sh*-*-netbsd*.
2252 (bfd_elf32_shnbsd_vec): New vector.
2253 (bfd_elf32_shlnbsd_vec): New vector.
2254 * configure: Regenerate.
2255 * elf32-sh-nbsd.c: New file.
2256 * targets.c: Update copyright years.
175e9962 2257 (_bfd_target_vector): Add bfd_elf32_shlnbsd_vec and
8d05742f
JT
2258 bfd_elf32_shnbsd_vec.
2259
1dba4cb4
AH
22602002-01-07 Aldy Hernandez <aldyh@redhat.com>
2261
2262 * coff-rs6000.c (READ20): Use bfd_scan_vma.
2263
47b22aef
GK
22642002-01-07 Geoffrey Keating <geoffk@redhat.com>
2265
2266 * elflink.h (elf_link_input_bfd): Don't ask for the merged offset
2267 of a symbol in a section that will be deleted.
2268
be2d1673
NC
22692002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
2270
2271 * po/es.po: New file: Spanish translation.
2272 * configure.in (ALL_LINGUAS): Add es.
2273 * configure: Regenerate.
2274
d9cf1b54
AM
22752002-01-06 Steve Ellcey <sje@cup.hp.com>
2276
2277 * elfxx-ia64.c (is_unwind_section_name): Add target vector as
2278 argument so we can handle HP-UX specially.
2279 (elfNN_ia64_hpux_vec): New for use in is_unwind_section_name.
2280 (elfNN_hpux_backend_section_from_bfd_section): New for support
2281 of SHN_IA_64_ANSI_COMMON.
2282 (elfNN_ia64_relax_section): Add support for SHN_IA_64_ANSI_COMMON.
2283 (is_unwind_section_name): Add special HP-UX support.
2284 (elfNN_ia64_section_from_shdr): Add support for more sections.
2285 (elfNN_ia64_fake_sections): Modify is_unwind_section_name call and
2286 add support for more sections.
2287 (elfNN_ia64_additional_program_headers): Modify
2288 is_unwind_section_name call.
2289 (elfNN_ia64_modify_segment_map): Remove assumption that there is
2290 only one unwind section in segment.
2291
3f3c5c34
AM
22922002-01-06 Alan Modra <amodra@bigpond.net.au>
2293
2294 * syms.c (_bfd_generic_make_empty_symbol): New function.
2295 * libbfd-in.h (_bfd_nosymbols_make_empty_symbol): Define as
2296 _bfd_generic_make_empty_symbol.
2297 * libbfd.h: Regenerate.
2298 * bfd-in2.h: Regenerate.
2299 * hppabsd-core.c (hppabsd_core_make_empty_symbol): Delete function.
2300 (hppabsd_core_get_symtab_upper_bound): Don't define.
2301 (hppabsd_core_get_symtab): Likewise.
2302 (hppabsd_core_print_symbol): Likewise.
2303 (hppabsd_core_get_symbol_info): Likewise.
2304 (hppabsd_core_bfd_is_local_label_name): Likewise.
2305 (hppabsd_core_get_lineno): Likewise.
2306 (hppabsd_core_find_nearest_line): Likewise.
2307 (hppabsd_core_bfd_make_debug_symbol): Likewise.
2308 (hppabsd_core_read_minisymbols): Likewise.
2309 (hppabsd_core_minisymbol_to_symbol): Likewise.
2310 (hppabsd_core_vec): Use BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols).
2311 Formatting fixes.
2312 * hpux-core.c: Similarly.
2313 * irix-core.c: Similarly.
2314 * osf-core.c: Similarly.
2315 * sco5-core.c: Similarly.
2316 * binary.c (binary_make_empty_symbol): Remove function, define as
2317 _bfd_generic_make_empty_symbol.
2318 * ihex.c (ihex_make_empty_symbol): Likewise.
2319 * mmo.c (mmo_make_empty_symbol): Likewise.
2320 * ppcboot.c (ppcboot_make_empty_symbol): Likewise.
2321 * srec.c (srec_make_empty_symbol): Likewise.
2322 * versados.c (versados_make_empty_symbol): Likewise.
2323 * vms.c (_bfd_vms_make_empty_symbol): Remove.
2324 (vms_make_empty_symbol): Define as _bfd_generic_make_empty_symbol.
2325 * vms-gsd.c (_bfd_vms_slurp_gsd): Call bfd_make_empty_symbol
2326 rather than _bfd_vms_make_empty_symbol.
2327 * vms-misc.c (new_symbol): Likewise.
2328
3f0a7f7f
AM
23292002-01-05 Alan Modra <amodra@bigpond.net.au>
2330
9e7b37b3
AM
2331 * section.c (bfd_section_init): Remove unnecessary initialisations.
2332 (bfd_section_list_clear): New function.
2333 (bfd_section_list_remove, bfd_section_list_insert): New macros.
2334 (_bfd_strip_section_from_output): Use them.
2335 * coffcode.h (coff_set_alignment_hook): Likewise.
2336 * elf32-mips.c (_bfd_mips_elf_final_link): Likewise.
2337 * elf64-mips.c (mips_elf64_final_link): Likewise.
2338 * elf64-mmix.c (mmix_elf_final_link): Likewise.
2339 * sunos.c (sunos_add_dynamic_symbols): Likewise.
2340 * xcofflink.c (_bfd_xcoff_bfd_final_link): Likewise.
2341 * bfd-in2.h: Regenerate.
2342
2343 * netbsd-core.c (netbsd_core_file_p): Use bfd_make_section_anyway
2344 rather than doing our own section handling. Clean up after errors
2345 with bfd_release and bfd_section_list_clear. Handle unexpected
2346 flags.
2347 * aoutf1.h (sunos4_core_file_p): Likewise.
2348 * aix386-core.c (aix386_core_file_p): Likewise.
2349 * cisco-core.c (cisco_core_file_validate): Likewise.
2350 * ptrace-core.c (ptrace_unix_core_file_p): Likewise.
2351 * trad-core.c (trad_unix_core_file_p): Likewise.
2352
2353 * hppabsd-core.c (hppabsd_core_core_file_p): Clean up after errors
2354 with bfd_release and bfd_section_list_clear.
2355 * hpux-core.c (hpux_core_core_file_p): Likewise.
2356 * irix-core.c (irix_core_core_file_p): Likewise.
2357 * lynx-core.c (lynx_core_file_p): Likewise.
2358 * osf-core.c (osf_core_core_file_p): Likewise.
2359 * rs6000-core.c (rs6000coff_core_p): Likewise.
2360 * sco5-core.c (sco5_core_file_p): Likewise.
2361
3f0a7f7f
AM
2362 * elf32-mips.c (_bfd_mips_elf_lo16_reloc): Simplify, and perform
2363 sign extension adjustments without conditionals.
2364
a3aa38ee
JJ
23652002-01-04 Jakub Jelinek <jakub@redhat.com>
2366
2367 * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): Don't crash if
2368 CIE at .eh_frame start is removed due to no FDEs referencing it.
2369
8a8b2d4b
AJ
23702002-01-04 Jason Thorpe <thorpej@wasabisystems.com>
2371
2372 * config.bfd (x86_64-*-netbsd*): New target.
2373 * configure.in (x86_64-*-netbsd*): Set COREFILE
2374 to netbsd-core.lo.
2375 * configure: Regenerated.
2376
04b5af89
TR
23772002-01-03 Tom Rix <trix@redhat.com>
2378
2379 * xcofflink.c (_bfd_xcoff_bfd_final_link): Update .pad section ordering
2380 for recent bfd_make_section_anyway change.
2381
51c5503b
NC
23822002-01-03 Nick Clifton <nickc@cambridge.redhat.com>
2383
2384 * elf32-arm.h (elf32_arm_final_link_relocate): Handle
2385 R_ARM_THM_PC11 reloc.
2386
07f7c046
NC
23872002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
2388
2389 * configure.in (LINGUAS): Add ja.
2390 * configure: Regenerate.
2391 * po/ja.po: Import from translation project's web site.
2392
5eefb65f
NC
23932002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
2394
2395 * elf32-arm.h (elf32_arm_merge_private_bfd_data): Reformat error
2396 messages to ease translation into other languages.
2397
39e90f10 2398For older changes see ChangeLog-0001
56882138
AM
2399\f
2400Local Variables:
2401mode: change-log
2402left-margin: 8
2403fill-column: 74
2404version-control: never
2405End: