12017-07-25  Tristan Gingold  <gingold@adacore.com>
2
3	* version.m4: Bump version to 2.28.1
4	* configure: Regenerate.
5
62017-07-25  Tristan Gingold  <gingold@adacore.com>
7
8	* development.sh: Set development to false.
9
102017-06-22  Eric Christopher  <echristo@gmail.com>
11
12	Backport from mainline
13	2017-06-22 Eric Christopher <echristo@gmail.com>
14
15        * elf32-arm.c (elf32_arm_final_link_relocate): Use labs rather than
16        abs to fix a truncation warning.
17
182017-06-20  Thomas Preud'homme  <thomas.preudhomme@arm.com>
19
20	Backport from mainline
21	2017-05-08  Thomas Preud'homme  <thomas.preudhomme@arm.com>
22
23	* elflink.c (elf_output_implib): Remove executable flag from import
24	library bfd.
25	* elf32-arm.c (elf32_arm_filter_implib_symbols): Assert that the import
26	library is a relocatable object file.
27
282017-06-13  Nick Clifton  <nickc@redhat.com>
29
30	Import this fix from the mainline sources:
31
32	2017-06-06  James Clarke  <jrtc27@jrtc27.com>
33
34	PR ld/19579
35	* elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol): Check
36	ELF_COMMON_DEF_P for common symbols.
37
382017-06-07  Nick Clifton  <nickc@redhat.com>
39
40	Import this fix from upstream:
41
42	2017-05-30  Casey Smith  <clegg89@gmail.com>
43
44	PR ld/21523
45	* elf32-arm.c (elf32_arm_final_link_relocate): Install an absolute
46	value when processing the R_ARM_THM_ALU_PREL_11_0 reloc.
47
482017-06-05  Alan Modra  <amodra@gmail.com>
49
50	PR 21529
51	* linker.c (_bfd_generic_link_output_symbols): Handle BSF_GNU_UNIQUE.
52
532017-05-01  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
54
55	PR ld/21404
56	* elf32-avr.c (avr_should_move_sym): New function.
57	(avr_should_reduce_sym_size): Likewise.
58	(avr_should_increase_sym_size): Likewise.
59	(elf32_avr_relax_delete_bytes): Adjust symbol values
60	and sizes by calling new functions.
61
622017-05-01  Palmer Dabbelt  <palmer@dabbelt.com>
63
64	* config.bfd (riscv32-*): Enable rv64.
65
662017-04-03  Palmer Dabbelt  <palmer@dabbelt.com>
67
68	* elfnn-riscv.c (GP_NAME): Delete.
69	(riscv_global_pointer_value): Change GP_NAME to RISCV_GP_SYMBOL.
70	(_bfd_riscv_relax_lui): Likewise.
71
722017-01-17  Kuan-Lin Chen  <kuanlinchentw@gmail.com>
73
74	* elfnn-riscv.c (riscv_elf_object_p): New function.
75
762017-04-26  Maciej W. Rozycki  <macro@imgtec.com>
77
78	PR ld/21334
79	* elf-bfd.h (elf_backend_data): Add `always_renumber_dynsyms'
80	member.
81	* elfxx-target.h [!elf_backend_always_renumber_dynsyms]
82	(elf_backend_always_renumber_dynsyms): Define.
83	(elfNN_bed): Initialize `always_renumber_dynsyms' member.
84	* elfxx-mips.h (elf_backend_always_renumber_dynsyms): Define.
85	* elflink.c (bfd_elf_size_dynsym_hash_dynstr): Also call
86	`_bfd_elf_link_renumber_dynsyms' if the backend has requested
87	it.
88	(elf_gc_sweep): Likewise.
89
902017-04-26  Maciej W. Rozycki  <macro@imgtec.com>
91
92	* elflink.c (elf_gc_sweep): Only call
93	`_bfd_elf_link_renumber_dynsyms' if dynamic sections have been
94	created.
95
962017-04-24  H.J. Lu  <hongjiu.lu@intel.com>
97
98	PR ld/21425
99	* elf32-i386.c (ELF_MAXPAGESIZE): Set to 0x1000 for VxWorks.
100
1012017-03-28  Hans-Peter Nilsson  <hp@axis.com>
102
103	PR ld/16044
104	* elf32-cris.c (elf_cris_adjust_gotplt_to_got): Adjust BFD_ASSERT
105	to handle a local symbol with a hash-symbol-entry; without PLT.
106	Add BFD_ASSERT for an incidental case with GOT entry present.
107	(cris_elf_check_relocs): Increment PLT refcount only if the symbol
108	isn't forced-or-set local.
109
1102017-04-13  Alan Modra  <amodra@gmail.com>
111
112	* elf32-arm.c (arm_type_of_stub): Supply missing args to "long
113	branch veneers" error.  Fix double space and format message.
114	* elf32-avr.c (avr_add_stub): Do not pass NULL as %B arg.
115	* elf64-ppc.c (tocsave_find): Supply missing %B arg.
116
1172017-04-10  H.J. Lu  <hongjiu.lu@intel.com>
118
119	PR ld/19579
120	PR ld/21306
121	* elf32-s390.c (elf_s390_finish_dynamic_symbol): Check
122	ELF_COMMON_DEF_P for common symbols.
123	* elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
124	* elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
125	* elflink.c (_bfd_elf_merge_symbol): Revert commits
126	202ac193bbbecc96a4978d1ac3d17148253f9b01 and
127	07492f668d2173da7a2bda3707ff0985e0f460b6.
128
1292017-03-07  Alan Modra  <amodra@gmail.com>
130
131	PR 21224
132	PR 20519
133	* elf64-ppc.c (ppc64_elf_relocate_section): Add missing
134	dyn_relocs check.
135
1362017-03-07  Alan Modra  <amodra@gmail.com>
137
138	Apply from master
139	2017-03-02  Alan Modra  <amodra@gmail.com>
140	* elf32-ppc.c (ppc_elf_vle_split16): Correct insn mask typo.
141
1422017-03-02  Tristan Gingold  <gingold@adacore.com>
143
144	* version.m4: Bump version to 2.28.0
145	* configure: Regenerate.
146
1472017-03-02  Tristan Gingold  <gingold@adacore.com>
148
149	* development.sh: Set development to true.
150
1512017-03-02  Tristan Gingold  <gingold@adacore.com>
152
153	* version.m4: Bump version to 2.28
154	* configure: Regenerate.
155
1562017-03-02  Tristan Gingold  <gingold@adacore.com>
157
158	* development.sh: Set development to false.
159
1602017-02-28  Alan Modra  <amodra@gmail.com>
161
162	PR 20995
163	* elf32-nios2.c (nios2_elf32_relocate_section): Use htab
164	rather than elf32_nios2_hash_table or elf_hash_table.
165	(create_got_section): Likewise.
166	(nios2_elf32_finish_dynamic_symbol): Likewise.
167	(nios2_elf32_adjust_dynamic_symbol): Likewise.
168	(nios2_elf32_size_dynamic_sections): Likewise.
169	(nios2_elf32_check_relocs): Delete dynobj, sgot, and srelgot
170	vars.  Use htab equivalents directly instead.  Don't create
171	all dynamic sections on needing just the GOT.  Use a goto
172	rather than a fall-through with reloc test.  Ensure
173	htab->dynobj is set when making dynamic sreloc section.
174	(nios2_elf32_finish_dynamic_sections): Delete dynobj, use htab
175	equivalent directly instead.  Don't segfault on looking for
176	.dynamic when dynamic sections have not been created.  Don't
177	segfault on .got.plt being discarded.
178	(nios2_elf32_size_dynamic_sections): Delete plt and got vars.
179	Don't set "relocs" on .rela.plt.  Do handle .sbss.  Delete
180	fixme and another not so relevant comment.
181	(nios2_elf_add_symbol_hook): Delete dynobj var.  If not
182	already set, set hash table dynobj on creating .sbss.
183
1842017-02-28  Alan Modra  <amodra@gmail.com>
185
186	* elflink.c (_bfd_elf_create_dynamic_sections): Don't make
187	dynamic .data.rel.ro read-only.
188	* elf32-arm.c (elf32_arm_finish_dynamic_symbol): Compare section
189	rather than section flags when deciding where copy reloc goes.
190	* elf32-cris.c (elf_cris_finish_dynamic_symbol): Likewise.
191	* elf32-hppa.c (elf32_hppa_finish_dynamic_symbol): Likewise.
192	* elf32-i386.c (elf_i386_finish_dynamic_symbol): Likewise.
193	* elf32-metag.c (elf_metag_finish_dynamic_symbol): Likewise.
194	* elf32-microblaze.c (microblaze_elf_finish_dynamic_symbol): Likewise.
195	* elf32-nios2.c (nios2_elf32_finish_dynamic_symbol): Likewise.
196	* elf32-or1k.c (or1k_elf_finish_dynamic_symbol): Likewise.
197	* elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Likewise.
198	* elf32-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
199	* elf32-tic6x.c (elf32_tic6x_finish_dynamic_symbol): Likewise.
200	* elf32-tilepro.c (tilepro_elf_finish_dynamic_symbol): Likewise.
201	* elf64-ppc.c (ppc64_elf_finish_dynamic_symbol): Likewise.
202	* elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
203	* elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.
204	* elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol): Likewise.
205	* elfnn-riscv.c (riscv_elf_finish_dynamic_symbol): Likewise.
206	* elfxx-mips.c (_bfd_mips_vxworks_finish_dynamic_symbol): Likewise.
207	* elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): Likewise.
208	* elfxx-tilegx.c (tilegx_elf_finish_dynamic_symbol): Likewise.
209
2102017-02-28  Alan Modra  <amodra@gmail.com>
211
212	* reloc.c (BFD_RELOC_PPC_16DX_HA): New.
213	* elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_16DX_HA>): New howto.
214	(ppc64_elf_reloc_type_lookup): Translate new bfd reloc.
215	(ppc64_elf_ha_reloc): Correct overflow test on REL16DX_HA.
216	(ppc64_elf_relocate_section): Likewise.
217	* elf32-ppc.c (ppc_elf_howto_raw <R_PPC_16DX_HA>): New howto.
218	(ppc_elf_reloc_type_lookup): Translate new bfd reloc.
219	(ppc_elf_check_relocs): Handle R_PPC_16DX_HA to pacify gcc.
220	* libbfd.h: Regenerate.
221	* bfd-in2.h: Regenerate.
222
2232017-02-24  Andrew Waterman  <andrew@sifive.com>
224
225	* elfnn-riscv.c (GP_NAME): New macro.
226	(riscv_global_pointer_value): Use it.
227	(_bfd_riscv_relax_lui): If symbol and global pointer are in same
228	output section, consider only that section's alignment.
229
2302017-02-23  Alan Modra  <amodra@gmail.com>
231
232	PR 20744
233	* elf32-ppc.c (ppc_elf_howto_raw): Correct dst_mask on all VLE
234	16D relocations.
235	(ppc_elf_vle_split16): Correct field mask and shift for 16D relocs.
236	(ppc_elf_relocate_section): Correct calculation for VLE SDAREL
237	relocs.
238
2392017-02-22  Alan Modra  <amodra@gmail.com>
240
241	* elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Don't segfault
242	on .got or .plt output section being discarded by script.
243	* elf32-ppc.c (ppc_elf_finish_dynamic_sections): Likewise.  Move
244	vxworks splt temp.
245
2462017-02-20  Alan Modra  <amodra@gmail.com>
247
248	PR 21181
249	* elflink.c (bfd_elf_final_link): Make DT_REL/DT_RELA zero
250	if DT_RELSZ/DT_RELASZ is zero.
251
2522017-02-16  Alan Modra  <amodra@gmail.com>
253
254	PR 21000
255	* elf-bfd.h (struct elf_backend_data): Add no_page_alias.
256	* elfxx-target.h (elf_backend_no_page_alias): Define.
257	(elfNN_bed): Init new field.
258	* elf.c (assign_file_positions_for_load_sections): If no_page_alias
259	ensure PT_LOAD segment starts on a new page.
260	* elf32-hppa.c (elf_backend_no_page_alias): Define.
261
2622017-02-16  Alan Modra  <amodra@gmail.com>
263
264	PR 21132
265	* elf32-hppa.c (allocate_plt_static): Allocate space for relocs
266	if pic.
267
2682017-02-15  H.J. Lu  <hongjiu.lu@intel.com>
269
270	PR ld/21168
271	* elf32-i386.c (elf_i386_relocate_section): Allow
272	"lea foo@GOT, %reg" in PIC.
273
2742017-02-14  Alan Modra  <amodra@gmail.com>
275
276	* elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Support
277	--gc-keep-exported, and test versioned field of sym rather than
278	looking for @ in name.
279
2802017-02-13  Palmer Dabbelt  <palmer@dabbelt.com>
281
282	* elfnn-riscv.c (riscv_global_pointer_value): Change _gp to
283	__global_pointer$.
284
2852017-02-13  Maciej W. Rozycki  <macro@imgtec.com>
286
287	* elfxx-mips.c (mips_elf_hash_sort_data): Add
288	`max_local_dynindx'.
289	(mips_elf_sort_hash_table): Handle it.
290	(mips_elf_sort_hash_table_f) <GGA_NONE>: For forced local
291	symbols bump up `max_local_dynindx' rather than
292	`max_non_got_dynindx'.
293
2942017-02-13  Maciej W. Rozycki  <macro@imgtec.com>
295
296	* elfxx-mips.c (mips_elf_hash_sort_data): Convert the
297	`min_got_dynindx', `max_unref_got_dynindx' and
298	`max_non_got_dynindx' members to the `bfd_size_type' data type.
299	(mips_elf_sort_hash_table): Adjust accordingly.
300
3012017-02-13  Maciej W. Rozycki  <macro@imgtec.com>
302
303	* elfxx-mips.c (mips_elf_sort_hash_table): Use `htab' throughout
304	to access the hash table.
305
3062017-02-13  Maciej W. Rozycki  <macro@imgtec.com>
307
308	* elfxx-mips.c (mips_elf_sort_hash_table): Move assertion on
309	non-NULL `htab' to the beginning.
310
3112017-02-03  Alan Modra  <amodra@gmail.com>
312
313	* elf32-hppa.c (ensure_undef_weak_dynamic): New function.
314	(allocate_plt_static, allocate_dynrelocs): Use it.
315
3162017-02-03  Alan Modra  <amodra@gmail.com>
317
318	* elf-hppa.h (elf_hppa_fake_sections): Set SHF_INFO_LINK for
319	.PARISC.unwind section.
320
3212017-02-02  Hans-Peter Nilsson  <hp@axis.com>
322
323	* elf32-cris.c (elf_cris_finish_dynamic_symbol): Remove now unused
324	local variable dynobj.
325
326	PR ld/20995
327	* elf32-cris.c (elf_cris_size_dynamic_sections): Handle sdynrelro.
328	(elf_cris_adjust_dynamic_symbol): Place variables copied into the
329	executable from read-only sections into sdynrelro.
330	(elf_cris_finish_dynamic_symbol): Select sreldynrelro for
331	dynamic relocs in sdynrelro.
332	(elf_backend_want_dynrelro): Define.
333
3342017-01-30  Maciej W. Rozycki  <macro@imgtec.com>
335
336	* elfxx-mips.h (_bfd_mips_elf_insn32): Rename prototype to...
337	(_bfd_mips_elf_linker_flags): ... this.  Add another parameter.
338	* elfxx-mips.c (mips_elf_link_hash_table): Add
339	`ignore_branch_isa' member.
340	(mips_elf_perform_relocation): Do not treat an ISA mode mismatch
341	in branch relocation calculation as an error if
342	`ignore_branch_isa' has been set.
343	(_bfd_mips_elf_insn32): Rename to...
344	(_bfd_mips_elf_linker_flags): ... this.  Rename the `on'
345	parameter to `insn32' and add an `ignore_branch_isa' parameter.
346	Handle the new parameter.
347
3482017-01-18  Maciej W. Rozycki  <macro@imgtec.com>
349
350	PR ld/20828
351	* elflink.c (bfd_elf_record_link_assignment): Clear any
352	`forced_local' marking for DSO symbols that are not being
353	provided.
354
3552017-01-13  H.J. Lu  <hongjiu.lu@intel.com>
356
357	Backport from master
358	2017-01-12  H.J. Lu  <hongjiu.lu@intel.com>
359
360	PR ld/21038
361	* elf64-x86-64.c (elf_x86_64_link_hash_table): Add
362	plt_bnd_eh_frame.
363	(elf_x86_64_check_relocs): Create .eh_frame section for the
364	.plt.bnd section.
365	(elf_x86_64_size_dynamic_sections): Allocate and initialize
366	.eh_frame section for the .plt.bnd section.
367	(elf_x86_64_finish_dynamic_sections): Adjust .eh_frame section
368	for the .plt.bnd section.
369
370	2017-01-11  H.J. Lu  <hongjiu.lu@intel.com>
371
372	PR ld/21038
373	* elf64-x86-64.c (elf_x86_64_eh_frame_bnd_plt): New.
374	(elf_x86_64_bnd_arch_bed): Use elf_x86_64_eh_frame_bnd_plt and
375	elf_x86_64_eh_frame_plt_got.
376	(elf_x86_64_size_dynamic_sections): Get unwind info from
377	elf_x86_64_bnd_arch_bed for the BND PLT.
378
3792017-01-13  H.J. Lu  <hongjiu.lu@intel.com>
380
381	Backport from master
382	2017-01-10  H.J. Lu  <hongjiu.lu@intel.com>
383
384	* elf32-i386.c (elf_i386_check_relocs): Align .eh_frame section
385	to 4 bytes.
386	* elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Align
387	.eh_frame section to 4 bytes for x32.
388	(elf_x86_64_check_relocs): Likewise.
389
390	2017-01-10  H.J. Lu  <hongjiu.lu@intel.com>
391
392	PR ld/20830
393	* elf32-i386.c (elf_i386_eh_frame_plt_got): New.
394	(PLT_GOT_FDE_LENGTH): Likewise.
395	(elf_i386_plt_layout): Add eh_frame_plt_got and
396	eh_frame_plt_got_size.
397	(elf_i386_plt): Updated.
398	(elf_i386_link_hash_table): Add plt_got_eh_frame.
399	(elf_i386_check_relocs): Create .eh_frame section for .plt.got.
400	(elf_i386_size_dynamic_sections): Allocate and initialize
401	.eh_frame section for .plt.got.
402	(elf_i386_finish_dynamic_sections): Adjust .eh_frame section for
403	.plt.got.
404	(elf_i386_nacl_plt): Add FIXME for eh_frame_plt_got and
405	eh_frame_plt_got_size.
406	* elf64-x86-64.c (elf_x86_64_eh_frame_plt_got): New.
407	(PLT_GOT_FDE_LENGTH): Likewise.
408	(elf_x86_64_backend_data): Add eh_frame_plt_got and
409	eh_frame_plt_got_size.
410	(elf_x86_64_arch_bed): Updated.
411	(elf_x86_64_bnd_arch_bed): Add FIXME for eh_frame_plt_got and
412	eh_frame_plt_got_size.
413	(elf_x86_64_nacl_arch_bed): Likewise.
414	(elf_x86_64_link_hash_table): Add plt_got_eh_frame.
415	(elf_x86_64_check_relocs): Create .eh_frame section for .plt.got.
416	(elf_x86_64_size_dynamic_sections): Allocate and initialize
417	.eh_frame section for .plt.got.
418	(elf_x86_64_finish_dynamic_sections): Adjust .eh_frame section
419	for .plt.got.
420
4212017-01-13  H.J. Lu  <hongjiu.lu@intel.com>
422
423	Backport from master
424	2017-01-10  H.J. Lu  <hongjiu.lu@intel.com>
425
426	* elf32-i386.c (elf_i386_size_dynamic_sections): Set
427	plt_eh_frame->size to eh_frame_plt_size and use eh_frame_plt.
428
4292017-01-12  Nick Clifton  <nickc@redhat.com>
430
431	PR binutils/20876
432	* opncls.c (find_separate_debug_file): Add include_dirs
433	parameter.  Only include the directory part of the bfd's filename
434	in search paths if include_dirs is true.  Add a couple of extra
435	locations for looking for debug files.
436	( bfd_follow_gnu_debuglink): Update invocation of
437	find_separate_debug_file.
438	(bfd_follow_gnu_debugaltlink): Likewise.
439	(get_build_id): New function: Finds the build-id of the given bfd.
440	(get_build_id_name): New function: Computes the name of the
441	separate debug info file for a bfd, based upon its build-id.
442	(check_build_id_file): New function: Checks to see if a separate
443	debug info file exists at the given location, and that its
444	build-id matches that of the original bfd.
445	(bfd_follow_build_id_debuglink): New function: Finds a separate
446	debug info file for a given bfd by using the build-id method.
447	* dwarf2.c (_bfd_dwarf2_slurp_debug_info): Try using the build-id
448	method of locating a separate debug info file before using the
449	debuglink method.
450	* bfd-in2.h: Regenerate.
451
4522017-01-04  James Clarke  <jrtc27@jrtc27.com>
453
454	* elf64-alpha.c (elf64_alpha_relax_opt_call): Don't set tsec_free
455	if relocs are cached.
456
4572017-01-02  Alan Modra  <amodra@gmail.com>
458
459	PR ld/20989
460	* elfxx-sparc.c (gdop_relative_offset_ok): New function.
461	(_bfd_sparc_elf_relocate_section): Use it to validate GOT
462	indirect to GOT pointer relative code edit.
463
4642017-01-02  Alan Modra  <amodra@gmail.com>
465
466	Update year range in copyright notice of all files.
467
468For older changes see ChangeLog-2016
469
470Copyright (C) 2017 Free Software Foundation, Inc.
471
472Copying and distribution of this file, with or without modification,
473are permitted in any medium without royalty provided the copyright
474notice and this notice are preserved.
475
476Local Variables:
477mode: change-log
478left-margin: 8
479fill-column: 74
480version-control: never
481End:
482