bfd: avoid "shadowing" of glibc function name
[deliverable/binutils-gdb.git] / bfd / ChangeLog
1 2021-03-23 Jan Beulich <jbeulich@suse.com>
2
3 * dwarf2.c (read_indexed_string): Rename index to idx.
4
5 2021-03-22 Martin Liska <mliska@suse.cz>
6
7 * bfd-in.h (startswith): Add startswith function.
8 (CONST_STRNEQ): Remove.
9 * bfd-in2.h (startswith): Regenerate with make headers.
10 * archive.c (bfd_slurp_armap): Replace usage of CONST_STRNEQ with startswith.
11 (_bfd_slurp_extended_name_table): Likewise.
12 * archive64.c (_bfd_archive_64_bit_slurp_armap): Likewise.
13 * bfd.c (bfd_get_sign_extend_vma): Likewise.
14 (bfd_convert_section_size): Likewise.
15 (bfd_convert_section_contents): Likewise.
16 * coff-stgo32.c (go32exe_create_stub): Likewise.
17 (go32exe_check_format): Likewise.
18 * coffcode.h (styp_to_sec_flags): Likewise.
19 (GNU_DEBUGALTLINK): Likewise.
20 * coffgen.c (_bfd_coff_section_already_linked): Likewise.
21 (coff_gc_sweep): Likewise.
22 (bfd_coff_gc_sections): Likewise.
23 * cofflink.c (coff_link_add_symbols): Likewise.
24 (process_embedded_commands): Likewise.
25 * compress.c (bfd_is_section_compressed_with_header): Likewise.
26 (bfd_init_section_decompress_status): Likewise.
27 * dwarf2.c (find_debug_info): Likewise.
28 (place_sections): Likewise.
29 * ecoff.c (_bfd_ecoff_slurp_armap): Likewise.
30 * elf-m10300.c (_bfd_mn10300_elf_size_dynamic_sections): Likewise.
31 * elf.c (_bfd_elf_make_section_from_shdr): Likewise.
32 (assign_section_numbers): Likewise.
33 (elfcore_grok_win32pstatus): Likewise.
34 * elf32-arm.c (cmse_scan): Likewise.
35 (elf32_arm_gc_mark_extra_sections): Likewise.
36 (elf32_arm_size_dynamic_sections): Likewise.
37 (is_arm_elf_unwind_section_name): Likewise.
38 * elf32-bfin.c (bfin_size_dynamic_sections): Likewise.
39 * elf32-cr16.c (_bfd_cr16_elf_size_dynamic_sections): Likewise.
40 * elf32-cris.c (elf_cris_size_dynamic_sections): Likewise.
41 * elf32-csky.c (csky_elf_size_dynamic_sections): Likewise.
42 * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Likewise.
43 * elf32-iq2000.c (iq2000_elf_check_relocs): Likewise.
44 * elf32-lm32.c (lm32_elf_size_dynamic_sections): Likewise.
45 * elf32-m32r.c (m32r_elf_size_dynamic_sections): Likewise.
46 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
47 * elf32-metag.c (elf_metag_size_dynamic_sections): Likewise.
48 * elf32-msp430.c (msp430_elf_relax_delete_bytes): Likewise.
49 * elf32-nios2.c (nios2_elf32_size_dynamic_sections): Likewise.
50 * elf32-or1k.c (or1k_elf_size_dynamic_sections): Likewise.
51 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
52 * elf32-s390.c (elf_s390_size_dynamic_sections): Likewise.
53 * elf32-score.c (s3_bfd_score_elf_size_dynamic_sections): Likewise.
54 * elf32-score7.c (s7_bfd_score_elf_size_dynamic_sections): Likewise.
55 * elf32-sh.c (sh_elf_size_dynamic_sections): Likewise.
56 * elf32-tic6x.c (is_tic6x_elf_unwind_section_name): Likewise.
57 (elf32_tic6x_size_dynamic_sections): Likewise.
58 * elf32-vax.c (elf_vax_size_dynamic_sections): Likewise.
59 * elf32-xtensa.c (elf_xtensa_size_dynamic_sections): Likewise.
60 (xtensa_is_insntable_section): Likewise.
61 (xtensa_is_littable_section): Likewise.
62 (xtensa_is_proptable_section): Likewise.
63 (xtensa_property_section_name): Likewise.
64 (xtensa_callback_required_dependence): Likewise.
65 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
66 * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
67 * elf64-ia64-vms.c (is_unwind_section_name): Likewise.
68 (get_reloc_section): Likewise.
69 (elf64_ia64_size_dynamic_sections): Likewise.
70 (elf64_ia64_object_p): Likewise.
71 * elf64-mmix.c (mmix_elf_add_symbol_hook): Likewise.
72 * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Likewise.
73 * elf64-s390.c (elf_s390_size_dynamic_sections): Likewise.
74 * elflink.c (elf_link_add_object_symbols): Likewise.
75 (_bfd_elf_gc_mark_extra_sections): Likewise.
76 (bfd_elf_parse_eh_frame_entries): Likewise.
77 (_bfd_elf_section_already_linked): Likewise.
78 * elfnn-aarch64.c (elfNN_aarch64_size_dynamic_sections): Likewise.
79 * elfnn-ia64.c (is_unwind_section_name): Likewise.
80 (elfNN_ia64_size_dynamic_sections): Likewise.
81 (elfNN_ia64_object_p): Likewise.
82 * elfxx-mips.c (FN_STUB_P): Likewise.
83 (CALL_STUB_P): Likewise.
84 (CALL_FP_STUB_P): Likewise.
85 (_bfd_mips_elf_section_from_shdr): Likewise.
86 (_bfd_mips_elf_fake_sections): Likewise.
87 (_bfd_mips_elf_size_dynamic_sections): Likewise.
88 (_bfd_mips_final_write_processing): Likewise.
89 (_bfd_mips_elf_final_link): Likewise.
90 * elfxx-sparc.c (_bfd_sparc_elf_size_dynamic_sections): Likewise.
91 * elfxx-x86.c (elf_i386_is_reloc_section): Likewise.
92 (elf_x86_64_is_reloc_section): Likewise.
93 * hpux-core.c (thread_section_p): Likewise.
94 * libcoff.h (bfd_pei_p): Likewise.
95 * linker.c (REAL): Likewise.
96 (unwrap_hash_lookup): Likewise.
97 (_bfd_generic_link_add_one_symbol): Likewise.
98 * mmo.c (mmo_internal_write_section): Likewise.
99 * osf-core.c (osf_core_core_file_p): Likewise.
100 * pef.c (bfd_pef_print_symbol): Likewise.
101 * pei-x86_64.c (pex64_print_all_pdata_sections): Likewise.
102 * som.c (som_slurp_symbol_table): Likewise.
103 (som_slurp_armap): Likewise.
104 * wasm-module.c (wasm_compute_custom_section_file_position): Likewise.
105
106 2021-03-22 Jan Beulich <jbeulich@suse.com>
107
108 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Add missing
109 language translation wrapping to _bfd_error_handler()
110 invocations.
111
112 2021-03-21 Alan Modra <amodra@gmail.com>
113
114 * bfd-in.h (startswith): New inline.
115 (CONST_STRNEQ): Use startswith.
116 * bfd-in2.h: Regenerate.
117
118 2021-03-20 Alan Modra <amodra@gmail.com>
119
120 PR 27590
121 * elf.c (_bfd_elf_make_section_from_shdr): Remove SHF_EXCLUDE
122 test for .gnu.debuglto*.
123
124 2021-03-18 H.J. Lu <hongjiu.lu@intel.com>
125
126 PR ld/27590
127 * elf.c (_bfd_elf_make_section_from_shdr): Treat
128 .gnu.debuglto_.debug_ section as debugging section unless it is
129 marked with SHF_EXCLUDE.
130 * elflink.c (elf_create_symbuf): Revert commit 994b2513281.
131 (bfd_elf_match_symbols_in_sections): Ignore section symbols when
132 matching non-debugging sections or linkonce section with comdat
133 section.
134
135 2021-03-18 H.J. Lu <hongjiu.lu@intel.com>
136
137 PR ld/27587
138 * dwarf2.c (read_attribute_value): Check version >= 3 for
139 DW_FORM_ref_addr.
140
141 2021-03-16 Nick Clifton <nickc@redhat.com>
142
143 * peXXigen.c (_bfd_XXi_swap_aux_out): Avoid potential buffer
144 overrun by using sizeof of the destination x_fname field as the
145 limit for a memcpy.
146
147 2021-03-16 Kuan-Lin Chen <kuanlinchentw@gmail.com>
148
149 * elfxx-riscv.c (riscv_std_z_ext_strtab): Add zba, zbb and zbc.
150
151 2021-03-12 Clément Chigot <clement.chigot@atos.net>
152
153 * reloc.c (BFD_RELOC_PPC_TLS_LE, BFD_RELOC_PPC_TLS_IE,
154 BFD_RELOC_PPC_TLS_M, BFD_RELOC_PPC_TLS_ML, BFD_RELOC_PPC64_TLS_GD,
155 BFD_RELOC_PPC64_TLS_LD, BFD_RELOC_PPC64_TLS_LE,
156 BFD_RELOC_PPC64_TLS_IE, BFD_RELOC_PPC64_TLS_M,
157 BFD_RELOC_PPC64_TLS_ML): New relocations.
158 * bfd-in2.h: Regenerate.
159 * libbfd.h: Regenerate.
160 * coff-rs6000.c (xcoff_calculate_relocation): Call
161 xcoff_reloc_type_tls for TLS relocations.
162 (xcoff_howto_table): Implement TLS relocations.
163 (_bfd_xcoff_reloc_type_lookup): Add cases TLS relocations.
164 (xcoff_reloc_type_tls): New function.
165 * coff64-rs6000.c (xcoff_calculate_relocation): Likewise.
166 (xcoff_howto_table): Likewise.
167 (_bfd_xcoff_reloc_type_lookup): Likewise.
168 * coffcode.h (sec_to_styp_flags): Handle TLS sections.
169 (styp_to_sec_flags): Likewise.
170 (coff_compute_section_file_positions): Avoid file offset
171 optimisation for .data when the previous section is .tdata.
172 (coff_write_object_contents): Handle TLS sections.
173 * coffswap.h (coff_swap_aouthdr_out): Add support for
174 new fields in aouthdr.
175 * libxcoff.h (xcoff_reloc_type_tls): Add prototype.
176 * xcofflink.c (xcoff_link_add_symbols): Handle XMC_UL.
177 (xcoff_need_ldrel_p): Add cases for TLS relocations.
178 (xcoff_create_ldrel): Add l_symndx for TLS sections.
179
180 2021-03-12 Clément Chigot <clement.chigot@atos.net>
181
182 * reloc.c (BFD_RELOC_PPC_TOC16_HI, BFD_RELOC_PPC_TOC16_LO):
183 New relocations.
184 * bfd-in2.h: Regenerate.
185 * libbfd.h: Regenerate.
186 * coff-rs6000.c (xcoff_calculate_relocation): Call
187 xcoff_reloc_type_toc for R_TOCU and R_TOCL.
188 (xcoff_howto_table): Remove src_mask for TOC relocations.
189 Add R_TOCU and R_TOCL howtos.
190 (_bfd_xcoff_reloc_type_lookup): Add cases for
191 BFD_RELOC_PPC_TOC16_HI and BFD_RELOC_PPC_TOC16_LO.
192 (xcoff_reloc_type_toc): Compute the whole offset.
193 Implement R_TOCU and R_TOCL.
194 * coff64-rs6000.c (xcoff64_calculate_relocation):
195 Likewise.
196 (xcoff64_howto_table): Likewise.
197 (xcoff64_reloc_type_lookup): Likewise.
198
199 2021-03-12 Clément Chigot <clement.chigot@atos.net>
200
201 * coff-rs6000.c (xcoff_calculate_relocation): Correct and
202 add new relocations.
203 (xcoff_howto_table): Likewise.
204 (xcoff_rtype2howto): Increase r_type maximum value.
205 (xcoff_ppc_relocate_section): Reuse predefined HOWTOs instead
206 of create a new one from scratch. Enable only some relocations
207 to have a changing r_size.
208 * coff64-rs6000.c (xcoff64_calculate_relocation): Likewise.
209 (xcoff64_howto_table): Likewise.
210 (xcoff64_rtype2howto): Likewise.
211 (xcoff64_ppc_relocate_section): Likewise.
212 * libxcoff.h (XCOFF_MAX_CALCULATE_RELOCATION): Fix value.
213
214 2021-03-12 Clément Chigot <clement.chigot@atos.net>
215
216 * coff64-rs6000.c (xcoff64_ppc_relocate_section): Move.
217
218 2021-03-12 Clément Chigot <clement.chigot@atos.net>
219
220 * coff64-rs6000.c (xcoff64_write_object_contents): Remove.
221 * coffcode.h (coff_write_object_contents): Add bfd_mach_ppc_620
222 support for o_cputype field. Avoid creating an empty a.out header
223 for XCOFF64.
224
225 2021-03-12 Clément Chigot <clement.chigot@atos.net>
226
227 * coff64-rs6000.c (xcoff64_create_csect_from_smclas): Add
228 missing smclass.
229
230 2021-03-11 Nelson Chu <nelson.chu@sifive.com>
231
232 * elfnn-riscv.c (riscv_elf_link_hash_table): New boolean
233 restart_relax, used to check if we need to run the whole
234 relaxations from relax pass 0 to 2 again.
235 (riscv_elf_link_hash_table_create): Init restart_relax to FALSE.
236 (_bfd_riscv_relax_align): Remove obsolete sec_flg0 set.
237 (_bfd_riscv_relax_delete): Set again to TRUE if we do delete the code.
238 (bfd_elfNN_riscv_restart_relax_sections): New function. Called by
239 after_allocation to check if we need to run the whole relaxations again.
240 (_bfd_riscv_relax_section): We will only enter into the relax pass 3
241 when the restart_relax is FALSE; At last set restart_relax to TRUE if
242 again is TRUE, too.
243 * elfxx-riscv.h (bfd_elf32_riscv_restart_relax_sections): Declaration.
244 (bfd_elf64_riscv_restart_relax_sections): Likewise.
245
246 2021-03-10 Jan Beulich <jbeulich@suse.com>
247
248 * cofflink.c (_bfd_coff_write_global_sym): Range-check symbol
249 offset.
250
251 2021-03-10 Alan Modra <amodra@gmail.com>
252 Jan Beulich <jbeulich@suse.com>
253
254 * elf.c (bfd_elf_generic_reloc): Make references between debug
255 sections use section relative values.
256
257 2021-03-09 Jan Beulich <jbeulich@suse.com>
258
259 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Diagnose out of range RVA.
260
261 2021-03-05 H.J. Lu <hongjiu.lu@intel.com>
262
263 PR ld/27425
264 PR ld/27432
265 * bfd.c (_bfd_get_link_info): New function.
266 * elf-bfd.h (output_elf_obj_tdata): Add link_info.
267 (elf_link_info): New.
268 * libbfd-in.h (_bfd_get_link_info): New prototype.
269 * coff-x86_64.c (coff_amd64_reloc): Also subtract __ImageBase for
270 R_AMD64_IMAGEBASE when generating x86-64 ELF executable.
271 * pe-x86_64.c: Include "coff/internal.h" and "libcoff.h".
272 (pex64_link_add_symbols): New function.
273 (coff_bfd_link_add_symbols): New macro.
274 * libbfd.h: Regenerated.
275
276 2021-03-05 Craig Blackmore <craig.blackmore@embecosm.com>
277 Andrew Burgess <andrew.burgess@embecosm.com>
278
279 * elf-bfd.h (elfcore_write_riscv_csr): Declare.
280 * elf.c (elfcore_grok_riscv_csr): New function.
281 (elfcore_grok_note): Handle NT_RISCV_CSR.
282 (elfcore_write_riscv_csr): New function.
283 (elfcore_write_register_note): Handle '.reg-riscv-csr'.
284
285 2021-03-05 Craig Blackmore <craig.blackmore@embecosm.com>
286 Andrew Burgess <andrew.burgess@embecosm.com>
287
288 * elfnn-riscv.c (PRPSINFO_PR_FNAME_LENGTH): Define.
289 (PRPSINFO_PR_PSARGS_LENGTH): Define.
290 (riscv_write_core_note): New function.
291 (riscv_elf_grok_psinfo): Make use of two new length defines.
292 (elf_backend_write_core_note): Define.
293
294 2021-03-05 Craig Blackmore <craig.blackmore@embecosm.com>
295 Andrew Burgess <andrew.burgess@embecosm.com>
296
297 * elf-bfd.h (elfcore_write_gdb_tdesc): Declare new function.
298 * elf.c (elfcore_grok_gdb_tdesc): New function.
299 (elfcore_grok_note): Handle NT_GDB_TDESC.
300 (elfcore_write_gdb_tdesc): New function.
301 (elfcore_write_register_note): Handle NT_GDB_TDESC.
302
303 2021-03-05 Nick Clifton <nickc@redhat.com>
304
305 PR 27521
306 * dwarf2.c (is_str_attr): Add DW_FORM_strx* forms.
307 (read_indexed_string): Placeholder function.
308 (read_attribute_value): Handle DW_FORM_strx* and DW_FORM_addrx*
309 forms.
310
311 2021-03-05 Alan Modra <amodra@gmail.com>
312
313 * reloc.c (bfd_perform_relocation): Revert 2021-01-12 and
314 2020-09-16 changes.
315 * coff-x86_64.c (coff_amd64_reloc): Do more or less the same
316 adjustments here instead. Separate pc-relative adjustments
317 from symbol related adjustments. Tidy comments and formatting.
318
319 2021-03-04 Jan Beulich <jbeulich@suse.com>
320
321 * coffcode.h (sec_to_styp_flags): Don't set IMAGE_SCN_LNK_* in
322 final PE images.
323
324 2021-03-04 Alan Modra <amodra@gmail.com>
325
326 * rs6000-core.c (rs6000coff_core_p): Correct prototype.
327
328 2021-03-03 Alan Modra <amodra@gmail.com>
329
330 PR 27500
331 * elflink.c (_bfd_elf_gc_mark_rsec): Do special start/stop
332 processing not when start/stop symbol section is unmarked but
333 on first time a start/stop symbol is processed.
334
335 2021-03-03 Alan Modra <amodra@gmail.com>
336
337 * reloc.c: Include x86_64.h rather than internal.h.
338
339 2021-03-02 Nick Clifton <nickc@redhat.com>
340
341 PR 27484
342 * dwarf2.c (scan_unit_for_symbols): Scan twice, once to accumulate
343 function and variable tags and a second time to resolve their
344 attributes.
345
346 2021-03-02 Nick Alcock <nick.alcock@oracle.com>
347
348 * elf-strtab.c (_bfd_elf_strtab_str): Skip strings with zero refcount.
349
350 2021-03-02 Alan Modra <amodra@gmail.com>
351
352 PR 27451
353 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Ignore synthesized
354 linker defined start/stop symbols when start_stop_gc.
355
356 2021-03-02 Alan Modra <amodra@gmail.com>
357
358 * elf64-ppc.c (ppc64_elf_relocate_section): Don't optimise got
359 indirect to pc-relative or toc-relative for undefined symbols.
360
361 2021-03-01 Alan Modra <amodra@gmail.com>
362 Fangrui Song <maskray@google.com>
363
364 * elflink.c (_bfd_elf_gc_mark_rsec): Ignore synthesized linker
365 defined start/stop symbols when start_stop_gc.
366 (bfd_elf_gc_mark_dynamic_ref_symbol): Likewise.
367 (bfd_elf_define_start_stop): Don't modify ldscript_def syms.
368 * linker.c (bfd_generic_define_start_stop): Likewise.
369
370 2021-02-25 Alan Modra <amodra@gmail.com>
371
372 PR 27441
373 * elf-bfd.h (struct elf_link_hash_entry): Add ref_ir_nonweak.
374 * elflink.c (elf_link_add_object_symbols): Set ref_ir_nonweak and
375 use when deciding an as-needed library should be loaded instead
376 of using the binding of the library definition.
377
378 2021-02-24 Alan Modra <amodra@gmail.com>
379
380 PR 27459
381 * coff-stgo32.c (go32exe_check_format): Sanity check size of
382 header to avoid a buffer overflow.
383
384 2021-02-22 Alan Modra <amodra@gmail.com>
385
386 * coff-rs6000.c (_bfd_xcoff_reloc_type_lookup): Remove BFD_RELOC_16.
387 * coff64-rs6000.c (xcoff64_reloc_type_lookup): Likewise.
388
389 2021-02-19 Nelson Chu <nelson.chu@sifive.com>
390
391 PR 27158
392 * elfnn-riscv.c (perform_relocation): Updated encoding macros.
393 (_bfd_riscv_relax_call): Likewise.
394 (_bfd_riscv_relax_lui): Likewise.
395 * elfxx-riscv.c (howto_table): Likewise.
396
397 2021-02-18 Nelson Chu <nelson.chu@sifive.com>
398
399 * Makefile.am: Added cpu-riscv.h.
400 * Makefile.in: Regenerated.
401 * po/SRC-POTFILES.in: Regenerated.
402 * cpu-riscv.h: Added to support spec versions controlling.
403 Also added extern arrays and functions for cpu-riscv.c.
404 (enum riscv_spec_class): Define all spec classes here uniformly.
405 (struct riscv_spec): Added for all specs.
406 (RISCV_GET_SPEC_CLASS): Added to reduce repeated code.
407 (RISCV_GET_SPEC_NAME): Likewise.
408 (RISCV_GET_ISA_SPEC_CLASS): Added to get ISA spec class.
409 (RISCV_GET_PRIV_SPEC_CLASS): Added to get privileged spec class.
410 (RISCV_GET_PRIV_SPEC_NAME): Added to get privileged spec name.
411 * cpu-riscv.c (struct priv_spec_t): Replaced with struct riscv_spec.
412 (riscv_get_priv_spec_class): Replaced with RISCV_GET_PRIV_SPEC_CLASS.
413 (riscv_get_priv_spec_name): Replaced with RISCV_GET_PRIV_SPEC_NAME.
414 (riscv_priv_specs): Moved below.
415 (riscv_get_priv_spec_class_from_numbers): Likewise, updated.
416 (riscv_isa_specs): Moved from include/opcode/riscv.h.
417 * elfnn-riscv.c: Included cpu-riscv.h.
418 (riscv_merge_attributes): Initialize in_priv_spec and out_priv_spec.
419 * elfxx-riscv.c: Included cpu-riscv.h and opcode/riscv.h.
420 (RISCV_UNKNOWN_VERSION): Moved from include/opcode/riscv.h.
421 * elfxx-riscv.h: Removed extern functions to cpu-riscv.h.
422
423 2021-02-17 Alan Modra <amodra@gmail.com>
424
425 * wasm-module.c: Guard include of limits.h.
426 (CHAR_BIT): Provide backup define.
427 (wasm_read_leb128): Use CHAR_BIT to size "result" in bits.
428 Correct signed overflow checking.
429
430 2021-02-17 Nelson Chu <nelson.chu@sifive.com>
431
432 PR 27200
433 * elfnn-riscv.c (_bfd_riscv_elf_merge_private_bfd_data): Delay
434 copying the elf flags from input BFD to output BFD, until we have
435 checked if the input BFD has no code section or not. Also fix the
436 problem that we only check the first section rather than the entire
437 sections for input BFD.
438
439 2021-02-16 Alan Modra <amodra@gmail.com>
440
441 * libbfd.c (_bfd_read_unsigned_leb128): Avoid excessive shift.
442 (_bfd_safe_read_leb128, _bfd_read_signed_leb128): Likewise.
443
444 2021-02-15 Jan Beulich <jbeulich@suse.com>
445
446 * doc/Makefile.am: Replace "cp -p" by "$(LN_S)".
447 * doc/Makefile.in: Re-generate.
448
449 2021-02-15 Alan Modra <amodra@gmail.com>
450
451 * elf32-nds32.c (nds32_get_section_contents): Replace
452 bfd_malloc_and_get_section with bfd_get_full_section_contents.
453 (nds32_elf_relax_delete_blanks): Init contents.
454 (nds32_elf_relax_section, nds32_relax_fp_as_gp): Likewise.
455
456 2021-02-15 Alan Modra <amodra@gmail.com>
457
458 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents): Use
459 bfd_get_full_section_contents.
460
461 2021-02-14 Alan Modra <amodra@gmail.com>
462
463 * elfxx-mips.c (_bfd_elf_mips_get_relocated_section_contents): Apply
464 all fixes to bfd_generic_get_relocated_section_contents since this
465 function was split out.
466
467 2021-02-11 Alan Modra <amodra@gmail.com>
468
469 * config.bfd: Remove ia64 from obsolete list.
470
471 2021-02-11 Alan Modra <amodra@gmail.com>
472
473 PR ld/22269
474 * elfnn-ia64.c: Revert 2017-10-14 git commit db41f6eb5234.
475
476 2021-02-11 Alan Modra <amodra@gmail.com>
477
478 PR 27294
479 * elf32-avr.c (avr_elf32_load_records_from_section): Use
480 bfd_malloc_and_get_section. Use bfd_byte* vars and remove then
481 unnecessary casts.
482
483 2021-02-11 Alan Modra <amodra@gmail.com>
484
485 PR 27291
486 * section.c (bfd_get_section_contents): Avoid possible overflow
487 when range checking offset and count.
488 (bfd_set_section_contents): Likewise.
489
490 2021-02-03 Nick Alcock <nick.alcock@oracle.com>
491
492 * configure.ac (SHARED_LIBADD): Remove explicit -lintl population in
493 favour of LIBINTL.
494 * configure: Regenerated.
495
496 2021-02-09 Alan Modra <amodra@gmail.com>
497
498 * config.bfd (arm*-*-symbianelf*): Move from obsolete to removed.
499 * configure.ac: Delete symbian entries.
500 * elf-bfd.h (enum elf_target_os): Delete is_symbian.
501 * elf32-arm.c: Remove symbian support. Formatting.
502 * targets.c: Delete symbian entries.
503 * configure: Regenerate.
504
505 2021-02-04 H.J. Lu <hongjiu.lu@intel.com>
506
507 PR ld/19609
508 * elf64-x86-64.c (elf_x86_64_relocate_section): Provide more
509 info when failed to convert GOTPCREL relocation.
510
511 2021-02-04 Nelson Chu <nelson.chu@sifive.com>
512
513 * elfxx-riscv.c (riscv_parse_prefixed_ext): Removed zb*.
514
515 2021-02-04 Alan Modra <amodra@gmail.com>
516
517 PR 27311
518 * elflink.c (elf_link_add_object_symbols): Don't pull in as-needed
519 libraries for IR references on pass over libraries after LTO
520 recompilation.
521
522 2021-02-03 Alan Modra <amodra@gmail.com>
523
524 PR 27311
525 * elflink.c (_bfd_elf_add_default_symbol): Revert last two changes.
526 (elf_link_add_object_symbols): Here too. Don't pull in as-needed
527 libraries when H is an indirect symbol after calling
528 _bfd_elf_add_default_symbol.
529
530 2021-02-03 Alan Modra <amodra@gmail.com>
531
532 PR 27311
533 * elflink.c (_bfd_elf_add_default_symbol): Clear override when
534 undecorated symbol will have a different version.
535
536 2021-02-02 Alan Modra <amodra@gmail.com>
537
538 PR 27311
539 * elflink.c (_bfd_elf_add_default_symbol): Add override parameter.
540 Use when handling default versioned symbol. Rename existing
541 override variable to nondef_override and use for non-default
542 versioned symbol.
543 (elf_link_add_object_symbols): Adjust call to suit. Don't
544 pull in as-needed libraries when override is set.
545
546 2021-02-01 Emery Hemingway <ehmry@posteo.net>
547
548 * config.bfd: Add *-*-genode* as a target for AArch64 and x86.
549
550 2021-02-01 Egor Vishnyakov <lenvampir@yandex.ru>
551
552 PR 27254
553 * elf32-rl78.c (rl78_elf_relocate_section): Fix calculation of
554 offset for the R_RL78_RH_SADDR relocation.
555
556 2021-01-29 Alan Modra <amodra@gmail.com>
557
558 PR 27271
559 * elflink.c (bfd_elf_link_record_dynamic_symbol): Don't segfault
560 on symbols defined in absolute or other special sections.
561
562 2021-01-28 Alan Modra <amodra@gmail.com>
563
564 PR 27259
565 * elflink.c (_bfd_elf_gc_mark_extra_sections): Use linker_mark to
566 prevent endless looping of linked-to sections.
567
568 2020-12-17 Mihails Strasuns <mihails.strasuns@intel.com>
569
570 * bfd-elf.h (elfcore_write_file_note): New function.
571 * elf.c (elfcore_write_file_note): New function.
572
573 2021-01-26 Alan Modra <amodra@gmail.com>
574
575 * elf32-ft32.c (ft32_reloc_type_lookup): Don't miss ft32_reloc_map[0].
576
577 2021-01-24 H.J. Lu <hongjiu.lu@intel.com>
578
579 PR binutils/27231
580 * dwarf2.c (read_rnglists): Ignore empty range when parsing line
581 number tables.
582
583 2021-01-23 H.J. Lu <hongjiu.lu@intel.com>
584
585 PR binutils/27231
586 * dwarf2.c (read_rnglists): Advance rngs_ptr after
587 _bfd_safe_read_leb128 when parsing DW_RLE_offset_pair.
588
589 2021-01-20 Alan Modra <amodra@gmail.com>
590
591 * elf32-ppc.c: Delete outdated comment.
592 (TARGET_KEEP_UNUSED_SECTION_SYMBOLS): Define.
593 * elf64-ppc.c (TARGET_KEEP_UNUSED_SECTION_SYMBOLS): Define.
594
595 2021-01-20 Alan Modra <amodra@gmail.com>
596
597 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Don't assume
598 section symbols are present.
599
600 2021-01-19 Alan Modra <amodra@gmail.com>
601
602 * elf64-ppc.c (elf_hash_entry): New inline function. Use
603 throughout to replace casts.
604 (branch_reloc_hash_match): Remove const from params.
605 (use_local_plt): New function.
606 (allocate_dynrelocs, ppc_build_one_stub, ppc_size_one_stub),
607 (build_global_entry_stubs_and_plt, ppc64_elf_relocate_section):
608 Use use_local_plt.
609 * elf32-ppc.c (use_local_plt): New function.
610 (allocate_dynrelocs, ppc_elf_relocate_section),
611 (write_global_sym_plt): Use use_local_plt.
612
613 2021-01-17 H.J. Lu <hongjiu.lu@intel.com>
614
615 PR ld/27193
616 * elflink.c (elf_create_symbuf): Also ignore section symbols.
617
618 2021-01-16 H.J. Lu <hongjiu.lu@intel.com>
619
620 PR ld/23169
621 * elfxx-x86.c (_bfd_x86_elf_link_fixup_ifunc_symbol): Don't
622 check pointer_equality_needed.
623
624 2021-01-15 H.J. Lu <hongjiu.lu@intel.com>
625
626 * elf-linker-x86.h (elf_linker_x86_params): Add
627 report_relative_reloc.
628 * elf32-i386.c (elf_i386_relocate_section): Call
629 _bfd_x86_elf_link_report_relative_reloc to report relative
630 relocations for -z report-relative-reloc.
631 (elf_i386_finish_dynamic_symbol): Likewse.
632 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewse.
633 (elf_x86_64_finish_dynamic_symbol): Likewse.
634 * elfxx-x86.c (_bfd_x86_elf_link_report_relative_reloc): New
635 function.
636 * elfxx-x86.h (_bfd_x86_elf_link_report_relative_reloc): New
637 prototype.
638
639 2021-01-16 Alan Modra <amodra@gmail.com>
640
641 * compress.c (decompress_contents): Tidy inflateEnd result test.
642
643 2021-01-16 Alan Modra <amodra@gmail.com>
644
645 PR 26002
646 * elflink.c (elf_link_output_extsym): Use version 1 in
647 .gnu.version for undefined unversioned symbols.
648
649 2021-01-15 Nelson Chu <nelson.chu@sifive.com>
650
651 * elfnn-riscv.c (riscv_relax_delete_bytes): Fixed the indent that
652 caused the by previous commit accidentally.
653
654 2021-01-15 Nelson Chu <nelson.chu@sifive.com>
655
656 * elfnn-riscv.c: Indent, labels and GNU coding standards tidy,
657 also aligned the code.
658
659 2021-01-15 Nelson Chu <nelson.chu@sifive.com>
660
661 * elfnn-riscv.c (riscv_merge_attributes): Fix typos of messages.
662
663 2021-01-15 Nelson Chu <nelson.chu@sifive.com>
664
665 * elfnn-riscv.c: Comments tidy and improvement.
666 * elfxx-riscv.c: Likewise.
667 * elfxx-riscv.h: Likewise.
668
669 2021-01-14 H.J. Lu <hongjiu.lu@intel.com>
670
671 PR ld/26688
672 * elf32-bfin.c (bfinfdpic_relocate_section): Skip non SEC_ALLOC
673 section for R_BFIN_FUNCDESC.
674
675 2021-01-14 Nick Clifton <nickc@redhat.com>
676
677 * elf.c (elfcore_grok_win32pstatus): Check for a note type of 0.
678
679 2021-01-13 Alan Modra <amodra@gmail.com>
680
681 * Makefile.in: Regenerate.
682 * doc/Makefile.in: Regenerate.
683
684 2021-01-13 Alan Modra <amodra@gmail.com>
685
686 PR 27160
687 * section.c (struct bfd_section): Remove pattern field.
688 (BFD_FAKE_SECTION): Adjust to suit.
689 * bfd-in2.h: Regenerate.
690 * elflink.c (compare_link_order, elf_fixup_link_order): Delete.
691 (bfd_elf_final_link): Don't call elf_fixup_link_order.
692
693 2021-01-12 H.J. Lu <hongjiu.lu@intel.com>
694
695 PR binutils/26792
696 * configure.ac: Use GNU_MAKE_JOBSERVER.
697 * aclocal.m4: Regenerated.
698 * configure: Likewise.
699
700 2021-01-12 H.J. Lu <hongjiu.lu@intel.com>
701
702 PR ld/27171
703 * reloc.c (bfd_perform_relocation): Adjust R_AMD64_DIR64 and
704 R_AMD64_DIR32 relocations for PE/x86-64 inputs.
705
706 2021-01-11 H.J. Lu <hongjiu.lu@intel.com>
707
708 PR ld/27173
709 * configure: Regenerated.
710
711 2021-01-11 Nick Clifton <nickc@redhat.com>
712
713 * po/fr.po: Updated French translation.
714 * po/pt.po: Updated Portuguese translation.
715 * po/sr.po: Updated Serbian translation.
716 * po/uk.po: Updated Ukranian translation.
717
718 2021-01-09 H.J. Lu <hongjiu.lu@intel.com>
719
720 * configure: Regenerated.
721
722 2021-01-09 H.J. Lu <hongjiu.lu@intel.com>
723
724 PR ld/27166
725 * elfxx-x86.c (_bfd_x86_elf_merge_gnu_properties): Handle
726 -z lam-u48 and -z lam-u57.
727
728 2021-01-09 Nick Clifton <nickc@redhat.com>
729
730 * version.m4: Change to 2.36.50.
731 * configure: Regenerate.
732 * po/bfd.pot: Regenerate.
733
734 2021-01-09 Nick Clifton <nickc@redhat.com>
735
736 * 2.36 release branch crated.
737
738 2021-01-08 H.J. Lu <hongjiu.lu@intel.com>
739
740 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Also set
741 LAM_U57 when setting LAM_U48.
742
743 2021-01-08 H.J. Lu <hongjiu.lu@intel.com>
744
745 PR ld/26256
746 PR ld/27160
747 * elflink.c (elf_fixup_link_order): Verify that fixing up
748 SHF_LINK_ORDER doesn't increase the output section size.
749
750 2021-01-09 Alan Modra <amodra@gmail.com>
751
752 * configure: Regenerate.
753
754 2021-01-07 Samuel Thibault <samuel.thibault@gnu.org>
755
756 * configure: Regenerate.
757
758 2021-01-07 H.J. Lu <hongjiu.lu@intel.com>
759
760 PR 27109
761 * aix386-core.c (core_aix386_vec): Initialize
762 keep_unused_section_symbol to TARGET_KEEP_UNUSED_SECTION_SYMBOLS.
763 * aout-target.h (MY (vec)): Likewise.
764 * binary.c (binary_vec): Likewise.
765 * cisco-core.c (core_cisco_be_vec): Likewise.
766 (core_cisco_le_vec): Likewise.
767 * coff-alpha.c (alpha_ecoff_le_vec): Likewise.
768 * coff-i386.c (TARGET_SYM): Likewise.
769 (TARGET_SYM_BIG): Likewise.
770 * coff-ia64.c (TARGET_SYM): Likewise.
771 * coff-mips.c (mips_ecoff_le_vec): Likewise.
772 (mips_ecoff_be_vec): Likewise.
773 (mips_ecoff_bele_vec): Likewise.
774 * coff-rs6000.c (rs6000_xcoff_vec): Likewise.
775 (powerpc_xcoff_vec): Likewise.
776 * coff-sh.c (sh_coff_small_vec): Likewise.
777 (sh_coff_small_le_vec): Likewise.
778 * coff-tic30.c (tic30_coff_vec): Likewise.
779 * coff-tic54x.c (tic54x_coff0_vec): Likewise.
780 (tic54x_coff0_beh_vec): Likewise.
781 (tic54x_coff1_vec): Likewise.
782 (tic54x_coff1_beh_vec): Likewise.
783 (tic54x_coff2_vec): Likewise.
784 (tic54x_coff2_beh_vec): Likewise.
785 * coff-x86_64.c (TARGET_SYM): Likewise.
786 (TARGET_SYM_BIG): Likewise.
787 * coff64-rs6000.c (rs6000_xcoff64_vec): Likewise.
788 (rs6000_xcoff64_aix_vec): Likewise.
789 * coffcode.h (CREATE_BIG_COFF_TARGET_VEC): Likewise.
790 (CREATE_BIGHDR_COFF_TARGET_VEC): Likewise.
791 (CREATE_LITTLE_COFF_TARGET_VEC): Likewise.
792 * elfxx-target.h (TARGET_BIG_SYM): Likewise.
793 (TARGET_LITTLE_SYM): Likewise.
794 * hppabsd-core.c (core_hppabsd_vec): Likewise.
795 * hpux-core.c (core_hpux_vec): Likewise.
796 * i386msdos.c (i386_msdos_vec): Likewise.
797 * ihex.c (ihex_vec): Likewise.
798 * irix-core.c (core_irix_vec): Likewise.
799 * mach-o-target.c (TARGET_NAME): Likewise.
800 * mmo.c (mmix_mmo_vec): Likewise.
801 * netbsd-core.c (core_netbsd_vec): Likewise.
802 * osf-core.c (core_osf_vec): Likewise.
803 * pdp11.c (MY (vec)): Likewise.
804 * pef.c (pef_vec): Likewise.
805 (pef_xlib_vec): Likewise.
806 * plugin.c (plugin_vec): Likewise.
807 * ppcboot.c (powerpc_boot_vec): Likewise.
808 * ptrace-core.c (core_ptrace_vec): Likewise.
809 * sco5-core.c (core_sco5_vec): Likewise.
810 * som.c (hppa_som_vec): Likewise.
811 * srec.c (srec_vec): Likewise.
812 (symbolsrec_vec): Likewise.
813 * tekhex.c (tekhex_vec): Likewise.
814 * trad-core.c (core_trad_vec): Likewise.
815 * verilog.c (verilog_vec): Likewise.
816 * vms-alpha.c (alpha_vms_vec): Likewise.
817 * vms-lib.c (alpha_vms_lib_txt_vec): Likewise.
818 * wasm-module.c (wasm_vec): Likewise.
819 * xsym.c (sym_vec): Likewise.
820 * elf.c (ignore_section_sym): Return TRUE if BSF_SECTION_SYM_USED
821 isn't set.
822 (elf_map_symbols): Don't include ignored section symbols.
823 * elfcode.h (elf_slurp_symbol_table): Also set
824 BSF_SECTION_SYM_USED on STT_SECTION symbols.
825 * elflink.c (bfd_elf_final_link): Generated section symbols only
826 when emitting relocations or reqired.
827 * elfxx-x86.h (TARGET_KEEP_UNUSED_SECTION_SYMBOLS): New.
828 * syms.c (BSF_SECTION_SYM_USED): New.
829 * targets.c (TARGET_KEEP_UNUSED_SECTION_SYMBOLS): New.
830 (bfd_target): Add keep_unused_section_symbols.
831 (bfd_keep_unused_section_symbols): New.
832 * bfd-in2.h: Regenerated.
833
834 2021-01-07 Nick Clifton <nickc@redhat.com>
835
836 PR 25713
837 * bfdio.c (_bfd_real_fopen): For Win32 convert relative paths to
838 absolute paths and check to see if they are longer than MAX_PATH.
839
840 2021-01-07 Philipp Tomsich <prt@gnu.org>
841
842 * elfxx-riscv.c (riscv_std_z_ext_strtab): Added zihintpause.
843
844 2021-01-07 Claire Xenia Wolf <claire@symbioticeda.com>
845 Jim Wilson <jimw@sifive.com>
846 Andrew Waterman <andrew@sifive.com>
847 Maxim Blinov <maxim.blinov@embecosm.com>
848 Kito Cheng <kito.cheng@sifive.com>
849 Nelson Chu <nelson.chu@sifive.com>
850
851 * elfxx-riscv.c (riscv_std_z_ext_strtab): Added zba, zbb and zbc.
852
853 2021-01-06 H.J. Lu <hongjiu.lu@intel.com>
854
855 * elf32-bfin.c (bfin_check_relocs): Check bfd_link_hash_indirect.
856 (bfinfdpic_check_relocs): Likewise.
857
858 2021-01-06 Alan Modra <amodra@gmail.com>
859
860 * elf32-score.c (s3_bfd_score_info_to_howto): Report an error
861 on unknown r_type.
862 * elf32-score7.c (s7_bfd_score_info_to_howto): Likewise.
863
864 2021-01-06 Alan Modra <amodra@gmail.com>
865
866 * config.bfd (sparc-*-solaris2*): Add sparc_elf32_vec.
867 (sparc64-*-solaris2*): Add sparc_elf64_vec and
868 sparc_elf32_vec.
869
870 2021-01-06 Marcus Comstedt <marcus@mc.pp.se>
871
872 * config.bfd: Added targets riscv64be*-*-*, riscv32be*-*-* and
873 riscvbe*-*-*. Also added riscv_elf[32|64]_be_vec.
874 * configure.ac: Handle riscv_elf[32|64]_be_vec.
875 * configure: Regenerate.
876 * elfnn-riscv.c: Include <limits.h> and define CHAR_BIT for
877 riscv_is_insn_reloc.
878 (riscv_get_insn): RISC-V instructions are always little endian, but
879 bfd_get may be used for big-endian, so add new riscv_get_insn to handle
880 the insturctions.
881 (riscv_put_insn): Likewsie.
882 (riscv_is_insn_reloc): Check if we are relocaing an instruction.
883 (perform_relocation): Call riscv_is_insn_reloc to decide if we should
884 use riscv_[get|put]_insn or bfd_[get|put].
885 (riscv_zero_pcrel_hi_reloc): Use riscv_[get|put]_insn, bfd_[get|put]l32
886 or bfd_[get|put]l16 for code.
887 (riscv_elf_relocate_section): Likewise.
888 (riscv_elf_finish_dynamic_symbol): Likewise.
889 (riscv_elf_finish_dynamic_sections): Likewise.
890 (_bfd_riscv_relax_call): Likewise.
891 (_bfd_riscv_relax_lui): Likewise.
892 (_bfd_riscv_relax_align): Likewise.
893 (_bfd_riscv_relax_pc): Likewise.
894 (riscv_elf_object_p): Handled for big endian.
895 (TARGET_BIG_SYM, TARGET_BIG_NAME): Defined.
896 * targets.c: Add riscv_elf[32|64]_be_vec.
897 (_bfd_target_vector): Likewise.
898
899 2021-01-05 Alan Modra <amodra@gmail.com>
900
901 * elflink.c (bfd_elf_link_record_dynamic_symbol): Handle no_export
902 for relocatable executable.
903
904 2021-01-05 Alan Modra <amodra@gmail.com>
905
906 * vms-alpha.c (_bfd_vms_slurp_egsd): Read flags after size check.
907
908 2021-01-05 Nelson Chu <nelson.chu@sifive.com>
909
910 * elfnn-riscv.c (allocate_dynrelocs): When we are generating pde,
911 make sure gp symbol is output as a dynamic symbol.
912
913 2021-01-04 H.J. Lu <hongjiu.lu@intel.com>
914
915 PR ld/26256
916 * elflink.c (compare_link_order): Place unordered sections before
917 ordered sections.
918 (elf_fixup_link_order): Add a link info argument. Allow mixed
919 ordered and unordered input sections for non-relocatable link.
920 Sort the consecutive bfd_indirect_link_order sections with the
921 same pattern. Change the offsets of the bfd_indirect_link_order
922 sections only.
923 (bfd_elf_final_link): Pass info to elf_fixup_link_order.
924 * section.c (bfd_section): Add pattern.
925 (BFD_FAKE_SECTION): Initialize pattern to NULL.
926 * bfd-in2.h: Regenerated.
927
928 2021-01-04 Alexander Fedotov <alfedotov@gmail.com>
929
930 * elf32-arm.c (elf32_arm_print_private_bfd_data): Prefix hex value
931 of private flags with 0x.
932 * elfnn-aarch64.c (elfNN_aarch64_print_private_bfd_data): Likewise.
933
934 2021-01-04 Alan Modra <amodra@gmail.com>
935
936 PR 26822
937 * elflink.c (elf_link_input_bfd): Use the file base name in
938 linker generated STT_FILE symbols.
939
940 2021-01-04 Nelson Chu <nelson.chu@sifive.com>
941
942 * elfxx-riscv.c (riscv_compare_subsets): Removed static.
943 * elfxx-riscv.h: Add declaration.
944 * elfnn-riscv.c (riscv_merge_multi_letter_ext): Use
945 riscv_compare_subsets to check the orders.
946 (riscv_skip_prefix): Removed.
947 (riscv_prefix_cmp): Removed.
948
949 2021-01-04 Alan Modra <amodra@gmail.com>
950
951 PR 26741
952 * elfxx-riscv.c (riscv_parse_prefixed_ext): Free subset after
953 calculating subset version length.
954
955 2021-01-01 Nicolas Boulenguez <nicolas@debian.org>
956
957 * xcofflink.c: Correct spelling in comments.
958
959 2021-01-01 Alan Modra <amodra@gmail.com>
960
961 Update year range in copyright notice of all files.
962
963 For older changes see ChangeLog-2020
964 \f
965 Copyright (C) 2021 Free Software Foundation, Inc.
966
967 Copying and distribution of this file, with or without modification,
968 are permitted in any medium without royalty provided the copyright
969 notice and this notice are preserved.
970
971 Local Variables:
972 mode: change-log
973 left-margin: 8
974 fill-column: 74
975 version-control: never
976 End:
This page took 0.047468 seconds and 5 git commands to generate.