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