x86: Suggest -fPIE when not building shared object
[external/binutils.git] / bfd / ChangeLog
1 2019-04-17  H.J. Lu  <hongjiu.lu@intel.com>
2
3         * elf64-x86-64.c (elf_x86_64_need_pic): Suggest -fPIE when not
4         building shared object.
5         * elfxx-x86.c (_bfd_x86_elf_size_dynamic_sections): Likewise.
6
7 2019-04-17  H.J. Lu  <hongjiu.lu@intel.com>
8
9         PR ld/24458
10         * elfxx-x86.h (SYMBOL_DEFINED_NON_SHARED_P): Also check x86
11         linker_def.
12
13 2019-04-15  Thomas Preud'homme  <thomas.preudhomme@arm.com>
14
15         * reloc.c (BFD_RELOC_ARM_T32_VLDR_VSTR_OFF_IMM): New internal
16         relocation.
17         * bfd-in2.h: Regenerate.
18         * libbfd.h: Likewise.
19
20 2019-04-15  Sudakshina Das  <sudi.das@arm.com>
21
22         * reloc.c (BFD_RELOC_ARM_THUMB_LOOP12): New.
23         * bfd-in2.h: Regenerated.
24         * libbfd.h: Regenerated.
25
26 2019-04-15  Sudakshina Das  <sudi.das@arm.com>
27
28         * reloc.c (BFD_RELOC_THUMB_PCREL_BFCSEL): New relocation.
29         * bfd-in2.h: Regenerated.
30         * libbfd.h: Likewise.
31
32 2019-04-15  Sudakshina Das  <sudi.das@arm.com>
33
34         * reloc.c (BFD_RELOC_ARM_THUMB_BF13): New.
35         * bfd-in2.h: Regenerated.
36         * libbfd.h: Regenerated.
37         * elf32-arm.c (elf32_arm_howto_table_1): New entry for R_ARM_THM_BF13.
38         (elf32_arm_reloc_map elf32_arm_reloc_map): Map BFD_RELOC_ARM_THUMB_BF13
39         and R_ARM_THM_BF12 together.
40         (elf32_arm_final_link_relocate): New switch case for R_ARM_THM_BF13.
41
42 2019-04-15  Sudakshina Das  <sudi.das@arm.com>
43
44         * reloc.c (BFD_RELOC_ARM_THUMB_BF19): New
45         * libbfd.h: Regenerated.
46         * bfd-in2.h: Regenerated.
47         * bfd-elf32-arm.c (elf32_arm_howto_table_1): New entry for R_ARM_THM_BF18.
48         (elf32_arm_reloc_map elf32_arm_reloc_map): Map BFD_RELOC_ARM_THUMB_BF19
49         and R_ARM_THM_BF18 together.
50         (elf32_arm_final_link_relocate): New switch case for R_ARM_THM_BF19.
51
52 2019-04-15  Sudakshina Das  <sudi.das@arm.com>
53
54         * reloc.c (BFD_RELOC_ARM_THUMB_BF17): New enum.
55         * bfd-in2.h: Regenerated.
56         * libbfd.h: Regenerated.
57         * bfd-elf32-arm.c (elf32_arm_howto_table_1): New entry for R_ARM_THM_BF16.
58         (elf32_arm_reloc_map elf32_arm_reloc_map): Map BFD_RELOC_ARM_THUMB_BF17
59         and R_ARM_THM_BF16 together.
60         (get_value_helper): New reloc helper.
61         (elf32_arm_final_link_relocate): New switch case for R_ARM_THM_BF16.
62
63 2019-04-15  Sudakshina Das  <sudi.das@arm.com>
64
65         * reloc.c (BFD_RELOC_THUMB_PCREL_BRANCH5): New enum.
66         * bfd-in2.h: Regenerate.
67         * libbfd.h: Regenerate.
68
69 2019-04-15  Thomas Preud'homme  <thomas.preudhomme@arm.com>
70
71         * archures.c (bfd_mach_arm_8_1M_MAIN): Define.
72         * bfd-in2.h: Regenerate.
73         * cpu-arm.c (arch_info_struct): Add entry for Armv8.1-M Mainline.
74         * elf32-arm.c (using_thumb_only): Return true for Armv8.1-M Mainline
75         and update assert.
76         (using_thumb2): Likewise.
77         (using_thumb2_bl): Update assert.
78         (arch_has_arm_nop): Likewise.
79         (bfd_arm_get_mach_from_attributes): Add case for Armv8.1-M Mainline.
80         (tag_cpu_arch_combine): Add logic for Armv8.1-M Mainline merging.
81
82 2019-04-11  H.J. Lu  <hongjiu.lu@intel.com>
83
84         * elf-linker-x86.h (elf_x86_cet_report): New.
85         (elf_linker_x86_params): Add cet_report.
86         * elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Report
87         missing IBT and SHSTK properties if needed.
88
89 2019-04-11  H.J. Lu  <hongjiu.lu@intel.com>
90
91         PR ld/24436
92         * elf-m10300.c (mn10300_elf_check_relocs): Remove BFD_ASSERT of
93         "h != NULL".  Don't check "h != NULL" before calling.
94         bfd_elf_gc_record_vtentry.
95         * elf32-arm.c (elf32_arm_check_relocs): Likewise.
96         * elf32-bfin.c (bfin_check_relocs): Likewise.
97         * elf32-cris.c (cris_elf_check_relocs): Likewise.
98         * elf32-csky.c (csky_elf_check_relocs): Likewise.
99         * elf32-d10v.c (elf32_d10v_check_relocs): Likewise.
100         * elf32-dlx.c (elf32_dlx_check_relocs): Likewise.
101         * elf32-fr30.c (fr30_elf_check_relocs): Likewise.
102         * elf32-frv.c (elf32_frv_check_relocs): Likewise.
103         * elf32-hppa.c (elf32_hppa_check_relocs): Likewise.
104         * elf32-i386.c (elf_i386_check_relocs): Likewise.
105         * elf32-iq2000.c (iq2000_elf_check_relocs): Likewise.
106         * elf32-m32r.c (m32r_elf_check_relocs): Likewise.
107         * elf32-m68hc1x.c (elf32_m68hc11_check_relocs): Likewise.
108         * elf32-m68k.c (elf_m68k_check_relocs): Likewise.
109         * elf32-mcore.c (mcore_elf_check_relocs): Likewise.
110         * elf32-metag.c (elf_metag_check_relocs): Likewise.
111         * elf32-or1k.c (or1k_elf_check_relocs): Likewise.
112         * elf32-ppc.c (ppc_elf_check_relocs): Likewise.
113         * elf32-s390.c (elf_s390_check_relocs): Likewise.
114         * elf32-sh.c (sh_elf_check_relocs): Likewise.
115         * elf32-v850.c (v850_elf_check_relocs): Likewise.
116         * elf32-vax.c (elf_vax_check_relocs): Likewise.
117         * elf32-xstormy16.c (xstormy16_elf_check_relocs): Likewise.
118         * elf32-xtensa.c (elf_xtensa_check_relocs): Likewise.
119         * elf64-mmix.c (mmix_elf_check_relocs): Likewise.
120         * elf64-ppc.c (ppc64_elf_check_relocs): Likewise.
121         * elf64-s390.c (elf_s390_check_relocs): Likewise.
122         * elf64-x86-64.c (elf_s390_check_relocs): Likewise.
123         * elfxx-mips.c (_bfd_mips_elf_check_relocs): Likewise.
124         * elfxx-sparc.c (_bfd_sparc_elf_check_relocs): Likewise.
125         * elflink.c (bfd_elf_gc_record_vtinherit): Check for corrupt
126         VTENTRY entry.
127
128 2019-04-11  Alan Modra  <amodra@gmail.com>
129
130         PR 24435
131         * elflink.c (elf_link_add_object_symbols): Don't read partial
132         dynamic entries from fuzzed objects.
133
134 2019-04-11  Tamar Christina  <tamar.christina@arm.com>
135
136         PR ld/24302
137         * elfnn-aarch64.c (elfNN_aarch64_size_dynamic_sections): Don't emit
138         DT_TLSDESC_GOT and DT_TLSDESC_PLT when DF_BIND_NOW.
139         (elfNN_aarch64_finish_dynamic_sections): Don't write PLT if DF_BIND_NOW.
140
141 2019-04-10  Michael Forney  <mforney@mforney.org>
142
143         PR 24427
144         * doc/chew.c (free_words): Correctly free "push_text" strings.
145
146 2019-04-08  H.J. Lu  <hongjiu.lu@intel.com>
147
148         * config.bfd: Remove i[3-7]86-*-kaos* and i[3-7]86-*-chaos targets.
149
150 2019-04-08  Alan Modra  <amodra@gmail.com>
151
152         * configure.ac (elfxx_x86): Define and use.
153         * configure: Regenerate.
154
155 2019-04-06  H.J. Lu  <hongjiu.lu@intel.com>
156
157         * elf-linker-x86.h: New file.
158         * elf32-i386.c (elf_i386_convert_load_reloc): Use htab->params
159         to get x86-specific linker options.
160         * elf64-x86-64.c (elf_x86_64_convert_load_reloc): Likewise.
161         (elf_x86_64_check_relocs): Likewise.
162         (elf_x86_64_relocate_section): Likewise.
163         (elf_x86_64_link_setup_gnu_properties): Likewise.
164         * elfxx-x86.c (_bfd_x86_elf_merge_gnu_properties): Likewise.
165         (_bfd_x86_elf_link_setup_gnu_properties): Likewise.
166         (_bfd_elf_linker_x86_set_options): New function.
167         * elfxx-x86.h: Include "elf-linker-x86.h".
168         (elf_x86_link_hash_table): Add params.
169
170 2019-04-03  Alan Modra  <amodra@gmail.com>
171
172         * coff-i386.c, * coff-x86_64.c, * coffgen.c, * dwarf2.c,
173         * elf-m10200.c, * elf.c, * elf32-arm.c, * elf32-bfin.c,
174         * elf32-csky.c, * elf32-m32r.c, * elf32-microblaze.c, * elf32-pru.c,
175         * elf32-rx.c, * elf32-xgate.c, * elf64-sparc.c, * elfnn-ia64.c,
176         * elfxx-riscv.c, * elfxx-sparc.c, * linker.c, * mach-o.c,
177         * pe-x86_64.c, * pei-x86_64.c, * plugin.c: Whitespace fixes.
178
179 2019-04-02  Jim Wilson  <jimw@sifive.com>
180
181         PR 24389
182         * elfnn-riscv.c (_bfd_riscv_elf_merge_private_bfd_data): Move read of
183         ELF header flags to after check for ELF object file.  Loop through
184         sections looking for code sections, if none, then skip ABI checks.
185
186 2019-03-30  Andrew Waterman  <andrew@sifive.com>
187
188         * elfnn-riscv.c (_bfd_riscv_relax_call): Only check ARCH_SIZE for
189         rd == X_RA case.
190
191 2019-03-29  Max Filippov  <jcmvbkbc@gmail.com>
192
193         * elf32-xtensa.c (shrink_dynamic_reloc_sections): Add
194         info->export_dynamic to the conditional.
195
196 2019-03-28  Alan Modra  <amodra@gmail.com>
197
198         PR 24392
199         * configure.ac: Invoke AC_CHECK_SIZEOF(int).
200         * configure: Regenerate.
201         * coffgen.c (coff_get_reloc_upper_bound): Replace gcc diagnostic
202         workaround with SIZEOF_LONG vs. SIZEOF_INT check.
203         * elf.c (_bfd_elf_get_reloc_upper_bound): Likewise.
204         * elf64-sparc.c (elf64_sparc_get_reloc_upper_bound): Likewise.
205         * mach-o.c (bfd_mach_o_get_reloc_upper_bound): Likewise.
206
207 2019-03-21  Jim Wilson  <jimw@sifive.com>
208
209         PR 24365
210         * elfnn-riscv.c (riscv_elf_relocate_section): For STT_SECTION check,
211         verify sym non-NULL before using.  Add identical check using h.
212
213 2019-03-21  Sudakshina Das  <sudi.das@arm.com>
214
215         * elf-bfd.h (struct elf_backend_data): Add argument to
216         merge_gnu_properties.
217         * elf-properties.c (elf_merge_gnu_properties): Add argument to
218         itself and while calling bed->merge_gnu_properties.
219         (elf_merge_gnu_property_list): Update the calls for
220         elf_merge_gnu_properties.
221         * elfnn-aarch64.c (elfNN_aarch64_merge_gnu_properties): Update handling
222         of --force-bti warning and add argument.
223         * elfxx-aarch64.c (_bfd_aarch64_elf_link_setup_gnu_properties): Add
224         warning.
225         * elfxx-x86.c (_bfd_x86_elf_merge_gnu_properties): Add argument.
226         * elfxx-x86.h (_bfd_x86_elf_merge_gnu_properties): Likewise in
227         declaration.
228
229 2019-03-20  Sudakshina Das  <sudi.das@arm.com>
230
231         * elfxx-aarch64.c (_bfd_aarch64_elf_link_fixup_gnu_properties): Define.
232         * elfxx-aarch64.h (_bfd_aarch64_elf_link_fixup_gnu_properties): Declare.
233         (elf_backend_fixup_gnu_properties): Define for AArch64.
234
235 2019-03-18  Alan Modra  <amodra@gmail.com>
236
237         PR 24355
238         * elf32-ppc.c (ppc_finish_symbols): Don't call write_glink_stub
239         for local iplt syms with ent->plt.offset == -1.  Remove ineffective
240         attempt at writing glink stubs only once.
241
242 2019-03-16  Alan Modra  <amodra@gmail.com>
243
244         PR 24337
245         * elf.c (_bfd_elf_rela_local_sym): Revert last change.
246         (_bfd_elf_rel_local_sym): Likewise.
247         * elflink.c (elf_link_input_bfd): Use bfd_und_section for
248         section of symbols with unrecognized shndx.
249
250 2019-03-15  H.J. Lu  <hongjiu.lu@intel.com>
251
252         PR ld/24267
253         * coffgen.c (_bfd_coff_section_already_linked): Skip discarded
254         section.
255         * cofflink.c (coff_link_add_symbols): Check for symbols defined
256         in discarded section.
257
258 2019-03-15  Alan Modra  <amodra@gmail.com>
259
260         PR 24339
261         * elflink.c (elf_link_add_object_symbols): Bail out on a local
262         symbol after globals if elf_bad_symtab is not set.
263
264 2019-03-15  Alan Modra  <amodra@gmail.com>
265
266         PR 24337
267         * elf.c (_bfd_elf_rela_local_sym): Don't segfault on NULL sec.
268         (_bfd_elf_rel_local_sym): Likewise.
269
270 2019-03-15  Alan Modra  <amodra@gmail.com>
271
272         PR 24336
273         * elflink.c (elf_link_read_relocs_from_section): Handle fuzzed
274         object files with sh_size not a multiple of sh_entsize.
275
276 2019-03-15  H.J. Lu  <hongjiu.lu@intel.com>
277
278         PR ld/24338
279         * elf64-x86-64.c (elf_x86_64_relocate_section): Check for corrupt
280         input with bad relocation.
281
282 22019-03-15  H.J. Lu  <hongjiu.lu@intel.com>
283
284         * elf64-x86-64.c (elf_x86_64_relocate_section): Re-indent.
285
286 2019-03-14  Nick Clifton  <nickc@redhat.com>
287
288         PR 24334
289         * dwarf2.c (struct dwarf2_debug): Add sec_vma_count field.
290         (save_section_vma): Initialise field to the number of entries in
291         the sec_vma table.
292         (section_vma_same): Check that the number of entries in the
293         sec_vma table matches the number of sections in the bfd.
294
295 2019-03-14  Nick Clifton  <nickc@redhat.com>
296
297         PR 24333
298         * elflink.c (_bfd_elf_add_default_symbol): Add a check for a NULL
299         section owner pointer when adding the default symbol.
300
301 2019-03-14  Nick Clifton  <nickc@redhat.com>
302
303         PR 24332
304         * elflink.c (elf_link_add_object_symbols): Add new local variable
305         extversym_end.  Initialise it to point to the end of the version
306         symbol table, if present.  Check it when initialising and updating
307         the ever pointer.
308
309 2019-03-13  Sudakshina Das  <sudi.das@arm.com>
310
311         * elfnn-aarch64.c (PLT_PAC_ENTRY_SIZE, PLT_PAC_SMALL_ENTRY_SIZE): New.
312         (PLT_BTI_PAC_ENTRY_SIZE, PLT_BTI_PAC_SMALL_ENTRY_SIZE): New.
313         (setup_plt_values): Account for PAC or PAC and BTI enabled PLTs.
314         (elfNN_aarch64_size_dynamic_sections): Add checks for PLT_BTI_PAC
315         and PLT_PAC_PLT.
316         (elfNN_aarch64_finish_dynamic_sections): Account for PLT_BTI_PAC.
317         (get_plt_type): Add case for DT_AARCH64_PAC_PLT.
318         (elfNN_aarch64_plt_sym_val): Add cases for PLT_BTI_PAC and PLT_PAC.
319
320 2019-03-13  Sudakshina Das  <sudi.das@arm.com>
321             Szabolcs Nagy  <szabolcs.nagy@arm.com>
322
323         * bfd-in.h (aarch64_plt_type, aarch64_enable_bti_type): New.
324         (aarch64_bti_pac_info): New.
325         (bfd_elf64_aarch64_set_options): Add aarch64_bti_pac_info argument.
326         (bfd_elf32_aarch64_set_options): Likewise.
327         * bfd-in2.h: Regenerate
328         * elfnn-aarch64.c (PLT_BTI_ENTRY_SIZE): New.
329         (PLT_BTI_SMALL_ENTRY_SIZE, PLT_BTI_TLSDESC_ENTRY_SIZE): New.
330         (elfNN_aarch64_small_plt0_bti_entry): New.
331         (elfNN_aarch64_small_plt_bti_entry): New.
332         (elfNN_aarch64_tlsdesc_small_plt_bti_entry): New.
333         (elf_aarch64_obj_tdata): Add no_bti_warn and plt_type fields.
334         (elf_aarch64_link_hash_table): Add plt0_entry, plt_entry and
335         tlsdesc_plt_entry_size fields.
336         (elfNN_aarch64_link_hash_table_create): Initialise the new fields.
337         (setup_plt_values): New helper function.
338         (bfd_elfNN_aarch64_set_options): Use new bp_info to set plt sizes and
339         bti enable type.
340         (elfNN_aarch64_allocate_dynrelocs): Use new size members instead of
341         fixed macros.
342         (elfNN_aarch64_size_dynamic_sections): Likewise and add checks.
343         (elfNN_aarch64_create_small_pltn_entry): Use new generic pointers
344         to plt stubs instead of fixed ones and update filling them according
345         to the need for bti.
346         (elfNN_aarch64_init_small_plt0_entry): Likewise.
347         (elfNN_aarch64_finish_dynamic_sections): Likewise.
348         (get_plt_type, elfNN_aarch64_get_synthetic_symtab): New.
349         (elfNN_aarch64_plt_sym_val): Update size accordingly.
350         (elfNN_aarch64_link_setup_gnu_properties): Set up plts if BTI GNU NOTE
351         is set.
352         (bfd_elfNN_get_synthetic_symtab): Define.
353         (elfNN_aarch64_merge_gnu_properties): Give out warning with --force-bti
354         and mising BTI NOTE SECTION.
355
356
357 2019-03-13  Sudakshina Das  <sudi.das@arm.com>
358
359         * elf-properties.c (_bfd_elf_link_setup_gnu_properties): Exclude
360         linker created inputs from merge.
361         * elfnn-aarch64.c (struct elf_aarch64_obj_tdata): Add field for
362         GNU_PROPERTY_AARCH64_FEATURE_1_AND properties.
363         (elfNN_aarch64_link_setup_gnu_properties): New.
364         (elfNN_aarch64_merge_gnu_properties): New.
365         (elf_backend_setup_gnu_properties): Define for AArch64.
366         (elf_backend_merge_gnu_properties): Likewise.
367         * elfxx-aarch64.c (_bfd_aarch64_elf_link_setup_gnu_properties): Define.
368         (_bfd_aarch64_elf_parse_gnu_properties): Define.
369         (_bfd_aarch64_elf_merge_gnu_properties): Define.
370         * elfxx-aarch64.h (_bfd_aarch64_elf_link_setup_gnu_properties): Declare.
371         (_bfd_aarch64_elf_parse_gnu_properties): Declare.
372         (_bfd_aarch64_elf_merge_gnu_properties): Declare.
373         (elf_backend_parse_gnu_properties): Define for AArch64.
374
375 2019-03-13  H.J. Lu  <hongjiu.lu@intel.com>
376
377         PR ld/24322
378         * elfxx-x86.c (_bfd_x86_elf_merge_gnu_properties): Properly
379         merge GNU_PROPERTY_X86_FEATURE_1_[IBT|SHSTK].
380
381 2019-03-12  Alan Modra  <amodra@gmail.com>
382
383         * coffcode.h (buy_and_read): Delete unnecessary forward decl.  Add
384         nmemb parameter.  Use bfd_alloc2.
385         (coff_slurp_line_table): Use bfd_alloc2.  Update buy_and_read calls.
386         Delete assertion.
387         (coff_slurp_symbol_table): Use bfd_alloc2 and bfd_zalloc2.
388         (coff_slurp_reloc_table): Use bfd_alloc2.  Update buy_and_read calls.
389         * coffgen.c (coff_get_reloc_upper_bound): Ensure size calculation
390         doesn't overflow.
391         * elf.c (bfd_section_from_shdr): Use bfd_zalloc2.  Style fix.
392         (assign_section_numbers): Style fix.
393         (swap_out_syms): Use bfd_malloc2.
394         (_bfd_elf_get_reloc_upper_bound): Ensure size calculation doesn't
395         overflow.
396         (_bfd_elf_make_empty_symbol): Style fix.
397         (elfobj_grok_stapsdt_note_1): Formatting.
398         * elfcode.h (elf_object_p): Use bfd_alloc2.
399         (elf_write_relocs, elf_write_shdrs_and_ehdr): Likewise.
400         (elf_slurp_symbol_table): Use bfd_zalloc2.
401         (elf_slurp_reloc_table): Use bfd_alloc2.
402         (_bfd_elf_bfd_from_remote_memory): Use bfd_malloc2.
403         * elf64-sparc (elf64_sparc_get_reloc_upper_bound): Ensure
404         size calculation doesn't overflow.
405         (elf64_sparc_get_dynamic_reloc_upper_bound): Likewise.
406         * mach-o.c (bfd_mach_o_get_reloc_upper_bound): Likewise.
407         * pdp11.c (get_reloc_upper_bound): Copy aoutx.h version.
408
409 2019-03-08  Alan Modra  <amodra@gmail.com>
410
411         PR 24311
412         * merge.c (merge_strings): Return secinfo.  Don't pad section
413         to alignment here.
414         (_bfd_merge_sections): Pad section to alignment here, if input
415         sections contributing to merged output all pad to alignment.
416         Formatting.
417
418 2019-03-06  Nick Clifton  <nickc@redhat.com>
419
420         * dwarf2.c (_bfd_dwarf2_find_symbol_bias): Check for a NULL symbol
421         table pointer.
422         * coffgen.c (coff_find_nearest_line_with_names): Do not call
423         _bfd_dwarf2_find_symbol_bias if there is no symbol table available.
424
425 2019-03-01  Andreas Krebbel  <krebbel@linux.ibm.com>
426
427         This reverts commit 5a12586d44fa8d5dfc74cbca4f2f36a273a16335.
428         2019-01-14  Maamoun Tarsha  <maamountk@hotmail.com>
429
430         PR 20113
431         * elf32-s390.c (allocate_dynrelocs): Update comment.
432
433 2019-02-28  Tamar Christina  <tamar.christina@arm.com>
434
435         * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): Correct CIE parse.
436
437 2019-02-28  Nick Clifton  <nickc@redhat.com>
438
439         PR 24273
440         * elf.c (bfd_elf_string_from_elf_section): Check for a string
441         section that is not NUL terminated.
442
443 2019-02-27  H.J. Lu  <hongjiu.lu@intel.com>
444
445         PR ld/24276
446         * elf64-x86-64.c (elf_x86_64_check_relocs): Skip symbol defined
447         by linker when checking copy reloc on protected symbol.
448
449 2019-02-24  Alan Modra  <amodra@gmail.com>
450
451         PR 24144
452         * pdp11.c (set_section_contents): Revert 2015-02-24 change.
453
454 2019-02-20  Eric Tsai  <erictsai@cadence.com>
455
456         * elf32-xtensa.c (is_resolvable_asm_expansion): Scan output
457         sections between the call site and call destination and adjust
458         call distance by the largest alignment.
459
460 2019-02-20  Alan Hayward  <alan.hayward@arm.com>
461
462         * elf-bfd.h (elfcore_write_aarch_pauth): Add declaration.
463         * elf.c (elfcore_grok_aarch_pauth): New function.
464         (elfcore_grok_note): Check for NT_ARM_PAC_MASK.
465         (elfcore_write_aarch_pauth): New function.
466         (elfcore_write_register_note): Check for AArch64 pauth section.
467
468 2019-02-20  Alan Modra  <amodra@gmail.com>
469
470         PR 24225
471         * elf32-nios2.c (nios2_elf32_relocate_section): Check asprintf
472         return value.
473
474 2019-02-20  Michael Roitzsch  <reactorcontrol@icloud.com>
475
476         * configure.ac (SHARED_LIBADD): Add -liberty -lintl for all
477         Darwin hosts, not just or1k.
478         * configure: Regenerate.
479
480 2019-02-20  Alan Modra  <amodra@gmail.com>
481
482         PR 24236
483         * archive64.c (_bfd_archive_64_bit_slurp_armap): Move code adding
484         sentinel NUL to string buffer nearer to loop where it is used.
485         Don't go past sentinel when scanning strings, and don't write
486         NUL again.
487         * archive.c (do_slurp_coff_armap): Simplify string handling to
488         archive64.c style.
489
490 2019-02-19  Alan Modra  <amodra@gmail.com>
491
492         PR 24235
493         * pei-x86_64.c (pex64_bfd_print_pdata_section): Correct checks
494         attempting to prevent read past end of section.
495
496 2019-02-18  Alan Modra  <amodra@gmail.com>
497
498         PR 24225
499         * elf32-nios2.c (nios2_elf32_relocate_section): Use asprintf and
500         PRIx64 to generate warning messages.  Print local sym names too.
501
502 2019-02-09  Vineet Gupta  <vgupta@synopsys.com>
503
504         * elf32-arc (INIT_SYM_STRING): Delete.
505         (FINI_SYM_STRING): Likewise.
506         (init_str): Likewise.
507         (fini_str): Likewise.
508
509 2019-02-08  Alan Modra  <amodra@gmail.com>
510
511         * elf32-ppc.c (ppc_elf_relocate_section): Add %X to "unsupported
512         for bss-plt" warning to make it an error.
513
514 2019-02-07  Eric Botcazou  <ebotcazou@adacore.com>
515
516         PR ld/18841
517         * elf32-sparc.c (elf32_sparc_reloc_type_class): Return
518         reloc_class_ifunc for ifunc symbols.
519         * elf64-sparc.c (elf64_sparc_reloc_type_class): Likewise.
520
521 2019-02-07  Eric Botcazou  <ebotcazou@adacore.com>
522
523         * elf32-visium.c (visium_elf_howto_parity_reloc): Minor tweak.
524         <R_VISIUM_PC16>: Use explicit range test to detect an overflow.
525
526 2019-02-07  Nick Clifton  <nickc@redhat.com>
527
528         * config.bfd: Move the powerpc-lynxos and powerpc-windiss targets
529         into the definitely obsolete list.
530
531 2019-02-05  H.J. Lu  <hongjiu.lu@intel.com>
532
533         PR ld/24151
534         * elf64-x86-64.c (elf_x86_64_need_pic): Check
535         SYMBOL_DEFINED_NON_SHARED_P instead of def_regular.
536         (elf_x86_64_relocate_section): Move PIC check for PC-relative
537         relocations to ...
538         (elf_x86_64_check_relocs): Here.
539         (elf_x86_64_finish_dynamic_symbol): Use SYMBOL_DEFINED_NON_SHARED_P
540         to check if a symbol is defined in a non-shared object.
541         * elfxx-x86.h (SYMBOL_DEFINED_NON_SHARED_P): New.
542
543 2019-01-21  Sergio Durigan Junior  <sergiodj@redhat.com>
544
545         * elf32-arm.c (elf32_arm_final_link_relocate): Use 'llabs' instead
546         of 'labs' (and fix GCC warning).
547
548 2019-01-25  Nick Clifton  <nickc@redhat.com>
549
550         * po/ru.po: Updated Russian translation.
551
552 2019-01-23  Nick Clifton  <nickc@redhat.com>
553
554         * po/fr.po: Updated French translation.
555
556 2019-01-21  Nick Clifton  <nickc@redhat.com>
557
558         * po/pt.po: Updated Portuguese translation.
559         * po/uk.po: Updated Ukranian translation.
560
561 2019-01-21  Yuri Chornoivan  <yurchor@ukr.net>
562
563         PR 24108
564         * elf32-nds32.c (nds32_relocate_section): Add space between words
565         in error message.
566         * elfnn-riscv.c (riscv_version_mismatch): Fix spelling mistake in
567         error message.
568         (riscv_i_or_e_p): Likewise.
569         (riscv_merge_arch_attr_info): Likewise.
570
571 2019-01-19  Nick Clifton  <nickc@redhat.com>
572
573         * version.m4: Reset to 2.32.51
574         * configure: Regenerate.
575         * po/bfd.pot: Regenerate.
576
577 2018-06-24  Nick Clifton  <nickc@redhat.com>
578
579         2.32 branch created.
580
581 2019-01-16  Kito Cheng  <kito@andestech.com>
582
583         * elf-attrs.c (vendor_obj_attr_size): Return 0 if size is 0 even
584         for OBJ_ATTR_PROC.
585
586 2019-01-16  Kito Cheng  <kito@andestech.com>
587             Nelson Chu  <nelson@andestech.com>
588
589         * elfnn-riscv.c (in_subsets): New.
590         (out_subsets): Likewise.
591         (merged_subsets): Likewise.
592         (riscv_std_ext_p): Likewise.
593         (riscv_non_std_ext_p): Likewise.
594         (riscv_std_sv_ext_p): Likewise.
595         (riscv_non_std_sv_ext_p): Likewise.
596         (riscv_version_mismatch): Likewise.
597         (riscv_i_or_e_p): Likewise.
598         (riscv_merge_std_ext): Likewise.
599         (riscv_merge_non_std_and_sv_ext): Likewise.
600         (riscv_merge_arch_attr_info): Likewise.
601         (riscv_merge_attributes): Likewise.
602         (_bfd_riscv_elf_merge_private_bfd_data): Merge attribute.
603
604         * elfnn-riscv.c (riscv_elf_obj_attrs_arg_type): New.
605         (elf_backend_obj_attrs_vendor): Define.
606         (elf_backend_obj_attrs_section_type): Likewise.
607         (elf_backend_obj_attrs_section): Likewise.
608         (elf_backend_obj_attrs_arg_type): Define as
609         riscv_elf_obj_attrs_arg_type.
610         * elfxx-riscv.c (riscv_estimate_digit): New.
611         (riscv_estimate_arch_strlen1): Likewise.
612         (riscv_estimate_arch_strlen): Likewise.
613         (riscv_arch_str1): Likewise.
614         (riscv_arch_str): Likewise.
615         * elfxx-riscv.h (riscv_arch_str): Declare.
616
617 2019-01-14  John Darrington <john@darrington.wattle.id.au>
618
619         * bfd-in2.h [BFD_RELOC_S12Z_OPR]: New reloc.
620         * libbfd.h: regen.
621         * elf32-s12z.c (eld_s12z_howto_table): R_S12Z_OPR takes non zero
622         source field.  (md_apply_fix): Apply final fix
623         to BFD_RELOC_S12Z_OPR.
624         * reloc.c[BFD_RELOC_S12Z_OPR]: New reloc.
625
626 2019-01-14  Maamoun Tarsha  <maamountk@hotmail.com>
627
628         PR 20113
629         * elf32-s390.c (allocate_dynrelocs): Update comment.
630
631 2019-01-09  Andrew Paprocki  <andrew@ishiboo.com>
632
633         * warning.m4: Adjust egrep pattern for non-GNU compilers.
634         * configure: Regenerate.
635
636 2019-01-08  Alan Modra  <amodra@gmail.com>
637
638         PR 23699
639         PR 24065
640         * ihex.c (ihex_write_object_contents): Properly check 32-bit
641         address range.
642
643 2019-01-05  Yoshinori Sato <ysato@users.sourceforge.jp>
644
645         * bfd/archures.c: Add bfd_mach_rx_v2 and bfd_mach_rx_v3.
646         * bfd/bfd-in2.h: Regenerate.
647         * bfd/cpu-rx.c (arch_info_struct): Add RXv2 and RXv3 entry.
648         * bfd/elf32-rx.c (elf32_rx_machine): Add RXv2 and RXv3 support.
649
650 2019-01-04  Lifang Xia  <lifang_xia@c-sky.com>
651
652         * config.bfd (csky-*-elf* | csky-*-linux*): Modify the csky
653         default target, little endian target is more suitable.
654
655 2019-01-04  Alan Modra  <amodra@gmail.com>
656
657         PR 24061
658         PR 21786
659         * coff-rs6000.c (GET_VALUE_IN_FIELD): Add base parameter and
660         adjust all callers.
661         (EQ_VALUE_IN_FIELD): Likewise.
662         * coff64-rs6000.c (GET_VALUE_IN_FIELD): Likewise.
663
664 2019-01-01  Alan Modra  <amodra@gmail.com>
665
666         Update year range in copyright notice of all files.
667
668 For older changes see ChangeLog-2018
669 \f
670 Copyright (C) 2019 Free Software Foundation, Inc.
671
672 Copying and distribution of this file, with or without modification,
673 are permitted in any medium without royalty provided the copyright
674 notice and this notice are preserved.
675
676 Local Variables:
677 mode: change-log
678 left-margin: 8
679 fill-column: 74
680 version-control: never
681 End: