Prevent an illegal memory access in gprof by ensuring that string tables for aout...
[deliverable/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
bf82069d
NC
12018-04-23 Nick Clifton <nickc@redhat.com>
2
3 PR 23056
4 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
5 the end of the string table, and zero it.
6
5a6312e8
AM
72018-04-23 Alan Modra <amodra@gmail.com>
8
9 * elf-linux-core.h (swap_linux_prpsinfo32_ugid32_out): Disable
10 gcc-8 string truncation warning.
11 (swap_linux_prpsinfo32_ugid16_out): Likewise.
12 (swap_linux_prpsinfo64_ugid32_out): Likewise.
13 (swap_linux_prpsinfo64_ugid16_out): Likewise.
14 * elf.c (elfcore_write_prpsinfo): Likewise.
15
bf82069d
NC
162018-04-23 Nick Clifton <nickc@redhat.com>
17
18 PR 23056
19 * aoutx.h (aout_get_external_symbols): Allocate an extra byte at
20 the end of the string table, and zero it.
21
4352556b
AM
222018-04-20 Alan Modra <amodra@gmail.com>
23
24 PR 22978
25 * elf32-hppa.c (got_relocs_needed): Add extra param to special
26 case both dtprel and tprel relocs.
27 (allocate_dynrelocs): Adjust conditions for got relocs.
28 (elf32_hppa_relocate_section): Likewise for local sym got relocs.
29 Emit dynamic relocs on TLS GOT entries for shared libraries,
30 not when pic. Omit dynamic reloc on dtprel entry when local,
31 and on tprel entry when local and executable.
32
f6a8b8c7
AM
332018-04-19 Alan Modra <amodra@gmail.com>
34
35 PR 22537
36 * elf32-hppa.c (elf32_hppa_size_stubs): Init "destination" to -1.
37 (hppa_type_of_stub): Don't return a long branch stub for
38 symbols other than those defined statically.
39
8e415ce8
AM
402018-04-19 Alan Modra <amodra@gmail.com>
41
42 * Makefile.am: Revert 2018-04-18 coff-mips changes.
43 * config.bfd: Add back mips_ecoff_le_vec and mips_ecoff_be_vec
44 to selvecs for mips targets change 2018-04-18.
45 * configure.ac: Reinstate mips_ecoff_le_vec, mips_ecoff_be_vec
46 and mips_ecoff_bele_vec.
47 * targets.c: Likewise.
48 * coff-mips.c: Resurrect.
49 * Makefile.in: Regenerate.
50 * configure: Regenerate.
51 * po/SRC-POTFILES.in: Regenerate.
52
3596d8ce
AM
532018-04-18 Alan Modra <amodra@gmail.com>
54
55 * Makefile.am: Remove mips aout and coff support.
56 * config.bfd: Likewise.
57 * configure.ac: Likewise.
58 * targets.c: Likewise.
59 * coff-mips.c: Delete
60 * mipsbsd.c: Delete
61 * pe-mips.c: Delete
62 * pei-mips.c: Delete
63 * Makefile.in: Regenerate.
64 * configure: Regenerate.
65 * po/SRC-POTFILES.in: Regenerate.
66
d9dd2045
L
672018-04-17 H.J. Lu <hongjiu.lu@intel.com>
68
69 * elf32-i386.c (elf32_bed): Define before including
70 "elf32-target.h".
71 * elf64-x86-64.c (elf64_bed): Define before including
72 "elf64-target.h".
73 (elf32_bed): Define before including "elf32-target.h".
74
e4e6a73d
L
752018-04-17 H.J. Lu <hongjiu.lu@intel.com>
76
77 PR ld/23055
78 * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Use a
79 normal input file with compatible relocation.
80
c65c21e1
AM
812018-04-18 Alan Modra <amodra@gmail.com>
82
83 * Makefile.am: Remove support for assorted i386 aout and coff targets.
84 * config.bfd: Likewise.
85 * configure.ac: Likewise.
86 * doc/bfdint.texi: Likewise.
87 * targets.c: Likewise.
88 * freebsd.h: Delete.
89 * i386dynix.c: Delete.
90 * i386freebsd.c: Delete.
91 * i386linux.c: Delete.
92 * i386mach3.c: Delete.
93 * i386netbsd.c: Delete.
94 * i386os9k.c: Delete.
95 * Makefile.in: Regenerate.
96 * configure: Regenerate.
97 * po/SRC-POTFILES.in: Regenerate.
98
884d4d8a 992018-04-17 Andrew Sadek <andrew.sadek.se@gmail.com>
3f0a5f17
ME
100
101 Microblaze Target: PIC data text relative
102
103 * bfd/reloc.c (2 new BFD relocations):
104 BFD_RELOC_MICROBLAZE_64_TEXTPCREL &
105 BFD_RELOC_MICROBLAZE_64_TEXTPCREL
106 * bfd/bfd-in2.h: Regenerate
107 * bfd/libbfd.h: Regenerate
108 * bfd/elf32-microblaze.c (Handle new relocs): define 'HOWTO' of 3
109 new relocs and handle them in both relocate and relax functions.
110 (microblaze_elf_reloc_type_lookup): add mapping between for new
111 bfd relocs.
112 (microblaze_elf_relocate_section): Handle new relocs in case of
113 elf relocation.
114 (microblaze_elf_relax_section): Handle new relocs for elf relaxation.
115
6327533b
NC
1162018-04-17 Nick Clifton <nickc@redhat.com>
117
808346fc
NC
118 PR 23055
119 * aoutx.h (find_nearest_line): Check that the symbol name exists
120 and is long enough, before attempting to see if it is for a .o
121 file.
122 * hash.c (bfd_hash_hash): Add an assertion that the string is not
123 NULL.
124 * linker.c (bfd_link_hash_lookup): Fail if the table or string are
125 NULL.
126 (_bfd_generic_link_add_archive_symbols): Fail if an archive entry
127 has no name.
128
6327533b
NC
129 PR 23065
130 * dwarf2.c (concat_filename): Check for a NULL table pointer.
131
e9af4700
NC
1322018-04-16 Nick Clifton <nickc@redhat.com>
133
134 PR 23061
135 * coffgen.c (coff_pointerize_aux): Check for an out of range
136 fixup.
137
ddb00039
AM
1382018-04-16 Alan Modra <amodra@gmail.com>
139
140 * Makefile.am: Remove arm-epoc-pe support.
141 * coff-arm.c: Likewise.
142 * config.bfd: Likewise.
143 * configure.ac: Likewise.
144 * targets.c: Likewise.
145 * epoc-pe-arm.c: Delete.
146 * epoc-pei-arm.c: Delete.
147 * Makefile.in: Regenerate.
148 * configure: Regenerate.
149 * po/SRC-POTFILES.in: Regenerate.
150
c9098af4
AM
1512018-04-16 Alan Modra <amodra@gmail.com>
152
153 * Makefile.am: Remove sparc-aout and sparc-coff support.
154 * config.bfd: Likewise.
155 * configure.ac: Likewise.
156 * targets.c: Likewise.
157 * aout-sparcle.c: Delete.
158 * aoutf1.h: Delete.
159 * cf-sparclynx.c: Delete.
160 * coff-sparc.c: Delete.
161 * demo64.c: Delete.
162 * sparclinux.c: Delete.
163 * sparclynx.c: Delete.
164 * sparcnetbsd.c: Delete.
165 * sunos.c: Delete.
166 * Makefile.in: Regenerate.
167 * configure: Regenerate.
168 * po/SRC-POTFILES.in: Regenerate.
169
dc12032b
AM
1702018-04-16 Alan Modra <amodra@gmail.com>
171
172 * Makefile.am: Remove m68k-aout and m68k-coff support.
173 * aoutf1.h: Likewise.
174 * aoutx.h: Likewise.
175 * archive.c: Likewise.
176 * bfd-in.h: Likewise.
177 * bfd.c: Likewise.
178 * coffcode.h: Likewise.
179 * coffswap.h: Likewise.
180 * config.bfd: Likewise.
181 * configure.ac: Likewise.
182 * configure.host: Likewise.
183 * doc/bfd.texinfo: Likewise.
184 * doc/bfdint.texi: Likewise.
185 * freebsd.h: Likewise.
186 * gen-aout.c: Likewise.
187 * hpux-core.c: Likewise.
188 * libaout.h: Likewise.
189 * libbfd-in.h: Likewise.
190 * pdp11.c: Likewise.
191 * peicode.h: Likewise.
192 * riscix.c: Likewise.
193 * targets.c: Likewise.
194 * aout0.c: Delete.
195 * coff-apollo.c: Delete.
196 * coff-aux.c: Delete.
197 * coff-m68k.c: Delete.
198 * coff-svm68k.c: Delete.
199 * coff-u68k.c: Delete.
200 * hosts/delta68.h: Delete.
201 * hosts/hp300bsd.h: Delete.
202 * hosts/m68kaux.h: Delete.
203 * hosts/news.h: Delete.
204 * hp300bsd.c: Delete.
205 * hp300hpux.c: Delete.
206 * liboasys.h: Delete.
207 * m68k4knetbsd.c: Delete.
208 * m68klinux.c: Delete.
209 * m68knetbsd.c: Delete.
210 * oasys.c: Delete.
211 * versados.c: Delete.
212 * Makefile.in: Regenerate.
213 * bfd-in2.h: Regenerate.
214 * configure: Regenerate.
215 * libbfd.h: Regenerate.
216 * po/SRC-POTFILES.in: Regenerate.
217
211dc24b
AM
2182018-04-16 Alan Modra <amodra@gmail.com>
219
220 * Makefile.am: Remove sh5 and sh64 support.
221 * archures.c: Likewise.
222 * config.bfd: Likewise.
223 * configure.ac: Likewise.
224 * cpu-sh.c: Likewise.
225 * elf32-sh-relocs.h: Likewise.
226 * elf32-sh.c: Likewise.
227 * targets.c: Likewise.
228 * elf32-sh64-com.c: Delete.
229 * elf32-sh64.c: Delete.
230 * elf32-sh64.h: Delete.
231 * elf64-sh64.c: Delete.
232 * Makefile.in: Regenerate.
233 * bfd-in2.h: Regenerate.
234 * configure: Regenerate.
235 * po/SRC-POTFILES.in: Regenerate.
236
4db9937a
AM
2372018-04-16 Alan Modra <amodra@gmail.com>
238
239 * Makefile.am: Remove sh-symbianelf support.
240 * config.bfd: Likewise.
241 * configure.ac: Likewise.
242 * targets.c: Likewise.
243 * elf32-sh-symbian.c: Delete.
244 * Makefile.in: Regenerate.
245 * configure: Regenerate.
246 * po/SRC-POTFILES.in: Regenerate.
247
9f5d1593
AM
2482018-04-16 Alan Modra <amodra@gmail.com>
249
250 * Makefile.am: Remove vax-bsd and vax-ultrix support.
251 * config.bfd: Likewise.
252 * configure.ac: Likewise.
253 * targets.c: Likewise.
254 * vaxbsd.c: Delete.
255 * Makefile.in: Regenerate.
256 * configure: Regenerate.
257 * po/SRC-POTFILES.in: Regenerate.
258
a9a4b302
AM
2592018-04-16 Alan Modra <amodra@gmail.com>
260
261 * Makefile.am: Remove w65 support.
262 * archures.c: Likewise.
263 * coffcode.h: Likewise.
264 * config.bfd: Likewise.
265 * configure.ac: Likewise.
266 * targets.c: Likewise.
267 * coff-w65.c: Delete.
268 * cpu-w65.c: Delete.
269 * Makefile.in: Regenerate.
270 * bfd-in2.h: Regenerate.
271 * configure: Regenerate.
272 * po/SRC-POTFILES.in: Regenerate.
273
04cb01fd
AM
2742018-04-16 Alan Modra <amodra@gmail.com>
275
276 * Makefile.am: Remove we32k support.
277 * archures.c: Likewise.
278 * coffcode.h: Likewise.
279 * config.bfd: Likewise.
280 * configure.ac: Likewise.
281 * targets.c: Likewise.
282 * coff-we32k.c: Delete.
283 * cpu-we32k.c: Delete.
284 * Makefile.in: Regenerate.
285 * bfd-in2.h: Regenerate.
286 * configure: Regenerate.
287 * po/SRC-POTFILES.in: Regenerate.
288
c2bf1eec
AM
2892018-04-16 Alan Modra <amodra@gmail.com>
290
291 * Makefile.am: Remove m88k support.
292 * aoutx.h: Likewise.
293 * archures.c: Likewise.
294 * coffcode.h: Likewise.
295 * coffswap.h: Likewise.
296 * config.bfd: Likewise.
297 * configure.ac: Likewise.
298 * cpu-ns32k.c: Likewise.
299 * elf32-nds32.c: Likewise.
300 * mach-o.c: Likewise.
301 * netbsd-core.c: Likewise.
302 * reloc.c: Likewise.
303 * targets.c: Likewise.
304 * coff-m88k.c: Delete.
305 * cpu-m88k.c: Delete.
306 * elf32-m88k.c: Delete.
307 * hosts/m88kmach3.h: Delete.
308 * m88kmach3.c: Delete.
309 * m88kopenbsd.c: Delete.
310 * Makefile.in: Regenerate.
311 * bfd-in2.h: Regenerate.
312 * configure: Regenerate.
313 * po/SRC-POTFILES.in: Regenerate.
314
6793974d
AM
3152018-04-16 Alan Modra <amodra@gmail.com>
316
317 * Makefile.am: Remove i370 support.
318 * archures.c: Likewise.
319 * config.bfd: Likewise.
320 * configure.ac: Likewise.
321 * targets.c: Likewise.
322 * cpu-i370.c: Delete.
323 * elf32-i370.c: Delete.
324 * Makefile.in: Regenerate.
325 * bfd-in2.h: Regenerate.
326 * configure: Regenerate.
327 * po/SRC-POTFILES.in: Regenerate.
328
e82aa794
AM
3292018-04-16 Alan Modra <amodra@gmail.com>
330
331 * Makefile.am: Remove h8500 support.
332 * archures.c: Likewise.
333 * coffcode.h: Likewise.
334 * config.bfd: Likewise.
335 * configure.ac: Likewise.
336 * targets.c: Likewise.
337 * coff-h8500.c: Delete.
338 * cpu-h8500.c: Delete.
339 * Makefile.in: Regenerate.
340 * bfd-in2.h: Regenerate.
341 * configure: Regenerate.
342 * po/SRC-POTFILES.in: Regenerate.
343
fe0bf0fd
AM
3442018-04-16 Alan Modra <amodra@gmail.com>
345
346 * Makefile.am: Remove h8300-coff support.
347 * coffcode.h: Likewise.
348 * config.bfd: Likewise.
349 * configure.ac: Likewise.
350 * reloc16.c: Likewise.
351 * targets.c: Likewise.
352 * coff-h8300.c: Delete.
353 * Makefile.in: Regenerate.
354 * configure: Regenerate.
355 * po/SRC-POTFILES.in: Regenerate.
356
fdef3943
AM
3572018-04-16 Alan Modra <amodra@gmail.com>
358
359 * Makefile.am: Remove IEEE 695 support.
360 * archures.c: Likewise.
361 * bfd.c: Likewise.
362 * config.bfd: Likewise.
363 * configure.ac: Likewise.
364 * doc/bfd.texinfo: Likewise.
365 * doc/bfdint.texi: Likewise.
366 * doc/bfdsumm.texi: Likewise.
367 * section.c: Likewise.
368 * targets.c: Likewise.
369 * ieee.c: Delete.
370 * libieee.h: Delete.
371 * Makefile.in: Regenerate.
372 * bfd-in2.h: Regenerate.
373 * configure: Regenerate.
374 * po/SRC-POTFILES.in: Regenerate.
375
de96689e
AM
3762018-04-16 Alan Modra <amodra@gmail.com>
377
378 * config.bfd: Remove tandem support.
379
5972ac73
AM
3802018-04-16 Alan Modra <amodra@gmail.com>
381
382 * Makefile.am: Remove newsos3 support.
383 * aoutx.h: Likewise.
384 * config.bfd: Likewise.
385 * configure.ac: Likewise.
386 * targets.c: Likewise.
387 * newsos3.c: Delete.
388 * Makefile.in: Regenerate.
389 * configure: Regenerate.
390 * po/SRC-POTFILES.in: Regenerate.
391
b4b594e3
AM
3922018-04-16 Alan Modra <amodra@gmail.com>
393
394 * Makefile.am: Remove netware support.
395 * bfd-in.h: Likewise.
396 * bfd.c: Likewise.
397 * config.bfd: Likewise.
398 * configure.ac: Likewise.
399 * doc/bfdint.texi: Likewise.
400 * ecoff.c: Likewise.
401 * targets.c: Likewise.
402 * libnlm.h: Delete.
403 * nlm-target.h: Delete.
404 * nlm.c: Delete.
405 * nlm32-alpha.c: Delete.
406 * nlm32-i386.c: Delete.
407 * nlm32-ppc.c: Delete.
408 * nlm32-sparc.c: Delete.
409 * nlm32.c: Delete.
410 * nlm64.c: Delete.
411 * nlmcode.h: Delete.
412 * nlmswap.h: Delete.
413 * Makefile.in: Regenerate.
414 * bfd-in2.h: Regenerate.
415 * configure: Regenerate.
416 * po/SRC-POTFILES.in: Regenerate.
417
fceadf09
AM
4182018-04-16 Alan Modra <amodra@gmail.com>
419
420 * archures.c: Remove tahoe support.
421 * config.bfd: Likewise.
422 * configure.ac: Likewise.
423 * hosts/tahoe.h: Delete.
424 * bfd-in2.h: Regenerate.
425 * configure: Regenerate.
426
702d1671
AM
4272018-04-14 Alan Modra <amodra@gmail.com>
428
429 * elf-bfd.h (struct elf_backend_data): Add relropagesize.
430 * elfxx-target.h (ELF_RELROPAGESIZE): Provide default and
431 sanity test.
432 (elfNN_bed): Init relropagesize.
433 * bfd.c (bfd_emul_get_commonpagesize): Add boolean param to
434 select relropagesize.
435 * elf32-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
436 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
437 (ELF_MINPAGESIZE): Don't define.
438 * elf64-ppc.c (ELF_COMMONPAGESIZE): Define as 0x1000.
439 (ELF_RELROPAGESIZE): Define as ELF_MAXPAGESIZE.
440 * bfd-in2.h: Regenerate.
441
03aa9684
AM
4422018-04-14 Alan Modra <amodra@gmail.com>
443
444 * elf32-ppc.c (ELF_MAXPAGESIZE, ELF_COMMONPAGESIZE): Don't depend
445 on __QNXTARGET__ define.
446
24acfe5e
AM
4472018-04-14 Alan Modra <amodra@gmail.com>
448
449 * config.bfd: Add powerpc-*-lynxos* and powerpc-*-windiss*
450 to obsolete list.
451
a8eb42a8
AM
4522018-04-11 Alan Modra <amodra@gmail.com>
453
454 * aout-adobe.c: Delete.
455 * bout.c: Delete.
456 * coff-i860.c: Delete.
457 * coff-i960.c: Delete.
458 * cpu-i860.c: Delete.
459 * cpu-i960.c: Delete.
460 * elf32-i860.c: Delete.
461 * elf32-i960.c: Delete.
462 * hosts/i860mach3.h: Delete.
463 * Makefile.am: Remove i860, i960, bout, and adobe support.
464 * archures.c: Remove i860 and i960 support.
465 * coffcode.h: Likewise.
466 * reloc.c: Likewise.
467 * aoutx.h: Comment updates.
468 * archive.c: Remove BOUT and i960 support.
469 * bfd.c: Remove BOUT support.
470 * coffswap.h: Remove i960 support.
471 * config.bfd: Remove i860, i960 and adobe targets.
472 * configure.ac: Remove adode, bout, i860, i960, icoff targets.
473 * targets.c: Likewise.
474 * ieee.c: Remove i960 support.
475 * mach-o.c: Remove i860 support.
476 * Makefile.in: Regenerate.
477 * bfd-in2.h: Regenerate.
478 * configure: Regenerate.
479 * libbfd.h: Regenerate.
480 * po/SRC-POTFILES.in: Regenerate.
481
aec2e0d2
MR
4822018-04-09 Maciej W. Rozycki <macro@mips.com>
483
484 * elf64-mips.c (mips_elf64_write_rel): Handle a NULL BFD pointer
485 in the BFD symbol referred by the relocation.
486 (mips_elf64_write_rela): Likewise.
487
9ccfa98b
MR
4882018-04-09 Maciej W. Rozycki <macro@mips.com>
489
490 * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Issue an
491 error for out-of-range `r_sym' values.
492
3e04d765
AM
4932018-04-09 Alan Modra <amodra@gmail.com>
494
495 * elf64-ppc.c (struct _ppc64_elf_section_data): Add has_pltcall field.
496 (struct ppc_link_hash_table): Add can_convert_all_inline_plt.
497 (ppc64_elf_check_relocs): Set has_pltcall.
498 (ppc64_elf_adjust_dynamic_symbol): Discard some PLT entries.
499 (ppc64_elf_inline_plt): New function.
500 (ppc64_elf_size_dynamic_sections): Discard some PLT entries for locals.
501 * elf64-ppc.h (ppc64_elf_inline_plt): Declare.
502 * elf32-ppc.c (has_pltcall): Define.
503 (struct ppc_elf_link_hash_table): Add can_convert_all_inline_plt.
504 (ppc_elf_check_relocs): Set has_pltcall.
505 (ppc_elf_inline_plt): New function.
506 (ppc_elf_adjust_dynamic_symbol): Discard some PLT entries.
507 (ppc_elf_size_dynamic_sections): Likewise.
508 * elf32-ppc.h (ppc_elf_inline_plt): Declare.
509
23cedd1d
AM
5102018-04-09 Alan Modra <amodra@gmail.com>
511
512 * elf32-ppc.c (ppc_elf_howto_raw): Add PLTSEQ and PLTCALL howtos.
513 (is_plt_seq_reloc): New function.
514 (ppc_elf_check_relocs): Handle PLTSEQ and PLTCALL relocs.
515 (ppc_elf_tls_optimize): Handle inline plt call sequence.
516 (ppc_elf_relax_section): Handle PLTCALL reloc.
517 (ppc_elf_relocate_section): Nop out inline plt call sequence when
518 resolving locally.
519 * elf64-ppc.c (ppc64_elf_howto_raw): Add R_PPC64_PLTSEQ and
520 R_PPC64_PLTCALL entries. Comment R_PPC64_TOCSAVE.
521 (has_tls_get_addr_call): Correct comment.
522 (is_branch_reloc): Add PLTCALL.
523 (is_plt_seq_reloc): New function.
524 (ppc64_elf_check_relocs): Handle PLT16_LO_DS reloc. Set
525 has_tls_reloc for R_PPC64_TLSGD and R_PPC64_TLSLD. Create plt
526 entry for R_PPC64_PLTCALL.
527 (ppc64_elf_tls_optimize): Handle inline plt call sequence.
528 (ppc_type_of_stub): Handle PLTCALL reloc.
529 (toc_adjusting_stub_needed): Likewise.
530 (ppc64_elf_relocate_section): Set "can_plt_call" for PLTCALL
531 reloc insn. Nop out inline plt call sequence when resolving
532 locally. Handle __tls_get_addr inline plt call optimization.
533
2d7ad24e
AM
5342018-04-09 Alan Modra <amodra@gmail.com>
535
536 * elf64-ppc.c (LOCAL_PLT_ENTRY_SIZE): Define.
537 (struct ppc_stub_hash_entry): Add symtype field.
538 (PLT_KEEP): Define.
539 (struct ppc_link_hash_table): Add pltlocal and relpltlocal.
540 (create_linkage_sections): Create pltlocal and relpltlocal.
541 (ppc64_elf_check_relocs): Allow PLT relocs on local symbols.
542 Set PLT_KEEP.
543 (ppc64_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
544 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
545 (ppc64_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
546 Keep PLT entries for inline calls against locals.
547 (ppc_build_one_stub): Use pltlocal as appropriate.
548 (ppc_size_one_stub): Likewise.
549 (ppc64_elf_size_stubs): Set symtype.
550 (build_global_entry_stubs_and_plt): Init pltlocal and write
551 relpltlocal for globals.
552 (write_plt_relocs_for_local_syms): Likewise for local syms.
553 (ppc64_elf_relocate_section): Support PLT for local syms.
554 * elf32-ppc.c (PLT_KEEP): Define.
555 (struct ppc_elf_link_hash_table): Add pltlocal and relpltlocal.
556 (ppc_elf_create_glink): Create pltlocal and relpltlocal.
557 (ppc_elf_check_relocs): Allow PLT relocs on local symbols.
558 Set PLT_KEEP. Adjust update_local_sym_info call.
559 (ppc_elf_adjust_dynamic_symbol): Keep PLT entries for inline calls.
560 (allocate_dynrelocs): Allocate pltlocal and relpltlocal.
561 (ppc_elf_size_dynamic_sections): Size pltlocal and relpltlocal.
562 (ppc_elf_relocate_section): Support PLT16 relocs for local syms.
563 (write_global_sym_plt): Init pltlocal and write relpltlocal.
564 (ppc_finish_symbols): Likewise for locals.
565
49c09209
AM
5662018-04-09 Alan Modra <amodra@gmail.com>
567
568 * elf64-ppc.c (ppc_build_one_stub): Move output of PLT relocs
569 for local symbols to..
570 (write_plt_relocs_for_local_syms): ..here. New function.
571 (ppc64_elf_finish_dynamic_symbol): Move output of PLT relocs for
572 global symbols to..
573 (build_global_entry_stubs_and_plt): ..here. Rename from
574 build_global_entry_stubs.
575 (ppc64_elf_build_stubs): Always call build_global_entry_stubs_and_plt.
576 Call write_plt_relocs_for_local_syms.
577 * elf32-ppc.c (get_sym_h): New function.
578 (ppc_elf_relax_section): Use get_sym_h.
579 (ppc_elf_relocate_section): Move output of PLT relocs and glink
580 stubs for local symbols to..
581 (ppc_finish_symbols): ..here. New function.
582 (ppc_elf_finish_dynamic_symbol): Move output of PLT relocs for
583 global syms to..
584 (write_global_sym_plt): ..here. New function.
585 * elf32-ppc.h (ppc_elf_modify_segment_map): Delete attribute.
586 (ppc_finish_symbols): Declare.
587
08be3224
AM
5882018-04-09 Alan Modra <amodra@gmail.com>
589
590 * elf32-ppc.c (ppc_elf_check_relocs): Handle PLT16 relocs.
591 (ppc_elf_relocate_section): Likewise.
592 * elf64-ppc.c (ppc64_elf_check_relocs): Handle PLT16_LO_DS.
593 (ppc64_elf_relocate_section): Likewise. Correct PLT16
594 resolution to plt entry relative to toc pointer.
595
37da22e5
AM
5962018-04-09 Alan Modra <amodra@gmail.com>
597
598 * elf64-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
599 TLS_TPRELGD, TLS_EXPLICIT): Renumber. Test TLS_TLS throughout
600 file when other TLS flags are tested in a mask.
601 (TLS_MARK, NON_GOT): Define.
602 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
603 (update_local_sym_info): Don't create got entry when NON_GOT.
604 (ppc64_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
605 Set TLS_MARK.
606 (get_tls_mask): Do toc lookup if tls_mask is just TLS_MARK.
607 (ppc64_elf_relocate_section): Likewise.
608 (ppc64_elf_tls_optimize): Don't attempt to optimize indirect
609 __tls_get_addr calls lacking a marker reloc.
610 * elf32-ppc.c (TLS_TLS, TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL,
611 TLS_TPRELGD): Renumber. Update comment.
612 (TLS_MARK, NON_GOT): Define.
613 (PLT_IFUNC): Redefine, and test TLS_TLS throughout file as well.
614 (update_local_sym_info): Don't create got entry when NON_GOT.
615 (ppc_elf_check_relocs): Pass NON_GOT with PLT_IFUNC.
616 Set TLS_MARK.
617 (ppc_elf_tls_optimize): Don't attempt to optimize indirect
618 __tls_get_addr calls lacking a marker reloc.
619
a6fd92b0
L
6202018-04-06 H.J. Lu <hongjiu.lu@intel.com>
621
622 * elf64-x86-64.c (elf_x86_64_info_to_howto): Don't mask out
623 R_X86_64_converted_reloc_bit.
624
3cba8b6c
L
6252018-04-05 H.J. Lu <hongjiu.lu@intel.com>
626
627 PR gas/22318
628 * configure: Regenerated.
629
0e8452bb
AM
6302018-04-05 Alan Modra <amodra@gmail.com>
631
632 * elf-hppa.h (elf_hppa_info_to_howto): Init howto to NULL.
633 (elf_hppa_info_to_howto_rel): Likewise.
634
8ee55178
MR
6352018-04-04 Maciej W. Rozycki <macro@mips.com>
636
637 * elf-hppa.h (elf_hppa_info_to_howto): Also return
638 unsuccessfully for unimplemented relocations.
639 (elf_hppa_info_to_howto_rel): Likewise.
640
5d7c8b80
MR
6412018-04-04 Maciej W. Rozycki <macro@mips.com>
642
643 * elf32-i860.c (lookup_howto): Add `abfd' parameter. Set the
644 `bfd_error_bad_value' error and call `_bfd_error_handler' on a
645 howto lookup failure.
646 (elf32_i860_reloc_type_lookup): Adjust `lookup_howto' call
647 accordingly.
648 (elf32_i860_info_to_howto_rela): Likewise.
649 (elf32_i860_relocate_splitn): Likewise.
650 (elf32_i860_relocate_pc16): Likewise.
651 (elf32_i860_relocate_pc26): Likewise.
652 (elf32_i860_relocate_section): Likewise.
653
707bad1b
MR
6542018-04-04 Maciej W. Rozycki <macro@mips.com>
655
656 * elf32-visium.c (visium_info_to_howto_rela): Correct the range
657 check for `visium_elf_howto_table' table access.
658
0cc919dc
MR
6592018-04-04 Maciej W. Rozycki <macro@mips.com>
660
661 * elf32-iq2000.c (iq2000_info_to_howto_rela): Correct the range
662 check for `iq2000_elf_howto_table' table access.
663
f428698e
MR
6642018-04-04 Maciej W. Rozycki <macro@mips.com>
665
666 * elf32-frv.c (frv_info_to_howto_rela): Correct the range check
667 for `elf32_frv_howto_table' table access.
668
7ed6f92a
MR
6692018-04-04 Maciej W. Rozycki <macro@mips.com>
670
671 * elf32-mips.c (mips_elf32_rtype_to_howto): Also return
672 unsuccessfully for placeholder howtos.
673 * elf64-mips.c (mips_elf64_rtype_to_howto): Likewise.
674 * elfn32-mips.c (mips_elf_n32_rtype_to_howto): Likewise.
675
75def2ab
MR
6762018-03-29 Maciej W. Rozycki <macro@mips.com>
677
678 * elf32-mips.c (mips_info_to_howto_rel): Remove the calls to
679 `_bfd_error_handler' and to set the `bfd_error_bad_value' error.
680
8b6a949a
MR
6812018-03-28 Maciej W. Rozycki <macro@mips.com>
682
683 * elf-hppa.h (elf_hppa_info_to_howto_rel): Remove
684 ATTRIBUTE_UNUSED from `abfd'.
685
d81270c3
MR
6862018-03-28 Maciej W. Rozycki <macro@mips.com>
687
688 * elf-hppa.h (elf_hppa_info_to_howto_rel): Correct
689 `_bfd_error_handler' call formatting.
690
60dceb8d 6912018-03-28 Maciej W. Rozycki <macro@mips.com>
8205a328
MR
692
693 * elf32-mips.c (mips_info_to_howto_rel): Call
694 `mips_elf32_rtype_to_howto' directly rather than via
695 `->elf_backend_mips_rtype_to_howto'.
696
e04ef022
RL
6972018-03-28 Renlin Li <renlin.li@arm.com>
698
699 PR ld/22970
700 * elfnn-aarch64.c (IS_AARCH64_TLS_RELOC): Add cases for
701 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
702 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
703 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
704 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
705 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
706 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
707 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
708 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
709 (elfNN_aarch64_final_link_relocate): Support new relocations.
710 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Support new
711 relocations.
712 (_bfd_aarch64_elf_resolve_relocation): Support new relocations.
713
84f1b9fb
RL
7142018-03-28 Renlin Li <renlin.li@arm.com>
715
716 PR ld/22970
717 * reloc.c: Add BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12
718 BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12_NC,
719 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
720 BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
721 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
722 BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
723 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
724 BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
725 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
726 BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC.
727 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add table entry for
728 TLSLE_LDST16_TPREL_LO12,
729 TLSLE_LDST16_TPREL_LO12_NC,
730 TLSLE_LDST32_TPREL_LO12,
731 TLSLE_LDST32_TPREL_LO12_NC,
732 TLSLE_LDST64_TPREL_LO12,
733 TLSLE_LDST64_TPREL_LO12_NC,
734 TLSLE_LDST8_TPREL_LO12,
735 TLSLE_LDST8_TPREL_LO12_NC.
736 * bfd-in2.h: Regenerated.
737 * libbfd.h: Regenerated.
738
f8745e1c
EB
7392018-03-28 Eric Botcazou <ebotcazou@adacore.com>
740
741 PR ld/22972
742 * elfxx-sparc.c (struct _bfd_sparc_elf_link_hash_entry): Add new flag
743 has_old_style_got_reloc.
744 (_bfd_sparc_elf_check_relocs) <GOT relocations>: Set it for old-style
745 relocations. Fix a couple of long lines.
746 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: Do not generate
747 a R_SPARC_NONE for the GOT slot if the symbol is also subject to old-style
748 GOT relocations.
749
bf54968b
L
7502018-03-25 H.J. Lu <hongjiu.lu@intel.com>
751
752 PR ld/23000
753 * elf64-x86-64.c (elf_x86_64_finish_dynamic_sections): Add
754 ENDBR64 to the TLSDESC PLT entry.
755
0ccf57bd
AM
7562018-03-21 Alan Modra <amodra@gmail.com>
757
758 * elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Trim uninteresting
759 symbols. Use size_t counts. Delete redundant opd test.
760
4bad6366
AM
7612018-03-21 Alan Modra <amodra@gmail.com>
762
763 * elf32-ppc.c (ppc_elf_tls_optimize): Delete locsyms.
764
bac3c8c5
AM
7652018-03-21 Alan Modra <amodra@gmail.com>
766
767 * elf32-ppc.c (struct ppc_elf_link_hash_entry): Make tls_mask
768 field unsigned.
769 (update_local_sym_info): Likewise for local_got_tls_masks.
770 (ppc_elf_tls_optimize): Likewise for lgot_masks.
771
6a3858a6
AM
7722018-03-21 Alan Modra <amodra@gmail.com>
773
774 * elf64-ppc.c (ppc_size_one_stub): Fix comment typo.
775 (ppc64_elf_layout_multitoc): Allocate relocs for tprel as we
776 do in size_dynamic_sections.
777
675e2809
AM
7782018-03-21 Alan Modra <amodra@gmail.com>
779
780 * elf64-ppc.c (ppc64_elf_relocate_section): Don't access rel[1]
781 without first checking array bounds.
782 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
783
416c34d6
L
7842018-03-20 H.J. Lu <hongjiu.lu@intel.com>
785
786 PR ld/22983
787 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Set
788 non_ir_ref_dynamic if a symbol is made dynamic by --dynamic-list.
789
315aa1cf
NC
7902018-03-19 Nick Clifton <nickc@redhat.com>
791
792 * po/es.po: Updated Spanish translation.
793
0854d504
MF
7942018-03-15 Max Filippov <jcmvbkbc@gmail.com>
795
796 * elf32-xtensa.c (xlate_map_entry): Change types of address
797 fields from 'unsigned' to 'bfd_vma'.
798 (xlate_offset_with_removed_text): Use struct xlate_map_entry as
799 the key argument to bsearch. Allow offsets past the end of a
800 section, use the last map entry for translation of such offsets.
801
f9671640
KLC
8022018-03-15 Kuan-Lin Chen <kuanlinchentw@gmail.com>
803
804 * elf32-nds32.c (nds32_elf_ex9_build_hash_table): Removed.
805 Not support the target feature.
806 (nds32_elf_ex9_itb_base): Likewise.
807 (nds32_elf_ex9_import_table): Likewise.
808 (nds32_elf_ex9_finish): Likewise.
809 (nds32_elf_ex9_reloc_jmp): Likewise.
810 (nds32_elf_get_insn_with_reg): Likewise.
811 (nds32_get_local_syms): Likewise.
812 (nds32_elf_ex9_replace_instruction): Likewise.
813 (nds32_elf_ifc_calc): Likewise.
814 (nds32_elf_ifc_finish): Likewise.
815 (nds32_elf_ifc_replace): Likewise.
816 (nds32_elf_ifc_reloc): Likewise.
817
7dda8d3c
AM
8182018-03-14 Alan Modra <amodra@gmail.com>
819
820 * elf64-ppc.c (sfpr_define): Adjust for stub_sec size having
821 sfpr size added before defining alias symbols.
822 (ppc64_elf_build_stubs): Add stub section padding before
823 copying sfpr contents and defining save/restore alias symbols.
824
9e223787
L
8252018-03-14 H.J. Lu <hongjiu.lu@intel.com>
826
827 PR ld/20882
828 * elflink.c (elf_gc_mark_debug_section): Also check the local
829 debug definition section.
830
3e33b239
NC
8312018-03-13 Nick Clifton <nickc@redhat.com>
832
833 PR 22113
834 * pei-x86_64.c (pex64_get_unwind_info): Change to a boolean
835 function. Add an end address parameter. Check access of the data
836 pointer to make sure that they do not extend beyond the end
837 address. Return FALSE if any check fails. Add the end address
838 pointer to the ui structure.
839 (pex64_xdata_print_uwd_codes): Check accesses of the raw unwind
840 codes to make sure that they do not extend beyond the end address
841 pointer. Print an error message and return immediately if any
842 check fails.
843
f657f8c4
NC
8442018-03-09 Nick Clifton <nickc@redhat.com>
845
846 * elf64-s390.c (elf_s390_relocate_section): Move check for
847 relocations against non-allocated sections to before the code that
848 handles ifunc relocations.
849 * elf32-s390.c (elf_s390_relocate_section): Likewise.
850 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Treat
851 relocs against IFUNC symbols in non-allocated sections as relocs
852 against FUNC symbols.
853 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
854
347a8774
L
8552018-03-08 H.J. Lu <hongjiu.lu@intel.com>
856
857 PR ld/22929
858 * elf32-i386.c (elf_i386_relocate_section): Treat relocation
859 against IFUNC symbol in SHT_NOTE section without SHF_ALLOC as
860 relocation against FUNC symbol.
861 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
862
0c1ded8d
RL
8632018-03-07 Renlin Li <renlin.li@arm.com>
864
865 PR ld/20402
866 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Check absolute
867 symbol, and don't emit relocation in specific case.
868
0118219e
AM
8692018-03-07 Alan Modra <amodra@gmail.com>
870
871 * elf64-mips.c (mips_elf64_rtype_to_howto): Return NULL on error.
872 (mips_elf64_slurp_one_reloc_table): Pass on error.
873
dfb93f11
JC
8742018-03-03 James Cowgill <james.cowgill@mips.com>
875 Maciej W. Rozycki <macro@mips.com>
876
877 PR ld/21900
878 * elfxx-mips.c (mips_elf_calculate_relocation): Only return
879 after calling `undefined_symbol' hook if this is an error
880 condition. Assume the value of 0 for the symbol requested
881 otherwise.
882
9a2ebffd
JW
8832018-03-02 Jim Wilson <jimw@sifive.com>
884
885 PR 22903
886 * elfnn-aarch64.c (_bfd_aarch64_resize_stubs): Add 8 bytes for branch
887 and nop instead of 4.
888 (elfNN_arch64_build_stubs): Add nop after branch. Increase size by
889 8 instead of 4.
890
788af978
JW
8912018-03-01 Jim Wilson <jimw@sifive.com>
892
893 PR 22756
894 * elfnn-riscv.c (riscv_relax_delete_bytes): When adjust st_size, use
895 else if instead of if.
896
5224fa03
AM
8972018-03-01 Alan Modra <amodra@gmail.com>
898
899 * elf32-ft32.c (ft32_info_to_howto_rela): Correct range test.
900
116acb2c
AM
9012018-02-28 Alan Modra <amodra@gmail.com>
902
903 PR 22887
904 * aoutx.h (swap_std_reloc_in): Correct r_index bound check.
905
eef10466
NC
9062018-02-28 Nick Clifton <nickc@redhat.com>
907
12c96342
NC
908 PR 22895
909 PR 22893
910 * dwarf2.c (read_n_bytes): Replace size parameter with dwarf_block
911 pointer. Drop unused abfd parameter. Check the size of the block
912 before initialising the data field. Return the end pointer if the
913 size is invalid.
914 (read_attribute_value): Adjust invocations of read_n_bytes.
915
eef10466
NC
916 PR 22894
917 * dwarf1.c (parse_die): Check the length of form blocks before
918 advancing the data pointer.
919
0d329c0a
AM
9202018-02-28 Alan Modra <amodra@gmail.com>
921
922 PR 22887
923 * aoutx.h (translate_symbol_table): Print an error message and set
924 bfd_error on finding an invalid name string offset.
925
f6aec96d
L
9262018-02-27 H.J. Lu <hongjiu.lu@intel.com>
927
928 * config.in: Regenerated.
929 * configure: Likewise.
930 * configure.ac: Add --enable-separate-code.
931 (DEFAULT_LD_Z_SEPARATE_CODE): New AC_DEFINE_UNQUOTED. Default
932 to 1 for Linux/x86 targets,
933 * elf64-x86-64.c (ELF_MAXPAGESIZE): Set to 0x1000 if
934 DEFAULT_LD_Z_SEPARATE_CODE is 1.
935
f3185997
NC
9362018-02-27 Nick Clifton <nickc@redhat.com>
937
e8f5af78
NC
938 * aout-cris.c (swap_ext_reloc_out): Standadize error/warning
939 message.
940 * elf-hppa.h (elf_hppa_info_to_howto_rel): Likewise.
941 * elf32-i386.c (elf_i386_reloc_type_lookup): Likewise.
942 * elf32-xtensa.c (elf_xtensa_reloc_type_lookup): Likewise.
943 * elf64-ppc.c (ppc64_elf_reloc_type_lookup): Likewise.
944 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
945 * elf64-sh64.c (sh_elf64_info_to_howto): Likewise.
946 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
947 * elfxx-sparc.c (_bfd_sparc_elf_reloc_type_lookup): Likewise.
948 * elfxx-tilegx.c (tilegx_reloc_type_lookup): Likewise.
949
f3185997
NC
950 PR 22875
951 * elf-bfd.h (struct elf_backend_data): Change the return type of
952 the elf_info_to_howto and elf_info_to_howto_rel function pointers
953 to bfd_boolean.
954 * elfcode.h (elf_slurp_reloc_table_from_section): Check the return
955 value from the info_to_howto function and fail if that function
956 failed.
957 * elf32-h8300.c (elf32_h8_relocate_section): Check return value
958 from the info_to_howto function.
959 (elf32_h8_relax_section): Likewise.
960 * elf32-lm32.c (lm32_elf_relocate_section): Likewise.
961 * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Likewise.
962 * elf32-score.c (s3_bfd_score_elf_relocate_section): Likewise.
963 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
964 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
965 * elf64-ia64-vms.c (elf64_ia64_relocate_section): Likewise.
966 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Likewise.
967 * elf64-x86-64.c (elf_x86_64_tls_transition): Likewise.
968 * elfnn-ia64.c (elfNN_ia64_relocate_section): Likewise.
969 * elfnn-riscv.c (riscv_elf_check_relocs): Likewise.
970 (riscv_elf_relocate_section): Likewise.
971 * elf-hppa.h (elf_hppa_info_to_howto): Change return type to
972 bfd_boolean. Issue an error message, set an error value and
973 return FALSE if the reloc is not recognized.
974 (elf_hppa_info_to_howto_rel): Likewise.
975 * elf-m10200.c (mn10200_info_to_howto): Likewise.
976 * elf-m10300.c (mn10300_info_to_howto): Likewise.
977 * elf.c (_bfd_elf_no_info_to_howto): Likewise.
978 * elf32-arc.c (arc_info_to_howto_rel): Likewise.
979 * elf32-arm.c (elf32_arm_info_to_howto): Likewise.
980 * elf32-avr.c (avr_info_to_howto_rela): Likewise.
981 * elf32-bfin.c (bfin_info_to_howto): Likewise.
982 * elf32-cr16.c (elf_cr16_info_to_howto): Likewise.
983 * elf32-cr16c.c (elf_cr16c_info_to_howto): Likewise.
984 * elf32-cris.c (elf_cr16c_info_to_howto_rel)
985 (cris_info_to_howto_rela): Likewise.
986 * elf32-crx.c (elf_crx_info_to_howto): Likewise.
987 * elf32-d10v.c (d10v_info_to_howto_rel): Likewise.
988 * elf32-d30v.c (d30v_info_to_howto_rel, d30v_info_to_howto_rela):
989 Likewise.
990 * elf32-dlx.c (dlx_rtype_to_howto, elf32_dlx_info_to_howto)
991 (elf32_dlx_info_to_howto_rel): Likewise.
992 * elf32-epiphany.c (epiphany_info_to_howto_rela): Likewise.
993 * elf32-fr30.c (fr30_info_to_howto_rela): Likewise.
994 * elf32-frv.c (frv_info_to_howto_rela)
995 (frvfdpic_info_to_howto_rel): Likewise.
996 * elf32-ft32.c (ft32_info_to_howto_rela): Likewise.
997 * elf32-gen.c (elf_generic_info_to_howto)
998 (elf_generic_info_to_howto_rel): Likewise.
999 * elf32-h8300.c (elf32_h8_info_to_howto)
1000 (elf32_h8_info_to_howto_rel): Likewise.
1001 * elf32-i370.c (i370_elf_info_to_howto): Likewise.
1002 * elf32-i386.c (elf_i386_reloc_type_lookup)
1003 (elf_i386_rtype_to_howto, elf_i386_info_to_howto_rel): Likewise.
1004 * elf32-i860.c (lookup_howto, elf32_i860_info_to_howto_rela):
1005 Likewise.
1006 * elf32-i960.c (elf32_i960_info_to_howto_rel): Likewise.
1007 * elf32-ip2k.c (ip2k_info_to_howto_rela): Likewise.
1008 * elf32-iq2000.c (iq2000_info_to_howto_rela): Likewise.
1009 * elf32-lm32.c (lm32_info_to_howto_rela): Likewise.
1010 * elf32-m32c.c (m32c_info_to_howto_rela): Likewise.
1011 * elf32-m32r.c (m32r_info_to_howto_rel, m32r_info_to_howto):
1012 Likewise.
1013 * elf32-m68hc11.c (m68hc11_info_to_howto_rel): Likewise.
1014 * elf32-m68hc12.c (m68hc11_info_to_howto_rel): Likewise.
1015 * elf32-m68k.c (rtype_to_howto): Likewise.
1016 * elf32-mcore.c (mcore_elf_info_to_howto): Likewise.
1017 * elf32-mep.c (mep_info_to_howto_rela): Likewise.
1018 * elf32-metag.c (metag_info_to_howto_rela): Likewise.
1019 * elf32-microblaze.c (microblaze_elf_info_to_howto): Likewise.
1020 * elf32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
1021 Likewise.
1022 * elf32-moxie.c (moxie_info_to_howto_rela): Likewise.
1023 * elf32-msp430.c (msp430_info_to_howto_rela): Likewise.
1024 * elf32-mt.c (mt_info_to_howto_rela): Likewise.
1025 * elf32-nds32.c (nds32_info_to_howto_rel, nds32_info_to_howto):
1026 Likewise.
1027 * elf32-nios2.c (nios2_elf32_info_to_howto): Likewise.
1028 * elf32-or1k.c (or1k_info_to_howto_rela): Likewise.
1029 * elf32-pj.c (pj_elf_info_to_howto): Likewise.
1030 * elf32-ppc.c (ppc_elf_info_to_howto): Likewise.
1031 * elf32-pru.c (pru_elf32_info_to_howto): Likewise.
1032 * elf32-rl78.c (rl78_info_to_howto_rela): Likewise.
1033 * elf32-rx.c (rx_info_to_howto_rela): Likewise.
1034 * elf32-s390.c (elf_s390_info_to_howto): Likewise.
1035 * elf32-score.c (s3_bfd_score_info_to_howto)
1036 (_bfd_score_info_to_howto): Likewise.
1037 * elf32-score7.c (s7_bfd_score_info_to_howto): Likewise.
1038 * elf32-sh.c (sh_elf_info_to_howto): Likewise.
1039 * elf32-spu.c (spu_elf_info_to_howto): Likewise.
1040 * elf32-tic6x.c (elf32_tic6x_info_to_howto)
1041 (elf32_tic6x_info_to_howto_rel): Likewise.
1042 * elf32-tilepro.c (tilepro_info_to_howto_rela): Likewise.
1043 * elf32-v850.c (v850_elf_info_to_howto_rel)
1044 (v850_elf_info_to_howto_rela, v800_elf_info_to_howto): Likewise.
1045 * elf32-vax.c (rtype_to_howto): Likewise.
1046 * elf32-visium.c (visium_info_to_howto_rela): Likewise.
1047 * elf32-wasm32.c (elf32_wasm32_rtype_to_howto)
1048 (elf32_wasm32_info_to_howto_rela): Likewise.
1049 * elf32-xc16x.c (elf32_xc16x_info_to_howto): Likewise.
1050 * elf32-xgate.c (xgate_info_to_howto_rel): Likewise.
1051 * elf32-xstormy16.c (xstormy16_info_to_howto_rela): Likewise.
1052 * elf32-xtensa.c (elf_xtensa_info_to_howto_rela): Likewise.
1053 * elf64-alpha.c (elf64_alpha_info_to_howto): Likewise.
1054 * elf64-gen.c (elf_generic_info_to_howto)
1055 (elf_generic_info_to_howto_rel): Likewise.
1056 * elf64-ia64-vms.c (elf64_ia64_info_to_howto): Likewise.
1057 * elf64-mips.c (mips_elf64_info_to_howto_rela): Likewise.
1058 * elf64-mmix.c (mmix_info_to_howto_rela): Likewise.
1059 * elf64-ppc.c (ppc64_elf_info_to_howto): Likewise.
1060 * elf64-s390.c (elf_s390_reloc_type_lookup): Likewise.
1061 * elf64-sh64.c (elf_s390_info_to_howto, sh_elf64_info_to_howto):
1062 Likewise.
1063 * elf64-x86-64.c (elf_x86_64_info_to_howto): Likewise.
1064 * elfn32-mips.c (mips_info_to_howto_rel, mips_info_to_howto_rela):
1065 Likewise.
1066 * elfnn-aarch64.c (elfNN_aarch64_info_to_howto): Likewise.
1067 * elfnn-ia64.c (elfNN_ia64_info_to_howto): Likewise.
1068 * elfnn-riscv.c (riscv_info_to_howto_rela): Likewise.
1069 * elfxx-ia64.c (ia64_elf_reloc_type_lookup): Likewise.
1070 * elfxx-sparc.c (_bfd_sparc_elf_info_to_howto): Likewise.
1071 * elfxx-tilegx.c (tilegx_info_to_howto_rela): Likewise.
1072 * elf32-score.h (s7_bfd_score_info_to_howto): Update prototype.
1073 * elfxx-sparc.h (_bfd_sparc_elf_info_to_howto): Update prototype.
1074 * elfxx-tilegx.h (tilegx_info_to_howto_rela): Update prototype.
1075 * elfxx-target.h (elf_info_to_howto, elf_info_to_howto_rel):
1076 Default to NULL.
1077
1f4bace8
JW
10782018-02-26 Jim Wilson <jimw@sifive.com>
1079 Stephan Schreiber <info@fs-driver.org>
1080
1081 PR 15904
1082 * elfnn-ia64.c (elfNN_ia64_relax_section): After ia64_elf_relax_brl
1083 call, set changed_contents and changed_relocs. Likewise after
1084 successful ia64_elf_relax_br call.
1085
6838f2be
AM
10862018-02-26 Alan Modra <amodra@gmail.com>
1087
1088 * elf.c (assign_file_positions_except_relocs): Don't segfault
1089 when actual number of phdrs is less than allocated. Delete
1090 outdated comment. Formatting.
1091
38f14ab8
AM
10922018-02-26 Alan Modra <amodra@gmail.com>
1093
1094 * elf-m10300.c, * elf-s390-common.c, * elf32-arc.c, * elf32-cris.c,
1095 * elf32-dlx.c, * elf32-frv.c, * elf32-i370.c, * elf32-lm32.c,
1096 * elf32-m32r.c, * elf32-m68hc1x.c, * elf32-m68k.c,
1097 * elf32-microblaze.c, * elf32-msp430.c, * elf32-nds32.c,
1098 * elf32-nios2.c, * elf32-or1k.c, * elf32-rl78.c, * elf32-rx.c,
1099 * elf32-score.c, * elf32-score7.c, * elf32-sh-symbian.c,
1100 * elf32-sh.c, * elf32-spu.c, * elf32-v850.c, * elf32-xtensa.c,
1101 * elf64-alpha.c, * elf64-ia64-vms.c, * elf64-mmix.c,
1102 * elf64-sh64.c, * elf64-sparc.c, * elfnn-ia64.c, * elfxx-tilegx.c,
1103 * mmo.c, * osf-core.c, * srec.c, * vms-alpha.c: Standardize
1104 error/warning messages.
1105
6e05870c
AM
11062018-02-26 Alan Modra <amodra@gmail.com>
1107
1108 * archive.c, * bfd.c, * linker.c, * reloc.c, * stabs.c,
1109 * syms.c: Standardize error/warning messages.
1110
59d08d6c
AM
11112018-02-26 Alan Modra <amodra@gmail.com>
1112
1113 * aout-adobe.c, * aout-cris.c, * i386linux.c, * m68klinux.c,
1114 * sparclinux.c, * coff-alpha.c, * coff-arm.c, * coff-mcore.c,
1115 * coffcode.h, * coffgen.c, * cofflink.c, * ecoff.c, * pe-mips.c,
1116 * peXXigen.c, * peicode.h: Standardize error/warning messages.
1117
90b6238f
AM
11182018-02-26 Alan Modra <amodra@gmail.com>
1119
1120 * elf32-arm.c, * elfnn-aarch64.c: Standardize error/warning messages.
1121
2c1c9679
AM
11222018-02-26 Alan Modra <amodra@gmail.com>
1123
1124 * elfxx-mips.c: Standardize error/warning messages.
1125
9793eb77
AM
11262018-02-26 Alan Modra <amodra@gmail.com>
1127
1128 * dwarf2.c, * elf-attrs.c, * elf-eh-frame.c, * elf.c, * elf32-gen.c,
1129 * elflink.c: Standardize error/warning messages. Replace use of
1130 linker callback einfo with _bfd_error_handler when possible.
1131
0aa13fee
AM
11322018-02-26 Alan Modra <amodra@gmail.com>
1133
1134 * aoutx.h, * coff-alpha.c, * coff-i860.c, * coff-m68k.c,
1135 * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c, * coff-sh.c,
1136 * coff-tic4x.c, * coff-tic54x.c, * coff-tic80.c, * coff-w65.c,
1137 * elf-bfd.h, * elf-m10300.c, * elf.c, * elf32-avr.c, * elf32-bfin.c,
1138 * elf32-cr16.c, * elf32-cr16c.c, * elf32-cris.c, * elf32-crx.c,
1139 * elf32-d10v.c, * elf32-d30v.c, * elf32-dlx.c, * elf32-epiphany.c,
1140 * elf32-fr30.c, * elf32-frv.c, * elf32-i370.c, * elf32-i386.c,
1141 * elf32-i960.c, * elf32-ip2k.c, * elf32-iq2000.c, * elf32-lm32.c,
1142 * elf32-m32c.c, * elf32-m32r.c, * elf32-m68hc11.c, * elf32-m68hc12.c,
1143 * elf32-m68k.c, * elf32-mcore.c, * elf32-mep.c, * elf32-metag.c,
1144 * elf32-microblaze.c, * elf32-mips.c, * elf32-moxie.c,
1145 * elf32-msp430.c, * elf32-mt.c, * elf32-nds32.c, * elf32-or1k.c,
1146 * elf32-pj.c, * elf32-ppc.c, * elf32-rl78.c, * elf32-rx.c,
1147 * elf32-s390.c, * elf32-sh.c, * elf32-spu.c, * elf32-tic6x.c,
1148 * elf32-v850.c, * elf32-vax.c, * elf32-visium.c, * elf32-wasm32.c,
1149 * elf32-xgate.c, * elf32-xtensa.c, * elf64-alpha.c,
1150 * elf64-ia64-vms.c, * elf64-mips.c, * elf64-mmix.c,
1151 * elf64-ppc.c, * elf64-s390.c, * elf64-sparc.c, * elf64-x86-64.c,
1152 * elfn32-mips.c, * elfnn-aarch64.c, * elfnn-ia64.c,
1153 * elfnn-riscv.c, * elfxx-mips.c, * elfxx-riscv.c, * elfxx-riscv.h,
1154 * elfxx-sparc.c, * elfxx-sparc.h, * reloc.c: Standardize
1155 unrecognized/unsupported reloc message.
1156
cf97bcb0
AM
11572018-02-26 Alan Modra <amodra@gmail.com>
1158
1159 * elf32-ppc.c: Standardize error/warning messages. Use
1160 _bfd_error_handler rather than einfo when einfo features not used.
1161 * elf64-ppc.c: Likewise.
1162
01f7e10c
AM
11632018-02-23 Alan Modra <amodra@gmail.com>
1164
1165 PR 22881
1166 * elf.c (assign_file_positions_for_non_load_sections): Remove RELRO
1167 segment if no matching LOAD segment.
1168
e859f655
KLC
11692018-02-23 Kuan-Lin Chen <kuanlinchentw@gmail.com>
1170
1171 * elf32-nds32.h: Define mask for ict_model.
1172
6e8d06db
JD
11732018-02-20 Jason Duerstock <jason.duerstock@gmail.com>
1174
1175 * elfnn-ia64.c (elf_backend_can_gc_sections): Enable.
1176
b248d650
MR
11772018-02-19 Maciej W. Rozycki <macro@mips.com>
1178
1179 Revert
1180 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
1181
1182 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
1183 .reginfo section has wrong size.
1184
6798f8bf
MR
11852018-02-19 Maciej W. Rozycki <macro@mips.com>
1186
1187 * elfxx-mips.c (_bfd_mips_elf_always_size_sections): Set
1188 SEC_FIXED_SIZE and SEC_HAS_CONTENTS flags for `.reginfo' and
1189 `.MIPS.abiflags' sections.
1190 (_bfd_mips_elf_final_link): Avoid reading beyond `.reginfo'
1191 section's end.
1192
8772de11
MR
11932018-02-19 Maciej W. Rozycki <macro@mips.com>
1194
1195 * section.c (SEC_FIXED_SIZE): New macro.
1196 * bfd-in2.h: Regenerate.
1197
4f7fd351
MR
11982018-02-19 Maciej W. Rozycki <macro@mips.com>
1199
1200 * section.c (SEC_HAS_GOT_REF): Remove macro.
1201 * bfd-in2.h: Regenerate.
1202
f2b740ac
AM
12032018-02-19 Alan Modra <amodra@gmail.com>
1204
1205 * elf-attrs.c (_bfd_elf_parse_attributes): Correct _bfd_error_handler
1206 arguments.
1207 * elfxx-mips.c (_bfd_mips_elf_final_link): Likewise.
1208 * elfnn-riscv.c (_bfd_riscv_relax_align): Likewise.
1209 (_bfd_riscv_relax_pc): Likewise and fix typos.
1210 * libbfd-in.h (_bfd_error_handler): Add attribute printf.
1211 * libbfd.h: Regenerate.
1212
8979927a
AM
12132018-02-19 Alan Modra <amodra@gmail.com>
1214
1215 * dwarf2.c (read_section): Don't use 'll' format modifier.
1216 (find_abstract_instance): Likewise.
1217 * elfcore.h (elf_core_file_p): Likewise.
1218
2dcf00ce
AM
12192018-02-19 Alan Modra <amodra@gmail.com>
1220
1221 * bfd-in.h: Include inttypes.h or if not available define
1222 PRId64, PRIu64 and PRIx64.
1223 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Remove support for L
1224 modifier to print bfd_vma.
1225 * coff-arm.c, * coff-mcore.c, * coff-ppc.c, * coff-rs6000.c,
1226 * coff-sh.c, * coff-tic80.c, * coffcode.h, * coffgen.c, * cofflink.c,
1227 * compress.c, * dwarf2.c, * elf-m10300.c, * elf.c, * elf32-arc.c,
1228 * elf32-arm.c, * elf32-bfin.c, * elf32-cris.c, * elf32-hppa.c,
1229 * elf32-i386.c, * elf32-ip2k.c, * elf32-lm32.c, * elf32-m32r.c,
1230 * elf32-m68k.c, * elf32-metag.c, * elf32-nds32.c, * elf32-nios2.c,
1231 * elf32-ppc.c, * elf32-rx.c, * elf32-s390.c, * elf32-score.c,
1232 * elf32-score7.c, * elf32-sh.c, * elf32-sh64.c, * elf32-spu.c,
1233 * elf32-tic6x.c, * elf32-tilepro.c, * elf32-v850.c, * elf32-vax.c,
1234 * elf32-xtensa.c, * elf64-alpha.c, * elf64-hppa.c, * elf64-ia64-vms.c,
1235 * elf64-mmix.c, * elf64-s390.c, * elf64-sh64.c, * elf64-x86-64.c,
1236 * elfcode.h, * elfcore.h, * elflink.c, * elfnn-aarch64.c,
1237 * elfnn-ia64.c, * elfnn-riscv.c, * elfxx-mips.c, * elfxx-sparc.c,
1238 * elfxx-tilegx.c, * ieee.c, * ihex.c, * mach-o.c, * merge.c, * mmo.c,
1239 * peXXigen.c, * xcofflink.c: Replace use of Lx modifier with PRIx64,
1240 and cast input to uint64_t, and similarly for Ld and Lu.
1241 * bfd-in2.h: Regenerate.
1242
c1c8c1ef
AM
12432018-02-19 Alan Modra <amodra@gmail.com>
1244
1245 * elf32-arm.c, * elf32-hppa.c, * elf32-lm32.c, * elf32-m32r.c,
1246 * elf32-metag.c, * elf32-nds32.c, * elf32-or1k.c, * elf32-ppc.c,
1247 * elf32-s390.c, * elf32-sh.c, * elf32-tic6x.c, * elf32-tilepro.c,
1248 * elf64-ppc.c, * elf64-s390.c, * elflink.c, * elfnn-aarch64.c,
1249 * elfnn-riscv.c, * elfxx-sparc.c, * elfxx-tilegx.c, * elfxx-x86.c,
1250 * reloc.c: Replace use of %R and %T in format strings passed to
1251 einfo and friends by %pR and %pT.
1252
871b3ab2
AM
12532018-02-19 Alan Modra <amodra@gmail.com>
1254
1255 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Handle %pA and %pB in place
1256 of %A and %B.
1257 * aout-adobe.c: Update all messages using %A and %B.
1258 * aout-cris.c: Likewise.
1259 * aoutx.h: Likewise.
1260 * archive.c: Likewise.
1261 * binary.c: Likewise.
1262 * cache.c: Likewise.
1263 * coff-alpha.c: Likewise.
1264 * coff-arm.c: Likewise.
1265 * coff-i860.c: Likewise.
1266 * coff-mcore.c: Likewise.
1267 * coff-ppc.c: Likewise.
1268 * coff-rs6000.c: Likewise.
1269 * coff-sh.c: Likewise.
1270 * coff-tic4x.c: Likewise.
1271 * coff-tic54x.c: Likewise.
1272 * coff-tic80.c: Likewise.
1273 * coff64-rs6000.c: Likewise.
1274 * coffcode.h: Likewise.
1275 * coffgen.c: Likewise.
1276 * cofflink.c: Likewise.
1277 * coffswap.h: Likewise.
1278 * compress.c: Likewise.
1279 * cpu-arm.c: Likewise.
1280 * ecoff.c: Likewise.
1281 * elf-attrs.c: Likewise.
1282 * elf-eh-frame.c: Likewise.
1283 * elf-ifunc.c: Likewise.
1284 * elf-m10300.c: Likewise.
1285 * elf-properties.c: Likewise.
1286 * elf-s390-common.c: Likewise.
1287 * elf.c: Likewise.
1288 * elf32-arc.c: Likewise.
1289 * elf32-arm.c: Likewise.
1290 * elf32-avr.c: Likewise.
1291 * elf32-bfin.c: Likewise.
1292 * elf32-cr16.c: Likewise.
1293 * elf32-cr16c.c: Likewise.
1294 * elf32-cris.c: Likewise.
1295 * elf32-crx.c: Likewise.
1296 * elf32-d10v.c: Likewise.
1297 * elf32-d30v.c: Likewise.
1298 * elf32-epiphany.c: Likewise.
1299 * elf32-fr30.c: Likewise.
1300 * elf32-frv.c: Likewise.
1301 * elf32-gen.c: Likewise.
1302 * elf32-hppa.c: Likewise.
1303 * elf32-i370.c: Likewise.
1304 * elf32-i386.c: Likewise.
1305 * elf32-i960.c: Likewise.
1306 * elf32-ip2k.c: Likewise.
1307 * elf32-iq2000.c: Likewise.
1308 * elf32-lm32.c: Likewise.
1309 * elf32-m32c.c: Likewise.
1310 * elf32-m32r.c: Likewise.
1311 * elf32-m68hc11.c: Likewise.
1312 * elf32-m68hc12.c: Likewise.
1313 * elf32-m68hc1x.c: Likewise.
1314 * elf32-m68k.c: Likewise.
1315 * elf32-mcore.c: Likewise.
1316 * elf32-mep.c: Likewise.
1317 * elf32-metag.c: Likewise.
1318 * elf32-microblaze.c: Likewise.
1319 * elf32-moxie.c: Likewise.
1320 * elf32-msp430.c: Likewise.
1321 * elf32-mt.c: Likewise.
1322 * elf32-nds32.c: Likewise.
1323 * elf32-nios2.c: Likewise.
1324 * elf32-or1k.c: Likewise.
1325 * elf32-pj.c: Likewise.
1326 * elf32-ppc.c: Likewise.
1327 * elf32-rl78.c: Likewise.
1328 * elf32-rx.c: Likewise.
1329 * elf32-s390.c: Likewise.
1330 * elf32-score.c: Likewise.
1331 * elf32-score7.c: Likewise.
1332 * elf32-sh-symbian.c: Likewise.
1333 * elf32-sh.c: Likewise.
1334 * elf32-sh64.c: Likewise.
1335 * elf32-sparc.c: Likewise.
1336 * elf32-spu.c: Likewise.
1337 * elf32-tic6x.c: Likewise.
1338 * elf32-tilepro.c: Likewise.
1339 * elf32-v850.c: Likewise.
1340 * elf32-vax.c: Likewise.
1341 * elf32-visium.c: Likewise.
1342 * elf32-wasm32.c: Likewise.
1343 * elf32-xgate.c: Likewise.
1344 * elf32-xtensa.c: Likewise.
1345 * elf64-alpha.c: Likewise.
1346 * elf64-gen.c: Likewise.
1347 * elf64-hppa.c: Likewise.
1348 * elf64-ia64-vms.c: Likewise.
1349 * elf64-mmix.c: Likewise.
1350 * elf64-ppc.c: Likewise.
1351 * elf64-s390.c: Likewise.
1352 * elf64-sh64.c: Likewise.
1353 * elf64-sparc.c: Likewise.
1354 * elf64-x86-64.c: Likewise.
1355 * elfcode.h: Likewise.
1356 * elfcore.h: Likewise.
1357 * elflink.c: Likewise.
1358 * elfnn-aarch64.c: Likewise.
1359 * elfnn-ia64.c: Likewise.
1360 * elfnn-riscv.c: Likewise.
1361 * elfxx-mips.c: Likewise.
1362 * elfxx-sparc.c: Likewise.
1363 * elfxx-tilegx.c: Likewise.
1364 * elfxx-x86.c: Likewise.
1365 * hpux-core.c: Likewise.
1366 * ieee.c: Likewise.
1367 * ihex.c: Likewise.
1368 * libbfd.c: Likewise.
1369 * linker.c: Likewise.
1370 * mach-o.c: Likewise.
1371 * merge.c: Likewise.
1372 * mmo.c: Likewise.
1373 * oasys.c: Likewise.
1374 * pdp11.c: Likewise.
1375 * pe-mips.c: Likewise.
1376 * peXXigen.c: Likewise.
1377 * peicode.h: Likewise.
1378 * reloc.c: Likewise.
1379 * rs6000-core.c: Likewise.
1380 * srec.c: Likewise.
1381 * stabs.c: Likewise.
1382 * vms-alpha.c: Likewise.
1383 * xcofflink.c: Likewise.
1384
dbc88fc1
AM
13852018-02-19 Alan Modra <amodra@gmail.com>
1386
1387 PR 22845
1388 * elf.c (IS_TBSS): Define.
1389 (_bfd_elf_map_sections_to_segments): Use IS_TBSS.
1390 (assign_file_positions_for_non_load_sections): Revert last change.
1391 Properly calculate load segment limits to compare against relro limits.
1392
325ba6fb
AM
13932018-02-17 Alan Modra <amodra@gmail.com>
1394
1395 PR 22845
1396 * elf.c (assign_file_positions_for_non_load_sections): Ignore
1397 degenerate zero size PT_LOAD segments when finding one overlapping
1398 the PT_GNU_RELRO segment.
1399
d00dd7dc
AM
14002018-02-16 Alan Modra <amodra@gmail.com>
1401
1402 * libbfd.c (_bfd_bool_bfd_false_error): Rename from bfd_false.
1403 (_bfd_bool_bfd_true): Rename from bfd_true.
1404 (_bfd_ptr_bfd_null_error): Rename from bfd_nullvoidptr.
1405 (_bfd_int_bfd_0): Rename from bfd_0.
1406 (_bfd_uint_bfd_0): Rename from bfd_0u.
1407 (_bfd_long_bfd_0): Rename from bfd_0l.
1408 (_bfd_long_bfd_n1_error): Rename from _bfd_n1.
1409 (_bfd_void_bfd): Rename from bfd_void.
1410 (_bfd_bool_bfd_false, _bfd_bool_bfd_asymbol_false),
1411 (_bfd_bool_bfd_link_false_error),
1412 (_bfd_bool_bfd_link_true, _bfd_bool_bfd_bfd_true),
1413 (_bfd_bool_bfd_uint_true, _bfd_bool_bfd_ptr_true),
1414 (_bfd_bool_bfd_asection_bfd_asection_true),
1415 (_bfd_bool_bfd_asymbol_bfd_asymbol_true),
1416 (_bfd_void_bfd_link, _bfd_void_bfd_asection): New functions.
1417 * archive.c (_bfd_noarchive_get_elt_at_index),
1418 (_bfd_noarchive_openr_next_archived_file),
1419 (_bfd_noarchive_construct_extended_name_table),
1420 (_bfd_noarchive_write_ar_hdr, _bfd_noarchive_truncate_arname),
1421 (_bfd_noarchive_write_armap): New functions.
1422 * archures.c (_bfd_nowrite_set_arch_mach): New function.
1423 * coff-alpha.c (alpha_ecoff_swap_coff_aux_in),
1424 (alpha_ecoff_swap_coff_sym_in, alpha_ecoff_swap_coff_lineno_in),
1425 (alpha_ecoff_swap_coff_aux_out, alpha_ecoff_swap_coff_sym_out),
1426 (alpha_ecoff_swap_coff_lineno_out),
1427 (alpha_ecoff_swap_coff_reloc_out): New functions.
1428 * coff-mips.c (mips_ecoff_swap_coff_aux_in),
1429 (mips_ecoff_swap_coff_sym_in, mips_ecoff_swap_coff_lineno_in),
1430 (mips_ecoff_swap_coff_aux_out, mips_ecoff_swap_coff_sym_out),
1431 (mips_ecoff_swap_coff_lineno_out),
1432 (mips_ecoff_swap_coff_reloc_out): New functions.
1433 * coffcode.h (coff_set_alignment_hook): Replace define with
1434 new function.
1435 (symname_in_debug_hook): Likewise.
1436 * ecoff.c (_bfd_ecoff_set_alignment_hook): New function.
1437 * elfxx-target.h (elf_backend_allow_non_load_phdr): Default to 0.
1438 * elf.c (assign_file_positions_except_relocs): Test
1439 elf_backend_allow_non_load_phdr for NULL.
1440 * elflink.c (_bfd_elf_omit_section_dynsym_default): Rename from
1441 _bfd_elf_link_omit_section_dynsym. Update uses.
1442 (_bfd_elf_omit_section_dynsym_all): New function.
1443 * elf-bfd.h (_bfd_elf_link_omit_section_dynsym): Delete.
1444 (_bfd_elf_omit_section_dynsym_default): Declare.
1445 (_bfd_elf_omit_section_dynsym_all): Declare.
1446 * linker.c (_bfd_nolink_sizeof_headers, _bfd_nolink_bfd_relax_section),
1447 (_bfd_nolink_bfd_get_relocated_section_contents),
1448 (_bfd_nolink_bfd_lookup_section_flags),
1449 (_bfd_nolink_bfd_is_group_section, _bfd_nolink_bfd_discard_group),
1450 (_bfd_nolink_bfd_link_hash_table_create),
1451 (_bfd_nolink_bfd_link_just_syms),
1452 (_bfd_nolink_bfd_copy_link_hash_symbol_type),
1453 (_bfd_nolink_bfd_link_split_section),
1454 (_bfd_nolink_section_already_linked),
1455 (_bfd_nolink_bfd_define_common_symbol),
1456 (_bfd_nolink_bfd_define_start_stop): New functions.
1457 * reloc.c (_bfd_norelocs_bfd_reloc_type_lookup),
1458 (_bfd_norelocs_bfd_reloc_name_lookup),
1459 (_bfd_nodynamic_canonicalize_dynamic_reloc): New functions.
1460 * section.c (_bfd_nowrite_set_section_contents): New function.
1461 * syms.c (_bfd_nosymbols_canonicalize_symtab),
1462 (_bfd_nosymbols_print_symbol, _bfd_nosymbols_get_symbol_info),
1463 (_bfd_nosymbols_get_symbol_version_string),
1464 (_bfd_nosymbols_bfd_is_local_label_name),
1465 (_bfd_nosymbols_get_lineno, _bfd_nosymbols_find_nearest_line),
1466 (_bfd_nosymbols_find_line, _bfd_nosymbols_find_inliner_info),
1467 (_bfd_nosymbols_bfd_make_debug_symbol),
1468 ( _bfd_nosymbols_read_minisymbols),
1469 ( _bfd_nosymbols_minisymbol_to_symbol),
1470 (_bfd_nodynamic_get_synthetic_symtab): New functions.
1471 * libbfd-in.h: Declare new functions. Update existing defines,
1472 removing casts.
1473 * aix386-core.c: Update to use new hooks. Formatting.
1474 * aout-adobe.c: Likewise.
1475 * aout-arm.c: Likewise.
1476 * aout-target.h: Likewise.
1477 * aout-tic30.c: Likewise.
1478 * aoutf1.h: Likewise.
1479 * binary.c: Likewise.
1480 * bout.c: Likewise.
1481 * cisco-core.c: Likewise.
1482 * coff-alpha.c: Likewise.
1483 * coff-i386.c: Likewise.
1484 * coff-i860.c: Likewise.
1485 * coff-i960.c: Likewise.
1486 * coff-ia64.c: Likewise.
1487 * coff-mips.c: Likewise.
1488 * coff-ppc.c: Likewise.
1489 * coff-rs6000.c: Likewise.
1490 * coff-sh.c: Likewise.
1491 * coff-tic30.c: Likewise.
1492 * coff-tic54x.c: Likewise.
1493 * coff-x86_64.c: Likewise.
1494 * coff64-rs6000.c: Likewise.
1495 * coffcode.h: Likewise.
1496 * elf-m10300.c: Likewise.
1497 * elf32-cr16.c: Likewise.
1498 * elf32-lm32.c: Likewise.
1499 * elf32-m32r.c: Likewise.
1500 * elf32-metag.c: Likewise.
1501 * elf32-score.c: Likewise.
1502 * elf32-score7.c: Likewise.
1503 * elf32-tilepro.c: Likewise.
1504 * elf32-xstormy16.c: Likewise.
1505 * elf32-xtensa.c: Likewise.
1506 * elf64-alpha.c: Likewise.
1507 * elf64-hppa.c: Likewise.
1508 * elf64-ia64-vms.c: Likewise.
1509 * elf64-mmix.c: Likewise.
1510 * elf64-sh64.c: Likewise.
1511 * elfnn-ia64.c: Likewise.
1512 * elfxx-sparc.c: Likewise.
1513 * elfxx-target.h: Likewise.
1514 * elfxx-tilegx.c: Likewise.
1515 * elfxx-x86.h: Likewise.
1516 * hp300hpux.c: Likewise.
1517 * hppabsd-core.c: Likewise.
1518 * hpux-core.c: Likewise.
1519 * i386msdos.c: Likewise.
1520 * i386os9k.c: Likewise.
1521 * ieee.c: Likewise.
1522 * ihex.c: Likewise.
1523 * irix-core.c: Likewise.
1524 * libaout.h: Likewise.
1525 * libecoff.h: Likewise.
1526 * mach-o-target.c: Likewise.
1527 * mach-o.c: Likewise.
1528 * mipsbsd.c: Likewise.
1529 * mmo.c: Likewise.
1530 * netbsd-core.c: Likewise.
1531 * nlm-target.h: Likewise.
1532 * oasys.c: Likewise.
1533 * osf-core.c: Likewise.
1534 * pdp11.c: Likewise.
1535 * pe-mips.c: Likewise.
1536 * pe-x86_64.c: Likewise.
1537 * pef.c: Likewise.
1538 * plugin.c: Likewise.
1539 * ppcboot.c: Likewise.
1540 * ptrace-core.c: Likewise.
1541 * sco5-core.c: Likewise.
1542 * som.c: Likewise.
1543 * sparclynx.c: Likewise.
1544 * srec.c: Likewise.
1545 * tekhex.c: Likewise.
1546 * trad-core.c: Likewise.
1547 * verilog.c: Likewise.
1548 * versados.c: Likewise.
1549 * vms-alpha.c: Likewise.
1550 * vms-lib.c: Likewise.
1551 * wasm-module.c: Likewise.
1552 * xsym.c: Likewise.
1553 * libbfd.h: Regenerate.
1554
2a0d9853
JW
15552018-02-15 Jim Wilson <jimw@sifive.com>
1556
09ca4b9d
JW
1557 * elfnn-riscv.c (_bfd_riscv_relax_section): Ifdef out check to ignore
1558 symbols whose section address is zero.
1559
2a0d9853
JW
1560 * elfnn-riscv.c (riscv_elf_relocate_section): Use bfd_reloc_dangerous
1561 when pcrel_lo reloc has an addend. Use reloc_dangerous callback for
1562 bfd_reloc_dangerous. Use einfo instead of warning callback for errors.
1563 Add %X%P to error messages.
1564
e513bd38
EB
15652018-02-15 Eric Botcazou <ebotcazou@adacore.com>
1566
1567 PR ld/22832
1568 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
1569 Pass FALSE instead of TRUE as 'create' argument to bfd_link_hash_lookup
1570 and assert that the result of the call is not NULL.
1571
12ef3f5a
NC
15722018-02-14 Nick Clifton <nickc@redhat.com>
1573
1574 PR 22823
1575 Revert previous delta. Add extra casts to avoid compile time
1576 warnings instead.
1577 * libbfd-in.h (_bfd_generic_bfd_copy_private_bfd_data): Add extra
1578 cast to avoid warning from gcc v8 compiler.
1579 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
1580 (_bfd_generic_bfd_set_private_flags): Likewise.
1581 (_bfd_generic_bfd_copy_private_section_data): Likewise.
1582 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
1583 (_bfd_generic_bfd_copy_private_header_data): Likewise.
1584 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
1585 (_bfd_noarchive_construct_extended_name_table): Likewise.
1586 (_bfd_noarchive_truncate_arname): Likewise.
1587 (_bfd_noarchive_write_ar_hdr): Likewise.
1588 (_bfd_noarchive_get_elt_at_index): Likewise.
1589 (_bfd_nosymbols_canonicalize_symtab): Likewise.
1590 (_bfd_nosymbols_print_symbol): Likewise.
1591 (_bfd_nosymbols_get_symbol_info): Likewise.
1592 (_bfd_nosymbols_get_symbol_version_string): Likewise.
1593 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
1594 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
1595 (_bfd_nosymbols_get_lineno): Likewise.
1596 (_bfd_nosymbols_find_nearest_line): Likewise.
1597 (_bfd_nosymbols_find_line): Likewise.
1598 (_bfd_nosymbols_find_inliner_info): Likewise.
1599 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
1600 (_bfd_nosymbols_read_minisymbols): Likewise.
1601 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
1602 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
1603 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
1604 (_bfd_nowrite_set_arch_mach): Likewise.
1605 (_bfd_nowrite_set_section_contents): Likewise.
1606 (_bfd_nolink_sizeof_headers): Likewise.
1607 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
1608 (_bfd_nolink_bfd_relax_section): Likewise.
1609 (_bfd_nolink_bfd_gc_sections): Likewise.
1610 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
1611 (_bfd_nolink_bfd_merge_sections): Likewise.
1612 (_bfd_nolink_bfd_is_group_section): Likewise.
1613 (_bfd_nolink_bfd_discard_group): Likewise.
1614 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
1615 (_bfd_nolink_bfd_link_add_symbols): Likewise.
1616 (_bfd_nolink_bfd_link_just_syms): Likewise.
1617 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
1618 (_bfd_nolink_bfd_final_link): Likewise.
1619 (_bfd_nolink_bfd_link_split_section): Likewise.
1620 (_bfd_nolink_section_already_linked): Likewise.
1621 (_bfd_nolink_bfd_define_common_symbol): Likewise.
1622 (_bfd_nolink_bfd_define_start_stop): Likewise.
1623 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
1624 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
1625 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
1626 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
1627 * libbfd.c (bfd_false_any): Delete.
1628 (bfd_true_any, bfd_nullvoidptr_any, bfd_0_any): Delete.
1629 (bfd_0u_any, bfd_0l_any, _bfd_n1_any, bfd_void_any): Delete.
1630 * libbfd.h (extern): Regenerate
1631 * aout-target.h (MY_bfd_is_target_special_symbol): Add extra
1632 cast to avoid warning from gcc v8 compiler.
1633 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
1634 * binary.c (binary_get_symbol_info): Likewise.
1635 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
1636 * coff-mips.c (mips_ecoff_backend_data): Likewise.
1637 * coffcode.h (coff_set_alignment_hook): Likewise.
1638 (symname_in_debug_hook): Likewise.
1639 (bfd_coff_backend_data bigobj_swap_table): Likewise.
1640 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
1641 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
1642 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
1643 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
1644 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
1645 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
1646 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
1647 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
1648 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
1649 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
1650 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
1651 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
1652 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
1653 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
1654 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
1655 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
1656 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
1657 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
1658 (bfd_elfNN_bfd_set_private_flags): Likewise.
1659 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
1660 (elf_backend_init_index_section): Likewise.
1661 (elf_backend_allow_non_load_phdr): Likewise.
1662 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
1663 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
1664 * ieee.c (ieee_construct_extended_name_table): Likewise.
1665 (ieee_write_armap): Likewise.
1666 (ieee_write_ar_hdr): Likewise.
1667 (ieee_bfd_is_target_special_symbol): Likewise.
1668 * ihex.c (ihex_canonicalize_symtab): Likewise.
1669 (ihex_bfd_is_target_special_symbol): Likewise.
1670 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
1671 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
1672 (_bfd_ecoff_set_alignment_hook): Likewise.
1673 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
1674 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
1675 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
1676 * oasys.c (oasys_construct_extended_name_table): Likewise.
1677 (oasys_write_armap): Likewise.
1678 (oasys_write_ar_hdr): Likewise.
1679 (oasys_bfd_is_target_special_symbol): Likewise.
1680 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
1681 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
1682 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
1683 * som.c (som_bfd_is_target_special_symbol): Likewise.
1684 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
1685 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
1686 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
1687 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
1688 (versados_bfd_reloc_name_lookup): Likewise.
1689 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
1690 (vms_bfd_define_start_stop): Likewise.
1691 (alpha_vms_bfd_is_target_special_symbol): Likewise.
1692 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
1693 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
1694
451875b4
L
16952018-02-14 H.J. Lu <hongjiu.lu@intel.com>
1696
1697 PR ld/22842
1698 * elf32-i386.c (elf_i386_check_relocs): Pass FALSE for non
1699 PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
1700 * elf64-x86-64.c (elf_x86_64_check_relocs): Create PLT for
1701 R_X86_64_PC32 reloc against dynamic function in data section.
1702 Pass TRUE for PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
1703 (elf_x86_64_relocate_section): Use PLT for R_X86_64_PC32 reloc
1704 against dynamic function in data section.
1705 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Use PLT in PIE as
1706 function address only if pcrel_plt is true.
1707 (_bfd_x86_elf_link_hash_table_create): Set pcrel_plt.
1708 * elfxx-x86.h (NEED_DYNAMIC_RELOCATION_P): Add PCREL_PLT for
1709 PC-relative PLT. If PLT is PC-relative, don't generate dynamic
1710 PC-relative relocation against a function definition in data
1711 secton in PIE. Remove the obsolete comments.
1712 (elf_x86_link_hash_table): Add pcrel_plt.
1713
1031c264
L
17142018-02-13 H.J. Lu <hongjiu.lu@intel.com>
1715
1716 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Check bfd_link_dll,
1717 instead of bfd_link_pic, for building shared library.
1718
bd7ab16b
L
17192018-02-13 H.J. Lu <hongjiu.lu@intel.com>
1720
1721 PR gas/22791
1722 * elf64-x86-64.c (is_32bit_relative_branch): Removed.
1723 (elf_x86_64_relocate_section): Check PIC relocations in PIE.
1724 Remove is_32bit_relative_branch usage. Disallow PC32 reloc
1725 against protected function in shared object.
1726
80c96350
ST
17272018-02-13 Sergei Trofimovich <slyfox@inbox.ru>
1728
1729 PR 22828
1730 * po/ru.po: Fix typo in Russian translation.
1731
87993319
MR
17322018-02-13 Maciej W. Rozycki <macro@mips.com>
1733
1734 * wasm-module.c (wasm_scan_name_function_section): Rename
1735 `index' local variable to `idx'.
1736
68d20676
NC
17372018-02-13 Nick Clifton <nickc@redhat.com>
1738
1739 PR 22823
1740 Fix compile time warnings generated by gcc version 8.
1741 * libbfd-in.h: Remove extraneous text from prototypes.
1742 Add prototypes for bfd_false_any, bfd_true_any,
1743 bfd_nullvoidptr_any, bfd_0_any, bfd_0u_any, bfd_0l_any,
1744 bfd_n1_any, bfd_void_any.
1745 (_bfd_generic_bfd_copy_private_bfd_data): Use vararg based dummy
1746 function.
1747 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
1748 (_bfd_generic_bfd_set_private_flags): Likewise.
1749 (_bfd_generic_bfd_copy_private_section_data): Likewise.
1750 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
1751 (_bfd_generic_bfd_copy_private_header_data): Likewise.
1752 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
1753 (_bfd_noarchive_construct_extended_name_table): Likewise.
1754 (_bfd_noarchive_truncate_arname): Likewise.
1755 (_bfd_noarchive_write_ar_hdr): Likewise.
1756 (_bfd_noarchive_get_elt_at_index): Likewise.
1757 (_bfd_nosymbols_canonicalize_symtab): Likewise.
1758 (_bfd_nosymbols_print_symbol): Likewise.
1759 (_bfd_nosymbols_get_symbol_info): Likewise.
1760 (_bfd_nosymbols_get_symbol_version_string): Likewise.
1761 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
1762 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
1763 (_bfd_nosymbols_get_lineno): Likewise.
1764 (_bfd_nosymbols_find_nearest_line): Likewise.
1765 (_bfd_nosymbols_find_line): Likewise.
1766 (_bfd_nosymbols_find_inliner_info): Likewise.
1767 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
1768 (_bfd_nosymbols_read_minisymbols): Likewise.
1769 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
1770 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
1771 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
1772 (_bfd_nowrite_set_arch_mach): Likewise.
1773 (_bfd_nowrite_set_section_contents): Likewise.
1774 (_bfd_nolink_sizeof_headers): Likewise.
1775 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
1776 (_bfd_nolink_bfd_relax_section): Likewise.
1777 (_bfd_nolink_bfd_gc_sections): Likewise.
1778 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
1779 (_bfd_nolink_bfd_merge_sections): Likewise.
1780 (_bfd_nolink_bfd_is_group_section): Likewise.
1781 (_bfd_nolink_bfd_discard_group): Likewise.
1782 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
1783 (_bfd_nolink_bfd_link_add_symbols): Likewise.
1784 (_bfd_nolink_bfd_link_just_syms): Likewise.
1785 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
1786 (_bfd_nolink_bfd_final_link): Likewise.
1787 (_bfd_nolink_bfd_link_split_section): Likewise.
1788 (_bfd_nolink_section_already_linked): Likewise.
1789 (_bfd_nolink_bfd_define_common_symbol): Likewise.
1790 (_bfd_nolink_bfd_define_start_stop): Likewise.
1791 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
1792 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
1793 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
1794 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
1795 * libbfd.c (bfd_false_any): New function. Like bfd_false but
1796 accepts one or more arguments.
1797 (bfd_true_any): Likewise.
1798 (bfd_nullvoidptr_any): Likewise.
1799 (bfd_0_any): Likewise.
1800 (bfd_0u_any): Likewise.
1801 (bfd_0l_any): Likewise.
1802 (_bfd_n1_any): Likewise.
1803 (bfd_void_any): Likewise.
1804 * libbfd.h (extern): Regenerate
1805 * aout-target.h (MY_bfd_is_target_special_symbol): Use vararg
1806 based dummy function.
1807 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
1808 * binary.c (binary_get_symbol_info): Likewise.
1809 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
1810 * coff-mips.c (mips_ecoff_backend_data): Likewise.
1811 * coffcode.h (coff_set_alignment_hook): Likewise.
1812 (symname_in_debug_hook): Likewise.
1813 (bfd_coff_backend_data bigobj_swap_table): Likewise.
1814 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
1815 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
1816 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
1817 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
1818 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
1819 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
1820 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
1821 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
1822 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
1823 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
1824 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
1825 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
1826 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
1827 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
1828 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
1829 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
1830 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
1831 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
1832 (bfd_elfNN_bfd_set_private_flags): Likewise.
1833 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
1834 (elf_backend_init_index_section): Likewise.
1835 (elf_backend_allow_non_load_phdr): Likewise.
1836 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
1837 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
1838 * ieee.c (ieee_construct_extended_name_table): Likewise.
1839 (ieee_write_armap): Likewise.
1840 (ieee_write_ar_hdr): Likewise.
1841 (ieee_bfd_is_target_special_symbol): Likewise.
1842 * ihex.c (ihex_canonicalize_symtab): Likewise.
1843 (ihex_bfd_is_target_special_symbol): Likewise.
1844 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
1845 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
1846 (_bfd_ecoff_set_alignment_hook): Likewise.
1847 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
1848 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
1849 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
1850 * oasys.c (oasys_construct_extended_name_table): Likewise.
1851 (oasys_write_armap): Likewise.
1852 (oasys_write_ar_hdr): Likewise.
1853 (oasys_bfd_is_target_special_symbol): Likewise.
1854 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
1855 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
1856 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
1857 * som.c (som_bfd_is_target_special_symbol): Likewise.
1858 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
1859 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
1860 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
1861 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
1862 (versados_bfd_reloc_name_lookup): Likewise.
1863 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
1864 (vms_bfd_define_start_stop): Likewise.
1865 (alpha_vms_bfd_is_target_special_symbol): Likewise.
1866 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
1867 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
1868 * elf32-arc.c (get_replace_function): Assign replacement function
1869 to func pointer.
1870 * elf32-i370.c (i370_noop): Update prototype.
1871
6e5e9d58
AM
18722018-02-13 Alan Modra <amodra@gmail.com>
1873
1874 PR 22836
1875 * elf.c (_bfd_elf_fixup_group_sections): Account for removed
1876 relocation sections. If size reduces to just the flag word,
1877 remove that too and mark with SEC_EXCLUDE.
1878 * elflink.c (bfd_elf_final_link): Strip empty group sections.
1879
f2731e0c
AM
18802018-02-13 Alan Modra <amodra@gmail.com>
1881
1882 PR 22829
1883 * elf.c (assign_file_positions_for_non_load_sections): Rewrite
1884 PT_GNU_RELRO setup.
1885
830db048
ZF
18862018-02-12 Zebediah Figura <z.figura12@gmail.com>
1887
1888 * i386msdos.c (msdos_mkobject); New function.
1889 (msdos_object_p): New function.
1890 (i386_msdos_vec): Use msdos_object_p as the check_format
1891 function.
1892 * peicode.h: Rename external_PEI_DOS_hdr, DOSMAGIC, and
1893 NT_SIGNATURE to external_DOS_hdr, IMAGE_DOS_SIGNATURE, and
1894 IMAGE_NT_SIGNATURE.
1895 * peXXigen.c: Likewise.
1896 * coff-ia64.c: Likewise.
1897
94fe5757
NC
18982018-02-12 Nick Clifton <nickc@redhat.com>
1899
1900 * elf32-nds32.c (nds32_elf_relax_longjump3): Remove redundant
1901 assignment.
0b8683b7 1902 * elf32-arc.c (elf_arc_relocate_section): Likewise.
94fe5757 1903
d805612e 19042018-02-09 Eric Botcazou <ebotcazou@adacore.com>
a8735c82
EB
1905
1906 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Reorder conditions.
1907 (sparc_elf_append_rela): Assert that there is enough room in section.
1908 (_bfd_sparc_elf_copy_indirect_symbol): Fix formatting.
1909 (_bfd_sparc_elf_adjust_dynamic_symbol): Minor tweak.
1910 (allocate_dynrelocs): Remove outdated comments and reorder conditions.
1911 For a symbol subject to a GOT relocation, reserve a slot in the
1912 relocation section if the symbol isn't dynamic and we are in PIC mode.
1913 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: If relocation
1914 is relaxed and a slot was reserved, generate a R_SPARC_NONE relocation.
1915 <R_SPARC_GOTDATA_OP_HIX22>: Adjust comments.
1916 <R_SPARC_PC10>: Reorder conditions. Remove always-false assertion.
1917 (_bfd_sparc_elf_finish_dynamic_symbol): Rename local_undefweak into
1918 resolved_to_zero. Do not generate a dynamic GOT relocation for an
1919 undefined weak symbol with non-default visibility. Remove superfluous
1920 'else' and fix formatting.
1921
3b4c3844
L
19222018-02-09 H.J. Lu <hongjiu.lu@intel.com>
1923
1924 * elf32-i386.c (elf_i386_get_synthetic_symtab): Also handle
1925 is_solaris.
1926 (i386_elf32_sol2_vec): Don't declare.
1927 (elf_i386_link_setup_gnu_properties): Also handle is_solaris.
1928 Don't set need_global_offset_table.
1929 (elf_i386_solaris_arch_bed): New.
1930 (elf_backend_arch_data): Set to elf_i386_solaris_arch_bed for
1931 Solaris.
1932 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Check
1933 target_os != is_nacl instead of target_os == is_normal.
1934 (x86_64_elf64_sol2_vec): Don't declare.
1935 (elf_x86_64_link_setup_gnu_properties): Check target_os !=
1936 is_nacl instead of target_os == is_normal. Don't set
1937 need_global_offset_table.
1938 (elf_x86_64_solaris_arch_bed): New.
1939 (elf_backend_arch_data): Set to elf_x86_64_solaris_arch_bed for
1940 Solaris.
1941 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep
1942 _GLOBAL_OFFSET_TABLE_ for Solaris.
1943 (_bfd_x86_elf_link_setup_gnu_properties): Don't copy
1944 need_global_offset_table.
1945 * elfxx-x86.h (elf_x86_target_os): Add is_solaris.
1946 (elf_x86_link_hash_table): Remove need_global_offset_table.
1947 (elf_x86_init_table): Likewise.
1948
15b23f36
L
19492018-02-08 H.J. Lu <hongjiu.lu@intel.com>
1950
1951 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
1952 Remove prototype.
1953 (i386_elf32_sol2_vec): Declared.
1954 (elf_i386_link_setup_gnu_properties): Set
1955 need_global_offset_table with info->output_bfd->xvec.
1956 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
1957 Remove prototype.
1958 (x86_64_elf64_sol2_vec): Declared.
1959 (elf_x86_64_link_setup_gnu_properties): Set
1960 need_global_offset_table with info->output_bfd->xvec.
1961
dc11dea2
L
19622018-02-08 H.J. Lu <hongjiu.lu@intel.com>
1963
1964 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
1965 New prototype.
1966 (elf_i386_link_setup_gnu_properties): Set need_global_offset_table
1967 for Solaris.
1968 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
1969 New prototype.
1970 (elf_x86_64_link_setup_gnu_properties): Set
1971 need_global_offset_table for Solaris.
1972 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep the
1973 unused _GLOBAL_OFFSET_TABLE_ for Solaris.
1974 (_bfd_x86_elf_link_setup_gnu_properties): Copy
1975 need_global_offset_table.
1976 * elfxx-x86.h (elf_x86_link_hash_table): Add
1977 need_global_offset_table.
1978 (elf_x86_init_table): Likewise.
1979
3f48fe4a
JW
19802018-02-08 Jim Wilson <jimw@sifive.com>
1981
1982 * elfnn-riscv.c (riscv_elf_relocate_section): Add comment for previous
1983 change.
1984
ef135d43
NC
19852018-02-08 Nick Clifton <nickc@redhat.com>
1986
1987 PR 22788
1988 * elf.c (elf_parse_notes): Reject notes with excessuively large
1989 alignments.
1990
407aa07c
AM
19912018-02-07 Alan Modra <amodra@gmail.com>
1992
1993 Revert 2018-01-17 Alan Modra <amodra@gmail.com>
1994 * elf32-ppc.c: Remove speculation barrier support.
1995 * elf32-ppc.h: Likewise.
1996 * elf64-ppc.c: Likewise.
1997 * elf64-ppc.h: Likewise.
1998
ed01220c
JW
19992018-02-06 Jim Wilson <jimw@sifive.com>
2000
2001 * elfnn-riscv.c (riscv_elf_relocate_section): Return TRUE if used
2002 callback to report an error.
2003
c20c30f6
EB
20042018-02-06 Eric Botcazou <ebotcazou@adacore.com>
2005
2006 PR ld/22263
2007 * elfxx-sparc.c (sparc_elf_tls_transition): Turn call to bfd_link_pic
2008 into call to !bfd_link_executable and tidy up.
2009 (_bfd_sparc_elf_check_relocs): Fix formatting and tidy up.
2010 <R_SPARC_TLS_LE_HIX22>: Turn call to bfd_link_pic into call to
2011 !bfd_link_executable.
2012 <R_SPARC_TLS_IE_HI22>: Likewise.
2013 <GOT relocations>: Remove useless code, tidy and merge related blocks.
2014 <R_SPARC_TLS_GD_CALL>: Turn call to bfd_link_pic into call to
2015 !bfd_link_executable.
2016 <R_SPARC_WPLT30>: Tidy up.
2017 (_bfd_sparc_elf_gc_mark_hook): Turn call to bfd_link_pic into call to
2018 !bfd_link_executable.
2019 (allocate_dynrelocs): Likewise.
2020 (_bfd_sparc_elf_relocate_section): Fix formatting and tidy up.
2021 <R_SPARC_TLS_GD_HI22>: Merge into...
2022 <R_SPARC_TLS_GD_LO10>: ...this. Adjust 4th argument in call to
2023 sparc_elf_tls_transition and remove redundant code.
2024 <R_SPARC_TLS_LDM_HI22>: Turn call to bfd_link_pic into call to
2025 !bfd_link_executable.
2026 <R_SPARC_TLS_LDO_HIX22>: Likewise.
2027 <R_SPARC_TLS_LE_HIX22>: Likewise. Tidy up.
2028 <R_SPARC_TLS_LDM_CALL>: Likewise.
2029 <R_SPARC_TLS_GD_CALL>: Likewise. Tidy up.
2030 <R_SPARC_TLS_GD_ADD>: Likewise.
2031 <R_SPARC_TLS_LDM_ADD>: Likewise.
2032 <R_SPARC_TLS_LDO_ADD>: Likewise.
2033 <R_SPARC_TLS_IE_LD>: Likewise.
2034
46d09186
NC
20352018-02-06 Miloš Stojanović <milos.stojanovic@rt-rk.com>
2036
2037 PR 22789
2038 * elfxx-mips.c (_bfd_mips_elf_find_nearest_line): If the dwarf
2039 functions failed to find the function name, try the generic elf
2040 find function instead.
2041
8278e7ce
SDJ
20422018-02-06 Sergio Durigan Junior <sergiodj@redhat.com>
2043
2044 * coff-rs6000.c (xcoff_write_archive_contents_old): Use
2045 'memcpy' instead of 'strncpy' when writing the magic number.
2046
64e234d4
NC
20472018-02-06 Nick Clifton <nickc@redhat.com>
2048
2049 PR 22794
2050 * opncls.c (bfd_get_debug_link_info_1): Check the size of the
2051 section before attempting to read it in.
2052 (bfd_get_alt_debug_link_info): Likewise.
2053
422f3d3d
PC
20542018-02-06 Paul Carroll <pcarroll@codesourcery.com>
2055
2056 * bfd/dwarf2.c (find_abstract_name): Modified to return file and
2057 line information in addition to name, if they can be found.
2058
279b2f94
RL
20592018-02-05 Renlin Li <renlin.li@arm.com>
2060
2061 PR ld/22764
2062 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Relax the
2063 R_AARCH64_ABS32 and R_AARCH64_ABS16 for absolute symbol. Apply the
2064 check for writeable section as well.
2065
cd048363
L
20662018-02-05 H.J. Lu <hongjiu.lu@intel.com>
2067
2068 PR ld/22782
2069 * elf32-i386.c (elf_i386_check_relocs): Set got_referenced if
2070 _GLOBAL_OFFSET_TABLE_ is referenced or GOT is needed to resolve
2071 undefined weak symbol to 0.
2072 * elf64-x86-64.c (elf_x86_64_check_relocs): Set got_referenced
2073 if _GLOBAL_OFFSET_TABLE_ is referenced.
2074 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Check
2075 got_referenced instead of ref_regular_nonweak. Remove the
2076 unused _GLOBAL_OFFSET_TABLE_ from symbol table.
2077 * elfxx-x86.h (elf_x86_link_hash_table): Add got_referenced.
2078
e65b1a78
MR
20792018-02-05 Maciej W. Rozycki <macro@mips.com>
2080
2081 * elfnn-riscv.c (_bfd_riscv_relax_pc): Use `memset' to
2082 initialize `hi_reloc'.
2083
2d6dda71
MR
20842018-02-05 Maciej W. Rozycki <macro@mips.com>
2085
2086 * elfxx-mips.c (_bfd_mips_elf_section_processing): For
2087 SHT_MIPS_REGINFO sections don't assert the correct size and
2088 report an error instead.
2089
75506100
MR
20902018-02-05 Maciej W. Rozycki <macro@mips.com>
2091
2092 * elf.c (_bfd_elf_write_object_contents): Propagate a failure
2093 status from `->elf_backend_section_processing'.
2094
7f02625e
JW
20952018-02-02 Jim Wilson <jimw@sifive.com>
2096
2097 PR ld/22756
2098 * elfnn-riscv.c (riscv_relax_delete_bytes): New parameter link_info.
2099 If link_info->wrap_hash, check for a duplicate symbol and ignore.
2100 (_bfd_riscv_relax_call, bfd_riscv_relax_lui, _bfd_riscv_relax_tls_le):
2101 Pass new argument to riscv_relax_delete_bytes.
2102 (_bfd_riscv_relax_align, _bfd_riscv_relax_delete): Likewise. Remove
2103 ATTRIBUTE_UNUSED from link_info parameter.
2104
d830549d
AM
21052018-02-02 Alan Modra <amodra@gmail.com>
2106
2107 * elf64-ppc.c (ppc64_elf_relocate_section): Don't relocate nops
2108 emitted for toc sequence optimization. Set and use "howto" later.
2109
e99955cd
SM
21102018-02-01 Simon Marchi <simon.marchi@ericsson.com>
2111
2112 * elf64-ppc.c (ppc64_elf_archive_symbol_lookup): Avoid pointer
2113 arithmetic on NULL pointer.
2114 * elflink.c (_bfd_elf_archive_symbol_lookup,
2115 elf_link_add_archive_symbols): Likewise.
2116
bf3077a6
MM
21172018-01-31 Michael Matz <matz@suse.de>
2118
2119 * elflink.c (bfd_elf_define_start_stop): Fix check of
2120 def_dynamic.
2121
823143c6
L
21222018-01-31 H.J. Lu <hongjiu.lu@intel.com>
2123
2124 PR ld/21964
2125 * elflink.c (bfd_elf_define_start_stop): Check if __start and
2126 __stop symbols are referenced by shared objects.
2127
76cb3a89
AM
21282018-01-30 Alan Modra <amodra@gmail.com>
2129
2130 PR 22758
2131 * elf.c (_bfd_elf_map_sections_to_segments): Don't start a new
2132 segment when demand paged with lma on the same page. Test this
2133 before load/non-load, executable/non-executable,
2134 writable/non-writable tests and simplify. Delete bogus relro
2135 condition in writable/non-writable test. Delete outdated
2136 comment. Formatting.
2137
36b8fda5
AM
21382018-01-30 Alan Modra <amodra@gmail.com>
2139
2140 * elflink.c (bfd_elf_define_start_stop): Make __start and __stop
2141 symbols dynamic.
2142
eb77f6a4
AM
21432018-01-29 Alan Modra <amodra@gmail.com>
2144
2145 PR 22741
2146 * coffgen.c (coff_pointerize_aux): Ensure auxent tagndx is in
2147 range before converting to a symbol table pointer.
2148
7d73b4c8
NC
21492018-01-27 Nick Clifton <nickc@redhat.com>
2150
2151 * po/ru.po: Updated Russian translation.
2152
32253bb7
AM
21532018-01-26 Alan Modra <amodra@gmail.com>
2154
2155 * elflink.c (bfd_elf_define_start_stop): Override symbols when
2156 they are defined dynamically.
2157
ba21f564
AM
21582018-01-26 Alan Modra <amodra@gmail.com>
2159
2160 * elf64-ppc.c (ppc64_elf_size_stubs): Iterate sizing when
2161 .branch_lt changes size.
2162
38e64b0e
AM
21632018-01-25 Alan Modra <amodra@gmail.com>
2164
2165 PR 22746
2166 * elfcode.h (elf_object_p): Avoid integer overflow.
2167
bb363086
EB
21682018-01-25 Eric Botcazou <ebotcazou@adacore.com>
2169
2170 PR ld/22727
2171 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
2172 Do a mere lookup of the __tls_get_addr symbol instead of adding it.
2173
2174 Revert
2175 2017-10-19 H.J. Lu <hongjiu.lu@intel.com>
2176
2177 PR ld/22263
2178 * elfxx-sparc.c (sparc_elf_tls_transition): Replace
2179 bfd_link_pic with !bfd_link_executable, !bfd_link_pic with
2180 bfd_link_executable for TLS check.
2181 (_bfd_sparc_elf_check_relocs): Likewise.
2182 (allocate_dynrelocs): Likewise.
2183 (_bfd_sparc_elf_relocate_section): Likewise.
2184
1daf502a
RL
21852018-01-24 Renlin Li <renlin.li@arm.com>
2186
2187 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Add support for
2188 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
2189 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
2190 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
2191 BFD_RELOC_AARCH64_MOVW_PREL_G3.
2192 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
2193 (_bfd_aarch64_elf_resolve_relocation): Likewise.
2194
32247401
RL
21952018-01-24 Renlin Li <renlin.li@arm.com>
2196
2197 * reloc.c: Add BFD_RELOC_AARCH64_MOVW_PREL_G0,
2198 BFD_RELOC_AARCH64_MOVW_PREL_G0_NC, BFD_RELOC_AARCH64_MOVW_PREL_G1,
2199 BFD_RELOC_AARCH64_MOVW_PREL_G1_NC, BFD_RELOC_AARCH64_MOVW_PREL_G2,
2200 BFD_RELOC_AARCH64_MOVW_PREL_G2_NC, BFD_RELOC_AARCH64_MOVW_PREL_G3.
2201 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add entries for
2202 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
2203 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
2204 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
2205 BFD_RELOC_AARCH64_MOVW_PREL_G3.
2206 * bfd-in2.h: Regenerate.
2207 * libbfd.h: Regenerate.
2208
1c5e4ee9
MR
22092018-01-23 Maciej W. Rozycki <macro@mips.com>
2210
2211 * elfxx-mips.c (_bfd_mips_elf_final_link): Update a stale
2212 `mips_elf32_section_processing' comment reference.
2213
8a1b824a
L
22142018-01-20 H.J. Lu <hongjiu.lu@intel.com>
2215
2216 PR ld/22721
2217 * elfxx-x86.c (_bfd_x86_elf_link_check_relocs): Check the
2218 versioned __tls_get_addr symbol.
2219
ee3fbc1e
NC
22202018-01-19 Nick Clifton <nickc@redhat.com>
2221
2222 * po/fr.po: Updated French translation.
2223
691d2e9a
AM
22242018-01-18 Alan Modra <amodra@gmail.com>
2225
2226 * elf32-ppc.c (ppc_elf_create_glink): Correct alignment of .glink.
2227 * elf64-ppc.c (ppc64_elf_size_stubs): Handle negative plt_stub_align.
2228 (ppc64_elf_build_stubs): Likewise.
2229
4bfce128
NC
22302018-01-17 Nick Clifton <nickc@redhat.com>
2231
2232 * po/ru.po: Updated Russian translation.
2233 * po/uk/po: Updated Ukranian translation.
2234
c75bc4f7
AM
22352018-01-17 Alan Modra <amodra@gmail.com>
2236
2237 * elf64-ppc.c (ppc64_elf_build_stubs): Silence gcc warning.
2238
1be5d8d3
AM
22392018-01-17 Alan Modra <amodra@gmail.com>
2240
2241 * elf32-ppc.c (GLINK_ENTRY_SIZE): Handle speculation barrier.
2242 (CRSETEQ, BEQCTRM): Define.
2243 (is_nonpic_glink_stub): Don't check bctr.
2244 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
2245 (ppc_elf_relax_section): Size speculation barrier.
2246 (output_bctr): New function.
2247 (write_glink_stub): Use output_bctr.
2248 (ppc_elf_relocate_section): Use output_bctr for long branch stub.
2249 (ppc_elf_finish_dynamic_symbol): Likewise.
2250 (ppc_elf_finish_dynamic_sections): Use output_bctr.
2251 * elf32-ppc.h (struct ppc_elf_params): Add speculate_indirect_jumps.
2252 * elf64-ppc.c (CRSETEQ, BEQCTRM, BEQCTRLM): Define.
2253 (GLINK_PLTRESOLVE_SIZE): Size speculation barrier.
2254 (size_global_entry_stubs): Handle speculation barrier sizing.
2255 (plt_stub_size): Likewise.
2256 (output_bctr): New function.
2257 (build_plt_stub, build_tls_get_addr_stub): Output speculation
2258 barrier.
2259 (ppc_build_one_stub): Likewise for ppc_stub_plt_branch.
2260 (ppc_size_one_stub): Size speculation barrier in ppc_stub_plt_branch.
2261 (build_global_entry_stubs): Output speculation barrier.
2262 (ppc64_elf_build_stubs): Likewise in __glink_PLTresolve stub.
2263 * elf64-ppc.h (struct ppc64_elf_params): Add speculate_indirect_jumps.
2264
9e390558
AM
22652018-01-17 Alan Modra <amodra@gmail.com>
2266
2267 * elf32-ppc.c (GLINK_ENTRY_SIZE): Add parameters, handle
2268 __tls_get_addr_opt, and alignment sizing.
2269 (TLS_GET_ADDR_GLINK_SIZE): Delete.
2270 (is_nonpic_glink_stub): Don't use GLINK_ENTRY_SIZE.
2271 (ppc_elf_get_synthetic_symtab): Recognize stubs spaced at 4, 6,
2272 or 8 insns.
2273 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
2274 (allocate_dynrelocs): Use new GLINK_ENTRY_SIZE.
2275 (ppc_elf_size_dynamic_sections): Likewise. Size branch table
2276 by PLT reloc count.
2277 (write_glink_stub): Handle __tls_get_addr_opt stub.
2278 Pad out to size given by GLINK_ENTRY_SIZE.
2279 (ppc_elf_relocate_section): Adjust write_glink_stub call.
2280 (ppc_elf_finish_dynamic_symbol): Likewise.
2281 (ppc_elf_finish_dynamic_sections): Write PLTresolve without using
2282 insn array since so many need rewriting.
2283 * elf32-ppc.h (struct ppc_elf_params): Add plt_stub_align.
2284 * elf64-ppc.c (GLINK_PLTRESOLVE_SIZE): Rename from
2285 GLINK_CALL_STUB_SIZE. Add htab param and evaluate to size without
2286 nops. Adjust all uses.
2287 (ppc64_elf_get_synthetic_symtab): Don't use GLINK_CALL_STUB_SIZE
2288 in glink_vma calculation.
2289 (struct ppc_link_hash_table): Add global_entry section pointer.
2290 (create_linkage_sections): Create separate section for global
2291 entry stubs.
2292 (PPC_LO, PPC_HI, PPC_HA): Move earlier.
2293 (size_global_entry_stubs): Handle sizing for aligned stubs.
2294 (ppc64_elf_size_dynamic_sections): Handle global_entry alloc,
2295 and don't stash end of glink branch table in rawsize.
2296 (ppc_build_one_stub): Rewrite stub size calculations.
2297 (build_global_entry_stubs): Use new section.
2298 (ppc64_elf_build_stubs): Don't pad __glink_PLTresolve with nops.
2299 Build lazy link stubs out to end of section. Build global entry
2300 stubs in new section.
2301
616dcb87
NC
23022018-01-15 Nick Clifton <nickc@redhat.com>
2303
2304 * po/uk.po: Updated Ukranian translation.
2305
3957a496
NC
23062018-01-13 Nick Clifton <nickc@redhat.com>
2307
2308 * po/bfd.pot: Regenerated.
2309
769c7ea5
NC
23102018-01-13 Nick Clifton <nickc@redhat.com>
2311
2312 * version.m4: Bump version to 2.30.51
2313 * configure: Regenerate.
2314
faf766e3
NC
23152018-01-13 Nick Clifton <nickc@redhat.com>
2316
2317 2.30 branch created.
2318
564e11c9
JW
23192018-01-12 Jens Widell <jl@opera.com>
2320
2321 * elf.c (setup_group): Optimize search for group by remembering
2322 last found group and restarting search at that index.
2323 * elf-bfd.h (struct elf_obj_tdata): Add group_search_offset field.
2324
a78eea16
AM
23252018-01-12 Gunther Nikl <gnikl@users.sourceforge.net>
2326
2327 * aoutx.h (aout_link_check_ar_symbols): Remove default and handle
2328 bfd_link_common_skip_none in switch.
2329
87e79a65
AM
23302018-01-12 Alan Modra <amodra@gmail.com>
2331
2332 PR ld/22649
2333 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Ignore dynamic
2334 references on forced local symbols.
2335
58807c48
VI
23362018-01-12 Vlad Ivanov <vlad@ivanov.email>
2337
2338 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
2339 .reginfo section has wrong size.
2340
2888249f
L
23412018-01-11 H.J. Lu <hongjiu.lu@intel.com>
2342
2343 PR ld/22393
2344 * elf.c (_bfd_elf_map_sections_to_segments): When generating
2345 separate code and read-only data LOAD segments, create a new
2346 LOAD segment if the previous section contains text and the
2347 current section doesn't or vice versa. Don't put a writable
2348 section in a read-only segment if there is a RELRO segment.
2349
d664fd41
L
23502018-01-11 H.J. Lu <hongjiu.lu@intel.com>
2351
2352 PR ld/22649
2353 * elflink.c (bfd_elf_gc_mark_dynamic_ref_symbol): Ignore dynamic
2354 references on forced local symbols.
2355
8b6f4cd3
L
23562018-01-11 H.J. Lu <hongjiu.lu@intel.com>
2357
2358 PR ld/22677
2359 * elflink.c (bfd_elf_gc_sections): Keep all PREINIT_ARRAY,
2360 INIT_ARRAY as well as FINI_ARRAY sections for ld -r --gc-section.
2361
9c70c522 23622018-01-09 Kuan-Lin Chen <kuanlinchentw@gmail.com>
6cef73f9
KLC
2363
2364 PR 22662
2365 * elf32-nds32.c (nds32_elf_relax_loadstore): Fix a typographical error.
2366
ddb2bbcf
JB
23672018-01-03 John Baldwin <jhb@FreeBSD.org>
2368
2369 * elf.c (elfcore_grok_freebsd_note): Handle
2370 NT_FREEBSD_PROCSTAT_PROC, NT_FREEBSD_PROCSTAT_FILES, and
2371 NT_FREEBSD_PROCSTAT_VMMAP.
2372
219d1afa
AM
23732018-01-03 Alan Modra <amodra@gmail.com>
2374
2375 Update year range in copyright notice of all files.
2376
1e563868 2377For older changes see ChangeLog-2017
3499769a 2378\f
1e563868 2379Copyright (C) 2018 Free Software Foundation, Inc.
3499769a
AM
2380
2381Copying and distribution of this file, with or without modification,
2382are permitted in any medium without royalty provided the copyright
2383notice and this notice are preserved.
2384
2385Local Variables:
2386mode: change-log
2387left-margin: 8
2388fill-column: 74
2389version-control: never
2390End:
This page took 0.25895 seconds and 4 git commands to generate.