1 2018-07-05 Alan Modra <amodra@gmail.com>
3 * elf-bfd.h (_bfd_elf_ppc_merge_fp_attributes): Update prototype.
4 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Return error
5 on mismatch. Remove "warning: " from messages. Track last bfd
7 (ppc_elf_merge_obj_attributes): Likewise. Handle status from
8 _bfd_elf_ppc_merge_fp_attributes.
9 * elf64-ppc.c (ppc64_elf_merge_private_bfd_data): Handle status
10 from _bfd_elf_ppc_merge_fp_attributes.
12 2018-07-04 H.J. Lu <hongjiu.lu@intel.com>
14 * Makefile.am (bfdinclude_HEADERS): Add $(INCDIR)/diagnostics.h.
15 * Makefile.in: Regenerated.
17 2018-07-03 Alan Modra <amodra@gmail.com>
19 * elflink.c (bfd_elf_final_link): Remove zero size .gnu.attributes
22 2018-07-03 Alan Modra <amodra@gmail.com>
24 * elf-bfd.h (ATTR_TYPE_FLAG_ERROR, ATTR_TYPE_HAS_ERROR): Define.
25 * elf-attrs.c (is_default_attr): Handle ATTR_TYPE_HAS_ERROR.
26 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Use
27 ATTR_TYPE_FLAG_INT_VAL. Set ATTR_TYPE_HAS_ERROR on finding
28 incompatible attribute.
29 (ppc_elf_merge_obj_attributes): Likewise. Return
30 _bfd_elf_merge_object_attributes result.
31 * elf64-ppc.c (ppc64_elf_merge_private_bfd_data): Return
32 _bfd_elf_merge_object_attributes result.
34 2018-07-03 Alan Modra <amodra@gmail.com>
37 * elflink.c (_bfd_elf_fix_symbol_flags): Hide dynamic symbols
38 in discarded sections.
40 2018-07-02 Maciej W. Rozycki <macro@mips.com>
42 * elfxx-mips.c (_bfd_mips_elf_create_dynamic_sections): Set
43 `mark' for symbols created from `mips_elf_dynsym_rtproc_names'
46 2018-07-02 Maciej W. Rozycki <macro@mips.com>
48 * elf64-mips.c (micromips_elf64_howto_table_rel): Add
49 R_MICROMIPS_HI0_LO16, R_MICROMIPS_TLS_GD, R_MICROMIPS_TLS_LDM,
50 R_MICROMIPS_TLS_DTPREL_HI16, R_MICROMIPS_TLS_DTPREL_LO16,
51 R_MICROMIPS_TLS_GOTTPREL, R_MICROMIPS_TLS_TPREL_HI16,
52 R_MICROMIPS_TLS_TPREL_LO16, R_MICROMIPS_GPREL7_S2 and
53 R_MICROMIPS_PC23_S2 relocation entries.
54 (micromips_elf64_howto_table_rela): Likewise.
55 (micromips_reloc_map): Likewise.
56 * elfn32-mips.c (elf_micromips_howto_table_rel): Likewise.
57 (elf_micromips_howto_table_rela): Likewise.
58 (micromips_reloc_map): Likewise.
60 2018-07-02 H.J. Lu <hongjiu.lu@intel.com>
63 * elf64-x86-64.c (elf_x86_64_relocate_section): Clear the
64 R_X86_64_converted_reloc_bit bit.
66 2018-07-02 Jeff Muizelaar <jrmuizel@gmail.com>
67 Tom Tromey <tom@tromey.com>
71 * mach-o.c (bfd_mach_o_fat_close_and_cleanup): New function.
72 (bfd_mach_o_close_and_cleanup): Redefine.
73 * archive.c (_bfd_unlink_from_archive_parent): New function,
75 (_bfd_archive_close_and_cleanup): ..here.
76 (bfd_generic_archive_p): Do not clear archive's format.
77 * libbfd-in.h (_bfd_unlink_from_archive_parent): Declare.
78 * libbfd.h: Regenerate.
80 2018-07-02 Thomas Preud'homme <thomas.preudhomme@arm.com>
82 * archures.c (bfd_mach_arm_5TEJ, bfd_mach_arm_6, bfd_mach_arm_6KZ,
83 bfd_mach_arm_6T2, bfd_mach_arm_6K, bfd_mach_arm_7, bfd_mach_arm_6M,
84 bfd_mach_arm_6SM, bfd_mach_arm_7EM, bfd_mach_arm_8, bfd_mach_arm_8R,
85 bfd_mach_arm_8M_BASE, bfd_mach_arm_8M_MAIN): Define.
86 * bfd-in2.h: Regenerate.
87 * cpu-arm.c (arch_info_struct): Add entries for above new
89 * elf32-arm.c (bfd_arm_get_mach_from_attributes): Add Tag_CPU_arch to
90 bfd_mach_arm mapping logic for pre Armv4 and Armv5TEJ and later
91 architectures. Force assert failure for any new Tag_CPU_arch value.
93 2018-07-02 Thomas Preud'homme <thomas.preudhomme@arm.com>
95 * doc/bfdint.texi: Use command-line consistently when used in a
97 * doc/bfdsumm.texi: Likewise.
99 2018-06-29 Maciej W. Rozycki <macro@mips.com>
101 * elfxx-mips.c (allocate_dynrelocs): Remove extraneous symbol
102 visibility check made for undefined weak symbols.
104 2018-06-26 Nick Clifton <nickc@redhat.com>
106 * po/uk.po: Updated Ukranian translation.
108 2018-06-25 Nick Clifton <nickc@redhat.com>
110 * elfnn-aarch64.c (_bfd_aarch64_erratum_835769_stub_name): Check
111 for malloc returning NULL.
112 (_bfd_aarch64_erratum_843419_fixup): Check for
113 _bfd_aarch64_erratum_835769_stub_name returning NULL.
115 2018-06-24 Nick Clifton <nickc@redhat.com>
117 * po/bfd.pot: Regenerate.
119 2018-06-24 Nick Clifton <nickc@redhat.com>
121 * version.m4: Update version string to 2.31.51.
122 * configure: Regenerate.
124 2018-06-24 Nick Clifton <nickc@redhat.com>
128 2018-06-21 Maciej W. Rozycki <macro@mips.com>
130 * elfxx-mips.c (_bfd_mips_elf_compact_eh_encoding)
131 (_bfd_mips_elf_cant_unwind_opcode): Correct formatting.
133 2018-06-21 Maciej W. Rozycki <macro@mips.com>
135 * elfxx-mips.c (_bfd_mips_post_process_headers): Keep
136 EI_ABIVERSION setting together.
138 2018-06-21 Maciej W. Rozycki <macro@mips.com>
140 * elfxx-mips.c (MIPS_LIBC_ABI_DEFAULT, MIPS_LIBC_ABI_MIPS_PLT)
141 (MIPS_LIBC_ABI_UNIQUE, MIPS_LIBC_ABI_MIPS_O32_FP64)
142 (MIPS_LIBC_ABI_MAX): New enumeration constants.
143 (_bfd_mips_post_process_headers): Use them in place of magic
146 2018-06-21 Jim Wilson <jimw@sifive.com>
148 * elfnn-riscv.c (riscv_elf_finish_dynamic_symbol): Update comment.
149 Use SYMBOL_REFERENCES_LOCAL. Add asserts for h->got.offset.
151 2018-06-21 Alan Modra <amodra@gmail.com>
153 * doc/Makefile.am (AUTOMAKE_OPTIONS): Add "foreign".
154 * doc/Makefile.in: Regenerate.
156 2018-06-20 Renlin Li <renlin.li@arm.com>
158 * elfxx-aarch64.c (_bfd_aarch64_elf_resolve_relocation): Use PG_OFFSET
159 to resolve BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12_NC,
160 BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12_NC,
161 BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12_NC,
162 BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12_NC,
163 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
164 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
165 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
166 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
168 2018-06-20 Nick Clifton <nickc@redhat.com>
171 * opncls.c (get_build_id): Check for a negative or excessive data
172 size in the build-id note.
174 2018-06-20 Nick Clifton <nickc@redhat.com>
177 * mach-o.c (cputype): New function.
178 (cpusubtype): New function.
179 (bfd_mach_o_bfd_print_private_data): New function. Dispalys the
180 values in the MACH-O file header.
181 (bfd_mach_o_bfd_copy_private_header_data): Copy the cputype and
182 cpusubtype fields from the input bfd's mach-o header to the output
184 * mach-o-target.c (bfd_mach_o_bfd_print_private_bfd_data):
185 Redefine to bfd_mach_o_bfd_print_private_data.
186 * mach-o.h (bfd_mach_o_bfd_print_private_bfd_data): Prototype.
188 2018-06-19 Maciej W. Rozycki <macro@mips.com>
191 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Verify the
192 `.got.plt' entry referred is in range.
193 (mips_finish_exec_plt): Correct the range check for `.got.plt'
194 start. Replace the assertion used for that with a proper error
197 2018-06-19 Maciej W. Rozycki <macro@mips.com>
199 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Fix
202 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
204 * Makefile.am (AUTOMAKE_OPTIONS): Remove 1.11.
205 (INCLUDES): Rename to ...
206 (AM_CPPFLAGS): ... this.
207 * configure.ac: Remove AC_PREREQ.
208 * doc/Makefile.am (AUTOMAKE_OPTIONS): Remove 1.9, cygnus, add
209 info-in-builddir no-texinfo.tex.
210 (info_TEXINFOS): Rename bfd.texinfo to bfd.texi.
211 * doc/bfd.texinfo: Rename to ...
212 * doc/bfd.texi: ... this.
213 * Makefile.in: Re-generate.
214 * aclocal.m4: Re-generate.
215 * config.in: Re-generate.
216 * configure: Re-generate.
217 * doc/Makefile.in: Re-generate.
219 2018-06-18 Mephi <mephi42@gmail.com>
222 * mach-o-x86-64.c (x86_64_howto_table): Add entry for
223 BFD_RELOC_MACH_O_X86_64_RELOC_TLV.
224 (bfd_mach_o_x86_64_canonicalize_one_reloc): Handle the new reloc.
225 (bfd_mach_o_x86_64_swap_reloc_out): Likewise.
226 * reloc.c (BFD_RELOC_MACH_O_X86_64_TV): New entry.
227 * bfd-in2.h: Regenerate.
228 * libbfd.h: Regenerate.
230 2018-06-14 Faraz Shahbazker <Faraz.Shahbazker@mips.com>
232 * elfxx-mips.c (print_mips_ases): Add GINV extension.
234 2018-06-14 H.J. Lu <hongjiu.lu@intel.com>
237 * elf.c (_bfd_elf_get_symbol_version_string): Check if the first
238 symbol version is base version.
240 2018-06-14 Alan Modra <amodra@gmail.com>
242 * elf-bfd.h (struct elf_link_hash_table): Add "dynamic_relocs".
243 * elflink.c (_bfd_elf_init_2_index_sections): Comment fix.
244 (_bfd_elf_add_dynamic_entry): Set "dynamic_relocs".
245 (_bfd_elf_link_renumber_dynsyms): Exclude all section symbols when
246 "dynamic_relocs" is not set.
247 * elfxx-mips.c (count_section_dynsyms): Likewise.
249 2018-06-14 Alan Modra <amodra@gmail.com>
252 * bfdio.c (bfd_seek): Optimize away seeks to current position.
254 2018-06-13 Scott Egerton <scott.egerton@imgtec.com>
255 Faraz Shahbazker <Faraz.Shahbazker@mips.com>
257 * elfxx-mips.c (print_mips_ases): Add CRC.
259 2018-06-08 H.J. Lu <hongjiu.lu@intel.com>
262 * elfxx-x86.c (elf_x86_hide_linker_defined): New function.
263 (_bfd_x86_elf_link_check_relocs): Use it to hide hidden
264 __bss_start, _end and _edata in shared libraries.
266 2018-06-07 Alan Modra <amodra@gmail.com>
268 * elf32-tic6x.c (elf32_tic6x_check_relocs): Reference
269 __c6xabi_DSBT_BASE explicitly for R_C6000_SBR_* relocs.
271 2018-06-05 Alan Modra <amodra@gmail.com>
273 * bfd.c (struct bfd): Update comment on "where" usage.
274 * bfdio.c (bfd_bwrite, bfd_stat): Use and update "iovec",
275 "iostream", and "where" from containing archive file. Return
277 (bfd_bread): Similarly, and return error attempted out of
278 bounds archive element access.
279 (bfd_tell, bfd_flush): Use and update "iovec", "iostream", and
280 "where" from containing archive file.
281 (bfd_seek): Likewise. Return error on NULL iovec. Don't
282 attempt to optimize away seeks. Don't paper over errors by
284 (bfd_get_mtime): Call bfd_stat rather than iovec->bstat.
285 (bfd_get_size): Likewise.
286 (bfd_mmap): Operate on and use iovec of containing archive
287 file. Return error on NULL iovec.
288 * cache.c (bfd_cache_lookup_worker): Abort if working on
290 (cache_bread_1): Delete bfd parameter, add FILE* parameter.
291 Don't ignore zero byte reads.
292 (cache_bread): Look up FILE* in cache here. Error on NULL
294 (cache_bwrite): Rename "where" to "from".
295 (cache_bmmap): Don't handle archive elements.
296 * coffcode.h (coff_slurp_line_table): Exit early on zero
298 * bfd-in2.h: Regenerate.
300 2018-06-05 Alan Modra <amodra@gmail.com>
303 * plugin.c (bfd_plugin_open_input): Allow for possibility of
304 nested archives. Open file again for plugin.
305 (try_claim): Don't save and restore file position. Close file
307 * sysdep.h (O_BINARY): Define.
309 2018-06-04 Max Filippov <jcmvbkbc@gmail.com>
311 * elf32-xtensa.c (xtensa_read_table_entries): Make global.
312 (compute_fill_extra_space): Drop declaration. Rename function to
313 xtensa_compute_fill_extra_space.
314 (compute_ebb_actions, remove_dead_literal): Update references to
315 compute_fill_extra_space.
317 2018-06-04 Volodymyr Arbatov <arbatov@cadence.com>
319 * elf32-xtensa.c (elf32xtensa_separate_props): New global
321 (xtensa_add_names): New function.
322 (xtensa_property_section_name): Add new parameter
323 separate_sections, use it to choose property section name.
324 (xtensa_get_separate_property_section): New function.
325 (xtensa_get_property_section): Invoke
326 xtensa_get_separate_property_section to get individual property
327 section if it exists, common property section otherwise.
328 (xtensa_make_property_section): Pass elf32xtensa_separate_props
329 to xtensa_property_section_name.
331 2018-06-04 H.J. Lu <hongjiu.lu@intel.com>
334 * bfd-in.h: Include "diagnostics.h".
335 * bfd-in2.h: Regenerated.
336 * elf32-arm.c (elf32_arm_nabi_write_core_note): Use
337 DIAGNOSTIC_PUSH, DIAGNOSTIC_IGNORE_STRINGOP_TRUNCATION and
338 DIAGNOSTIC_POP to silence GCC 8.1 warnings with
339 -Wstringop-truncation.
340 * elf32-ppc.c (ppc_elf_write_core_note): Likewse.
341 * elf32-s390.c (elf_s390_write_core_note): Likewse.
342 * elf64-ppc.c (ppc64_elf_write_core_note): Likewse.
343 * elf64-s390.c (elf_s390_write_core_note): Likewse.
344 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewse.
346 2018-06-03 Jim Wilson <jimw@sifive.com>
349 * elfnn-riscv.c (riscv_elf_relocate_section) <R_RISCV_CALL>: Check
350 for and handle an undefined weak with no PLT.
353 * elfnn-riscv.c (riscv_relax_delete_bytes): Add versioned_hidden check
354 to code that ignores duplicate symbols.
356 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
358 * version.m4: Bump version to 2.30.52
359 * configure: Regenerated.
361 2018-06-01 Alan Modra <amodra@gmail.com>
363 * bfd.c (_bfd_error_handler): Arrange for this function to be
364 declared in bfd-in2.h.
365 * libbfd-in.h (_bfd_error_handler): Don't declare.
366 * libbfd.h: Regenerate.
367 * bfd-in2.h: Regenerate.
369 2018-05-30 Amaan Cheval <amaan.cheval@gmail.com>
371 * config.bfd (x86_64-*-*): Add pei-x86-64 target to x86_64-*-rtems*
372 This is needed to generate UEFI application image files from ELFs.
374 2018-05-28 H.J. Lu <hongjiu.lu@intel.com>
376 * elf32-i386.c (elf_i386_lazy_plt): Add plt_tlsdesc_entry,
377 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
378 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
379 plt_tlsdesc_got2_insn_end for TLSDESC entry.
380 (elf_i386_lazy_ibt_plt): Likewise.
381 (elf_i386_nacl_plt): Likewise.
382 * elf64-x86-64.c (tlsdesc_plt_entry): Moved and renamed to ...
383 (elf_x86_64_tlsdesc_plt_entry): This.
384 (elf_x86_64_lazy_plt): Add plt_tlsdesc_entry,
385 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
386 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
387 plt_tlsdesc_got2_insn_end for TLSDESC entry.
388 (elf_x86_64_lazy_bnd_plt): Likewise.
389 (elf_x86_64_lazy_ibt_plt): Likewise.
390 (elf_x32_lazy_ibt_plt): Likewise.
391 (elf_x86_64_nacl_plt): Likewise.
392 (elf_x86_64_finish_dynamic_sections): Use plt_tlsdesc_entry,
393 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
394 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
395 plt_tlsdesc_got2_insn_end to update TLSDESC entry.
396 * elfxx-x86.h (elf_x86_lazy_plt_layout): Update comments.
397 Add plt_tlsdesc_entry, plt_tlsdesc_entry_size,
398 plt_tlsdesc_got1_offset, plt_tlsdesc_got2_offset,
399 plt_tlsdesc_got1_insn_end and plt_tlsdesc_got2_insn_end.
400 (elf_x86_non_lazy_plt_layout): Update comments.
401 (elf_x86_plt_layout): Likewise.
403 2018-05-28 H.J. Lu <hongjiu.lu@intel.com>
406 * elf-s390-common.c (elf_s390_add_symbol_hook): Removed.
407 * elf32-arc.c (elf_arc_add_symbol_hook): Likewise.
408 (elf_backend_add_symbol_hook): Likewise.
409 * elf32-m68k.c (elf_m68k_add_symbol_hook): Likewise.
410 (elf_backend_add_symbol_hook): Likewise.
411 * elf32-s390.c (elf_backend_add_symbol_hook): Likewise.
412 * elf32-sparc.c (elf32_sparc_add_symbol_hook): Likewise.
413 (elf_backend_add_symbol_hook): Likewise.
414 * elf64-s390.c (elf_backend_add_symbol_hook): Likewise.
415 * elfxx-aarch64.c (_bfd_aarch64_elf_add_symbol_hook): Likewise.
416 * elfxx-aarch64.h (_bfd_aarch64_elf_add_symbol_hook): Likewise.
417 (elf_backend_add_symbol_hook): Likewise.
418 * elf32-arm.c (elf32_arm_add_symbol_hook): Remove STT_GNU_IFUNC
420 * elf32-ppc.c (ppc_elf_add_symbol_hook): Likewise.
421 * elf64-ppc.c (ppc64_elf_add_symbol_hook): Likewise.
422 * elf64-sparc.c (elf64_sparc_add_symbol_hook): Likewise.
423 * elflink.c (elf_link_add_object_symbols): Set
424 elf_gnu_symbol_ifunc for STT_GNU_IFUNC symbols.
426 2018-05-26 H.J. Lu <hongjiu.lu@intel.com>
429 * elf-bfd.h (_bfd_elf_link_hide_sym_by_version): New.
430 * elflink.c (_bfd_elf_link_hide_versioned_symbol): New function.
431 Extracted from _bfd_elf_link_assign_sym_version.
432 (_bfd_elf_link_hide_sym_by_version): New function.
433 (_bfd_elf_link_assign_sym_version): Use
434 _bfd_elf_link_hide_versioned_symbol.
435 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Call
436 _bfd_elf_link_hide_sym_by_version instead of
437 bfd_hide_sym_by_version. Don't check unversioned symbol.
439 2018-05-25 Alan Modra <amodra@gmail.com>
441 * Makefile.in: Regenerate.
442 * po/SRC-POTFILES.in: Regenerate.
444 2018-05-25 Alan Modra <amodra@gmail.com>
446 * configure.ac (bfd_cv_hidden): Run test with -Werror in CFLAGS.
447 * configure: Regenerate.
449 2018-05-23 H.J. Lu <hongjiu.lu@intel.com>
451 * elf64-ppc.c (ppc64_elf_write_core_note): Add ATTRIBUTE_NONSTRING
454 2018-05-22 Alan Modra <amodra@gmail.com>
457 * elf32-hppa.c (hppa_get_stub_entry): Return NULL when link_sec
459 (elf32_hppa_size_stubs): Only create stubs for load, alloc, code
461 (final_link_relocate): Revert last change.
463 2018-05-22 Alan Modra <amodra@gmail.com>
466 * elf32-hppa.c (final_link_relocate): Don't look for plt call
467 stubs in non-alloc sections.
469 2018-05-21 H.J. Lu <hongjiu.lu@intel.com>
472 * aout-target.h (MY_bfd_link_hide_symbol): New.
473 * aout-tic30.c (MY_bfd_link_hide_symbol): Likewise.
474 * binary.c (binary_bfd_link_hide_symbol): Likewise.
475 * coff-alpha.c (_bfd_ecoff_bfd_link_hide_symbol): Likewise.
476 * coff-mips.c (_bfd_ecoff_bfd_link_hide_symbol): Likewise.
477 * coff-rs6000.c (_bfd_xcoff_bfd_link_hide_symbol): Likewise.
478 * coffcode.h (coff_bfd_link_hide_symbol): Likewise.
479 * elf-bfd.h (_bfd_elf_link_hide_symbol): Likewise.
480 * elfxx-target.h (bfd_elfNN_bfd_link_hide_symbol): Likewise.
481 * i386msdos.c (msdos_bfd_link_hide_symbol): Likewise.
482 * ihex.c (ihex_bfd_link_hide_symbol): Likewise.
483 * libbfd-in.h (_bfd_nolink_bfd_link_hide_symbol): Likewise.
484 * linker.c (_bfd_generic_link_hide_symbol): Likewise.
485 (bfd_link_hide_symbol): Likewise.
486 * mach-o-target.c (bfd_mach_o_bfd_link_hide_symbol): Likewise.
487 * mmo.c (mmo_bfd_link_hide_symbol): Likewise.
488 * pef.c (bfd_pef_bfd_link_hide_symbol): Likewise.
489 * plugin.c (bfd_plugin_bfd_link_hide_symbol): Likewise.
490 * ppcboot.c (ppcboot_bfd_link_hide_symbol): Likewise.
491 * som.c (som_bfd_link_hide_symbol): Likewise.
492 * srec.c (srec_bfd_link_hide_symbol): Likewise.
493 * tekhex.c (tekhex_bfd_link_hide_symbol): Likewise.
494 * vms-alpha.c (vms_bfd_link_hide_symbol): Likewise.
495 (alpha_vms_bfd_link_hide_symbol): Likewise.
496 * xsym.c (bfd_sym_bfd_link_hide_symbol): Likewise.
497 * coff64-rs6000.c (rs6000_xcoff64_vec): Add
498 _bfd_generic_link_hide_symbol.
499 (rs6000_xcoff64_aix_vec): Likewise.
500 * elflink.c (bfd_elf_record_link_assignment): Don't make forced
501 local symbol dynamic.
502 (_bfd_elf_link_hide_symbol): New function.
503 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
504 check root.ldscript_def.
505 * targets.c (bfd_target): Add _bfd_link_hide_symbol.
506 (BFD_JUMP_TABLE_LINK): Add NAME##_bfd_link_hide_symbol.
507 * bfd-in2.h: Regenerated.
508 * libbfd.h: Likewise.
510 2018-05-21 H.J. Lu <hongjiu.lu@intel.com>
513 * elf.c (setup_group): Mark section in a section group with
516 2018-05-18 H.J. Lu <hongjiu.lu@intel.com>
519 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
520 set eh->local_ref to 1 if a symbol is versioned and there is a
523 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
525 * elfnn-riscv.c (_bfd_riscv_elf_merge_private_bfd_data): Handle
528 2018-05-18 Jim Wilson <jimw@sifive.com>
530 * elfnn-riscv.c (allocate_dynrelocs): Discard dynamic relocations if
531 UNDEFWEAK_NO_DYNAMIC_RELOC is true.
532 (riscv_elf_relocate_section): Don't generate dynamic relocation if
533 UNDEFWEAK_NO_DYNAMIC_RELOC is true.
534 (riscv_elf_finish_dynamic_symbol): Likewise.
536 2018-05-18 John Darrington <john@darrington.wattle.id.au>
538 * Makefile.am: Add s12z files.
539 * Makefile.in: Regenerate.
540 * archures.c: Add bfd_s12z_arch.
541 * bfd-in.h: Add exports of bfd_putb24 and bfd_putl24.
542 * bfd-in2.h: Regenerate.
543 * config.bfd: Add s12z target.
544 * configure.ac: Add s12z target.
545 * configure: Regenerate.
546 * cpu-s12z.c: New file.
547 * elf32-s12z.c: New file.
548 * libbfd.c (bfd_putb24): New function.
549 (bfd_putl24): New function.
550 * libbfd.h: Regenerate.
551 * reloc.c: Add s12z relocations.
552 (bfd_get_reloc_size): Handle size 5 relocs.
553 * targets.c: Add s12z_elf32_vec.
555 2018-05-18 H.J. Lu <hongjiu.lu@intel.com>
558 * elf32-i386.c (elf_i386_relocate_section): Handle R_386_GOT32X
560 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
561 set eh->local_ref to 1 for linker defined symbols.
563 2018-05-18 Alan Modra <amodra@gmail.com>
566 * elf.c (setup_group): Formatting. Check that SHT_GROUP entries
567 don't point at other SHT_GROUP sections. Set shdr corresponding
568 to invalid entry, to NULL rather than section 0. Identify
569 SHT_GROUP section index when reporting an error. Cope with NULL
572 2018-05-18 Alan Modra <amodra@gmail.com>
574 * libbfd-in.h (ATTRIBUTE_HIDDEN): Define and use throughout.
575 * configure.ac (HAVE_HIDDEN): Check compiler support for hidden
577 * libbfd.h: Regenerate.
578 * configure: Regenerate.
579 * config.in: Regenerate.
581 2018-05-18 Alan Modra <amodra@gmail.com>
583 * libbfd-in.h: Add include guard.
584 * libcoff-in.h: Likewise.
585 * doc/Makefile.am (libbfd.h, libcoff.h): Append another #endif.
586 * doc/Makefile.in: Regenerate.
587 * libbfd.h: Regenerate.
588 * libcoff.h: Regenerate.
590 2018-05-16 Maciej W. Rozycki <macro@mips.com>
592 * elf32-nds32.c (nds32_convert_32_to_16): Preset `insn_type'.
594 2018-05-16 Alan Modra <amodra@gmail.com>
597 * format.c (struct bfd_preserve): Add section_id.
598 (bfd_preserve_save, bfd_preserve_restore): Save and restore
600 (bfd_reinit): Set _bfd_section_id.
601 (bfd_check_format_matches): Put all matches of any priority into
602 matching_vector. Save initial section id and start each attempted
603 match at that section id.
604 * libbfd-in.h (_bfd_section_id): Declare.
605 * section.c (_bfd_section_id): Rename from section_id and make
607 (bfd_get_next_section_id): Delete.
608 * elf64-ppc.c (ppc64_elf_setup_section_lists): Replace use of
609 bfd_get_section_id with _bfd_section_id.
610 * libbfd.h: Regenerate.
611 * bfd-in2.h: Regenerate.
613 2018-05-15 Christophe Guillon <christophe.guillon@st.com>
615 * coffcode.h (coff_bigobj_swap_aux_in): Make sure that all fields
616 of the aux structure are initialised.
618 2018-05-15 Francois H. Theron <francois.theron@netronome.com>
620 * targets.c: Wrap nfp_elf64_vec in BFD64 ifdef.
622 2018-05-15 Nick Clifton <nickc@redhat.com>
624 * po/pt.po: New Portuguese translation.
625 * configure.ac (ALL_LINGUAS): Add pt.
626 * configure: Regenerate.
628 2018-05-14 H.J. Lu <hongjiu.lu@intel.com>
631 * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Don't issue
632 an error on IFUNC pointer defined in PDE.
633 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Call
634 _bfd_x86_elf_link_fixup_ifunc_symbol.
635 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
636 * elfxx-x86.c (_bfd_x86_elf_link_fixup_ifunc_symbol): New
638 * elfxx-x86.h (_bfd_x86_elf_link_fixup_ifunc_symbol): New.
640 2018-05-14 H.J. Lu <hongjiu.lu@intel.com>
643 * elfxx-x86.c (elf_x86_linker_defined): New function.
644 (_bfd_x86_elf_link_check_relocs): Use it to mark __bss_start,
645 _end and _edata locally defined within executables.
647 2018-05-12 Alan Modra <amodra@gmail.com>
650 * elf.c (rewrite_elf_program_header): Use segment_mark only for
651 PT_LOAD headers. Delete first_matching_lma and first_suggested_lma.
652 Instead make matching_lma and suggested_lma pointers to the
653 sections. Align section vma and lma calculated from segment.
654 Don't clear includes_phdrs or includes_filehdr based on p_paddr
655 test. Try to handle alignment padding before first section by
656 adjusting new segment lma down. Adjust PT_PHDR map p_paddr.
658 2018-05-09 Dimitar Dimitrov <dimitar@dinux.eu>
660 * elf32-pru.c (pru_elf32_do_ldi32_relocate): Make LDI32 relocation
661 conformant to TI ABI.
662 (pru_elf32_relax_section): Likewise.
663 (pru_elf_relax_delete_bytes): Fix offsets for new LDI32 code.
664 * elf32-pru.c (pru_elf32_do_ldi32_relocate): Ignore addend.
665 (pru_elf32_pmem_relocate): Trap - should not get here.
666 (pru_elf32_relocate_section): Add support for REL relocations.
667 (elf_info_to_howto_rel): Enable REL.
668 (elf_backend_may_use_rel_p): Likewise.
669 (elf_backend_may_use_rela_p): Likewise.
670 (elf_backend_default_use_rela_p): Likewise.
672 2018-05-09 Alan Modra <amodra@gmail.com>
675 * peXXigen.c (pe_print_edata): Correct minimum size.
677 2018-05-09 Alan Modra <amodra@gmail.com>
680 * peXXigen.c (pe_print_idata): Bound check hint_addr.
682 2018-05-08 Nick Clifton <nickc@redhat.com>
685 * elf.c (bfd_elf_get_str_section): Check for an excessively large
687 * elf-attrs.c (_bfd_elf_parse_attributes): Issue an error if the
688 attribute section is larger than the size of the file.
690 2018-05-07 Alan Modra <amodra@gmail.com>
692 * cofflink.c (_bfd_coff_link_input_bfd): Use memcmp rather than
693 strncmp when checking for ".bf" special symbol.
694 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Make pe_required_section_flags
695 section name a char array, remove sentinal known_sections entry,
696 and adjust loop over known_sections to suit. Use memcmp rather
699 2018-05-04 Alan Modra <amodra@gmail.com>
701 * elf-linux-core.h (struct elf_external_linux_prpsinfo32_ugid32),
702 (struct elf_external_linux_prpsinfo32_ugid16),
703 (struct elf_external_linux_prpsinfo64_ugid32),
704 (struct elf_external_linux_prpsinfo64_ugid16): Add ATTRIBUTE_NONSTRING
705 to pr_fname and pr_psargs fields. Remove GCC diagnostic pragmas.
707 * elf.c (elfcore_write_prpsinfo): ..here. Indent nested preprocessor
709 * elf32-arm.c (elf32_arm_nabi_write_core_note): Add ATTRIBUTE_NONSTRING
711 * elf32-ppc.c (ppc_elf_write_core_note): Likewise.
712 * elf32-s390.c (elf_s390_write_core_note): Likewise.
713 * elf64-s390.c (elf_s390_write_core_note): Likewise.
714 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewise.
715 * elf64-x86-64.c (elf_x86_64_write_core_note): Add GCC diagnostic
717 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Use strnlen to avoid
718 false positive gcc-8 warning.
719 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
721 2018-05-04 Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
723 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Fix the order
724 of arguments when warning about different long double types.
726 2018-05-03 Simon Atanasyan <simon@atanasyan.com>
728 * elf32-mips.c: (elf32_mips_fixup_symbol): New function.
729 (elf_backend_fixup_symbol): New macro.
730 * elfxx-mips.c: (mips_elf_output_extsym): Discard _gp_disp
732 (_bfd_mips_elf_finish_dynamic_symbol): Likewise.
734 2018-04-30 Francois H. Theron <francois.theron@netronome.com>
736 * Makefile.am: Added NFP files to build.
737 * archures.c: Added bfd_arch_nfp
738 * config.bfd: Added NFP support.
739 * configure.ac: Added NFP support.
740 * cpu-nfp.c: New, for NFP support.
741 * elf-bfd.h: Added elf_section_info()
742 * elf64-nfp.c: New, for NFP support.
743 * po/SRC-POTFILES.in: Added NFP source files.
744 * targets.c: Added nfp_elf64_vec
745 * bfd-in2.h: Regenerate.
746 * Makefile.in: Regenerate.
747 * configure: Regenerate.
749 2018-04-27 Alan Modra <amodra@gmail.com>
751 * bfd-in2.h: Regenerate.
752 * libbfd.h: Regenerate.
754 2018-04-27 Alan Modra <amodra@gmail.com>
758 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Don't drop plt
760 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Comment fixes.
762 2018-04-26 Pedro Alves <palves@redhat.com>
764 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Don't consider
765 ifunc and non-ifunc symbols duplicates.
767 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
768 Mickaël Guêné <mickael.guene@st.com>
770 * elf32-arm.c (elf32_arm_fdpic_thumb_plt_entry): New.
771 (elf32_arm_plt_needs_thumb_stub_p): Handle thumb-only case.
772 (elf32_arm_populate_plt_entry): Likewise.
773 (elf32_arm_output_plt_map_1): Likewise.
774 (elf32_arm_output_arch_local_syms): Likewise.
776 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
777 Mickaël Guêné <mickael.guene@st.com>
779 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Handle
780 _GLOBAL_OFFSET_TABLE_ in FDPIC mode.
782 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
783 Mickaël Guêné <mickael.guene@st.com>
785 * elf32-arm.c (bfd_elf32_arm_set_target_params): Handle FDPIC case
788 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
789 Mickaël Guêné <mickael.guene@st.com>
791 * elf32-arm.c (DEFAULT_STACK_SIZE): New.
792 (elf32_arm_always_size_sections): Create stack segment.
794 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
795 Mickaël Guêné <mickael.guene@st.com>
797 * bfd-in2.h (BFD_RELOC_ARM_TLS_GD32_FDPIC)
798 (BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC): New
800 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_TLS_GD32_FDPIC,
801 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC relocations.
802 (elf32_arm_reloc_map): Add R_ARM_TLS_GD32_FDPIC,
803 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC.
804 (struct elf32_arm_link_hash_table): Update comment.
805 (elf32_arm_final_link_relocate): Handle TLS FDPIC relocations.
806 (IS_ARM_TLS_RELOC): Likewise.
807 (elf32_arm_check_relocs): Likewise.
808 (allocate_dynrelocs_for_symbol): Likewise.
809 (elf32_arm_size_dynamic_sections): Update comment.
810 * reloc.c: Add BFD_RELOC_ARM_TLS_GD32_FDPIC,
811 BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC.
813 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
814 Mickaël Guêné <mickael.guene@st.com>
816 * elf32-arm.c (elf32_arm_fdpic_plt_entry): New.
817 (elf32_arm_create_dynamic_sections): Handle FDPIC.
818 (elf32_arm_allocate_plt_entry): Likewise.
819 (elf32_arm_populate_plt_entry): Likewise.
820 (elf32_arm_output_plt_map_1): Likewise.
822 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
823 Mickaël Guêné <mickael.guene@st.com>
825 * elf32-arm.c (struct fdpic_local): New.
826 (elf_arm_obj_tdata): Add local_fdpic_cnts field.
827 (elf32_arm_local_fdpic_cnts): New.
828 (struct fdpic_global): New.
829 (elf32_arm_link_hash_entry): Add fdpic_cnts field.
830 (elf32_arm_link_hash_table): Add srofixup field.
831 (arm_elf_add_rofixup): New.
832 (arm_elf_fill_funcdesc): New.
833 (elf32_arm_link_hash_newfunc): Handle fdpic_cnts.
834 (elf32_arm_allocate_local_sym_info): Likewise.
835 (create_got_section): Create .rofixup section.
836 (elf32_arm_copy_indirect_symbol): Handle fdpic_cnts.
837 (bfd_elf32_arm_set_target_params): Handle FDPIC.
838 (elf32_arm_final_link_relocate): Likewise.
839 (elf32_arm_check_relocs): Likewise.
840 (allocate_dynrelocs_for_symbol): Likewise.
841 (elf32_arm_size_dynamic_sections): Likewise.
842 (elf32_arm_finish_dynamic_sections): Likewise.
843 (elf32_arm_output_arch_local_syms): Likewise.
844 (elf32_arm_fdpic_omit_section_dynsym): New.
846 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
847 Mickaël Guêné <mickael.guene@st.com>
849 * bfd-in2.c (BFD_RELOC_ARM_GOTFUNCDESC)
850 (BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC)
851 (BFD_RELOC_ARM_FUNCDESC_VALUE): New.
852 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_GOTFUNCDESC,
853 R_ARM_GOTOFFFUNCDESC, R_ARM_FUNCDESC, R_ARM_FUNCDESC_VALUE.
854 (elf32_arm_howto_from_type): Take new members of
855 elf32_arm_howto_table_2 into account.
856 (elf32_arm_reloc_map): Add BFD_RELOC_ARM_GOTFUNCDESC,
857 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
858 BFD_RELOC_ARM_FUNCDESC_VALUE.
859 * reloc.c: Add BFD_RELOC_ARM_GOTFUNCDESC,
860 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
861 BFD_RELOC_ARM_FUNCDESC_VALUE.
863 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
864 Mickaël Guêné <mickael.guene@st.com>
866 * elf32-arm.c (elf32_arm_print_private_bfd_data): Support
867 EF_ARM_PIC and ELFOSABI_ARM_FDPIC.
868 (elf32_arm_post_process_headers): Support ELFOSABI_ARM_FDPIC.
869 (ELF_OSABI): Define to ELFOSABI_ARM_FDPIC.
871 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
872 Mickaël Guêné <mickael.guene@st.com>
874 * config.bfd (arm*-*-linux-*): Add arm_elf32_fdpic_be_vec and
875 arm_elf32_fdpic_le_vec to targ_selvecs. Accept
876 arm*-*-uclinuxfdpiceabi.
877 * configure.ac: Add support for arm_elf32_fdpic_be_vec and
878 arm_elf32_fdpic_le_vec.
879 * configure: Regenerate.
880 * elf32-arm.c (struct elf32_arm_link_hash_table): Add fdpic_p.
881 (elf32_arm_link_hash_table_create): Initialize fdpic_p.
882 (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME, TARGET_BIG_SYM)
883 (TARGET_BIG_NAME, elf_match_priority): Define for FDPIC targets.
884 (elf32_arm_fdpic_link_hash_table_create): New.
885 * targets.c (_bfd_target_vector): Add arm_elf32_fdpic_be_vec and
886 arm_elf32_fdpic_le_vec.
888 2018-04-25 Alan Modra <amodra@gmail.com>
890 * elf-linux-core.h: Disable gcc-8 string truncation warning.
891 * elf.c (elfcore_write_prpsinfo): Likewise.
893 2018-04-25 Alan Modra <amodra@gmail.com>
895 * Makefile.am: Remove arm-aout and arm-coff support.
896 * config.bfd: Likewise.
897 * configure.ac: Likewise.
898 * targets.c: Likewise.
899 * aout-arm.c: Delete.
900 * armnetbsd.c: Delete.
902 * Makefile.in: Regenerate.
903 * configure: Regenerate.
904 * po/SRC-POTFILES.in: Regenerate.
906 2018-04-24 Nick Clifton <nickc@redhat.com>
909 * elf.c (ignore_section_sym): Check for the output_section pointer
910 being NULL before dereferencing it.
913 * peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Check for
914 a negative PE_DEBUG_DATA size before iterating over the debug data.
916 2018-04-23 Alan Modra <amodra@gmail.com>
918 * elf-linux-core.h: Revert last change.
921 2018-04-23 Nick Clifton <nickc@redhat.com>
924 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
925 the end of the string table, and zero it.
927 2018-04-23 Alan Modra <amodra@gmail.com>
929 * elf-linux-core.h (swap_linux_prpsinfo32_ugid32_out): Disable
930 gcc-8 string truncation warning.
931 (swap_linux_prpsinfo32_ugid16_out): Likewise.
932 (swap_linux_prpsinfo64_ugid32_out): Likewise.
933 (swap_linux_prpsinfo64_ugid16_out): Likewise.
934 * elf.c (elfcore_write_prpsinfo): Likewise.
936 2018-04-23 Nick Clifton <nickc@redhat.com>
939 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
940 the end of the string table, and zero it.
942 2018-04-20 Alan Modra <amodra@gmail.com>
945 * elf32-hppa.c (got_relocs_needed): Add extra param to special
946 case both dtprel and tprel relocs.
947 (allocate_dynrelocs): Adjust conditions for got relocs.
948 (elf32_hppa_relocate_section): Likewise for local sym got relocs.
949 Emit dynamic relocs on TLS GOT entries for shared libraries,
950 not when pic. Omit dynamic reloc on dtprel entry when local,
951 and on tprel entry when local and executable.
953 2018-04-19 Alan Modra <amodra@gmail.com>
956 * elf32-hppa.c (elf32_hppa_size_stubs): Init "destination" to -1.
957 (hppa_type_of_stub): Don't return a long branch stub for
958 symbols other than those defined statically.
960 2018-04-19 Alan Modra <amodra@gmail.com>
962 * Makefile.am: Revert 2018-04-18 coff-mips changes.
963 * config.bfd: Add back mips_ecoff_le_vec and mips_ecoff_be_vec
964 to selvecs for mips targets change 2018-04-18.
965 * configure.ac: Reinstate mips_ecoff_le_vec, mips_ecoff_be_vec
966 and mips_ecoff_bele_vec.
967 * targets.c: Likewise.
968 * coff-mips.c: Resurrect.
969 * Makefile.in: Regenerate.
970 * configure: Regenerate.
971 * po/SRC-POTFILES.in: Regenerate.
973 2018-04-18 Alan Modra <amodra@gmail.com>
975 * Makefile.am: Remove mips aout and coff support.
976 * config.bfd: Likewise.
977 * configure.ac: Likewise.
978 * targets.c: Likewise.
979 * coff-mips.c: Delete
983 * Makefile.in: Regenerate.
984 * configure: Regenerate.
985 * po/SRC-POTFILES.in: Regenerate.
987 2018-04-17 H.J. Lu <hongjiu.lu@intel.com>
989 * elf32-i386.c (elf32_bed): Define before including
991 * elf64-x86-64.c (elf64_bed): Define before including
993 (elf32_bed): Define before including "elf32-target.h".
995 2018-04-17 H.J. Lu <hongjiu.lu@intel.com>
998 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Use a
999 normal input file with compatible relocation.
1001 2018-04-18 Alan Modra <amodra@gmail.com>
1003 * Makefile.am: Remove support for assorted i386 aout and coff targets.
1004 * config.bfd: Likewise.
1005 * configure.ac: Likewise.
1006 * doc/bfdint.texi: Likewise.
1007 * targets.c: Likewise.
1008 * freebsd.h: Delete.
1009 * i386dynix.c: Delete.
1010 * i386freebsd.c: Delete.
1011 * i386linux.c: Delete.
1012 * i386mach3.c: Delete.
1013 * i386netbsd.c: Delete.
1014 * i386os9k.c: Delete.
1015 * Makefile.in: Regenerate.
1016 * configure: Regenerate.
1017 * po/SRC-POTFILES.in: Regenerate.
1019 2018-04-17 Andrew Sadek <andrew.sadek.se@gmail.com>
1021 Microblaze Target: PIC data text relative
1023 * bfd/reloc.c (2 new BFD relocations):
1024 BFD_RELOC_MICROBLAZE_64_TEXTPCREL &
1025 BFD_RELOC_MICROBLAZE_64_TEXTPCREL
1026 * bfd/bfd-in2.h: Regenerate
1027 * bfd/libbfd.h: Regenerate
1028 * bfd/elf32-microblaze.c (Handle new relocs): define 'HOWTO' of 3
1029 new relocs and handle them in both relocate and relax functions.
1030 (microblaze_elf_reloc_type_lookup): add mapping between for new
1032 (microblaze_elf_relocate_section): Handle new relocs in case of
1034 (microblaze_elf_relax_section): Handle new relocs for elf relaxation.
1036 2018-04-17 Nick Clifton <nickc@redhat.com>
1039 * aoutx.h (find_nearest_line): Check that the symbol name exists
1040 and is long enough, before attempting to see if it is for a .o
1042 * hash.c (bfd_hash_hash): Add an assertion that the string is not
1044 * linker.c (bfd_link_hash_lookup): Fail if the table or string are
1046 (_bfd_generic_link_add_archive_symbols): Fail if an archive entry
1050 * dwarf2.c (concat_filename): Check for a NULL table pointer.
1052 2018-04-16 Nick Clifton <nickc@redhat.com>
1055 * coffgen.c (coff_pointerize_aux): Check for an out of range
1058 2018-04-16 Alan Modra <amodra@gmail.com>
1060 * Makefile.am: Remove arm-epoc-pe support.
1061 * coff-arm.c: Likewise.
1062 * config.bfd: Likewise.
1063 * configure.ac: Likewise.
1064 * targets.c: Likewise.
1065 * epoc-pe-arm.c: Delete.
1066 * epoc-pei-arm.c: Delete.
1067 * Makefile.in: Regenerate.
1068 * configure: Regenerate.
1069 * po/SRC-POTFILES.in: Regenerate.
1071 2018-04-16 Alan Modra <amodra@gmail.com>
1073 * Makefile.am: Remove sparc-aout and sparc-coff support.
1074 * config.bfd: Likewise.
1075 * configure.ac: Likewise.
1076 * targets.c: Likewise.
1077 * aout-sparcle.c: Delete.
1079 * cf-sparclynx.c: Delete.
1080 * coff-sparc.c: Delete.
1082 * sparclinux.c: Delete.
1083 * sparclynx.c: Delete.
1084 * sparcnetbsd.c: Delete.
1086 * Makefile.in: Regenerate.
1087 * configure: Regenerate.
1088 * po/SRC-POTFILES.in: Regenerate.
1090 2018-04-16 Alan Modra <amodra@gmail.com>
1092 * Makefile.am: Remove m68k-aout and m68k-coff support.
1093 * aoutf1.h: Likewise.
1094 * aoutx.h: Likewise.
1095 * archive.c: Likewise.
1096 * bfd-in.h: Likewise.
1098 * coffcode.h: Likewise.
1099 * coffswap.h: Likewise.
1100 * config.bfd: Likewise.
1101 * configure.ac: Likewise.
1102 * configure.host: Likewise.
1103 * doc/bfd.texinfo: Likewise.
1104 * doc/bfdint.texi: Likewise.
1105 * freebsd.h: Likewise.
1106 * gen-aout.c: Likewise.
1107 * hpux-core.c: Likewise.
1108 * libaout.h: Likewise.
1109 * libbfd-in.h: Likewise.
1110 * pdp11.c: Likewise.
1111 * peicode.h: Likewise.
1112 * riscix.c: Likewise.
1113 * targets.c: Likewise.
1115 * coff-apollo.c: Delete.
1116 * coff-aux.c: Delete.
1117 * coff-m68k.c: Delete.
1118 * coff-svm68k.c: Delete.
1119 * coff-u68k.c: Delete.
1120 * hosts/delta68.h: Delete.
1121 * hosts/hp300bsd.h: Delete.
1122 * hosts/m68kaux.h: Delete.
1123 * hosts/news.h: Delete.
1124 * hp300bsd.c: Delete.
1125 * hp300hpux.c: Delete.
1126 * liboasys.h: Delete.
1127 * m68k4knetbsd.c: Delete.
1128 * m68klinux.c: Delete.
1129 * m68knetbsd.c: Delete.
1131 * versados.c: Delete.
1132 * Makefile.in: Regenerate.
1133 * bfd-in2.h: Regenerate.
1134 * configure: Regenerate.
1135 * libbfd.h: Regenerate.
1136 * po/SRC-POTFILES.in: Regenerate.
1138 2018-04-16 Alan Modra <amodra@gmail.com>
1140 * Makefile.am: Remove sh5 and sh64 support.
1141 * archures.c: Likewise.
1142 * config.bfd: Likewise.
1143 * configure.ac: Likewise.
1144 * cpu-sh.c: Likewise.
1145 * elf32-sh-relocs.h: Likewise.
1146 * elf32-sh.c: Likewise.
1147 * targets.c: Likewise.
1148 * elf32-sh64-com.c: Delete.
1149 * elf32-sh64.c: Delete.
1150 * elf32-sh64.h: Delete.
1151 * elf64-sh64.c: Delete.
1152 * Makefile.in: Regenerate.
1153 * bfd-in2.h: Regenerate.
1154 * configure: Regenerate.
1155 * po/SRC-POTFILES.in: Regenerate.
1157 2018-04-16 Alan Modra <amodra@gmail.com>
1159 * Makefile.am: Remove sh-symbianelf support.
1160 * config.bfd: Likewise.
1161 * configure.ac: Likewise.
1162 * targets.c: Likewise.
1163 * elf32-sh-symbian.c: Delete.
1164 * Makefile.in: Regenerate.
1165 * configure: Regenerate.
1166 * po/SRC-POTFILES.in: Regenerate.
1168 2018-04-16 Alan Modra <amodra@gmail.com>
1170 * Makefile.am: Remove vax-bsd and vax-ultrix support.
1171 * config.bfd: Likewise.
1172 * configure.ac: Likewise.
1173 * targets.c: Likewise.
1175 * Makefile.in: Regenerate.
1176 * configure: Regenerate.
1177 * po/SRC-POTFILES.in: Regenerate.
1179 2018-04-16 Alan Modra <amodra@gmail.com>
1181 * Makefile.am: Remove w65 support.
1182 * archures.c: Likewise.
1183 * coffcode.h: Likewise.
1184 * config.bfd: Likewise.
1185 * configure.ac: Likewise.
1186 * targets.c: Likewise.
1187 * coff-w65.c: Delete.
1188 * cpu-w65.c: Delete.
1189 * Makefile.in: Regenerate.
1190 * bfd-in2.h: Regenerate.
1191 * configure: Regenerate.
1192 * po/SRC-POTFILES.in: Regenerate.
1194 2018-04-16 Alan Modra <amodra@gmail.com>
1196 * Makefile.am: Remove we32k support.
1197 * archures.c: Likewise.
1198 * coffcode.h: Likewise.
1199 * config.bfd: Likewise.
1200 * configure.ac: Likewise.
1201 * targets.c: Likewise.
1202 * coff-we32k.c: Delete.
1203 * cpu-we32k.c: Delete.
1204 * Makefile.in: Regenerate.
1205 * bfd-in2.h: Regenerate.
1206 * configure: Regenerate.
1207 * po/SRC-POTFILES.in: Regenerate.
1209 2018-04-16 Alan Modra <amodra@gmail.com>
1211 * Makefile.am: Remove m88k support.
1212 * aoutx.h: Likewise.
1213 * archures.c: Likewise.
1214 * coffcode.h: Likewise.
1215 * coffswap.h: Likewise.
1216 * config.bfd: Likewise.
1217 * configure.ac: Likewise.
1218 * cpu-ns32k.c: Likewise.
1219 * elf32-nds32.c: Likewise.
1220 * mach-o.c: Likewise.
1221 * netbsd-core.c: Likewise.
1222 * reloc.c: Likewise.
1223 * targets.c: Likewise.
1224 * coff-m88k.c: Delete.
1225 * cpu-m88k.c: Delete.
1226 * elf32-m88k.c: Delete.
1227 * hosts/m88kmach3.h: Delete.
1228 * m88kmach3.c: Delete.
1229 * m88kopenbsd.c: Delete.
1230 * Makefile.in: Regenerate.
1231 * bfd-in2.h: Regenerate.
1232 * configure: Regenerate.
1233 * po/SRC-POTFILES.in: Regenerate.
1235 2018-04-16 Alan Modra <amodra@gmail.com>
1237 * Makefile.am: Remove i370 support.
1238 * archures.c: Likewise.
1239 * config.bfd: Likewise.
1240 * configure.ac: Likewise.
1241 * targets.c: Likewise.
1242 * cpu-i370.c: Delete.
1243 * elf32-i370.c: Delete.
1244 * Makefile.in: Regenerate.
1245 * bfd-in2.h: Regenerate.
1246 * configure: Regenerate.
1247 * po/SRC-POTFILES.in: Regenerate.
1249 2018-04-16 Alan Modra <amodra@gmail.com>
1251 * Makefile.am: Remove h8500 support.
1252 * archures.c: Likewise.
1253 * coffcode.h: Likewise.
1254 * config.bfd: Likewise.
1255 * configure.ac: Likewise.
1256 * targets.c: Likewise.
1257 * coff-h8500.c: Delete.
1258 * cpu-h8500.c: Delete.
1259 * Makefile.in: Regenerate.
1260 * bfd-in2.h: Regenerate.
1261 * configure: Regenerate.
1262 * po/SRC-POTFILES.in: Regenerate.
1264 2018-04-16 Alan Modra <amodra@gmail.com>
1266 * Makefile.am: Remove h8300-coff support.
1267 * coffcode.h: Likewise.
1268 * config.bfd: Likewise.
1269 * configure.ac: Likewise.
1270 * reloc16.c: Likewise.
1271 * targets.c: Likewise.
1272 * coff-h8300.c: Delete.
1273 * Makefile.in: Regenerate.
1274 * configure: Regenerate.
1275 * po/SRC-POTFILES.in: Regenerate.
1277 2018-04-16 Alan Modra <amodra@gmail.com>
1279 * Makefile.am: Remove IEEE 695 support.
1280 * archures.c: Likewise.
1282 * config.bfd: Likewise.
1283 * configure.ac: Likewise.
1284 * doc/bfd.texinfo: Likewise.
1285 * doc/bfdint.texi: Likewise.
1286 * doc/bfdsumm.texi: Likewise.
1287 * section.c: Likewise.
1288 * targets.c: Likewise.
1290 * libieee.h: Delete.
1291 * Makefile.in: Regenerate.
1292 * bfd-in2.h: Regenerate.
1293 * configure: Regenerate.
1294 * po/SRC-POTFILES.in: Regenerate.
1296 2018-04-16 Alan Modra <amodra@gmail.com>
1298 * config.bfd: Remove tandem support.
1300 2018-04-16 Alan Modra <amodra@gmail.com>
1302 * Makefile.am: Remove newsos3 support.
1303 * aoutx.h: Likewise.
1304 * config.bfd: Likewise.
1305 * configure.ac: Likewise.
1306 * targets.c: Likewise.
1307 * newsos3.c: Delete.
1308 * Makefile.in: Regenerate.
1309 * configure: Regenerate.
1310 * po/SRC-POTFILES.in: Regenerate.
1312 2018-04-16 Alan Modra <amodra@gmail.com>
1314 * Makefile.am: Remove netware support.
1315 * bfd-in.h: Likewise.
1317 * config.bfd: Likewise.
1318 * configure.ac: Likewise.
1319 * doc/bfdint.texi: Likewise.
1320 * ecoff.c: Likewise.
1321 * targets.c: Likewise.
1323 * nlm-target.h: Delete.
1325 * nlm32-alpha.c: Delete.
1326 * nlm32-i386.c: Delete.
1327 * nlm32-ppc.c: Delete.
1328 * nlm32-sparc.c: Delete.
1331 * nlmcode.h: Delete.
1332 * nlmswap.h: Delete.
1333 * Makefile.in: Regenerate.
1334 * bfd-in2.h: Regenerate.
1335 * configure: Regenerate.
1336 * po/SRC-POTFILES.in: Regenerate.
1338 2018-04-16 Alan Modra <amodra@gmail.com>
1340 * archures.c: Remove tahoe support.
1341 * config.bfd: Likewise.
1342 * configure.ac: Likewise.
1343 * hosts/tahoe.h: Delete.
1344 * bfd-in2.h: Regenerate.
1345 * configure: Regenerate.
1347 2018-04-14 Alan Modra <amodra@gmail.com>
1349 * elf-bfd.h (struct elf_backend_data): Add relropagesize.
1350 * elfxx-target.h (ELF_RELROPAGESIZE): Provide default and
1352 (elfNN_bed): Init relropagesize.
1353 * bfd.c (bfd_emul_get_commonpagesize): Add boolean param to
1354 select relropagesize.
1355 * elf32-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
1356 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
1357 (ELF_MINPAGESIZE): Don't define.
1358 * elf64-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
1359 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
1360 * bfd-in2.h: Regenerate.
1362 2018-04-14 Alan Modra <amodra@gmail.com>
1364 * elf32-ppc.c (ELF_MAXPAGESIZE, ELF_COMMONPAGESIZE): Don't depend
1365 on __QNXTARGET__ define.
1367 2018-04-14 Alan Modra <amodra@gmail.com>
1369 * config.bfd: Add powerpc-*-lynxos* and powerpc-*-windiss*
1372 2018-04-11 Alan Modra <amodra@gmail.com>
1374 * aout-adobe.c: Delete.
1376 * coff-i860.c: Delete.
1377 * coff-i960.c: Delete.
1378 * cpu-i860.c: Delete.
1379 * cpu-i960.c: Delete.
1380 * elf32-i860.c: Delete.
1381 * elf32-i960.c: Delete.
1382 * hosts/i860mach3.h: Delete.
1383 * Makefile.am: Remove i860, i960, bout, and adobe support.
1384 * archures.c: Remove i860 and i960 support.
1385 * coffcode.h: Likewise.
1386 * reloc.c: Likewise.
1387 * aoutx.h: Comment updates.
1388 * archive.c: Remove BOUT and i960 support.
1389 * bfd.c: Remove BOUT support.
1390 * coffswap.h: Remove i960 support.
1391 * config.bfd: Remove i860, i960 and adobe targets.
1392 * configure.ac: Remove adode, bout, i860, i960, icoff targets.
1393 * targets.c: Likewise.
1394 * ieee.c: Remove i960 support.
1395 * mach-o.c: Remove i860 support.
1396 * Makefile.in: Regenerate.
1397 * bfd-in2.h: Regenerate.
1398 * configure: Regenerate.
1399 * libbfd.h: Regenerate.
1400 * po/SRC-POTFILES.in: Regenerate.
1402 2018-04-09 Maciej W. Rozycki <macro@mips.com>
1404 * elf64-mips.c (mips_elf64_write_rel): Handle a NULL BFD pointer
1405 in the BFD symbol referred by the relocation.
1406 (mips_elf64_write_rela): Likewise.
1408 2018-04-09 Maciej W. Rozycki <macro@mips.com>
1410 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Issue an
1411 error for out-of-range `r_sym' values.
1413 2018-04-09 Alan Modra <amodra@gmail.com>
1415 * elf64-ppc.c (struct _ppc64_elf_section_data): Add has_pltcall field.
1416 (struct ppc_link_hash_table): Add can_convert_all_inline_plt.
1417 (ppc64_elf_check_relocs): Set has_pltcall.
1418 (ppc64_elf_adjust_dynamic_symbol): Discard some PLT entries.
1419 (ppc64_elf_inline_plt): New function.
1420 (ppc64_elf_size_dynamic_sections): Discard some PLT entries for locals.
1421 * elf64-ppc.h (ppc64_elf_inline_plt): Declare.
1422 * elf32-ppc.c (has_pltcall): Define.
1423 (struct ppc_elf_link_hash_table): Add can_convert_all_inline_plt.
1424 (ppc_elf_check_relocs): Set has_pltcall.
1425 (ppc_elf_inline_plt): New function.
1426 (ppc_elf_adjust_dynamic_symbol): Discard some PLT entries.
1427 (ppc_elf_size_dynamic_sections): Likewise.
1428 * elf32-ppc.h (ppc_elf_inline_plt): Declare.
1430 2018-04-09 Alan Modra <amodra@gmail.com>
1432 * elf32-ppc.c (ppc_elf_howto_raw): Add PLTSEQ and PLTCALL howtos.
1433 (is_plt_seq_reloc): New function.
1434 (ppc_elf_check_relocs): Handle PLTSEQ and PLTCALL relocs.
1435 (ppc_elf_tls_optimize): Handle inline plt call sequence.
1436 (ppc_elf_relax_section): Handle PLTCALL reloc.
1437 (ppc_elf_relocate_section): Nop out inline plt call sequence when
1439 * elf64-ppc.c (ppc64_elf_howto_raw): Add R_PPC64_PLTSEQ and
1440 R_PPC64_PLTCALL entries. Comment R_PPC64_TOCSAVE.
1441 (has_tls_get_addr_call): Correct comment.
1442 (is_branch_reloc): Add PLTCALL.
1443 (is_plt_seq_reloc): New function.
1444 (ppc64_elf_check_relocs): Handle PLT16_LO_DS reloc. Set
1445 has_tls_reloc for R_PPC64_TLSGD and R_PPC64_TLSLD. Create plt
1446 entry for R_PPC64_PLTCALL.
1447 (ppc64_elf_tls_optimize): Handle inline plt call sequence.
1448 (ppc_type_of_stub): Handle PLTCALL reloc.
1449 (toc_adjusting_stub_needed): Likewise.
1450 (ppc64_elf_relocate_section): Set "can_plt_call" for PLTCALL
1451 reloc insn. Nop out inline plt call sequence when resolving
1452 locally. Handle __tls_get_addr inline plt call optimization.
1454 2018-04-09 Alan Modra <amodra@gmail.com>
1456 * elf64-ppc.c (LOCAL_PLT_ENTRY_SIZE): Define.
1457 (struct ppc_stub_hash_entry): Add symtype field.
1459 (struct ppc_link_hash_table): Add pltlocal and relpltlocal.
1460 (create_linkage_sections): Create pltlocal and relpltlocal.
1461 (ppc64_elf_check_relocs): Allow PLT relocs on local symbols.
1463 (ppc64_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
1464 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
1465 (ppc64_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
1466 Keep PLT entries for inline calls against locals.
1467 (ppc_build_one_stub): Use pltlocal as appropriate.
1468 (ppc_size_one_stub): Likewise.
1469 (ppc64_elf_size_stubs): Set symtype.
1470 (build_global_entry_stubs_and_plt): Init pltlocal and write
1471 relpltlocal for globals.
1472 (write_plt_relocs_for_local_syms): Likewise for local syms.
1473 (ppc64_elf_relocate_section): Support PLT for local syms.
1474 * elf32-ppc.c (PLT_KEEP): Define.
1475 (struct ppc_elf_link_hash_table): Add pltlocal and relpltlocal.
1476 (ppc_elf_create_glink): Create pltlocal and relpltlocal.
1477 (ppc_elf_check_relocs): Allow PLT relocs on local symbols.
1478 Set PLT_KEEP. Adjust update_local_sym_info call.
1479 (ppc_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
1480 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
1481 (ppc_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
1482 (ppc_elf_relocate_section): Support PLT16 relocs for local syms.
1483 (write_global_sym_plt): Init pltlocal and write relpltlocal.
1484 (ppc_finish_symbols): Likewise for locals.
1486 2018-04-09 Alan Modra <amodra@gmail.com>
1488 * elf64-ppc.c (ppc_build_one_stub): Move output of PLT relocs
1489 for local symbols to..
1490 (write_plt_relocs_for_local_syms): ..here. New function.
1491 (ppc64_elf_finish_dynamic_symbol): Move output of PLT relocs for
1493 (build_global_entry_stubs_and_plt): ..here. Rename from
1494 build_global_entry_stubs.
1495 (ppc64_elf_build_stubs): Always call build_global_entry_stubs_and_plt.
1496 Call write_plt_relocs_for_local_syms.
1497 * elf32-ppc.c (get_sym_h): New function.
1498 (ppc_elf_relax_section): Use get_sym_h.
1499 (ppc_elf_relocate_section): Move output of PLT relocs and glink
1500 stubs for local symbols to..
1501 (ppc_finish_symbols): ..here. New function.
1502 (ppc_elf_finish_dynamic_symbol): Move output of PLT relocs for
1504 (write_global_sym_plt): ..here. New function.
1505 * elf32-ppc.h (ppc_elf_modify_segment_map): Delete attribute.
1506 (ppc_finish_symbols): Declare.
1508 2018-04-09 Alan Modra <amodra@gmail.com>
1510 * elf32-ppc.c (ppc_elf_check_relocs): Handle PLT16 relocs.
1511 (ppc_elf_relocate_section): Likewise.
1512 * elf64-ppc.c (ppc64_elf_check_relocs): Handle PLT16_LO_DS.
1513 (ppc64_elf_relocate_section): Likewise. Correct PLT16
1514 resolution to plt entry relative to toc pointer.
1516 2018-04-09 Alan Modra <amodra@gmail.com>
1518 * elf64-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
1519 TLS_TPRELGD, TLS_EXPLICIT): Renumber. Test TLS_TLS throughout
1520 file when other TLS flags are tested in a mask.
1521 (TLS_MARK, NON_GOT): Define.
1522 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
1523 (update_local_sym_info): Don't create got entry when NON_GOT.
1524 (ppc64_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
1526 (get_tls_mask): Do toc lookup if tls_mask is just TLS_MARK.
1527 (ppc64_elf_relocate_section): Likewise.
1528 (ppc64_elf_tls_optimize): Don't attempt to optimize indirect
1529 __tls_get_addr calls lacking a marker reloc.
1530 * elf32-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
1531 TLS_TPRELGD): Renumber. Update comment.
1532 (TLS_MARK, NON_GOT): Define.
1533 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
1534 (update_local_sym_info): Don't create got entry when NON_GOT.
1535 (ppc_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
1537 (ppc_elf_tls_optimize): Don't attempt to optimize indirect
1538 __tls_get_addr calls lacking a marker reloc.
1540 2018-04-06 H.J. Lu <hongjiu.lu@intel.com>
1542 * elf64-x86-64.c (elf_x86_64_info_to_howto): Don't mask out
1543 R_X86_64_converted_reloc_bit.
1545 2018-04-05 H.J. Lu <hongjiu.lu@intel.com>
1548 * configure: Regenerated.
1550 2018-04-05 Alan Modra <amodra@gmail.com>
1552 * elf-hppa.h (elf_hppa_info_to_howto): Init howto to NULL.
1553 (elf_hppa_info_to_howto_rel): Likewise.
1555 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1557 * elf-hppa.h (elf_hppa_info_to_howto): Also return
1558 unsuccessfully for unimplemented relocations.
1559 (elf_hppa_info_to_howto_rel): Likewise.
1561 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1563 * elf32-i860.c (lookup_howto): Add `abfd' parameter. Set the
1564 `bfd_error_bad_value' error and call `_bfd_error_handler' on a
1565 howto lookup failure.
1566 (elf32_i860_reloc_type_lookup): Adjust `lookup_howto' call
1568 (elf32_i860_info_to_howto_rela): Likewise.
1569 (elf32_i860_relocate_splitn): Likewise.
1570 (elf32_i860_relocate_pc16): Likewise.
1571 (elf32_i860_relocate_pc26): Likewise.
1572 (elf32_i860_relocate_section): Likewise.
1574 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1576 * elf32-visium.c (visium_info_to_howto_rela): Correct the range
1577 check for `visium_elf_howto_table' table access.
1579 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1581 * elf32-iq2000.c (iq2000_info_to_howto_rela): Correct the range
1582 check for `iq2000_elf_howto_table' table access.
1584 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1586 * elf32-frv.c (frv_info_to_howto_rela): Correct the range check
1587 for `elf32_frv_howto_table' table access.
1589 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1591 * elf32-mips.c (mips_elf32_rtype_to_howto): Also return
1592 unsuccessfully for placeholder howtos.
1593 * elf64-mips.c (mips_elf64_rtype_to_howto): Likewise.
1594 * elfn32-mips.c (mips_elf_n32_rtype_to_howto): Likewise.
1596 2018-03-29 Maciej W. Rozycki <macro@mips.com>
1598 * elf32-mips.c (mips_info_to_howto_rel): Remove the calls to
1599 `_bfd_error_handler' and to set the `bfd_error_bad_value' error.
1601 2018-03-28 Maciej W. Rozycki <macro@mips.com>
1603 * elf-hppa.h (elf_hppa_info_to_howto_rel): Remove
1604 ATTRIBUTE_UNUSED from `abfd'.
1606 2018-03-28 Maciej W. Rozycki <macro@mips.com>
1608 * elf-hppa.h (elf_hppa_info_to_howto_rel): Correct
1609 `_bfd_error_handler' call formatting.
1611 2018-03-28 Maciej W. Rozycki <macro@mips.com>
1613 * elf32-mips.c (mips_info_to_howto_rel): Call
1614 `mips_elf32_rtype_to_howto' directly rather than via
1615 `->elf_backend_mips_rtype_to_howto'.
1617 2018-03-28 Renlin Li <renlin.li@arm.com>
1620 * elfnn-aarch64.c (IS_AARCH64_TLS_RELOC): Add cases for
1621 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
1622 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
1623 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
1624 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
1625 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
1626 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
1627 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
1628 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
1629 (elfNN_aarch64_final_link_relocate): Support new relocations.
1630 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Support new
1632 (_bfd_aarch64_elf_resolve_relocation): Support new relocations.
1634 2018-03-28 Renlin Li <renlin.li@arm.com>
1637 * reloc.c: Add BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12
1638 BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12_NC,
1639 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
1640 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
1641 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
1642 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
1643 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
1644 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
1645 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
1646 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
1647 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add table entry for
1648 TLSLE_LDST16_TPREL_LO12,
1649 TLSLE_LDST16_TPREL_LO12_NC,
1650 TLSLE_LDST32_TPREL_LO12,
1651 TLSLE_LDST32_TPREL_LO12_NC,
1652 TLSLE_LDST64_TPREL_LO12,
1653 TLSLE_LDST64_TPREL_LO12_NC,
1654 TLSLE_LDST8_TPREL_LO12,
1655 TLSLE_LDST8_TPREL_LO12_NC.
1656 * bfd-in2.h: Regenerated.
1657 * libbfd.h: Regenerated.
1659 2018-03-28 Eric Botcazou <ebotcazou@adacore.com>
1662 * elfxx-sparc.c (struct _bfd_sparc_elf_link_hash_entry): Add new flag
1663 has_old_style_got_reloc.
1664 (_bfd_sparc_elf_check_relocs) <GOT relocations>: Set it for old-style
1665 relocations. Fix a couple of long lines.
1666 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: Do not generate
1667 a R_SPARC_NONE for the GOT slot if the symbol is also subject to old-style
1670 2018-03-25 H.J. Lu <hongjiu.lu@intel.com>
1673 * elf64-x86-64.c (elf_x86_64_finish_dynamic_sections): Add
1674 ENDBR64 to the TLSDESC PLT entry.
1676 2018-03-21 Alan Modra <amodra@gmail.com>
1678 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Trim uninteresting
1679 symbols. Use size_t counts. Delete redundant opd test.
1681 2018-03-21 Alan Modra <amodra@gmail.com>
1683 * elf32-ppc.c (ppc_elf_tls_optimize): Delete locsyms.
1685 2018-03-21 Alan Modra <amodra@gmail.com>
1687 * elf32-ppc.c (struct ppc_elf_link_hash_entry): Make tls_mask
1689 (update_local_sym_info): Likewise for local_got_tls_masks.
1690 (ppc_elf_tls_optimize): Likewise for lgot_masks.
1692 2018-03-21 Alan Modra <amodra@gmail.com>
1694 * elf64-ppc.c (ppc_size_one_stub): Fix comment typo.
1695 (ppc64_elf_layout_multitoc): Allocate relocs for tprel as we
1696 do in size_dynamic_sections.
1698 2018-03-21 Alan Modra <amodra@gmail.com>
1700 * elf64-ppc.c (ppc64_elf_relocate_section): Don't access rel[1]
1701 without first checking array bounds.
1702 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
1704 2018-03-20 H.J. Lu <hongjiu.lu@intel.com>
1707 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Set
1708 non_ir_ref_dynamic if a symbol is made dynamic by --dynamic-list.
1710 2018-03-19 Nick Clifton <nickc@redhat.com>
1712 * po/es.po: Updated Spanish translation.
1714 2018-03-15 Max Filippov <jcmvbkbc@gmail.com>
1716 * elf32-xtensa.c (xlate_map_entry): Change types of address
1717 fields from 'unsigned' to 'bfd_vma'.
1718 (xlate_offset_with_removed_text): Use struct xlate_map_entry as
1719 the key argument to bsearch. Allow offsets past the end of a
1720 section, use the last map entry for translation of such offsets.
1722 2018-03-15 Kuan-Lin Chen <kuanlinchentw@gmail.com>
1724 * elf32-nds32.c (nds32_elf_ex9_build_hash_table): Removed.
1725 Not support the target feature.
1726 (nds32_elf_ex9_itb_base): Likewise.
1727 (nds32_elf_ex9_import_table): Likewise.
1728 (nds32_elf_ex9_finish): Likewise.
1729 (nds32_elf_ex9_reloc_jmp): Likewise.
1730 (nds32_elf_get_insn_with_reg): Likewise.
1731 (nds32_get_local_syms): Likewise.
1732 (nds32_elf_ex9_replace_instruction): Likewise.
1733 (nds32_elf_ifc_calc): Likewise.
1734 (nds32_elf_ifc_finish): Likewise.
1735 (nds32_elf_ifc_replace): Likewise.
1736 (nds32_elf_ifc_reloc): Likewise.
1738 2018-03-14 Alan Modra <amodra@gmail.com>
1740 * elf64-ppc.c (sfpr_define): Adjust for stub_sec size having
1741 sfpr size added before defining alias symbols.
1742 (ppc64_elf_build_stubs): Add stub section padding before
1743 copying sfpr contents and defining save/restore alias symbols.
1745 2018-03-14 H.J. Lu <hongjiu.lu@intel.com>
1748 * elflink.c (elf_gc_mark_debug_section): Also check the local
1749 debug definition section.
1751 2018-03-13 Nick Clifton <nickc@redhat.com>
1754 * pei-x86_64.c (pex64_get_unwind_info): Change to a boolean
1755 function. Add an end address parameter. Check access of the data
1756 pointer to make sure that they do not extend beyond the end
1757 address. Return FALSE if any check fails. Add the end address
1758 pointer to the ui structure.
1759 (pex64_xdata_print_uwd_codes): Check accesses of the raw unwind
1760 codes to make sure that they do not extend beyond the end address
1761 pointer. Print an error message and return immediately if any
1764 2018-03-09 Nick Clifton <nickc@redhat.com>
1766 * elf64-s390.c (elf_s390_relocate_section): Move check for
1767 relocations against non-allocated sections to before the code that
1768 handles ifunc relocations.
1769 * elf32-s390.c (elf_s390_relocate_section): Likewise.
1770 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Treat
1771 relocs against IFUNC symbols in non-allocated sections as relocs
1772 against FUNC symbols.
1773 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
1775 2018-03-08 H.J. Lu <hongjiu.lu@intel.com>
1778 * elf32-i386.c (elf_i386_relocate_section): Treat relocation
1779 against IFUNC symbol in SHT_NOTE section without SHF_ALLOC as
1780 relocation against FUNC symbol.
1781 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
1783 2018-03-07 Renlin Li <renlin.li@arm.com>
1786 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Check absolute
1787 symbol, and don't emit relocation in specific case.
1789 2018-03-07 Alan Modra <amodra@gmail.com>
1791 * elf64-mips.c (mips_elf64_rtype_to_howto): Return NULL on error.
1792 (mips_elf64_slurp_one_reloc_table): Pass on error.
1794 2018-03-03 James Cowgill <james.cowgill@mips.com>
1795 Maciej W. Rozycki <macro@mips.com>
1798 * elfxx-mips.c (mips_elf_calculate_relocation): Only return
1799 after calling `undefined_symbol' hook if this is an error
1800 condition. Assume the value of 0 for the symbol requested
1803 2018-03-02 Jim Wilson <jimw@sifive.com>
1806 * elfnn-aarch64.c (_bfd_aarch64_resize_stubs): Add 8 bytes for branch
1807 and nop instead of 4.
1808 (elfNN_arch64_build_stubs): Add nop after branch. Increase size by
1811 2018-03-01 Jim Wilson <jimw@sifive.com>
1814 * elfnn-riscv.c (riscv_relax_delete_bytes): When adjust st_size, use
1815 else if instead of if.
1817 2018-03-01 Alan Modra <amodra@gmail.com>
1819 * elf32-ft32.c (ft32_info_to_howto_rela): Correct range test.
1821 2018-02-28 Alan Modra <amodra@gmail.com>
1824 * aoutx.h (swap_std_reloc_in): Correct r_index bound check.
1826 2018-02-28 Nick Clifton <nickc@redhat.com>
1830 * dwarf2.c (read_n_bytes): Replace size parameter with dwarf_block
1831 pointer. Drop unused abfd parameter. Check the size of the block
1832 before initialising the data field. Return the end pointer if the
1834 (read_attribute_value): Adjust invocations of read_n_bytes.
1837 * dwarf1.c (parse_die): Check the length of form blocks before
1838 advancing the data pointer.
1840 2018-02-28 Alan Modra <amodra@gmail.com>
1843 * aoutx.h (translate_symbol_table): Print an error message and set
1844 bfd_error on finding an invalid name string offset.
1846 2018-02-27 H.J. Lu <hongjiu.lu@intel.com>
1848 * config.in: Regenerated.
1849 * configure: Likewise.
1850 * configure.ac: Add --enable-separate-code.
1851 (DEFAULT_LD_Z_SEPARATE_CODE): New AC_DEFINE_UNQUOTED. Default
1852 to 1 for Linux/x86 targets,
1853 * elf64-x86-64.c (ELF_MAXPAGESIZE): Set to 0x1000 if
1854 DEFAULT_LD_Z_SEPARATE_CODE is 1.
1856 2018-02-27 Nick Clifton <nickc@redhat.com>
1858 * aout-cris.c (swap_ext_reloc_out): Standadize error/warning
1860 * elf-hppa.h (elf_hppa_info_to_howto_rel): Likewise.
1861 * elf32-i386.c (elf_i386_reloc_type_lookup): Likewise.
1862 * elf32-xtensa.c (elf_xtensa_reloc_type_lookup): Likewise.
1863 * elf64-ppc.c (ppc64_elf_reloc_type_lookup): Likewise.
1864 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
1865 * elf64-sh64.c (sh_elf64_info_to_howto): Likewise.
1866 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
1867 * elfxx-sparc.c (_bfd_sparc_elf_reloc_type_lookup): Likewise.
1868 * elfxx-tilegx.c (tilegx_reloc_type_lookup): Likewise.
1871 * elf-bfd.h (struct elf_backend_data): Change the return type of
1872 the elf_info_to_howto and elf_info_to_howto_rel function pointers
1874 * elfcode.h (elf_slurp_reloc_table_from_section): Check the return
1875 value from the info_to_howto function and fail if that function
1877 * elf32-h8300.c (elf32_h8_relocate_section): Check return value
1878 from the info_to_howto function.
1879 (elf32_h8_relax_section): Likewise.
1880 * elf32-lm32.c (lm32_elf_relocate_section): Likewise.
1881 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
1882 * elf32-score.c (s3_bfd_score_elf_relocate_section): Likewise.
1883 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
1884 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
1885 * elf64-ia64-vms.c (elf64_ia64_relocate_section): Likewise.
1886 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Likewise.
1887 * elf64-x86-64.c (elf_x86_64_tls_transition): Likewise.
1888 * elfnn-ia64.c (elfNN_ia64_relocate_section): Likewise.
1889 * elfnn-riscv.c (riscv_elf_check_relocs): Likewise.
1890 (riscv_elf_relocate_section): Likewise.
1891 * elf-hppa.h (elf_hppa_info_to_howto): Change return type to
1892 bfd_boolean. Issue an error message, set an error value and
1893 return FALSE if the reloc is not recognized.
1894 (elf_hppa_info_to_howto_rel): Likewise.
1895 * elf-m10200.c (mn10200_info_to_howto): Likewise.
1896 * elf-m10300.c (mn10300_info_to_howto): Likewise.
1897 * elf.c (_bfd_elf_no_info_to_howto): Likewise.
1898 * elf32-arc.c (arc_info_to_howto_rel): Likewise.
1899 * elf32-arm.c (elf32_arm_info_to_howto): Likewise.
1900 * elf32-avr.c (avr_info_to_howto_rela): Likewise.
1901 * elf32-bfin.c (bfin_info_to_howto): Likewise.
1902 * elf32-cr16.c (elf_cr16_info_to_howto): Likewise.
1903 * elf32-cr16c.c (elf_cr16c_info_to_howto): Likewise.
1904 * elf32-cris.c (elf_cr16c_info_to_howto_rel)
1905 (cris_info_to_howto_rela): Likewise.
1906 * elf32-crx.c (elf_crx_info_to_howto): Likewise.
1907 * elf32-d10v.c (d10v_info_to_howto_rel): Likewise.
1908 * elf32-d30v.c (d30v_info_to_howto_rel, d30v_info_to_howto_rela):
1910 * elf32-dlx.c (dlx_rtype_to_howto, elf32_dlx_info_to_howto)
1911 (elf32_dlx_info_to_howto_rel): Likewise.
1912 * elf32-epiphany.c (epiphany_info_to_howto_rela): Likewise.
1913 * elf32-fr30.c (fr30_info_to_howto_rela): Likewise.
1914 * elf32-frv.c (frv_info_to_howto_rela)
1915 (frvfdpic_info_to_howto_rel): Likewise.
1916 * elf32-ft32.c (ft32_info_to_howto_rela): Likewise.
1917 * elf32-gen.c (elf_generic_info_to_howto)
1918 (elf_generic_info_to_howto_rel): Likewise.
1919 * elf32-h8300.c (elf32_h8_info_to_howto)
1920 (elf32_h8_info_to_howto_rel): Likewise.
1921 * elf32-i370.c (i370_elf_info_to_howto): Likewise.
1922 * elf32-i386.c (elf_i386_reloc_type_lookup)
1923 (elf_i386_rtype_to_howto, elf_i386_info_to_howto_rel): Likewise.
1924 * elf32-i860.c (lookup_howto, elf32_i860_info_to_howto_rela):
1926 * elf32-i960.c (elf32_i960_info_to_howto_rel): Likewise.
1927 * elf32-ip2k.c (ip2k_info_to_howto_rela): Likewise.
1928 * elf32-iq2000.c (iq2000_info_to_howto_rela): Likewise.
1929 * elf32-lm32.c (lm32_info_to_howto_rela): Likewise.
1930 * elf32-m32c.c (m32c_info_to_howto_rela): Likewise.
1931 * elf32-m32r.c (m32r_info_to_howto_rel, m32r_info_to_howto):
1933 * elf32-m68hc11.c (m68hc11_info_to_howto_rel): Likewise.
1934 * elf32-m68hc12.c (m68hc11_info_to_howto_rel): Likewise.
1935 * elf32-m68k.c (rtype_to_howto): Likewise.
1936 * elf32-mcore.c (mcore_elf_info_to_howto): Likewise.
1937 * elf32-mep.c (mep_info_to_howto_rela): Likewise.
1938 * elf32-metag.c (metag_info_to_howto_rela): Likewise.
1939 * elf32-microblaze.c (microblaze_elf_info_to_howto): Likewise.
1940 * elf32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
1942 * elf32-moxie.c (moxie_info_to_howto_rela): Likewise.
1943 * elf32-msp430.c (msp430_info_to_howto_rela): Likewise.
1944 * elf32-mt.c (mt_info_to_howto_rela): Likewise.
1945 * elf32-nds32.c (nds32_info_to_howto_rel, nds32_info_to_howto):
1947 * elf32-nios2.c (nios2_elf32_info_to_howto): Likewise.
1948 * elf32-or1k.c (or1k_info_to_howto_rela): Likewise.
1949 * elf32-pj.c (pj_elf_info_to_howto): Likewise.
1950 * elf32-ppc.c (ppc_elf_info_to_howto): Likewise.
1951 * elf32-pru.c (pru_elf32_info_to_howto): Likewise.
1952 * elf32-rl78.c (rl78_info_to_howto_rela): Likewise.
1953 * elf32-rx.c (rx_info_to_howto_rela): Likewise.
1954 * elf32-s390.c (elf_s390_info_to_howto): Likewise.
1955 * elf32-score.c (s3_bfd_score_info_to_howto)
1956 (_bfd_score_info_to_howto): Likewise.
1957 * elf32-score7.c (s7_bfd_score_info_to_howto): Likewise.
1958 * elf32-sh.c (sh_elf_info_to_howto): Likewise.
1959 * elf32-spu.c (spu_elf_info_to_howto): Likewise.
1960 * elf32-tic6x.c (elf32_tic6x_info_to_howto)
1961 (elf32_tic6x_info_to_howto_rel): Likewise.
1962 * elf32-tilepro.c (tilepro_info_to_howto_rela): Likewise.
1963 * elf32-v850.c (v850_elf_info_to_howto_rel)
1964 (v850_elf_info_to_howto_rela, v800_elf_info_to_howto): Likewise.
1965 * elf32-vax.c (rtype_to_howto): Likewise.
1966 * elf32-visium.c (visium_info_to_howto_rela): Likewise.
1967 * elf32-wasm32.c (elf32_wasm32_rtype_to_howto)
1968 (elf32_wasm32_info_to_howto_rela): Likewise.
1969 * elf32-xc16x.c (elf32_xc16x_info_to_howto): Likewise.
1970 * elf32-xgate.c (xgate_info_to_howto_rel): Likewise.
1971 * elf32-xstormy16.c (xstormy16_info_to_howto_rela): Likewise.
1972 * elf32-xtensa.c (elf_xtensa_info_to_howto_rela): Likewise.
1973 * elf64-alpha.c (elf64_alpha_info_to_howto): Likewise.
1974 * elf64-gen.c (elf_generic_info_to_howto)
1975 (elf_generic_info_to_howto_rel): Likewise.
1976 * elf64-ia64-vms.c (elf64_ia64_info_to_howto): Likewise.
1977 * elf64-mips.c (mips_elf64_info_to_howto_rela): Likewise.
1978 * elf64-mmix.c (mmix_info_to_howto_rela): Likewise.
1979 * elf64-ppc.c (ppc64_elf_info_to_howto): Likewise.
1980 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
1981 * elf64-sh64.c (elf_s390_info_to_howto, sh_elf64_info_to_howto):
1983 * elf64-x86-64.c (elf_x86_64_info_to_howto): Likewise.
1984 * elfn32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
1986 * elfnn-aarch64.c (elfNN_aarch64_info_to_howto): Likewise.
1987 * elfnn-ia64.c (elfNN_ia64_info_to_howto): Likewise.
1988 * elfnn-riscv.c (riscv_info_to_howto_rela): Likewise.
1989 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
1990 * elfxx-sparc.c (_bfd_sparc_elf_info_to_howto): Likewise.
1991 * elfxx-tilegx.c (tilegx_info_to_howto_rela): Likewise.
1992 * elf32-score.h (s7_bfd_score_info_to_howto): Update prototype.
1993 * elfxx-sparc.h (_bfd_sparc_elf_info_to_howto): Update prototype.
1994 * elfxx-tilegx.h (tilegx_info_to_howto_rela): Update prototype.
1995 * elfxx-target.h (elf_info_to_howto, elf_info_to_howto_rel):
1998 2018-02-26 Jim Wilson <jimw@sifive.com>
1999 Stephan Schreiber <info@fs-driver.org>
2002 * elfnn-ia64.c (elfNN_ia64_relax_section): After ia64_elf_relax_brl
2003 call, set changed_contents and changed_relocs. Likewise after
2004 successful ia64_elf_relax_br call.
2006 2018-02-26 Alan Modra <amodra@gmail.com>
2008 * elf.c (assign_file_positions_except_relocs): Don't segfault
2009 when actual number of phdrs is less than allocated. Delete
2010 outdated comment. Formatting.
2012 2018-02-26 Alan Modra <amodra@gmail.com>
2014 * elf-m10300.c, * elf-s390-common.c, * elf32-arc.c, * elf32-cris.c,
2015 * elf32-dlx.c, * elf32-frv.c, * elf32-i370.c, * elf32-lm32.c,
2016 * elf32-m32r.c, * elf32-m68hc1x.c, * elf32-m68k.c,
2017 * elf32-microblaze.c, * elf32-msp430.c, * elf32-nds32.c,
2018 * elf32-nios2.c, * elf32-or1k.c, * elf32-rl78.c, * elf32-rx.c,
2019 * elf32-score.c, * elf32-score7.c, * elf32-sh-symbian.c,
2020 * elf32-sh.c, * elf32-spu.c, * elf32-v850.c, * elf32-xtensa.c,
2021 * elf64-alpha.c, * elf64-ia64-vms.c, * elf64-mmix.c,
2022 * elf64-sh64.c, * elf64-sparc.c, * elfnn-ia64.c, * elfxx-tilegx.c,
2023 * mmo.c, * osf-core.c, * srec.c, * vms-alpha.c: Standardize
2024 error/warning messages.
2026 2018-02-26 Alan Modra <amodra@gmail.com>
2028 * archive.c, * bfd.c, * linker.c, * reloc.c, * stabs.c,
2029 * syms.c: Standardize error/warning messages.
2031 2018-02-26 Alan Modra <amodra@gmail.com>
2033 * aout-adobe.c, * aout-cris.c, * i386linux.c, * m68klinux.c,
2034 * sparclinux.c, * coff-alpha.c, * coff-arm.c, * coff-mcore.c,
2035 * coffcode.h, * coffgen.c, * cofflink.c, * ecoff.c, * pe-mips.c,
2036 * peXXigen.c, * peicode.h: Standardize error/warning messages.
2038 2018-02-26 Alan Modra <amodra@gmail.com>
2040 * elf32-arm.c, * elfnn-aarch64.c: Standardize error/warning messages.
2042 2018-02-26 Alan Modra <amodra@gmail.com>
2044 * elfxx-mips.c: Standardize error/warning messages.
2046 2018-02-26 Alan Modra <amodra@gmail.com>
2048 * dwarf2.c, * elf-attrs.c, * elf-eh-frame.c, * elf.c, * elf32-gen.c,
2049 * elflink.c: Standardize error/warning messages. Replace use of
2050 linker callback einfo with _bfd_error_handler when possible.
2052 2018-02-26 Alan Modra <amodra@gmail.com>
2054 * aoutx.h, * coff-alpha.c, * coff-i860.c, * coff-m68k.c,
2055 * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c, * coff-sh.c,
2056 * coff-tic4x.c, * coff-tic54x.c, * coff-tic80.c, * coff-w65.c,
2057 * elf-bfd.h, * elf-m10300.c, * elf.c, * elf32-avr.c, * elf32-bfin.c,
2058 * elf32-cr16.c, * elf32-cr16c.c, * elf32-cris.c, * elf32-crx.c,
2059 * elf32-d10v.c, * elf32-d30v.c, * elf32-dlx.c, * elf32-epiphany.c,
2060 * elf32-fr30.c, * elf32-frv.c, * elf32-i370.c, * elf32-i386.c,
2061 * elf32-i960.c, * elf32-ip2k.c, * elf32-iq2000.c, * elf32-lm32.c,
2062 * elf32-m32c.c, * elf32-m32r.c, * elf32-m68hc11.c, * elf32-m68hc12.c,
2063 * elf32-m68k.c, * elf32-mcore.c, * elf32-mep.c, * elf32-metag.c,
2064 * elf32-microblaze.c, * elf32-mips.c, * elf32-moxie.c,
2065 * elf32-msp430.c, * elf32-mt.c, * elf32-nds32.c, * elf32-or1k.c,
2066 * elf32-pj.c, * elf32-ppc.c, * elf32-rl78.c, * elf32-rx.c,
2067 * elf32-s390.c, * elf32-sh.c, * elf32-spu.c, * elf32-tic6x.c,
2068 * elf32-v850.c, * elf32-vax.c, * elf32-visium.c, * elf32-wasm32.c,
2069 * elf32-xgate.c, * elf32-xtensa.c, * elf64-alpha.c,
2070 * elf64-ia64-vms.c, * elf64-mips.c, * elf64-mmix.c,
2071 * elf64-ppc.c, * elf64-s390.c, * elf64-sparc.c, * elf64-x86-64.c,
2072 * elfn32-mips.c, * elfnn-aarch64.c, * elfnn-ia64.c,
2073 * elfnn-riscv.c, * elfxx-mips.c, * elfxx-riscv.c, * elfxx-riscv.h,
2074 * elfxx-sparc.c, * elfxx-sparc.h, * reloc.c: Standardize
2075 unrecognized/unsupported reloc message.
2077 2018-02-26 Alan Modra <amodra@gmail.com>
2079 * elf32-ppc.c: Standardize error/warning messages. Use
2080 _bfd_error_handler rather than einfo when einfo features not used.
2081 * elf64-ppc.c: Likewise.
2083 2018-02-23 Alan Modra <amodra@gmail.com>
2086 * elf.c (assign_file_positions_for_non_load_sections): Remove RELRO
2087 segment if no matching LOAD segment.
2089 2018-02-23 Kuan-Lin Chen <kuanlinchentw@gmail.com>
2091 * elf32-nds32.h: Define mask for ict_model.
2093 2018-02-20 Jason Duerstock <jason.duerstock@gmail.com>
2095 * elfnn-ia64.c (elf_backend_can_gc_sections): Enable.
2097 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2100 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
2102 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
2103 .reginfo section has wrong size.
2105 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2107 * elfxx-mips.c (_bfd_mips_elf_always_size_sections): Set
2108 SEC_FIXED_SIZE and SEC_HAS_CONTENTS flags for `.reginfo' and
2109 `.MIPS.abiflags' sections.
2110 (_bfd_mips_elf_final_link): Avoid reading beyond `.reginfo'
2113 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2115 * section.c (SEC_FIXED_SIZE): New macro.
2116 * bfd-in2.h: Regenerate.
2118 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2120 * section.c (SEC_HAS_GOT_REF): Remove macro.
2121 * bfd-in2.h: Regenerate.
2123 2018-02-19 Alan Modra <amodra@gmail.com>
2125 * elf-attrs.c (_bfd_elf_parse_attributes): Correct _bfd_error_handler
2127 * elfxx-mips.c (_bfd_mips_elf_final_link): Likewise.
2128 * elfnn-riscv.c (_bfd_riscv_relax_align): Likewise.
2129 (_bfd_riscv_relax_pc): Likewise and fix typos.
2130 * libbfd-in.h (_bfd_error_handler): Add attribute printf.
2131 * libbfd.h: Regenerate.
2133 2018-02-19 Alan Modra <amodra@gmail.com>
2135 * dwarf2.c (read_section): Don't use 'll' format modifier.
2136 (find_abstract_instance): Likewise.
2137 * elfcore.h (elf_core_file_p): Likewise.
2139 2018-02-19 Alan Modra <amodra@gmail.com>
2141 * bfd-in.h: Include inttypes.h or if not available define
2142 PRId64, PRIu64 and PRIx64.
2143 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Remove support for L
2144 modifier to print bfd_vma.
2145 * coff-arm.c, * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c,
2146 * coff-sh.c, * coff-tic80.c, * coffcode.h, * coffgen.c, * cofflink.c,
2147 * compress.c, * dwarf2.c, * elf-m10300.c, * elf.c, * elf32-arc.c,
2148 * elf32-arm.c, * elf32-bfin.c, * elf32-cris.c, * elf32-hppa.c,
2149 * elf32-i386.c, * elf32-ip2k.c, * elf32-lm32.c, * elf32-m32r.c,
2150 * elf32-m68k.c, * elf32-metag.c, * elf32-nds32.c, * elf32-nios2.c,
2151 * elf32-ppc.c, * elf32-rx.c, * elf32-s390.c, * elf32-score.c,
2152 * elf32-score7.c, * elf32-sh.c, * elf32-sh64.c, * elf32-spu.c,
2153 * elf32-tic6x.c, * elf32-tilepro.c, * elf32-v850.c, * elf32-vax.c,
2154 * elf32-xtensa.c, * elf64-alpha.c, * elf64-hppa.c, * elf64-ia64-vms.c,
2155 * elf64-mmix.c, * elf64-s390.c, * elf64-sh64.c, * elf64-x86-64.c,
2156 * elfcode.h, * elfcore.h, * elflink.c, * elfnn-aarch64.c,
2157 * elfnn-ia64.c, * elfnn-riscv.c, * elfxx-mips.c, * elfxx-sparc.c,
2158 * elfxx-tilegx.c, * ieee.c, * ihex.c, * mach-o.c, * merge.c, * mmo.c,
2159 * peXXigen.c, * xcofflink.c: Replace use of Lx modifier with PRIx64,
2160 and cast input to uint64_t, and similarly for Ld and Lu.
2161 * bfd-in2.h: Regenerate.
2163 2018-02-19 Alan Modra <amodra@gmail.com>
2165 * elf32-arm.c, * elf32-hppa.c, * elf32-lm32.c, * elf32-m32r.c,
2166 * elf32-metag.c, * elf32-nds32.c, * elf32-or1k.c, * elf32-ppc.c,
2167 * elf32-s390.c, * elf32-sh.c, * elf32-tic6x.c, * elf32-tilepro.c,
2168 * elf64-ppc.c, * elf64-s390.c, * elflink.c, * elfnn-aarch64.c,
2169 * elfnn-riscv.c, * elfxx-sparc.c, * elfxx-tilegx.c, * elfxx-x86.c,
2170 * reloc.c: Replace use of %R and %T in format strings passed to
2171 einfo and friends by %pR and %pT.
2173 2018-02-19 Alan Modra <amodra@gmail.com>
2175 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Handle %pA and %pB in place
2177 * aout-adobe.c: Update all messages using %A and %B.
2178 * aout-cris.c: Likewise.
2179 * aoutx.h: Likewise.
2180 * archive.c: Likewise.
2181 * binary.c: Likewise.
2182 * cache.c: Likewise.
2183 * coff-alpha.c: Likewise.
2184 * coff-arm.c: Likewise.
2185 * coff-i860.c: Likewise.
2186 * coff-mcore.c: Likewise.
2187 * coff-ppc.c: Likewise.
2188 * coff-rs6000.c: Likewise.
2189 * coff-sh.c: Likewise.
2190 * coff-tic4x.c: Likewise.
2191 * coff-tic54x.c: Likewise.
2192 * coff-tic80.c: Likewise.
2193 * coff64-rs6000.c: Likewise.
2194 * coffcode.h: Likewise.
2195 * coffgen.c: Likewise.
2196 * cofflink.c: Likewise.
2197 * coffswap.h: Likewise.
2198 * compress.c: Likewise.
2199 * cpu-arm.c: Likewise.
2200 * ecoff.c: Likewise.
2201 * elf-attrs.c: Likewise.
2202 * elf-eh-frame.c: Likewise.
2203 * elf-ifunc.c: Likewise.
2204 * elf-m10300.c: Likewise.
2205 * elf-properties.c: Likewise.
2206 * elf-s390-common.c: Likewise.
2208 * elf32-arc.c: Likewise.
2209 * elf32-arm.c: Likewise.
2210 * elf32-avr.c: Likewise.
2211 * elf32-bfin.c: Likewise.
2212 * elf32-cr16.c: Likewise.
2213 * elf32-cr16c.c: Likewise.
2214 * elf32-cris.c: Likewise.
2215 * elf32-crx.c: Likewise.
2216 * elf32-d10v.c: Likewise.
2217 * elf32-d30v.c: Likewise.
2218 * elf32-epiphany.c: Likewise.
2219 * elf32-fr30.c: Likewise.
2220 * elf32-frv.c: Likewise.
2221 * elf32-gen.c: Likewise.
2222 * elf32-hppa.c: Likewise.
2223 * elf32-i370.c: Likewise.
2224 * elf32-i386.c: Likewise.
2225 * elf32-i960.c: Likewise.
2226 * elf32-ip2k.c: Likewise.
2227 * elf32-iq2000.c: Likewise.
2228 * elf32-lm32.c: Likewise.
2229 * elf32-m32c.c: Likewise.
2230 * elf32-m32r.c: Likewise.
2231 * elf32-m68hc11.c: Likewise.
2232 * elf32-m68hc12.c: Likewise.
2233 * elf32-m68hc1x.c: Likewise.
2234 * elf32-m68k.c: Likewise.
2235 * elf32-mcore.c: Likewise.
2236 * elf32-mep.c: Likewise.
2237 * elf32-metag.c: Likewise.
2238 * elf32-microblaze.c: Likewise.
2239 * elf32-moxie.c: Likewise.
2240 * elf32-msp430.c: Likewise.
2241 * elf32-mt.c: Likewise.
2242 * elf32-nds32.c: Likewise.
2243 * elf32-nios2.c: Likewise.
2244 * elf32-or1k.c: Likewise.
2245 * elf32-pj.c: Likewise.
2246 * elf32-ppc.c: Likewise.
2247 * elf32-rl78.c: Likewise.
2248 * elf32-rx.c: Likewise.
2249 * elf32-s390.c: Likewise.
2250 * elf32-score.c: Likewise.
2251 * elf32-score7.c: Likewise.
2252 * elf32-sh-symbian.c: Likewise.
2253 * elf32-sh.c: Likewise.
2254 * elf32-sh64.c: Likewise.
2255 * elf32-sparc.c: Likewise.
2256 * elf32-spu.c: Likewise.
2257 * elf32-tic6x.c: Likewise.
2258 * elf32-tilepro.c: Likewise.
2259 * elf32-v850.c: Likewise.
2260 * elf32-vax.c: Likewise.
2261 * elf32-visium.c: Likewise.
2262 * elf32-wasm32.c: Likewise.
2263 * elf32-xgate.c: Likewise.
2264 * elf32-xtensa.c: Likewise.
2265 * elf64-alpha.c: Likewise.
2266 * elf64-gen.c: Likewise.
2267 * elf64-hppa.c: Likewise.
2268 * elf64-ia64-vms.c: Likewise.
2269 * elf64-mmix.c: Likewise.
2270 * elf64-ppc.c: Likewise.
2271 * elf64-s390.c: Likewise.
2272 * elf64-sh64.c: Likewise.
2273 * elf64-sparc.c: Likewise.
2274 * elf64-x86-64.c: Likewise.
2275 * elfcode.h: Likewise.
2276 * elfcore.h: Likewise.
2277 * elflink.c: Likewise.
2278 * elfnn-aarch64.c: Likewise.
2279 * elfnn-ia64.c: Likewise.
2280 * elfnn-riscv.c: Likewise.
2281 * elfxx-mips.c: Likewise.
2282 * elfxx-sparc.c: Likewise.
2283 * elfxx-tilegx.c: Likewise.
2284 * elfxx-x86.c: Likewise.
2285 * hpux-core.c: Likewise.
2288 * libbfd.c: Likewise.
2289 * linker.c: Likewise.
2290 * mach-o.c: Likewise.
2291 * merge.c: Likewise.
2293 * oasys.c: Likewise.
2294 * pdp11.c: Likewise.
2295 * pe-mips.c: Likewise.
2296 * peXXigen.c: Likewise.
2297 * peicode.h: Likewise.
2298 * reloc.c: Likewise.
2299 * rs6000-core.c: Likewise.
2301 * stabs.c: Likewise.
2302 * vms-alpha.c: Likewise.
2303 * xcofflink.c: Likewise.
2305 2018-02-19 Alan Modra <amodra@gmail.com>
2308 * elf.c (IS_TBSS): Define.
2309 (_bfd_elf_map_sections_to_segments): Use IS_TBSS.
2310 (assign_file_positions_for_non_load_sections): Revert last change.
2311 Properly calculate load segment limits to compare against relro limits.
2313 2018-02-17 Alan Modra <amodra@gmail.com>
2316 * elf.c (assign_file_positions_for_non_load_sections): Ignore
2317 degenerate zero size PT_LOAD segments when finding one overlapping
2318 the PT_GNU_RELRO segment.
2320 2018-02-16 Alan Modra <amodra@gmail.com>
2322 * libbfd.c (_bfd_bool_bfd_false_error): Rename from bfd_false.
2323 (_bfd_bool_bfd_true): Rename from bfd_true.
2324 (_bfd_ptr_bfd_null_error): Rename from bfd_nullvoidptr.
2325 (_bfd_int_bfd_0): Rename from bfd_0.
2326 (_bfd_uint_bfd_0): Rename from bfd_0u.
2327 (_bfd_long_bfd_0): Rename from bfd_0l.
2328 (_bfd_long_bfd_n1_error): Rename from _bfd_n1.
2329 (_bfd_void_bfd): Rename from bfd_void.
2330 (_bfd_bool_bfd_false, _bfd_bool_bfd_asymbol_false),
2331 (_bfd_bool_bfd_link_false_error),
2332 (_bfd_bool_bfd_link_true, _bfd_bool_bfd_bfd_true),
2333 (_bfd_bool_bfd_uint_true, _bfd_bool_bfd_ptr_true),
2334 (_bfd_bool_bfd_asection_bfd_asection_true),
2335 (_bfd_bool_bfd_asymbol_bfd_asymbol_true),
2336 (_bfd_void_bfd_link, _bfd_void_bfd_asection): New functions.
2337 * archive.c (_bfd_noarchive_get_elt_at_index),
2338 (_bfd_noarchive_openr_next_archived_file),
2339 (_bfd_noarchive_construct_extended_name_table),
2340 (_bfd_noarchive_write_ar_hdr, _bfd_noarchive_truncate_arname),
2341 (_bfd_noarchive_write_armap): New functions.
2342 * archures.c (_bfd_nowrite_set_arch_mach): New function.
2343 * coff-alpha.c (alpha_ecoff_swap_coff_aux_in),
2344 (alpha_ecoff_swap_coff_sym_in, alpha_ecoff_swap_coff_lineno_in),
2345 (alpha_ecoff_swap_coff_aux_out, alpha_ecoff_swap_coff_sym_out),
2346 (alpha_ecoff_swap_coff_lineno_out),
2347 (alpha_ecoff_swap_coff_reloc_out): New functions.
2348 * coff-mips.c (mips_ecoff_swap_coff_aux_in),
2349 (mips_ecoff_swap_coff_sym_in, mips_ecoff_swap_coff_lineno_in),
2350 (mips_ecoff_swap_coff_aux_out, mips_ecoff_swap_coff_sym_out),
2351 (mips_ecoff_swap_coff_lineno_out),
2352 (mips_ecoff_swap_coff_reloc_out): New functions.
2353 * coffcode.h (coff_set_alignment_hook): Replace define with
2355 (symname_in_debug_hook): Likewise.
2356 * ecoff.c (_bfd_ecoff_set_alignment_hook): New function.
2357 * elfxx-target.h (elf_backend_allow_non_load_phdr): Default to 0.
2358 * elf.c (assign_file_positions_except_relocs): Test
2359 elf_backend_allow_non_load_phdr for NULL.
2360 * elflink.c (_bfd_elf_omit_section_dynsym_default): Rename from
2361 _bfd_elf_link_omit_section_dynsym. Update uses.
2362 (_bfd_elf_omit_section_dynsym_all): New function.
2363 * elf-bfd.h (_bfd_elf_link_omit_section_dynsym): Delete.
2364 (_bfd_elf_omit_section_dynsym_default): Declare.
2365 (_bfd_elf_omit_section_dynsym_all): Declare.
2366 * linker.c (_bfd_nolink_sizeof_headers, _bfd_nolink_bfd_relax_section),
2367 (_bfd_nolink_bfd_get_relocated_section_contents),
2368 (_bfd_nolink_bfd_lookup_section_flags),
2369 (_bfd_nolink_bfd_is_group_section, _bfd_nolink_bfd_discard_group),
2370 (_bfd_nolink_bfd_link_hash_table_create),
2371 (_bfd_nolink_bfd_link_just_syms),
2372 (_bfd_nolink_bfd_copy_link_hash_symbol_type),
2373 (_bfd_nolink_bfd_link_split_section),
2374 (_bfd_nolink_section_already_linked),
2375 (_bfd_nolink_bfd_define_common_symbol),
2376 (_bfd_nolink_bfd_define_start_stop): New functions.
2377 * reloc.c (_bfd_norelocs_bfd_reloc_type_lookup),
2378 (_bfd_norelocs_bfd_reloc_name_lookup),
2379 (_bfd_nodynamic_canonicalize_dynamic_reloc): New functions.
2380 * section.c (_bfd_nowrite_set_section_contents): New function.
2381 * syms.c (_bfd_nosymbols_canonicalize_symtab),
2382 (_bfd_nosymbols_print_symbol, _bfd_nosymbols_get_symbol_info),
2383 (_bfd_nosymbols_get_symbol_version_string),
2384 (_bfd_nosymbols_bfd_is_local_label_name),
2385 (_bfd_nosymbols_get_lineno, _bfd_nosymbols_find_nearest_line),
2386 (_bfd_nosymbols_find_line, _bfd_nosymbols_find_inliner_info),
2387 (_bfd_nosymbols_bfd_make_debug_symbol),
2388 ( _bfd_nosymbols_read_minisymbols),
2389 ( _bfd_nosymbols_minisymbol_to_symbol),
2390 (_bfd_nodynamic_get_synthetic_symtab): New functions.
2391 * libbfd-in.h: Declare new functions. Update existing defines,
2393 * aix386-core.c: Update to use new hooks. Formatting.
2394 * aout-adobe.c: Likewise.
2395 * aout-arm.c: Likewise.
2396 * aout-target.h: Likewise.
2397 * aout-tic30.c: Likewise.
2398 * aoutf1.h: Likewise.
2399 * binary.c: Likewise.
2401 * cisco-core.c: Likewise.
2402 * coff-alpha.c: Likewise.
2403 * coff-i386.c: Likewise.
2404 * coff-i860.c: Likewise.
2405 * coff-i960.c: Likewise.
2406 * coff-ia64.c: Likewise.
2407 * coff-mips.c: Likewise.
2408 * coff-ppc.c: Likewise.
2409 * coff-rs6000.c: Likewise.
2410 * coff-sh.c: Likewise.
2411 * coff-tic30.c: Likewise.
2412 * coff-tic54x.c: Likewise.
2413 * coff-x86_64.c: Likewise.
2414 * coff64-rs6000.c: Likewise.
2415 * coffcode.h: Likewise.
2416 * elf-m10300.c: Likewise.
2417 * elf32-cr16.c: Likewise.
2418 * elf32-lm32.c: Likewise.
2419 * elf32-m32r.c: Likewise.
2420 * elf32-metag.c: Likewise.
2421 * elf32-score.c: Likewise.
2422 * elf32-score7.c: Likewise.
2423 * elf32-tilepro.c: Likewise.
2424 * elf32-xstormy16.c: Likewise.
2425 * elf32-xtensa.c: Likewise.
2426 * elf64-alpha.c: Likewise.
2427 * elf64-hppa.c: Likewise.
2428 * elf64-ia64-vms.c: Likewise.
2429 * elf64-mmix.c: Likewise.
2430 * elf64-sh64.c: Likewise.
2431 * elfnn-ia64.c: Likewise.
2432 * elfxx-sparc.c: Likewise.
2433 * elfxx-target.h: Likewise.
2434 * elfxx-tilegx.c: Likewise.
2435 * elfxx-x86.h: Likewise.
2436 * hp300hpux.c: Likewise.
2437 * hppabsd-core.c: Likewise.
2438 * hpux-core.c: Likewise.
2439 * i386msdos.c: Likewise.
2440 * i386os9k.c: Likewise.
2443 * irix-core.c: Likewise.
2444 * libaout.h: Likewise.
2445 * libecoff.h: Likewise.
2446 * mach-o-target.c: Likewise.
2447 * mach-o.c: Likewise.
2448 * mipsbsd.c: Likewise.
2450 * netbsd-core.c: Likewise.
2451 * nlm-target.h: Likewise.
2452 * oasys.c: Likewise.
2453 * osf-core.c: Likewise.
2454 * pdp11.c: Likewise.
2455 * pe-mips.c: Likewise.
2456 * pe-x86_64.c: Likewise.
2458 * plugin.c: Likewise.
2459 * ppcboot.c: Likewise.
2460 * ptrace-core.c: Likewise.
2461 * sco5-core.c: Likewise.
2463 * sparclynx.c: Likewise.
2465 * tekhex.c: Likewise.
2466 * trad-core.c: Likewise.
2467 * verilog.c: Likewise.
2468 * versados.c: Likewise.
2469 * vms-alpha.c: Likewise.
2470 * vms-lib.c: Likewise.
2471 * wasm-module.c: Likewise.
2473 * libbfd.h: Regenerate.
2475 2018-02-15 Jim Wilson <jimw@sifive.com>
2477 * elfnn-riscv.c (_bfd_riscv_relax_section): Ifdef out check to ignore
2478 symbols whose section address is zero.
2480 * elfnn-riscv.c (riscv_elf_relocate_section): Use bfd_reloc_dangerous
2481 when pcrel_lo reloc has an addend. Use reloc_dangerous callback for
2482 bfd_reloc_dangerous. Use einfo instead of warning callback for errors.
2483 Add %X%P to error messages.
2485 2018-02-15 Eric Botcazou <ebotcazou@adacore.com>
2488 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
2489 Pass FALSE instead of TRUE as 'create' argument to bfd_link_hash_lookup
2490 and assert that the result of the call is not NULL.
2492 2018-02-14 Nick Clifton <nickc@redhat.com>
2495 Revert previous delta. Add extra casts to avoid compile time
2497 * libbfd-in.h (_bfd_generic_bfd_copy_private_bfd_data): Add extra
2498 cast to avoid warning from gcc v8 compiler.
2499 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
2500 (_bfd_generic_bfd_set_private_flags): Likewise.
2501 (_bfd_generic_bfd_copy_private_section_data): Likewise.
2502 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
2503 (_bfd_generic_bfd_copy_private_header_data): Likewise.
2504 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
2505 (_bfd_noarchive_construct_extended_name_table): Likewise.
2506 (_bfd_noarchive_truncate_arname): Likewise.
2507 (_bfd_noarchive_write_ar_hdr): Likewise.
2508 (_bfd_noarchive_get_elt_at_index): Likewise.
2509 (_bfd_nosymbols_canonicalize_symtab): Likewise.
2510 (_bfd_nosymbols_print_symbol): Likewise.
2511 (_bfd_nosymbols_get_symbol_info): Likewise.
2512 (_bfd_nosymbols_get_symbol_version_string): Likewise.
2513 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
2514 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
2515 (_bfd_nosymbols_get_lineno): Likewise.
2516 (_bfd_nosymbols_find_nearest_line): Likewise.
2517 (_bfd_nosymbols_find_line): Likewise.
2518 (_bfd_nosymbols_find_inliner_info): Likewise.
2519 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
2520 (_bfd_nosymbols_read_minisymbols): Likewise.
2521 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
2522 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
2523 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
2524 (_bfd_nowrite_set_arch_mach): Likewise.
2525 (_bfd_nowrite_set_section_contents): Likewise.
2526 (_bfd_nolink_sizeof_headers): Likewise.
2527 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
2528 (_bfd_nolink_bfd_relax_section): Likewise.
2529 (_bfd_nolink_bfd_gc_sections): Likewise.
2530 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
2531 (_bfd_nolink_bfd_merge_sections): Likewise.
2532 (_bfd_nolink_bfd_is_group_section): Likewise.
2533 (_bfd_nolink_bfd_discard_group): Likewise.
2534 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
2535 (_bfd_nolink_bfd_link_add_symbols): Likewise.
2536 (_bfd_nolink_bfd_link_just_syms): Likewise.
2537 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
2538 (_bfd_nolink_bfd_final_link): Likewise.
2539 (_bfd_nolink_bfd_link_split_section): Likewise.
2540 (_bfd_nolink_section_already_linked): Likewise.
2541 (_bfd_nolink_bfd_define_common_symbol): Likewise.
2542 (_bfd_nolink_bfd_define_start_stop): Likewise.
2543 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
2544 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
2545 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
2546 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
2547 * libbfd.c (bfd_false_any): Delete.
2548 (bfd_true_any, bfd_nullvoidptr_any, bfd_0_any): Delete.
2549 (bfd_0u_any, bfd_0l_any, _bfd_n1_any, bfd_void_any): Delete.
2550 * libbfd.h (extern): Regenerate
2551 * aout-target.h (MY_bfd_is_target_special_symbol): Add extra
2552 cast to avoid warning from gcc v8 compiler.
2553 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
2554 * binary.c (binary_get_symbol_info): Likewise.
2555 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
2556 * coff-mips.c (mips_ecoff_backend_data): Likewise.
2557 * coffcode.h (coff_set_alignment_hook): Likewise.
2558 (symname_in_debug_hook): Likewise.
2559 (bfd_coff_backend_data bigobj_swap_table): Likewise.
2560 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
2561 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
2562 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
2563 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
2564 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
2565 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
2566 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
2567 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
2568 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
2569 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
2570 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
2571 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
2572 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
2573 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
2574 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
2575 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
2576 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
2577 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
2578 (bfd_elfNN_bfd_set_private_flags): Likewise.
2579 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
2580 (elf_backend_init_index_section): Likewise.
2581 (elf_backend_allow_non_load_phdr): Likewise.
2582 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
2583 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
2584 * ieee.c (ieee_construct_extended_name_table): Likewise.
2585 (ieee_write_armap): Likewise.
2586 (ieee_write_ar_hdr): Likewise.
2587 (ieee_bfd_is_target_special_symbol): Likewise.
2588 * ihex.c (ihex_canonicalize_symtab): Likewise.
2589 (ihex_bfd_is_target_special_symbol): Likewise.
2590 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
2591 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
2592 (_bfd_ecoff_set_alignment_hook): Likewise.
2593 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
2594 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
2595 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
2596 * oasys.c (oasys_construct_extended_name_table): Likewise.
2597 (oasys_write_armap): Likewise.
2598 (oasys_write_ar_hdr): Likewise.
2599 (oasys_bfd_is_target_special_symbol): Likewise.
2600 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
2601 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
2602 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
2603 * som.c (som_bfd_is_target_special_symbol): Likewise.
2604 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
2605 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
2606 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
2607 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
2608 (versados_bfd_reloc_name_lookup): Likewise.
2609 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
2610 (vms_bfd_define_start_stop): Likewise.
2611 (alpha_vms_bfd_is_target_special_symbol): Likewise.
2612 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
2613 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
2615 2018-02-14 H.J. Lu <hongjiu.lu@intel.com>
2618 * elf32-i386.c (elf_i386_check_relocs): Pass FALSE for non
2619 PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
2620 * elf64-x86-64.c (elf_x86_64_check_relocs): Create PLT for
2621 R_X86_64_PC32 reloc against dynamic function in data section.
2622 Pass TRUE for PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
2623 (elf_x86_64_relocate_section): Use PLT for R_X86_64_PC32 reloc
2624 against dynamic function in data section.
2625 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Use PLT in PIE as
2626 function address only if pcrel_plt is true.
2627 (_bfd_x86_elf_link_hash_table_create): Set pcrel_plt.
2628 * elfxx-x86.h (NEED_DYNAMIC_RELOCATION_P): Add PCREL_PLT for
2629 PC-relative PLT. If PLT is PC-relative, don't generate dynamic
2630 PC-relative relocation against a function definition in data
2631 secton in PIE. Remove the obsolete comments.
2632 (elf_x86_link_hash_table): Add pcrel_plt.
2634 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
2636 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Check bfd_link_dll,
2637 instead of bfd_link_pic, for building shared library.
2639 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
2642 * elf64-x86-64.c (is_32bit_relative_branch): Removed.
2643 (elf_x86_64_relocate_section): Check PIC relocations in PIE.
2644 Remove is_32bit_relative_branch usage. Disallow PC32 reloc
2645 against protected function in shared object.
2647 2018-02-13 Sergei Trofimovich <slyfox@inbox.ru>
2650 * po/ru.po: Fix typo in Russian translation.
2652 2018-02-13 Maciej W. Rozycki <macro@mips.com>
2654 * wasm-module.c (wasm_scan_name_function_section): Rename
2655 `index' local variable to `idx'.
2657 2018-02-13 Nick Clifton <nickc@redhat.com>
2660 Fix compile time warnings generated by gcc version 8.
2661 * libbfd-in.h: Remove extraneous text from prototypes.
2662 Add prototypes for bfd_false_any, bfd_true_any,
2663 bfd_nullvoidptr_any, bfd_0_any, bfd_0u_any, bfd_0l_any,
2664 bfd_n1_any, bfd_void_any.
2665 (_bfd_generic_bfd_copy_private_bfd_data): Use vararg based dummy
2667 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
2668 (_bfd_generic_bfd_set_private_flags): Likewise.
2669 (_bfd_generic_bfd_copy_private_section_data): Likewise.
2670 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
2671 (_bfd_generic_bfd_copy_private_header_data): Likewise.
2672 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
2673 (_bfd_noarchive_construct_extended_name_table): Likewise.
2674 (_bfd_noarchive_truncate_arname): Likewise.
2675 (_bfd_noarchive_write_ar_hdr): Likewise.
2676 (_bfd_noarchive_get_elt_at_index): Likewise.
2677 (_bfd_nosymbols_canonicalize_symtab): Likewise.
2678 (_bfd_nosymbols_print_symbol): Likewise.
2679 (_bfd_nosymbols_get_symbol_info): Likewise.
2680 (_bfd_nosymbols_get_symbol_version_string): Likewise.
2681 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
2682 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
2683 (_bfd_nosymbols_get_lineno): Likewise.
2684 (_bfd_nosymbols_find_nearest_line): Likewise.
2685 (_bfd_nosymbols_find_line): Likewise.
2686 (_bfd_nosymbols_find_inliner_info): Likewise.
2687 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
2688 (_bfd_nosymbols_read_minisymbols): Likewise.
2689 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
2690 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
2691 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
2692 (_bfd_nowrite_set_arch_mach): Likewise.
2693 (_bfd_nowrite_set_section_contents): Likewise.
2694 (_bfd_nolink_sizeof_headers): Likewise.
2695 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
2696 (_bfd_nolink_bfd_relax_section): Likewise.
2697 (_bfd_nolink_bfd_gc_sections): Likewise.
2698 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
2699 (_bfd_nolink_bfd_merge_sections): Likewise.
2700 (_bfd_nolink_bfd_is_group_section): Likewise.
2701 (_bfd_nolink_bfd_discard_group): Likewise.
2702 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
2703 (_bfd_nolink_bfd_link_add_symbols): Likewise.
2704 (_bfd_nolink_bfd_link_just_syms): Likewise.
2705 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
2706 (_bfd_nolink_bfd_final_link): Likewise.
2707 (_bfd_nolink_bfd_link_split_section): Likewise.
2708 (_bfd_nolink_section_already_linked): Likewise.
2709 (_bfd_nolink_bfd_define_common_symbol): Likewise.
2710 (_bfd_nolink_bfd_define_start_stop): Likewise.
2711 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
2712 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
2713 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
2714 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
2715 * libbfd.c (bfd_false_any): New function. Like bfd_false but
2716 accepts one or more arguments.
2717 (bfd_true_any): Likewise.
2718 (bfd_nullvoidptr_any): Likewise.
2719 (bfd_0_any): Likewise.
2720 (bfd_0u_any): Likewise.
2721 (bfd_0l_any): Likewise.
2722 (_bfd_n1_any): Likewise.
2723 (bfd_void_any): Likewise.
2724 * libbfd.h (extern): Regenerate
2725 * aout-target.h (MY_bfd_is_target_special_symbol): Use vararg
2726 based dummy function.
2727 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
2728 * binary.c (binary_get_symbol_info): Likewise.
2729 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
2730 * coff-mips.c (mips_ecoff_backend_data): Likewise.
2731 * coffcode.h (coff_set_alignment_hook): Likewise.
2732 (symname_in_debug_hook): Likewise.
2733 (bfd_coff_backend_data bigobj_swap_table): Likewise.
2734 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
2735 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
2736 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
2737 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
2738 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
2739 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
2740 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
2741 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
2742 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
2743 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
2744 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
2745 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
2746 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
2747 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
2748 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
2749 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
2750 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
2751 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
2752 (bfd_elfNN_bfd_set_private_flags): Likewise.
2753 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
2754 (elf_backend_init_index_section): Likewise.
2755 (elf_backend_allow_non_load_phdr): Likewise.
2756 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
2757 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
2758 * ieee.c (ieee_construct_extended_name_table): Likewise.
2759 (ieee_write_armap): Likewise.
2760 (ieee_write_ar_hdr): Likewise.
2761 (ieee_bfd_is_target_special_symbol): Likewise.
2762 * ihex.c (ihex_canonicalize_symtab): Likewise.
2763 (ihex_bfd_is_target_special_symbol): Likewise.
2764 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
2765 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
2766 (_bfd_ecoff_set_alignment_hook): Likewise.
2767 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
2768 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
2769 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
2770 * oasys.c (oasys_construct_extended_name_table): Likewise.
2771 (oasys_write_armap): Likewise.
2772 (oasys_write_ar_hdr): Likewise.
2773 (oasys_bfd_is_target_special_symbol): Likewise.
2774 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
2775 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
2776 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
2777 * som.c (som_bfd_is_target_special_symbol): Likewise.
2778 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
2779 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
2780 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
2781 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
2782 (versados_bfd_reloc_name_lookup): Likewise.
2783 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
2784 (vms_bfd_define_start_stop): Likewise.
2785 (alpha_vms_bfd_is_target_special_symbol): Likewise.
2786 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
2787 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
2788 * elf32-arc.c (get_replace_function): Assign replacement function
2790 * elf32-i370.c (i370_noop): Update prototype.
2792 2018-02-13 Alan Modra <amodra@gmail.com>
2795 * elf.c (_bfd_elf_fixup_group_sections): Account for removed
2796 relocation sections. If size reduces to just the flag word,
2797 remove that too and mark with SEC_EXCLUDE.
2798 * elflink.c (bfd_elf_final_link): Strip empty group sections.
2800 2018-02-13 Alan Modra <amodra@gmail.com>
2803 * elf.c (assign_file_positions_for_non_load_sections): Rewrite
2806 2018-02-12 Zebediah Figura <z.figura12@gmail.com>
2808 * i386msdos.c (msdos_mkobject); New function.
2809 (msdos_object_p): New function.
2810 (i386_msdos_vec): Use msdos_object_p as the check_format
2812 * peicode.h: Rename external_PEI_DOS_hdr, DOSMAGIC, and
2813 NT_SIGNATURE to external_DOS_hdr, IMAGE_DOS_SIGNATURE, and
2815 * peXXigen.c: Likewise.
2816 * coff-ia64.c: Likewise.
2818 2018-02-12 Nick Clifton <nickc@redhat.com>
2820 * elf32-nds32.c (nds32_elf_relax_longjump3): Remove redundant
2822 * elf32-arc.c (elf_arc_relocate_section): Likewise.
2824 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
2826 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Reorder conditions.
2827 (sparc_elf_append_rela): Assert that there is enough room in section.
2828 (_bfd_sparc_elf_copy_indirect_symbol): Fix formatting.
2829 (_bfd_sparc_elf_adjust_dynamic_symbol): Minor tweak.
2830 (allocate_dynrelocs): Remove outdated comments and reorder conditions.
2831 For a symbol subject to a GOT relocation, reserve a slot in the
2832 relocation section if the symbol isn't dynamic and we are in PIC mode.
2833 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: If relocation
2834 is relaxed and a slot was reserved, generate a R_SPARC_NONE relocation.
2835 <R_SPARC_GOTDATA_OP_HIX22>: Adjust comments.
2836 <R_SPARC_PC10>: Reorder conditions. Remove always-false assertion.
2837 (_bfd_sparc_elf_finish_dynamic_symbol): Rename local_undefweak into
2838 resolved_to_zero. Do not generate a dynamic GOT relocation for an
2839 undefined weak symbol with non-default visibility. Remove superfluous
2840 'else' and fix formatting.
2842 2018-02-09 H.J. Lu <hongjiu.lu@intel.com>
2844 * elf32-i386.c (elf_i386_get_synthetic_symtab): Also handle
2846 (i386_elf32_sol2_vec): Don't declare.
2847 (elf_i386_link_setup_gnu_properties): Also handle is_solaris.
2848 Don't set need_global_offset_table.
2849 (elf_i386_solaris_arch_bed): New.
2850 (elf_backend_arch_data): Set to elf_i386_solaris_arch_bed for
2852 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Check
2853 target_os != is_nacl instead of target_os == is_normal.
2854 (x86_64_elf64_sol2_vec): Don't declare.
2855 (elf_x86_64_link_setup_gnu_properties): Check target_os !=
2856 is_nacl instead of target_os == is_normal. Don't set
2857 need_global_offset_table.
2858 (elf_x86_64_solaris_arch_bed): New.
2859 (elf_backend_arch_data): Set to elf_x86_64_solaris_arch_bed for
2861 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep
2862 _GLOBAL_OFFSET_TABLE_ for Solaris.
2863 (_bfd_x86_elf_link_setup_gnu_properties): Don't copy
2864 need_global_offset_table.
2865 * elfxx-x86.h (elf_x86_target_os): Add is_solaris.
2866 (elf_x86_link_hash_table): Remove need_global_offset_table.
2867 (elf_x86_init_table): Likewise.
2869 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
2871 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
2873 (i386_elf32_sol2_vec): Declared.
2874 (elf_i386_link_setup_gnu_properties): Set
2875 need_global_offset_table with info->output_bfd->xvec.
2876 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
2878 (x86_64_elf64_sol2_vec): Declared.
2879 (elf_x86_64_link_setup_gnu_properties): Set
2880 need_global_offset_table with info->output_bfd->xvec.
2882 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
2884 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
2886 (elf_i386_link_setup_gnu_properties): Set need_global_offset_table
2888 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
2890 (elf_x86_64_link_setup_gnu_properties): Set
2891 need_global_offset_table for Solaris.
2892 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep the
2893 unused _GLOBAL_OFFSET_TABLE_ for Solaris.
2894 (_bfd_x86_elf_link_setup_gnu_properties): Copy
2895 need_global_offset_table.
2896 * elfxx-x86.h (elf_x86_link_hash_table): Add
2897 need_global_offset_table.
2898 (elf_x86_init_table): Likewise.
2900 2018-02-08 Jim Wilson <jimw@sifive.com>
2902 * elfnn-riscv.c (riscv_elf_relocate_section): Add comment for previous
2905 2018-02-08 Nick Clifton <nickc@redhat.com>
2908 * elf.c (elf_parse_notes): Reject notes with excessuively large
2911 2018-02-07 Alan Modra <amodra@gmail.com>
2913 Revert 2018-01-17 Alan Modra <amodra@gmail.com>
2914 * elf32-ppc.c: Remove speculation barrier support.
2915 * elf32-ppc.h: Likewise.
2916 * elf64-ppc.c: Likewise.
2917 * elf64-ppc.h: Likewise.
2919 2018-02-06 Jim Wilson <jimw@sifive.com>
2921 * elfnn-riscv.c (riscv_elf_relocate_section): Return TRUE if used
2922 callback to report an error.
2924 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
2927 * elfxx-sparc.c (sparc_elf_tls_transition): Turn call to bfd_link_pic
2928 into call to !bfd_link_executable and tidy up.
2929 (_bfd_sparc_elf_check_relocs): Fix formatting and tidy up.
2930 <R_SPARC_TLS_LE_HIX22>: Turn call to bfd_link_pic into call to
2931 !bfd_link_executable.
2932 <R_SPARC_TLS_IE_HI22>: Likewise.
2933 <GOT relocations>: Remove useless code, tidy and merge related blocks.
2934 <R_SPARC_TLS_GD_CALL>: Turn call to bfd_link_pic into call to
2935 !bfd_link_executable.
2936 <R_SPARC_WPLT30>: Tidy up.
2937 (_bfd_sparc_elf_gc_mark_hook): Turn call to bfd_link_pic into call to
2938 !bfd_link_executable.
2939 (allocate_dynrelocs): Likewise.
2940 (_bfd_sparc_elf_relocate_section): Fix formatting and tidy up.
2941 <R_SPARC_TLS_GD_HI22>: Merge into...
2942 <R_SPARC_TLS_GD_LO10>: ...this. Adjust 4th argument in call to
2943 sparc_elf_tls_transition and remove redundant code.
2944 <R_SPARC_TLS_LDM_HI22>: Turn call to bfd_link_pic into call to
2945 !bfd_link_executable.
2946 <R_SPARC_TLS_LDO_HIX22>: Likewise.
2947 <R_SPARC_TLS_LE_HIX22>: Likewise. Tidy up.
2948 <R_SPARC_TLS_LDM_CALL>: Likewise.
2949 <R_SPARC_TLS_GD_CALL>: Likewise. Tidy up.
2950 <R_SPARC_TLS_GD_ADD>: Likewise.
2951 <R_SPARC_TLS_LDM_ADD>: Likewise.
2952 <R_SPARC_TLS_LDO_ADD>: Likewise.
2953 <R_SPARC_TLS_IE_LD>: Likewise.
2955 2018-02-06 Miloš Stojanović <milos.stojanovic@rt-rk.com>
2958 * elfxx-mips.c (_bfd_mips_elf_find_nearest_line): If the dwarf
2959 functions failed to find the function name, try the generic elf
2960 find function instead.
2962 2018-02-06 Sergio Durigan Junior <sergiodj@redhat.com>
2964 * coff-rs6000.c (xcoff_write_archive_contents_old): Use
2965 'memcpy' instead of 'strncpy' when writing the magic number.
2967 2018-02-06 Nick Clifton <nickc@redhat.com>
2970 * opncls.c (bfd_get_debug_link_info_1): Check the size of the
2971 section before attempting to read it in.
2972 (bfd_get_alt_debug_link_info): Likewise.
2974 2018-02-06 Paul Carroll <pcarroll@codesourcery.com>
2976 * bfd/dwarf2.c (find_abstract_name): Modified to return file and
2977 line information in addition to name, if they can be found.
2979 2018-02-05 Renlin Li <renlin.li@arm.com>
2982 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Relax the
2983 R_AARCH64_ABS32 and R_AARCH64_ABS16 for absolute symbol. Apply the
2984 check for writeable section as well.
2986 2018-02-05 H.J. Lu <hongjiu.lu@intel.com>
2989 * elf32-i386.c (elf_i386_check_relocs): Set got_referenced if
2990 _GLOBAL_OFFSET_TABLE_ is referenced or GOT is needed to resolve
2991 undefined weak symbol to 0.
2992 * elf64-x86-64.c (elf_x86_64_check_relocs): Set got_referenced
2993 if _GLOBAL_OFFSET_TABLE_ is referenced.
2994 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Check
2995 got_referenced instead of ref_regular_nonweak. Remove the
2996 unused _GLOBAL_OFFSET_TABLE_ from symbol table.
2997 * elfxx-x86.h (elf_x86_link_hash_table): Add got_referenced.
2999 2018-02-05 Maciej W. Rozycki <macro@mips.com>
3001 * elfnn-riscv.c (_bfd_riscv_relax_pc): Use `memset' to
3002 initialize `hi_reloc'.
3004 2018-02-05 Maciej W. Rozycki <macro@mips.com>
3006 * elfxx-mips.c (_bfd_mips_elf_section_processing): For
3007 SHT_MIPS_REGINFO sections don't assert the correct size and
3008 report an error instead.
3010 2018-02-05 Maciej W. Rozycki <macro@mips.com>
3012 * elf.c (_bfd_elf_write_object_contents): Propagate a failure
3013 status from `->elf_backend_section_processing'.
3015 2018-02-02 Jim Wilson <jimw@sifive.com>
3018 * elfnn-riscv.c (riscv_relax_delete_bytes): New parameter link_info.
3019 If link_info->wrap_hash, check for a duplicate symbol and ignore.
3020 (_bfd_riscv_relax_call, bfd_riscv_relax_lui, _bfd_riscv_relax_tls_le):
3021 Pass new argument to riscv_relax_delete_bytes.
3022 (_bfd_riscv_relax_align, _bfd_riscv_relax_delete): Likewise. Remove
3023 ATTRIBUTE_UNUSED from link_info parameter.
3025 2018-02-02 Alan Modra <amodra@gmail.com>
3027 * elf64-ppc.c (ppc64_elf_relocate_section): Don't relocate nops
3028 emitted for toc sequence optimization. Set and use "howto" later.
3030 2018-02-01 Simon Marchi <simon.marchi@ericsson.com>
3032 * elf64-ppc.c (ppc64_elf_archive_symbol_lookup): Avoid pointer
3033 arithmetic on NULL pointer.
3034 * elflink.c (_bfd_elf_archive_symbol_lookup,
3035 elf_link_add_archive_symbols): Likewise.
3037 2018-01-31 Michael Matz <matz@suse.de>
3039 * elflink.c (bfd_elf_define_start_stop): Fix check of
3042 2018-01-31 H.J. Lu <hongjiu.lu@intel.com>
3045 * elflink.c (bfd_elf_define_start_stop): Check if __start and
3046 __stop symbols are referenced by shared objects.
3048 2018-01-30 Alan Modra <amodra@gmail.com>
3051 * elf.c (_bfd_elf_map_sections_to_segments): Don't start a new
3052 segment when demand paged with lma on the same page. Test this
3053 before load/non-load, executable/non-executable,
3054 writable/non-writable tests and simplify. Delete bogus relro
3055 condition in writable/non-writable test. Delete outdated
3056 comment. Formatting.
3058 2018-01-30 Alan Modra <amodra@gmail.com>
3060 * elflink.c (bfd_elf_define_start_stop): Make __start and __stop
3063 2018-01-29 Alan Modra <amodra@gmail.com>
3066 * coffgen.c (coff_pointerize_aux): Ensure auxent tagndx is in
3067 range before converting to a symbol table pointer.
3069 2018-01-27 Nick Clifton <nickc@redhat.com>
3071 * po/ru.po: Updated Russian translation.
3073 2018-01-26 Alan Modra <amodra@gmail.com>
3075 * elflink.c (bfd_elf_define_start_stop): Override symbols when
3076 they are defined dynamically.
3078 2018-01-26 Alan Modra <amodra@gmail.com>
3080 * elf64-ppc.c (ppc64_elf_size_stubs): Iterate sizing when
3081 .branch_lt changes size.
3083 2018-01-25 Alan Modra <amodra@gmail.com>
3086 * elfcode.h (elf_object_p): Avoid integer overflow.
3088 2018-01-25 Eric Botcazou <ebotcazou@adacore.com>
3091 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
3092 Do a mere lookup of the __tls_get_addr symbol instead of adding it.
3095 2017-10-19 H.J. Lu <hongjiu.lu@intel.com>
3098 * elfxx-sparc.c (sparc_elf_tls_transition): Replace
3099 bfd_link_pic with !bfd_link_executable, !bfd_link_pic with
3100 bfd_link_executable for TLS check.
3101 (_bfd_sparc_elf_check_relocs): Likewise.
3102 (allocate_dynrelocs): Likewise.
3103 (_bfd_sparc_elf_relocate_section): Likewise.
3105 2018-01-24 Renlin Li <renlin.li@arm.com>
3107 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Add support for
3108 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
3109 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
3110 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
3111 BFD_RELOC_AARCH64_MOVW_PREL_G3.
3112 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
3113 (_bfd_aarch64_elf_resolve_relocation): Likewise.
3115 2018-01-24 Renlin Li <renlin.li@arm.com>
3117 * reloc.c: Add BFD_RELOC_AARCH64_MOVW_PREL_G0,
3118 BFD_RELOC_AARCH64_MOVW_PREL_G0_NC, BFD_RELOC_AARCH64_MOVW_PREL_G1,
3119 BFD_RELOC_AARCH64_MOVW_PREL_G1_NC, BFD_RELOC_AARCH64_MOVW_PREL_G2,
3120 BFD_RELOC_AARCH64_MOVW_PREL_G2_NC, BFD_RELOC_AARCH64_MOVW_PREL_G3.
3121 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add entries for
3122 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
3123 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
3124 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
3125 BFD_RELOC_AARCH64_MOVW_PREL_G3.
3126 * bfd-in2.h: Regenerate.
3127 * libbfd.h: Regenerate.
3129 2018-01-23 Maciej W. Rozycki <macro@mips.com>
3131 * elfxx-mips.c (_bfd_mips_elf_final_link): Update a stale
3132 `mips_elf32_section_processing' comment reference.
3134 2018-01-20 H.J. Lu <hongjiu.lu@intel.com>
3137 * elfxx-x86.c (_bfd_x86_elf_link_check_relocs): Check the
3138 versioned __tls_get_addr symbol.
3140 2018-01-19 Nick Clifton <nickc@redhat.com>
3142 * po/fr.po: Updated French translation.
3144 2018-01-18 Alan Modra <amodra@gmail.com>
3146 * elf32-ppc.c (ppc_elf_create_glink): Correct alignment of .glink.
3147 * elf64-ppc.c (ppc64_elf_size_stubs): Handle negative plt_stub_align.
3148 (ppc64_elf_build_stubs): Likewise.
3150 2018-01-17 Nick Clifton <nickc@redhat.com>
3152 * po/ru.po: Updated Russian translation.
3153 * po/uk/po: Updated Ukranian translation.
3155 2018-01-17 Alan Modra <amodra@gmail.com>
3157 * elf64-ppc.c (ppc64_elf_build_stubs): Silence gcc warning.
3159 2018-01-17 Alan Modra <amodra@gmail.com>
3161 * elf32-ppc.c (GLINK_ENTRY_SIZE): Handle speculation barrier.
3162 (CRSETEQ, BEQCTRM): Define.
3163 (is_nonpic_glink_stub): Don't check bctr.
3164 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
3165 (ppc_elf_relax_section): Size speculation barrier.
3166 (output_bctr): New function.
3167 (write_glink_stub): Use output_bctr.
3168 (ppc_elf_relocate_section): Use output_bctr for long branch stub.
3169 (ppc_elf_finish_dynamic_symbol): Likewise.
3170 (ppc_elf_finish_dynamic_sections): Use output_bctr.
3171 * elf32-ppc.h (struct ppc_elf_params): Add speculate_indirect_jumps.
3172 * elf64-ppc.c (CRSETEQ, BEQCTRM, BEQCTRLM): Define.
3173 (GLINK_PLTRESOLVE_SIZE): Size speculation barrier.
3174 (size_global_entry_stubs): Handle speculation barrier sizing.
3175 (plt_stub_size): Likewise.
3176 (output_bctr): New function.
3177 (build_plt_stub, build_tls_get_addr_stub): Output speculation
3179 (ppc_build_one_stub): Likewise for ppc_stub_plt_branch.
3180 (ppc_size_one_stub): Size speculation barrier in ppc_stub_plt_branch.
3181 (build_global_entry_stubs): Output speculation barrier.
3182 (ppc64_elf_build_stubs): Likewise in __glink_PLTresolve stub.
3183 * elf64-ppc.h (struct ppc64_elf_params): Add speculate_indirect_jumps.
3185 2018-01-17 Alan Modra <amodra@gmail.com>
3187 * elf32-ppc.c (GLINK_ENTRY_SIZE): Add parameters, handle
3188 __tls_get_addr_opt, and alignment sizing.
3189 (TLS_GET_ADDR_GLINK_SIZE): Delete.
3190 (is_nonpic_glink_stub): Don't use GLINK_ENTRY_SIZE.
3191 (ppc_elf_get_synthetic_symtab): Recognize stubs spaced at 4, 6,
3193 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
3194 (allocate_dynrelocs): Use new GLINK_ENTRY_SIZE.
3195 (ppc_elf_size_dynamic_sections): Likewise. Size branch table
3197 (write_glink_stub): Handle __tls_get_addr_opt stub.
3198 Pad out to size given by GLINK_ENTRY_SIZE.
3199 (ppc_elf_relocate_section): Adjust write_glink_stub call.
3200 (ppc_elf_finish_dynamic_symbol): Likewise.
3201 (ppc_elf_finish_dynamic_sections): Write PLTresolve without using
3202 insn array since so many need rewriting.
3203 * elf32-ppc.h (struct ppc_elf_params): Add plt_stub_align.
3204 * elf64-ppc.c (GLINK_PLTRESOLVE_SIZE): Rename from
3205 GLINK_CALL_STUB_SIZE. Add htab param and evaluate to size without
3206 nops. Adjust all uses.
3207 (ppc64_elf_get_synthetic_symtab): Don't use GLINK_CALL_STUB_SIZE
3208 in glink_vma calculation.
3209 (struct ppc_link_hash_table): Add global_entry section pointer.
3210 (create_linkage_sections): Create separate section for global
3212 (PPC_LO, PPC_HI, PPC_HA): Move earlier.
3213 (size_global_entry_stubs): Handle sizing for aligned stubs.
3214 (ppc64_elf_size_dynamic_sections): Handle global_entry alloc,
3215 and don't stash end of glink branch table in rawsize.
3216 (ppc_build_one_stub): Rewrite stub size calculations.
3217 (build_global_entry_stubs): Use new section.
3218 (ppc64_elf_build_stubs): Don't pad __glink_PLTresolve with nops.
3219 Build lazy link stubs out to end of section. Build global entry
3220 stubs in new section.
3222 2018-01-15 Nick Clifton <nickc@redhat.com>
3224 * po/uk.po: Updated Ukranian translation.
3226 2018-01-13 Nick Clifton <nickc@redhat.com>
3228 * po/bfd.pot: Regenerated.
3230 2018-01-13 Nick Clifton <nickc@redhat.com>
3232 * version.m4: Bump version to 2.30.51
3233 * configure: Regenerate.
3235 2018-01-13 Nick Clifton <nickc@redhat.com>
3237 2.30 branch created.
3239 2018-01-12 Jens Widell <jl@opera.com>
3241 * elf.c (setup_group): Optimize search for group by remembering
3242 last found group and restarting search at that index.
3243 * elf-bfd.h (struct elf_obj_tdata): Add group_search_offset field.
3245 2018-01-12 Gunther Nikl <gnikl@users.sourceforge.net>
3247 * aoutx.h (aout_link_check_ar_symbols): Remove default and handle
3248 bfd_link_common_skip_none in switch.
3250 2018-01-12 Alan Modra <amodra@gmail.com>
3253 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Ignore dynamic
3254 references on forced local symbols.
3256 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
3258 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
3259 .reginfo section has wrong size.
3261 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
3264 * elf.c (_bfd_elf_map_sections_to_segments): When generating
3265 separate code and read-only data LOAD segments, create a new
3266 LOAD segment if the previous section contains text and the
3267 current section doesn't or vice versa. Don't put a writable
3268 section in a read-only segment if there is a RELRO segment.
3270 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
3273 * elflink.c (bfd_elf_gc_mark_dynamic_ref_symbol): Ignore dynamic
3274 references on forced local symbols.
3276 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
3279 * elflink.c (bfd_elf_gc_sections): Keep all PREINIT_ARRAY,
3280 INIT_ARRAY as well as FINI_ARRAY sections for ld -r --gc-section.
3282 2018-01-09 Kuan-Lin Chen <kuanlinchentw@gmail.com>
3285 * elf32-nds32.c (nds32_elf_relax_loadstore): Fix a typographical error.
3287 2018-01-03 John Baldwin <jhb@FreeBSD.org>
3289 * elf.c (elfcore_grok_freebsd_note): Handle
3290 NT_FREEBSD_PROCSTAT_PROC, NT_FREEBSD_PROCSTAT_FILES, and
3291 NT_FREEBSD_PROCSTAT_VMMAP.
3293 2018-01-03 Alan Modra <amodra@gmail.com>
3295 Update year range in copyright notice of all files.
3297 For older changes see ChangeLog-2017
3299 Copyright (C) 2018 Free Software Foundation, Inc.
3301 Copying and distribution of this file, with or without modification,
3302 are permitted in any medium without royalty provided the copyright
3303 notice and this notice are preserved.
3309 version-control: never