1 2018-06-25 Nick Clifton <nickc@redhat.com>
3 * elfnn-aarch64.c (_bfd_aarch64_erratum_835769_stub_name): Check
4 for malloc returning NULL.
5 (_bfd_aarch64_erratum_843419_fixup): Check for
6 _bfd_aarch64_erratum_835769_stub_name returning NULL.
8 2018-06-24 Nick Clifton <nickc@redhat.com>
10 * po/bfd.pot: Regenerate.
12 2018-06-24 Nick Clifton <nickc@redhat.com>
14 * version.m4: Update version string to 2.31.51.
15 * configure: Regenerate.
17 2018-06-24 Nick Clifton <nickc@redhat.com>
21 2018-06-21 Maciej W. Rozycki <macro@mips.com>
23 * elfxx-mips.c (_bfd_mips_elf_compact_eh_encoding)
24 (_bfd_mips_elf_cant_unwind_opcode): Correct formatting.
26 2018-06-21 Maciej W. Rozycki <macro@mips.com>
28 * elfxx-mips.c (_bfd_mips_post_process_headers): Keep
29 EI_ABIVERSION setting together.
31 2018-06-21 Maciej W. Rozycki <macro@mips.com>
33 * elfxx-mips.c (MIPS_LIBC_ABI_DEFAULT, MIPS_LIBC_ABI_MIPS_PLT)
34 (MIPS_LIBC_ABI_UNIQUE, MIPS_LIBC_ABI_MIPS_O32_FP64)
35 (MIPS_LIBC_ABI_MAX): New enumeration constants.
36 (_bfd_mips_post_process_headers): Use them in place of magic
39 2018-06-21 Jim Wilson <jimw@sifive.com>
41 * elfnn-riscv.c (riscv_elf_finish_dynamic_symbol): Update comment.
42 Use SYMBOL_REFERENCES_LOCAL. Add asserts for h->got.offset.
44 2018-06-21 Alan Modra <amodra@gmail.com>
46 * doc/Makefile.am (AUTOMAKE_OPTIONS): Add "foreign".
47 * doc/Makefile.in: Regenerate.
49 2018-06-20 Renlin Li <renlin.li@arm.com>
51 * elfxx-aarch64.c (_bfd_aarch64_elf_resolve_relocation): Use PG_OFFSET
52 to resolve BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12_NC,
53 BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12_NC,
54 BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12_NC,
55 BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12_NC,
56 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
57 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
58 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
59 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
61 2018-06-20 Nick Clifton <nickc@redhat.com>
64 * opncls.c (get_build_id): Check for a negative or excessive data
65 size in the build-id note.
67 2018-06-20 Nick Clifton <nickc@redhat.com>
70 * mach-o.c (cputype): New function.
71 (cpusubtype): New function.
72 (bfd_mach_o_bfd_print_private_data): New function. Dispalys the
73 values in the MACH-O file header.
74 (bfd_mach_o_bfd_copy_private_header_data): Copy the cputype and
75 cpusubtype fields from the input bfd's mach-o header to the output
77 * mach-o-target.c (bfd_mach_o_bfd_print_private_bfd_data):
78 Redefine to bfd_mach_o_bfd_print_private_data.
79 * mach-o.h (bfd_mach_o_bfd_print_private_bfd_data): Prototype.
81 2018-06-19 Maciej W. Rozycki <macro@mips.com>
84 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Verify the
85 `.got.plt' entry referred is in range.
86 (mips_finish_exec_plt): Correct the range check for `.got.plt'
87 start. Replace the assertion used for that with a proper error
90 2018-06-19 Maciej W. Rozycki <macro@mips.com>
92 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Fix
95 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
97 * Makefile.am (AUTOMAKE_OPTIONS): Remove 1.11.
98 (INCLUDES): Rename to ...
99 (AM_CPPFLAGS): ... this.
100 * configure.ac: Remove AC_PREREQ.
101 * doc/Makefile.am (AUTOMAKE_OPTIONS): Remove 1.9, cygnus, add
102 info-in-builddir no-texinfo.tex.
103 (info_TEXINFOS): Rename bfd.texinfo to bfd.texi.
104 * doc/bfd.texinfo: Rename to ...
105 * doc/bfd.texi: ... this.
106 * Makefile.in: Re-generate.
107 * aclocal.m4: Re-generate.
108 * config.in: Re-generate.
109 * configure: Re-generate.
110 * doc/Makefile.in: Re-generate.
112 2018-06-18 Mephi <mephi42@gmail.com>
115 * mach-o-x86-64.c (x86_64_howto_table): Add entry for
116 BFD_RELOC_MACH_O_X86_64_RELOC_TLV.
117 (bfd_mach_o_x86_64_canonicalize_one_reloc): Handle the new reloc.
118 (bfd_mach_o_x86_64_swap_reloc_out): Likewise.
119 * reloc.c (BFD_RELOC_MACH_O_X86_64_TV): New entry.
120 * bfd-in2.h: Regenerate.
121 * libbfd.h: Regenerate.
123 2018-06-14 Faraz Shahbazker <Faraz.Shahbazker@mips.com>
125 * elfxx-mips.c (print_mips_ases): Add GINV extension.
127 2018-06-14 H.J. Lu <hongjiu.lu@intel.com>
130 * elf.c (_bfd_elf_get_symbol_version_string): Check if the first
131 symbol version is base version.
133 2018-06-14 Alan Modra <amodra@gmail.com>
135 * elf-bfd.h (struct elf_link_hash_table): Add "dynamic_relocs".
136 * elflink.c (_bfd_elf_init_2_index_sections): Comment fix.
137 (_bfd_elf_add_dynamic_entry): Set "dynamic_relocs".
138 (_bfd_elf_link_renumber_dynsyms): Exclude all section symbols when
139 "dynamic_relocs" is not set.
140 * elfxx-mips.c (count_section_dynsyms): Likewise.
142 2018-06-14 Alan Modra <amodra@gmail.com>
145 * bfdio.c (bfd_seek): Optimize away seeks to current position.
147 2018-06-13 Scott Egerton <scott.egerton@imgtec.com>
148 Faraz Shahbazker <Faraz.Shahbazker@mips.com>
150 * elfxx-mips.c (print_mips_ases): Add CRC.
152 2018-06-08 H.J. Lu <hongjiu.lu@intel.com>
155 * elfxx-x86.c (elf_x86_hide_linker_defined): New function.
156 (_bfd_x86_elf_link_check_relocs): Use it to hide hidden
157 __bss_start, _end and _edata in shared libraries.
159 2018-06-07 Alan Modra <amodra@gmail.com>
161 * elf32-tic6x.c (elf32_tic6x_check_relocs): Reference
162 __c6xabi_DSBT_BASE explicitly for R_C6000_SBR_* relocs.
164 2018-06-05 Alan Modra <amodra@gmail.com>
166 * bfd.c (struct bfd): Update comment on "where" usage.
167 * bfdio.c (bfd_bwrite, bfd_stat): Use and update "iovec",
168 "iostream", and "where" from containing archive file. Return
170 (bfd_bread): Similarly, and return error attempted out of
171 bounds archive element access.
172 (bfd_tell, bfd_flush): Use and update "iovec", "iostream", and
173 "where" from containing archive file.
174 (bfd_seek): Likewise. Return error on NULL iovec. Don't
175 attempt to optimize away seeks. Don't paper over errors by
177 (bfd_get_mtime): Call bfd_stat rather than iovec->bstat.
178 (bfd_get_size): Likewise.
179 (bfd_mmap): Operate on and use iovec of containing archive
180 file. Return error on NULL iovec.
181 * cache.c (bfd_cache_lookup_worker): Abort if working on
183 (cache_bread_1): Delete bfd parameter, add FILE* parameter.
184 Don't ignore zero byte reads.
185 (cache_bread): Look up FILE* in cache here. Error on NULL
187 (cache_bwrite): Rename "where" to "from".
188 (cache_bmmap): Don't handle archive elements.
189 * coffcode.h (coff_slurp_line_table): Exit early on zero
191 * bfd-in2.h: Regenerate.
193 2018-06-05 Alan Modra <amodra@gmail.com>
196 * plugin.c (bfd_plugin_open_input): Allow for possibility of
197 nested archives. Open file again for plugin.
198 (try_claim): Don't save and restore file position. Close file
200 * sysdep.h (O_BINARY): Define.
202 2018-06-04 Max Filippov <jcmvbkbc@gmail.com>
204 * elf32-xtensa.c (xtensa_read_table_entries): Make global.
205 (compute_fill_extra_space): Drop declaration. Rename function to
206 xtensa_compute_fill_extra_space.
207 (compute_ebb_actions, remove_dead_literal): Update references to
208 compute_fill_extra_space.
210 2018-06-04 Volodymyr Arbatov <arbatov@cadence.com>
212 * elf32-xtensa.c (elf32xtensa_separate_props): New global
214 (xtensa_add_names): New function.
215 (xtensa_property_section_name): Add new parameter
216 separate_sections, use it to choose property section name.
217 (xtensa_get_separate_property_section): New function.
218 (xtensa_get_property_section): Invoke
219 xtensa_get_separate_property_section to get individual property
220 section if it exists, common property section otherwise.
221 (xtensa_make_property_section): Pass elf32xtensa_separate_props
222 to xtensa_property_section_name.
224 2018-06-04 H.J. Lu <hongjiu.lu@intel.com>
227 * bfd-in.h: Include "diagnostics.h".
228 * bfd-in2.h: Regenerated.
229 * elf32-arm.c (elf32_arm_nabi_write_core_note): Use
230 DIAGNOSTIC_PUSH, DIAGNOSTIC_IGNORE_STRINGOP_TRUNCATION and
231 DIAGNOSTIC_POP to silence GCC 8.1 warnings with
232 -Wstringop-truncation.
233 * elf32-ppc.c (ppc_elf_write_core_note): Likewse.
234 * elf32-s390.c (elf_s390_write_core_note): Likewse.
235 * elf64-ppc.c (ppc64_elf_write_core_note): Likewse.
236 * elf64-s390.c (elf_s390_write_core_note): Likewse.
237 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewse.
239 2018-06-03 Jim Wilson <jimw@sifive.com>
242 * elfnn-riscv.c (riscv_elf_relocate_section) <R_RISCV_CALL>: Check
243 for and handle an undefined weak with no PLT.
246 * elfnn-riscv.c (riscv_relax_delete_bytes): Add versioned_hidden check
247 to code that ignores duplicate symbols.
249 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
251 * version.m4: Bump version to 2.30.52
252 * configure: Regenerated.
254 2018-06-01 Alan Modra <amodra@gmail.com>
256 * bfd.c (_bfd_error_handler): Arrange for this function to be
257 declared in bfd-in2.h.
258 * libbfd-in.h (_bfd_error_handler): Don't declare.
259 * libbfd.h: Regenerate.
260 * bfd-in2.h: Regenerate.
262 2018-05-30 Amaan Cheval <amaan.cheval@gmail.com>
264 * config.bfd (x86_64-*-*): Add pei-x86-64 target to x86_64-*-rtems*
265 This is needed to generate UEFI application image files from ELFs.
267 2018-05-28 H.J. Lu <hongjiu.lu@intel.com>
269 * elf32-i386.c (elf_i386_lazy_plt): Add plt_tlsdesc_entry,
270 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
271 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
272 plt_tlsdesc_got2_insn_end for TLSDESC entry.
273 (elf_i386_lazy_ibt_plt): Likewise.
274 (elf_i386_nacl_plt): Likewise.
275 * elf64-x86-64.c (tlsdesc_plt_entry): Moved and renamed to ...
276 (elf_x86_64_tlsdesc_plt_entry): This.
277 (elf_x86_64_lazy_plt): Add plt_tlsdesc_entry,
278 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
279 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
280 plt_tlsdesc_got2_insn_end for TLSDESC entry.
281 (elf_x86_64_lazy_bnd_plt): Likewise.
282 (elf_x86_64_lazy_ibt_plt): Likewise.
283 (elf_x32_lazy_ibt_plt): Likewise.
284 (elf_x86_64_nacl_plt): Likewise.
285 (elf_x86_64_finish_dynamic_sections): Use plt_tlsdesc_entry,
286 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
287 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
288 plt_tlsdesc_got2_insn_end to update TLSDESC entry.
289 * elfxx-x86.h (elf_x86_lazy_plt_layout): Update comments.
290 Add plt_tlsdesc_entry, plt_tlsdesc_entry_size,
291 plt_tlsdesc_got1_offset, plt_tlsdesc_got2_offset,
292 plt_tlsdesc_got1_insn_end and plt_tlsdesc_got2_insn_end.
293 (elf_x86_non_lazy_plt_layout): Update comments.
294 (elf_x86_plt_layout): Likewise.
296 2018-05-28 H.J. Lu <hongjiu.lu@intel.com>
299 * elf-s390-common.c (elf_s390_add_symbol_hook): Removed.
300 * elf32-arc.c (elf_arc_add_symbol_hook): Likewise.
301 (elf_backend_add_symbol_hook): Likewise.
302 * elf32-m68k.c (elf_m68k_add_symbol_hook): Likewise.
303 (elf_backend_add_symbol_hook): Likewise.
304 * elf32-s390.c (elf_backend_add_symbol_hook): Likewise.
305 * elf32-sparc.c (elf32_sparc_add_symbol_hook): Likewise.
306 (elf_backend_add_symbol_hook): Likewise.
307 * elf64-s390.c (elf_backend_add_symbol_hook): Likewise.
308 * elfxx-aarch64.c (_bfd_aarch64_elf_add_symbol_hook): Likewise.
309 * elfxx-aarch64.h (_bfd_aarch64_elf_add_symbol_hook): Likewise.
310 (elf_backend_add_symbol_hook): Likewise.
311 * elf32-arm.c (elf32_arm_add_symbol_hook): Remove STT_GNU_IFUNC
313 * elf32-ppc.c (ppc_elf_add_symbol_hook): Likewise.
314 * elf64-ppc.c (ppc64_elf_add_symbol_hook): Likewise.
315 * elf64-sparc.c (elf64_sparc_add_symbol_hook): Likewise.
316 * elflink.c (elf_link_add_object_symbols): Set
317 elf_gnu_symbol_ifunc for STT_GNU_IFUNC symbols.
319 2018-05-26 H.J. Lu <hongjiu.lu@intel.com>
322 * elf-bfd.h (_bfd_elf_link_hide_sym_by_version): New.
323 * elflink.c (_bfd_elf_link_hide_versioned_symbol): New function.
324 Extracted from _bfd_elf_link_assign_sym_version.
325 (_bfd_elf_link_hide_sym_by_version): New function.
326 (_bfd_elf_link_assign_sym_version): Use
327 _bfd_elf_link_hide_versioned_symbol.
328 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Call
329 _bfd_elf_link_hide_sym_by_version instead of
330 bfd_hide_sym_by_version. Don't check unversioned symbol.
332 2018-05-25 Alan Modra <amodra@gmail.com>
334 * Makefile.in: Regenerate.
335 * po/SRC-POTFILES.in: Regenerate.
337 2018-05-25 Alan Modra <amodra@gmail.com>
339 * configure.ac (bfd_cv_hidden): Run test with -Werror in CFLAGS.
340 * configure: Regenerate.
342 2018-05-23 H.J. Lu <hongjiu.lu@intel.com>
344 * elf64-ppc.c (ppc64_elf_write_core_note): Add ATTRIBUTE_NONSTRING
347 2018-05-22 Alan Modra <amodra@gmail.com>
350 * elf32-hppa.c (hppa_get_stub_entry): Return NULL when link_sec
352 (elf32_hppa_size_stubs): Only create stubs for load, alloc, code
354 (final_link_relocate): Revert last change.
356 2018-05-22 Alan Modra <amodra@gmail.com>
359 * elf32-hppa.c (final_link_relocate): Don't look for plt call
360 stubs in non-alloc sections.
362 2018-05-21 H.J. Lu <hongjiu.lu@intel.com>
365 * aout-target.h (MY_bfd_link_hide_symbol): New.
366 * aout-tic30.c (MY_bfd_link_hide_symbol): Likewise.
367 * binary.c (binary_bfd_link_hide_symbol): Likewise.
368 * coff-alpha.c (_bfd_ecoff_bfd_link_hide_symbol): Likewise.
369 * coff-mips.c (_bfd_ecoff_bfd_link_hide_symbol): Likewise.
370 * coff-rs6000.c (_bfd_xcoff_bfd_link_hide_symbol): Likewise.
371 * coffcode.h (coff_bfd_link_hide_symbol): Likewise.
372 * elf-bfd.h (_bfd_elf_link_hide_symbol): Likewise.
373 * elfxx-target.h (bfd_elfNN_bfd_link_hide_symbol): Likewise.
374 * i386msdos.c (msdos_bfd_link_hide_symbol): Likewise.
375 * ihex.c (ihex_bfd_link_hide_symbol): Likewise.
376 * libbfd-in.h (_bfd_nolink_bfd_link_hide_symbol): Likewise.
377 * linker.c (_bfd_generic_link_hide_symbol): Likewise.
378 (bfd_link_hide_symbol): Likewise.
379 * mach-o-target.c (bfd_mach_o_bfd_link_hide_symbol): Likewise.
380 * mmo.c (mmo_bfd_link_hide_symbol): Likewise.
381 * pef.c (bfd_pef_bfd_link_hide_symbol): Likewise.
382 * plugin.c (bfd_plugin_bfd_link_hide_symbol): Likewise.
383 * ppcboot.c (ppcboot_bfd_link_hide_symbol): Likewise.
384 * som.c (som_bfd_link_hide_symbol): Likewise.
385 * srec.c (srec_bfd_link_hide_symbol): Likewise.
386 * tekhex.c (tekhex_bfd_link_hide_symbol): Likewise.
387 * vms-alpha.c (vms_bfd_link_hide_symbol): Likewise.
388 (alpha_vms_bfd_link_hide_symbol): Likewise.
389 * xsym.c (bfd_sym_bfd_link_hide_symbol): Likewise.
390 * coff64-rs6000.c (rs6000_xcoff64_vec): Add
391 _bfd_generic_link_hide_symbol.
392 (rs6000_xcoff64_aix_vec): Likewise.
393 * elflink.c (bfd_elf_record_link_assignment): Don't make forced
394 local symbol dynamic.
395 (_bfd_elf_link_hide_symbol): New function.
396 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
397 check root.ldscript_def.
398 * targets.c (bfd_target): Add _bfd_link_hide_symbol.
399 (BFD_JUMP_TABLE_LINK): Add NAME##_bfd_link_hide_symbol.
400 * bfd-in2.h: Regenerated.
401 * libbfd.h: Likewise.
403 2018-05-21 H.J. Lu <hongjiu.lu@intel.com>
406 * elf.c (setup_group): Mark section in a section group with
409 2018-05-18 H.J. Lu <hongjiu.lu@intel.com>
412 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
413 set eh->local_ref to 1 if a symbol is versioned and there is a
416 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
418 * elfnn-riscv.c (_bfd_riscv_elf_merge_private_bfd_data): Handle
421 2018-05-18 Jim Wilson <jimw@sifive.com>
423 * elfnn-riscv.c (allocate_dynrelocs): Discard dynamic relocations if
424 UNDEFWEAK_NO_DYNAMIC_RELOC is true.
425 (riscv_elf_relocate_section): Don't generate dynamic relocation if
426 UNDEFWEAK_NO_DYNAMIC_RELOC is true.
427 (riscv_elf_finish_dynamic_symbol): Likewise.
429 2018-05-18 John Darrington <john@darrington.wattle.id.au>
431 * Makefile.am: Add s12z files.
432 * Makefile.in: Regenerate.
433 * archures.c: Add bfd_s12z_arch.
434 * bfd-in.h: Add exports of bfd_putb24 and bfd_putl24.
435 * bfd-in2.h: Regenerate.
436 * config.bfd: Add s12z target.
437 * configure.ac: Add s12z target.
438 * configure: Regenerate.
439 * cpu-s12z.c: New file.
440 * elf32-s12z.c: New file.
441 * libbfd.c (bfd_putb24): New function.
442 (bfd_putl24): New function.
443 * libbfd.h: Regenerate.
444 * reloc.c: Add s12z relocations.
445 (bfd_get_reloc_size): Handle size 5 relocs.
446 * targets.c: Add s12z_elf32_vec.
448 2018-05-18 H.J. Lu <hongjiu.lu@intel.com>
451 * elf32-i386.c (elf_i386_relocate_section): Handle R_386_GOT32X
453 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
454 set eh->local_ref to 1 for linker defined symbols.
456 2018-05-18 Alan Modra <amodra@gmail.com>
459 * elf.c (setup_group): Formatting. Check that SHT_GROUP entries
460 don't point at other SHT_GROUP sections. Set shdr corresponding
461 to invalid entry, to NULL rather than section 0. Identify
462 SHT_GROUP section index when reporting an error. Cope with NULL
465 2018-05-18 Alan Modra <amodra@gmail.com>
467 * libbfd-in.h (ATTRIBUTE_HIDDEN): Define and use throughout.
468 * configure.ac (HAVE_HIDDEN): Check compiler support for hidden
470 * libbfd.h: Regenerate.
471 * configure: Regenerate.
472 * config.in: Regenerate.
474 2018-05-18 Alan Modra <amodra@gmail.com>
476 * libbfd-in.h: Add include guard.
477 * libcoff-in.h: Likewise.
478 * doc/Makefile.am (libbfd.h, libcoff.h): Append another #endif.
479 * doc/Makefile.in: Regenerate.
480 * libbfd.h: Regenerate.
481 * libcoff.h: Regenerate.
483 2018-05-16 Maciej W. Rozycki <macro@mips.com>
485 * elf32-nds32.c (nds32_convert_32_to_16): Preset `insn_type'.
487 2018-05-16 Alan Modra <amodra@gmail.com>
490 * format.c (struct bfd_preserve): Add section_id.
491 (bfd_preserve_save, bfd_preserve_restore): Save and restore
493 (bfd_reinit): Set _bfd_section_id.
494 (bfd_check_format_matches): Put all matches of any priority into
495 matching_vector. Save initial section id and start each attempted
496 match at that section id.
497 * libbfd-in.h (_bfd_section_id): Declare.
498 * section.c (_bfd_section_id): Rename from section_id and make
500 (bfd_get_next_section_id): Delete.
501 * elf64-ppc.c (ppc64_elf_setup_section_lists): Replace use of
502 bfd_get_section_id with _bfd_section_id.
503 * libbfd.h: Regenerate.
504 * bfd-in2.h: Regenerate.
506 2018-05-15 Christophe Guillon <christophe.guillon@st.com>
508 * coffcode.h (coff_bigobj_swap_aux_in): Make sure that all fields
509 of the aux structure are initialised.
511 2018-05-15 Francois H. Theron <francois.theron@netronome.com>
513 * targets.c: Wrap nfp_elf64_vec in BFD64 ifdef.
515 2018-05-15 Nick Clifton <nickc@redhat.com>
517 * po/pt.po: New Portuguese translation.
518 * configure.ac (ALL_LINGUAS): Add pt.
519 * configure: Regenerate.
521 2018-05-14 H.J. Lu <hongjiu.lu@intel.com>
524 * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Don't issue
525 an error on IFUNC pointer defined in PDE.
526 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Call
527 _bfd_x86_elf_link_fixup_ifunc_symbol.
528 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
529 * elfxx-x86.c (_bfd_x86_elf_link_fixup_ifunc_symbol): New
531 * elfxx-x86.h (_bfd_x86_elf_link_fixup_ifunc_symbol): New.
533 2018-05-14 H.J. Lu <hongjiu.lu@intel.com>
536 * elfxx-x86.c (elf_x86_linker_defined): New function.
537 (_bfd_x86_elf_link_check_relocs): Use it to mark __bss_start,
538 _end and _edata locally defined within executables.
540 2018-05-12 Alan Modra <amodra@gmail.com>
543 * elf.c (rewrite_elf_program_header): Use segment_mark only for
544 PT_LOAD headers. Delete first_matching_lma and first_suggested_lma.
545 Instead make matching_lma and suggested_lma pointers to the
546 sections. Align section vma and lma calculated from segment.
547 Don't clear includes_phdrs or includes_filehdr based on p_paddr
548 test. Try to handle alignment padding before first section by
549 adjusting new segment lma down. Adjust PT_PHDR map p_paddr.
551 2018-05-09 Dimitar Dimitrov <dimitar@dinux.eu>
553 * elf32-pru.c (pru_elf32_do_ldi32_relocate): Make LDI32 relocation
554 conformant to TI ABI.
555 (pru_elf32_relax_section): Likewise.
556 (pru_elf_relax_delete_bytes): Fix offsets for new LDI32 code.
557 * elf32-pru.c (pru_elf32_do_ldi32_relocate): Ignore addend.
558 (pru_elf32_pmem_relocate): Trap - should not get here.
559 (pru_elf32_relocate_section): Add support for REL relocations.
560 (elf_info_to_howto_rel): Enable REL.
561 (elf_backend_may_use_rel_p): Likewise.
562 (elf_backend_may_use_rela_p): Likewise.
563 (elf_backend_default_use_rela_p): Likewise.
565 2018-05-09 Alan Modra <amodra@gmail.com>
568 * peXXigen.c (pe_print_edata): Correct minimum size.
570 2018-05-09 Alan Modra <amodra@gmail.com>
573 * peXXigen.c (pe_print_idata): Bound check hint_addr.
575 2018-05-08 Nick Clifton <nickc@redhat.com>
578 * elf.c (bfd_elf_get_str_section): Check for an excessively large
580 * elf-attrs.c (_bfd_elf_parse_attributes): Issue an error if the
581 attribute section is larger than the size of the file.
583 2018-05-07 Alan Modra <amodra@gmail.com>
585 * cofflink.c (_bfd_coff_link_input_bfd): Use memcmp rather than
586 strncmp when checking for ".bf" special symbol.
587 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Make pe_required_section_flags
588 section name a char array, remove sentinal known_sections entry,
589 and adjust loop over known_sections to suit. Use memcmp rather
592 2018-05-04 Alan Modra <amodra@gmail.com>
594 * elf-linux-core.h (struct elf_external_linux_prpsinfo32_ugid32),
595 (struct elf_external_linux_prpsinfo32_ugid16),
596 (struct elf_external_linux_prpsinfo64_ugid32),
597 (struct elf_external_linux_prpsinfo64_ugid16): Add ATTRIBUTE_NONSTRING
598 to pr_fname and pr_psargs fields. Remove GCC diagnostic pragmas.
600 * elf.c (elfcore_write_prpsinfo): ..here. Indent nested preprocessor
602 * elf32-arm.c (elf32_arm_nabi_write_core_note): Add ATTRIBUTE_NONSTRING
604 * elf32-ppc.c (ppc_elf_write_core_note): Likewise.
605 * elf32-s390.c (elf_s390_write_core_note): Likewise.
606 * elf64-s390.c (elf_s390_write_core_note): Likewise.
607 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewise.
608 * elf64-x86-64.c (elf_x86_64_write_core_note): Add GCC diagnostic
610 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Use strnlen to avoid
611 false positive gcc-8 warning.
612 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
614 2018-05-04 Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
616 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Fix the order
617 of arguments when warning about different long double types.
619 2018-05-03 Simon Atanasyan <simon@atanasyan.com>
621 * elf32-mips.c: (elf32_mips_fixup_symbol): New function.
622 (elf_backend_fixup_symbol): New macro.
623 * elfxx-mips.c: (mips_elf_output_extsym): Discard _gp_disp
625 (_bfd_mips_elf_finish_dynamic_symbol): Likewise.
627 2018-04-30 Francois H. Theron <francois.theron@netronome.com>
629 * Makefile.am: Added NFP files to build.
630 * archures.c: Added bfd_arch_nfp
631 * config.bfd: Added NFP support.
632 * configure.ac: Added NFP support.
633 * cpu-nfp.c: New, for NFP support.
634 * elf-bfd.h: Added elf_section_info()
635 * elf64-nfp.c: New, for NFP support.
636 * po/SRC-POTFILES.in: Added NFP source files.
637 * targets.c: Added nfp_elf64_vec
638 * bfd-in2.h: Regenerate.
639 * Makefile.in: Regenerate.
640 * configure: Regenerate.
642 2018-04-27 Alan Modra <amodra@gmail.com>
644 * bfd-in2.h: Regenerate.
645 * libbfd.h: Regenerate.
647 2018-04-27 Alan Modra <amodra@gmail.com>
651 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Don't drop plt
653 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Comment fixes.
655 2018-04-26 Pedro Alves <palves@redhat.com>
657 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Don't consider
658 ifunc and non-ifunc symbols duplicates.
660 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
661 Mickaël Guêné <mickael.guene@st.com>
663 * elf32-arm.c (elf32_arm_fdpic_thumb_plt_entry): New.
664 (elf32_arm_plt_needs_thumb_stub_p): Handle thumb-only case.
665 (elf32_arm_populate_plt_entry): Likewise.
666 (elf32_arm_output_plt_map_1): Likewise.
667 (elf32_arm_output_arch_local_syms): Likewise.
669 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
670 Mickaël Guêné <mickael.guene@st.com>
672 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Handle
673 _GLOBAL_OFFSET_TABLE_ in FDPIC mode.
675 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
676 Mickaël Guêné <mickael.guene@st.com>
678 * elf32-arm.c (bfd_elf32_arm_set_target_params): Handle FDPIC case
681 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
682 Mickaël Guêné <mickael.guene@st.com>
684 * elf32-arm.c (DEFAULT_STACK_SIZE): New.
685 (elf32_arm_always_size_sections): Create stack segment.
687 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
688 Mickaël Guêné <mickael.guene@st.com>
690 * bfd-in2.h (BFD_RELOC_ARM_TLS_GD32_FDPIC)
691 (BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC): New
693 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_TLS_GD32_FDPIC,
694 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC relocations.
695 (elf32_arm_reloc_map): Add R_ARM_TLS_GD32_FDPIC,
696 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC.
697 (struct elf32_arm_link_hash_table): Update comment.
698 (elf32_arm_final_link_relocate): Handle TLS FDPIC relocations.
699 (IS_ARM_TLS_RELOC): Likewise.
700 (elf32_arm_check_relocs): Likewise.
701 (allocate_dynrelocs_for_symbol): Likewise.
702 (elf32_arm_size_dynamic_sections): Update comment.
703 * reloc.c: Add BFD_RELOC_ARM_TLS_GD32_FDPIC,
704 BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC.
706 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
707 Mickaël Guêné <mickael.guene@st.com>
709 * elf32-arm.c (elf32_arm_fdpic_plt_entry): New.
710 (elf32_arm_create_dynamic_sections): Handle FDPIC.
711 (elf32_arm_allocate_plt_entry): Likewise.
712 (elf32_arm_populate_plt_entry): Likewise.
713 (elf32_arm_output_plt_map_1): Likewise.
715 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
716 Mickaël Guêné <mickael.guene@st.com>
718 * elf32-arm.c (struct fdpic_local): New.
719 (elf_arm_obj_tdata): Add local_fdpic_cnts field.
720 (elf32_arm_local_fdpic_cnts): New.
721 (struct fdpic_global): New.
722 (elf32_arm_link_hash_entry): Add fdpic_cnts field.
723 (elf32_arm_link_hash_table): Add srofixup field.
724 (arm_elf_add_rofixup): New.
725 (arm_elf_fill_funcdesc): New.
726 (elf32_arm_link_hash_newfunc): Handle fdpic_cnts.
727 (elf32_arm_allocate_local_sym_info): Likewise.
728 (create_got_section): Create .rofixup section.
729 (elf32_arm_copy_indirect_symbol): Handle fdpic_cnts.
730 (bfd_elf32_arm_set_target_params): Handle FDPIC.
731 (elf32_arm_final_link_relocate): Likewise.
732 (elf32_arm_check_relocs): Likewise.
733 (allocate_dynrelocs_for_symbol): Likewise.
734 (elf32_arm_size_dynamic_sections): Likewise.
735 (elf32_arm_finish_dynamic_sections): Likewise.
736 (elf32_arm_output_arch_local_syms): Likewise.
737 (elf32_arm_fdpic_omit_section_dynsym): New.
739 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
740 Mickaël Guêné <mickael.guene@st.com>
742 * bfd-in2.c (BFD_RELOC_ARM_GOTFUNCDESC)
743 (BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC)
744 (BFD_RELOC_ARM_FUNCDESC_VALUE): New.
745 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_GOTFUNCDESC,
746 R_ARM_GOTOFFFUNCDESC, R_ARM_FUNCDESC, R_ARM_FUNCDESC_VALUE.
747 (elf32_arm_howto_from_type): Take new members of
748 elf32_arm_howto_table_2 into account.
749 (elf32_arm_reloc_map): Add BFD_RELOC_ARM_GOTFUNCDESC,
750 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
751 BFD_RELOC_ARM_FUNCDESC_VALUE.
752 * reloc.c: Add BFD_RELOC_ARM_GOTFUNCDESC,
753 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
754 BFD_RELOC_ARM_FUNCDESC_VALUE.
756 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
757 Mickaël Guêné <mickael.guene@st.com>
759 * elf32-arm.c (elf32_arm_print_private_bfd_data): Support
760 EF_ARM_PIC and ELFOSABI_ARM_FDPIC.
761 (elf32_arm_post_process_headers): Support ELFOSABI_ARM_FDPIC.
762 (ELF_OSABI): Define to ELFOSABI_ARM_FDPIC.
764 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
765 Mickaël Guêné <mickael.guene@st.com>
767 * config.bfd (arm*-*-linux-*): Add arm_elf32_fdpic_be_vec and
768 arm_elf32_fdpic_le_vec to targ_selvecs. Accept
769 arm*-*-uclinuxfdpiceabi.
770 * configure.ac: Add support for arm_elf32_fdpic_be_vec and
771 arm_elf32_fdpic_le_vec.
772 * configure: Regenerate.
773 * elf32-arm.c (struct elf32_arm_link_hash_table): Add fdpic_p.
774 (elf32_arm_link_hash_table_create): Initialize fdpic_p.
775 (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME, TARGET_BIG_SYM)
776 (TARGET_BIG_NAME, elf_match_priority): Define for FDPIC targets.
777 (elf32_arm_fdpic_link_hash_table_create): New.
778 * targets.c (_bfd_target_vector): Add arm_elf32_fdpic_be_vec and
779 arm_elf32_fdpic_le_vec.
781 2018-04-25 Alan Modra <amodra@gmail.com>
783 * elf-linux-core.h: Disable gcc-8 string truncation warning.
784 * elf.c (elfcore_write_prpsinfo): Likewise.
786 2018-04-25 Alan Modra <amodra@gmail.com>
788 * Makefile.am: Remove arm-aout and arm-coff support.
789 * config.bfd: Likewise.
790 * configure.ac: Likewise.
791 * targets.c: Likewise.
792 * aout-arm.c: Delete.
793 * armnetbsd.c: Delete.
795 * Makefile.in: Regenerate.
796 * configure: Regenerate.
797 * po/SRC-POTFILES.in: Regenerate.
799 2018-04-24 Nick Clifton <nickc@redhat.com>
802 * elf.c (ignore_section_sym): Check for the output_section pointer
803 being NULL before dereferencing it.
806 * peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Check for
807 a negative PE_DEBUG_DATA size before iterating over the debug data.
809 2018-04-23 Alan Modra <amodra@gmail.com>
811 * elf-linux-core.h: Revert last change.
814 2018-04-23 Nick Clifton <nickc@redhat.com>
817 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
818 the end of the string table, and zero it.
820 2018-04-23 Alan Modra <amodra@gmail.com>
822 * elf-linux-core.h (swap_linux_prpsinfo32_ugid32_out): Disable
823 gcc-8 string truncation warning.
824 (swap_linux_prpsinfo32_ugid16_out): Likewise.
825 (swap_linux_prpsinfo64_ugid32_out): Likewise.
826 (swap_linux_prpsinfo64_ugid16_out): Likewise.
827 * elf.c (elfcore_write_prpsinfo): Likewise.
829 2018-04-23 Nick Clifton <nickc@redhat.com>
832 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
833 the end of the string table, and zero it.
835 2018-04-20 Alan Modra <amodra@gmail.com>
838 * elf32-hppa.c (got_relocs_needed): Add extra param to special
839 case both dtprel and tprel relocs.
840 (allocate_dynrelocs): Adjust conditions for got relocs.
841 (elf32_hppa_relocate_section): Likewise for local sym got relocs.
842 Emit dynamic relocs on TLS GOT entries for shared libraries,
843 not when pic. Omit dynamic reloc on dtprel entry when local,
844 and on tprel entry when local and executable.
846 2018-04-19 Alan Modra <amodra@gmail.com>
849 * elf32-hppa.c (elf32_hppa_size_stubs): Init "destination" to -1.
850 (hppa_type_of_stub): Don't return a long branch stub for
851 symbols other than those defined statically.
853 2018-04-19 Alan Modra <amodra@gmail.com>
855 * Makefile.am: Revert 2018-04-18 coff-mips changes.
856 * config.bfd: Add back mips_ecoff_le_vec and mips_ecoff_be_vec
857 to selvecs for mips targets change 2018-04-18.
858 * configure.ac: Reinstate mips_ecoff_le_vec, mips_ecoff_be_vec
859 and mips_ecoff_bele_vec.
860 * targets.c: Likewise.
861 * coff-mips.c: Resurrect.
862 * Makefile.in: Regenerate.
863 * configure: Regenerate.
864 * po/SRC-POTFILES.in: Regenerate.
866 2018-04-18 Alan Modra <amodra@gmail.com>
868 * Makefile.am: Remove mips aout and coff support.
869 * config.bfd: Likewise.
870 * configure.ac: Likewise.
871 * targets.c: Likewise.
872 * coff-mips.c: Delete
876 * Makefile.in: Regenerate.
877 * configure: Regenerate.
878 * po/SRC-POTFILES.in: Regenerate.
880 2018-04-17 H.J. Lu <hongjiu.lu@intel.com>
882 * elf32-i386.c (elf32_bed): Define before including
884 * elf64-x86-64.c (elf64_bed): Define before including
886 (elf32_bed): Define before including "elf32-target.h".
888 2018-04-17 H.J. Lu <hongjiu.lu@intel.com>
891 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Use a
892 normal input file with compatible relocation.
894 2018-04-18 Alan Modra <amodra@gmail.com>
896 * Makefile.am: Remove support for assorted i386 aout and coff targets.
897 * config.bfd: Likewise.
898 * configure.ac: Likewise.
899 * doc/bfdint.texi: Likewise.
900 * targets.c: Likewise.
902 * i386dynix.c: Delete.
903 * i386freebsd.c: Delete.
904 * i386linux.c: Delete.
905 * i386mach3.c: Delete.
906 * i386netbsd.c: Delete.
907 * i386os9k.c: Delete.
908 * Makefile.in: Regenerate.
909 * configure: Regenerate.
910 * po/SRC-POTFILES.in: Regenerate.
912 2018-04-17 Andrew Sadek <andrew.sadek.se@gmail.com>
914 Microblaze Target: PIC data text relative
916 * bfd/reloc.c (2 new BFD relocations):
917 BFD_RELOC_MICROBLAZE_64_TEXTPCREL &
918 BFD_RELOC_MICROBLAZE_64_TEXTPCREL
919 * bfd/bfd-in2.h: Regenerate
920 * bfd/libbfd.h: Regenerate
921 * bfd/elf32-microblaze.c (Handle new relocs): define 'HOWTO' of 3
922 new relocs and handle them in both relocate and relax functions.
923 (microblaze_elf_reloc_type_lookup): add mapping between for new
925 (microblaze_elf_relocate_section): Handle new relocs in case of
927 (microblaze_elf_relax_section): Handle new relocs for elf relaxation.
929 2018-04-17 Nick Clifton <nickc@redhat.com>
932 * aoutx.h (find_nearest_line): Check that the symbol name exists
933 and is long enough, before attempting to see if it is for a .o
935 * hash.c (bfd_hash_hash): Add an assertion that the string is not
937 * linker.c (bfd_link_hash_lookup): Fail if the table or string are
939 (_bfd_generic_link_add_archive_symbols): Fail if an archive entry
943 * dwarf2.c (concat_filename): Check for a NULL table pointer.
945 2018-04-16 Nick Clifton <nickc@redhat.com>
948 * coffgen.c (coff_pointerize_aux): Check for an out of range
951 2018-04-16 Alan Modra <amodra@gmail.com>
953 * Makefile.am: Remove arm-epoc-pe support.
954 * coff-arm.c: Likewise.
955 * config.bfd: Likewise.
956 * configure.ac: Likewise.
957 * targets.c: Likewise.
958 * epoc-pe-arm.c: Delete.
959 * epoc-pei-arm.c: Delete.
960 * Makefile.in: Regenerate.
961 * configure: Regenerate.
962 * po/SRC-POTFILES.in: Regenerate.
964 2018-04-16 Alan Modra <amodra@gmail.com>
966 * Makefile.am: Remove sparc-aout and sparc-coff support.
967 * config.bfd: Likewise.
968 * configure.ac: Likewise.
969 * targets.c: Likewise.
970 * aout-sparcle.c: Delete.
972 * cf-sparclynx.c: Delete.
973 * coff-sparc.c: Delete.
975 * sparclinux.c: Delete.
976 * sparclynx.c: Delete.
977 * sparcnetbsd.c: Delete.
979 * Makefile.in: Regenerate.
980 * configure: Regenerate.
981 * po/SRC-POTFILES.in: Regenerate.
983 2018-04-16 Alan Modra <amodra@gmail.com>
985 * Makefile.am: Remove m68k-aout and m68k-coff support.
986 * aoutf1.h: Likewise.
988 * archive.c: Likewise.
989 * bfd-in.h: Likewise.
991 * coffcode.h: Likewise.
992 * coffswap.h: Likewise.
993 * config.bfd: Likewise.
994 * configure.ac: Likewise.
995 * configure.host: Likewise.
996 * doc/bfd.texinfo: Likewise.
997 * doc/bfdint.texi: Likewise.
998 * freebsd.h: Likewise.
999 * gen-aout.c: Likewise.
1000 * hpux-core.c: Likewise.
1001 * libaout.h: Likewise.
1002 * libbfd-in.h: Likewise.
1003 * pdp11.c: Likewise.
1004 * peicode.h: Likewise.
1005 * riscix.c: Likewise.
1006 * targets.c: Likewise.
1008 * coff-apollo.c: Delete.
1009 * coff-aux.c: Delete.
1010 * coff-m68k.c: Delete.
1011 * coff-svm68k.c: Delete.
1012 * coff-u68k.c: Delete.
1013 * hosts/delta68.h: Delete.
1014 * hosts/hp300bsd.h: Delete.
1015 * hosts/m68kaux.h: Delete.
1016 * hosts/news.h: Delete.
1017 * hp300bsd.c: Delete.
1018 * hp300hpux.c: Delete.
1019 * liboasys.h: Delete.
1020 * m68k4knetbsd.c: Delete.
1021 * m68klinux.c: Delete.
1022 * m68knetbsd.c: Delete.
1024 * versados.c: Delete.
1025 * Makefile.in: Regenerate.
1026 * bfd-in2.h: Regenerate.
1027 * configure: Regenerate.
1028 * libbfd.h: Regenerate.
1029 * po/SRC-POTFILES.in: Regenerate.
1031 2018-04-16 Alan Modra <amodra@gmail.com>
1033 * Makefile.am: Remove sh5 and sh64 support.
1034 * archures.c: Likewise.
1035 * config.bfd: Likewise.
1036 * configure.ac: Likewise.
1037 * cpu-sh.c: Likewise.
1038 * elf32-sh-relocs.h: Likewise.
1039 * elf32-sh.c: Likewise.
1040 * targets.c: Likewise.
1041 * elf32-sh64-com.c: Delete.
1042 * elf32-sh64.c: Delete.
1043 * elf32-sh64.h: Delete.
1044 * elf64-sh64.c: Delete.
1045 * Makefile.in: Regenerate.
1046 * bfd-in2.h: Regenerate.
1047 * configure: Regenerate.
1048 * po/SRC-POTFILES.in: Regenerate.
1050 2018-04-16 Alan Modra <amodra@gmail.com>
1052 * Makefile.am: Remove sh-symbianelf support.
1053 * config.bfd: Likewise.
1054 * configure.ac: Likewise.
1055 * targets.c: Likewise.
1056 * elf32-sh-symbian.c: Delete.
1057 * Makefile.in: Regenerate.
1058 * configure: Regenerate.
1059 * po/SRC-POTFILES.in: Regenerate.
1061 2018-04-16 Alan Modra <amodra@gmail.com>
1063 * Makefile.am: Remove vax-bsd and vax-ultrix support.
1064 * config.bfd: Likewise.
1065 * configure.ac: Likewise.
1066 * targets.c: Likewise.
1068 * Makefile.in: Regenerate.
1069 * configure: Regenerate.
1070 * po/SRC-POTFILES.in: Regenerate.
1072 2018-04-16 Alan Modra <amodra@gmail.com>
1074 * Makefile.am: Remove w65 support.
1075 * archures.c: Likewise.
1076 * coffcode.h: Likewise.
1077 * config.bfd: Likewise.
1078 * configure.ac: Likewise.
1079 * targets.c: Likewise.
1080 * coff-w65.c: Delete.
1081 * cpu-w65.c: Delete.
1082 * Makefile.in: Regenerate.
1083 * bfd-in2.h: Regenerate.
1084 * configure: Regenerate.
1085 * po/SRC-POTFILES.in: Regenerate.
1087 2018-04-16 Alan Modra <amodra@gmail.com>
1089 * Makefile.am: Remove we32k support.
1090 * archures.c: Likewise.
1091 * coffcode.h: Likewise.
1092 * config.bfd: Likewise.
1093 * configure.ac: Likewise.
1094 * targets.c: Likewise.
1095 * coff-we32k.c: Delete.
1096 * cpu-we32k.c: Delete.
1097 * Makefile.in: Regenerate.
1098 * bfd-in2.h: Regenerate.
1099 * configure: Regenerate.
1100 * po/SRC-POTFILES.in: Regenerate.
1102 2018-04-16 Alan Modra <amodra@gmail.com>
1104 * Makefile.am: Remove m88k support.
1105 * aoutx.h: Likewise.
1106 * archures.c: Likewise.
1107 * coffcode.h: Likewise.
1108 * coffswap.h: Likewise.
1109 * config.bfd: Likewise.
1110 * configure.ac: Likewise.
1111 * cpu-ns32k.c: Likewise.
1112 * elf32-nds32.c: Likewise.
1113 * mach-o.c: Likewise.
1114 * netbsd-core.c: Likewise.
1115 * reloc.c: Likewise.
1116 * targets.c: Likewise.
1117 * coff-m88k.c: Delete.
1118 * cpu-m88k.c: Delete.
1119 * elf32-m88k.c: Delete.
1120 * hosts/m88kmach3.h: Delete.
1121 * m88kmach3.c: Delete.
1122 * m88kopenbsd.c: Delete.
1123 * Makefile.in: Regenerate.
1124 * bfd-in2.h: Regenerate.
1125 * configure: Regenerate.
1126 * po/SRC-POTFILES.in: Regenerate.
1128 2018-04-16 Alan Modra <amodra@gmail.com>
1130 * Makefile.am: Remove i370 support.
1131 * archures.c: Likewise.
1132 * config.bfd: Likewise.
1133 * configure.ac: Likewise.
1134 * targets.c: Likewise.
1135 * cpu-i370.c: Delete.
1136 * elf32-i370.c: Delete.
1137 * Makefile.in: Regenerate.
1138 * bfd-in2.h: Regenerate.
1139 * configure: Regenerate.
1140 * po/SRC-POTFILES.in: Regenerate.
1142 2018-04-16 Alan Modra <amodra@gmail.com>
1144 * Makefile.am: Remove h8500 support.
1145 * archures.c: Likewise.
1146 * coffcode.h: Likewise.
1147 * config.bfd: Likewise.
1148 * configure.ac: Likewise.
1149 * targets.c: Likewise.
1150 * coff-h8500.c: Delete.
1151 * cpu-h8500.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 h8300-coff support.
1160 * coffcode.h: Likewise.
1161 * config.bfd: Likewise.
1162 * configure.ac: Likewise.
1163 * reloc16.c: Likewise.
1164 * targets.c: Likewise.
1165 * coff-h8300.c: Delete.
1166 * Makefile.in: Regenerate.
1167 * configure: Regenerate.
1168 * po/SRC-POTFILES.in: Regenerate.
1170 2018-04-16 Alan Modra <amodra@gmail.com>
1172 * Makefile.am: Remove IEEE 695 support.
1173 * archures.c: Likewise.
1175 * config.bfd: Likewise.
1176 * configure.ac: Likewise.
1177 * doc/bfd.texinfo: Likewise.
1178 * doc/bfdint.texi: Likewise.
1179 * doc/bfdsumm.texi: Likewise.
1180 * section.c: Likewise.
1181 * targets.c: Likewise.
1183 * libieee.h: Delete.
1184 * Makefile.in: Regenerate.
1185 * bfd-in2.h: Regenerate.
1186 * configure: Regenerate.
1187 * po/SRC-POTFILES.in: Regenerate.
1189 2018-04-16 Alan Modra <amodra@gmail.com>
1191 * config.bfd: Remove tandem support.
1193 2018-04-16 Alan Modra <amodra@gmail.com>
1195 * Makefile.am: Remove newsos3 support.
1196 * aoutx.h: Likewise.
1197 * config.bfd: Likewise.
1198 * configure.ac: Likewise.
1199 * targets.c: Likewise.
1200 * newsos3.c: Delete.
1201 * Makefile.in: Regenerate.
1202 * configure: Regenerate.
1203 * po/SRC-POTFILES.in: Regenerate.
1205 2018-04-16 Alan Modra <amodra@gmail.com>
1207 * Makefile.am: Remove netware support.
1208 * bfd-in.h: Likewise.
1210 * config.bfd: Likewise.
1211 * configure.ac: Likewise.
1212 * doc/bfdint.texi: Likewise.
1213 * ecoff.c: Likewise.
1214 * targets.c: Likewise.
1216 * nlm-target.h: Delete.
1218 * nlm32-alpha.c: Delete.
1219 * nlm32-i386.c: Delete.
1220 * nlm32-ppc.c: Delete.
1221 * nlm32-sparc.c: Delete.
1224 * nlmcode.h: Delete.
1225 * nlmswap.h: Delete.
1226 * Makefile.in: Regenerate.
1227 * bfd-in2.h: Regenerate.
1228 * configure: Regenerate.
1229 * po/SRC-POTFILES.in: Regenerate.
1231 2018-04-16 Alan Modra <amodra@gmail.com>
1233 * archures.c: Remove tahoe support.
1234 * config.bfd: Likewise.
1235 * configure.ac: Likewise.
1236 * hosts/tahoe.h: Delete.
1237 * bfd-in2.h: Regenerate.
1238 * configure: Regenerate.
1240 2018-04-14 Alan Modra <amodra@gmail.com>
1242 * elf-bfd.h (struct elf_backend_data): Add relropagesize.
1243 * elfxx-target.h (ELF_RELROPAGESIZE): Provide default and
1245 (elfNN_bed): Init relropagesize.
1246 * bfd.c (bfd_emul_get_commonpagesize): Add boolean param to
1247 select relropagesize.
1248 * elf32-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
1249 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
1250 (ELF_MINPAGESIZE): Don't define.
1251 * elf64-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
1252 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
1253 * bfd-in2.h: Regenerate.
1255 2018-04-14 Alan Modra <amodra@gmail.com>
1257 * elf32-ppc.c (ELF_MAXPAGESIZE, ELF_COMMONPAGESIZE): Don't depend
1258 on __QNXTARGET__ define.
1260 2018-04-14 Alan Modra <amodra@gmail.com>
1262 * config.bfd: Add powerpc-*-lynxos* and powerpc-*-windiss*
1265 2018-04-11 Alan Modra <amodra@gmail.com>
1267 * aout-adobe.c: Delete.
1269 * coff-i860.c: Delete.
1270 * coff-i960.c: Delete.
1271 * cpu-i860.c: Delete.
1272 * cpu-i960.c: Delete.
1273 * elf32-i860.c: Delete.
1274 * elf32-i960.c: Delete.
1275 * hosts/i860mach3.h: Delete.
1276 * Makefile.am: Remove i860, i960, bout, and adobe support.
1277 * archures.c: Remove i860 and i960 support.
1278 * coffcode.h: Likewise.
1279 * reloc.c: Likewise.
1280 * aoutx.h: Comment updates.
1281 * archive.c: Remove BOUT and i960 support.
1282 * bfd.c: Remove BOUT support.
1283 * coffswap.h: Remove i960 support.
1284 * config.bfd: Remove i860, i960 and adobe targets.
1285 * configure.ac: Remove adode, bout, i860, i960, icoff targets.
1286 * targets.c: Likewise.
1287 * ieee.c: Remove i960 support.
1288 * mach-o.c: Remove i860 support.
1289 * Makefile.in: Regenerate.
1290 * bfd-in2.h: Regenerate.
1291 * configure: Regenerate.
1292 * libbfd.h: Regenerate.
1293 * po/SRC-POTFILES.in: Regenerate.
1295 2018-04-09 Maciej W. Rozycki <macro@mips.com>
1297 * elf64-mips.c (mips_elf64_write_rel): Handle a NULL BFD pointer
1298 in the BFD symbol referred by the relocation.
1299 (mips_elf64_write_rela): Likewise.
1301 2018-04-09 Maciej W. Rozycki <macro@mips.com>
1303 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Issue an
1304 error for out-of-range `r_sym' values.
1306 2018-04-09 Alan Modra <amodra@gmail.com>
1308 * elf64-ppc.c (struct _ppc64_elf_section_data): Add has_pltcall field.
1309 (struct ppc_link_hash_table): Add can_convert_all_inline_plt.
1310 (ppc64_elf_check_relocs): Set has_pltcall.
1311 (ppc64_elf_adjust_dynamic_symbol): Discard some PLT entries.
1312 (ppc64_elf_inline_plt): New function.
1313 (ppc64_elf_size_dynamic_sections): Discard some PLT entries for locals.
1314 * elf64-ppc.h (ppc64_elf_inline_plt): Declare.
1315 * elf32-ppc.c (has_pltcall): Define.
1316 (struct ppc_elf_link_hash_table): Add can_convert_all_inline_plt.
1317 (ppc_elf_check_relocs): Set has_pltcall.
1318 (ppc_elf_inline_plt): New function.
1319 (ppc_elf_adjust_dynamic_symbol): Discard some PLT entries.
1320 (ppc_elf_size_dynamic_sections): Likewise.
1321 * elf32-ppc.h (ppc_elf_inline_plt): Declare.
1323 2018-04-09 Alan Modra <amodra@gmail.com>
1325 * elf32-ppc.c (ppc_elf_howto_raw): Add PLTSEQ and PLTCALL howtos.
1326 (is_plt_seq_reloc): New function.
1327 (ppc_elf_check_relocs): Handle PLTSEQ and PLTCALL relocs.
1328 (ppc_elf_tls_optimize): Handle inline plt call sequence.
1329 (ppc_elf_relax_section): Handle PLTCALL reloc.
1330 (ppc_elf_relocate_section): Nop out inline plt call sequence when
1332 * elf64-ppc.c (ppc64_elf_howto_raw): Add R_PPC64_PLTSEQ and
1333 R_PPC64_PLTCALL entries. Comment R_PPC64_TOCSAVE.
1334 (has_tls_get_addr_call): Correct comment.
1335 (is_branch_reloc): Add PLTCALL.
1336 (is_plt_seq_reloc): New function.
1337 (ppc64_elf_check_relocs): Handle PLT16_LO_DS reloc. Set
1338 has_tls_reloc for R_PPC64_TLSGD and R_PPC64_TLSLD. Create plt
1339 entry for R_PPC64_PLTCALL.
1340 (ppc64_elf_tls_optimize): Handle inline plt call sequence.
1341 (ppc_type_of_stub): Handle PLTCALL reloc.
1342 (toc_adjusting_stub_needed): Likewise.
1343 (ppc64_elf_relocate_section): Set "can_plt_call" for PLTCALL
1344 reloc insn. Nop out inline plt call sequence when resolving
1345 locally. Handle __tls_get_addr inline plt call optimization.
1347 2018-04-09 Alan Modra <amodra@gmail.com>
1349 * elf64-ppc.c (LOCAL_PLT_ENTRY_SIZE): Define.
1350 (struct ppc_stub_hash_entry): Add symtype field.
1352 (struct ppc_link_hash_table): Add pltlocal and relpltlocal.
1353 (create_linkage_sections): Create pltlocal and relpltlocal.
1354 (ppc64_elf_check_relocs): Allow PLT relocs on local symbols.
1356 (ppc64_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
1357 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
1358 (ppc64_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
1359 Keep PLT entries for inline calls against locals.
1360 (ppc_build_one_stub): Use pltlocal as appropriate.
1361 (ppc_size_one_stub): Likewise.
1362 (ppc64_elf_size_stubs): Set symtype.
1363 (build_global_entry_stubs_and_plt): Init pltlocal and write
1364 relpltlocal for globals.
1365 (write_plt_relocs_for_local_syms): Likewise for local syms.
1366 (ppc64_elf_relocate_section): Support PLT for local syms.
1367 * elf32-ppc.c (PLT_KEEP): Define.
1368 (struct ppc_elf_link_hash_table): Add pltlocal and relpltlocal.
1369 (ppc_elf_create_glink): Create pltlocal and relpltlocal.
1370 (ppc_elf_check_relocs): Allow PLT relocs on local symbols.
1371 Set PLT_KEEP. Adjust update_local_sym_info call.
1372 (ppc_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
1373 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
1374 (ppc_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
1375 (ppc_elf_relocate_section): Support PLT16 relocs for local syms.
1376 (write_global_sym_plt): Init pltlocal and write relpltlocal.
1377 (ppc_finish_symbols): Likewise for locals.
1379 2018-04-09 Alan Modra <amodra@gmail.com>
1381 * elf64-ppc.c (ppc_build_one_stub): Move output of PLT relocs
1382 for local symbols to..
1383 (write_plt_relocs_for_local_syms): ..here. New function.
1384 (ppc64_elf_finish_dynamic_symbol): Move output of PLT relocs for
1386 (build_global_entry_stubs_and_plt): ..here. Rename from
1387 build_global_entry_stubs.
1388 (ppc64_elf_build_stubs): Always call build_global_entry_stubs_and_plt.
1389 Call write_plt_relocs_for_local_syms.
1390 * elf32-ppc.c (get_sym_h): New function.
1391 (ppc_elf_relax_section): Use get_sym_h.
1392 (ppc_elf_relocate_section): Move output of PLT relocs and glink
1393 stubs for local symbols to..
1394 (ppc_finish_symbols): ..here. New function.
1395 (ppc_elf_finish_dynamic_symbol): Move output of PLT relocs for
1397 (write_global_sym_plt): ..here. New function.
1398 * elf32-ppc.h (ppc_elf_modify_segment_map): Delete attribute.
1399 (ppc_finish_symbols): Declare.
1401 2018-04-09 Alan Modra <amodra@gmail.com>
1403 * elf32-ppc.c (ppc_elf_check_relocs): Handle PLT16 relocs.
1404 (ppc_elf_relocate_section): Likewise.
1405 * elf64-ppc.c (ppc64_elf_check_relocs): Handle PLT16_LO_DS.
1406 (ppc64_elf_relocate_section): Likewise. Correct PLT16
1407 resolution to plt entry relative to toc pointer.
1409 2018-04-09 Alan Modra <amodra@gmail.com>
1411 * elf64-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
1412 TLS_TPRELGD, TLS_EXPLICIT): Renumber. Test TLS_TLS throughout
1413 file when other TLS flags are tested in a mask.
1414 (TLS_MARK, NON_GOT): Define.
1415 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
1416 (update_local_sym_info): Don't create got entry when NON_GOT.
1417 (ppc64_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
1419 (get_tls_mask): Do toc lookup if tls_mask is just TLS_MARK.
1420 (ppc64_elf_relocate_section): Likewise.
1421 (ppc64_elf_tls_optimize): Don't attempt to optimize indirect
1422 __tls_get_addr calls lacking a marker reloc.
1423 * elf32-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
1424 TLS_TPRELGD): Renumber. Update comment.
1425 (TLS_MARK, NON_GOT): Define.
1426 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
1427 (update_local_sym_info): Don't create got entry when NON_GOT.
1428 (ppc_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
1430 (ppc_elf_tls_optimize): Don't attempt to optimize indirect
1431 __tls_get_addr calls lacking a marker reloc.
1433 2018-04-06 H.J. Lu <hongjiu.lu@intel.com>
1435 * elf64-x86-64.c (elf_x86_64_info_to_howto): Don't mask out
1436 R_X86_64_converted_reloc_bit.
1438 2018-04-05 H.J. Lu <hongjiu.lu@intel.com>
1441 * configure: Regenerated.
1443 2018-04-05 Alan Modra <amodra@gmail.com>
1445 * elf-hppa.h (elf_hppa_info_to_howto): Init howto to NULL.
1446 (elf_hppa_info_to_howto_rel): Likewise.
1448 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1450 * elf-hppa.h (elf_hppa_info_to_howto): Also return
1451 unsuccessfully for unimplemented relocations.
1452 (elf_hppa_info_to_howto_rel): Likewise.
1454 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1456 * elf32-i860.c (lookup_howto): Add `abfd' parameter. Set the
1457 `bfd_error_bad_value' error and call `_bfd_error_handler' on a
1458 howto lookup failure.
1459 (elf32_i860_reloc_type_lookup): Adjust `lookup_howto' call
1461 (elf32_i860_info_to_howto_rela): Likewise.
1462 (elf32_i860_relocate_splitn): Likewise.
1463 (elf32_i860_relocate_pc16): Likewise.
1464 (elf32_i860_relocate_pc26): Likewise.
1465 (elf32_i860_relocate_section): Likewise.
1467 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1469 * elf32-visium.c (visium_info_to_howto_rela): Correct the range
1470 check for `visium_elf_howto_table' table access.
1472 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1474 * elf32-iq2000.c (iq2000_info_to_howto_rela): Correct the range
1475 check for `iq2000_elf_howto_table' table access.
1477 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1479 * elf32-frv.c (frv_info_to_howto_rela): Correct the range check
1480 for `elf32_frv_howto_table' table access.
1482 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1484 * elf32-mips.c (mips_elf32_rtype_to_howto): Also return
1485 unsuccessfully for placeholder howtos.
1486 * elf64-mips.c (mips_elf64_rtype_to_howto): Likewise.
1487 * elfn32-mips.c (mips_elf_n32_rtype_to_howto): Likewise.
1489 2018-03-29 Maciej W. Rozycki <macro@mips.com>
1491 * elf32-mips.c (mips_info_to_howto_rel): Remove the calls to
1492 `_bfd_error_handler' and to set the `bfd_error_bad_value' error.
1494 2018-03-28 Maciej W. Rozycki <macro@mips.com>
1496 * elf-hppa.h (elf_hppa_info_to_howto_rel): Remove
1497 ATTRIBUTE_UNUSED from `abfd'.
1499 2018-03-28 Maciej W. Rozycki <macro@mips.com>
1501 * elf-hppa.h (elf_hppa_info_to_howto_rel): Correct
1502 `_bfd_error_handler' call formatting.
1504 2018-03-28 Maciej W. Rozycki <macro@mips.com>
1506 * elf32-mips.c (mips_info_to_howto_rel): Call
1507 `mips_elf32_rtype_to_howto' directly rather than via
1508 `->elf_backend_mips_rtype_to_howto'.
1510 2018-03-28 Renlin Li <renlin.li@arm.com>
1513 * elfnn-aarch64.c (IS_AARCH64_TLS_RELOC): Add cases for
1514 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
1515 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
1516 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
1517 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
1518 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
1519 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
1520 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
1521 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
1522 (elfNN_aarch64_final_link_relocate): Support new relocations.
1523 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Support new
1525 (_bfd_aarch64_elf_resolve_relocation): Support new relocations.
1527 2018-03-28 Renlin Li <renlin.li@arm.com>
1530 * reloc.c: Add BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12
1531 BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12_NC,
1532 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
1533 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
1534 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
1535 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
1536 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
1537 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
1538 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
1539 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
1540 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add table entry for
1541 TLSLE_LDST16_TPREL_LO12,
1542 TLSLE_LDST16_TPREL_LO12_NC,
1543 TLSLE_LDST32_TPREL_LO12,
1544 TLSLE_LDST32_TPREL_LO12_NC,
1545 TLSLE_LDST64_TPREL_LO12,
1546 TLSLE_LDST64_TPREL_LO12_NC,
1547 TLSLE_LDST8_TPREL_LO12,
1548 TLSLE_LDST8_TPREL_LO12_NC.
1549 * bfd-in2.h: Regenerated.
1550 * libbfd.h: Regenerated.
1552 2018-03-28 Eric Botcazou <ebotcazou@adacore.com>
1555 * elfxx-sparc.c (struct _bfd_sparc_elf_link_hash_entry): Add new flag
1556 has_old_style_got_reloc.
1557 (_bfd_sparc_elf_check_relocs) <GOT relocations>: Set it for old-style
1558 relocations. Fix a couple of long lines.
1559 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: Do not generate
1560 a R_SPARC_NONE for the GOT slot if the symbol is also subject to old-style
1563 2018-03-25 H.J. Lu <hongjiu.lu@intel.com>
1566 * elf64-x86-64.c (elf_x86_64_finish_dynamic_sections): Add
1567 ENDBR64 to the TLSDESC PLT entry.
1569 2018-03-21 Alan Modra <amodra@gmail.com>
1571 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Trim uninteresting
1572 symbols. Use size_t counts. Delete redundant opd test.
1574 2018-03-21 Alan Modra <amodra@gmail.com>
1576 * elf32-ppc.c (ppc_elf_tls_optimize): Delete locsyms.
1578 2018-03-21 Alan Modra <amodra@gmail.com>
1580 * elf32-ppc.c (struct ppc_elf_link_hash_entry): Make tls_mask
1582 (update_local_sym_info): Likewise for local_got_tls_masks.
1583 (ppc_elf_tls_optimize): Likewise for lgot_masks.
1585 2018-03-21 Alan Modra <amodra@gmail.com>
1587 * elf64-ppc.c (ppc_size_one_stub): Fix comment typo.
1588 (ppc64_elf_layout_multitoc): Allocate relocs for tprel as we
1589 do in size_dynamic_sections.
1591 2018-03-21 Alan Modra <amodra@gmail.com>
1593 * elf64-ppc.c (ppc64_elf_relocate_section): Don't access rel[1]
1594 without first checking array bounds.
1595 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
1597 2018-03-20 H.J. Lu <hongjiu.lu@intel.com>
1600 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Set
1601 non_ir_ref_dynamic if a symbol is made dynamic by --dynamic-list.
1603 2018-03-19 Nick Clifton <nickc@redhat.com>
1605 * po/es.po: Updated Spanish translation.
1607 2018-03-15 Max Filippov <jcmvbkbc@gmail.com>
1609 * elf32-xtensa.c (xlate_map_entry): Change types of address
1610 fields from 'unsigned' to 'bfd_vma'.
1611 (xlate_offset_with_removed_text): Use struct xlate_map_entry as
1612 the key argument to bsearch. Allow offsets past the end of a
1613 section, use the last map entry for translation of such offsets.
1615 2018-03-15 Kuan-Lin Chen <kuanlinchentw@gmail.com>
1617 * elf32-nds32.c (nds32_elf_ex9_build_hash_table): Removed.
1618 Not support the target feature.
1619 (nds32_elf_ex9_itb_base): Likewise.
1620 (nds32_elf_ex9_import_table): Likewise.
1621 (nds32_elf_ex9_finish): Likewise.
1622 (nds32_elf_ex9_reloc_jmp): Likewise.
1623 (nds32_elf_get_insn_with_reg): Likewise.
1624 (nds32_get_local_syms): Likewise.
1625 (nds32_elf_ex9_replace_instruction): Likewise.
1626 (nds32_elf_ifc_calc): Likewise.
1627 (nds32_elf_ifc_finish): Likewise.
1628 (nds32_elf_ifc_replace): Likewise.
1629 (nds32_elf_ifc_reloc): Likewise.
1631 2018-03-14 Alan Modra <amodra@gmail.com>
1633 * elf64-ppc.c (sfpr_define): Adjust for stub_sec size having
1634 sfpr size added before defining alias symbols.
1635 (ppc64_elf_build_stubs): Add stub section padding before
1636 copying sfpr contents and defining save/restore alias symbols.
1638 2018-03-14 H.J. Lu <hongjiu.lu@intel.com>
1641 * elflink.c (elf_gc_mark_debug_section): Also check the local
1642 debug definition section.
1644 2018-03-13 Nick Clifton <nickc@redhat.com>
1647 * pei-x86_64.c (pex64_get_unwind_info): Change to a boolean
1648 function. Add an end address parameter. Check access of the data
1649 pointer to make sure that they do not extend beyond the end
1650 address. Return FALSE if any check fails. Add the end address
1651 pointer to the ui structure.
1652 (pex64_xdata_print_uwd_codes): Check accesses of the raw unwind
1653 codes to make sure that they do not extend beyond the end address
1654 pointer. Print an error message and return immediately if any
1657 2018-03-09 Nick Clifton <nickc@redhat.com>
1659 * elf64-s390.c (elf_s390_relocate_section): Move check for
1660 relocations against non-allocated sections to before the code that
1661 handles ifunc relocations.
1662 * elf32-s390.c (elf_s390_relocate_section): Likewise.
1663 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Treat
1664 relocs against IFUNC symbols in non-allocated sections as relocs
1665 against FUNC symbols.
1666 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
1668 2018-03-08 H.J. Lu <hongjiu.lu@intel.com>
1671 * elf32-i386.c (elf_i386_relocate_section): Treat relocation
1672 against IFUNC symbol in SHT_NOTE section without SHF_ALLOC as
1673 relocation against FUNC symbol.
1674 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
1676 2018-03-07 Renlin Li <renlin.li@arm.com>
1679 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Check absolute
1680 symbol, and don't emit relocation in specific case.
1682 2018-03-07 Alan Modra <amodra@gmail.com>
1684 * elf64-mips.c (mips_elf64_rtype_to_howto): Return NULL on error.
1685 (mips_elf64_slurp_one_reloc_table): Pass on error.
1687 2018-03-03 James Cowgill <james.cowgill@mips.com>
1688 Maciej W. Rozycki <macro@mips.com>
1691 * elfxx-mips.c (mips_elf_calculate_relocation): Only return
1692 after calling `undefined_symbol' hook if this is an error
1693 condition. Assume the value of 0 for the symbol requested
1696 2018-03-02 Jim Wilson <jimw@sifive.com>
1699 * elfnn-aarch64.c (_bfd_aarch64_resize_stubs): Add 8 bytes for branch
1700 and nop instead of 4.
1701 (elfNN_arch64_build_stubs): Add nop after branch. Increase size by
1704 2018-03-01 Jim Wilson <jimw@sifive.com>
1707 * elfnn-riscv.c (riscv_relax_delete_bytes): When adjust st_size, use
1708 else if instead of if.
1710 2018-03-01 Alan Modra <amodra@gmail.com>
1712 * elf32-ft32.c (ft32_info_to_howto_rela): Correct range test.
1714 2018-02-28 Alan Modra <amodra@gmail.com>
1717 * aoutx.h (swap_std_reloc_in): Correct r_index bound check.
1719 2018-02-28 Nick Clifton <nickc@redhat.com>
1723 * dwarf2.c (read_n_bytes): Replace size parameter with dwarf_block
1724 pointer. Drop unused abfd parameter. Check the size of the block
1725 before initialising the data field. Return the end pointer if the
1727 (read_attribute_value): Adjust invocations of read_n_bytes.
1730 * dwarf1.c (parse_die): Check the length of form blocks before
1731 advancing the data pointer.
1733 2018-02-28 Alan Modra <amodra@gmail.com>
1736 * aoutx.h (translate_symbol_table): Print an error message and set
1737 bfd_error on finding an invalid name string offset.
1739 2018-02-27 H.J. Lu <hongjiu.lu@intel.com>
1741 * config.in: Regenerated.
1742 * configure: Likewise.
1743 * configure.ac: Add --enable-separate-code.
1744 (DEFAULT_LD_Z_SEPARATE_CODE): New AC_DEFINE_UNQUOTED. Default
1745 to 1 for Linux/x86 targets,
1746 * elf64-x86-64.c (ELF_MAXPAGESIZE): Set to 0x1000 if
1747 DEFAULT_LD_Z_SEPARATE_CODE is 1.
1749 2018-02-27 Nick Clifton <nickc@redhat.com>
1751 * aout-cris.c (swap_ext_reloc_out): Standadize error/warning
1753 * elf-hppa.h (elf_hppa_info_to_howto_rel): Likewise.
1754 * elf32-i386.c (elf_i386_reloc_type_lookup): Likewise.
1755 * elf32-xtensa.c (elf_xtensa_reloc_type_lookup): Likewise.
1756 * elf64-ppc.c (ppc64_elf_reloc_type_lookup): Likewise.
1757 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
1758 * elf64-sh64.c (sh_elf64_info_to_howto): Likewise.
1759 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
1760 * elfxx-sparc.c (_bfd_sparc_elf_reloc_type_lookup): Likewise.
1761 * elfxx-tilegx.c (tilegx_reloc_type_lookup): Likewise.
1764 * elf-bfd.h (struct elf_backend_data): Change the return type of
1765 the elf_info_to_howto and elf_info_to_howto_rel function pointers
1767 * elfcode.h (elf_slurp_reloc_table_from_section): Check the return
1768 value from the info_to_howto function and fail if that function
1770 * elf32-h8300.c (elf32_h8_relocate_section): Check return value
1771 from the info_to_howto function.
1772 (elf32_h8_relax_section): Likewise.
1773 * elf32-lm32.c (lm32_elf_relocate_section): Likewise.
1774 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
1775 * elf32-score.c (s3_bfd_score_elf_relocate_section): Likewise.
1776 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
1777 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
1778 * elf64-ia64-vms.c (elf64_ia64_relocate_section): Likewise.
1779 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Likewise.
1780 * elf64-x86-64.c (elf_x86_64_tls_transition): Likewise.
1781 * elfnn-ia64.c (elfNN_ia64_relocate_section): Likewise.
1782 * elfnn-riscv.c (riscv_elf_check_relocs): Likewise.
1783 (riscv_elf_relocate_section): Likewise.
1784 * elf-hppa.h (elf_hppa_info_to_howto): Change return type to
1785 bfd_boolean. Issue an error message, set an error value and
1786 return FALSE if the reloc is not recognized.
1787 (elf_hppa_info_to_howto_rel): Likewise.
1788 * elf-m10200.c (mn10200_info_to_howto): Likewise.
1789 * elf-m10300.c (mn10300_info_to_howto): Likewise.
1790 * elf.c (_bfd_elf_no_info_to_howto): Likewise.
1791 * elf32-arc.c (arc_info_to_howto_rel): Likewise.
1792 * elf32-arm.c (elf32_arm_info_to_howto): Likewise.
1793 * elf32-avr.c (avr_info_to_howto_rela): Likewise.
1794 * elf32-bfin.c (bfin_info_to_howto): Likewise.
1795 * elf32-cr16.c (elf_cr16_info_to_howto): Likewise.
1796 * elf32-cr16c.c (elf_cr16c_info_to_howto): Likewise.
1797 * elf32-cris.c (elf_cr16c_info_to_howto_rel)
1798 (cris_info_to_howto_rela): Likewise.
1799 * elf32-crx.c (elf_crx_info_to_howto): Likewise.
1800 * elf32-d10v.c (d10v_info_to_howto_rel): Likewise.
1801 * elf32-d30v.c (d30v_info_to_howto_rel, d30v_info_to_howto_rela):
1803 * elf32-dlx.c (dlx_rtype_to_howto, elf32_dlx_info_to_howto)
1804 (elf32_dlx_info_to_howto_rel): Likewise.
1805 * elf32-epiphany.c (epiphany_info_to_howto_rela): Likewise.
1806 * elf32-fr30.c (fr30_info_to_howto_rela): Likewise.
1807 * elf32-frv.c (frv_info_to_howto_rela)
1808 (frvfdpic_info_to_howto_rel): Likewise.
1809 * elf32-ft32.c (ft32_info_to_howto_rela): Likewise.
1810 * elf32-gen.c (elf_generic_info_to_howto)
1811 (elf_generic_info_to_howto_rel): Likewise.
1812 * elf32-h8300.c (elf32_h8_info_to_howto)
1813 (elf32_h8_info_to_howto_rel): Likewise.
1814 * elf32-i370.c (i370_elf_info_to_howto): Likewise.
1815 * elf32-i386.c (elf_i386_reloc_type_lookup)
1816 (elf_i386_rtype_to_howto, elf_i386_info_to_howto_rel): Likewise.
1817 * elf32-i860.c (lookup_howto, elf32_i860_info_to_howto_rela):
1819 * elf32-i960.c (elf32_i960_info_to_howto_rel): Likewise.
1820 * elf32-ip2k.c (ip2k_info_to_howto_rela): Likewise.
1821 * elf32-iq2000.c (iq2000_info_to_howto_rela): Likewise.
1822 * elf32-lm32.c (lm32_info_to_howto_rela): Likewise.
1823 * elf32-m32c.c (m32c_info_to_howto_rela): Likewise.
1824 * elf32-m32r.c (m32r_info_to_howto_rel, m32r_info_to_howto):
1826 * elf32-m68hc11.c (m68hc11_info_to_howto_rel): Likewise.
1827 * elf32-m68hc12.c (m68hc11_info_to_howto_rel): Likewise.
1828 * elf32-m68k.c (rtype_to_howto): Likewise.
1829 * elf32-mcore.c (mcore_elf_info_to_howto): Likewise.
1830 * elf32-mep.c (mep_info_to_howto_rela): Likewise.
1831 * elf32-metag.c (metag_info_to_howto_rela): Likewise.
1832 * elf32-microblaze.c (microblaze_elf_info_to_howto): Likewise.
1833 * elf32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
1835 * elf32-moxie.c (moxie_info_to_howto_rela): Likewise.
1836 * elf32-msp430.c (msp430_info_to_howto_rela): Likewise.
1837 * elf32-mt.c (mt_info_to_howto_rela): Likewise.
1838 * elf32-nds32.c (nds32_info_to_howto_rel, nds32_info_to_howto):
1840 * elf32-nios2.c (nios2_elf32_info_to_howto): Likewise.
1841 * elf32-or1k.c (or1k_info_to_howto_rela): Likewise.
1842 * elf32-pj.c (pj_elf_info_to_howto): Likewise.
1843 * elf32-ppc.c (ppc_elf_info_to_howto): Likewise.
1844 * elf32-pru.c (pru_elf32_info_to_howto): Likewise.
1845 * elf32-rl78.c (rl78_info_to_howto_rela): Likewise.
1846 * elf32-rx.c (rx_info_to_howto_rela): Likewise.
1847 * elf32-s390.c (elf_s390_info_to_howto): Likewise.
1848 * elf32-score.c (s3_bfd_score_info_to_howto)
1849 (_bfd_score_info_to_howto): Likewise.
1850 * elf32-score7.c (s7_bfd_score_info_to_howto): Likewise.
1851 * elf32-sh.c (sh_elf_info_to_howto): Likewise.
1852 * elf32-spu.c (spu_elf_info_to_howto): Likewise.
1853 * elf32-tic6x.c (elf32_tic6x_info_to_howto)
1854 (elf32_tic6x_info_to_howto_rel): Likewise.
1855 * elf32-tilepro.c (tilepro_info_to_howto_rela): Likewise.
1856 * elf32-v850.c (v850_elf_info_to_howto_rel)
1857 (v850_elf_info_to_howto_rela, v800_elf_info_to_howto): Likewise.
1858 * elf32-vax.c (rtype_to_howto): Likewise.
1859 * elf32-visium.c (visium_info_to_howto_rela): Likewise.
1860 * elf32-wasm32.c (elf32_wasm32_rtype_to_howto)
1861 (elf32_wasm32_info_to_howto_rela): Likewise.
1862 * elf32-xc16x.c (elf32_xc16x_info_to_howto): Likewise.
1863 * elf32-xgate.c (xgate_info_to_howto_rel): Likewise.
1864 * elf32-xstormy16.c (xstormy16_info_to_howto_rela): Likewise.
1865 * elf32-xtensa.c (elf_xtensa_info_to_howto_rela): Likewise.
1866 * elf64-alpha.c (elf64_alpha_info_to_howto): Likewise.
1867 * elf64-gen.c (elf_generic_info_to_howto)
1868 (elf_generic_info_to_howto_rel): Likewise.
1869 * elf64-ia64-vms.c (elf64_ia64_info_to_howto): Likewise.
1870 * elf64-mips.c (mips_elf64_info_to_howto_rela): Likewise.
1871 * elf64-mmix.c (mmix_info_to_howto_rela): Likewise.
1872 * elf64-ppc.c (ppc64_elf_info_to_howto): Likewise.
1873 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
1874 * elf64-sh64.c (elf_s390_info_to_howto, sh_elf64_info_to_howto):
1876 * elf64-x86-64.c (elf_x86_64_info_to_howto): Likewise.
1877 * elfn32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
1879 * elfnn-aarch64.c (elfNN_aarch64_info_to_howto): Likewise.
1880 * elfnn-ia64.c (elfNN_ia64_info_to_howto): Likewise.
1881 * elfnn-riscv.c (riscv_info_to_howto_rela): Likewise.
1882 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
1883 * elfxx-sparc.c (_bfd_sparc_elf_info_to_howto): Likewise.
1884 * elfxx-tilegx.c (tilegx_info_to_howto_rela): Likewise.
1885 * elf32-score.h (s7_bfd_score_info_to_howto): Update prototype.
1886 * elfxx-sparc.h (_bfd_sparc_elf_info_to_howto): Update prototype.
1887 * elfxx-tilegx.h (tilegx_info_to_howto_rela): Update prototype.
1888 * elfxx-target.h (elf_info_to_howto, elf_info_to_howto_rel):
1891 2018-02-26 Jim Wilson <jimw@sifive.com>
1892 Stephan Schreiber <info@fs-driver.org>
1895 * elfnn-ia64.c (elfNN_ia64_relax_section): After ia64_elf_relax_brl
1896 call, set changed_contents and changed_relocs. Likewise after
1897 successful ia64_elf_relax_br call.
1899 2018-02-26 Alan Modra <amodra@gmail.com>
1901 * elf.c (assign_file_positions_except_relocs): Don't segfault
1902 when actual number of phdrs is less than allocated. Delete
1903 outdated comment. Formatting.
1905 2018-02-26 Alan Modra <amodra@gmail.com>
1907 * elf-m10300.c, * elf-s390-common.c, * elf32-arc.c, * elf32-cris.c,
1908 * elf32-dlx.c, * elf32-frv.c, * elf32-i370.c, * elf32-lm32.c,
1909 * elf32-m32r.c, * elf32-m68hc1x.c, * elf32-m68k.c,
1910 * elf32-microblaze.c, * elf32-msp430.c, * elf32-nds32.c,
1911 * elf32-nios2.c, * elf32-or1k.c, * elf32-rl78.c, * elf32-rx.c,
1912 * elf32-score.c, * elf32-score7.c, * elf32-sh-symbian.c,
1913 * elf32-sh.c, * elf32-spu.c, * elf32-v850.c, * elf32-xtensa.c,
1914 * elf64-alpha.c, * elf64-ia64-vms.c, * elf64-mmix.c,
1915 * elf64-sh64.c, * elf64-sparc.c, * elfnn-ia64.c, * elfxx-tilegx.c,
1916 * mmo.c, * osf-core.c, * srec.c, * vms-alpha.c: Standardize
1917 error/warning messages.
1919 2018-02-26 Alan Modra <amodra@gmail.com>
1921 * archive.c, * bfd.c, * linker.c, * reloc.c, * stabs.c,
1922 * syms.c: Standardize error/warning messages.
1924 2018-02-26 Alan Modra <amodra@gmail.com>
1926 * aout-adobe.c, * aout-cris.c, * i386linux.c, * m68klinux.c,
1927 * sparclinux.c, * coff-alpha.c, * coff-arm.c, * coff-mcore.c,
1928 * coffcode.h, * coffgen.c, * cofflink.c, * ecoff.c, * pe-mips.c,
1929 * peXXigen.c, * peicode.h: Standardize error/warning messages.
1931 2018-02-26 Alan Modra <amodra@gmail.com>
1933 * elf32-arm.c, * elfnn-aarch64.c: Standardize error/warning messages.
1935 2018-02-26 Alan Modra <amodra@gmail.com>
1937 * elfxx-mips.c: Standardize error/warning messages.
1939 2018-02-26 Alan Modra <amodra@gmail.com>
1941 * dwarf2.c, * elf-attrs.c, * elf-eh-frame.c, * elf.c, * elf32-gen.c,
1942 * elflink.c: Standardize error/warning messages. Replace use of
1943 linker callback einfo with _bfd_error_handler when possible.
1945 2018-02-26 Alan Modra <amodra@gmail.com>
1947 * aoutx.h, * coff-alpha.c, * coff-i860.c, * coff-m68k.c,
1948 * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c, * coff-sh.c,
1949 * coff-tic4x.c, * coff-tic54x.c, * coff-tic80.c, * coff-w65.c,
1950 * elf-bfd.h, * elf-m10300.c, * elf.c, * elf32-avr.c, * elf32-bfin.c,
1951 * elf32-cr16.c, * elf32-cr16c.c, * elf32-cris.c, * elf32-crx.c,
1952 * elf32-d10v.c, * elf32-d30v.c, * elf32-dlx.c, * elf32-epiphany.c,
1953 * elf32-fr30.c, * elf32-frv.c, * elf32-i370.c, * elf32-i386.c,
1954 * elf32-i960.c, * elf32-ip2k.c, * elf32-iq2000.c, * elf32-lm32.c,
1955 * elf32-m32c.c, * elf32-m32r.c, * elf32-m68hc11.c, * elf32-m68hc12.c,
1956 * elf32-m68k.c, * elf32-mcore.c, * elf32-mep.c, * elf32-metag.c,
1957 * elf32-microblaze.c, * elf32-mips.c, * elf32-moxie.c,
1958 * elf32-msp430.c, * elf32-mt.c, * elf32-nds32.c, * elf32-or1k.c,
1959 * elf32-pj.c, * elf32-ppc.c, * elf32-rl78.c, * elf32-rx.c,
1960 * elf32-s390.c, * elf32-sh.c, * elf32-spu.c, * elf32-tic6x.c,
1961 * elf32-v850.c, * elf32-vax.c, * elf32-visium.c, * elf32-wasm32.c,
1962 * elf32-xgate.c, * elf32-xtensa.c, * elf64-alpha.c,
1963 * elf64-ia64-vms.c, * elf64-mips.c, * elf64-mmix.c,
1964 * elf64-ppc.c, * elf64-s390.c, * elf64-sparc.c, * elf64-x86-64.c,
1965 * elfn32-mips.c, * elfnn-aarch64.c, * elfnn-ia64.c,
1966 * elfnn-riscv.c, * elfxx-mips.c, * elfxx-riscv.c, * elfxx-riscv.h,
1967 * elfxx-sparc.c, * elfxx-sparc.h, * reloc.c: Standardize
1968 unrecognized/unsupported reloc message.
1970 2018-02-26 Alan Modra <amodra@gmail.com>
1972 * elf32-ppc.c: Standardize error/warning messages. Use
1973 _bfd_error_handler rather than einfo when einfo features not used.
1974 * elf64-ppc.c: Likewise.
1976 2018-02-23 Alan Modra <amodra@gmail.com>
1979 * elf.c (assign_file_positions_for_non_load_sections): Remove RELRO
1980 segment if no matching LOAD segment.
1982 2018-02-23 Kuan-Lin Chen <kuanlinchentw@gmail.com>
1984 * elf32-nds32.h: Define mask for ict_model.
1986 2018-02-20 Jason Duerstock <jason.duerstock@gmail.com>
1988 * elfnn-ia64.c (elf_backend_can_gc_sections): Enable.
1990 2018-02-19 Maciej W. Rozycki <macro@mips.com>
1993 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
1995 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
1996 .reginfo section has wrong size.
1998 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2000 * elfxx-mips.c (_bfd_mips_elf_always_size_sections): Set
2001 SEC_FIXED_SIZE and SEC_HAS_CONTENTS flags for `.reginfo' and
2002 `.MIPS.abiflags' sections.
2003 (_bfd_mips_elf_final_link): Avoid reading beyond `.reginfo'
2006 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2008 * section.c (SEC_FIXED_SIZE): New macro.
2009 * bfd-in2.h: Regenerate.
2011 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2013 * section.c (SEC_HAS_GOT_REF): Remove macro.
2014 * bfd-in2.h: Regenerate.
2016 2018-02-19 Alan Modra <amodra@gmail.com>
2018 * elf-attrs.c (_bfd_elf_parse_attributes): Correct _bfd_error_handler
2020 * elfxx-mips.c (_bfd_mips_elf_final_link): Likewise.
2021 * elfnn-riscv.c (_bfd_riscv_relax_align): Likewise.
2022 (_bfd_riscv_relax_pc): Likewise and fix typos.
2023 * libbfd-in.h (_bfd_error_handler): Add attribute printf.
2024 * libbfd.h: Regenerate.
2026 2018-02-19 Alan Modra <amodra@gmail.com>
2028 * dwarf2.c (read_section): Don't use 'll' format modifier.
2029 (find_abstract_instance): Likewise.
2030 * elfcore.h (elf_core_file_p): Likewise.
2032 2018-02-19 Alan Modra <amodra@gmail.com>
2034 * bfd-in.h: Include inttypes.h or if not available define
2035 PRId64, PRIu64 and PRIx64.
2036 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Remove support for L
2037 modifier to print bfd_vma.
2038 * coff-arm.c, * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c,
2039 * coff-sh.c, * coff-tic80.c, * coffcode.h, * coffgen.c, * cofflink.c,
2040 * compress.c, * dwarf2.c, * elf-m10300.c, * elf.c, * elf32-arc.c,
2041 * elf32-arm.c, * elf32-bfin.c, * elf32-cris.c, * elf32-hppa.c,
2042 * elf32-i386.c, * elf32-ip2k.c, * elf32-lm32.c, * elf32-m32r.c,
2043 * elf32-m68k.c, * elf32-metag.c, * elf32-nds32.c, * elf32-nios2.c,
2044 * elf32-ppc.c, * elf32-rx.c, * elf32-s390.c, * elf32-score.c,
2045 * elf32-score7.c, * elf32-sh.c, * elf32-sh64.c, * elf32-spu.c,
2046 * elf32-tic6x.c, * elf32-tilepro.c, * elf32-v850.c, * elf32-vax.c,
2047 * elf32-xtensa.c, * elf64-alpha.c, * elf64-hppa.c, * elf64-ia64-vms.c,
2048 * elf64-mmix.c, * elf64-s390.c, * elf64-sh64.c, * elf64-x86-64.c,
2049 * elfcode.h, * elfcore.h, * elflink.c, * elfnn-aarch64.c,
2050 * elfnn-ia64.c, * elfnn-riscv.c, * elfxx-mips.c, * elfxx-sparc.c,
2051 * elfxx-tilegx.c, * ieee.c, * ihex.c, * mach-o.c, * merge.c, * mmo.c,
2052 * peXXigen.c, * xcofflink.c: Replace use of Lx modifier with PRIx64,
2053 and cast input to uint64_t, and similarly for Ld and Lu.
2054 * bfd-in2.h: Regenerate.
2056 2018-02-19 Alan Modra <amodra@gmail.com>
2058 * elf32-arm.c, * elf32-hppa.c, * elf32-lm32.c, * elf32-m32r.c,
2059 * elf32-metag.c, * elf32-nds32.c, * elf32-or1k.c, * elf32-ppc.c,
2060 * elf32-s390.c, * elf32-sh.c, * elf32-tic6x.c, * elf32-tilepro.c,
2061 * elf64-ppc.c, * elf64-s390.c, * elflink.c, * elfnn-aarch64.c,
2062 * elfnn-riscv.c, * elfxx-sparc.c, * elfxx-tilegx.c, * elfxx-x86.c,
2063 * reloc.c: Replace use of %R and %T in format strings passed to
2064 einfo and friends by %pR and %pT.
2066 2018-02-19 Alan Modra <amodra@gmail.com>
2068 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Handle %pA and %pB in place
2070 * aout-adobe.c: Update all messages using %A and %B.
2071 * aout-cris.c: Likewise.
2072 * aoutx.h: Likewise.
2073 * archive.c: Likewise.
2074 * binary.c: Likewise.
2075 * cache.c: Likewise.
2076 * coff-alpha.c: Likewise.
2077 * coff-arm.c: Likewise.
2078 * coff-i860.c: Likewise.
2079 * coff-mcore.c: Likewise.
2080 * coff-ppc.c: Likewise.
2081 * coff-rs6000.c: Likewise.
2082 * coff-sh.c: Likewise.
2083 * coff-tic4x.c: Likewise.
2084 * coff-tic54x.c: Likewise.
2085 * coff-tic80.c: Likewise.
2086 * coff64-rs6000.c: Likewise.
2087 * coffcode.h: Likewise.
2088 * coffgen.c: Likewise.
2089 * cofflink.c: Likewise.
2090 * coffswap.h: Likewise.
2091 * compress.c: Likewise.
2092 * cpu-arm.c: Likewise.
2093 * ecoff.c: Likewise.
2094 * elf-attrs.c: Likewise.
2095 * elf-eh-frame.c: Likewise.
2096 * elf-ifunc.c: Likewise.
2097 * elf-m10300.c: Likewise.
2098 * elf-properties.c: Likewise.
2099 * elf-s390-common.c: Likewise.
2101 * elf32-arc.c: Likewise.
2102 * elf32-arm.c: Likewise.
2103 * elf32-avr.c: Likewise.
2104 * elf32-bfin.c: Likewise.
2105 * elf32-cr16.c: Likewise.
2106 * elf32-cr16c.c: Likewise.
2107 * elf32-cris.c: Likewise.
2108 * elf32-crx.c: Likewise.
2109 * elf32-d10v.c: Likewise.
2110 * elf32-d30v.c: Likewise.
2111 * elf32-epiphany.c: Likewise.
2112 * elf32-fr30.c: Likewise.
2113 * elf32-frv.c: Likewise.
2114 * elf32-gen.c: Likewise.
2115 * elf32-hppa.c: Likewise.
2116 * elf32-i370.c: Likewise.
2117 * elf32-i386.c: Likewise.
2118 * elf32-i960.c: Likewise.
2119 * elf32-ip2k.c: Likewise.
2120 * elf32-iq2000.c: Likewise.
2121 * elf32-lm32.c: Likewise.
2122 * elf32-m32c.c: Likewise.
2123 * elf32-m32r.c: Likewise.
2124 * elf32-m68hc11.c: Likewise.
2125 * elf32-m68hc12.c: Likewise.
2126 * elf32-m68hc1x.c: Likewise.
2127 * elf32-m68k.c: Likewise.
2128 * elf32-mcore.c: Likewise.
2129 * elf32-mep.c: Likewise.
2130 * elf32-metag.c: Likewise.
2131 * elf32-microblaze.c: Likewise.
2132 * elf32-moxie.c: Likewise.
2133 * elf32-msp430.c: Likewise.
2134 * elf32-mt.c: Likewise.
2135 * elf32-nds32.c: Likewise.
2136 * elf32-nios2.c: Likewise.
2137 * elf32-or1k.c: Likewise.
2138 * elf32-pj.c: Likewise.
2139 * elf32-ppc.c: Likewise.
2140 * elf32-rl78.c: Likewise.
2141 * elf32-rx.c: Likewise.
2142 * elf32-s390.c: Likewise.
2143 * elf32-score.c: Likewise.
2144 * elf32-score7.c: Likewise.
2145 * elf32-sh-symbian.c: Likewise.
2146 * elf32-sh.c: Likewise.
2147 * elf32-sh64.c: Likewise.
2148 * elf32-sparc.c: Likewise.
2149 * elf32-spu.c: Likewise.
2150 * elf32-tic6x.c: Likewise.
2151 * elf32-tilepro.c: Likewise.
2152 * elf32-v850.c: Likewise.
2153 * elf32-vax.c: Likewise.
2154 * elf32-visium.c: Likewise.
2155 * elf32-wasm32.c: Likewise.
2156 * elf32-xgate.c: Likewise.
2157 * elf32-xtensa.c: Likewise.
2158 * elf64-alpha.c: Likewise.
2159 * elf64-gen.c: Likewise.
2160 * elf64-hppa.c: Likewise.
2161 * elf64-ia64-vms.c: Likewise.
2162 * elf64-mmix.c: Likewise.
2163 * elf64-ppc.c: Likewise.
2164 * elf64-s390.c: Likewise.
2165 * elf64-sh64.c: Likewise.
2166 * elf64-sparc.c: Likewise.
2167 * elf64-x86-64.c: Likewise.
2168 * elfcode.h: Likewise.
2169 * elfcore.h: Likewise.
2170 * elflink.c: Likewise.
2171 * elfnn-aarch64.c: Likewise.
2172 * elfnn-ia64.c: Likewise.
2173 * elfnn-riscv.c: Likewise.
2174 * elfxx-mips.c: Likewise.
2175 * elfxx-sparc.c: Likewise.
2176 * elfxx-tilegx.c: Likewise.
2177 * elfxx-x86.c: Likewise.
2178 * hpux-core.c: Likewise.
2181 * libbfd.c: Likewise.
2182 * linker.c: Likewise.
2183 * mach-o.c: Likewise.
2184 * merge.c: Likewise.
2186 * oasys.c: Likewise.
2187 * pdp11.c: Likewise.
2188 * pe-mips.c: Likewise.
2189 * peXXigen.c: Likewise.
2190 * peicode.h: Likewise.
2191 * reloc.c: Likewise.
2192 * rs6000-core.c: Likewise.
2194 * stabs.c: Likewise.
2195 * vms-alpha.c: Likewise.
2196 * xcofflink.c: Likewise.
2198 2018-02-19 Alan Modra <amodra@gmail.com>
2201 * elf.c (IS_TBSS): Define.
2202 (_bfd_elf_map_sections_to_segments): Use IS_TBSS.
2203 (assign_file_positions_for_non_load_sections): Revert last change.
2204 Properly calculate load segment limits to compare against relro limits.
2206 2018-02-17 Alan Modra <amodra@gmail.com>
2209 * elf.c (assign_file_positions_for_non_load_sections): Ignore
2210 degenerate zero size PT_LOAD segments when finding one overlapping
2211 the PT_GNU_RELRO segment.
2213 2018-02-16 Alan Modra <amodra@gmail.com>
2215 * libbfd.c (_bfd_bool_bfd_false_error): Rename from bfd_false.
2216 (_bfd_bool_bfd_true): Rename from bfd_true.
2217 (_bfd_ptr_bfd_null_error): Rename from bfd_nullvoidptr.
2218 (_bfd_int_bfd_0): Rename from bfd_0.
2219 (_bfd_uint_bfd_0): Rename from bfd_0u.
2220 (_bfd_long_bfd_0): Rename from bfd_0l.
2221 (_bfd_long_bfd_n1_error): Rename from _bfd_n1.
2222 (_bfd_void_bfd): Rename from bfd_void.
2223 (_bfd_bool_bfd_false, _bfd_bool_bfd_asymbol_false),
2224 (_bfd_bool_bfd_link_false_error),
2225 (_bfd_bool_bfd_link_true, _bfd_bool_bfd_bfd_true),
2226 (_bfd_bool_bfd_uint_true, _bfd_bool_bfd_ptr_true),
2227 (_bfd_bool_bfd_asection_bfd_asection_true),
2228 (_bfd_bool_bfd_asymbol_bfd_asymbol_true),
2229 (_bfd_void_bfd_link, _bfd_void_bfd_asection): New functions.
2230 * archive.c (_bfd_noarchive_get_elt_at_index),
2231 (_bfd_noarchive_openr_next_archived_file),
2232 (_bfd_noarchive_construct_extended_name_table),
2233 (_bfd_noarchive_write_ar_hdr, _bfd_noarchive_truncate_arname),
2234 (_bfd_noarchive_write_armap): New functions.
2235 * archures.c (_bfd_nowrite_set_arch_mach): New function.
2236 * coff-alpha.c (alpha_ecoff_swap_coff_aux_in),
2237 (alpha_ecoff_swap_coff_sym_in, alpha_ecoff_swap_coff_lineno_in),
2238 (alpha_ecoff_swap_coff_aux_out, alpha_ecoff_swap_coff_sym_out),
2239 (alpha_ecoff_swap_coff_lineno_out),
2240 (alpha_ecoff_swap_coff_reloc_out): New functions.
2241 * coff-mips.c (mips_ecoff_swap_coff_aux_in),
2242 (mips_ecoff_swap_coff_sym_in, mips_ecoff_swap_coff_lineno_in),
2243 (mips_ecoff_swap_coff_aux_out, mips_ecoff_swap_coff_sym_out),
2244 (mips_ecoff_swap_coff_lineno_out),
2245 (mips_ecoff_swap_coff_reloc_out): New functions.
2246 * coffcode.h (coff_set_alignment_hook): Replace define with
2248 (symname_in_debug_hook): Likewise.
2249 * ecoff.c (_bfd_ecoff_set_alignment_hook): New function.
2250 * elfxx-target.h (elf_backend_allow_non_load_phdr): Default to 0.
2251 * elf.c (assign_file_positions_except_relocs): Test
2252 elf_backend_allow_non_load_phdr for NULL.
2253 * elflink.c (_bfd_elf_omit_section_dynsym_default): Rename from
2254 _bfd_elf_link_omit_section_dynsym. Update uses.
2255 (_bfd_elf_omit_section_dynsym_all): New function.
2256 * elf-bfd.h (_bfd_elf_link_omit_section_dynsym): Delete.
2257 (_bfd_elf_omit_section_dynsym_default): Declare.
2258 (_bfd_elf_omit_section_dynsym_all): Declare.
2259 * linker.c (_bfd_nolink_sizeof_headers, _bfd_nolink_bfd_relax_section),
2260 (_bfd_nolink_bfd_get_relocated_section_contents),
2261 (_bfd_nolink_bfd_lookup_section_flags),
2262 (_bfd_nolink_bfd_is_group_section, _bfd_nolink_bfd_discard_group),
2263 (_bfd_nolink_bfd_link_hash_table_create),
2264 (_bfd_nolink_bfd_link_just_syms),
2265 (_bfd_nolink_bfd_copy_link_hash_symbol_type),
2266 (_bfd_nolink_bfd_link_split_section),
2267 (_bfd_nolink_section_already_linked),
2268 (_bfd_nolink_bfd_define_common_symbol),
2269 (_bfd_nolink_bfd_define_start_stop): New functions.
2270 * reloc.c (_bfd_norelocs_bfd_reloc_type_lookup),
2271 (_bfd_norelocs_bfd_reloc_name_lookup),
2272 (_bfd_nodynamic_canonicalize_dynamic_reloc): New functions.
2273 * section.c (_bfd_nowrite_set_section_contents): New function.
2274 * syms.c (_bfd_nosymbols_canonicalize_symtab),
2275 (_bfd_nosymbols_print_symbol, _bfd_nosymbols_get_symbol_info),
2276 (_bfd_nosymbols_get_symbol_version_string),
2277 (_bfd_nosymbols_bfd_is_local_label_name),
2278 (_bfd_nosymbols_get_lineno, _bfd_nosymbols_find_nearest_line),
2279 (_bfd_nosymbols_find_line, _bfd_nosymbols_find_inliner_info),
2280 (_bfd_nosymbols_bfd_make_debug_symbol),
2281 ( _bfd_nosymbols_read_minisymbols),
2282 ( _bfd_nosymbols_minisymbol_to_symbol),
2283 (_bfd_nodynamic_get_synthetic_symtab): New functions.
2284 * libbfd-in.h: Declare new functions. Update existing defines,
2286 * aix386-core.c: Update to use new hooks. Formatting.
2287 * aout-adobe.c: Likewise.
2288 * aout-arm.c: Likewise.
2289 * aout-target.h: Likewise.
2290 * aout-tic30.c: Likewise.
2291 * aoutf1.h: Likewise.
2292 * binary.c: Likewise.
2294 * cisco-core.c: Likewise.
2295 * coff-alpha.c: Likewise.
2296 * coff-i386.c: Likewise.
2297 * coff-i860.c: Likewise.
2298 * coff-i960.c: Likewise.
2299 * coff-ia64.c: Likewise.
2300 * coff-mips.c: Likewise.
2301 * coff-ppc.c: Likewise.
2302 * coff-rs6000.c: Likewise.
2303 * coff-sh.c: Likewise.
2304 * coff-tic30.c: Likewise.
2305 * coff-tic54x.c: Likewise.
2306 * coff-x86_64.c: Likewise.
2307 * coff64-rs6000.c: Likewise.
2308 * coffcode.h: Likewise.
2309 * elf-m10300.c: Likewise.
2310 * elf32-cr16.c: Likewise.
2311 * elf32-lm32.c: Likewise.
2312 * elf32-m32r.c: Likewise.
2313 * elf32-metag.c: Likewise.
2314 * elf32-score.c: Likewise.
2315 * elf32-score7.c: Likewise.
2316 * elf32-tilepro.c: Likewise.
2317 * elf32-xstormy16.c: Likewise.
2318 * elf32-xtensa.c: Likewise.
2319 * elf64-alpha.c: Likewise.
2320 * elf64-hppa.c: Likewise.
2321 * elf64-ia64-vms.c: Likewise.
2322 * elf64-mmix.c: Likewise.
2323 * elf64-sh64.c: Likewise.
2324 * elfnn-ia64.c: Likewise.
2325 * elfxx-sparc.c: Likewise.
2326 * elfxx-target.h: Likewise.
2327 * elfxx-tilegx.c: Likewise.
2328 * elfxx-x86.h: Likewise.
2329 * hp300hpux.c: Likewise.
2330 * hppabsd-core.c: Likewise.
2331 * hpux-core.c: Likewise.
2332 * i386msdos.c: Likewise.
2333 * i386os9k.c: Likewise.
2336 * irix-core.c: Likewise.
2337 * libaout.h: Likewise.
2338 * libecoff.h: Likewise.
2339 * mach-o-target.c: Likewise.
2340 * mach-o.c: Likewise.
2341 * mipsbsd.c: Likewise.
2343 * netbsd-core.c: Likewise.
2344 * nlm-target.h: Likewise.
2345 * oasys.c: Likewise.
2346 * osf-core.c: Likewise.
2347 * pdp11.c: Likewise.
2348 * pe-mips.c: Likewise.
2349 * pe-x86_64.c: Likewise.
2351 * plugin.c: Likewise.
2352 * ppcboot.c: Likewise.
2353 * ptrace-core.c: Likewise.
2354 * sco5-core.c: Likewise.
2356 * sparclynx.c: Likewise.
2358 * tekhex.c: Likewise.
2359 * trad-core.c: Likewise.
2360 * verilog.c: Likewise.
2361 * versados.c: Likewise.
2362 * vms-alpha.c: Likewise.
2363 * vms-lib.c: Likewise.
2364 * wasm-module.c: Likewise.
2366 * libbfd.h: Regenerate.
2368 2018-02-15 Jim Wilson <jimw@sifive.com>
2370 * elfnn-riscv.c (_bfd_riscv_relax_section): Ifdef out check to ignore
2371 symbols whose section address is zero.
2373 * elfnn-riscv.c (riscv_elf_relocate_section): Use bfd_reloc_dangerous
2374 when pcrel_lo reloc has an addend. Use reloc_dangerous callback for
2375 bfd_reloc_dangerous. Use einfo instead of warning callback for errors.
2376 Add %X%P to error messages.
2378 2018-02-15 Eric Botcazou <ebotcazou@adacore.com>
2381 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
2382 Pass FALSE instead of TRUE as 'create' argument to bfd_link_hash_lookup
2383 and assert that the result of the call is not NULL.
2385 2018-02-14 Nick Clifton <nickc@redhat.com>
2388 Revert previous delta. Add extra casts to avoid compile time
2390 * libbfd-in.h (_bfd_generic_bfd_copy_private_bfd_data): Add extra
2391 cast to avoid warning from gcc v8 compiler.
2392 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
2393 (_bfd_generic_bfd_set_private_flags): Likewise.
2394 (_bfd_generic_bfd_copy_private_section_data): Likewise.
2395 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
2396 (_bfd_generic_bfd_copy_private_header_data): Likewise.
2397 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
2398 (_bfd_noarchive_construct_extended_name_table): Likewise.
2399 (_bfd_noarchive_truncate_arname): Likewise.
2400 (_bfd_noarchive_write_ar_hdr): Likewise.
2401 (_bfd_noarchive_get_elt_at_index): Likewise.
2402 (_bfd_nosymbols_canonicalize_symtab): Likewise.
2403 (_bfd_nosymbols_print_symbol): Likewise.
2404 (_bfd_nosymbols_get_symbol_info): Likewise.
2405 (_bfd_nosymbols_get_symbol_version_string): Likewise.
2406 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
2407 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
2408 (_bfd_nosymbols_get_lineno): Likewise.
2409 (_bfd_nosymbols_find_nearest_line): Likewise.
2410 (_bfd_nosymbols_find_line): Likewise.
2411 (_bfd_nosymbols_find_inliner_info): Likewise.
2412 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
2413 (_bfd_nosymbols_read_minisymbols): Likewise.
2414 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
2415 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
2416 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
2417 (_bfd_nowrite_set_arch_mach): Likewise.
2418 (_bfd_nowrite_set_section_contents): Likewise.
2419 (_bfd_nolink_sizeof_headers): Likewise.
2420 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
2421 (_bfd_nolink_bfd_relax_section): Likewise.
2422 (_bfd_nolink_bfd_gc_sections): Likewise.
2423 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
2424 (_bfd_nolink_bfd_merge_sections): Likewise.
2425 (_bfd_nolink_bfd_is_group_section): Likewise.
2426 (_bfd_nolink_bfd_discard_group): Likewise.
2427 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
2428 (_bfd_nolink_bfd_link_add_symbols): Likewise.
2429 (_bfd_nolink_bfd_link_just_syms): Likewise.
2430 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
2431 (_bfd_nolink_bfd_final_link): Likewise.
2432 (_bfd_nolink_bfd_link_split_section): Likewise.
2433 (_bfd_nolink_section_already_linked): Likewise.
2434 (_bfd_nolink_bfd_define_common_symbol): Likewise.
2435 (_bfd_nolink_bfd_define_start_stop): Likewise.
2436 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
2437 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
2438 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
2439 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
2440 * libbfd.c (bfd_false_any): Delete.
2441 (bfd_true_any, bfd_nullvoidptr_any, bfd_0_any): Delete.
2442 (bfd_0u_any, bfd_0l_any, _bfd_n1_any, bfd_void_any): Delete.
2443 * libbfd.h (extern): Regenerate
2444 * aout-target.h (MY_bfd_is_target_special_symbol): Add extra
2445 cast to avoid warning from gcc v8 compiler.
2446 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
2447 * binary.c (binary_get_symbol_info): Likewise.
2448 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
2449 * coff-mips.c (mips_ecoff_backend_data): Likewise.
2450 * coffcode.h (coff_set_alignment_hook): Likewise.
2451 (symname_in_debug_hook): Likewise.
2452 (bfd_coff_backend_data bigobj_swap_table): Likewise.
2453 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
2454 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
2455 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
2456 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
2457 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
2458 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
2459 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
2460 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
2461 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
2462 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
2463 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
2464 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
2465 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
2466 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
2467 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
2468 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
2469 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
2470 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
2471 (bfd_elfNN_bfd_set_private_flags): Likewise.
2472 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
2473 (elf_backend_init_index_section): Likewise.
2474 (elf_backend_allow_non_load_phdr): Likewise.
2475 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
2476 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
2477 * ieee.c (ieee_construct_extended_name_table): Likewise.
2478 (ieee_write_armap): Likewise.
2479 (ieee_write_ar_hdr): Likewise.
2480 (ieee_bfd_is_target_special_symbol): Likewise.
2481 * ihex.c (ihex_canonicalize_symtab): Likewise.
2482 (ihex_bfd_is_target_special_symbol): Likewise.
2483 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
2484 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
2485 (_bfd_ecoff_set_alignment_hook): Likewise.
2486 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
2487 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
2488 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
2489 * oasys.c (oasys_construct_extended_name_table): Likewise.
2490 (oasys_write_armap): Likewise.
2491 (oasys_write_ar_hdr): Likewise.
2492 (oasys_bfd_is_target_special_symbol): Likewise.
2493 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
2494 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
2495 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
2496 * som.c (som_bfd_is_target_special_symbol): Likewise.
2497 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
2498 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
2499 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
2500 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
2501 (versados_bfd_reloc_name_lookup): Likewise.
2502 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
2503 (vms_bfd_define_start_stop): Likewise.
2504 (alpha_vms_bfd_is_target_special_symbol): Likewise.
2505 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
2506 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
2508 2018-02-14 H.J. Lu <hongjiu.lu@intel.com>
2511 * elf32-i386.c (elf_i386_check_relocs): Pass FALSE for non
2512 PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
2513 * elf64-x86-64.c (elf_x86_64_check_relocs): Create PLT for
2514 R_X86_64_PC32 reloc against dynamic function in data section.
2515 Pass TRUE for PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
2516 (elf_x86_64_relocate_section): Use PLT for R_X86_64_PC32 reloc
2517 against dynamic function in data section.
2518 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Use PLT in PIE as
2519 function address only if pcrel_plt is true.
2520 (_bfd_x86_elf_link_hash_table_create): Set pcrel_plt.
2521 * elfxx-x86.h (NEED_DYNAMIC_RELOCATION_P): Add PCREL_PLT for
2522 PC-relative PLT. If PLT is PC-relative, don't generate dynamic
2523 PC-relative relocation against a function definition in data
2524 secton in PIE. Remove the obsolete comments.
2525 (elf_x86_link_hash_table): Add pcrel_plt.
2527 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
2529 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Check bfd_link_dll,
2530 instead of bfd_link_pic, for building shared library.
2532 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
2535 * elf64-x86-64.c (is_32bit_relative_branch): Removed.
2536 (elf_x86_64_relocate_section): Check PIC relocations in PIE.
2537 Remove is_32bit_relative_branch usage. Disallow PC32 reloc
2538 against protected function in shared object.
2540 2018-02-13 Sergei Trofimovich <slyfox@inbox.ru>
2543 * po/ru.po: Fix typo in Russian translation.
2545 2018-02-13 Maciej W. Rozycki <macro@mips.com>
2547 * wasm-module.c (wasm_scan_name_function_section): Rename
2548 `index' local variable to `idx'.
2550 2018-02-13 Nick Clifton <nickc@redhat.com>
2553 Fix compile time warnings generated by gcc version 8.
2554 * libbfd-in.h: Remove extraneous text from prototypes.
2555 Add prototypes for bfd_false_any, bfd_true_any,
2556 bfd_nullvoidptr_any, bfd_0_any, bfd_0u_any, bfd_0l_any,
2557 bfd_n1_any, bfd_void_any.
2558 (_bfd_generic_bfd_copy_private_bfd_data): Use vararg based dummy
2560 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
2561 (_bfd_generic_bfd_set_private_flags): Likewise.
2562 (_bfd_generic_bfd_copy_private_section_data): Likewise.
2563 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
2564 (_bfd_generic_bfd_copy_private_header_data): Likewise.
2565 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
2566 (_bfd_noarchive_construct_extended_name_table): Likewise.
2567 (_bfd_noarchive_truncate_arname): Likewise.
2568 (_bfd_noarchive_write_ar_hdr): Likewise.
2569 (_bfd_noarchive_get_elt_at_index): Likewise.
2570 (_bfd_nosymbols_canonicalize_symtab): Likewise.
2571 (_bfd_nosymbols_print_symbol): Likewise.
2572 (_bfd_nosymbols_get_symbol_info): Likewise.
2573 (_bfd_nosymbols_get_symbol_version_string): Likewise.
2574 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
2575 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
2576 (_bfd_nosymbols_get_lineno): Likewise.
2577 (_bfd_nosymbols_find_nearest_line): Likewise.
2578 (_bfd_nosymbols_find_line): Likewise.
2579 (_bfd_nosymbols_find_inliner_info): Likewise.
2580 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
2581 (_bfd_nosymbols_read_minisymbols): Likewise.
2582 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
2583 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
2584 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
2585 (_bfd_nowrite_set_arch_mach): Likewise.
2586 (_bfd_nowrite_set_section_contents): Likewise.
2587 (_bfd_nolink_sizeof_headers): Likewise.
2588 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
2589 (_bfd_nolink_bfd_relax_section): Likewise.
2590 (_bfd_nolink_bfd_gc_sections): Likewise.
2591 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
2592 (_bfd_nolink_bfd_merge_sections): Likewise.
2593 (_bfd_nolink_bfd_is_group_section): Likewise.
2594 (_bfd_nolink_bfd_discard_group): Likewise.
2595 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
2596 (_bfd_nolink_bfd_link_add_symbols): Likewise.
2597 (_bfd_nolink_bfd_link_just_syms): Likewise.
2598 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
2599 (_bfd_nolink_bfd_final_link): Likewise.
2600 (_bfd_nolink_bfd_link_split_section): Likewise.
2601 (_bfd_nolink_section_already_linked): Likewise.
2602 (_bfd_nolink_bfd_define_common_symbol): Likewise.
2603 (_bfd_nolink_bfd_define_start_stop): Likewise.
2604 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
2605 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
2606 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
2607 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
2608 * libbfd.c (bfd_false_any): New function. Like bfd_false but
2609 accepts one or more arguments.
2610 (bfd_true_any): Likewise.
2611 (bfd_nullvoidptr_any): Likewise.
2612 (bfd_0_any): Likewise.
2613 (bfd_0u_any): Likewise.
2614 (bfd_0l_any): Likewise.
2615 (_bfd_n1_any): Likewise.
2616 (bfd_void_any): Likewise.
2617 * libbfd.h (extern): Regenerate
2618 * aout-target.h (MY_bfd_is_target_special_symbol): Use vararg
2619 based dummy function.
2620 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
2621 * binary.c (binary_get_symbol_info): Likewise.
2622 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
2623 * coff-mips.c (mips_ecoff_backend_data): Likewise.
2624 * coffcode.h (coff_set_alignment_hook): Likewise.
2625 (symname_in_debug_hook): Likewise.
2626 (bfd_coff_backend_data bigobj_swap_table): Likewise.
2627 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
2628 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
2629 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
2630 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
2631 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
2632 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
2633 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
2634 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
2635 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
2636 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
2637 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
2638 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
2639 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
2640 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
2641 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
2642 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
2643 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
2644 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
2645 (bfd_elfNN_bfd_set_private_flags): Likewise.
2646 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
2647 (elf_backend_init_index_section): Likewise.
2648 (elf_backend_allow_non_load_phdr): Likewise.
2649 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
2650 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
2651 * ieee.c (ieee_construct_extended_name_table): Likewise.
2652 (ieee_write_armap): Likewise.
2653 (ieee_write_ar_hdr): Likewise.
2654 (ieee_bfd_is_target_special_symbol): Likewise.
2655 * ihex.c (ihex_canonicalize_symtab): Likewise.
2656 (ihex_bfd_is_target_special_symbol): Likewise.
2657 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
2658 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
2659 (_bfd_ecoff_set_alignment_hook): Likewise.
2660 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
2661 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
2662 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
2663 * oasys.c (oasys_construct_extended_name_table): Likewise.
2664 (oasys_write_armap): Likewise.
2665 (oasys_write_ar_hdr): Likewise.
2666 (oasys_bfd_is_target_special_symbol): Likewise.
2667 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
2668 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
2669 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
2670 * som.c (som_bfd_is_target_special_symbol): Likewise.
2671 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
2672 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
2673 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
2674 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
2675 (versados_bfd_reloc_name_lookup): Likewise.
2676 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
2677 (vms_bfd_define_start_stop): Likewise.
2678 (alpha_vms_bfd_is_target_special_symbol): Likewise.
2679 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
2680 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
2681 * elf32-arc.c (get_replace_function): Assign replacement function
2683 * elf32-i370.c (i370_noop): Update prototype.
2685 2018-02-13 Alan Modra <amodra@gmail.com>
2688 * elf.c (_bfd_elf_fixup_group_sections): Account for removed
2689 relocation sections. If size reduces to just the flag word,
2690 remove that too and mark with SEC_EXCLUDE.
2691 * elflink.c (bfd_elf_final_link): Strip empty group sections.
2693 2018-02-13 Alan Modra <amodra@gmail.com>
2696 * elf.c (assign_file_positions_for_non_load_sections): Rewrite
2699 2018-02-12 Zebediah Figura <z.figura12@gmail.com>
2701 * i386msdos.c (msdos_mkobject); New function.
2702 (msdos_object_p): New function.
2703 (i386_msdos_vec): Use msdos_object_p as the check_format
2705 * peicode.h: Rename external_PEI_DOS_hdr, DOSMAGIC, and
2706 NT_SIGNATURE to external_DOS_hdr, IMAGE_DOS_SIGNATURE, and
2708 * peXXigen.c: Likewise.
2709 * coff-ia64.c: Likewise.
2711 2018-02-12 Nick Clifton <nickc@redhat.com>
2713 * elf32-nds32.c (nds32_elf_relax_longjump3): Remove redundant
2715 * elf32-arc.c (elf_arc_relocate_section): Likewise.
2717 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
2719 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Reorder conditions.
2720 (sparc_elf_append_rela): Assert that there is enough room in section.
2721 (_bfd_sparc_elf_copy_indirect_symbol): Fix formatting.
2722 (_bfd_sparc_elf_adjust_dynamic_symbol): Minor tweak.
2723 (allocate_dynrelocs): Remove outdated comments and reorder conditions.
2724 For a symbol subject to a GOT relocation, reserve a slot in the
2725 relocation section if the symbol isn't dynamic and we are in PIC mode.
2726 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: If relocation
2727 is relaxed and a slot was reserved, generate a R_SPARC_NONE relocation.
2728 <R_SPARC_GOTDATA_OP_HIX22>: Adjust comments.
2729 <R_SPARC_PC10>: Reorder conditions. Remove always-false assertion.
2730 (_bfd_sparc_elf_finish_dynamic_symbol): Rename local_undefweak into
2731 resolved_to_zero. Do not generate a dynamic GOT relocation for an
2732 undefined weak symbol with non-default visibility. Remove superfluous
2733 'else' and fix formatting.
2735 2018-02-09 H.J. Lu <hongjiu.lu@intel.com>
2737 * elf32-i386.c (elf_i386_get_synthetic_symtab): Also handle
2739 (i386_elf32_sol2_vec): Don't declare.
2740 (elf_i386_link_setup_gnu_properties): Also handle is_solaris.
2741 Don't set need_global_offset_table.
2742 (elf_i386_solaris_arch_bed): New.
2743 (elf_backend_arch_data): Set to elf_i386_solaris_arch_bed for
2745 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Check
2746 target_os != is_nacl instead of target_os == is_normal.
2747 (x86_64_elf64_sol2_vec): Don't declare.
2748 (elf_x86_64_link_setup_gnu_properties): Check target_os !=
2749 is_nacl instead of target_os == is_normal. Don't set
2750 need_global_offset_table.
2751 (elf_x86_64_solaris_arch_bed): New.
2752 (elf_backend_arch_data): Set to elf_x86_64_solaris_arch_bed for
2754 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep
2755 _GLOBAL_OFFSET_TABLE_ for Solaris.
2756 (_bfd_x86_elf_link_setup_gnu_properties): Don't copy
2757 need_global_offset_table.
2758 * elfxx-x86.h (elf_x86_target_os): Add is_solaris.
2759 (elf_x86_link_hash_table): Remove need_global_offset_table.
2760 (elf_x86_init_table): Likewise.
2762 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
2764 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
2766 (i386_elf32_sol2_vec): Declared.
2767 (elf_i386_link_setup_gnu_properties): Set
2768 need_global_offset_table with info->output_bfd->xvec.
2769 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
2771 (x86_64_elf64_sol2_vec): Declared.
2772 (elf_x86_64_link_setup_gnu_properties): Set
2773 need_global_offset_table with info->output_bfd->xvec.
2775 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
2777 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
2779 (elf_i386_link_setup_gnu_properties): Set need_global_offset_table
2781 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
2783 (elf_x86_64_link_setup_gnu_properties): Set
2784 need_global_offset_table for Solaris.
2785 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep the
2786 unused _GLOBAL_OFFSET_TABLE_ for Solaris.
2787 (_bfd_x86_elf_link_setup_gnu_properties): Copy
2788 need_global_offset_table.
2789 * elfxx-x86.h (elf_x86_link_hash_table): Add
2790 need_global_offset_table.
2791 (elf_x86_init_table): Likewise.
2793 2018-02-08 Jim Wilson <jimw@sifive.com>
2795 * elfnn-riscv.c (riscv_elf_relocate_section): Add comment for previous
2798 2018-02-08 Nick Clifton <nickc@redhat.com>
2801 * elf.c (elf_parse_notes): Reject notes with excessuively large
2804 2018-02-07 Alan Modra <amodra@gmail.com>
2806 Revert 2018-01-17 Alan Modra <amodra@gmail.com>
2807 * elf32-ppc.c: Remove speculation barrier support.
2808 * elf32-ppc.h: Likewise.
2809 * elf64-ppc.c: Likewise.
2810 * elf64-ppc.h: Likewise.
2812 2018-02-06 Jim Wilson <jimw@sifive.com>
2814 * elfnn-riscv.c (riscv_elf_relocate_section): Return TRUE if used
2815 callback to report an error.
2817 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
2820 * elfxx-sparc.c (sparc_elf_tls_transition): Turn call to bfd_link_pic
2821 into call to !bfd_link_executable and tidy up.
2822 (_bfd_sparc_elf_check_relocs): Fix formatting and tidy up.
2823 <R_SPARC_TLS_LE_HIX22>: Turn call to bfd_link_pic into call to
2824 !bfd_link_executable.
2825 <R_SPARC_TLS_IE_HI22>: Likewise.
2826 <GOT relocations>: Remove useless code, tidy and merge related blocks.
2827 <R_SPARC_TLS_GD_CALL>: Turn call to bfd_link_pic into call to
2828 !bfd_link_executable.
2829 <R_SPARC_WPLT30>: Tidy up.
2830 (_bfd_sparc_elf_gc_mark_hook): Turn call to bfd_link_pic into call to
2831 !bfd_link_executable.
2832 (allocate_dynrelocs): Likewise.
2833 (_bfd_sparc_elf_relocate_section): Fix formatting and tidy up.
2834 <R_SPARC_TLS_GD_HI22>: Merge into...
2835 <R_SPARC_TLS_GD_LO10>: ...this. Adjust 4th argument in call to
2836 sparc_elf_tls_transition and remove redundant code.
2837 <R_SPARC_TLS_LDM_HI22>: Turn call to bfd_link_pic into call to
2838 !bfd_link_executable.
2839 <R_SPARC_TLS_LDO_HIX22>: Likewise.
2840 <R_SPARC_TLS_LE_HIX22>: Likewise. Tidy up.
2841 <R_SPARC_TLS_LDM_CALL>: Likewise.
2842 <R_SPARC_TLS_GD_CALL>: Likewise. Tidy up.
2843 <R_SPARC_TLS_GD_ADD>: Likewise.
2844 <R_SPARC_TLS_LDM_ADD>: Likewise.
2845 <R_SPARC_TLS_LDO_ADD>: Likewise.
2846 <R_SPARC_TLS_IE_LD>: Likewise.
2848 2018-02-06 Miloš Stojanović <milos.stojanovic@rt-rk.com>
2851 * elfxx-mips.c (_bfd_mips_elf_find_nearest_line): If the dwarf
2852 functions failed to find the function name, try the generic elf
2853 find function instead.
2855 2018-02-06 Sergio Durigan Junior <sergiodj@redhat.com>
2857 * coff-rs6000.c (xcoff_write_archive_contents_old): Use
2858 'memcpy' instead of 'strncpy' when writing the magic number.
2860 2018-02-06 Nick Clifton <nickc@redhat.com>
2863 * opncls.c (bfd_get_debug_link_info_1): Check the size of the
2864 section before attempting to read it in.
2865 (bfd_get_alt_debug_link_info): Likewise.
2867 2018-02-06 Paul Carroll <pcarroll@codesourcery.com>
2869 * bfd/dwarf2.c (find_abstract_name): Modified to return file and
2870 line information in addition to name, if they can be found.
2872 2018-02-05 Renlin Li <renlin.li@arm.com>
2875 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Relax the
2876 R_AARCH64_ABS32 and R_AARCH64_ABS16 for absolute symbol. Apply the
2877 check for writeable section as well.
2879 2018-02-05 H.J. Lu <hongjiu.lu@intel.com>
2882 * elf32-i386.c (elf_i386_check_relocs): Set got_referenced if
2883 _GLOBAL_OFFSET_TABLE_ is referenced or GOT is needed to resolve
2884 undefined weak symbol to 0.
2885 * elf64-x86-64.c (elf_x86_64_check_relocs): Set got_referenced
2886 if _GLOBAL_OFFSET_TABLE_ is referenced.
2887 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Check
2888 got_referenced instead of ref_regular_nonweak. Remove the
2889 unused _GLOBAL_OFFSET_TABLE_ from symbol table.
2890 * elfxx-x86.h (elf_x86_link_hash_table): Add got_referenced.
2892 2018-02-05 Maciej W. Rozycki <macro@mips.com>
2894 * elfnn-riscv.c (_bfd_riscv_relax_pc): Use `memset' to
2895 initialize `hi_reloc'.
2897 2018-02-05 Maciej W. Rozycki <macro@mips.com>
2899 * elfxx-mips.c (_bfd_mips_elf_section_processing): For
2900 SHT_MIPS_REGINFO sections don't assert the correct size and
2901 report an error instead.
2903 2018-02-05 Maciej W. Rozycki <macro@mips.com>
2905 * elf.c (_bfd_elf_write_object_contents): Propagate a failure
2906 status from `->elf_backend_section_processing'.
2908 2018-02-02 Jim Wilson <jimw@sifive.com>
2911 * elfnn-riscv.c (riscv_relax_delete_bytes): New parameter link_info.
2912 If link_info->wrap_hash, check for a duplicate symbol and ignore.
2913 (_bfd_riscv_relax_call, bfd_riscv_relax_lui, _bfd_riscv_relax_tls_le):
2914 Pass new argument to riscv_relax_delete_bytes.
2915 (_bfd_riscv_relax_align, _bfd_riscv_relax_delete): Likewise. Remove
2916 ATTRIBUTE_UNUSED from link_info parameter.
2918 2018-02-02 Alan Modra <amodra@gmail.com>
2920 * elf64-ppc.c (ppc64_elf_relocate_section): Don't relocate nops
2921 emitted for toc sequence optimization. Set and use "howto" later.
2923 2018-02-01 Simon Marchi <simon.marchi@ericsson.com>
2925 * elf64-ppc.c (ppc64_elf_archive_symbol_lookup): Avoid pointer
2926 arithmetic on NULL pointer.
2927 * elflink.c (_bfd_elf_archive_symbol_lookup,
2928 elf_link_add_archive_symbols): Likewise.
2930 2018-01-31 Michael Matz <matz@suse.de>
2932 * elflink.c (bfd_elf_define_start_stop): Fix check of
2935 2018-01-31 H.J. Lu <hongjiu.lu@intel.com>
2938 * elflink.c (bfd_elf_define_start_stop): Check if __start and
2939 __stop symbols are referenced by shared objects.
2941 2018-01-30 Alan Modra <amodra@gmail.com>
2944 * elf.c (_bfd_elf_map_sections_to_segments): Don't start a new
2945 segment when demand paged with lma on the same page. Test this
2946 before load/non-load, executable/non-executable,
2947 writable/non-writable tests and simplify. Delete bogus relro
2948 condition in writable/non-writable test. Delete outdated
2949 comment. Formatting.
2951 2018-01-30 Alan Modra <amodra@gmail.com>
2953 * elflink.c (bfd_elf_define_start_stop): Make __start and __stop
2956 2018-01-29 Alan Modra <amodra@gmail.com>
2959 * coffgen.c (coff_pointerize_aux): Ensure auxent tagndx is in
2960 range before converting to a symbol table pointer.
2962 2018-01-27 Nick Clifton <nickc@redhat.com>
2964 * po/ru.po: Updated Russian translation.
2966 2018-01-26 Alan Modra <amodra@gmail.com>
2968 * elflink.c (bfd_elf_define_start_stop): Override symbols when
2969 they are defined dynamically.
2971 2018-01-26 Alan Modra <amodra@gmail.com>
2973 * elf64-ppc.c (ppc64_elf_size_stubs): Iterate sizing when
2974 .branch_lt changes size.
2976 2018-01-25 Alan Modra <amodra@gmail.com>
2979 * elfcode.h (elf_object_p): Avoid integer overflow.
2981 2018-01-25 Eric Botcazou <ebotcazou@adacore.com>
2984 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
2985 Do a mere lookup of the __tls_get_addr symbol instead of adding it.
2988 2017-10-19 H.J. Lu <hongjiu.lu@intel.com>
2991 * elfxx-sparc.c (sparc_elf_tls_transition): Replace
2992 bfd_link_pic with !bfd_link_executable, !bfd_link_pic with
2993 bfd_link_executable for TLS check.
2994 (_bfd_sparc_elf_check_relocs): Likewise.
2995 (allocate_dynrelocs): Likewise.
2996 (_bfd_sparc_elf_relocate_section): Likewise.
2998 2018-01-24 Renlin Li <renlin.li@arm.com>
3000 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Add support for
3001 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
3002 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
3003 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
3004 BFD_RELOC_AARCH64_MOVW_PREL_G3.
3005 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
3006 (_bfd_aarch64_elf_resolve_relocation): Likewise.
3008 2018-01-24 Renlin Li <renlin.li@arm.com>
3010 * reloc.c: Add BFD_RELOC_AARCH64_MOVW_PREL_G0,
3011 BFD_RELOC_AARCH64_MOVW_PREL_G0_NC, BFD_RELOC_AARCH64_MOVW_PREL_G1,
3012 BFD_RELOC_AARCH64_MOVW_PREL_G1_NC, BFD_RELOC_AARCH64_MOVW_PREL_G2,
3013 BFD_RELOC_AARCH64_MOVW_PREL_G2_NC, BFD_RELOC_AARCH64_MOVW_PREL_G3.
3014 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add entries for
3015 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
3016 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
3017 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
3018 BFD_RELOC_AARCH64_MOVW_PREL_G3.
3019 * bfd-in2.h: Regenerate.
3020 * libbfd.h: Regenerate.
3022 2018-01-23 Maciej W. Rozycki <macro@mips.com>
3024 * elfxx-mips.c (_bfd_mips_elf_final_link): Update a stale
3025 `mips_elf32_section_processing' comment reference.
3027 2018-01-20 H.J. Lu <hongjiu.lu@intel.com>
3030 * elfxx-x86.c (_bfd_x86_elf_link_check_relocs): Check the
3031 versioned __tls_get_addr symbol.
3033 2018-01-19 Nick Clifton <nickc@redhat.com>
3035 * po/fr.po: Updated French translation.
3037 2018-01-18 Alan Modra <amodra@gmail.com>
3039 * elf32-ppc.c (ppc_elf_create_glink): Correct alignment of .glink.
3040 * elf64-ppc.c (ppc64_elf_size_stubs): Handle negative plt_stub_align.
3041 (ppc64_elf_build_stubs): Likewise.
3043 2018-01-17 Nick Clifton <nickc@redhat.com>
3045 * po/ru.po: Updated Russian translation.
3046 * po/uk/po: Updated Ukranian translation.
3048 2018-01-17 Alan Modra <amodra@gmail.com>
3050 * elf64-ppc.c (ppc64_elf_build_stubs): Silence gcc warning.
3052 2018-01-17 Alan Modra <amodra@gmail.com>
3054 * elf32-ppc.c (GLINK_ENTRY_SIZE): Handle speculation barrier.
3055 (CRSETEQ, BEQCTRM): Define.
3056 (is_nonpic_glink_stub): Don't check bctr.
3057 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
3058 (ppc_elf_relax_section): Size speculation barrier.
3059 (output_bctr): New function.
3060 (write_glink_stub): Use output_bctr.
3061 (ppc_elf_relocate_section): Use output_bctr for long branch stub.
3062 (ppc_elf_finish_dynamic_symbol): Likewise.
3063 (ppc_elf_finish_dynamic_sections): Use output_bctr.
3064 * elf32-ppc.h (struct ppc_elf_params): Add speculate_indirect_jumps.
3065 * elf64-ppc.c (CRSETEQ, BEQCTRM, BEQCTRLM): Define.
3066 (GLINK_PLTRESOLVE_SIZE): Size speculation barrier.
3067 (size_global_entry_stubs): Handle speculation barrier sizing.
3068 (plt_stub_size): Likewise.
3069 (output_bctr): New function.
3070 (build_plt_stub, build_tls_get_addr_stub): Output speculation
3072 (ppc_build_one_stub): Likewise for ppc_stub_plt_branch.
3073 (ppc_size_one_stub): Size speculation barrier in ppc_stub_plt_branch.
3074 (build_global_entry_stubs): Output speculation barrier.
3075 (ppc64_elf_build_stubs): Likewise in __glink_PLTresolve stub.
3076 * elf64-ppc.h (struct ppc64_elf_params): Add speculate_indirect_jumps.
3078 2018-01-17 Alan Modra <amodra@gmail.com>
3080 * elf32-ppc.c (GLINK_ENTRY_SIZE): Add parameters, handle
3081 __tls_get_addr_opt, and alignment sizing.
3082 (TLS_GET_ADDR_GLINK_SIZE): Delete.
3083 (is_nonpic_glink_stub): Don't use GLINK_ENTRY_SIZE.
3084 (ppc_elf_get_synthetic_symtab): Recognize stubs spaced at 4, 6,
3086 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
3087 (allocate_dynrelocs): Use new GLINK_ENTRY_SIZE.
3088 (ppc_elf_size_dynamic_sections): Likewise. Size branch table
3090 (write_glink_stub): Handle __tls_get_addr_opt stub.
3091 Pad out to size given by GLINK_ENTRY_SIZE.
3092 (ppc_elf_relocate_section): Adjust write_glink_stub call.
3093 (ppc_elf_finish_dynamic_symbol): Likewise.
3094 (ppc_elf_finish_dynamic_sections): Write PLTresolve without using
3095 insn array since so many need rewriting.
3096 * elf32-ppc.h (struct ppc_elf_params): Add plt_stub_align.
3097 * elf64-ppc.c (GLINK_PLTRESOLVE_SIZE): Rename from
3098 GLINK_CALL_STUB_SIZE. Add htab param and evaluate to size without
3099 nops. Adjust all uses.
3100 (ppc64_elf_get_synthetic_symtab): Don't use GLINK_CALL_STUB_SIZE
3101 in glink_vma calculation.
3102 (struct ppc_link_hash_table): Add global_entry section pointer.
3103 (create_linkage_sections): Create separate section for global
3105 (PPC_LO, PPC_HI, PPC_HA): Move earlier.
3106 (size_global_entry_stubs): Handle sizing for aligned stubs.
3107 (ppc64_elf_size_dynamic_sections): Handle global_entry alloc,
3108 and don't stash end of glink branch table in rawsize.
3109 (ppc_build_one_stub): Rewrite stub size calculations.
3110 (build_global_entry_stubs): Use new section.
3111 (ppc64_elf_build_stubs): Don't pad __glink_PLTresolve with nops.
3112 Build lazy link stubs out to end of section. Build global entry
3113 stubs in new section.
3115 2018-01-15 Nick Clifton <nickc@redhat.com>
3117 * po/uk.po: Updated Ukranian translation.
3119 2018-01-13 Nick Clifton <nickc@redhat.com>
3121 * po/bfd.pot: Regenerated.
3123 2018-01-13 Nick Clifton <nickc@redhat.com>
3125 * version.m4: Bump version to 2.30.51
3126 * configure: Regenerate.
3128 2018-01-13 Nick Clifton <nickc@redhat.com>
3130 2.30 branch created.
3132 2018-01-12 Jens Widell <jl@opera.com>
3134 * elf.c (setup_group): Optimize search for group by remembering
3135 last found group and restarting search at that index.
3136 * elf-bfd.h (struct elf_obj_tdata): Add group_search_offset field.
3138 2018-01-12 Gunther Nikl <gnikl@users.sourceforge.net>
3140 * aoutx.h (aout_link_check_ar_symbols): Remove default and handle
3141 bfd_link_common_skip_none in switch.
3143 2018-01-12 Alan Modra <amodra@gmail.com>
3146 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Ignore dynamic
3147 references on forced local symbols.
3149 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
3151 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
3152 .reginfo section has wrong size.
3154 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
3157 * elf.c (_bfd_elf_map_sections_to_segments): When generating
3158 separate code and read-only data LOAD segments, create a new
3159 LOAD segment if the previous section contains text and the
3160 current section doesn't or vice versa. Don't put a writable
3161 section in a read-only segment if there is a RELRO segment.
3163 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
3166 * elflink.c (bfd_elf_gc_mark_dynamic_ref_symbol): Ignore dynamic
3167 references on forced local symbols.
3169 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
3172 * elflink.c (bfd_elf_gc_sections): Keep all PREINIT_ARRAY,
3173 INIT_ARRAY as well as FINI_ARRAY sections for ld -r --gc-section.
3175 2018-01-09 Kuan-Lin Chen <kuanlinchentw@gmail.com>
3178 * elf32-nds32.c (nds32_elf_relax_loadstore): Fix a typographical error.
3180 2018-01-03 John Baldwin <jhb@FreeBSD.org>
3182 * elf.c (elfcore_grok_freebsd_note): Handle
3183 NT_FREEBSD_PROCSTAT_PROC, NT_FREEBSD_PROCSTAT_FILES, and
3184 NT_FREEBSD_PROCSTAT_VMMAP.
3186 2018-01-03 Alan Modra <amodra@gmail.com>
3188 Update year range in copyright notice of all files.
3190 For older changes see ChangeLog-2017
3192 Copyright (C) 2018 Free Software Foundation, Inc.
3194 Copying and distribution of this file, with or without modification,
3195 are permitted in any medium without royalty provided the copyright
3196 notice and this notice are preserved.
3202 version-control: never