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