Use %pI, %pR, %pS, %pT in place of %I, %R, %S and %T.
[deliverable/binutils-gdb.git] / bfd / ChangeLog
1 2018-02-19 Alan Modra <amodra@gmail.com>
2
3 * elf32-arm.c, * elf32-hppa.c, * elf32-lm32.c, * elf32-m32r.c,
4 * elf32-metag.c, * elf32-nds32.c, * elf32-or1k.c, * elf32-ppc.c,
5 * elf32-s390.c, * elf32-sh.c, * elf32-tic6x.c, * elf32-tilepro.c,
6 * elf64-ppc.c, * elf64-s390.c, * elflink.c, * elfnn-aarch64.c,
7 * elfnn-riscv.c, * elfxx-sparc.c, * elfxx-tilegx.c, * elfxx-x86.c,
8 * reloc.c: Replace use of %R and %T in format strings passed to
9 einfo and friends by %pR and %pT.
10
11 2018-02-19 Alan Modra <amodra@gmail.com>
12
13 * bfd.c (_bfd_doprnt, _bfd_doprnt_scan): Handle %pA and %pB in place
14 of %A and %B.
15 * aout-adobe.c: Update all messages using %A and %B.
16 * aout-cris.c: Likewise.
17 * aoutx.h: Likewise.
18 * archive.c: Likewise.
19 * binary.c: Likewise.
20 * cache.c: Likewise.
21 * coff-alpha.c: Likewise.
22 * coff-arm.c: Likewise.
23 * coff-i860.c: Likewise.
24 * coff-mcore.c: Likewise.
25 * coff-ppc.c: Likewise.
26 * coff-rs6000.c: Likewise.
27 * coff-sh.c: Likewise.
28 * coff-tic4x.c: Likewise.
29 * coff-tic54x.c: Likewise.
30 * coff-tic80.c: Likewise.
31 * coff64-rs6000.c: Likewise.
32 * coffcode.h: Likewise.
33 * coffgen.c: Likewise.
34 * cofflink.c: Likewise.
35 * coffswap.h: Likewise.
36 * compress.c: Likewise.
37 * cpu-arm.c: Likewise.
38 * ecoff.c: Likewise.
39 * elf-attrs.c: Likewise.
40 * elf-eh-frame.c: Likewise.
41 * elf-ifunc.c: Likewise.
42 * elf-m10300.c: Likewise.
43 * elf-properties.c: Likewise.
44 * elf-s390-common.c: Likewise.
45 * elf.c: Likewise.
46 * elf32-arc.c: Likewise.
47 * elf32-arm.c: Likewise.
48 * elf32-avr.c: Likewise.
49 * elf32-bfin.c: Likewise.
50 * elf32-cr16.c: Likewise.
51 * elf32-cr16c.c: Likewise.
52 * elf32-cris.c: Likewise.
53 * elf32-crx.c: Likewise.
54 * elf32-d10v.c: Likewise.
55 * elf32-d30v.c: Likewise.
56 * elf32-epiphany.c: Likewise.
57 * elf32-fr30.c: Likewise.
58 * elf32-frv.c: Likewise.
59 * elf32-gen.c: Likewise.
60 * elf32-hppa.c: Likewise.
61 * elf32-i370.c: Likewise.
62 * elf32-i386.c: Likewise.
63 * elf32-i960.c: Likewise.
64 * elf32-ip2k.c: Likewise.
65 * elf32-iq2000.c: Likewise.
66 * elf32-lm32.c: Likewise.
67 * elf32-m32c.c: Likewise.
68 * elf32-m32r.c: Likewise.
69 * elf32-m68hc11.c: Likewise.
70 * elf32-m68hc12.c: Likewise.
71 * elf32-m68hc1x.c: Likewise.
72 * elf32-m68k.c: Likewise.
73 * elf32-mcore.c: Likewise.
74 * elf32-mep.c: Likewise.
75 * elf32-metag.c: Likewise.
76 * elf32-microblaze.c: Likewise.
77 * elf32-moxie.c: Likewise.
78 * elf32-msp430.c: Likewise.
79 * elf32-mt.c: Likewise.
80 * elf32-nds32.c: Likewise.
81 * elf32-nios2.c: Likewise.
82 * elf32-or1k.c: Likewise.
83 * elf32-pj.c: Likewise.
84 * elf32-ppc.c: Likewise.
85 * elf32-rl78.c: Likewise.
86 * elf32-rx.c: Likewise.
87 * elf32-s390.c: Likewise.
88 * elf32-score.c: Likewise.
89 * elf32-score7.c: Likewise.
90 * elf32-sh-symbian.c: Likewise.
91 * elf32-sh.c: Likewise.
92 * elf32-sh64.c: Likewise.
93 * elf32-sparc.c: Likewise.
94 * elf32-spu.c: Likewise.
95 * elf32-tic6x.c: Likewise.
96 * elf32-tilepro.c: Likewise.
97 * elf32-v850.c: Likewise.
98 * elf32-vax.c: Likewise.
99 * elf32-visium.c: Likewise.
100 * elf32-wasm32.c: Likewise.
101 * elf32-xgate.c: Likewise.
102 * elf32-xtensa.c: Likewise.
103 * elf64-alpha.c: Likewise.
104 * elf64-gen.c: Likewise.
105 * elf64-hppa.c: Likewise.
106 * elf64-ia64-vms.c: Likewise.
107 * elf64-mmix.c: Likewise.
108 * elf64-ppc.c: Likewise.
109 * elf64-s390.c: Likewise.
110 * elf64-sh64.c: Likewise.
111 * elf64-sparc.c: Likewise.
112 * elf64-x86-64.c: Likewise.
113 * elfcode.h: Likewise.
114 * elfcore.h: Likewise.
115 * elflink.c: Likewise.
116 * elfnn-aarch64.c: Likewise.
117 * elfnn-ia64.c: Likewise.
118 * elfnn-riscv.c: Likewise.
119 * elfxx-mips.c: Likewise.
120 * elfxx-sparc.c: Likewise.
121 * elfxx-tilegx.c: Likewise.
122 * elfxx-x86.c: Likewise.
123 * hpux-core.c: Likewise.
124 * ieee.c: Likewise.
125 * ihex.c: Likewise.
126 * libbfd.c: Likewise.
127 * linker.c: Likewise.
128 * mach-o.c: Likewise.
129 * merge.c: Likewise.
130 * mmo.c: Likewise.
131 * oasys.c: Likewise.
132 * pdp11.c: Likewise.
133 * pe-mips.c: Likewise.
134 * peXXigen.c: Likewise.
135 * peicode.h: Likewise.
136 * reloc.c: Likewise.
137 * rs6000-core.c: Likewise.
138 * srec.c: Likewise.
139 * stabs.c: Likewise.
140 * vms-alpha.c: Likewise.
141 * xcofflink.c: Likewise.
142
143 2018-02-19 Alan Modra <amodra@gmail.com>
144
145 PR 22845
146 * elf.c (IS_TBSS): Define.
147 (_bfd_elf_map_sections_to_segments): Use IS_TBSS.
148 (assign_file_positions_for_non_load_sections): Revert last change.
149 Properly calculate load segment limits to compare against relro limits.
150
151 2018-02-17 Alan Modra <amodra@gmail.com>
152
153 PR 22845
154 * elf.c (assign_file_positions_for_non_load_sections): Ignore
155 degenerate zero size PT_LOAD segments when finding one overlapping
156 the PT_GNU_RELRO segment.
157
158 2018-02-16 Alan Modra <amodra@gmail.com>
159
160 * libbfd.c (_bfd_bool_bfd_false_error): Rename from bfd_false.
161 (_bfd_bool_bfd_true): Rename from bfd_true.
162 (_bfd_ptr_bfd_null_error): Rename from bfd_nullvoidptr.
163 (_bfd_int_bfd_0): Rename from bfd_0.
164 (_bfd_uint_bfd_0): Rename from bfd_0u.
165 (_bfd_long_bfd_0): Rename from bfd_0l.
166 (_bfd_long_bfd_n1_error): Rename from _bfd_n1.
167 (_bfd_void_bfd): Rename from bfd_void.
168 (_bfd_bool_bfd_false, _bfd_bool_bfd_asymbol_false),
169 (_bfd_bool_bfd_link_false_error),
170 (_bfd_bool_bfd_link_true, _bfd_bool_bfd_bfd_true),
171 (_bfd_bool_bfd_uint_true, _bfd_bool_bfd_ptr_true),
172 (_bfd_bool_bfd_asection_bfd_asection_true),
173 (_bfd_bool_bfd_asymbol_bfd_asymbol_true),
174 (_bfd_void_bfd_link, _bfd_void_bfd_asection): New functions.
175 * archive.c (_bfd_noarchive_get_elt_at_index),
176 (_bfd_noarchive_openr_next_archived_file),
177 (_bfd_noarchive_construct_extended_name_table),
178 (_bfd_noarchive_write_ar_hdr, _bfd_noarchive_truncate_arname),
179 (_bfd_noarchive_write_armap): New functions.
180 * archures.c (_bfd_nowrite_set_arch_mach): New function.
181 * coff-alpha.c (alpha_ecoff_swap_coff_aux_in),
182 (alpha_ecoff_swap_coff_sym_in, alpha_ecoff_swap_coff_lineno_in),
183 (alpha_ecoff_swap_coff_aux_out, alpha_ecoff_swap_coff_sym_out),
184 (alpha_ecoff_swap_coff_lineno_out),
185 (alpha_ecoff_swap_coff_reloc_out): New functions.
186 * coff-mips.c (mips_ecoff_swap_coff_aux_in),
187 (mips_ecoff_swap_coff_sym_in, mips_ecoff_swap_coff_lineno_in),
188 (mips_ecoff_swap_coff_aux_out, mips_ecoff_swap_coff_sym_out),
189 (mips_ecoff_swap_coff_lineno_out),
190 (mips_ecoff_swap_coff_reloc_out): New functions.
191 * coffcode.h (coff_set_alignment_hook): Replace define with
192 new function.
193 (symname_in_debug_hook): Likewise.
194 * ecoff.c (_bfd_ecoff_set_alignment_hook): New function.
195 * elfxx-target.h (elf_backend_allow_non_load_phdr): Default to 0.
196 * elf.c (assign_file_positions_except_relocs): Test
197 elf_backend_allow_non_load_phdr for NULL.
198 * elflink.c (_bfd_elf_omit_section_dynsym_default): Rename from
199 _bfd_elf_link_omit_section_dynsym. Update uses.
200 (_bfd_elf_omit_section_dynsym_all): New function.
201 * elf-bfd.h (_bfd_elf_link_omit_section_dynsym): Delete.
202 (_bfd_elf_omit_section_dynsym_default): Declare.
203 (_bfd_elf_omit_section_dynsym_all): Declare.
204 * linker.c (_bfd_nolink_sizeof_headers, _bfd_nolink_bfd_relax_section),
205 (_bfd_nolink_bfd_get_relocated_section_contents),
206 (_bfd_nolink_bfd_lookup_section_flags),
207 (_bfd_nolink_bfd_is_group_section, _bfd_nolink_bfd_discard_group),
208 (_bfd_nolink_bfd_link_hash_table_create),
209 (_bfd_nolink_bfd_link_just_syms),
210 (_bfd_nolink_bfd_copy_link_hash_symbol_type),
211 (_bfd_nolink_bfd_link_split_section),
212 (_bfd_nolink_section_already_linked),
213 (_bfd_nolink_bfd_define_common_symbol),
214 (_bfd_nolink_bfd_define_start_stop): New functions.
215 * reloc.c (_bfd_norelocs_bfd_reloc_type_lookup),
216 (_bfd_norelocs_bfd_reloc_name_lookup),
217 (_bfd_nodynamic_canonicalize_dynamic_reloc): New functions.
218 * section.c (_bfd_nowrite_set_section_contents): New function.
219 * syms.c (_bfd_nosymbols_canonicalize_symtab),
220 (_bfd_nosymbols_print_symbol, _bfd_nosymbols_get_symbol_info),
221 (_bfd_nosymbols_get_symbol_version_string),
222 (_bfd_nosymbols_bfd_is_local_label_name),
223 (_bfd_nosymbols_get_lineno, _bfd_nosymbols_find_nearest_line),
224 (_bfd_nosymbols_find_line, _bfd_nosymbols_find_inliner_info),
225 (_bfd_nosymbols_bfd_make_debug_symbol),
226 ( _bfd_nosymbols_read_minisymbols),
227 ( _bfd_nosymbols_minisymbol_to_symbol),
228 (_bfd_nodynamic_get_synthetic_symtab): New functions.
229 * libbfd-in.h: Declare new functions. Update existing defines,
230 removing casts.
231 * aix386-core.c: Update to use new hooks. Formatting.
232 * aout-adobe.c: Likewise.
233 * aout-arm.c: Likewise.
234 * aout-target.h: Likewise.
235 * aout-tic30.c: Likewise.
236 * aoutf1.h: Likewise.
237 * binary.c: Likewise.
238 * bout.c: Likewise.
239 * cisco-core.c: Likewise.
240 * coff-alpha.c: Likewise.
241 * coff-i386.c: Likewise.
242 * coff-i860.c: Likewise.
243 * coff-i960.c: Likewise.
244 * coff-ia64.c: Likewise.
245 * coff-mips.c: Likewise.
246 * coff-ppc.c: Likewise.
247 * coff-rs6000.c: Likewise.
248 * coff-sh.c: Likewise.
249 * coff-tic30.c: Likewise.
250 * coff-tic54x.c: Likewise.
251 * coff-x86_64.c: Likewise.
252 * coff64-rs6000.c: Likewise.
253 * coffcode.h: Likewise.
254 * elf-m10300.c: Likewise.
255 * elf32-cr16.c: Likewise.
256 * elf32-lm32.c: Likewise.
257 * elf32-m32r.c: Likewise.
258 * elf32-metag.c: Likewise.
259 * elf32-score.c: Likewise.
260 * elf32-score7.c: Likewise.
261 * elf32-tilepro.c: Likewise.
262 * elf32-xstormy16.c: Likewise.
263 * elf32-xtensa.c: Likewise.
264 * elf64-alpha.c: Likewise.
265 * elf64-hppa.c: Likewise.
266 * elf64-ia64-vms.c: Likewise.
267 * elf64-mmix.c: Likewise.
268 * elf64-sh64.c: Likewise.
269 * elfnn-ia64.c: Likewise.
270 * elfxx-sparc.c: Likewise.
271 * elfxx-target.h: Likewise.
272 * elfxx-tilegx.c: Likewise.
273 * elfxx-x86.h: Likewise.
274 * hp300hpux.c: Likewise.
275 * hppabsd-core.c: Likewise.
276 * hpux-core.c: Likewise.
277 * i386msdos.c: Likewise.
278 * i386os9k.c: Likewise.
279 * ieee.c: Likewise.
280 * ihex.c: Likewise.
281 * irix-core.c: Likewise.
282 * libaout.h: Likewise.
283 * libecoff.h: Likewise.
284 * mach-o-target.c: Likewise.
285 * mach-o.c: Likewise.
286 * mipsbsd.c: Likewise.
287 * mmo.c: Likewise.
288 * netbsd-core.c: Likewise.
289 * nlm-target.h: Likewise.
290 * oasys.c: Likewise.
291 * osf-core.c: Likewise.
292 * pdp11.c: Likewise.
293 * pe-mips.c: Likewise.
294 * pe-x86_64.c: Likewise.
295 * pef.c: Likewise.
296 * plugin.c: Likewise.
297 * ppcboot.c: Likewise.
298 * ptrace-core.c: Likewise.
299 * sco5-core.c: Likewise.
300 * som.c: Likewise.
301 * sparclynx.c: Likewise.
302 * srec.c: Likewise.
303 * tekhex.c: Likewise.
304 * trad-core.c: Likewise.
305 * verilog.c: Likewise.
306 * versados.c: Likewise.
307 * vms-alpha.c: Likewise.
308 * vms-lib.c: Likewise.
309 * wasm-module.c: Likewise.
310 * xsym.c: Likewise.
311 * libbfd.h: Regenerate.
312
313 2018-02-15 Jim Wilson <jimw@sifive.com>
314
315 * elfnn-riscv.c (_bfd_riscv_relax_section): Ifdef out check to ignore
316 symbols whose section address is zero.
317
318 * elfnn-riscv.c (riscv_elf_relocate_section): Use bfd_reloc_dangerous
319 when pcrel_lo reloc has an addend. Use reloc_dangerous callback for
320 bfd_reloc_dangerous. Use einfo instead of warning callback for errors.
321 Add %X%P to error messages.
322
323 2018-02-15 Eric Botcazou <ebotcazou@adacore.com>
324
325 PR ld/22832
326 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
327 Pass FALSE instead of TRUE as 'create' argument to bfd_link_hash_lookup
328 and assert that the result of the call is not NULL.
329
330 2018-02-14 Nick Clifton <nickc@redhat.com>
331
332 PR 22823
333 Revert previous delta. Add extra casts to avoid compile time
334 warnings instead.
335 * libbfd-in.h (_bfd_generic_bfd_copy_private_bfd_data): Add extra
336 cast to avoid warning from gcc v8 compiler.
337 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
338 (_bfd_generic_bfd_set_private_flags): Likewise.
339 (_bfd_generic_bfd_copy_private_section_data): Likewise.
340 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
341 (_bfd_generic_bfd_copy_private_header_data): Likewise.
342 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
343 (_bfd_noarchive_construct_extended_name_table): Likewise.
344 (_bfd_noarchive_truncate_arname): Likewise.
345 (_bfd_noarchive_write_ar_hdr): Likewise.
346 (_bfd_noarchive_get_elt_at_index): Likewise.
347 (_bfd_nosymbols_canonicalize_symtab): Likewise.
348 (_bfd_nosymbols_print_symbol): Likewise.
349 (_bfd_nosymbols_get_symbol_info): Likewise.
350 (_bfd_nosymbols_get_symbol_version_string): Likewise.
351 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
352 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
353 (_bfd_nosymbols_get_lineno): Likewise.
354 (_bfd_nosymbols_find_nearest_line): Likewise.
355 (_bfd_nosymbols_find_line): Likewise.
356 (_bfd_nosymbols_find_inliner_info): Likewise.
357 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
358 (_bfd_nosymbols_read_minisymbols): Likewise.
359 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
360 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
361 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
362 (_bfd_nowrite_set_arch_mach): Likewise.
363 (_bfd_nowrite_set_section_contents): Likewise.
364 (_bfd_nolink_sizeof_headers): Likewise.
365 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
366 (_bfd_nolink_bfd_relax_section): Likewise.
367 (_bfd_nolink_bfd_gc_sections): Likewise.
368 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
369 (_bfd_nolink_bfd_merge_sections): Likewise.
370 (_bfd_nolink_bfd_is_group_section): Likewise.
371 (_bfd_nolink_bfd_discard_group): Likewise.
372 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
373 (_bfd_nolink_bfd_link_add_symbols): Likewise.
374 (_bfd_nolink_bfd_link_just_syms): Likewise.
375 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
376 (_bfd_nolink_bfd_final_link): Likewise.
377 (_bfd_nolink_bfd_link_split_section): Likewise.
378 (_bfd_nolink_section_already_linked): Likewise.
379 (_bfd_nolink_bfd_define_common_symbol): Likewise.
380 (_bfd_nolink_bfd_define_start_stop): Likewise.
381 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
382 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
383 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
384 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
385 * libbfd.c (bfd_false_any): Delete.
386 (bfd_true_any, bfd_nullvoidptr_any, bfd_0_any): Delete.
387 (bfd_0u_any, bfd_0l_any, _bfd_n1_any, bfd_void_any): Delete.
388 * libbfd.h (extern): Regenerate
389 * aout-target.h (MY_bfd_is_target_special_symbol): Add extra
390 cast to avoid warning from gcc v8 compiler.
391 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
392 * binary.c (binary_get_symbol_info): Likewise.
393 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
394 * coff-mips.c (mips_ecoff_backend_data): Likewise.
395 * coffcode.h (coff_set_alignment_hook): Likewise.
396 (symname_in_debug_hook): Likewise.
397 (bfd_coff_backend_data bigobj_swap_table): Likewise.
398 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
399 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
400 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
401 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
402 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
403 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
404 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
405 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
406 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
407 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
408 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
409 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
410 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
411 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
412 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
413 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
414 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
415 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
416 (bfd_elfNN_bfd_set_private_flags): Likewise.
417 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
418 (elf_backend_init_index_section): Likewise.
419 (elf_backend_allow_non_load_phdr): Likewise.
420 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
421 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
422 * ieee.c (ieee_construct_extended_name_table): Likewise.
423 (ieee_write_armap): Likewise.
424 (ieee_write_ar_hdr): Likewise.
425 (ieee_bfd_is_target_special_symbol): Likewise.
426 * ihex.c (ihex_canonicalize_symtab): Likewise.
427 (ihex_bfd_is_target_special_symbol): Likewise.
428 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
429 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
430 (_bfd_ecoff_set_alignment_hook): Likewise.
431 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
432 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
433 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
434 * oasys.c (oasys_construct_extended_name_table): Likewise.
435 (oasys_write_armap): Likewise.
436 (oasys_write_ar_hdr): Likewise.
437 (oasys_bfd_is_target_special_symbol): Likewise.
438 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
439 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
440 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
441 * som.c (som_bfd_is_target_special_symbol): Likewise.
442 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
443 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
444 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
445 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
446 (versados_bfd_reloc_name_lookup): Likewise.
447 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
448 (vms_bfd_define_start_stop): Likewise.
449 (alpha_vms_bfd_is_target_special_symbol): Likewise.
450 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
451 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
452
453 2018-02-14 H.J. Lu <hongjiu.lu@intel.com>
454
455 PR ld/22842
456 * elf32-i386.c (elf_i386_check_relocs): Pass FALSE for non
457 PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
458 * elf64-x86-64.c (elf_x86_64_check_relocs): Create PLT for
459 R_X86_64_PC32 reloc against dynamic function in data section.
460 Pass TRUE for PC-relative PLT to NEED_DYNAMIC_RELOCATION_P.
461 (elf_x86_64_relocate_section): Use PLT for R_X86_64_PC32 reloc
462 against dynamic function in data section.
463 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Use PLT in PIE as
464 function address only if pcrel_plt is true.
465 (_bfd_x86_elf_link_hash_table_create): Set pcrel_plt.
466 * elfxx-x86.h (NEED_DYNAMIC_RELOCATION_P): Add PCREL_PLT for
467 PC-relative PLT. If PLT is PC-relative, don't generate dynamic
468 PC-relative relocation against a function definition in data
469 secton in PIE. Remove the obsolete comments.
470 (elf_x86_link_hash_table): Add pcrel_plt.
471
472 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
473
474 * elfxx-x86.c (elf_x86_allocate_dynrelocs): Check bfd_link_dll,
475 instead of bfd_link_pic, for building shared library.
476
477 2018-02-13 H.J. Lu <hongjiu.lu@intel.com>
478
479 PR gas/22791
480 * elf64-x86-64.c (is_32bit_relative_branch): Removed.
481 (elf_x86_64_relocate_section): Check PIC relocations in PIE.
482 Remove is_32bit_relative_branch usage. Disallow PC32 reloc
483 against protected function in shared object.
484
485 2018-02-13 Sergei Trofimovich <slyfox@inbox.ru>
486
487 PR 22828
488 * po/ru.po: Fix typo in Russian translation.
489
490 2018-02-13 Maciej W. Rozycki <macro@mips.com>
491
492 * wasm-module.c (wasm_scan_name_function_section): Rename
493 `index' local variable to `idx'.
494
495 2018-02-13 Nick Clifton <nickc@redhat.com>
496
497 PR 22823
498 Fix compile time warnings generated by gcc version 8.
499 * libbfd-in.h: Remove extraneous text from prototypes.
500 Add prototypes for bfd_false_any, bfd_true_any,
501 bfd_nullvoidptr_any, bfd_0_any, bfd_0u_any, bfd_0l_any,
502 bfd_n1_any, bfd_void_any.
503 (_bfd_generic_bfd_copy_private_bfd_data): Use vararg based dummy
504 function.
505 (_bfd_generic_bfd_merge_private_bfd_data): Likewise.
506 (_bfd_generic_bfd_set_private_flags): Likewise.
507 (_bfd_generic_bfd_copy_private_section_data): Likewise.
508 (_bfd_generic_bfd_copy_private_symbol_data): Likewise.
509 (_bfd_generic_bfd_copy_private_header_data): Likewise.
510 (_bfd_generic_bfd_print_private_bfd_data): Likewise.
511 (_bfd_noarchive_construct_extended_name_table): Likewise.
512 (_bfd_noarchive_truncate_arname): Likewise.
513 (_bfd_noarchive_write_ar_hdr): Likewise.
514 (_bfd_noarchive_get_elt_at_index): Likewise.
515 (_bfd_nosymbols_canonicalize_symtab): Likewise.
516 (_bfd_nosymbols_print_symbol): Likewise.
517 (_bfd_nosymbols_get_symbol_info): Likewise.
518 (_bfd_nosymbols_get_symbol_version_string): Likewise.
519 (_bfd_nosymbols_bfd_is_local_label_name): Likewise.
520 (_bfd_nosymbols_bfd_is_target_special_symbol): Likewise.
521 (_bfd_nosymbols_get_lineno): Likewise.
522 (_bfd_nosymbols_find_nearest_line): Likewise.
523 (_bfd_nosymbols_find_line): Likewise.
524 (_bfd_nosymbols_find_inliner_info): Likewise.
525 (_bfd_nosymbols_bfd_make_debug_symbol): Likewise.
526 (_bfd_nosymbols_read_minisymbols): Likewise.
527 (_bfd_nosymbols_minisymbol_to_symbol): Likewise.
528 (_bfd_norelocs_bfd_reloc_type_lookup): Likewise.
529 (_bfd_norelocs_bfd_reloc_name_lookup): Likewise.
530 (_bfd_nowrite_set_arch_mach): Likewise.
531 (_bfd_nowrite_set_section_contents): Likewise.
532 (_bfd_nolink_sizeof_headers): Likewise.
533 (_bfd_nolink_bfd_get_relocated_section_contents): Likewise.
534 (_bfd_nolink_bfd_relax_section): Likewise.
535 (_bfd_nolink_bfd_gc_sections): Likewise.
536 (_bfd_nolink_bfd_lookup_section_flags): Likewise.
537 (_bfd_nolink_bfd_merge_sections): Likewise.
538 (_bfd_nolink_bfd_is_group_section): Likewise.
539 (_bfd_nolink_bfd_discard_group): Likewise.
540 (_bfd_nolink_bfd_link_hash_table_create): Likewise.
541 (_bfd_nolink_bfd_link_add_symbols): Likewise.
542 (_bfd_nolink_bfd_link_just_syms): Likewise.
543 (_bfd_nolink_bfd_copy_link_hash_symbol_type): Likewise.
544 (_bfd_nolink_bfd_final_link): Likewise.
545 (_bfd_nolink_bfd_link_split_section): Likewise.
546 (_bfd_nolink_section_already_linked): Likewise.
547 (_bfd_nolink_bfd_define_common_symbol): Likewise.
548 (_bfd_nolink_bfd_define_start_stop): Likewise.
549 (_bfd_nodynamic_canonicalize_dynamic_symtab): Likewise.
550 (_bfd_nodynamic_get_synthetic_symtab): Likewise.
551 (_bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_): Likewise.
552 (_bfd_nodynamic_canonicalize_dynamic_reloc): Likewise.
553 * libbfd.c (bfd_false_any): New function. Like bfd_false but
554 accepts one or more arguments.
555 (bfd_true_any): Likewise.
556 (bfd_nullvoidptr_any): Likewise.
557 (bfd_0_any): Likewise.
558 (bfd_0u_any): Likewise.
559 (bfd_0l_any): Likewise.
560 (_bfd_n1_any): Likewise.
561 (bfd_void_any): Likewise.
562 * libbfd.h (extern): Regenerate
563 * aout-target.h (MY_bfd_is_target_special_symbol): Use vararg
564 based dummy function.
565 * aout-tic30.c (tic30_aout_set_arch_mach): Likewise.
566 * binary.c (binary_get_symbol_info): Likewise.
567 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
568 * coff-mips.c (mips_ecoff_backend_data): Likewise.
569 * coffcode.h (coff_set_alignment_hook): Likewise.
570 (symname_in_debug_hook): Likewise.
571 (bfd_coff_backend_data bigobj_swap_table): Likewise.
572 * elf-m10300.c (elf_backend_omit_section_dynsym): Likewise.
573 * elf32-cr16.c (elf_backend_omit_section_dynsym): Likewise.
574 * elf32-lm32.c (elf_backend_omit_section_dynsym): Likewise.
575 * elf32-m32r.c (elf_backend_omit_section_dynsym): Likewise.
576 * elf32-metag.c (elf_backend_omit_section_dynsym): Likewise.
577 * elf32-score.c (elf_backend_omit_section_dynsym): Likewise.
578 * elf32-score7.c (elf_backend_omit_section_dynsym): Likewise.
579 * elf32-xstormy16.c (elf_backend_omit_section_dynsym): Likewise.
580 * elf32-xtensa.c (elf_backend_omit_section_dynsym): Likewise.
581 * elf64-alpha.c (elf_backend_omit_section_dynsym): Likewise.
582 * elf64-hppa.c (elf_backend_omit_section_dynsym): Likewise.
583 * elf64-ia64-vms.c (elf_backend_omit_section_dynsym): Likewise.
584 * elf64-mmix.c (elf_backend_omit_section_dynsym): Likewise.
585 * elf64-sh64.c (elf_backend_omit_section_dynsym): Likewise.
586 * elfnn-ia64.c (elf_backend_omit_section_dynsym): Likewise.
587 * elfxx-target.h (bfd_elfNN_bfd_debug_info_accumulate): Likewise.
588 (bfd_elfNN_bfd_make_debug_symbol): Likewise.
589 (bfd_elfNN_bfd_merge_private_bfd_data): Likewise.
590 (bfd_elfNN_bfd_set_private_flags): Likewise.
591 (bfd_elfNN_bfd_is_target_special_symbol): Likewise.
592 (elf_backend_init_index_section): Likewise.
593 (elf_backend_allow_non_load_phdr): Likewise.
594 * elfxx-x86.h (elf_backend_omit_section_dynsym): Likewise.
595 * i386msdos.c (msdos_bfd_is_target_special_symbol): Likewise.
596 * ieee.c (ieee_construct_extended_name_table): Likewise.
597 (ieee_write_armap): Likewise.
598 (ieee_write_ar_hdr): Likewise.
599 (ieee_bfd_is_target_special_symbol): Likewise.
600 * ihex.c (ihex_canonicalize_symtab): Likewise.
601 (ihex_bfd_is_target_special_symbol): Likewise.
602 * libaout.h (aout_32_bfd_is_target_special_symbol): Likewise.
603 * libecoff.h (_bfd_ecoff_bfd_is_target_special_symbol): Likewise.
604 (_bfd_ecoff_set_alignment_hook): Likewise.
605 * mach-o-target.c (bfd_mach_o_bfd_is_target_special_symbol): Likewise.
606 * mmo.c (mmo_bfd_is_target_special_symbol): Likewise.
607 * nlm-target.h (nlm_bfd_is_target_special_symbol): Likewise.
608 * oasys.c (oasys_construct_extended_name_table): Likewise.
609 (oasys_write_armap): Likewise.
610 (oasys_write_ar_hdr): Likewise.
611 (oasys_bfd_is_target_special_symbol): Likewise.
612 * pef.c (bfd_pef_bfd_is_target_special_symbol): Likewise.
613 * plugin.c (bfd_plugin_bfd_is_target_special_symbol): Likewise.
614 * ppcboot.c (ppcboot_bfd_is_target_special_symbol): Likewise.
615 * som.c (som_bfd_is_target_special_symbol): Likewise.
616 * srec.c (srec_bfd_is_target_special_symbol): Likewise.
617 * tekhex.c (tekhex_bfd_is_target_special_symbol): Likewise.
618 * verilog.c (verilog_bfd_is_target_special_symbol): Likewise.
619 * versados.c (versados_bfd_is_target_special_symbol): Likewise.
620 (versados_bfd_reloc_name_lookup): Likewise.
621 * vms-alpha.c (vms_bfd_is_target_special_symbol): Likewise.
622 (vms_bfd_define_start_stop): Likewise.
623 (alpha_vms_bfd_is_target_special_symbol): Likewise.
624 * wasm-module.c (wasm_bfd_is_target_special_symbol): Likewise.
625 * xsym.c (bfd_sym_bfd_is_target_special_symbol): Likewise.
626 * elf32-arc.c (get_replace_function): Assign replacement function
627 to func pointer.
628 * elf32-i370.c (i370_noop): Update prototype.
629
630 2018-02-13 Alan Modra <amodra@gmail.com>
631
632 PR 22836
633 * elf.c (_bfd_elf_fixup_group_sections): Account for removed
634 relocation sections. If size reduces to just the flag word,
635 remove that too and mark with SEC_EXCLUDE.
636 * elflink.c (bfd_elf_final_link): Strip empty group sections.
637
638 2018-02-13 Alan Modra <amodra@gmail.com>
639
640 PR 22829
641 * elf.c (assign_file_positions_for_non_load_sections): Rewrite
642 PT_GNU_RELRO setup.
643
644 2018-02-12 Zebediah Figura <z.figura12@gmail.com>
645
646 * i386msdos.c (msdos_mkobject); New function.
647 (msdos_object_p): New function.
648 (i386_msdos_vec): Use msdos_object_p as the check_format
649 function.
650 * peicode.h: Rename external_PEI_DOS_hdr, DOSMAGIC, and
651 NT_SIGNATURE to external_DOS_hdr, IMAGE_DOS_SIGNATURE, and
652 IMAGE_NT_SIGNATURE.
653 * peXXigen.c: Likewise.
654 * coff-ia64.c: Likewise.
655
656 2018-02-12 Nick Clifton <nickc@redhat.com>
657
658 * elf32-nds32.c (nds32_elf_relax_longjump3): Remove redundant
659 assignment.
660 * elf32-arc.c (elf_arc_relocate_section): Likewise.
661
662 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
663
664 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Reorder conditions.
665 (sparc_elf_append_rela): Assert that there is enough room in section.
666 (_bfd_sparc_elf_copy_indirect_symbol): Fix formatting.
667 (_bfd_sparc_elf_adjust_dynamic_symbol): Minor tweak.
668 (allocate_dynrelocs): Remove outdated comments and reorder conditions.
669 For a symbol subject to a GOT relocation, reserve a slot in the
670 relocation section if the symbol isn't dynamic and we are in PIC mode.
671 (_bfd_sparc_elf_relocate_section) <R_SPARC_GOTDATA_OP>: If relocation
672 is relaxed and a slot was reserved, generate a R_SPARC_NONE relocation.
673 <R_SPARC_GOTDATA_OP_HIX22>: Adjust comments.
674 <R_SPARC_PC10>: Reorder conditions. Remove always-false assertion.
675 (_bfd_sparc_elf_finish_dynamic_symbol): Rename local_undefweak into
676 resolved_to_zero. Do not generate a dynamic GOT relocation for an
677 undefined weak symbol with non-default visibility. Remove superfluous
678 'else' and fix formatting.
679
680 2018-02-09 H.J. Lu <hongjiu.lu@intel.com>
681
682 * elf32-i386.c (elf_i386_get_synthetic_symtab): Also handle
683 is_solaris.
684 (i386_elf32_sol2_vec): Don't declare.
685 (elf_i386_link_setup_gnu_properties): Also handle is_solaris.
686 Don't set need_global_offset_table.
687 (elf_i386_solaris_arch_bed): New.
688 (elf_backend_arch_data): Set to elf_i386_solaris_arch_bed for
689 Solaris.
690 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Check
691 target_os != is_nacl instead of target_os == is_normal.
692 (x86_64_elf64_sol2_vec): Don't declare.
693 (elf_x86_64_link_setup_gnu_properties): Check target_os !=
694 is_nacl instead of target_os == is_normal. Don't set
695 need_global_offset_table.
696 (elf_x86_64_solaris_arch_bed): New.
697 (elf_backend_arch_data): Set to elf_x86_64_solaris_arch_bed for
698 Solaris.
699 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep
700 _GLOBAL_OFFSET_TABLE_ for Solaris.
701 (_bfd_x86_elf_link_setup_gnu_properties): Don't copy
702 need_global_offset_table.
703 * elfxx-x86.h (elf_x86_target_os): Add is_solaris.
704 (elf_x86_link_hash_table): Remove need_global_offset_table.
705 (elf_x86_init_table): Likewise.
706
707 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
708
709 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
710 Remove prototype.
711 (i386_elf32_sol2_vec): Declared.
712 (elf_i386_link_setup_gnu_properties): Set
713 need_global_offset_table with info->output_bfd->xvec.
714 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
715 Remove prototype.
716 (x86_64_elf64_sol2_vec): Declared.
717 (elf_x86_64_link_setup_gnu_properties): Set
718 need_global_offset_table with info->output_bfd->xvec.
719
720 2018-02-08 H.J. Lu <hongjiu.lu@intel.com>
721
722 * elf32-i386.c (elf32_i386_copy_solaris_special_section_fields):
723 New prototype.
724 (elf_i386_link_setup_gnu_properties): Set need_global_offset_table
725 for Solaris.
726 * elf64-x86-64.c (elf64_x86_64_copy_solaris_special_section_fields):
727 New prototype.
728 (elf_x86_64_link_setup_gnu_properties): Set
729 need_global_offset_table for Solaris.
730 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Keep the
731 unused _GLOBAL_OFFSET_TABLE_ for Solaris.
732 (_bfd_x86_elf_link_setup_gnu_properties): Copy
733 need_global_offset_table.
734 * elfxx-x86.h (elf_x86_link_hash_table): Add
735 need_global_offset_table.
736 (elf_x86_init_table): Likewise.
737
738 2018-02-08 Jim Wilson <jimw@sifive.com>
739
740 * elfnn-riscv.c (riscv_elf_relocate_section): Add comment for previous
741 change.
742
743 2018-02-08 Nick Clifton <nickc@redhat.com>
744
745 PR 22788
746 * elf.c (elf_parse_notes): Reject notes with excessuively large
747 alignments.
748
749 2018-02-07 Alan Modra <amodra@gmail.com>
750
751 Revert 2018-01-17 Alan Modra <amodra@gmail.com>
752 * elf32-ppc.c: Remove speculation barrier support.
753 * elf32-ppc.h: Likewise.
754 * elf64-ppc.c: Likewise.
755 * elf64-ppc.h: Likewise.
756
757 2018-02-06 Jim Wilson <jimw@sifive.com>
758
759 * elfnn-riscv.c (riscv_elf_relocate_section): Return TRUE if used
760 callback to report an error.
761
762 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
763
764 PR ld/22263
765 * elfxx-sparc.c (sparc_elf_tls_transition): Turn call to bfd_link_pic
766 into call to !bfd_link_executable and tidy up.
767 (_bfd_sparc_elf_check_relocs): Fix formatting and tidy up.
768 <R_SPARC_TLS_LE_HIX22>: Turn call to bfd_link_pic into call to
769 !bfd_link_executable.
770 <R_SPARC_TLS_IE_HI22>: Likewise.
771 <GOT relocations>: Remove useless code, tidy and merge related blocks.
772 <R_SPARC_TLS_GD_CALL>: Turn call to bfd_link_pic into call to
773 !bfd_link_executable.
774 <R_SPARC_WPLT30>: Tidy up.
775 (_bfd_sparc_elf_gc_mark_hook): Turn call to bfd_link_pic into call to
776 !bfd_link_executable.
777 (allocate_dynrelocs): Likewise.
778 (_bfd_sparc_elf_relocate_section): Fix formatting and tidy up.
779 <R_SPARC_TLS_GD_HI22>: Merge into...
780 <R_SPARC_TLS_GD_LO10>: ...this. Adjust 4th argument in call to
781 sparc_elf_tls_transition and remove redundant code.
782 <R_SPARC_TLS_LDM_HI22>: Turn call to bfd_link_pic into call to
783 !bfd_link_executable.
784 <R_SPARC_TLS_LDO_HIX22>: Likewise.
785 <R_SPARC_TLS_LE_HIX22>: Likewise. Tidy up.
786 <R_SPARC_TLS_LDM_CALL>: Likewise.
787 <R_SPARC_TLS_GD_CALL>: Likewise. Tidy up.
788 <R_SPARC_TLS_GD_ADD>: Likewise.
789 <R_SPARC_TLS_LDM_ADD>: Likewise.
790 <R_SPARC_TLS_LDO_ADD>: Likewise.
791 <R_SPARC_TLS_IE_LD>: Likewise.
792
793 2018-02-06 Miloš Stojanović <milos.stojanovic@rt-rk.com>
794
795 PR 22789
796 * elfxx-mips.c (_bfd_mips_elf_find_nearest_line): If the dwarf
797 functions failed to find the function name, try the generic elf
798 find function instead.
799
800 2018-02-06 Sergio Durigan Junior <sergiodj@redhat.com>
801
802 * coff-rs6000.c (xcoff_write_archive_contents_old): Use
803 'memcpy' instead of 'strncpy' when writing the magic number.
804
805 2018-02-06 Nick Clifton <nickc@redhat.com>
806
807 PR 22794
808 * opncls.c (bfd_get_debug_link_info_1): Check the size of the
809 section before attempting to read it in.
810 (bfd_get_alt_debug_link_info): Likewise.
811
812 2018-02-06 Paul Carroll <pcarroll@codesourcery.com>
813
814 * bfd/dwarf2.c (find_abstract_name): Modified to return file and
815 line information in addition to name, if they can be found.
816
817 2018-02-05 Renlin Li <renlin.li@arm.com>
818
819 PR ld/22764
820 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Relax the
821 R_AARCH64_ABS32 and R_AARCH64_ABS16 for absolute symbol. Apply the
822 check for writeable section as well.
823
824 2018-02-05 H.J. Lu <hongjiu.lu@intel.com>
825
826 PR ld/22782
827 * elf32-i386.c (elf_i386_check_relocs): Set got_referenced if
828 _GLOBAL_OFFSET_TABLE_ is referenced or GOT is needed to resolve
829 undefined weak symbol to 0.
830 * elf64-x86-64.c (elf_x86_64_check_relocs): Set got_referenced
831 if _GLOBAL_OFFSET_TABLE_ is referenced.
832 * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Check
833 got_referenced instead of ref_regular_nonweak. Remove the
834 unused _GLOBAL_OFFSET_TABLE_ from symbol table.
835 * elfxx-x86.h (elf_x86_link_hash_table): Add got_referenced.
836
837 2018-02-05 Maciej W. Rozycki <macro@mips.com>
838
839 * elfnn-riscv.c (_bfd_riscv_relax_pc): Use `memset' to
840 initialize `hi_reloc'.
841
842 2018-02-05 Maciej W. Rozycki <macro@mips.com>
843
844 * elfxx-mips.c (_bfd_mips_elf_section_processing): For
845 SHT_MIPS_REGINFO sections don't assert the correct size and
846 report an error instead.
847
848 2018-02-05 Maciej W. Rozycki <macro@mips.com>
849
850 * elf.c (_bfd_elf_write_object_contents): Propagate a failure
851 status from `->elf_backend_section_processing'.
852
853 2018-02-02 Jim Wilson <jimw@sifive.com>
854
855 PR ld/22756
856 * elfnn-riscv.c (riscv_relax_delete_bytes): New parameter link_info.
857 If link_info->wrap_hash, check for a duplicate symbol and ignore.
858 (_bfd_riscv_relax_call, bfd_riscv_relax_lui, _bfd_riscv_relax_tls_le):
859 Pass new argument to riscv_relax_delete_bytes.
860 (_bfd_riscv_relax_align, _bfd_riscv_relax_delete): Likewise. Remove
861 ATTRIBUTE_UNUSED from link_info parameter.
862
863 2018-02-02 Alan Modra <amodra@gmail.com>
864
865 * elf64-ppc.c (ppc64_elf_relocate_section): Don't relocate nops
866 emitted for toc sequence optimization. Set and use "howto" later.
867
868 2018-02-01 Simon Marchi <simon.marchi@ericsson.com>
869
870 * elf64-ppc.c (ppc64_elf_archive_symbol_lookup): Avoid pointer
871 arithmetic on NULL pointer.
872 * elflink.c (_bfd_elf_archive_symbol_lookup,
873 elf_link_add_archive_symbols): Likewise.
874
875 2018-01-31 Michael Matz <matz@suse.de>
876
877 * elflink.c (bfd_elf_define_start_stop): Fix check of
878 def_dynamic.
879
880 2018-01-31 H.J. Lu <hongjiu.lu@intel.com>
881
882 PR ld/21964
883 * elflink.c (bfd_elf_define_start_stop): Check if __start and
884 __stop symbols are referenced by shared objects.
885
886 2018-01-30 Alan Modra <amodra@gmail.com>
887
888 PR 22758
889 * elf.c (_bfd_elf_map_sections_to_segments): Don't start a new
890 segment when demand paged with lma on the same page. Test this
891 before load/non-load, executable/non-executable,
892 writable/non-writable tests and simplify. Delete bogus relro
893 condition in writable/non-writable test. Delete outdated
894 comment. Formatting.
895
896 2018-01-30 Alan Modra <amodra@gmail.com>
897
898 * elflink.c (bfd_elf_define_start_stop): Make __start and __stop
899 symbols dynamic.
900
901 2018-01-29 Alan Modra <amodra@gmail.com>
902
903 PR 22741
904 * coffgen.c (coff_pointerize_aux): Ensure auxent tagndx is in
905 range before converting to a symbol table pointer.
906
907 2018-01-27 Nick Clifton <nickc@redhat.com>
908
909 * po/ru.po: Updated Russian translation.
910
911 2018-01-26 Alan Modra <amodra@gmail.com>
912
913 * elflink.c (bfd_elf_define_start_stop): Override symbols when
914 they are defined dynamically.
915
916 2018-01-26 Alan Modra <amodra@gmail.com>
917
918 * elf64-ppc.c (ppc64_elf_size_stubs): Iterate sizing when
919 .branch_lt changes size.
920
921 2018-01-25 Alan Modra <amodra@gmail.com>
922
923 PR 22746
924 * elfcode.h (elf_object_p): Avoid integer overflow.
925
926 2018-01-25 Eric Botcazou <ebotcazou@adacore.com>
927
928 PR ld/22727
929 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs) <R_SPARC_TLS_GD_CALL>:
930 Do a mere lookup of the __tls_get_addr symbol instead of adding it.
931
932 Revert
933 2017-10-19 H.J. Lu <hongjiu.lu@intel.com>
934
935 PR ld/22263
936 * elfxx-sparc.c (sparc_elf_tls_transition): Replace
937 bfd_link_pic with !bfd_link_executable, !bfd_link_pic with
938 bfd_link_executable for TLS check.
939 (_bfd_sparc_elf_check_relocs): Likewise.
940 (allocate_dynrelocs): Likewise.
941 (_bfd_sparc_elf_relocate_section): Likewise.
942
943 2018-01-24 Renlin Li <renlin.li@arm.com>
944
945 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Add support for
946 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
947 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
948 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
949 BFD_RELOC_AARCH64_MOVW_PREL_G3.
950 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
951 (_bfd_aarch64_elf_resolve_relocation): Likewise.
952
953 2018-01-24 Renlin Li <renlin.li@arm.com>
954
955 * reloc.c: Add BFD_RELOC_AARCH64_MOVW_PREL_G0,
956 BFD_RELOC_AARCH64_MOVW_PREL_G0_NC, BFD_RELOC_AARCH64_MOVW_PREL_G1,
957 BFD_RELOC_AARCH64_MOVW_PREL_G1_NC, BFD_RELOC_AARCH64_MOVW_PREL_G2,
958 BFD_RELOC_AARCH64_MOVW_PREL_G2_NC, BFD_RELOC_AARCH64_MOVW_PREL_G3.
959 * elfnn-aarch64.c (elfNN_aarch64_howto_table): Add entries for
960 BFD_RELOC_AARCH64_MOVW_PREL_G0, BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
961 BFD_RELOC_AARCH64_MOVW_PREL_G1, BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
962 BFD_RELOC_AARCH64_MOVW_PREL_G2, BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
963 BFD_RELOC_AARCH64_MOVW_PREL_G3.
964 * bfd-in2.h: Regenerate.
965 * libbfd.h: Regenerate.
966
967 2018-01-23 Maciej W. Rozycki <macro@mips.com>
968
969 * elfxx-mips.c (_bfd_mips_elf_final_link): Update a stale
970 `mips_elf32_section_processing' comment reference.
971
972 2018-01-20 H.J. Lu <hongjiu.lu@intel.com>
973
974 PR ld/22721
975 * elfxx-x86.c (_bfd_x86_elf_link_check_relocs): Check the
976 versioned __tls_get_addr symbol.
977
978 2018-01-19 Nick Clifton <nickc@redhat.com>
979
980 * po/fr.po: Updated French translation.
981
982 2018-01-18 Alan Modra <amodra@gmail.com>
983
984 * elf32-ppc.c (ppc_elf_create_glink): Correct alignment of .glink.
985 * elf64-ppc.c (ppc64_elf_size_stubs): Handle negative plt_stub_align.
986 (ppc64_elf_build_stubs): Likewise.
987
988 2018-01-17 Nick Clifton <nickc@redhat.com>
989
990 * po/ru.po: Updated Russian translation.
991 * po/uk/po: Updated Ukranian translation.
992
993 2018-01-17 Alan Modra <amodra@gmail.com>
994
995 * elf64-ppc.c (ppc64_elf_build_stubs): Silence gcc warning.
996
997 2018-01-17 Alan Modra <amodra@gmail.com>
998
999 * elf32-ppc.c (GLINK_ENTRY_SIZE): Handle speculation barrier.
1000 (CRSETEQ, BEQCTRM): Define.
1001 (is_nonpic_glink_stub): Don't check bctr.
1002 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
1003 (ppc_elf_relax_section): Size speculation barrier.
1004 (output_bctr): New function.
1005 (write_glink_stub): Use output_bctr.
1006 (ppc_elf_relocate_section): Use output_bctr for long branch stub.
1007 (ppc_elf_finish_dynamic_symbol): Likewise.
1008 (ppc_elf_finish_dynamic_sections): Use output_bctr.
1009 * elf32-ppc.h (struct ppc_elf_params): Add speculate_indirect_jumps.
1010 * elf64-ppc.c (CRSETEQ, BEQCTRM, BEQCTRLM): Define.
1011 (GLINK_PLTRESOLVE_SIZE): Size speculation barrier.
1012 (size_global_entry_stubs): Handle speculation barrier sizing.
1013 (plt_stub_size): Likewise.
1014 (output_bctr): New function.
1015 (build_plt_stub, build_tls_get_addr_stub): Output speculation
1016 barrier.
1017 (ppc_build_one_stub): Likewise for ppc_stub_plt_branch.
1018 (ppc_size_one_stub): Size speculation barrier in ppc_stub_plt_branch.
1019 (build_global_entry_stubs): Output speculation barrier.
1020 (ppc64_elf_build_stubs): Likewise in __glink_PLTresolve stub.
1021 * elf64-ppc.h (struct ppc64_elf_params): Add speculate_indirect_jumps.
1022
1023 2018-01-17 Alan Modra <amodra@gmail.com>
1024
1025 * elf32-ppc.c (GLINK_ENTRY_SIZE): Add parameters, handle
1026 __tls_get_addr_opt, and alignment sizing.
1027 (TLS_GET_ADDR_GLINK_SIZE): Delete.
1028 (is_nonpic_glink_stub): Don't use GLINK_ENTRY_SIZE.
1029 (ppc_elf_get_synthetic_symtab): Recognize stubs spaced at 4, 6,
1030 or 8 insns.
1031 (ppc_elf_link_hash_table_create): Init new ppc_elf_params field.
1032 (allocate_dynrelocs): Use new GLINK_ENTRY_SIZE.
1033 (ppc_elf_size_dynamic_sections): Likewise. Size branch table
1034 by PLT reloc count.
1035 (write_glink_stub): Handle __tls_get_addr_opt stub.
1036 Pad out to size given by GLINK_ENTRY_SIZE.
1037 (ppc_elf_relocate_section): Adjust write_glink_stub call.
1038 (ppc_elf_finish_dynamic_symbol): Likewise.
1039 (ppc_elf_finish_dynamic_sections): Write PLTresolve without using
1040 insn array since so many need rewriting.
1041 * elf32-ppc.h (struct ppc_elf_params): Add plt_stub_align.
1042 * elf64-ppc.c (GLINK_PLTRESOLVE_SIZE): Rename from
1043 GLINK_CALL_STUB_SIZE. Add htab param and evaluate to size without
1044 nops. Adjust all uses.
1045 (ppc64_elf_get_synthetic_symtab): Don't use GLINK_CALL_STUB_SIZE
1046 in glink_vma calculation.
1047 (struct ppc_link_hash_table): Add global_entry section pointer.
1048 (create_linkage_sections): Create separate section for global
1049 entry stubs.
1050 (PPC_LO, PPC_HI, PPC_HA): Move earlier.
1051 (size_global_entry_stubs): Handle sizing for aligned stubs.
1052 (ppc64_elf_size_dynamic_sections): Handle global_entry alloc,
1053 and don't stash end of glink branch table in rawsize.
1054 (ppc_build_one_stub): Rewrite stub size calculations.
1055 (build_global_entry_stubs): Use new section.
1056 (ppc64_elf_build_stubs): Don't pad __glink_PLTresolve with nops.
1057 Build lazy link stubs out to end of section. Build global entry
1058 stubs in new section.
1059
1060 2018-01-15 Nick Clifton <nickc@redhat.com>
1061
1062 * po/uk.po: Updated Ukranian translation.
1063
1064 2018-01-13 Nick Clifton <nickc@redhat.com>
1065
1066 * po/bfd.pot: Regenerated.
1067
1068 2018-01-13 Nick Clifton <nickc@redhat.com>
1069
1070 * version.m4: Bump version to 2.30.51
1071 * configure: Regenerate.
1072
1073 2018-01-13 Nick Clifton <nickc@redhat.com>
1074
1075 2.30 branch created.
1076
1077 2018-01-12 Jens Widell <jl@opera.com>
1078
1079 * elf.c (setup_group): Optimize search for group by remembering
1080 last found group and restarting search at that index.
1081 * elf-bfd.h (struct elf_obj_tdata): Add group_search_offset field.
1082
1083 2018-01-12 Gunther Nikl <gnikl@users.sourceforge.net>
1084
1085 * aoutx.h (aout_link_check_ar_symbols): Remove default and handle
1086 bfd_link_common_skip_none in switch.
1087
1088 2018-01-12 Alan Modra <amodra@gmail.com>
1089
1090 PR ld/22649
1091 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Ignore dynamic
1092 references on forced local symbols.
1093
1094 2018-01-12 Vlad Ivanov <vlad@ivanov.email>
1095
1096 * elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
1097 .reginfo section has wrong size.
1098
1099 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
1100
1101 PR ld/22393
1102 * elf.c (_bfd_elf_map_sections_to_segments): When generating
1103 separate code and read-only data LOAD segments, create a new
1104 LOAD segment if the previous section contains text and the
1105 current section doesn't or vice versa. Don't put a writable
1106 section in a read-only segment if there is a RELRO segment.
1107
1108 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
1109
1110 PR ld/22649
1111 * elflink.c (bfd_elf_gc_mark_dynamic_ref_symbol): Ignore dynamic
1112 references on forced local symbols.
1113
1114 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
1115
1116 PR ld/22677
1117 * elflink.c (bfd_elf_gc_sections): Keep all PREINIT_ARRAY,
1118 INIT_ARRAY as well as FINI_ARRAY sections for ld -r --gc-section.
1119
1120 2017-09-27 Kuan-Lin Chen <kuanlinchentw@gmail.com>
1121
1122 PR 22662
1123 * elf32-nds32.c (nds32_elf_relax_loadstore): Fix a typographical error.
1124
1125 2018-01-03 John Baldwin <jhb@FreeBSD.org>
1126
1127 * elf.c (elfcore_grok_freebsd_note): Handle
1128 NT_FREEBSD_PROCSTAT_PROC, NT_FREEBSD_PROCSTAT_FILES, and
1129 NT_FREEBSD_PROCSTAT_VMMAP.
1130
1131 2018-01-03 Alan Modra <amodra@gmail.com>
1132
1133 Update year range in copyright notice of all files.
1134
1135 For older changes see ChangeLog-2017
1136 \f
1137 Copyright (C) 2018 Free Software Foundation, Inc.
1138
1139 Copying and distribution of this file, with or without modification,
1140 are permitted in any medium without royalty provided the copyright
1141 notice and this notice are preserved.
1142
1143 Local Variables:
1144 mode: change-log
1145 left-margin: 8
1146 fill-column: 74
1147 version-control: never
1148 End:
This page took 0.077057 seconds and 4 git commands to generate.