gdb.base/commands.exp: Remove unused global references
[deliverable/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
90efb642
L
12017-08-28 H.J. Lu <hongjiu.lu@intel.com>
2
3 PR binutils/22018
4 * elf32-i386.c (elf_i386_get_synthetic_symtab): Check for valid
5 PLT section size.
6 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.
7
596dc58f
L
82017-08-27 H.J. Lu <hongjiu.lu@intel.com>
9
10 * elf32-i386.c (elf_i386_link_hash_newfunc): Initialize
11 def_protected.
12 * elf64-x86-64.c (elf_x86_64_link_hash_newfunc): Likewise.
13
a5b4ee94
L
142017-08-26 H.J. Lu <hongjiu.lu@intel.com>
15
16 PR ld/21997
17 * elf-bfd.h (elf_obj_tdata): Use ENUM_BITFIELD on object_id,
18 dyn_lib_class and has_gnu_symbols. Change bad_symtab to bitfield.
19 Add a has_no_copy_on_protected bitfield.
20 (elf_has_no_copy_on_protected): New.
21 * elf-properties.c (_bfd_elf_parse_gnu_properties): Set
22 elf_has_no_copy_on_protected for GNU_PROPERTY_NO_COPY_ON_PROTECTED.
23 (elf_merge_gnu_property_list): Likewise.
24 (_bfd_elf_link_setup_gnu_properties): Set extern_protected_data
25 to FALSE for elf_has_no_copy_on_protected.
26 * elf32-i386.c (SYMBOL_NO_COPYRELOC): New.
27 (elf_i386_link_hash_entry): Add def_protected.
28 (elf_i386_adjust_dynamic_symbol): Also check SYMBOL_NO_COPYRELOC
29 when checking info->nocopyreloc.
30 (elf_i386_link_setup_gnu_properties): Don't set
31 extern_protected_data here.
32 (elf_i386_merge_symbol_attribute): New function.
33 (elf_backend_merge_symbol_attribute): New.
34 * elf64-x86-64.c (SYMBOL_NO_COPYRELOC): New.
35 (elf_x86_64_link_hash_entry): Add def_protected.
36 (elf_x86_64_need_pic): Report protected symbol for def_protected.
37 (elf_x86_64_adjust_dynamic_symbol): Also check SYMBOL_NO_COPYRELOC
38 when checking info->nocopyreloc.
39 (elf_x86_64_relocate_section): Also check for R_X86_64_PC32
40 relocation run-time overflow and unresolvable R_X86_64_32S
41 relocation against protected data symbol defined in shared object
42 with GNU_PROPERTY_NO_COPY_ON_PROTECTED.
43 (elf_x86_64_link_setup_gnu_properties): Don't set
44 extern_protected_data here.
45 (elf_x86_64_merge_symbol_attribute): New function.
46 (elf_backend_merge_symbol_attribute): New.
47
7c8bbca5
AM
482017-08-26 Alan Modra <amodra@gmail.com>
49
50 * elf32-ppc.c (must_be_dyn_reloc): Use bfd_link_dll. Comment.
51 (ppc_elf_check_relocs): Only set DF_STATIC_TLS in shared libs.
52 (ppc_elf_relocate_section): Comment fix.
53 * elf64-ppc.c (must_be_dyn_reloc): Use bfd_link_dll. Comment.
54 (ppc64_elf_check_relocs): Only set DF_STATIC_TLS in shared libs.
55 Support dynamic relocs for TPREL16 when non-pic too.
56 (dec_dynrel_count): Adjust TPREL16 handling as per check_relocs.
57 (ppc64_elf_relocate_section): Support dynamic relocs for TPREL16
58 when non-pic too.
59
5fdda9d6
L
602017-08-25 H.J. Lu <hongjiu.lu@intel.com>
61
62 * elf32-i386.c (elf_i386_link_hash_entry): Remove redundant
63 "symbol" in comments.
64 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Likewise.
65
7073b5b9
L
662017-08-24 H.J. Lu <hongjiu.lu@intel.com>
67
68 PR ld/22001
69 * elf64-x86-64.c (elf_x86_64_relocate_section): Check for
70 R_X86_64_PC32 relocation run-time overflow and unresolvable
71 R_X86_64_32S relocation with -z nocopyreloc.
72
34bb2571
L
732017-08-24 H.J. Lu <hongjiu.lu@intel.com>
74
75 * elf32-i386.c (elf_i386_check_relocs): Revert the last change.
76 Undefined symbols may not have a type.
77 * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
78
aab921ad
L
792017-08-23 H.J. Lu <hongjiu.lu@intel.com>
80
81 * elf64-x86-64.c (elf_x86_64_need_pic): Add an argument for
82 bfd_link_info. Report shared, PIE or PDE object based on
83 bfd_link_info.
84 (elf_x86_64_check_relocs): Update elf_x86_64_need_pic call.
85 (elf_x86_64_relocate_section): Likewise.
86
b1bb697e
L
872017-08-23 H.J. Lu <hongjiu.lu@intel.com>
88
89 * elf32-i386.c (elf_i386_check_relocs): Increment PLT count only
90 for function symbols.
91 * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
92
73784fa5
L
932017-08-23 H.J. Lu <hongjiu.lu@intel.com>
94
95 * elf32-i386.c (elf_i386_link_setup_gnu_properties): Set
96 extern_protected_data to FALSE if GNU_PROPERTY_NO_COPY_ON_PROTECTED
97 is set on any input relocatable file.
98 * elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Likewise.
99
46434633
AM
1002017-08-23 Alan Modra <amodra@gmail.com>
101
102 PR 21988
103 * elf64-ppc.c (ensure_undef_dynamic): Rename from
104 ensure_undefweak_dynamic. Handle undefined too.
105 * elf32-ppc.c (ensure_undef_dynamic): Likewise.
106 * elf32-hppa.c (ensure_undef_dynamic): Likewise.
107 (allocate_dynrelocs): Discard undefined non-default visibility
108 relocs first. Make undefined syms dynamic. Tidy goto.
109
487b6440
AM
1102017-08-21 Alan Modra <amodra@gmail.com>
111 H.J. Lu <hongjiu.lu@intel.com>
112
113 PR ld/21964
114 * elf-bfd.h (SYMBOLIC_BIND): Return TRUE for __start/__stop symbols.
115 * elflink.c (bfd_elf_define_start_stop): Rewrite.
116
284d826d
HPN
1172017-08-21 Hans-Peter Nilsson <hp@bitrange.com>
118
119 PR ld/20125
120 * elf64-mmix.c (mmix_elf_relax_section): Correct handling of
121 undefined weak symbols.
122
de259397
NC
1232017-08-18 Nick Clifton <nickc@redhat.com>
124
125 PR binutils/21962
126 * tekhex.c (getsym): Fix check for source pointer walking off the
127 end of the input buffer.
128
545bc2b3
SN
1292017-08-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
130
131 PR ld/18808
132 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Skip IFUNC
133 relocations in debug sections, change abort to _bfd_error_handler.
134
0c54f692
NC
1352017-08-14 Nick Clifton <nickc@redhat.com>
136
137 PR 21957
138 * elf.c (setup_group): Check for an empty or very small group
139 section.
140 * po/bfd.pot: Regenerate.
141
79a94a2a
AM
1422017-08-14 Alan Modra <amodra@gmail.com>
143
144 PR 21441
145 * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't add
146 alignment padding here.
147 * elflink.c (bfd_elf_discard_info): Add .eh_frame padding here
148 in a reverse pass over sections.
149
98c5dfc9
L
1502017-08-11 H.J. Lu <hongjiu.lu@intel.com>
151
152 PR binutils/21943
153 * elf32-i386.c (elf_i386_get_synthetic_symtab): Allocate space
154 for @plt suffixes first.
155 * elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.
156
24d3e51b
NC
1572017-08-08 Nick Clifton <nickc@redhat.com>
158
159 PR 21916
160 * elf-attrs.c (_bfd_elf_parse_attributes): Complain about very
161 small section lengths.
162 * elf.c (_bfd_elf_setup_sections): Skip empty entries in the group
163 table.
164 (elfcore_grok_freebsd_prstatus): Add checks to make sure that
165 there is enough data present in the note.
166
206c9c79
AM
1672017-08-08 Alan Modra <amodra@gmail.com>
168
169 PR 21017
170 * elf32-microblaze.c (microblaze_elf_check_relocs): Don't bump
171 got.refcount for GOTOFF relocs, just create .got section.
172
2980ccad
L
1732017-08-07 H.J. Lu <hongjiu.lu@intel.com>
174
175 * elflink.c (elf_link_add_object_symbols): Move common symbol
176 check after bed->common_definition.
177
b3293efa
AM
1782017-08-07 Alan Modra <amodra@gmail.com>
179
180 PR 21910
181 * elflink.c (bfd_elf_final_link): Don't segfault when sections
182 needed to define various dynamic tags have been discarded.
183
b7a18930
NC
1842017-08-07 Nick Clifton <nickc@redhat.com>
185
186 PR 21884
187 * elf32-i386.c (elf_i386_link_setup_gnu_properties): If the dynobj
188 has not been set then use the bfd returned by
189 _bfd_elf_link_setup_gnu_properties. If that is null then search
190 through all the input bfds selecting the first normal, ELF format
191 one.
192 * elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Likewise.
193
1d4af308
L
1942017-08-06 H.J. Lu <hongjiu.lu@intel.com>
195
196 * elf32-i386.c (elf_i386_link_hash_entry): Change tls_get_addr
197 to 1 bit.
198 (elf_i386_link_hash_newfunc): Initialize tls_get_addr to 0.
199 (elf_i386_check_tls_transition): Check tls_get_addr directly.
200 (elf_i386_convert_load_reloc): Update tls_get_addr check.
201 (elf_i386_link_check_relocs): New function.
202 (bfd_elf32_bfd_link_check_relocs): New.
203 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Change tls_get_addr
204 to 1 bit.
205 (elf_x86_64_link_hash_newfunc): Initialize tls_get_addr to 0.
206 (elf_x86_64_check_tls_transition): Check tls_get_addr directly.
207 (elf_x86_64_convert_load_reloc): Update tls_get_addr check.
208 (elf_x86_64_link_check_relocs): New function.
209 (bfd_elf64_bfd_link_check_relocs): New.
210 (bfd_elf32_bfd_link_check_relocs): Likewise.
211
a4819f54
L
2122017-08-06 H.J. Lu <hongjiu.lu@intel.com>
213
214 PR ld/21903:
215 * elflink.c (elf_link_add_object_symbols): Treat common symbol
216 as undefined for --no-define-common.
217
55ef6584
AM
2182017-08-05 Alan Modra <amodra@gmail.com>
219
220 * elf32-hppa.c (elf32_hppa_set_gp): Don't require an
221 hppa_link_hash_table.
222
d84ed528
MF
2232017-08-02 Max Filippov <jcmvbkbc@gmail.com>
224
225 * xtensa-isa.c (xtensa_isa_init): Don't update lookup table
226 entries for sysregs with negative indices.
227
1ef692ea
AK
2282017-08-01 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
229
230 * elf32-s390.c (elf_s390_finish_dynamic_sections): Skip if it
231 isn't the S/390 specific elf data.
232 * elf64-s390.c (elf_s390_finish_dynamic_sections): Likewise.
233
57593436
KLC
2342017-07-31 Kuan-Lin Chen <rufus@andestech.com>
235
236 * elfxx-riscv.c (riscv_elf_add_sub_reloc): New function.
237 * (howto_table) [R_RISCV_ADD8]: Use riscv_elf_add_sub_reloc.
238 [R_RISCV_ADD16]: Likewise.
239 [R_RISCV_ADD32]: Likewise.
240 [R_RISCV_ADD64]: Likewise.
241 [R_RISCV_SUB6]: Likewise.
242 [R_RISCV_SUB8]: Likewise.
243 [R_RISCV_SUB16]: Likewise.
244 [R_RISCV_SUB32]: Likewise.
245 [R_RISCV_SUB64]: Likewise.
246
d44c746a
AM
2472017-07-31 Alan Modra <amodra@gmail.com>
248
249 * elf64-ppc.c (ppc64_elf_tls_setup): Warn on --plt-localentry
250 without ld.so checks.
251
8b5f1ed8
AM
2522017-07-29 Alan Modra <amodra@gmail.com>
253
254 PR 21847
255 * elf64-ppc.c (struct ppc_link_hash_entry): Add non_zero_localentry.
256 (ppc64_elf_merge_symbol): Set non_zero_localentry.
257 (is_elfv2_localentry0): Test non_zero_localentry.
258 (ppc64_elf_tls_setup): Default to --no-plt-localentry.
259
894dde0b
AK
2602017-07-28 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
261
262 * elf32-s390.c (elf_s390_finish_dynamic_sections): Add NULL
263 pointer check for htab->elf.irelplt.
264 * elf64-s390.c (elf_s390_finish_dynamic_sections): Likewise.
265
8bdf0be1
NC
2662017-07-27 Nick Clifton <nickc@redhat.com>
267
268 PR 21840
269 * mach-o.c (bfd_mach_o_read_symtab_strtab): Fail if the symtab
270 size is -1.
271 * nlmcode.h (nlm_swap_auxiliary_headers_in): Replace assertion
272 with error return.
273 * section.c (bfd_make_section_with_flags): Fail if the name or bfd
274 are NULL.
275 * vms-alpha.c (bfd_make_section_with_flags): Correct computation
276 of end pointer.
277 (evax_bfd_print_emh): Check for invalid string lengths.
278
c26bb067
NC
2792017-07-25 Nick Clifton <nickc@redhat.com>
280
281 * po/fr.po: Updated French translation.
282
cfe7b9bd
BG
2832017-07-25 Benjamin Green <bengreen5mx@gmail.com>
284
285 PR 21824
286 * elf32-msp430.c (msp430_elf_relax_section): Allow conversion of
287 16-bit absolute branches into 10-bit pc-relative branches on the
288 MSP430 as well as the MSP430X.
289
d4aaa2a0
AM
2902017-07-25 Alan Modra <amodra@gmail.com>
291
292 * elf64-ppc.c (struct map_stub): Add tls_get_addr_opt_bctrl.
293 (stub_eh_frame_size): New function.
294 (ppc_size_one_stub): Set group tls_get_addr_opt_bctrl.
295 (group_sections): Init group tls_get_addr_opt_bctrl.
296 (ppc64_elf_size_stubs): Update sizing and initialization of
297 .eh_frame. Iteration over stubs via group list.
298 (ppc64_elf_build_stubs): Iterate over stubs via group list.
299 (ppc64_elf_finish_dynamic_sections): Update finalization of
300 .eh_frame.
301
ca4cf9b9
NC
3022017-07-24 Nick Clifton <nickc@redhat.com>
303
304 PR 21813
305 * mach-o.c (bfd_mach_o_canonicalize_relocs): Pass the base address
306 of the relocs to the canonicalize_one_reloc routine.
307 * mach-o.h (struct bfd_mach_o_backend_data): Update the prototype
308 for the _bfd_mach_o_canonicalize_one_reloc field.
309 * mach-o-arm.c (bfd_mach_o_arm_canonicalize_one_reloc): Add
310 res_base parameter. Use to check for corrupt pair relocs.
311 * mach-o-aarch64.c (bfd_mach_o_arm64_canonicalize_one_reloc):
312 Likewise.
313 * mach-o-i386.c (bfd_mach_o_i386_canonicalize_one_reloc):
314 Likewise.
315 * mach-o-x86-64.c (bfd_mach_o_x86_64_canonicalize_one_reloc):
316 Likewise.
317
318 * vms-alpha.c (_bfd_vms_slurp_eihd): Make sure that there is
319 enough data in the record before attempting to parse it.
320 (_bfd_vms_slurp_eeom): Likewise.
321
322 (_bfd_vms_slurp_egsd): Check for an invalid section index.
323 (image_set_ptr): Likewise.
324 (alpha_vms_slurp_relocs): Likewise.
325
8a2df5e2
NC
326 (alpha_vms_object_p): Check for a truncated record.
327
47aeb64c
NC
3282017-07-24 Nick Clifton <nickc@redhat.com>
329
330 PR 21803
331 * reloc.c (_bfd_unrecognized_reloc): New function. Reports
332 an unrecognized reloc and sets the bfd_error value.
333 * libbfd.h: Regenerate.
334 * elf32-arm.c (elf32_arm_final_link_relocate): Use the new
335 function.
336 * elf32-i386.c (elf_i386_relocate_section): Likewise.
337 * elf32-tilepro.c (tilepro_elf_relocate_section): Likewise.
338 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
339 * elfnn-aarch64.c (elfNN_aarch64_relocate_section): Likewise.
340 * elfxx-tilegx.c (tilegx_elf_relocate_section): Likewise.
341
15a3a14f
AM
3422017-07-23 Alan Modra <amodra@gmail.com>
343
344 * elf64-ppc.c (ppc64_elf_size_stubs): Correct advance to
345 restore of LR.
346
f2e6a843
SN
3472017-07-19 Szabolcs Nagy <szabolcs.nagy@arm.com>
348
349 PR ld/18841
350 * elfnn-aarch64.c (elfNN_aarch64_reloc_type_class): Return
351 reloc_class_ifunc for ifunc symbols.
352
909e4e71
NC
3532017-07-19 Nick Clifton <nickc@redhat.com>
354
355 PR 21787
356 * archive.c (bfd_generic_archive_p): If the bfd does not have the
357 correct magic bytes at the start, set the error to wrong format
358 and clear the format selector before returning NULL.
359
29866fa1
NC
3602017-07-19 Nick Clifton <nickc@redhat.com>
361
362 PR 21786
363 * coff-rs6000.c (_bfd_strntol): New function.
364 (_bfd_strntoll): New function.
365 (GET_VALUE_IN_FIELD): New macro.
366 (EQ_VALUE_IN_FIELD): new macro.
367 (_bfd_xcoff_slurp_armap): Use new macros.
368 (_bfd_xcoff_archive_p): Likewise.
369 (_bfd_xcoff_read_ar_hdr): Likewise.
370 (_bfd_xcoff_openr_next_archived_file): Likewise.
371 (_bfd_xcoff_stat_arch_elt): Likewise.
6c4e7b6b
NC
372 * coff64-rs6000.c (_bfd_strntol): New function.
373 (_bfd_strntoll): New function.
374 (GET_VALUE_IN_FIELD): New macro.
375 (xcoff64_slurp_armap): Use new macros.
29866fa1 376
684d5a10
JEM
3772017-07-19 Claudiu Zissulescu <claziss@synopsys.com>
378 John Eric Martin <John.Martin@emmicro-us.com>
379
380 * bfd-in2.h: Regenerate.
381 * libbfd.h: Regenerate.
382 * elf32-arc.c (JLI): Define.
383 * reloc.c: Add JLI relocations.
384
de194d85
YC
3852017-07-18 Nick Clifton <nickc@redhat.com>
386
387 PR 21775
388 * coff-sh.c: Fix spelling typos.
389 * compress.c: Likewise.
390 * cpu-pdp11.c: Likewise.
391 * ecofflink.c: Likewise.
392 * elf-m10300.c: Likewise.
393 * elf.c: Likewise.
394 * elf32-arm.c: Likewise.
395 * elf32-m68k.c: Likewise.
396 * elf32-nds32.c: Likewise.
397 * elf32-ppc.c: Likewise.
398 * elf32-sh.c: Likewise.
399 * elf32-v850.c: Likewise.
400 * elf64-ppc.c: Likewise.
401 * elf64-x86-64.c: Likewise.
402 * elflink.c: Likewise.
403 * elfnn-aarch64.c: Likewise.
404 * elfxx-mips.c: Likewise.
405 * som.c: Likewise.
406 * sunos.c: Likewise.
407 * vms-alpha.c: Likewise.
408 * xcofflink.c: Likewise.
409
e4e21d9e
NC
4102017-07-18 Nick Clifton <nickc@redhat.com>
411
412 PR binutils/21781
413 * coffcode.h (handle_COMDAT): Replace abort with an error message
414 and return.
415
8e85f840
L
4162017-07-17 H.J. Lu <hongjiu.lu@intel.com>
417
418 PR ld/21782
419 * elf64-x86-64.c (elf_x86_64_relocate_section): Limit PIC check
420 to shared library.
421
dd57c19c
L
4222017-07-17 H.J. Lu <hongjiu.lu@intel.com>
423
424 * elf64-x86-64.c (elf_x86_64_relocate_section): Re-indent.
425
676ee2b5
AM
4262017-07-16 Alan Modra <amodra@gmail.com>
427
428 * elf64-ppc.c (ppc64_elf_relocate_section): Don't optimize
429 __tls_index GOT entries when using __tls_get_addr_opt stub.
430 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
431
429d795d
AM
4322017-07-12 Alan Modra <amodra@gmail.com>
433
434 * po/es.po: Update from translationproject.org/latest/bfd/.
435 * po/fi.po: Likewise.
436 * po/fr.po: Likewise.
437 * po/id.po: Likewise.
438 * po/ja.po: Likewise.
439 * po/ro.po: Likewise.
440 * po/ru.po: Likewise.
441 * po/sr.po: Likewise.
442 * po/sv.po: Likewise.
443 * po/tr.po: Likewise.
444 * po/uk.po: Likewise.
445 * po/vi.po: Likewise.
446 * po/zh_CN.po: Likewise.
447 * po/hr.po: New file from translationproject.org.
448 * configure.ac (ALL_LINGUAS): Add hr. Sort.
449 * configure: Regenerate.
450
0bae9e9e
NC
4512017-07-12 Nick Clifton <nickc@redhat.com>
452
453 Fix compile time warnings using gcc 7.1.1.
454 * elf32-xtensa.c (elf_xtensa_get_plt_section): Increase length of
455 plt_name buffer.
456 (elf_xtensa_get_gotplt_section): Increase length of got_name
457 buffer.
458 * mach-o-arm.c (bfd_mach_o_arm_canonicalize_one_reloc): Add a
459 default return of FALSE.
460 * mach-o-i386.c (bfd_mach_o_i386_canonicalize_one_reloc): Add a
461 default return of FALSE.
462
d42c267e
AM
4632017-07-12 Alan Modra <amodra@gmail.com>
464
465 * binary.c (binary_set_section_contents): Don't print filepos in
466 error message.
467 (coff_write_object_contents): Cast size_t for error message.
468 (coff_slurp_line_table): Don't use bfd_vma symndx.
469 (coff_slurp_reloc_table): Remove unneeded cast.
470 * dwarf2.c (read_section): Cast bfd_int64_t to long long for
471 error message.
472 (find_abstract_instance_name): Likewise.
473 * elf32-arm.c (arm_type_of_stub): Correct error arg order.
474 (bfd_elf32_arm_stm32l4xx_erratum_scan): Don't cast error arg.
475 (elf32_arm_check_relocs): Make r_symndx an int.
476 * elf32-cris.c (cris_elf_check_relocs): Delete extraneous %s in
477 format string.
478 * elf32-metag.c (elf_metag_relocate_section): Delete extra error
479 message arg.
480 * elf32-nds32.c (nds32_elf_ex9_build_hash_table): Rewrite bogus
481 error message.
482 * elf32-i386.c (elf_i386_check_relocs): Make r_symndx an int.
483 * elf32-s390.c (elf_s390_check_relocs): Likewise.
484 * elf32-tic6x.c (elf32_tic6x_check_relocs): Likewise.
485 * elf32-tilepro.c (tilepro_elf_check_relocs): Likewise.
486 * elf32-xtensa.c (elf_xtensa_check_relocs): Likewise.
487 * elf64-s390.c (elf_s390_check_relocs): Likewise.
488 * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
489 * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Likewise.
490 * elfnn-riscv.c (riscv_elf_check_relocs): Likewise.
491 * elfxx-sparc.c (_bfd_sparc_elf_check_relocs): Likewise.
492 * elfxx-tilegx.c (tilegx_elf_check_relocs): Likewise.
493 * elf64-mmix.c (_bfd_mmix_after_linker_allocation): Cast size_t args
494 and use %lu for error message.
495 * elflink.c (elf_link_adjust_relocs): Delete extra error message arg.
496 * mmo.c (mmo_scan): Make stab_loc a file_ptr. Cast expression for
497 error message.
498
499 * elf32-arm.c (elf32_arm_tls_relax): Correct format string and args
500 in error message.
501 (elf32_arm_final_link_relocate): Likewise.
502 * coff-arm.c (bfd_arm_process_before_allocation): Likewise.
503 * coffcode.h (styp_to_sec_flags): Likewise.
504 * cofflink.c (_bfd_coff_write_global_sym): Likewise.
505 * ecoff.c (_bfd_ecoff_slurp_symbol_table): Likewise.
506 * elf32-arc.c (arc_elf_merge_private_bfd_data): Likewise.
507 * elf32-bfin.c (bfinfdpic_check_relocs): Likewise.
508 (elf32_bfin_merge_private_bfd_data): Likewise.
509 * elf32-cris.c (cris_elf_relocate_section): Likewise.
510 * elf32-frv.c (frv_elf_merge_private_bfd_data): Likewise.
511 * elf32-i370.c (i370_elf_merge_private_bfd_data): Likewise.
512 (i370_elf_relocate_section): Likewise.
513 * elf32-iq2000.c (iq2000_elf_merge_private_bfd_data): Likewise.
514 * elf32-m32c.c (m32c_elf_merge_private_bfd_data): Likewise.
515 * elf32-m68hc1x.c (_bfd_m68hc11_elf_merge_private_bfd_data): Likewise.
516 * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
517 * elf32-mep.c (mep_elf_merge_private_bfd_data): Likewise.
518 * elf32-mt.c (mt_elf_merge_private_bfd_data): Likewise.
519 * elf64-sparc.c (elf64_sparc_merge_private_bfd_data): Likewise.
520 * elfxx-mips.c (mips_elf_merge_obj_e_flags): Likewise.
521 (_bfd_mips_elf_merge_private_bfd_data): Likewise.
522 * ieee.c (ieee_write_id, read_id): Likewise.
523 * mach-o.c (bfd_mach_o_write_contents): Likewise.
524 (bfd_mach_o_layout_commands, bfd_mach_o_read_section_32): Likewise.
525 (bfd_mach_o_read_section_64, bfd_mach_o_read_symtab_symbol): Likewise.
526 (bfd_mach_o_read_command, bfd_mach_o_header_p): Likewise.
527 * peXXigen.c (_bfd_XXi_swap_aouthdr_in): Likewise.
528 * stabs.c (_bfd_link_section_stabs): Likewise.
529
530 * coff-arm.c (coff_arm_relocate_section): Use L modifier in error
531 format.
532 * coff-mcore.c (coff_mcore_relocate_section): Likewise.
533 * coff-ppc.c (coff_ppc_relocate_section): Likewise.
534 * coff-rs6000.c (xcoff_reloc_type_toc): Likewise.
535 * coff-sh.c (sh_relax_section): Likewise.
536 (sh_relax_delete_bytes, sh_swap_insns): Likewise.
537 * coff-tic80.c (coff_tic80_relocate_section): Likewise.
538 * coffcode.h (coff_slurp_reloc_table): Likewise.
539 * coffgen.c (_bfd_coff_get_external_symbols): Likewise.
540 (_bfd_coff_read_string_table): Likewise.
541 * cofflink.c (_bfd_coff_generic_relocate_section): Likewise.
542 * compress.c (bfd_get_full_section_contents): Likewise.
543 * dwarf2.c (read_formatted_entries, decode_line_info): Likewise.
544 * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
545 * elf.c (bfd_elf_string_from_elf_section): Likewise.
546 * elf32-arc.c (arc_special_overflow_checks): Likewise.
547 * elf32-arm.c (elf32_arm_tls_relax): Likewise.
548 (elf32_arm_final_link_relocate, elf32_arm_relocate_section): Likewise.
549 (elf32_arm_write_section): Likewise.
550 * elf32-bfin.c (bfin_relocate_section): Likewise.
551 (bfinfdpic_relocate_section): Likewise.
552 * elf32-hppa.c (hppa_build_one_stub): Likewise.
553 (final_link_relocate, elf32_hppa_relocate_section): Likewise.
554 * elf32-i386.c (elf_i386_tls_transition): Likewise.
555 (elf_i386_relocate_section): Likewise.
556 * elf32-ip2k.c (ip2k_final_link_relocate): Likewise.
557 * elf32-lm32.c (lm32_elf_finish_dynamic_sections): Likewise.
558 * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
559 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
560 * elf32-metag.c (elf_metag_relocate_section): Likewise.
561 * elf32-nds32.c (unrecognized_reloc_msg): Likewise.
562 (nds32_elf_relax_longcall1, nds32_elf_relax_longcall2): Likewise.
563 (nds32_elf_relax_longcall3, nds32_elf_relax_longjump1): Likewise.
564 (nds32_elf_relax_longjump2, nds32_elf_relax_longjump3): Likewise.
565 (nds32_elf_relax_longcall4, nds32_elf_relax_longcall5): Likewise.
566 (nds32_elf_relax_longcall6, nds32_elf_relax_longjump4): Likewise.
567 (nds32_elf_relax_longjump5, nds32_elf_relax_longjump6): Likewise.
568 (nds32_elf_relax_longjump7, nds32_elf_relax_loadstore): Likewise.
569 (nds32_elf_relax_ptr, nds32_elf_ex9_build_hash_table): Likewise.
570 * elf32-nios2.c (nios2_elf32_relocate_section): Likewise.
571 * elf32-rx.c (UNSAFE_FOR_PID): Likewise.
572 * elf32-s390.c (invalid_tls_insn, elf_s390_relocate_section): Likewise.
573 * elf32-score.c (s3_bfd_score_elf_check_relocs): Likewise.
574 * elf32-score7.c (s7_bfd_score_elf_check_relocs): Likewise.
575 * elf32-sh.c (sh_elf_relax_section): Likewise.
576 (sh_elf_relax_delete_bytes, sh_elf_swap_insns): Likewise.
577 (sh_elf_relocate_section): Likewise.
578 * elf32-sh64.c (shmedia_prepare_reloc): Likewise.
579 * elf32-spu.c (spu_elf_relocate_section): Likewise.
580 * elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
581 * elf32-tilepro.c (tilepro_elf_relocate_section): Likewise.
582 * elf32-v850.c (v850_elf_relax_section): Likewise.
583 * elf32-vax.c (elf_vax_check_relocs): Likewise.
584 (elf_vax_relocate_section): Likewise.
585 * elf32-xtensa.c (elf_xtensa_relocate_section): Likewise.
586 (extend_ebb_bounds_forward, extend_ebb_bounds_backward): Likewise.
587 (compute_text_actions, compute_ebb_proposed_actions): Likewise.
588 (do_fix_for_relocatable_link): Likewise.
589 * elf64-alpha.c (elf64_alpha_relax_got_load): Likewise.
590 (elf64_alpha_relax_with_lituse): Likewise.
591 * elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Likewise.
592 (elf_hppa_final_link_relocate): Likewise.
593 * elf64-ia64-vms.c (elf64_ia64_relax_section): Likewise.
594 (elf64_ia64_choose_gp, elf64_ia64_relocate_section): Likewise.
595 (elf64_vms_link_add_object_symbols): Likewise.
596 * elf64-mmix.c (mmix_elf_perform_relocation): Likewise.
597 (mmix_final_link_relocate): Likewise.
598 * elf64-s390.c (invalid_tls_insn): Likewise.
599 (elf_s390_relocate_section): Likewise.
600 * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
601 * elf64-x86-64.c (elf_x86_64_tls_transition): Likewise.
602 (elf_x86_64_relocate_section): Likewise.
603 * elfcode.h (elf_slurp_symbol_table): Likewise.
604 * elfcore.h (elf_core_file_p): Likewise.
605 * elflink.c (elf_link_read_relocs_from_section): Likewise.
606 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Likewise.
607 (elfNN_aarch64_relocate_section): Likewise.
608 * elfnn-ia64.c (elfNN_ia64_relax_section): Likewise.
609 (elfNN_ia64_choose_gp, elfNN_ia64_relocate_section): Likewise.
610 * elfnn-riscv.c (riscv_elf_relocate_section): Likewise.
611 * elfxx-mips.c (_bfd_mips_elf_check_relocs): Likewise.
612 (_bfd_mips_elf_relocate_section): Likewise.
613 (_bfd_mips_elf_finish_dynamic_symbol, mips_finish_exec_plt): Likewise.
614 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
615 * elfxx-tilegx.c (tilegx_elf_relocate_section): Likewise.
616 * ieee.c (ieee_slurp_external_symbols): Likewise.
617 * ihex.c (ihex_write_object_content): Likewise.
618 * mach-o.c (bfd_mach_o_build_exec_seg_command): Likewise.
619 * merge.c (_bfd_merged_section_offset): Likewise.
620 * mmo.c (mmo_write_loc_chunk): Likewise.
621 (mmo_write_object_contents): Likewise.
622 * peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Likewise.
623 * stabs.c (_bfd_link_section_stabs): Likewise.
624 * xcofflink.c (xcoff_link_add_symbols, xcoff_find_tc0): Likewise.
625
e3fbc3da
AM
6262017-07-11 Alan Modra <amodra@gmail.com>
627
628 * elf32-ppc.c (ppc_elf_relocate_section): Fix typo.
629
2c4d9cbe
AM
6302017-07-11 Alan Modra <amodra@gmail.com>
631
632 * elf32-ppc.c (ppc_elf_relocate_section): Emit "unexpected
633 instruction" error using _bfd_error_handler, not einfo.
634
adce5b39
NC
6352017-07-10 Nick Clifton <nickc@redhat.com>
636
637 * coffcode.h (coff_slurp_symbol_table): Do not include an entry
638 for C_AIX_WEAKEXT if it has the same value as C_WEAKEXT.
639
e6f3b9c3
JB
6402017-07-07 John Baldwin <jhb@FreeBSD.org>
641
642 * elf.c (elfcore_grok_freebsd_note): Handle NT_FREEBSD_PTLWPINFO.
643
532cc313
AM
6442017-07-07 Alan Modra <amodra@gmail.com>
645
646 * coffcode.h (coff_slurp_symbol_table): Handle C_AIX_WEAKEXT.
647
1cf9552b
AM
6482017-07-07 Alan Modra <amodra@gmail.com>
649
650 * bfd.c (_doprnt): Replace "L" with "ll" when printing bfd_vma
651 as long long. Move code replacing "ll" with "I64", and simplify.
652
a0b7b105
L
6532017-07-06 H.J. Lu <hongjiu.lu@intel.com>
654
655 * bfd.c (_doprnt): Convert 'L' to 'l' when setting wide_width
656 to 1.
657
1d827a72
L
6582017-07-05 H.J. Lu <hongjiu.lu@intel.com>
659
660 * dwarf2.c (line_info_add_include_dir_stub): Replace time with
661 xtime.
662 (line_info_add_file_name): Likewise.
663 (decode_line_info): Likewise.
664
0d702cfe
TG
6652017-07-04 Tristan Gingold <gingold@adacore.com>
666
667 * version.m4: Bump version to 2.29.51
668 * configure: Regenerate.
669
564e46b7
JW
6702017-07-04 Jiong Wang <jiong.wang@arm.com>
671
672 * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol): Remove the
673 sanity check at the head of this function.
674
0041f7df
JK
6752017-07-04 Jan Kratochvil <jan.kratochvil@redhat.com>
676
677 * dwarf2.c (struct dwarf2_debug): Add fields dwarf_line_str_buffer and
678 dwarf_line_str_size.
679 (struct attr_abbrev): Add field implicit_const.
680 (dwarf_debug_sections): Add .debug_line_str.
681 (enum dwarf_debug_section_enum): Add debug_line_str and debug_max.
682 (dwarf_debug_section_assert): Add static assertion.
683 (read_indirect_line_string): New.
684 (read_abbrevs): Support DW_FORM_implicit_const.
685 (is_str_attr): Support DW_FORM_line_strp.
686 (read_attribute_value): Support DW_FORM_line_strp and
687 DW_FORM_implicit_const.
688 (read_attribute): Support DW_FORM_implicit_const.
689 (line_info_add_include_dir, line_info_add_include_dir_stub):
690 (line_info_add_file_name, read_formatted_entries): New.
691 (decode_line_info, parse_comp_unit): Support DWARF 5.
692 (_bfd_dwarf2_cleanup_debug_info): Free dwarf_line_str_buffer.
693
d8cd8c1f
EB
6942017-07-03 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
695
696 * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): Remove the
697 abort statement that was put for symbols that are not dynamic.
698
15e6ed8c
TG
6992017-07-03 Tristan Gingold <gingold@adacore.com>
700
701 * po/bfd.pot: Regenerate
702
76cfced5
AM
7032017-07-03 Alan Modra <amodra@gmail.com>
704
705 * bfd.c (_doprnt): Rewrite "ll" and "L" modifiers to "I64" for
706 __MSVCRT__. Support "L" modifier for bfd_vma. Formatting.
707 * elf.c (setup_group): Use "Lx" to print sh_size.
708 (_bfd_elf_setup_sections): Remove unnecessary cast and print
709 unknown section type in hex.
710 (copy_special_section_fields): Style fix.
711 (bfd_section_from_shdr): Correct format for sh_link. Use a
712 common error message for all the variants of unrecognized
713 section types.
714 (assign_file_positions_for_load_sections): Use "Lx" for lma
715 adjust error message.
716 (assign_file_positions_for_non_load_sections): Formatting.
717 (rewrite_elf_program_header): Formatting. Use "Lx" for
718 bfd_vma values in error messages.
719 * elfcode.h (elf_slurp_reloc_table_from_section): Cast
720 ELF_R_SYM value to type expected by format.
721 * elflink.c (elf_link_read_relocs_from_section): Use "Lx"
722 in error messages.
723 (elf_link_add_object_symbols): Use "Lu" for symbol sizes.
724 (elf_link_input_bfd): Use "Lx" for r_info.
725 (bfd_elf_gc_record_vtinherit): Use "Lx" for offset.
726
ce9116fd
AM
7272017-07-03 Alan Modra <amodra@gmail.com>
728
729 * bfd.c (bfd_scan_vma): Don't use long long unless HAVE_LONG_LONG.
730 * coff-rs6000.c (FMT20): Handle hosts with 64-bit long and
731 Microsoft C library variant of long long format specifier.
732 (PRINT20): Cast value to bfd_uint64_t not long long.
733 * coffcode.h (coff_print_aux): Use BFD_VMA_FMT.
734 * coff-x86_64.c (coff_amd64_reloc): Use bfd_uint64_t rather than
735 long long. Don't cast to bfd_vma.
736 * elf32-score.c (score3_bfd_getl48): Likewise.
737 * vms-alpha.c (_bfd_vms_slurp_eisd): Likewise.
738
cd9af601
AM
7392017-07-03 Alan Modra <amodra@gmail.com>
740
741 * elf.c (_bfd_elf_print_private_bfd_data): Use BFD_VMA_FMT to
742 print d_tag.
743 (bfd_elf_print_symbol): Don't cast symbol->flags.
744 (_bfd_elf_symbol_from_bfd_symbol): Likewise.
745 * elf32-ppc.c (ppc_elf_begin_write_processing): Correct
746 _bfd_error_handler argument order.
747 (ppc_elf_merge_private_bfd_data): Don't cast flags.
748
33c734b2
AM
7492017-07-03 Alan Modra <amodra@gmail.com>
750
751 * configure.ac: Invoke AC_CHECK_TYPES for long long. Invoke
752 AC_TYPE_LONG_DOUBLE.
753 * configure: Regenerate.
754 * config.in: Regenerate.
755
3df5cd13
AW
7562017-06-29 Andrew Waterman <andrew@sifive.com>
757
758 * elfnn-riscv.c (riscv_elf_adjust_dynamic_symbol): Fix TLS copy
759 relocs.
760
ec1acaba
EB
7612017-06-29 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
762
763 * elfxx-sparc.c (allocate_dynrelocs): Don't make a symbol dynamic
764 unless it is undefined weak.
765 * elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Set the flag
766 relative_reloc to direct non-dynamic symbols to R_SPARC_RELATIVE
767 relocation.
768 * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): If symbol
769 is not dynamic in PIC, abort.
770
ff07562f
JW
7712017-06-29 Jiong Wang <jiong.wang@arm.com>
772
773 PR ld/21402
774 * elfnn-aarch64.c (elfNN_aarch64_allocate_dynrelocs): Only make
775 undefined weak symbols into dynamic.
776 (elfNN_aarch64_final_link_relocate): Generate runtime RELATIVE
777 relocation for non-dynamic symbols.
778 (elfNN_aarch64_finish_dynamic_symbol): Add sanity check.
779
2aff25ba
JW
7802017-06-29 Jiong Wang <jiong.wang@arm.com>
781
782 * elfnn-aarch64.c (aarch64_relocation_aginst_gp_p): New function.
783 (elfNN_aarch64_final_link_relocate): Delete duplicated code for
784 BFD_RELOC_AARCH64_LD64_GOTOFF_LO15, BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC,
785 BFD_RELOC_AARCH64_MOVW_GOTOFF_G1.
786 * elfxx-aarch64.c (_bfd_aarch64_elf_resolve_relocation): Optimize the
787 support for them.
788
88ab90e8
AA
7892017-06-29 Andreas Arnez <arnez@linux.vnet.ibm.com>
790
791 * elf-bfd.h (elfcore_write_s390_gs_cb): Add prototype.
792 (elfcore_write_s390_gs_bc): Likewise.
793 * elf.c (elfcore_grok_s390_gs_cb): New function.
794 (elfcore_grok_s390_gs_bc): New function.
795 (elfcore_grok_note): Call them.
796 (elfcore_write_s390_gs_cb): New function.
797 (elfcore_write_s390_gs_bc): New function.
798 (elfcore_write_register_note): Call them.
799
328ce951
L
8002017-06-28 H.J. Lu <hongjiu.lu@intel.com>
801
802 * libbfd.c (_bfd_generic_get_section_contents): Don't call
803 bfd_get_file_size. Check archive element size.
804 (_bfd_generic_get_section_contents_in_window): Likewise.
805
47fdcf63
L
8062017-06-28 H.J. Lu <hongjiu.lu@intel.com>
807
808 * bfd-in2.h: Regenerated.
809 * bfdio.c (bfd_get_size): Change return type to ufile_ptr.
810 (bfd_get_file_size): Likewise.
811
38bf472a
MR
8122017-06-28 Maciej W. Rozycki <macro@imgtec.com>
813 Matthew Fortune <matthew.fortune@imgtec.com>
814
815 * archures.c (bfd_mach_mips_interaptiv_mr2): New macro.
816 * cpu-mips.c (I_interaptiv_mr2): New enum value.
817 (arch_info_struct): Add "mips:interaptiv-mr2" entry.
818 * elfxx-mips.c (_bfd_elf_mips_mach) <E_MIPS_MACH_IAMR2>: New
819 case.
820 (mips_set_isa_flags) <bfd_mach_mips_interaptiv_mr2>: Likewise.
821 (bfd_mips_isa_ext) <bfd_mach_mips_interaptiv_mr2>: Likewise.
822 (print_mips_isa_ext) <AFL_EXT_INTERAPTIV_MR2>: Likewise.
823 (mips_mach_extensions): Add `bfd_mach_mipsisa32r3' and
824 `bfd_mach_mips_interaptiv_mr2' entries.
825 * bfd-in2.h: Regenerate.
826
2d68166e
NC
8272017-06-27 Nick Clifton <nickc@redhat.com>
828
829 * tekhex.c (pass_over): Revert accidental conversion of a local
830 array to a static array.
831
68063779
SKS
8322017-06-27 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
833
834 PR ld/13402
835 * elf32-avr.c (elf32_avr_adjust_diff_reloc_value): Adjust
836 reloc addend if necessary. Adjust diff only if
837 shrinked_insn_address < end_address.
838
ea9aafc4
AM
8392017-06-27 Alan Modra <amodra@gmail.com>
840
841 PR binutils/21665
842 * libbfd.c (_bfd_generic_get_section_contents): Warning fix.
843 (_bfd_generic_get_section_contents_in_window): Likewise.
844
a6cbf936
KLC
8452017-06-26 Kuan-Lin Chen <rufus@andestech.com>
846
847 * elfnn-riscv.c (perform_relocation): Support the new
848 R_RISCV_32_PCREL relocation.
849 (riscv_elf_relocate_section): Likewise.
850 * elfxx-riscv.c (howto_table): Likewise.
851 (riscv_reloc_map): Likewise.
852 * bfd-in2.h (BFD_RELOC_RISCV_32_PCREL): New relocation.
853 * libbfd.h: Regenerate.
854
7211ae50
AM
8552017-06-27 Alan Modra <amodra@gmail.com>
856
857 PR binutils/21665
858 * libbfd.c (_bfd_generic_get_section_contents): Delete abort.
859 Use unsigned file pointer type, and remove cast.
860 * libbfd.c (_bfd_generic_get_section_contents_in_window): Likewise.
861 Add "count", not "sz".
862
ab27f80c
PA
8632017-06-26 Pedro Alves <palves@redhat.com>
864
865 PR binutils/21665
866 * libbfd.c (_bfd_generic_get_section_contents): Add "count", not
867 "sz".
868
1f473e3d
L
8692017-06-26 H.J. Lu <hongjiu.lu@intel.com>
870
871 PR binutils/21665
872 * libbfd.c (_bfd_generic_get_section_contents_in_window): Add
873 a missing line.
874
b417536f
MR
8752017-06-26 Maciej W. Rozycki <macro@imgtec.com>
876
877 * cpu-mips.c (arch_info_struct): Mark the 4010 32-bit.
878 * elfxx-mips.c (mips_set_isa_flags) <bfd_mach_mips4010>: Set
879 E_MIPS_ARCH_2 rather than E_MIPS_ARCH_3 in `e_flags'.
880 (mips_mach_extensions): Mark `bfd_mach_mips4010' as extending
881 `bfd_mach_mips6000' rather than `bfd_mach_mips4000'.
882
0630b49c
L
8832017-06-26 H.J. Lu <hongjiu.lu@intel.com>
884
885 PR binutils/21665
886 * compress.c (bfd_get_full_section_contents): Don't check the
887 file size here.
888 * libbfd.c (_bfd_generic_get_section_contents): Check for and
ea9aafc4 889 reject a section whose size + offset is greater than the size
0630b49c
L
890 of the entire file.
891 (_bfd_generic_get_section_contents_in_window): Likewise.
515a4464 892
04e15b4a
NC
8932017-06-26 Nick Clifton <nickc@redhat.com>
894
895 PR binutils/21670
896 * tekhex.c (getvalue): Check for the source pointer exceeding the
897 end pointer before the first byte is read.
898
cfd14a50
NC
8992017-06-26 Nick Clifton <nickc@redhat.com>
900
901 PR binutils/21665
ea9aafc4 902 * opncls.c (get_build_id): Check that the section is big enough
cfd14a50
NC
903 to contain the whole note.
904 * compress.c (bfd_get_full_section_contents): Check for and reject
ea9aafc4 905 a section whose size is greater than the size of the entire file.
cfd14a50
NC
906 * elf32-v850.c (v850_elf_copy_notes): Allow for the ouput to not
907 contain a notes section.
908
93ec5e23
AK
9092017-06-26 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
910
911 * elf64-s390.c (elf_s390_additional_program_headers): Add NULL
912 pointer checks.
913 (elf_s390_modify_segment_map): Likewise.
914 (bfd_elf_s390_set_options): Lisewise.
915
57963c05
AM
9162017-06-26 Alan Modra <amodra@gmail.com>
917
918 * elflink.c (_bfd_elf_link_create_dynstrtab): Don't make dynobj
919 a --just-syms bfd.
920 (_bfd_elf_size_group_sections): Skip --just-syms bfds.
921 (bfd_elf_size_dynamic_sections): Ignore .note.GNU-stack and
922 .preinit_array on --just-syms bfds.
923 (_bfd_elf_gc_mark_extra_sections): Skip --just-syms bfds.
924 (elf_gc_sweep, bfd_elf_parse_eh_frame_entries): Likewise.
925 (bfd_elf_gc_sections, bfd_elf_discard_info): Likewise.
926
5cc4ca83
ST
9272017-06-25 Sergei Trofimovich <slyfox@gentoo.org>
928
929 * elf.c (find_link): Bounds check "hint".
930
bff0500d
TP
9312017-06-24 Thomas Preud'homme <thomas.preudhomme@arm.com>
932
933 * elf32-arm.c (using_thumb_only): Update list of architectures in
934 BFD_ASSERT for which the logic is valid.
935 (using_thumb2_bl): Likewise.
936 (using_thumb2): Likewise and return true for ARMv8-R.
937 (arch_has_arm_nop): Likewise.
938 (tag_cpu_arch_combine): New v8r table for ARMv8-R Tag_CPU_arch
939 merging logic. Update commentis for value 15 of v8m_baseline,
940 v8m_mainline and v4t_plus_v6_m arrays. Use v8r array to decide
941 merging of value 15 of Tag_CPU_arch.
942
4aa57d6a
JW
9432017-06-23 Jiong Wang <jiong.wang@arm.com>
944
945 * reloc.c (BFD_RELOC_AARCH64_ADR_GOTPAGE): Rename to
946 BFD_RELOC_AARCH64_ADR_GOT_PAGE
947 * bfd-in2.h: Regenerate.
948
5d8763a3
L
9492017-06-22 H.J. Lu <hongjiu.lu@intel.com>
950
951 * elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Move
952 the error_alignment label forward. Properly align program
953 property note section.
954
e652757b
EC
9552017-06-22 Eric Christopher <echristo@gmail.com>
956
957 * elf32-arm.c (elf32_arm_final_link_relocate): Use labs rather than
958 abs to fix a truncation warning.
959
84da4cf8
L
9602017-06-22 H.J. Lu <hongjiu.lu@intel.com>
961
962 * elf32-i386.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Resolve
963 local undefined weak symbol to 0.
964 * elf64-x86-64.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Likewise.
965
48580982
L
9662017-06-22 H.J. Lu <hongjiu.lu@intel.com>
967
968 * elf32-i386.c (elf_i386_merge_gnu_properties): If info->shstk
969 is set, turn on GNU_PROPERTY_X86_FEATURE_1_SHSTK.
970 (elf_i386_link_setup_gnu_properties): If info->shstk is set,
971 turn on GNU_PROPERTY_X86_FEATURE_1_IBT.
972 * elf64-x86-64.c (elf_x86_64_merge_gnu_properties): If
973 info->shstk is set, turn on GNU_PROPERTY_X86_FEATURE_1_SHSTK.
974 (elf_x86_64_link_setup_gnu_properties): If info->shstk is set,
975 turn on GNU_PROPERTY_X86_FEATURE_1_IBT.
976
ee2fdd6f
L
9772017-06-22 H.J. Lu <hongjiu.lu@intel.com>
978
979 * elf32-i386.c (elf_i386_lazy_ibt_plt0_entry): New.
980 (elf_i386_lazy_ibt_plt_entry): Likewise.
981 (elf_i386_pic_lazy_ibt_plt0_entry): Likewise.
982 (elf_i386_non_lazy_ibt_plt_entry): Likewise.
983 (elf_i386_pic_non_lazy_ibt_plt_entry): Likewise.
984 (elf_i386_eh_frame_lazy_ibt_plt): Likewise.
985 (elf_i386_lazy_plt_layout): Likewise.
986 (elf_i386_non_lazy_plt_layout): Likewise.
987 (elf_i386_link_hash_entry): Add plt_second.
988 (elf_i386_link_hash_table): Add plt_second and
989 plt_second_eh_frame.
990 (elf_i386_allocate_dynrelocs): Use the second PLT if needed.
991 (elf_i386_size_dynamic_sections): Use .plt.got unwind info for
992 the second PLT. Check the second PLT.
993 (elf_i386_relocate_section): Use the second PLT to resolve
994 PLT reference if needed.
995 (elf_i386_finish_dynamic_symbol): Fill and use the second PLT if
996 needed.
997 (elf_i386_finish_dynamic_sections): Set sh_entsize on the
998 second PLT. Generate unwind info for the second PLT.
999 (elf_i386_plt_type): Add plt_second.
1000 (elf_i386_get_synthetic_symtab): Support the second PLT.
1001 (elf_i386_parse_gnu_properties): Support
1002 GNU_PROPERTY_X86_FEATURE_1_AND.
1003 (elf_i386_merge_gnu_properties): Support
1004 GNU_PROPERTY_X86_FEATURE_1_AND. If info->ibt is set, turn
1005 on GNU_PROPERTY_X86_FEATURE_1_IBT
1006 (elf_i386_link_setup_gnu_properties): If info->ibt is set,
1007 turn on GNU_PROPERTY_X86_FEATURE_1_IBT. Use IBT-enabled PLT
1008 for info->ibtplt, info->ibt or GNU_PROPERTY_X86_FEATURE_1_IBT
1009 is set on all relocatable inputs.
1010 * elf64-x86-64.c (elf_x86_64_lazy_ibt_plt_entry): New.
1011 (elf_x32_lazy_ibt_plt_entry): Likewise.
1012 (elf_x86_64_non_lazy_ibt_plt_entry): Likewise.
1013 (elf_x32_non_lazy_ibt_plt_entry): Likewise.
1014 (elf_x86_64_eh_frame_lazy_ibt_plt): Likewise.
1015 (elf_x32_eh_frame_lazy_ibt_plt): Likewise.
1016 (elf_x86_64_lazy_ibt_plt): Likewise.
1017 (elf_x32_lazy_ibt_plt): Likewise.
1018 (elf_x86_64_non_lazy_ibt_plt): Likewise.
1019 (elf_x32_non_lazy_ibt_plt): Likewise.
1020 (elf_x86_64_get_synthetic_symtab): Support the second PLT.
1021 (elf_x86_64_parse_gnu_properties): Support
1022 GNU_PROPERTY_X86_FEATURE_1_AND.
1023 (elf_x86_64_merge_gnu_properties): Support
1024 GNU_PROPERTY_X86_FEATURE_1_AND. If info->ibt is set, turn
1025 on GNU_PROPERTY_X86_FEATURE_1_IBT
1026 (elf_x86_64_link_setup_gnu_properties): If info->ibt is set,
1027 turn on GNU_PROPERTY_X86_FEATURE_1_IBT. Use IBT-enabled PLT
1028 for info->ibtplt, info->ibt or GNU_PROPERTY_X86_FEATURE_1_IBT
1029 is set on all relocatable inputs.
1030
d19237d9
NC
10312017-06-22 Nick Clifton <nickc@redhat.com>
1032
1033 PR binutils/21649
1034 * som.c (setup_sections): NUL terminate the space_strings buffer.
1035 Check that the space.name field does not index beyond the end of
1036 the space_strings buffer.
1037
6879f5a9
NC
10382017-06-21 Nick Clifton <nickc@redhat.com>
1039
1040 PR binutils/21646
1041 * coff-sh.c (sh_reloc): Check for an out of range reloc.
1042
7adc0a81
NC
10432017-06-21 Nick Clifton <nickc@redhat.com>
1044
1045 PR binutils/21639
1046 * vms-misc.c (_bfd_vms_save_sized_string): Use unsigned int as
1047 type of the size parameter.
1048 (_bfd_vms_save_counted_string): Add second parameter - the maximum
1049 length of the counted string.
1050 * vms.h (_bfd_vms_save_sized_string): Update prototype.
1051 (_bfd_vms_save_counted_string): Likewise.
1052 * vms-alpha.c (_bfd_vms_slurp_eisd): Update calls to
1053 _bfd_vms_save_counted_string.
1054 (_bfd_vms_slurp_ehdr): Likewise.
1055 (_bfd_vms_slurp_egsd): Likewise.
1056 (Parse_module): Likewise.
1057
6e1816be
AM
10582017-06-21 Alan Modra <amodra@gmail.com>
1059
1060 * elf64-ppc.c (ppc64_elf_size_stubs): Test for localentry:0 plt
1061 calls before tocsave calls.
1062 (ppc64_elf_relocate_section): Allow localentry:0 plt calls without
1063 following nop.
1064
20bd1b6b
NC
10652017-06-21 Nick Clifton <nickc@redhat.com>
1066
1067 PR binutils/21645
1068 * reloc.c (bfd_generic_get_relocated_section_contents): Fail if
1069 bfd_get_full_section_contents returns no contents.
1070
3de58d95
NC
10712017-06-21 Nick Clifton <nickc@redhat.com>
1072
1073 PR binutils/21638
1074 * vms-alpha.c (_bfd_vms_slurp_egsd): Check for an undersized
1075 record.
1076
cb06d03a
NC
10772017-06-21 Nick Clifton <nickc@redhat.com>
1078
1079 PR binutils/21637
1080 * vms-alpha.c (_bfd_vms_slurp_egsd): Check for an empty section
1081 list.
1082 (image_set_ptr): Likewise.
1083 (alpha_vms_fix_sec_rel): Likewise.
1084 (alpha_vms_slurp_relocs): Likewise.
1085
c458d007
NC
10862017-06-21 Nick Clifton <nickc@redhat.com>
1087
1088 PR binutils/21633
1089 * ieee.c (ieee_slurp_sections): Check for a NULL return from
1090 read_id.
1091 (ieee_archive_p): Likewise.
1092 (ieee_object_p): Likewise.
1093
ce497010
NC
10942017-06-21 Nick Clifton <nickc@redhat.com>
1095
1096 PR binutils/21640
1097 * elf.c (setup_group): Zero the group section pointer list after
1098 allocation so that loops can be caught. Check for NULL pointers
1099 when processing a group list.
1100
fd52715c
AK
11012017-06-20 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
1102
1103 * elf-s390.h: New file.
1104 * elf64-s390.c (struct elf_s390_link_hash_table): Add params
1105 field.
1106 (elf_s390_additional_program_headers): New function.
1107 (elf_s390_modify_segment_map): New function.
1108 (bfd_elf_s390_set_options): New function.
1109 (elf_backend_additional_program_headers)
1110 (elf_backend_modify_segment_map): Add macro definitions.
1111
abfa390d
L
11122017-06-19 H.J. Lu <hongjiu.lu@intel.com>
1113
1114 PR ld/21626
1115 * elf-properties.c (_bfd_elf_link_setup_gnu_properties): Check
1116 the DYNAMIC bit instead of bfd_count_sections.
1117
bc21b167
NC
11182017-06-19 Nick Clifton <nickc@redhat.com>
1119
1120 PR binutils/21618
1121 * vms-alpha.c (evax_bfd_print_emh): Check for insufficient record
1122 length.
1123 (evax_bfd_print_eeom): Likewise.
1124 (evax_bfd_print_egsd): Check for an overlarge record length.
1125 (evax_bfd_print_etir): Likewise.
1126
acb56a83
NC
11272017-06-19 Nick Clifton <nickc@redhat.com>
1128
1129 PR binutils/21612
1130 * libieee.h (struct common_header_type): Add end_p field.
1131 * ieee.c (this_byte_and_next): Do not advance input_p beyond
1132 end_p.
1133 (read_id): Check for a length that exceeds the remaining bytes in
1134 the input buffer.
1135 (ieee_seek): Initialise end_p.
1136 (ieee_archive_p): Likewise.
1137 (ieee_object_p): Likewise.
1138
72e84f96
NC
11392017-06-19 Nick Clifton <nickc@redhat.com>
1140
80053e46
NC
1141 PR binutils/21611
1142 * vms-alpha.c (_bfd_vms_slurp_eihs): Check for invalid offset
1143 before reading the EIHS structure entries.
1144
11452017-06-19 Nick Clifton <nickc@redhat.com>
1146
1147 PR binutils/21615
72e84f96
NC
1148 * vms-alpha.c (_bfd_vms_slurp_egsd): Use unsigned int for
1149 gsd_size. Check that there are enough bytes remaining to read the
1150 type and size of the next egsd. Check that the size of the egsd
1151 does not exceed the size of the record.
1152
875ffa3e
AM
11532017-06-19 Alan Modra <amodra@gmail.com>
1154
1155 * config.bfd: Correct targ_underscore for cris.
1156
bdd32e03
AM
11572017-06-18 Alan Modra <amodra@gmail.com>
1158
1159 * config.bfd: Correct targ_underscore for epiphany, ip2k,
1160 m32c, mn10200, pru, rl78, rx, crisv32 and v850.
1161
4b48e2f6
NC
11622017-06-16 Nick Clifton <nickc@redhat.com>
1163
1164 * elflink.c (bfd_elf_size_dynsym_hash_dynstr): Do not fail if the
1165 bucketlist is empty because there are no symbols to add to the
1166 list.
1167
7dba9362
AM
11682017-06-16 Alan Modra <amodra@gmail.com>
1169
1170 PR ld/20022
1171 PR ld/21557
1172 PR ld/21562
1173 PR ld/21571
1174 * targets.c (struct bfd_target): Add _bfd_define_start_stop.
1175 (BFD_JUMP_TABLE_LINK): Likewise.
1176 * elf-bfd.h (bfd_elf_define_start_stop): Declare.
1177 * elflink.c (_bfd_elf_gc_mark_rsec): Update comment.
1178 (bfd_elf_define_start_stop): New function.
1179 * linker.c (bfd_generic_define_start_stop): New function.
1180 * coff64-rs6000.c (rs6000_xcoff64_vec, rs6000_xcoff64_aix_vec): Init
1181 new field.
1182 * aout-adobe.c (aout_32_bfd_define_start_stop): Define.
1183 * aout-target.h (MY_bfd_define_start_stop): Define.
1184 * aout-tic30.c (MY_bfd_define_start_stop): Define.
1185 * binary.c (binary_bfd_define_start_stop): Define.
1186 * bout.c (b_out_bfd_define_start_stop): Define.
1187 * coff-alpha.c (_bfd_ecoff_bfd_define_start_stop): Define.
1188 * coff-mips.c (_bfd_ecoff_bfd_define_start_stop): Define.
1189 * coff-rs6000.c (_bfd_xcoff_bfd_define_start_stop): Define.
1190 * coffcode.h (coff_bfd_define_start_stop): Define.
1191 * elfxx-target.h (bfd_elfNN_bfd_define_start_stop): Define.
1192 * i386msdos.c (msdos_bfd_define_start_stop): Define.
1193 * i386os9k.c (os9k_bfd_define_start_stop): Define.
1194 * ieee.c (ieee_bfd_define_start_stop): Define.
1195 * ihex.c (ihex_bfd_define_start_stop): Define.
1196 * libbfd-in.h (_bfd_nolink_bfd_define_start_stop): Define.
1197 * mach-o-target.c (bfd_mach_o_bfd_define_start_stop): Define.
1198 * mmo.c (mmo_bfd_define_start_stop): Define.
1199 * nlm-target.h (nlm_bfd_define_start_stop): Define.
1200 * oasys.c (oasys_bfd_define_start_stop): Define.
1201 * pef.c (bfd_pef_bfd_define_start_stop): Define.
1202 * plugin.c (bfd_plugin_bfd_define_start_stop): Define.
1203 * ppcboot.c (ppcboot_bfd_define_start_stop): Define.
1204 * som.c (som_bfd_define_start_stop): Define.
1205 * srec.c (srec_bfd_define_start_stop): Define.
1206 * tekhex.c (tekhex_bfd_define_start_stop): Define.
1207 * versados.c (versados_bfd_define_start_stop): Define.
1208 * vms-alpha.c (vms_bfd_define_start_stop): Define.
1209 (alpha_vms_bfd_define_start_stop): Define.
1210 * xsym.c (bfd_sym_bfd_define_start_stop): Define.
1211 * bfd-in2.h: Regenerate.
1212 * libbfd.h: Regenerate.
1213
d68f1976
JW
12142017-06-16 Jiong Wang <jiong.wang@arm.com>
1215
1216 * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Use
1217 SYMBOL_REFERENCES_LOCAL.
1218
6353d82b
JW
12192017-06-15 Jiong Wang <jiong.wang@arm.com>
1220
1221 PR ld/21532
1222 * elfnn-aarch64.c (ELIMINATE_COPY_RELOCS): Set to 1.
1223 (elfNN_aarch64_final_link_relocate): Also propagate relocations to
1224 runtime for if there needs copy relocation elimination.
1225 (need_copy_relocation_p): New function. Return true for symbol with
1226 pc-relative references and if it's against read-only sections.
1227 (elfNN_aarch64_adjust_dynamic_symbol): Use need_copy_relocation_p.
1228 (elfNN_aarch64_check_relocs): Allocate dynrelocs for relocation types
1229 that are related with accessing external objects.
1230 (elfNN_aarch64_gc_sweep_hook): Sync the relocation types with the change
1231 in elfNN_aarch64_check_relocs.
1232
63634bb4
NC
12332017-06-15 Nick Clifton <nickc@redhat.com>
1234
1235 PR binutils/21582
1236 * ieee.c (ieee_object_p): Use a static buffer to avoid compiler
1237 bugs.
62b76e4b
NC
1238 PR binutils/21581
1239 (ieee_archive_p): Likewise.
63634bb4 1240
76800cba
NC
12412017-06-15 Nick Clifton <nickc@redhat.com>
1242
1243 PR binutils/21579
1244 * vms-alpha.c (_bfd_vms_slurp_etir): Extend check of cmd_length.
1245
f7e16c2a
MF
12462017-06-14 Max Filippov <jcmvbkbc@gmail.com>
1247
1248 * elf32-xtensa.c (elf_xtensa_be_plt_entry,
1249 elf_xtensa_le_plt_entry): Add dimension for the ABI to arrays,
1250 keep both windowed and call0 ABI PLT definitions.
1251 (elf_xtensa_create_plt_entry): Use selected ABI to choose upper
1252 elf_xtensa_*_plt_entry endex.
1253 (ELF_MAXPAGESIZE): Fix at minimal supported MMU page size.
1254
f461bbd8
NC
12552017-06-14 Nick Clifton <nickc@redhat.com>
1256
1257 PR binutils/21578
1258 * elf32-sh.c (sh_elf_set_mach_from_flags): Fix check for invalid
1259 flag value.
1260
c53d2e6d
NC
12612017-06-14 Nick Clifton <nickc@redhat.com>
1262
1263 PR binutils/21589
1264 * vms-alpha.c (_bfd_vms_get_value): Add an extra parameter - the
1265 maximum value for the ascic pointer. Check that name processing
1266 does not read beyond this value.
1267 (_bfd_vms_slurp_etir): Add checks for attempts to read beyond the
1268 end of etir record.
1269
04f963fd
NC
12702017-06-14 Nick Clifton <nickc@redhat.com>
1271
1272 PR binutils/21591
1273 * versados.c (versados_mkobject): Zero the allocated tdata structure.
1274 (process_otr): Check for an invalid offset in the otr structure.
1275
319c2dbe
SH
12762017-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
1277
1278 * config.bfd (epiphany-*-elf): Accept epiphany-*-*.
1279
cbd0eecf
L
12802017-06-13 H.J. Lu <hongjiu.lu@intel.com>
1281
1282 PR ld/20022
1283 PR ld/21557
1284 PR ld/21562
1285 PR ld/21571
1286 * elf-bfd.h (elf_link_hash_entry): Add start_stop. Change the
1287 vtable field to a union.
1288 (_bfd_elf_is_start_stop): Removed.
1289 * elf32-i386.c (elf_i386_convert_load_reloc): Also check for
1290 __start_SECNAME and __stop_SECNAME symbols.
1291 * elf64-x86-64.c (elf_x86_64_convert_load_reloc): Likewise.
1292 * elflink.c (_bfd_elf_is_start_stop): Removed.
1293 (_bfd_elf_gc_mark_rsec): Check start_stop instead of calling
1294 _bfd_elf_is_start_stop.
1295 (elf_gc_propagate_vtable_entries_used): Skip __start_SECNAME and
1296 __stop_SECNAME symbols. Updated.
1297 (elf_gc_smash_unused_vtentry_relocs): Likewise.
1298 (bfd_elf_gc_record_vtinherit): Likewise.
1299 (bfd_elf_gc_record_vtentry): Likewise.
1300
10bbbc1d
NC
13012017-06-13 Nick Clifton <nickc@redhat.com>
1302
1303 PR ld/21524
1304 * elflink.c (elf_link_adjust_relocs): Generate an error when
1305 encountering a reloc against a symbol removed by garbage
1306 collection.
1307
5c3ce2bc
L
13082017-06-12 H.J. Lu <hongjiu.lu@intel.com>
1309
1310 * elf-bfd.h (elf_backend_data): Add struct bfd_link_info *
1311 to merge_gnu_properties.
1312 * elf-properties.c (elf_merge_gnu_properties): Add struct
1313 bfd_link_info * and pass it to merge_gnu_properties.
1314 (elf_merge_gnu_property_list): Add struct bfd_link_info *
1315 and pass it to elf_merge_gnu_properties.
1316 (_bfd_elf_link_setup_gnu_properties): Pass info to
1317 elf_merge_gnu_property_list.
1318 * elf32-i386.c (elf_i386_merge_gnu_properties): Add struct
1319 bfd_link_info *.
1320 * elf64-x86-64.c (elf_x86_64_merge_gnu_properties): Likewise.
1321
9b97dfbf
AM
13222017-06-11 Joe Zbiciak <joe.zbiciak@leftturnonly.info>
1323
1324 PR 21564
1325 * binary.c (binary_set_section_contents): Scale lma by octets
1326 per byte to set filepos.
1327
e3d1d408
CM
13282017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1329
1330 * elf32-arc.c (elf_arc_check_relocs): Fixed conditions to generate
1331 dynamic sections.
1332
64aa8e03
CM
13332017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1334
1335 * elf32-arc.c (elf_arc_size_dynamic_sections): Changed condition to
1336 require TEXTREL.
1337
a0abe743
CM
13382017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1339
1340 * arc-got.h (relocate_fix_got_relocs_for_got_info): Added TCB_SIZE to
1341 patched section contents for TLS IE reloc.
1342 * elf32-arc.c: Remove TCB_SIZE preprocessor macro.
1343
f4e6805f
CM
13442017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1345
1346 * elf32-arc.c (elf_arc_relocate_section): Added "call" to
1347 RELOC_FOR_GLOBAL_SYMBOL macro.
1348
cd640291
CM
13492018-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1350
1351 * elf32-arc.c (elf_arc_relocate_section): Small refactor and condition
1352 changes.
1353
7ef0acc1
VG
13542017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1355
1356 * config/tc-arc.c (md_undefined_symbol): Changed.
1357 * config/tc-arc.h (DYNAMIC_STRUCT_NAME): Removed.
1358
cc89d0b3
CM
13592017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1360
1361 * elf32-arc.c (elf_arc_relocate_section): Fixed reassign of indirect
1362 symbols.
1363
9d5c718b
CM
13642017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1365
1366 * elf32-arc.c (elf_arc_check_relocs): Added condition to disable
1367 warning and "Bad value" for local symbols ARC_32 or ARC_32_ME relocs.
1368
be9e3704
CM
13692017-06-08 Cupertino Miranda <cmiranda@synopsys.com>
1370
1371 * elf32-arc.c (ADD_RELA): Changed to only work when dynamic
1372 object is created.
1373
4ec192e6
RE
13742017-06-08 Richard Earnshaw <rearnsha@arm.com>
1375
1376 * elf32-arm.c (elf32_arm_merge_eabi_attributes): Remove assertion
1377 that the input bfd has Tag_FP_ARCH non-zero if Tag_ABI_HardFP_use
1378 is non-zero. Add clarifying comments.
1379
51fa2693
L
13802017-06-08 H.J. Lu <hongjiu.lu@intel.com>
1381
1382 * elf32-i386.c (elf_i386_check_relocs): Set local IFUNC symbol
1383 name. Use local IFUNC symbol name string to report unsupported
1384 non-PIC call to IFUNC function.
1385 (elf_i386_relocate_section): Dump local IFUNC name with minfo
1386 when generating R_386_IRELATIVE relocation.
1387 (elf_i386_finish_dynamic_symbol): Likewise.
1388 * elf_x86_64_check_relocs (elf_x86_64_check_relocs): Set local
1389 IFUNC symbol name.
1390 (elf_x86_64_relocate_section): Dump local IFUNC name with minfo
1391 when generating R_X86_64_IRELATIVE relocation.
1392 (elf_x86_64_finish_dynamic_symbol): Likewise.
1393
78e8a2ff
JM
13942017-06-06 Jose E. Marchesi <jose.marchesi@oracle.com>
1395
1396 * elf.c (setup_group): Make sure BFD sections are created for all
1397 group sections in the input file when processing SHF_GROUP
1398 sections.
1399 (bfd_section_from_shdr): Avoid duplicating logic already
1400 implemented in `setup_group'.
1401
9949827b
DBR
14022017-06-06 Daniel Bonniot de Ruisselet <bonniot@gmail.com>
1403
1404 PR binutils/21546
1405 * peXXigen.c (pe_print_idata): Use the address of the first thunk
1406 if the hint address is zero.
1407
0ee3a6db
JC
14082017-06-06 James Clarke <jrtc27@jrtc27.com>
1409
1410 PR ld/19579
1411 * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol): Check
1412 ELF_COMMON_DEF_P for common symbols.
1413
7bdf4127
AB
14142017-06-06 Andrew Burgess <andrew.burgess@embecosm.com>
1415
1416 * elf.c (_bfd_elf_make_section_from_shdr): Don't initially mark
1417 SEC_GROUP sections as SEC_EXCLUDE.
1418 (bfd_elf_set_group_contents): Replace use of abort with an assert.
1419 (assign_section_numbers): Use resolve_section_groups flag instead
1420 of relocatable link type.
1421 (_bfd_elf_init_private_section_data): Use resolve_section_groups
1422 flag instead of checking the final_link flag for part of the
1423 checks in here. Fix white space as a result.
1424 * elflink.c (elf_link_input_bfd): Use resolve_section_groups flag
1425 instead of relocatable link type.
1426 (bfd_elf_final_link): Likewise.
1427
458ad2b8
JM
14282017-06-06 Jose E. Marchesi <jose.marchesi@oracle.com>
1429
1430 * elfxx-mips.c (_bfd_mips_elf_relocate_section): Remove unused
1431 variable `bed'.
1432 * elf32-score.c (score_elf_final_link_relocate): Likewise.
1433 (s3_bfd_score_elf_check_relocs): Likewise.
1434 * elf32-score7.c (s7_bfd_score_elf_relocate_section): Likewise.
1435 (score_elf_final_link_relocate): Likewise.
1436 (s7_bfd_score_elf_check_relocs): Likewise.
1437
fbebaf4a
JM
14382017-06-06 Jose E. Marchesi <jose.marchesi@oracle.com>
1439
1440 * elflink.c (init_reloc_cookie_rels): Remove unused variable
1441 `bed'.
1442
056bafd4
MR
14432017-06-06 Maciej W. Rozycki <macro@imgtec.com>
1444
1445 * elf-bfd.h (RELOC_AGAINST_DISCARDED_SECTION): Subtract `count'
1446 from `reloc_count' rather than decrementing it.
1447 * elf.c (bfd_section_from_shdr): Multiply the adjustment to
1448 `reloc_count' by `int_rels_per_ext_rel'.
1449 * elf32-score.c (score_elf_final_link_relocate): Do not multiply
1450 `reloc_count' by `int_rels_per_ext_rel' for last relocation
1451 entry determination.
1452 (s3_bfd_score_elf_check_relocs): Likewise.
1453 * elf32-score7.c (score_elf_final_link_relocate): Likewise.
1454 (s7_bfd_score_elf_relocate_section): Likewise.
1455 (s7_bfd_score_elf_check_relocs): Likewise.
1456 * elf64-mips.c (mips_elf64_get_reloc_upper_bound): Remove
1457 prototype and function.
1458 (mips_elf64_slurp_one_reloc_table): Do not update `reloc_count'.
1459 (mips_elf64_slurp_reloc_table): Assert that `reloc_count' is
1460 triple rather than once the sum of REL and RELA relocation entry
1461 counts.
1462 (bfd_elf64_get_reloc_upper_bound): Remove macro.
1463 * elflink.c (_bfd_elf_link_read_relocs): Do not multiply
1464 `reloc_count' by `int_rels_per_ext_rel' for internal relocation
1465 storage allocation size determination.
1466 (elf_link_input_bfd): Multiply `.ctors' and `.dtors' section's
1467 size by `int_rels_per_ext_rel'. Do not multiply `reloc_count'
1468 by `int_rels_per_ext_rel' for last relocation entry
1469 determination.
1470 (bfd_elf_final_link): Do not multiply `reloc_count' by
1471 `int_rels_per_ext_rel' for internal relocation storage
1472 allocation size determination.
1473 (init_reloc_cookie_rels): Do not multiply `reloc_count' by
1474 `int_rels_per_ext_rel' for last relocation entry determination.
1475 (elf_gc_smash_unused_vtentry_relocs): Likewise.
1476 * elfxx-mips.c (_bfd_mips_elf_check_relocs): Likewise.
1477 (_bfd_mips_elf_relocate_section): Likewise.
1478
af54f0eb
AM
14792017-06-05 Alan Modra <amodra@gmail.com>
1480
1481 PR 21529
1482 * linker.c (_bfd_generic_link_output_symbols): Handle BSF_GNU_UNIQUE.
1483
6cf3bf88 14842017-06-01 John Baldwin <jhb@FreeBSD.org>
b5430a3c
JB
1485
1486 * elf.c (elfcore_grok_freebsd_psinfo): Use ELF header class to
1487 determine structure sizes.
1488 (elfcore_grok_freebsd_prstatus): Likewise.
1489
f378ab09
AM
14902017-06-01 Alan Modra <amodra@gmail.com>
1491
1492 * elf64-ppc.c (struct ppc_link_hash_table): Add has_plt_localentry0.
1493 (ppc64_elf_merge_symbol_attribute): Merge localentry bits from
1494 dynamic objects.
1495 (is_elfv2_localentry0): New function.
1496 (ppc64_elf_tls_setup): Default params->plt_localentry0.
1497 (plt_stub_size): Adjust size for tls_get_addr_opt stub.
1498 (build_tls_get_addr_stub): Use a simpler stub when r2 is not saved.
1499 (ppc64_elf_size_stubs): Leave stub_type as ppc_stub_plt_call for
1500 optimized localentry:0 stubs.
1501 (ppc64_elf_build_stubs): Save r2 in ELFv2 __glink_PLTresolve.
1502 (ppc64_elf_relocate_section): Leave nop unchanged for optimized
1503 localentry:0 stubs.
1504 (ppc64_elf_finish_dynamic_sections): Set PPC64_OPT_LOCALENTRY in
1505 DT_PPC64_OPT.
1506 * elf64-ppc.h (struct ppc64_elf_params): Add plt_localentry0.
1507
8c65b54f
CS
15082017-05-30 Casey Smith <clegg89@gmail.com>
1509
1510 PR ld/21523
1511 * elf32-arm.c (elf32_arm_final_link_relocate): Install an absolute
1512 value when processing the R_ARM_THM_ALU_PREL_11_0 reloc.
1513
64984c22
AK
15142017-05-30 Anton Kolesov Anton.Kolesov@synopsys.com
1515
1516 * cpu-arc.c (arc_compatible): New function.
1517
37cd3877
AK
15182017-05-30 Anton Kolesov <anton.kolesov@synopsys.com>
1519
1520 * cpu-arc.c (arch_info_struct): Remove duplicate ARC600 entry.
1521
8e2f54bc
L
15222017-05-30 H.J. Lu <hongjiu.lu@intel.com>
1523
1524 PR binutils/21519
1525 * bfdio.c (bfd_get_file_size): New function.
1526 * bfd-in2.h: Regenerated.
1527
8e7f04f1 15282017-05-23 Dilian Palauzov <git-dpa@aegee.org>
1529
1530 * elf32-arc.c (arc_elf_merge_attributes): Add fall through
1531 comments.
1532
25f94347
L
15332017-05-22 H.J. Lu <hongjiu.lu@intel.com>
1534
1535 * elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Use
1536 dynobj instead of htab->elf.dynobj.
1537
e5713223
MR
15382017-05-19 Maciej W. Rozycki <macro@imgtec.com>
1539
1540 * elf64-mips.c (mips_elf64_canonicalize_reloc): Remove prototype
1541 and function.
1542 (mips_elf64_canonicalize_dynamic_reloc): Likewise.
1543 (mips_elf64_slurp_one_reloc_table): Set `reloc_count' to the
1544 actual number of internal relocations retrieved. Adjust
1545 function description.
1546 (bfd_elf64_canonicalize_reloc): Remove macro.
1547 (bfd_elf64_canonicalize_dynamic_reloc): Likewise.
1548
64517994
JM
15492017-05-19 Jose E. Marchesi <jose.marchesi@oracle.com>
1550
1551 * archures.c (bfd_mach_sparc_v9m8): Define.
1552 (bfd_mach_sparc_v8plusm8): Likewise.
1553 (bfd_mach_sparc_v9_p): Adjust to M8.
1554 (bfd_mach_sparc_64bit_p): Likewise.
1555 * aoutx.h (machine_type): Handle bfd_mach_sparc_v9m8 and
1556 bfd_mach_sparc_v8plusm8.
1557 * bfd-in2.h: Regenerated.
1558 * cpu-sparc.c (arch_info_struct): Entries for sparc:v9m8 and
1559 sparc:v8plusm8.
1560 * elfxx-sparc.c (_bfd_sparc_elf_object_p): Handle
1561 bfd_mach_sparc_v8plusm8 and bfd_mach_sparc_v9m8 using the new hw
1562 capabilities ONADDSUB, ONMUL, ONDIV, DICTUNP, FPCPSHL, RLE and
1563 SHA3.
1564 * elf32-sparc.c (elf32_sparc_final_write_processing): Handle
1565 bfd_mach_sparc_v8plusm8.
1566
eb026f09
AM
15672017-05-19 Alan Modra <amodra@gmail.com>
1568
1569 * elflink.c (_bfd_elf_gc_mark_extra_sections): Don't keep
1570 debug and special sections when no non-note alloc sections in an
1571 object are kept.
1572
535b785f
AM
15732017-05-18 Alan Modra <amodra@gmail.com>
1574
1575 * arc-got.h: Don't compare boolean values against TRUE or FALSE.
1576 * elf-m10300.c: Likewise.
1577 * elf.c: Likewise.
1578 * elf32-arc.c: Likewise.
1579 * elf32-bfin.c: Likewise.
1580 * elf32-m68k.c: Likewise.
1581 * elf32-nds32.c: Likewise.
1582 * elf32-tilepro.c: Likewise.
1583 * elflink.c: Likewise.
1584 * elfnn-aarch64.c: Likewise.
1585 * elfnn-riscv.c: Likewise.
1586 * elfxx-tilegx.c: Likewise.
1587 * mach-o.c: Likewise.
1588 * peXXigen.c: Likewise.
1589 * vms-alpha.c: Likewise.
1590 * vms-lib.c: Likewise.
1591
b7c871ed
L
15922017-05-17 H.J. Lu <hongjiu.lu@intel.com>
1593
1594 PR ld/20882
1595 * elflink.c (elf_gc_mark_debug_section): New function.
1596 (_bfd_elf_gc_mark_extra_sections): Mark any debug sections
1597 referenced by kept debug sections.
1598
bc4e12de
AM
15992017-05-16 Alan Modra <amodra@gmail.com>
1600
1601 * elf-m10300.c: Rename occurrences of non_ir_ref.
1602 * elf32-arm.c: Likewise.
1603 * elf32-bfin.c: Likewise.
1604 * elf32-cr16.c: Likewise.
1605 * elf32-cris.c: Likewise.
1606 * elf32-d10v.c: Likewise.
1607 * elf32-dlx.c: Likewise.
1608 * elf32-fr30.c: Likewise.
1609 * elf32-frv.c: Likewise.
1610 * elf32-hppa.c: Likewise.
1611 * elf32-i370.c: Likewise.
1612 * elf32-i386.c: Likewise.
1613 * elf32-iq2000.c: Likewise.
1614 * elf32-lm32.c: Likewise.
1615 * elf32-m32c.c: Likewise.
1616 * elf32-m32r.c: Likewise.
1617 * elf32-m68hc1x.c: Likewise.
1618 * elf32-m68k.c: Likewise.
1619 * elf32-mcore.c: Likewise.
1620 * elf32-metag.c: Likewise.
1621 * elf32-microblaze.c: Likewise.
1622 * elf32-moxie.c: Likewise.
1623 * elf32-msp430.c: Likewise.
1624 * elf32-mt.c: Likewise.
1625 * elf32-nios2.c: Likewise.
1626 * elf32-or1k.c: Likewise.
1627 * elf32-ppc.c: Likewise.
1628 * elf32-rl78.c: Likewise.
1629 * elf32-s390.c: Likewise.
1630 * elf32-score.c: Likewise.
1631 * elf32-score7.c: Likewise.
1632 * elf32-sh.c: Likewise.
1633 * elf32-tic6x.c: Likewise.
1634 * elf32-tilepro.c: Likewise.
1635 * elf32-v850.c: Likewise.
1636 * elf32-vax.c: Likewise.
1637 * elf32-xstormy16.c: Likewise.
1638 * elf32-xtensa.c: Likewise.
1639 * elf64-alpha.c: Likewise.
1640 * elf64-hppa.c: Likewise.
1641 * elf64-ia64-vms.c: Likewise.
1642 * elf64-mmix.c: Likewise.
1643 * elf64-ppc.c: Likewise.
1644 * elf64-s390.c: Likewise.
1645 * elf64-sh64.c: Likewise.
1646 * elf64-x86-64.c: Likewise.
1647 * elflink.c: Likewise.
1648 * elfnn-aarch64.c: Likewise.
1649 * elfnn-ia64.c: Likewise.
1650 * elfnn-riscv.c: Likewise.
1651 * elfxx-mips.c: Likewise.
1652 * elfxx-sparc.c: Likewise.
1653 * elfxx-tilegx.c: Likewise.
1654 * linker.c: Likewise.
1655
4070765b
AM
16562017-05-16 Alan Modra <amodra@gmail.com>
1657
1658 * elf64-ppc.c (add_symbol_adjust): Transfer non_ir_ref_dynamic.
1659 * elflink.c (elf_link_add_object_symbols): Update to use
1660 non_ir_ref_dynamic.
1661 (elf_link_input_bfd): Test non_ir_ref_dynamic in addition to
1662 non_ir_ref.
1663 * linker.c (_bfd_generic_link_add_one_symbol): Likewise.
1664
25499ac7
MR
16652017-05-15 Maciej W. Rozycki <macro@imgtec.com>
1666
1667 * elfxx-mips.c (print_mips_ases): Handle MIPS16e2 ASE.
1668
73caa85d
L
16692017-05-12 H.J. Lu <hongjiu.lu@intel.com>
1670
1671 * elf32-i386.c (elf_i386_parse_gnu_properties): Merge
1672 GNU_PROPERTY_X86_ISA_1_USED and GNU_PROPERTY_X86_ISA_1_NEEDED
1673 properties.
1674 * elf64-x86-64.c (elf_x86_64_parse_gnu_properties): Likewise.
1675
f2c29a16
L
16762017-05-11 H.J. Lu <hongjiu.lu@intel.com>
1677
1678 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Rename plt_bnd
1679 to plt_second.
1680 (elf_x86_64_link_hash_table): Rename plt_bnd/plt_bnd_eh_frame
1681 to plt_second/plt_second_eh_frame.
1682 (elf_x86_64_link_hash_newfunc): Updated.
1683 (elf_x86_64_allocate_dynrelocs): Likewise.
1684 (elf_x86_64_size_dynamic_sections): Likewise.
1685 (elf_x86_64_relocate_section): Likewise.
1686 (elf_x86_64_finish_dynamic_symbol): Likewise.
1687 (elf_x86_64_finish_dynamic_sections): Likewise.
1688 (elf_x86_64_plt_type): Rename plt_bnd to plt_second.
1689 (elf_x86_64_get_synthetic_symtab): Updated. Also scan the
1690 .plt.sec section.
1691 (elf_backend_setup_gnu_properties): Updated. Create the
1692 .plt.sec section instead of the .plt.sec section.
1693
dc2be3d2
L
16942017-05-11 H.J. Lu <hongjiu.lu@intel.com>
1695
1696 * elf32-i386.c (elf_i386_allocate_dynrelocs): Partially revert
1697 commit 25070364b0ce33eed46aa5d78ebebbec6accec7e.
1698 * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Likewse.
1699
db84b98a
JM
17002017-05-10 Jose E. Marchesi <jose.marchesi@oracle.com>
1701
1702 * elf64-sparc.c (elf64_sparc_set_reloc): New function.
1703 (bfd_elf64_set_reloc): Define.
1704 (elf64_sparc_write_relocs): Use `canon_reloc_count'.
1705
23186865
JM
17062017-05-10 Jose E. Marchesi <jose.marchesi@oracle.com>
1707
1708 * targets.c (BFD_JUMP_TABLE_RELOCS): Add NAME##_set_reloc.
1709 (struct bfd_target): New field _bfd_set_reloc.
1710 * bfd.c (bfd_set_reloc): Call backend _set_bfd.
1711 * reloc.c (_bfd_generic_set_reloc): New function.
1712 * coffcode.h (coff_set_reloc): Define to _bfd_generic_set_reloc.
1713 * nlm-target.h (nlm_set_reloc): Likewise.
1714 * coff-rs6000.c (_bfd_xcoff_set_reloc): Likewise.
1715 * aout-tic30.c (MY_set_reloc): Likewise.
1716 * aout-target.h (MY_set_reloc): Likewise.
1717 * elfxx-target.h (bfd_elfNN_set_reloc): Likewise.
1718 * coff-alpha.c (_bfd_ecoff_set_reloc): Likewise.
1719 * mach-o-target.c (bfd_mach_o_set_reloc): Likewise.
1720 * vms-alpha.c (alpha_vms_set_reloc): Likewise.
1721 * aout-adobe.c (aout_32_set_reloc): Likewise.
1722 * bout.c (b_out_set_reloc): Likewise.
1723 * coff-mips.c (_bfd_ecoff_set_reloc): Likewise.
1724 * i386os9k.c (aout_32_set_reloc): Likewise.
1725 * ieee.c (ieee_set_reloc): Likewise.
1726 * oasys.c (oasys_set_reloc): Likewise.
1727 * som.c (som_set_reloc): Likewise.
1728 * versados.c (versados_set_reloc): Likewise.
1729 * coff64-rs6000.c (rs6000_xcoff64_vec): Add
1730 _bfd_generic_set_reloc.
1731 (rs6000_xcoff64_aix_vec): LIkewise.
1732 * libbfd.c (_bfd_norelocs_set_reloc): New function.
1733 * libbfd-in.h: Prototype for _bfd_norelocs_set_reloc.
1734 * i386msdos.c (msdos_set_reloc): Define to
1735 _bfd_norelocs_set_reloc.
1736 * elfcode.h (elf_set_reloc): Define.
1737 * bfd-in2.h: Regenerated.
1738
aab82f4c
L
17392017-05-10 H.J. Lu <hongjiu.lu@intel.com>
1740
1741 PR ld/21481
1742 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Use .plt.bnd
1743 for IFUNC function address.
1744
53a346d8
CZ
17452017-05-10 Claudiu Zissulescu <claziss@synopsys.com>
1746
1747 * elf32-arc.c (FEATURE_LIST_NAME): Define.
1748 (CONFLICT_LIST): Likewise.
1749 (opcode/arc-attrs.h): Include.
1750 (arc_elf_print_private_bfd_data): Print OSABI v4 flag.
1751 (arc_extract_features): New file.
1752 (arc_stralloc): Likewise.
1753 (arc_elf_merge_attributes): Likewise.
1754 (arc_elf_merge_private_bfd_data): Use object attributes.
1755 (bfd_arc_get_mach_from_attributes): New function.
1756 (arc_elf_object_p): Use object attributes.
1757 (arc_elf_final_write_processing): Likewise.
1758 (elf32_arc_obj_attrs_arg_type): New function.
1759 (elf32_arc_obj_attrs_handle_unknown): Likewise.
1760 (elf32_arc_section_from_shdr): Likewise.
1761 (elf_backend_obj_attrs_vendor): Define.
1762 (elf_backend_obj_attrs_section): Likewise.
1763 (elf_backend_obj_attrs_arg_type): Likewise.
1764 (elf_backend_obj_attrs_section_type): Likewise.
1765 (elf_backend_obj_attrs_handle_unknown): Likewise.
1766 (elf_backend_section_from_shdr): Likewise.
1767
e645cf40
AG
17682017-05-09 Andrew Goedhart <Andrewgoedhart@simplepowersolutions.co.za>
1769
1770 PR ld/21458
1771 * elf32-arm.c (elf32_arm_final_link_relocate): Set the bottom bit
1772 of the value when resolving a R_ARM_THM_ALU_PREL_11_0 relocation
1773 and the destination is a Thumb symbol.
1774
dd9e66ee
L
17752017-05-08 H.J. Lu <hongjiu.lu@intel.com>
1776
1777 * elf32-i386.c (elf_i386_get_synthetic_symtab): Add missing
1778 initializer to silence GCC 4.2.
1779 * lf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.
1780
38b12349
L
17812017-05-08 H.J. Lu <hongjiu.lu@intel.com>
1782
1783 * elf64-x86-64.c (PLT_ENTRY_SIZE): Renamed to ...
1784 (LAZY_PLT_ENTRY_SIZE): This.
1785 (NON_LAZY_PLT_ENTRY_SIZE): New.
1786 (elf_x86_64_plt0_entry): Renamed to ...
1787 (elf_x86_64_lazy_plt0_entry): This.
1788 (elf_x86_64_plt_entry): Renamed to ...
1789 (elf_x86_64_lazy_plt_entry): This.
1790 (elf_x86_64_bnd_plt0_entry): Renamed to ...
1791 (elf_x86_64_lazy_bnd_plt0_entry): This.
1792 (elf_x86_64_legacy_plt_entry): Removed.
1793 (elf_x86_64_bnd_plt_entry): Renamed to ...
1794 (elf_x86_64_lazy_bnd_plt_entry): This.
1795 (elf_x86_64_legacy_plt2_entry): Renamed to ...
1796 (elf_x86_64_non_lazy_plt_entry): This.
1797 (elf_x86_64_bnd_plt2_entry): Renamed to ...
1798 (elf_x86_64_non_lazy_bnd_plt_entry): This.
1799 (elf_x86_64_eh_frame_plt): Renamed to ...
1800 (elf_x86_64_eh_frame_lazy_plt): This.
1801 (elf_x86_64_eh_frame_bnd_plt): Renamed to ...
1802 (elf_x86_64_eh_frame_lazy_bnd_plt): This.
1803 (elf_x86_64_eh_frame_plt_got): Renamed to ...
1804 (elf_x86_64_eh_frame_non_lazy_plt): This.
1805 (elf_x86_64_lazy_plt_layout): New.
1806 (elf_x86_64_non_lazy_plt_layout): Likewise.
1807 (elf_x86_64_plt_layout): Likewise.
1808 (elf_x86_64_backend_data): Remove PLT layout information. Add
1809 os for target system.
1810 (GET_PLT_ENTRY_SIZE): Removed.
1811 (elf_x86_64_lazy_plt): New.
1812 (elf_x86_64_non_lazy_plt): Likewise.
1813 (elf_x86_64_lazy_bnd_plt): Likewise.
1814 (elf_x86_64_non_lazy_bnd_plt): Likewise.
1815 (elf_x86-64_arch_bed): Updated.
1816 (elf_x86_64_link_hash_table): Add plt, lazy_plt and non_lazy_plt.
1817 (elf_x86_64_create_dynamic_sections): Removed.
1818 (elf_x86_64_check_relocs): Don't check elf.dynobj. Don't call
1819 _bfd_elf_create_ifunc_sections nor _bfd_elf_create_got_section.
1820 (elf_x86-64_adjust_dynamic_symbol): Updated.
1821 (elf_x86_64_allocate_dynrelocs): Updated. Pass 0 as PLT header
1822 size to _bfd_elf_allocate_ifunc_dyn_relocs and don't allocate
1823 size for PLT0 if there is no PLT0. Get plt_entry_size from
1824 non_lazy_plt for non-lazy PLT entries.
1825 (elf_x86_64_size_dynamic_sections): Updated. Get plt_entry_size
1826 from non_lazy_plt for non-lazy PLT entries.
1827 (elf_x86-64_relocate_section): Updated. Properly get PLT index
1828 if there is no PLT0.
1829 (elf_x86_64_finish_dynamic_symbol): Updated. Fill the first slot
1830 in the PLT entry with generic PLT layout. Fill the non-lazy PLT
1831 entries with non-lazy PLT layout. Don't fill the second and third
1832 slots in the PLT entry if there is no PLT0.
1833 (elf_x86_64_finish_dynamic_sections): Updated. Don't fill PLT0
1834 if there is no PLT0. Set sh_entsize on the .plt.got section.
1835 (compare_relocs): New.
1836 (elf_x86_64_plt_type): Likewise.
1837 (elf_x86_64_plt): Likewise.
1838 (elf_x86_64_nacl_plt): New. Forward declaration.
1839 (elf_x86_64_get_plt_sym_val): Removed.
1840 (elf_x86_64_get_synthetic_symtab): Rewrite to check PLT sections
1841 against all dynamic relocations.
1842 (elf_x86_64_link_setup_gnu_properties): New function.
1843 (elf_backend_create_dynamic_sections): Updated.
1844 (elf_backend_setup_gnu_properties): New.
1845 (elf_x86_64_nacl_plt): New.
1846 (elf_x86_64_nacl_arch_bed): Updated.
1847
f604c2a2
L
18482017-05-08 H.J. Lu <hongjiu.lu@intel.com>
1849
1850 * elf32-i386.c (PLT_ENTRY_SIZE): Renamed to ...
1851 (LAZY_PLT_ENTRY_SIZE): This.
1852 (NON_LAZY_PLT_ENTRY_SIZE): New.
1853 (elf_i386_plt0_entry): Renamed to ...
1854 (elf_i386_lazy_plt0_entry): This.
1855 (elf_i386_plt_entry): Renamed to ...
1856 (elf_i386_lazy_plt_entry): This.
1857 (elf_i386_pic_plt0_entry): Renamed to ...
1858 (elf_i386_pic_lazy_plt0_entry): This.
1859 (elf_i386_pic_plt_entry): Renamed to ...
1860 (elf_i386_pic_lazy_plt_entry): This.
1861 (elf_i386_got_plt_entry): Renamed to ...
1862 (elf_i386_non_lazy_plt_entry): This.
1863 (elf_i386_pic_got_plt_entry): Renamed to ...
1864 (elf_i386_pic_non_lazy_plt_entry): This.
1865 (elf_i386_eh_frame_plt): Renamed to ...
1866 (elf_i386_eh_frame_lazy_plt): This.
1867 (elf_i386_eh_frame_plt_got): Renamed to ...
1868 (elf_i386_eh_frame_non_lazy_plt): This.
1869 (elf_i386_plt_layout): Renamed to ...
1870 (elf_i386_lazy_plt_layout): This. Remove eh_frame_plt_got and
1871 eh_frame_plt_got_size.
1872 (elf_i386_non_lazy_plt_layout): New.
1873 (elf_i386_plt_layout): Likewise.
1874 (elf_i386_non_lazy_plt): Likewise.
1875 (GET_PLT_ENTRY_SIZE): Removed.
1876 (elf_i386_plt): Renamed to ...
1877 (elf_i386_lazy_plt): This.
1878 (elf_i386_backend_data): Remove plt. Rename is_vxworks to os.
1879 (elf_i386_arch_bed): Updated.
1880 (elf_i386_link_hash_table): Add plt, lazy_plt and non_lazy_plt.
1881 (elf_i386_create_dynamic_sections): Removed.
1882 (elf_i386_check_relocs): Don't check elf.dynobj. Don't call
1883 _bfd_elf_create_ifunc_sections nor _bfd_elf_create_got_section.
1884 (elf_i386_adjust_dynamic_symbol): Updated.
1885 (elf_i386_allocate_dynrelocs): Updated. Pass 0 as PLT header
1886 size to _bfd_elf_allocate_ifunc_dyn_relocs and don't allocate
1887 size for PLT0 if there is no PLT0.
1888 (elf_i386_size_dynamic_sections): Updated. Check whether GOT
1889 output section is discarded only if GOT isn't empty.
1890 (elf_i386_relocate_section): Updated. Properly get PLT index
1891 if there is no PLT0.
1892 (elf_i386_finish_dynamic_symbol): Updated. Don't fill the
1893 second and third slots in the PLT entry if there is no PLT0.
1894 (elf_i386_finish_dynamic_sections): Updated. Don't fill PLT0
1895 if there is no PLT0. Set sh_entsize on the .plt.got section.
1896 (elf_i386_nacl_plt): Forward declaration.
1897 (elf_i386_get_plt_sym_val): Removed.
1898 (elf_i386_get_synthetic_symtab): Rewrite to check PLT sections
1899 against all dynamic relocations.
1900 (elf_i386_link_setup_gnu_properties): New function.
1901 (elf_backend_create_dynamic_sections): Updated.
1902 (elf_backend_setup_gnu_properties): New.
1903 (elf_i386_nacl_plt): Updated.
1904 (elf_i386_nacl_arch_bed): Likewise.
1905 (elf_i386_vxworks_arch_bed): Likewise.
1906
046734ff
TP
19072017-05-08 Thomas Preud'homme <thomas.preudhomme@arm.com>
1908
1909 * elflink.c (elf_output_implib): Remove executable flag from import
1910 library bfd.
1911 * elf32-arm.c (elf32_arm_filter_implib_symbols): Assert that the import
1912 library is a relocatable object file.
1913
b660e9eb
SKS
19142017-05-01 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
1915
1916 PR ld/21404
1917 * elf32-avr.c (avr_should_move_sym): New function.
1918 (avr_should_reduce_sym_size): Likewise.
1919 (avr_should_increase_sym_size): Likewise.
1920 (elf32_avr_relax_delete_bytes): Adjust symbol values
1921 and sizes by calling new functions.
1922
763a5fa4
PD
19232017-05-01 Palmer Dabbelt <palmer@dabbelt.com>
1924
1925 * config.bfd (riscv32-*): Enable rv64.
1926
73ec947d
AM
19272017-05-02 Alan Modra <amodra@gmail.com>
1928
1929 PR 21384
1930 * elflink.c (bfd_elf_link_mark_dynamic_symbol): Test h->non_elf
1931 rather than h->root.type == bfd_link_hash_new.
1932 (bfd_elf_record_link_assignment): Similarly, call
1933 bfd_elf_link_mark_dynamic_symbol when h->non_elf.
1934
a941291c
AM
19352017-04-29 Alan Modra <amodra@gmail.com>
1936
1937 PR 21432
1938 * reloc.c (reloc_offset_in_range): New function.
1939 (bfd_perform_relocation, bfd_install_relocation): Use it.
1940 (_bfd_final_link_relocate): Likewise.
1941
750eaa47
L
19422017-04-28 H.J. Lu <hongjiu.lu@intel.com>
1943
1944 * elf32-i386.c (elf_i386_allocate_dynrelocs): Check plt_got
1945 before using .plt.got.
1946 * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Likewise.
1947
5b66fac4
L
19482017-04-27 H.J. Lu <hongjiu.lu@intel.com>
1949
1950 * elf64-x86-64.c (elf_x86_64_size_dynamic_sections): Use "="
1951 instead of "+=" to update 0.
1952
de9a3c42
L
19532017-04-27 H.J. Lu <hongjiu.lu@intel.com>
1954
1955 * elf32-i386.c (elf_i386_create_dynamic_sections): Create the
1956 .plt.got section here.
1957 (elf_i386_check_relocs): Don't create the .plt.got section.
1958 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Create
1959 the .plt.got and .plt.bnd sections here.
1960 (elf_x86_64_check_relocs): Don't create the .plt.got nor
1961 .plt.bnd sections.
1962
da3d25af
L
19632017-04-27 H.J. Lu <hongjiu.lu@intel.com>
1964
1965 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Remove
1966 has_bnd_reloc.
1967 (elf_x86_64_link_hash_newfunc): Don't clear has_bnd_reloc.
1968 (elf_x86_64_copy_indirect_symbol): Don't copy has_bnd_reloc.
1969 (elf_x86_64_check_relocs): Don't set has_bnd_reloc.
1970 (elf_x86_64_finish_dynamic_symbol): Check bndplt instead of
1971 has_bnd_reloc.
1972
fba37edd
L
19732017-04-27 H.J. Lu <hongjiu.lu@intel.com>
1974
1975 * elf-bfd.h (elf_backend_data): Change setup_gnu_properties
1976 to return bfd *.
1977 (_bfd_elf_link_setup_gnu_properties): Return bfd *.
1978 * elf-properties.c (_bfd_elf_link_setup_gnu_properties): Return
1979 the first relocatable ELF input with GNU properties.
1980
1f78f649
L
19812017-04-27 H.J. Lu <hongjiu.lu@intel.com>
1982
1983 * elf32-i386.c (elf_i386_finish_dynamic_sections): Simplify
1984 VxWorks for non-PIC.
1985
76c20d54
AM
19862017-04-27 Alan Modra <amodra@gmail.com>
1987
1988 * elf-bfd.h (struct elf_backend_data): Make asection param of
1989 elf_backend_eh_frame_address_size const.
1990 (_bfd_elf_eh_frame_address_size): Likewise.
1991 * elf32-m32c.c (_bfd_m32c_elf_eh_frame_address_size): Likewise.
1992 * elf32-msp430.c (elf32_msp430_eh_frame_address_size): Likewise.
1993 * elfxx-mips.c (_bfd_mips_elf_eh_frame_address_size): Likewise.
1994 * elfxx-mips.h (_bfd_mips_elf_eh_frame_address_size): Likewise.
1995 * elf-eh-frame.c (_bfd_elf_eh_frame_address_size): Likewise.
1996 (next_cie_fde_offset): Constify params.
1997 (offset_adjust, adjust_eh_frame_local_symbols): Likewise.
1998
d7153c4a
AM
19992017-04-27 Alan Modra <amodra@gmail.com>
2000
2001 * elf-bfd.h (struct eh_cie_fde): Add aug_str_len and aug_data_len.
2002 (_bfd_elf_adjust_eh_frame_global_symbol): Declare.
2003 * elf-eh-frame.c (_bfd_elf_parse_eh_frame): Set aug_str_len and
2004 aug_data_len.
2005 (offset_adjust): New function.
2006 (_bfd_elf_adjust_eh_frame_global_symbol): Likewise.
2007 (adjust_eh_frame_local_symbols): Likewise.
2008 (_bfd_elf_discard_section_eh_frame): Call adjust_eh_frame_local_symbols
2009 after changing anything. Return true if anything changed.
2010 * elflink.c (bfd_elf_discard_info): If .eh_frame changed, call
2011 _bfd_elf_adjust_eh_frame_global_symbol for globals.
2012
641338d8
AM
20132017-04-27 Alan Modra <amodra@gmail.com>
2014
2015 * elflink.c (_bfd_elf_link_hash_hide_symbol): Clear dynstr_index
2016 when force_local.
2017
21d68fcd
AM
20182017-04-27 Alan Modra <amodra@gmail.com>
2019
2020 * elf32-ppc.c (UNDEFWEAK_NO_DYNAMIC_RELOC): Define.
2021 (ppc_elf_select_plt_layout, ppc_elf_tls_setup): Use it.
2022 (ppc_elf_adjust_dynamic_symbol, allocate_dynrelocs): Likewise.
2023 (ppc_elf_relocate_section): Likewise. Delete silly optimisation
2024 for undef and undefweak dyn_relocs.
2025 * elf64-ppc.c (UNDEFWEAK_NO_DYNAMIC_RELOC): Define.
2026 (ppc64_elf_adjust_dynamic_symbol, ppc64_elf_tls_setup): Use it.
2027 (allocate_got, allocate_dynrelocs): Likewise.
2028 (ppc64_elf_relocate_section): Likewise.
2029
97d343d4
L
20302017-04-26 H.J. Lu <hongjiu.lu@intel.com>
2031
2032 * elf32-i386.c (elf_i386_size_dynamic_sections): Alwasys add
2033 DT_PLTRELSZ, DT_PLTREL and DT_JMPREL for .rel.plt section.
2034 * elf64-x86-64.c (elf_x86_64_size_dynamic_sections): Alwasys
2035 add DT_PLTRELSZ, DT_PLTREL and DT_JMPREL for .rela.plt section.
2036
04b31182
NC
20372017-04-26 Nick Clifton <nickc@redhat.com>
2038
2039 PR binutils/21434
2040 * reloc.c (bfd_perform_relocation): Check for a negative address
2041 in the reloc.
2042
23ec1e32
MR
20432017-04-26 Maciej W. Rozycki <macro@imgtec.com>
2044
2045 PR ld/21334
2046 * elf-bfd.h (elf_backend_data): Add `always_renumber_dynsyms'
2047 member.
2048 * elfxx-target.h [!elf_backend_always_renumber_dynsyms]
2049 (elf_backend_always_renumber_dynsyms): Define.
2050 (elfNN_bed): Initialize `always_renumber_dynsyms' member.
2051 * elfxx-mips.h (elf_backend_always_renumber_dynsyms): Define.
2052 * elflink.c (bfd_elf_size_dynamic_sections): Also call
2053 `_bfd_elf_link_renumber_dynsyms' if the backend has requested
2054 it.
2055 (bfd_elf_size_dynsym_hash_dynstr): Likewise.
2056
c46cec3a
MR
20572017-04-26 Maciej W. Rozycki <macro@imgtec.com>
2058
2059 * elflink.c (bfd_elf_size_dynamic_sections): Only call
2060 `_bfd_elf_link_renumber_dynsyms' after section GC if dynamic
2061 sections have been created.
2062
e63d1232
NC
20632017-04-26 Nick Clifton <nickc@redhat.com>
2064
2065 PR binutils/21431
2066 * compress.c (bfd_init_section_compress_status): Check the return
2067 value from bfd_malloc.
2068
9e9821dd
L
20692017-04-24 H.J. Lu <hongjiu.lu@intel.com>
2070
2071 * elf64-x86-64.c (elf_x86_64_link_hash_entry): Add
2072 no_finish_dynamic_symbol.
2073 (elf_x86_64_link_hash_newfunc): Set no_finish_dynamic_symbol to
2074 0.
2075 (elf_x86_64_allocate_dynrelocs): If a symbol isn't undefined
2076 weak symbol, don't make it dynamic.
2077 (elf_x86_64_relocate_section): If a symbol isn't dynamic in PIC,
2078 set no_finish_dynamic_symbol and generate R_X86_64_RELATIVE
2079 relocation for GOT reference.
2080 (elf_x86_64_finish_dynamic_symbol): Abort if
2081 no_finish_dynamic_symbol isn't 0.
2082
0dc9a308
L
20832017-04-24 H.J. Lu <hongjiu.lu@intel.com>
2084
2085 PR ld/21402
2086 * elf32-i386.c (elf_i386_allocate_dynrelocs): If a symbol isn't
2087 undefined weak symbol, don't make it dynamic.
2088 (elf_i386_relocate_section): If a symbol isn't dynamic in PIC,
2089 set no_finish_dynamic_symbol and generate R_386_RELATIVE
2090 relocation for R_386_GOT32.
2091
1587442d
L
20922017-04-24 H.J. Lu <hongjiu.lu@intel.com>
2093
2094 PR ld/21425
2095 * elf32-i386.c (ELF_MAXPAGESIZE): Set to 0x1000 for VxWorks.
2096
7eacd66b
AM
20972017-04-23 Alan Modra <amodra@gmail.com>
2098
2099 PR 21414
2100 * section.c (GLOBAL_SYM_INIT): Make available in bfd.h.
2101 * elf.c (lcomm_sym): New.
2102 (_bfd_elf_large_com_section): Use lcomm_sym section symbol.
2103 * bfd-in2.h: Regenerate.
2104
bce964aa
AM
21052017-04-23 Alan Modra <amodra@gmail.com>
2106
2107 PR 21412
2108 * elf-bfd.h (struct elf_backend_data <get_reloc_section>): Change
2109 parameters and comment.
2110 (_bfd_elf_get_reloc_section): Delete.
2111 (_bfd_elf_plt_get_reloc_section): Declare.
2112 * elf.c (_bfd_elf_plt_get_reloc_section, elf_get_reloc_section):
2113 New functions. Don't blindly skip over assumed .rel/.rela prefix.
2114 Extracted from..
2115 (_bfd_elf_get_reloc_section): ..here. Delete.
2116 (assign_section_numbers): Call elf_get_reloc_section.
2117 * elf64-ppc.c (elf_backend_get_reloc_section): Define.
2118 * elfxx-target.h (elf_backend_get_reloc_section): Update.
2119
97e83a10
AM
21202017-04-23 Alan Modra <amodra@gmail.com>
2121
2122 PR 21409
2123 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Don't segfault when
2124 no symbols.
2125
e133d005
L
21262017-04-21 H.J. Lu <hongjiu.lu@intel.com>
2127
2128 PR ld/21402
2129 * elf32-i386.c (elf_i386_link_hash_entry): Add
2130 no_finish_dynamic_symbol.
2131 (elf_i386_link_hash_newfunc): Set no_finish_dynamic_symbol to 0.
2132 (elf_i386_allocate_dynrelocs): If a symbol isn't undefined weak
2133 symbol, don't make it dynamic in PIE.
2134 (elf_i386_relocate_section): If a symbol isn't dynamic in PIE,
2135 set no_finish_dynamic_symbol and generate R_386_RELATIVE
2136 relocation for R_386_GOT32
2137 (elf_i386_finish_dynamic_symbol): Abort if no_finish_dynamic_symbol
2138 isn't 0.
2139
3c5fce9b
L
21402017-04-21 H.J. Lu <hongjiu.lu@intel.com>
2141
2142 PR ld/19617
2143 PR ld/21086
2144 * elflink.c (elf_link_add_object_symbols): Require
2145 --no-dynamic-linker with -E/--dynamic-list when creating
2146 dynamic sections.
2147
0fad2956
MR
21482017-04-20 Maciej W. Rozycki <macro@imgtec.com>
2149
2150 * elflink.c (_bfd_elf_symbol_refs_local_p): Always return TRUE
2151 if forced local.
2152
64575f78
MR
21532017-04-20 Maciej W. Rozycki <macro@imgtec.com>
2154
2155 * elfxx-mips.c (_bfd_mips_elf_final_link): Reorder comment about
2156 dynamic symbol sorting.
2157
59fa66c5
L
21582017-04-20 H.J. Lu <hongjiu.lu@intel.com>
2159
2160 PR ld/21382
2161 * elflink.c (elf_link_add_object_symbols): Preserve
2162 dynamic_ref_after_ir_def when restoring the symbol table for
2163 unneeded dynamic object.
2164
e492d2f8
L
21652017-04-19 H.J. Lu <hongjiu.lu@intel.com>
2166
2167 PR ld/21401
2168 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Don't abort
2169 on on undefined IFUNC symbol in the second PLT.
2170
10169134
WAF
21712017-04-19 Wedson Almeida Filho <wedsonaf@gmail.com>
2172
2173 * peXXigen.c (pe_print_reloc): Correct chunk_end.
2174
954b63d4
AM
21752017-04-19 Alan Modra <amodra@gmail.com>
2176
2177 * elflink.c (_bfd_elf_adjust_dynamic_symbol): Hide undefweak
2178 or make dynamic for info->dynamic_undefined_weak 0 and 1.
2179 * elf32-ppc.c:Formatting.
2180 (ensure_undefweak_dynamic): Don't make dynamic when
2181 info->dynamic_undefined_weak is zero.
2182 (allocate_dynrelocs): Discard undefweak dyn_relocs for
2183 info->dynamic_undefined_weak. Discard undef dyn_relocs when
2184 not default visibility. Discard undef and undefweak
2185 dyn_relocs earlier.
2186 (ppc_elf_relocate_section): Adjust to suit.
2187 * elf64-ppc.c: Formatting.
2188 (ensure_undefweak_dynamic): Don't make dynamic when
2189 info->dynamic_undefined_weak is zero.
2190 (allocate_dynrelocs): Discard undefweak dyn_relocs for
2191 info->dynamic_undefined_weak. Discard them earlier.
2192
e6699019
L
21932017-04-17 H.J. Lu <hongjiu.lu@intel.com>
2194
2195 PR ld/21389
2196 * elflink.c (bfd_elf_size_dynamic_sections): Get soname index
2197 before generating the version definition section.
2198
c5d37467
AM
21992017-04-17 Alan Modra <amodra@gmail.com>
2200
2201 * elflink.c (_bfd_elf_merge_symbol): Undo dynamic linking
2202 state when a regular object file defines a symbol with
2203 incompatible type to that defined by an earlier shared lib.
2204
63a5468a
AM
22052017-04-13 Alan Modra <amodra@gmail.com>
2206
2207 * coffcode.h: Wrap some overly long _bfd_error_handler args.
2208 * elf.c: Likewise.
2209 * elf32-arm.c: Likewise.
2210 * elf32-i386.c: Likewise.
2211 * elf32-mep.c: Likewise.
2212 * elf64-ia64-vms.c: Likewise.
2213 * elf64-x86-64.c: Likewise.
2214 * elflink.c: Likewise.
2215 * elfnn-ia64.c: Likewise.
2216 * elfxx-mips.c: Likewise.
2217
dae82561
AM
22182017-04-13 Alan Modra <amodra@gmail.com>
2219
2220 * aoutx.h: Use %B and %A in error messages throughout file.
2221 * aout-cris.c: Likewise.
2222 * archive.c: Likewise.
2223 * binary.c: Likewise.
2224 * coff-rs6000.c: Likewise.
2225 * coff-tic4x.c: Likewise.
2226 * coffcode.h: Likewise.
2227 * coffgen.c: Likewise.
2228 * cofflink.c: Likewise.
2229 * coffswap.h: Likewise.
2230 * cpu-arm.c: Likewise.
2231 * elf-eh-frame.c: Likewise.
2232 * elf-m10300.c: Likewise.
2233 * elf.c: Likewise.
2234 * elf32-arc.c: Likewise.
2235 * elf32-arm.c: Likewise.
2236 * elf32-bfin.c: Likewise.
2237 * elf32-frv.c: Likewise.
2238 * elf32-iq2000.c: Likewise.
2239 * elf32-m32c.c: Likewise.
2240 * elf32-microblaze.c: Likewise.
2241 * elf32-nds32.c: Likewise.
2242 * elf32-rl78.c: Likewise.
2243 * elf32-rx.c: Likewise.
2244 * elf32-score.c: Likewise.
2245 * elf32-score7.c: Likewise.
2246 * elf32-sh64.c: Likewise.
2247 * elf32-v850.c: Likewise.
2248 * elf32-vax.c: Likewise.
2249 * elf32-visium.c: Likewise.
2250 * elf64-ia64-vms.c: Likewise.
2251 * elf64-mmix.c: Likewise.
2252 * elf64-sh64.c: Likewise.
2253 * elfcode.h: Likewise.
2254 * elfnn-aarch64.c: Likewise.
2255 * elfnn-ia64.c: Likewise.
2256 * elfxx-mips.c: Likewise.
2257 * hpux-core.c: Likewise.
2258 * ieee.c: Likewise.
2259 * ihex.c: Likewise.
2260 * linker.c: Likewise.
2261 * merge.c: Likewise.
2262 * mmo.c: Likewise.
2263 * oasys.c: Likewise.
2264 * pdp11.c: Likewise.
2265 * peXXigen.c: Likewise.
2266 * rs6000-core.c: Likewise.
2267 * vms-alpha.c: Likewise.
2268 * xcofflink.c: Likewise.
2269
c08bb8dd
AM
22702017-04-13 Alan Modra <amodra@gmail.com>
2271
2272 * bfd.c (PRINT_TYPE): Define.
2273 (_doprnt): New function.
2274 (error_handler_internal): Use _doprnt.
2275 * coff-arm.c: Put %A and %B arguments to _bfd_error_handler
2276 calls in their natural order, throughout file.
2277 * coff-mcore.c: Likewise.
2278 * coff-ppc.c: Likewise.
2279 * coff-tic80.c: Likewise.
2280 * cofflink.c: Likewise.
2281 * elf-s390-common.c: Likewise.
2282 * elf.c: Likewise.
2283 * elf32-arm.c: Likewise.
2284 * elf32-i386.c: Likewise.
2285 * elf32-m32r.c: Likewise.
2286 * elf32-msp430.c: Likewise.
2287 * elf32-spu.c: Likewise.
2288 * elf64-ia64-vms.c: Likewise.
2289 * elf64-sparc.c: Likewise.
2290 * elf64-x86-64.c: Likewise.
2291 * elflink.c: Likewise.
2292 * elfnn-aarch64.c: Likewise.
2293 * elfnn-ia64.c: Likewise.
2294 * elfxx-mips.c: Likewise.
2295
10463f39
AM
22962017-04-13 Alan Modra <amodra@gmail.com>
2297
2298 * elf32-arm.c (arm_type_of_stub): Supply missing args to "long
2299 branch veneers" error. Fix double space and format message.
2300 * elf32-avr.c (avr_add_stub): Do not pass NULL as %B arg.
2301 * elf64-ppc.c (tocsave_find): Supply missing %B arg.
2302
4af8774e
AM
23032017-04-13 Alan Modra <amodra@gmail.com>
2304
2305 * bfd-in2.h: Regenerate.
2306
e4097f5e
L
23072017-04-11 H.J. Lu <hongjiu.lu@intel.com>
2308
2309 * elf-properties.c (_bfd_elf_parse_gnu_properties): Remove the
2310 extra `\n' in warning/error messages.
2311 * elf32-i386.c (elf_i386_parse_gnu_properties): Likewise.
2312 * elf64-x86-64.c (elf_x86_64_parse_gnu_properties): Likewise.
2313
537616aa
L
23142017-04-11 H.J. Lu <hongjiu.lu@intel.com>
2315
2316 * elf-properties.c (_bfd_elf_parse_gnu_properties): Ignore
2317 processor-specific properties with generic ELF target vector.
2318
bb1dd176
QZ
23192017-04-10 Qing Zhao <qing.zhao@oracle.com>
2320
2321 * elf32-sparc.c (elf_backend_fixup_symbol): New.
2322 * elf64-sparc.c (elf_backend_fixup_symbol): New.
2323 * elfxx-sparc.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): New.
2324 (_bfd_sparc_elf_link_hash_entry): Add has_got_reloc and
2325 has_non_got_reloc.
2326 (link_hash_newfunc): Initialize has_got_reloc and
2327 has_non_got_reloc.
2328 (_bfd_sparc_elf_size_dynamic_sections): Set interp to .interp
2329 section.
2330 (_bfd_sparc_elf_copy_indirect_symbol): Copy has_got_reloc and
2331 has_non_got_reloc.
2332 (_bfd_sparc_elf_check_relocs): Set has_got_reloc and
2333 has_non_got_reloc.
2334 (_bfd_sparc_elf_fixup_symbol): New function.
2335 (allocate_dynrelocs): Don't allocate space for dynamic
2336 relocations and discard relocations against resolved undefined
2337 weak symbols in executable. Don't make resolved undefined weak
2338 symbols in executable dynamic. Keep dynamic non-GOT/non-PLT
2339 relocation against undefined weak symbols in PIE.
2340 (_bfd_sparc_elf_relocate_section): Don't generate dynamic
2341 relocations against resolved undefined weak symbols in PIE
2342 (_bfd_sparc_elf_finish_dynamic_symbol): Keep PLT/GOT entries
2343 without ynamic PLT/GOT relocations for resolved undefined weak
2344 symbols.
2345 Don't generate dynamic relocation against resolved undefined
2346 weak symbol in executable.
2347 (pie_finish_undefweak_symbol): New function.
2348 (_bfd_sparc_elf_finish_dynamic_sections): Call
2349 pie_finish_undefweak_symbol on all symbols in PIE.
2350 * elfxx-sparc.h (_bfd_sparc_elf_link_hash_table): Add interp.
2351 (_bfd_sparc_elf_fixup_symbol): New function.
2352
d236cfd4
NC
23532017-04-10 Nick Clifton <nickc@redhat.com>
2354
2355 * config.bfd: Remove ns32k from obsolete list.
2356
6f9dbcd4
AM
23572017-04-10 Alan Modra <amodra@gmail.com>
2358
2359 PR 21287
2360 * elf.c (special_sections_f): Match .fini_array and .fini_array.*.
2361 (special_sections_i): Likewise for .init_array.
2362 (special_sections_p): Likewise for .preinit_array.
2363
8170f769
L
23642017-04-07 H.J. Lu <hongjiu.lu@intel.com>
2365
2366 PR ld/19579
2367 PR ld/21306
2368 * elf32-s390.c (elf_s390_finish_dynamic_symbol): Check
2369 ELF_COMMON_DEF_P for common symbols.
2370 * elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
2371 * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
2372 * elflink.c (_bfd_elf_merge_symbol): Revert commits
2373 202ac193bbbecc96a4978d1ac3d17148253f9b01 and
2374 07492f668d2173da7a2bda3707ff0985e0f460b6.
2375
49f4617b
PA
23762017-04-07 Pedro Alves <palves@redhat.com>
2377
2378 * opncls.c (bfd_get_debug_link_info): Rename to...
2379 (bfd_get_debug_link_info_1): ... this. Change type of second
2380 parameter to void pointer. Adjust.
2381 (bfd_get_debug_link_info): Reimplement on top of
2382 bfd_get_debug_link_info_1.
2383 (separate_debug_file_exists, separate_alt_debug_file_exists):
2384 Change type of second parameter to void pointer. Adjust.
2385 (get_func_type, check_func_type): Change type of second parameter
2386 to void pointer.
2387 (find_separate_debug_file): Add 'func_data' parameter. Pass it to
2388 the callback functions instead of passing the address of a local.
2389 (bfd_follow_gnu_debuglink): Pass address of unsigned long local to
2390 find_separate_debug_file.
2391 (get_alt_debug_link_info_shim): Change type of second parameter to
2392 void pointer. Adjust.
2393 (bfd_follow_gnu_debugaltlink): Adjust to pass NULL to
2394 find_separate_debug_file.
2395 (get_build_id_name, bfd_boolean check_build_id_file): Change type
2396 of second parameter to void pointer. Adjust.
2397 (bfd_follow_build_id_debuglink): Pass address of bfd_build_id
2398 pointer local to find_separate_debug_file.
2399
24002017-04-07 Tristan Gingold <gingold@gingold-Precision-7510>
1fd6d111
TG
2401
2402 * coffgen.c (_bfd_coff_gc_mark_hook): Handle PE weak
2403 external symbols with a definition.
2404 (_bfd_coff_gc_mark_extra_sections): Fix typo.
2405
86abf93a
AM
24062017-04-07 Alan Modra <amodra@gmail.com>
2407
2408 * po/SRC-POTFILES.in: Regenerate.
2409
8dea77f0
AM
24102017-04-05 Alan Modra <amodra@gmail.com>
2411
2412 * elf64-ppc.c (ppc64_elf_gc_sweep_hook): Support ELFv2 PLT
2413 reference counting.
2414
477bdd39
JT
24152017-04-02 Jon Turney <jon.turney@dronecode.org.uk>
2416
2417 (_bfd_XXi_swap_aouthdr_out): For clarity, use defines rather than
2418 numbers for DataDirectory entry indicies passed to
2419 add_data_entry().
2420
a91e1603
L
24212017-04-04 H.J. Lu <hongjiu.lu@intel.com>
2422
2423 * elf.c (get_program_header_size): Add a GNU_MBIND segment for
2424 each GNU_MBIND section and align GNU_MBIND section to page size.
2425 (_bfd_elf_map_sections_to_segments): Create a GNU_MBIND
2426 segment for each GNU_MBIND section.
2427 (_bfd_elf_init_private_section_data): Copy sh_info from input
2428 for GNU_MBIND section.
2429
b5292032
PD
24302017-04-03 Palmer Dabbelt <palmer@dabbelt.com>
2431
2432 * elfnn-riscv.c (GP_NAME): Delete.
2433 (riscv_global_pointer_value): Change GP_NAME to RISCV_GP_SYMBOL.
2434 (_bfd_riscv_relax_lui): Likewise.
2435
ad32986f
NC
24362017-04-04 Nick Clifton <nickc@redhat.com>
2437
2438 PR binutils/21342
2439 * elflink.c (_bfd_elf_define_linkage_sym): Prevent null pointer
2440 dereference.
2441 (bfd_elf_final_link): Only initialize the extended symbol index
2442 section if there are extended symbol tables to list.
2443
46bed679
L
24442017-04-03 H.J. Lu <hongjiu.lu@intel.com>
2445
2446 * Makefile.am (BFD32_BACKENDS): Add elf-properties.lo.
2447 (BFD32_BACKENDS_CFILES): Add elf-properties.c.
2448 * configure.ac (elf): Add elf-properties.lo.
2449 * Makefile.in: Regenerated.
2450 * configure: Likewise.
2451 * elf-bfd.h (elf_property_kind): New.
2452 (elf_property): Likewise.
2453 (elf_property_list): Likewise.
2454 (elf_properties): Likewise.
2455 (_bfd_elf_parse_gnu_properties): Likewise.
2456 (_bfd_elf_get_property): Likewise.
2457 (_bfd_elf_link_setup_gnu_properties): Likewise.
2458 (elf_backend_data): Add parse_gnu_properties, merge_gnu_properties
2459 and setup_gnu_properties.
2460 (elf_obj_tdata): Add properties.
2461 * elf-properties.c: New file.
2462 * elf32-i386.c (elf_i386_parse_gnu_properties): New.
2463 (elf_i386_merge_gnu_properties): Likewise.
2464 (elf_backend_parse_gnu_properties): Likewise.
2465 (elf_backend_merge_gnu_properties): Likewise.
2466 * elf64-x86-64.c (elf_x86_64_parse_gnu_properties): Likewise.
2467 (elf_x86_64_merge_gnu_properties): Likewise.
2468 (elf_backend_parse_gnu_properties): Likewise.
2469 (elf_backend_merge_gnu_properties): Likewise.
2470 * elfxx-target.h (elf_backend_merge_gnu_properties): Likewise.
2471 (elf_backend_parse_gnu_properties): Likewise.
2472 (elf_backend_setup_gnu_properties): Likewise.
2473 (elfNN_bed): Add elf_backend_parse_gnu_properties,
2474 elf_backend_merge_gnu_properties and
2475 elf_backend_setup_gnu_properties.
2476
f96bd6c2
PC
24772017-03-30 Pip Cet <pipcet@gmail.com>
2478
2479 * elf32-wasm32.c: Add relocation code, two relocs.
2480 * reloc.c: Add wasm32 relocations.
2481 * libbfd.h: Regenerate.
2482 * bfd-in2.h: Regenerate.
2483 * bfd/po/bfd.pot: Regenerate.
2484
e643cb45
NC
24852017-03-29 Nick Clifton <nickc@redhat.com>
2486
2487 PR binutils/18025
2488 * coff-bfd.h (struct coff_section_data): Add new fields:
2489 saved_bias and bias.
2490 * coffgen.c (coff_find_nearest_line_with_names): Cache the bias
2491 computed for PE binaries.
2492 * dwarf2.c (scan_unit_for_symbols): Only warn once about each
2493 missing abbrev.
2494
086554e8
HPN
24952017-03-28 Hans-Peter Nilsson <hp@axis.com>
2496
2497 PR ld/16044
2498 * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Adjust BFD_ASSERT
2499 to handle a local symbol with a hash-symbol-entry; without PLT.
2500 Add BFD_ASSERT for an incidental case with GOT entry present.
2501 (cris_elf_check_relocs): Increment PLT refcount only if the symbol
2502 isn't forced-or-set local.
2503
a6be0538
PC
25042017-03-27 Pip Cet <pipcet@gmail.com>
2505
2506 * wasm-module.c: New file to support WebAssembly modules.
2507 * wasm-module.h: New file to support WebAssembly modules.
2508 * doc/webassembly.texi: Start documenting wasm-module.c.
2509 * config.bfd: Add wasm_vec.
2510 * targets.c: Likewise.
2511 * configure.ac: Likewise.
2512 * Makefile.am: Add entries for wasm-module.c.
2513 * Makefile.in: Regenerate.
2514 * configure: Regenerate.
2515 * po/SRC-POTFILES.in: Regenerate.
2516
79b1d3cb
PC
25172017-03-27 Pip Cet <pipcet@gmail.com>
2518
2519 * cpu-wasm32.c: New file to support wasm32 architecture.
2520 * elf32-wasm32.c: New file to support wasm32 architecture.
2521 * Makefile.am: Add wasm32 architecture.
2522 * archures.c: Likewise.
2523 * config.bfd: Likewise.
2524 * configure.ac: Likewise.
2525 * targets.c: Likewise.
2526 * Makefile.in: Regenerate.
2527 * bfd-in2.h: Regenerate.
2528 * configure: Regenerate.
2529 * po/SRC-POTFILES.in: Regenerate.
2530
aaed6f5b
AM
25312017-03-20 Alan Modra <amodra@gmail.com>
2532
2533 PR 21266
2534 * elf64-ppc.c (compare_symbols): Stabilize sort.
2535
82e66161
AM
25362017-03-18 Alan Modra <amodra@gmail.com>
2537
2538 * elf64-ppc.c (struct ppc_link_hash_table): Add
2539 local_ifunc_resolver and maybe_local_ifunc_resolver.
2540 (ppc_build_one_stub): Set flags on emitting dynamic
2541 relocation to ifunc.
2542 (ppc64_elf_relocate_section): Likewise.
2543 (ppc64_elf_finish_dynamic_symbol): Likewise.
2544 (ppc64_elf_finish_dynamic_sections): Error on DT_TEXTREL with
2545 local dynamic relocs to ifuncs.
2546 * elf32-ppc.c (struct ppc_elf_link_hash_table): Add
2547 local_ifunc_resolver and maybe_local_ifunc_resolver.
2548 (ppc_elf_relocate_section): Set flag on emitting dynamic
2549 relocation to ifuncs.
2550 (ppc_elf_finish_dynamic_symbol): Likewise.
2551 (ppc_elf_finish_dynamic_sections): Error on DT_TEXTREL with local
2552 dynamic relocs to ifuncs.
2553
f955cccf
NC
25542017-03-13 Nick Clifton <nickc@redhat.com>
2555
2556 PR binutils/21202
2557 * reloc.c (BFD_RELOC_AARCH64_TLSDESC_LD64_LO12_NC): Rename to
2558 BFD_RELOC_AARCH64_TLSDESC_LD64_LO12.
2559 (BFD_RELOC_AARCH64_TLSDESC_ADD_LO12_NC): Rename to
2560 BFD_RELOC_AARCH64_TLSDESC_ADD_LO12.
2561 * bfd-in2.h: Regenerate.
2562 * libbfd.h: Regenerate.
2563 * elfnn-aarch64.c (IS_AARCH64_TLS_RELAX_RELOC): Update reloc
2564 names.
2565 (IS_AARCH64_TLSDESC_RELOC): Likewise.
2566 (elfNN_aarch64_howto_table): Likewise.
2567 (aarch64_tls_transition_without_check): Likewise.
2568 (aarch64_reloc_got_type): Likewise.
2569 (elfNN_aarch64_final_link_relocate): Likewise.
2570 (elfNN_aarch64_tls_relax): Likewise.
2571 (elfNN_aarch64_relocate_section): Likewise.
2572 (elfNN_aarch64_gc_sweep_hook): Likewise.
2573 (elfNN_aarch64_check_relocs): Likewise.
2574 * elfxx-aarch64.c (_bfd_aarch64_elf_put_addend): Likewise.
2575 (_bfd_aarch64_elf_resolve_relocation): Likewise.
2576
4aef7643
AM
25772017-03-11 Alan Modra <amodra@gmail.com>
2578
2579 * elf32-ppc.c: Remove ATTRIBUTE_UNUSED throughout when function
2580 parameter is in fact used. Whitespace fixes.
2581 * elf64-ppc.c: Likewise.
2582
f03265d9
ST
25832017-03-09 Sam Thursfield <sam.thursfield@codethink.co.uk>
2584
2585 * rs6000-core.c (CORE_NEW): Simplify macro when
2586 AIX_CORE_DUMPX_CORE and BFD64 are true to avoid compile warning.
2587
b1b07054
AM
25882017-03-07 Alan Modra <amodra@gmail.com>
2589
2590 PR 21224
2591 PR 20519
2592 * elf64-ppc.c (ppc64_elf_relocate_section): Add missing
2593 dyn_relocs check.
2594
2e0ce1c8
AM
25952017-03-05 Alan Modra <amodra@gmail.com>
2596
2597 * elf-bfd.h (struct eh_cie_fde): Add u.cie.per_encoding_aligned8.
2598 * elf-eh-frame.c (size_of_output_cie_fde): Don't align here.
2599 (next_cie_fde_offset): New function.
2600 (_bfd_elf_parse_eh_frame): Set u.cie.per_encoding_aligned8.
2601 (_bfd_elf_discard_section_eh_frame): Align zero terminator to
2602 four bytes. Align CIEs to four or eight bytes depending on
2603 per_encoding_aligned8. Align FDEs according to their encoding.
2604 Pad last FDE to output section alignment.
2605 (_bfd_elf_write_section_eh_frame): Adjust to suit. Remove
2606 assertion.
2607 * elf64-ppc.c (glink_eh_frame_cie): Delete padding.
2608 (ppc64_elf_size_stubs): Pad glink eh_frame as per elf-eh-frame.c.
2609 (ppc64_elf_finish_dynamic_sections): Adjust to suit.
2610
f98450c6
NC
26112017-03-02 Martin Bickel <binutils@ineranves.de>
2612
2613 PR ld/21212
2614 * elf.c (rewrite_elf_program_header): Do not issue a warning for
d20928fa 2615 empty segments which have a zero filesz, but a non-zero memsz.
f98450c6 2616
673cff9b
AM
26172017-03-02 Alan Modra <amodra@gmail.com>
2618
2619 * elf32-ppc.c (ppc_elf_vle_split16): Correct insn mask typo.
2620
3de43e7b
AM
26212017-02-28 Alan Modra <amodra@gmail.com>
2622
2623 * elf64-ppc.c (ppc64_elf_ha_reloc): Revert last change.
2624 (ppc64_elf_relocate_section): Likewise.
2625
4ef97a1b
AM
26262017-02-28 Alan Modra <amodra@gmail.com>
2627
2628 PR 20995
2629 * elf32-nios2.c (nios2_elf32_relocate_section): Use htab
2630 rather than elf32_nios2_hash_table or elf_hash_table.
2631 (create_got_section): Likewise.
2632 (nios2_elf32_finish_dynamic_symbol): Likewise.
2633 (nios2_elf32_adjust_dynamic_symbol): Likewise.
2634 (nios2_elf32_size_dynamic_sections): Likewise.
2635 (nios2_elf32_check_relocs): Delete dynobj, sgot, and srelgot
2636 vars. Use htab equivalents directly instead. Don't create
2637 all dynamic sections on needing just the GOT. Use a goto
2638 rather than a fall-through with reloc test. Ensure
2639 htab->dynobj is set when making dynamic sreloc section.
2640 (nios2_elf32_finish_dynamic_sections): Delete dynobj, use htab
2641 equivalent directly instead. Don't segfault on looking for
2642 .dynamic when dynamic sections have not been created. Don't
2643 segfault on .got.plt being discarded.
2644 (nios2_elf32_size_dynamic_sections): Delete plt and got vars.
2645 Don't set "relocs" on .rela.plt. Do handle .sbss. Delete
2646 fixme and another not so relevant comment.
2647 (nios2_elf_add_symbol_hook): Delete dynobj var. If not
2648 already set, set hash table dynobj on creating .sbss.
2649
7ba71655
AM
26502017-02-28 Alan Modra <amodra@gmail.com>
2651
2652 * reloc.c (BFD_RELOC_PPC_16DX_HA): New.
2653 * elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_16DX_HA>): New howto.
2654 (ppc64_elf_reloc_type_lookup): Translate new bfd reloc.
2655 (ppc64_elf_ha_reloc): Correct overflow test on REL16DX_HA.
2656 (ppc64_elf_relocate_section): Likewise.
2657 * elf32-ppc.c (ppc_elf_howto_raw <R_PPC_16DX_HA>): New howto.
2658 (ppc_elf_reloc_type_lookup): Translate new bfd reloc.
2659 (ppc_elf_check_relocs): Handle R_PPC_16DX_HA to pacify gcc.
2660 * libbfd.h: Regenerate.
2661 * bfd-in2.h: Regenerate.
2662
afbf7e8e
AM
26632017-02-28 Alan Modra <amodra@gmail.com>
2664
2665 * elflink.c (_bfd_elf_create_dynamic_sections): Don't make
2666 dynamic .data.rel.ro read-only.
2667 * elf32-arm.c (elf32_arm_finish_dynamic_symbol): Compare section
2668 rather than section flags when deciding where copy reloc goes.
2669 * elf32-cris.c (elf_cris_finish_dynamic_symbol): Likewise.
2670 * elf32-hppa.c (elf32_hppa_finish_dynamic_symbol): Likewise.
2671 * elf32-i386.c (elf_i386_finish_dynamic_symbol): Likewise.
2672 * elf32-metag.c (elf_metag_finish_dynamic_symbol): Likewise.
2673 * elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol): Likewise.
2674 * elf32-nios2.c (nios2_elf32_finish_dynamic_symbol): Likewise.
2675 * elf32-or1k.c (or1k_elf_finish_dynamic_symbol): Likewise.
2676 * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Likewise.
2677 * elf32-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
2678 * elf32-tic6x.c (elf32_tic6x_finish_dynamic_symbol): Likewise.
2679 * elf32-tilepro.c (tilepro_elf_finish_dynamic_symbol): Likewise.
2680 * elf64-ppc.c (ppc64_elf_finish_dynamic_symbol): Likewise.
2681 * elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
2682 * elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
2683 * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol): Likewise.
2684 * elfnn-riscv.c (riscv_elf_finish_dynamic_symbol): Likewise.
2685 * elfxx-mips.c (_bfd_mips_vxworks_finish_dynamic_symbol): Likewise.
2686 * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): Likewise.
2687 * elfxx-tilegx.c (tilegx_elf_finish_dynamic_symbol): Likewise.
2688
0e392101
MR
26892017-02-28 Maciej W. Rozycki <macro@imgtec.com>
2690
2691 * elfxx-mips.c (mips_elf_perform_relocation): Also handle the
2692 `jalr $0, $25' instruction encoding.
2693
bd757ca7
NC
26942017-02-27 Nick Clifton <nickc@redhat.com>
2695
2696 PR ld/21180
2697 * elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol): Avoid
2698 generating a seg-fault when encountering a symbol that has been
2699 deleted by garbage collection.
2700
034fed0b
AM
27012017-02-25 Alan Modra <amodra@gmail.com>
2702
2703 * elf32-arc.c (struct dynamic_sections): Delete.
2704 (enum dyn_section_types): Delete.
2705 (dyn_section_names): Delete.
2706 (arc_create_dynamic_sections): Delete.
2707 (elf_arc_finish_dynamic_sections): Don't call the above. Don't
2708 segfault on discarded .rela.plt section.
2709 (elf_arc_size_dynamic_sections): Formatting. Don't call
2710 arc_create_dynamic_sections. Don't allocate memory for sections
2711 handled by the generic linker. Correct code finding relocs in
2712 read-only sections. Set SEC_EXCLUDE on zero size .got,
2713 .got.plt, and .dynbss sections. Do set .interp for pies.
2714
d0f744f9
AW
27152017-02-24 Andrew Waterman <andrew@sifive.com>
2716
2717 * elfnn-riscv.c (GP_NAME): New macro.
2718 (riscv_global_pointer_value): Use it.
2719 (_bfd_riscv_relax_lui): If symbol and global pointer are in same
2720 output section, consider only that section's alignment.
2721
5d58c733
MR
27222017-02-23 Maciej W. Rozycki <macro@imgtec.com>
2723
2724 * elfxx-mips.h (_bfd_mips_relax_section): Remove prototype.
2725 * elfxx-mips.c (_bfd_mips_relax_section): Remove function.
2726 * elf64-mips.c (bfd_elf64_bfd_relax_section): Remove macro.
2727 * elfn32-mips.c (bfd_elf32_bfd_relax_section): Likewise.
2728
c1556ecd
MR
27292017-02-23 Maciej W. Rozycki <macro@imgtec.com>
2730
2731 * elfxx-mips.c (mips_elf_calculate_relocation) <R_MIPS_JALR>
2732 <R_MICROMIPS_JALR>: Discard relocation if `cross_mode_jump_p'
2733 or misaligned.
2734
5499c7c7
AM
27352017-02-23 Alan Modra <amodra@gmail.com>
2736
2737 PR 20744
2738 * elf32-ppc.c (ppc_elf_howto_raw): Correct dst_mask on all VLE
2739 16D relocations.
2740 (ppc_elf_vle_split16): Correct field mask and shift for 16D relocs.
2741 (ppc_elf_relocate_section): Correct calculation for VLE SDAREL
2742 relocs.
2743
902e9fc7
MR
27442017-02-22 Maciej W. Rozycki <macro@imgtec.com>
2745
2746 PR ld/20828
2747 * elflink.c (bfd_elf_size_dynamic_sections): Move symbol version
2748 processing ahead of the call to `elf_gc_sweep_symbol'.
2749
758d96d8
NC
27502017-02-22 Nick Clifton <nickc@redhat.com>
2751
2752 PR binutils/21193
2753 * opncls.c (bfd_create_gnu_debuglink_section): Give the newly
2754 created section 4-byte alignment.
2755
6528b6eb
AM
27562017-02-22 Alan Modra <amodra@gmail.com>
2757
2758 * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Don't segfault
2759 on .got or .plt output section being discarded by script.
2760 * elf32-ppc.c (ppc_elf_finish_dynamic_sections): Likewise. Move
2761 vxworks splt temp.
2762
24f1a751
AM
27632017-02-21 Alan Modra <amodra@gmail.com>
2764
2765 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Only emit
2766 DT_RELA, DT_RELASZ, and DT_RELAENT when DT_RELASZ is non-zero.
2767
64487780
AM
27682017-02-20 Alan Modra <amodra@gmail.com>
2769
2770 PR 21181
2771 * elflink.c (bfd_elf_final_link): Make DT_REL/DT_RELA zero
2772 if DT_RELSZ/DT_RELASZ is zero.
2773
6438d1be
NC
27742017-02-17 Nick Clifton <nickc@redhat.com>
2775
2776 * compress.c (bfd_get_full_section_contents): Remember to reduce
2777 compressed size by the sizeof the compression header when
2778 decompressing the contents.
2779
4bc26c69
PA
27802017-02-17 Pedro Alves <palves@redhat.com>
2781
2782 * srec.c (Chunk): Rename to ...
2783 (_bfd_srec_len): ... this.
2784 (S3Forced): Rename to ...
2785 (_bfd_srec_forceS3): ... this.
2786 * objcopy.c: Adjust all references.
2787
7ec22e0f
PA
27882017-02-17 Pedro Alves <palves@redhat.com>
2789
2790 * archive.c (bsd_write_armap): Rename to ...
2791 (_bfd_bsd_write_armap): ... this.
2792 (coff_write_armap): Rename to ...
2793 (_bfd_coff_write_armap): ... this.
2794 * libbfd-in.h (bsd_write_armap): Rename to ...
2795 (_bfd_bsd_write_armap): ... this.
2796 (coff_write_armap): Rename to ...
2797 (_bfd_coff_write_armap): ... this.
2798 * aout-target.h, aout-tic30.c: Adjust all users.
2799 * libbfd.h: Regenerate.
2800
8c8402cc
PA
28012017-02-17 Pedro Alves <palves@redhat.com>
2802
2803 * bfd-in.h (bfd_read, bfd_write): Adjust to rename.
2804 (warn_deprecated): Rename to ...
2805 (_bfd_warn_deprecated): ... this.
2806 * libbfd.c (warn_deprecated): Rename to ...
2807 (_bfd_warn_deprecated): ... this.
2808 * bfd-in2.h: Regenerate.
2809
c7c3d11b
PA
28102017-02-17 Pedro Alves <palves@redhat.com>
2811
2812 * bfdio.c (real_ftell): Rename to ...
2813 (_bfd_real_ftell): ... this.
2814 (real_fseek): Rename to ...
2815 (_bfd_real_fseek): ... this.
2816 (real_fopen): Rename to ...
2817 (_bfd_real_fopen): ... this.
2818 * libbfd-in.h (real_ftell): Rename to ...
2819 (_bfd_real_ftell): ... this.
2820 (real_fseek): Rename to ...
2821 (_bfd_real_fseek): ... this.
2822 (real_fopen): Rename to ...
2823 (_bfd_real_fopen): ... this.
2824 * cache.c, dwarf2.c, opncls.c: Adjust all callers.
2825 * libbfd.h: Regenerate.
2826
4265548c
PA
28272017-02-17 Pedro Alves <palves@redhat.com>
2828
2829 * dwarf2.c, elf-attrs.c, elf32-nds32.c: Adjust all callers.
2830 * libbfd.c (read_unsigned_leb128): Rename to ...
2831 (_bfd_read_unsigned_leb128): ... this.
2832 (read_signed_leb128): Rename to ...
2833 (_bfd_read_signed_leb128): ... this.
2834 (safe_read_leb128): Rename to ...
2835 (_bfd_safe_read_leb128): ... this.
2836 * libbfd-in.h (read_unsigned_leb128): Rename to ...
2837 (_bfd_read_unsigned_leb128): ... this.
2838 (read_signed_leb128): Rename to ...
2839 (_bfd_read_signed_leb128): ... this.
2840 (safe_read_leb128): Rename to ...
2841 (_bfd_safe_read_leb128): ... this.
2842 * libbfd.h: Renegerate.
2843
3239a423
AB
28442017-02-16 Andrew Burgess <andrew.burgess@embecosm.com>
2845
2846 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Perform symbol lookup
2847 before trying to fine matching file and line information.
2848
90ed9b8b
AB
28492017-02-16 Andrew Burgess <andrew.burgess@embecosm.com>
2850
2851 * dwarf2.c (struct dwarf2_debug): Add orig_bfd member.
2852 (_bfd_dwarf2_slurp_debug_info): If stashed debug information does
2853 not match current bfd, then reload debug information. Record bfd
2854 we're loading debug info for in the stash. If we have debug
2855 informatin in the cache then perform section placement before
2856 returning.
2857
a8c75b76
AM
28582017-02-16 Alan Modra <amodra@gmail.com>
2859
2860 PR 21000
2861 * elf-bfd.h (struct elf_backend_data): Add no_page_alias.
2862 * elfxx-target.h (elf_backend_no_page_alias): Define.
2863 (elfNN_bed): Init new field.
2864 * elf.c (assign_file_positions_for_load_sections): If no_page_alias
2865 ensure PT_LOAD segment starts on a new page.
2866 * elf32-hppa.c (elf_backend_no_page_alias): Define.
2867
247d6c4c
AM
28682017-02-16 Alan Modra <amodra@gmail.com>
2869
2870 PR 21132
2871 * elf32-hppa.c (allocate_plt_static): Allocate space for relocs
2872 if pic.
2873
90571206
JW
28742017-02-16 Jiong Wang <jiong.wang@arm.com>
2875
2876 * bfd.c (BFD_FLAGS_SAVED): Add BFD_LINKER_CREATED.
2877 * bfd-in2.h: Regenerated.
2878
2a568401
L
28792017-02-15 H.J. Lu <hongjiu.lu@intel.com>
2880
2881 PR ld/21168
2882 * elf32-i386.c (elf_i386_relocate_section): Allow
2883 "lea foo@GOT, %reg" in PIC.
2884
a5def14f
L
28852017-02-15 H.J. Lu <hongjiu.lu@intel.com>
2886
2887 PR ld/20244
2888 * elf32-i386.c (elf_i386_relocate_section): Properly get IFUNC
2889 symbol name when reporting R_386_GOT32/R_386_GOT32X relocation
2890 error against local IFUNC symbol without a base register for
2891 PIC.
2892
174d0a74
MR
28932017-02-15 Maciej W. Rozycki <macro@imgtec.com>
2894
2895 * elf32-ppc.c (ppc_elf_check_relocs): Use `%H:' rather than
2896 `%P: %H:' with `info->callbacks->einfo'.
2897 (ppc_elf_relocate_section): Likewise.
2898 * elf64-ppc.c (ppc64_elf_check_relocs): Likewise.
2899 (ppc64_elf_edit_toc): Likewise.
2900 (ppc64_elf_relocate_section): Likewise.
2901
e278ae05
AM
29022017-02-14 Alan Modra <amodra@gmail.com>
2903
2904 * elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Support
2905 --gc-keep-exported, and test versioned field of sym rather than
2906 looking for @ in name.
2907
10ddfe62
PD
29082017-02-13 Palmer Dabbelt <palmer@dabbelt.com>
2909
2910 * elfnn-riscv.c (riscv_global_pointer_value): Change _gp to
2911 __global_pointer$.
2912
d11135f5
NC
29132017-02-13 Nick Clifton <nickc@redhat.com>
2914
2915 PR binutils/21151
2916 * dwarf2.c (_bfd_dwarf2_find_nearest_line): Check for an invalid
2917 unit length field.
2918
cc162427
AW
29192017-02-07 Andrew Waterman <andrew@sifive.com>
2920
2921 * elfnn-riscv.c (riscv_elf_finish_dynamic_sections): Only write PLT
2922 entry size if PLT header is written.
2923
3d044c0c
SL
29242017-02-06 Sheldon Lobo <sheldon.lobo@oracle.com>
2925
2926 Fix sparc64 dynamic relocation processing to use the dynamic
2927 symbol count.
2928 * elf64-sparc.c (elf64_sparc_slurp_one_reloc_table): Use 'dynamic'
2929 to determine if bfd_get_symcount() or bfd_get_dynamic_symcount()
2930 should be used.
2931
1b7e3d2f
NC
29322017-02-03 Nick Clifton <nickc@redhat.com>
2933
2934 PR 21096
2935 * coffcode.h (coff_write_object_contents): Enlarge size of
2936 s_name_buf in order to avoid compile time warning about possible
2937 integer truncation.
2938 * elf32-nds32.c (nds32_elf_ex9_import_table): Mask off lower
2939 32-bits of insn value before printing into buffer.
2940
e17b0c35
MR
29412017-02-02 Maciej W. Rozycki <macro@imgtec.com>
2942
2943 * elfxx-mips.c (mips_elf_hash_sort_data): Add
2944 `max_local_dynindx'.
2945 (mips_elf_sort_hash_table): Handle it.
2946 (mips_elf_sort_hash_table_f) <GGA_NONE>: For forced local
2947 symbols bump up `max_local_dynindx' rather than
2948 `max_non_got_dynindx'.
2949
55f8b9d2
MR
29502017-02-02 Maciej W. Rozycki <macro@imgtec.com>
2951
2952 * elfxx-mips.c (mips_elf_hash_sort_data): Convert the
2953 `min_got_dynindx', `max_unref_got_dynindx' and
2954 `max_non_got_dynindx' members to the `bfd_size_type' data type.
2955 (mips_elf_sort_hash_table): Adjust accordingly.
2956
0f8c4b60
MR
29572017-02-02 Maciej W. Rozycki <macro@imgtec.com>
2958
2959 * elfxx-mips.c (mips_elf_sort_hash_table): Use `htab' throughout
2960 to access the hash table.
2961
17a80fa8
MR
29622017-02-02 Maciej W. Rozycki <macro@imgtec.com>
2963
2964 * elfxx-mips.c (mips_elf_sort_hash_table): Move assertion on
2965 non-NULL `htab' to the beginning.
2966
8f56d4fd
MR
29672017-02-02 Maciej W. Rozycki <macro@imgtec.com>
2968
2969 * elflink.c (elf_gc_sweep): Wrap overlong line.
2970
8b10b0b3
MR
29712017-01-30 Maciej W. Rozycki <macro@imgtec.com>
2972
2973 * elfxx-mips.h (_bfd_mips_elf_insn32): Rename prototype to...
2974 (_bfd_mips_elf_linker_flags): ... this. Add another parameter.
2975 * elfxx-mips.c (mips_elf_link_hash_table): Add
2976 `ignore_branch_isa' member.
2977 (mips_elf_perform_relocation): Do not treat an ISA mode mismatch
2978 in branch relocation calculation as an error if
2979 `ignore_branch_isa' has been set.
2980 (_bfd_mips_elf_insn32): Rename to...
2981 (_bfd_mips_elf_linker_flags): ... this. Rename the `on'
2982 parameter to `insn32' and add an `ignore_branch_isa' parameter.
2983 Handle the new parameter.
2984
1fbd05e1
HPN
29852017-01-27 Hans-Peter Nilsson <hp@axis.com>
2986
22d9a0de
HPN
2987 * elf32-cris.c (elf_cris_finish_dynamic_symbol): Remove now unused
2988 local variable dynobj.
2989
1fbd05e1
HPN
2990 PR ld/20995
2991 * elf32-cris.c (elf_cris_size_dynamic_sections): Handle sdynrelro.
2992 (elf_cris_adjust_dynamic_symbol): Place variables copied into the
2993 executable from read-only sections into sdynrelro.
2994 (elf_cris_finish_dynamic_symbol): Select sreldynrelro for
2995 dynamic relocs in sdynrelro.
2996 (elf_backend_want_dynrelro): Define.
2997
4a7324e1
SH
29982017-01-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
2999
3000 * config.bfd (*-*-rtemsaout*): Mark as removed.
3001
c75b4ebd
SH
30022017-01-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
3003
3004 * config.bfd (powerpcle-*-rtems*): Do not mark as removed.
3005 (arm-*-rtems*): Move to (arm*-*-eabi*).
3006 (i[3-7]86-*-rtems*): Move to (i[3-7]86-*-elf*).
3007 (m68-*-rtems*): Move to (m68*-*-elf*).
3008
850d84f6
SH
30092017-01-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
3010
3011 * config.bfd (*-*-rtemscoff*): Mark as removed.
3012
b531344c
MR
30132017-01-24 Maciej W. Rozycki <macro@imgtec.com>
3014
3015 PR ld/20828
3016 * elflink.c (bfd_elf_record_link_assignment): Revert last
3017 change and don't ever clear `forced_local'. Set `mark'
3018 unconditionally.
3019 (elf_gc_sweep_symbol_info, elf_gc_sweep_symbol): Reorder within
3020 file.
3021 (elf_gc_sweep): Move the call to `elf_gc_sweep_symbol'...
3022 (bfd_elf_size_dynamic_sections): ... here.
3023 * elf32-ppc.c (ppc_elf_tls_setup): Don't clear `forced_local'
3024 and set `mark' instead in `__tls_get_addr_opt' processing.
3025 * elf64-ppc.c (ppc64_elf_tls_setup): Likewise.
3026
f0158f44
AM
30272017-01-24 Alan Modra <amodra@gmail.com>
3028
3029 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Merge two cases
3030 where dynamic relocs are preferable. Allow ifunc too.
3031 (ensure_undefweak_dynamic): New function.
3032 (allocate_dynrelocs): Use it here. Move plt handling last and
3033 don't make symbols dynamic, simplifying loop. Only make undef
3034 weak symbols with GOT entries dynamic. Correct condition
3035 for GOT relocs. Handle dynamic relocs on ifuncs. Correct
3036 comments. Remove goto.
3037 (ppc_elf_relocate_section): Correct test for using dynamic
3038 symbol on GOT relocs. Rearrange test for emitting GOT relocs
3039 to suit. Set up explicit tls_index entries and implicit GOT
3040 tls_index entries resolvable at link time for
3041 __tls_get_addr_opt. Simplify test to clear mem for prelink.
3042 * elf64-ppc.c (allocate_got): Correct condition for GOT relocs.
3043 (ensure_undefweak_dynamic): New function.
3044 (allocate_dynrelocs): Use it here. Only make undef weak symbols
3045 with GOT entries dynamic. Remove unnecessary test of
3046 WILL_CALL_FINISH_DYNAMIC_SYMBOL in PLT handling.
3047 (ppc64_elf_relocate_section): Correct test for using dynamic
3048 symbol on GOT relocs. Rearrange test for emitting GOT relocs
3049 to suit. Set up explicit tls_index entries and implicit GOT
3050 tls_index entries resolvable at link time for __tls_get_addr_opt.
3051 Simplify expression to clear mem for prelink.
3052
2d0ca824
YN
30532017-01-23 Yury Norov <ynorov@caviumnetworks.com>
3054
3055 * elfnn-aarch64.c: Fix relaxations for ILP32 mode.
3056
7f784814
JW
30572017-01-20 Jiong Wang <jiong.wang@arm.com>
3058
3059 * elfnn-aarch64.c (elf_aarch64_hash_symbol): New function.
3060 (elf_backend_hash_symbol): Define.
3061
81ff47b3
MR
30622017-01-18 Maciej W. Rozycki <macro@imgtec.com>
3063
3064 PR ld/20828
3065 * elflink.c (bfd_elf_record_link_assignment): Clear any
3066 `forced_local' marking for DSO symbols that are not being
3067 provided.
3068
640d6bfd
KLC
30692017-01-17 Kuan-Lin Chen <kuanlinchentw@gmail.com>
3070
3071 * elfnn-riscv.c (riscv_elf_object_p): New function.
3072
8361ed4d
L
30732017-01-12 H.J. Lu <hongjiu.lu@intel.com>
3074
3075 PR ld/21038
3076 * elf64-x86-64.c (elf_x86_64_link_hash_table): Add
3077 plt_bnd_eh_frame.
3078 (elf_x86_64_check_relocs): Create .eh_frame section for the
3079 .plt.bnd section.
3080 (elf_x86_64_size_dynamic_sections): Allocate and initialize
3081 .eh_frame section for the .plt.bnd section.
3082 (elf_x86_64_finish_dynamic_sections): Adjust .eh_frame section
3083 for the .plt.bnd section.
3084
2425a30e
NC
30852017-01-12 Nick Clifton <nickc@redhat.com>
3086
3087 PR binutils/20876
3088 * opncls.c (find_separate_debug_file): Add include_dirs
3089 parameter. Only include the directory part of the bfd's filename
3090 in search paths if include_dirs is true. Add a couple of extra
3091 locations for looking for debug files.
3092 ( bfd_follow_gnu_debuglink): Update invocation of
3093 find_separate_debug_file.
3094 (bfd_follow_gnu_debugaltlink): Likewise.
3095 (get_build_id): New function: Finds the build-id of the given bfd.
3096 (get_build_id_name): New function: Computes the name of the
3097 separate debug info file for a bfd, based upon its build-id.
3098 (check_build_id_file): New function: Checks to see if a separate
3099 debug info file exists at the given location, and that its
3100 build-id matches that of the original bfd.
3101 (bfd_follow_build_id_debuglink): New function: Finds a separate
3102 debug info file for a given bfd by using the build-id method.
3103 * dwarf2.c (_bfd_dwarf2_slurp_debug_info): Try using the build-id
3104 method of locating a separate debug info file before using the
3105 debuglink method.
3106 * bfd-in2.h: Regenerate.
3107
9e659176
L
31082017-01-11 H.J. Lu <hongjiu.lu@intel.com>
3109
3110 PR ld/21038
3111 * elf64-x86-64.c (elf_x86_64_eh_frame_bnd_plt): New.
3112 (elf_x86_64_bnd_arch_bed): Use elf_x86_64_eh_frame_bnd_plt and
3113 elf_x86_64_eh_frame_plt_got.
3114 (elf_x86_64_size_dynamic_sections): Get unwind info from
3115 elf_x86_64_bnd_arch_bed for the BND PLT.
3116
f2e2d2f5
JS
31172017-01-11 Jeremy Soller <jackpot51@gmail.com>
3118
3119 * config.bfd: Add entries for i686-redox and x86_64-redox.
3120
52b232b3
L
31212017-01-10 H.J. Lu <hongjiu.lu@intel.com>
3122
3123 * elf32-i386.c (elf_i386_check_relocs): Align .eh_frame section
3124 to 4 bytes.
3125 * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Align
3126 .eh_frame section to 4 bytes for x32.
3127 (elf_x86_64_check_relocs): Likewise.
3128
fff53dae
L
31292017-01-10 H.J. Lu <hongjiu.lu@intel.com>
3130
3131 PR ld/20830
3132 * elf32-i386.c (elf_i386_eh_frame_plt_got): New.
3133 (PLT_GOT_FDE_LENGTH): Likewise.
3134 (elf_i386_plt_layout): Add eh_frame_plt_got and
3135 eh_frame_plt_got_size.
3136 (elf_i386_plt): Updated.
3137 (elf_i386_link_hash_table): Add plt_got_eh_frame.
3138 (elf_i386_check_relocs): Create .eh_frame section for .plt.got.
3139 (elf_i386_size_dynamic_sections): Allocate and initialize
3140 .eh_frame section for .plt.got.
3141 (elf_i386_finish_dynamic_sections): Adjust .eh_frame section for
3142 .plt.got.
3143 (elf_i386_nacl_plt): Add FIXME for eh_frame_plt_got and
3144 eh_frame_plt_got_size.
3145 * elf64-x86-64.c (elf_x86_64_eh_frame_plt_got): New.
3146 (PLT_GOT_FDE_LENGTH): Likewise.
3147 (elf_x86_64_backend_data): Add eh_frame_plt_got and
3148 eh_frame_plt_got_size.
3149 (elf_x86_64_arch_bed): Updated.
3150 (elf_x86_64_bnd_arch_bed): Add FIXME for eh_frame_plt_got and
3151 eh_frame_plt_got_size.
3152 (elf_x86_64_nacl_arch_bed): Likewise.
3153 (elf_x86_64_link_hash_table): Add plt_got_eh_frame.
3154 (elf_x86_64_check_relocs): Create .eh_frame section for .plt.got.
3155 (elf_x86_64_size_dynamic_sections): Allocate and initialize
3156 .eh_frame section for .plt.got.
3157 (elf_x86_64_finish_dynamic_sections): Adjust .eh_frame section
3158 for .plt.got.
3159
f129e49f
L
31602017-01-10 H.J. Lu <hongjiu.lu@intel.com>
3161
3162 * elf32-i386.c (elf_i386_size_dynamic_sections): Set
3163 plt_eh_frame->size to eh_frame_plt_size and use eh_frame_plt.
3164
cd6581da
NC
31652017-01-09 Nick Clifton <nickc@redhat.com>
3166
3167 * dwarf2.c (lookup_address_in_function_table): Return early if
3168 there are no functions in the given comp unit, or if the high
3169 address of the last function in the comp unit is less than the
3170 desired address.
3171
98f02962
NC
31722017-01-09 Nick Clifton <nickc@redhat.com>
3173
3174 PR binutils/21013
3175 * coffgen.c (_bfd_coff_get_external_symbols): Generate an error
3176 message if there are too many symbols to load.
3177
ae4fda66
JC
31782017-01-04 James Clarke <jrtc27@jrtc27.com>
3179
3180 * elf64-alpha.c (elf64_alpha_relax_opt_call): Don't set tsec_free
3181 if relocs are cached.
3182
de1010f4
RF
31832017-01-03 Rich Felker <bugdal@aerifal.cx>
3184
3185 PR ld/21017
3186 * elf32-microblaze.c (microblaze_elf_check_relocs): Add an entry
3187 for R_MICROBLAZE_GOTOFF_64.
3188
09fe2662
NC
31892017-01-03 Nick Clifton <nickc@redhat.com>
3190
3191 * mach-o.c (bfd_mach_o_lookup_uuid_command): Fix compile time
3192 warning about using a possibly uninitialised variable.
3193
595e0a47
AM
31942017-01-02 Alan Modra <amodra@gmail.com>
3195
3196 * elf32-hppa.c (ensure_undef_weak_dynamic): New function.
3197 (allocate_plt_static, allocate_dynrelocs): Use it.
3198
7bd9df3b
AM
31992017-01-02 Alan Modra <amodra@gmail.com>
3200
3201 * elf-hppa.h (elf_hppa_fake_sections): Set SHF_INFO_LINK for
3202 .PARISC.unwind section.
3203
5b86074c
AM
32042017-01-02 Alan Modra <amodra@gmail.com>
3205
3206 PR ld/20989
3207 * elfxx-sparc.c (gdop_relative_offset_ok): New function.
3208 (_bfd_sparc_elf_relocate_section): Use it to validate GOT
3209 indirect to GOT pointer relative code edit.
3210
2571583a
AM
32112017-01-02 Alan Modra <amodra@gmail.com>
3212
3213 Update year range in copyright notice of all files.
3214
5c1ad6b5 3215For older changes see ChangeLog-2016
3499769a 3216\f
5c1ad6b5 3217Copyright (C) 2017 Free Software Foundation, Inc.
3499769a
AM
3218
3219Copying and distribution of this file, with or without modification,
3220are permitted in any medium without royalty provided the copyright
3221notice and this notice are preserved.
3222
3223Local Variables:
3224mode: change-log
3225left-margin: 8
3226fill-column: 74
3227version-control: never
3228End:
This page took 0.311624 seconds and 4 git commands to generate.