Add new Serbian translation for the bfd library.
[external/binutils.git] / bfd / ChangeLog
1 2016-06-01  Nick Clifton  <nickc@redhat.com>
2
3         * po/sr.po: New Serbian translation.
4         * configure.ac (ALL_LINGUAS): Add sr.
5         * configure: Regenerate.
6
7 2016-05-28  Maciej W. Rozycki  <macro@imgtec.com>
8
9         * elfxx-mips.c (b_reloc_p): New function.
10         (_bfd_mips_elf_relocate_section) <bfd_reloc_outofrange>: Handle
11         branch relocations.
12
13 2016-05-28  Maciej W. Rozycki  <macro@imgtec.com>
14
15         * elfxx-mips.c (mips_elf_calculate_relocation): <R_MIPS16_26>
16         <R_MIPS_26, R_MICROMIPS_26_S1>: Drop the region bits of the
17         reloc location from calculation, treat the addend as signed with
18         local non-section symbols and enable overflow detection.
19
20 2016-05-28  Alan Modra  <amodra@gmail.com>
21
22         * aoutx.h: Adjust linker callback calls throughout file,
23         removing dead code.
24         * bout.c: Likewise.
25         * coff-alpha.c: Likewise.
26         * coff-arm.c: Likewise.
27         * coff-h8300.c: Likewise.
28         * coff-h8500.c: Likewise.
29         * coff-i960.c: Likewise.
30         * coff-mcore.c: Likewise.
31         * coff-mips.c: Likewise.
32         * coff-ppc.c: Likewise.
33         * coff-rs6000.c: Likewise.
34         * coff-sh.c: Likewise.
35         * coff-tic80.c: Likewise.
36         * coff-w65.c: Likewise.
37         * coff-z80.c: Likewise.
38         * coff-z8k.c: Likewise.
39         * coff64-rs6000.c: Likewise.
40         * cofflink.c: Likewise.
41         * ecoff.c: Likewise.
42         * elf-bfd.h: Likewise.
43         * elf-m10200.c: Likewise.
44         * elf-m10300.c: Likewise.
45         * elf32-arc.c: Likewise.
46         * elf32-arm.c: Likewise.
47         * elf32-avr.c: Likewise.
48         * elf32-bfin.c: Likewise.
49         * elf32-cr16.c: Likewise.
50         * elf32-cr16c.c: Likewise.
51         * elf32-cris.c: Likewise.
52         * elf32-crx.c: Likewise.
53         * elf32-d10v.c: Likewise.
54         * elf32-epiphany.c: Likewise.
55         * elf32-fr30.c: Likewise.
56         * elf32-frv.c: Likewise.
57         * elf32-ft32.c: Likewise.
58         * elf32-h8300.c: Likewise.
59         * elf32-hppa.c: Likewise.
60         * elf32-i370.c: Likewise.
61         * elf32-i386.c: Likewise.
62         * elf32-i860.c: Likewise.
63         * elf32-ip2k.c: Likewise.
64         * elf32-iq2000.c: Likewise.
65         * elf32-lm32.c: Likewise.
66         * elf32-m32c.c: Likewise.
67         * elf32-m32r.c: Likewise.
68         * elf32-m68hc1x.c: Likewise.
69         * elf32-m68k.c: Likewise.
70         * elf32-mep.c: Likewise.
71         * elf32-metag.c: Likewise.
72         * elf32-microblaze.c: Likewise.
73         * elf32-moxie.c: Likewise.
74         * elf32-msp430.c: Likewise.
75         * elf32-mt.c: Likewise.
76         * elf32-nds32.c: Likewise.
77         * elf32-nios2.c: Likewise.
78         * elf32-or1k.c: Likewise.
79         * elf32-ppc.c: Likewise.
80         * elf32-s390.c: Likewise.
81         * elf32-score.c: Likewise.
82         * elf32-score7.c: Likewise.
83         * elf32-sh.c: Likewise.
84         * elf32-sh64.c: Likewise.
85         * elf32-spu.c: Likewise.
86         * elf32-tic6x.c: Likewise.
87         * elf32-tilepro.c: Likewise.
88         * elf32-v850.c: Likewise.
89         * elf32-vax.c: Likewise.
90         * elf32-visium.c: Likewise.
91         * elf32-xstormy16.c: Likewise.
92         * elf32-xtensa.c: Likewise.
93         * elf64-alpha.c: Likewise.
94         * elf64-hppa.c: Likewise.
95         * elf64-ia64-vms.c: Likewise.
96         * elf64-mmix.c: Likewise.
97         * elf64-ppc.c: Likewise.
98         * elf64-s390.c: Likewise.
99         * elf64-sh64.c: Likewise.
100         * elf64-x86-64.c: Likewise.
101         * elflink.c: Likewise.
102         * elfnn-aarch64.c: Likewise.
103         * elfnn-ia64.c: Likewise.
104         * elfxx-mips.c: Likewise.
105         * elfxx-sparc.c: Likewise.
106         * elfxx-tilegx.c: Likewise.
107         * linker.c: Likewise.
108         * pdp11.c: Likewise.
109         * pe-mips.c: Likewise.
110         * reloc.c: Likewise.
111         * reloc16.c: Likewise.
112         * simple.c: Likewise.
113         * vms-alpha.c: Likewise.
114         * xcofflink.c: Likewise.
115         * elf32-rl78.c (get_symbol_value, get_romstart, get_ramstart): Delete
116         status param.  Adjust calls to these and linker callbacks throughout.
117         * elf32-rx.c: (get_symbol_value, get_gp, get_romstart,
118         get_ramstart): Delete status param.  Adjust calls to these and
119         linker callbacks throughout.
120
121 2016-05-27  Maciej W. Rozycki  <macro@imgtec.com>
122
123         * elfxx-mips.c (mips_elf_calculate_relocation) <R_MIPS16_26>
124         <R_MIPS_26, R_MICROMIPS_26_S1>: Include the addend in JALX's
125         target alignment verification.
126
127 2016-05-27  Maciej W. Rozycki  <macro@imgtec.com>
128
129         * elfxx-mips.c (mips_elf_calculate_relocation): Also use the
130         section name if `bfd_elf_string_from_elf_section' returns an
131         empty string.
132
133 2016-05-26  Maciej W. Rozycki  <macro@imgtec.com>
134
135         * elfxx-mips.c (_bfd_mips_elf_relocate_section)
136         <bfd_reloc_outofrange>: Use the `%X%H' rather than `%C' format
137         for message.  Continue processing rather than returning failure.
138
139 2016-05-25  Maciej W. Rozycki  <macro@imgtec.com>
140
141         * elfxx-mips.c (_bfd_mips_elf_relocate_section)
142         <bfd_reloc_outofrange>: Call `->einfo' rather than `->warning'.
143         Call `bfd_set_error'.
144
145 2016-05-25  H.J. Lu  <hongjiu.lu@intel.com>
146
147         PR binutils/14625
148         * archive.c (bfd_slurp_armap): Replace
149         bfd_elf64_archive_slurp_armap with
150         _bfd_archive_64_bit_slurp_armap.
151         (bsd_write_armap): Call _bfd_archive_64_bit_write_armap if
152         BFD64 is defined and the archive is too big.
153         (coff_write_armap): Likewise.
154         * archive64.c (bfd_elf64_archive_slurp_armap): Renamed to ...
155         (_bfd_archive_64_bit_slurp_armap): This.
156         (bfd_elf64_archive_write_armap): Renamed to ...
157         (_bfd_archive_64_bit_write_armap): This.
158         * configure.ac: Add --enable-64-bit-archive.
159         (want_64_bit_archive): New.  Set to true by default for 64-bit
160         MIPS and s390 ELF targets.
161         (USE_64_BIT_ARCHIVE): New AC_DEFINE.
162         * config.in: Regenerated.
163         * configure: Likewise.
164         * elf64-mips.c (bfd_elf64_archive_functions): Removed.
165         (bfd_elf64_archive_slurp_armap): Likewise.
166         (bfd_elf64_archive_write_armap): Likewise.
167         (bfd_elf64_archive_slurp_extended_name_table): Likewise.
168         (bfd_elf64_archive_construct_extended_name_table): Likewise.
169         (bfd_elf64_archive_truncate_arname): Likewise.
170         (bfd_elf64_archive_read_ar_hdr): Likewise.
171         (bfd_elf64_archive_write_ar_hdr): Likewise.
172         (bfd_elf64_archive_openr_next_archived_file): Likewise.
173         (bfd_elf64_archive_get_elt_at_index): Likewise.
174         (bfd_elf64_archive_generic_stat_arch_elt): Likewise.
175         (bfd_elf64_archive_update_armap_timestamp): Likewise.
176         * elf64-s390.c (bfd_elf64_archive_functions): Removed.
177         (bfd_elf64_archive_slurp_armap): Likewise.
178         (bfd_elf64_archive_write_armap): Likewise.
179         (bfd_elf64_archive_slurp_extended_name_table): Likewise.
180         (bfd_elf64_archive_construct_extended_name_table): Likewise.
181         (bfd_elf64_archive_truncate_arname): Likewise.
182         (bfd_elf64_archive_read_ar_hdr): Likewise.
183         (bfd_elf64_archive_write_ar_hdr): Likewise.
184         (bfd_elf64_archive_openr_next_archived_file): Likewise.
185         (bfd_elf64_archive_get_elt_at_index): Likewise.
186         (bfd_elf64_archive_generic_stat_arch_elt): Likewise.
187         (bfd_elf64_archive_update_armap_timestamp): Likewise.
188         * elfxx-target.h (TARGET_BIG_SYM): Use _bfd_archive_64_bit on
189         BFD_JUMP_TABLE_ARCHIVE if USE_64_BIT_ARCHIVE is defined and
190         bfd_elfNN_archive_functions isn't defined.
191         (TARGET_LITTLE_SYM): Likewise.
192         * libbfd-in.h (_bfd_archive_64_bit_slurp_armap): New prototype.
193         (_bfd_archive_64_bit_write_armap): Likewise.
194         (_bfd_archive_64_bit_slurp_extended_name_table): New macro.
195         (_bfd_archive_64_bit_construct_extended_name_table): Likewise.
196         (_bfd_archive_64_bit_truncate_arname): Likewise.
197         (_bfd_archive_64_bit_read_ar_hdr): Likewise.
198         (_bfd_archive_64_bit_write_ar_hdr): Likewise.
199         (_bfd_archive_64_bit_openr_next_archived_file): Likewise.
200         (_bfd_archive_64_bit_get_elt_at_index): Likewise.
201         (_bfd_archive_64_bit_generic_stat_arch_elt): Likewise.
202         (_bfd_archive_64_bit_update_armap_timestamp): Likewise.
203         * libbfd.h: Regenerated.
204         * plugin.c (plugin_vec): Use _bfd_archive_64_bit on
205         BFD_JUMP_TABLE_ARCHIVE if USE_64_BIT_ARCHIVE is defined.
206
207 2016-05-25  H.J. Lu  <hongjiu.lu@intel.com>
208
209         PR ld/20103
210         * cofflink.c (coff_link_check_archive_element): Return TRUE if
211         linker add_archive_element callback returns FALSE.
212         * ecoff.c (ecoff_link_check_archive_element): Likewise.
213         * elf64-ia64-vms.c (elf64_vms_link_add_archive_symbols): Skip
214         archive element if linker add_archive_element callback returns
215         FALSE.
216         * elflink.c (elf_link_add_archive_symbols): Likewise.
217         * pdp11.c (aout_link_check_ar_symbols): Likewise.
218         * vms-alpha.c (alpha_vms_link_add_archive_symbols): Likewise.
219         * xcofflink.c (xcoff_link_check_dynamic_ar_symbols): Likewise.
220         (xcoff_link_check_ar_symbols): Likewise.
221
222 2016-05-24  Maciej W. Rozycki  <macro@imgtec.com>
223
224         * elfxx-mips.c (_bfd_mips_elf_relocate_section)
225         <bfd_reloc_outofrange>: Unify error reporting code.
226
227 2016-05-23  Jim Wilson  <jim.wilson@linaro.org>
228
229         * elfnn-aarch64.c: Unconditionally enable R_AARCH64_NULL and
230         R_AARCH64_NONE.  Use HOWTO64 for R_AARCH64_NULL.
231         * relocs.c: Add BFD_RELOC_AARCH64_NULL.
232         * bfd-in2.h: Regenerate.
233         * libbfd.h: Likewise.
234
235 2016-05-23  Kuba Sejdak  <jakub.sejdak@phoesys.com>
236
237         * config.bfd: Add entry for arm-phoenix.
238
239 2016-05-23  Thomas Preud'homme  <thomas.preudhomme@arm.com>
240
241         * elf32-arm.c (arm_dedicated_stub_section_padding): New function.
242         (elf32_arm_size_stubs): Declare stub_type in a more outer scope and
243         account for padding for stub section requiring one.
244         (elf32_arm_build_stubs): Add comment to stress the importance of
245         zeroing veneer section content.
246
247 2016-05-23  Thomas Preud'homme  <thomas.preudhomme@arm.com>
248
249         * bfd-in.h (bfd_elf32_arm_keep_private_stub_output_sections): Declare
250         bfd hook.
251         * bfd-in2.h: Regenerate.
252         * elf32-arm.c (arm_dedicated_stub_output_section_required): New
253         function.
254         (arm_dedicated_stub_output_section_required_alignment): Likewise.
255         (arm_dedicated_stub_output_section_name): Likewise.
256         (arm_dedicated_stub_input_section_ptr): Likewise.
257         (elf32_arm_create_or_find_stub_sec): Add stub type parameter and
258         function description comment. Add support for dedicated output stub
259         section to given stub types.
260         (elf32_arm_add_stub): Add a stub type parameter and pass it down to
261         elf32_arm_create_or_find_stub_sec.
262         (elf32_arm_create_stub): Pass stub type down to elf32_arm_add_stub.
263         (elf32_arm_size_stubs): Pass stub type when calling
264         elf32_arm_create_or_find_stub_sec for Cortex-A8 erratum veneers.
265         (bfd_elf32_arm_keep_private_stub_output_sections): New function.
266
267 2016-05-20  H.J. Lu  <hongjiu.lu@intel.com>
268
269         * elf32-i386.c (elf_i386_check_relocs): Don't check R_386_GOT32
270         when setting need_convert_load.
271
272 2016-05-20  Maciej W. Rozycki  <macro@imgtec.com>
273
274         * elfxx-mips.c (mips_elf_read_rel_addend): Adjust the addend for
275         microMIPS JALX.
276
277 2016-05-19  H.J. Lu  <hongjiu.lu@intel.com>
278
279         PR ld/20117
280         * elf32-i386.c (elf_i386_convert_load_reloc): Don't check
281         R_386_GOT32X.
282         (elf_i386_convert_load): Don't convert R_386_GOT32.
283
284 2016-05-20  Alan Modra  <amodra@gmail.com>
285
286         PR gas/20118
287         * elf.c (elf_fake_sections): Set sh_entsize for SHT_INIT_ARRAY,
288         SHT_FINI_ARRAY, and SHT_PREINIT_ARRAY.
289
290 2016-05-19  Cupertino Miranda  <cmiranda@synopsys.com>
291
292         * elf32-arc.c (arc_elf_final_write_processing): Changed.
293         (debug_arc_reloc): Likewise.
294         (elf_arc_relocate_section): Likewise.
295         (elf_arc_check_relocs): Likewise.
296         (elf_arc_adjust_dynamic_symbol): Likewise.
297         (elf_arc_add_symbol_hook): Likewise.
298
299 2016-05-19  Maciej W. Rozycki  <macro@imgtec.com>
300
301         * config.bfd: Remove `am34-*-linux*' support.
302
303 2016-05-19  Alan Modra  <amodra@gmail.com>
304
305         * elf64-ppc.c (allocate_dynrelocs): Allocate got and other dynamic
306         relocs before plt relocs.
307
308 2016-05-19  Alan Modra  <amodra@gmail.com>
309
310         * elf64-ppc.c (ppc64_elf_branch_reloc): Check for NULL owner
311         before dereferencing.
312
313 2016-05-18  Nick Clifton  <nickc@redhat.com>
314
315         * po/sv.po: Updated Swedish translation.
316
317 2016-05-18  Alan Modra  <amodra@gmail.com>
318
319         * elf32-arm.c (elf32_arm_size_stubs): Free or cache local syms
320         for each BFD.  Don't goto error_ret_free_local from outside loop.
321
322 2016-05-17  Maciej W. Rozycki  <macro@imgtec.com>
323
324         * elf-s390-common.c (elf_s390_add_symbol_hook): Remove
325         STB_GNU_UNIQUE handling.
326         * elf32-arc.c (elf_arc_add_symbol_hook): Likewise.
327         * elf32-arm.c (elf32_arm_add_symbol_hook): Likewise.
328         * elf32-m68k.c (elf_m68k_add_symbol_hook): Likewise.
329         * elf32-ppc.c (ppc_elf_add_symbol_hook): Likewise.
330         * elf32-sparc.c (elf32_sparc_add_symbol_hook): Likewise.
331         * elf64-ppc.c (ppc64_elf_add_symbol_hook): Likewise.
332         * elf64-sparc.c (elf64_sparc_add_symbol_hook): Likewise.
333         * elf64-x86-64.c (elf_x86_64_add_symbol_hook): Likewise.
334         * elfxx-aarch64.c (_bfd_aarch64_elf_add_symbol_hook): Likewise.
335         * elfxx-mips.c (_bfd_mips_elf_add_symbol_hook): Likewise.
336         * elf32-i386.c (elf_i386_add_symbol_hook): Remove function.
337         (elf_backend_add_symbol_hook): Remove macro.
338         * elflink.c (elf_link_add_object_symbols): Set `has_gnu_symbols'
339         for STB_GNU_UNIQUE symbols.
340
341 2016-05-16  Maciej W. Rozycki  <macro@imgtec.com>
342
343         * elf32-v850.c (v850_elf_copy_notes): New function, factored out
344         from...
345         (v850_elf_copy_private_bfd_data): ... here.  Call the new
346         function and `_bfd_elf_copy_private_bfd_data'.
347
348 2016-05-13  H.J. Lu  <hongjiu.lu@intel.com>
349
350         PR ld/20093
351         * elf64-x86-64.c (elf_x86_64_convert_load_reloc): Don't convert
352         GOTPCREL relocation against large section.
353
354 2016-05-13  Alan Modra  <amodra@gmail.com>
355
356         * elf-m10300.c (_bfd_mn10300_elf_finish_dynamic_sections): Use
357         linker dynamic sections in calculating size and address of
358         dynamic tags rather than using output sections.  Remove asserts.
359         * elf32-arm.c (elf32_arm_finish_dynamic_sections): Likewise.
360         * elf32-cr16.c (_bfd_cr16_elf_finish_dynamic_sections): Likewise.
361         * elf32-cris.c (elf_cris_finish_dynamic_sections): Likewise.
362         * elf32-i370.c (i370_elf_finish_dynamic_sections): Likewise.
363         * elf32-lm32.c (lm32_elf_finish_dynamic_sections): Likewise.
364         * elf32-m32r.c (m32r_elf_finish_dynamic_sections): Likewise.
365         * elf32-m68k.c (elf_m68k_finish_dynamic_sections): Likewise.
366         * elf32-metag.c (elf_metag_finish_dynamic_sections): Likewise.
367         * elf32-microblaze.c (microblaze_elf_finish_dynamic_sections): Likewise.
368         * elf32-nds32.c (nds32_elf_finish_dynamic_sections): Likewise.
369         * elf32-nios2.c (nios2_elf32_finish_dynamic_sections): Likewise.
370         * elf32-or1k.c (or1k_elf_finish_dynamic_sections): Likewise.
371         * elf32-s390.c (elf_s390_finish_dynamic_sections): Likewise.
372         * elf32-score.c (s3_bfd_score_elf_finish_dynamic_sections): Likewise.
373         * elf32-score7.c (s7_bfd_score_elf_finish_dynamic_sections): Likewise.
374         * elf32-vax.c (elf_vax_finish_dynamic_sections): Likewise.
375         * elf32-xtensa.c (elf_xtensa_finish_dynamic_sections): Likewise.
376         * elf64-alpha.c (elf64_alpha_finish_dynamic_sections): Likewise.
377         * elf64-s390.c (elf_s390_finish_dynamic_sections): Likewise.
378         * elf64-sh64.c (sh64_elf64_finish_dynamic_sections): Likewise.
379         * elflink.c (bfd_elf_final_link): Likewise.
380         * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_sections): Likewise.
381         * elfxx-sparc.c (sparc_finish_dyn): Likewise.  Adjust error message.
382         * elf32-arc.c (GET_SYMBOL_OR_SECTION): Remove ASSERT arg and
383         don't set doit.  Look up dynobj section.
384         (elf_arc_finish_dynamic_sections): Adjust GET_SYMBOL_OR_SECTION
385         invocation and dynamic tag vma calculation.  Don't test
386         boolean var == TRUE.
387         * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_sections): Fix
388         DT_JMPREL calc.
389
390 2016-05-13  Alan Modra  <amodra@gmail.com>
391
392         * elflink.c (elf_link_sort_relocs): Wrap overlong lines.  Fix
393         octets_per_byte.  Put dynamic .rela.plt last in link orders.
394         Assign output_offset for reloc sections rather than writing
395         sorted relocs from block corresponding to output_offset.
396
397 2016-05-12  Alan Modra  <amodra@gmail.com>
398
399         * elf-bfd.h (elf_reloc_type_class): Put reloc_class_plt last.
400
401 2016-05-11  Andrew Bennett  <andrew.bennett@imgtec.com>
402
403         * elfxx-mips.c (print_mips_ases): Add DSPR3.
404
405 2016-05-11  Alan Modra  <amodra@gmail.com>
406
407         * elf32-hppa.c (elf32_hppa_init_stub_bfd): New function.
408         (elf32_hppa_check_relocs): Don't set dynobj.
409         (elf32_hppa_size_stubs): Test !SEC_LINKER_CREATED for stub sections.
410         (elf32_hppa_build_stubs): Likewise.
411         * elf32-hppa.h (elf32_hppa_init_stub_bfd): Declare.
412
413 2016-05-11  Alan Modra  <amodra@gmail.com>
414
415         PR 20060
416         * elf64-ppc.c (ppc64_elf_tls_setup): Clear forced_local.
417         * elf32-ppc.c (ppc_elf_tls_setup): Likewise.
418
419 2016-05-10  Jiong Wang  <jiong.wang@arm.com>
420
421         * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Remove redundant
422         aarch64_tls_transition check.
423
424 2016-05-10  Thomas Preud'homme  <thomas.preudhomme@arm.com>
425
426         * elf32-arm.c (enum elf32_arm_stub_type): New max_stub_type
427         enumerator.
428         (arm_stub_sym_claimed): New function.
429         (elf32_arm_create_stub): Use veneered symbol name and section if
430         veneer needs to claim its symbol, and keep logic unchanged otherwise.
431         (arm_stub_claim_sym): New function.
432         (arm_map_one_stub): Call arm_stub_claim_sym if veneer needs to claim
433         veneered symbol, otherwise create local symbol as before.
434
435 2016-05-10  Thomas Preud'homme  <thomas.preudhomme@arm.com>
436
437         * elf32-arm.c (elf32_arm_size_stubs): Use new macros
438         ARM_GET_SYM_BRANCH_TYPE and ARM_SET_SYM_BRANCH_TYPE to respectively get
439         and set branch type of a symbol.
440         (bfd_elf32_arm_process_before_allocation): Likewise.
441         (elf32_arm_relocate_section): Likewise and fix identation along the
442         way.
443         (allocate_dynrelocs_for_symbol): Likewise.
444         (elf32_arm_finish_dynamic_symbol): Likewise.
445         (elf32_arm_swap_symbol_in): Likewise.
446         (elf32_arm_swap_symbol_out): Likewise.
447
448 2016-05-10  Thomas Preud'homme  <thomas.preudhomme@arm.com>
449
450         * bfd-in.h (elf32_arm_size_stubs): Add an output section parameter.
451         * bfd-in2.h: Regenerated.
452         * elf32-arm.c (struct elf32_arm_link_hash_table): Add an output section
453         parameter to add_stub_section callback.
454         (elf32_arm_create_or_find_stub_sec): Get output section from link_sec
455         and pass it down to add_stub_section.
456         (elf32_arm_add_stub): Set section to stub_sec if NULL before using it
457         for error message.
458         (elf32_arm_size_stubs): Add output section parameter to
459         add_stub_section function pointer parameter.
460
461 2016-05-10  Thomas Preud'homme  <thomas.preudhomme@arm.com>
462
463         * elf32-arm.c (elf32_arm_create_stub): New function.
464         (elf32_arm_size_stubs): Use elf32_arm_create_stub for stub creation.
465
466 2016-05-10  Thomas Preud'homme  <thomas.preudhomme@arm.com>
467
468         * elf32-arm.c (enum elf32_arm_stub_type): Delete
469         arm_stub_a8_veneer_lwm enumerator.
470         (arm_stub_a8_veneer_lwm): New unsigned constant to replace
471         aforementioned enumerator.
472         (struct elf32_arm_stub_hash_entry): Delete target_addend
473         field and add source_value.
474         (struct a8_erratum_fix): Delete addend field and add target_offset.
475         (stub_hash_newfunc): Initialize source_value field amd remove
476         initialization for target_addend.
477         (arm_build_one_stub): Stop special casing Thumb relocations: promote
478         the else to being always executed, moving the
479         arm_stub_a8_veneer_b_cond specific code in it.  Remove
480         stub_entry->target_addend from points_to computation.
481         (cortex_a8_erratum_scan): Store in a8_erratum_fix structure the offset
482         to target symbol from start of section rather than the offset from the
483         stub address.
484         (elf32_arm_size_stubs): Set stub_entry's source_value and target_value
485         fields from struct a8_erratum_fix's offset and target_offset
486         respectively.
487         (make_branch_to_a8_stub): Rename target variable to loc.  Compute
488         veneered_insn_loc and loc using stub_entry's source_value.
489
490 2016-05-10  Thomas Preud'homme  <thomas.preudhomme@arm.com>
491
492         (elf32_arm_merge_eabi_attributes): Add merging logic for
493         Tag_DSP_extension.
494
495 2016-05-10  Pip Cet  <pipcet@gmail.com>
496
497         PR ld/20059
498         * elfxx-target.h (bfd_elfNN_bfd_copy_link_hash_symbol_type):
499         Define as _bfd_generic_copy_link_hash_symbol_type when using
500         generic hash table.
501
502 2016-05-09  Nick Clifton  <nickc@redhat.com>
503
504         PR binutils/20063
505         * elf.c (bfd_elf_get_elf_syms): Check for out of range sh_link
506         field before accessing sections array.
507
508 2016-05-09  Christophe Monat  <christophe.monat@st.com>
509
510         PR ld/20030
511         * elf32-arm.c (is_thumb2_vldm): Account for T1 (DP) encoding.
512         (stm32l4xx_need_create_replacing_stub): Rename ambiguous nb_regs
513         to nb_words.
514         (create_instruction_vldmia): Add is_dp to disambiguate SP/DP
515         encoding.
516         (create_instruction_vldmdb): Likewise.
517         (stm32l4xx_create_replacing_stub_vldm): is_dp detects DP encoding,
518         uses it to re-encode.
519
520 2016-05-09  Nick Clifton  <nickc@redhat.com>
521
522         PR 19938
523         * elf32-arm.c (elf32_arm_adjust_dynamic_symbol): Revert accidental
524         commit.
525
526 2016-05-09  Alan Modra  <amodra@gmail.com>
527
528         * elf64-ppc.c (ppc64_elf_init_stub_bfd): Remove redundant NULL check.
529
530 2016-05-06  H.J. Lu  <hongjiu.lu@intel.com>
531
532         PR ld/17550
533         * elf-bfd.h (elf_link_hash_entry): Update comments for indx,
534         documenting that indx == -3 if symbol is defined in a discarded
535         section.
536         * elflink.c (elf_link_add_object_symbols): Set indx to -3 if
537         symbol is defined in a discarded section.
538         (elf_link_output_extsym): Strip a global symbol defined in a
539         discarded section.
540
541 2016-05-06  H.J. Lu  <hongjiu.lu@intel.com>
542
543         * elf32-i386.c (elf_backend_add_symbol_hook): Defined for Intel
544         MCU.
545
546 2016-05-05  H.J. Lu  <hongjiu.lu@intel.com>
547
548         * elf32-i386.c (elf_i386_convert_load): Extract the GOT load
549         conversion to ...
550         (elf_i386_convert_load_reloc): This.  New function.
551         * elf64-x86-64.c (elf_x86_64_convert_load): Extract the GOT load
552         conversion to ...
553         (elf_x86_64_convert_load_reloc): This.  New function.
554
555 2016-05-05  H.J. Lu  <hongjiu.lu@intel.com>
556
557         * elf32-i386.c (elf_i386_check_tls_transition): Remove abfd.
558         Don't check if contents == NULL.
559         (elf_i386_tls_transition): Add from_relocate_section.  Check
560         from_relocate_section instead of contents != NULL.  Update
561         elf_i386_check_tls_transition call.
562         (elf_i386_check_relocs): Cache the section contents if
563         keep_memory is FALSE.  Pass FALSE as from_relocate_section to
564         elf_i386_tls_transition.
565         (elf_i386_relocate_section): Pass TRUE as from_relocate_section
566         to elf_i386_tls_transition.
567         (elf_backend_caches_rawsize): New.
568         * elf64-x86-64.c (elf_x86_64_check_tls_transition): Don't check
569         if contents == NULL.
570         (elf_x86_64_tls_transition): Add from_relocate_section.  Check
571         from_relocate_section instead of contents != NULL.
572         (elf_x86_64_check_relocs): Cache the section contents if
573         keep_memory is FALSE.  Pass FALSE as from_relocate_section to
574         elf_x86_64_tls_transition.
575         (elf_x86_64_relocate_section): Pass TRUE as from_relocate_section
576         to elf_x86_64_tls_transition.
577         (elf_backend_caches_rawsize): New.
578
579 2016-05-03  Maciej W. Rozycki  <macro@imgtec.com>
580
581         PR 10549
582         * elfxx-mips.c (_bfd_mips_elf_add_symbol_hook): Handle
583         STB_GNU_UNIQUE.
584
585 2016-05-03  Jiong Wang  <jiong.wang@arm.com>
586
587         * bfd-in.h (bfd_elf64_aarch64_set_options): Update prototype.
588         * bfd-in2.h (bfd_elf64_aarch64_set_options): Likewise.
589         * elfnn-aarch64.c (bfd_elfNN_aarch64_set_options): Initialize
590         no_apply_dynamic_relocs.
591         (elfNN_aarch64_final_link_relocate): Apply absolute relocations even though
592         dynamic relocations generated.
593
594 2016-04-29  H.J. Lu  <hongjiu.lu@intel.com>
595
596         * elf32-i386.c (elf_i386_size_dynamic_sections): Move interp
597         setting to ...
598         (elf_i386_create_dynamic_sections): Here.
599         * elf64-x86-64.c (elf_x86_64_size_dynamic_sections): Move
600         interp setting to ...
601         (elf_x86_64_create_dynamic_sections): Here.
602
603 2016-04-29  H.J. Lu  <hongjiu.lu@intel.com>
604
605         * elf32-i386.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Take GOT_RELOC
606         and replace (EH)->has_got_reloc with GOT_RELOC.
607         (elf_i386_fixup_symbol): Pass has_got_reloc to
608         UNDEFINED_WEAK_RESOLVED_TO_ZERO.
609         (elf_i386_allocate_dynrelocs): Likewise.
610         (elf_i386_relocate_section): Likewise.
611         (elf_i386_finish_dynamic_symbol): Likewise.
612         (elf_i386_convert_load): Pass TRUE to
613         UNDEFINED_WEAK_RESOLVED_TO_ZERO.
614         * elf64-x86-64.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Take
615         GOT_RELOC and replace (EH)->has_got_reloc with GOT_RELOC.
616         (elf_x86_64_fixup_symbol): Pass has_got_reloc to
617         UNDEFINED_WEAK_RESOLVED_TO_ZERO.
618         (elf_x86_64_allocate_dynrelocs): Likewise.
619         (elf_x86_64_relocate_section): Likewise.
620         (elf_x86_64_finish_dynamic_symbol): Likewise.
621         (elf_x86_64_convert_load): Pass TRUE to
622         UNDEFINED_WEAK_RESOLVED_TO_ZERO.
623
624 2016-04-29  H.J. Lu  <hongjiu.lu@intel.com>
625
626         * elf32-i386.c (check_relocs_failed): New.
627         (elf_i386_check_relocs): Set check_relocs_failed on error.
628         (elf_i386_relocate_section): Skip if check_relocs failed.
629
630 2016-04-29  H.J. Lu  <hongjiu.lu@intel.com>
631
632         * elf64-x86-64.c (elf_x86_64_check_relocs): Set
633         check_relocs_failed on error.
634
635 2016-04-29  Nick Clifton  <nickc@redhat.com>
636
637         PR 19938
638         * elf-bfd.h (struct elf_backend_data): Rename
639         elf_backend_set_special_section_info_and_link to
640         elf_backend_copy_special_section_fields.
641         * elfxx-target.h: Likewise.
642         * elf.c (section_match): Ignore the SHF_INFO_LINK flag when
643         comparing section flags.
644         (copy_special_section_fields): New function.
645         (_bfd_elf_copy_private_bfd_data): Copy the EI_ABIVERSION field.
646         Perform two scans over special sections.  The first one looks for
647         a direct mapping between the output section and an input section.
648         The second scan looks for a possible match based upon section
649         characteristics.
650         * elf32-arm.c (elf32_arm_copy_special_section_fields): New
651         function.  Handle setting the sh_link field of SHT_ARM_EXIDX
652         sections.
653         * elf32-i386.c (elf32_i386_set_special_info_link): Rename to
654         elf32_i386_copy_solaris_special_section_fields.
655         * elf32-sparc.c (elf32_sparc_set_special_section_info_link):
656         Rename to elf32_sparc_copy_solaris_special_section_fields.
657         * elf64-x86-64.c (elf64_x86_64_set_special_info_link): Rename to
658         elf64_x86_64_copy_solaris_special_section_fields.
659
660 2016-04-28  Nick Clifton  <nickc@redhat.com>
661
662         * po/zh_CN.po: Updated Chinese (simplified) translation.
663
664 2016-04-27  H.J. Lu  <hongjiu.lu@intel.com>
665
666         PR ld/20006
667         * elf64-x86-64.c (elf_x86_64_convert_load): Skip debug sections
668         when estimating distances between output sections.
669
670 2016-04-27  Alan Modra  <amodra@gmail.com>
671
672         * elflink.c (_bfd_elf_is_start_stop): New function.
673         (_bfd_elf_gc_mark_rsec): Use it.
674         * elf-bfd.h (_bfd_elf_is_start_stop): Declare.
675
676 2016-04-26  Trevor Saunders  <tbsaunde+binutils@tbsaunde.org>
677
678         * elf32-rx.c (rx_set_section_contents): Avoid arithmetic on void *.
679         * mmo.c (mmo_get_section_contents): Likewise.
680         (mmo_set_section_contents): Likewise.
681
682 2016-04-26  H.J. Lu  <hongjiu.lu@intel.com>
683
684         * elf-bfd.h (elf_link_hash_table): Update comments for
685         dynsymcount.
686         * elflink.c (_bfd_elf_link_renumber_dynsyms): Always count for
687         the unused NULL entry at the head of dynamic symbol table.
688         (bfd_elf_size_dynsym_hash_dynstr): Remove dynsymcount != 0
689         checks.
690
691 2016-04-21  H.J. Lu  <hongjiu.lu@intel.com>
692
693         * elflink.c (_bfd_elf_link_create_dynstrtab): Exclude linker
694         created file from dynobj.
695
696 2016-04-21  H.J. Lu  <hongjiu.lu@intel.com>
697
698         * elflink.c (_bfd_elf_link_create_dynstrtab): Set dynobj to a
699         normal input file if possible.
700
701 2016-04-21  Nick Clifton  <nickc@redhat.com>
702
703         * aout-adobe.c: Use _bfd_generic_link_check_relocs.
704         * aout-target.h: Likewise.
705         * aout-tic30.c: Likewise.
706         * binary.c: Likewise.
707         * bout.c: Likewise.
708         * coff-alpha.c: Likewise.
709         * coff-rs6000.c: Likewise.
710         * coff64-rs6000.c: Likewise.
711         * coffcode.h: Likewise.
712         * i386msdos.c: Likewise.
713         * i386os9k.c: Likewise.
714         * ieee.c: Likewise.
715         * ihex.c: Likewise.
716         * libbfd-in.h: Likewise.
717         * libecoff.h: Likewise.
718         * mach-o-target.c: Likewise.
719         * mmo.c: Likewise.
720         * nlm-target.h: Likewise.
721         * oasys.c: Likewise.
722         * pef.c: Likewise.
723         * plugin.c: Likewise.
724         * ppcboot.c: Likewise.
725         * som.c: Likewise.
726         * srec.c: Likewise.
727         * tekhex.c: Likewise.
728         * versados.c: Likewise.
729         * vms-alpha.c: Likewise.
730         * xsym.c: Likewise.
731         * elfxx-target.h: Use _bfd_elf_link_check_relocs.
732         * linker.c (bfd_link_check_relocs): New function.
733         (_bfd_generic_link_check_relocs): New function.
734         * targets.c (BFD_JUMP_TABLE_LINK): Add initialization of
735         _bfd_link_check_relocs field.
736         (struct bfd_target)L Add _bfd_link_check_relocs field.
737         * bfd-in2.h: Regenerate.
738         * libbfd.h: Regenerate.
739
740 2016-04-20  H.J. Lu  <hongjiu.lu@intel.com>
741
742         * elf32-i386.c (elf_i386_gc_sweep_hook): Removed.
743         (elf_backend_gc_sweep_hook): Likewise.
744         * elf64-x86-64.c (elf_x86_64_gc_sweep_hook): Likewise.
745         (elf_backend_gc_sweep_hook): Likewise.
746
747 2016-04-20  H.J. Lu  <hongjiu.lu@intel.com>
748
749         * elflink.c (_bfd_elf_link_check_relocs): Don't check relocations
750         in excluded sections
751
752 2016-04-20  H.J. Lu  <hongjiu.lu@intel.com>
753
754         PR ld/19969
755         * elf64-x86-64.c (check_relocs_failed): New.
756         (elf_x86_64_need_pic): Moved before elf_x86_64_check_relocs.
757         Support relocation agaist local symbol.  Set check_relocs_failed.
758         (elf_x86_64_check_relocs): Use elf_x86_64_need_pic.  Check
759         R_X86_64_32 relocation overflow.
760         (elf_x86_64_relocate_section): Skip if check_relocs failed.
761         Update one elf_x86_64_need_pic and remove one elf_x86_64_need_pic.
762
763 2016-04-20  H.J. Lu  <hongjiu.lu@intel.com>
764
765         * elf32-i386.c (elf_i386_check_relocs): Call
766         _bfd_elf_create_ifunc_sections only for STT_GNU_IFUNC symbol.
767         * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
768
769 2016-04-20  H.J. Lu  <hongjiu.lu@intel.com>
770
771         * elf-bfd.h (_bfd_elf_link_check_relocs): New.
772         * elflink.c (_bfd_elf_link_check_relocs): New function.
773         (elf_link_add_object_symbols): Call _bfd_elf_link_check_relocs
774         if check_relocs_after_open_input is FALSE.
775
776 2016-04-20  Trevor Saunders  <tbsaunde+binutils@tbsaunde.org>
777
778         * cache.c: Update old style function definitions.
779         * elf32-m68k.c: Likewise.
780         * elf64-mmix.c: Likewise.
781         * stab-syms.c: Likewise.
782
783 2016-04-20  Trevor Saunders  <tbsaunde+binutils@tbsaunde.org>
784
785         * elf32-arm.c (put_thumb2_insn): Change argument type to bfd_byte *.
786
787 2016-04-15  H.J. Lu  <hongjiu.lu@intel.com>
788
789         * Makefile.in: Regenerated with automake 1.11.6.
790         * aclocal.m4: Likewise.
791         * doc/Makefile.in: Likewise.
792
793 2016-04-14  Andrew Burgess  <andrew.burgess@embecosm.com>
794
795         * reloc.c: Add BFD_RELOC_ARC_NPS_CMEM16 entry.
796         * bfd-in2.h: Regenerate.
797         * libbfd.h: Regenerate.
798         * elf32-arc.c: Add 'opcode/arc.h' include.
799         (struct arc_relocation_data): Add symbol_name.
800         (arc_special_overflow_checks): New function.
801         (arc_do_relocation): Use arc_special_overflow_checks, reindent as
802         required, add an extra comment.
803         (elf_arc_relocate_section): Setup symbol_name in reloc_data.
804
805 2016-04-14  Andrew Burgess  <andrew.burgess@embecosm.com>
806
807         * elf32-arc.c (tls_got_entries): Add 'TLS_GOT_' prefix to all
808         entries.
809         (elf_arc_relocate_section): Update enum uses.
810         (elf_arc_check_relocs): Likewise.
811         (elf_arc_finish_dynamic_symbol): Likewise.
812
813 2016-04-14  H.J. Lu  <hongjiu.lu@intel.com>
814
815         * elf.c (_bfd_elf_copy_private_bfd_data): Replace "link" with
816         "sh_link".
817
818 2016-04-14  Nick Clifton  <nickc@redhat.com>
819
820         PR target/19938
821         * elf-bbfd.h (struct elf_backend_data): New field:
822         elf_strtab_flags.
823         New field: elf_backend_set_special_section_info_and_link
824         * elfxx-target.h (elf_backend_strtab_flags): Define if not already
825         defined.
826         (elf_backend_set_special_section_info_and_link): Define if not
827         already defined.
828         (elfNN_bed): Use elf_backend_set_special_section_info_and_link and
829         elf_backend_strtab_flags macros to initialise fields in structure.
830         * elf.c (_bfd_elf_make_section_from_shdr): Check for SHF_STRINGS
831         being set even if SHF_MERGE is not set.
832         (elf_fake_sections): Likewise.
833         (section_match): New function.  Matches two ELF sections based
834         upon fixed characteristics.
835         (find_link): New function.  Locates a section in a BFD that
836         matches a section in a different BFD.
837         (_bfd_elf_copy_private_bfd_data): Copy the sh_info and sh_link
838         fields of reserved sections.
839         (bfd_elf_compute_section_file_positions): Set the flags for the
840         .shstrtab section based upon the elf_strtab_flags field in the
841         elf_backend_data structure.
842         (swap_out_syms): Likewise for the .strtab section.
843         * elflink.c (bfd_elf_final_link): Set the flags for the
844         .strtab section based upon the elf_strtab_flags field in the
845         elf_backend_data structure.
846         * elf32-i386.c (elf32_i386_set_special_info_link): New function.
847         (elf_backend_strtab_flags): Set to SHF_STRINGS for Solaris
848         targets.
849         (elf_backend_set_special_section_info_and_link): Define for
850         Solaris targets.
851         * elf32-sparc.c: Likewise.
852         * elf64-x86-64.c: Likewise.
853
854 2016-04-11  H.J. Lu  <hongjiu.lu@intel.com>
855
856         PR ld/19939
857         * elf-bfd.h (_bfd_elf_allocate_ifunc_dyn_relocs): Add a pointer
858         to bfd_boolean.
859         * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Updated.
860         Set *readonly_dynrelocs_against_ifunc_p to TRUE if dynamic reloc
861         applies to read-only section.
862         * elf32-i386.c (elf_i386_link_hash_table): Add
863         readonly_dynrelocs_against_ifunc.
864         (elf_i386_allocate_dynrelocs): Updated.
865         (elf_i386_size_dynamic_sections): Issue an error for read-only
866         segment with dynamic IFUNC relocations only if
867         readonly_dynrelocs_against_ifunc is TRUE.
868         * elf64-x86-64.c (elf_x86_64_link_hash_table): Add
869         readonly_dynrelocs_against_ifunc.
870         (elf_x86_64_allocate_dynrelocs): Updated.
871         (elf_x86_64_size_dynamic_sections): Issue an error for read-only
872         segment with dynamic IFUNC relocations only if
873         readonly_dynrelocs_against_ifunc is TRUE.
874         * elfnn-aarch64.c (elfNN_aarch64_allocate_ifunc_dynrelocs):
875         Updated.
876
877 2016-04-06  Thomas Preud'homme  <thomas.preudhomme@arm.com>
878
879         * elf32-arm.c (elf32_arm_size_stubs): Move error_ret_free_local to be
880         a fall through from error_ret_free_internal.  Free local_syms in
881         error_ret_free_local if allocated from bfd_elf_get_elf_syms ().
882
883 2016-04-05  Cupertino Miranda  <cmiranda@synopsys.com>
884
885         * elf32-arc.c (plt_do_relocs_for_symbol): Changed.
886         (relocate_plt_for_entry): Likewise.
887
888 2016-04-05  Cupertino Miranda  <cmiranda@synopsys.com>
889
890         * elf32-arc.c (elf_arc_check_relocs): Changed
891
892 2016-04-05  Cupertino Miranda  <cmiranda@synopsys.com>
893
894         * elf32-arc.c (name_for_global_symbol): Changed assert.
895         (get_replace_function): Created.:
896         (struct arc_relocation_data): Changed to signed types.
897         (defines S, L, P, PDATA): Casted to signed type.
898         (defines SECTSTART, _SDA_BASE_, TLS_REL): Likewise.
899         (PRINT_DEBUG_RELOC_INFO_BEFORE): Changed.
900         (arc_do_relocation): Changed.
901
902 2016-04-05  Cupertino Miranda  <cmiranda@synopsys.com>
903
904         * elf32-arc.c (name_for_global_symbol): Added assert to check for
905         symbol index.
906         (elf_arc_relocate_section): Added and changed asserts, validating
907         the synamic symbol index.
908         (elf_arc_finish_dynamic_symbol): Do not fill the dynamic
909         relocation if symbol has dynindx set to -1.
910
911 2016-04-05  Maciej W. Rozycki  <macro@imgtec.com>
912
913         * elflink.c (elf_link_add_object_symbols): Always turn hidden
914         and internal symbols which have a dynamic index into local
915         ones.
916
917 2016-04-04  Nick Clifton  <nickc@redhat.com>
918
919         PR 19872
920         * dwarf2.c (parse_comp_unit): Skip warning about unrecognised
921         version number if the version is zero.
922
923 2016-04-01  Alan Modra  <amodra@gmail.com>
924
925         PR 19886
926         * elflink.c (on_needed_list): Recursively check needed status.
927         (elf_link_add_object_symbols): Adjust.
928
929 2016-03-30  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
930
931         * elf32-avr.c (avr_elf32_load_records_from_section): Free
932         internal_relocs only if they aren't cached.
933
934 2016-03-29  Nick Clifton  <nickc@redhat.com>
935
936         PR 17334
937         * elf32-bfin.c (elf32_bfinfdpic_finish_dynamic_sections): Relax
938         assertion on the size of the got section to allow it to be bigger
939         than the number of relocs.
940
941 2016-03-29  Toni Spets  <toni.spets@iki.fi>
942
943         PR 19878
944         * coffcode.h (coff_write_object_contents): Revert accidental
945         2014-11-10 change.
946
947 2016-03-22  Alan Modra  <amodra@gmail.com>
948
949         PR 19850
950         * dwarf2.c (read_attribute_value): Skip info_ptr check for
951         DW_FORM_flag_present.
952
953 2016-03-22  Nick Clifton  <nickc@redhat.com>
954
955         * cpu-v850_rh850.c (arch_info_struct): Restore v850-rh850 as an
956         architecture name for backwards compatibility.
957
958         * peXXigen.c (_bfd_XXi_write_codeview_record): Fix possible
959         unbounded stack use.
960
961         * warning.m4 (GCC_WARN_CFLAGS): Only add -Wstack-usage if using a
962         sufficiently recent version of GCC.
963         * configure: Regenerate.
964
965 2016-03-22  Alan Modra  <amodra@gmail.com>
966
967         PR 19851
968         * plugin.c (try_load_plugin): Avoid -Wstack-usage warning.
969
970 2016-03-21  Andrew Burgess  <andrew.burgess@embecosm.com>
971
972         * archures.c (bfd_mach_arc_nps400): Define.
973         * bfd-in2.h: Regenerate.
974         * cpu-arc.c (arch_info_struct): New entry for nps400, renumber
975         some existing entries to make space.
976         * elf32-arc.c (arc_elf_object_p): Add nps400 case.
977         (arc_elf_final_write_processing): Likewise.
978
979 2016-03-21  Andrew Burgess  <andrew.burgess@embecosm.com>
980
981         * elf32-arc.c (arc_elf_print_private_bfd_data): Remove use of
982         EF_ARC_CPU_GENERIC.
983         (arc_elf_final_write_processing): Don't bother setting cpu field
984         in e_flags, this will have been set elsewhere.
985
986 2016-03-21  Andrew Burgess  <andrew.burgess@embecosm.com>
987
988         * elf32-arc.c (arc_elf_final_write_processing): Switch to using
989         EF_ARC_MACH_MSK.
990
991 2016-03-21  Nick Clifton  <nickc@redhat.com>
992
993         * warning.m4 (GCC_WARN_CFLAGS): Add -Wstack-usage=262144
994         * configure: Regenerate.
995         * elf32-m68hc1x.c (elf32_m68hc11_relocate_section): Replace use of
996         alloca with call to xmalloc.
997         * elf32-nds32.c: Likewise.
998         * elf64-hppa.c: Likewise.
999         * elfxx-mips.c: Likewise.
1000         * pef.c: Likewise.
1001         * pei-x86_64.c: Likewise.
1002         * som.c: Likewise.
1003         * xsym.c: Likewise.
1004
1005 2016-03-15  H.J. Lu  <hongjiu.lu@intel.com>
1006
1007         PR ld/19827
1008         * elf32-i386.c (elf_i386_check_relocs): Bind defined symbol
1009         locally in PIE.
1010         (elf_i386_relocate_section): Likewise.
1011         * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
1012         (elf_x86_64_relocate_section): Likewise.
1013
1014 2016-03-15  H.J. Lu  <hongjiu.lu@intel.com>
1015
1016         PR ld/19807
1017         * elf64-x86-64.c (elf_x86_64_relocate_section): Check
1018         no_reloc_overflow_check to diable R_X86_64_32/R_X86_64_32S
1019         relocation overflow check.
1020
1021 2016-03-14  H.J. Lu  <hongjiu.lu@intel.com>
1022
1023         * bfd-in2.h: Regenerated.
1024
1025 2016-03-11  Dan Gissel  <dgisselq@ieee.org>
1026
1027         PR 19713
1028         * elf.c (_bfd_elf_section_offset): Ensure that the returned offset
1029         uses bytes not octets.
1030         * elflink.c (resolve_section): Likewise.
1031         Add a bfd parameter.
1032         (eval_section): Pass the input_bfd to resolve_section.
1033         (bfd_elf_perform_complex_relocation): Convert byte offset to
1034         octets before read and writing values.
1035         (elf_link_input_bfd): Add byte to octet conversions.
1036         (elf_reloc_link_order): Likewise.
1037         (elf_fixup_link_order): Likewise.
1038         (bfd_elf_final_link): Likewise.
1039         * reloc.c (_bfd_final_link_relocate): Likewise.
1040         * syms.c (_bfd_stab_section_find_nearest_line): Likewise.
1041
1042 2016-03-10  Nick Clifton  <nickc@redhat.com>
1043
1044         * config.bfd: Mark the i370 target as obsolete.
1045
1046 2016-03-09  Pedro Alves  <palves@redhat.com>
1047
1048         * cpu-v850.c (N): Append ":old-gcc-abi" instead of " (using old
1049         gcc ABI)" to printable name.
1050         * cpu-v850_rh850.c (bfd_v850_rh850_arch): Use "v850:rh850" instead
1051         of "v850-rh850" as printable name.
1052
1053 2016-03-09  Leon Winter  <winter-gcc@bfw-online.de>
1054
1055         PR ld/19623
1056         * cofflink.c (_bfd_coff_generic_relocate_section): Do not apply
1057         relocations against absolute symbols.
1058
1059 2016-03-09  Alan Modra  <amodra@gmail.com>
1060
1061         PR binutils/19775
1062         * coff-alpha.c (alpha_ecoff_openr_next_archived_file): Allow zero
1063         length elements in the archive.
1064
1065 2016-03-08  H.J. Lu  <hongjiu.lu@intel.com>
1066
1067         PR ld/19789
1068         * elflink.c (elf_link_add_object_symbols): Create dynamic sections
1069         for -E/--dynamic-list only when not relocatable.
1070
1071 2016-03-08  H.J. Lu  <hongjiu.lu@intel.com>
1072
1073         PR ld/19784
1074         * elf32-i386.c (elf_i386_check_relocs): Increment PLT reference
1075         count for locally defined local IFUNC symbols in shared object.
1076         * elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
1077
1078 2016-03-08  H.J. Lu  <hongjiu.lu@intel.com>
1079
1080         PR ld/19579
1081         * elflink.c (_bfd_elf_merge_symbol): Group common symbol checking
1082         together.
1083
1084 2016-03-08  Cupertino Miranda  <Cupertino.Miranda@synopsys.com>
1085             Andrew Burgess  <andrew.burgess@embecosm.com>
1086
1087         * elf32-arc.c (arc_bfd_get_32): Becomes an alias for bfd_get_32.
1088         (arc_bfd_put_32): Becomes an alias for bfd_put_32.
1089         (arc_elf_howto_init): Added assert to validate relocations.
1090         (get_middle_endian_relocation): Delete.
1091         (middle_endian_convert): New function.
1092         (ME): Redefine, now does nothing.
1093         (IS_ME): New define.
1094         (arc_do_relocation): Extend the attached 'ARC_RELOC_HOWTO'
1095         definition to call middle_endian_convert.  Add a new local
1096         variable and make use of this throughout. Added call to
1097         arc_bfd_get_8 and arc_bfd_put_8 for 8 bit relocations.
1098
1099 2016-03-07  Nick Clifton  <nickc@redhat.com>
1100
1101         PR binutils/19775
1102         * archive.c (bfd_generic_openr_next_archived_file): Allow zero
1103         length elements in the archive.
1104
1105 2016-03-07  Jiong Wang  <jiong.wang@arm.com>
1106
1107         * elfnn-aarch64.c (elfNN_aarch64_check_relocs): Always create .got
1108         section if the symbol "_GLOBAL_OFFSET_TABLE_" is referenced.
1109
1110 2016-03-04  H.J. Lu  <hongjiu.lu@intel.com>
1111
1112         PR ld/19579
1113         * elflink.c (_bfd_elf_merge_symbol): Treat common symbol in
1114         executable as definition if the new definition comes from a
1115         shared library.
1116
1117 2016-03-02  Alan Modra  <amodra@gmail.com>
1118
1119         * Makefile.in: Regenerate.
1120         * po/SRC-POTFILES.in: Regenerate.
1121
1122 2016-02-29  Cupertino Miranda  <cmiranda@synopsys.com>
1123
1124         * elf32-arc.c (elf_arc_relocate_section): Added rules to fix the
1125         relocation addend when sections get merged.
1126
1127 2016-02-29  Cupertino Miranda <Cupertino.Miranda@synopsys.com>
1128
1129         * elf32-arc.c (arc_elf_final_write_processing): Add condition to
1130         the flag change.
1131         (elf_arc_relocate_section): Fixes and conditions to support PIE.
1132         Assert for code sections dynamic relocs.
1133
1134 2016-02-26  Renlin Li  <renlin.li@arm.com>
1135
1136         * elfnn-aarch64.c (elfNN_aarch64_howto_table): Fix signed overflow
1137         check for MOVW_SABS_G0, MOVW_SABS_G1, MOVW_SABS_G2.
1138
1139 2016-02-26  H.J. Lu  <hongjiu.lu@intel.com>
1140
1141         PR ld/19609
1142         * elf32-i386.c (elf_i386_convert_load): Convert to R_386_32 for
1143         load with locally bound symbols if PIC is false or there is no
1144         base register.  Optimize branch to 0 if PIC is false.
1145         (elf_i386_relocate_section): Don't generate dynamic relocations
1146         against undefined weak symbols if PIC is false.
1147         * elf64-x86-64.c (elf_x86_64_convert_load): Disable optimization
1148         if we can't estimate relocation overflow with --no-relax.
1149         Convert to R_X86_64_32S/R_X86_64_32 for load with locally bound
1150         symbols if PIC is false.  Optimize branch to 0 if PIC is false.
1151         (elf_x86_64_relocate_section): Don't generate dynamic relocations
1152         against undefined weak symbols if PIC is false.
1153
1154 2016-02-26  H.J. Lu  <hongjiu.lu@intel.com>
1155
1156         PR ld/19645
1157         * bfd.c (bfd): Change flags to 20 bits.
1158         (BFD_CONVERT_ELF_COMMON): New.
1159         (BFD_USE_ELF_STT_COMMON): Likewise.
1160         (BFD_FLAGS_SAVED): Add BFD_CONVERT_ELF_COMMON and
1161         BFD_USE_ELF_STT_COMMON.
1162         (BFD_FLAGS_FOR_BFD_USE_MASK): Likewise.
1163         * configure.ac: Remove --enable-elf-stt-common.
1164         * elf.c (swap_out_syms): Choose STT_COMMON or STT_OBJECT for
1165         common symbol depending on BFD_CONVERT_ELF_COMMON and
1166         BFD_USE_ELF_STT_COMMON.
1167         * elfcode.h (elf_slurp_symbol_table): Set BSF_ELF_COMMON for
1168         STT_COMMON.
1169         * elflink.c (bfd_elf_link_mark_dynamic_symbol): Also check
1170         STT_COMMON.
1171         (elf_link_convert_common_type): New function.
1172         (elf_link_output_extsym): Choose STT_COMMON or STT_OBJECT for
1173         common symbol depending on BFD_CONVERT_ELF_COMMON and
1174         BFD_USE_ELF_STT_COMMON.  Set sym.st_info after sym.st_shndx.
1175         * elfxx-target.h (TARGET_BIG_SYM): Add BFD_CONVERT_ELF_COMMON
1176         and BFD_USE_ELF_STT_COMMON to object_flags.
1177         (TARGET_LITTLE_SYM): Likewise.
1178         * syms.c (BSF_KEEP_G): Renamed to ...
1179         (BSF_ELF_COMMON): This.
1180         * bfd-in2.h: Regenerated.
1181         * config.in: Likewise.
1182         * configure: Likewise.
1183
1184 2016-02-26  H.J. Lu  <hongjiu.lu@intel.com>
1185
1186         PR ld/19636
1187         PR ld/19704
1188         PR ld/19719
1189         * elf32-i386.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): New.
1190         (elf_i386_link_hash_entry): Add has_got_reloc and
1191         has_non_got_reloc.
1192         (elf_i386_link_hash_table): Add interp.
1193         (elf_i386_link_hash_newfunc): Initialize has_got_reloc and
1194         has_non_got_reloc.
1195         (elf_i386_copy_indirect_symbol): Copy has_got_reloc and
1196         has_non_got_reloc.
1197         (elf_i386_check_relocs): Set has_got_reloc and has_non_got_reloc.
1198         (elf_i386_fixup_symbol): New function.
1199         (elf_i386_pie_finish_undefweak_symbol): Likewise.
1200         (elf_i386_allocate_dynrelocs): Don't allocate space for dynamic
1201         relocations and discard relocations against resolved undefined
1202         weak symbols in executable.  Don't make resolved undefined weak
1203         symbols in executable dynamic.  Keep dynamic non-GOT/non-PLT
1204         relocation against undefined weak symbols in PIE.
1205         (elf_i386_size_dynamic_sections): Set interp to .interp section.
1206         (elf_i386_relocate_section): Don't generate dynamic relocations
1207         against resolved undefined weak symbols in PIE, except for
1208         R_386_PC32.
1209         (elf_i386_finish_dynamic_symbol): Keep PLT/GOT entries without
1210         dynamic PLT/GOT relocations for resolved undefined weak symbols.
1211         Don't generate dynamic relocation against resolved undefined weak
1212         symbol in executable.
1213         (elf_i386_finish_dynamic_sections): Call
1214         elf_i386_pie_finish_undefweak_symbol on all symbols in PIE.
1215         (elf_backend_fixup_symbol): New.
1216         * elf64-x86-64.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): New.
1217         (elf_x86_64_link_hash_entry): Add has_got_reloc and
1218         has_non_got_reloc.
1219         (elf_x86_64_link_hash_table): Add interp.
1220         (elf_x86_64_link_hash_newfunc): Initialize has_got_reloc and
1221         has_non_got_reloc.
1222         (elf_x86_64_copy_indirect_symbol): Copy has_got_reloc and
1223         has_non_got_reloc.
1224         (elf_x86_64_check_relocs): Set has_got_reloc and
1225         has_non_got_reloc.
1226         (elf_x86_64_fixup_symbol): New function.
1227         (elf_x86_64_pie_finish_undefweak_symbol): Likewise.
1228         (elf_x86_64_allocate_dynrelocs): Don't allocate space for dynamic
1229         relocations and discard relocations against resolved undefined
1230         weak symbols in executable.  Don't make resolved undefined weak
1231         symbols in executable dynamic.
1232         (elf_x86_64_size_dynamic_sections): Set interp to .interp section.
1233         (elf_x86_64_relocate_section): Check relocation overflow for
1234         dynamic relocations against unresolved weak undefined symbols.
1235         Don't generate dynamic relocations against resolved weak
1236         undefined symbols in PIE.
1237         (elf_x86_64_finish_dynamic_symbol): Keep PLT/GOT entries without
1238         dynamic PLT/GOT relocations for resolved undefined weak symbols.
1239         Don't generate dynamic relocation against resolved undefined weak
1240         symbol in executable.
1241         (elf_x86_64_finish_dynamic_sections): Call
1242         elf_x86_64_pie_finish_undefweak_symbol on all symbols in PIE.
1243         (elf_backend_fixup_symbol): New.
1244
1245 2016-02-26  Alan Modra  <amodra@gmail.com>
1246
1247         * elf64-ppc.c (create_linkage_sections): Create sfpr when
1248         save_restore_funcs, rest of sections when not relocatable.
1249         (ppc64_elf_init_stub_bfd): Always call create_linkage_sections.
1250         (sfpr_define): Define all symbols on emitted code.
1251         (ppc64_elf_func_desc_adjust): Adjust for sfpr now being created
1252         when relocatable.  Move sfpr_define loop earlier.
1253
1254 2016-02-24  H.J. Lu  <hongjiu.lu@intel.com>
1255
1256         * elf64-x86-64.c (elf_x86_64_need_pic): New function.
1257         (elf_x86_64_relocate_section): Use it.  Replace
1258         x86_64_elf_howto_table[r_type] with howto.
1259
1260 2016-02-24  H.J. Lu  <hongjiu.lu@intel.com>
1261
1262         PR ld/19698
1263         * elflink.c (bfd_elf_record_link_assignment): Set versioned if
1264         symbol version is unknown.
1265
1266 2016-02-24  H.J. Lu  <hongjiu.lu@intel.com>
1267
1268         * elf32-i386.c (elf_i386_allocate_dynrelocs): Set plt_got.offset
1269         to (bfd_vma) -1 when setting needs_plt to 0.
1270         * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Likewise.
1271
1272 2016-02-23  H.J. Lu  <hongjiu.lu@intel.com>
1273
1274         * elflink.c (bfd_elf_record_link_assignment): Check for shared
1275         library, instead of PIC, and don't check PDE when making linker
1276         assigned symbol dynamic.
1277
1278 2016-02-23  Faraz Shahbazker  <faraz.shahbazker@imgtec.com>
1279
1280         * bfd/elfxx-mips.c (_bfd_mips_post_process_headers): Increment
1281         ABIVERSION for non-executable stack.
1282
1283 2016-02-23  Rich Felker  <bugdal@aerifal.cx>
1284
1285         PR target/19516
1286         * elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol):
1287         Always produce a RELATIVE reloc for a local symbol.
1288
1289 2016-02-23  Hans-Peter Nilsson  <hp@axis.com>
1290
1291         Fix test-case ld-elf/pr19617b
1292         * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Don't
1293         discard unused non-function symbols when --dynamic-list-data.
1294
1295 2016-02-22  H.J. Lu  <hongjiu.lu@intel.com>
1296
1297         * elflink.c (_bfd_elf_link_renumber_dynsyms): Always create the
1298         dynsym section, even if it is empty, with dynamic sections.
1299
1300 2016-02-22  H.J. Lu  <hongjiu.lu@intel.com>
1301
1302         * syms.c: Remove BSF_COMMON from comments.
1303         * bfd-in2.h: Regenerated.
1304
1305 2016-02-22  Jiong Wang  <jiong.wang@arm.com>
1306
1307         * elfnn-aarch64. (aarch64_type_of_stub): Remove redundation calcuation
1308         for destination.  Remove useless function parameters.
1309         (elfNN_aarch64_size_stubs): Update parameters for aarch64_type_of_stub.
1310
1311 2016-02-19  Nick Clifton  <nickc@redhat.com>
1312
1313         PR ld/19629
1314         * aoutx.h (aout_link_add_symbols): Check for out of range string
1315         table offsets.
1316
1317         PR ld/19628
1318         * reloc.c (bfd_generic_get_relocated_section_contents): Stop
1319         processing if we encounter a reloc without an associated symbol.
1320
1321 2016-02-18  H.J. Lu  <hongjiu.lu@intel.com>
1322
1323         PR ld/19617
1324         * elflink.c (elf_link_add_object_symbols): Always create dynamic
1325         sections for -E/--dynamic-list.
1326
1327 2016-02-17  H.J. Lu  <hongjiu.lu@intel.com>
1328
1329         * elf64-x86-64.c (elf_backend_omit_section_dynsym): New.  Defined
1330         to bfd_true.
1331
1332 2016-02-16  Joseph Myers  <joseph@codesourcery.com>
1333
1334         * plugin.c (plugin_vec): Set match priority to 255.
1335         * format.c (bfd_check_format_matches) [BFD_SUPPORTS_PLUGINS]: When
1336         matching against the plugin vector, take priority from there not
1337         from TEMP.
1338
1339 2016-02-15  Nick Clifton  <nickc@redhat.com>
1340
1341         * elf-bfd.h (struct bfd_elf_special_section): Use unsigned values
1342         for length and type fields.  Use a signed value for the
1343         suffix_length field.
1344
1345 2016-02-10  H.J. Lu  <hongjiu.lu@intel.com>
1346
1347         PR ld/19601
1348         * elf32-i386.c (elf_i386_relocate_section): Mask off the least
1349         significant bit in GOT offset for R_386_GOT32X.
1350
1351 2016-02-10  Nick Clifton  <nickc@redhat.com>
1352
1353         PR 19405
1354         * elf32-nios2.c (nios2_elf32_install_imm16): Allow for signed
1355         immediate values.
1356         * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Limit the
1357         number of messages about FDE encoding preventing .eh_frame_hdr
1358         generation.
1359
1360 2016-02-09  Nick Clifton  <nickc@redhat.com>
1361
1362         * oasys.c (oasys_archive_p): Fix indentation.
1363         * elf32-nds32.c (nds32_elf_relax_section): Use an unsigned
1364         constant for left shifting.
1365
1366         * elfnn-aarch64.c (elfNN_aarch64_relocate_section): Add a more
1367         helpful warning message to explain why certain AArch64 relocs
1368         might overflow.
1369
1370 2016-02-05  Simon Marchi  <simon.marchi@ericsson.com>
1371
1372         * pe-mips.c (coff_mips_reloc): Fix formatting.
1373
1374 2016-02-05  Cupertino Miranda  <Cupertino.Miranda@synopsys.com>
1375
1376         * cpu-arc.c: Change default archure from bfd_mach_arc_arcv2
1377         to bfd_mach_arc_arc600.
1378
1379 2016-02-04  Alan Modra  <amodra@gmail.com>
1380
1381         * elf64-ppc.c (ppc64_elf_relocate_section): Adjust last patch
1382         for big-endian.
1383
1384 2016-02-02  H.J. Lu  <hongjiu.lu@intel.com>
1385
1386         PR ld/19542
1387         * elf64-x86-64.c (elf_x86_64_convert_load): Store the estimated
1388         distances in the compressed_size field of the output section.
1389
1390 2016-02-02  Alan Modra  <amodra@gmail.com>
1391
1392         * elf64-ppc.c (ppc64_elf_relocate_section): Further restrict
1393         ELFv2 entry optimization.
1394
1395 2016-02-02  H.J. Lu  <hongjiu.lu@intel.com>
1396
1397         PR binutils/19547
1398         * elf.c (assign_section_numbers): Clear HAS_RELOC if there are
1399         no relocations in relocatable files.
1400
1401 2016-02-01  H.J. Lu  <hongjiu.lu@intel.com>
1402
1403         PR ld/19553
1404         * elflink.c (elf_link_add_object_symbols): Don't add DT_NEEDED
1405         if a symbol from a library loaded via DT_NEEDED doesn't match
1406         the symbol referenced by regular object.
1407
1408 2016-02-01  Nathaniel Smith  <njs@pobox.com>
1409
1410         * peicode.h (pe_ILF_build_a_bfd): Create an import symbol for both
1411         CODE and DATA.
1412
1413 2016-02-01  Alan Modra  <amodra@gmail.com>
1414
1415         * elf64-x86-64.c (elf_x86_64_get_plt_sym_val): Don't abort on
1416         an out of range reloc_index.
1417         * elf32-i386.c (elf_i386_get_plt_sym_val): Likewise.
1418
1419 2016-02-01  Kamil Rytarowski  <n54@gmx.com>
1420
1421         * Makefile.am (OPTIONAL_BACKENDS): Add netbsd-core.lo.
1422         (OPTIONAL_BACKENDS_CFILES): Add netbsd-core.c.
1423         * Makefile.in: Regenerated.
1424
1425 2016-02-01  Jan Kratochvil  <jan.kratochvil@redhat.com>
1426
1427         * elf64-s390.c (elf_s390_reloc_name_lookup): Fix indentation.
1428
1429 2016-01-31  John David Anglin  <danglin@gcc.gnu.org>
1430
1431         PR ld/19526
1432         * elf32-hppa.c (elf32_hppa_final_link): Don't sort non-regular output
1433         files.
1434         * elf64-hppa.c (elf32_hppa_final_link): Likewise.  Remove retval.
1435
1436 2016-01-30  H.J. Lu  <hongjiu.lu@intel.com>
1437
1438         PR ld/19539
1439         * elf32-i386.c (elf_i386_reloc_type_class): Check relocation
1440         against STT_GNU_IFUNC symbol only with dynamic symbols.
1441         * elf64-x86-64.c (elf_x86_64_reloc_type_class): Likewise.
1442
1443 2016-01-28  H.J. Lu  <hongjiu.lu@intel.com>
1444
1445         PR binutils/19523
1446         * dwarf2.c (_bfd_dwarf2_slurp_debug_info): Set BFD_DECOMPRESS to
1447         decompress debug sections.
1448
1449 2016-01-25  Maciej W. Rozycki  <macro@imgtec.com>
1450
1451         * elf32-arc.c (elf_arc_finish_dynamic_symbol): Rename `index' to
1452         `dynindx'.
1453
1454 2016-01-25  Nick Clifton  <nickc@redhat.com>
1455
1456         PR target/19435
1457         * mach-o.c (bfd_mach_o_close_and_cleanup): Suppress code to free
1458         dsym filename buffer.
1459
1460 2016-01-24  Maciej W. Rozycki  <macro@imgtec.com>
1461
1462         * elfxx-mips.c (BZ16_REG_FIELD): Simplify calculation.
1463
1464 2016-01-24  Maciej W. Rozycki  <macro@imgtec.com>
1465
1466         * elfxx-mips.c (BZ16_REG): Correct calculation.
1467
1468 2016-01-21  Nick Clifton  <nickc@redhat.com>
1469
1470         * elf32-arc.c (ADD_RELA): Fix compile time warning errors by
1471         changing the type of _loc to be bfd_byte *.
1472         (elf_arc_finish_dynamic_symbol): Likewise.
1473
1474 2016-01-21  Nick Clifton  <nickc@redhat.com>
1475
1476         PR ld/19455
1477         * elf32-arm.c (elf32_arm_create_dynamic_sections): Set the ELF
1478         class of the linker stub bfd.
1479         (elf32_arm_check_relocs): Skip check for pic format after
1480         processing a vxWorks R_ARM_ABS12 reloc.
1481         * elflink.c (bfd_elf_final_link): Check for ELFCLASSNONE when
1482         reporting a class mismatch.
1483
1484 2016-01-21  Jiong Wang  <jiong.wang@arm.com>
1485
1486         * elfnn-aarch64.c (aarch64_type_of_stub): Allow insert long branch
1487         veneer for sym_sec != input_sec.
1488         (elfNN_aarch64_size_stub): Support STT_SECTION symbol.
1489         (elfNN_aarch64_final_link_relocate): Take rela addend into account when
1490         calculation destination.
1491
1492 2016-01-21  Alan Modra  <amodra@gmail.com>
1493
1494         * elf-linux-core.h (swap_linux_prpsinfo32_out): New function.
1495         (swap_linux_prpsinfo64_out): New function.
1496         (LINUX_PRPSINFO32_SWAP_FIELDS): Delete.
1497         (LINUX_PRPSINFO64_SWAP_FIELDS): Delete.
1498         * elf.c (elfcore_write_linux_prpsinfo32): Adjust.  Don't memset.
1499         (elfcore_write_linux_prpsinfo64): Likewise.
1500         * elf32-ppc.c (swap_ppc_linux_prpsinfo32_out): New function.
1501         (PPC_LINUX_PRPSINFO32_SWAP_FIELDS): Delete.
1502         (elfcore_write_ppc_linux_prpsinfo32): Adjust.  Don't memset.
1503
1504 2016-01-21  Alan Modra  <amodra@gmail.com>
1505
1506         * elf-linux-core.h: Rename from elf-linux-psinfo.h.
1507         * elf.c: Adjust #include.
1508         * elf32-ppc.c: Don't #include elf-linux-psinfo.h
1509         * Makefile.am (SOURCE_HFILES): Update.
1510         * Makefile.in: Regenerate.
1511         * po/SRC-PORFILES.in: Regenerate.
1512
1513 2016-01-21  Alan Modra  <amodra@gmail.com>
1514
1515         * configure.ac: Move corefile selection later in file.  Move
1516         tdefaults code immediately after other target vector code.
1517         * configure: Regenerate.
1518
1519 2016-01-20  Mickael Guene  <mickael.guene@st.com>
1520
1521         * elf32-arm.c (elf32_arm_special_sections): Remove catch of noread
1522         section using '.text.noread' pattern.
1523
1524 2016-01-19  John Baldwin  <jhb@FreeBSD.org>
1525
1526         * elf.c (elfcore_grok_note): Recognize NT_FREEBSD_THRMISC notes.
1527
1528 2016-01-18  Miranda Cupertino  <Cupertino.Miranda@synopsys.com>
1529             Zissulescu Claudiu  <Claudiu.Zissulescu@synopsys.com>
1530
1531         * arc-plt.def: New file.
1532         * arc-plt.h: Likewise.
1533         * elf32-arc.c (elf_arc_abs_plt0_entry, elf_arc_abs_pltn_entry,
1534                        elf_arcV2_abs_plt0_entry, elf_arcV2_abs_pltn_entry,
1535                        elf_arc_pic_plt0_entry, elf_arc_pic_pltn_entry,
1536                        elf_arcV2_pic_plt0_entry, elf_arcV2_pic_pltn_entry): Remove.
1537         (name_for_global_symbol): Added.
1538         (ADD_RELA): Helper to create dynamic relocs.
1539         (new_got_entry_to_list): Create a new got entry in linked list.
1540         (symbol_has_entry_of_type): Search for specific type of entry in
1541         list.
1542         (is_reloc_for_GOT): return FALSE for any TLS related relocs.
1543         (is_reloc_for_TLS, arc_elf_set_private_flags)
1544         (arc_elf_print_private_bfd_data, arc_elf_copy_private_bfd_data)
1545         (arc_elf_merge_private_bfd_data): New functions.
1546         (debug_arc_reloc): Cleaned debug info printing.
1547         (PDATA reloc): Changed not to perform address alignment.
1548         (reverse_me): Added. Fix for ARC_32 relocs.
1549         (arc_do_relocation): Return bfd_reloc_of when no relocation should
1550         occur.
1551         (arc_get_local_got_ents): Renamed from arc_get_local_got_offsets.
1552         Changed function to access an array of list of GOT entries instead
1553         of just an array of offsets.
1554         (elf_arc_relocate_section): Added support for PIC and TLS related relocations.
1555         (elf_arc_check_relocs): Likewise.
1556         (elf_arc_adjust_dynamic_symbol, elf_arc_finish_dynamic_symbol,
1557         (elf_arc_finish_dynamic_sections): Likewise
1558         (arc_create_dynamic_sections): Modified conditions to create
1559         dynamic sections.
1560         (ADD_SYMBOL_REF_SEC_AND_RELOC): New macro.
1561         (plt_do_relocs_for_symbol, relocate_plt_for_symbol)
1562         (relocate_plt_for_entry): Changed to support new way to define PLT
1563         related code.
1564         (add_symbol_to_plt): Likewise.
1565         (arc_elf_link_hash_table_create): New function.
1566
1567 2016-01-18  Nick Clifton  <nickc@redhat.com>
1568
1569         PR ld/19440
1570         * coff-rs6000.c (_bfd_xcoff_swap_sym_in): Sign extend external
1571         section number into internal section number.
1572         * coff64-rs6000.c (_bfd_xcoff64_swap_sym_in): Likewise.
1573         * coffswap.h (coff_swap_sym_in): Likewise.
1574         * peXXigen.c (_bfd_XXi_swap_sym_in): Likewise.
1575         * coffcode.h (_coff_bigobj_swap_sym_in): Make sure that internal
1576         section number field is big enough to hold the external value.
1577
1578 2016-01-17  Alan Modra  <amodra@gmail.com>
1579
1580         * configure: Regenerate.
1581
1582 2016-01-12  Yury Usishchev  <y.usishchev@samsung.com>
1583
1584         * elf32-arm.c (elf32_arm_fix_exidx_coverage): Insert cantunwind
1585         when address in first unwind entry does not match start of
1586         section.
1587
1588 2016-01-08  Richard Sandiford  <richard.sandiford@arm.com>
1589             Jiong Wang  <jiong.wang@arm.com>
1590
1591         PR ld/19368
1592         * elf32-arm.c (elf32_arm_reloc_type_class): Map R_ARM_IRELATIVE to
1593         reloc_class_ifunc.
1594
1595 2016-01-06  Andrew Burgess  <andrew.burgess@embecosm.com>
1596
1597         * elf32-arc.c (reloc_type_to_name): Change ARC_RELOC_HOWTO to
1598         place 'R_' before the reloc name returned.
1599         (elf_arc_howto_table): Change ARC_RELOC_HOWTO to place 'R_' before
1600         the relocation string.
1601
1602 2016-01-04  Maciej W. Rozycki  <macro@imgtec.com>
1603
1604         * elfxx-mips.c (mips_elf_merge_obj_abiflags): New function,
1605         factored out from...
1606         (_bfd_mips_elf_merge_private_bfd_data): ... here.
1607
1608 2016-01-04  Maciej W. Rozycki  <macro@imgtec.com>
1609
1610         * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Move
1611         attribute check after ELF file header flag check.
1612
1613 2016-01-04  Maciej W. Rozycki  <macro@imgtec.com>
1614
1615         * elfxx-mips.c (mips_elf_merge_obj_attributes): Propagate the
1616         return status from `_bfd_elf_merge_object_attributes'.
1617
1618 2016-01-04  Maciej W. Rozycki  <macro@imgtec.com>
1619
1620         * elfxx-mips.c (mips_elf_merge_obj_e_flags): New function,
1621         factored out from...
1622         (_bfd_mips_elf_merge_private_bfd_data): ... here.
1623
1624 2016-01-04  Maciej W. Rozycki  <macro@imgtec.com>
1625
1626         * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Fold the
1627         handling of input MIPS ABI flags together.
1628
1629 2016-01-04  Maciej W. Rozycki  <macro@imgtec.com>
1630
1631         * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Suppress
1632         attribute checks for null input.
1633
1634 2016-01-04  Maciej W. Rozycki  <macro@imgtec.com>
1635
1636         * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Use local
1637         pointers to target data.
1638
1639 2016-01-04  Maciej W. Rozycki  <macro@imgtec.com>
1640
1641         * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Correct
1642         an FP ABI warning.
1643
1644 2016-01-01  Alan Modra  <amodra@gmail.com>
1645
1646         Update year range in copyright notice of all files.
1647
1648 For older changes see ChangeLog-2015 and doc/ChangeLog-0415
1649 \f
1650 Copyright (C) 2016 Free Software Foundation, Inc.
1651
1652 Copying and distribution of this file, with or without modification,
1653 are permitted in any medium without royalty provided the copyright
1654 notice and this notice are preserved.
1655
1656 Local Variables:
1657 mode: change-log
1658 left-margin: 8
1659 fill-column: 74
1660 version-control: never
1661 End: