1 2018-07-23 Max Filippov <jcmvbkbc@gmail.com>
3 * elf32-xtensa.c (elf_xtensa_finish_dynamic_sections): Move
4 relocation sections consistency check to always check both
5 .rela.dyn and .rela.plt when they exist. Rearrange variable
6 definition and assignment places.
8 2018-07-23 Max Filippov <jcmvbkbc@gmail.com>
10 * elf32-xtensa.c (shrink_dynamic_reloc_sections): Shrink dynamic
11 relocations section for dynamic undefined weak symbols when
12 linking a shared object.
14 2018-07-23 Tom Tromey <tom@tromey.com>
16 * elf.c (bfd_get_elf_phdrs): Don't call memcpy with size 0.
18 2018-07-21 Eric Botcazou <ebotcazou@adacore.com>
20 * elf32-arm.c (elf32_arm_final_link_relocate) <R_ARM_GOT32>: Small
21 cleanup for the case of a global symbol that binds locally. Also
22 install a value in the GOT slot in the case of a local symbol in
25 2018-07-20 H.J. Lu <hongjiu.lu@intel.com>
28 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): If the
29 separate code program header is needed, make sure that the first
30 read-only PT_LOAD segment has no code by adding a
31 GNU_PROPERTY_X86_ISA_1_USED note.
33 2018-07-20 Chenghua Xu <paul.hua.gm@gmail.com>
34 Maciej W. Rozycki <macro@mips.com>
36 * elfxx-mips.c (print_mips_ases): Add MMI extension.
38 2018-07-20 Maciej W. Rozycki <macro@mips.com>
40 * elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Do not
41 create DT_REL, DT_RELSZ or DT_RELENT dynamic entries if the
42 dynamic relocation section will be discarded from output.
43 (_bfd_mips_elf_finish_dynamic_sections) <DT_RELSZ>: Assert that
44 the dynamic relocation section will be retained in output.
46 2018-07-18 Maciej W. Rozycki <macro@mips.com>
48 * xcofflink.c (xcoff_write_global_symbol): Fix symbol type
49 checks for defined weak symbols.
51 2018-07-17 Maciej W. Rozycki <macro@mips.com>
53 * elf32-nds32.c (nds32_elf_relax_loadstore): Use
54 `bfd_is_abs_symbol' rather than `bfd_is_abs_section' in checking
55 whether the symbol is absolute.
56 (nds32_elf_relax_lo12): Likewise.
57 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Likewise.
58 (elfNN_aarch64_check_relocs): Likewise.
59 * xcofflink.c (xcoff_need_ldrel_p): Likewise.
60 (bfd_xcoff_import_symbol): Likewise.
61 (xcoff_write_global_symbol): Likewise.
63 2018-07-17 Maciej W. Rozycki <macro@mips.com>
65 * linker.c (bfd_is_abs_symbol): New macro.
66 * bfd-in2.h: Regenerate.
68 2018-07-16 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
70 * elf-bfd.h (elfcore_write_ppc_tar): Add prototype.
71 (elfcore_write_ppc_ppr): Likewise.
72 (elfcore_write_ppc_dscr): Likewise.
73 (elfcore_write_ppc_ebb): Likewise.
74 (elfcore_write_ppc_pmu): Likewise.
75 (elfcore_write_ppc_tm_cgpr): Likewise.
76 (elfcore_write_ppc_tm_cfpr): Likewise.
77 (elfcore_write_ppc_tm_cvmx): Likewise.
78 (elfcore_write_ppc_tm_cvsx): Likewise.
79 (elfcore_write_ppc_tm_spr): Likewise.
80 (elfcore_write_ppc_tm_ctar): Likewise.
81 (elfcore_write_ppc_tm_cppr): Likewise.
82 (elfcore_write_ppc_tm_cdscr): Likewise.
83 * elf.c (elfcore_write_ppc_tar): New function.
84 (elfcore_write_ppc_ppr): Likewise.
85 (elfcore_write_ppc_dscr): Likewise.
86 (elfcore_write_ppc_ebb): Likewise.
87 (elfcore_write_ppc_pmu): Likewise.
88 (elfcore_write_ppc_tm_cgpr): Likewise.
89 (elfcore_write_ppc_tm_cfpr): Likewise.
90 (elfcore_write_ppc_tm_cvmx): Likewise.
91 (elfcore_write_ppc_tm_cvsx): Likewise.
92 (elfcore_write_ppc_tm_spr): Likewise.
93 (elfcore_write_ppc_tm_ctar): Likewise.
94 (elfcore_write_ppc_tm_cppr): Likewise.
95 (elfcore_write_ppc_tm_cdscr): Likewise.
96 (elfcore_write_register_note): Call them.
97 (elfcore_grok_ppc_tar): New function.
98 (elfcore_grok_ppc_ppr): Likewise.
99 (elfcore_grok_ppc_dscr): Likewise.
100 (elfcore_grok_ppc_ebb): Likewise.
101 (elfcore_grok_ppc_pmu): Likewise.
102 (elfcore_grok_ppc_tm_cgpr): Likewise.
103 (elfcore_grok_ppc_tm_cfpr): Likewise.
104 (elfcore_grok_ppc_tm_cvmx): Likewise.
105 (elfcore_grok_ppc_tm_cvsx): Likewise.
106 (elfcore_grok_ppc_tm_spr): Likewise.
107 (elfcore_grok_ppc_tm_ctar): Likewise.
108 (elfcore_grok_ppc_tm_cppr): Likewise.
109 (elfcore_grok_ppc_tm_cdscr): Likewise.
110 (elfcore_grok_note): Call them.
112 2018-07-11 Maciej W. Rozycki <macro@mips.com>
114 * elfxx-mips.c (mips_tls_got_relocs): Use `bfd_link_dll' rather
115 than `!bfd_link_pic' in determining the dynamic symbol index.
116 Avoid the index of -1.
117 (mips_elf_initialize_tls_slots): Likewise. Flatten code by
118 moving `dyn' to the beginning of the function block.
120 2018-07-11 Maciej W. Rozycki <macro@mips.com>
121 Rich Felker <bugdal@aerifal.cx>
124 * elfxx-mips.c (mips_tls_got_relocs): Use `bfd_link_dll' rather
125 than `bfd_link_pic' to determine whether dynamic relocations are
127 (mips_elf_initialize_tls_slots): Likewise.
129 2018-07-10 Maciej W. Rozycki <macro@mips.com>
131 * elflink.c (bfd_elf_final_link): Rename `remove' local variable
134 2018-07-10 Alan Modra <amodra@gmail.com>
136 * elf32-xgate.h: Delete.
137 * elf32-xgate.c: Delete unnecessary forward declarations, add two
139 (xgate_elf_bfd_link_hash_table_create)
140 (xgate_elf_bfd_link_hash_table_free)
141 (xgate_elf_set_mach_from_flags, struct xgate_scan_param)
142 (stub_hash_newfunc, elf32_xgate_add_symbol_hook)
143 (elf32_xgate_setup_section_lists, elf32_xgate_size_stubs)
144 (elf32_xgate_build_stubs, elf32_xgate_check_relocs)
145 (elf32_xgate_relocate_section, _bfd_xgate_elf_set_private_flags)
146 (elf32_xgate_post_process_headers): Delete.
147 (elf32_xgate_backend_symbol_processing): New function.
148 (xgate_elf_ignore_reloc, xgate_elf_special_reloc)
149 (_bfd_xgate_elf_print_private_bfd_data): Make static.
150 (ELF_TARGET_ID, elf_info_to_howto, elf_backend_check_relocs)
151 (elf_backend_relocate_section, elf_backend_object_p)
152 (elf_backend_final_write_processing, elf_backend_can_gc_sections)
153 (elf_backend_post_process_headers, elf_backend_add_symbol_hook)
154 (bfd_elf32_bfd_link_hash_table_create)
155 (bfd_elf32_bfd_set_private_flags)
156 (xgate_stub_hash_lookup): Don't define.
157 (elf_backend_symbol_processing): Define.
158 * elf-bfd.h (elf_target_id): Delete XGATE_ELF_DATA.
160 2018-07-09 Maciej W. Rozycki <macro@mips.com>
162 * elfxx-mips.c (_bfd_mips_elf_adjust_dynamic_symbol): Don't set
163 `->needs_lazy_stub' if the stubs output section is the absolute
166 2018-07-09 H.J. Lu <hongjiu.lu@intel.com>
169 * configure.ac: Use changequote for "i[3-7]86-*-linux-*".
170 * configure: Regenerated.
172 2018-07-09 Alan Modra <amodra@gmail.com>
174 * elf32-m68hc1x.c (elf32_m68hc11_post_process_headers): Call
175 _bfd_elf_post_process_headers.
177 2018-07-06 Max Filippov <jcmvbkbc@gmail.com>
179 * elf32-xtensa.c (elf_xtensa_allocate_dynrelocs): Don't allocate
180 space for dynamic relocation for undefined weak symbol.
181 (elf_xtensa_relocate_section): Don't emit R_XTENSA_RELATIVE
182 relocation for undefined weak symbols.
183 (shrink_dynamic_reloc_sections): Don't shrink dynamic relocation
184 section for relocations against undefined weak symbols.
186 2018-07-06 Alan Hayward <alan.hayward@arm.com>
188 * elf.c (elfcore_grok_aarch_sve): New function.
189 (elfcore_grok_note): Check for Aarch64 SVE.
190 (elfcore_write_aarch_sve): New function.
191 (elfcore_write_register_note): Check for Aarch64 SVE.
192 * elf-bfd.h(elfcore_grok_aarch_sve): New declaration.
194 2018-07-06 Alan Modra <amodra@gmail.com>
196 * elf32-arm.c (elf32_arm_nabi_write_core_note): Don't use
197 DIAGNOTIC_PUSH and DIAGNOSTIC_POP unconditionally.
198 * elf32-ppc.c (ppc_elf_write_core_note): Likewise.
199 * elf32-s390.c (elf_s390_write_core_note): Likewise.
200 * elf64-ppc.c (ppc64_elf_write_core_note): Likewise.
201 * elf64-s390.c (elf_s390_write_core_note): Likewise.
202 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewise.
204 2018-07-05 Jim Wilson <jimw@sifive.com>
206 * config.bfd (riscv32*-*-*): Renamed from riscv32-*-*.
207 (riscv64*-*-*): Likewise.
208 (riscv-*-*): Add as an alias for riscv32*-*-*.
210 2018-07-05 H.J. Lu <hongjiu.lu@intel.com>
213 * elfxx-x86.c (_bfd_x86_elf_merge_gnu_properties): Remove x86
214 ISA properties with empty bits.
216 2018-07-05 Nick Clifton <nickc@redhat.com>
218 * po/ru.po: Updated Russian translation.
220 2018-07-05 Alan Modra <amodra@gmail.com>
222 * elf-bfd.h (_bfd_elf_ppc_merge_fp_attributes): Update prototype.
223 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Return error
224 on mismatch. Remove "warning: " from messages. Track last bfd
226 (ppc_elf_merge_obj_attributes): Likewise. Handle status from
227 _bfd_elf_ppc_merge_fp_attributes.
228 * elf64-ppc.c (ppc64_elf_merge_private_bfd_data): Handle status
229 from _bfd_elf_ppc_merge_fp_attributes.
231 2018-07-04 H.J. Lu <hongjiu.lu@intel.com>
233 * Makefile.am (bfdinclude_HEADERS): Add $(INCDIR)/diagnostics.h.
234 * Makefile.in: Regenerated.
236 2018-07-03 Alan Modra <amodra@gmail.com>
238 * elflink.c (bfd_elf_final_link): Remove zero size .gnu.attributes
241 2018-07-03 Alan Modra <amodra@gmail.com>
243 * elf-bfd.h (ATTR_TYPE_FLAG_ERROR, ATTR_TYPE_HAS_ERROR): Define.
244 * elf-attrs.c (is_default_attr): Handle ATTR_TYPE_HAS_ERROR.
245 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Use
246 ATTR_TYPE_FLAG_INT_VAL. Set ATTR_TYPE_HAS_ERROR on finding
247 incompatible attribute.
248 (ppc_elf_merge_obj_attributes): Likewise. Return
249 _bfd_elf_merge_object_attributes result.
250 * elf64-ppc.c (ppc64_elf_merge_private_bfd_data): Return
251 _bfd_elf_merge_object_attributes result.
253 2018-07-03 Alan Modra <amodra@gmail.com>
256 * elflink.c (_bfd_elf_fix_symbol_flags): Hide dynamic symbols
257 in discarded sections.
259 2018-07-02 Maciej W. Rozycki <macro@mips.com>
261 * elfxx-mips.c (_bfd_mips_elf_create_dynamic_sections): Set
262 `mark' for symbols created from `mips_elf_dynsym_rtproc_names'
265 2018-07-02 Maciej W. Rozycki <macro@mips.com>
267 * elf64-mips.c (micromips_elf64_howto_table_rel): Add
268 R_MICROMIPS_HI0_LO16, R_MICROMIPS_TLS_GD, R_MICROMIPS_TLS_LDM,
269 R_MICROMIPS_TLS_DTPREL_HI16, R_MICROMIPS_TLS_DTPREL_LO16,
270 R_MICROMIPS_TLS_GOTTPREL, R_MICROMIPS_TLS_TPREL_HI16,
271 R_MICROMIPS_TLS_TPREL_LO16, R_MICROMIPS_GPREL7_S2 and
272 R_MICROMIPS_PC23_S2 relocation entries.
273 (micromips_elf64_howto_table_rela): Likewise.
274 (micromips_reloc_map): Likewise.
275 * elfn32-mips.c (elf_micromips_howto_table_rel): Likewise.
276 (elf_micromips_howto_table_rela): Likewise.
277 (micromips_reloc_map): Likewise.
279 2018-07-02 H.J. Lu <hongjiu.lu@intel.com>
282 * elf64-x86-64.c (elf_x86_64_relocate_section): Clear the
283 R_X86_64_converted_reloc_bit bit.
285 2018-07-02 Jeff Muizelaar <jrmuizel@gmail.com>
286 Tom Tromey <tom@tromey.com>
290 * mach-o.c (bfd_mach_o_fat_close_and_cleanup): New function.
291 (bfd_mach_o_close_and_cleanup): Redefine.
292 * archive.c (_bfd_unlink_from_archive_parent): New function,
294 (_bfd_archive_close_and_cleanup): ..here.
295 (bfd_generic_archive_p): Do not clear archive's format.
296 * libbfd-in.h (_bfd_unlink_from_archive_parent): Declare.
297 * libbfd.h: Regenerate.
299 2018-07-02 Thomas Preud'homme <thomas.preudhomme@arm.com>
301 * archures.c (bfd_mach_arm_5TEJ, bfd_mach_arm_6, bfd_mach_arm_6KZ,
302 bfd_mach_arm_6T2, bfd_mach_arm_6K, bfd_mach_arm_7, bfd_mach_arm_6M,
303 bfd_mach_arm_6SM, bfd_mach_arm_7EM, bfd_mach_arm_8, bfd_mach_arm_8R,
304 bfd_mach_arm_8M_BASE, bfd_mach_arm_8M_MAIN): Define.
305 * bfd-in2.h: Regenerate.
306 * cpu-arm.c (arch_info_struct): Add entries for above new
308 * elf32-arm.c (bfd_arm_get_mach_from_attributes): Add Tag_CPU_arch to
309 bfd_mach_arm mapping logic for pre Armv4 and Armv5TEJ and later
310 architectures. Force assert failure for any new Tag_CPU_arch value.
312 2018-07-02 Thomas Preud'homme <thomas.preudhomme@arm.com>
314 * doc/bfdint.texi: Use command-line consistently when used in a
316 * doc/bfdsumm.texi: Likewise.
318 2018-06-29 Maciej W. Rozycki <macro@mips.com>
320 * elfxx-mips.c (allocate_dynrelocs): Remove extraneous symbol
321 visibility check made for undefined weak symbols.
323 2018-06-26 Nick Clifton <nickc@redhat.com>
325 * po/uk.po: Updated Ukranian translation.
327 2018-06-25 Nick Clifton <nickc@redhat.com>
329 * elfnn-aarch64.c (_bfd_aarch64_erratum_835769_stub_name): Check
330 for malloc returning NULL.
331 (_bfd_aarch64_erratum_843419_fixup): Check for
332 _bfd_aarch64_erratum_835769_stub_name returning NULL.
334 2018-06-24 Nick Clifton <nickc@redhat.com>
336 * po/bfd.pot: Regenerate.
338 2018-06-24 Nick Clifton <nickc@redhat.com>
340 * version.m4: Update version string to 2.31.51.
341 * configure: Regenerate.
343 2018-06-24 Nick Clifton <nickc@redhat.com>
347 2018-06-21 Maciej W. Rozycki <macro@mips.com>
349 * elfxx-mips.c (_bfd_mips_elf_compact_eh_encoding)
350 (_bfd_mips_elf_cant_unwind_opcode): Correct formatting.
352 2018-06-21 Maciej W. Rozycki <macro@mips.com>
354 * elfxx-mips.c (_bfd_mips_post_process_headers): Keep
355 EI_ABIVERSION setting together.
357 2018-06-21 Maciej W. Rozycki <macro@mips.com>
359 * elfxx-mips.c (MIPS_LIBC_ABI_DEFAULT, MIPS_LIBC_ABI_MIPS_PLT)
360 (MIPS_LIBC_ABI_UNIQUE, MIPS_LIBC_ABI_MIPS_O32_FP64)
361 (MIPS_LIBC_ABI_MAX): New enumeration constants.
362 (_bfd_mips_post_process_headers): Use them in place of magic
365 2018-06-21 Jim Wilson <jimw@sifive.com>
367 * elfnn-riscv.c (riscv_elf_finish_dynamic_symbol): Update comment.
368 Use SYMBOL_REFERENCES_LOCAL. Add asserts for h->got.offset.
370 2018-06-21 Alan Modra <amodra@gmail.com>
372 * doc/Makefile.am (AUTOMAKE_OPTIONS): Add "foreign".
373 * doc/Makefile.in: Regenerate.
375 2018-06-20 Renlin Li <renlin.li@arm.com>
377 * elfxx-aarch64.c (_bfd_aarch64_elf_resolve_relocation): Use PG_OFFSET
378 to resolve BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12_NC,
379 BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12_NC,
380 BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12_NC,
381 BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12_NC,
382 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
383 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
384 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
385 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
387 2018-06-20 Nick Clifton <nickc@redhat.com>
390 * opncls.c (get_build_id): Check for a negative or excessive data
391 size in the build-id note.
393 2018-06-20 Nick Clifton <nickc@redhat.com>
396 * mach-o.c (cputype): New function.
397 (cpusubtype): New function.
398 (bfd_mach_o_bfd_print_private_data): New function. Dispalys the
399 values in the MACH-O file header.
400 (bfd_mach_o_bfd_copy_private_header_data): Copy the cputype and
401 cpusubtype fields from the input bfd's mach-o header to the output
403 * mach-o-target.c (bfd_mach_o_bfd_print_private_bfd_data):
404 Redefine to bfd_mach_o_bfd_print_private_data.
405 * mach-o.h (bfd_mach_o_bfd_print_private_bfd_data): Prototype.
407 2018-06-19 Maciej W. Rozycki <macro@mips.com>
410 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Verify the
411 `.got.plt' entry referred is in range.
412 (mips_finish_exec_plt): Correct the range check for `.got.plt'
413 start. Replace the assertion used for that with a proper error
416 2018-06-19 Maciej W. Rozycki <macro@mips.com>
418 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Fix
421 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
423 * Makefile.am (AUTOMAKE_OPTIONS): Remove 1.11.
424 (INCLUDES): Rename to ...
425 (AM_CPPFLAGS): ... this.
426 * configure.ac: Remove AC_PREREQ.
427 * doc/Makefile.am (AUTOMAKE_OPTIONS): Remove 1.9, cygnus, add
428 info-in-builddir no-texinfo.tex.
429 (info_TEXINFOS): Rename bfd.texinfo to bfd.texi.
430 * doc/bfd.texinfo: Rename to ...
431 * doc/bfd.texi: ... this.
432 * Makefile.in: Re-generate.
433 * aclocal.m4: Re-generate.
434 * config.in: Re-generate.
435 * configure: Re-generate.
436 * doc/Makefile.in: Re-generate.
438 2018-06-18 Mephi <mephi42@gmail.com>
441 * mach-o-x86-64.c (x86_64_howto_table): Add entry for
442 BFD_RELOC_MACH_O_X86_64_RELOC_TLV.
443 (bfd_mach_o_x86_64_canonicalize_one_reloc): Handle the new reloc.
444 (bfd_mach_o_x86_64_swap_reloc_out): Likewise.
445 * reloc.c (BFD_RELOC_MACH_O_X86_64_TV): New entry.
446 * bfd-in2.h: Regenerate.
447 * libbfd.h: Regenerate.
449 2018-06-14 Faraz Shahbazker <Faraz.Shahbazker@mips.com>
451 * elfxx-mips.c (print_mips_ases): Add GINV extension.
453 2018-06-14 H.J. Lu <hongjiu.lu@intel.com>
456 * elf.c (_bfd_elf_get_symbol_version_string): Check if the first
457 symbol version is base version.
459 2018-06-14 Alan Modra <amodra@gmail.com>
461 * elf-bfd.h (struct elf_link_hash_table): Add "dynamic_relocs".
462 * elflink.c (_bfd_elf_init_2_index_sections): Comment fix.
463 (_bfd_elf_add_dynamic_entry): Set "dynamic_relocs".
464 (_bfd_elf_link_renumber_dynsyms): Exclude all section symbols when
465 "dynamic_relocs" is not set.
466 * elfxx-mips.c (count_section_dynsyms): Likewise.
468 2018-06-14 Alan Modra <amodra@gmail.com>
471 * bfdio.c (bfd_seek): Optimize away seeks to current position.
473 2018-06-13 Scott Egerton <scott.egerton@imgtec.com>
474 Faraz Shahbazker <Faraz.Shahbazker@mips.com>
476 * elfxx-mips.c (print_mips_ases): Add CRC.
478 2018-06-08 H.J. Lu <hongjiu.lu@intel.com>
481 * elfxx-x86.c (elf_x86_hide_linker_defined): New function.
482 (_bfd_x86_elf_link_check_relocs): Use it to hide hidden
483 __bss_start, _end and _edata in shared libraries.
485 2018-06-07 Alan Modra <amodra@gmail.com>
487 * elf32-tic6x.c (elf32_tic6x_check_relocs): Reference
488 __c6xabi_DSBT_BASE explicitly for R_C6000_SBR_* relocs.
490 2018-06-05 Alan Modra <amodra@gmail.com>
492 * bfd.c (struct bfd): Update comment on "where" usage.
493 * bfdio.c (bfd_bwrite, bfd_stat): Use and update "iovec",
494 "iostream", and "where" from containing archive file. Return
496 (bfd_bread): Similarly, and return error attempted out of
497 bounds archive element access.
498 (bfd_tell, bfd_flush): Use and update "iovec", "iostream", and
499 "where" from containing archive file.
500 (bfd_seek): Likewise. Return error on NULL iovec. Don't
501 attempt to optimize away seeks. Don't paper over errors by
503 (bfd_get_mtime): Call bfd_stat rather than iovec->bstat.
504 (bfd_get_size): Likewise.
505 (bfd_mmap): Operate on and use iovec of containing archive
506 file. Return error on NULL iovec.
507 * cache.c (bfd_cache_lookup_worker): Abort if working on
509 (cache_bread_1): Delete bfd parameter, add FILE* parameter.
510 Don't ignore zero byte reads.
511 (cache_bread): Look up FILE* in cache here. Error on NULL
513 (cache_bwrite): Rename "where" to "from".
514 (cache_bmmap): Don't handle archive elements.
515 * coffcode.h (coff_slurp_line_table): Exit early on zero
517 * bfd-in2.h: Regenerate.
519 2018-06-05 Alan Modra <amodra@gmail.com>
522 * plugin.c (bfd_plugin_open_input): Allow for possibility of
523 nested archives. Open file again for plugin.
524 (try_claim): Don't save and restore file position. Close file
526 * sysdep.h (O_BINARY): Define.
528 2018-06-04 Max Filippov <jcmvbkbc@gmail.com>
530 * elf32-xtensa.c (xtensa_read_table_entries): Make global.
531 (compute_fill_extra_space): Drop declaration. Rename function to
532 xtensa_compute_fill_extra_space.
533 (compute_ebb_actions, remove_dead_literal): Update references to
534 compute_fill_extra_space.
536 2018-06-04 Volodymyr Arbatov <arbatov@cadence.com>
538 * elf32-xtensa.c (elf32xtensa_separate_props): New global
540 (xtensa_add_names): New function.
541 (xtensa_property_section_name): Add new parameter
542 separate_sections, use it to choose property section name.
543 (xtensa_get_separate_property_section): New function.
544 (xtensa_get_property_section): Invoke
545 xtensa_get_separate_property_section to get individual property
546 section if it exists, common property section otherwise.
547 (xtensa_make_property_section): Pass elf32xtensa_separate_props
548 to xtensa_property_section_name.
550 2018-06-04 H.J. Lu <hongjiu.lu@intel.com>
553 * bfd-in.h: Include "diagnostics.h".
554 * bfd-in2.h: Regenerated.
555 * elf32-arm.c (elf32_arm_nabi_write_core_note): Use
556 DIAGNOSTIC_PUSH, DIAGNOSTIC_IGNORE_STRINGOP_TRUNCATION and
557 DIAGNOSTIC_POP to silence GCC 8.1 warnings with
558 -Wstringop-truncation.
559 * elf32-ppc.c (ppc_elf_write_core_note): Likewse.
560 * elf32-s390.c (elf_s390_write_core_note): Likewse.
561 * elf64-ppc.c (ppc64_elf_write_core_note): Likewse.
562 * elf64-s390.c (elf_s390_write_core_note): Likewse.
563 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewse.
565 2018-06-03 Jim Wilson <jimw@sifive.com>
568 * elfnn-riscv.c (riscv_elf_relocate_section) <R_RISCV_CALL>: Check
569 for and handle an undefined weak with no PLT.
572 * elfnn-riscv.c (riscv_relax_delete_bytes): Add versioned_hidden check
573 to code that ignores duplicate symbols.
575 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
577 * version.m4: Bump version to 2.30.52
578 * configure: Regenerated.
580 2018-06-01 Alan Modra <amodra@gmail.com>
582 * bfd.c (_bfd_error_handler): Arrange for this function to be
583 declared in bfd-in2.h.
584 * libbfd-in.h (_bfd_error_handler): Don't declare.
585 * libbfd.h: Regenerate.
586 * bfd-in2.h: Regenerate.
588 2018-05-30 Amaan Cheval <amaan.cheval@gmail.com>
590 * config.bfd (x86_64-*-*): Add pei-x86-64 target to x86_64-*-rtems*
591 This is needed to generate UEFI application image files from ELFs.
593 2018-05-28 H.J. Lu <hongjiu.lu@intel.com>
595 * elf32-i386.c (elf_i386_lazy_plt): Add plt_tlsdesc_entry,
596 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
597 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
598 plt_tlsdesc_got2_insn_end for TLSDESC entry.
599 (elf_i386_lazy_ibt_plt): Likewise.
600 (elf_i386_nacl_plt): Likewise.
601 * elf64-x86-64.c (tlsdesc_plt_entry): Moved and renamed to ...
602 (elf_x86_64_tlsdesc_plt_entry): This.
603 (elf_x86_64_lazy_plt): Add plt_tlsdesc_entry,
604 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
605 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
606 plt_tlsdesc_got2_insn_end for TLSDESC entry.
607 (elf_x86_64_lazy_bnd_plt): Likewise.
608 (elf_x86_64_lazy_ibt_plt): Likewise.
609 (elf_x32_lazy_ibt_plt): Likewise.
610 (elf_x86_64_nacl_plt): Likewise.
611 (elf_x86_64_finish_dynamic_sections): Use plt_tlsdesc_entry,
612 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
613 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
614 plt_tlsdesc_got2_insn_end to update TLSDESC entry.
615 * elfxx-x86.h (elf_x86_lazy_plt_layout): Update comments.
616 Add plt_tlsdesc_entry, plt_tlsdesc_entry_size,
617 plt_tlsdesc_got1_offset, plt_tlsdesc_got2_offset,
618 plt_tlsdesc_got1_insn_end and plt_tlsdesc_got2_insn_end.
619 (elf_x86_non_lazy_plt_layout): Update comments.
620 (elf_x86_plt_layout): Likewise.
622 2018-05-28 H.J. Lu <hongjiu.lu@intel.com>
625 * elf-s390-common.c (elf_s390_add_symbol_hook): Removed.
626 * elf32-arc.c (elf_arc_add_symbol_hook): Likewise.
627 (elf_backend_add_symbol_hook): Likewise.
628 * elf32-m68k.c (elf_m68k_add_symbol_hook): Likewise.
629 (elf_backend_add_symbol_hook): Likewise.
630 * elf32-s390.c (elf_backend_add_symbol_hook): Likewise.
631 * elf32-sparc.c (elf32_sparc_add_symbol_hook): Likewise.
632 (elf_backend_add_symbol_hook): Likewise.
633 * elf64-s390.c (elf_backend_add_symbol_hook): Likewise.
634 * elfxx-aarch64.c (_bfd_aarch64_elf_add_symbol_hook): Likewise.
635 * elfxx-aarch64.h (_bfd_aarch64_elf_add_symbol_hook): Likewise.
636 (elf_backend_add_symbol_hook): Likewise.
637 * elf32-arm.c (elf32_arm_add_symbol_hook): Remove STT_GNU_IFUNC
639 * elf32-ppc.c (ppc_elf_add_symbol_hook): Likewise.
640 * elf64-ppc.c (ppc64_elf_add_symbol_hook): Likewise.
641 * elf64-sparc.c (elf64_sparc_add_symbol_hook): Likewise.
642 * elflink.c (elf_link_add_object_symbols): Set
643 elf_gnu_symbol_ifunc for STT_GNU_IFUNC symbols.
645 2018-05-26 H.J. Lu <hongjiu.lu@intel.com>
648 * elf-bfd.h (_bfd_elf_link_hide_sym_by_version): New.
649 * elflink.c (_bfd_elf_link_hide_versioned_symbol): New function.
650 Extracted from _bfd_elf_link_assign_sym_version.
651 (_bfd_elf_link_hide_sym_by_version): New function.
652 (_bfd_elf_link_assign_sym_version): Use
653 _bfd_elf_link_hide_versioned_symbol.
654 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Call
655 _bfd_elf_link_hide_sym_by_version instead of
656 bfd_hide_sym_by_version. Don't check unversioned symbol.
658 2018-05-25 Alan Modra <amodra@gmail.com>
660 * Makefile.in: Regenerate.
661 * po/SRC-POTFILES.in: Regenerate.
663 2018-05-25 Alan Modra <amodra@gmail.com>
665 * configure.ac (bfd_cv_hidden): Run test with -Werror in CFLAGS.
666 * configure: Regenerate.
668 2018-05-23 H.J. Lu <hongjiu.lu@intel.com>
670 * elf64-ppc.c (ppc64_elf_write_core_note): Add ATTRIBUTE_NONSTRING
673 2018-05-22 Alan Modra <amodra@gmail.com>
676 * elf32-hppa.c (hppa_get_stub_entry): Return NULL when link_sec
678 (elf32_hppa_size_stubs): Only create stubs for load, alloc, code
680 (final_link_relocate): Revert last change.
682 2018-05-22 Alan Modra <amodra@gmail.com>
685 * elf32-hppa.c (final_link_relocate): Don't look for plt call
686 stubs in non-alloc sections.
688 2018-05-21 H.J. Lu <hongjiu.lu@intel.com>
691 * aout-target.h (MY_bfd_link_hide_symbol): New.
692 * aout-tic30.c (MY_bfd_link_hide_symbol): Likewise.
693 * binary.c (binary_bfd_link_hide_symbol): Likewise.
694 * coff-alpha.c (_bfd_ecoff_bfd_link_hide_symbol): Likewise.
695 * coff-mips.c (_bfd_ecoff_bfd_link_hide_symbol): Likewise.
696 * coff-rs6000.c (_bfd_xcoff_bfd_link_hide_symbol): Likewise.
697 * coffcode.h (coff_bfd_link_hide_symbol): Likewise.
698 * elf-bfd.h (_bfd_elf_link_hide_symbol): Likewise.
699 * elfxx-target.h (bfd_elfNN_bfd_link_hide_symbol): Likewise.
700 * i386msdos.c (msdos_bfd_link_hide_symbol): Likewise.
701 * ihex.c (ihex_bfd_link_hide_symbol): Likewise.
702 * libbfd-in.h (_bfd_nolink_bfd_link_hide_symbol): Likewise.
703 * linker.c (_bfd_generic_link_hide_symbol): Likewise.
704 (bfd_link_hide_symbol): Likewise.
705 * mach-o-target.c (bfd_mach_o_bfd_link_hide_symbol): Likewise.
706 * mmo.c (mmo_bfd_link_hide_symbol): Likewise.
707 * pef.c (bfd_pef_bfd_link_hide_symbol): Likewise.
708 * plugin.c (bfd_plugin_bfd_link_hide_symbol): Likewise.
709 * ppcboot.c (ppcboot_bfd_link_hide_symbol): Likewise.
710 * som.c (som_bfd_link_hide_symbol): Likewise.
711 * srec.c (srec_bfd_link_hide_symbol): Likewise.
712 * tekhex.c (tekhex_bfd_link_hide_symbol): Likewise.
713 * vms-alpha.c (vms_bfd_link_hide_symbol): Likewise.
714 (alpha_vms_bfd_link_hide_symbol): Likewise.
715 * xsym.c (bfd_sym_bfd_link_hide_symbol): Likewise.
716 * coff64-rs6000.c (rs6000_xcoff64_vec): Add
717 _bfd_generic_link_hide_symbol.
718 (rs6000_xcoff64_aix_vec): Likewise.
719 * elflink.c (bfd_elf_record_link_assignment): Don't make forced
720 local symbol dynamic.
721 (_bfd_elf_link_hide_symbol): New function.
722 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
723 check root.ldscript_def.
724 * targets.c (bfd_target): Add _bfd_link_hide_symbol.
725 (BFD_JUMP_TABLE_LINK): Add NAME##_bfd_link_hide_symbol.
726 * bfd-in2.h: Regenerated.
727 * libbfd.h: Likewise.
729 2018-05-21 H.J. Lu <hongjiu.lu@intel.com>
732 * elf.c (setup_group): Mark section in a section group with
735 2018-05-18 H.J. Lu <hongjiu.lu@intel.com>
738 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
739 set eh->local_ref to 1 if a symbol is versioned and there is a
742 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
744 * elfnn-riscv.c (_bfd_riscv_elf_merge_private_bfd_data): Handle
747 2018-05-18 Jim Wilson <jimw@sifive.com>
749 * elfnn-riscv.c (allocate_dynrelocs): Discard dynamic relocations if
750 UNDEFWEAK_NO_DYNAMIC_RELOC is true.
751 (riscv_elf_relocate_section): Don't generate dynamic relocation if
752 UNDEFWEAK_NO_DYNAMIC_RELOC is true.
753 (riscv_elf_finish_dynamic_symbol): Likewise.
755 2018-05-18 John Darrington <john@darrington.wattle.id.au>
757 * Makefile.am: Add s12z files.
758 * Makefile.in: Regenerate.
759 * archures.c: Add bfd_s12z_arch.
760 * bfd-in.h: Add exports of bfd_putb24 and bfd_putl24.
761 * bfd-in2.h: Regenerate.
762 * config.bfd: Add s12z target.
763 * configure.ac: Add s12z target.
764 * configure: Regenerate.
765 * cpu-s12z.c: New file.
766 * elf32-s12z.c: New file.
767 * libbfd.c (bfd_putb24): New function.
768 (bfd_putl24): New function.
769 * libbfd.h: Regenerate.
770 * reloc.c: Add s12z relocations.
771 (bfd_get_reloc_size): Handle size 5 relocs.
772 * targets.c: Add s12z_elf32_vec.
774 2018-05-18 H.J. Lu <hongjiu.lu@intel.com>
777 * elf32-i386.c (elf_i386_relocate_section): Handle R_386_GOT32X
779 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
780 set eh->local_ref to 1 for linker defined symbols.
782 2018-05-18 Alan Modra <amodra@gmail.com>
785 * elf.c (setup_group): Formatting. Check that SHT_GROUP entries
786 don't point at other SHT_GROUP sections. Set shdr corresponding
787 to invalid entry, to NULL rather than section 0. Identify
788 SHT_GROUP section index when reporting an error. Cope with NULL
791 2018-05-18 Alan Modra <amodra@gmail.com>
793 * libbfd-in.h (ATTRIBUTE_HIDDEN): Define and use throughout.
794 * configure.ac (HAVE_HIDDEN): Check compiler support for hidden
796 * libbfd.h: Regenerate.
797 * configure: Regenerate.
798 * config.in: Regenerate.
800 2018-05-18 Alan Modra <amodra@gmail.com>
802 * libbfd-in.h: Add include guard.
803 * libcoff-in.h: Likewise.
804 * doc/Makefile.am (libbfd.h, libcoff.h): Append another #endif.
805 * doc/Makefile.in: Regenerate.
806 * libbfd.h: Regenerate.
807 * libcoff.h: Regenerate.
809 2018-05-16 Maciej W. Rozycki <macro@mips.com>
811 * elf32-nds32.c (nds32_convert_32_to_16): Preset `insn_type'.
813 2018-05-16 Alan Modra <amodra@gmail.com>
816 * format.c (struct bfd_preserve): Add section_id.
817 (bfd_preserve_save, bfd_preserve_restore): Save and restore
819 (bfd_reinit): Set _bfd_section_id.
820 (bfd_check_format_matches): Put all matches of any priority into
821 matching_vector. Save initial section id and start each attempted
822 match at that section id.
823 * libbfd-in.h (_bfd_section_id): Declare.
824 * section.c (_bfd_section_id): Rename from section_id and make
826 (bfd_get_next_section_id): Delete.
827 * elf64-ppc.c (ppc64_elf_setup_section_lists): Replace use of
828 bfd_get_section_id with _bfd_section_id.
829 * libbfd.h: Regenerate.
830 * bfd-in2.h: Regenerate.
832 2018-05-15 Christophe Guillon <christophe.guillon@st.com>
834 * coffcode.h (coff_bigobj_swap_aux_in): Make sure that all fields
835 of the aux structure are initialised.
837 2018-05-15 Francois H. Theron <francois.theron@netronome.com>
839 * targets.c: Wrap nfp_elf64_vec in BFD64 ifdef.
841 2018-05-15 Nick Clifton <nickc@redhat.com>
843 * po/pt.po: New Portuguese translation.
844 * configure.ac (ALL_LINGUAS): Add pt.
845 * configure: Regenerate.
847 2018-05-14 H.J. Lu <hongjiu.lu@intel.com>
850 * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Don't issue
851 an error on IFUNC pointer defined in PDE.
852 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Call
853 _bfd_x86_elf_link_fixup_ifunc_symbol.
854 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
855 * elfxx-x86.c (_bfd_x86_elf_link_fixup_ifunc_symbol): New
857 * elfxx-x86.h (_bfd_x86_elf_link_fixup_ifunc_symbol): New.
859 2018-05-14 H.J. Lu <hongjiu.lu@intel.com>
862 * elfxx-x86.c (elf_x86_linker_defined): New function.
863 (_bfd_x86_elf_link_check_relocs): Use it to mark __bss_start,
864 _end and _edata locally defined within executables.
866 2018-05-12 Alan Modra <amodra@gmail.com>
869 * elf.c (rewrite_elf_program_header): Use segment_mark only for
870 PT_LOAD headers. Delete first_matching_lma and first_suggested_lma.
871 Instead make matching_lma and suggested_lma pointers to the
872 sections. Align section vma and lma calculated from segment.
873 Don't clear includes_phdrs or includes_filehdr based on p_paddr
874 test. Try to handle alignment padding before first section by
875 adjusting new segment lma down. Adjust PT_PHDR map p_paddr.
877 2018-05-09 Dimitar Dimitrov <dimitar@dinux.eu>
879 * elf32-pru.c (pru_elf32_do_ldi32_relocate): Make LDI32 relocation
880 conformant to TI ABI.
881 (pru_elf32_relax_section): Likewise.
882 (pru_elf_relax_delete_bytes): Fix offsets for new LDI32 code.
883 * elf32-pru.c (pru_elf32_do_ldi32_relocate): Ignore addend.
884 (pru_elf32_pmem_relocate): Trap - should not get here.
885 (pru_elf32_relocate_section): Add support for REL relocations.
886 (elf_info_to_howto_rel): Enable REL.
887 (elf_backend_may_use_rel_p): Likewise.
888 (elf_backend_may_use_rela_p): Likewise.
889 (elf_backend_default_use_rela_p): Likewise.
891 2018-05-09 Alan Modra <amodra@gmail.com>
894 * peXXigen.c (pe_print_edata): Correct minimum size.
896 2018-05-09 Alan Modra <amodra@gmail.com>
899 * peXXigen.c (pe_print_idata): Bound check hint_addr.
901 2018-05-08 Nick Clifton <nickc@redhat.com>
904 * elf.c (bfd_elf_get_str_section): Check for an excessively large
906 * elf-attrs.c (_bfd_elf_parse_attributes): Issue an error if the
907 attribute section is larger than the size of the file.
909 2018-05-07 Alan Modra <amodra@gmail.com>
911 * cofflink.c (_bfd_coff_link_input_bfd): Use memcmp rather than
912 strncmp when checking for ".bf" special symbol.
913 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Make pe_required_section_flags
914 section name a char array, remove sentinal known_sections entry,
915 and adjust loop over known_sections to suit. Use memcmp rather
918 2018-05-04 Alan Modra <amodra@gmail.com>
920 * elf-linux-core.h (struct elf_external_linux_prpsinfo32_ugid32),
921 (struct elf_external_linux_prpsinfo32_ugid16),
922 (struct elf_external_linux_prpsinfo64_ugid32),
923 (struct elf_external_linux_prpsinfo64_ugid16): Add ATTRIBUTE_NONSTRING
924 to pr_fname and pr_psargs fields. Remove GCC diagnostic pragmas.
926 * elf.c (elfcore_write_prpsinfo): ..here. Indent nested preprocessor
928 * elf32-arm.c (elf32_arm_nabi_write_core_note): Add ATTRIBUTE_NONSTRING
930 * elf32-ppc.c (ppc_elf_write_core_note): Likewise.
931 * elf32-s390.c (elf_s390_write_core_note): Likewise.
932 * elf64-s390.c (elf_s390_write_core_note): Likewise.
933 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewise.
934 * elf64-x86-64.c (elf_x86_64_write_core_note): Add GCC diagnostic
936 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Use strnlen to avoid
937 false positive gcc-8 warning.
938 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
940 2018-05-04 Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
942 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Fix the order
943 of arguments when warning about different long double types.
945 2018-05-03 Simon Atanasyan <simon@atanasyan.com>
947 * elf32-mips.c: (elf32_mips_fixup_symbol): New function.
948 (elf_backend_fixup_symbol): New macro.
949 * elfxx-mips.c: (mips_elf_output_extsym): Discard _gp_disp
951 (_bfd_mips_elf_finish_dynamic_symbol): Likewise.
953 2018-04-30 Francois H. Theron <francois.theron@netronome.com>
955 * Makefile.am: Added NFP files to build.
956 * archures.c: Added bfd_arch_nfp
957 * config.bfd: Added NFP support.
958 * configure.ac: Added NFP support.
959 * cpu-nfp.c: New, for NFP support.
960 * elf-bfd.h: Added elf_section_info()
961 * elf64-nfp.c: New, for NFP support.
962 * po/SRC-POTFILES.in: Added NFP source files.
963 * targets.c: Added nfp_elf64_vec
964 * bfd-in2.h: Regenerate.
965 * Makefile.in: Regenerate.
966 * configure: Regenerate.
968 2018-04-27 Alan Modra <amodra@gmail.com>
970 * bfd-in2.h: Regenerate.
971 * libbfd.h: Regenerate.
973 2018-04-27 Alan Modra <amodra@gmail.com>
977 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Don't drop plt
979 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Comment fixes.
981 2018-04-26 Pedro Alves <palves@redhat.com>
983 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Don't consider
984 ifunc and non-ifunc symbols duplicates.
986 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
987 Mickaël Guêné <mickael.guene@st.com>
989 * elf32-arm.c (elf32_arm_fdpic_thumb_plt_entry): New.
990 (elf32_arm_plt_needs_thumb_stub_p): Handle thumb-only case.
991 (elf32_arm_populate_plt_entry): Likewise.
992 (elf32_arm_output_plt_map_1): Likewise.
993 (elf32_arm_output_arch_local_syms): Likewise.
995 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
996 Mickaël Guêné <mickael.guene@st.com>
998 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Handle
999 _GLOBAL_OFFSET_TABLE_ in FDPIC mode.
1001 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1002 Mickaël Guêné <mickael.guene@st.com>
1004 * elf32-arm.c (bfd_elf32_arm_set_target_params): Handle FDPIC case
1007 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1008 Mickaël Guêné <mickael.guene@st.com>
1010 * elf32-arm.c (DEFAULT_STACK_SIZE): New.
1011 (elf32_arm_always_size_sections): Create stack segment.
1013 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1014 Mickaël Guêné <mickael.guene@st.com>
1016 * bfd-in2.h (BFD_RELOC_ARM_TLS_GD32_FDPIC)
1017 (BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC): New
1019 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_TLS_GD32_FDPIC,
1020 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC relocations.
1021 (elf32_arm_reloc_map): Add R_ARM_TLS_GD32_FDPIC,
1022 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC.
1023 (struct elf32_arm_link_hash_table): Update comment.
1024 (elf32_arm_final_link_relocate): Handle TLS FDPIC relocations.
1025 (IS_ARM_TLS_RELOC): Likewise.
1026 (elf32_arm_check_relocs): Likewise.
1027 (allocate_dynrelocs_for_symbol): Likewise.
1028 (elf32_arm_size_dynamic_sections): Update comment.
1029 * reloc.c: Add BFD_RELOC_ARM_TLS_GD32_FDPIC,
1030 BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC.
1032 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1033 Mickaël Guêné <mickael.guene@st.com>
1035 * elf32-arm.c (elf32_arm_fdpic_plt_entry): New.
1036 (elf32_arm_create_dynamic_sections): Handle FDPIC.
1037 (elf32_arm_allocate_plt_entry): Likewise.
1038 (elf32_arm_populate_plt_entry): Likewise.
1039 (elf32_arm_output_plt_map_1): Likewise.
1041 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1042 Mickaël Guêné <mickael.guene@st.com>
1044 * elf32-arm.c (struct fdpic_local): New.
1045 (elf_arm_obj_tdata): Add local_fdpic_cnts field.
1046 (elf32_arm_local_fdpic_cnts): New.
1047 (struct fdpic_global): New.
1048 (elf32_arm_link_hash_entry): Add fdpic_cnts field.
1049 (elf32_arm_link_hash_table): Add srofixup field.
1050 (arm_elf_add_rofixup): New.
1051 (arm_elf_fill_funcdesc): New.
1052 (elf32_arm_link_hash_newfunc): Handle fdpic_cnts.
1053 (elf32_arm_allocate_local_sym_info): Likewise.
1054 (create_got_section): Create .rofixup section.
1055 (elf32_arm_copy_indirect_symbol): Handle fdpic_cnts.
1056 (bfd_elf32_arm_set_target_params): Handle FDPIC.
1057 (elf32_arm_final_link_relocate): Likewise.
1058 (elf32_arm_check_relocs): Likewise.
1059 (allocate_dynrelocs_for_symbol): Likewise.
1060 (elf32_arm_size_dynamic_sections): Likewise.
1061 (elf32_arm_finish_dynamic_sections): Likewise.
1062 (elf32_arm_output_arch_local_syms): Likewise.
1063 (elf32_arm_fdpic_omit_section_dynsym): New.
1065 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1066 Mickaël Guêné <mickael.guene@st.com>
1068 * bfd-in2.c (BFD_RELOC_ARM_GOTFUNCDESC)
1069 (BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC)
1070 (BFD_RELOC_ARM_FUNCDESC_VALUE): New.
1071 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_GOTFUNCDESC,
1072 R_ARM_GOTOFFFUNCDESC, R_ARM_FUNCDESC, R_ARM_FUNCDESC_VALUE.
1073 (elf32_arm_howto_from_type): Take new members of
1074 elf32_arm_howto_table_2 into account.
1075 (elf32_arm_reloc_map): Add BFD_RELOC_ARM_GOTFUNCDESC,
1076 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
1077 BFD_RELOC_ARM_FUNCDESC_VALUE.
1078 * reloc.c: Add BFD_RELOC_ARM_GOTFUNCDESC,
1079 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
1080 BFD_RELOC_ARM_FUNCDESC_VALUE.
1082 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1083 Mickaël Guêné <mickael.guene@st.com>
1085 * elf32-arm.c (elf32_arm_print_private_bfd_data): Support
1086 EF_ARM_PIC and ELFOSABI_ARM_FDPIC.
1087 (elf32_arm_post_process_headers): Support ELFOSABI_ARM_FDPIC.
1088 (ELF_OSABI): Define to ELFOSABI_ARM_FDPIC.
1090 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1091 Mickaël Guêné <mickael.guene@st.com>
1093 * config.bfd (arm*-*-linux-*): Add arm_elf32_fdpic_be_vec and
1094 arm_elf32_fdpic_le_vec to targ_selvecs. Accept
1095 arm*-*-uclinuxfdpiceabi.
1096 * configure.ac: Add support for arm_elf32_fdpic_be_vec and
1097 arm_elf32_fdpic_le_vec.
1098 * configure: Regenerate.
1099 * elf32-arm.c (struct elf32_arm_link_hash_table): Add fdpic_p.
1100 (elf32_arm_link_hash_table_create): Initialize fdpic_p.
1101 (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME, TARGET_BIG_SYM)
1102 (TARGET_BIG_NAME, elf_match_priority): Define for FDPIC targets.
1103 (elf32_arm_fdpic_link_hash_table_create): New.
1104 * targets.c (_bfd_target_vector): Add arm_elf32_fdpic_be_vec and
1105 arm_elf32_fdpic_le_vec.
1107 2018-04-25 Alan Modra <amodra@gmail.com>
1109 * elf-linux-core.h: Disable gcc-8 string truncation warning.
1110 * elf.c (elfcore_write_prpsinfo): Likewise.
1112 2018-04-25 Alan Modra <amodra@gmail.com>
1114 * Makefile.am: Remove arm-aout and arm-coff support.
1115 * config.bfd: Likewise.
1116 * configure.ac: Likewise.
1117 * targets.c: Likewise.
1118 * aout-arm.c: Delete.
1119 * armnetbsd.c: Delete.
1121 * Makefile.in: Regenerate.
1122 * configure: Regenerate.
1123 * po/SRC-POTFILES.in: Regenerate.
1125 2018-04-24 Nick Clifton <nickc@redhat.com>
1128 * elf.c (ignore_section_sym): Check for the output_section pointer
1129 being NULL before dereferencing it.
1132 * peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Check for
1133 a negative PE_DEBUG_DATA size before iterating over the debug data.
1135 2018-04-23 Alan Modra <amodra@gmail.com>
1137 * elf-linux-core.h: Revert last change.
1140 2018-04-23 Nick Clifton <nickc@redhat.com>
1143 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
1144 the end of the string table, and zero it.
1146 2018-04-23 Alan Modra <amodra@gmail.com>
1148 * elf-linux-core.h (swap_linux_prpsinfo32_ugid32_out): Disable
1149 gcc-8 string truncation warning.
1150 (swap_linux_prpsinfo32_ugid16_out): Likewise.
1151 (swap_linux_prpsinfo64_ugid32_out): Likewise.
1152 (swap_linux_prpsinfo64_ugid16_out): Likewise.
1153 * elf.c (elfcore_write_prpsinfo): Likewise.
1155 2018-04-23 Nick Clifton <nickc@redhat.com>
1158 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
1159 the end of the string table, and zero it.
1161 2018-04-20 Alan Modra <amodra@gmail.com>
1164 * elf32-hppa.c (got_relocs_needed): Add extra param to special
1165 case both dtprel and tprel relocs.
1166 (allocate_dynrelocs): Adjust conditions for got relocs.
1167 (elf32_hppa_relocate_section): Likewise for local sym got relocs.
1168 Emit dynamic relocs on TLS GOT entries for shared libraries,
1169 not when pic. Omit dynamic reloc on dtprel entry when local,
1170 and on tprel entry when local and executable.
1172 2018-04-19 Alan Modra <amodra@gmail.com>
1175 * elf32-hppa.c (elf32_hppa_size_stubs): Init "destination" to -1.
1176 (hppa_type_of_stub): Don't return a long branch stub for
1177 symbols other than those defined statically.
1179 2018-04-19 Alan Modra <amodra@gmail.com>
1181 * Makefile.am: Revert 2018-04-18 coff-mips changes.
1182 * config.bfd: Add back mips_ecoff_le_vec and mips_ecoff_be_vec
1183 to selvecs for mips targets change 2018-04-18.
1184 * configure.ac: Reinstate mips_ecoff_le_vec, mips_ecoff_be_vec
1185 and mips_ecoff_bele_vec.
1186 * targets.c: Likewise.
1187 * coff-mips.c: Resurrect.
1188 * Makefile.in: Regenerate.
1189 * configure: Regenerate.
1190 * po/SRC-POTFILES.in: Regenerate.
1192 2018-04-18 Alan Modra <amodra@gmail.com>
1194 * Makefile.am: Remove mips aout and coff support.
1195 * config.bfd: Likewise.
1196 * configure.ac: Likewise.
1197 * targets.c: Likewise.
1198 * coff-mips.c: Delete
1201 * pei-mips.c: Delete
1202 * Makefile.in: Regenerate.
1203 * configure: Regenerate.
1204 * po/SRC-POTFILES.in: Regenerate.
1206 2018-04-17 H.J. Lu <hongjiu.lu@intel.com>
1208 * elf32-i386.c (elf32_bed): Define before including
1210 * elf64-x86-64.c (elf64_bed): Define before including
1212 (elf32_bed): Define before including "elf32-target.h".
1214 2018-04-17 H.J. Lu <hongjiu.lu@intel.com>
1217 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Use a
1218 normal input file with compatible relocation.
1220 2018-04-18 Alan Modra <amodra@gmail.com>
1222 * Makefile.am: Remove support for assorted i386 aout and coff targets.
1223 * config.bfd: Likewise.
1224 * configure.ac: Likewise.
1225 * doc/bfdint.texi: Likewise.
1226 * targets.c: Likewise.
1227 * freebsd.h: Delete.
1228 * i386dynix.c: Delete.
1229 * i386freebsd.c: Delete.
1230 * i386linux.c: Delete.
1231 * i386mach3.c: Delete.
1232 * i386netbsd.c: Delete.
1233 * i386os9k.c: Delete.
1234 * Makefile.in: Regenerate.
1235 * configure: Regenerate.
1236 * po/SRC-POTFILES.in: Regenerate.
1238 2018-04-17 Andrew Sadek <andrew.sadek.se@gmail.com>
1240 Microblaze Target: PIC data text relative
1242 * bfd/reloc.c (2 new BFD relocations):
1243 BFD_RELOC_MICROBLAZE_64_TEXTPCREL &
1244 BFD_RELOC_MICROBLAZE_64_TEXTPCREL
1245 * bfd/bfd-in2.h: Regenerate
1246 * bfd/libbfd.h: Regenerate
1247 * bfd/elf32-microblaze.c (Handle new relocs): define 'HOWTO' of 3
1248 new relocs and handle them in both relocate and relax functions.
1249 (microblaze_elf_reloc_type_lookup): add mapping between for new
1251 (microblaze_elf_relocate_section): Handle new relocs in case of
1253 (microblaze_elf_relax_section): Handle new relocs for elf relaxation.
1255 2018-04-17 Nick Clifton <nickc@redhat.com>
1258 * aoutx.h (find_nearest_line): Check that the symbol name exists
1259 and is long enough, before attempting to see if it is for a .o
1261 * hash.c (bfd_hash_hash): Add an assertion that the string is not
1263 * linker.c (bfd_link_hash_lookup): Fail if the table or string are
1265 (_bfd_generic_link_add_archive_symbols): Fail if an archive entry
1269 * dwarf2.c (concat_filename): Check for a NULL table pointer.
1271 2018-04-16 Nick Clifton <nickc@redhat.com>
1274 * coffgen.c (coff_pointerize_aux): Check for an out of range
1277 2018-04-16 Alan Modra <amodra@gmail.com>
1279 * Makefile.am: Remove arm-epoc-pe support.
1280 * coff-arm.c: Likewise.
1281 * config.bfd: Likewise.
1282 * configure.ac: Likewise.
1283 * targets.c: Likewise.
1284 * epoc-pe-arm.c: Delete.
1285 * epoc-pei-arm.c: Delete.
1286 * Makefile.in: Regenerate.
1287 * configure: Regenerate.
1288 * po/SRC-POTFILES.in: Regenerate.
1290 2018-04-16 Alan Modra <amodra@gmail.com>
1292 * Makefile.am: Remove sparc-aout and sparc-coff support.
1293 * config.bfd: Likewise.
1294 * configure.ac: Likewise.
1295 * targets.c: Likewise.
1296 * aout-sparcle.c: Delete.
1298 * cf-sparclynx.c: Delete.
1299 * coff-sparc.c: Delete.
1301 * sparclinux.c: Delete.
1302 * sparclynx.c: Delete.
1303 * sparcnetbsd.c: Delete.
1305 * Makefile.in: Regenerate.
1306 * configure: Regenerate.
1307 * po/SRC-POTFILES.in: Regenerate.
1309 2018-04-16 Alan Modra <amodra@gmail.com>
1311 * Makefile.am: Remove m68k-aout and m68k-coff support.
1312 * aoutf1.h: Likewise.
1313 * aoutx.h: Likewise.
1314 * archive.c: Likewise.
1315 * bfd-in.h: Likewise.
1317 * coffcode.h: Likewise.
1318 * coffswap.h: Likewise.
1319 * config.bfd: Likewise.
1320 * configure.ac: Likewise.
1321 * configure.host: Likewise.
1322 * doc/bfd.texinfo: Likewise.
1323 * doc/bfdint.texi: Likewise.
1324 * freebsd.h: Likewise.
1325 * gen-aout.c: Likewise.
1326 * hpux-core.c: Likewise.
1327 * libaout.h: Likewise.
1328 * libbfd-in.h: Likewise.
1329 * pdp11.c: Likewise.
1330 * peicode.h: Likewise.
1331 * riscix.c: Likewise.
1332 * targets.c: Likewise.
1334 * coff-apollo.c: Delete.
1335 * coff-aux.c: Delete.
1336 * coff-m68k.c: Delete.
1337 * coff-svm68k.c: Delete.
1338 * coff-u68k.c: Delete.
1339 * hosts/delta68.h: Delete.
1340 * hosts/hp300bsd.h: Delete.
1341 * hosts/m68kaux.h: Delete.
1342 * hosts/news.h: Delete.
1343 * hp300bsd.c: Delete.
1344 * hp300hpux.c: Delete.
1345 * liboasys.h: Delete.
1346 * m68k4knetbsd.c: Delete.
1347 * m68klinux.c: Delete.
1348 * m68knetbsd.c: Delete.
1350 * versados.c: Delete.
1351 * Makefile.in: Regenerate.
1352 * bfd-in2.h: Regenerate.
1353 * configure: Regenerate.
1354 * libbfd.h: Regenerate.
1355 * po/SRC-POTFILES.in: Regenerate.
1357 2018-04-16 Alan Modra <amodra@gmail.com>
1359 * Makefile.am: Remove sh5 and sh64 support.
1360 * archures.c: Likewise.
1361 * config.bfd: Likewise.
1362 * configure.ac: Likewise.
1363 * cpu-sh.c: Likewise.
1364 * elf32-sh-relocs.h: Likewise.
1365 * elf32-sh.c: Likewise.
1366 * targets.c: Likewise.
1367 * elf32-sh64-com.c: Delete.
1368 * elf32-sh64.c: Delete.
1369 * elf32-sh64.h: Delete.
1370 * elf64-sh64.c: Delete.
1371 * Makefile.in: Regenerate.
1372 * bfd-in2.h: Regenerate.
1373 * configure: Regenerate.
1374 * po/SRC-POTFILES.in: Regenerate.
1376 2018-04-16 Alan Modra <amodra@gmail.com>
1378 * Makefile.am: Remove sh-symbianelf support.
1379 * config.bfd: Likewise.
1380 * configure.ac: Likewise.
1381 * targets.c: Likewise.
1382 * elf32-sh-symbian.c: Delete.
1383 * Makefile.in: Regenerate.
1384 * configure: Regenerate.
1385 * po/SRC-POTFILES.in: Regenerate.
1387 2018-04-16 Alan Modra <amodra@gmail.com>
1389 * Makefile.am: Remove vax-bsd and vax-ultrix support.
1390 * config.bfd: Likewise.
1391 * configure.ac: Likewise.
1392 * targets.c: Likewise.
1394 * Makefile.in: Regenerate.
1395 * configure: Regenerate.
1396 * po/SRC-POTFILES.in: Regenerate.
1398 2018-04-16 Alan Modra <amodra@gmail.com>
1400 * Makefile.am: Remove w65 support.
1401 * archures.c: Likewise.
1402 * coffcode.h: Likewise.
1403 * config.bfd: Likewise.
1404 * configure.ac: Likewise.
1405 * targets.c: Likewise.
1406 * coff-w65.c: Delete.
1407 * cpu-w65.c: Delete.
1408 * Makefile.in: Regenerate.
1409 * bfd-in2.h: Regenerate.
1410 * configure: Regenerate.
1411 * po/SRC-POTFILES.in: Regenerate.
1413 2018-04-16 Alan Modra <amodra@gmail.com>
1415 * Makefile.am: Remove we32k support.
1416 * archures.c: Likewise.
1417 * coffcode.h: Likewise.
1418 * config.bfd: Likewise.
1419 * configure.ac: Likewise.
1420 * targets.c: Likewise.
1421 * coff-we32k.c: Delete.
1422 * cpu-we32k.c: Delete.
1423 * Makefile.in: Regenerate.
1424 * bfd-in2.h: Regenerate.
1425 * configure: Regenerate.
1426 * po/SRC-POTFILES.in: Regenerate.
1428 2018-04-16 Alan Modra <amodra@gmail.com>
1430 * Makefile.am: Remove m88k support.
1431 * aoutx.h: Likewise.
1432 * archures.c: Likewise.
1433 * coffcode.h: Likewise.
1434 * coffswap.h: Likewise.
1435 * config.bfd: Likewise.
1436 * configure.ac: Likewise.
1437 * cpu-ns32k.c: Likewise.
1438 * elf32-nds32.c: Likewise.
1439 * mach-o.c: Likewise.
1440 * netbsd-core.c: Likewise.
1441 * reloc.c: Likewise.
1442 * targets.c: Likewise.
1443 * coff-m88k.c: Delete.
1444 * cpu-m88k.c: Delete.
1445 * elf32-m88k.c: Delete.
1446 * hosts/m88kmach3.h: Delete.
1447 * m88kmach3.c: Delete.
1448 * m88kopenbsd.c: Delete.
1449 * Makefile.in: Regenerate.
1450 * bfd-in2.h: Regenerate.
1451 * configure: Regenerate.
1452 * po/SRC-POTFILES.in: Regenerate.
1454 2018-04-16 Alan Modra <amodra@gmail.com>
1456 * Makefile.am: Remove i370 support.
1457 * archures.c: Likewise.
1458 * config.bfd: Likewise.
1459 * configure.ac: Likewise.
1460 * targets.c: Likewise.
1461 * cpu-i370.c: Delete.
1462 * elf32-i370.c: Delete.
1463 * Makefile.in: Regenerate.
1464 * bfd-in2.h: Regenerate.
1465 * configure: Regenerate.
1466 * po/SRC-POTFILES.in: Regenerate.
1468 2018-04-16 Alan Modra <amodra@gmail.com>
1470 * Makefile.am: Remove h8500 support.
1471 * archures.c: Likewise.
1472 * coffcode.h: Likewise.
1473 * config.bfd: Likewise.
1474 * configure.ac: Likewise.
1475 * targets.c: Likewise.
1476 * coff-h8500.c: Delete.
1477 * cpu-h8500.c: Delete.
1478 * Makefile.in: Regenerate.
1479 * bfd-in2.h: Regenerate.
1480 * configure: Regenerate.
1481 * po/SRC-POTFILES.in: Regenerate.
1483 2018-04-16 Alan Modra <amodra@gmail.com>
1485 * Makefile.am: Remove h8300-coff support.
1486 * coffcode.h: Likewise.
1487 * config.bfd: Likewise.
1488 * configure.ac: Likewise.
1489 * reloc16.c: Likewise.
1490 * targets.c: Likewise.
1491 * coff-h8300.c: Delete.
1492 * Makefile.in: Regenerate.
1493 * configure: Regenerate.
1494 * po/SRC-POTFILES.in: Regenerate.
1496 2018-04-16 Alan Modra <amodra@gmail.com>
1498 * Makefile.am: Remove IEEE 695 support.
1499 * archures.c: Likewise.
1501 * config.bfd: Likewise.
1502 * configure.ac: Likewise.
1503 * doc/bfd.texinfo: Likewise.
1504 * doc/bfdint.texi: Likewise.
1505 * doc/bfdsumm.texi: Likewise.
1506 * section.c: Likewise.
1507 * targets.c: Likewise.
1509 * libieee.h: Delete.
1510 * Makefile.in: Regenerate.
1511 * bfd-in2.h: Regenerate.
1512 * configure: Regenerate.
1513 * po/SRC-POTFILES.in: Regenerate.
1515 2018-04-16 Alan Modra <amodra@gmail.com>
1517 * config.bfd: Remove tandem support.
1519 2018-04-16 Alan Modra <amodra@gmail.com>
1521 * Makefile.am: Remove newsos3 support.
1522 * aoutx.h: Likewise.
1523 * config.bfd: Likewise.
1524 * configure.ac: Likewise.
1525 * targets.c: Likewise.
1526 * newsos3.c: Delete.
1527 * Makefile.in: Regenerate.
1528 * configure: Regenerate.
1529 * po/SRC-POTFILES.in: Regenerate.
1531 2018-04-16 Alan Modra <amodra@gmail.com>
1533 * Makefile.am: Remove netware support.
1534 * bfd-in.h: Likewise.
1536 * config.bfd: Likewise.
1537 * configure.ac: Likewise.
1538 * doc/bfdint.texi: Likewise.
1539 * ecoff.c: Likewise.
1540 * targets.c: Likewise.
1542 * nlm-target.h: Delete.
1544 * nlm32-alpha.c: Delete.
1545 * nlm32-i386.c: Delete.
1546 * nlm32-ppc.c: Delete.
1547 * nlm32-sparc.c: Delete.
1550 * nlmcode.h: Delete.
1551 * nlmswap.h: Delete.
1552 * Makefile.in: Regenerate.
1553 * bfd-in2.h: Regenerate.
1554 * configure: Regenerate.
1555 * po/SRC-POTFILES.in: Regenerate.
1557 2018-04-16 Alan Modra <amodra@gmail.com>
1559 * archures.c: Remove tahoe support.
1560 * config.bfd: Likewise.
1561 * configure.ac: Likewise.
1562 * hosts/tahoe.h: Delete.
1563 * bfd-in2.h: Regenerate.
1564 * configure: Regenerate.
1566 2018-04-14 Alan Modra <amodra@gmail.com>
1568 * elf-bfd.h (struct elf_backend_data): Add relropagesize.
1569 * elfxx-target.h (ELF_RELROPAGESIZE): Provide default and
1571 (elfNN_bed): Init relropagesize.
1572 * bfd.c (bfd_emul_get_commonpagesize): Add boolean param to
1573 select relropagesize.
1574 * elf32-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
1575 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
1576 (ELF_MINPAGESIZE): Don't define.
1577 * elf64-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
1578 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
1579 * bfd-in2.h: Regenerate.
1581 2018-04-14 Alan Modra <amodra@gmail.com>
1583 * elf32-ppc.c (ELF_MAXPAGESIZE, ELF_COMMONPAGESIZE): Don't depend
1584 on __QNXTARGET__ define.
1586 2018-04-14 Alan Modra <amodra@gmail.com>
1588 * config.bfd: Add powerpc-*-lynxos* and powerpc-*-windiss*
1591 2018-04-11 Alan Modra <amodra@gmail.com>
1593 * aout-adobe.c: Delete.
1595 * coff-i860.c: Delete.
1596 * coff-i960.c: Delete.
1597 * cpu-i860.c: Delete.
1598 * cpu-i960.c: Delete.
1599 * elf32-i860.c: Delete.
1600 * elf32-i960.c: Delete.
1601 * hosts/i860mach3.h: Delete.
1602 * Makefile.am: Remove i860, i960, bout, and adobe support.
1603 * archures.c: Remove i860 and i960 support.
1604 * coffcode.h: Likewise.
1605 * reloc.c: Likewise.
1606 * aoutx.h: Comment updates.
1607 * archive.c: Remove BOUT and i960 support.
1608 * bfd.c: Remove BOUT support.
1609 * coffswap.h: Remove i960 support.
1610 * config.bfd: Remove i860, i960 and adobe targets.
1611 * configure.ac: Remove adode, bout, i860, i960, icoff targets.
1612 * targets.c: Likewise.
1613 * ieee.c: Remove i960 support.
1614 * mach-o.c: Remove i860 support.
1615 * Makefile.in: Regenerate.
1616 * bfd-in2.h: Regenerate.
1617 * configure: Regenerate.
1618 * libbfd.h: Regenerate.
1619 * po/SRC-POTFILES.in: Regenerate.
1621 2018-04-09 Maciej W. Rozycki <macro@mips.com>
1623 * elf64-mips.c (mips_elf64_write_rel): Handle a NULL BFD pointer
1624 in the BFD symbol referred by the relocation.
1625 (mips_elf64_write_rela): Likewise.
1627 2018-04-09 Maciej W. Rozycki <macro@mips.com>
1629 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Issue an
1630 error for out-of-range `r_sym' values.
1632 2018-04-09 Alan Modra <amodra@gmail.com>
1634 * elf64-ppc.c (struct _ppc64_elf_section_data): Add has_pltcall field.
1635 (struct ppc_link_hash_table): Add can_convert_all_inline_plt.
1636 (ppc64_elf_check_relocs): Set has_pltcall.
1637 (ppc64_elf_adjust_dynamic_symbol): Discard some PLT entries.
1638 (ppc64_elf_inline_plt): New function.
1639 (ppc64_elf_size_dynamic_sections): Discard some PLT entries for locals.
1640 * elf64-ppc.h (ppc64_elf_inline_plt): Declare.
1641 * elf32-ppc.c (has_pltcall): Define.
1642 (struct ppc_elf_link_hash_table): Add can_convert_all_inline_plt.
1643 (ppc_elf_check_relocs): Set has_pltcall.
1644 (ppc_elf_inline_plt): New function.
1645 (ppc_elf_adjust_dynamic_symbol): Discard some PLT entries.
1646 (ppc_elf_size_dynamic_sections): Likewise.
1647 * elf32-ppc.h (ppc_elf_inline_plt): Declare.
1649 2018-04-09 Alan Modra <amodra@gmail.com>
1651 * elf32-ppc.c (ppc_elf_howto_raw): Add PLTSEQ and PLTCALL howtos.
1652 (is_plt_seq_reloc): New function.
1653 (ppc_elf_check_relocs): Handle PLTSEQ and PLTCALL relocs.
1654 (ppc_elf_tls_optimize): Handle inline plt call sequence.
1655 (ppc_elf_relax_section): Handle PLTCALL reloc.
1656 (ppc_elf_relocate_section): Nop out inline plt call sequence when
1658 * elf64-ppc.c (ppc64_elf_howto_raw): Add R_PPC64_PLTSEQ and
1659 R_PPC64_PLTCALL entries. Comment R_PPC64_TOCSAVE.
1660 (has_tls_get_addr_call): Correct comment.
1661 (is_branch_reloc): Add PLTCALL.
1662 (is_plt_seq_reloc): New function.
1663 (ppc64_elf_check_relocs): Handle PLT16_LO_DS reloc. Set
1664 has_tls_reloc for R_PPC64_TLSGD and R_PPC64_TLSLD. Create plt
1665 entry for R_PPC64_PLTCALL.
1666 (ppc64_elf_tls_optimize): Handle inline plt call sequence.
1667 (ppc_type_of_stub): Handle PLTCALL reloc.
1668 (toc_adjusting_stub_needed): Likewise.
1669 (ppc64_elf_relocate_section): Set "can_plt_call" for PLTCALL
1670 reloc insn. Nop out inline plt call sequence when resolving
1671 locally. Handle __tls_get_addr inline plt call optimization.
1673 2018-04-09 Alan Modra <amodra@gmail.com>
1675 * elf64-ppc.c (LOCAL_PLT_ENTRY_SIZE): Define.
1676 (struct ppc_stub_hash_entry): Add symtype field.
1678 (struct ppc_link_hash_table): Add pltlocal and relpltlocal.
1679 (create_linkage_sections): Create pltlocal and relpltlocal.
1680 (ppc64_elf_check_relocs): Allow PLT relocs on local symbols.
1682 (ppc64_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
1683 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
1684 (ppc64_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
1685 Keep PLT entries for inline calls against locals.
1686 (ppc_build_one_stub): Use pltlocal as appropriate.
1687 (ppc_size_one_stub): Likewise.
1688 (ppc64_elf_size_stubs): Set symtype.
1689 (build_global_entry_stubs_and_plt): Init pltlocal and write
1690 relpltlocal for globals.
1691 (write_plt_relocs_for_local_syms): Likewise for local syms.
1692 (ppc64_elf_relocate_section): Support PLT for local syms.
1693 * elf32-ppc.c (PLT_KEEP): Define.
1694 (struct ppc_elf_link_hash_table): Add pltlocal and relpltlocal.
1695 (ppc_elf_create_glink): Create pltlocal and relpltlocal.
1696 (ppc_elf_check_relocs): Allow PLT relocs on local symbols.
1697 Set PLT_KEEP. Adjust update_local_sym_info call.
1698 (ppc_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
1699 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
1700 (ppc_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
1701 (ppc_elf_relocate_section): Support PLT16 relocs for local syms.
1702 (write_global_sym_plt): Init pltlocal and write relpltlocal.
1703 (ppc_finish_symbols): Likewise for locals.
1705 2018-04-09 Alan Modra <amodra@gmail.com>
1707 * elf64-ppc.c (ppc_build_one_stub): Move output of PLT relocs
1708 for local symbols to..
1709 (write_plt_relocs_for_local_syms): ..here. New function.
1710 (ppc64_elf_finish_dynamic_symbol): Move output of PLT relocs for
1712 (build_global_entry_stubs_and_plt): ..here. Rename from
1713 build_global_entry_stubs.
1714 (ppc64_elf_build_stubs): Always call build_global_entry_stubs_and_plt.
1715 Call write_plt_relocs_for_local_syms.
1716 * elf32-ppc.c (get_sym_h): New function.
1717 (ppc_elf_relax_section): Use get_sym_h.
1718 (ppc_elf_relocate_section): Move output of PLT relocs and glink
1719 stubs for local symbols to..
1720 (ppc_finish_symbols): ..here. New function.
1721 (ppc_elf_finish_dynamic_symbol): Move output of PLT relocs for
1723 (write_global_sym_plt): ..here. New function.
1724 * elf32-ppc.h (ppc_elf_modify_segment_map): Delete attribute.
1725 (ppc_finish_symbols): Declare.
1727 2018-04-09 Alan Modra <amodra@gmail.com>
1729 * elf32-ppc.c (ppc_elf_check_relocs): Handle PLT16 relocs.
1730 (ppc_elf_relocate_section): Likewise.
1731 * elf64-ppc.c (ppc64_elf_check_relocs): Handle PLT16_LO_DS.
1732 (ppc64_elf_relocate_section): Likewise. Correct PLT16
1733 resolution to plt entry relative to toc pointer.
1735 2018-04-09 Alan Modra <amodra@gmail.com>
1737 * elf64-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
1738 TLS_TPRELGD, TLS_EXPLICIT): Renumber. Test TLS_TLS throughout
1739 file when other TLS flags are tested in a mask.
1740 (TLS_MARK, NON_GOT): Define.
1741 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
1742 (update_local_sym_info): Don't create got entry when NON_GOT.
1743 (ppc64_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
1745 (get_tls_mask): Do toc lookup if tls_mask is just TLS_MARK.
1746 (ppc64_elf_relocate_section): Likewise.
1747 (ppc64_elf_tls_optimize): Don't attempt to optimize indirect
1748 __tls_get_addr calls lacking a marker reloc.
1749 * elf32-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
1750 TLS_TPRELGD): Renumber. Update comment.
1751 (TLS_MARK, NON_GOT): Define.
1752 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
1753 (update_local_sym_info): Don't create got entry when NON_GOT.
1754 (ppc_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
1756 (ppc_elf_tls_optimize): Don't attempt to optimize indirect
1757 __tls_get_addr calls lacking a marker reloc.
1759 2018-04-06 H.J. Lu <hongjiu.lu@intel.com>
1761 * elf64-x86-64.c (elf_x86_64_info_to_howto): Don't mask out
1762 R_X86_64_converted_reloc_bit.
1764 2018-04-05 H.J. Lu <hongjiu.lu@intel.com>
1767 * configure: Regenerated.
1769 2018-04-05 Alan Modra <amodra@gmail.com>
1771 * elf-hppa.h (elf_hppa_info_to_howto): Init howto to NULL.
1772 (elf_hppa_info_to_howto_rel): Likewise.
1774 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1776 * elf-hppa.h (elf_hppa_info_to_howto): Also return
1777 unsuccessfully for unimplemented relocations.
1778 (elf_hppa_info_to_howto_rel): Likewise.
1780 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1782 * elf32-i860.c (lookup_howto): Add `abfd' parameter. Set the
1783 `bfd_error_bad_value' error and call `_bfd_error_handler' on a
1784 howto lookup failure.
1785 (elf32_i860_reloc_type_lookup): Adjust `lookup_howto' call
1787 (elf32_i860_info_to_howto_rela): Likewise.
1788 (elf32_i860_relocate_splitn): Likewise.
1789 (elf32_i860_relocate_pc16): Likewise.
1790 (elf32_i860_relocate_pc26): Likewise.
1791 (elf32_i860_relocate_section): Likewise.
1793 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1795 * elf32-visium.c (visium_info_to_howto_rela): Correct the range
1796 check for `visium_elf_howto_table' table access.
1798 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1800 * elf32-iq2000.c (iq2000_info_to_howto_rela): Correct the range
1801 check for `iq2000_elf_howto_table' table access.
1803 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1805 * elf32-frv.c (frv_info_to_howto_rela): Correct the range check
1806 for `elf32_frv_howto_table' table access.
1808 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1810 * elf32-mips.c (mips_elf32_rtype_to_howto): Also return
1811 unsuccessfully for placeholder howtos.
1812 * elf64-mips.c (mips_elf64_rtype_to_howto): Likewise.
1813 * elfn32-mips.c (mips_elf_n32_rtype_to_howto): Likewise.
1815 2018-03-29 Maciej W. Rozycki <macro@mips.com>
1817 * elf32-mips.c (mips_info_to_howto_rel): Remove the calls to
1818 `_bfd_error_handler' and to set the `bfd_error_bad_value' error.
1820 2018-03-28 Maciej W. Rozycki <macro@mips.com>
1822 * elf-hppa.h (elf_hppa_info_to_howto_rel): Remove
1823 ATTRIBUTE_UNUSED from `abfd'.
1825 2018-03-28 Maciej W. Rozycki <macro@mips.com>
1827 * elf-hppa.h (elf_hppa_info_to_howto_rel): Correct
1828 `_bfd_error_handler' call formatting.
1830 2018-03-28 Maciej W. Rozycki <macro@mips.com>
1832 * elf32-mips.c (mips_info_to_howto_rel): Call
1833 `mips_elf32_rtype_to_howto' directly rather than via
1834 `->elf_backend_mips_rtype_to_howto'.
1836 2018-03-28 Renlin Li <renlin.li@arm.com>
1839 * elfnn-aarch64.c (IS_AARCH64_TLS_RELOC): Add cases for
1840 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
1841 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
1842 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
1843 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
1844 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
1845 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
1846 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
1847 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
1848 (elfNN_aarch64_final_link_relocate): Support new relocations.
1849 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Support new
1851 (_bfd_aarch64_elf_resolve_relocation): Support new relocations.
1853 2018-03-28 Renlin Li <renlin.li@arm.com>
1856 * reloc.c: Add BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12
1857 BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12_NC,
1858 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
1859 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
1860 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
1861 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
1862 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
1863 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
1864 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
1865 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
1866 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add table entry for
1867 TLSLE_LDST16_TPREL_LO12,
1868 TLSLE_LDST16_TPREL_LO12_NC,
1869 TLSLE_LDST32_TPREL_LO12,
1870 TLSLE_LDST32_TPREL_LO12_NC,
1871 TLSLE_LDST64_TPREL_LO12,
1872 TLSLE_LDST64_TPREL_LO12_NC,
1873 TLSLE_LDST8_TPREL_LO12,
1874 TLSLE_LDST8_TPREL_LO12_NC.
1875 * bfd-in2.h: Regenerated.
1876 * libbfd.h: Regenerated.
1878 2018-03-28 Eric Botcazou <ebotcazou@adacore.com>
1881 * elfxx-sparc.c (struct _bfd_sparc_elf_link_hash_entry): Add new flag
1882 has_old_style_got_reloc.
1883 (_bfd_sparc_elf_check_relocs) <GOT relocations>: Set it for old-style
1884 relocations. Fix a couple of long lines.
1885 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: Do not generate
1886 a R_SPARC_NONE for the GOT slot if the symbol is also subject to old-style
1889 2018-03-25 H.J. Lu <hongjiu.lu@intel.com>
1892 * elf64-x86-64.c (elf_x86_64_finish_dynamic_sections): Add
1893 ENDBR64 to the TLSDESC PLT entry.
1895 2018-03-21 Alan Modra <amodra@gmail.com>
1897 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Trim uninteresting
1898 symbols. Use size_t counts. Delete redundant opd test.
1900 2018-03-21 Alan Modra <amodra@gmail.com>
1902 * elf32-ppc.c (ppc_elf_tls_optimize): Delete locsyms.
1904 2018-03-21 Alan Modra <amodra@gmail.com>
1906 * elf32-ppc.c (struct ppc_elf_link_hash_entry): Make tls_mask
1908 (update_local_sym_info): Likewise for local_got_tls_masks.
1909 (ppc_elf_tls_optimize): Likewise for lgot_masks.
1911 2018-03-21 Alan Modra <amodra@gmail.com>
1913 * elf64-ppc.c (ppc_size_one_stub): Fix comment typo.
1914 (ppc64_elf_layout_multitoc): Allocate relocs for tprel as we
1915 do in size_dynamic_sections.
1917 2018-03-21 Alan Modra <amodra@gmail.com>
1919 * elf64-ppc.c (ppc64_elf_relocate_section): Don't access rel[1]
1920 without first checking array bounds.
1921 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
1923 2018-03-20 H.J. Lu <hongjiu.lu@intel.com>
1926 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Set
1927 non_ir_ref_dynamic if a symbol is made dynamic by --dynamic-list.
1929 2018-03-19 Nick Clifton <nickc@redhat.com>
1931 * po/es.po: Updated Spanish translation.
1933 2018-03-15 Max Filippov <jcmvbkbc@gmail.com>
1935 * elf32-xtensa.c (xlate_map_entry): Change types of address
1936 fields from 'unsigned' to 'bfd_vma'.
1937 (xlate_offset_with_removed_text): Use struct xlate_map_entry as
1938 the key argument to bsearch. Allow offsets past the end of a
1939 section, use the last map entry for translation of such offsets.
1941 2018-03-15 Kuan-Lin Chen <kuanlinchentw@gmail.com>
1943 * elf32-nds32.c (nds32_elf_ex9_build_hash_table): Removed.
1944 Not support the target feature.
1945 (nds32_elf_ex9_itb_base): Likewise.
1946 (nds32_elf_ex9_import_table): Likewise.
1947 (nds32_elf_ex9_finish): Likewise.
1948 (nds32_elf_ex9_reloc_jmp): Likewise.
1949 (nds32_elf_get_insn_with_reg): Likewise.
1950 (nds32_get_local_syms): Likewise.
1951 (nds32_elf_ex9_replace_instruction): Likewise.
1952 (nds32_elf_ifc_calc): Likewise.
1953 (nds32_elf_ifc_finish): Likewise.
1954 (nds32_elf_ifc_replace): Likewise.
1955 (nds32_elf_ifc_reloc): Likewise.
1957 2018-03-14 Alan Modra <amodra@gmail.com>
1959 * elf64-ppc.c (sfpr_define): Adjust for stub_sec size having
1960 sfpr size added before defining alias symbols.
1961 (ppc64_elf_build_stubs): Add stub section padding before
1962 copying sfpr contents and defining save/restore alias symbols.
1964 2018-03-14 H.J. Lu <hongjiu.lu@intel.com>
1967 * elflink.c (elf_gc_mark_debug_section): Also check the local
1968 debug definition section.
1970 2018-03-13 Nick Clifton <nickc@redhat.com>
1973 * pei-x86_64.c (pex64_get_unwind_info): Change to a boolean
1974 function. Add an end address parameter. Check access of the data
1975 pointer to make sure that they do not extend beyond the end
1976 address. Return FALSE if any check fails. Add the end address
1977 pointer to the ui structure.
1978 (pex64_xdata_print_uwd_codes): Check accesses of the raw unwind
1979 codes to make sure that they do not extend beyond the end address
1980 pointer. Print an error message and return immediately if any
1983 2018-03-09 Nick Clifton <nickc@redhat.com>
1985 * elf64-s390.c (elf_s390_relocate_section): Move check for
1986 relocations against non-allocated sections to before the code that
1987 handles ifunc relocations.
1988 * elf32-s390.c (elf_s390_relocate_section): Likewise.
1989 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Treat
1990 relocs against IFUNC symbols in non-allocated sections as relocs
1991 against FUNC symbols.
1992 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
1994 2018-03-08 H.J. Lu <hongjiu.lu@intel.com>
1997 * elf32-i386.c (elf_i386_relocate_section): Treat relocation
1998 against IFUNC symbol in SHT_NOTE section without SHF_ALLOC as
1999 relocation against FUNC symbol.
2000 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
2002 2018-03-07 Renlin Li <renlin.li@arm.com>
2005 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Check absolute
2006 symbol, and don't emit relocation in specific case.
2008 2018-03-07 Alan Modra <amodra@gmail.com>
2010 * elf64-mips.c (mips_elf64_rtype_to_howto): Return NULL on error.
2011 (mips_elf64_slurp_one_reloc_table): Pass on error.
2013 2018-03-03 James Cowgill <james.cowgill@mips.com>
2014 Maciej W. Rozycki <macro@mips.com>
2017 * elfxx-mips.c (mips_elf_calculate_relocation): Only return
2018 after calling `undefined_symbol' hook if this is an error
2019 condition. Assume the value of 0 for the symbol requested
2022 2018-03-02 Jim Wilson <jimw@sifive.com>
2025 * elfnn-aarch64.c (_bfd_aarch64_resize_stubs): Add 8 bytes for branch
2026 and nop instead of 4.
2027 (elfNN_arch64_build_stubs): Add nop after branch. Increase size by
2030 2018-03-01 Jim Wilson <jimw@sifive.com>
2033 * elfnn-riscv.c (riscv_relax_delete_bytes): When adjust st_size, use
2034 else if instead of if.
2036 2018-03-01 Alan Modra <amodra@gmail.com>
2038 * elf32-ft32.c (ft32_info_to_howto_rela): Correct range test.
2040 2018-02-28 Alan Modra <amodra@gmail.com>
2043 * aoutx.h (swap_std_reloc_in): Correct r_index bound check.
2045 2018-02-28 Nick Clifton <nickc@redhat.com>
2049 * dwarf2.c (read_n_bytes): Replace size parameter with dwarf_block
2050 pointer. Drop unused abfd parameter. Check the size of the block
2051 before initialising the data field. Return the end pointer if the
2053 (read_attribute_value): Adjust invocations of read_n_bytes.
2056 * dwarf1.c (parse_die): Check the length of form blocks before
2057 advancing the data pointer.
2059 2018-02-28 Alan Modra <amodra@gmail.com>
2062 * aoutx.h (translate_symbol_table): Print an error message and set
2063 bfd_error on finding an invalid name string offset.
2065 2018-02-27 H.J. Lu <hongjiu.lu@intel.com>
2067 * config.in: Regenerated.
2068 * configure: Likewise.
2069 * configure.ac: Add --enable-separate-code.
2070 (DEFAULT_LD_Z_SEPARATE_CODE): New AC_DEFINE_UNQUOTED. Default
2071 to 1 for Linux/x86 targets,
2072 * elf64-x86-64.c (ELF_MAXPAGESIZE): Set to 0x1000 if
2073 DEFAULT_LD_Z_SEPARATE_CODE is 1.
2075 2018-02-27 Nick Clifton <nickc@redhat.com>
2077 * aout-cris.c (swap_ext_reloc_out): Standadize error/warning
2079 * elf-hppa.h (elf_hppa_info_to_howto_rel): Likewise.
2080 * elf32-i386.c (elf_i386_reloc_type_lookup): Likewise.
2081 * elf32-xtensa.c (elf_xtensa_reloc_type_lookup): Likewise.
2082 * elf64-ppc.c (ppc64_elf_reloc_type_lookup): Likewise.
2083 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
2084 * elf64-sh64.c (sh_elf64_info_to_howto): Likewise.
2085 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
2086 * elfxx-sparc.c (_bfd_sparc_elf_reloc_type_lookup): Likewise.
2087 * elfxx-tilegx.c (tilegx_reloc_type_lookup): Likewise.
2090 * elf-bfd.h (struct elf_backend_data): Change the return type of
2091 the elf_info_to_howto and elf_info_to_howto_rel function pointers
2093 * elfcode.h (elf_slurp_reloc_table_from_section): Check the return
2094 value from the info_to_howto function and fail if that function
2096 * elf32-h8300.c (elf32_h8_relocate_section): Check return value
2097 from the info_to_howto function.
2098 (elf32_h8_relax_section): Likewise.
2099 * elf32-lm32.c (lm32_elf_relocate_section): Likewise.
2100 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
2101 * elf32-score.c (s3_bfd_score_elf_relocate_section): Likewise.
2102 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
2103 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
2104 * elf64-ia64-vms.c (elf64_ia64_relocate_section): Likewise.
2105 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Likewise.
2106 * elf64-x86-64.c (elf_x86_64_tls_transition): Likewise.
2107 * elfnn-ia64.c (elfNN_ia64_relocate_section): Likewise.
2108 * elfnn-riscv.c (riscv_elf_check_relocs): Likewise.
2109 (riscv_elf_relocate_section): Likewise.
2110 * elf-hppa.h (elf_hppa_info_to_howto): Change return type to
2111 bfd_boolean. Issue an error message, set an error value and
2112 return FALSE if the reloc is not recognized.
2113 (elf_hppa_info_to_howto_rel): Likewise.
2114 * elf-m10200.c (mn10200_info_to_howto): Likewise.
2115 * elf-m10300.c (mn10300_info_to_howto): Likewise.
2116 * elf.c (_bfd_elf_no_info_to_howto): Likewise.
2117 * elf32-arc.c (arc_info_to_howto_rel): Likewise.
2118 * elf32-arm.c (elf32_arm_info_to_howto): Likewise.
2119 * elf32-avr.c (avr_info_to_howto_rela): Likewise.
2120 * elf32-bfin.c (bfin_info_to_howto): Likewise.
2121 * elf32-cr16.c (elf_cr16_info_to_howto): Likewise.
2122 * elf32-cr16c.c (elf_cr16c_info_to_howto): Likewise.
2123 * elf32-cris.c (elf_cr16c_info_to_howto_rel)
2124 (cris_info_to_howto_rela): Likewise.
2125 * elf32-crx.c (elf_crx_info_to_howto): Likewise.
2126 * elf32-d10v.c (d10v_info_to_howto_rel): Likewise.
2127 * elf32-d30v.c (d30v_info_to_howto_rel, d30v_info_to_howto_rela):
2129 * elf32-dlx.c (dlx_rtype_to_howto, elf32_dlx_info_to_howto)
2130 (elf32_dlx_info_to_howto_rel): Likewise.
2131 * elf32-epiphany.c (epiphany_info_to_howto_rela): Likewise.
2132 * elf32-fr30.c (fr30_info_to_howto_rela): Likewise.
2133 * elf32-frv.c (frv_info_to_howto_rela)
2134 (frvfdpic_info_to_howto_rel): Likewise.
2135 * elf32-ft32.c (ft32_info_to_howto_rela): Likewise.
2136 * elf32-gen.c (elf_generic_info_to_howto)
2137 (elf_generic_info_to_howto_rel): Likewise.
2138 * elf32-h8300.c (elf32_h8_info_to_howto)
2139 (elf32_h8_info_to_howto_rel): Likewise.
2140 * elf32-i370.c (i370_elf_info_to_howto): Likewise.
2141 * elf32-i386.c (elf_i386_reloc_type_lookup)
2142 (elf_i386_rtype_to_howto, elf_i386_info_to_howto_rel): Likewise.
2143 * elf32-i860.c (lookup_howto, elf32_i860_info_to_howto_rela):
2145 * elf32-i960.c (elf32_i960_info_to_howto_rel): Likewise.
2146 * elf32-ip2k.c (ip2k_info_to_howto_rela): Likewise.
2147 * elf32-iq2000.c (iq2000_info_to_howto_rela): Likewise.
2148 * elf32-lm32.c (lm32_info_to_howto_rela): Likewise.
2149 * elf32-m32c.c (m32c_info_to_howto_rela): Likewise.
2150 * elf32-m32r.c (m32r_info_to_howto_rel, m32r_info_to_howto):
2152 * elf32-m68hc11.c (m68hc11_info_to_howto_rel): Likewise.
2153 * elf32-m68hc12.c (m68hc11_info_to_howto_rel): Likewise.
2154 * elf32-m68k.c (rtype_to_howto): Likewise.
2155 * elf32-mcore.c (mcore_elf_info_to_howto): Likewise.
2156 * elf32-mep.c (mep_info_to_howto_rela): Likewise.
2157 * elf32-metag.c (metag_info_to_howto_rela): Likewise.
2158 * elf32-microblaze.c (microblaze_elf_info_to_howto): Likewise.
2159 * elf32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
2161 * elf32-moxie.c (moxie_info_to_howto_rela): Likewise.
2162 * elf32-msp430.c (msp430_info_to_howto_rela): Likewise.
2163 * elf32-mt.c (mt_info_to_howto_rela): Likewise.
2164 * elf32-nds32.c (nds32_info_to_howto_rel, nds32_info_to_howto):
2166 * elf32-nios2.c (nios2_elf32_info_to_howto): Likewise.
2167 * elf32-or1k.c (or1k_info_to_howto_rela): Likewise.
2168 * elf32-pj.c (pj_elf_info_to_howto): Likewise.
2169 * elf32-ppc.c (ppc_elf_info_to_howto): Likewise.
2170 * elf32-pru.c (pru_elf32_info_to_howto): Likewise.
2171 * elf32-rl78.c (rl78_info_to_howto_rela): Likewise.
2172 * elf32-rx.c (rx_info_to_howto_rela): Likewise.
2173 * elf32-s390.c (elf_s390_info_to_howto): Likewise.
2174 * elf32-score.c (s3_bfd_score_info_to_howto)
2175 (_bfd_score_info_to_howto): Likewise.
2176 * elf32-score7.c (s7_bfd_score_info_to_howto): Likewise.
2177 * elf32-sh.c (sh_elf_info_to_howto): Likewise.
2178 * elf32-spu.c (spu_elf_info_to_howto): Likewise.
2179 * elf32-tic6x.c (elf32_tic6x_info_to_howto)
2180 (elf32_tic6x_info_to_howto_rel): Likewise.
2181 * elf32-tilepro.c (tilepro_info_to_howto_rela): Likewise.
2182 * elf32-v850.c (v850_elf_info_to_howto_rel)
2183 (v850_elf_info_to_howto_rela, v800_elf_info_to_howto): Likewise.
2184 * elf32-vax.c (rtype_to_howto): Likewise.
2185 * elf32-visium.c (visium_info_to_howto_rela): Likewise.
2186 * elf32-wasm32.c (elf32_wasm32_rtype_to_howto)
2187 (elf32_wasm32_info_to_howto_rela): Likewise.
2188 * elf32-xc16x.c (elf32_xc16x_info_to_howto): Likewise.
2189 * elf32-xgate.c (xgate_info_to_howto_rel): Likewise.
2190 * elf32-xstormy16.c (xstormy16_info_to_howto_rela): Likewise.
2191 * elf32-xtensa.c (elf_xtensa_info_to_howto_rela): Likewise.
2192 * elf64-alpha.c (elf64_alpha_info_to_howto): Likewise.
2193 * elf64-gen.c (elf_generic_info_to_howto)
2194 (elf_generic_info_to_howto_rel): Likewise.
2195 * elf64-ia64-vms.c (elf64_ia64_info_to_howto): Likewise.
2196 * elf64-mips.c (mips_elf64_info_to_howto_rela): Likewise.
2197 * elf64-mmix.c (mmix_info_to_howto_rela): Likewise.
2198 * elf64-ppc.c (ppc64_elf_info_to_howto): Likewise.
2199 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
2200 * elf64-sh64.c (elf_s390_info_to_howto, sh_elf64_info_to_howto):
2202 * elf64-x86-64.c (elf_x86_64_info_to_howto): Likewise.
2203 * elfn32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
2205 * elfnn-aarch64.c (elfNN_aarch64_info_to_howto): Likewise.
2206 * elfnn-ia64.c (elfNN_ia64_info_to_howto): Likewise.
2207 * elfnn-riscv.c (riscv_info_to_howto_rela): Likewise.
2208 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
2209 * elfxx-sparc.c (_bfd_sparc_elf_info_to_howto): Likewise.
2210 * elfxx-tilegx.c (tilegx_info_to_howto_rela): Likewise.
2211 * elf32-score.h (s7_bfd_score_info_to_howto): Update prototype.
2212 * elfxx-sparc.h (_bfd_sparc_elf_info_to_howto): Update prototype.
2213 * elfxx-tilegx.h (tilegx_info_to_howto_rela): Update prototype.
2214 * elfxx-target.h (elf_info_to_howto, elf_info_to_howto_rel):
2217 2018-02-26 Jim Wilson <jimw@sifive.com>
2218 Stephan Schreiber <info@fs-driver.org>
2221 * elfnn-ia64.c (elfNN_ia64_relax_section): After ia64_elf_relax_brl
2222 call, set changed_contents and changed_relocs. Likewise after
2223 successful ia64_elf_relax_br call.
2225 2018-02-26 Alan Modra <amodra@gmail.com>
2227 * elf.c (assign_file_positions_except_relocs): Don't segfault
2228 when actual number of phdrs is less than allocated. Delete
2229 outdated comment. Formatting.
2231 2018-02-26 Alan Modra <amodra@gmail.com>
2233 * elf-m10300.c, * elf-s390-common.c, * elf32-arc.c, * elf32-cris.c,
2234 * elf32-dlx.c, * elf32-frv.c, * elf32-i370.c, * elf32-lm32.c,
2235 * elf32-m32r.c, * elf32-m68hc1x.c, * elf32-m68k.c,
2236 * elf32-microblaze.c, * elf32-msp430.c, * elf32-nds32.c,
2237 * elf32-nios2.c, * elf32-or1k.c, * elf32-rl78.c, * elf32-rx.c,
2238 * elf32-score.c, * elf32-score7.c, * elf32-sh-symbian.c,
2239 * elf32-sh.c, * elf32-spu.c, * elf32-v850.c, * elf32-xtensa.c,
2240 * elf64-alpha.c, * elf64-ia64-vms.c, * elf64-mmix.c,
2241 * elf64-sh64.c, * elf64-sparc.c, * elfnn-ia64.c, * elfxx-tilegx.c,
2242 * mmo.c, * osf-core.c, * srec.c, * vms-alpha.c: Standardize
2243 error/warning messages.
2245 2018-02-26 Alan Modra <amodra@gmail.com>
2247 * archive.c, * bfd.c, * linker.c, * reloc.c, * stabs.c,
2248 * syms.c: Standardize error/warning messages.
2250 2018-02-26 Alan Modra <amodra@gmail.com>
2252 * aout-adobe.c, * aout-cris.c, * i386linux.c, * m68klinux.c,
2253 * sparclinux.c, * coff-alpha.c, * coff-arm.c, * coff-mcore.c,
2254 * coffcode.h, * coffgen.c, * cofflink.c, * ecoff.c, * pe-mips.c,
2255 * peXXigen.c, * peicode.h: Standardize error/warning messages.
2257 2018-02-26 Alan Modra <amodra@gmail.com>
2259 * elf32-arm.c, * elfnn-aarch64.c: Standardize error/warning messages.
2261 2018-02-26 Alan Modra <amodra@gmail.com>
2263 * elfxx-mips.c: Standardize error/warning messages.
2265 2018-02-26 Alan Modra <amodra@gmail.com>
2267 * dwarf2.c, * elf-attrs.c, * elf-eh-frame.c, * elf.c, * elf32-gen.c,
2268 * elflink.c: Standardize error/warning messages. Replace use of
2269 linker callback einfo with _bfd_error_handler when possible.
2271 2018-02-26 Alan Modra <amodra@gmail.com>
2273 * aoutx.h, * coff-alpha.c, * coff-i860.c, * coff-m68k.c,
2274 * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c, * coff-sh.c,
2275 * coff-tic4x.c, * coff-tic54x.c, * coff-tic80.c, * coff-w65.c,
2276 * elf-bfd.h, * elf-m10300.c, * elf.c, * elf32-avr.c, * elf32-bfin.c,
2277 * elf32-cr16.c, * elf32-cr16c.c, * elf32-cris.c, * elf32-crx.c,
2278 * elf32-d10v.c, * elf32-d30v.c, * elf32-dlx.c, * elf32-epiphany.c,
2279 * elf32-fr30.c, * elf32-frv.c, * elf32-i370.c, * elf32-i386.c,
2280 * elf32-i960.c, * elf32-ip2k.c, * elf32-iq2000.c, * elf32-lm32.c,
2281 * elf32-m32c.c, * elf32-m32r.c, * elf32-m68hc11.c, * elf32-m68hc12.c,
2282 * elf32-m68k.c, * elf32-mcore.c, * elf32-mep.c, * elf32-metag.c,
2283 * elf32-microblaze.c, * elf32-mips.c, * elf32-moxie.c,
2284 * elf32-msp430.c, * elf32-mt.c, * elf32-nds32.c, * elf32-or1k.c,
2285 * elf32-pj.c, * elf32-ppc.c, * elf32-rl78.c, * elf32-rx.c,
2286 * elf32-s390.c, * elf32-sh.c, * elf32-spu.c, * elf32-tic6x.c,
2287 * elf32-v850.c, * elf32-vax.c, * elf32-visium.c, * elf32-wasm32.c,
2288 * elf32-xgate.c, * elf32-xtensa.c, * elf64-alpha.c,
2289 * elf64-ia64-vms.c, * elf64-mips.c, * elf64-mmix.c,
2290 * elf64-ppc.c, * elf64-s390.c, * elf64-sparc.c, * elf64-x86-64.c,
2291 * elfn32-mips.c, * elfnn-aarch64.c, * elfnn-ia64.c,
2292 * elfnn-riscv.c, * elfxx-mips.c, * elfxx-riscv.c, * elfxx-riscv.h,
2293 * elfxx-sparc.c, * elfxx-sparc.h, * reloc.c: Standardize
2294 unrecognized/unsupported reloc message.
2296 2018-02-26 Alan Modra <amodra@gmail.com>
2298 * elf32-ppc.c: Standardize error/warning messages. Use
2299 _bfd_error_handler rather than einfo when einfo features not used.
2300 * elf64-ppc.c: Likewise.
2302 2018-02-23 Alan Modra <amodra@gmail.com>
2305 * elf.c (assign_file_positions_for_non_load_sections): Remove RELRO
2306 segment if no matching LOAD segment.
2308 2018-02-23 Kuan-Lin Chen <kuanlinchentw@gmail.com>
2310 * elf32-nds32.h: Define mask for ict_model.
2312 2018-02-20 Jason Duerstock <jason.duerstock@gmail.com>
2314 * elfnn-ia64.c (elf_backend_can_gc_sections): Enable.
2316 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2319 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
2321 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
2322 .reginfo section has wrong size.
2324 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2326 * elfxx-mips.c (_bfd_mips_elf_always_size_sections): Set
2327 SEC_FIXED_SIZE and SEC_HAS_CONTENTS flags for `.reginfo' and
2328 `.MIPS.abiflags' sections.
2329 (_bfd_mips_elf_final_link): Avoid reading beyond `.reginfo'
2332 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2334 * section.c (SEC_FIXED_SIZE): New macro.
2335 * bfd-in2.h: Regenerate.
2337 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2339 * section.c (SEC_HAS_GOT_REF): Remove macro.
2340 * bfd-in2.h: Regenerate.
2342 2018-02-19 Alan Modra <amodra@gmail.com>
2344 * elf-attrs.c (_bfd_elf_parse_attributes): Correct _bfd_error_handler
2346 * elfxx-mips.c (_bfd_mips_elf_final_link): Likewise.
2347 * elfnn-riscv.c (_bfd_riscv_relax_align): Likewise.
2348 (_bfd_riscv_relax_pc): Likewise and fix typos.
2349 * libbfd-in.h (_bfd_error_handler): Add attribute printf.
2350 * libbfd.h: Regenerate.
2352 2018-02-19 Alan Modra <amodra@gmail.com>
2354 * dwarf2.c (read_section): Don't use 'll' format modifier.
2355 (find_abstract_instance): Likewise.
2356 * elfcore.h (elf_core_file_p): Likewise.
2358 2018-02-19 Alan Modra <amodra@gmail.com>
2360 * bfd-in.h: Include inttypes.h or if not available define
2361 PRId64, PRIu64 and PRIx64.
2362 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Remove support for L
2363 modifier to print bfd_vma.
2364 * coff-arm.c, * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c,
2365 * coff-sh.c, * coff-tic80.c, * coffcode.h, * coffgen.c, * cofflink.c,
2366 * compress.c, * dwarf2.c, * elf-m10300.c, * elf.c, * elf32-arc.c,
2367 * elf32-arm.c, * elf32-bfin.c, * elf32-cris.c, * elf32-hppa.c,
2368 * elf32-i386.c, * elf32-ip2k.c, * elf32-lm32.c, * elf32-m32r.c,
2369 * elf32-m68k.c, * elf32-metag.c, * elf32-nds32.c, * elf32-nios2.c,
2370 * elf32-ppc.c, * elf32-rx.c, * elf32-s390.c, * elf32-score.c,
2371 * elf32-score7.c, * elf32-sh.c, * elf32-sh64.c, * elf32-spu.c,
2372 * elf32-tic6x.c, * elf32-tilepro.c, * elf32-v850.c, * elf32-vax.c,
2373 * elf32-xtensa.c, * elf64-alpha.c, * elf64-hppa.c, * elf64-ia64-vms.c,
2374 * elf64-mmix.c, * elf64-s390.c, * elf64-sh64.c, * elf64-x86-64.c,
2375 * elfcode.h, * elfcore.h, * elflink.c, * elfnn-aarch64.c,
2376 * elfnn-ia64.c, * elfnn-riscv.c, * elfxx-mips.c, * elfxx-sparc.c,
2377 * elfxx-tilegx.c, * ieee.c, * ihex.c, * mach-o.c, * merge.c, * mmo.c,
2378 * peXXigen.c, * xcofflink.c: Replace use of Lx modifier with PRIx64,
2379 and cast input to uint64_t, and similarly for Ld and Lu.
2380 * bfd-in2.h: Regenerate.
2382 2018-02-19 Alan Modra <amodra@gmail.com>
2384 * elf32-arm.c, * elf32-hppa.c, * elf32-lm32.c, * elf32-m32r.c,
2385 * elf32-metag.c, * elf32-nds32.c, * elf32-or1k.c, * elf32-ppc.c,
2386 * elf32-s390.c, * elf32-sh.c, * elf32-tic6x.c, * elf32-tilepro.c,
2387 * elf64-ppc.c, * elf64-s390.c, * elflink.c, * elfnn-aarch64.c,
2388 * elfnn-riscv.c, * elfxx-sparc.c, * elfxx-tilegx.c, * elfxx-x86.c,
2389 * reloc.c: Replace use of %R and %T in format strings passed to
2390 einfo and friends by %pR and %pT.
2392 2018-02-19 Alan Modra <amodra@gmail.com>
2394 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Handle %pA and %pB in place
2396 * aout-adobe.c: Update all messages using %A and %B.
2397 * aout-cris.c: Likewise.
2398 * aoutx.h: Likewise.
2399 * archive.c: Likewise.
2400 * binary.c: Likewise.
2401 * cache.c: Likewise.
2402 * coff-alpha.c: Likewise.
2403 * coff-arm.c: Likewise.
2404 * coff-i860.c: Likewise.
2405 * coff-mcore.c: Likewise.
2406 * coff-ppc.c: Likewise.
2407 * coff-rs6000.c: Likewise.
2408 * coff-sh.c: Likewise.
2409 * coff-tic4x.c: Likewise.
2410 * coff-tic54x.c: Likewise.
2411 * coff-tic80.c: Likewise.
2412 * coff64-rs6000.c: Likewise.
2413 * coffcode.h: Likewise.
2414 * coffgen.c: Likewise.
2415 * cofflink.c: Likewise.
2416 * coffswap.h: Likewise.
2417 * compress.c: Likewise.
2418 * cpu-arm.c: Likewise.
2419 * ecoff.c: Likewise.
2420 * elf-attrs.c: Likewise.
2421 * elf-eh-frame.c: Likewise.
2422 * elf-ifunc.c: Likewise.
2423 * elf-m10300.c: Likewise.
2424 * elf-properties.c: Likewise.
2425 * elf-s390-common.c: Likewise.
2427 * elf32-arc.c: Likewise.
2428 * elf32-arm.c: Likewise.
2429 * elf32-avr.c: Likewise.
2430 * elf32-bfin.c: Likewise.
2431 * elf32-cr16.c: Likewise.
2432 * elf32-cr16c.c: Likewise.
2433 * elf32-cris.c: Likewise.
2434 * elf32-crx.c: Likewise.
2435 * elf32-d10v.c: Likewise.
2436 * elf32-d30v.c: Likewise.
2437 * elf32-epiphany.c: Likewise.
2438 * elf32-fr30.c: Likewise.
2439 * elf32-frv.c: Likewise.
2440 * elf32-gen.c: Likewise.
2441 * elf32-hppa.c: Likewise.
2442 * elf32-i370.c: Likewise.
2443 * elf32-i386.c: Likewise.
2444 * elf32-i960.c: Likewise.
2445 * elf32-ip2k.c: Likewise.
2446 * elf32-iq2000.c: Likewise.
2447 * elf32-lm32.c: Likewise.
2448 * elf32-m32c.c: Likewise.
2449 * elf32-m32r.c: Likewise.
2450 * elf32-m68hc11.c: Likewise.
2451 * elf32-m68hc12.c: Likewise.
2452 * elf32-m68hc1x.c: Likewise.
2453 * elf32-m68k.c: Likewise.
2454 * elf32-mcore.c: Likewise.
2455 * elf32-mep.c: Likewise.
2456 * elf32-metag.c: Likewise.
2457 * elf32-microblaze.c: Likewise.
2458 * elf32-moxie.c: Likewise.
2459 * elf32-msp430.c: Likewise.
2460 * elf32-mt.c: Likewise.
2461 * elf32-nds32.c: Likewise.
2462 * elf32-nios2.c: Likewise.
2463 * elf32-or1k.c: Likewise.
2464 * elf32-pj.c: Likewise.
2465 * elf32-ppc.c: Likewise.
2466 * elf32-rl78.c: Likewise.
2467 * elf32-rx.c: Likewise.
2468 * elf32-s390.c: Likewise.
2469 * elf32-score.c: Likewise.
2470 * elf32-score7.c: Likewise.
2471 * elf32-sh-symbian.c: Likewise.
2472 * elf32-sh.c: Likewise.
2473 * elf32-sh64.c: Likewise.
2474 * elf32-sparc.c: Likewise.
2475 * elf32-spu.c: Likewise.
2476 * elf32-tic6x.c: Likewise.
2477 * elf32-tilepro.c: Likewise.
2478 * elf32-v850.c: Likewise.
2479 * elf32-vax.c: Likewise.
2480 * elf32-visium.c: Likewise.
2481 * elf32-wasm32.c: Likewise.
2482 * elf32-xgate.c: Likewise.
2483 * elf32-xtensa.c: Likewise.
2484 * elf64-alpha.c: Likewise.
2485 * elf64-gen.c: Likewise.
2486 * elf64-hppa.c: Likewise.
2487 * elf64-ia64-vms.c: Likewise.
2488 * elf64-mmix.c: Likewise.
2489 * elf64-ppc.c: Likewise.
2490 * elf64-s390.c: Likewise.
2491 * elf64-sh64.c: Likewise.
2492 * elf64-sparc.c: Likewise.
2493 * elf64-x86-64.c: Likewise.
2494 * elfcode.h: Likewise.
2495 * elfcore.h: Likewise.
2496 * elflink.c: Likewise.
2497 * elfnn-aarch64.c: Likewise.
2498 * elfnn-ia64.c: Likewise.
2499 * elfnn-riscv.c: Likewise.
2500 * elfxx-mips.c: Likewise.
2501 * elfxx-sparc.c: Likewise.
2502 * elfxx-tilegx.c: Likewise.
2503 * elfxx-x86.c: Likewise.
2504 * hpux-core.c: Likewise.
2507 * libbfd.c: Likewise.
2508 * linker.c: Likewise.
2509 * mach-o.c: Likewise.
2510 * merge.c: Likewise.
2512 * oasys.c: Likewise.
2513 * pdp11.c: Likewise.
2514 * pe-mips.c: Likewise.
2515 * peXXigen.c: Likewise.
2516 * peicode.h: Likewise.
2517 * reloc.c: Likewise.
2518 * rs6000-core.c: Likewise.
2520 * stabs.c: Likewise.
2521 * vms-alpha.c: Likewise.
2522 * xcofflink.c: Likewise.
2524 2018-02-19 Alan Modra <amodra@gmail.com>
2527 * elf.c (IS_TBSS): Define.
2528 (_bfd_elf_map_sections_to_segments): Use IS_TBSS.
2529 (assign_file_positions_for_non_load_sections): Revert last change.
2530 Properly calculate load segment limits to compare against relro limits.
2532 2018-02-17 Alan Modra <amodra@gmail.com>
2535 * elf.c (assign_file_positions_for_non_load_sections): Ignore
2536 degenerate zero size PT_LOAD segments when finding one overlapping
2537 the PT_GNU_RELRO segment.
2539 2018-02-16 Alan Modra <amodra@gmail.com>
2541 * libbfd.c (_bfd_bool_bfd_false_error): Rename from bfd_false.
2542 (_bfd_bool_bfd_true): Rename from bfd_true.
2543 (_bfd_ptr_bfd_null_error): Rename from bfd_nullvoidptr.
2544 (_bfd_int_bfd_0): Rename from bfd_0.
2545 (_bfd_uint_bfd_0): Rename from bfd_0u.
2546 (_bfd_long_bfd_0): Rename from bfd_0l.
2547 (_bfd_long_bfd_n1_error): Rename from _bfd_n1.
2548 (_bfd_void_bfd): Rename from bfd_void.
2549 (_bfd_bool_bfd_false, _bfd_bool_bfd_asymbol_false),
2550 (_bfd_bool_bfd_link_false_error),
2551 (_bfd_bool_bfd_link_true, _bfd_bool_bfd_bfd_true),
2552 (_bfd_bool_bfd_uint_true, _bfd_bool_bfd_ptr_true),
2553 (_bfd_bool_bfd_asection_bfd_asection_true),
2554 (_bfd_bool_bfd_asymbol_bfd_asymbol_true),
2555 (_bfd_void_bfd_link, _bfd_void_bfd_asection): New functions.
2556 * archive.c (_bfd_noarchive_get_elt_at_index),
2557 (_bfd_noarchive_openr_next_archived_file),
2558 (_bfd_noarchive_construct_extended_name_table),
2559 (_bfd_noarchive_write_ar_hdr, _bfd_noarchive_truncate_arname),
2560 (_bfd_noarchive_write_armap): New functions.
2561 * archures.c (_bfd_nowrite_set_arch_mach): New function.
2562 * coff-alpha.c (alpha_ecoff_swap_coff_aux_in),
2563 (alpha_ecoff_swap_coff_sym_in, alpha_ecoff_swap_coff_lineno_in),
2564 (alpha_ecoff_swap_coff_aux_out, alpha_ecoff_swap_coff_sym_out),
2565 (alpha_ecoff_swap_coff_lineno_out),
2566 (alpha_ecoff_swap_coff_reloc_out): New functions.
2567 * coff-mips.c (mips_ecoff_swap_coff_aux_in),
2568 (mips_ecoff_swap_coff_sym_in, mips_ecoff_swap_coff_lineno_in),
2569 (mips_ecoff_swap_coff_aux_out, mips_ecoff_swap_coff_sym_out),
2570 (mips_ecoff_swap_coff_lineno_out),
2571 (mips_ecoff_swap_coff_reloc_out): New functions.
2572 * coffcode.h (coff_set_alignment_hook): Replace define with
2574 (symname_in_debug_hook): Likewise.
2575 * ecoff.c (_bfd_ecoff_set_alignment_hook): New function.
2576 * elfxx-target.h (elf_backend_allow_non_load_phdr): Default to 0.
2577 * elf.c (assign_file_positions_except_relocs): Test
2578 elf_backend_allow_non_load_phdr for NULL.
2579 * elflink.c (_bfd_elf_omit_section_dynsym_default): Rename from
2580 _bfd_elf_link_omit_section_dynsym. Update uses.
2581 (_bfd_elf_omit_section_dynsym_all): New function.
2582 * elf-bfd.h (_bfd_elf_link_omit_section_dynsym): Delete.
2583 (_bfd_elf_omit_section_dynsym_default): Declare.
2584 (_bfd_elf_omit_section_dynsym_all): Declare.
2585 * linker.c (_bfd_nolink_sizeof_headers, _bfd_nolink_bfd_relax_section),
2586 (_bfd_nolink_bfd_get_relocated_section_contents),
2587 (_bfd_nolink_bfd_lookup_section_flags),
2588 (_bfd_nolink_bfd_is_group_section, _bfd_nolink_bfd_discard_group),
2589 (_bfd_nolink_bfd_link_hash_table_create),
2590 (_bfd_nolink_bfd_link_just_syms),
2591 (_bfd_nolink_bfd_copy_link_hash_symbol_type),
2592 (_bfd_nolink_bfd_link_split_section),
2593 (_bfd_nolink_section_already_linked),
2594 (_bfd_nolink_bfd_define_common_symbol),
2595 (_bfd_nolink_bfd_define_start_stop): New functions.
2596 * reloc.c (_bfd_norelocs_bfd_reloc_type_lookup),
2597 (_bfd_norelocs_bfd_reloc_name_lookup),
2598 (_bfd_nodynamic_canonicalize_dynamic_reloc): New functions.
2599 * section.c (_bfd_nowrite_set_section_contents): New function.
2600 * syms.c (_bfd_nosymbols_canonicalize_symtab),
2601 (_bfd_nosymbols_print_symbol, _bfd_nosymbols_get_symbol_info),
2602 (_bfd_nosymbols_get_symbol_version_string),
2603 (_bfd_nosymbols_bfd_is_local_label_name),
2604 (_bfd_nosymbols_get_lineno, _bfd_nosymbols_find_nearest_line),
2605 (_bfd_nosymbols_find_line, _bfd_nosymbols_find_inliner_info),
2606 (_bfd_nosymbols_bfd_make_debug_symbol),
2607 ( _bfd_nosymbols_read_minisymbols),
2608 ( _bfd_nosymbols_minisymbol_to_symbol),
2609 (_bfd_nodynamic_get_synthetic_symtab): New functions.
2610 * libbfd-in.h: Declare new functions. Update existing defines,
2612 * aix386-core.c: Update to use new hooks. Formatting.
2613 * aout-adobe.c: Likewise.
2614 * aout-arm.c: Likewise.
2615 * aout-target.h: Likewise.
2616 * aout-tic30.c: Likewise.
2617 * aoutf1.h: Likewise.
2618 * binary.c: Likewise.
2620 * cisco-core.c: Likewise.
2621 * coff-alpha.c: Likewise.
2622 * coff-i386.c: Likewise.
2623 * coff-i860.c: Likewise.
2624 * coff-i960.c: Likewise.
2625 * coff-ia64.c: Likewise.
2626 * coff-mips.c: Likewise.
2627 * coff-ppc.c: Likewise.
2628 * coff-rs6000.c: Likewise.
2629 * coff-sh.c: Likewise.
2630 * coff-tic30.c: Likewise.
2631 * coff-tic54x.c: Likewise.
2632 * coff-x86_64.c: Likewise.
2633 * coff64-rs6000.c: Likewise.
2634 * coffcode.h: Likewise.
2635 * elf-m10300.c: Likewise.
2636 * elf32-cr16.c: Likewise.
2637 * elf32-lm32.c: Likewise.
2638 * elf32-m32r.c: Likewise.
2639 * elf32-metag.c: Likewise.
2640 * elf32-score.c: Likewise.
2641 * elf32-score7.c: Likewise.
2642 * elf32-tilepro.c: Likewise.
2643 * elf32-xstormy16.c: Likewise.
2644 * elf32-xtensa.c: Likewise.
2645 * elf64-alpha.c: Likewise.
2646 * elf64-hppa.c: Likewise.
2647 * elf64-ia64-vms.c: Likewise.
2648 * elf64-mmix.c: Likewise.
2649 * elf64-sh64.c: Likewise.
2650 * elfnn-ia64.c: Likewise.
2651 * elfxx-sparc.c: Likewise.
2652 * elfxx-target.h: Likewise.
2653 * elfxx-tilegx.c: Likewise.
2654 * elfxx-x86.h: Likewise.
2655 * hp300hpux.c: Likewise.
2656 * hppabsd-core.c: Likewise.
2657 * hpux-core.c: Likewise.
2658 * i386msdos.c: Likewise.
2659 * i386os9k.c: Likewise.
2662 * irix-core.c: Likewise.
2663 * libaout.h: Likewise.
2664 * libecoff.h: Likewise.
2665 * mach-o-target.c: Likewise.
2666 * mach-o.c: Likewise.
2667 * mipsbsd.c: Likewise.
2669 * netbsd-core.c: Likewise.
2670 * nlm-target.h: Likewise.
2671 * oasys.c: Likewise.
2672 * osf-core.c: Likewise.
2673 * pdp11.c: Likewise.
2674 * pe-mips.c: Likewise.
2675 * pe-x86_64.c: Likewise.
2677 * plugin.c: Likewise.
2678 * ppcboot.c: Likewise.
2679 * ptrace-core.c: Likewise.
2680 * sco5-core.c: Likewise.
2682 * sparclynx.c: Likewise.
2684 * tekhex.c: Likewise.
2685 * trad-core.c: Likewise.
2686 * verilog.c: Likewise.
2687 * versados.c: Likewise.
2688 * vms-alpha.c: Likewise.
2689 * vms-lib.c: Likewise.
2690 * wasm-module.c: Likewise.
2692 * libbfd.h: Regenerate.
2694 2018-02-15 Jim Wilson <jimw@sifive.com>
2696 * elfnn-riscv.c (_bfd_riscv_relax_section): Ifdef out check to ignore
2697 symbols whose section address is zero.
2699 * elfnn-riscv.c (riscv_elf_relocate_section): Use bfd_reloc_dangerous
2700 when pcrel_lo reloc has an addend. Use reloc_dangerous callback for
2701 bfd_reloc_dangerous. Use einfo instead of warning callback for errors.
2702 Add %X%P to error messages.
2704 2018-02-15 Eric Botcazou <ebotcazou@adacore.com>
2707 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
2708 Pass FALSE instead of TRUE as 'create' argument to bfd_link_hash_lookup
2709 and assert that the result of the call is not NULL.
2711 2018-02-14 Nick Clifton <nickc@redhat.com>
2714 Revert previous delta. Add extra casts to avoid compile time
2716 * libbfd-in.h (_bfd_generic_bfd_copy_private_bfd_data): Add extra
2717 cast to avoid warning from gcc v8 compiler.
2718 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
2719 (_bfd_generic_bfd_set_private_flags): Likewise.
2720 (_bfd_generic_bfd_copy_private_section_data): Likewise.
2721 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
2722 (_bfd_generic_bfd_copy_private_header_data): Likewise.
2723 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
2724 (_bfd_noarchive_construct_extended_name_table): Likewise.
2725 (_bfd_noarchive_truncate_arname): Likewise.
2726 (_bfd_noarchive_write_ar_hdr): Likewise.
2727 (_bfd_noarchive_get_elt_at_index): Likewise.
2728 (_bfd_nosymbols_canonicalize_symtab): Likewise.
2729 (_bfd_nosymbols_print_symbol): Likewise.
2730 (_bfd_nosymbols_get_symbol_info): Likewise.
2731 (_bfd_nosymbols_get_symbol_version_string): Likewise.
2732 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
2733 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
2734 (_bfd_nosymbols_get_lineno): Likewise.
2735 (_bfd_nosymbols_find_nearest_line): Likewise.
2736 (_bfd_nosymbols_find_line): Likewise.
2737 (_bfd_nosymbols_find_inliner_info): Likewise.
2738 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
2739 (_bfd_nosymbols_read_minisymbols): Likewise.
2740 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
2741 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
2742 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
2743 (_bfd_nowrite_set_arch_mach): Likewise.
2744 (_bfd_nowrite_set_section_contents): Likewise.
2745 (_bfd_nolink_sizeof_headers): Likewise.
2746 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
2747 (_bfd_nolink_bfd_relax_section): Likewise.
2748 (_bfd_nolink_bfd_gc_sections): Likewise.
2749 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
2750 (_bfd_nolink_bfd_merge_sections): Likewise.
2751 (_bfd_nolink_bfd_is_group_section): Likewise.
2752 (_bfd_nolink_bfd_discard_group): Likewise.
2753 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
2754 (_bfd_nolink_bfd_link_add_symbols): Likewise.
2755 (_bfd_nolink_bfd_link_just_syms): Likewise.
2756 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
2757 (_bfd_nolink_bfd_final_link): Likewise.
2758 (_bfd_nolink_bfd_link_split_section): Likewise.
2759 (_bfd_nolink_section_already_linked): Likewise.
2760 (_bfd_nolink_bfd_define_common_symbol): Likewise.
2761 (_bfd_nolink_bfd_define_start_stop): Likewise.
2762 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
2763 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
2764 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
2765 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
2766 * libbfd.c (bfd_false_any): Delete.
2767 (bfd_true_any, bfd_nullvoidptr_any, bfd_0_any): Delete.
2768 (bfd_0u_any, bfd_0l_any, _bfd_n1_any, bfd_void_any): Delete.
2769 * libbfd.h (extern): Regenerate
2770 * aout-target.h (MY_bfd_is_target_special_symbol): Add extra
2771 cast to avoid warning from gcc v8 compiler.
2772 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
2773 * binary.c (binary_get_symbol_info): Likewise.
2774 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
2775 * coff-mips.c (mips_ecoff_backend_data): Likewise.
2776 * coffcode.h (coff_set_alignment_hook): Likewise.
2777 (symname_in_debug_hook): Likewise.
2778 (bfd_coff_backend_data bigobj_swap_table): Likewise.
2779 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
2780 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
2781 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
2782 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
2783 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
2784 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
2785 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
2786 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
2787 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
2788 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
2789 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
2790 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
2791 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
2792 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
2793 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
2794 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
2795 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
2796 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
2797 (bfd_elfNN_bfd_set_private_flags): Likewise.
2798 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
2799 (elf_backend_init_index_section): Likewise.
2800 (elf_backend_allow_non_load_phdr): Likewise.
2801 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
2802 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
2803 * ieee.c (ieee_construct_extended_name_table): Likewise.
2804 (ieee_write_armap): Likewise.
2805 (ieee_write_ar_hdr): Likewise.
2806 (ieee_bfd_is_target_special_symbol): Likewise.
2807 * ihex.c (ihex_canonicalize_symtab): Likewise.
2808 (ihex_bfd_is_target_special_symbol): Likewise.
2809 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
2810 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
2811 (_bfd_ecoff_set_alignment_hook): Likewise.
2812 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
2813 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
2814 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
2815 * oasys.c (oasys_construct_extended_name_table): Likewise.
2816 (oasys_write_armap): Likewise.
2817 (oasys_write_ar_hdr): Likewise.
2818 (oasys_bfd_is_target_special_symbol): Likewise.
2819 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
2820 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
2821 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
2822 * som.c (som_bfd_is_target_special_symbol): Likewise.
2823 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
2824 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
2825 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
2826 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
2827 (versados_bfd_reloc_name_lookup): Likewise.
2828 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
2829 (vms_bfd_define_start_stop): Likewise.
2830 (alpha_vms_bfd_is_target_special_symbol): Likewise.
2831 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
2832 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
2834 2018-02-14 H.J. Lu <hongjiu.lu@intel.com>
2837 * elf32-i386.c (elf_i386_check_relocs): Pass FALSE for non
2838 PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
2839 * elf64-x86-64.c (elf_x86_64_check_relocs): Create PLT for
2840 R_X86_64_PC32 reloc against dynamic function in data section.
2841 Pass TRUE for PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
2842 (elf_x86_64_relocate_section): Use PLT for R_X86_64_PC32 reloc
2843 against dynamic function in data section.
2844 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Use PLT in PIE as
2845 function address only if pcrel_plt is true.
2846 (_bfd_x86_elf_link_hash_table_create): Set pcrel_plt.
2847 * elfxx-x86.h (NEED_DYNAMIC_RELOCATION_P): Add PCREL_PLT for
2848 PC-relative PLT. If PLT is PC-relative, don't generate dynamic
2849 PC-relative relocation against a function definition in data
2850 secton in PIE. Remove the obsolete comments.
2851 (elf_x86_link_hash_table): Add pcrel_plt.
2853 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
2855 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Check bfd_link_dll,
2856 instead of bfd_link_pic, for building shared library.
2858 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
2861 * elf64-x86-64.c (is_32bit_relative_branch): Removed.
2862 (elf_x86_64_relocate_section): Check PIC relocations in PIE.
2863 Remove is_32bit_relative_branch usage. Disallow PC32 reloc
2864 against protected function in shared object.
2866 2018-02-13 Sergei Trofimovich <slyfox@inbox.ru>
2869 * po/ru.po: Fix typo in Russian translation.
2871 2018-02-13 Maciej W. Rozycki <macro@mips.com>
2873 * wasm-module.c (wasm_scan_name_function_section): Rename
2874 `index' local variable to `idx'.
2876 2018-02-13 Nick Clifton <nickc@redhat.com>
2879 Fix compile time warnings generated by gcc version 8.
2880 * libbfd-in.h: Remove extraneous text from prototypes.
2881 Add prototypes for bfd_false_any, bfd_true_any,
2882 bfd_nullvoidptr_any, bfd_0_any, bfd_0u_any, bfd_0l_any,
2883 bfd_n1_any, bfd_void_any.
2884 (_bfd_generic_bfd_copy_private_bfd_data): Use vararg based dummy
2886 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
2887 (_bfd_generic_bfd_set_private_flags): Likewise.
2888 (_bfd_generic_bfd_copy_private_section_data): Likewise.
2889 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
2890 (_bfd_generic_bfd_copy_private_header_data): Likewise.
2891 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
2892 (_bfd_noarchive_construct_extended_name_table): Likewise.
2893 (_bfd_noarchive_truncate_arname): Likewise.
2894 (_bfd_noarchive_write_ar_hdr): Likewise.
2895 (_bfd_noarchive_get_elt_at_index): Likewise.
2896 (_bfd_nosymbols_canonicalize_symtab): Likewise.
2897 (_bfd_nosymbols_print_symbol): Likewise.
2898 (_bfd_nosymbols_get_symbol_info): Likewise.
2899 (_bfd_nosymbols_get_symbol_version_string): Likewise.
2900 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
2901 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
2902 (_bfd_nosymbols_get_lineno): Likewise.
2903 (_bfd_nosymbols_find_nearest_line): Likewise.
2904 (_bfd_nosymbols_find_line): Likewise.
2905 (_bfd_nosymbols_find_inliner_info): Likewise.
2906 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
2907 (_bfd_nosymbols_read_minisymbols): Likewise.
2908 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
2909 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
2910 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
2911 (_bfd_nowrite_set_arch_mach): Likewise.
2912 (_bfd_nowrite_set_section_contents): Likewise.
2913 (_bfd_nolink_sizeof_headers): Likewise.
2914 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
2915 (_bfd_nolink_bfd_relax_section): Likewise.
2916 (_bfd_nolink_bfd_gc_sections): Likewise.
2917 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
2918 (_bfd_nolink_bfd_merge_sections): Likewise.
2919 (_bfd_nolink_bfd_is_group_section): Likewise.
2920 (_bfd_nolink_bfd_discard_group): Likewise.
2921 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
2922 (_bfd_nolink_bfd_link_add_symbols): Likewise.
2923 (_bfd_nolink_bfd_link_just_syms): Likewise.
2924 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
2925 (_bfd_nolink_bfd_final_link): Likewise.
2926 (_bfd_nolink_bfd_link_split_section): Likewise.
2927 (_bfd_nolink_section_already_linked): Likewise.
2928 (_bfd_nolink_bfd_define_common_symbol): Likewise.
2929 (_bfd_nolink_bfd_define_start_stop): Likewise.
2930 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
2931 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
2932 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
2933 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
2934 * libbfd.c (bfd_false_any): New function. Like bfd_false but
2935 accepts one or more arguments.
2936 (bfd_true_any): Likewise.
2937 (bfd_nullvoidptr_any): Likewise.
2938 (bfd_0_any): Likewise.
2939 (bfd_0u_any): Likewise.
2940 (bfd_0l_any): Likewise.
2941 (_bfd_n1_any): Likewise.
2942 (bfd_void_any): Likewise.
2943 * libbfd.h (extern): Regenerate
2944 * aout-target.h (MY_bfd_is_target_special_symbol): Use vararg
2945 based dummy function.
2946 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
2947 * binary.c (binary_get_symbol_info): Likewise.
2948 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
2949 * coff-mips.c (mips_ecoff_backend_data): Likewise.
2950 * coffcode.h (coff_set_alignment_hook): Likewise.
2951 (symname_in_debug_hook): Likewise.
2952 (bfd_coff_backend_data bigobj_swap_table): Likewise.
2953 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
2954 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
2955 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
2956 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
2957 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
2958 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
2959 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
2960 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
2961 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
2962 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
2963 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
2964 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
2965 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
2966 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
2967 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
2968 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
2969 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
2970 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
2971 (bfd_elfNN_bfd_set_private_flags): Likewise.
2972 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
2973 (elf_backend_init_index_section): Likewise.
2974 (elf_backend_allow_non_load_phdr): Likewise.
2975 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
2976 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
2977 * ieee.c (ieee_construct_extended_name_table): Likewise.
2978 (ieee_write_armap): Likewise.
2979 (ieee_write_ar_hdr): Likewise.
2980 (ieee_bfd_is_target_special_symbol): Likewise.
2981 * ihex.c (ihex_canonicalize_symtab): Likewise.
2982 (ihex_bfd_is_target_special_symbol): Likewise.
2983 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
2984 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
2985 (_bfd_ecoff_set_alignment_hook): Likewise.
2986 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
2987 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
2988 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
2989 * oasys.c (oasys_construct_extended_name_table): Likewise.
2990 (oasys_write_armap): Likewise.
2991 (oasys_write_ar_hdr): Likewise.
2992 (oasys_bfd_is_target_special_symbol): Likewise.
2993 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
2994 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
2995 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
2996 * som.c (som_bfd_is_target_special_symbol): Likewise.
2997 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
2998 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
2999 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
3000 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
3001 (versados_bfd_reloc_name_lookup): Likewise.
3002 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
3003 (vms_bfd_define_start_stop): Likewise.
3004 (alpha_vms_bfd_is_target_special_symbol): Likewise.
3005 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
3006 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
3007 * elf32-arc.c (get_replace_function): Assign replacement function
3009 * elf32-i370.c (i370_noop): Update prototype.
3011 2018-02-13 Alan Modra <amodra@gmail.com>
3014 * elf.c (_bfd_elf_fixup_group_sections): Account for removed
3015 relocation sections. If size reduces to just the flag word,
3016 remove that too and mark with SEC_EXCLUDE.
3017 * elflink.c (bfd_elf_final_link): Strip empty group sections.
3019 2018-02-13 Alan Modra <amodra@gmail.com>
3022 * elf.c (assign_file_positions_for_non_load_sections): Rewrite
3025 2018-02-12 Zebediah Figura <z.figura12@gmail.com>
3027 * i386msdos.c (msdos_mkobject); New function.
3028 (msdos_object_p): New function.
3029 (i386_msdos_vec): Use msdos_object_p as the check_format
3031 * peicode.h: Rename external_PEI_DOS_hdr, DOSMAGIC, and
3032 NT_SIGNATURE to external_DOS_hdr, IMAGE_DOS_SIGNATURE, and
3034 * peXXigen.c: Likewise.
3035 * coff-ia64.c: Likewise.
3037 2018-02-12 Nick Clifton <nickc@redhat.com>
3039 * elf32-nds32.c (nds32_elf_relax_longjump3): Remove redundant
3041 * elf32-arc.c (elf_arc_relocate_section): Likewise.
3043 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
3045 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Reorder conditions.
3046 (sparc_elf_append_rela): Assert that there is enough room in section.
3047 (_bfd_sparc_elf_copy_indirect_symbol): Fix formatting.
3048 (_bfd_sparc_elf_adjust_dynamic_symbol): Minor tweak.
3049 (allocate_dynrelocs): Remove outdated comments and reorder conditions.
3050 For a symbol subject to a GOT relocation, reserve a slot in the
3051 relocation section if the symbol isn't dynamic and we are in PIC mode.
3052 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: If relocation
3053 is relaxed and a slot was reserved, generate a R_SPARC_NONE relocation.
3054 <R_SPARC_GOTDATA_OP_HIX22>: Adjust comments.
3055 <R_SPARC_PC10>: Reorder conditions. Remove always-false assertion.
3056 (_bfd_sparc_elf_finish_dynamic_symbol): Rename local_undefweak into
3057 resolved_to_zero. Do not generate a dynamic GOT relocation for an
3058 undefined weak symbol with non-default visibility. Remove superfluous
3059 'else' and fix formatting.
3061 2018-02-09 H.J. Lu <hongjiu.lu@intel.com>
3063 * elf32-i386.c (elf_i386_get_synthetic_symtab): Also handle
3065 (i386_elf32_sol2_vec): Don't declare.
3066 (elf_i386_link_setup_gnu_properties): Also handle is_solaris.
3067 Don't set need_global_offset_table.
3068 (elf_i386_solaris_arch_bed): New.
3069 (elf_backend_arch_data): Set to elf_i386_solaris_arch_bed for
3071 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Check
3072 target_os != is_nacl instead of target_os == is_normal.
3073 (x86_64_elf64_sol2_vec): Don't declare.
3074 (elf_x86_64_link_setup_gnu_properties): Check target_os !=
3075 is_nacl instead of target_os == is_normal. Don't set
3076 need_global_offset_table.
3077 (elf_x86_64_solaris_arch_bed): New.
3078 (elf_backend_arch_data): Set to elf_x86_64_solaris_arch_bed for
3080 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep
3081 _GLOBAL_OFFSET_TABLE_ for Solaris.
3082 (_bfd_x86_elf_link_setup_gnu_properties): Don't copy
3083 need_global_offset_table.
3084 * elfxx-x86.h (elf_x86_target_os): Add is_solaris.
3085 (elf_x86_link_hash_table): Remove need_global_offset_table.
3086 (elf_x86_init_table): Likewise.
3088 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
3090 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
3092 (i386_elf32_sol2_vec): Declared.
3093 (elf_i386_link_setup_gnu_properties): Set
3094 need_global_offset_table with info->output_bfd->xvec.
3095 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
3097 (x86_64_elf64_sol2_vec): Declared.
3098 (elf_x86_64_link_setup_gnu_properties): Set
3099 need_global_offset_table with info->output_bfd->xvec.
3101 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
3103 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
3105 (elf_i386_link_setup_gnu_properties): Set need_global_offset_table
3107 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
3109 (elf_x86_64_link_setup_gnu_properties): Set
3110 need_global_offset_table for Solaris.
3111 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep the
3112 unused _GLOBAL_OFFSET_TABLE_ for Solaris.
3113 (_bfd_x86_elf_link_setup_gnu_properties): Copy
3114 need_global_offset_table.
3115 * elfxx-x86.h (elf_x86_link_hash_table): Add
3116 need_global_offset_table.
3117 (elf_x86_init_table): Likewise.
3119 2018-02-08 Jim Wilson <jimw@sifive.com>
3121 * elfnn-riscv.c (riscv_elf_relocate_section): Add comment for previous
3124 2018-02-08 Nick Clifton <nickc@redhat.com>
3127 * elf.c (elf_parse_notes): Reject notes with excessuively large
3130 2018-02-07 Alan Modra <amodra@gmail.com>
3132 Revert 2018-01-17 Alan Modra <amodra@gmail.com>
3133 * elf32-ppc.c: Remove speculation barrier support.
3134 * elf32-ppc.h: Likewise.
3135 * elf64-ppc.c: Likewise.
3136 * elf64-ppc.h: Likewise.
3138 2018-02-06 Jim Wilson <jimw@sifive.com>
3140 * elfnn-riscv.c (riscv_elf_relocate_section): Return TRUE if used
3141 callback to report an error.
3143 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
3146 * elfxx-sparc.c (sparc_elf_tls_transition): Turn call to bfd_link_pic
3147 into call to !bfd_link_executable and tidy up.
3148 (_bfd_sparc_elf_check_relocs): Fix formatting and tidy up.
3149 <R_SPARC_TLS_LE_HIX22>: Turn call to bfd_link_pic into call to
3150 !bfd_link_executable.
3151 <R_SPARC_TLS_IE_HI22>: Likewise.
3152 <GOT relocations>: Remove useless code, tidy and merge related blocks.
3153 <R_SPARC_TLS_GD_CALL>: Turn call to bfd_link_pic into call to
3154 !bfd_link_executable.
3155 <R_SPARC_WPLT30>: Tidy up.
3156 (_bfd_sparc_elf_gc_mark_hook): Turn call to bfd_link_pic into call to
3157 !bfd_link_executable.
3158 (allocate_dynrelocs): Likewise.
3159 (_bfd_sparc_elf_relocate_section): Fix formatting and tidy up.
3160 <R_SPARC_TLS_GD_HI22>: Merge into...
3161 <R_SPARC_TLS_GD_LO10>: ...this. Adjust 4th argument in call to
3162 sparc_elf_tls_transition and remove redundant code.
3163 <R_SPARC_TLS_LDM_HI22>: Turn call to bfd_link_pic into call to
3164 !bfd_link_executable.
3165 <R_SPARC_TLS_LDO_HIX22>: Likewise.
3166 <R_SPARC_TLS_LE_HIX22>: Likewise. Tidy up.
3167 <R_SPARC_TLS_LDM_CALL>: Likewise.
3168 <R_SPARC_TLS_GD_CALL>: Likewise. Tidy up.
3169 <R_SPARC_TLS_GD_ADD>: Likewise.
3170 <R_SPARC_TLS_LDM_ADD>: Likewise.
3171 <R_SPARC_TLS_LDO_ADD>: Likewise.
3172 <R_SPARC_TLS_IE_LD>: Likewise.
3174 2018-02-06 Miloš Stojanović <milos.stojanovic@rt-rk.com>
3177 * elfxx-mips.c (_bfd_mips_elf_find_nearest_line): If the dwarf
3178 functions failed to find the function name, try the generic elf
3179 find function instead.
3181 2018-02-06 Sergio Durigan Junior <sergiodj@redhat.com>
3183 * coff-rs6000.c (xcoff_write_archive_contents_old): Use
3184 'memcpy' instead of 'strncpy' when writing the magic number.
3186 2018-02-06 Nick Clifton <nickc@redhat.com>
3189 * opncls.c (bfd_get_debug_link_info_1): Check the size of the
3190 section before attempting to read it in.
3191 (bfd_get_alt_debug_link_info): Likewise.
3193 2018-02-06 Paul Carroll <pcarroll@codesourcery.com>
3195 * bfd/dwarf2.c (find_abstract_name): Modified to return file and
3196 line information in addition to name, if they can be found.
3198 2018-02-05 Renlin Li <renlin.li@arm.com>
3201 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Relax the
3202 R_AARCH64_ABS32 and R_AARCH64_ABS16 for absolute symbol. Apply the
3203 check for writeable section as well.
3205 2018-02-05 H.J. Lu <hongjiu.lu@intel.com>
3208 * elf32-i386.c (elf_i386_check_relocs): Set got_referenced if
3209 _GLOBAL_OFFSET_TABLE_ is referenced or GOT is needed to resolve
3210 undefined weak symbol to 0.
3211 * elf64-x86-64.c (elf_x86_64_check_relocs): Set got_referenced
3212 if _GLOBAL_OFFSET_TABLE_ is referenced.
3213 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Check
3214 got_referenced instead of ref_regular_nonweak. Remove the
3215 unused _GLOBAL_OFFSET_TABLE_ from symbol table.
3216 * elfxx-x86.h (elf_x86_link_hash_table): Add got_referenced.
3218 2018-02-05 Maciej W. Rozycki <macro@mips.com>
3220 * elfnn-riscv.c (_bfd_riscv_relax_pc): Use `memset' to
3221 initialize `hi_reloc'.
3223 2018-02-05 Maciej W. Rozycki <macro@mips.com>
3225 * elfxx-mips.c (_bfd_mips_elf_section_processing): For
3226 SHT_MIPS_REGINFO sections don't assert the correct size and
3227 report an error instead.
3229 2018-02-05 Maciej W. Rozycki <macro@mips.com>
3231 * elf.c (_bfd_elf_write_object_contents): Propagate a failure
3232 status from `->elf_backend_section_processing'.
3234 2018-02-02 Jim Wilson <jimw@sifive.com>
3237 * elfnn-riscv.c (riscv_relax_delete_bytes): New parameter link_info.
3238 If link_info->wrap_hash, check for a duplicate symbol and ignore.
3239 (_bfd_riscv_relax_call, bfd_riscv_relax_lui, _bfd_riscv_relax_tls_le):
3240 Pass new argument to riscv_relax_delete_bytes.
3241 (_bfd_riscv_relax_align, _bfd_riscv_relax_delete): Likewise. Remove
3242 ATTRIBUTE_UNUSED from link_info parameter.
3244 2018-02-02 Alan Modra <amodra@gmail.com>
3246 * elf64-ppc.c (ppc64_elf_relocate_section): Don't relocate nops
3247 emitted for toc sequence optimization. Set and use "howto" later.
3249 2018-02-01 Simon Marchi <simon.marchi@ericsson.com>
3251 * elf64-ppc.c (ppc64_elf_archive_symbol_lookup): Avoid pointer
3252 arithmetic on NULL pointer.
3253 * elflink.c (_bfd_elf_archive_symbol_lookup,
3254 elf_link_add_archive_symbols): Likewise.
3256 2018-01-31 Michael Matz <matz@suse.de>
3258 * elflink.c (bfd_elf_define_start_stop): Fix check of
3261 2018-01-31 H.J. Lu <hongjiu.lu@intel.com>
3264 * elflink.c (bfd_elf_define_start_stop): Check if __start and
3265 __stop symbols are referenced by shared objects.
3267 2018-01-30 Alan Modra <amodra@gmail.com>
3270 * elf.c (_bfd_elf_map_sections_to_segments): Don't start a new
3271 segment when demand paged with lma on the same page. Test this
3272 before load/non-load, executable/non-executable,
3273 writable/non-writable tests and simplify. Delete bogus relro
3274 condition in writable/non-writable test. Delete outdated
3275 comment. Formatting.
3277 2018-01-30 Alan Modra <amodra@gmail.com>
3279 * elflink.c (bfd_elf_define_start_stop): Make __start and __stop
3282 2018-01-29 Alan Modra <amodra@gmail.com>
3285 * coffgen.c (coff_pointerize_aux): Ensure auxent tagndx is in
3286 range before converting to a symbol table pointer.
3288 2018-01-27 Nick Clifton <nickc@redhat.com>
3290 * po/ru.po: Updated Russian translation.
3292 2018-01-26 Alan Modra <amodra@gmail.com>
3294 * elflink.c (bfd_elf_define_start_stop): Override symbols when
3295 they are defined dynamically.
3297 2018-01-26 Alan Modra <amodra@gmail.com>
3299 * elf64-ppc.c (ppc64_elf_size_stubs): Iterate sizing when
3300 .branch_lt changes size.
3302 2018-01-25 Alan Modra <amodra@gmail.com>
3305 * elfcode.h (elf_object_p): Avoid integer overflow.
3307 2018-01-25 Eric Botcazou <ebotcazou@adacore.com>
3310 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
3311 Do a mere lookup of the __tls_get_addr symbol instead of adding it.
3314 2017-10-19 H.J. Lu <hongjiu.lu@intel.com>
3317 * elfxx-sparc.c (sparc_elf_tls_transition): Replace
3318 bfd_link_pic with !bfd_link_executable, !bfd_link_pic with
3319 bfd_link_executable for TLS check.
3320 (_bfd_sparc_elf_check_relocs): Likewise.
3321 (allocate_dynrelocs): Likewise.
3322 (_bfd_sparc_elf_relocate_section): Likewise.
3324 2018-01-24 Renlin Li <renlin.li@arm.com>
3326 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Add support for
3327 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
3328 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
3329 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
3330 BFD_RELOC_AARCH64_MOVW_PREL_G3.
3331 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
3332 (_bfd_aarch64_elf_resolve_relocation): Likewise.
3334 2018-01-24 Renlin Li <renlin.li@arm.com>
3336 * reloc.c: Add BFD_RELOC_AARCH64_MOVW_PREL_G0,
3337 BFD_RELOC_AARCH64_MOVW_PREL_G0_NC, BFD_RELOC_AARCH64_MOVW_PREL_G1,
3338 BFD_RELOC_AARCH64_MOVW_PREL_G1_NC, BFD_RELOC_AARCH64_MOVW_PREL_G2,
3339 BFD_RELOC_AARCH64_MOVW_PREL_G2_NC, BFD_RELOC_AARCH64_MOVW_PREL_G3.
3340 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add entries for
3341 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
3342 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
3343 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
3344 BFD_RELOC_AARCH64_MOVW_PREL_G3.
3345 * bfd-in2.h: Regenerate.
3346 * libbfd.h: Regenerate.
3348 2018-01-23 Maciej W. Rozycki <macro@mips.com>
3350 * elfxx-mips.c (_bfd_mips_elf_final_link): Update a stale
3351 `mips_elf32_section_processing' comment reference.
3353 2018-01-20 H.J. Lu <hongjiu.lu@intel.com>
3356 * elfxx-x86.c (_bfd_x86_elf_link_check_relocs): Check the
3357 versioned __tls_get_addr symbol.
3359 2018-01-19 Nick Clifton <nickc@redhat.com>
3361 * po/fr.po: Updated French translation.
3363 2018-01-18 Alan Modra <amodra@gmail.com>
3365 * elf32-ppc.c (ppc_elf_create_glink): Correct alignment of .glink.
3366 * elf64-ppc.c (ppc64_elf_size_stubs): Handle negative plt_stub_align.
3367 (ppc64_elf_build_stubs): Likewise.
3369 2018-01-17 Nick Clifton <nickc@redhat.com>
3371 * po/ru.po: Updated Russian translation.
3372 * po/uk/po: Updated Ukranian translation.
3374 2018-01-17 Alan Modra <amodra@gmail.com>
3376 * elf64-ppc.c (ppc64_elf_build_stubs): Silence gcc warning.
3378 2018-01-17 Alan Modra <amodra@gmail.com>
3380 * elf32-ppc.c (GLINK_ENTRY_SIZE): Handle speculation barrier.
3381 (CRSETEQ, BEQCTRM): Define.
3382 (is_nonpic_glink_stub): Don't check bctr.
3383 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
3384 (ppc_elf_relax_section): Size speculation barrier.
3385 (output_bctr): New function.
3386 (write_glink_stub): Use output_bctr.
3387 (ppc_elf_relocate_section): Use output_bctr for long branch stub.
3388 (ppc_elf_finish_dynamic_symbol): Likewise.
3389 (ppc_elf_finish_dynamic_sections): Use output_bctr.
3390 * elf32-ppc.h (struct ppc_elf_params): Add speculate_indirect_jumps.
3391 * elf64-ppc.c (CRSETEQ, BEQCTRM, BEQCTRLM): Define.
3392 (GLINK_PLTRESOLVE_SIZE): Size speculation barrier.
3393 (size_global_entry_stubs): Handle speculation barrier sizing.
3394 (plt_stub_size): Likewise.
3395 (output_bctr): New function.
3396 (build_plt_stub, build_tls_get_addr_stub): Output speculation
3398 (ppc_build_one_stub): Likewise for ppc_stub_plt_branch.
3399 (ppc_size_one_stub): Size speculation barrier in ppc_stub_plt_branch.
3400 (build_global_entry_stubs): Output speculation barrier.
3401 (ppc64_elf_build_stubs): Likewise in __glink_PLTresolve stub.
3402 * elf64-ppc.h (struct ppc64_elf_params): Add speculate_indirect_jumps.
3404 2018-01-17 Alan Modra <amodra@gmail.com>
3406 * elf32-ppc.c (GLINK_ENTRY_SIZE): Add parameters, handle
3407 __tls_get_addr_opt, and alignment sizing.
3408 (TLS_GET_ADDR_GLINK_SIZE): Delete.
3409 (is_nonpic_glink_stub): Don't use GLINK_ENTRY_SIZE.
3410 (ppc_elf_get_synthetic_symtab): Recognize stubs spaced at 4, 6,
3412 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
3413 (allocate_dynrelocs): Use new GLINK_ENTRY_SIZE.
3414 (ppc_elf_size_dynamic_sections): Likewise. Size branch table
3416 (write_glink_stub): Handle __tls_get_addr_opt stub.
3417 Pad out to size given by GLINK_ENTRY_SIZE.
3418 (ppc_elf_relocate_section): Adjust write_glink_stub call.
3419 (ppc_elf_finish_dynamic_symbol): Likewise.
3420 (ppc_elf_finish_dynamic_sections): Write PLTresolve without using
3421 insn array since so many need rewriting.
3422 * elf32-ppc.h (struct ppc_elf_params): Add plt_stub_align.
3423 * elf64-ppc.c (GLINK_PLTRESOLVE_SIZE): Rename from
3424 GLINK_CALL_STUB_SIZE. Add htab param and evaluate to size without
3425 nops. Adjust all uses.
3426 (ppc64_elf_get_synthetic_symtab): Don't use GLINK_CALL_STUB_SIZE
3427 in glink_vma calculation.
3428 (struct ppc_link_hash_table): Add global_entry section pointer.
3429 (create_linkage_sections): Create separate section for global
3431 (PPC_LO, PPC_HI, PPC_HA): Move earlier.
3432 (size_global_entry_stubs): Handle sizing for aligned stubs.
3433 (ppc64_elf_size_dynamic_sections): Handle global_entry alloc,
3434 and don't stash end of glink branch table in rawsize.
3435 (ppc_build_one_stub): Rewrite stub size calculations.
3436 (build_global_entry_stubs): Use new section.
3437 (ppc64_elf_build_stubs): Don't pad __glink_PLTresolve with nops.
3438 Build lazy link stubs out to end of section. Build global entry
3439 stubs in new section.
3441 2018-01-15 Nick Clifton <nickc@redhat.com>
3443 * po/uk.po: Updated Ukranian translation.
3445 2018-01-13 Nick Clifton <nickc@redhat.com>
3447 * po/bfd.pot: Regenerated.
3449 2018-01-13 Nick Clifton <nickc@redhat.com>
3451 * version.m4: Bump version to 2.30.51
3452 * configure: Regenerate.
3454 2018-01-13 Nick Clifton <nickc@redhat.com>
3456 2.30 branch created.
3458 2018-01-12 Jens Widell <jl@opera.com>
3460 * elf.c (setup_group): Optimize search for group by remembering
3461 last found group and restarting search at that index.
3462 * elf-bfd.h (struct elf_obj_tdata): Add group_search_offset field.
3464 2018-01-12 Gunther Nikl <gnikl@users.sourceforge.net>
3466 * aoutx.h (aout_link_check_ar_symbols): Remove default and handle
3467 bfd_link_common_skip_none in switch.
3469 2018-01-12 Alan Modra <amodra@gmail.com>
3472 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Ignore dynamic
3473 references on forced local symbols.
3475 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
3477 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
3478 .reginfo section has wrong size.
3480 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
3483 * elf.c (_bfd_elf_map_sections_to_segments): When generating
3484 separate code and read-only data LOAD segments, create a new
3485 LOAD segment if the previous section contains text and the
3486 current section doesn't or vice versa. Don't put a writable
3487 section in a read-only segment if there is a RELRO segment.
3489 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
3492 * elflink.c (bfd_elf_gc_mark_dynamic_ref_symbol): Ignore dynamic
3493 references on forced local symbols.
3495 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
3498 * elflink.c (bfd_elf_gc_sections): Keep all PREINIT_ARRAY,
3499 INIT_ARRAY as well as FINI_ARRAY sections for ld -r --gc-section.
3501 2018-01-09 Kuan-Lin Chen <kuanlinchentw@gmail.com>
3504 * elf32-nds32.c (nds32_elf_relax_loadstore): Fix a typographical error.
3506 2018-01-03 John Baldwin <jhb@FreeBSD.org>
3508 * elf.c (elfcore_grok_freebsd_note): Handle
3509 NT_FREEBSD_PROCSTAT_PROC, NT_FREEBSD_PROCSTAT_FILES, and
3510 NT_FREEBSD_PROCSTAT_VMMAP.
3512 2018-01-03 Alan Modra <amodra@gmail.com>
3514 Update year range in copyright notice of all files.
3516 For older changes see ChangeLog-2017
3518 Copyright (C) 2018 Free Software Foundation, Inc.
3520 Copying and distribution of this file, with or without modification,
3521 are permitted in any medium without royalty provided the copyright
3522 notice and this notice are preserved.
3528 version-control: never