1 2018-07-30 Nick Clifton <nickc@redhat.com>
4 * elf32-sh.c (sh_elf_relocate_section): When processing
5 translation relocs, fail if the relocation offset is too small.
6 Replace BFD_ASSERTs with more helpful error messages.
8 2018-07-30 Andrew Jenner <andrew@codesourcery.com>
10 * Makefile.am (ALL_MACHINES, ALL_MACHINES_CFILES): Add C-SKY.
11 (BFD32_BACKENDS, BFD_BACKENDS_CFILES): Likewise.
12 * Makefile.in: Regenerated.
13 * archures.c (enum bfd_architecture): Add bfd_arch_csky and
14 related bfd_mach defines.
15 (bfd_csky_arch): Declare.
16 (bfd_archures_list): Add C-SKY.
17 * bfd-in.h (elf32_csky_build_stubs): Declare.
18 (elf32_csky_size_stubs): Declare.
19 (elf32_csky_next_input_section: Declare.
20 (elf32_csky_setup_section_lists): Declare.
21 * bfd-in2.h: Regenerated.
22 * config.bfd: Add C-SKY.
23 * configure.ac: Likewise.
24 * configure: Regenerated.
25 * cpu-csky.c: New file.
26 * elf-bfd.h (enum elf_target_id): Add C-SKY.
27 * elf32-csky.c: New file.
28 * libbfd.h: Regenerated.
29 * reloc.c: Add C-SKY relocations.
30 * targets.c (csky_elf32_be_vec, csky_elf32_le_vec): Declare.
31 (_bfd_target_vector): Add C-SKY target vector entries.
33 2018-07-27 John Darrington <john@darrington.wattle.id.au>
35 * elf32-s12z.c (ELF_TARGET_ID): Don't define.
37 2018-07-27 John Darrington <john@darrington.wattle.id.au>
39 * libbfd.c (bfd_getb24, bfd_getl24): New functions.
40 (bfd_get_24, bfd_put_24): New macros.
41 * bfd-in2.h: Regenerate.
43 2018-07-27 John Darrington <john@darrington.wattle.id.au>
45 * elf32-s12z.c (s12z_elf_set_mach_from_flags): Remove comment.
47 2018-07-26 Alan Modra <amodra@gmail.com>
49 * elf64-ppc.c (ppc64_elf_size_stubs): Use a ppc_stub_long_branch_r2off
50 for calls to symbols with STO_PPC64_LOCAL_MASK bits set to 1.
52 2018-07-25 Alan Modra <amodra@gmail.com>
54 * elf32-ppc.c (ppc_elf_relax_section): Ignore common or undef locals.
55 Avoid trashing toff with added when used as a symbol index.
56 Ignore R_PPC_PLTREL24 addends in unused example code. Avoid
57 creating unnecessary fixups when relocatable.
59 2018-07-25 Alan Modra <amodra@gmail.com>
61 * elf32-arm.c (elf32_arm_nabi_write_core_note): Disable
62 -Wstringop-truncation warning for gcc-8.0 too.
63 * elf32-ppc.c (ppc_elf_write_core_note): Likewise.
64 * elf64-ppc.c (ppc64_elf_write_core_note): Likewise.
65 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewise.
66 * elf32-s390.c (elf_s390_write_core_note): Comment fix.
67 * elf64-s390.c (elf_s390_write_core_note): Likewise.
69 2018-07-24 Alan Modra <amodra@gmail.com>
72 * dwarf2.c (dwarf_debug_section_enum): Fix comment typo.
73 * elf.c (bfd_section_from_shdr, elf_sort_sections): Likewise.
75 2018-07-23 Max Filippov <jcmvbkbc@gmail.com>
77 * elf32-xtensa.c (elf_xtensa_finish_dynamic_sections): Move
78 relocation sections consistency check to always check both
79 .rela.dyn and .rela.plt when they exist. Rearrange variable
80 definition and assignment places.
82 2018-07-23 Max Filippov <jcmvbkbc@gmail.com>
84 * elf32-xtensa.c (shrink_dynamic_reloc_sections): Shrink dynamic
85 relocations section for dynamic undefined weak symbols when
86 linking a shared object.
88 2018-07-23 Tom Tromey <tom@tromey.com>
90 * elf.c (bfd_get_elf_phdrs): Don't call memcpy with size 0.
92 2018-07-21 Eric Botcazou <ebotcazou@adacore.com>
94 * elf32-arm.c (elf32_arm_final_link_relocate) <R_ARM_GOT32>: Small
95 cleanup for the case of a global symbol that binds locally. Also
96 install a value in the GOT slot in the case of a local symbol in
99 2018-07-20 H.J. Lu <hongjiu.lu@intel.com>
102 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): If the
103 separate code program header is needed, make sure that the first
104 read-only PT_LOAD segment has no code by adding a
105 GNU_PROPERTY_X86_ISA_1_USED note.
107 2018-07-20 Chenghua Xu <paul.hua.gm@gmail.com>
108 Maciej W. Rozycki <macro@mips.com>
110 * elfxx-mips.c (print_mips_ases): Add MMI extension.
112 2018-07-20 Maciej W. Rozycki <macro@mips.com>
114 * elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Do not
115 create DT_REL, DT_RELSZ or DT_RELENT dynamic entries if the
116 dynamic relocation section will be discarded from output.
117 (_bfd_mips_elf_finish_dynamic_sections) <DT_RELSZ>: Assert that
118 the dynamic relocation section will be retained in output.
120 2018-07-18 Maciej W. Rozycki <macro@mips.com>
122 * xcofflink.c (xcoff_write_global_symbol): Fix symbol type
123 checks for defined weak symbols.
125 2018-07-17 Maciej W. Rozycki <macro@mips.com>
127 * elf32-nds32.c (nds32_elf_relax_loadstore): Use
128 `bfd_is_abs_symbol' rather than `bfd_is_abs_section' in checking
129 whether the symbol is absolute.
130 (nds32_elf_relax_lo12): Likewise.
131 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Likewise.
132 (elfNN_aarch64_check_relocs): Likewise.
133 * xcofflink.c (xcoff_need_ldrel_p): Likewise.
134 (bfd_xcoff_import_symbol): Likewise.
135 (xcoff_write_global_symbol): Likewise.
137 2018-07-17 Maciej W. Rozycki <macro@mips.com>
139 * linker.c (bfd_is_abs_symbol): New macro.
140 * bfd-in2.h: Regenerate.
142 2018-07-16 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
144 * elf-bfd.h (elfcore_write_ppc_tar): Add prototype.
145 (elfcore_write_ppc_ppr): Likewise.
146 (elfcore_write_ppc_dscr): Likewise.
147 (elfcore_write_ppc_ebb): Likewise.
148 (elfcore_write_ppc_pmu): Likewise.
149 (elfcore_write_ppc_tm_cgpr): Likewise.
150 (elfcore_write_ppc_tm_cfpr): Likewise.
151 (elfcore_write_ppc_tm_cvmx): Likewise.
152 (elfcore_write_ppc_tm_cvsx): Likewise.
153 (elfcore_write_ppc_tm_spr): Likewise.
154 (elfcore_write_ppc_tm_ctar): Likewise.
155 (elfcore_write_ppc_tm_cppr): Likewise.
156 (elfcore_write_ppc_tm_cdscr): Likewise.
157 * elf.c (elfcore_write_ppc_tar): New function.
158 (elfcore_write_ppc_ppr): Likewise.
159 (elfcore_write_ppc_dscr): Likewise.
160 (elfcore_write_ppc_ebb): Likewise.
161 (elfcore_write_ppc_pmu): Likewise.
162 (elfcore_write_ppc_tm_cgpr): Likewise.
163 (elfcore_write_ppc_tm_cfpr): Likewise.
164 (elfcore_write_ppc_tm_cvmx): Likewise.
165 (elfcore_write_ppc_tm_cvsx): Likewise.
166 (elfcore_write_ppc_tm_spr): Likewise.
167 (elfcore_write_ppc_tm_ctar): Likewise.
168 (elfcore_write_ppc_tm_cppr): Likewise.
169 (elfcore_write_ppc_tm_cdscr): Likewise.
170 (elfcore_write_register_note): Call them.
171 (elfcore_grok_ppc_tar): New function.
172 (elfcore_grok_ppc_ppr): Likewise.
173 (elfcore_grok_ppc_dscr): Likewise.
174 (elfcore_grok_ppc_ebb): Likewise.
175 (elfcore_grok_ppc_pmu): Likewise.
176 (elfcore_grok_ppc_tm_cgpr): Likewise.
177 (elfcore_grok_ppc_tm_cfpr): Likewise.
178 (elfcore_grok_ppc_tm_cvmx): Likewise.
179 (elfcore_grok_ppc_tm_cvsx): Likewise.
180 (elfcore_grok_ppc_tm_spr): Likewise.
181 (elfcore_grok_ppc_tm_ctar): Likewise.
182 (elfcore_grok_ppc_tm_cppr): Likewise.
183 (elfcore_grok_ppc_tm_cdscr): Likewise.
184 (elfcore_grok_note): Call them.
186 2018-07-11 Maciej W. Rozycki <macro@mips.com>
188 * elfxx-mips.c (mips_tls_got_relocs): Use `bfd_link_dll' rather
189 than `!bfd_link_pic' in determining the dynamic symbol index.
190 Avoid the index of -1.
191 (mips_elf_initialize_tls_slots): Likewise. Flatten code by
192 moving `dyn' to the beginning of the function block.
194 2018-07-11 Maciej W. Rozycki <macro@mips.com>
195 Rich Felker <bugdal@aerifal.cx>
198 * elfxx-mips.c (mips_tls_got_relocs): Use `bfd_link_dll' rather
199 than `bfd_link_pic' to determine whether dynamic relocations are
201 (mips_elf_initialize_tls_slots): Likewise.
203 2018-07-10 Maciej W. Rozycki <macro@mips.com>
205 * elflink.c (bfd_elf_final_link): Rename `remove' local variable
208 2018-07-10 Alan Modra <amodra@gmail.com>
210 * elf32-xgate.h: Delete.
211 * elf32-xgate.c: Delete unnecessary forward declarations, add two
213 (xgate_elf_bfd_link_hash_table_create)
214 (xgate_elf_bfd_link_hash_table_free)
215 (xgate_elf_set_mach_from_flags, struct xgate_scan_param)
216 (stub_hash_newfunc, elf32_xgate_add_symbol_hook)
217 (elf32_xgate_setup_section_lists, elf32_xgate_size_stubs)
218 (elf32_xgate_build_stubs, elf32_xgate_check_relocs)
219 (elf32_xgate_relocate_section, _bfd_xgate_elf_set_private_flags)
220 (elf32_xgate_post_process_headers): Delete.
221 (elf32_xgate_backend_symbol_processing): New function.
222 (xgate_elf_ignore_reloc, xgate_elf_special_reloc)
223 (_bfd_xgate_elf_print_private_bfd_data): Make static.
224 (ELF_TARGET_ID, elf_info_to_howto, elf_backend_check_relocs)
225 (elf_backend_relocate_section, elf_backend_object_p)
226 (elf_backend_final_write_processing, elf_backend_can_gc_sections)
227 (elf_backend_post_process_headers, elf_backend_add_symbol_hook)
228 (bfd_elf32_bfd_link_hash_table_create)
229 (bfd_elf32_bfd_set_private_flags)
230 (xgate_stub_hash_lookup): Don't define.
231 (elf_backend_symbol_processing): Define.
232 * elf-bfd.h (elf_target_id): Delete XGATE_ELF_DATA.
234 2018-07-09 Maciej W. Rozycki <macro@mips.com>
236 * elfxx-mips.c (_bfd_mips_elf_adjust_dynamic_symbol): Don't set
237 `->needs_lazy_stub' if the stubs output section is the absolute
240 2018-07-09 H.J. Lu <hongjiu.lu@intel.com>
243 * configure.ac: Use changequote for "i[3-7]86-*-linux-*".
244 * configure: Regenerated.
246 2018-07-09 Alan Modra <amodra@gmail.com>
248 * elf32-m68hc1x.c (elf32_m68hc11_post_process_headers): Call
249 _bfd_elf_post_process_headers.
251 2018-07-06 Max Filippov <jcmvbkbc@gmail.com>
253 * elf32-xtensa.c (elf_xtensa_allocate_dynrelocs): Don't allocate
254 space for dynamic relocation for undefined weak symbol.
255 (elf_xtensa_relocate_section): Don't emit R_XTENSA_RELATIVE
256 relocation for undefined weak symbols.
257 (shrink_dynamic_reloc_sections): Don't shrink dynamic relocation
258 section for relocations against undefined weak symbols.
260 2018-07-06 Alan Hayward <alan.hayward@arm.com>
262 * elf.c (elfcore_grok_aarch_sve): New function.
263 (elfcore_grok_note): Check for Aarch64 SVE.
264 (elfcore_write_aarch_sve): New function.
265 (elfcore_write_register_note): Check for Aarch64 SVE.
266 * elf-bfd.h(elfcore_grok_aarch_sve): New declaration.
268 2018-07-06 Alan Modra <amodra@gmail.com>
270 * elf32-arm.c (elf32_arm_nabi_write_core_note): Don't use
271 DIAGNOTIC_PUSH and DIAGNOSTIC_POP unconditionally.
272 * elf32-ppc.c (ppc_elf_write_core_note): Likewise.
273 * elf32-s390.c (elf_s390_write_core_note): Likewise.
274 * elf64-ppc.c (ppc64_elf_write_core_note): Likewise.
275 * elf64-s390.c (elf_s390_write_core_note): Likewise.
276 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewise.
278 2018-07-05 Jim Wilson <jimw@sifive.com>
280 * config.bfd (riscv32*-*-*): Renamed from riscv32-*-*.
281 (riscv64*-*-*): Likewise.
282 (riscv-*-*): Add as an alias for riscv32*-*-*.
284 2018-07-05 H.J. Lu <hongjiu.lu@intel.com>
287 * elfxx-x86.c (_bfd_x86_elf_merge_gnu_properties): Remove x86
288 ISA properties with empty bits.
290 2018-07-05 Nick Clifton <nickc@redhat.com>
292 * po/ru.po: Updated Russian translation.
294 2018-07-05 Alan Modra <amodra@gmail.com>
296 * elf-bfd.h (_bfd_elf_ppc_merge_fp_attributes): Update prototype.
297 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Return error
298 on mismatch. Remove "warning: " from messages. Track last bfd
300 (ppc_elf_merge_obj_attributes): Likewise. Handle status from
301 _bfd_elf_ppc_merge_fp_attributes.
302 * elf64-ppc.c (ppc64_elf_merge_private_bfd_data): Handle status
303 from _bfd_elf_ppc_merge_fp_attributes.
305 2018-07-04 H.J. Lu <hongjiu.lu@intel.com>
307 * Makefile.am (bfdinclude_HEADERS): Add $(INCDIR)/diagnostics.h.
308 * Makefile.in: Regenerated.
310 2018-07-03 Alan Modra <amodra@gmail.com>
312 * elflink.c (bfd_elf_final_link): Remove zero size .gnu.attributes
315 2018-07-03 Alan Modra <amodra@gmail.com>
317 * elf-bfd.h (ATTR_TYPE_FLAG_ERROR, ATTR_TYPE_HAS_ERROR): Define.
318 * elf-attrs.c (is_default_attr): Handle ATTR_TYPE_HAS_ERROR.
319 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Use
320 ATTR_TYPE_FLAG_INT_VAL. Set ATTR_TYPE_HAS_ERROR on finding
321 incompatible attribute.
322 (ppc_elf_merge_obj_attributes): Likewise. Return
323 _bfd_elf_merge_object_attributes result.
324 * elf64-ppc.c (ppc64_elf_merge_private_bfd_data): Return
325 _bfd_elf_merge_object_attributes result.
327 2018-07-03 Alan Modra <amodra@gmail.com>
330 * elflink.c (_bfd_elf_fix_symbol_flags): Hide dynamic symbols
331 in discarded sections.
333 2018-07-02 Maciej W. Rozycki <macro@mips.com>
335 * elfxx-mips.c (_bfd_mips_elf_create_dynamic_sections): Set
336 `mark' for symbols created from `mips_elf_dynsym_rtproc_names'
339 2018-07-02 Maciej W. Rozycki <macro@mips.com>
341 * elf64-mips.c (micromips_elf64_howto_table_rel): Add
342 R_MICROMIPS_HI0_LO16, R_MICROMIPS_TLS_GD, R_MICROMIPS_TLS_LDM,
343 R_MICROMIPS_TLS_DTPREL_HI16, R_MICROMIPS_TLS_DTPREL_LO16,
344 R_MICROMIPS_TLS_GOTTPREL, R_MICROMIPS_TLS_TPREL_HI16,
345 R_MICROMIPS_TLS_TPREL_LO16, R_MICROMIPS_GPREL7_S2 and
346 R_MICROMIPS_PC23_S2 relocation entries.
347 (micromips_elf64_howto_table_rela): Likewise.
348 (micromips_reloc_map): Likewise.
349 * elfn32-mips.c (elf_micromips_howto_table_rel): Likewise.
350 (elf_micromips_howto_table_rela): Likewise.
351 (micromips_reloc_map): Likewise.
353 2018-07-02 H.J. Lu <hongjiu.lu@intel.com>
356 * elf64-x86-64.c (elf_x86_64_relocate_section): Clear the
357 R_X86_64_converted_reloc_bit bit.
359 2018-07-02 Jeff Muizelaar <jrmuizel@gmail.com>
360 Tom Tromey <tom@tromey.com>
364 * mach-o.c (bfd_mach_o_fat_close_and_cleanup): New function.
365 (bfd_mach_o_close_and_cleanup): Redefine.
366 * archive.c (_bfd_unlink_from_archive_parent): New function,
368 (_bfd_archive_close_and_cleanup): ..here.
369 (bfd_generic_archive_p): Do not clear archive's format.
370 * libbfd-in.h (_bfd_unlink_from_archive_parent): Declare.
371 * libbfd.h: Regenerate.
373 2018-07-02 Thomas Preud'homme <thomas.preudhomme@arm.com>
375 * archures.c (bfd_mach_arm_5TEJ, bfd_mach_arm_6, bfd_mach_arm_6KZ,
376 bfd_mach_arm_6T2, bfd_mach_arm_6K, bfd_mach_arm_7, bfd_mach_arm_6M,
377 bfd_mach_arm_6SM, bfd_mach_arm_7EM, bfd_mach_arm_8, bfd_mach_arm_8R,
378 bfd_mach_arm_8M_BASE, bfd_mach_arm_8M_MAIN): Define.
379 * bfd-in2.h: Regenerate.
380 * cpu-arm.c (arch_info_struct): Add entries for above new
382 * elf32-arm.c (bfd_arm_get_mach_from_attributes): Add Tag_CPU_arch to
383 bfd_mach_arm mapping logic for pre Armv4 and Armv5TEJ and later
384 architectures. Force assert failure for any new Tag_CPU_arch value.
386 2018-07-02 Thomas Preud'homme <thomas.preudhomme@arm.com>
388 * doc/bfdint.texi: Use command-line consistently when used in a
390 * doc/bfdsumm.texi: Likewise.
392 2018-06-29 Maciej W. Rozycki <macro@mips.com>
394 * elfxx-mips.c (allocate_dynrelocs): Remove extraneous symbol
395 visibility check made for undefined weak symbols.
397 2018-06-26 Nick Clifton <nickc@redhat.com>
399 * po/uk.po: Updated Ukranian translation.
401 2018-06-25 Nick Clifton <nickc@redhat.com>
403 * elfnn-aarch64.c (_bfd_aarch64_erratum_835769_stub_name): Check
404 for malloc returning NULL.
405 (_bfd_aarch64_erratum_843419_fixup): Check for
406 _bfd_aarch64_erratum_835769_stub_name returning NULL.
408 2018-06-24 Nick Clifton <nickc@redhat.com>
410 * po/bfd.pot: Regenerate.
412 2018-06-24 Nick Clifton <nickc@redhat.com>
414 * version.m4: Update version string to 2.31.51.
415 * configure: Regenerate.
417 2018-06-24 Nick Clifton <nickc@redhat.com>
421 2018-06-21 Maciej W. Rozycki <macro@mips.com>
423 * elfxx-mips.c (_bfd_mips_elf_compact_eh_encoding)
424 (_bfd_mips_elf_cant_unwind_opcode): Correct formatting.
426 2018-06-21 Maciej W. Rozycki <macro@mips.com>
428 * elfxx-mips.c (_bfd_mips_post_process_headers): Keep
429 EI_ABIVERSION setting together.
431 2018-06-21 Maciej W. Rozycki <macro@mips.com>
433 * elfxx-mips.c (MIPS_LIBC_ABI_DEFAULT, MIPS_LIBC_ABI_MIPS_PLT)
434 (MIPS_LIBC_ABI_UNIQUE, MIPS_LIBC_ABI_MIPS_O32_FP64)
435 (MIPS_LIBC_ABI_MAX): New enumeration constants.
436 (_bfd_mips_post_process_headers): Use them in place of magic
439 2018-06-21 Jim Wilson <jimw@sifive.com>
441 * elfnn-riscv.c (riscv_elf_finish_dynamic_symbol): Update comment.
442 Use SYMBOL_REFERENCES_LOCAL. Add asserts for h->got.offset.
444 2018-06-21 Alan Modra <amodra@gmail.com>
446 * doc/Makefile.am (AUTOMAKE_OPTIONS): Add "foreign".
447 * doc/Makefile.in: Regenerate.
449 2018-06-20 Renlin Li <renlin.li@arm.com>
451 * elfxx-aarch64.c (_bfd_aarch64_elf_resolve_relocation): Use PG_OFFSET
452 to resolve BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12_NC,
453 BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12_NC,
454 BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12_NC,
455 BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12_NC,
456 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
457 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
458 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
459 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
461 2018-06-20 Nick Clifton <nickc@redhat.com>
464 * opncls.c (get_build_id): Check for a negative or excessive data
465 size in the build-id note.
467 2018-06-20 Nick Clifton <nickc@redhat.com>
470 * mach-o.c (cputype): New function.
471 (cpusubtype): New function.
472 (bfd_mach_o_bfd_print_private_data): New function. Dispalys the
473 values in the MACH-O file header.
474 (bfd_mach_o_bfd_copy_private_header_data): Copy the cputype and
475 cpusubtype fields from the input bfd's mach-o header to the output
477 * mach-o-target.c (bfd_mach_o_bfd_print_private_bfd_data):
478 Redefine to bfd_mach_o_bfd_print_private_data.
479 * mach-o.h (bfd_mach_o_bfd_print_private_bfd_data): Prototype.
481 2018-06-19 Maciej W. Rozycki <macro@mips.com>
484 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Verify the
485 `.got.plt' entry referred is in range.
486 (mips_finish_exec_plt): Correct the range check for `.got.plt'
487 start. Replace the assertion used for that with a proper error
490 2018-06-19 Maciej W. Rozycki <macro@mips.com>
492 * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Fix
495 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
497 * Makefile.am (AUTOMAKE_OPTIONS): Remove 1.11.
498 (INCLUDES): Rename to ...
499 (AM_CPPFLAGS): ... this.
500 * configure.ac: Remove AC_PREREQ.
501 * doc/Makefile.am (AUTOMAKE_OPTIONS): Remove 1.9, cygnus, add
502 info-in-builddir no-texinfo.tex.
503 (info_TEXINFOS): Rename bfd.texinfo to bfd.texi.
504 * doc/bfd.texinfo: Rename to ...
505 * doc/bfd.texi: ... this.
506 * Makefile.in: Re-generate.
507 * aclocal.m4: Re-generate.
508 * config.in: Re-generate.
509 * configure: Re-generate.
510 * doc/Makefile.in: Re-generate.
512 2018-06-18 Mephi <mephi42@gmail.com>
515 * mach-o-x86-64.c (x86_64_howto_table): Add entry for
516 BFD_RELOC_MACH_O_X86_64_RELOC_TLV.
517 (bfd_mach_o_x86_64_canonicalize_one_reloc): Handle the new reloc.
518 (bfd_mach_o_x86_64_swap_reloc_out): Likewise.
519 * reloc.c (BFD_RELOC_MACH_O_X86_64_TV): New entry.
520 * bfd-in2.h: Regenerate.
521 * libbfd.h: Regenerate.
523 2018-06-14 Faraz Shahbazker <Faraz.Shahbazker@mips.com>
525 * elfxx-mips.c (print_mips_ases): Add GINV extension.
527 2018-06-14 H.J. Lu <hongjiu.lu@intel.com>
530 * elf.c (_bfd_elf_get_symbol_version_string): Check if the first
531 symbol version is base version.
533 2018-06-14 Alan Modra <amodra@gmail.com>
535 * elf-bfd.h (struct elf_link_hash_table): Add "dynamic_relocs".
536 * elflink.c (_bfd_elf_init_2_index_sections): Comment fix.
537 (_bfd_elf_add_dynamic_entry): Set "dynamic_relocs".
538 (_bfd_elf_link_renumber_dynsyms): Exclude all section symbols when
539 "dynamic_relocs" is not set.
540 * elfxx-mips.c (count_section_dynsyms): Likewise.
542 2018-06-14 Alan Modra <amodra@gmail.com>
545 * bfdio.c (bfd_seek): Optimize away seeks to current position.
547 2018-06-13 Scott Egerton <scott.egerton@imgtec.com>
548 Faraz Shahbazker <Faraz.Shahbazker@mips.com>
550 * elfxx-mips.c (print_mips_ases): Add CRC.
552 2018-06-08 H.J. Lu <hongjiu.lu@intel.com>
555 * elfxx-x86.c (elf_x86_hide_linker_defined): New function.
556 (_bfd_x86_elf_link_check_relocs): Use it to hide hidden
557 __bss_start, _end and _edata in shared libraries.
559 2018-06-07 Alan Modra <amodra@gmail.com>
561 * elf32-tic6x.c (elf32_tic6x_check_relocs): Reference
562 __c6xabi_DSBT_BASE explicitly for R_C6000_SBR_* relocs.
564 2018-06-05 Alan Modra <amodra@gmail.com>
566 * bfd.c (struct bfd): Update comment on "where" usage.
567 * bfdio.c (bfd_bwrite, bfd_stat): Use and update "iovec",
568 "iostream", and "where" from containing archive file. Return
570 (bfd_bread): Similarly, and return error attempted out of
571 bounds archive element access.
572 (bfd_tell, bfd_flush): Use and update "iovec", "iostream", and
573 "where" from containing archive file.
574 (bfd_seek): Likewise. Return error on NULL iovec. Don't
575 attempt to optimize away seeks. Don't paper over errors by
577 (bfd_get_mtime): Call bfd_stat rather than iovec->bstat.
578 (bfd_get_size): Likewise.
579 (bfd_mmap): Operate on and use iovec of containing archive
580 file. Return error on NULL iovec.
581 * cache.c (bfd_cache_lookup_worker): Abort if working on
583 (cache_bread_1): Delete bfd parameter, add FILE* parameter.
584 Don't ignore zero byte reads.
585 (cache_bread): Look up FILE* in cache here. Error on NULL
587 (cache_bwrite): Rename "where" to "from".
588 (cache_bmmap): Don't handle archive elements.
589 * coffcode.h (coff_slurp_line_table): Exit early on zero
591 * bfd-in2.h: Regenerate.
593 2018-06-05 Alan Modra <amodra@gmail.com>
596 * plugin.c (bfd_plugin_open_input): Allow for possibility of
597 nested archives. Open file again for plugin.
598 (try_claim): Don't save and restore file position. Close file
600 * sysdep.h (O_BINARY): Define.
602 2018-06-04 Max Filippov <jcmvbkbc@gmail.com>
604 * elf32-xtensa.c (xtensa_read_table_entries): Make global.
605 (compute_fill_extra_space): Drop declaration. Rename function to
606 xtensa_compute_fill_extra_space.
607 (compute_ebb_actions, remove_dead_literal): Update references to
608 compute_fill_extra_space.
610 2018-06-04 Volodymyr Arbatov <arbatov@cadence.com>
612 * elf32-xtensa.c (elf32xtensa_separate_props): New global
614 (xtensa_add_names): New function.
615 (xtensa_property_section_name): Add new parameter
616 separate_sections, use it to choose property section name.
617 (xtensa_get_separate_property_section): New function.
618 (xtensa_get_property_section): Invoke
619 xtensa_get_separate_property_section to get individual property
620 section if it exists, common property section otherwise.
621 (xtensa_make_property_section): Pass elf32xtensa_separate_props
622 to xtensa_property_section_name.
624 2018-06-04 H.J. Lu <hongjiu.lu@intel.com>
627 * bfd-in.h: Include "diagnostics.h".
628 * bfd-in2.h: Regenerated.
629 * elf32-arm.c (elf32_arm_nabi_write_core_note): Use
630 DIAGNOSTIC_PUSH, DIAGNOSTIC_IGNORE_STRINGOP_TRUNCATION and
631 DIAGNOSTIC_POP to silence GCC 8.1 warnings with
632 -Wstringop-truncation.
633 * elf32-ppc.c (ppc_elf_write_core_note): Likewse.
634 * elf32-s390.c (elf_s390_write_core_note): Likewse.
635 * elf64-ppc.c (ppc64_elf_write_core_note): Likewse.
636 * elf64-s390.c (elf_s390_write_core_note): Likewse.
637 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewse.
639 2018-06-03 Jim Wilson <jimw@sifive.com>
642 * elfnn-riscv.c (riscv_elf_relocate_section) <R_RISCV_CALL>: Check
643 for and handle an undefined weak with no PLT.
646 * elfnn-riscv.c (riscv_relax_delete_bytes): Add versioned_hidden check
647 to code that ignores duplicate symbols.
649 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
651 * version.m4: Bump version to 2.30.52
652 * configure: Regenerated.
654 2018-06-01 Alan Modra <amodra@gmail.com>
656 * bfd.c (_bfd_error_handler): Arrange for this function to be
657 declared in bfd-in2.h.
658 * libbfd-in.h (_bfd_error_handler): Don't declare.
659 * libbfd.h: Regenerate.
660 * bfd-in2.h: Regenerate.
662 2018-05-30 Amaan Cheval <amaan.cheval@gmail.com>
664 * config.bfd (x86_64-*-*): Add pei-x86-64 target to x86_64-*-rtems*
665 This is needed to generate UEFI application image files from ELFs.
667 2018-05-28 H.J. Lu <hongjiu.lu@intel.com>
669 * elf32-i386.c (elf_i386_lazy_plt): Add plt_tlsdesc_entry,
670 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
671 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
672 plt_tlsdesc_got2_insn_end for TLSDESC entry.
673 (elf_i386_lazy_ibt_plt): Likewise.
674 (elf_i386_nacl_plt): Likewise.
675 * elf64-x86-64.c (tlsdesc_plt_entry): Moved and renamed to ...
676 (elf_x86_64_tlsdesc_plt_entry): This.
677 (elf_x86_64_lazy_plt): Add plt_tlsdesc_entry,
678 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
679 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
680 plt_tlsdesc_got2_insn_end for TLSDESC entry.
681 (elf_x86_64_lazy_bnd_plt): Likewise.
682 (elf_x86_64_lazy_ibt_plt): Likewise.
683 (elf_x32_lazy_ibt_plt): Likewise.
684 (elf_x86_64_nacl_plt): Likewise.
685 (elf_x86_64_finish_dynamic_sections): Use plt_tlsdesc_entry,
686 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
687 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
688 plt_tlsdesc_got2_insn_end to update TLSDESC entry.
689 * elfxx-x86.h (elf_x86_lazy_plt_layout): Update comments.
690 Add plt_tlsdesc_entry, plt_tlsdesc_entry_size,
691 plt_tlsdesc_got1_offset, plt_tlsdesc_got2_offset,
692 plt_tlsdesc_got1_insn_end and plt_tlsdesc_got2_insn_end.
693 (elf_x86_non_lazy_plt_layout): Update comments.
694 (elf_x86_plt_layout): Likewise.
696 2018-05-28 H.J. Lu <hongjiu.lu@intel.com>
699 * elf-s390-common.c (elf_s390_add_symbol_hook): Removed.
700 * elf32-arc.c (elf_arc_add_symbol_hook): Likewise.
701 (elf_backend_add_symbol_hook): Likewise.
702 * elf32-m68k.c (elf_m68k_add_symbol_hook): Likewise.
703 (elf_backend_add_symbol_hook): Likewise.
704 * elf32-s390.c (elf_backend_add_symbol_hook): Likewise.
705 * elf32-sparc.c (elf32_sparc_add_symbol_hook): Likewise.
706 (elf_backend_add_symbol_hook): Likewise.
707 * elf64-s390.c (elf_backend_add_symbol_hook): Likewise.
708 * elfxx-aarch64.c (_bfd_aarch64_elf_add_symbol_hook): Likewise.
709 * elfxx-aarch64.h (_bfd_aarch64_elf_add_symbol_hook): Likewise.
710 (elf_backend_add_symbol_hook): Likewise.
711 * elf32-arm.c (elf32_arm_add_symbol_hook): Remove STT_GNU_IFUNC
713 * elf32-ppc.c (ppc_elf_add_symbol_hook): Likewise.
714 * elf64-ppc.c (ppc64_elf_add_symbol_hook): Likewise.
715 * elf64-sparc.c (elf64_sparc_add_symbol_hook): Likewise.
716 * elflink.c (elf_link_add_object_symbols): Set
717 elf_gnu_symbol_ifunc for STT_GNU_IFUNC symbols.
719 2018-05-26 H.J. Lu <hongjiu.lu@intel.com>
722 * elf-bfd.h (_bfd_elf_link_hide_sym_by_version): New.
723 * elflink.c (_bfd_elf_link_hide_versioned_symbol): New function.
724 Extracted from _bfd_elf_link_assign_sym_version.
725 (_bfd_elf_link_hide_sym_by_version): New function.
726 (_bfd_elf_link_assign_sym_version): Use
727 _bfd_elf_link_hide_versioned_symbol.
728 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Call
729 _bfd_elf_link_hide_sym_by_version instead of
730 bfd_hide_sym_by_version. Don't check unversioned symbol.
732 2018-05-25 Alan Modra <amodra@gmail.com>
734 * Makefile.in: Regenerate.
735 * po/SRC-POTFILES.in: Regenerate.
737 2018-05-25 Alan Modra <amodra@gmail.com>
739 * configure.ac (bfd_cv_hidden): Run test with -Werror in CFLAGS.
740 * configure: Regenerate.
742 2018-05-23 H.J. Lu <hongjiu.lu@intel.com>
744 * elf64-ppc.c (ppc64_elf_write_core_note): Add ATTRIBUTE_NONSTRING
747 2018-05-22 Alan Modra <amodra@gmail.com>
750 * elf32-hppa.c (hppa_get_stub_entry): Return NULL when link_sec
752 (elf32_hppa_size_stubs): Only create stubs for load, alloc, code
754 (final_link_relocate): Revert last change.
756 2018-05-22 Alan Modra <amodra@gmail.com>
759 * elf32-hppa.c (final_link_relocate): Don't look for plt call
760 stubs in non-alloc sections.
762 2018-05-21 H.J. Lu <hongjiu.lu@intel.com>
765 * aout-target.h (MY_bfd_link_hide_symbol): New.
766 * aout-tic30.c (MY_bfd_link_hide_symbol): Likewise.
767 * binary.c (binary_bfd_link_hide_symbol): Likewise.
768 * coff-alpha.c (_bfd_ecoff_bfd_link_hide_symbol): Likewise.
769 * coff-mips.c (_bfd_ecoff_bfd_link_hide_symbol): Likewise.
770 * coff-rs6000.c (_bfd_xcoff_bfd_link_hide_symbol): Likewise.
771 * coffcode.h (coff_bfd_link_hide_symbol): Likewise.
772 * elf-bfd.h (_bfd_elf_link_hide_symbol): Likewise.
773 * elfxx-target.h (bfd_elfNN_bfd_link_hide_symbol): Likewise.
774 * i386msdos.c (msdos_bfd_link_hide_symbol): Likewise.
775 * ihex.c (ihex_bfd_link_hide_symbol): Likewise.
776 * libbfd-in.h (_bfd_nolink_bfd_link_hide_symbol): Likewise.
777 * linker.c (_bfd_generic_link_hide_symbol): Likewise.
778 (bfd_link_hide_symbol): Likewise.
779 * mach-o-target.c (bfd_mach_o_bfd_link_hide_symbol): Likewise.
780 * mmo.c (mmo_bfd_link_hide_symbol): Likewise.
781 * pef.c (bfd_pef_bfd_link_hide_symbol): Likewise.
782 * plugin.c (bfd_plugin_bfd_link_hide_symbol): Likewise.
783 * ppcboot.c (ppcboot_bfd_link_hide_symbol): Likewise.
784 * som.c (som_bfd_link_hide_symbol): Likewise.
785 * srec.c (srec_bfd_link_hide_symbol): Likewise.
786 * tekhex.c (tekhex_bfd_link_hide_symbol): Likewise.
787 * vms-alpha.c (vms_bfd_link_hide_symbol): Likewise.
788 (alpha_vms_bfd_link_hide_symbol): Likewise.
789 * xsym.c (bfd_sym_bfd_link_hide_symbol): Likewise.
790 * coff64-rs6000.c (rs6000_xcoff64_vec): Add
791 _bfd_generic_link_hide_symbol.
792 (rs6000_xcoff64_aix_vec): Likewise.
793 * elflink.c (bfd_elf_record_link_assignment): Don't make forced
794 local symbol dynamic.
795 (_bfd_elf_link_hide_symbol): New function.
796 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
797 check root.ldscript_def.
798 * targets.c (bfd_target): Add _bfd_link_hide_symbol.
799 (BFD_JUMP_TABLE_LINK): Add NAME##_bfd_link_hide_symbol.
800 * bfd-in2.h: Regenerated.
801 * libbfd.h: Likewise.
803 2018-05-21 H.J. Lu <hongjiu.lu@intel.com>
806 * elf.c (setup_group): Mark section in a section group with
809 2018-05-18 H.J. Lu <hongjiu.lu@intel.com>
812 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
813 set eh->local_ref to 1 if a symbol is versioned and there is a
816 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
818 * elfnn-riscv.c (_bfd_riscv_elf_merge_private_bfd_data): Handle
821 2018-05-18 Jim Wilson <jimw@sifive.com>
823 * elfnn-riscv.c (allocate_dynrelocs): Discard dynamic relocations if
824 UNDEFWEAK_NO_DYNAMIC_RELOC is true.
825 (riscv_elf_relocate_section): Don't generate dynamic relocation if
826 UNDEFWEAK_NO_DYNAMIC_RELOC is true.
827 (riscv_elf_finish_dynamic_symbol): Likewise.
829 2018-05-18 John Darrington <john@darrington.wattle.id.au>
831 * Makefile.am: Add s12z files.
832 * Makefile.in: Regenerate.
833 * archures.c: Add bfd_s12z_arch.
834 * bfd-in.h: Add exports of bfd_putb24 and bfd_putl24.
835 * bfd-in2.h: Regenerate.
836 * config.bfd: Add s12z target.
837 * configure.ac: Add s12z target.
838 * configure: Regenerate.
839 * cpu-s12z.c: New file.
840 * elf32-s12z.c: New file.
841 * libbfd.c (bfd_putb24): New function.
842 (bfd_putl24): New function.
843 * libbfd.h: Regenerate.
844 * reloc.c: Add s12z relocations.
845 (bfd_get_reloc_size): Handle size 5 relocs.
846 * targets.c: Add s12z_elf32_vec.
848 2018-05-18 H.J. Lu <hongjiu.lu@intel.com>
851 * elf32-i386.c (elf_i386_relocate_section): Handle R_386_GOT32X
853 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
854 set eh->local_ref to 1 for linker defined symbols.
856 2018-05-18 Alan Modra <amodra@gmail.com>
859 * elf.c (setup_group): Formatting. Check that SHT_GROUP entries
860 don't point at other SHT_GROUP sections. Set shdr corresponding
861 to invalid entry, to NULL rather than section 0. Identify
862 SHT_GROUP section index when reporting an error. Cope with NULL
865 2018-05-18 Alan Modra <amodra@gmail.com>
867 * libbfd-in.h (ATTRIBUTE_HIDDEN): Define and use throughout.
868 * configure.ac (HAVE_HIDDEN): Check compiler support for hidden
870 * libbfd.h: Regenerate.
871 * configure: Regenerate.
872 * config.in: Regenerate.
874 2018-05-18 Alan Modra <amodra@gmail.com>
876 * libbfd-in.h: Add include guard.
877 * libcoff-in.h: Likewise.
878 * doc/Makefile.am (libbfd.h, libcoff.h): Append another #endif.
879 * doc/Makefile.in: Regenerate.
880 * libbfd.h: Regenerate.
881 * libcoff.h: Regenerate.
883 2018-05-16 Maciej W. Rozycki <macro@mips.com>
885 * elf32-nds32.c (nds32_convert_32_to_16): Preset `insn_type'.
887 2018-05-16 Alan Modra <amodra@gmail.com>
890 * format.c (struct bfd_preserve): Add section_id.
891 (bfd_preserve_save, bfd_preserve_restore): Save and restore
893 (bfd_reinit): Set _bfd_section_id.
894 (bfd_check_format_matches): Put all matches of any priority into
895 matching_vector. Save initial section id and start each attempted
896 match at that section id.
897 * libbfd-in.h (_bfd_section_id): Declare.
898 * section.c (_bfd_section_id): Rename from section_id and make
900 (bfd_get_next_section_id): Delete.
901 * elf64-ppc.c (ppc64_elf_setup_section_lists): Replace use of
902 bfd_get_section_id with _bfd_section_id.
903 * libbfd.h: Regenerate.
904 * bfd-in2.h: Regenerate.
906 2018-05-15 Christophe Guillon <christophe.guillon@st.com>
908 * coffcode.h (coff_bigobj_swap_aux_in): Make sure that all fields
909 of the aux structure are initialised.
911 2018-05-15 Francois H. Theron <francois.theron@netronome.com>
913 * targets.c: Wrap nfp_elf64_vec in BFD64 ifdef.
915 2018-05-15 Nick Clifton <nickc@redhat.com>
917 * po/pt.po: New Portuguese translation.
918 * configure.ac (ALL_LINGUAS): Add pt.
919 * configure: Regenerate.
921 2018-05-14 H.J. Lu <hongjiu.lu@intel.com>
924 * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Don't issue
925 an error on IFUNC pointer defined in PDE.
926 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Call
927 _bfd_x86_elf_link_fixup_ifunc_symbol.
928 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
929 * elfxx-x86.c (_bfd_x86_elf_link_fixup_ifunc_symbol): New
931 * elfxx-x86.h (_bfd_x86_elf_link_fixup_ifunc_symbol): New.
933 2018-05-14 H.J. Lu <hongjiu.lu@intel.com>
936 * elfxx-x86.c (elf_x86_linker_defined): New function.
937 (_bfd_x86_elf_link_check_relocs): Use it to mark __bss_start,
938 _end and _edata locally defined within executables.
940 2018-05-12 Alan Modra <amodra@gmail.com>
943 * elf.c (rewrite_elf_program_header): Use segment_mark only for
944 PT_LOAD headers. Delete first_matching_lma and first_suggested_lma.
945 Instead make matching_lma and suggested_lma pointers to the
946 sections. Align section vma and lma calculated from segment.
947 Don't clear includes_phdrs or includes_filehdr based on p_paddr
948 test. Try to handle alignment padding before first section by
949 adjusting new segment lma down. Adjust PT_PHDR map p_paddr.
951 2018-05-09 Dimitar Dimitrov <dimitar@dinux.eu>
953 * elf32-pru.c (pru_elf32_do_ldi32_relocate): Make LDI32 relocation
954 conformant to TI ABI.
955 (pru_elf32_relax_section): Likewise.
956 (pru_elf_relax_delete_bytes): Fix offsets for new LDI32 code.
957 * elf32-pru.c (pru_elf32_do_ldi32_relocate): Ignore addend.
958 (pru_elf32_pmem_relocate): Trap - should not get here.
959 (pru_elf32_relocate_section): Add support for REL relocations.
960 (elf_info_to_howto_rel): Enable REL.
961 (elf_backend_may_use_rel_p): Likewise.
962 (elf_backend_may_use_rela_p): Likewise.
963 (elf_backend_default_use_rela_p): Likewise.
965 2018-05-09 Alan Modra <amodra@gmail.com>
968 * peXXigen.c (pe_print_edata): Correct minimum size.
970 2018-05-09 Alan Modra <amodra@gmail.com>
973 * peXXigen.c (pe_print_idata): Bound check hint_addr.
975 2018-05-08 Nick Clifton <nickc@redhat.com>
978 * elf.c (bfd_elf_get_str_section): Check for an excessively large
980 * elf-attrs.c (_bfd_elf_parse_attributes): Issue an error if the
981 attribute section is larger than the size of the file.
983 2018-05-07 Alan Modra <amodra@gmail.com>
985 * cofflink.c (_bfd_coff_link_input_bfd): Use memcmp rather than
986 strncmp when checking for ".bf" special symbol.
987 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Make pe_required_section_flags
988 section name a char array, remove sentinal known_sections entry,
989 and adjust loop over known_sections to suit. Use memcmp rather
992 2018-05-04 Alan Modra <amodra@gmail.com>
994 * elf-linux-core.h (struct elf_external_linux_prpsinfo32_ugid32),
995 (struct elf_external_linux_prpsinfo32_ugid16),
996 (struct elf_external_linux_prpsinfo64_ugid32),
997 (struct elf_external_linux_prpsinfo64_ugid16): Add ATTRIBUTE_NONSTRING
998 to pr_fname and pr_psargs fields. Remove GCC diagnostic pragmas.
1000 * elf.c (elfcore_write_prpsinfo): ..here. Indent nested preprocessor
1002 * elf32-arm.c (elf32_arm_nabi_write_core_note): Add ATTRIBUTE_NONSTRING
1004 * elf32-ppc.c (ppc_elf_write_core_note): Likewise.
1005 * elf32-s390.c (elf_s390_write_core_note): Likewise.
1006 * elf64-s390.c (elf_s390_write_core_note): Likewise.
1007 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewise.
1008 * elf64-x86-64.c (elf_x86_64_write_core_note): Add GCC diagnostic
1010 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Use strnlen to avoid
1011 false positive gcc-8 warning.
1012 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
1014 2018-05-04 Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
1016 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Fix the order
1017 of arguments when warning about different long double types.
1019 2018-05-03 Simon Atanasyan <simon@atanasyan.com>
1021 * elf32-mips.c: (elf32_mips_fixup_symbol): New function.
1022 (elf_backend_fixup_symbol): New macro.
1023 * elfxx-mips.c: (mips_elf_output_extsym): Discard _gp_disp
1025 (_bfd_mips_elf_finish_dynamic_symbol): Likewise.
1027 2018-04-30 Francois H. Theron <francois.theron@netronome.com>
1029 * Makefile.am: Added NFP files to build.
1030 * archures.c: Added bfd_arch_nfp
1031 * config.bfd: Added NFP support.
1032 * configure.ac: Added NFP support.
1033 * cpu-nfp.c: New, for NFP support.
1034 * elf-bfd.h: Added elf_section_info()
1035 * elf64-nfp.c: New, for NFP support.
1036 * po/SRC-POTFILES.in: Added NFP source files.
1037 * targets.c: Added nfp_elf64_vec
1038 * bfd-in2.h: Regenerate.
1039 * Makefile.in: Regenerate.
1040 * configure: Regenerate.
1042 2018-04-27 Alan Modra <amodra@gmail.com>
1044 * bfd-in2.h: Regenerate.
1045 * libbfd.h: Regenerate.
1047 2018-04-27 Alan Modra <amodra@gmail.com>
1051 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Don't drop plt
1053 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Comment fixes.
1055 2018-04-26 Pedro Alves <palves@redhat.com>
1057 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Don't consider
1058 ifunc and non-ifunc symbols duplicates.
1060 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1061 Mickaël Guêné <mickael.guene@st.com>
1063 * elf32-arm.c (elf32_arm_fdpic_thumb_plt_entry): New.
1064 (elf32_arm_plt_needs_thumb_stub_p): Handle thumb-only case.
1065 (elf32_arm_populate_plt_entry): Likewise.
1066 (elf32_arm_output_plt_map_1): Likewise.
1067 (elf32_arm_output_arch_local_syms): Likewise.
1069 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1070 Mickaël Guêné <mickael.guene@st.com>
1072 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Handle
1073 _GLOBAL_OFFSET_TABLE_ in FDPIC mode.
1075 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1076 Mickaël Guêné <mickael.guene@st.com>
1078 * elf32-arm.c (bfd_elf32_arm_set_target_params): Handle FDPIC case
1081 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1082 Mickaël Guêné <mickael.guene@st.com>
1084 * elf32-arm.c (DEFAULT_STACK_SIZE): New.
1085 (elf32_arm_always_size_sections): Create stack segment.
1087 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1088 Mickaël Guêné <mickael.guene@st.com>
1090 * bfd-in2.h (BFD_RELOC_ARM_TLS_GD32_FDPIC)
1091 (BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC): New
1093 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_TLS_GD32_FDPIC,
1094 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC relocations.
1095 (elf32_arm_reloc_map): Add R_ARM_TLS_GD32_FDPIC,
1096 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC.
1097 (struct elf32_arm_link_hash_table): Update comment.
1098 (elf32_arm_final_link_relocate): Handle TLS FDPIC relocations.
1099 (IS_ARM_TLS_RELOC): Likewise.
1100 (elf32_arm_check_relocs): Likewise.
1101 (allocate_dynrelocs_for_symbol): Likewise.
1102 (elf32_arm_size_dynamic_sections): Update comment.
1103 * reloc.c: Add BFD_RELOC_ARM_TLS_GD32_FDPIC,
1104 BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC.
1106 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1107 Mickaël Guêné <mickael.guene@st.com>
1109 * elf32-arm.c (elf32_arm_fdpic_plt_entry): New.
1110 (elf32_arm_create_dynamic_sections): Handle FDPIC.
1111 (elf32_arm_allocate_plt_entry): Likewise.
1112 (elf32_arm_populate_plt_entry): Likewise.
1113 (elf32_arm_output_plt_map_1): Likewise.
1115 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1116 Mickaël Guêné <mickael.guene@st.com>
1118 * elf32-arm.c (struct fdpic_local): New.
1119 (elf_arm_obj_tdata): Add local_fdpic_cnts field.
1120 (elf32_arm_local_fdpic_cnts): New.
1121 (struct fdpic_global): New.
1122 (elf32_arm_link_hash_entry): Add fdpic_cnts field.
1123 (elf32_arm_link_hash_table): Add srofixup field.
1124 (arm_elf_add_rofixup): New.
1125 (arm_elf_fill_funcdesc): New.
1126 (elf32_arm_link_hash_newfunc): Handle fdpic_cnts.
1127 (elf32_arm_allocate_local_sym_info): Likewise.
1128 (create_got_section): Create .rofixup section.
1129 (elf32_arm_copy_indirect_symbol): Handle fdpic_cnts.
1130 (bfd_elf32_arm_set_target_params): Handle FDPIC.
1131 (elf32_arm_final_link_relocate): Likewise.
1132 (elf32_arm_check_relocs): Likewise.
1133 (allocate_dynrelocs_for_symbol): Likewise.
1134 (elf32_arm_size_dynamic_sections): Likewise.
1135 (elf32_arm_finish_dynamic_sections): Likewise.
1136 (elf32_arm_output_arch_local_syms): Likewise.
1137 (elf32_arm_fdpic_omit_section_dynsym): New.
1139 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1140 Mickaël Guêné <mickael.guene@st.com>
1142 * bfd-in2.c (BFD_RELOC_ARM_GOTFUNCDESC)
1143 (BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC)
1144 (BFD_RELOC_ARM_FUNCDESC_VALUE): New.
1145 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_GOTFUNCDESC,
1146 R_ARM_GOTOFFFUNCDESC, R_ARM_FUNCDESC, R_ARM_FUNCDESC_VALUE.
1147 (elf32_arm_howto_from_type): Take new members of
1148 elf32_arm_howto_table_2 into account.
1149 (elf32_arm_reloc_map): Add BFD_RELOC_ARM_GOTFUNCDESC,
1150 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
1151 BFD_RELOC_ARM_FUNCDESC_VALUE.
1152 * reloc.c: Add BFD_RELOC_ARM_GOTFUNCDESC,
1153 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
1154 BFD_RELOC_ARM_FUNCDESC_VALUE.
1156 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1157 Mickaël Guêné <mickael.guene@st.com>
1159 * elf32-arm.c (elf32_arm_print_private_bfd_data): Support
1160 EF_ARM_PIC and ELFOSABI_ARM_FDPIC.
1161 (elf32_arm_post_process_headers): Support ELFOSABI_ARM_FDPIC.
1162 (ELF_OSABI): Define to ELFOSABI_ARM_FDPIC.
1164 2018-04-25 Christophe Lyon <christophe.lyon@st.com>
1165 Mickaël Guêné <mickael.guene@st.com>
1167 * config.bfd (arm*-*-linux-*): Add arm_elf32_fdpic_be_vec and
1168 arm_elf32_fdpic_le_vec to targ_selvecs. Accept
1169 arm*-*-uclinuxfdpiceabi.
1170 * configure.ac: Add support for arm_elf32_fdpic_be_vec and
1171 arm_elf32_fdpic_le_vec.
1172 * configure: Regenerate.
1173 * elf32-arm.c (struct elf32_arm_link_hash_table): Add fdpic_p.
1174 (elf32_arm_link_hash_table_create): Initialize fdpic_p.
1175 (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME, TARGET_BIG_SYM)
1176 (TARGET_BIG_NAME, elf_match_priority): Define for FDPIC targets.
1177 (elf32_arm_fdpic_link_hash_table_create): New.
1178 * targets.c (_bfd_target_vector): Add arm_elf32_fdpic_be_vec and
1179 arm_elf32_fdpic_le_vec.
1181 2018-04-25 Alan Modra <amodra@gmail.com>
1183 * elf-linux-core.h: Disable gcc-8 string truncation warning.
1184 * elf.c (elfcore_write_prpsinfo): Likewise.
1186 2018-04-25 Alan Modra <amodra@gmail.com>
1188 * Makefile.am: Remove arm-aout and arm-coff support.
1189 * config.bfd: Likewise.
1190 * configure.ac: Likewise.
1191 * targets.c: Likewise.
1192 * aout-arm.c: Delete.
1193 * armnetbsd.c: Delete.
1195 * Makefile.in: Regenerate.
1196 * configure: Regenerate.
1197 * po/SRC-POTFILES.in: Regenerate.
1199 2018-04-24 Nick Clifton <nickc@redhat.com>
1202 * elf.c (ignore_section_sym): Check for the output_section pointer
1203 being NULL before dereferencing it.
1206 * peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Check for
1207 a negative PE_DEBUG_DATA size before iterating over the debug data.
1209 2018-04-23 Alan Modra <amodra@gmail.com>
1211 * elf-linux-core.h: Revert last change.
1214 2018-04-23 Nick Clifton <nickc@redhat.com>
1217 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
1218 the end of the string table, and zero it.
1220 2018-04-23 Alan Modra <amodra@gmail.com>
1222 * elf-linux-core.h (swap_linux_prpsinfo32_ugid32_out): Disable
1223 gcc-8 string truncation warning.
1224 (swap_linux_prpsinfo32_ugid16_out): Likewise.
1225 (swap_linux_prpsinfo64_ugid32_out): Likewise.
1226 (swap_linux_prpsinfo64_ugid16_out): Likewise.
1227 * elf.c (elfcore_write_prpsinfo): Likewise.
1229 2018-04-23 Nick Clifton <nickc@redhat.com>
1232 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
1233 the end of the string table, and zero it.
1235 2018-04-20 Alan Modra <amodra@gmail.com>
1238 * elf32-hppa.c (got_relocs_needed): Add extra param to special
1239 case both dtprel and tprel relocs.
1240 (allocate_dynrelocs): Adjust conditions for got relocs.
1241 (elf32_hppa_relocate_section): Likewise for local sym got relocs.
1242 Emit dynamic relocs on TLS GOT entries for shared libraries,
1243 not when pic. Omit dynamic reloc on dtprel entry when local,
1244 and on tprel entry when local and executable.
1246 2018-04-19 Alan Modra <amodra@gmail.com>
1249 * elf32-hppa.c (elf32_hppa_size_stubs): Init "destination" to -1.
1250 (hppa_type_of_stub): Don't return a long branch stub for
1251 symbols other than those defined statically.
1253 2018-04-19 Alan Modra <amodra@gmail.com>
1255 * Makefile.am: Revert 2018-04-18 coff-mips changes.
1256 * config.bfd: Add back mips_ecoff_le_vec and mips_ecoff_be_vec
1257 to selvecs for mips targets change 2018-04-18.
1258 * configure.ac: Reinstate mips_ecoff_le_vec, mips_ecoff_be_vec
1259 and mips_ecoff_bele_vec.
1260 * targets.c: Likewise.
1261 * coff-mips.c: Resurrect.
1262 * Makefile.in: Regenerate.
1263 * configure: Regenerate.
1264 * po/SRC-POTFILES.in: Regenerate.
1266 2018-04-18 Alan Modra <amodra@gmail.com>
1268 * Makefile.am: Remove mips aout and coff support.
1269 * config.bfd: Likewise.
1270 * configure.ac: Likewise.
1271 * targets.c: Likewise.
1272 * coff-mips.c: Delete
1275 * pei-mips.c: Delete
1276 * Makefile.in: Regenerate.
1277 * configure: Regenerate.
1278 * po/SRC-POTFILES.in: Regenerate.
1280 2018-04-17 H.J. Lu <hongjiu.lu@intel.com>
1282 * elf32-i386.c (elf32_bed): Define before including
1284 * elf64-x86-64.c (elf64_bed): Define before including
1286 (elf32_bed): Define before including "elf32-target.h".
1288 2018-04-17 H.J. Lu <hongjiu.lu@intel.com>
1291 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Use a
1292 normal input file with compatible relocation.
1294 2018-04-18 Alan Modra <amodra@gmail.com>
1296 * Makefile.am: Remove support for assorted i386 aout and coff targets.
1297 * config.bfd: Likewise.
1298 * configure.ac: Likewise.
1299 * doc/bfdint.texi: Likewise.
1300 * targets.c: Likewise.
1301 * freebsd.h: Delete.
1302 * i386dynix.c: Delete.
1303 * i386freebsd.c: Delete.
1304 * i386linux.c: Delete.
1305 * i386mach3.c: Delete.
1306 * i386netbsd.c: Delete.
1307 * i386os9k.c: Delete.
1308 * Makefile.in: Regenerate.
1309 * configure: Regenerate.
1310 * po/SRC-POTFILES.in: Regenerate.
1312 2018-04-17 Andrew Sadek <andrew.sadek.se@gmail.com>
1314 Microblaze Target: PIC data text relative
1316 * bfd/reloc.c (2 new BFD relocations):
1317 BFD_RELOC_MICROBLAZE_64_TEXTPCREL &
1318 BFD_RELOC_MICROBLAZE_64_TEXTPCREL
1319 * bfd/bfd-in2.h: Regenerate
1320 * bfd/libbfd.h: Regenerate
1321 * bfd/elf32-microblaze.c (Handle new relocs): define 'HOWTO' of 3
1322 new relocs and handle them in both relocate and relax functions.
1323 (microblaze_elf_reloc_type_lookup): add mapping between for new
1325 (microblaze_elf_relocate_section): Handle new relocs in case of
1327 (microblaze_elf_relax_section): Handle new relocs for elf relaxation.
1329 2018-04-17 Nick Clifton <nickc@redhat.com>
1332 * aoutx.h (find_nearest_line): Check that the symbol name exists
1333 and is long enough, before attempting to see if it is for a .o
1335 * hash.c (bfd_hash_hash): Add an assertion that the string is not
1337 * linker.c (bfd_link_hash_lookup): Fail if the table or string are
1339 (_bfd_generic_link_add_archive_symbols): Fail if an archive entry
1343 * dwarf2.c (concat_filename): Check for a NULL table pointer.
1345 2018-04-16 Nick Clifton <nickc@redhat.com>
1348 * coffgen.c (coff_pointerize_aux): Check for an out of range
1351 2018-04-16 Alan Modra <amodra@gmail.com>
1353 * Makefile.am: Remove arm-epoc-pe support.
1354 * coff-arm.c: Likewise.
1355 * config.bfd: Likewise.
1356 * configure.ac: Likewise.
1357 * targets.c: Likewise.
1358 * epoc-pe-arm.c: Delete.
1359 * epoc-pei-arm.c: Delete.
1360 * Makefile.in: Regenerate.
1361 * configure: Regenerate.
1362 * po/SRC-POTFILES.in: Regenerate.
1364 2018-04-16 Alan Modra <amodra@gmail.com>
1366 * Makefile.am: Remove sparc-aout and sparc-coff support.
1367 * config.bfd: Likewise.
1368 * configure.ac: Likewise.
1369 * targets.c: Likewise.
1370 * aout-sparcle.c: Delete.
1372 * cf-sparclynx.c: Delete.
1373 * coff-sparc.c: Delete.
1375 * sparclinux.c: Delete.
1376 * sparclynx.c: Delete.
1377 * sparcnetbsd.c: Delete.
1379 * Makefile.in: Regenerate.
1380 * configure: Regenerate.
1381 * po/SRC-POTFILES.in: Regenerate.
1383 2018-04-16 Alan Modra <amodra@gmail.com>
1385 * Makefile.am: Remove m68k-aout and m68k-coff support.
1386 * aoutf1.h: Likewise.
1387 * aoutx.h: Likewise.
1388 * archive.c: Likewise.
1389 * bfd-in.h: Likewise.
1391 * coffcode.h: Likewise.
1392 * coffswap.h: Likewise.
1393 * config.bfd: Likewise.
1394 * configure.ac: Likewise.
1395 * configure.host: Likewise.
1396 * doc/bfd.texinfo: Likewise.
1397 * doc/bfdint.texi: Likewise.
1398 * freebsd.h: Likewise.
1399 * gen-aout.c: Likewise.
1400 * hpux-core.c: Likewise.
1401 * libaout.h: Likewise.
1402 * libbfd-in.h: Likewise.
1403 * pdp11.c: Likewise.
1404 * peicode.h: Likewise.
1405 * riscix.c: Likewise.
1406 * targets.c: Likewise.
1408 * coff-apollo.c: Delete.
1409 * coff-aux.c: Delete.
1410 * coff-m68k.c: Delete.
1411 * coff-svm68k.c: Delete.
1412 * coff-u68k.c: Delete.
1413 * hosts/delta68.h: Delete.
1414 * hosts/hp300bsd.h: Delete.
1415 * hosts/m68kaux.h: Delete.
1416 * hosts/news.h: Delete.
1417 * hp300bsd.c: Delete.
1418 * hp300hpux.c: Delete.
1419 * liboasys.h: Delete.
1420 * m68k4knetbsd.c: Delete.
1421 * m68klinux.c: Delete.
1422 * m68knetbsd.c: Delete.
1424 * versados.c: Delete.
1425 * Makefile.in: Regenerate.
1426 * bfd-in2.h: Regenerate.
1427 * configure: Regenerate.
1428 * libbfd.h: Regenerate.
1429 * po/SRC-POTFILES.in: Regenerate.
1431 2018-04-16 Alan Modra <amodra@gmail.com>
1433 * Makefile.am: Remove sh5 and sh64 support.
1434 * archures.c: Likewise.
1435 * config.bfd: Likewise.
1436 * configure.ac: Likewise.
1437 * cpu-sh.c: Likewise.
1438 * elf32-sh-relocs.h: Likewise.
1439 * elf32-sh.c: Likewise.
1440 * targets.c: Likewise.
1441 * elf32-sh64-com.c: Delete.
1442 * elf32-sh64.c: Delete.
1443 * elf32-sh64.h: Delete.
1444 * elf64-sh64.c: Delete.
1445 * Makefile.in: Regenerate.
1446 * bfd-in2.h: Regenerate.
1447 * configure: Regenerate.
1448 * po/SRC-POTFILES.in: Regenerate.
1450 2018-04-16 Alan Modra <amodra@gmail.com>
1452 * Makefile.am: Remove sh-symbianelf support.
1453 * config.bfd: Likewise.
1454 * configure.ac: Likewise.
1455 * targets.c: Likewise.
1456 * elf32-sh-symbian.c: Delete.
1457 * Makefile.in: Regenerate.
1458 * configure: Regenerate.
1459 * po/SRC-POTFILES.in: Regenerate.
1461 2018-04-16 Alan Modra <amodra@gmail.com>
1463 * Makefile.am: Remove vax-bsd and vax-ultrix support.
1464 * config.bfd: Likewise.
1465 * configure.ac: Likewise.
1466 * targets.c: Likewise.
1468 * Makefile.in: Regenerate.
1469 * configure: Regenerate.
1470 * po/SRC-POTFILES.in: Regenerate.
1472 2018-04-16 Alan Modra <amodra@gmail.com>
1474 * Makefile.am: Remove w65 support.
1475 * archures.c: Likewise.
1476 * coffcode.h: Likewise.
1477 * config.bfd: Likewise.
1478 * configure.ac: Likewise.
1479 * targets.c: Likewise.
1480 * coff-w65.c: Delete.
1481 * cpu-w65.c: Delete.
1482 * Makefile.in: Regenerate.
1483 * bfd-in2.h: Regenerate.
1484 * configure: Regenerate.
1485 * po/SRC-POTFILES.in: Regenerate.
1487 2018-04-16 Alan Modra <amodra@gmail.com>
1489 * Makefile.am: Remove we32k support.
1490 * archures.c: Likewise.
1491 * coffcode.h: Likewise.
1492 * config.bfd: Likewise.
1493 * configure.ac: Likewise.
1494 * targets.c: Likewise.
1495 * coff-we32k.c: Delete.
1496 * cpu-we32k.c: Delete.
1497 * Makefile.in: Regenerate.
1498 * bfd-in2.h: Regenerate.
1499 * configure: Regenerate.
1500 * po/SRC-POTFILES.in: Regenerate.
1502 2018-04-16 Alan Modra <amodra@gmail.com>
1504 * Makefile.am: Remove m88k support.
1505 * aoutx.h: Likewise.
1506 * archures.c: Likewise.
1507 * coffcode.h: Likewise.
1508 * coffswap.h: Likewise.
1509 * config.bfd: Likewise.
1510 * configure.ac: Likewise.
1511 * cpu-ns32k.c: Likewise.
1512 * elf32-nds32.c: Likewise.
1513 * mach-o.c: Likewise.
1514 * netbsd-core.c: Likewise.
1515 * reloc.c: Likewise.
1516 * targets.c: Likewise.
1517 * coff-m88k.c: Delete.
1518 * cpu-m88k.c: Delete.
1519 * elf32-m88k.c: Delete.
1520 * hosts/m88kmach3.h: Delete.
1521 * m88kmach3.c: Delete.
1522 * m88kopenbsd.c: Delete.
1523 * Makefile.in: Regenerate.
1524 * bfd-in2.h: Regenerate.
1525 * configure: Regenerate.
1526 * po/SRC-POTFILES.in: Regenerate.
1528 2018-04-16 Alan Modra <amodra@gmail.com>
1530 * Makefile.am: Remove i370 support.
1531 * archures.c: Likewise.
1532 * config.bfd: Likewise.
1533 * configure.ac: Likewise.
1534 * targets.c: Likewise.
1535 * cpu-i370.c: Delete.
1536 * elf32-i370.c: Delete.
1537 * Makefile.in: Regenerate.
1538 * bfd-in2.h: Regenerate.
1539 * configure: Regenerate.
1540 * po/SRC-POTFILES.in: Regenerate.
1542 2018-04-16 Alan Modra <amodra@gmail.com>
1544 * Makefile.am: Remove h8500 support.
1545 * archures.c: Likewise.
1546 * coffcode.h: Likewise.
1547 * config.bfd: Likewise.
1548 * configure.ac: Likewise.
1549 * targets.c: Likewise.
1550 * coff-h8500.c: Delete.
1551 * cpu-h8500.c: 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 * Makefile.am: Remove h8300-coff support.
1560 * coffcode.h: Likewise.
1561 * config.bfd: Likewise.
1562 * configure.ac: Likewise.
1563 * reloc16.c: Likewise.
1564 * targets.c: Likewise.
1565 * coff-h8300.c: Delete.
1566 * Makefile.in: Regenerate.
1567 * configure: Regenerate.
1568 * po/SRC-POTFILES.in: Regenerate.
1570 2018-04-16 Alan Modra <amodra@gmail.com>
1572 * Makefile.am: Remove IEEE 695 support.
1573 * archures.c: Likewise.
1575 * config.bfd: Likewise.
1576 * configure.ac: Likewise.
1577 * doc/bfd.texinfo: Likewise.
1578 * doc/bfdint.texi: Likewise.
1579 * doc/bfdsumm.texi: Likewise.
1580 * section.c: Likewise.
1581 * targets.c: Likewise.
1583 * libieee.h: Delete.
1584 * Makefile.in: Regenerate.
1585 * bfd-in2.h: Regenerate.
1586 * configure: Regenerate.
1587 * po/SRC-POTFILES.in: Regenerate.
1589 2018-04-16 Alan Modra <amodra@gmail.com>
1591 * config.bfd: Remove tandem support.
1593 2018-04-16 Alan Modra <amodra@gmail.com>
1595 * Makefile.am: Remove newsos3 support.
1596 * aoutx.h: Likewise.
1597 * config.bfd: Likewise.
1598 * configure.ac: Likewise.
1599 * targets.c: Likewise.
1600 * newsos3.c: Delete.
1601 * Makefile.in: Regenerate.
1602 * configure: Regenerate.
1603 * po/SRC-POTFILES.in: Regenerate.
1605 2018-04-16 Alan Modra <amodra@gmail.com>
1607 * Makefile.am: Remove netware support.
1608 * bfd-in.h: Likewise.
1610 * config.bfd: Likewise.
1611 * configure.ac: Likewise.
1612 * doc/bfdint.texi: Likewise.
1613 * ecoff.c: Likewise.
1614 * targets.c: Likewise.
1616 * nlm-target.h: Delete.
1618 * nlm32-alpha.c: Delete.
1619 * nlm32-i386.c: Delete.
1620 * nlm32-ppc.c: Delete.
1621 * nlm32-sparc.c: Delete.
1624 * nlmcode.h: Delete.
1625 * nlmswap.h: Delete.
1626 * Makefile.in: Regenerate.
1627 * bfd-in2.h: Regenerate.
1628 * configure: Regenerate.
1629 * po/SRC-POTFILES.in: Regenerate.
1631 2018-04-16 Alan Modra <amodra@gmail.com>
1633 * archures.c: Remove tahoe support.
1634 * config.bfd: Likewise.
1635 * configure.ac: Likewise.
1636 * hosts/tahoe.h: Delete.
1637 * bfd-in2.h: Regenerate.
1638 * configure: Regenerate.
1640 2018-04-14 Alan Modra <amodra@gmail.com>
1642 * elf-bfd.h (struct elf_backend_data): Add relropagesize.
1643 * elfxx-target.h (ELF_RELROPAGESIZE): Provide default and
1645 (elfNN_bed): Init relropagesize.
1646 * bfd.c (bfd_emul_get_commonpagesize): Add boolean param to
1647 select relropagesize.
1648 * elf32-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
1649 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
1650 (ELF_MINPAGESIZE): Don't define.
1651 * elf64-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
1652 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
1653 * bfd-in2.h: Regenerate.
1655 2018-04-14 Alan Modra <amodra@gmail.com>
1657 * elf32-ppc.c (ELF_MAXPAGESIZE, ELF_COMMONPAGESIZE): Don't depend
1658 on __QNXTARGET__ define.
1660 2018-04-14 Alan Modra <amodra@gmail.com>
1662 * config.bfd: Add powerpc-*-lynxos* and powerpc-*-windiss*
1665 2018-04-11 Alan Modra <amodra@gmail.com>
1667 * aout-adobe.c: Delete.
1669 * coff-i860.c: Delete.
1670 * coff-i960.c: Delete.
1671 * cpu-i860.c: Delete.
1672 * cpu-i960.c: Delete.
1673 * elf32-i860.c: Delete.
1674 * elf32-i960.c: Delete.
1675 * hosts/i860mach3.h: Delete.
1676 * Makefile.am: Remove i860, i960, bout, and adobe support.
1677 * archures.c: Remove i860 and i960 support.
1678 * coffcode.h: Likewise.
1679 * reloc.c: Likewise.
1680 * aoutx.h: Comment updates.
1681 * archive.c: Remove BOUT and i960 support.
1682 * bfd.c: Remove BOUT support.
1683 * coffswap.h: Remove i960 support.
1684 * config.bfd: Remove i860, i960 and adobe targets.
1685 * configure.ac: Remove adode, bout, i860, i960, icoff targets.
1686 * targets.c: Likewise.
1687 * ieee.c: Remove i960 support.
1688 * mach-o.c: Remove i860 support.
1689 * Makefile.in: Regenerate.
1690 * bfd-in2.h: Regenerate.
1691 * configure: Regenerate.
1692 * libbfd.h: Regenerate.
1693 * po/SRC-POTFILES.in: Regenerate.
1695 2018-04-09 Maciej W. Rozycki <macro@mips.com>
1697 * elf64-mips.c (mips_elf64_write_rel): Handle a NULL BFD pointer
1698 in the BFD symbol referred by the relocation.
1699 (mips_elf64_write_rela): Likewise.
1701 2018-04-09 Maciej W. Rozycki <macro@mips.com>
1703 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Issue an
1704 error for out-of-range `r_sym' values.
1706 2018-04-09 Alan Modra <amodra@gmail.com>
1708 * elf64-ppc.c (struct _ppc64_elf_section_data): Add has_pltcall field.
1709 (struct ppc_link_hash_table): Add can_convert_all_inline_plt.
1710 (ppc64_elf_check_relocs): Set has_pltcall.
1711 (ppc64_elf_adjust_dynamic_symbol): Discard some PLT entries.
1712 (ppc64_elf_inline_plt): New function.
1713 (ppc64_elf_size_dynamic_sections): Discard some PLT entries for locals.
1714 * elf64-ppc.h (ppc64_elf_inline_plt): Declare.
1715 * elf32-ppc.c (has_pltcall): Define.
1716 (struct ppc_elf_link_hash_table): Add can_convert_all_inline_plt.
1717 (ppc_elf_check_relocs): Set has_pltcall.
1718 (ppc_elf_inline_plt): New function.
1719 (ppc_elf_adjust_dynamic_symbol): Discard some PLT entries.
1720 (ppc_elf_size_dynamic_sections): Likewise.
1721 * elf32-ppc.h (ppc_elf_inline_plt): Declare.
1723 2018-04-09 Alan Modra <amodra@gmail.com>
1725 * elf32-ppc.c (ppc_elf_howto_raw): Add PLTSEQ and PLTCALL howtos.
1726 (is_plt_seq_reloc): New function.
1727 (ppc_elf_check_relocs): Handle PLTSEQ and PLTCALL relocs.
1728 (ppc_elf_tls_optimize): Handle inline plt call sequence.
1729 (ppc_elf_relax_section): Handle PLTCALL reloc.
1730 (ppc_elf_relocate_section): Nop out inline plt call sequence when
1732 * elf64-ppc.c (ppc64_elf_howto_raw): Add R_PPC64_PLTSEQ and
1733 R_PPC64_PLTCALL entries. Comment R_PPC64_TOCSAVE.
1734 (has_tls_get_addr_call): Correct comment.
1735 (is_branch_reloc): Add PLTCALL.
1736 (is_plt_seq_reloc): New function.
1737 (ppc64_elf_check_relocs): Handle PLT16_LO_DS reloc. Set
1738 has_tls_reloc for R_PPC64_TLSGD and R_PPC64_TLSLD. Create plt
1739 entry for R_PPC64_PLTCALL.
1740 (ppc64_elf_tls_optimize): Handle inline plt call sequence.
1741 (ppc_type_of_stub): Handle PLTCALL reloc.
1742 (toc_adjusting_stub_needed): Likewise.
1743 (ppc64_elf_relocate_section): Set "can_plt_call" for PLTCALL
1744 reloc insn. Nop out inline plt call sequence when resolving
1745 locally. Handle __tls_get_addr inline plt call optimization.
1747 2018-04-09 Alan Modra <amodra@gmail.com>
1749 * elf64-ppc.c (LOCAL_PLT_ENTRY_SIZE): Define.
1750 (struct ppc_stub_hash_entry): Add symtype field.
1752 (struct ppc_link_hash_table): Add pltlocal and relpltlocal.
1753 (create_linkage_sections): Create pltlocal and relpltlocal.
1754 (ppc64_elf_check_relocs): Allow PLT relocs on local symbols.
1756 (ppc64_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
1757 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
1758 (ppc64_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
1759 Keep PLT entries for inline calls against locals.
1760 (ppc_build_one_stub): Use pltlocal as appropriate.
1761 (ppc_size_one_stub): Likewise.
1762 (ppc64_elf_size_stubs): Set symtype.
1763 (build_global_entry_stubs_and_plt): Init pltlocal and write
1764 relpltlocal for globals.
1765 (write_plt_relocs_for_local_syms): Likewise for local syms.
1766 (ppc64_elf_relocate_section): Support PLT for local syms.
1767 * elf32-ppc.c (PLT_KEEP): Define.
1768 (struct ppc_elf_link_hash_table): Add pltlocal and relpltlocal.
1769 (ppc_elf_create_glink): Create pltlocal and relpltlocal.
1770 (ppc_elf_check_relocs): Allow PLT relocs on local symbols.
1771 Set PLT_KEEP. Adjust update_local_sym_info call.
1772 (ppc_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
1773 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
1774 (ppc_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
1775 (ppc_elf_relocate_section): Support PLT16 relocs for local syms.
1776 (write_global_sym_plt): Init pltlocal and write relpltlocal.
1777 (ppc_finish_symbols): Likewise for locals.
1779 2018-04-09 Alan Modra <amodra@gmail.com>
1781 * elf64-ppc.c (ppc_build_one_stub): Move output of PLT relocs
1782 for local symbols to..
1783 (write_plt_relocs_for_local_syms): ..here. New function.
1784 (ppc64_elf_finish_dynamic_symbol): Move output of PLT relocs for
1786 (build_global_entry_stubs_and_plt): ..here. Rename from
1787 build_global_entry_stubs.
1788 (ppc64_elf_build_stubs): Always call build_global_entry_stubs_and_plt.
1789 Call write_plt_relocs_for_local_syms.
1790 * elf32-ppc.c (get_sym_h): New function.
1791 (ppc_elf_relax_section): Use get_sym_h.
1792 (ppc_elf_relocate_section): Move output of PLT relocs and glink
1793 stubs for local symbols to..
1794 (ppc_finish_symbols): ..here. New function.
1795 (ppc_elf_finish_dynamic_symbol): Move output of PLT relocs for
1797 (write_global_sym_plt): ..here. New function.
1798 * elf32-ppc.h (ppc_elf_modify_segment_map): Delete attribute.
1799 (ppc_finish_symbols): Declare.
1801 2018-04-09 Alan Modra <amodra@gmail.com>
1803 * elf32-ppc.c (ppc_elf_check_relocs): Handle PLT16 relocs.
1804 (ppc_elf_relocate_section): Likewise.
1805 * elf64-ppc.c (ppc64_elf_check_relocs): Handle PLT16_LO_DS.
1806 (ppc64_elf_relocate_section): Likewise. Correct PLT16
1807 resolution to plt entry relative to toc pointer.
1809 2018-04-09 Alan Modra <amodra@gmail.com>
1811 * elf64-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
1812 TLS_TPRELGD, TLS_EXPLICIT): Renumber. Test TLS_TLS throughout
1813 file when other TLS flags are tested in a mask.
1814 (TLS_MARK, NON_GOT): Define.
1815 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
1816 (update_local_sym_info): Don't create got entry when NON_GOT.
1817 (ppc64_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
1819 (get_tls_mask): Do toc lookup if tls_mask is just TLS_MARK.
1820 (ppc64_elf_relocate_section): Likewise.
1821 (ppc64_elf_tls_optimize): Don't attempt to optimize indirect
1822 __tls_get_addr calls lacking a marker reloc.
1823 * elf32-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
1824 TLS_TPRELGD): Renumber. Update comment.
1825 (TLS_MARK, NON_GOT): Define.
1826 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
1827 (update_local_sym_info): Don't create got entry when NON_GOT.
1828 (ppc_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
1830 (ppc_elf_tls_optimize): Don't attempt to optimize indirect
1831 __tls_get_addr calls lacking a marker reloc.
1833 2018-04-06 H.J. Lu <hongjiu.lu@intel.com>
1835 * elf64-x86-64.c (elf_x86_64_info_to_howto): Don't mask out
1836 R_X86_64_converted_reloc_bit.
1838 2018-04-05 H.J. Lu <hongjiu.lu@intel.com>
1841 * configure: Regenerated.
1843 2018-04-05 Alan Modra <amodra@gmail.com>
1845 * elf-hppa.h (elf_hppa_info_to_howto): Init howto to NULL.
1846 (elf_hppa_info_to_howto_rel): Likewise.
1848 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1850 * elf-hppa.h (elf_hppa_info_to_howto): Also return
1851 unsuccessfully for unimplemented relocations.
1852 (elf_hppa_info_to_howto_rel): Likewise.
1854 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1856 * elf32-i860.c (lookup_howto): Add `abfd' parameter. Set the
1857 `bfd_error_bad_value' error and call `_bfd_error_handler' on a
1858 howto lookup failure.
1859 (elf32_i860_reloc_type_lookup): Adjust `lookup_howto' call
1861 (elf32_i860_info_to_howto_rela): Likewise.
1862 (elf32_i860_relocate_splitn): Likewise.
1863 (elf32_i860_relocate_pc16): Likewise.
1864 (elf32_i860_relocate_pc26): Likewise.
1865 (elf32_i860_relocate_section): Likewise.
1867 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1869 * elf32-visium.c (visium_info_to_howto_rela): Correct the range
1870 check for `visium_elf_howto_table' table access.
1872 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1874 * elf32-iq2000.c (iq2000_info_to_howto_rela): Correct the range
1875 check for `iq2000_elf_howto_table' table access.
1877 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1879 * elf32-frv.c (frv_info_to_howto_rela): Correct the range check
1880 for `elf32_frv_howto_table' table access.
1882 2018-04-04 Maciej W. Rozycki <macro@mips.com>
1884 * elf32-mips.c (mips_elf32_rtype_to_howto): Also return
1885 unsuccessfully for placeholder howtos.
1886 * elf64-mips.c (mips_elf64_rtype_to_howto): Likewise.
1887 * elfn32-mips.c (mips_elf_n32_rtype_to_howto): Likewise.
1889 2018-03-29 Maciej W. Rozycki <macro@mips.com>
1891 * elf32-mips.c (mips_info_to_howto_rel): Remove the calls to
1892 `_bfd_error_handler' and to set the `bfd_error_bad_value' error.
1894 2018-03-28 Maciej W. Rozycki <macro@mips.com>
1896 * elf-hppa.h (elf_hppa_info_to_howto_rel): Remove
1897 ATTRIBUTE_UNUSED from `abfd'.
1899 2018-03-28 Maciej W. Rozycki <macro@mips.com>
1901 * elf-hppa.h (elf_hppa_info_to_howto_rel): Correct
1902 `_bfd_error_handler' call formatting.
1904 2018-03-28 Maciej W. Rozycki <macro@mips.com>
1906 * elf32-mips.c (mips_info_to_howto_rel): Call
1907 `mips_elf32_rtype_to_howto' directly rather than via
1908 `->elf_backend_mips_rtype_to_howto'.
1910 2018-03-28 Renlin Li <renlin.li@arm.com>
1913 * elfnn-aarch64.c (IS_AARCH64_TLS_RELOC): Add cases for
1914 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
1915 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
1916 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
1917 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
1918 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
1919 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
1920 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
1921 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
1922 (elfNN_aarch64_final_link_relocate): Support new relocations.
1923 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Support new
1925 (_bfd_aarch64_elf_resolve_relocation): Support new relocations.
1927 2018-03-28 Renlin Li <renlin.li@arm.com>
1930 * reloc.c: Add BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12
1931 BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12_NC,
1932 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
1933 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
1934 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
1935 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
1936 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
1937 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
1938 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
1939 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
1940 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add table entry for
1941 TLSLE_LDST16_TPREL_LO12,
1942 TLSLE_LDST16_TPREL_LO12_NC,
1943 TLSLE_LDST32_TPREL_LO12,
1944 TLSLE_LDST32_TPREL_LO12_NC,
1945 TLSLE_LDST64_TPREL_LO12,
1946 TLSLE_LDST64_TPREL_LO12_NC,
1947 TLSLE_LDST8_TPREL_LO12,
1948 TLSLE_LDST8_TPREL_LO12_NC.
1949 * bfd-in2.h: Regenerated.
1950 * libbfd.h: Regenerated.
1952 2018-03-28 Eric Botcazou <ebotcazou@adacore.com>
1955 * elfxx-sparc.c (struct _bfd_sparc_elf_link_hash_entry): Add new flag
1956 has_old_style_got_reloc.
1957 (_bfd_sparc_elf_check_relocs) <GOT relocations>: Set it for old-style
1958 relocations. Fix a couple of long lines.
1959 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: Do not generate
1960 a R_SPARC_NONE for the GOT slot if the symbol is also subject to old-style
1963 2018-03-25 H.J. Lu <hongjiu.lu@intel.com>
1966 * elf64-x86-64.c (elf_x86_64_finish_dynamic_sections): Add
1967 ENDBR64 to the TLSDESC PLT entry.
1969 2018-03-21 Alan Modra <amodra@gmail.com>
1971 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Trim uninteresting
1972 symbols. Use size_t counts. Delete redundant opd test.
1974 2018-03-21 Alan Modra <amodra@gmail.com>
1976 * elf32-ppc.c (ppc_elf_tls_optimize): Delete locsyms.
1978 2018-03-21 Alan Modra <amodra@gmail.com>
1980 * elf32-ppc.c (struct ppc_elf_link_hash_entry): Make tls_mask
1982 (update_local_sym_info): Likewise for local_got_tls_masks.
1983 (ppc_elf_tls_optimize): Likewise for lgot_masks.
1985 2018-03-21 Alan Modra <amodra@gmail.com>
1987 * elf64-ppc.c (ppc_size_one_stub): Fix comment typo.
1988 (ppc64_elf_layout_multitoc): Allocate relocs for tprel as we
1989 do in size_dynamic_sections.
1991 2018-03-21 Alan Modra <amodra@gmail.com>
1993 * elf64-ppc.c (ppc64_elf_relocate_section): Don't access rel[1]
1994 without first checking array bounds.
1995 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
1997 2018-03-20 H.J. Lu <hongjiu.lu@intel.com>
2000 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Set
2001 non_ir_ref_dynamic if a symbol is made dynamic by --dynamic-list.
2003 2018-03-19 Nick Clifton <nickc@redhat.com>
2005 * po/es.po: Updated Spanish translation.
2007 2018-03-15 Max Filippov <jcmvbkbc@gmail.com>
2009 * elf32-xtensa.c (xlate_map_entry): Change types of address
2010 fields from 'unsigned' to 'bfd_vma'.
2011 (xlate_offset_with_removed_text): Use struct xlate_map_entry as
2012 the key argument to bsearch. Allow offsets past the end of a
2013 section, use the last map entry for translation of such offsets.
2015 2018-03-15 Kuan-Lin Chen <kuanlinchentw@gmail.com>
2017 * elf32-nds32.c (nds32_elf_ex9_build_hash_table): Removed.
2018 Not support the target feature.
2019 (nds32_elf_ex9_itb_base): Likewise.
2020 (nds32_elf_ex9_import_table): Likewise.
2021 (nds32_elf_ex9_finish): Likewise.
2022 (nds32_elf_ex9_reloc_jmp): Likewise.
2023 (nds32_elf_get_insn_with_reg): Likewise.
2024 (nds32_get_local_syms): Likewise.
2025 (nds32_elf_ex9_replace_instruction): Likewise.
2026 (nds32_elf_ifc_calc): Likewise.
2027 (nds32_elf_ifc_finish): Likewise.
2028 (nds32_elf_ifc_replace): Likewise.
2029 (nds32_elf_ifc_reloc): Likewise.
2031 2018-03-14 Alan Modra <amodra@gmail.com>
2033 * elf64-ppc.c (sfpr_define): Adjust for stub_sec size having
2034 sfpr size added before defining alias symbols.
2035 (ppc64_elf_build_stubs): Add stub section padding before
2036 copying sfpr contents and defining save/restore alias symbols.
2038 2018-03-14 H.J. Lu <hongjiu.lu@intel.com>
2041 * elflink.c (elf_gc_mark_debug_section): Also check the local
2042 debug definition section.
2044 2018-03-13 Nick Clifton <nickc@redhat.com>
2047 * pei-x86_64.c (pex64_get_unwind_info): Change to a boolean
2048 function. Add an end address parameter. Check access of the data
2049 pointer to make sure that they do not extend beyond the end
2050 address. Return FALSE if any check fails. Add the end address
2051 pointer to the ui structure.
2052 (pex64_xdata_print_uwd_codes): Check accesses of the raw unwind
2053 codes to make sure that they do not extend beyond the end address
2054 pointer. Print an error message and return immediately if any
2057 2018-03-09 Nick Clifton <nickc@redhat.com>
2059 * elf64-s390.c (elf_s390_relocate_section): Move check for
2060 relocations against non-allocated sections to before the code that
2061 handles ifunc relocations.
2062 * elf32-s390.c (elf_s390_relocate_section): Likewise.
2063 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Treat
2064 relocs against IFUNC symbols in non-allocated sections as relocs
2065 against FUNC symbols.
2066 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
2068 2018-03-08 H.J. Lu <hongjiu.lu@intel.com>
2071 * elf32-i386.c (elf_i386_relocate_section): Treat relocation
2072 against IFUNC symbol in SHT_NOTE section without SHF_ALLOC as
2073 relocation against FUNC symbol.
2074 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
2076 2018-03-07 Renlin Li <renlin.li@arm.com>
2079 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Check absolute
2080 symbol, and don't emit relocation in specific case.
2082 2018-03-07 Alan Modra <amodra@gmail.com>
2084 * elf64-mips.c (mips_elf64_rtype_to_howto): Return NULL on error.
2085 (mips_elf64_slurp_one_reloc_table): Pass on error.
2087 2018-03-03 James Cowgill <james.cowgill@mips.com>
2088 Maciej W. Rozycki <macro@mips.com>
2091 * elfxx-mips.c (mips_elf_calculate_relocation): Only return
2092 after calling `undefined_symbol' hook if this is an error
2093 condition. Assume the value of 0 for the symbol requested
2096 2018-03-02 Jim Wilson <jimw@sifive.com>
2099 * elfnn-aarch64.c (_bfd_aarch64_resize_stubs): Add 8 bytes for branch
2100 and nop instead of 4.
2101 (elfNN_arch64_build_stubs): Add nop after branch. Increase size by
2104 2018-03-01 Jim Wilson <jimw@sifive.com>
2107 * elfnn-riscv.c (riscv_relax_delete_bytes): When adjust st_size, use
2108 else if instead of if.
2110 2018-03-01 Alan Modra <amodra@gmail.com>
2112 * elf32-ft32.c (ft32_info_to_howto_rela): Correct range test.
2114 2018-02-28 Alan Modra <amodra@gmail.com>
2117 * aoutx.h (swap_std_reloc_in): Correct r_index bound check.
2119 2018-02-28 Nick Clifton <nickc@redhat.com>
2123 * dwarf2.c (read_n_bytes): Replace size parameter with dwarf_block
2124 pointer. Drop unused abfd parameter. Check the size of the block
2125 before initialising the data field. Return the end pointer if the
2127 (read_attribute_value): Adjust invocations of read_n_bytes.
2130 * dwarf1.c (parse_die): Check the length of form blocks before
2131 advancing the data pointer.
2133 2018-02-28 Alan Modra <amodra@gmail.com>
2136 * aoutx.h (translate_symbol_table): Print an error message and set
2137 bfd_error on finding an invalid name string offset.
2139 2018-02-27 H.J. Lu <hongjiu.lu@intel.com>
2141 * config.in: Regenerated.
2142 * configure: Likewise.
2143 * configure.ac: Add --enable-separate-code.
2144 (DEFAULT_LD_Z_SEPARATE_CODE): New AC_DEFINE_UNQUOTED. Default
2145 to 1 for Linux/x86 targets,
2146 * elf64-x86-64.c (ELF_MAXPAGESIZE): Set to 0x1000 if
2147 DEFAULT_LD_Z_SEPARATE_CODE is 1.
2149 2018-02-27 Nick Clifton <nickc@redhat.com>
2151 * aout-cris.c (swap_ext_reloc_out): Standadize error/warning
2153 * elf-hppa.h (elf_hppa_info_to_howto_rel): Likewise.
2154 * elf32-i386.c (elf_i386_reloc_type_lookup): Likewise.
2155 * elf32-xtensa.c (elf_xtensa_reloc_type_lookup): Likewise.
2156 * elf64-ppc.c (ppc64_elf_reloc_type_lookup): Likewise.
2157 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
2158 * elf64-sh64.c (sh_elf64_info_to_howto): Likewise.
2159 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
2160 * elfxx-sparc.c (_bfd_sparc_elf_reloc_type_lookup): Likewise.
2161 * elfxx-tilegx.c (tilegx_reloc_type_lookup): Likewise.
2164 * elf-bfd.h (struct elf_backend_data): Change the return type of
2165 the elf_info_to_howto and elf_info_to_howto_rel function pointers
2167 * elfcode.h (elf_slurp_reloc_table_from_section): Check the return
2168 value from the info_to_howto function and fail if that function
2170 * elf32-h8300.c (elf32_h8_relocate_section): Check return value
2171 from the info_to_howto function.
2172 (elf32_h8_relax_section): Likewise.
2173 * elf32-lm32.c (lm32_elf_relocate_section): Likewise.
2174 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
2175 * elf32-score.c (s3_bfd_score_elf_relocate_section): Likewise.
2176 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
2177 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
2178 * elf64-ia64-vms.c (elf64_ia64_relocate_section): Likewise.
2179 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Likewise.
2180 * elf64-x86-64.c (elf_x86_64_tls_transition): Likewise.
2181 * elfnn-ia64.c (elfNN_ia64_relocate_section): Likewise.
2182 * elfnn-riscv.c (riscv_elf_check_relocs): Likewise.
2183 (riscv_elf_relocate_section): Likewise.
2184 * elf-hppa.h (elf_hppa_info_to_howto): Change return type to
2185 bfd_boolean. Issue an error message, set an error value and
2186 return FALSE if the reloc is not recognized.
2187 (elf_hppa_info_to_howto_rel): Likewise.
2188 * elf-m10200.c (mn10200_info_to_howto): Likewise.
2189 * elf-m10300.c (mn10300_info_to_howto): Likewise.
2190 * elf.c (_bfd_elf_no_info_to_howto): Likewise.
2191 * elf32-arc.c (arc_info_to_howto_rel): Likewise.
2192 * elf32-arm.c (elf32_arm_info_to_howto): Likewise.
2193 * elf32-avr.c (avr_info_to_howto_rela): Likewise.
2194 * elf32-bfin.c (bfin_info_to_howto): Likewise.
2195 * elf32-cr16.c (elf_cr16_info_to_howto): Likewise.
2196 * elf32-cr16c.c (elf_cr16c_info_to_howto): Likewise.
2197 * elf32-cris.c (elf_cr16c_info_to_howto_rel)
2198 (cris_info_to_howto_rela): Likewise.
2199 * elf32-crx.c (elf_crx_info_to_howto): Likewise.
2200 * elf32-d10v.c (d10v_info_to_howto_rel): Likewise.
2201 * elf32-d30v.c (d30v_info_to_howto_rel, d30v_info_to_howto_rela):
2203 * elf32-dlx.c (dlx_rtype_to_howto, elf32_dlx_info_to_howto)
2204 (elf32_dlx_info_to_howto_rel): Likewise.
2205 * elf32-epiphany.c (epiphany_info_to_howto_rela): Likewise.
2206 * elf32-fr30.c (fr30_info_to_howto_rela): Likewise.
2207 * elf32-frv.c (frv_info_to_howto_rela)
2208 (frvfdpic_info_to_howto_rel): Likewise.
2209 * elf32-ft32.c (ft32_info_to_howto_rela): Likewise.
2210 * elf32-gen.c (elf_generic_info_to_howto)
2211 (elf_generic_info_to_howto_rel): Likewise.
2212 * elf32-h8300.c (elf32_h8_info_to_howto)
2213 (elf32_h8_info_to_howto_rel): Likewise.
2214 * elf32-i370.c (i370_elf_info_to_howto): Likewise.
2215 * elf32-i386.c (elf_i386_reloc_type_lookup)
2216 (elf_i386_rtype_to_howto, elf_i386_info_to_howto_rel): Likewise.
2217 * elf32-i860.c (lookup_howto, elf32_i860_info_to_howto_rela):
2219 * elf32-i960.c (elf32_i960_info_to_howto_rel): Likewise.
2220 * elf32-ip2k.c (ip2k_info_to_howto_rela): Likewise.
2221 * elf32-iq2000.c (iq2000_info_to_howto_rela): Likewise.
2222 * elf32-lm32.c (lm32_info_to_howto_rela): Likewise.
2223 * elf32-m32c.c (m32c_info_to_howto_rela): Likewise.
2224 * elf32-m32r.c (m32r_info_to_howto_rel, m32r_info_to_howto):
2226 * elf32-m68hc11.c (m68hc11_info_to_howto_rel): Likewise.
2227 * elf32-m68hc12.c (m68hc11_info_to_howto_rel): Likewise.
2228 * elf32-m68k.c (rtype_to_howto): Likewise.
2229 * elf32-mcore.c (mcore_elf_info_to_howto): Likewise.
2230 * elf32-mep.c (mep_info_to_howto_rela): Likewise.
2231 * elf32-metag.c (metag_info_to_howto_rela): Likewise.
2232 * elf32-microblaze.c (microblaze_elf_info_to_howto): Likewise.
2233 * elf32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
2235 * elf32-moxie.c (moxie_info_to_howto_rela): Likewise.
2236 * elf32-msp430.c (msp430_info_to_howto_rela): Likewise.
2237 * elf32-mt.c (mt_info_to_howto_rela): Likewise.
2238 * elf32-nds32.c (nds32_info_to_howto_rel, nds32_info_to_howto):
2240 * elf32-nios2.c (nios2_elf32_info_to_howto): Likewise.
2241 * elf32-or1k.c (or1k_info_to_howto_rela): Likewise.
2242 * elf32-pj.c (pj_elf_info_to_howto): Likewise.
2243 * elf32-ppc.c (ppc_elf_info_to_howto): Likewise.
2244 * elf32-pru.c (pru_elf32_info_to_howto): Likewise.
2245 * elf32-rl78.c (rl78_info_to_howto_rela): Likewise.
2246 * elf32-rx.c (rx_info_to_howto_rela): Likewise.
2247 * elf32-s390.c (elf_s390_info_to_howto): Likewise.
2248 * elf32-score.c (s3_bfd_score_info_to_howto)
2249 (_bfd_score_info_to_howto): Likewise.
2250 * elf32-score7.c (s7_bfd_score_info_to_howto): Likewise.
2251 * elf32-sh.c (sh_elf_info_to_howto): Likewise.
2252 * elf32-spu.c (spu_elf_info_to_howto): Likewise.
2253 * elf32-tic6x.c (elf32_tic6x_info_to_howto)
2254 (elf32_tic6x_info_to_howto_rel): Likewise.
2255 * elf32-tilepro.c (tilepro_info_to_howto_rela): Likewise.
2256 * elf32-v850.c (v850_elf_info_to_howto_rel)
2257 (v850_elf_info_to_howto_rela, v800_elf_info_to_howto): Likewise.
2258 * elf32-vax.c (rtype_to_howto): Likewise.
2259 * elf32-visium.c (visium_info_to_howto_rela): Likewise.
2260 * elf32-wasm32.c (elf32_wasm32_rtype_to_howto)
2261 (elf32_wasm32_info_to_howto_rela): Likewise.
2262 * elf32-xc16x.c (elf32_xc16x_info_to_howto): Likewise.
2263 * elf32-xgate.c (xgate_info_to_howto_rel): Likewise.
2264 * elf32-xstormy16.c (xstormy16_info_to_howto_rela): Likewise.
2265 * elf32-xtensa.c (elf_xtensa_info_to_howto_rela): Likewise.
2266 * elf64-alpha.c (elf64_alpha_info_to_howto): Likewise.
2267 * elf64-gen.c (elf_generic_info_to_howto)
2268 (elf_generic_info_to_howto_rel): Likewise.
2269 * elf64-ia64-vms.c (elf64_ia64_info_to_howto): Likewise.
2270 * elf64-mips.c (mips_elf64_info_to_howto_rela): Likewise.
2271 * elf64-mmix.c (mmix_info_to_howto_rela): Likewise.
2272 * elf64-ppc.c (ppc64_elf_info_to_howto): Likewise.
2273 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
2274 * elf64-sh64.c (elf_s390_info_to_howto, sh_elf64_info_to_howto):
2276 * elf64-x86-64.c (elf_x86_64_info_to_howto): Likewise.
2277 * elfn32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
2279 * elfnn-aarch64.c (elfNN_aarch64_info_to_howto): Likewise.
2280 * elfnn-ia64.c (elfNN_ia64_info_to_howto): Likewise.
2281 * elfnn-riscv.c (riscv_info_to_howto_rela): Likewise.
2282 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
2283 * elfxx-sparc.c (_bfd_sparc_elf_info_to_howto): Likewise.
2284 * elfxx-tilegx.c (tilegx_info_to_howto_rela): Likewise.
2285 * elf32-score.h (s7_bfd_score_info_to_howto): Update prototype.
2286 * elfxx-sparc.h (_bfd_sparc_elf_info_to_howto): Update prototype.
2287 * elfxx-tilegx.h (tilegx_info_to_howto_rela): Update prototype.
2288 * elfxx-target.h (elf_info_to_howto, elf_info_to_howto_rel):
2291 2018-02-26 Jim Wilson <jimw@sifive.com>
2292 Stephan Schreiber <info@fs-driver.org>
2295 * elfnn-ia64.c (elfNN_ia64_relax_section): After ia64_elf_relax_brl
2296 call, set changed_contents and changed_relocs. Likewise after
2297 successful ia64_elf_relax_br call.
2299 2018-02-26 Alan Modra <amodra@gmail.com>
2301 * elf.c (assign_file_positions_except_relocs): Don't segfault
2302 when actual number of phdrs is less than allocated. Delete
2303 outdated comment. Formatting.
2305 2018-02-26 Alan Modra <amodra@gmail.com>
2307 * elf-m10300.c, * elf-s390-common.c, * elf32-arc.c, * elf32-cris.c,
2308 * elf32-dlx.c, * elf32-frv.c, * elf32-i370.c, * elf32-lm32.c,
2309 * elf32-m32r.c, * elf32-m68hc1x.c, * elf32-m68k.c,
2310 * elf32-microblaze.c, * elf32-msp430.c, * elf32-nds32.c,
2311 * elf32-nios2.c, * elf32-or1k.c, * elf32-rl78.c, * elf32-rx.c,
2312 * elf32-score.c, * elf32-score7.c, * elf32-sh-symbian.c,
2313 * elf32-sh.c, * elf32-spu.c, * elf32-v850.c, * elf32-xtensa.c,
2314 * elf64-alpha.c, * elf64-ia64-vms.c, * elf64-mmix.c,
2315 * elf64-sh64.c, * elf64-sparc.c, * elfnn-ia64.c, * elfxx-tilegx.c,
2316 * mmo.c, * osf-core.c, * srec.c, * vms-alpha.c: Standardize
2317 error/warning messages.
2319 2018-02-26 Alan Modra <amodra@gmail.com>
2321 * archive.c, * bfd.c, * linker.c, * reloc.c, * stabs.c,
2322 * syms.c: Standardize error/warning messages.
2324 2018-02-26 Alan Modra <amodra@gmail.com>
2326 * aout-adobe.c, * aout-cris.c, * i386linux.c, * m68klinux.c,
2327 * sparclinux.c, * coff-alpha.c, * coff-arm.c, * coff-mcore.c,
2328 * coffcode.h, * coffgen.c, * cofflink.c, * ecoff.c, * pe-mips.c,
2329 * peXXigen.c, * peicode.h: Standardize error/warning messages.
2331 2018-02-26 Alan Modra <amodra@gmail.com>
2333 * elf32-arm.c, * elfnn-aarch64.c: Standardize error/warning messages.
2335 2018-02-26 Alan Modra <amodra@gmail.com>
2337 * elfxx-mips.c: Standardize error/warning messages.
2339 2018-02-26 Alan Modra <amodra@gmail.com>
2341 * dwarf2.c, * elf-attrs.c, * elf-eh-frame.c, * elf.c, * elf32-gen.c,
2342 * elflink.c: Standardize error/warning messages. Replace use of
2343 linker callback einfo with _bfd_error_handler when possible.
2345 2018-02-26 Alan Modra <amodra@gmail.com>
2347 * aoutx.h, * coff-alpha.c, * coff-i860.c, * coff-m68k.c,
2348 * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c, * coff-sh.c,
2349 * coff-tic4x.c, * coff-tic54x.c, * coff-tic80.c, * coff-w65.c,
2350 * elf-bfd.h, * elf-m10300.c, * elf.c, * elf32-avr.c, * elf32-bfin.c,
2351 * elf32-cr16.c, * elf32-cr16c.c, * elf32-cris.c, * elf32-crx.c,
2352 * elf32-d10v.c, * elf32-d30v.c, * elf32-dlx.c, * elf32-epiphany.c,
2353 * elf32-fr30.c, * elf32-frv.c, * elf32-i370.c, * elf32-i386.c,
2354 * elf32-i960.c, * elf32-ip2k.c, * elf32-iq2000.c, * elf32-lm32.c,
2355 * elf32-m32c.c, * elf32-m32r.c, * elf32-m68hc11.c, * elf32-m68hc12.c,
2356 * elf32-m68k.c, * elf32-mcore.c, * elf32-mep.c, * elf32-metag.c,
2357 * elf32-microblaze.c, * elf32-mips.c, * elf32-moxie.c,
2358 * elf32-msp430.c, * elf32-mt.c, * elf32-nds32.c, * elf32-or1k.c,
2359 * elf32-pj.c, * elf32-ppc.c, * elf32-rl78.c, * elf32-rx.c,
2360 * elf32-s390.c, * elf32-sh.c, * elf32-spu.c, * elf32-tic6x.c,
2361 * elf32-v850.c, * elf32-vax.c, * elf32-visium.c, * elf32-wasm32.c,
2362 * elf32-xgate.c, * elf32-xtensa.c, * elf64-alpha.c,
2363 * elf64-ia64-vms.c, * elf64-mips.c, * elf64-mmix.c,
2364 * elf64-ppc.c, * elf64-s390.c, * elf64-sparc.c, * elf64-x86-64.c,
2365 * elfn32-mips.c, * elfnn-aarch64.c, * elfnn-ia64.c,
2366 * elfnn-riscv.c, * elfxx-mips.c, * elfxx-riscv.c, * elfxx-riscv.h,
2367 * elfxx-sparc.c, * elfxx-sparc.h, * reloc.c: Standardize
2368 unrecognized/unsupported reloc message.
2370 2018-02-26 Alan Modra <amodra@gmail.com>
2372 * elf32-ppc.c: Standardize error/warning messages. Use
2373 _bfd_error_handler rather than einfo when einfo features not used.
2374 * elf64-ppc.c: Likewise.
2376 2018-02-23 Alan Modra <amodra@gmail.com>
2379 * elf.c (assign_file_positions_for_non_load_sections): Remove RELRO
2380 segment if no matching LOAD segment.
2382 2018-02-23 Kuan-Lin Chen <kuanlinchentw@gmail.com>
2384 * elf32-nds32.h: Define mask for ict_model.
2386 2018-02-20 Jason Duerstock <jason.duerstock@gmail.com>
2388 * elfnn-ia64.c (elf_backend_can_gc_sections): Enable.
2390 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2393 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
2395 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
2396 .reginfo section has wrong size.
2398 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2400 * elfxx-mips.c (_bfd_mips_elf_always_size_sections): Set
2401 SEC_FIXED_SIZE and SEC_HAS_CONTENTS flags for `.reginfo' and
2402 `.MIPS.abiflags' sections.
2403 (_bfd_mips_elf_final_link): Avoid reading beyond `.reginfo'
2406 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2408 * section.c (SEC_FIXED_SIZE): New macro.
2409 * bfd-in2.h: Regenerate.
2411 2018-02-19 Maciej W. Rozycki <macro@mips.com>
2413 * section.c (SEC_HAS_GOT_REF): Remove macro.
2414 * bfd-in2.h: Regenerate.
2416 2018-02-19 Alan Modra <amodra@gmail.com>
2418 * elf-attrs.c (_bfd_elf_parse_attributes): Correct _bfd_error_handler
2420 * elfxx-mips.c (_bfd_mips_elf_final_link): Likewise.
2421 * elfnn-riscv.c (_bfd_riscv_relax_align): Likewise.
2422 (_bfd_riscv_relax_pc): Likewise and fix typos.
2423 * libbfd-in.h (_bfd_error_handler): Add attribute printf.
2424 * libbfd.h: Regenerate.
2426 2018-02-19 Alan Modra <amodra@gmail.com>
2428 * dwarf2.c (read_section): Don't use 'll' format modifier.
2429 (find_abstract_instance): Likewise.
2430 * elfcore.h (elf_core_file_p): Likewise.
2432 2018-02-19 Alan Modra <amodra@gmail.com>
2434 * bfd-in.h: Include inttypes.h or if not available define
2435 PRId64, PRIu64 and PRIx64.
2436 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Remove support for L
2437 modifier to print bfd_vma.
2438 * coff-arm.c, * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c,
2439 * coff-sh.c, * coff-tic80.c, * coffcode.h, * coffgen.c, * cofflink.c,
2440 * compress.c, * dwarf2.c, * elf-m10300.c, * elf.c, * elf32-arc.c,
2441 * elf32-arm.c, * elf32-bfin.c, * elf32-cris.c, * elf32-hppa.c,
2442 * elf32-i386.c, * elf32-ip2k.c, * elf32-lm32.c, * elf32-m32r.c,
2443 * elf32-m68k.c, * elf32-metag.c, * elf32-nds32.c, * elf32-nios2.c,
2444 * elf32-ppc.c, * elf32-rx.c, * elf32-s390.c, * elf32-score.c,
2445 * elf32-score7.c, * elf32-sh.c, * elf32-sh64.c, * elf32-spu.c,
2446 * elf32-tic6x.c, * elf32-tilepro.c, * elf32-v850.c, * elf32-vax.c,
2447 * elf32-xtensa.c, * elf64-alpha.c, * elf64-hppa.c, * elf64-ia64-vms.c,
2448 * elf64-mmix.c, * elf64-s390.c, * elf64-sh64.c, * elf64-x86-64.c,
2449 * elfcode.h, * elfcore.h, * elflink.c, * elfnn-aarch64.c,
2450 * elfnn-ia64.c, * elfnn-riscv.c, * elfxx-mips.c, * elfxx-sparc.c,
2451 * elfxx-tilegx.c, * ieee.c, * ihex.c, * mach-o.c, * merge.c, * mmo.c,
2452 * peXXigen.c, * xcofflink.c: Replace use of Lx modifier with PRIx64,
2453 and cast input to uint64_t, and similarly for Ld and Lu.
2454 * bfd-in2.h: Regenerate.
2456 2018-02-19 Alan Modra <amodra@gmail.com>
2458 * elf32-arm.c, * elf32-hppa.c, * elf32-lm32.c, * elf32-m32r.c,
2459 * elf32-metag.c, * elf32-nds32.c, * elf32-or1k.c, * elf32-ppc.c,
2460 * elf32-s390.c, * elf32-sh.c, * elf32-tic6x.c, * elf32-tilepro.c,
2461 * elf64-ppc.c, * elf64-s390.c, * elflink.c, * elfnn-aarch64.c,
2462 * elfnn-riscv.c, * elfxx-sparc.c, * elfxx-tilegx.c, * elfxx-x86.c,
2463 * reloc.c: Replace use of %R and %T in format strings passed to
2464 einfo and friends by %pR and %pT.
2466 2018-02-19 Alan Modra <amodra@gmail.com>
2468 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Handle %pA and %pB in place
2470 * aout-adobe.c: Update all messages using %A and %B.
2471 * aout-cris.c: Likewise.
2472 * aoutx.h: Likewise.
2473 * archive.c: Likewise.
2474 * binary.c: Likewise.
2475 * cache.c: Likewise.
2476 * coff-alpha.c: Likewise.
2477 * coff-arm.c: Likewise.
2478 * coff-i860.c: Likewise.
2479 * coff-mcore.c: Likewise.
2480 * coff-ppc.c: Likewise.
2481 * coff-rs6000.c: Likewise.
2482 * coff-sh.c: Likewise.
2483 * coff-tic4x.c: Likewise.
2484 * coff-tic54x.c: Likewise.
2485 * coff-tic80.c: Likewise.
2486 * coff64-rs6000.c: Likewise.
2487 * coffcode.h: Likewise.
2488 * coffgen.c: Likewise.
2489 * cofflink.c: Likewise.
2490 * coffswap.h: Likewise.
2491 * compress.c: Likewise.
2492 * cpu-arm.c: Likewise.
2493 * ecoff.c: Likewise.
2494 * elf-attrs.c: Likewise.
2495 * elf-eh-frame.c: Likewise.
2496 * elf-ifunc.c: Likewise.
2497 * elf-m10300.c: Likewise.
2498 * elf-properties.c: Likewise.
2499 * elf-s390-common.c: Likewise.
2501 * elf32-arc.c: Likewise.
2502 * elf32-arm.c: Likewise.
2503 * elf32-avr.c: Likewise.
2504 * elf32-bfin.c: Likewise.
2505 * elf32-cr16.c: Likewise.
2506 * elf32-cr16c.c: Likewise.
2507 * elf32-cris.c: Likewise.
2508 * elf32-crx.c: Likewise.
2509 * elf32-d10v.c: Likewise.
2510 * elf32-d30v.c: Likewise.
2511 * elf32-epiphany.c: Likewise.
2512 * elf32-fr30.c: Likewise.
2513 * elf32-frv.c: Likewise.
2514 * elf32-gen.c: Likewise.
2515 * elf32-hppa.c: Likewise.
2516 * elf32-i370.c: Likewise.
2517 * elf32-i386.c: Likewise.
2518 * elf32-i960.c: Likewise.
2519 * elf32-ip2k.c: Likewise.
2520 * elf32-iq2000.c: Likewise.
2521 * elf32-lm32.c: Likewise.
2522 * elf32-m32c.c: Likewise.
2523 * elf32-m32r.c: Likewise.
2524 * elf32-m68hc11.c: Likewise.
2525 * elf32-m68hc12.c: Likewise.
2526 * elf32-m68hc1x.c: Likewise.
2527 * elf32-m68k.c: Likewise.
2528 * elf32-mcore.c: Likewise.
2529 * elf32-mep.c: Likewise.
2530 * elf32-metag.c: Likewise.
2531 * elf32-microblaze.c: Likewise.
2532 * elf32-moxie.c: Likewise.
2533 * elf32-msp430.c: Likewise.
2534 * elf32-mt.c: Likewise.
2535 * elf32-nds32.c: Likewise.
2536 * elf32-nios2.c: Likewise.
2537 * elf32-or1k.c: Likewise.
2538 * elf32-pj.c: Likewise.
2539 * elf32-ppc.c: Likewise.
2540 * elf32-rl78.c: Likewise.
2541 * elf32-rx.c: Likewise.
2542 * elf32-s390.c: Likewise.
2543 * elf32-score.c: Likewise.
2544 * elf32-score7.c: Likewise.
2545 * elf32-sh-symbian.c: Likewise.
2546 * elf32-sh.c: Likewise.
2547 * elf32-sh64.c: Likewise.
2548 * elf32-sparc.c: Likewise.
2549 * elf32-spu.c: Likewise.
2550 * elf32-tic6x.c: Likewise.
2551 * elf32-tilepro.c: Likewise.
2552 * elf32-v850.c: Likewise.
2553 * elf32-vax.c: Likewise.
2554 * elf32-visium.c: Likewise.
2555 * elf32-wasm32.c: Likewise.
2556 * elf32-xgate.c: Likewise.
2557 * elf32-xtensa.c: Likewise.
2558 * elf64-alpha.c: Likewise.
2559 * elf64-gen.c: Likewise.
2560 * elf64-hppa.c: Likewise.
2561 * elf64-ia64-vms.c: Likewise.
2562 * elf64-mmix.c: Likewise.
2563 * elf64-ppc.c: Likewise.
2564 * elf64-s390.c: Likewise.
2565 * elf64-sh64.c: Likewise.
2566 * elf64-sparc.c: Likewise.
2567 * elf64-x86-64.c: Likewise.
2568 * elfcode.h: Likewise.
2569 * elfcore.h: Likewise.
2570 * elflink.c: Likewise.
2571 * elfnn-aarch64.c: Likewise.
2572 * elfnn-ia64.c: Likewise.
2573 * elfnn-riscv.c: Likewise.
2574 * elfxx-mips.c: Likewise.
2575 * elfxx-sparc.c: Likewise.
2576 * elfxx-tilegx.c: Likewise.
2577 * elfxx-x86.c: Likewise.
2578 * hpux-core.c: Likewise.
2581 * libbfd.c: Likewise.
2582 * linker.c: Likewise.
2583 * mach-o.c: Likewise.
2584 * merge.c: Likewise.
2586 * oasys.c: Likewise.
2587 * pdp11.c: Likewise.
2588 * pe-mips.c: Likewise.
2589 * peXXigen.c: Likewise.
2590 * peicode.h: Likewise.
2591 * reloc.c: Likewise.
2592 * rs6000-core.c: Likewise.
2594 * stabs.c: Likewise.
2595 * vms-alpha.c: Likewise.
2596 * xcofflink.c: Likewise.
2598 2018-02-19 Alan Modra <amodra@gmail.com>
2601 * elf.c (IS_TBSS): Define.
2602 (_bfd_elf_map_sections_to_segments): Use IS_TBSS.
2603 (assign_file_positions_for_non_load_sections): Revert last change.
2604 Properly calculate load segment limits to compare against relro limits.
2606 2018-02-17 Alan Modra <amodra@gmail.com>
2609 * elf.c (assign_file_positions_for_non_load_sections): Ignore
2610 degenerate zero size PT_LOAD segments when finding one overlapping
2611 the PT_GNU_RELRO segment.
2613 2018-02-16 Alan Modra <amodra@gmail.com>
2615 * libbfd.c (_bfd_bool_bfd_false_error): Rename from bfd_false.
2616 (_bfd_bool_bfd_true): Rename from bfd_true.
2617 (_bfd_ptr_bfd_null_error): Rename from bfd_nullvoidptr.
2618 (_bfd_int_bfd_0): Rename from bfd_0.
2619 (_bfd_uint_bfd_0): Rename from bfd_0u.
2620 (_bfd_long_bfd_0): Rename from bfd_0l.
2621 (_bfd_long_bfd_n1_error): Rename from _bfd_n1.
2622 (_bfd_void_bfd): Rename from bfd_void.
2623 (_bfd_bool_bfd_false, _bfd_bool_bfd_asymbol_false),
2624 (_bfd_bool_bfd_link_false_error),
2625 (_bfd_bool_bfd_link_true, _bfd_bool_bfd_bfd_true),
2626 (_bfd_bool_bfd_uint_true, _bfd_bool_bfd_ptr_true),
2627 (_bfd_bool_bfd_asection_bfd_asection_true),
2628 (_bfd_bool_bfd_asymbol_bfd_asymbol_true),
2629 (_bfd_void_bfd_link, _bfd_void_bfd_asection): New functions.
2630 * archive.c (_bfd_noarchive_get_elt_at_index),
2631 (_bfd_noarchive_openr_next_archived_file),
2632 (_bfd_noarchive_construct_extended_name_table),
2633 (_bfd_noarchive_write_ar_hdr, _bfd_noarchive_truncate_arname),
2634 (_bfd_noarchive_write_armap): New functions.
2635 * archures.c (_bfd_nowrite_set_arch_mach): New function.
2636 * coff-alpha.c (alpha_ecoff_swap_coff_aux_in),
2637 (alpha_ecoff_swap_coff_sym_in, alpha_ecoff_swap_coff_lineno_in),
2638 (alpha_ecoff_swap_coff_aux_out, alpha_ecoff_swap_coff_sym_out),
2639 (alpha_ecoff_swap_coff_lineno_out),
2640 (alpha_ecoff_swap_coff_reloc_out): New functions.
2641 * coff-mips.c (mips_ecoff_swap_coff_aux_in),
2642 (mips_ecoff_swap_coff_sym_in, mips_ecoff_swap_coff_lineno_in),
2643 (mips_ecoff_swap_coff_aux_out, mips_ecoff_swap_coff_sym_out),
2644 (mips_ecoff_swap_coff_lineno_out),
2645 (mips_ecoff_swap_coff_reloc_out): New functions.
2646 * coffcode.h (coff_set_alignment_hook): Replace define with
2648 (symname_in_debug_hook): Likewise.
2649 * ecoff.c (_bfd_ecoff_set_alignment_hook): New function.
2650 * elfxx-target.h (elf_backend_allow_non_load_phdr): Default to 0.
2651 * elf.c (assign_file_positions_except_relocs): Test
2652 elf_backend_allow_non_load_phdr for NULL.
2653 * elflink.c (_bfd_elf_omit_section_dynsym_default): Rename from
2654 _bfd_elf_link_omit_section_dynsym. Update uses.
2655 (_bfd_elf_omit_section_dynsym_all): New function.
2656 * elf-bfd.h (_bfd_elf_link_omit_section_dynsym): Delete.
2657 (_bfd_elf_omit_section_dynsym_default): Declare.
2658 (_bfd_elf_omit_section_dynsym_all): Declare.
2659 * linker.c (_bfd_nolink_sizeof_headers, _bfd_nolink_bfd_relax_section),
2660 (_bfd_nolink_bfd_get_relocated_section_contents),
2661 (_bfd_nolink_bfd_lookup_section_flags),
2662 (_bfd_nolink_bfd_is_group_section, _bfd_nolink_bfd_discard_group),
2663 (_bfd_nolink_bfd_link_hash_table_create),
2664 (_bfd_nolink_bfd_link_just_syms),
2665 (_bfd_nolink_bfd_copy_link_hash_symbol_type),
2666 (_bfd_nolink_bfd_link_split_section),
2667 (_bfd_nolink_section_already_linked),
2668 (_bfd_nolink_bfd_define_common_symbol),
2669 (_bfd_nolink_bfd_define_start_stop): New functions.
2670 * reloc.c (_bfd_norelocs_bfd_reloc_type_lookup),
2671 (_bfd_norelocs_bfd_reloc_name_lookup),
2672 (_bfd_nodynamic_canonicalize_dynamic_reloc): New functions.
2673 * section.c (_bfd_nowrite_set_section_contents): New function.
2674 * syms.c (_bfd_nosymbols_canonicalize_symtab),
2675 (_bfd_nosymbols_print_symbol, _bfd_nosymbols_get_symbol_info),
2676 (_bfd_nosymbols_get_symbol_version_string),
2677 (_bfd_nosymbols_bfd_is_local_label_name),
2678 (_bfd_nosymbols_get_lineno, _bfd_nosymbols_find_nearest_line),
2679 (_bfd_nosymbols_find_line, _bfd_nosymbols_find_inliner_info),
2680 (_bfd_nosymbols_bfd_make_debug_symbol),
2681 ( _bfd_nosymbols_read_minisymbols),
2682 ( _bfd_nosymbols_minisymbol_to_symbol),
2683 (_bfd_nodynamic_get_synthetic_symtab): New functions.
2684 * libbfd-in.h: Declare new functions. Update existing defines,
2686 * aix386-core.c: Update to use new hooks. Formatting.
2687 * aout-adobe.c: Likewise.
2688 * aout-arm.c: Likewise.
2689 * aout-target.h: Likewise.
2690 * aout-tic30.c: Likewise.
2691 * aoutf1.h: Likewise.
2692 * binary.c: Likewise.
2694 * cisco-core.c: Likewise.
2695 * coff-alpha.c: Likewise.
2696 * coff-i386.c: Likewise.
2697 * coff-i860.c: Likewise.
2698 * coff-i960.c: Likewise.
2699 * coff-ia64.c: Likewise.
2700 * coff-mips.c: Likewise.
2701 * coff-ppc.c: Likewise.
2702 * coff-rs6000.c: Likewise.
2703 * coff-sh.c: Likewise.
2704 * coff-tic30.c: Likewise.
2705 * coff-tic54x.c: Likewise.
2706 * coff-x86_64.c: Likewise.
2707 * coff64-rs6000.c: Likewise.
2708 * coffcode.h: Likewise.
2709 * elf-m10300.c: Likewise.
2710 * elf32-cr16.c: Likewise.
2711 * elf32-lm32.c: Likewise.
2712 * elf32-m32r.c: Likewise.
2713 * elf32-metag.c: Likewise.
2714 * elf32-score.c: Likewise.
2715 * elf32-score7.c: Likewise.
2716 * elf32-tilepro.c: Likewise.
2717 * elf32-xstormy16.c: Likewise.
2718 * elf32-xtensa.c: Likewise.
2719 * elf64-alpha.c: Likewise.
2720 * elf64-hppa.c: Likewise.
2721 * elf64-ia64-vms.c: Likewise.
2722 * elf64-mmix.c: Likewise.
2723 * elf64-sh64.c: Likewise.
2724 * elfnn-ia64.c: Likewise.
2725 * elfxx-sparc.c: Likewise.
2726 * elfxx-target.h: Likewise.
2727 * elfxx-tilegx.c: Likewise.
2728 * elfxx-x86.h: Likewise.
2729 * hp300hpux.c: Likewise.
2730 * hppabsd-core.c: Likewise.
2731 * hpux-core.c: Likewise.
2732 * i386msdos.c: Likewise.
2733 * i386os9k.c: Likewise.
2736 * irix-core.c: Likewise.
2737 * libaout.h: Likewise.
2738 * libecoff.h: Likewise.
2739 * mach-o-target.c: Likewise.
2740 * mach-o.c: Likewise.
2741 * mipsbsd.c: Likewise.
2743 * netbsd-core.c: Likewise.
2744 * nlm-target.h: Likewise.
2745 * oasys.c: Likewise.
2746 * osf-core.c: Likewise.
2747 * pdp11.c: Likewise.
2748 * pe-mips.c: Likewise.
2749 * pe-x86_64.c: Likewise.
2751 * plugin.c: Likewise.
2752 * ppcboot.c: Likewise.
2753 * ptrace-core.c: Likewise.
2754 * sco5-core.c: Likewise.
2756 * sparclynx.c: Likewise.
2758 * tekhex.c: Likewise.
2759 * trad-core.c: Likewise.
2760 * verilog.c: Likewise.
2761 * versados.c: Likewise.
2762 * vms-alpha.c: Likewise.
2763 * vms-lib.c: Likewise.
2764 * wasm-module.c: Likewise.
2766 * libbfd.h: Regenerate.
2768 2018-02-15 Jim Wilson <jimw@sifive.com>
2770 * elfnn-riscv.c (_bfd_riscv_relax_section): Ifdef out check to ignore
2771 symbols whose section address is zero.
2773 * elfnn-riscv.c (riscv_elf_relocate_section): Use bfd_reloc_dangerous
2774 when pcrel_lo reloc has an addend. Use reloc_dangerous callback for
2775 bfd_reloc_dangerous. Use einfo instead of warning callback for errors.
2776 Add %X%P to error messages.
2778 2018-02-15 Eric Botcazou <ebotcazou@adacore.com>
2781 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
2782 Pass FALSE instead of TRUE as 'create' argument to bfd_link_hash_lookup
2783 and assert that the result of the call is not NULL.
2785 2018-02-14 Nick Clifton <nickc@redhat.com>
2788 Revert previous delta. Add extra casts to avoid compile time
2790 * libbfd-in.h (_bfd_generic_bfd_copy_private_bfd_data): Add extra
2791 cast to avoid warning from gcc v8 compiler.
2792 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
2793 (_bfd_generic_bfd_set_private_flags): Likewise.
2794 (_bfd_generic_bfd_copy_private_section_data): Likewise.
2795 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
2796 (_bfd_generic_bfd_copy_private_header_data): Likewise.
2797 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
2798 (_bfd_noarchive_construct_extended_name_table): Likewise.
2799 (_bfd_noarchive_truncate_arname): Likewise.
2800 (_bfd_noarchive_write_ar_hdr): Likewise.
2801 (_bfd_noarchive_get_elt_at_index): Likewise.
2802 (_bfd_nosymbols_canonicalize_symtab): Likewise.
2803 (_bfd_nosymbols_print_symbol): Likewise.
2804 (_bfd_nosymbols_get_symbol_info): Likewise.
2805 (_bfd_nosymbols_get_symbol_version_string): Likewise.
2806 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
2807 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
2808 (_bfd_nosymbols_get_lineno): Likewise.
2809 (_bfd_nosymbols_find_nearest_line): Likewise.
2810 (_bfd_nosymbols_find_line): Likewise.
2811 (_bfd_nosymbols_find_inliner_info): Likewise.
2812 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
2813 (_bfd_nosymbols_read_minisymbols): Likewise.
2814 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
2815 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
2816 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
2817 (_bfd_nowrite_set_arch_mach): Likewise.
2818 (_bfd_nowrite_set_section_contents): Likewise.
2819 (_bfd_nolink_sizeof_headers): Likewise.
2820 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
2821 (_bfd_nolink_bfd_relax_section): Likewise.
2822 (_bfd_nolink_bfd_gc_sections): Likewise.
2823 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
2824 (_bfd_nolink_bfd_merge_sections): Likewise.
2825 (_bfd_nolink_bfd_is_group_section): Likewise.
2826 (_bfd_nolink_bfd_discard_group): Likewise.
2827 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
2828 (_bfd_nolink_bfd_link_add_symbols): Likewise.
2829 (_bfd_nolink_bfd_link_just_syms): Likewise.
2830 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
2831 (_bfd_nolink_bfd_final_link): Likewise.
2832 (_bfd_nolink_bfd_link_split_section): Likewise.
2833 (_bfd_nolink_section_already_linked): Likewise.
2834 (_bfd_nolink_bfd_define_common_symbol): Likewise.
2835 (_bfd_nolink_bfd_define_start_stop): Likewise.
2836 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
2837 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
2838 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
2839 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
2840 * libbfd.c (bfd_false_any): Delete.
2841 (bfd_true_any, bfd_nullvoidptr_any, bfd_0_any): Delete.
2842 (bfd_0u_any, bfd_0l_any, _bfd_n1_any, bfd_void_any): Delete.
2843 * libbfd.h (extern): Regenerate
2844 * aout-target.h (MY_bfd_is_target_special_symbol): Add extra
2845 cast to avoid warning from gcc v8 compiler.
2846 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
2847 * binary.c (binary_get_symbol_info): Likewise.
2848 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
2849 * coff-mips.c (mips_ecoff_backend_data): Likewise.
2850 * coffcode.h (coff_set_alignment_hook): Likewise.
2851 (symname_in_debug_hook): Likewise.
2852 (bfd_coff_backend_data bigobj_swap_table): Likewise.
2853 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
2854 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
2855 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
2856 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
2857 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
2858 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
2859 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
2860 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
2861 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
2862 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
2863 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
2864 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
2865 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
2866 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
2867 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
2868 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
2869 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
2870 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
2871 (bfd_elfNN_bfd_set_private_flags): Likewise.
2872 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
2873 (elf_backend_init_index_section): Likewise.
2874 (elf_backend_allow_non_load_phdr): Likewise.
2875 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
2876 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
2877 * ieee.c (ieee_construct_extended_name_table): Likewise.
2878 (ieee_write_armap): Likewise.
2879 (ieee_write_ar_hdr): Likewise.
2880 (ieee_bfd_is_target_special_symbol): Likewise.
2881 * ihex.c (ihex_canonicalize_symtab): Likewise.
2882 (ihex_bfd_is_target_special_symbol): Likewise.
2883 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
2884 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
2885 (_bfd_ecoff_set_alignment_hook): Likewise.
2886 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
2887 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
2888 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
2889 * oasys.c (oasys_construct_extended_name_table): Likewise.
2890 (oasys_write_armap): Likewise.
2891 (oasys_write_ar_hdr): Likewise.
2892 (oasys_bfd_is_target_special_symbol): Likewise.
2893 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
2894 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
2895 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
2896 * som.c (som_bfd_is_target_special_symbol): Likewise.
2897 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
2898 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
2899 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
2900 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
2901 (versados_bfd_reloc_name_lookup): Likewise.
2902 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
2903 (vms_bfd_define_start_stop): Likewise.
2904 (alpha_vms_bfd_is_target_special_symbol): Likewise.
2905 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
2906 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
2908 2018-02-14 H.J. Lu <hongjiu.lu@intel.com>
2911 * elf32-i386.c (elf_i386_check_relocs): Pass FALSE for non
2912 PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
2913 * elf64-x86-64.c (elf_x86_64_check_relocs): Create PLT for
2914 R_X86_64_PC32 reloc against dynamic function in data section.
2915 Pass TRUE for PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
2916 (elf_x86_64_relocate_section): Use PLT for R_X86_64_PC32 reloc
2917 against dynamic function in data section.
2918 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Use PLT in PIE as
2919 function address only if pcrel_plt is true.
2920 (_bfd_x86_elf_link_hash_table_create): Set pcrel_plt.
2921 * elfxx-x86.h (NEED_DYNAMIC_RELOCATION_P): Add PCREL_PLT for
2922 PC-relative PLT. If PLT is PC-relative, don't generate dynamic
2923 PC-relative relocation against a function definition in data
2924 secton in PIE. Remove the obsolete comments.
2925 (elf_x86_link_hash_table): Add pcrel_plt.
2927 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
2929 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Check bfd_link_dll,
2930 instead of bfd_link_pic, for building shared library.
2932 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
2935 * elf64-x86-64.c (is_32bit_relative_branch): Removed.
2936 (elf_x86_64_relocate_section): Check PIC relocations in PIE.
2937 Remove is_32bit_relative_branch usage. Disallow PC32 reloc
2938 against protected function in shared object.
2940 2018-02-13 Sergei Trofimovich <slyfox@inbox.ru>
2943 * po/ru.po: Fix typo in Russian translation.
2945 2018-02-13 Maciej W. Rozycki <macro@mips.com>
2947 * wasm-module.c (wasm_scan_name_function_section): Rename
2948 `index' local variable to `idx'.
2950 2018-02-13 Nick Clifton <nickc@redhat.com>
2953 Fix compile time warnings generated by gcc version 8.
2954 * libbfd-in.h: Remove extraneous text from prototypes.
2955 Add prototypes for bfd_false_any, bfd_true_any,
2956 bfd_nullvoidptr_any, bfd_0_any, bfd_0u_any, bfd_0l_any,
2957 bfd_n1_any, bfd_void_any.
2958 (_bfd_generic_bfd_copy_private_bfd_data): Use vararg based dummy
2960 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
2961 (_bfd_generic_bfd_set_private_flags): Likewise.
2962 (_bfd_generic_bfd_copy_private_section_data): Likewise.
2963 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
2964 (_bfd_generic_bfd_copy_private_header_data): Likewise.
2965 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
2966 (_bfd_noarchive_construct_extended_name_table): Likewise.
2967 (_bfd_noarchive_truncate_arname): Likewise.
2968 (_bfd_noarchive_write_ar_hdr): Likewise.
2969 (_bfd_noarchive_get_elt_at_index): Likewise.
2970 (_bfd_nosymbols_canonicalize_symtab): Likewise.
2971 (_bfd_nosymbols_print_symbol): Likewise.
2972 (_bfd_nosymbols_get_symbol_info): Likewise.
2973 (_bfd_nosymbols_get_symbol_version_string): Likewise.
2974 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
2975 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
2976 (_bfd_nosymbols_get_lineno): Likewise.
2977 (_bfd_nosymbols_find_nearest_line): Likewise.
2978 (_bfd_nosymbols_find_line): Likewise.
2979 (_bfd_nosymbols_find_inliner_info): Likewise.
2980 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
2981 (_bfd_nosymbols_read_minisymbols): Likewise.
2982 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
2983 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
2984 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
2985 (_bfd_nowrite_set_arch_mach): Likewise.
2986 (_bfd_nowrite_set_section_contents): Likewise.
2987 (_bfd_nolink_sizeof_headers): Likewise.
2988 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
2989 (_bfd_nolink_bfd_relax_section): Likewise.
2990 (_bfd_nolink_bfd_gc_sections): Likewise.
2991 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
2992 (_bfd_nolink_bfd_merge_sections): Likewise.
2993 (_bfd_nolink_bfd_is_group_section): Likewise.
2994 (_bfd_nolink_bfd_discard_group): Likewise.
2995 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
2996 (_bfd_nolink_bfd_link_add_symbols): Likewise.
2997 (_bfd_nolink_bfd_link_just_syms): Likewise.
2998 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
2999 (_bfd_nolink_bfd_final_link): Likewise.
3000 (_bfd_nolink_bfd_link_split_section): Likewise.
3001 (_bfd_nolink_section_already_linked): Likewise.
3002 (_bfd_nolink_bfd_define_common_symbol): Likewise.
3003 (_bfd_nolink_bfd_define_start_stop): Likewise.
3004 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
3005 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
3006 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
3007 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
3008 * libbfd.c (bfd_false_any): New function. Like bfd_false but
3009 accepts one or more arguments.
3010 (bfd_true_any): Likewise.
3011 (bfd_nullvoidptr_any): Likewise.
3012 (bfd_0_any): Likewise.
3013 (bfd_0u_any): Likewise.
3014 (bfd_0l_any): Likewise.
3015 (_bfd_n1_any): Likewise.
3016 (bfd_void_any): Likewise.
3017 * libbfd.h (extern): Regenerate
3018 * aout-target.h (MY_bfd_is_target_special_symbol): Use vararg
3019 based dummy function.
3020 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
3021 * binary.c (binary_get_symbol_info): Likewise.
3022 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
3023 * coff-mips.c (mips_ecoff_backend_data): Likewise.
3024 * coffcode.h (coff_set_alignment_hook): Likewise.
3025 (symname_in_debug_hook): Likewise.
3026 (bfd_coff_backend_data bigobj_swap_table): Likewise.
3027 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
3028 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
3029 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
3030 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
3031 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
3032 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
3033 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
3034 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
3035 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
3036 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
3037 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
3038 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
3039 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
3040 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
3041 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
3042 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
3043 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
3044 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
3045 (bfd_elfNN_bfd_set_private_flags): Likewise.
3046 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
3047 (elf_backend_init_index_section): Likewise.
3048 (elf_backend_allow_non_load_phdr): Likewise.
3049 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
3050 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
3051 * ieee.c (ieee_construct_extended_name_table): Likewise.
3052 (ieee_write_armap): Likewise.
3053 (ieee_write_ar_hdr): Likewise.
3054 (ieee_bfd_is_target_special_symbol): Likewise.
3055 * ihex.c (ihex_canonicalize_symtab): Likewise.
3056 (ihex_bfd_is_target_special_symbol): Likewise.
3057 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
3058 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
3059 (_bfd_ecoff_set_alignment_hook): Likewise.
3060 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
3061 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
3062 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
3063 * oasys.c (oasys_construct_extended_name_table): Likewise.
3064 (oasys_write_armap): Likewise.
3065 (oasys_write_ar_hdr): Likewise.
3066 (oasys_bfd_is_target_special_symbol): Likewise.
3067 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
3068 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
3069 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
3070 * som.c (som_bfd_is_target_special_symbol): Likewise.
3071 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
3072 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
3073 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
3074 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
3075 (versados_bfd_reloc_name_lookup): Likewise.
3076 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
3077 (vms_bfd_define_start_stop): Likewise.
3078 (alpha_vms_bfd_is_target_special_symbol): Likewise.
3079 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
3080 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
3081 * elf32-arc.c (get_replace_function): Assign replacement function
3083 * elf32-i370.c (i370_noop): Update prototype.
3085 2018-02-13 Alan Modra <amodra@gmail.com>
3088 * elf.c (_bfd_elf_fixup_group_sections): Account for removed
3089 relocation sections. If size reduces to just the flag word,
3090 remove that too and mark with SEC_EXCLUDE.
3091 * elflink.c (bfd_elf_final_link): Strip empty group sections.
3093 2018-02-13 Alan Modra <amodra@gmail.com>
3096 * elf.c (assign_file_positions_for_non_load_sections): Rewrite
3099 2018-02-12 Zebediah Figura <z.figura12@gmail.com>
3101 * i386msdos.c (msdos_mkobject); New function.
3102 (msdos_object_p): New function.
3103 (i386_msdos_vec): Use msdos_object_p as the check_format
3105 * peicode.h: Rename external_PEI_DOS_hdr, DOSMAGIC, and
3106 NT_SIGNATURE to external_DOS_hdr, IMAGE_DOS_SIGNATURE, and
3108 * peXXigen.c: Likewise.
3109 * coff-ia64.c: Likewise.
3111 2018-02-12 Nick Clifton <nickc@redhat.com>
3113 * elf32-nds32.c (nds32_elf_relax_longjump3): Remove redundant
3115 * elf32-arc.c (elf_arc_relocate_section): Likewise.
3117 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
3119 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Reorder conditions.
3120 (sparc_elf_append_rela): Assert that there is enough room in section.
3121 (_bfd_sparc_elf_copy_indirect_symbol): Fix formatting.
3122 (_bfd_sparc_elf_adjust_dynamic_symbol): Minor tweak.
3123 (allocate_dynrelocs): Remove outdated comments and reorder conditions.
3124 For a symbol subject to a GOT relocation, reserve a slot in the
3125 relocation section if the symbol isn't dynamic and we are in PIC mode.
3126 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: If relocation
3127 is relaxed and a slot was reserved, generate a R_SPARC_NONE relocation.
3128 <R_SPARC_GOTDATA_OP_HIX22>: Adjust comments.
3129 <R_SPARC_PC10>: Reorder conditions. Remove always-false assertion.
3130 (_bfd_sparc_elf_finish_dynamic_symbol): Rename local_undefweak into
3131 resolved_to_zero. Do not generate a dynamic GOT relocation for an
3132 undefined weak symbol with non-default visibility. Remove superfluous
3133 'else' and fix formatting.
3135 2018-02-09 H.J. Lu <hongjiu.lu@intel.com>
3137 * elf32-i386.c (elf_i386_get_synthetic_symtab): Also handle
3139 (i386_elf32_sol2_vec): Don't declare.
3140 (elf_i386_link_setup_gnu_properties): Also handle is_solaris.
3141 Don't set need_global_offset_table.
3142 (elf_i386_solaris_arch_bed): New.
3143 (elf_backend_arch_data): Set to elf_i386_solaris_arch_bed for
3145 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Check
3146 target_os != is_nacl instead of target_os == is_normal.
3147 (x86_64_elf64_sol2_vec): Don't declare.
3148 (elf_x86_64_link_setup_gnu_properties): Check target_os !=
3149 is_nacl instead of target_os == is_normal. Don't set
3150 need_global_offset_table.
3151 (elf_x86_64_solaris_arch_bed): New.
3152 (elf_backend_arch_data): Set to elf_x86_64_solaris_arch_bed for
3154 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep
3155 _GLOBAL_OFFSET_TABLE_ for Solaris.
3156 (_bfd_x86_elf_link_setup_gnu_properties): Don't copy
3157 need_global_offset_table.
3158 * elfxx-x86.h (elf_x86_target_os): Add is_solaris.
3159 (elf_x86_link_hash_table): Remove need_global_offset_table.
3160 (elf_x86_init_table): Likewise.
3162 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
3164 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
3166 (i386_elf32_sol2_vec): Declared.
3167 (elf_i386_link_setup_gnu_properties): Set
3168 need_global_offset_table with info->output_bfd->xvec.
3169 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
3171 (x86_64_elf64_sol2_vec): Declared.
3172 (elf_x86_64_link_setup_gnu_properties): Set
3173 need_global_offset_table with info->output_bfd->xvec.
3175 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
3177 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
3179 (elf_i386_link_setup_gnu_properties): Set need_global_offset_table
3181 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
3183 (elf_x86_64_link_setup_gnu_properties): Set
3184 need_global_offset_table for Solaris.
3185 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep the
3186 unused _GLOBAL_OFFSET_TABLE_ for Solaris.
3187 (_bfd_x86_elf_link_setup_gnu_properties): Copy
3188 need_global_offset_table.
3189 * elfxx-x86.h (elf_x86_link_hash_table): Add
3190 need_global_offset_table.
3191 (elf_x86_init_table): Likewise.
3193 2018-02-08 Jim Wilson <jimw@sifive.com>
3195 * elfnn-riscv.c (riscv_elf_relocate_section): Add comment for previous
3198 2018-02-08 Nick Clifton <nickc@redhat.com>
3201 * elf.c (elf_parse_notes): Reject notes with excessuively large
3204 2018-02-07 Alan Modra <amodra@gmail.com>
3206 Revert 2018-01-17 Alan Modra <amodra@gmail.com>
3207 * elf32-ppc.c: Remove speculation barrier support.
3208 * elf32-ppc.h: Likewise.
3209 * elf64-ppc.c: Likewise.
3210 * elf64-ppc.h: Likewise.
3212 2018-02-06 Jim Wilson <jimw@sifive.com>
3214 * elfnn-riscv.c (riscv_elf_relocate_section): Return TRUE if used
3215 callback to report an error.
3217 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
3220 * elfxx-sparc.c (sparc_elf_tls_transition): Turn call to bfd_link_pic
3221 into call to !bfd_link_executable and tidy up.
3222 (_bfd_sparc_elf_check_relocs): Fix formatting and tidy up.
3223 <R_SPARC_TLS_LE_HIX22>: Turn call to bfd_link_pic into call to
3224 !bfd_link_executable.
3225 <R_SPARC_TLS_IE_HI22>: Likewise.
3226 <GOT relocations>: Remove useless code, tidy and merge related blocks.
3227 <R_SPARC_TLS_GD_CALL>: Turn call to bfd_link_pic into call to
3228 !bfd_link_executable.
3229 <R_SPARC_WPLT30>: Tidy up.
3230 (_bfd_sparc_elf_gc_mark_hook): Turn call to bfd_link_pic into call to
3231 !bfd_link_executable.
3232 (allocate_dynrelocs): Likewise.
3233 (_bfd_sparc_elf_relocate_section): Fix formatting and tidy up.
3234 <R_SPARC_TLS_GD_HI22>: Merge into...
3235 <R_SPARC_TLS_GD_LO10>: ...this. Adjust 4th argument in call to
3236 sparc_elf_tls_transition and remove redundant code.
3237 <R_SPARC_TLS_LDM_HI22>: Turn call to bfd_link_pic into call to
3238 !bfd_link_executable.
3239 <R_SPARC_TLS_LDO_HIX22>: Likewise.
3240 <R_SPARC_TLS_LE_HIX22>: Likewise. Tidy up.
3241 <R_SPARC_TLS_LDM_CALL>: Likewise.
3242 <R_SPARC_TLS_GD_CALL>: Likewise. Tidy up.
3243 <R_SPARC_TLS_GD_ADD>: Likewise.
3244 <R_SPARC_TLS_LDM_ADD>: Likewise.
3245 <R_SPARC_TLS_LDO_ADD>: Likewise.
3246 <R_SPARC_TLS_IE_LD>: Likewise.
3248 2018-02-06 Miloš Stojanović <milos.stojanovic@rt-rk.com>
3251 * elfxx-mips.c (_bfd_mips_elf_find_nearest_line): If the dwarf
3252 functions failed to find the function name, try the generic elf
3253 find function instead.
3255 2018-02-06 Sergio Durigan Junior <sergiodj@redhat.com>
3257 * coff-rs6000.c (xcoff_write_archive_contents_old): Use
3258 'memcpy' instead of 'strncpy' when writing the magic number.
3260 2018-02-06 Nick Clifton <nickc@redhat.com>
3263 * opncls.c (bfd_get_debug_link_info_1): Check the size of the
3264 section before attempting to read it in.
3265 (bfd_get_alt_debug_link_info): Likewise.
3267 2018-02-06 Paul Carroll <pcarroll@codesourcery.com>
3269 * bfd/dwarf2.c (find_abstract_name): Modified to return file and
3270 line information in addition to name, if they can be found.
3272 2018-02-05 Renlin Li <renlin.li@arm.com>
3275 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Relax the
3276 R_AARCH64_ABS32 and R_AARCH64_ABS16 for absolute symbol. Apply the
3277 check for writeable section as well.
3279 2018-02-05 H.J. Lu <hongjiu.lu@intel.com>
3282 * elf32-i386.c (elf_i386_check_relocs): Set got_referenced if
3283 _GLOBAL_OFFSET_TABLE_ is referenced or GOT is needed to resolve
3284 undefined weak symbol to 0.
3285 * elf64-x86-64.c (elf_x86_64_check_relocs): Set got_referenced
3286 if _GLOBAL_OFFSET_TABLE_ is referenced.
3287 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Check
3288 got_referenced instead of ref_regular_nonweak. Remove the
3289 unused _GLOBAL_OFFSET_TABLE_ from symbol table.
3290 * elfxx-x86.h (elf_x86_link_hash_table): Add got_referenced.
3292 2018-02-05 Maciej W. Rozycki <macro@mips.com>
3294 * elfnn-riscv.c (_bfd_riscv_relax_pc): Use `memset' to
3295 initialize `hi_reloc'.
3297 2018-02-05 Maciej W. Rozycki <macro@mips.com>
3299 * elfxx-mips.c (_bfd_mips_elf_section_processing): For
3300 SHT_MIPS_REGINFO sections don't assert the correct size and
3301 report an error instead.
3303 2018-02-05 Maciej W. Rozycki <macro@mips.com>
3305 * elf.c (_bfd_elf_write_object_contents): Propagate a failure
3306 status from `->elf_backend_section_processing'.
3308 2018-02-02 Jim Wilson <jimw@sifive.com>
3311 * elfnn-riscv.c (riscv_relax_delete_bytes): New parameter link_info.
3312 If link_info->wrap_hash, check for a duplicate symbol and ignore.
3313 (_bfd_riscv_relax_call, bfd_riscv_relax_lui, _bfd_riscv_relax_tls_le):
3314 Pass new argument to riscv_relax_delete_bytes.
3315 (_bfd_riscv_relax_align, _bfd_riscv_relax_delete): Likewise. Remove
3316 ATTRIBUTE_UNUSED from link_info parameter.
3318 2018-02-02 Alan Modra <amodra@gmail.com>
3320 * elf64-ppc.c (ppc64_elf_relocate_section): Don't relocate nops
3321 emitted for toc sequence optimization. Set and use "howto" later.
3323 2018-02-01 Simon Marchi <simon.marchi@ericsson.com>
3325 * elf64-ppc.c (ppc64_elf_archive_symbol_lookup): Avoid pointer
3326 arithmetic on NULL pointer.
3327 * elflink.c (_bfd_elf_archive_symbol_lookup,
3328 elf_link_add_archive_symbols): Likewise.
3330 2018-01-31 Michael Matz <matz@suse.de>
3332 * elflink.c (bfd_elf_define_start_stop): Fix check of
3335 2018-01-31 H.J. Lu <hongjiu.lu@intel.com>
3338 * elflink.c (bfd_elf_define_start_stop): Check if __start and
3339 __stop symbols are referenced by shared objects.
3341 2018-01-30 Alan Modra <amodra@gmail.com>
3344 * elf.c (_bfd_elf_map_sections_to_segments): Don't start a new
3345 segment when demand paged with lma on the same page. Test this
3346 before load/non-load, executable/non-executable,
3347 writable/non-writable tests and simplify. Delete bogus relro
3348 condition in writable/non-writable test. Delete outdated
3349 comment. Formatting.
3351 2018-01-30 Alan Modra <amodra@gmail.com>
3353 * elflink.c (bfd_elf_define_start_stop): Make __start and __stop
3356 2018-01-29 Alan Modra <amodra@gmail.com>
3359 * coffgen.c (coff_pointerize_aux): Ensure auxent tagndx is in
3360 range before converting to a symbol table pointer.
3362 2018-01-27 Nick Clifton <nickc@redhat.com>
3364 * po/ru.po: Updated Russian translation.
3366 2018-01-26 Alan Modra <amodra@gmail.com>
3368 * elflink.c (bfd_elf_define_start_stop): Override symbols when
3369 they are defined dynamically.
3371 2018-01-26 Alan Modra <amodra@gmail.com>
3373 * elf64-ppc.c (ppc64_elf_size_stubs): Iterate sizing when
3374 .branch_lt changes size.
3376 2018-01-25 Alan Modra <amodra@gmail.com>
3379 * elfcode.h (elf_object_p): Avoid integer overflow.
3381 2018-01-25 Eric Botcazou <ebotcazou@adacore.com>
3384 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
3385 Do a mere lookup of the __tls_get_addr symbol instead of adding it.
3388 2017-10-19 H.J. Lu <hongjiu.lu@intel.com>
3391 * elfxx-sparc.c (sparc_elf_tls_transition): Replace
3392 bfd_link_pic with !bfd_link_executable, !bfd_link_pic with
3393 bfd_link_executable for TLS check.
3394 (_bfd_sparc_elf_check_relocs): Likewise.
3395 (allocate_dynrelocs): Likewise.
3396 (_bfd_sparc_elf_relocate_section): Likewise.
3398 2018-01-24 Renlin Li <renlin.li@arm.com>
3400 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Add support for
3401 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
3402 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
3403 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
3404 BFD_RELOC_AARCH64_MOVW_PREL_G3.
3405 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
3406 (_bfd_aarch64_elf_resolve_relocation): Likewise.
3408 2018-01-24 Renlin Li <renlin.li@arm.com>
3410 * reloc.c: Add BFD_RELOC_AARCH64_MOVW_PREL_G0,
3411 BFD_RELOC_AARCH64_MOVW_PREL_G0_NC, BFD_RELOC_AARCH64_MOVW_PREL_G1,
3412 BFD_RELOC_AARCH64_MOVW_PREL_G1_NC, BFD_RELOC_AARCH64_MOVW_PREL_G2,
3413 BFD_RELOC_AARCH64_MOVW_PREL_G2_NC, BFD_RELOC_AARCH64_MOVW_PREL_G3.
3414 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add entries for
3415 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
3416 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
3417 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
3418 BFD_RELOC_AARCH64_MOVW_PREL_G3.
3419 * bfd-in2.h: Regenerate.
3420 * libbfd.h: Regenerate.
3422 2018-01-23 Maciej W. Rozycki <macro@mips.com>
3424 * elfxx-mips.c (_bfd_mips_elf_final_link): Update a stale
3425 `mips_elf32_section_processing' comment reference.
3427 2018-01-20 H.J. Lu <hongjiu.lu@intel.com>
3430 * elfxx-x86.c (_bfd_x86_elf_link_check_relocs): Check the
3431 versioned __tls_get_addr symbol.
3433 2018-01-19 Nick Clifton <nickc@redhat.com>
3435 * po/fr.po: Updated French translation.
3437 2018-01-18 Alan Modra <amodra@gmail.com>
3439 * elf32-ppc.c (ppc_elf_create_glink): Correct alignment of .glink.
3440 * elf64-ppc.c (ppc64_elf_size_stubs): Handle negative plt_stub_align.
3441 (ppc64_elf_build_stubs): Likewise.
3443 2018-01-17 Nick Clifton <nickc@redhat.com>
3445 * po/ru.po: Updated Russian translation.
3446 * po/uk/po: Updated Ukranian translation.
3448 2018-01-17 Alan Modra <amodra@gmail.com>
3450 * elf64-ppc.c (ppc64_elf_build_stubs): Silence gcc warning.
3452 2018-01-17 Alan Modra <amodra@gmail.com>
3454 * elf32-ppc.c (GLINK_ENTRY_SIZE): Handle speculation barrier.
3455 (CRSETEQ, BEQCTRM): Define.
3456 (is_nonpic_glink_stub): Don't check bctr.
3457 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
3458 (ppc_elf_relax_section): Size speculation barrier.
3459 (output_bctr): New function.
3460 (write_glink_stub): Use output_bctr.
3461 (ppc_elf_relocate_section): Use output_bctr for long branch stub.
3462 (ppc_elf_finish_dynamic_symbol): Likewise.
3463 (ppc_elf_finish_dynamic_sections): Use output_bctr.
3464 * elf32-ppc.h (struct ppc_elf_params): Add speculate_indirect_jumps.
3465 * elf64-ppc.c (CRSETEQ, BEQCTRM, BEQCTRLM): Define.
3466 (GLINK_PLTRESOLVE_SIZE): Size speculation barrier.
3467 (size_global_entry_stubs): Handle speculation barrier sizing.
3468 (plt_stub_size): Likewise.
3469 (output_bctr): New function.
3470 (build_plt_stub, build_tls_get_addr_stub): Output speculation
3472 (ppc_build_one_stub): Likewise for ppc_stub_plt_branch.
3473 (ppc_size_one_stub): Size speculation barrier in ppc_stub_plt_branch.
3474 (build_global_entry_stubs): Output speculation barrier.
3475 (ppc64_elf_build_stubs): Likewise in __glink_PLTresolve stub.
3476 * elf64-ppc.h (struct ppc64_elf_params): Add speculate_indirect_jumps.
3478 2018-01-17 Alan Modra <amodra@gmail.com>
3480 * elf32-ppc.c (GLINK_ENTRY_SIZE): Add parameters, handle
3481 __tls_get_addr_opt, and alignment sizing.
3482 (TLS_GET_ADDR_GLINK_SIZE): Delete.
3483 (is_nonpic_glink_stub): Don't use GLINK_ENTRY_SIZE.
3484 (ppc_elf_get_synthetic_symtab): Recognize stubs spaced at 4, 6,
3486 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
3487 (allocate_dynrelocs): Use new GLINK_ENTRY_SIZE.
3488 (ppc_elf_size_dynamic_sections): Likewise. Size branch table
3490 (write_glink_stub): Handle __tls_get_addr_opt stub.
3491 Pad out to size given by GLINK_ENTRY_SIZE.
3492 (ppc_elf_relocate_section): Adjust write_glink_stub call.
3493 (ppc_elf_finish_dynamic_symbol): Likewise.
3494 (ppc_elf_finish_dynamic_sections): Write PLTresolve without using
3495 insn array since so many need rewriting.
3496 * elf32-ppc.h (struct ppc_elf_params): Add plt_stub_align.
3497 * elf64-ppc.c (GLINK_PLTRESOLVE_SIZE): Rename from
3498 GLINK_CALL_STUB_SIZE. Add htab param and evaluate to size without
3499 nops. Adjust all uses.
3500 (ppc64_elf_get_synthetic_symtab): Don't use GLINK_CALL_STUB_SIZE
3501 in glink_vma calculation.
3502 (struct ppc_link_hash_table): Add global_entry section pointer.
3503 (create_linkage_sections): Create separate section for global
3505 (PPC_LO, PPC_HI, PPC_HA): Move earlier.
3506 (size_global_entry_stubs): Handle sizing for aligned stubs.
3507 (ppc64_elf_size_dynamic_sections): Handle global_entry alloc,
3508 and don't stash end of glink branch table in rawsize.
3509 (ppc_build_one_stub): Rewrite stub size calculations.
3510 (build_global_entry_stubs): Use new section.
3511 (ppc64_elf_build_stubs): Don't pad __glink_PLTresolve with nops.
3512 Build lazy link stubs out to end of section. Build global entry
3513 stubs in new section.
3515 2018-01-15 Nick Clifton <nickc@redhat.com>
3517 * po/uk.po: Updated Ukranian translation.
3519 2018-01-13 Nick Clifton <nickc@redhat.com>
3521 * po/bfd.pot: Regenerated.
3523 2018-01-13 Nick Clifton <nickc@redhat.com>
3525 * version.m4: Bump version to 2.30.51
3526 * configure: Regenerate.
3528 2018-01-13 Nick Clifton <nickc@redhat.com>
3530 2.30 branch created.
3532 2018-01-12 Jens Widell <jl@opera.com>
3534 * elf.c (setup_group): Optimize search for group by remembering
3535 last found group and restarting search at that index.
3536 * elf-bfd.h (struct elf_obj_tdata): Add group_search_offset field.
3538 2018-01-12 Gunther Nikl <gnikl@users.sourceforge.net>
3540 * aoutx.h (aout_link_check_ar_symbols): Remove default and handle
3541 bfd_link_common_skip_none in switch.
3543 2018-01-12 Alan Modra <amodra@gmail.com>
3546 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Ignore dynamic
3547 references on forced local symbols.
3549 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
3551 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
3552 .reginfo section has wrong size.
3554 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
3557 * elf.c (_bfd_elf_map_sections_to_segments): When generating
3558 separate code and read-only data LOAD segments, create a new
3559 LOAD segment if the previous section contains text and the
3560 current section doesn't or vice versa. Don't put a writable
3561 section in a read-only segment if there is a RELRO segment.
3563 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
3566 * elflink.c (bfd_elf_gc_mark_dynamic_ref_symbol): Ignore dynamic
3567 references on forced local symbols.
3569 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
3572 * elflink.c (bfd_elf_gc_sections): Keep all PREINIT_ARRAY,
3573 INIT_ARRAY as well as FINI_ARRAY sections for ld -r --gc-section.
3575 2018-01-09 Kuan-Lin Chen <kuanlinchentw@gmail.com>
3578 * elf32-nds32.c (nds32_elf_relax_loadstore): Fix a typographical error.
3580 2018-01-03 John Baldwin <jhb@FreeBSD.org>
3582 * elf.c (elfcore_grok_freebsd_note): Handle
3583 NT_FREEBSD_PROCSTAT_PROC, NT_FREEBSD_PROCSTAT_FILES, and
3584 NT_FREEBSD_PROCSTAT_VMMAP.
3586 2018-01-03 Alan Modra <amodra@gmail.com>
3588 Update year range in copyright notice of all files.
3590 For older changes see ChangeLog-2017
3592 Copyright (C) 2018 Free Software Foundation, Inc.
3594 Copying and distribution of this file, with or without modification,
3595 are permitted in any medium without royalty provided the copyright
3596 notice and this notice are preserved.
3602 version-control: never