Mark END_CATCH as ATTRIBUTE_NORETURN (-Wmaybe-uninitialized warnings)
[deliverable/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
92e68c1d
L
12018-05-28 H.J. Lu <hongjiu.lu@intel.com>
2
3 * elf32-i386.c (elf_i386_lazy_plt): Add plt_tlsdesc_entry,
4 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
5 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
6 plt_tlsdesc_got2_insn_end for TLSDESC entry.
7 (elf_i386_lazy_ibt_plt): Likewise.
8 (elf_i386_nacl_plt): Likewise.
9 * elf64-x86-64.c (tlsdesc_plt_entry): Moved and renamed to ...
10 (elf_x86_64_tlsdesc_plt_entry): This.
11 (elf_x86_64_lazy_plt): Add plt_tlsdesc_entry,
12 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
13 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
14 plt_tlsdesc_got2_insn_end for TLSDESC entry.
15 (elf_x86_64_lazy_bnd_plt): Likewise.
16 (elf_x86_64_lazy_ibt_plt): Likewise.
17 (elf_x32_lazy_ibt_plt): Likewise.
18 (elf_x86_64_nacl_plt): Likewise.
19 (elf_x86_64_finish_dynamic_sections): Use plt_tlsdesc_entry,
20 plt_tlsdesc_entry_size, plt_tlsdesc_got1_offset,
21 plt_tlsdesc_got2_offset, plt_tlsdesc_got1_insn_end and
22 plt_tlsdesc_got2_insn_end to update TLSDESC entry.
23 * elfxx-x86.h (elf_x86_lazy_plt_layout): Update comments.
24 Add plt_tlsdesc_entry, plt_tlsdesc_entry_size,
25 plt_tlsdesc_got1_offset, plt_tlsdesc_got2_offset,
26 plt_tlsdesc_got1_insn_end and plt_tlsdesc_got2_insn_end.
27 (elf_x86_non_lazy_plt_layout): Update comments.
28 (elf_x86_plt_layout): Likewise.
29
ac98f9e2
L
302018-05-28 H.J. Lu <hongjiu.lu@intel.com>
31
32 PR ld/23238
33 * elf-s390-common.c (elf_s390_add_symbol_hook): Removed.
34 * elf32-arc.c (elf_arc_add_symbol_hook): Likewise.
35 (elf_backend_add_symbol_hook): Likewise.
36 * elf32-m68k.c (elf_m68k_add_symbol_hook): Likewise.
37 (elf_backend_add_symbol_hook): Likewise.
38 * elf32-s390.c (elf_backend_add_symbol_hook): Likewise.
39 * elf32-sparc.c (elf32_sparc_add_symbol_hook): Likewise.
40 (elf_backend_add_symbol_hook): Likewise.
41 * elf64-s390.c (elf_backend_add_symbol_hook): Likewise.
42 * elfxx-aarch64.c (_bfd_aarch64_elf_add_symbol_hook): Likewise.
43 * elfxx-aarch64.h (_bfd_aarch64_elf_add_symbol_hook): Likewise.
44 (elf_backend_add_symbol_hook): Likewise.
45 * elf32-arm.c (elf32_arm_add_symbol_hook): Remove STT_GNU_IFUNC
46 handling.
47 * elf32-ppc.c (ppc_elf_add_symbol_hook): Likewise.
48 * elf64-ppc.c (ppc64_elf_add_symbol_hook): Likewise.
49 * elf64-sparc.c (elf64_sparc_add_symbol_hook): Likewise.
50 * elflink.c (elf_link_add_object_symbols): Set
51 elf_gnu_symbol_ifunc for STT_GNU_IFUNC symbols.
52
099bb8fb
L
532018-05-26 H.J. Lu <hongjiu.lu@intel.com>
54
55 PR ld/23194
56 * elf-bfd.h (_bfd_elf_link_hide_sym_by_version): New.
57 * elflink.c (_bfd_elf_link_hide_versioned_symbol): New function.
58 Extracted from _bfd_elf_link_assign_sym_version.
59 (_bfd_elf_link_hide_sym_by_version): New function.
60 (_bfd_elf_link_assign_sym_version): Use
61 _bfd_elf_link_hide_versioned_symbol.
62 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Call
63 _bfd_elf_link_hide_sym_by_version instead of
64 bfd_hide_sym_by_version. Don't check unversioned symbol.
65
277eb7f6
AM
662018-05-25 Alan Modra <amodra@gmail.com>
67
68 * Makefile.in: Regenerate.
69 * po/SRC-POTFILES.in: Regenerate.
70
629dabe3
AM
712018-05-25 Alan Modra <amodra@gmail.com>
72
73 * configure.ac (bfd_cv_hidden): Run test with -Werror in CFLAGS.
74 * configure: Regenerate.
75
9ef6d1e3
L
762018-05-23 H.J. Lu <hongjiu.lu@intel.com>
77
78 * elf64-ppc.c (ppc64_elf_write_core_note): Add ATTRIBUTE_NONSTRING
79 to data.
80
215f5271
AM
812018-05-22 Alan Modra <amodra@gmail.com>
82
83 PR 23207
84 * elf32-hppa.c (hppa_get_stub_entry): Return NULL when link_sec
85 is NULL.
86 (elf32_hppa_size_stubs): Only create stubs for load, alloc, code
87 sections.
88 (final_link_relocate): Revert last change.
89
7455c018
AM
902018-05-22 Alan Modra <amodra@gmail.com>
91
92 PR 23207
93 * elf32-hppa.c (final_link_relocate): Don't look for plt call
94 stubs in non-alloc sections.
95
34a87bb0
L
962018-05-21 H.J. Lu <hongjiu.lu@intel.com>
97
98 PR ld/23201
99 * aout-target.h (MY_bfd_link_hide_symbol): New.
100 * aout-tic30.c (MY_bfd_link_hide_symbol): Likewise.
101 * binary.c (binary_bfd_link_hide_symbol): Likewise.
102 * coff-alpha.c (_bfd_ecoff_bfd_link_hide_symbol): Likewise.
103 * coff-mips.c (_bfd_ecoff_bfd_link_hide_symbol): Likewise.
104 * coff-rs6000.c (_bfd_xcoff_bfd_link_hide_symbol): Likewise.
105 * coffcode.h (coff_bfd_link_hide_symbol): Likewise.
106 * elf-bfd.h (_bfd_elf_link_hide_symbol): Likewise.
107 * elfxx-target.h (bfd_elfNN_bfd_link_hide_symbol): Likewise.
108 * i386msdos.c (msdos_bfd_link_hide_symbol): Likewise.
109 * ihex.c (ihex_bfd_link_hide_symbol): Likewise.
110 * libbfd-in.h (_bfd_nolink_bfd_link_hide_symbol): Likewise.
111 * linker.c (_bfd_generic_link_hide_symbol): Likewise.
112 (bfd_link_hide_symbol): Likewise.
113 * mach-o-target.c (bfd_mach_o_bfd_link_hide_symbol): Likewise.
114 * mmo.c (mmo_bfd_link_hide_symbol): Likewise.
115 * pef.c (bfd_pef_bfd_link_hide_symbol): Likewise.
116 * plugin.c (bfd_plugin_bfd_link_hide_symbol): Likewise.
117 * ppcboot.c (ppcboot_bfd_link_hide_symbol): Likewise.
118 * som.c (som_bfd_link_hide_symbol): Likewise.
119 * srec.c (srec_bfd_link_hide_symbol): Likewise.
120 * tekhex.c (tekhex_bfd_link_hide_symbol): Likewise.
121 * vms-alpha.c (vms_bfd_link_hide_symbol): Likewise.
122 (alpha_vms_bfd_link_hide_symbol): Likewise.
123 * xsym.c (bfd_sym_bfd_link_hide_symbol): Likewise.
124 * coff64-rs6000.c (rs6000_xcoff64_vec): Add
125 _bfd_generic_link_hide_symbol.
126 (rs6000_xcoff64_aix_vec): Likewise.
127 * elflink.c (bfd_elf_record_link_assignment): Don't make forced
128 local symbol dynamic.
129 (_bfd_elf_link_hide_symbol): New function.
130 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
131 check root.ldscript_def.
132 * targets.c (bfd_target): Add _bfd_link_hide_symbol.
133 (BFD_JUMP_TABLE_LINK): Add NAME##_bfd_link_hide_symbol.
134 * bfd-in2.h: Regenerated.
135 * libbfd.h: Likewise.
136
bae363f1
L
1372018-05-21 H.J. Lu <hongjiu.lu@intel.com>
138
139 PR binutils/23199
140 * elf.c (setup_group): Mark section in a section group with
141 SHF_GROUP.
142
97373b2e
L
1432018-05-18 H.J. Lu <hongjiu.lu@intel.com>
144
145 PR ld/23194
146 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
147 set eh->local_ref to 1 if a symbol is versioned and there is a
148 version script.
149
7f999549
JW
1502018-05-18 Kito Cheng <kito.cheng@gmail.com>
151
152 * elfnn-riscv.c (_bfd_riscv_elf_merge_private_bfd_data): Handle
153 EF_RISCV_RVE.
154
6487709f
JW
1552018-05-18 Jim Wilson <jimw@sifive.com>
156
157 * elfnn-riscv.c (allocate_dynrelocs): Discard dynamic relocations if
158 UNDEFWEAK_NO_DYNAMIC_RELOC is true.
159 (riscv_elf_relocate_section): Don't generate dynamic relocation if
160 UNDEFWEAK_NO_DYNAMIC_RELOC is true.
161 (riscv_elf_finish_dynamic_symbol): Likewise.
162
7b4ae824
JD
1632018-05-18 John Darrington <john@darrington.wattle.id.au>
164
165 * Makefile.am: Add s12z files.
166 * Makefile.in: Regenerate.
167 * archures.c: Add bfd_s12z_arch.
168 * bfd-in.h: Add exports of bfd_putb24 and bfd_putl24.
169 * bfd-in2.h: Regenerate.
170 * config.bfd: Add s12z target.
171 * configure.ac: Add s12z target.
172 * configure: Regenerate.
173 * cpu-s12z.c: New file.
174 * elf32-s12z.c: New file.
175 * libbfd.c (bfd_putb24): New function.
176 (bfd_putl24): New function.
177 * libbfd.h: Regenerate.
178 * reloc.c: Add s12z relocations.
179 (bfd_get_reloc_size): Handle size 5 relocs.
180 * targets.c: Add s12z_elf32_vec.
181
011b32fd
L
1822018-05-18 H.J. Lu <hongjiu.lu@intel.com>
183
184 PR ld/23189
185 * elf32-i386.c (elf_i386_relocate_section): Handle R_386_GOT32X
186 like R_386_GOT32.
187 * elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
188 set eh->local_ref to 1 for linker defined symbols.
189
4bba0fb1
AM
1902018-05-18 Alan Modra <amodra@gmail.com>
191
192 PR 23199
193 * elf.c (setup_group): Formatting. Check that SHT_GROUP entries
194 don't point at other SHT_GROUP sections. Set shdr corresponding
195 to invalid entry, to NULL rather than section 0. Identify
196 SHT_GROUP section index when reporting an error. Cope with NULL
197 shdr pointer.
198
8722de9c
AM
1992018-05-18 Alan Modra <amodra@gmail.com>
200
201 * libbfd-in.h (ATTRIBUTE_HIDDEN): Define and use throughout.
202 * configure.ac (HAVE_HIDDEN): Check compiler support for hidden
203 visibility.
204 * libbfd.h: Regenerate.
205 * configure: Regenerate.
206 * config.in: Regenerate.
207
0b439543
AM
2082018-05-18 Alan Modra <amodra@gmail.com>
209
210 * libbfd-in.h: Add include guard.
211 * libcoff-in.h: Likewise.
212 * doc/Makefile.am (libbfd.h, libcoff.h): Append another #endif.
213 * doc/Makefile.in: Regenerate.
214 * libbfd.h: Regenerate.
215 * libcoff.h: Regenerate.
216
1624c9ca
MR
2172018-05-16 Maciej W. Rozycki <macro@mips.com>
218
219 * elf32-nds32.c (nds32_convert_32_to_16): Preset `insn_type'.
220
7cf7fcc8
AM
2212018-05-16 Alan Modra <amodra@gmail.com>
222
223 PR 22458
224 * format.c (struct bfd_preserve): Add section_id.
225 (bfd_preserve_save, bfd_preserve_restore): Save and restore
226 _bfd_section_id.
227 (bfd_reinit): Set _bfd_section_id.
228 (bfd_check_format_matches): Put all matches of any priority into
229 matching_vector. Save initial section id and start each attempted
230 match at that section id.
231 * libbfd-in.h (_bfd_section_id): Declare.
232 * section.c (_bfd_section_id): Rename from section_id and make
233 global. Adjust uses.
234 (bfd_get_next_section_id): Delete.
235 * elf64-ppc.c (ppc64_elf_setup_section_lists): Replace use of
236 bfd_get_section_id with _bfd_section_id.
237 * libbfd.h: Regenerate.
238 * bfd-in2.h: Regenerate.
239
810ed4db
CG
2402018-05-15 Christophe Guillon <christophe.guillon@st.com>
241
242 * coffcode.h (coff_bigobj_swap_aux_in): Make sure that all fields
243 of the aux structure are initialised.
244
1678bd35
FT
2452018-05-15 Francois H. Theron <francois.theron@netronome.com>
246
247 * targets.c: Wrap nfp_elf64_vec in BFD64 ifdef.
248
293b4d4f
NC
2492018-05-15 Nick Clifton <nickc@redhat.com>
250
251 * po/pt.po: New Portuguese translation.
252 * configure.ac (ALL_LINGUAS): Add pt.
253 * configure: Regenerate.
254
4ec09950
L
2552018-05-14 H.J. Lu <hongjiu.lu@intel.com>
256
257 PR ld/23169
258 * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Don't issue
259 an error on IFUNC pointer defined in PDE.
260 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Call
261 _bfd_x86_elf_link_fixup_ifunc_symbol.
262 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
263 * elfxx-x86.c (_bfd_x86_elf_link_fixup_ifunc_symbol): New
264 function.
265 * elfxx-x86.h (_bfd_x86_elf_link_fixup_ifunc_symbol): New.
266
9bc935ef
L
2672018-05-14 H.J. Lu <hongjiu.lu@intel.com>
268
269 PR ld/23162
270 * elfxx-x86.c (elf_x86_linker_defined): New function.
271 (_bfd_x86_elf_link_check_relocs): Use it to mark __bss_start,
272 _end and _edata locally defined within executables.
273
9933dc52
AM
2742018-05-12 Alan Modra <amodra@gmail.com>
275
276 PR 20659
277 * elf.c (rewrite_elf_program_header): Use segment_mark only for
278 PT_LOAD headers. Delete first_matching_lma and first_suggested_lma.
279 Instead make matching_lma and suggested_lma pointers to the
280 sections. Align section vma and lma calculated from segment.
281 Don't clear includes_phdrs or includes_filehdr based on p_paddr
282 test. Try to handle alignment padding before first section by
283 adjusting new segment lma down. Adjust PT_PHDR map p_paddr.
284
493ffac5
DD
2852018-05-09 Dimitar Dimitrov <dimitar@dinux.eu>
286
287 * elf32-pru.c (pru_elf32_do_ldi32_relocate): Make LDI32 relocation
288 conformant to TI ABI.
289 (pru_elf32_relax_section): Likewise.
290 (pru_elf_relax_delete_bytes): Fix offsets for new LDI32 code.
291 * elf32-pru.c (pru_elf32_do_ldi32_relocate): Ignore addend.
292 (pru_elf32_pmem_relocate): Trap - should not get here.
293 (pru_elf32_relocate_section): Add support for REL relocations.
294 (elf_info_to_howto_rel): Enable REL.
295 (elf_backend_may_use_rel_p): Likewise.
296 (elf_backend_may_use_rela_p): Likewise.
297 (elf_backend_default_use_rela_p): Likewise.
298
b4560c7d
AM
2992018-05-09 Alan Modra <amodra@gmail.com>
300
301 PR 23148
302 * peXXigen.c (pe_print_edata): Correct minimum size.
303
53db9cf9
AM
3042018-05-09 Alan Modra <amodra@gmail.com>
305
306 PR 23147
307 * peXXigen.c (pe_print_idata): Bound check hint_addr.
308
95a6d235
NC
3092018-05-08 Nick Clifton <nickc@redhat.com>
310
311 PR 22809
312 * elf.c (bfd_elf_get_str_section): Check for an excessively large
313 string section.
314 * elf-attrs.c (_bfd_elf_parse_attributes): Issue an error if the
315 attribute section is larger than the size of the file.
316
7bd8862c
AM
3172018-05-07 Alan Modra <amodra@gmail.com>
318
319 * cofflink.c (_bfd_coff_link_input_bfd): Use memcmp rather than
320 strncmp when checking for ".bf" special symbol.
321 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Make pe_required_section_flags
322 section name a char array, remove sentinal known_sections entry,
323 and adjust loop over known_sections to suit. Use memcmp rather
324 than strncmp.
325
602f1657
AM
3262018-05-04 Alan Modra <amodra@gmail.com>
327
328 * elf-linux-core.h (struct elf_external_linux_prpsinfo32_ugid32),
329 (struct elf_external_linux_prpsinfo32_ugid16),
330 (struct elf_external_linux_prpsinfo64_ugid32),
331 (struct elf_external_linux_prpsinfo64_ugid16): Add ATTRIBUTE_NONSTRING
332 to pr_fname and pr_psargs fields. Remove GCC diagnostic pragmas.
333 Move comment to..
334 * elf.c (elfcore_write_prpsinfo): ..here. Indent nested preprocessor
335 directives.
336 * elf32-arm.c (elf32_arm_nabi_write_core_note): Add ATTRIBUTE_NONSTRING
337 to data.
338 * elf32-ppc.c (ppc_elf_write_core_note): Likewise.
339 * elf32-s390.c (elf_s390_write_core_note): Likewise.
340 * elf64-s390.c (elf_s390_write_core_note): Likewise.
341 * elfxx-aarch64.c (_bfd_aarch64_elf_write_core_note): Likewise.
342 * elf64-x86-64.c (elf_x86_64_write_core_note): Add GCC diagnostic
343 pragmas.
344 * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Use strnlen to avoid
345 false positive gcc-8 warning.
7bd8862c 346 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
602f1657 347
a27ca19c
TMQMF
3482018-05-04 Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
349
350 * elf32-ppc.c (_bfd_elf_ppc_merge_fp_attributes): Fix the order
351 of arguments when warning about different long double types.
352
3be08ea4
SA
3532018-05-03 Simon Atanasyan <simon@atanasyan.com>
354
355 * elf32-mips.c: (elf32_mips_fixup_symbol): New function.
356 (elf_backend_fixup_symbol): New macro.
357 * elfxx-mips.c: (mips_elf_output_extsym): Discard _gp_disp
358 handling.
359 (_bfd_mips_elf_finish_dynamic_symbol): Likewise.
360
fe944acf
FT
3612018-04-30 Francois H. Theron <francois.theron@netronome.com>
362
363 * Makefile.am: Added NFP files to build.
364 * archures.c: Added bfd_arch_nfp
365 * config.bfd: Added NFP support.
366 * configure.ac: Added NFP support.
367 * cpu-nfp.c: New, for NFP support.
368 * elf-bfd.h: Added elf_section_info()
369 * elf64-nfp.c: New, for NFP support.
370 * po/SRC-POTFILES.in: Added NFP source files.
371 * targets.c: Added nfp_elf64_vec
372 * bfd-in2.h: Regenerate.
373 * Makefile.in: Regenerate.
374 * configure: Regenerate.
375
ffa389a3
AM
3762018-04-27 Alan Modra <amodra@gmail.com>
377
378 * bfd-in2.h: Regenerate.
379 * libbfd.h: Regenerate.
380
04383fd1
AM
3812018-04-27 Alan Modra <amodra@gmail.com>
382
383 PR 23123
384 PR 22374
385 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Don't drop plt
386 relocs for ifuncs.
387 * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Comment fixes.
388
bfa5bd2a
PA
3892018-04-26 Pedro Alves <palves@redhat.com>
390
391 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Don't consider
392 ifunc and non-ifunc symbols duplicates.
393
59029f57
CL
3942018-04-25 Christophe Lyon <christophe.lyon@st.com>
395 Mickaël Guêné <mickael.guene@st.com>
396
397 * elf32-arm.c (elf32_arm_fdpic_thumb_plt_entry): New.
398 (elf32_arm_plt_needs_thumb_stub_p): Handle thumb-only case.
399 (elf32_arm_populate_plt_entry): Likewise.
400 (elf32_arm_output_plt_map_1): Likewise.
401 (elf32_arm_output_arch_local_syms): Likewise.
402
fac7bd64
CL
4032018-04-25 Christophe Lyon <christophe.lyon@st.com>
404 Mickaël Guêné <mickael.guene@st.com>
405
406 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Handle
407 _GLOBAL_OFFSET_TABLE_ in FDPIC mode.
408
29e9b073
CL
4092018-04-25 Christophe Lyon <christophe.lyon@st.com>
410 Mickaël Guêné <mickael.guene@st.com>
411
412 * elf32-arm.c (bfd_elf32_arm_set_target_params): Handle FDPIC case
413 for R_ARM_TARGET2.
414
cb10292c
CL
4152018-04-25 Christophe Lyon <christophe.lyon@st.com>
416 Mickaël Guêné <mickael.guene@st.com>
417
418 * elf32-arm.c (DEFAULT_STACK_SIZE): New.
419 (elf32_arm_always_size_sections): Create stack segment.
420
5c5a4843
CL
4212018-04-25 Christophe Lyon <christophe.lyon@st.com>
422 Mickaël Guêné <mickael.guene@st.com>
423
424 * bfd-in2.h (BFD_RELOC_ARM_TLS_GD32_FDPIC)
425 (BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC): New
426 relocations.
427 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_TLS_GD32_FDPIC,
428 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC relocations.
429 (elf32_arm_reloc_map): Add R_ARM_TLS_GD32_FDPIC,
430 R_ARM_TLS_LDM32_FDPIC, R_ARM_TLS_IE32_FDPIC.
431 (struct elf32_arm_link_hash_table): Update comment.
432 (elf32_arm_final_link_relocate): Handle TLS FDPIC relocations.
433 (IS_ARM_TLS_RELOC): Likewise.
434 (elf32_arm_check_relocs): Likewise.
435 (allocate_dynrelocs_for_symbol): Likewise.
436 (elf32_arm_size_dynamic_sections): Update comment.
437 * reloc.c: Add BFD_RELOC_ARM_TLS_GD32_FDPIC,
438 BFD_RELOC_ARM_TLS_LDM32_FDPIC, BFD_RELOC_ARM_TLS_IE32_FDPIC.
439
7801f98f
CL
4402018-04-25 Christophe Lyon <christophe.lyon@st.com>
441 Mickaël Guêné <mickael.guene@st.com>
442
443 * elf32-arm.c (elf32_arm_fdpic_plt_entry): New.
444 (elf32_arm_create_dynamic_sections): Handle FDPIC.
445 (elf32_arm_allocate_plt_entry): Likewise.
446 (elf32_arm_populate_plt_entry): Likewise.
447 (elf32_arm_output_plt_map_1): Likewise.
448
e8b09b87
CL
4492018-04-25 Christophe Lyon <christophe.lyon@st.com>
450 Mickaël Guêné <mickael.guene@st.com>
451
452 * elf32-arm.c (struct fdpic_local): New.
453 (elf_arm_obj_tdata): Add local_fdpic_cnts field.
454 (elf32_arm_local_fdpic_cnts): New.
455 (struct fdpic_global): New.
456 (elf32_arm_link_hash_entry): Add fdpic_cnts field.
457 (elf32_arm_link_hash_table): Add srofixup field.
458 (arm_elf_add_rofixup): New.
459 (arm_elf_fill_funcdesc): New.
460 (elf32_arm_link_hash_newfunc): Handle fdpic_cnts.
461 (elf32_arm_allocate_local_sym_info): Likewise.
462 (create_got_section): Create .rofixup section.
463 (elf32_arm_copy_indirect_symbol): Handle fdpic_cnts.
464 (bfd_elf32_arm_set_target_params): Handle FDPIC.
465 (elf32_arm_final_link_relocate): Likewise.
466 (elf32_arm_check_relocs): Likewise.
467 (allocate_dynrelocs_for_symbol): Likewise.
468 (elf32_arm_size_dynamic_sections): Likewise.
469 (elf32_arm_finish_dynamic_sections): Likewise.
470 (elf32_arm_output_arch_local_syms): Likewise.
471 (elf32_arm_fdpic_omit_section_dynsym): New.
472
188fd7ae
CL
4732018-04-25 Christophe Lyon <christophe.lyon@st.com>
474 Mickaël Guêné <mickael.guene@st.com>
475
476 * bfd-in2.c (BFD_RELOC_ARM_GOTFUNCDESC)
477 (BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC)
478 (BFD_RELOC_ARM_FUNCDESC_VALUE): New.
479 * elf32-arm.c (elf32_arm_howto_table_2): Add R_ARM_GOTFUNCDESC,
480 R_ARM_GOTOFFFUNCDESC, R_ARM_FUNCDESC, R_ARM_FUNCDESC_VALUE.
481 (elf32_arm_howto_from_type): Take new members of
482 elf32_arm_howto_table_2 into account.
483 (elf32_arm_reloc_map): Add BFD_RELOC_ARM_GOTFUNCDESC,
484 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
485 BFD_RELOC_ARM_FUNCDESC_VALUE.
486 * reloc.c: Add BFD_RELOC_ARM_GOTFUNCDESC,
487 BFD_RELOC_ARM_GOTOFFFUNCDESC, BFD_RELOC_ARM_FUNCDESC,
488 BFD_RELOC_ARM_FUNCDESC_VALUE.
489
18a20338
CL
4902018-04-25 Christophe Lyon <christophe.lyon@st.com>
491 Mickaël Guêné <mickael.guene@st.com>
492
493 * elf32-arm.c (elf32_arm_print_private_bfd_data): Support
494 EF_ARM_PIC and ELFOSABI_ARM_FDPIC.
495 (elf32_arm_post_process_headers): Support ELFOSABI_ARM_FDPIC.
496 (ELF_OSABI): Define to ELFOSABI_ARM_FDPIC.
497
617a5ada
CL
4982018-04-25 Christophe Lyon <christophe.lyon@st.com>
499 Mickaël Guêné <mickael.guene@st.com>
500
501 * config.bfd (arm*-*-linux-*): Add arm_elf32_fdpic_be_vec and
502 arm_elf32_fdpic_le_vec to targ_selvecs. Accept
503 arm*-*-uclinuxfdpiceabi.
504 * configure.ac: Add support for arm_elf32_fdpic_be_vec and
505 arm_elf32_fdpic_le_vec.
506 * configure: Regenerate.
507 * elf32-arm.c (struct elf32_arm_link_hash_table): Add fdpic_p.
508 (elf32_arm_link_hash_table_create): Initialize fdpic_p.
509 (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME, TARGET_BIG_SYM)
510 (TARGET_BIG_NAME, elf_match_priority): Define for FDPIC targets.
511 (elf32_arm_fdpic_link_hash_table_create): New.
512 * targets.c (_bfd_target_vector): Add arm_elf32_fdpic_be_vec and
513 arm_elf32_fdpic_le_vec.
514
d99b4b92
AM
5152018-04-25 Alan Modra <amodra@gmail.com>
516
517 * elf-linux-core.h: Disable gcc-8 string truncation warning.
518 * elf.c (elfcore_write_prpsinfo): Likewise.
519
5202018-04-25 Alan Modra <amodra@gmail.com>
2ac93be7
AM
521
522 * Makefile.am: Remove arm-aout and arm-coff support.
523 * config.bfd: Likewise.
524 * configure.ac: Likewise.
525 * targets.c: Likewise.
526 * aout-arm.c: Delete.
527 * armnetbsd.c: Delete.
528 * riscix.c: Delete.
529 * Makefile.in: Regenerate.
530 * configure: Regenerate.
531 * po/SRC-POTFILES.in: Regenerate.
532
aa4a8c2a
NC
5332018-04-24 Nick Clifton <nickc@redhat.com>
534
db0c309f
NC
535 PR 23113
536 * elf.c (ignore_section_sym): Check for the output_section pointer
537 being NULL before dereferencing it.
538
aa4a8c2a
NC
539 PR 23110
540 * peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Check for
541 a negative PE_DEBUG_DATA size before iterating over the debug data.
542
b9f26d2e
AM
5432018-04-23 Alan Modra <amodra@gmail.com>
544
545 * elf-linux-core.h: Revert last change.
546 * elf.c: Likewise.
547
bf82069d
NC
5482018-04-23 Nick Clifton <nickc@redhat.com>
549
550 PR 23056
551 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
552 the end of the string table, and zero it.
553
5a6312e8
AM
5542018-04-23 Alan Modra <amodra@gmail.com>
555
556 * elf-linux-core.h (swap_linux_prpsinfo32_ugid32_out): Disable
557 gcc-8 string truncation warning.
558 (swap_linux_prpsinfo32_ugid16_out): Likewise.
559 (swap_linux_prpsinfo64_ugid32_out): Likewise.
560 (swap_linux_prpsinfo64_ugid16_out): Likewise.
561 * elf.c (elfcore_write_prpsinfo): Likewise.
562
bf82069d
NC
5632018-04-23 Nick Clifton <nickc@redhat.com>
564
565 PR 23056
566 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
567 the end of the string table, and zero it.
568
4352556b
AM
5692018-04-20 Alan Modra <amodra@gmail.com>
570
571 PR 22978
572 * elf32-hppa.c (got_relocs_needed): Add extra param to special
573 case both dtprel and tprel relocs.
574 (allocate_dynrelocs): Adjust conditions for got relocs.
575 (elf32_hppa_relocate_section): Likewise for local sym got relocs.
576 Emit dynamic relocs on TLS GOT entries for shared libraries,
577 not when pic. Omit dynamic reloc on dtprel entry when local,
578 and on tprel entry when local and executable.
579
f6a8b8c7
AM
5802018-04-19 Alan Modra <amodra@gmail.com>
581
582 PR 22537
583 * elf32-hppa.c (elf32_hppa_size_stubs): Init "destination" to -1.
584 (hppa_type_of_stub): Don't return a long branch stub for
585 symbols other than those defined statically.
586
8e415ce8
AM
5872018-04-19 Alan Modra <amodra@gmail.com>
588
589 * Makefile.am: Revert 2018-04-18 coff-mips changes.
590 * config.bfd: Add back mips_ecoff_le_vec and mips_ecoff_be_vec
591 to selvecs for mips targets change 2018-04-18.
592 * configure.ac: Reinstate mips_ecoff_le_vec, mips_ecoff_be_vec
593 and mips_ecoff_bele_vec.
594 * targets.c: Likewise.
595 * coff-mips.c: Resurrect.
596 * Makefile.in: Regenerate.
597 * configure: Regenerate.
598 * po/SRC-POTFILES.in: Regenerate.
599
3596d8ce
AM
6002018-04-18 Alan Modra <amodra@gmail.com>
601
602 * Makefile.am: Remove mips aout and coff support.
603 * config.bfd: Likewise.
604 * configure.ac: Likewise.
605 * targets.c: Likewise.
606 * coff-mips.c: Delete
607 * mipsbsd.c: Delete
608 * pe-mips.c: Delete
609 * pei-mips.c: Delete
610 * Makefile.in: Regenerate.
611 * configure: Regenerate.
612 * po/SRC-POTFILES.in: Regenerate.
613
d9dd2045
L
6142018-04-17 H.J. Lu <hongjiu.lu@intel.com>
615
616 * elf32-i386.c (elf32_bed): Define before including
617 "elf32-target.h".
618 * elf64-x86-64.c (elf64_bed): Define before including
619 "elf64-target.h".
620 (elf32_bed): Define before including "elf32-target.h".
621
e4e6a73d
L
6222018-04-17 H.J. Lu <hongjiu.lu@intel.com>
623
624 PR ld/23055
625 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Use a
626 normal input file with compatible relocation.
627
c65c21e1
AM
6282018-04-18 Alan Modra <amodra@gmail.com>
629
630 * Makefile.am: Remove support for assorted i386 aout and coff targets.
631 * config.bfd: Likewise.
632 * configure.ac: Likewise.
633 * doc/bfdint.texi: Likewise.
634 * targets.c: Likewise.
635 * freebsd.h: Delete.
636 * i386dynix.c: Delete.
637 * i386freebsd.c: Delete.
638 * i386linux.c: Delete.
639 * i386mach3.c: Delete.
640 * i386netbsd.c: Delete.
641 * i386os9k.c: Delete.
642 * Makefile.in: Regenerate.
643 * configure: Regenerate.
644 * po/SRC-POTFILES.in: Regenerate.
645
884d4d8a 6462018-04-17 Andrew Sadek <andrew.sadek.se@gmail.com>
3f0a5f17
ME
647
648 Microblaze Target: PIC data text relative
649
650 * bfd/reloc.c (2 new BFD relocations):
651 BFD_RELOC_MICROBLAZE_64_TEXTPCREL &
652 BFD_RELOC_MICROBLAZE_64_TEXTPCREL
653 * bfd/bfd-in2.h: Regenerate
654 * bfd/libbfd.h: Regenerate
655 * bfd/elf32-microblaze.c (Handle new relocs): define 'HOWTO' of 3
656 new relocs and handle them in both relocate and relax functions.
657 (microblaze_elf_reloc_type_lookup): add mapping between for new
658 bfd relocs.
659 (microblaze_elf_relocate_section): Handle new relocs in case of
660 elf relocation.
661 (microblaze_elf_relax_section): Handle new relocs for elf relaxation.
662
6327533b
NC
6632018-04-17 Nick Clifton <nickc@redhat.com>
664
808346fc
NC
665 PR 23055
666 * aoutx.h (find_nearest_line): Check that the symbol name exists
667 and is long enough, before attempting to see if it is for a .o
668 file.
669 * hash.c (bfd_hash_hash): Add an assertion that the string is not
670 NULL.
671 * linker.c (bfd_link_hash_lookup): Fail if the table or string are
672 NULL.
673 (_bfd_generic_link_add_archive_symbols): Fail if an archive entry
674 has no name.
675
6327533b
NC
676 PR 23065
677 * dwarf2.c (concat_filename): Check for a NULL table pointer.
678
e9af4700
NC
6792018-04-16 Nick Clifton <nickc@redhat.com>
680
681 PR 23061
682 * coffgen.c (coff_pointerize_aux): Check for an out of range
683 fixup.
684
ddb00039
AM
6852018-04-16 Alan Modra <amodra@gmail.com>
686
687 * Makefile.am: Remove arm-epoc-pe support.
688 * coff-arm.c: Likewise.
689 * config.bfd: Likewise.
690 * configure.ac: Likewise.
691 * targets.c: Likewise.
692 * epoc-pe-arm.c: Delete.
693 * epoc-pei-arm.c: Delete.
694 * Makefile.in: Regenerate.
695 * configure: Regenerate.
696 * po/SRC-POTFILES.in: Regenerate.
697
c9098af4
AM
6982018-04-16 Alan Modra <amodra@gmail.com>
699
700 * Makefile.am: Remove sparc-aout and sparc-coff support.
701 * config.bfd: Likewise.
702 * configure.ac: Likewise.
703 * targets.c: Likewise.
704 * aout-sparcle.c: Delete.
705 * aoutf1.h: Delete.
706 * cf-sparclynx.c: Delete.
707 * coff-sparc.c: Delete.
708 * demo64.c: Delete.
709 * sparclinux.c: Delete.
710 * sparclynx.c: Delete.
711 * sparcnetbsd.c: Delete.
712 * sunos.c: Delete.
713 * Makefile.in: Regenerate.
714 * configure: Regenerate.
715 * po/SRC-POTFILES.in: Regenerate.
716
dc12032b
AM
7172018-04-16 Alan Modra <amodra@gmail.com>
718
719 * Makefile.am: Remove m68k-aout and m68k-coff support.
720 * aoutf1.h: Likewise.
721 * aoutx.h: Likewise.
722 * archive.c: Likewise.
723 * bfd-in.h: Likewise.
724 * bfd.c: Likewise.
725 * coffcode.h: Likewise.
726 * coffswap.h: Likewise.
727 * config.bfd: Likewise.
728 * configure.ac: Likewise.
729 * configure.host: Likewise.
730 * doc/bfd.texinfo: Likewise.
731 * doc/bfdint.texi: Likewise.
732 * freebsd.h: Likewise.
733 * gen-aout.c: Likewise.
734 * hpux-core.c: Likewise.
735 * libaout.h: Likewise.
736 * libbfd-in.h: Likewise.
737 * pdp11.c: Likewise.
738 * peicode.h: Likewise.
739 * riscix.c: Likewise.
740 * targets.c: Likewise.
741 * aout0.c: Delete.
742 * coff-apollo.c: Delete.
743 * coff-aux.c: Delete.
744 * coff-m68k.c: Delete.
745 * coff-svm68k.c: Delete.
746 * coff-u68k.c: Delete.
747 * hosts/delta68.h: Delete.
748 * hosts/hp300bsd.h: Delete.
749 * hosts/m68kaux.h: Delete.
750 * hosts/news.h: Delete.
751 * hp300bsd.c: Delete.
752 * hp300hpux.c: Delete.
753 * liboasys.h: Delete.
754 * m68k4knetbsd.c: Delete.
755 * m68klinux.c: Delete.
756 * m68knetbsd.c: Delete.
757 * oasys.c: Delete.
758 * versados.c: Delete.
759 * Makefile.in: Regenerate.
760 * bfd-in2.h: Regenerate.
761 * configure: Regenerate.
762 * libbfd.h: Regenerate.
763 * po/SRC-POTFILES.in: Regenerate.
764
211dc24b
AM
7652018-04-16 Alan Modra <amodra@gmail.com>
766
767 * Makefile.am: Remove sh5 and sh64 support.
768 * archures.c: Likewise.
769 * config.bfd: Likewise.
770 * configure.ac: Likewise.
771 * cpu-sh.c: Likewise.
772 * elf32-sh-relocs.h: Likewise.
773 * elf32-sh.c: Likewise.
774 * targets.c: Likewise.
775 * elf32-sh64-com.c: Delete.
776 * elf32-sh64.c: Delete.
777 * elf32-sh64.h: Delete.
778 * elf64-sh64.c: Delete.
779 * Makefile.in: Regenerate.
780 * bfd-in2.h: Regenerate.
781 * configure: Regenerate.
782 * po/SRC-POTFILES.in: Regenerate.
783
4db9937a
AM
7842018-04-16 Alan Modra <amodra@gmail.com>
785
786 * Makefile.am: Remove sh-symbianelf support.
787 * config.bfd: Likewise.
788 * configure.ac: Likewise.
789 * targets.c: Likewise.
790 * elf32-sh-symbian.c: Delete.
791 * Makefile.in: Regenerate.
792 * configure: Regenerate.
793 * po/SRC-POTFILES.in: Regenerate.
794
9f5d1593
AM
7952018-04-16 Alan Modra <amodra@gmail.com>
796
797 * Makefile.am: Remove vax-bsd and vax-ultrix support.
798 * config.bfd: Likewise.
799 * configure.ac: Likewise.
800 * targets.c: Likewise.
801 * vaxbsd.c: Delete.
802 * Makefile.in: Regenerate.
803 * configure: Regenerate.
804 * po/SRC-POTFILES.in: Regenerate.
805
a9a4b302
AM
8062018-04-16 Alan Modra <amodra@gmail.com>
807
808 * Makefile.am: Remove w65 support.
809 * archures.c: Likewise.
810 * coffcode.h: Likewise.
811 * config.bfd: Likewise.
812 * configure.ac: Likewise.
813 * targets.c: Likewise.
814 * coff-w65.c: Delete.
815 * cpu-w65.c: Delete.
816 * Makefile.in: Regenerate.
817 * bfd-in2.h: Regenerate.
818 * configure: Regenerate.
819 * po/SRC-POTFILES.in: Regenerate.
820
04cb01fd
AM
8212018-04-16 Alan Modra <amodra@gmail.com>
822
823 * Makefile.am: Remove we32k support.
824 * archures.c: Likewise.
825 * coffcode.h: Likewise.
826 * config.bfd: Likewise.
827 * configure.ac: Likewise.
828 * targets.c: Likewise.
829 * coff-we32k.c: Delete.
830 * cpu-we32k.c: Delete.
831 * Makefile.in: Regenerate.
832 * bfd-in2.h: Regenerate.
833 * configure: Regenerate.
834 * po/SRC-POTFILES.in: Regenerate.
835
c2bf1eec
AM
8362018-04-16 Alan Modra <amodra@gmail.com>
837
838 * Makefile.am: Remove m88k support.
839 * aoutx.h: Likewise.
840 * archures.c: Likewise.
841 * coffcode.h: Likewise.
842 * coffswap.h: Likewise.
843 * config.bfd: Likewise.
844 * configure.ac: Likewise.
845 * cpu-ns32k.c: Likewise.
846 * elf32-nds32.c: Likewise.
847 * mach-o.c: Likewise.
848 * netbsd-core.c: Likewise.
849 * reloc.c: Likewise.
850 * targets.c: Likewise.
851 * coff-m88k.c: Delete.
852 * cpu-m88k.c: Delete.
853 * elf32-m88k.c: Delete.
854 * hosts/m88kmach3.h: Delete.
855 * m88kmach3.c: Delete.
856 * m88kopenbsd.c: Delete.
857 * Makefile.in: Regenerate.
858 * bfd-in2.h: Regenerate.
859 * configure: Regenerate.
860 * po/SRC-POTFILES.in: Regenerate.
861
6793974d
AM
8622018-04-16 Alan Modra <amodra@gmail.com>
863
864 * Makefile.am: Remove i370 support.
865 * archures.c: Likewise.
866 * config.bfd: Likewise.
867 * configure.ac: Likewise.
868 * targets.c: Likewise.
869 * cpu-i370.c: Delete.
870 * elf32-i370.c: Delete.
871 * Makefile.in: Regenerate.
872 * bfd-in2.h: Regenerate.
873 * configure: Regenerate.
874 * po/SRC-POTFILES.in: Regenerate.
875
e82aa794
AM
8762018-04-16 Alan Modra <amodra@gmail.com>
877
878 * Makefile.am: Remove h8500 support.
879 * archures.c: Likewise.
880 * coffcode.h: Likewise.
881 * config.bfd: Likewise.
882 * configure.ac: Likewise.
883 * targets.c: Likewise.
884 * coff-h8500.c: Delete.
885 * cpu-h8500.c: Delete.
886 * Makefile.in: Regenerate.
887 * bfd-in2.h: Regenerate.
888 * configure: Regenerate.
889 * po/SRC-POTFILES.in: Regenerate.
890
fe0bf0fd
AM
8912018-04-16 Alan Modra <amodra@gmail.com>
892
893 * Makefile.am: Remove h8300-coff support.
894 * coffcode.h: Likewise.
895 * config.bfd: Likewise.
896 * configure.ac: Likewise.
897 * reloc16.c: Likewise.
898 * targets.c: Likewise.
899 * coff-h8300.c: Delete.
900 * Makefile.in: Regenerate.
901 * configure: Regenerate.
902 * po/SRC-POTFILES.in: Regenerate.
903
fdef3943
AM
9042018-04-16 Alan Modra <amodra@gmail.com>
905
906 * Makefile.am: Remove IEEE 695 support.
907 * archures.c: Likewise.
908 * bfd.c: Likewise.
909 * config.bfd: Likewise.
910 * configure.ac: Likewise.
911 * doc/bfd.texinfo: Likewise.
912 * doc/bfdint.texi: Likewise.
913 * doc/bfdsumm.texi: Likewise.
914 * section.c: Likewise.
915 * targets.c: Likewise.
916 * ieee.c: Delete.
917 * libieee.h: Delete.
918 * Makefile.in: Regenerate.
919 * bfd-in2.h: Regenerate.
920 * configure: Regenerate.
921 * po/SRC-POTFILES.in: Regenerate.
922
de96689e
AM
9232018-04-16 Alan Modra <amodra@gmail.com>
924
925 * config.bfd: Remove tandem support.
926
5972ac73
AM
9272018-04-16 Alan Modra <amodra@gmail.com>
928
929 * Makefile.am: Remove newsos3 support.
930 * aoutx.h: Likewise.
931 * config.bfd: Likewise.
932 * configure.ac: Likewise.
933 * targets.c: Likewise.
934 * newsos3.c: Delete.
935 * Makefile.in: Regenerate.
936 * configure: Regenerate.
937 * po/SRC-POTFILES.in: Regenerate.
938
b4b594e3
AM
9392018-04-16 Alan Modra <amodra@gmail.com>
940
941 * Makefile.am: Remove netware support.
942 * bfd-in.h: Likewise.
943 * bfd.c: Likewise.
944 * config.bfd: Likewise.
945 * configure.ac: Likewise.
946 * doc/bfdint.texi: Likewise.
947 * ecoff.c: Likewise.
948 * targets.c: Likewise.
949 * libnlm.h: Delete.
950 * nlm-target.h: Delete.
951 * nlm.c: Delete.
952 * nlm32-alpha.c: Delete.
953 * nlm32-i386.c: Delete.
954 * nlm32-ppc.c: Delete.
955 * nlm32-sparc.c: Delete.
956 * nlm32.c: Delete.
957 * nlm64.c: Delete.
958 * nlmcode.h: Delete.
959 * nlmswap.h: Delete.
960 * Makefile.in: Regenerate.
961 * bfd-in2.h: Regenerate.
962 * configure: Regenerate.
963 * po/SRC-POTFILES.in: Regenerate.
964
fceadf09
AM
9652018-04-16 Alan Modra <amodra@gmail.com>
966
967 * archures.c: Remove tahoe support.
968 * config.bfd: Likewise.
969 * configure.ac: Likewise.
970 * hosts/tahoe.h: Delete.
971 * bfd-in2.h: Regenerate.
972 * configure: Regenerate.
973
702d1671
AM
9742018-04-14 Alan Modra <amodra@gmail.com>
975
976 * elf-bfd.h (struct elf_backend_data): Add relropagesize.
977 * elfxx-target.h (ELF_RELROPAGESIZE): Provide default and
978 sanity test.
979 (elfNN_bed): Init relropagesize.
980 * bfd.c (bfd_emul_get_commonpagesize): Add boolean param to
981 select relropagesize.
982 * elf32-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
983 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
984 (ELF_MINPAGESIZE): Don't define.
985 * elf64-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
986 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
987 * bfd-in2.h: Regenerate.
988
03aa9684
AM
9892018-04-14 Alan Modra <amodra@gmail.com>
990
991 * elf32-ppc.c (ELF_MAXPAGESIZE, ELF_COMMONPAGESIZE): Don't depend
992 on __QNXTARGET__ define.
993
24acfe5e
AM
9942018-04-14 Alan Modra <amodra@gmail.com>
995
996 * config.bfd: Add powerpc-*-lynxos* and powerpc-*-windiss*
997 to obsolete list.
998
a8eb42a8
AM
9992018-04-11 Alan Modra <amodra@gmail.com>
1000
1001 * aout-adobe.c: Delete.
1002 * bout.c: Delete.
1003 * coff-i860.c: Delete.
1004 * coff-i960.c: Delete.
1005 * cpu-i860.c: Delete.
1006 * cpu-i960.c: Delete.
1007 * elf32-i860.c: Delete.
1008 * elf32-i960.c: Delete.
1009 * hosts/i860mach3.h: Delete.
1010 * Makefile.am: Remove i860, i960, bout, and adobe support.
1011 * archures.c: Remove i860 and i960 support.
1012 * coffcode.h: Likewise.
1013 * reloc.c: Likewise.
1014 * aoutx.h: Comment updates.
1015 * archive.c: Remove BOUT and i960 support.
1016 * bfd.c: Remove BOUT support.
1017 * coffswap.h: Remove i960 support.
1018 * config.bfd: Remove i860, i960 and adobe targets.
1019 * configure.ac: Remove adode, bout, i860, i960, icoff targets.
1020 * targets.c: Likewise.
1021 * ieee.c: Remove i960 support.
1022 * mach-o.c: Remove i860 support.
1023 * Makefile.in: Regenerate.
1024 * bfd-in2.h: Regenerate.
1025 * configure: Regenerate.
1026 * libbfd.h: Regenerate.
1027 * po/SRC-POTFILES.in: Regenerate.
1028
aec2e0d2
MR
10292018-04-09 Maciej W. Rozycki <macro@mips.com>
1030
1031 * elf64-mips.c (mips_elf64_write_rel): Handle a NULL BFD pointer
1032 in the BFD symbol referred by the relocation.
1033 (mips_elf64_write_rela): Likewise.
1034
9ccfa98b
MR
10352018-04-09 Maciej W. Rozycki <macro@mips.com>
1036
1037 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Issue an
1038 error for out-of-range `r_sym' values.
1039
3e04d765
AM
10402018-04-09 Alan Modra <amodra@gmail.com>
1041
1042 * elf64-ppc.c (struct _ppc64_elf_section_data): Add has_pltcall field.
1043 (struct ppc_link_hash_table): Add can_convert_all_inline_plt.
1044 (ppc64_elf_check_relocs): Set has_pltcall.
1045 (ppc64_elf_adjust_dynamic_symbol): Discard some PLT entries.
1046 (ppc64_elf_inline_plt): New function.
1047 (ppc64_elf_size_dynamic_sections): Discard some PLT entries for locals.
1048 * elf64-ppc.h (ppc64_elf_inline_plt): Declare.
1049 * elf32-ppc.c (has_pltcall): Define.
1050 (struct ppc_elf_link_hash_table): Add can_convert_all_inline_plt.
1051 (ppc_elf_check_relocs): Set has_pltcall.
1052 (ppc_elf_inline_plt): New function.
1053 (ppc_elf_adjust_dynamic_symbol): Discard some PLT entries.
1054 (ppc_elf_size_dynamic_sections): Likewise.
1055 * elf32-ppc.h (ppc_elf_inline_plt): Declare.
1056
23cedd1d
AM
10572018-04-09 Alan Modra <amodra@gmail.com>
1058
1059 * elf32-ppc.c (ppc_elf_howto_raw): Add PLTSEQ and PLTCALL howtos.
1060 (is_plt_seq_reloc): New function.
1061 (ppc_elf_check_relocs): Handle PLTSEQ and PLTCALL relocs.
1062 (ppc_elf_tls_optimize): Handle inline plt call sequence.
1063 (ppc_elf_relax_section): Handle PLTCALL reloc.
1064 (ppc_elf_relocate_section): Nop out inline plt call sequence when
1065 resolving locally.
1066 * elf64-ppc.c (ppc64_elf_howto_raw): Add R_PPC64_PLTSEQ and
1067 R_PPC64_PLTCALL entries. Comment R_PPC64_TOCSAVE.
1068 (has_tls_get_addr_call): Correct comment.
1069 (is_branch_reloc): Add PLTCALL.
1070 (is_plt_seq_reloc): New function.
1071 (ppc64_elf_check_relocs): Handle PLT16_LO_DS reloc. Set
1072 has_tls_reloc for R_PPC64_TLSGD and R_PPC64_TLSLD. Create plt
1073 entry for R_PPC64_PLTCALL.
1074 (ppc64_elf_tls_optimize): Handle inline plt call sequence.
1075 (ppc_type_of_stub): Handle PLTCALL reloc.
1076 (toc_adjusting_stub_needed): Likewise.
1077 (ppc64_elf_relocate_section): Set "can_plt_call" for PLTCALL
1078 reloc insn. Nop out inline plt call sequence when resolving
1079 locally. Handle __tls_get_addr inline plt call optimization.
1080
2d7ad24e
AM
10812018-04-09 Alan Modra <amodra@gmail.com>
1082
1083 * elf64-ppc.c (LOCAL_PLT_ENTRY_SIZE): Define.
1084 (struct ppc_stub_hash_entry): Add symtype field.
1085 (PLT_KEEP): Define.
1086 (struct ppc_link_hash_table): Add pltlocal and relpltlocal.
1087 (create_linkage_sections): Create pltlocal and relpltlocal.
1088 (ppc64_elf_check_relocs): Allow PLT relocs on local symbols.
1089 Set PLT_KEEP.
1090 (ppc64_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
1091 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
1092 (ppc64_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
1093 Keep PLT entries for inline calls against locals.
1094 (ppc_build_one_stub): Use pltlocal as appropriate.
1095 (ppc_size_one_stub): Likewise.
1096 (ppc64_elf_size_stubs): Set symtype.
1097 (build_global_entry_stubs_and_plt): Init pltlocal and write
1098 relpltlocal for globals.
1099 (write_plt_relocs_for_local_syms): Likewise for local syms.
1100 (ppc64_elf_relocate_section): Support PLT for local syms.
1101 * elf32-ppc.c (PLT_KEEP): Define.
1102 (struct ppc_elf_link_hash_table): Add pltlocal and relpltlocal.
1103 (ppc_elf_create_glink): Create pltlocal and relpltlocal.
1104 (ppc_elf_check_relocs): Allow PLT relocs on local symbols.
1105 Set PLT_KEEP. Adjust update_local_sym_info call.
1106 (ppc_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
1107 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
1108 (ppc_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
1109 (ppc_elf_relocate_section): Support PLT16 relocs for local syms.
1110 (write_global_sym_plt): Init pltlocal and write relpltlocal.
1111 (ppc_finish_symbols): Likewise for locals.
1112
49c09209
AM
11132018-04-09 Alan Modra <amodra@gmail.com>
1114
1115 * elf64-ppc.c (ppc_build_one_stub): Move output of PLT relocs
1116 for local symbols to..
1117 (write_plt_relocs_for_local_syms): ..here. New function.
1118 (ppc64_elf_finish_dynamic_symbol): Move output of PLT relocs for
1119 global symbols to..
1120 (build_global_entry_stubs_and_plt): ..here. Rename from
1121 build_global_entry_stubs.
1122 (ppc64_elf_build_stubs): Always call build_global_entry_stubs_and_plt.
1123 Call write_plt_relocs_for_local_syms.
1124 * elf32-ppc.c (get_sym_h): New function.
1125 (ppc_elf_relax_section): Use get_sym_h.
1126 (ppc_elf_relocate_section): Move output of PLT relocs and glink
1127 stubs for local symbols to..
1128 (ppc_finish_symbols): ..here. New function.
1129 (ppc_elf_finish_dynamic_symbol): Move output of PLT relocs for
1130 global syms to..
1131 (write_global_sym_plt): ..here. New function.
1132 * elf32-ppc.h (ppc_elf_modify_segment_map): Delete attribute.
1133 (ppc_finish_symbols): Declare.
1134
08be3224
AM
11352018-04-09 Alan Modra <amodra@gmail.com>
1136
1137 * elf32-ppc.c (ppc_elf_check_relocs): Handle PLT16 relocs.
1138 (ppc_elf_relocate_section): Likewise.
1139 * elf64-ppc.c (ppc64_elf_check_relocs): Handle PLT16_LO_DS.
1140 (ppc64_elf_relocate_section): Likewise. Correct PLT16
1141 resolution to plt entry relative to toc pointer.
1142
37da22e5
AM
11432018-04-09 Alan Modra <amodra@gmail.com>
1144
1145 * elf64-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
1146 TLS_TPRELGD, TLS_EXPLICIT): Renumber. Test TLS_TLS throughout
1147 file when other TLS flags are tested in a mask.
1148 (TLS_MARK, NON_GOT): Define.
1149 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
1150 (update_local_sym_info): Don't create got entry when NON_GOT.
1151 (ppc64_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
1152 Set TLS_MARK.
1153 (get_tls_mask): Do toc lookup if tls_mask is just TLS_MARK.
1154 (ppc64_elf_relocate_section): Likewise.
1155 (ppc64_elf_tls_optimize): Don't attempt to optimize indirect
1156 __tls_get_addr calls lacking a marker reloc.
1157 * elf32-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
1158 TLS_TPRELGD): Renumber. Update comment.
1159 (TLS_MARK, NON_GOT): Define.
1160 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
1161 (update_local_sym_info): Don't create got entry when NON_GOT.
1162 (ppc_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
1163 Set TLS_MARK.
1164 (ppc_elf_tls_optimize): Don't attempt to optimize indirect
1165 __tls_get_addr calls lacking a marker reloc.
1166
a6fd92b0
L
11672018-04-06 H.J. Lu <hongjiu.lu@intel.com>
1168
1169 * elf64-x86-64.c (elf_x86_64_info_to_howto): Don't mask out
1170 R_X86_64_converted_reloc_bit.
1171
3cba8b6c
L
11722018-04-05 H.J. Lu <hongjiu.lu@intel.com>
1173
1174 PR gas/22318
1175 * configure: Regenerated.
1176
0e8452bb
AM
11772018-04-05 Alan Modra <amodra@gmail.com>
1178
1179 * elf-hppa.h (elf_hppa_info_to_howto): Init howto to NULL.
1180 (elf_hppa_info_to_howto_rel): Likewise.
1181
8ee55178
MR
11822018-04-04 Maciej W. Rozycki <macro@mips.com>
1183
1184 * elf-hppa.h (elf_hppa_info_to_howto): Also return
1185 unsuccessfully for unimplemented relocations.
1186 (elf_hppa_info_to_howto_rel): Likewise.
1187
5d7c8b80
MR
11882018-04-04 Maciej W. Rozycki <macro@mips.com>
1189
1190 * elf32-i860.c (lookup_howto): Add `abfd' parameter. Set the
1191 `bfd_error_bad_value' error and call `_bfd_error_handler' on a
1192 howto lookup failure.
1193 (elf32_i860_reloc_type_lookup): Adjust `lookup_howto' call
1194 accordingly.
1195 (elf32_i860_info_to_howto_rela): Likewise.
1196 (elf32_i860_relocate_splitn): Likewise.
1197 (elf32_i860_relocate_pc16): Likewise.
1198 (elf32_i860_relocate_pc26): Likewise.
1199 (elf32_i860_relocate_section): Likewise.
1200
707bad1b
MR
12012018-04-04 Maciej W. Rozycki <macro@mips.com>
1202
1203 * elf32-visium.c (visium_info_to_howto_rela): Correct the range
1204 check for `visium_elf_howto_table' table access.
1205
0cc919dc
MR
12062018-04-04 Maciej W. Rozycki <macro@mips.com>
1207
1208 * elf32-iq2000.c (iq2000_info_to_howto_rela): Correct the range
1209 check for `iq2000_elf_howto_table' table access.
1210
f428698e
MR
12112018-04-04 Maciej W. Rozycki <macro@mips.com>
1212
1213 * elf32-frv.c (frv_info_to_howto_rela): Correct the range check
1214 for `elf32_frv_howto_table' table access.
1215
7ed6f92a
MR
12162018-04-04 Maciej W. Rozycki <macro@mips.com>
1217
1218 * elf32-mips.c (mips_elf32_rtype_to_howto): Also return
1219 unsuccessfully for placeholder howtos.
1220 * elf64-mips.c (mips_elf64_rtype_to_howto): Likewise.
1221 * elfn32-mips.c (mips_elf_n32_rtype_to_howto): Likewise.
1222
75def2ab
MR
12232018-03-29 Maciej W. Rozycki <macro@mips.com>
1224
1225 * elf32-mips.c (mips_info_to_howto_rel): Remove the calls to
1226 `_bfd_error_handler' and to set the `bfd_error_bad_value' error.
1227
8b6a949a
MR
12282018-03-28 Maciej W. Rozycki <macro@mips.com>
1229
1230 * elf-hppa.h (elf_hppa_info_to_howto_rel): Remove
1231 ATTRIBUTE_UNUSED from `abfd'.
1232
d81270c3
MR
12332018-03-28 Maciej W. Rozycki <macro@mips.com>
1234
1235 * elf-hppa.h (elf_hppa_info_to_howto_rel): Correct
1236 `_bfd_error_handler' call formatting.
1237
60dceb8d 12382018-03-28 Maciej W. Rozycki <macro@mips.com>
8205a328
MR
1239
1240 * elf32-mips.c (mips_info_to_howto_rel): Call
1241 `mips_elf32_rtype_to_howto' directly rather than via
1242 `->elf_backend_mips_rtype_to_howto'.
1243
e04ef022
RL
12442018-03-28 Renlin Li <renlin.li@arm.com>
1245
1246 PR ld/22970
1247 * elfnn-aarch64.c (IS_AARCH64_TLS_RELOC): Add cases for
1248 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
1249 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
1250 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
1251 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
1252 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
1253 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
1254 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
1255 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
1256 (elfNN_aarch64_final_link_relocate): Support new relocations.
1257 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Support new
1258 relocations.
1259 (_bfd_aarch64_elf_resolve_relocation): Support new relocations.
1260
84f1b9fb
RL
12612018-03-28 Renlin Li <renlin.li@arm.com>
1262
1263 PR ld/22970
1264 * reloc.c: Add BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12
1265 BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12_NC,
1266 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
1267 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
1268 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
1269 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
1270 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
1271 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
1272 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
1273 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
1274 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add table entry for
1275 TLSLE_LDST16_TPREL_LO12,
1276 TLSLE_LDST16_TPREL_LO12_NC,
1277 TLSLE_LDST32_TPREL_LO12,
1278 TLSLE_LDST32_TPREL_LO12_NC,
1279 TLSLE_LDST64_TPREL_LO12,
1280 TLSLE_LDST64_TPREL_LO12_NC,
1281 TLSLE_LDST8_TPREL_LO12,
1282 TLSLE_LDST8_TPREL_LO12_NC.
1283 * bfd-in2.h: Regenerated.
1284 * libbfd.h: Regenerated.
1285
f8745e1c
EB
12862018-03-28 Eric Botcazou <ebotcazou@adacore.com>
1287
1288 PR ld/22972
1289 * elfxx-sparc.c (struct _bfd_sparc_elf_link_hash_entry): Add new flag
1290 has_old_style_got_reloc.
1291 (_bfd_sparc_elf_check_relocs) <GOT relocations>: Set it for old-style
1292 relocations. Fix a couple of long lines.
1293 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: Do not generate
1294 a R_SPARC_NONE for the GOT slot if the symbol is also subject to old-style
1295 GOT relocations.
1296
bf54968b
L
12972018-03-25 H.J. Lu <hongjiu.lu@intel.com>
1298
1299 PR ld/23000
1300 * elf64-x86-64.c (elf_x86_64_finish_dynamic_sections): Add
1301 ENDBR64 to the TLSDESC PLT entry.
1302
0ccf57bd
AM
13032018-03-21 Alan Modra <amodra@gmail.com>
1304
1305 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Trim uninteresting
1306 symbols. Use size_t counts. Delete redundant opd test.
1307
4bad6366
AM
13082018-03-21 Alan Modra <amodra@gmail.com>
1309
1310 * elf32-ppc.c (ppc_elf_tls_optimize): Delete locsyms.
1311
bac3c8c5
AM
13122018-03-21 Alan Modra <amodra@gmail.com>
1313
1314 * elf32-ppc.c (struct ppc_elf_link_hash_entry): Make tls_mask
1315 field unsigned.
1316 (update_local_sym_info): Likewise for local_got_tls_masks.
1317 (ppc_elf_tls_optimize): Likewise for lgot_masks.
1318
6a3858a6
AM
13192018-03-21 Alan Modra <amodra@gmail.com>
1320
1321 * elf64-ppc.c (ppc_size_one_stub): Fix comment typo.
1322 (ppc64_elf_layout_multitoc): Allocate relocs for tprel as we
1323 do in size_dynamic_sections.
1324
675e2809
AM
13252018-03-21 Alan Modra <amodra@gmail.com>
1326
1327 * elf64-ppc.c (ppc64_elf_relocate_section): Don't access rel[1]
1328 without first checking array bounds.
1329 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
1330
416c34d6
L
13312018-03-20 H.J. Lu <hongjiu.lu@intel.com>
1332
1333 PR ld/22983
1334 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Set
1335 non_ir_ref_dynamic if a symbol is made dynamic by --dynamic-list.
1336
315aa1cf
NC
13372018-03-19 Nick Clifton <nickc@redhat.com>
1338
1339 * po/es.po: Updated Spanish translation.
1340
0854d504
MF
13412018-03-15 Max Filippov <jcmvbkbc@gmail.com>
1342
1343 * elf32-xtensa.c (xlate_map_entry): Change types of address
1344 fields from 'unsigned' to 'bfd_vma'.
1345 (xlate_offset_with_removed_text): Use struct xlate_map_entry as
1346 the key argument to bsearch. Allow offsets past the end of a
1347 section, use the last map entry for translation of such offsets.
1348
f9671640
KLC
13492018-03-15 Kuan-Lin Chen <kuanlinchentw@gmail.com>
1350
1351 * elf32-nds32.c (nds32_elf_ex9_build_hash_table): Removed.
1352 Not support the target feature.
1353 (nds32_elf_ex9_itb_base): Likewise.
1354 (nds32_elf_ex9_import_table): Likewise.
1355 (nds32_elf_ex9_finish): Likewise.
1356 (nds32_elf_ex9_reloc_jmp): Likewise.
1357 (nds32_elf_get_insn_with_reg): Likewise.
1358 (nds32_get_local_syms): Likewise.
1359 (nds32_elf_ex9_replace_instruction): Likewise.
1360 (nds32_elf_ifc_calc): Likewise.
1361 (nds32_elf_ifc_finish): Likewise.
1362 (nds32_elf_ifc_replace): Likewise.
1363 (nds32_elf_ifc_reloc): Likewise.
1364
7dda8d3c
AM
13652018-03-14 Alan Modra <amodra@gmail.com>
1366
1367 * elf64-ppc.c (sfpr_define): Adjust for stub_sec size having
1368 sfpr size added before defining alias symbols.
1369 (ppc64_elf_build_stubs): Add stub section padding before
1370 copying sfpr contents and defining save/restore alias symbols.
1371
9e223787
L
13722018-03-14 H.J. Lu <hongjiu.lu@intel.com>
1373
1374 PR ld/20882
1375 * elflink.c (elf_gc_mark_debug_section): Also check the local
1376 debug definition section.
1377
3e33b239
NC
13782018-03-13 Nick Clifton <nickc@redhat.com>
1379
1380 PR 22113
1381 * pei-x86_64.c (pex64_get_unwind_info): Change to a boolean
1382 function. Add an end address parameter. Check access of the data
1383 pointer to make sure that they do not extend beyond the end
1384 address. Return FALSE if any check fails. Add the end address
1385 pointer to the ui structure.
1386 (pex64_xdata_print_uwd_codes): Check accesses of the raw unwind
1387 codes to make sure that they do not extend beyond the end address
1388 pointer. Print an error message and return immediately if any
1389 check fails.
1390
f657f8c4
NC
13912018-03-09 Nick Clifton <nickc@redhat.com>
1392
1393 * elf64-s390.c (elf_s390_relocate_section): Move check for
1394 relocations against non-allocated sections to before the code that
1395 handles ifunc relocations.
1396 * elf32-s390.c (elf_s390_relocate_section): Likewise.
1397 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Treat
1398 relocs against IFUNC symbols in non-allocated sections as relocs
1399 against FUNC symbols.
1400 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
1401
347a8774
L
14022018-03-08 H.J. Lu <hongjiu.lu@intel.com>
1403
1404 PR ld/22929
1405 * elf32-i386.c (elf_i386_relocate_section): Treat relocation
1406 against IFUNC symbol in SHT_NOTE section without SHF_ALLOC as
1407 relocation against FUNC symbol.
1408 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
1409
0c1ded8d
RL
14102018-03-07 Renlin Li <renlin.li@arm.com>
1411
1412 PR ld/20402
1413 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Check absolute
1414 symbol, and don't emit relocation in specific case.
1415
0118219e
AM
14162018-03-07 Alan Modra <amodra@gmail.com>
1417
1418 * elf64-mips.c (mips_elf64_rtype_to_howto): Return NULL on error.
1419 (mips_elf64_slurp_one_reloc_table): Pass on error.
1420
dfb93f11
JC
14212018-03-03 James Cowgill <james.cowgill@mips.com>
1422 Maciej W. Rozycki <macro@mips.com>
1423
1424 PR ld/21900
1425 * elfxx-mips.c (mips_elf_calculate_relocation): Only return
1426 after calling `undefined_symbol' hook if this is an error
1427 condition. Assume the value of 0 for the symbol requested
1428 otherwise.
1429
9a2ebffd
JW
14302018-03-02 Jim Wilson <jimw@sifive.com>
1431
1432 PR 22903
1433 * elfnn-aarch64.c (_bfd_aarch64_resize_stubs): Add 8 bytes for branch
1434 and nop instead of 4.
1435 (elfNN_arch64_build_stubs): Add nop after branch. Increase size by
1436 8 instead of 4.
1437
788af978
JW
14382018-03-01 Jim Wilson <jimw@sifive.com>
1439
1440 PR 22756
1441 * elfnn-riscv.c (riscv_relax_delete_bytes): When adjust st_size, use
1442 else if instead of if.
1443
5224fa03
AM
14442018-03-01 Alan Modra <amodra@gmail.com>
1445
1446 * elf32-ft32.c (ft32_info_to_howto_rela): Correct range test.
1447
116acb2c
AM
14482018-02-28 Alan Modra <amodra@gmail.com>
1449
1450 PR 22887
1451 * aoutx.h (swap_std_reloc_in): Correct r_index bound check.
1452
eef10466
NC
14532018-02-28 Nick Clifton <nickc@redhat.com>
1454
12c96342
NC
1455 PR 22895
1456 PR 22893
1457 * dwarf2.c (read_n_bytes): Replace size parameter with dwarf_block
1458 pointer. Drop unused abfd parameter. Check the size of the block
1459 before initialising the data field. Return the end pointer if the
1460 size is invalid.
1461 (read_attribute_value): Adjust invocations of read_n_bytes.
1462
eef10466
NC
1463 PR 22894
1464 * dwarf1.c (parse_die): Check the length of form blocks before
1465 advancing the data pointer.
1466
0d329c0a
AM
14672018-02-28 Alan Modra <amodra@gmail.com>
1468
1469 PR 22887
1470 * aoutx.h (translate_symbol_table): Print an error message and set
1471 bfd_error on finding an invalid name string offset.
1472
f6aec96d
L
14732018-02-27 H.J. Lu <hongjiu.lu@intel.com>
1474
1475 * config.in: Regenerated.
1476 * configure: Likewise.
1477 * configure.ac: Add --enable-separate-code.
1478 (DEFAULT_LD_Z_SEPARATE_CODE): New AC_DEFINE_UNQUOTED. Default
1479 to 1 for Linux/x86 targets,
1480 * elf64-x86-64.c (ELF_MAXPAGESIZE): Set to 0x1000 if
1481 DEFAULT_LD_Z_SEPARATE_CODE is 1.
1482
f3185997
NC
14832018-02-27 Nick Clifton <nickc@redhat.com>
1484
e8f5af78
NC
1485 * aout-cris.c (swap_ext_reloc_out): Standadize error/warning
1486 message.
1487 * elf-hppa.h (elf_hppa_info_to_howto_rel): Likewise.
1488 * elf32-i386.c (elf_i386_reloc_type_lookup): Likewise.
1489 * elf32-xtensa.c (elf_xtensa_reloc_type_lookup): Likewise.
1490 * elf64-ppc.c (ppc64_elf_reloc_type_lookup): Likewise.
1491 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
1492 * elf64-sh64.c (sh_elf64_info_to_howto): Likewise.
1493 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
1494 * elfxx-sparc.c (_bfd_sparc_elf_reloc_type_lookup): Likewise.
1495 * elfxx-tilegx.c (tilegx_reloc_type_lookup): Likewise.
1496
f3185997
NC
1497 PR 22875
1498 * elf-bfd.h (struct elf_backend_data): Change the return type of
1499 the elf_info_to_howto and elf_info_to_howto_rel function pointers
1500 to bfd_boolean.
1501 * elfcode.h (elf_slurp_reloc_table_from_section): Check the return
1502 value from the info_to_howto function and fail if that function
1503 failed.
1504 * elf32-h8300.c (elf32_h8_relocate_section): Check return value
1505 from the info_to_howto function.
1506 (elf32_h8_relax_section): Likewise.
1507 * elf32-lm32.c (lm32_elf_relocate_section): Likewise.
1508 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
1509 * elf32-score.c (s3_bfd_score_elf_relocate_section): Likewise.
1510 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
1511 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
1512 * elf64-ia64-vms.c (elf64_ia64_relocate_section): Likewise.
1513 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Likewise.
1514 * elf64-x86-64.c (elf_x86_64_tls_transition): Likewise.
1515 * elfnn-ia64.c (elfNN_ia64_relocate_section): Likewise.
1516 * elfnn-riscv.c (riscv_elf_check_relocs): Likewise.
1517 (riscv_elf_relocate_section): Likewise.
1518 * elf-hppa.h (elf_hppa_info_to_howto): Change return type to
1519 bfd_boolean. Issue an error message, set an error value and
1520 return FALSE if the reloc is not recognized.
1521 (elf_hppa_info_to_howto_rel): Likewise.
1522 * elf-m10200.c (mn10200_info_to_howto): Likewise.
1523 * elf-m10300.c (mn10300_info_to_howto): Likewise.
1524 * elf.c (_bfd_elf_no_info_to_howto): Likewise.
1525 * elf32-arc.c (arc_info_to_howto_rel): Likewise.
1526 * elf32-arm.c (elf32_arm_info_to_howto): Likewise.
1527 * elf32-avr.c (avr_info_to_howto_rela): Likewise.
1528 * elf32-bfin.c (bfin_info_to_howto): Likewise.
1529 * elf32-cr16.c (elf_cr16_info_to_howto): Likewise.
1530 * elf32-cr16c.c (elf_cr16c_info_to_howto): Likewise.
1531 * elf32-cris.c (elf_cr16c_info_to_howto_rel)
1532 (cris_info_to_howto_rela): Likewise.
1533 * elf32-crx.c (elf_crx_info_to_howto): Likewise.
1534 * elf32-d10v.c (d10v_info_to_howto_rel): Likewise.
1535 * elf32-d30v.c (d30v_info_to_howto_rel, d30v_info_to_howto_rela):
1536 Likewise.
1537 * elf32-dlx.c (dlx_rtype_to_howto, elf32_dlx_info_to_howto)
1538 (elf32_dlx_info_to_howto_rel): Likewise.
1539 * elf32-epiphany.c (epiphany_info_to_howto_rela): Likewise.
1540 * elf32-fr30.c (fr30_info_to_howto_rela): Likewise.
1541 * elf32-frv.c (frv_info_to_howto_rela)
1542 (frvfdpic_info_to_howto_rel): Likewise.
1543 * elf32-ft32.c (ft32_info_to_howto_rela): Likewise.
1544 * elf32-gen.c (elf_generic_info_to_howto)
1545 (elf_generic_info_to_howto_rel): Likewise.
1546 * elf32-h8300.c (elf32_h8_info_to_howto)
1547 (elf32_h8_info_to_howto_rel): Likewise.
1548 * elf32-i370.c (i370_elf_info_to_howto): Likewise.
1549 * elf32-i386.c (elf_i386_reloc_type_lookup)
1550 (elf_i386_rtype_to_howto, elf_i386_info_to_howto_rel): Likewise.
1551 * elf32-i860.c (lookup_howto, elf32_i860_info_to_howto_rela):
1552 Likewise.
1553 * elf32-i960.c (elf32_i960_info_to_howto_rel): Likewise.
1554 * elf32-ip2k.c (ip2k_info_to_howto_rela): Likewise.
1555 * elf32-iq2000.c (iq2000_info_to_howto_rela): Likewise.
1556 * elf32-lm32.c (lm32_info_to_howto_rela): Likewise.
1557 * elf32-m32c.c (m32c_info_to_howto_rela): Likewise.
1558 * elf32-m32r.c (m32r_info_to_howto_rel, m32r_info_to_howto):
1559 Likewise.
1560 * elf32-m68hc11.c (m68hc11_info_to_howto_rel): Likewise.
1561 * elf32-m68hc12.c (m68hc11_info_to_howto_rel): Likewise.
1562 * elf32-m68k.c (rtype_to_howto): Likewise.
1563 * elf32-mcore.c (mcore_elf_info_to_howto): Likewise.
1564 * elf32-mep.c (mep_info_to_howto_rela): Likewise.
1565 * elf32-metag.c (metag_info_to_howto_rela): Likewise.
1566 * elf32-microblaze.c (microblaze_elf_info_to_howto): Likewise.
1567 * elf32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
1568 Likewise.
1569 * elf32-moxie.c (moxie_info_to_howto_rela): Likewise.
1570 * elf32-msp430.c (msp430_info_to_howto_rela): Likewise.
1571 * elf32-mt.c (mt_info_to_howto_rela): Likewise.
1572 * elf32-nds32.c (nds32_info_to_howto_rel, nds32_info_to_howto):
1573 Likewise.
1574 * elf32-nios2.c (nios2_elf32_info_to_howto): Likewise.
1575 * elf32-or1k.c (or1k_info_to_howto_rela): Likewise.
1576 * elf32-pj.c (pj_elf_info_to_howto): Likewise.
1577 * elf32-ppc.c (ppc_elf_info_to_howto): Likewise.
1578 * elf32-pru.c (pru_elf32_info_to_howto): Likewise.
1579 * elf32-rl78.c (rl78_info_to_howto_rela): Likewise.
1580 * elf32-rx.c (rx_info_to_howto_rela): Likewise.
1581 * elf32-s390.c (elf_s390_info_to_howto): Likewise.
1582 * elf32-score.c (s3_bfd_score_info_to_howto)
1583 (_bfd_score_info_to_howto): Likewise.
1584 * elf32-score7.c (s7_bfd_score_info_to_howto): Likewise.
1585 * elf32-sh.c (sh_elf_info_to_howto): Likewise.
1586 * elf32-spu.c (spu_elf_info_to_howto): Likewise.
1587 * elf32-tic6x.c (elf32_tic6x_info_to_howto)
1588 (elf32_tic6x_info_to_howto_rel): Likewise.
1589 * elf32-tilepro.c (tilepro_info_to_howto_rela): Likewise.
1590 * elf32-v850.c (v850_elf_info_to_howto_rel)
1591 (v850_elf_info_to_howto_rela, v800_elf_info_to_howto): Likewise.
1592 * elf32-vax.c (rtype_to_howto): Likewise.
1593 * elf32-visium.c (visium_info_to_howto_rela): Likewise.
1594 * elf32-wasm32.c (elf32_wasm32_rtype_to_howto)
1595 (elf32_wasm32_info_to_howto_rela): Likewise.
1596 * elf32-xc16x.c (elf32_xc16x_info_to_howto): Likewise.
1597 * elf32-xgate.c (xgate_info_to_howto_rel): Likewise.
1598 * elf32-xstormy16.c (xstormy16_info_to_howto_rela): Likewise.
1599 * elf32-xtensa.c (elf_xtensa_info_to_howto_rela): Likewise.
1600 * elf64-alpha.c (elf64_alpha_info_to_howto): Likewise.
1601 * elf64-gen.c (elf_generic_info_to_howto)
1602 (elf_generic_info_to_howto_rel): Likewise.
1603 * elf64-ia64-vms.c (elf64_ia64_info_to_howto): Likewise.
1604 * elf64-mips.c (mips_elf64_info_to_howto_rela): Likewise.
1605 * elf64-mmix.c (mmix_info_to_howto_rela): Likewise.
1606 * elf64-ppc.c (ppc64_elf_info_to_howto): Likewise.
1607 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
1608 * elf64-sh64.c (elf_s390_info_to_howto, sh_elf64_info_to_howto):
1609 Likewise.
1610 * elf64-x86-64.c (elf_x86_64_info_to_howto): Likewise.
1611 * elfn32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
1612 Likewise.
1613 * elfnn-aarch64.c (elfNN_aarch64_info_to_howto): Likewise.
1614 * elfnn-ia64.c (elfNN_ia64_info_to_howto): Likewise.
1615 * elfnn-riscv.c (riscv_info_to_howto_rela): Likewise.
1616 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
1617 * elfxx-sparc.c (_bfd_sparc_elf_info_to_howto): Likewise.
1618 * elfxx-tilegx.c (tilegx_info_to_howto_rela): Likewise.
1619 * elf32-score.h (s7_bfd_score_info_to_howto): Update prototype.
1620 * elfxx-sparc.h (_bfd_sparc_elf_info_to_howto): Update prototype.
1621 * elfxx-tilegx.h (tilegx_info_to_howto_rela): Update prototype.
1622 * elfxx-target.h (elf_info_to_howto, elf_info_to_howto_rel):
1623 Default to NULL.
1624
1f4bace8
JW
16252018-02-26 Jim Wilson <jimw@sifive.com>
1626 Stephan Schreiber <info@fs-driver.org>
1627
1628 PR 15904
1629 * elfnn-ia64.c (elfNN_ia64_relax_section): After ia64_elf_relax_brl
1630 call, set changed_contents and changed_relocs. Likewise after
1631 successful ia64_elf_relax_br call.
1632
6838f2be
AM
16332018-02-26 Alan Modra <amodra@gmail.com>
1634
1635 * elf.c (assign_file_positions_except_relocs): Don't segfault
1636 when actual number of phdrs is less than allocated. Delete
1637 outdated comment. Formatting.
1638
38f14ab8
AM
16392018-02-26 Alan Modra <amodra@gmail.com>
1640
1641 * elf-m10300.c, * elf-s390-common.c, * elf32-arc.c, * elf32-cris.c,
1642 * elf32-dlx.c, * elf32-frv.c, * elf32-i370.c, * elf32-lm32.c,
1643 * elf32-m32r.c, * elf32-m68hc1x.c, * elf32-m68k.c,
1644 * elf32-microblaze.c, * elf32-msp430.c, * elf32-nds32.c,
1645 * elf32-nios2.c, * elf32-or1k.c, * elf32-rl78.c, * elf32-rx.c,
1646 * elf32-score.c, * elf32-score7.c, * elf32-sh-symbian.c,
1647 * elf32-sh.c, * elf32-spu.c, * elf32-v850.c, * elf32-xtensa.c,
1648 * elf64-alpha.c, * elf64-ia64-vms.c, * elf64-mmix.c,
1649 * elf64-sh64.c, * elf64-sparc.c, * elfnn-ia64.c, * elfxx-tilegx.c,
1650 * mmo.c, * osf-core.c, * srec.c, * vms-alpha.c: Standardize
1651 error/warning messages.
1652
6e05870c
AM
16532018-02-26 Alan Modra <amodra@gmail.com>
1654
1655 * archive.c, * bfd.c, * linker.c, * reloc.c, * stabs.c,
1656 * syms.c: Standardize error/warning messages.
1657
59d08d6c
AM
16582018-02-26 Alan Modra <amodra@gmail.com>
1659
1660 * aout-adobe.c, * aout-cris.c, * i386linux.c, * m68klinux.c,
1661 * sparclinux.c, * coff-alpha.c, * coff-arm.c, * coff-mcore.c,
1662 * coffcode.h, * coffgen.c, * cofflink.c, * ecoff.c, * pe-mips.c,
1663 * peXXigen.c, * peicode.h: Standardize error/warning messages.
1664
90b6238f
AM
16652018-02-26 Alan Modra <amodra@gmail.com>
1666
1667 * elf32-arm.c, * elfnn-aarch64.c: Standardize error/warning messages.
1668
2c1c9679
AM
16692018-02-26 Alan Modra <amodra@gmail.com>
1670
1671 * elfxx-mips.c: Standardize error/warning messages.
1672
9793eb77
AM
16732018-02-26 Alan Modra <amodra@gmail.com>
1674
1675 * dwarf2.c, * elf-attrs.c, * elf-eh-frame.c, * elf.c, * elf32-gen.c,
1676 * elflink.c: Standardize error/warning messages. Replace use of
1677 linker callback einfo with _bfd_error_handler when possible.
1678
0aa13fee
AM
16792018-02-26 Alan Modra <amodra@gmail.com>
1680
1681 * aoutx.h, * coff-alpha.c, * coff-i860.c, * coff-m68k.c,
1682 * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c, * coff-sh.c,
1683 * coff-tic4x.c, * coff-tic54x.c, * coff-tic80.c, * coff-w65.c,
1684 * elf-bfd.h, * elf-m10300.c, * elf.c, * elf32-avr.c, * elf32-bfin.c,
1685 * elf32-cr16.c, * elf32-cr16c.c, * elf32-cris.c, * elf32-crx.c,
1686 * elf32-d10v.c, * elf32-d30v.c, * elf32-dlx.c, * elf32-epiphany.c,
1687 * elf32-fr30.c, * elf32-frv.c, * elf32-i370.c, * elf32-i386.c,
1688 * elf32-i960.c, * elf32-ip2k.c, * elf32-iq2000.c, * elf32-lm32.c,
1689 * elf32-m32c.c, * elf32-m32r.c, * elf32-m68hc11.c, * elf32-m68hc12.c,
1690 * elf32-m68k.c, * elf32-mcore.c, * elf32-mep.c, * elf32-metag.c,
1691 * elf32-microblaze.c, * elf32-mips.c, * elf32-moxie.c,
1692 * elf32-msp430.c, * elf32-mt.c, * elf32-nds32.c, * elf32-or1k.c,
1693 * elf32-pj.c, * elf32-ppc.c, * elf32-rl78.c, * elf32-rx.c,
1694 * elf32-s390.c, * elf32-sh.c, * elf32-spu.c, * elf32-tic6x.c,
1695 * elf32-v850.c, * elf32-vax.c, * elf32-visium.c, * elf32-wasm32.c,
1696 * elf32-xgate.c, * elf32-xtensa.c, * elf64-alpha.c,
1697 * elf64-ia64-vms.c, * elf64-mips.c, * elf64-mmix.c,
1698 * elf64-ppc.c, * elf64-s390.c, * elf64-sparc.c, * elf64-x86-64.c,
1699 * elfn32-mips.c, * elfnn-aarch64.c, * elfnn-ia64.c,
1700 * elfnn-riscv.c, * elfxx-mips.c, * elfxx-riscv.c, * elfxx-riscv.h,
1701 * elfxx-sparc.c, * elfxx-sparc.h, * reloc.c: Standardize
1702 unrecognized/unsupported reloc message.
1703
cf97bcb0
AM
17042018-02-26 Alan Modra <amodra@gmail.com>
1705
1706 * elf32-ppc.c: Standardize error/warning messages. Use
1707 _bfd_error_handler rather than einfo when einfo features not used.
1708 * elf64-ppc.c: Likewise.
1709
01f7e10c
AM
17102018-02-23 Alan Modra <amodra@gmail.com>
1711
1712 PR 22881
1713 * elf.c (assign_file_positions_for_non_load_sections): Remove RELRO
1714 segment if no matching LOAD segment.
1715
e859f655
KLC
17162018-02-23 Kuan-Lin Chen <kuanlinchentw@gmail.com>
1717
1718 * elf32-nds32.h: Define mask for ict_model.
1719
6e8d06db
JD
17202018-02-20 Jason Duerstock <jason.duerstock@gmail.com>
1721
1722 * elfnn-ia64.c (elf_backend_can_gc_sections): Enable.
1723
b248d650
MR
17242018-02-19 Maciej W. Rozycki <macro@mips.com>
1725
1726 Revert
1727 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
1728
1729 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
1730 .reginfo section has wrong size.
1731
6798f8bf
MR
17322018-02-19 Maciej W. Rozycki <macro@mips.com>
1733
1734 * elfxx-mips.c (_bfd_mips_elf_always_size_sections): Set
1735 SEC_FIXED_SIZE and SEC_HAS_CONTENTS flags for `.reginfo' and
1736 `.MIPS.abiflags' sections.
1737 (_bfd_mips_elf_final_link): Avoid reading beyond `.reginfo'
1738 section's end.
1739
8772de11
MR
17402018-02-19 Maciej W. Rozycki <macro@mips.com>
1741
1742 * section.c (SEC_FIXED_SIZE): New macro.
1743 * bfd-in2.h: Regenerate.
1744
4f7fd351
MR
17452018-02-19 Maciej W. Rozycki <macro@mips.com>
1746
1747 * section.c (SEC_HAS_GOT_REF): Remove macro.
1748 * bfd-in2.h: Regenerate.
1749
f2b740ac
AM
17502018-02-19 Alan Modra <amodra@gmail.com>
1751
1752 * elf-attrs.c (_bfd_elf_parse_attributes): Correct _bfd_error_handler
1753 arguments.
1754 * elfxx-mips.c (_bfd_mips_elf_final_link): Likewise.
1755 * elfnn-riscv.c (_bfd_riscv_relax_align): Likewise.
1756 (_bfd_riscv_relax_pc): Likewise and fix typos.
1757 * libbfd-in.h (_bfd_error_handler): Add attribute printf.
1758 * libbfd.h: Regenerate.
1759
8979927a
AM
17602018-02-19 Alan Modra <amodra@gmail.com>
1761
1762 * dwarf2.c (read_section): Don't use 'll' format modifier.
1763 (find_abstract_instance): Likewise.
1764 * elfcore.h (elf_core_file_p): Likewise.
1765
2dcf00ce
AM
17662018-02-19 Alan Modra <amodra@gmail.com>
1767
1768 * bfd-in.h: Include inttypes.h or if not available define
1769 PRId64, PRIu64 and PRIx64.
1770 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Remove support for L
1771 modifier to print bfd_vma.
1772 * coff-arm.c, * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c,
1773 * coff-sh.c, * coff-tic80.c, * coffcode.h, * coffgen.c, * cofflink.c,
1774 * compress.c, * dwarf2.c, * elf-m10300.c, * elf.c, * elf32-arc.c,
1775 * elf32-arm.c, * elf32-bfin.c, * elf32-cris.c, * elf32-hppa.c,
1776 * elf32-i386.c, * elf32-ip2k.c, * elf32-lm32.c, * elf32-m32r.c,
1777 * elf32-m68k.c, * elf32-metag.c, * elf32-nds32.c, * elf32-nios2.c,
1778 * elf32-ppc.c, * elf32-rx.c, * elf32-s390.c, * elf32-score.c,
1779 * elf32-score7.c, * elf32-sh.c, * elf32-sh64.c, * elf32-spu.c,
1780 * elf32-tic6x.c, * elf32-tilepro.c, * elf32-v850.c, * elf32-vax.c,
1781 * elf32-xtensa.c, * elf64-alpha.c, * elf64-hppa.c, * elf64-ia64-vms.c,
1782 * elf64-mmix.c, * elf64-s390.c, * elf64-sh64.c, * elf64-x86-64.c,
1783 * elfcode.h, * elfcore.h, * elflink.c, * elfnn-aarch64.c,
1784 * elfnn-ia64.c, * elfnn-riscv.c, * elfxx-mips.c, * elfxx-sparc.c,
1785 * elfxx-tilegx.c, * ieee.c, * ihex.c, * mach-o.c, * merge.c, * mmo.c,
1786 * peXXigen.c, * xcofflink.c: Replace use of Lx modifier with PRIx64,
1787 and cast input to uint64_t, and similarly for Ld and Lu.
1788 * bfd-in2.h: Regenerate.
1789
c1c8c1ef
AM
17902018-02-19 Alan Modra <amodra@gmail.com>
1791
1792 * elf32-arm.c, * elf32-hppa.c, * elf32-lm32.c, * elf32-m32r.c,
1793 * elf32-metag.c, * elf32-nds32.c, * elf32-or1k.c, * elf32-ppc.c,
1794 * elf32-s390.c, * elf32-sh.c, * elf32-tic6x.c, * elf32-tilepro.c,
1795 * elf64-ppc.c, * elf64-s390.c, * elflink.c, * elfnn-aarch64.c,
1796 * elfnn-riscv.c, * elfxx-sparc.c, * elfxx-tilegx.c, * elfxx-x86.c,
1797 * reloc.c: Replace use of %R and %T in format strings passed to
1798 einfo and friends by %pR and %pT.
1799
871b3ab2
AM
18002018-02-19 Alan Modra <amodra@gmail.com>
1801
1802 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Handle %pA and %pB in place
1803 of %A and %B.
1804 * aout-adobe.c: Update all messages using %A and %B.
1805 * aout-cris.c: Likewise.
1806 * aoutx.h: Likewise.
1807 * archive.c: Likewise.
1808 * binary.c: Likewise.
1809 * cache.c: Likewise.
1810 * coff-alpha.c: Likewise.
1811 * coff-arm.c: Likewise.
1812 * coff-i860.c: Likewise.
1813 * coff-mcore.c: Likewise.
1814 * coff-ppc.c: Likewise.
1815 * coff-rs6000.c: Likewise.
1816 * coff-sh.c: Likewise.
1817 * coff-tic4x.c: Likewise.
1818 * coff-tic54x.c: Likewise.
1819 * coff-tic80.c: Likewise.
1820 * coff64-rs6000.c: Likewise.
1821 * coffcode.h: Likewise.
1822 * coffgen.c: Likewise.
1823 * cofflink.c: Likewise.
1824 * coffswap.h: Likewise.
1825 * compress.c: Likewise.
1826 * cpu-arm.c: Likewise.
1827 * ecoff.c: Likewise.
1828 * elf-attrs.c: Likewise.
1829 * elf-eh-frame.c: Likewise.
1830 * elf-ifunc.c: Likewise.
1831 * elf-m10300.c: Likewise.
1832 * elf-properties.c: Likewise.
1833 * elf-s390-common.c: Likewise.
1834 * elf.c: Likewise.
1835 * elf32-arc.c: Likewise.
1836 * elf32-arm.c: Likewise.
1837 * elf32-avr.c: Likewise.
1838 * elf32-bfin.c: Likewise.
1839 * elf32-cr16.c: Likewise.
1840 * elf32-cr16c.c: Likewise.
1841 * elf32-cris.c: Likewise.
1842 * elf32-crx.c: Likewise.
1843 * elf32-d10v.c: Likewise.
1844 * elf32-d30v.c: Likewise.
1845 * elf32-epiphany.c: Likewise.
1846 * elf32-fr30.c: Likewise.
1847 * elf32-frv.c: Likewise.
1848 * elf32-gen.c: Likewise.
1849 * elf32-hppa.c: Likewise.
1850 * elf32-i370.c: Likewise.
1851 * elf32-i386.c: Likewise.
1852 * elf32-i960.c: Likewise.
1853 * elf32-ip2k.c: Likewise.
1854 * elf32-iq2000.c: Likewise.
1855 * elf32-lm32.c: Likewise.
1856 * elf32-m32c.c: Likewise.
1857 * elf32-m32r.c: Likewise.
1858 * elf32-m68hc11.c: Likewise.
1859 * elf32-m68hc12.c: Likewise.
1860 * elf32-m68hc1x.c: Likewise.
1861 * elf32-m68k.c: Likewise.
1862 * elf32-mcore.c: Likewise.
1863 * elf32-mep.c: Likewise.
1864 * elf32-metag.c: Likewise.
1865 * elf32-microblaze.c: Likewise.
1866 * elf32-moxie.c: Likewise.
1867 * elf32-msp430.c: Likewise.
1868 * elf32-mt.c: Likewise.
1869 * elf32-nds32.c: Likewise.
1870 * elf32-nios2.c: Likewise.
1871 * elf32-or1k.c: Likewise.
1872 * elf32-pj.c: Likewise.
1873 * elf32-ppc.c: Likewise.
1874 * elf32-rl78.c: Likewise.
1875 * elf32-rx.c: Likewise.
1876 * elf32-s390.c: Likewise.
1877 * elf32-score.c: Likewise.
1878 * elf32-score7.c: Likewise.
1879 * elf32-sh-symbian.c: Likewise.
1880 * elf32-sh.c: Likewise.
1881 * elf32-sh64.c: Likewise.
1882 * elf32-sparc.c: Likewise.
1883 * elf32-spu.c: Likewise.
1884 * elf32-tic6x.c: Likewise.
1885 * elf32-tilepro.c: Likewise.
1886 * elf32-v850.c: Likewise.
1887 * elf32-vax.c: Likewise.
1888 * elf32-visium.c: Likewise.
1889 * elf32-wasm32.c: Likewise.
1890 * elf32-xgate.c: Likewise.
1891 * elf32-xtensa.c: Likewise.
1892 * elf64-alpha.c: Likewise.
1893 * elf64-gen.c: Likewise.
1894 * elf64-hppa.c: Likewise.
1895 * elf64-ia64-vms.c: Likewise.
1896 * elf64-mmix.c: Likewise.
1897 * elf64-ppc.c: Likewise.
1898 * elf64-s390.c: Likewise.
1899 * elf64-sh64.c: Likewise.
1900 * elf64-sparc.c: Likewise.
1901 * elf64-x86-64.c: Likewise.
1902 * elfcode.h: Likewise.
1903 * elfcore.h: Likewise.
1904 * elflink.c: Likewise.
1905 * elfnn-aarch64.c: Likewise.
1906 * elfnn-ia64.c: Likewise.
1907 * elfnn-riscv.c: Likewise.
1908 * elfxx-mips.c: Likewise.
1909 * elfxx-sparc.c: Likewise.
1910 * elfxx-tilegx.c: Likewise.
1911 * elfxx-x86.c: Likewise.
1912 * hpux-core.c: Likewise.
1913 * ieee.c: Likewise.
1914 * ihex.c: Likewise.
1915 * libbfd.c: Likewise.
1916 * linker.c: Likewise.
1917 * mach-o.c: Likewise.
1918 * merge.c: Likewise.
1919 * mmo.c: Likewise.
1920 * oasys.c: Likewise.
1921 * pdp11.c: Likewise.
1922 * pe-mips.c: Likewise.
1923 * peXXigen.c: Likewise.
1924 * peicode.h: Likewise.
1925 * reloc.c: Likewise.
1926 * rs6000-core.c: Likewise.
1927 * srec.c: Likewise.
1928 * stabs.c: Likewise.
1929 * vms-alpha.c: Likewise.
1930 * xcofflink.c: Likewise.
1931
dbc88fc1
AM
19322018-02-19 Alan Modra <amodra@gmail.com>
1933
1934 PR 22845
1935 * elf.c (IS_TBSS): Define.
1936 (_bfd_elf_map_sections_to_segments): Use IS_TBSS.
1937 (assign_file_positions_for_non_load_sections): Revert last change.
1938 Properly calculate load segment limits to compare against relro limits.
1939
325ba6fb
AM
19402018-02-17 Alan Modra <amodra@gmail.com>
1941
1942 PR 22845
1943 * elf.c (assign_file_positions_for_non_load_sections): Ignore
1944 degenerate zero size PT_LOAD segments when finding one overlapping
1945 the PT_GNU_RELRO segment.
1946
d00dd7dc
AM
19472018-02-16 Alan Modra <amodra@gmail.com>
1948
1949 * libbfd.c (_bfd_bool_bfd_false_error): Rename from bfd_false.
1950 (_bfd_bool_bfd_true): Rename from bfd_true.
1951 (_bfd_ptr_bfd_null_error): Rename from bfd_nullvoidptr.
1952 (_bfd_int_bfd_0): Rename from bfd_0.
1953 (_bfd_uint_bfd_0): Rename from bfd_0u.
1954 (_bfd_long_bfd_0): Rename from bfd_0l.
1955 (_bfd_long_bfd_n1_error): Rename from _bfd_n1.
1956 (_bfd_void_bfd): Rename from bfd_void.
1957 (_bfd_bool_bfd_false, _bfd_bool_bfd_asymbol_false),
1958 (_bfd_bool_bfd_link_false_error),
1959 (_bfd_bool_bfd_link_true, _bfd_bool_bfd_bfd_true),
1960 (_bfd_bool_bfd_uint_true, _bfd_bool_bfd_ptr_true),
1961 (_bfd_bool_bfd_asection_bfd_asection_true),
1962 (_bfd_bool_bfd_asymbol_bfd_asymbol_true),
1963 (_bfd_void_bfd_link, _bfd_void_bfd_asection): New functions.
1964 * archive.c (_bfd_noarchive_get_elt_at_index),
1965 (_bfd_noarchive_openr_next_archived_file),
1966 (_bfd_noarchive_construct_extended_name_table),
1967 (_bfd_noarchive_write_ar_hdr, _bfd_noarchive_truncate_arname),
1968 (_bfd_noarchive_write_armap): New functions.
1969 * archures.c (_bfd_nowrite_set_arch_mach): New function.
1970 * coff-alpha.c (alpha_ecoff_swap_coff_aux_in),
1971 (alpha_ecoff_swap_coff_sym_in, alpha_ecoff_swap_coff_lineno_in),
1972 (alpha_ecoff_swap_coff_aux_out, alpha_ecoff_swap_coff_sym_out),
1973 (alpha_ecoff_swap_coff_lineno_out),
1974 (alpha_ecoff_swap_coff_reloc_out): New functions.
1975 * coff-mips.c (mips_ecoff_swap_coff_aux_in),
1976 (mips_ecoff_swap_coff_sym_in, mips_ecoff_swap_coff_lineno_in),
1977 (mips_ecoff_swap_coff_aux_out, mips_ecoff_swap_coff_sym_out),
1978 (mips_ecoff_swap_coff_lineno_out),
1979 (mips_ecoff_swap_coff_reloc_out): New functions.
1980 * coffcode.h (coff_set_alignment_hook): Replace define with
1981 new function.
1982 (symname_in_debug_hook): Likewise.
1983 * ecoff.c (_bfd_ecoff_set_alignment_hook): New function.
1984 * elfxx-target.h (elf_backend_allow_non_load_phdr): Default to 0.
1985 * elf.c (assign_file_positions_except_relocs): Test
1986 elf_backend_allow_non_load_phdr for NULL.
1987 * elflink.c (_bfd_elf_omit_section_dynsym_default): Rename from
1988 _bfd_elf_link_omit_section_dynsym. Update uses.
1989 (_bfd_elf_omit_section_dynsym_all): New function.
1990 * elf-bfd.h (_bfd_elf_link_omit_section_dynsym): Delete.
1991 (_bfd_elf_omit_section_dynsym_default): Declare.
1992 (_bfd_elf_omit_section_dynsym_all): Declare.
1993 * linker.c (_bfd_nolink_sizeof_headers, _bfd_nolink_bfd_relax_section),
1994 (_bfd_nolink_bfd_get_relocated_section_contents),
1995 (_bfd_nolink_bfd_lookup_section_flags),
1996 (_bfd_nolink_bfd_is_group_section, _bfd_nolink_bfd_discard_group),
1997 (_bfd_nolink_bfd_link_hash_table_create),
1998 (_bfd_nolink_bfd_link_just_syms),
1999 (_bfd_nolink_bfd_copy_link_hash_symbol_type),
2000 (_bfd_nolink_bfd_link_split_section),
2001 (_bfd_nolink_section_already_linked),
2002 (_bfd_nolink_bfd_define_common_symbol),
2003 (_bfd_nolink_bfd_define_start_stop): New functions.
2004 * reloc.c (_bfd_norelocs_bfd_reloc_type_lookup),
2005 (_bfd_norelocs_bfd_reloc_name_lookup),
2006 (_bfd_nodynamic_canonicalize_dynamic_reloc): New functions.
2007 * section.c (_bfd_nowrite_set_section_contents): New function.
2008 * syms.c (_bfd_nosymbols_canonicalize_symtab),
2009 (_bfd_nosymbols_print_symbol, _bfd_nosymbols_get_symbol_info),
2010 (_bfd_nosymbols_get_symbol_version_string),
2011 (_bfd_nosymbols_bfd_is_local_label_name),
2012 (_bfd_nosymbols_get_lineno, _bfd_nosymbols_find_nearest_line),
2013 (_bfd_nosymbols_find_line, _bfd_nosymbols_find_inliner_info),
2014 (_bfd_nosymbols_bfd_make_debug_symbol),
2015 ( _bfd_nosymbols_read_minisymbols),
2016 ( _bfd_nosymbols_minisymbol_to_symbol),
2017 (_bfd_nodynamic_get_synthetic_symtab): New functions.
2018 * libbfd-in.h: Declare new functions. Update existing defines,
2019 removing casts.
2020 * aix386-core.c: Update to use new hooks. Formatting.
2021 * aout-adobe.c: Likewise.
2022 * aout-arm.c: Likewise.
2023 * aout-target.h: Likewise.
2024 * aout-tic30.c: Likewise.
2025 * aoutf1.h: Likewise.
2026 * binary.c: Likewise.
2027 * bout.c: Likewise.
2028 * cisco-core.c: Likewise.
2029 * coff-alpha.c: Likewise.
2030 * coff-i386.c: Likewise.
2031 * coff-i860.c: Likewise.
2032 * coff-i960.c: Likewise.
2033 * coff-ia64.c: Likewise.
2034 * coff-mips.c: Likewise.
2035 * coff-ppc.c: Likewise.
2036 * coff-rs6000.c: Likewise.
2037 * coff-sh.c: Likewise.
2038 * coff-tic30.c: Likewise.
2039 * coff-tic54x.c: Likewise.
2040 * coff-x86_64.c: Likewise.
2041 * coff64-rs6000.c: Likewise.
2042 * coffcode.h: Likewise.
2043 * elf-m10300.c: Likewise.
2044 * elf32-cr16.c: Likewise.
2045 * elf32-lm32.c: Likewise.
2046 * elf32-m32r.c: Likewise.
2047 * elf32-metag.c: Likewise.
2048 * elf32-score.c: Likewise.
2049 * elf32-score7.c: Likewise.
2050 * elf32-tilepro.c: Likewise.
2051 * elf32-xstormy16.c: Likewise.
2052 * elf32-xtensa.c: Likewise.
2053 * elf64-alpha.c: Likewise.
2054 * elf64-hppa.c: Likewise.
2055 * elf64-ia64-vms.c: Likewise.
2056 * elf64-mmix.c: Likewise.
2057 * elf64-sh64.c: Likewise.
2058 * elfnn-ia64.c: Likewise.
2059 * elfxx-sparc.c: Likewise.
2060 * elfxx-target.h: Likewise.
2061 * elfxx-tilegx.c: Likewise.
2062 * elfxx-x86.h: Likewise.
2063 * hp300hpux.c: Likewise.
2064 * hppabsd-core.c: Likewise.
2065 * hpux-core.c: Likewise.
2066 * i386msdos.c: Likewise.
2067 * i386os9k.c: Likewise.
2068 * ieee.c: Likewise.
2069 * ihex.c: Likewise.
2070 * irix-core.c: Likewise.
2071 * libaout.h: Likewise.
2072 * libecoff.h: Likewise.
2073 * mach-o-target.c: Likewise.
2074 * mach-o.c: Likewise.
2075 * mipsbsd.c: Likewise.
2076 * mmo.c: Likewise.
2077 * netbsd-core.c: Likewise.
2078 * nlm-target.h: Likewise.
2079 * oasys.c: Likewise.
2080 * osf-core.c: Likewise.
2081 * pdp11.c: Likewise.
2082 * pe-mips.c: Likewise.
2083 * pe-x86_64.c: Likewise.
2084 * pef.c: Likewise.
2085 * plugin.c: Likewise.
2086 * ppcboot.c: Likewise.
2087 * ptrace-core.c: Likewise.
2088 * sco5-core.c: Likewise.
2089 * som.c: Likewise.
2090 * sparclynx.c: Likewise.
2091 * srec.c: Likewise.
2092 * tekhex.c: Likewise.
2093 * trad-core.c: Likewise.
2094 * verilog.c: Likewise.
2095 * versados.c: Likewise.
2096 * vms-alpha.c: Likewise.
2097 * vms-lib.c: Likewise.
2098 * wasm-module.c: Likewise.
2099 * xsym.c: Likewise.
2100 * libbfd.h: Regenerate.
2101
2a0d9853
JW
21022018-02-15 Jim Wilson <jimw@sifive.com>
2103
09ca4b9d
JW
2104 * elfnn-riscv.c (_bfd_riscv_relax_section): Ifdef out check to ignore
2105 symbols whose section address is zero.
2106
2a0d9853
JW
2107 * elfnn-riscv.c (riscv_elf_relocate_section): Use bfd_reloc_dangerous
2108 when pcrel_lo reloc has an addend. Use reloc_dangerous callback for
2109 bfd_reloc_dangerous. Use einfo instead of warning callback for errors.
2110 Add %X%P to error messages.
2111
e513bd38
EB
21122018-02-15 Eric Botcazou <ebotcazou@adacore.com>
2113
2114 PR ld/22832
2115 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
2116 Pass FALSE instead of TRUE as 'create' argument to bfd_link_hash_lookup
2117 and assert that the result of the call is not NULL.
2118
12ef3f5a
NC
21192018-02-14 Nick Clifton <nickc@redhat.com>
2120
2121 PR 22823
2122 Revert previous delta. Add extra casts to avoid compile time
2123 warnings instead.
2124 * libbfd-in.h (_bfd_generic_bfd_copy_private_bfd_data): Add extra
2125 cast to avoid warning from gcc v8 compiler.
2126 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
2127 (_bfd_generic_bfd_set_private_flags): Likewise.
2128 (_bfd_generic_bfd_copy_private_section_data): Likewise.
2129 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
2130 (_bfd_generic_bfd_copy_private_header_data): Likewise.
2131 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
2132 (_bfd_noarchive_construct_extended_name_table): Likewise.
2133 (_bfd_noarchive_truncate_arname): Likewise.
2134 (_bfd_noarchive_write_ar_hdr): Likewise.
2135 (_bfd_noarchive_get_elt_at_index): Likewise.
2136 (_bfd_nosymbols_canonicalize_symtab): Likewise.
2137 (_bfd_nosymbols_print_symbol): Likewise.
2138 (_bfd_nosymbols_get_symbol_info): Likewise.
2139 (_bfd_nosymbols_get_symbol_version_string): Likewise.
2140 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
2141 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
2142 (_bfd_nosymbols_get_lineno): Likewise.
2143 (_bfd_nosymbols_find_nearest_line): Likewise.
2144 (_bfd_nosymbols_find_line): Likewise.
2145 (_bfd_nosymbols_find_inliner_info): Likewise.
2146 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
2147 (_bfd_nosymbols_read_minisymbols): Likewise.
2148 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
2149 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
2150 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
2151 (_bfd_nowrite_set_arch_mach): Likewise.
2152 (_bfd_nowrite_set_section_contents): Likewise.
2153 (_bfd_nolink_sizeof_headers): Likewise.
2154 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
2155 (_bfd_nolink_bfd_relax_section): Likewise.
2156 (_bfd_nolink_bfd_gc_sections): Likewise.
2157 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
2158 (_bfd_nolink_bfd_merge_sections): Likewise.
2159 (_bfd_nolink_bfd_is_group_section): Likewise.
2160 (_bfd_nolink_bfd_discard_group): Likewise.
2161 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
2162 (_bfd_nolink_bfd_link_add_symbols): Likewise.
2163 (_bfd_nolink_bfd_link_just_syms): Likewise.
2164 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
2165 (_bfd_nolink_bfd_final_link): Likewise.
2166 (_bfd_nolink_bfd_link_split_section): Likewise.
2167 (_bfd_nolink_section_already_linked): Likewise.
2168 (_bfd_nolink_bfd_define_common_symbol): Likewise.
2169 (_bfd_nolink_bfd_define_start_stop): Likewise.
2170 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
2171 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
2172 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
2173 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
2174 * libbfd.c (bfd_false_any): Delete.
2175 (bfd_true_any, bfd_nullvoidptr_any, bfd_0_any): Delete.
2176 (bfd_0u_any, bfd_0l_any, _bfd_n1_any, bfd_void_any): Delete.
2177 * libbfd.h (extern): Regenerate
2178 * aout-target.h (MY_bfd_is_target_special_symbol): Add extra
2179 cast to avoid warning from gcc v8 compiler.
2180 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
2181 * binary.c (binary_get_symbol_info): Likewise.
2182 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
2183 * coff-mips.c (mips_ecoff_backend_data): Likewise.
2184 * coffcode.h (coff_set_alignment_hook): Likewise.
2185 (symname_in_debug_hook): Likewise.
2186 (bfd_coff_backend_data bigobj_swap_table): Likewise.
2187 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
2188 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
2189 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
2190 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
2191 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
2192 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
2193 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
2194 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
2195 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
2196 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
2197 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
2198 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
2199 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
2200 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
2201 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
2202 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
2203 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
2204 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
2205 (bfd_elfNN_bfd_set_private_flags): Likewise.
2206 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
2207 (elf_backend_init_index_section): Likewise.
2208 (elf_backend_allow_non_load_phdr): Likewise.
2209 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
2210 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
2211 * ieee.c (ieee_construct_extended_name_table): Likewise.
2212 (ieee_write_armap): Likewise.
2213 (ieee_write_ar_hdr): Likewise.
2214 (ieee_bfd_is_target_special_symbol): Likewise.
2215 * ihex.c (ihex_canonicalize_symtab): Likewise.
2216 (ihex_bfd_is_target_special_symbol): Likewise.
2217 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
2218 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
2219 (_bfd_ecoff_set_alignment_hook): Likewise.
2220 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
2221 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
2222 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
2223 * oasys.c (oasys_construct_extended_name_table): Likewise.
2224 (oasys_write_armap): Likewise.
2225 (oasys_write_ar_hdr): Likewise.
2226 (oasys_bfd_is_target_special_symbol): Likewise.
2227 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
2228 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
2229 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
2230 * som.c (som_bfd_is_target_special_symbol): Likewise.
2231 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
2232 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
2233 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
2234 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
2235 (versados_bfd_reloc_name_lookup): Likewise.
2236 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
2237 (vms_bfd_define_start_stop): Likewise.
2238 (alpha_vms_bfd_is_target_special_symbol): Likewise.
2239 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
2240 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
2241
451875b4
L
22422018-02-14 H.J. Lu <hongjiu.lu@intel.com>
2243
2244 PR ld/22842
2245 * elf32-i386.c (elf_i386_check_relocs): Pass FALSE for non
2246 PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
2247 * elf64-x86-64.c (elf_x86_64_check_relocs): Create PLT for
2248 R_X86_64_PC32 reloc against dynamic function in data section.
2249 Pass TRUE for PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
2250 (elf_x86_64_relocate_section): Use PLT for R_X86_64_PC32 reloc
2251 against dynamic function in data section.
2252 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Use PLT in PIE as
2253 function address only if pcrel_plt is true.
2254 (_bfd_x86_elf_link_hash_table_create): Set pcrel_plt.
2255 * elfxx-x86.h (NEED_DYNAMIC_RELOCATION_P): Add PCREL_PLT for
2256 PC-relative PLT. If PLT is PC-relative, don't generate dynamic
2257 PC-relative relocation against a function definition in data
2258 secton in PIE. Remove the obsolete comments.
2259 (elf_x86_link_hash_table): Add pcrel_plt.
2260
1031c264
L
22612018-02-13 H.J. Lu <hongjiu.lu@intel.com>
2262
2263 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Check bfd_link_dll,
2264 instead of bfd_link_pic, for building shared library.
2265
bd7ab16b
L
22662018-02-13 H.J. Lu <hongjiu.lu@intel.com>
2267
2268 PR gas/22791
2269 * elf64-x86-64.c (is_32bit_relative_branch): Removed.
2270 (elf_x86_64_relocate_section): Check PIC relocations in PIE.
2271 Remove is_32bit_relative_branch usage. Disallow PC32 reloc
2272 against protected function in shared object.
2273
80c96350
ST
22742018-02-13 Sergei Trofimovich <slyfox@inbox.ru>
2275
2276 PR 22828
2277 * po/ru.po: Fix typo in Russian translation.
2278
87993319
MR
22792018-02-13 Maciej W. Rozycki <macro@mips.com>
2280
2281 * wasm-module.c (wasm_scan_name_function_section): Rename
2282 `index' local variable to `idx'.
2283
68d20676
NC
22842018-02-13 Nick Clifton <nickc@redhat.com>
2285
2286 PR 22823
2287 Fix compile time warnings generated by gcc version 8.
2288 * libbfd-in.h: Remove extraneous text from prototypes.
2289 Add prototypes for bfd_false_any, bfd_true_any,
2290 bfd_nullvoidptr_any, bfd_0_any, bfd_0u_any, bfd_0l_any,
2291 bfd_n1_any, bfd_void_any.
2292 (_bfd_generic_bfd_copy_private_bfd_data): Use vararg based dummy
2293 function.
2294 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
2295 (_bfd_generic_bfd_set_private_flags): Likewise.
2296 (_bfd_generic_bfd_copy_private_section_data): Likewise.
2297 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
2298 (_bfd_generic_bfd_copy_private_header_data): Likewise.
2299 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
2300 (_bfd_noarchive_construct_extended_name_table): Likewise.
2301 (_bfd_noarchive_truncate_arname): Likewise.
2302 (_bfd_noarchive_write_ar_hdr): Likewise.
2303 (_bfd_noarchive_get_elt_at_index): Likewise.
2304 (_bfd_nosymbols_canonicalize_symtab): Likewise.
2305 (_bfd_nosymbols_print_symbol): Likewise.
2306 (_bfd_nosymbols_get_symbol_info): Likewise.
2307 (_bfd_nosymbols_get_symbol_version_string): Likewise.
2308 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
2309 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
2310 (_bfd_nosymbols_get_lineno): Likewise.
2311 (_bfd_nosymbols_find_nearest_line): Likewise.
2312 (_bfd_nosymbols_find_line): Likewise.
2313 (_bfd_nosymbols_find_inliner_info): Likewise.
2314 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
2315 (_bfd_nosymbols_read_minisymbols): Likewise.
2316 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
2317 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
2318 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
2319 (_bfd_nowrite_set_arch_mach): Likewise.
2320 (_bfd_nowrite_set_section_contents): Likewise.
2321 (_bfd_nolink_sizeof_headers): Likewise.
2322 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
2323 (_bfd_nolink_bfd_relax_section): Likewise.
2324 (_bfd_nolink_bfd_gc_sections): Likewise.
2325 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
2326 (_bfd_nolink_bfd_merge_sections): Likewise.
2327 (_bfd_nolink_bfd_is_group_section): Likewise.
2328 (_bfd_nolink_bfd_discard_group): Likewise.
2329 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
2330 (_bfd_nolink_bfd_link_add_symbols): Likewise.
2331 (_bfd_nolink_bfd_link_just_syms): Likewise.
2332 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
2333 (_bfd_nolink_bfd_final_link): Likewise.
2334 (_bfd_nolink_bfd_link_split_section): Likewise.
2335 (_bfd_nolink_section_already_linked): Likewise.
2336 (_bfd_nolink_bfd_define_common_symbol): Likewise.
2337 (_bfd_nolink_bfd_define_start_stop): Likewise.
2338 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
2339 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
2340 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
2341 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
2342 * libbfd.c (bfd_false_any): New function. Like bfd_false but
2343 accepts one or more arguments.
2344 (bfd_true_any): Likewise.
2345 (bfd_nullvoidptr_any): Likewise.
2346 (bfd_0_any): Likewise.
2347 (bfd_0u_any): Likewise.
2348 (bfd_0l_any): Likewise.
2349 (_bfd_n1_any): Likewise.
2350 (bfd_void_any): Likewise.
2351 * libbfd.h (extern): Regenerate
2352 * aout-target.h (MY_bfd_is_target_special_symbol): Use vararg
2353 based dummy function.
2354 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
2355 * binary.c (binary_get_symbol_info): Likewise.
2356 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
2357 * coff-mips.c (mips_ecoff_backend_data): Likewise.
2358 * coffcode.h (coff_set_alignment_hook): Likewise.
2359 (symname_in_debug_hook): Likewise.
2360 (bfd_coff_backend_data bigobj_swap_table): Likewise.
2361 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
2362 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
2363 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
2364 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
2365 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
2366 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
2367 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
2368 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
2369 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
2370 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
2371 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
2372 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
2373 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
2374 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
2375 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
2376 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
2377 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
2378 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
2379 (bfd_elfNN_bfd_set_private_flags): Likewise.
2380 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
2381 (elf_backend_init_index_section): Likewise.
2382 (elf_backend_allow_non_load_phdr): Likewise.
2383 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
2384 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
2385 * ieee.c (ieee_construct_extended_name_table): Likewise.
2386 (ieee_write_armap): Likewise.
2387 (ieee_write_ar_hdr): Likewise.
2388 (ieee_bfd_is_target_special_symbol): Likewise.
2389 * ihex.c (ihex_canonicalize_symtab): Likewise.
2390 (ihex_bfd_is_target_special_symbol): Likewise.
2391 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
2392 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
2393 (_bfd_ecoff_set_alignment_hook): Likewise.
2394 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
2395 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
2396 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
2397 * oasys.c (oasys_construct_extended_name_table): Likewise.
2398 (oasys_write_armap): Likewise.
2399 (oasys_write_ar_hdr): Likewise.
2400 (oasys_bfd_is_target_special_symbol): Likewise.
2401 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
2402 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
2403 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
2404 * som.c (som_bfd_is_target_special_symbol): Likewise.
2405 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
2406 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
2407 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
2408 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
2409 (versados_bfd_reloc_name_lookup): Likewise.
2410 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
2411 (vms_bfd_define_start_stop): Likewise.
2412 (alpha_vms_bfd_is_target_special_symbol): Likewise.
2413 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
2414 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
2415 * elf32-arc.c (get_replace_function): Assign replacement function
2416 to func pointer.
2417 * elf32-i370.c (i370_noop): Update prototype.
2418
6e5e9d58
AM
24192018-02-13 Alan Modra <amodra@gmail.com>
2420
2421 PR 22836
2422 * elf.c (_bfd_elf_fixup_group_sections): Account for removed
2423 relocation sections. If size reduces to just the flag word,
2424 remove that too and mark with SEC_EXCLUDE.
2425 * elflink.c (bfd_elf_final_link): Strip empty group sections.
2426
f2731e0c
AM
24272018-02-13 Alan Modra <amodra@gmail.com>
2428
2429 PR 22829
2430 * elf.c (assign_file_positions_for_non_load_sections): Rewrite
2431 PT_GNU_RELRO setup.
2432
830db048
ZF
24332018-02-12 Zebediah Figura <z.figura12@gmail.com>
2434
2435 * i386msdos.c (msdos_mkobject); New function.
2436 (msdos_object_p): New function.
2437 (i386_msdos_vec): Use msdos_object_p as the check_format
2438 function.
2439 * peicode.h: Rename external_PEI_DOS_hdr, DOSMAGIC, and
2440 NT_SIGNATURE to external_DOS_hdr, IMAGE_DOS_SIGNATURE, and
2441 IMAGE_NT_SIGNATURE.
2442 * peXXigen.c: Likewise.
2443 * coff-ia64.c: Likewise.
2444
94fe5757
NC
24452018-02-12 Nick Clifton <nickc@redhat.com>
2446
2447 * elf32-nds32.c (nds32_elf_relax_longjump3): Remove redundant
2448 assignment.
0b8683b7 2449 * elf32-arc.c (elf_arc_relocate_section): Likewise.
94fe5757 2450
d805612e 24512018-02-09 Eric Botcazou <ebotcazou@adacore.com>
a8735c82
EB
2452
2453 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Reorder conditions.
2454 (sparc_elf_append_rela): Assert that there is enough room in section.
2455 (_bfd_sparc_elf_copy_indirect_symbol): Fix formatting.
2456 (_bfd_sparc_elf_adjust_dynamic_symbol): Minor tweak.
2457 (allocate_dynrelocs): Remove outdated comments and reorder conditions.
2458 For a symbol subject to a GOT relocation, reserve a slot in the
2459 relocation section if the symbol isn't dynamic and we are in PIC mode.
2460 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: If relocation
2461 is relaxed and a slot was reserved, generate a R_SPARC_NONE relocation.
2462 <R_SPARC_GOTDATA_OP_HIX22>: Adjust comments.
2463 <R_SPARC_PC10>: Reorder conditions. Remove always-false assertion.
2464 (_bfd_sparc_elf_finish_dynamic_symbol): Rename local_undefweak into
2465 resolved_to_zero. Do not generate a dynamic GOT relocation for an
2466 undefined weak symbol with non-default visibility. Remove superfluous
2467 'else' and fix formatting.
2468
3b4c3844
L
24692018-02-09 H.J. Lu <hongjiu.lu@intel.com>
2470
2471 * elf32-i386.c (elf_i386_get_synthetic_symtab): Also handle
2472 is_solaris.
2473 (i386_elf32_sol2_vec): Don't declare.
2474 (elf_i386_link_setup_gnu_properties): Also handle is_solaris.
2475 Don't set need_global_offset_table.
2476 (elf_i386_solaris_arch_bed): New.
2477 (elf_backend_arch_data): Set to elf_i386_solaris_arch_bed for
2478 Solaris.
2479 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Check
2480 target_os != is_nacl instead of target_os == is_normal.
2481 (x86_64_elf64_sol2_vec): Don't declare.
2482 (elf_x86_64_link_setup_gnu_properties): Check target_os !=
2483 is_nacl instead of target_os == is_normal. Don't set
2484 need_global_offset_table.
2485 (elf_x86_64_solaris_arch_bed): New.
2486 (elf_backend_arch_data): Set to elf_x86_64_solaris_arch_bed for
2487 Solaris.
2488 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep
2489 _GLOBAL_OFFSET_TABLE_ for Solaris.
2490 (_bfd_x86_elf_link_setup_gnu_properties): Don't copy
2491 need_global_offset_table.
2492 * elfxx-x86.h (elf_x86_target_os): Add is_solaris.
2493 (elf_x86_link_hash_table): Remove need_global_offset_table.
2494 (elf_x86_init_table): Likewise.
2495
15b23f36
L
24962018-02-08 H.J. Lu <hongjiu.lu@intel.com>
2497
2498 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
2499 Remove prototype.
2500 (i386_elf32_sol2_vec): Declared.
2501 (elf_i386_link_setup_gnu_properties): Set
2502 need_global_offset_table with info->output_bfd->xvec.
2503 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
2504 Remove prototype.
2505 (x86_64_elf64_sol2_vec): Declared.
2506 (elf_x86_64_link_setup_gnu_properties): Set
2507 need_global_offset_table with info->output_bfd->xvec.
2508
dc11dea2
L
25092018-02-08 H.J. Lu <hongjiu.lu@intel.com>
2510
2511 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
2512 New prototype.
2513 (elf_i386_link_setup_gnu_properties): Set need_global_offset_table
2514 for Solaris.
2515 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
2516 New prototype.
2517 (elf_x86_64_link_setup_gnu_properties): Set
2518 need_global_offset_table for Solaris.
2519 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep the
2520 unused _GLOBAL_OFFSET_TABLE_ for Solaris.
2521 (_bfd_x86_elf_link_setup_gnu_properties): Copy
2522 need_global_offset_table.
2523 * elfxx-x86.h (elf_x86_link_hash_table): Add
2524 need_global_offset_table.
2525 (elf_x86_init_table): Likewise.
2526
3f48fe4a
JW
25272018-02-08 Jim Wilson <jimw@sifive.com>
2528
2529 * elfnn-riscv.c (riscv_elf_relocate_section): Add comment for previous
2530 change.
2531
ef135d43
NC
25322018-02-08 Nick Clifton <nickc@redhat.com>
2533
2534 PR 22788
2535 * elf.c (elf_parse_notes): Reject notes with excessuively large
2536 alignments.
2537
407aa07c
AM
25382018-02-07 Alan Modra <amodra@gmail.com>
2539
2540 Revert 2018-01-17 Alan Modra <amodra@gmail.com>
2541 * elf32-ppc.c: Remove speculation barrier support.
2542 * elf32-ppc.h: Likewise.
2543 * elf64-ppc.c: Likewise.
2544 * elf64-ppc.h: Likewise.
2545
ed01220c
JW
25462018-02-06 Jim Wilson <jimw@sifive.com>
2547
2548 * elfnn-riscv.c (riscv_elf_relocate_section): Return TRUE if used
2549 callback to report an error.
2550
c20c30f6
EB
25512018-02-06 Eric Botcazou <ebotcazou@adacore.com>
2552
2553 PR ld/22263
2554 * elfxx-sparc.c (sparc_elf_tls_transition): Turn call to bfd_link_pic
2555 into call to !bfd_link_executable and tidy up.
2556 (_bfd_sparc_elf_check_relocs): Fix formatting and tidy up.
2557 <R_SPARC_TLS_LE_HIX22>: Turn call to bfd_link_pic into call to
2558 !bfd_link_executable.
2559 <R_SPARC_TLS_IE_HI22>: Likewise.
2560 <GOT relocations>: Remove useless code, tidy and merge related blocks.
2561 <R_SPARC_TLS_GD_CALL>: Turn call to bfd_link_pic into call to
2562 !bfd_link_executable.
2563 <R_SPARC_WPLT30>: Tidy up.
2564 (_bfd_sparc_elf_gc_mark_hook): Turn call to bfd_link_pic into call to
2565 !bfd_link_executable.
2566 (allocate_dynrelocs): Likewise.
2567 (_bfd_sparc_elf_relocate_section): Fix formatting and tidy up.
2568 <R_SPARC_TLS_GD_HI22>: Merge into...
2569 <R_SPARC_TLS_GD_LO10>: ...this. Adjust 4th argument in call to
2570 sparc_elf_tls_transition and remove redundant code.
2571 <R_SPARC_TLS_LDM_HI22>: Turn call to bfd_link_pic into call to
2572 !bfd_link_executable.
2573 <R_SPARC_TLS_LDO_HIX22>: Likewise.
2574 <R_SPARC_TLS_LE_HIX22>: Likewise. Tidy up.
2575 <R_SPARC_TLS_LDM_CALL>: Likewise.
2576 <R_SPARC_TLS_GD_CALL>: Likewise. Tidy up.
2577 <R_SPARC_TLS_GD_ADD>: Likewise.
2578 <R_SPARC_TLS_LDM_ADD>: Likewise.
2579 <R_SPARC_TLS_LDO_ADD>: Likewise.
2580 <R_SPARC_TLS_IE_LD>: Likewise.
2581
46d09186
NC
25822018-02-06 Miloš Stojanović <milos.stojanovic@rt-rk.com>
2583
2584 PR 22789
2585 * elfxx-mips.c (_bfd_mips_elf_find_nearest_line): If the dwarf
2586 functions failed to find the function name, try the generic elf
2587 find function instead.
2588
8278e7ce
SDJ
25892018-02-06 Sergio Durigan Junior <sergiodj@redhat.com>
2590
2591 * coff-rs6000.c (xcoff_write_archive_contents_old): Use
2592 'memcpy' instead of 'strncpy' when writing the magic number.
2593
64e234d4
NC
25942018-02-06 Nick Clifton <nickc@redhat.com>
2595
2596 PR 22794
2597 * opncls.c (bfd_get_debug_link_info_1): Check the size of the
2598 section before attempting to read it in.
2599 (bfd_get_alt_debug_link_info): Likewise.
2600
422f3d3d
PC
26012018-02-06 Paul Carroll <pcarroll@codesourcery.com>
2602
2603 * bfd/dwarf2.c (find_abstract_name): Modified to return file and
2604 line information in addition to name, if they can be found.
2605
279b2f94
RL
26062018-02-05 Renlin Li <renlin.li@arm.com>
2607
2608 PR ld/22764
2609 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Relax the
2610 R_AARCH64_ABS32 and R_AARCH64_ABS16 for absolute symbol. Apply the
2611 check for writeable section as well.
2612
cd048363
L
26132018-02-05 H.J. Lu <hongjiu.lu@intel.com>
2614
2615 PR ld/22782
2616 * elf32-i386.c (elf_i386_check_relocs): Set got_referenced if
2617 _GLOBAL_OFFSET_TABLE_ is referenced or GOT is needed to resolve
2618 undefined weak symbol to 0.
2619 * elf64-x86-64.c (elf_x86_64_check_relocs): Set got_referenced
2620 if _GLOBAL_OFFSET_TABLE_ is referenced.
2621 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Check
2622 got_referenced instead of ref_regular_nonweak. Remove the
2623 unused _GLOBAL_OFFSET_TABLE_ from symbol table.
2624 * elfxx-x86.h (elf_x86_link_hash_table): Add got_referenced.
2625
e65b1a78
MR
26262018-02-05 Maciej W. Rozycki <macro@mips.com>
2627
2628 * elfnn-riscv.c (_bfd_riscv_relax_pc): Use `memset' to
2629 initialize `hi_reloc'.
2630
2d6dda71
MR
26312018-02-05 Maciej W. Rozycki <macro@mips.com>
2632
2633 * elfxx-mips.c (_bfd_mips_elf_section_processing): For
2634 SHT_MIPS_REGINFO sections don't assert the correct size and
2635 report an error instead.
2636
75506100
MR
26372018-02-05 Maciej W. Rozycki <macro@mips.com>
2638
2639 * elf.c (_bfd_elf_write_object_contents): Propagate a failure
2640 status from `->elf_backend_section_processing'.
2641
7f02625e
JW
26422018-02-02 Jim Wilson <jimw@sifive.com>
2643
2644 PR ld/22756
2645 * elfnn-riscv.c (riscv_relax_delete_bytes): New parameter link_info.
2646 If link_info->wrap_hash, check for a duplicate symbol and ignore.
2647 (_bfd_riscv_relax_call, bfd_riscv_relax_lui, _bfd_riscv_relax_tls_le):
2648 Pass new argument to riscv_relax_delete_bytes.
2649 (_bfd_riscv_relax_align, _bfd_riscv_relax_delete): Likewise. Remove
2650 ATTRIBUTE_UNUSED from link_info parameter.
2651
d830549d
AM
26522018-02-02 Alan Modra <amodra@gmail.com>
2653
2654 * elf64-ppc.c (ppc64_elf_relocate_section): Don't relocate nops
2655 emitted for toc sequence optimization. Set and use "howto" later.
2656
e99955cd
SM
26572018-02-01 Simon Marchi <simon.marchi@ericsson.com>
2658
2659 * elf64-ppc.c (ppc64_elf_archive_symbol_lookup): Avoid pointer
2660 arithmetic on NULL pointer.
2661 * elflink.c (_bfd_elf_archive_symbol_lookup,
2662 elf_link_add_archive_symbols): Likewise.
2663
bf3077a6
MM
26642018-01-31 Michael Matz <matz@suse.de>
2665
2666 * elflink.c (bfd_elf_define_start_stop): Fix check of
2667 def_dynamic.
2668
823143c6
L
26692018-01-31 H.J. Lu <hongjiu.lu@intel.com>
2670
2671 PR ld/21964
2672 * elflink.c (bfd_elf_define_start_stop): Check if __start and
2673 __stop symbols are referenced by shared objects.
2674
76cb3a89
AM
26752018-01-30 Alan Modra <amodra@gmail.com>
2676
2677 PR 22758
2678 * elf.c (_bfd_elf_map_sections_to_segments): Don't start a new
2679 segment when demand paged with lma on the same page. Test this
2680 before load/non-load, executable/non-executable,
2681 writable/non-writable tests and simplify. Delete bogus relro
2682 condition in writable/non-writable test. Delete outdated
2683 comment. Formatting.
2684
36b8fda5
AM
26852018-01-30 Alan Modra <amodra@gmail.com>
2686
2687 * elflink.c (bfd_elf_define_start_stop): Make __start and __stop
2688 symbols dynamic.
2689
eb77f6a4
AM
26902018-01-29 Alan Modra <amodra@gmail.com>
2691
2692 PR 22741
2693 * coffgen.c (coff_pointerize_aux): Ensure auxent tagndx is in
2694 range before converting to a symbol table pointer.
2695
7d73b4c8
NC
26962018-01-27 Nick Clifton <nickc@redhat.com>
2697
2698 * po/ru.po: Updated Russian translation.
2699
32253bb7
AM
27002018-01-26 Alan Modra <amodra@gmail.com>
2701
2702 * elflink.c (bfd_elf_define_start_stop): Override symbols when
2703 they are defined dynamically.
2704
ba21f564
AM
27052018-01-26 Alan Modra <amodra@gmail.com>
2706
2707 * elf64-ppc.c (ppc64_elf_size_stubs): Iterate sizing when
2708 .branch_lt changes size.
2709
38e64b0e
AM
27102018-01-25 Alan Modra <amodra@gmail.com>
2711
2712 PR 22746
2713 * elfcode.h (elf_object_p): Avoid integer overflow.
2714
bb363086
EB
27152018-01-25 Eric Botcazou <ebotcazou@adacore.com>
2716
2717 PR ld/22727
2718 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
2719 Do a mere lookup of the __tls_get_addr symbol instead of adding it.
2720
2721 Revert
2722 2017-10-19 H.J. Lu <hongjiu.lu@intel.com>
2723
2724 PR ld/22263
2725 * elfxx-sparc.c (sparc_elf_tls_transition): Replace
2726 bfd_link_pic with !bfd_link_executable, !bfd_link_pic with
2727 bfd_link_executable for TLS check.
2728 (_bfd_sparc_elf_check_relocs): Likewise.
2729 (allocate_dynrelocs): Likewise.
2730 (_bfd_sparc_elf_relocate_section): Likewise.
2731
1daf502a
RL
27322018-01-24 Renlin Li <renlin.li@arm.com>
2733
2734 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Add support for
2735 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
2736 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
2737 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
2738 BFD_RELOC_AARCH64_MOVW_PREL_G3.
2739 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
2740 (_bfd_aarch64_elf_resolve_relocation): Likewise.
2741
32247401
RL
27422018-01-24 Renlin Li <renlin.li@arm.com>
2743
2744 * reloc.c: Add BFD_RELOC_AARCH64_MOVW_PREL_G0,
2745 BFD_RELOC_AARCH64_MOVW_PREL_G0_NC, BFD_RELOC_AARCH64_MOVW_PREL_G1,
2746 BFD_RELOC_AARCH64_MOVW_PREL_G1_NC, BFD_RELOC_AARCH64_MOVW_PREL_G2,
2747 BFD_RELOC_AARCH64_MOVW_PREL_G2_NC, BFD_RELOC_AARCH64_MOVW_PREL_G3.
2748 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add entries for
2749 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
2750 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
2751 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
2752 BFD_RELOC_AARCH64_MOVW_PREL_G3.
2753 * bfd-in2.h: Regenerate.
2754 * libbfd.h: Regenerate.
2755
1c5e4ee9
MR
27562018-01-23 Maciej W. Rozycki <macro@mips.com>
2757
2758 * elfxx-mips.c (_bfd_mips_elf_final_link): Update a stale
2759 `mips_elf32_section_processing' comment reference.
2760
8a1b824a
L
27612018-01-20 H.J. Lu <hongjiu.lu@intel.com>
2762
2763 PR ld/22721
2764 * elfxx-x86.c (_bfd_x86_elf_link_check_relocs): Check the
2765 versioned __tls_get_addr symbol.
2766
ee3fbc1e
NC
27672018-01-19 Nick Clifton <nickc@redhat.com>
2768
2769 * po/fr.po: Updated French translation.
2770
691d2e9a
AM
27712018-01-18 Alan Modra <amodra@gmail.com>
2772
2773 * elf32-ppc.c (ppc_elf_create_glink): Correct alignment of .glink.
2774 * elf64-ppc.c (ppc64_elf_size_stubs): Handle negative plt_stub_align.
2775 (ppc64_elf_build_stubs): Likewise.
2776
4bfce128
NC
27772018-01-17 Nick Clifton <nickc@redhat.com>
2778
2779 * po/ru.po: Updated Russian translation.
2780 * po/uk/po: Updated Ukranian translation.
2781
c75bc4f7
AM
27822018-01-17 Alan Modra <amodra@gmail.com>
2783
2784 * elf64-ppc.c (ppc64_elf_build_stubs): Silence gcc warning.
2785
1be5d8d3
AM
27862018-01-17 Alan Modra <amodra@gmail.com>
2787
2788 * elf32-ppc.c (GLINK_ENTRY_SIZE): Handle speculation barrier.
2789 (CRSETEQ, BEQCTRM): Define.
2790 (is_nonpic_glink_stub): Don't check bctr.
2791 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
2792 (ppc_elf_relax_section): Size speculation barrier.
2793 (output_bctr): New function.
2794 (write_glink_stub): Use output_bctr.
2795 (ppc_elf_relocate_section): Use output_bctr for long branch stub.
2796 (ppc_elf_finish_dynamic_symbol): Likewise.
2797 (ppc_elf_finish_dynamic_sections): Use output_bctr.
2798 * elf32-ppc.h (struct ppc_elf_params): Add speculate_indirect_jumps.
2799 * elf64-ppc.c (CRSETEQ, BEQCTRM, BEQCTRLM): Define.
2800 (GLINK_PLTRESOLVE_SIZE): Size speculation barrier.
2801 (size_global_entry_stubs): Handle speculation barrier sizing.
2802 (plt_stub_size): Likewise.
2803 (output_bctr): New function.
2804 (build_plt_stub, build_tls_get_addr_stub): Output speculation
2805 barrier.
2806 (ppc_build_one_stub): Likewise for ppc_stub_plt_branch.
2807 (ppc_size_one_stub): Size speculation barrier in ppc_stub_plt_branch.
2808 (build_global_entry_stubs): Output speculation barrier.
2809 (ppc64_elf_build_stubs): Likewise in __glink_PLTresolve stub.
2810 * elf64-ppc.h (struct ppc64_elf_params): Add speculate_indirect_jumps.
2811
9e390558
AM
28122018-01-17 Alan Modra <amodra@gmail.com>
2813
2814 * elf32-ppc.c (GLINK_ENTRY_SIZE): Add parameters, handle
2815 __tls_get_addr_opt, and alignment sizing.
2816 (TLS_GET_ADDR_GLINK_SIZE): Delete.
2817 (is_nonpic_glink_stub): Don't use GLINK_ENTRY_SIZE.
2818 (ppc_elf_get_synthetic_symtab): Recognize stubs spaced at 4, 6,
2819 or 8 insns.
2820 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
2821 (allocate_dynrelocs): Use new GLINK_ENTRY_SIZE.
2822 (ppc_elf_size_dynamic_sections): Likewise. Size branch table
2823 by PLT reloc count.
2824 (write_glink_stub): Handle __tls_get_addr_opt stub.
2825 Pad out to size given by GLINK_ENTRY_SIZE.
2826 (ppc_elf_relocate_section): Adjust write_glink_stub call.
2827 (ppc_elf_finish_dynamic_symbol): Likewise.
2828 (ppc_elf_finish_dynamic_sections): Write PLTresolve without using
2829 insn array since so many need rewriting.
2830 * elf32-ppc.h (struct ppc_elf_params): Add plt_stub_align.
2831 * elf64-ppc.c (GLINK_PLTRESOLVE_SIZE): Rename from
2832 GLINK_CALL_STUB_SIZE. Add htab param and evaluate to size without
2833 nops. Adjust all uses.
2834 (ppc64_elf_get_synthetic_symtab): Don't use GLINK_CALL_STUB_SIZE
2835 in glink_vma calculation.
2836 (struct ppc_link_hash_table): Add global_entry section pointer.
2837 (create_linkage_sections): Create separate section for global
2838 entry stubs.
2839 (PPC_LO, PPC_HI, PPC_HA): Move earlier.
2840 (size_global_entry_stubs): Handle sizing for aligned stubs.
2841 (ppc64_elf_size_dynamic_sections): Handle global_entry alloc,
2842 and don't stash end of glink branch table in rawsize.
2843 (ppc_build_one_stub): Rewrite stub size calculations.
2844 (build_global_entry_stubs): Use new section.
2845 (ppc64_elf_build_stubs): Don't pad __glink_PLTresolve with nops.
2846 Build lazy link stubs out to end of section. Build global entry
2847 stubs in new section.
2848
616dcb87
NC
28492018-01-15 Nick Clifton <nickc@redhat.com>
2850
2851 * po/uk.po: Updated Ukranian translation.
2852
3957a496
NC
28532018-01-13 Nick Clifton <nickc@redhat.com>
2854
2855 * po/bfd.pot: Regenerated.
2856
769c7ea5
NC
28572018-01-13 Nick Clifton <nickc@redhat.com>
2858
2859 * version.m4: Bump version to 2.30.51
2860 * configure: Regenerate.
2861
faf766e3
NC
28622018-01-13 Nick Clifton <nickc@redhat.com>
2863
2864 2.30 branch created.
2865
564e11c9
JW
28662018-01-12 Jens Widell <jl@opera.com>
2867
2868 * elf.c (setup_group): Optimize search for group by remembering
2869 last found group and restarting search at that index.
2870 * elf-bfd.h (struct elf_obj_tdata): Add group_search_offset field.
2871
a78eea16
AM
28722018-01-12 Gunther Nikl <gnikl@users.sourceforge.net>
2873
2874 * aoutx.h (aout_link_check_ar_symbols): Remove default and handle
2875 bfd_link_common_skip_none in switch.
2876
87e79a65
AM
28772018-01-12 Alan Modra <amodra@gmail.com>
2878
2879 PR ld/22649
2880 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Ignore dynamic
2881 references on forced local symbols.
2882
58807c48
VI
28832018-01-12 Vlad Ivanov <vlad@ivanov.email>
2884
2885 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
2886 .reginfo section has wrong size.
2887
2888249f
L
28882018-01-11 H.J. Lu <hongjiu.lu@intel.com>
2889
2890 PR ld/22393
2891 * elf.c (_bfd_elf_map_sections_to_segments): When generating
2892 separate code and read-only data LOAD segments, create a new
2893 LOAD segment if the previous section contains text and the
2894 current section doesn't or vice versa. Don't put a writable
2895 section in a read-only segment if there is a RELRO segment.
2896
d664fd41
L
28972018-01-11 H.J. Lu <hongjiu.lu@intel.com>
2898
2899 PR ld/22649
2900 * elflink.c (bfd_elf_gc_mark_dynamic_ref_symbol): Ignore dynamic
2901 references on forced local symbols.
2902
8b6f4cd3
L
29032018-01-11 H.J. Lu <hongjiu.lu@intel.com>
2904
2905 PR ld/22677
2906 * elflink.c (bfd_elf_gc_sections): Keep all PREINIT_ARRAY,
2907 INIT_ARRAY as well as FINI_ARRAY sections for ld -r --gc-section.
2908
9c70c522 29092018-01-09 Kuan-Lin Chen <kuanlinchentw@gmail.com>
6cef73f9
KLC
2910
2911 PR 22662
2912 * elf32-nds32.c (nds32_elf_relax_loadstore): Fix a typographical error.
2913
ddb2bbcf
JB
29142018-01-03 John Baldwin <jhb@FreeBSD.org>
2915
2916 * elf.c (elfcore_grok_freebsd_note): Handle
2917 NT_FREEBSD_PROCSTAT_PROC, NT_FREEBSD_PROCSTAT_FILES, and
2918 NT_FREEBSD_PROCSTAT_VMMAP.
2919
219d1afa
AM
29202018-01-03 Alan Modra <amodra@gmail.com>
2921
2922 Update year range in copyright notice of all files.
2923
1e563868 2924For older changes see ChangeLog-2017
3499769a 2925\f
1e563868 2926Copyright (C) 2018 Free Software Foundation, Inc.
3499769a
AM
2927
2928Copying and distribution of this file, with or without modification,
2929are permitted in any medium without royalty provided the copyright
2930notice and this notice are preserved.
2931
2932Local Variables:
2933mode: change-log
2934left-margin: 8
2935fill-column: 74
2936version-control: never
2937End:
This page took 0.277988 seconds and 4 git commands to generate.