ELF: Call check_relocs after opening all inputs
[external/binutils.git] / ld / ChangeLog
1 2017-10-16  H.J. Lu  <hongjiu.lu@intel.com>
2
3         * emulparams/elf32_x86_64.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
4         Removed.
5         * emulparams/elf_i386_be.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
6         Likewise.
7         * emulparams/elf_i386_chaos.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
8         Likewise.
9         * emulparams/elf_i386_ldso.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
10         Likewise.
11         * emulparams/elf_i386_vxworks.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
12         Likewise.
13         * emulparams/elf_iamcu.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
14         Likewise.
15         * emulparams/elf_k1om.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
16         Likewise.
17         * emulparams/elf_l1om.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
18         Likewise.
19         * emulparams/elf_x86_64.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
20         Likewise.
21         * emulparams/i386lynx.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
22         Likewise.
23         * emulparams/i386moss.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
24         Likewise.
25         * emulparams/i386nto.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
26         Likewise.
27         * emulparams/i386nw.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
28         Likewise.
29         * emulparams/shelf.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
30         Likewise.
31         * emulparams/shelf32.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
32         Likewise.
33         * emulparams/shelf_nto.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
34         Likewise.
35         * emulparams/shelf_vxworks.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
36         Likewise.
37         * emulparams/shlelf32_linux.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
38         Likewise.
39         * emulparams/shlelf_linux.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
40         Likewise.
41         * emulparams/shlelf_nto.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
42         Likewise.
43         * emultempl/aarch64elf.em (gld${EMULATION_NAME}_before_parse):
44         Set link_info.check_relocs_after_open_input to TRUE.
45         * emultempl/armelf.em (gld${EMULATION_NAME}_before_parse):
46         Likewise.
47         * emultempl/scoreelf.em (gld${EMULATION_NAME}_before_parse):
48         Likewise.
49         * emultempl/aix.em (ld_${EMULATION_NAME}_emulation): Add
50         after_parse_default.
51         * emultempl/armcoff.em (ld_${EMULATION_NAME}_emulation): Likewise.
52         * emultempl/beos.em (ld_${EMULATION_NAME}_emulation): Likewise.
53         * emultempl/generic.em (ld_${EMULATION_NAME}_emulation): Likewise.
54         * emultempl/gld960.em (ld_${EMULATION_NAME}_emulation): Likewise.
55         * emultempl/gld960c.em (ld_${EMULATION_NAME}_emulation): Likewise.
56         * emultempl/lnk960.em (ld_${EMULATION_NAME}_emulation): Likewise.
57         * emultempl/m68kcoff.em (ld_${EMULATION_NAME}_emulation): Likewise.
58         * emultempl/msp430.em (ld_${EMULATION_NAME}_emulation): Likewise.
59         * emultempl/pe.em (ld_${EMULATION_NAME}_emulation): Likewise.
60         * emultempl/pep.em (ld_${EMULATION_NAME}_emulation): Likewise.
61         * emultempl/sunos.em (ld_${EMULATION_NAME}_emulation): Likewise.
62         * emultempl/ticoff.em (ld_${EMULATION_NAME}_emulation): Likewise.
63         * emultempl/vanilla.em (ld_${EMULATION_NAME}_emulation): Likewise.
64         * emultempl/elf32.em (gld${EMULATION_NAME}_before_parse): Always
65         set link_info.check_relocs_after_open_input to TRUE.
66         (ld_${EMULATION_NAME}_emulation): Add $LDEMUL_AFTER_CHECK_RELOCS.
67         * emultempl/linux.em (gld${EMULATION_NAME}_before_parse):
68         Set link_info.check_relocs_after_open_input to TRUE.
69         (ld_${EMULATION_NAME}_emulation): Add after_check_relocs_default.
70         * emultempl/mmix-elfnmmo.em (mmix_before_parse): New function.
71         (LDEMUL_BEFORE_PARSE): New.
72         * emultempl/mmixelf.em (elfmmix_before_parse): Replace
73         gld${EMULATION_NAME}_before_parse with mmix_before_parse.
74         * emultempl/ppc32elf.em (ppc_after_open): Renamed to ...
75         (ppc_after_check_relocs): This.  Call after_check_relocs_default
76         instead of gld${EMULATION_NAME}_after_open.
77         (LDEMUL_AFTER_OPEN): Removed.
78         (LDEMUL_AFTER_CHECK_RELOCS): New.
79         * ldemul.c (ldemul_after_check_relocs): New.
80         (after_check_relocs_default): Likewise.
81         * ldemul.h (ldemul_after_check_relocs): Likewise.
82         (after_check_relocs_default): Likewise.
83         (ld_emulation_xfer_struct): Add after_check_relocs.
84         * ldlang.c (lang_process): Call ldemul_after_check_relocs after
85         lang_check_relocs.
86         * testsuite/ld-aarch64/gc-got-relocs.d: Don't expect GOT section.
87         * testsuite/ld-aarch64/gc-tls-relocs.d: Likewise.
88         * testsuite/ld-cris/tls-gc-68.d: Likewise.
89         * testsuite/ld-cris/tls-gc-69.d: Likewise.
90         * testsuite/ld-cris/tls-gc-70.d: Likewise.
91         * testsuite/ld-cris/tls-gc-75.d: Likewise.
92         * testsuite/ld-cris/tls-gc-79.d: Likewise.
93         * testsuite/ld-mmix/bpo-10.d: Don't expect .MMIX.reg_contents
94         section.
95
96 2017-10-14  H.J. Lu  <hongjiu.lu@intel.com>
97
98         PR ld/22269
99         * testsuite/ld-cris/weakhiddso.d: Update and remove R_CRIS_NONE.
100
101 2017-10-13  Alan Modra  <amodra@gmail.com>
102
103         PR ld/22263
104         * testsuite/ld-elf/tls.exp: Link with -z text.
105         * testsuite/ld-elf/pr22263-1.rd: Test for tprel relocs.
106
107 2017-10-12  H.J. Lu  <hongjiu.lu@intel.com>
108
109         PR ld/22263
110         * testsuite/ld-elf/pr22263-1.rd: New file.
111         * testsuite/ld-elf/pr22263-1a.c: Likewise.
112         * testsuite/ld-elf/pr22263-1b.c: Likewise.
113         * testsuite/ld-elf/tls.exp: Likewise.
114
115 2017-10-12  Nick Clifton  <nickc@redhat.com>
116
117         * testsuite/ld-aarch64/pcrel_pic_defined.d: Expect errors not
118         warnings.  Expect errors about unsupported relocations.
119         * testsuite/ld-aarch64/pcrel_pic_undefined.d: Likewise.
120
121 2017-10-12  H.J. Lu  <hongjiu.lu@intel.com>
122
123         * testsuite/ld-elf/pr22269b.d: Expect warning of
124         "-z dynamic-undefined-weak ignored".
125         * testsuite/ld-i386/pr19636-1j.d: Likewise.
126         * testsuite/ld-i386/pr19636-1k.d: Likewise.
127         * testsuite/ld-i386/pr19636-1l.d: Likewise.
128         * testsuite/ld-x86-64/pr19636-2j.d: Likewise.
129         * testsuite/ld-x86-64/pr19636-2k.d: Likewise.
130         * testsuite/ld-x86-64/pr19636-2l.d: Likewise.
131         * testsuite/ld-x86-64/pr19636-2m.d: Likewise.
132
133 2017-10-12  Alan Modra  <amodra@gmail.com>
134
135         PR 22269
136         * emultempl/elf32.em (after_parse): Warn on --no-dynamic-linker
137         -z dynamic-undefined-weak combination.  Set dynamic_undefined_weak
138         to zero when nointerp.
139
140 2017-10-12  Alan Modra  <amodra@gmail.com>
141
142         * emultempl/elf32.em (before_allocation): Call
143         elf_backend_hide_symbol, not _bfd_elf_link_hash_hide_symbol.
144         Formatting.
145
146 2017-10-11  H.J. Lu  <hongjiu.lu@intel.com>
147
148         * PR ld/22269
149         * testsuite/ld-elf/pr22269.s: New file.
150         * testsuite/ld-elf/pr22269a.d: Likewise.
151         * testsuite/ld-elf/pr22269b.d: Likewise.
152
153 2017-10-11  H.J. Lu  <hongjiu.lu@intel.com>
154
155         * testsuite/ld-i386/i386.exp: Run pr19636-1j, pr19636-1k,
156         pr19636-1l, pr19636-3h and pr19636-3i.
157         * testsuite/ld-i386/pr19636-1j.d: New file.
158         * testsuite/ld-i386/pr19636-1k.d: Likewise.
159         * testsuite/ld-i386/pr19636-1l.d: Likewise.
160         * testsuite/ld-i386/pr19636-3h.d: Likewise.
161         * testsuite/ld-i386/pr19636-3i.d: Likewise.
162         * testsuite/ld-x86-64/pr19636-1h.d: Likewise.
163         * testsuite/ld-x86-64/pr19636-1i.d: Likewise.
164         * testsuite/ld-x86-64/pr19636-1j.d: Likewise.
165         * testsuite/ld-x86-64/pr19636-2j.d: Likewise.
166         * testsuite/ld-x86-64/pr19636-2k.d: Likewise.
167         * testsuite/ld-x86-64/pr19636-2l.d: Likewise.
168         * testsuite/ld-x86-64/pr19636-2m.d: Likewise.
169         * testsuite/ld-x86-64/x86-64.exp: Run pr19636-1h, pr19636-1i,
170         pr19636-1j, pr19636-2j, pr19636-2k, pr19636-2l and pr19636-2m.
171
172 2017-10-11  Alan Modra  <amodra@gmail.com>
173
174         * emultempl/aarch64elf.em: Wrap einfo strings in _().  Formatting.
175         * emultempl/aix.em: Likewise.
176         * emultempl/armcoff.em: Likewise.
177         * emultempl/armelf.em: Likewise.
178         * emultempl/avrelf.em: Likewise.
179         * emultempl/beos.em: Likewise.
180         * emultempl/cr16elf.em: Likewise.
181         * emultempl/elf-generic.em: Likewise.
182         * emultempl/elf32.em: Likewise.
183         * emultempl/genelf.em: Likewise.
184         * emultempl/hppaelf.em: Likewise.
185         * emultempl/linux.em: Likewise.
186         * emultempl/lnk960.em: Likewise.
187         * emultempl/m68hc1xelf.em: Likewise.
188         * emultempl/m68kcoff.em: Likewise.
189         * emultempl/m68kelf.em: Likewise.
190         * emultempl/metagelf.em: Likewise.
191         * emultempl/mipself.em: Likewise.
192         * emultempl/mmix-elfnmmo.em: Likewise.
193         * emultempl/mmo.em: Likewise.
194         * emultempl/msp430.em: Likewise.
195         * emultempl/nds32elf.em: Likewise.
196         * emultempl/nios2elf.em: Likewise.
197         * emultempl/pe.em: Likewise.
198         * emultempl/pep.em: Likewise.
199         * emultempl/ppc32elf.em: Likewise.
200         * emultempl/ppc64elf.em: Likewise.
201         * emultempl/riscvelf.em: Likewise.
202         * emultempl/s390.em: Likewise.
203         * emultempl/scoreelf.em: Likewise.
204         * emultempl/spuelf.em: Likewise.
205         * emultempl/sunos.em: Likewise.
206         * emultempl/tic6xdsbt.em: Likewise.
207         * emultempl/v850elf.em: Likewise.
208         * emultempl/vms.em: Likewise.
209         * emultempl/vxworks.em: Likewise.
210         * ldcref.c: Likewise.
211         * ldlang.c: Likewise.
212         * ldlex.l: Likewise.
213         * ldmain.c: Likewise.
214         * pe-dll.c: Likewise.
215         * plugin.c: Likewise.
216
217 2017-10-10  Renlin Li  <renlin.li@arm.com>
218
219         PR ld/21402
220         * testsuite/ld-arm/tls-app.d: Update address.
221         * testsuite/ld-arm/tls-app.r: Remove relocations.
222         * testsuite/ld-arm/unresolved-1-dyn.d: Update.
223
224 2017-10-10  Alan Modra  <amodra@gmail.com>
225
226         * Makefile.am (earmelfb_fuchsia.c): Rename rule from earmelf_fuchsia.c.
227         * Makefile.in: Regenerate.
228
229 2017-10-09  Nick Clifton  <nickc@redhat.com>
230
231         * testsuite/ld-srec/srec.exp (run_srec_test): Set start address.
232
233         PR ld/19874
234         * testsuite/ld-x86-64/pr19784c.c (bar): Change return type to void.
235
236 2017-10-09  H.J. Lu  <hongjiu.lu@intel.com>
237
238         PR ld/22267
239         * ldlex.l (SYMBOLNAMECHAR1) New.
240         (DEFSYMEXP): Replace FILENAMECHAR1 with SYMBOLNAMECHAR1.
241         (EXPRESSION): Likewise.
242         * testsuite/ld-scripts/expr.exp: Run pr22267.
243         * testsuite/ld-scripts/pr22267.d: New file.
244         * testsuite/ld-scripts/pr22267.s: Likewise.
245         * testsuite/ld-scripts/pr22267.t: Likewise.
246
247 2017-10-07  H.J. Lu  <hongjiu.lu@intel.com>
248
249         * testsuite/ld-elf/merge.d: Don't expect to fail for sparc.
250
251 2017-10-05  Nick Clifton  <nickc@redhat.com>
252
253         * po/tr.po: Updated Turkish translation.
254
255 2017-10-05  Nick Clifton  <nickc@redhat.com>
256
257         PR 22262
258         * testsuite/ld-powerpc/relocsort.d: Update expected output (for
259         longer reloc names).
260
261 2017-10-05  Alan Modra  <amodra@gmail.com>
262
263         PR 21167
264         * testsuite/ld-elf/group9b.d: Adjust for relocs included in group.
265
266 2017-10-03  Alan Modra  <amodra@gmail.com>
267
268         PR 21294
269         * NEWS: Note that defaulting to -z relro results in increased
270         memory and disk size.
271
272 2017-10-03  Alan Modra  <amodra@gmail.com>
273
274         * ld.texinfo (-z relro): Expand description.
275         (DATA_SEGMENT_ALIGN): Note that -z relro is not effective when
276         running with system page size larger than commonpagesize.
277         (DATA_SEGMENT_RELRO_END): Be explicit about the alignment.
278
279 2017-10-01  Alan Modra  <amodra@gmail.com>
280
281         PR 21970
282         * ldlang.c (lang_leave_overlay): Reset overlay_subalign.
283
284 2017-09-30  H.J. Lu  <hongjiu.lu@intel.com>
285
286         PR binutils/21978
287         * testsuite/ld-elf/pr21978.od: New file.
288         * testsuite/ld-elf/pr21978a.c: Likewise.
289         * testsuite/ld-elf/pr21978b.c: Likewise.
290         * testsuite/ld-elf/shared.exp: Run PR binutils/21978 test.
291
292 2017-09-28  Nick Clifton  <nickc@redhat.com>
293
294         PR 14918
295         * testsuite/ld-plugin/lto.exp (link_elf_tests): Skip the pr14918
296         test for ARM targets as they always link with libgcc.
297
298 2017-09-28  Alan Modra  <amodra@gmail.com>
299
300         * testsuite/ld-plugin/pr22220.h,
301         * testsuite/ld-plugin/pr22220lib.cc,
302         * testsuite/ld-plugin/pr22220lib.ver,
303         * testsuite/ld-plugin/pr22220main.cc: New test.
304         * testsuite/ld-plugin/lto.exp: Run it.
305
306 2017-09-26  Maciej W. Rozycki  <macro@imgtec.com>
307
308         * testsuite/ld-undefined/undefined.exp: Correct the dyn reloc
309         test for MIPS and S+core targets.
310
311 2017-09-22  H.J. Lu  <hongjiu.lu@intel.com>
312
313         PR ld/22150
314         * testsuite/ld-elf/pr22150.vd: New file.
315         * testsuite/ld-elf/pr22150.ver: Likewise.
316         * testsuite/ld-elf/pr22150a.s: Likewise.
317         * testsuite/ld-elf/pr22150b.s: Likewise.
318         * testsuite/ld-elf/shared.exp: Run PR ld/22150 tests.
319
320 2017-09-21  Alan Modra  <amodra@gmail.com>
321
322         * testsuite/ld-powerpc/tlsopt5.wf: Update for reduced alignment.
323
324 2017-09-19  Maciej W. Rozycki  <macro@imgtec.com>
325
326         * configure.tgt <mips64el-*-openbsd*, mips64-*-openbsd*>: New
327         targets.
328
329 2017-09-15  Alan Modra  <amodra@gmail.com>
330
331         PR 22118
332         * testsuite/ld-aarch64/erratum843419.d: Correct regexp.
333
334 2017-09-14  H.J. Lu  <hongjiu.lu@intel.com>
335
336         PR ld/22139
337         * testsuite/ld-elf/globalaudit.rd: Allow additional bits in
338         DT_FLAGS_1.
339
340 2017-09-14  H.J. Lu  <hongjiu.lu@intel.com>
341
342         PR ld/22135
343         * testsuite/ld-i386/i386.exp: Run pr22135.
344         * testsuite/ld-x86-64/x86-64.exp: Likewise.
345         * testsuite/ld-i386/pr22135.d: New file.
346         * testsuite/ld-i386/pr22135.s: Likewise.
347         * testsuite/ld-x86-64/pr22135.d: Likewise.
348         * testsuite/ld-x86-64/pr22135.s: Likewise.
349
350 2017-09-09  Alan Modra  <amodra@gmail.com>
351
352         * ld.texinfo (--plt-align): Describe new behaviour of option.
353         * emultempl/ppc64elf.em (params): Default plt_stub_align to 5.
354         * testsuite/ld-powerpc/powerpc.exp: Pass --no-plt-align for
355         selected tests.
356         * testsuite/ld-powerpc/relbrlt.d: Pass --no-plt-align.
357         * testsuite/ld-powerpc/elfv2so.d: Adjust expected output.
358
359 2017-09-09  H.J. Lu  <hongjiu.lu@intel.com>
360
361         PR ld/22115
362         * ld-i386/i386.exp: Run PR ld/22115 tests,
363         * ld/testsuite/ld-x86-64/x86-64.exp: Likewise.
364         * testsuite/ld-i386/pr22115-1.s: New file.
365         * testsuite/ld-i386/pr22115-1a.d: Likewise.
366         * testsuite/ld-i386/pr22115-1b.d: Likewise.
367         * testsuite/ld-i386/pr22115-1c.d: Likewise.
368         * testsuite/ld-i386/pr22115-1d.d: Likewise.
369         * testsuite/ld-x86-64/pr22115-1.s: Likewise.
370         * testsuite/ld-x86-64/pr22115-1a-x32.d: Likewise.
371         * testsuite/ld-x86-64/pr22115-1a.d: Likewise.
372         * testsuite/ld-x86-64/pr22115-1b-x32.d: Likewise.
373         * testsuite/ld-x86-64/pr22115-1b.d: Likewise.
374         * testsuite/ld-x86-64/pr22115-1c-x32.d: Likewise.
375         * testsuite/ld-x86-64/pr22115-1c.d: Likewise.
376         * testsuite/ld-x86-64/pr22115-1d-x32.d: Likewise.
377         * testsuite/ld-x86-64/pr22115-1d.d: Likewise.
378
379 2017-09-06  H.J. Lu  <hongjiu.lu@intel.com>
380
381         * testsuite/ld-x86-64/pr19609-2a.d: Updated.
382         * testsuite/ld-x86-64/pr19609-2b.d: Likewise.
383         * testsuite/ld-x86-64/pr19609-4a.d: Likewise.
384         * testsuite/ld-x86-64/pr19609-4c.d: Likewise.
385
386 2017-09-05  H.J. Lu  <hongjiu.lu@intel.com>
387
388         * testsuite/ld-x86-64/pr19609-5d.d: Updated.
389         * testsuite/ld-x86-64/pr19609-7a.d: Likewise.
390         * testsuite/ld-x86-64/pr19609-7c.d: Likewise.
391
392 2017-09-05  H.J. Lu  <hongjiu.lu@intel.com>
393
394         * testsuite/ld-x86-64/pr19609-4e.d: Updated.
395         * testsuite/ld-x86-64/pr19609-6a.d: Likewise.
396
397 2017-09-03  H.J. Lu  <hongjiu.lu@intel.com>
398
399         PR ld/22071
400         * testsuite/ld-x86-64/pr22071.d: New file.
401         * testsuite/ld-x86-64/pr22071.s: Likewise.
402         * testsuite/ld-x86-64/x86-64.exp: Run pr22071.
403
404 2017-09-02  Alan Modra  <amodra@gmail.com>
405
406         * ldlang.h (lang_input_statement_type): Expand comments.
407         (LANG_FOR_EACH_INPUT_STATEMENT): Rewrite without casts.
408         * ldlang.c (lang_for_each_input_file): Likewise.
409         (load_symbols): Set usrdata for archives.
410         (find_rescan_insertion): New function.
411         (lang_process): Trim off and reinsert entries added to file chain
412         when rescanning archives for LTO.
413         * ldmain.c (add_archive_element): Set my_archive input_statement
414         next pointer to last element added.
415
416 2017-09-01  H.J. Lu  <hongjiu.lu@intel.com>
417
418         PR ld/22064
419         * testsuite/ld-x86-64/pr22064a.S: New file.
420         * testsuite/ld-x86-64/pr22064b.c: Likewise.
421         * testsuite/ld-x86-64/x86-64.exp: Run PR ld/22064 test.
422
423 2017-09-02  Alan Modra  <amodra@gmail.com>
424
425         * emultempl/msp430.em (eval_upper_either_sections): Make base_sec_name
426         a const char*.
427         (eval_lower_either_sections): Likewise.
428         (msp430_elf_after_allocation): Likewise, and don't needlessly concat
429         and free.  Warning fix.
430
431 2017-09-01  H.J. Lu  <hongjiu.lu@intel.com>
432
433         PR ld/22061
434         * testsuite/ld-i386/ibt-plt-1.d: Updated.
435         * testsuite/ld-i386/ibt-plt-2a.d: Likewise.
436         * testsuite/ld-i386/ibt-plt-2c.d: Likewise.
437         * testsuite/ld-i386/ibt-plt-3a.d: Likewise.
438         * testsuite/ld-i386/ibt-plt-3c.d: Likewise.
439         * testsuite/ld-x86-64/ibt-plt-1-x32.d: Likewise.
440         * testsuite/ld-x86-64/ibt-plt-2a-x32.d: Likewise.
441         * testsuite/ld-x86-64/ibt-plt-2c-x32.d: Likewise.
442         * testsuite/ld-x86-64/ibt-plt-3a-x32.d: Likewise.
443         * testsuite/ld-x86-64/ibt-plt-3c-x32.d: Likewise.
444         * testsuite/ld-i386/ibt-plt-2b.d: Pass --hash-style=sysv to ld
445         and dump unwind information.
446         * testsuite/ld-i386/ibt-plt-2d.d: Likewise.
447         * testsuite/ld-i386/ibt-plt-3b.d: Likewise.
448         * testsuite/ld-i386/ibt-plt-3d.d: Likewise.
449         * testsuite/ld-x86-64/ibt-plt-2b-x32.d: Likewise.
450         * testsuite/ld-x86-64/ibt-plt-2b.d: Likewise.
451         * testsuite/ld-x86-64/ibt-plt-2d-x32.d: Likewise.
452         * testsuite/ld-x86-64/ibt-plt-2d.d: Likewise.
453         * testsuite/ld-x86-64/ibt-plt-3b-x32.d: Likewise.
454         * testsuite/ld-x86-64/ibt-plt-3b.d: Likewise.
455         * testsuite/ld-x86-64/ibt-plt-3d-x32.d: Likewise.
456         * testsuite/ld-x86-64/ibt-plt-3d.d: Likewise.
457
458 2017-08-31  H.J. Lu  <hongjiu.lu@intel.com>
459
460         PR ld/22048
461         * testsuite/ld-x86-64/pr22048.d: New file.
462         * testsuite/ld-x86-64/pr22048a.s: Likewise.
463         * testsuite/ld-x86-64/pr22048b.s: Likewise.
464         * testsuite/ld-x86-64/x86-64.exp: Run pr22048.
465
466 2017-08-31  Alan Modra  <amodra@gmail.com>
467
468         * testsuite/ld-elf/eh3.d: Update.
469         * testsuite/ld-elf/eh4.d: Update.
470
471 2017-08-30  Maciej W. Rozycki  <macro@imgtec.com>
472
473         * testsuite/ld-elf/orphan-11.ld: Also discard `.MIPS.options'
474         sections.
475
476 2017-08-30  Maciej W. Rozycki  <macro@imgtec.com>
477
478         * testsuite/ld-mips-elf/bal-jalx-addend-micromips.d: New test.
479         * testsuite/ld-mips-elf/bal-jalx-addend-micromips-n32.d: New
480         test.
481         * testsuite/ld-mips-elf/bal-jalx-addend-micromips-n64.d: New
482         test.
483         * testsuite/ld-mips-elf/bal-jalx-local-micromips.d: New test.
484         * testsuite/ld-mips-elf/bal-jalx-local-micromips-n32.d: New
485         test.
486         * testsuite/ld-mips-elf/bal-jalx-local-micromips-n64.d: New
487         test.
488         * testsuite/ld-mips-elf/bal-jalx-pic-micromips.d: New test.
489         * testsuite/ld-mips-elf/bal-jalx-pic-micromips-n32.d: New test.
490         * testsuite/ld-mips-elf/bal-jalx-pic-micromips-n64.d: New test.
491         * testsuite/ld-mips-elf/bal-jalx-pic-ignore-micromips.d: New
492         test.
493         * testsuite/ld-mips-elf/bal-jalx-pic-ignore-micromips-n32.d: New
494         test.
495         * testsuite/ld-mips-elf/bal-jalx-pic-ignore-micromips-n64.d: New
496         test.
497         * testsuite/ld-mips-elf/mips-elf.exp: Run the new tests.
498
499 2017-08-30  Alan Modra  <amodra@gmail.com>
500
501         * testsuite/ld-powerpc/tls.s: Add calls with tls markers.
502         * testsuite/ld-powerpc/tls32.s: Likewise.
503         * testsuite/ld-powerpc/powerpc.exp: Run tls marker tests.
504         * testsuite/ld-powerpc/tls.d: Adjust for TPREL16_HA/LO optimization.
505         * testsuite/ld-powerpc/tlsexe.d: Likewise.
506         * testsuite/ld-powerpc/tlsexetoc.d: Likewise.
507         * testsuite/ld-powerpc/tlsld.d: Likewise.
508         * testsuite/ld-powerpc/tlsmark.d: Likewise.
509         * testsuite/ld-powerpc/tlsopt4.d: Likewise.
510         * testsuite/ld-powerpc/tlstoc.d: Likewise.
511
512 2017-08-30  Alan Modra  <amodra@gmail.com>
513
514         * testsuite/ld-powerpc/tls.d: Update.
515         * testsuite/ld-powerpc/tlsexe.d: Update.
516         * testsuite/ld-powerpc/tlsexetoc.d: Update.
517         * testsuite/ld-powerpc/tlsld.d: Update.
518         * testsuite/ld-powerpc/tlsmark.d: Update.
519         * testsuite/ld-powerpc/tlsopt4.d: Update.
520         * testsuite/ld-powerpc/tlstoc.d: Update.
521
522 2017-08-30  Hans-Peter Nilsson  <hp@axis.com>
523
524         * testsuite/ld-cris/dso-pltdis1.d: Run ld with --hash-style=sysv.
525         * testsuite/ld-cris/dso-pltdis2.d,
526         testsuite/ld-cris/dso12-pltdis.d, testsuite/ld-cris/expdyn1.d,
527         testsuite/ld-cris/expdyn5.d, testsuite/ld-cris/expdyn6.d,
528         testsuite/ld-cris/expdyn7.d, testsuite/ld-cris/gotplt1.d,
529         testsuite/ld-cris/gotplt2.d, testsuite/ld-cris/gotplt3.d,
530         testsuite/ld-cris/hiddef1.d, testsuite/ld-cris/libdso-11.d,
531         testsuite/ld-cris/libdso-12.d, testsuite/ld-cris/libdso-12b.d,
532         testsuite/ld-cris/libdso-12c.d, testsuite/ld-cris/libdso-13.d,
533         testsuite/ld-cris/libdso-13b.d, testsuite/ld-cris/libdso-14.d,
534         testsuite/ld-cris/libdso-15.d, testsuite/ld-cris/libdso-15b.d,
535         testsuite/ld-cris/libdso-1b.d, testsuite/ld-cris/libdso-1c.d,
536         testsuite/ld-cris/libdso-1d.d, testsuite/ld-cris/libdso-4.d,
537         testsuite/ld-cris/pr16044.d, testsuite/ld-cris/pv32-1.d,
538         testsuite/ld-cris/tls-dso-dtpoffd2.d,
539         testsuite/ld-cris/tls-dso-dtpoffd4.d,
540         testsuite/ld-cris/tls-dso-tpoffgotcomm1.d,
541         testsuite/ld-cris/tls-dso-x1x2-1.d, testsuite/ld-cris/tls-gc-71.d,
542         testsuite/ld-cris/tls-ie-78.d, testsuite/ld-cris/tls-js1.d,
543         testsuite/ld-cris/tls-ldgdex-14.d,
544         testsuite/ld-cris/tls-ldgdex-15.d,
545         testsuite/ld-cris/tls-legdx-16.d,
546         testsuite/ld-cris/tls-legdx-17.d,
547         testsuite/ld-cris/tls-local-63.d,
548         testsuite/ld-cris/tls-local-64.d, testsuite/ld-cris/tls-ok-30.d,
549         testsuite/ld-cris/tls-ok-32.d, testsuite/ld-cris/tls-ok-34.d,
550         testsuite/ld-cris/tls-und-38.d, testsuite/ld-cris/tls-und-42.d,
551         testsuite/ld-cris/tls-und-46.d, testsuite/ld-cris/tls-und-50.d,
552         testsuite/ld-cris/weakref2.d, testsuite/ld-cris/weakref3.d,
553         testsuite/ld-cris/weakref4.d: Likewise.
554
555 2017-08-29  Jozef Lawrynowicz  <jozef.l@somniumtech.com>
556
557         * emultempl/msp430.em (change_output_section): New function.
558         (move_prefixed_section): New function.
559         (add_region_prefix): New function.
560         (msp430_elf_after_open): New function.
561         (gld${EMULATION_NAME}_add_options): Implement.
562         (gld${EMULATION_NAME}_list_options): Implement.
563         (gld${EMULATION_NAME}_handle_option): Implement.
564         * ld.texinfo: Document new options.
565         * testsuite/ld-msp430-elf/main-bss-lower.d: New.
566         * testsuite/ld-msp430-elf/main-bss-upper.d: New.
567         * testsuite/ld-msp430-elf/main-const-lower.d: New.
568         * testsuite/ld-msp430-elf/main-const-upper.d: New.
569         * testsuite/ld-msp430-elf/main-text-lower.d: New.
570         * testsuite/ld-msp430-elf/main-text-upper.d: New.
571         * testsuite/ld-msp430-elf/main-var-lower.d: New.
572         * testsuite/ld-msp430-elf/main-var-upper.d: New.
573         * testsuite/ld-msp430-elf/main-with-data-bss-unique-sec.s: New.
574         * testsuite/ld-msp430-elf/main-with-data-bss.s: New.
575         * testsuite/ld-msp430-elf/main-with-text-rodata-unique-sec.s: New.
576         * testsuite/ld-msp430-elf/main-with-text-rodata.s: New.
577         * testsuite/ld-msp430-elf/msp430-elf.exp: New.
578         * testsuite/ld-msp430-elf/msp430-no-lower.ld: New.
579         * testsuite/ld-msp430-elf/msp430.ld: New.
580         * emultempl/msp430.em (data_statement_size): New.
581         (eval_upper_either_sections): New.
582         (eval_lower_either_sections): New.
583         (intermediate_relax_sections): New.
584         (msp430_elf_after_allocation): New.
585         * emultempl/msp430.em (gld${EMULATION_NAME}_place_orphan): Always
586         place sections in the lower region.
587
588 2017-08-26  H.J. Lu  <hongjiu.lu@intel.com>
589
590         PR ld/21997
591         * testsuite/ld-i386/i386.exp: Run PR ld/21997 tests.
592         * testsuite/ld-x86-64/x86-64.exp: Likewise.
593         * testsuite/ld-i386/pr21997-1a.S: New file.
594         * testsuite/ld-i386/pr21997-1b.c: Likewise.
595         * testsuite/ld-i386/pr21997-1c.S: Likewise.
596         * testsuite/ld-x86-64/pr21997-1a.S: Likewise.
597         * testsuite/ld-x86-64/pr21997-1a.err: Likewise.
598         * testsuite/ld-x86-64/pr21997-1b.c: Likewise.
599         * testsuite/ld-x86-64/pr21997-1b.err: Likewise.
600         * testsuite/ld-x86-64/pr21997-1c.c: Likewise.
601
602 2017-08-24  H.J. Lu  <hongjiu.lu@intel.com>
603
604         * testsuite/ld-elf/pr21903c.d: Remove '\' before --.
605         * testsuite/ld-elf/pr21903d.d: Likewise.
606         * testsuite/ld-elf/pr21903e.d: Likewise.
607         * testsuite/lib/ld-lib.exp (run_dump_test): Add "--" after
608         regexp.
609
610 2017-08-24  H.J. Lu  <hongjiu.lu@intel.com>
611
612         * testsuite/ld-i386/i386.exp (undefined_weak): Replace regexp
613         with string match.
614         * testsuite/ld-x86-64/x86-64.exp (undefined_weak): Likewise.
615
616 2017-08-24  H.J. Lu  <hongjiu.lu@intel.com>
617
618         * testsuite/ld-x86-64/x86-64.exp: Run pr22001-1b on x32.
619
620 2017-08-24  H.J. Lu  <hongjiu.lu@intel.com>
621
622         PR ld/22001
623         * testsuite/ld-i386/i386.exp: Run -z nocopyreloc tests.
624         * testsuite/ld-x86-64/x86-64.exp: Likewise.
625         * testsuite/ld-i386/pr22001-1a.c: New file.
626         * testsuite/ld-i386/pr22001-1b.c: Likewise.
627         * testsuite/ld-i386/pr22001-1c.S: Likewise.
628         * testsuite/ld-x86-64/pr22001-1a.c: Likewise.
629         * testsuite/ld-x86-64/pr22001-1a.err: Likewise.
630         * testsuite/ld-x86-64/pr22001-1b.c: Likewise.
631         * testsuite/ld-x86-64/pr22001-1b.err: Likewise.
632         * testsuite/ld-x86-64/pr22001-1c.c: Likewise.
633
634 2017-08-17  Andrew Burgess  <andrew.burgess@embecosm.com>
635
636         PR 21961
637         * ldlang.c (lang_discard_section_p): New function.
638         (lang_add_section): Checks moved out into new function, which is
639         now called.
640         (lang_place_orphans): Call lang_discard_section_p instead of
641         duplicating some of the checks from lang_add_section.
642         * testsuite/ld-elf/orphan-11.d: New file.
643         * testsuite/ld-elf/orphan-11.ld: New file.
644         * testsuite/ld-elf/orphan-11.s: New file.
645         * testsuite/ld-elf/orphan-12.d: New file.
646         * testsuite/ld-elf/orphan-12.s: New file.
647
648 2017-08-24  Alan Modra  <amodra@gmail.com>
649
650         * testsuite/ld-undefined/fundef.s: New test.
651         * testsuite/ld-undefined/undefined.exp: Test that undefined
652         symbols in shared libraries are made dynamic.
653
654 2017-08-23  H.J. Lu  <hongjiu.lu@intel.com>
655
656         * testsuite/ld-elf/pr21903c.d: Add '\' before --.
657         * testsuite/ld-elf/pr21903d.d: Likewise.
658         * testsuite/ld-elf/pr21903e.d: Likewise.
659
660 2017-08-23  H.J. Lu  <hongjiu.lu@intel.com>
661
662         * testsuite/ld-x86-64/pie2.d: Updated.
663         * testsuite/ld-x86-64/pr19719.d: Likewise.
664         * testsuite/ld-x86-64/pr19807-2a.d: Likewise.
665         * testsuite/ld-x86-64/pr19969.d: Likewise.
666
667 2017-08-23  H.J. Lu  <hongjiu.lu@intel.com>
668
669         * testsuite/ld-i386/i386.exp: Run protected7.
670         * testsuite/ld-i386/protected7.d: New file.
671         * testsuite/ld-i386/protected7.s: Likewise.
672         * testsuite/ld-x86-64/protected8.d: Likewise.
673         * testsuite/ld-x86-64/protected8.s: Likewise.
674         * testsuite/ld-x86-64/x86-64.exp: Run protected8.
675
676 2017-08-23  Alan Modra  <amodra@gmail.com>
677
678         * testsuite/ld-gc/pr19161.d: Don't xfail hppa.
679
680 2017-08-22  H.J. Lu  <hongjiu.lu@intel.com>
681             Alan Modra  <amodra@gmail.com>
682
683         * testsuite/ld-elf/pr21964-1a.c (foo): Renamed to ...
684         (foo1): This.
685         * testsuite/ld-elf/pr21964-1b.c: Rewrite.
686         * testsuite/ld-elf/pr21964-1c.c: New file.
687         * testsuite/ld-elf/pr21964-2c.c: Likewise.
688         * testsuite/ld-elf/pr21964-2a.c (foo): Renamed to ...
689         (foo1): This.
690         * testsuite/ld-elf/pr21964-2b.c: Rewrite.
691         * testsuite/ld-elf/shared.exp: Update PR ld/21964 tests.
692
693 2017-08-21  H.J. Lu  <hongjiu.lu@intel.com>
694             Alan Modra  <amodra@gmail.com>
695
696         PR ld/21964
697         * testsuite/ld-elf/pr21562a.d: Update for changed start/stop symbols.
698         * testsuite/ld-elf/pr21562b.d: Likewise.
699         * testsuite/ld-elf/pr21562c.d: Likewise.
700         * testsuite/ld-elf/pr21562d.d: Likewise.
701         * testsuite/ld-elf/pr21562e.d: Likewise.
702         * testsuite/ld-elf/pr21562f.d: Likewise.
703         * testsuite/ld-elf/pr21562g.d: Likewise.
704         * testsuite/ld-elf/pr21562h.d: Likewise.
705         * testsuite/ld-elf/pr21562i.d: Likewise.
706         * testsuite/ld-elf/pr21562j.d: Likewise.
707         * testsuite/ld-elf/pr21562k.d: Likewise.
708         * testsuite/ld-elf/pr21562l.d: Likewise.
709         * testsuite/ld-elf/pr21562m.d: Likewise.
710         * testsuite/ld-elf/pr21562n.d: Likewise.
711         * testsuite/ld-elf/sizeofa.d: Likewise.
712         * testsuite/ld-elf/sizeofb.d: Likewise.
713         * testsuite/ld-elf/startofa.d: Likewise.
714         * testsuite/ld-elf/startofb.d: Likewise.
715         * testsuite/ld-gc/pr20022.d: Likewise.
716         * testsuite/ld-gc/start.d: Likewise.
717         * testsuite/ld-elf/pr21964-1a.c: New file.
718         * testsuite/ld-elf/pr21964-1b.c: New file.
719         * testsuite/ld-elf/pr21964-2a.c: New file.
720         * testsuite/ld-elf/pr21964-2b.c: New file.
721         * testsuite/ld-elf/shared.exp: Run PR ld/21964 tests.
722
723 2017-08-21  Hans-Peter Nilsson  <hp@bitrange.com>
724
725         PR ld/20125
726         * testsuite/ld-mmix/pr20125.d, testsuite/ld-mmix/pr20125.s: New
727         test.
728
729 2017-08-20  A. Wilcox  <awilfox@adelielinux.org>
730
731         PR ld/21976
732         * testsuite/ld-x86-64/plt-main-bnd.dd: Accept '_' in symbol
733         name.
734
735 2017-08-17  Nick Clifton  <nickc@redhat.com>
736
737         * po/pt_BR.po: New Brazilian Portuguese translation.
738         * configure.ac (ALL_LINGUAS): Add pt_BR.
739         * configure: Regenerate.
740
741 2017-08-14  Alan Modra  <amodra@gmail.com>
742
743         PR 21441
744         * testsuite/ld-x86-64/pr21038a.d: Adjust.
745         * testsuite/ld-x86-64/pr21038a-now.d: Adjust.
746
747 2017-08-13  H.J. Lu  <hongjiu.lu@intel.com>
748
749         * testsuite/ld-i386/i386.exp: Run pr21884-nacl.
750         * testsuite/ld-x86-64/x86-64.exp: Likewise.
751         * testsuite/ld-i386/pr21884.d: Don't run on nacl targets.
752         * testsuite/ld-x86-64/pr21884.d: Likewise.
753         * testsuite/ld-i386/pr21884.t: Revert the last change.
754         * testsuite/ld-x86-64/pr21884.t: Likewise.
755         * testsuite/ld-i386/pr21884-nacl.d: New file.
756         * testsuite/ld-i386/pr21884-nacl.t: Likewise.
757         * testsuite/ld-x86-64/pr21884-nacl.d: Likewise.
758         * testsuite/ld-x86-64/pr21884-nacl.t: Likewise.
759
760 2017-08-13  Alan Modra  <amodra@gmail.com>
761
762         * testsuite/ld-i386/pr21884.t: Remove unneeded format, arch and entry.
763         * testsuite/ld-x86-64/pr21884.t: Likewise.
764
765 2017-08-11  Nick Clifton  <nickc@redhat.com>
766
767         * emultempl/elf32.em (handle_option): Accept the -z globalaudit
768         command line option.
769         * lexsup.c (elf_static_list_options): Add -z globalaudit.
770         * ld.texinfo: Document the support for the new command line
771         option.
772         * NEWS: Mention the new feature.
773         * testsuite/ld-elf/audit.exp: Add a test of the -z globalaudit
774         command line option.
775         * testsuite/ld-elf/globalaudit.rd: New file: Expected output from
776         readelf.
777
778 2017-08-11  H.J. Lu  <hongjiu.lu@intel.com>
779
780         PR ld/21884
781         * testsuite/ld-i386/i386.exp: Run pr21884.
782         * testsuite/ld-x86-64/x86-64.exp: Likewise.
783         * testsuite/ld-i386/pr21884.d: New file.
784         * testsuite/ld-i386/pr21884.t: Likewise.
785         * testsuite/ld-x86-64/pr21884.d: Likewise.
786         * testsuite/ld-x86-64/pr21884.t: Likewise.
787
788 2017-08-10  Nick Clifton  <nickc@redhat.com>
789
790         * scripttempl/pep.sc: Enclose __CTOR_LIST__, ___CTOR_LIST__,
791         __DTOR_LIST__ and ___DTOR_LIST__ in PROVIDE statements so that
792         they can be overrridden by crt input files.
793         * scripttempl/pe.sc: Likewise.
794
795 2017-08-09  H.J. Lu  <hongjiu.lu@intel.com>
796
797         * testsuite/config/default.exp (LD_CLASS): Check .libs/ld-new
798         for linker first.
799
800 2017-08-09  H.J. Lu  <hongjiu.lu@intel.com>
801
802         * testsuite/config/default.exp (LD_CLASS): New.  Set to "64bit"
803         for 64-bit ELF linker.
804         * testsuite/ld-x86-64/pr17618.d (#notarget): Removed.
805         * testsuite/ld-x86-64/x86-64.exp: Run pr17618 only for 64-bit
806         linker.
807
808 2017-08-08  H.J. Lu  <hongjiu.lu@intel.com>
809
810         PR ld/21924
811         * testsuite/ld-i386/i386.exp: Require GCC 5 or above for
812         "weakundef1 with PIE" test.
813         * testsuite/ld-x86-64/tls.exp: Require GCC 5 or above for
814         "tlsdesc1" and "tlsdesc1 with PIE" tests.
815
816 2017-08-08  H.J. Lu  <hongjiu.lu@intel.com>
817
818         * configure.ac (TESTBFDLIB): Add a ',' after -Wl,--rpath.
819         * configure: Regenerated.
820
821 2017-08-08  H.J. Lu  <hongjiu.lu@intel.com>
822
823         PR ld/21923
824         * configure.ac (TESTBFDLIB): Replace --rpath with -Wl,--rpath
825         for --disable-static.
826         * configure: Regenerated.
827
828 2017-08-08  Romain Geissler  <romain.geissler@gmail.com>
829             Alan Modra  <amodra@gmail.com>
830
831         * configure.ac: Add --enable-default-hash-style option.
832         * ldmain.c (main): Set link_info.emit_hash to DEFAULT_EMIT_SYSV_HASH.
833         Set link_info.emit_gnu_hash to DEFAULT_EMIT_GNU_HASH.
834         * configure: Regenerate.
835         * config.in: Regenerate.
836
837 2017-08-08  Alan Modra  <amodra@gmail.com>
838
839         * testsuite/ld-aarch64/ifunc-1-local.d: Run ld with --hash-style=sysv.
840         * testsuite/ld-aarch64/ifunc-2-local.d: Likewise.
841         * testsuite/ld-aarch64/ifunc-3a.d: Likewise.
842         * testsuite/ld-frv/fdpic-pie-1.d: Likewise.
843         * testsuite/ld-frv/fdpic-pie-2.d: Likewise.
844         * testsuite/ld-frv/fdpic-pie-7.d: Likewise.
845         * testsuite/ld-frv/fdpic-pie-8.d: Likewise.
846         * testsuite/ld-arm/arm-elf.exp: Add --hash-style=sysv to "Using
847         Thumb lib by another lib" test's ld options.
848         * testsuite/ld-elf/note-3.l: Match .gnu.hash.
849         * testsuite/ld-elf/note-3.t: Add .gnu.hash output section.
850
851 2017-08-07  H.J. Lu  <hongjiu.lu@intel.com>
852
853         * testsuite/ld-elf/pr21903.s (start): Removed.
854         (_start): Likewise.
855         (__start): Likewise.
856         (main): Likewise.
857         (bar): New.
858
859 2017-08-07  Alan Modra  <amodra@gmail.com>
860
861         * testsuite/ld-alpha/alpha.exp: Add --hash-style=sysv to various
862         test's ld options.
863         * testsuite/ld-arm/arm-elf.exp: Likewise.
864         * testsuite/ld-elf/elf.exp: Likewise.
865         * testsuite/ld-elf/readelf.exp: Likewise.
866         * testsuite/ld-elfvsb/elfvsb.exp: Likewise.
867         * testsuite/ld-i386/i386.exp: Likewise.
868         * testsuite/ld-ia64/ia64.exp: Likewise.
869         * testsuite/ld-m68k/m68k.exp: Likewise.
870         * testsuite/ld-metag/metag.exp: Likewise.
871         * testsuite/ld-powerpc/powerpc.exp: Likewise.
872         * testsuite/ld-s390/s390.exp: Likewise.
873         * testsuite/ld-sh/sh-vxworks.exp: Likewise.
874         * testsuite/ld-shared/shared.exp: Likewise.
875         * testsuite/ld-sparc/sparc.exp: Likewise.
876         * testsuite/ld-tic6x/tic6x.exp: Likewise.
877         * testsuite/ld-vax-elf/vax-elf.exp: Likewise.
878         * testsuite/ld-x86-64/mpx.exp: Likewise.
879         * testsuite/ld-x86-64/x86-64.exp: Likewise.
880         * testsuite/ld-xtensa/xtensa.exp: Likewise.
881
882         * testsuite/ld-elf/comm-data2.ld: Add .gnu.hash output section.
883         * testsuite/ld-elf/pr20828-v.ld: Likewise.
884         * testsuite/ld-elf/pr20828.ld: Likewise.
885         * testsuite/ld-elf/pr21233.ld: Likewise.
886         * testsuite/ld-elf/pr21384.ld: Likewise.
887         * testsuite/ld-elf/provide-hidden-1.ld: Likewise.
888         * testsuite/ld-elf/provide-hidden-2.ld: Likewise.
889         * testsuite/ld-elf/provide-hidden-s.ld: Likewise.
890         * testsuite/ld-scripts/cross1.t: Likewise.
891
892         * testsuite/ld-elf/stab.d: Adjust allowed section indices.
893
894         * testsuite/ld-i386/pie1.d: Don't match addresses.
895         * testsuite/ld-i386/plt-pic2.dd: Likewise.
896         * testsuite/ld-i386/pr19636-1d.d: Likewise.
897         * testsuite/ld-i386/pr19636-2c.d: Likewise.
898         * testsuite/ld-powerpc/elfv2so.d: Likewise.
899         * testsuite/ld-powerpc/tlsopt5.d: Likewise.
900         * testsuite/ld-powerpc/tlsopt5.wf: Likewise.
901         * testsuite/ld-powerpc/tlsopt5_32.d: Likewise.
902
903         * testsuite/ld-i386/pr19636-2b.d: Don't match _start.
904
905         * testsuite/ld-powerpc/ambiguousv1.d: Relax symbol count, index
906         and address match.
907         * testsuite/ld-powerpc/ambiguousv1b.d: Likewise.
908         * testsuite/ld-powerpc/ambiguousv2.d: Likewise.
909         * testsuite/ld-powerpc/ambiguousv2b.d: Likewise.
910
911         * testsuite/ld-aarch64/gc-plt-relocs.d: Run ld with --hash-style=sysv.
912         * testsuite/ld-aarch64/ifunc-1.d: Likewise.
913         * testsuite/ld-aarch64/ifunc-2.d: Likewise.
914         * testsuite/ld-aarch64/ifunc-21.d: Likewise.
915         * testsuite/ld-aarch64/relasz.d: Likewise.
916         * testsuite/ld-aarch64/tls-small-ld.d: Likewise.
917         * testsuite/ld-aarch64/tls-tiny-ld.d: Likewise.
918         * testsuite/ld-arc/tls_gd-01.d: Likewise.
919         * testsuite/ld-cris/libdso-10.d: Likewise.
920         * testsuite/ld-cris/libdso-2.d: Likewise.
921         * testsuite/ld-cris/pic-gc-72.d: Likewise.
922         * testsuite/ld-cris/pic-gc-73.d: Likewise.
923         * testsuite/ld-cris/tls-gd-1.d: Likewise.
924         * testsuite/ld-cris/tls-gd-1h.d: Likewise.
925         * testsuite/ld-cris/tls-gd-2.d: Likewise.
926         * testsuite/ld-cris/tls-gd-2h.d: Likewise.
927         * testsuite/ld-cris/tls-ie-10.d: Likewise.
928         * testsuite/ld-cris/tls-ie-11.d: Likewise.
929         * testsuite/ld-cris/tls-ie-8.d: Likewise.
930         * testsuite/ld-cris/tls-ie-9.d: Likewise.
931         * testsuite/ld-cris/tls-ld-4.d: Likewise.
932         * testsuite/ld-cris/tls-ld-5.d: Likewise.
933         * testsuite/ld-cris/tls-ld-6.d: Likewise.
934         * testsuite/ld-cris/tls-ld-7.d: Likewise.
935         * testsuite/ld-cris/tls-ldgd-14.d: Likewise.
936         * testsuite/ld-cris/tls-ldgd-15.d: Likewise.
937         * testsuite/ld-cris/tls-ldgdx-14.d: Likewise.
938         * testsuite/ld-cris/tls-ldgdx-15.d: Likewise.
939         * testsuite/ld-cris/tls-local-54.d: Likewise.
940         * testsuite/ld-cris/tls-local-60.d: Likewise.
941         * testsuite/ld-cris/tls-local-61.d: Likewise.
942         * testsuite/ld-cris/weakhiddso.d: Likewise.
943         * testsuite/ld-elf/linkinfo1a.d: Likewise.
944         * testsuite/ld-elf/linkinfo1b.d: Likewise.
945         * testsuite/ld-elf/pr19617a.d: Likewise.
946         * testsuite/ld-elfvsb/hidden2.d: Likewise.
947         * testsuite/ld-frv/fdpic-pie-6.d: Likewise.
948         * testsuite/ld-frv/fdpic-shared-2.d: Likewise.
949         * testsuite/ld-frv/fdpic-shared-5.d: Likewise.
950         * testsuite/ld-frv/fdpic-shared-6.d: Likewise.
951         * testsuite/ld-frv/fdpic-shared-8.d: Likewise.
952         * testsuite/ld-frv/fdpic-shared-local-2.d: Likewise.
953         * testsuite/ld-frv/fdpic-shared-local-8.d: Likewise.
954         * testsuite/ld-frv/tls-dynamic-2.d: Likewise.
955         * testsuite/ld-i386/ibt-plt-1.d: Likewise.
956         * testsuite/ld-i386/ibt-plt-2a.d: Likewise.
957         * testsuite/ld-i386/ibt-plt-2c.d: Likewise.
958         * testsuite/ld-i386/ibt-plt-3a.d: Likewise.
959         * testsuite/ld-i386/ibt-plt-3c.d: Likewise.
960         * testsuite/ld-i386/pr20830.d: Likewise.
961         * testsuite/ld-ia64/merge1.d: Likewise.
962         * testsuite/ld-ia64/merge2.d: Likewise.
963         * testsuite/ld-ia64/merge3.d: Likewise.
964         * testsuite/ld-ia64/merge4.d: Likewise.
965         * testsuite/ld-ia64/merge5.d: Likewise.
966         * testsuite/ld-ifunc/ifunc-1-local-x86.d: Likewise.
967         * testsuite/ld-ifunc/ifunc-1-x86.d: Likewise.
968         * testsuite/ld-ifunc/ifunc-2-i386-now.d: Likewise.
969         * testsuite/ld-ifunc/ifunc-2-local-i386-now.d: Likewise.
970         * testsuite/ld-ifunc/ifunc-2-local-x86-64-now.d: Likewise.
971         * testsuite/ld-ifunc/ifunc-2-local-x86-64.d: Likewise.
972         * testsuite/ld-ifunc/ifunc-2-x86-64-now.d: Likewise.
973         * testsuite/ld-ifunc/ifunc-2-x86-64.d: Likewise.
974         * testsuite/ld-ifunc/ifunc-3a-x86.d: Likewise.
975         * testsuite/ld-ifunc/pr17154-i386-now.d: Likewise.
976         * testsuite/ld-ifunc/pr17154-i386.d: Likewise.
977         * testsuite/ld-ifunc/pr17154-x86-64-now.d: Likewise.
978         * testsuite/ld-ifunc/pr17154-x86-64.d: Likewise.
979         * testsuite/ld-m68k/got-1.d: Likewise.
980         * testsuite/ld-m68k/got-multigot-12-13-14-34-35-ok.d: Likewise.
981         * testsuite/ld-m68k/got-multigot-14-ok.d: Likewise.
982         * testsuite/ld-m68k/got-multigot-15-er.d: Likewise.
983         * testsuite/ld-m68k/got-negative-12-13-14-34-ok.d: Likewise.
984         * testsuite/ld-m68k/got-negative-12-13-14-35-er.d: Likewise.
985         * testsuite/ld-m68k/got-negative-14-ok.d: Likewise.
986         * testsuite/ld-m68k/got-negative-15-er.d: Likewise.
987         * testsuite/ld-m68k/got-single-12-ok.d: Likewise.
988         * testsuite/ld-m68k/got-single-13-er.d: Likewise.
989         * testsuite/ld-m68k/got-xgot-12-13-14-15-34-35-ok.d: Likewise.
990         * testsuite/ld-m68k/got-xgot-15-ok.d: Likewise.
991         * testsuite/ld-m68k/tls-gd-1.d: Likewise.
992         * testsuite/ld-m68k/tls-gd-2.d: Likewise.
993         * testsuite/ld-m68k/tls-gd-ie-1.d: Likewise.
994         * testsuite/ld-m68k/tls-ie-1.d: Likewise.
995         * testsuite/ld-m68k/tls-ld-1.d: Likewise.
996         * testsuite/ld-m68k/tls-ld-2.d: Likewise.
997         * testsuite/ld-sh/shared-2.d: Likewise.
998         * testsuite/ld-sh/tlsbin-2.d: Likewise.
999         * testsuite/ld-sh/tlspic-2.d: Likewise.
1000         * testsuite/ld-x86-64/bnd-branch-1-now.d: Likewise.
1001         * testsuite/ld-x86-64/bnd-ifunc-1-now.d: Likewise.
1002         * testsuite/ld-x86-64/bnd-ifunc-1.d: Likewise.
1003         * testsuite/ld-x86-64/bnd-ifunc-2-now.d: Likewise.
1004         * testsuite/ld-x86-64/bnd-ifunc-2.d: Likewise.
1005         * testsuite/ld-x86-64/bnd-plt-1-now.d: Likewise.
1006         * testsuite/ld-x86-64/bnd-plt-1.d: Likewise.
1007         * testsuite/ld-x86-64/ibt-plt-1-x32.d: Likewise.
1008         * testsuite/ld-x86-64/ibt-plt-1.d: Likewise.
1009         * testsuite/ld-x86-64/ibt-plt-2a-x32.d: Likewise.
1010         * testsuite/ld-x86-64/ibt-plt-2a.d: Likewise.
1011         * testsuite/ld-x86-64/ibt-plt-2c-x32.d: Likewise.
1012         * testsuite/ld-x86-64/ibt-plt-2c.d: Likewise.
1013         * testsuite/ld-x86-64/ibt-plt-3a-x32.d: Likewise.
1014         * testsuite/ld-x86-64/ibt-plt-3a.d: Likewise.
1015         * testsuite/ld-x86-64/ibt-plt-3c-x32.d: Likewise.
1016         * testsuite/ld-x86-64/ibt-plt-3c.d: Likewise.
1017         * testsuite/ld-x86-64/ilp32-4-nacl.d: Likewise.
1018         * testsuite/ld-x86-64/ilp32-4.d: Likewise.
1019         * testsuite/ld-x86-64/load1c-nacl.d: Likewise.
1020         * testsuite/ld-x86-64/load1c.d: Likewise.
1021         * testsuite/ld-x86-64/load1d-nacl.d: Likewise.
1022         * testsuite/ld-x86-64/load1d.d: Likewise.
1023         * testsuite/ld-x86-64/pie3-nacl.d: Likewise.
1024         * testsuite/ld-x86-64/pie3.d: Likewise.
1025         * testsuite/ld-x86-64/pr14207.d: Likewise.
1026         * testsuite/ld-x86-64/pr19162.d: Likewise.
1027         * testsuite/ld-x86-64/pr19636-2d-nacl.d: Likewise.
1028         * testsuite/ld-x86-64/pr19636-2d.d: Likewise.
1029         * testsuite/ld-x86-64/pr20253-1d.d: Likewise.
1030         * testsuite/ld-x86-64/pr20253-1f.d: Likewise.
1031         * testsuite/ld-x86-64/pr20253-1j.d: Likewise.
1032         * testsuite/ld-x86-64/pr20253-1l.d: Likewise.
1033         * testsuite/ld-x86-64/pr20830a-now.d: Likewise.
1034         * testsuite/ld-x86-64/pr20830a.d: Likewise.
1035         * testsuite/ld-x86-64/pr20830b-now.d: Likewise.
1036         * testsuite/ld-x86-64/pr20830b.d: Likewise.
1037         * testsuite/ld-x86-64/pr21038a-now.d: Likewise.
1038         * testsuite/ld-x86-64/pr21038a.d: Likewise.
1039         * testsuite/ld-x86-64/pr21038b-now.d: Likewise.
1040         * testsuite/ld-x86-64/pr21038b.d: Likewise.
1041         * testsuite/ld-x86-64/pr21038c-now.d: Likewise.
1042         * testsuite/ld-x86-64/pr21038c.d: Likewise.
1043
1044 2017-08-06  H.J. Lu  <hongjiu.lu@intel.com>
1045
1046         PR ld/21903:
1047         * ld.h (command_line): Remove inhibit_common_definition.
1048         * ldgram.y: Replace command_line.inhibit_common_definition with
1049         link_info.inhibit_common_definition.
1050         * ldlang.c (lang_common): Likewise.
1051         * lexsup.c (parse_args): Likewise.
1052         * ldmain.c (main): Only allow --no-define-common with -shared.
1053         * testsuite/ld-elf/pr21903.s: New file.
1054         * testsuite/ld-elf/pr21903a.d: Likewise.
1055         * testsuite/ld-elf/pr21903b.d: Likewise.
1056         * testsuite/ld-elf/pr21903c.d: Likewise.
1057         * testsuite/ld-elf/pr21903d.d: Likewise.
1058         * testsuite/ld-elf/pr21903e.d: Likewise.
1059
1060 2017-08-05  Alan Modra  <amodra@gmail.com>
1061
1062         * testsuite/ld-unique/pr21529.d: Don't xfail hppa.
1063
1064 2017-08-04  H.J. Lu  <hongjiu.lu@intel.com>
1065
1066         PR ld/21904
1067         * testsuite/ld-elf/pr21904.d: New file.
1068         * testsuite/ld-elf/pr21904.s: Likewise.
1069
1070 2017-08-03  Nick Clifton  <nickc@redhat.com>
1071
1072         PR ld/21884
1073         * testsuite/ld-elf/pr21884.d: Add AVR, HPPA, IA64, M68HC1x and
1074         SCORE to list of targets not supporting file format changes during
1075         linking.
1076         * testsuite/ld-unique/pr21529.d: Likewise.
1077         * emultempl/avrelf.em (_before_allocation): Skip for non-ELF
1078         output formats.
1079         (avr_elf_create_output_section_statements): Fail if the output
1080         format is not ELF.
1081         (avr_finish): Do not access the ELF header in non-ELF format
1082         output bfds.
1083         * emultempl/m68hc1xelf.em (_before_allocation): Skip for non-ELF
1084         output formats.
1085         (m68hc11elf_create_output_section_statements): Fail if the putput
1086         format is not ELF.
1087         (m68hc11elf_after_allocation): Skip for non-ELF output formats.
1088
1089 2017-08-03  Alan Modra  <amodra@gmail.com>
1090
1091         PR ld/21884
1092         * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Revert
1093         last change.  Rename iself to elfinput.  Expand comments.  Condition
1094         ELF checks on having both input and output ELF files.  Extract..
1095         (elf_orphan_compatible): ..this new function.
1096
1097 2017-08-02  H.J. Lu  <hongjiu.lu@intel.com>
1098
1099         PR ld/21884
1100         * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Check
1101         ELF section header only for ELF output.
1102         * testsuite/ld-elf/pr21884.d: New test.
1103         * testsuite/ld-elf/pr21884.t: Likewise.
1104         * testsuite/ld-elf/pr21884a.s: Likewise.
1105         * testsuite/ld-elf/pr21884b.s: Likewise.
1106
1107 2017-08-02  H.J. Lu  <hongjiu.lu@intel.com>
1108
1109         * emultempl/elf32.em (_place_orphan): Revert the last change.
1110
1111 2017-08-02  Max Filippov  <jcmvbkbc@gmail.com>
1112
1113         * emultempl/xtensaelf.em (xtensa_wild_group_interleave_callback):
1114         Only check for by_name sorting.
1115
1116 2017-08-02  Nick Clifton  <nickc@redhat.com>
1117
1118         PR 21884
1119         * emultempl/elf32.em (_place_orphan): Skip non-ELF binaries when
1120         looking for sections to merge.
1121
1122 2017-07-31  Alan Modra  <amodra@gmail.com>
1123
1124         * ld.texinfo (plt-localentry): Revise.
1125
1126 2017-07-29  Alan Modra  <amodra@gmail.com>
1127
1128         * ld.texinfo (plt-localentry): Document.
1129
1130 2017-07-28  Andrew Burgess  <andrew.burgess@embecosm.com>
1131
1132         * ldgram.y (ldgram_had_keep): Make static.
1133         (ldgram_vers_current_lang): Likewise.
1134         (filename_spec): New rule.
1135         (input_section_spec_no_keep): Use filename_spec.
1136         (wildcard_maybe_exclude): New rule.
1137         (wildcard_spec): Rename to...
1138         (section_name_spec): ...this.
1139         (section_NAME_list): Rename to...
1140         (section_name_list): ...this.
1141         (section_name_spec): Simplifiy and use wildcard_maybe_exclude.
1142         * ldlang.c (placed_commons): Delete.
1143         (lang_add_wild): No longer set placed_commons.
1144         (print_wild_statement): Use full names for SORT specifiers.
1145         * testsuite/ld-scripts/align.exp: Run new tests.
1146         * testsuite/ld-scripts/align3.d: New file.
1147         * testsuite/ld-scripts/align3.t: New file.
1148         * testsuite/ld-scripts/align4.d: New file.
1149         * testsuite/ld-scripts/align4.t: New file.
1150         * testsuite/ld-scripts/align5.d: New file.
1151         * testsuite/ld-scripts/align5.t: New file.
1152         * testsuite/ld-scripts/exclude-file-5.d: New file.
1153         * testsuite/ld-scripts/exclude-file-5.map: New file.
1154         * testsuite/ld-scripts/exclude-file-5.t: New file.
1155         * testsuite/ld-scripts/exclude-file-6.d: New file.
1156         * testsuite/ld-scripts/exclude-file-6.map: New file.
1157         * testsuite/ld-scripts/exclude-file-6.t: New file.
1158         * NEWS: Mention the changes.
1159
1160 2017-07-27  Georg-Johann Lay  <gjl@gcc.gnu.org>
1161
1162         PR ld/21849
1163         * scripttempl/avr.sc: Split .progmemx.* from .progmem.* and locate
1164         former at a higher address.
1165
1166 2017-07-25  Alan Modra  <amodra@gmail.com>
1167
1168         * testsuite/ld-powerpc/tlsopt5.s: Add cfi.
1169         * testsuite/ld-powerpc/tlsopt5.d: Update.
1170         * testsuite/ld-powerpc/tlsopt5.wf: New file.
1171         * testsuite/ld-powerpc/powerpc.exp: Perform new tlsopt5 test.
1172
1173 2017-07-24  Claudiu Zissulescu  <claziss@synopsys.com>
1174
1175         * testsuite/ld-arc/jli-overflow.d: Force testing for little
1176         endian.
1177         * testsuite/ld-arc/tls_gd-01.d: Fix string to match bigendian
1178         systems.
1179         * testsuite/ld-arc/tls_ie-01.d: Fix test for bigendian systems.
1180
1181 2017-07-19  Maciej W. Rozycki  <macro@imgtec.com>
1182
1183         * testsuite/ld-scripts/fill.d: Adjust `xfail' entries.  Add
1184         `notarget' entries.  Update comments.
1185         * testsuite/ld-scripts/fill16.d: New test.
1186         * testsuite/ld-scripts/fill16_0.s: New test source.
1187         * testsuite/ld-scripts/fill16_1.s: New test source.
1188         * testsuite/ld-scripts/fill16_2.s: New test source.
1189         * testsuite/ld-scripts/data.exp: Run the new test.
1190
1191 2017-07-19  Claudiu Zissulescu  <claziss@synopsys.com>
1192             John Eric Martin  <John.Martin@emmicro-us.com>
1193
1194         * emulparams/arcelf.sh (JLI_START_TABLE): Define.
1195         * scripttempl/elfarc.sc: Handle jlitab section.
1196         * scripttempl/elfarcv2.sc: Likewise.
1197         * testsuite/ld-arc/arc.exp: Add JLI test.
1198         * testsuite/ld-arc/jli-script.ld: New file.
1199         * testsuite/ld-arc/jli-simple.dd: Likewise.
1200         * testsuite/ld-arc/jli-simple.rd: Likewise.
1201         * testsuite/ld-arc/jli-simple.s: Likewise.
1202         * testsuite/ld-arc/jli-overflow.s: Likewise.
1203         * testsuite/ld-arc/jli-overflow.d: Likewise.
1204         * testsuite/ld-arc/jli-overflow.err: Likewise.
1205
1206 2017-07-19  Tristan Gingold  <gingold@adacore.com>
1207
1208         * ldmain.c (main): Remove display of data size.
1209
1210 2017-07-18  Maciej W. Rozycki  <macro@imgtec.com>
1211
1212         PR ld/16656
1213         * testsuite/ld-elf/binutils.exp (binutils_test): Make the
1214         expectation for `.got' in GNU_RELRO segment target-specific.
1215         Handle `.got.plt' separately.
1216
1217 2017-07-18  Maciej W. Rozycki  <macro@imgtec.com>
1218
1219         PR ld/16656
1220         * testsuite/ld-elf/binutils.exp (binutils_test): Make the
1221         expectation for `.dynamic' in GNU_RELRO segment target-specific.
1222
1223 2017-07-18  Nick Clifton  <nickc@redhat.com>
1224
1225         PR 21775
1226         * ld.texinfo: Fix spelling typos.
1227         * testsuite/ld-elfcomm/elfcomm.exp: Likewise.
1228
1229 2017-07-17  H.J. Lu  <hongjiu.lu@intel.com>
1230
1231         * testsuite/ld-i386/i386.exp: Run pie1 and pie1-nacl.
1232         * testsuite/ld-i386/pie1-nacl.d: New file.
1233         * testsuite/ld-i386/pie1.d: Likewise.
1234         * testsuite/ld-i386/pie1.s: Likewise.
1235
1236 2017-07-17  H.J. Lu  <hongjiu.lu@intel.com>
1237
1238         PR ld/21782
1239         * testsuite/ld-x86-64/pie3-nacl.d: New file.
1240         * testsuite/ld-x86-64/pie3.d: Likewise.
1241         * testsuite/ld-x86-64/pie3.s: Likewise.
1242         * testsuite/ld-x86-64/x86-64.exp: Run pie3 and pie3-nacl.
1243
1244 2017-07-14  Alan Modra  <amodra@gmail.com>
1245
1246         * testsuite/ld-powerpc/powerpc.exp: Add -shared to tlsop5 tests.
1247         * testsuite/ld-powerpc/tlsopt5.d: Adjust.
1248         * testsuite/ld-powerpc/tlsopt1_32.s: Use r30 as GOT pointer.
1249         * testsuite/ld-powerpc/tlsopt2_32.s: Likewise.
1250         * testsuite/ld-powerpc/tlsopt3_32.s: Likewise.
1251         * testsuite/ld-powerpc/tlsopt4_32.s: Likewise.
1252         * testsuite/ld-powerpc/tlsopt5_32.s: Rewrite.
1253         * testsuite/ld-powerpc/tlsopt1_32.d: Adjust.
1254         * testsuite/ld-powerpc/tlsopt2_32.d: Adjust.
1255         * testsuite/ld-powerpc/tlsopt3_32.d: Adjust.
1256         * testsuite/ld-powerpc/tlsopt5_32.d: Adjust.
1257
1258 2016-07-14  Maciej W. Rozycki  <macro@imgtec.com>
1259
1260         * testsuite/ld-unique/pr21529.ld: New test linker script.
1261         * testsuite/ld-unique/pr21529.d: Use it.
1262
1263 2017-07-12  Alan Modra  <amodra@gmail.com>
1264
1265         * po/bg.po: Update from translationproject.org/latest/ld/.
1266         * po/da.po: Likewise.
1267         * po/es.po: Likewise.
1268         * po/fi.po: Likewise.
1269         * po/fr.po: Likewise.
1270         * po/id.po: Likewise.
1271         * po/it.po: Likewise.
1272         * po/ja.po: Likewise.
1273         * po/tr.po: Likewise.
1274         * po/uk.po: Likewise.
1275         * po/vi.po: Likewise.
1276         * po/zh_CN.po: Likewise.
1277         * po/zh_TW.po: Likewise.
1278         * po/de.po: New file from translationproject.org.
1279         * po/ru.po: Likewise.
1280         * configure.ac (ALL_LINGUAS): Add de, ru.  Sort.
1281         * configure: Regenerate.
1282
1283 2017-07-12  Alan Modra  <amodra@gmail.com>
1284
1285         * testsuite/ld-scripts/align.exp: Exclude powerpc*-*-aix*.
1286         * testsuite/ld-scripts/assign-loc.d: Likewise.
1287         * testsuite/ld-scripts/defined3.d: Likewise.
1288         * testsuite/ld-scripts/defined4.d: Likewise.
1289         * testsuite/ld-scripts/defined5.d: Likewise.
1290         * testsuite/ld-scripts/expr2.d: Likewise.
1291         * testsuite/ld-scripts/provide.exp: Likewise.
1292         * testsuite/ld-scripts/sane1.d: Likewise.
1293         * testsuite/ld-scripts/size.exp: Likewise.
1294         * testsuite/ld-scripts/defined2.d: Don't xfail rs6000-*-aix*.
1295
1296 2017-07-12  Alan Modra  <amodra@gmail.com>
1297
1298         * testsuite/ld-arc/nps-1b.err: Update.
1299         * testsuite/ld-x86-64/ilp32-11.d: Update.
1300
1301 2017-07-11  H.J. Lu  <hongjiu.lu@intel.com>
1302
1303         * testsuite/ld-selective/selective.exp: Support single digit
1304         GCC version.
1305
1306 2017-07-11  Jiong Wang  <jiong.wang@arm.com>
1307
1308         * testsuite/ld-aarch64/dt_textrel.d: Use "#pass" instead of ".*" to
1309         filter out remaining lines.
1310
1311 2017-07-07  Maciej W. Rozycki  <macro@imgtec.com>
1312
1313         * emultempl/mipself.em (mips_before_allocation): Avoid ELF
1314         processing if not MIPS ELF.
1315         * testsuite/ld-mips-elf/binary.d: New test.
1316         * testsuite/ld-mips-elf/binary.ld: New test linker script.
1317         * testsuite/ld-mips-elf/binary.s: New test source.
1318         * testsuite/ld-mips-elf/mips-elf.exp: Run the new test.
1319
1320 2017-07-07  Alan Modra  <amodra@gmail.com>
1321
1322         * testsuite/ld-powerpc/ppc476-shared.lnk: Align .bss.
1323         * testsuite/ld-powerpc/ppc476-shared.d: Adjust.
1324         * testsuite/ld-powerpc/ppc476-shared2.d: Adjust.
1325
1326 2017-07-07  Alan Modra  <amodra@gmail.com>
1327
1328         * Makefile.am (eelf64_s390.c): Depend on emultempl/s390.em.
1329
1330 2017-07-04  Tristan Gingold  <gingold@adacore.com>
1331
1332         * configure: Regenerate.
1333
1334 2017-07-04  Tristan Gingold  <gingold@adacore.com>
1335
1336         * NEWS: Add marker for 2.29.
1337
1338 2017-07-03  Tristan Gingold  <gingold@adacore.com>
1339
1340         * po/ld.pot: Regenerate.
1341
1342 2017-06-30  Maciej W. Rozycki  <macro@imgtec.com>
1343
1344         * testsuite/ld-mips-elf/relax-offset.dd: New test.
1345         * testsuite/ld-mips-elf/relax-offset.gd: New test.
1346         * testsuite/ld-mips-elf/relax-offset-umips.dd: New test.
1347         * testsuite/ld-mips-elf/relax-offset-umips.gd: New test.
1348         * testsuite/ld-mips-elf/relax-offset.ld: New test linker script.
1349         * testsuite/ld-mips-elf/mips-elf.exp: Run the new tests.
1350         (prune_warnings): New temporary procedure.
1351
1352 2017-06-28  Maciej W. Rozycki  <macro@imgtec.com>
1353
1354         * testsuite/ld-mips-elf/mips-elf-flags.exp: Add interAptiv MR2
1355         tests.
1356
1357 2017-06-27  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
1358
1359         PR ld/13402
1360         * testsuite/ld-avr/pr13402.d: New test.
1361         * testsuite/ld-avr/pr13402.s: New test.
1362
1363 2017-06-27  Maciej W. Rozycki  <macro@imgtec.com>
1364
1365         * testsuite/ld-mips-elf/mips-elf-flags.exp (good_combination):
1366         Add an `args' final argument and examination code for `readelf
1367         -A' output.  Update procedure description accordingly.
1368
1369 2017-06-27  Maciej W. Rozycki  <macro@imgtec.com>
1370
1371         * testsuite/ld-mips-elf/mips-elf-flags.exp (good_combination):
1372         Use `remote_exec' to call `readelf'.  Log the command issued.
1373
1374 2017-06-27  Maciej W. Rozycki  <macro@imgtec.com>
1375
1376         * testsuite/ld-mips-elf/mips-elf-flags.exp (good_combination):
1377         Use `readelf -h' rather than `readelf --headers'.
1378
1379 2017-06-26  Maciej W. Rozycki  <macro@imgtec.com>
1380
1381         * testsuite/ld-mips-elf/lsi-4010-isa.d: New test.
1382         * ld/testsuite/ld-mips-elf/mips-elf.exp: Run the new test.
1383
1384 2017-06-26  Maciej W. Rozycki  <macro@imgtec.com>
1385
1386         * testsuite/ld-elf/sizeofa.d: Also accept the OBJECT type for
1387         the symbols examined.
1388         * testsuite/ld-elf/sizeofc.d: Likewise.
1389         * testsuite/ld-elf/startofa.d: Likewise.
1390         * testsuite/ld-elf/startofc.d: Likewise.
1391
1392 2017-06-26  Alan Modra  <amodra@gmail.com>
1393
1394         * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Skip
1395         --just-syms bfds when looking for a place to attach .note.gnu.build-id
1396         and .eh_frame_hdr sections.  Delete dead code.
1397
1398 2017-06-24  Thomas Preud'homme  <thomas.preudhomme@arm.com>
1399
1400         * testsuite/ld-arm/arm-elf.exp (EABI attribute merging 11): New test.
1401         (EABI attribute merging 12): Likewise.
1402         * testsuite/ld-arm/attr-merge-11a.s: New file.
1403         * testsuite/ld-arm/attr-merge-11b.s: New file.
1404         * testsuite/ld-arm/attr-merge-11.attr: New file.
1405         * testsuite/ld-arm/attr-merge-12a.s: New file.
1406         * testsuite/ld-arm/attr-merge-12b.s: New file.
1407         * testsuite/ld-arm/attr-merge-12.attr: New file.
1408
1409 2017-06-22  H.J. Lu  <hongjiu.lu@intel.com>
1410
1411         * testsuite/ld-i386/i386.exp: Run weakundef1 tests.
1412         * testsuite/ld-i386/weakundef1.c: New file.
1413
1414 2017-06-22  H.J. Lu  <hongjiu.lu@intel.com>
1415
1416         PR ld/21090
1417         * testsuite/ld-elfvsb/elfvsb.exp (visibility_run): Pass
1418         $NOPIE_CFLAGS if non-PIE is required.
1419
1420 2017-06-22  H.J. Lu  <hongjiu.lu@intel.com>
1421
1422         PR ld/21090
1423         * testsuite/ld-i386/i386.exp: Pass $NOPIE_CFLAGS and
1424         $NOPIE_LDFLAGS to "Run pr19031".
1425
1426 2017-06-22  H.J. Lu  <hongjiu.lu@intel.com>
1427
1428         PR ld/21090
1429         * testsuite/ld-gc/gc.exp: Compile tmpdir/pr14265.o with
1430         $NOPIE_CFLAGS.
1431         * testsuite/ld-i386/i386.exp: Pass $NOPIE_CFLAGS and
1432         $NOPIE_LDFLAGS if non-PIE is required.
1433         * testsuite/ld-i386/no-plt.exp (NOPIE_CFLAGS): New.
1434         (NOPIE_LDFLAGS): Likewise.
1435         Pass $NOPIE_LDFLAGS if non-PIE is required.
1436         * testsuite/ld-shared/shared.exp: Compile tmpdir/sh1np.o with
1437         $NOPIE_CFLAGS.
1438
1439 2017-06-22  H.J. Lu  <hongjiu.lu@intel.com>
1440
1441         * NEWS: Mention -z shstk and GNU_PROPERTY_X86_FEATURE_1_SHSTK.
1442         * emulparams/cet.sh (PARSE_AND_LIST_OPTIONS_CET): Add "-z shstk".
1443         (PARSE_AND_LIST_ARGS_CASE_Z_CET): Support "-z shstk".
1444         * ld.texinfo: Document -z shstk.
1445         * testsuite/ld-i386/i386.exp: Run SHSTK tests.
1446         * testsuite/ld-x86-64/x86-64.exp: Likewise.
1447         * testsuite/ld-i386/property-x86-shstk.s: New file.
1448         * testsuite/ld-i386/property-x86-shstk1a.d: Likewise.
1449         * testsuite/ld-i386/property-x86-shstk1b.d: Likewise.
1450         * testsuite/ld-i386/property-x86-shstk2.d: Likewise.
1451         * testsuite/ld-i386/property-x86-shstk3a.d: Likewise.
1452         * testsuite/ld-i386/property-x86-shstk3b.d: Likewise.
1453         * testsuite/ld-i386/property-x86-shstk4.d: Likewise.
1454         * testsuite/ld-i386/property-x86-shstk5.d: Likewise.
1455         * testsuite/ld-x86-64/property-x86-shstk.s: Likewise.
1456         * testsuite/ld-x86-64/property-x86-shstk1a-x32.d: Likewise.
1457         * testsuite/ld-x86-64/property-x86-shstk1a.d: Likewise.
1458         * testsuite/ld-x86-64/property-x86-shstk1b-x32.d: Likewise.
1459         * testsuite/ld-x86-64/property-x86-shstk1b.d: Likewise.
1460         * testsuite/ld-x86-64/property-x86-shstk2-x32.d: Likewise.
1461         * testsuite/ld-x86-64/property-x86-shstk2.d: Likewise.
1462         * testsuite/ld-x86-64/property-x86-shstk3a-x32.d: Likewise.
1463         * testsuite/ld-x86-64/property-x86-shstk3a.d: Likewise.
1464         * testsuite/ld-x86-64/property-x86-shstk3b-x32.d: Likewise.
1465         * testsuite/ld-x86-64/property-x86-shstk3b.d: Likewise.
1466         * testsuite/ld-x86-64/property-x86-shstk4-x32.d: Likewise.
1467         * testsuite/ld-x86-64/property-x86-shstk4.d: Likewise.
1468         * testsuite/ld-x86-64/property-x86-shstk5-x32.d: Likewise.
1469         * testsuite/ld-x86-64/property-x86-shstk5.d: Likewise.
1470
1471 2017-06-22  H.J. Lu  <hongjiu.lu@intel.com>
1472
1473         * Makefile.am (ELF_X86_DEPS): Add $(srcdir)/emulparams/cet.sh.
1474         * Makefile.in: Regenerated.
1475         * NEWS: Mention GNU_PROPERTY_X86_FEATURE_1_IBT, -z ibtplt
1476         and -z ibt.
1477         * emulparams/cet.sh: New file.
1478         * testsuite/ld-i386/ibt-plt-1.d: Likewise.
1479         * testsuite/ld-i386/ibt-plt-1.s: Likewise.
1480         * testsuite/ld-i386/ibt-plt-2.s: Likewise.
1481         * testsuite/ld-i386/ibt-plt-2a.d: Likewise.
1482         * testsuite/ld-i386/ibt-plt-2b.d: Likewise.
1483         * testsuite/ld-i386/ibt-plt-2c.d: Likewise.
1484         * testsuite/ld-i386/ibt-plt-2d.d: Likewise.
1485         * testsuite/ld-i386/ibt-plt-3.s: Likewise.
1486         * testsuite/ld-i386/ibt-plt-3a.d: Likewise.
1487         * testsuite/ld-i386/ibt-plt-3b.d: Likewise.
1488         * testsuite/ld-i386/ibt-plt-3c.d: Likewise.
1489         * testsuite/ld-i386/ibt-plt-3d.d: Likewise.
1490         * testsuite/ld-i386/plt-main-ibt.dd: Likewise.
1491         * testsuite/ld-i386/plt-pie-ibt.dd: Likewise.
1492         * testsuite/ld-i386/property-x86-empty.s: Likewise.
1493         * testsuite/ld-i386/property-x86-ibt.s: Likewise.
1494         * testsuite/ld-i386/property-x86-ibt1a.d: Likewise.
1495         * testsuite/ld-i386/property-x86-ibt1b.d: Likewise.
1496         * testsuite/ld-i386/property-x86-ibt2.d: Likewise.
1497         * testsuite/ld-i386/property-x86-ibt3a.d: Likewise.
1498         * testsuite/ld-i386/property-x86-ibt3b.d: Likewise.
1499         * testsuite/ld-i386/property-x86-ibt4.d: Likewise.
1500         * testsuite/ld-i386/property-x86-ibt5.d: Likewise.
1501         * testsuite/ld-x86-64/ibt-plt-1-x32.d: Likewise.
1502         * testsuite/ld-x86-64/ibt-plt-1.d: Likewise.
1503         * testsuite/ld-x86-64/ibt-plt-1.s: Likewise.
1504         * testsuite/ld-x86-64/ibt-plt-2.s: Likewise.
1505         * testsuite/ld-x86-64/ibt-plt-2a-x32.d: Likewise.
1506         * testsuite/ld-x86-64/ibt-plt-2a.d: Likewise.
1507         * testsuite/ld-x86-64/ibt-plt-2b-x32.d: Likewise.
1508         * testsuite/ld-x86-64/ibt-plt-2b.d: Likewise.
1509         * testsuite/ld-x86-64/ibt-plt-2c-x32.d: Likewise.
1510         * testsuite/ld-x86-64/ibt-plt-2c.d: Likewise.
1511         * testsuite/ld-x86-64/ibt-plt-2d-x32.d: Likewise.
1512         * testsuite/ld-x86-64/ibt-plt-2d.d: Likewise.
1513         * testsuite/ld-x86-64/ibt-plt-3.s: Likewise.
1514         * testsuite/ld-x86-64/ibt-plt-3a-x32.d: Likewise.
1515         * testsuite/ld-x86-64/ibt-plt-3a.d: Likewise.
1516         * testsuite/ld-x86-64/ibt-plt-3b-x32.d: Likewise.
1517         * testsuite/ld-x86-64/ibt-plt-3b.d: Likewise.
1518         * testsuite/ld-x86-64/ibt-plt-3c-x32.d: Likewise.
1519         * testsuite/ld-x86-64/ibt-plt-3c.d: Likewise.
1520         * testsuite/ld-x86-64/ibt-plt-3d-x32.d: Likewise.
1521         * testsuite/ld-x86-64/ibt-plt-3d.d: Likewise.
1522         * testsuite/ld-x86-64/plt-main-ibt-now.rd: Likewise.
1523         * testsuite/ld-x86-64/plt-main-ibt-x32.dd: Likewise.
1524         * testsuite/ld-x86-64/plt-main-ibt.dd: Likewise.
1525         * testsuite/ld-x86-64/property-x86-empty.s: Likewise.
1526         * testsuite/ld-x86-64/property-x86-ibt.s: Likewise.
1527         * testsuite/ld-x86-64/property-x86-ibt1a-x32.d: Likewise.
1528         * testsuite/ld-x86-64/property-x86-ibt1a.d: Likewise.
1529         * testsuite/ld-x86-64/property-x86-ibt1b-x32.d: Likewise.
1530         * testsuite/ld-x86-64/property-x86-ibt1b.d: Likewise.
1531         * testsuite/ld-x86-64/property-x86-ibt2-x32.d: Likewise.
1532         * testsuite/ld-x86-64/property-x86-ibt2.d: Likewise.
1533         * testsuite/ld-x86-64/property-x86-ibt3a-x32.d: Likewise.
1534         * testsuite/ld-x86-64/property-x86-ibt3a.d: Likewise.
1535         * testsuite/ld-x86-64/property-x86-ibt3b-x32.d: Likewise.
1536         * testsuite/ld-x86-64/property-x86-ibt3b.d: Likewise.
1537         * testsuite/ld-x86-64/property-x86-ibt4-x32.d: Likewise.
1538         * testsuite/ld-x86-64/property-x86-ibt4.d: Likewise.
1539         * testsuite/ld-x86-64/property-x86-ibt5-x32.d: Likewise.
1540         * testsuite/ld-x86-64/property-x86-ibt5.d: Likewise.
1541         * emulparams/elf32_x86_64.sh: Source emulparams/cet.sh.
1542         (TINY_READONLY_SECTION): Add .plt.sec.
1543         * emulparams/elf_i386.sh: Likewise.
1544         * emulparams/elf_x86_64.sh: Source emulparams/cet.sh.
1545         * ld.texinfo: Document -z ibtplt and -z ibt.
1546         * testsuite/ld-i386/i386.exp: Run IBT and IBT PLT tests.
1547         * testsuite/ld-x86-64/x86-64.exp: Likewise.
1548         * testsuite/ld-x86-64/pr21481b.S (check): Updated for x32.
1549
1550 2017-06-21  H.J. Lu  <hongjiu.lu@intel.com>
1551
1552         PR ld/21090
1553         * testsuite/ld-elf/shared.exp: Pass $NOPIE_CFLAGS and
1554         $NOPIE_LDFLAGS if non-PIE is required.
1555
1556 2017-06-21  H.J. Lu  <hongjiu.lu@intel.com>
1557
1558         PR ld/21090
1559         * testsuite/ld-scripts/crossref.exp: Also pass $NOPIE_CFLAGS
1560         to CC.
1561
1562 2017-06-21  H.J. Lu  <hongjiu.lu@intel.com>
1563
1564         PR ld/21090
1565         * testsuite/ld-size/size.exp: Pass $NOPIE_LDFLAGS to size-4a,
1566         size-4b, size-5a, size-5b, size-6 and size-8 tests.
1567         * testsuite/ld-srec/srec.exp (NOPIE_CFLAGS): New.
1568         (NOPIE_LDFLAGS): Likewise.
1569         (CC): Add $NOPIE_CFLAGS $NOPIE_LDFLAGS.
1570         (CXX): Likewise.
1571         * testsuite/ld-x86-64/no-plt.exp (NOPIE_CFLAGS): New.
1572         (NOPIE_LDFLAGS): Likewise.
1573         Pass $NOPIE_LDFLAGS to "No PLT (dynamic 1a)",
1574         "No PLT (dynamic 1c)" and "Run pr20253-2f".
1575         * testsuite/ld-x86-64/x86-64.exp: Pass $NOPIE_LDFLAGS to
1576         "Build gotpcrel1" and "Run pr19031".
1577
1578 2017-06-21  Alan Modra  <amodra@gmail.com>
1579
1580         * testsuite/ld-powerpc/powerpc.exp: Run TOCSAVE tests.
1581         * testsuite/ld-powerpc/tocsave1.s,
1582         * testsuite/ld-powerpc/tocsave1a.d,
1583         * testsuite/ld-powerpc/tocsave1s.d,
1584         * testsuite/ld-powerpc/tocsave2.s,
1585         * testsuite/ld-powerpc/tocsave2a.d,
1586         * testsuite/ld-powerpc/tocsave2s.d,
1587         * testsuite/ld-powerpc/tocsavelib.s: New files.
1588
1589 2017-06-20  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
1590
1591         * Makefile.in: Add s390.em as build dependency.
1592         * emulparams/elf64_s390.sh (EXTRA_EM_FILE): Add s390.em.
1593         * emultempl/s390.em: New file.
1594         * gen-doc.texi: Add documentation for --s390-pgste option.
1595         * ld.texinfo: Likewise.
1596
1597 2017-06-19  H.J. Lu  <hongjiu.lu@intel.com>
1598
1599         PR ld/21626
1600         * testsuite/ld-i386/i386.exp: Run ld/21626 tests.
1601         * testsuite/ld-x86-64/x86-64.exp: Likewise.
1602
1603 2017-06-18  Alan Modra  <amodra@gmail.com>
1604
1605         * testsuite/lib/ld-lib.exp (is_underscore_target): New.
1606         * testsuite/ld-elf/elf.exp (ASFLAGS): Define UNDERSCORE.
1607         * testsuite/ld-elf/pr21562a.s: If UNDERSCORE defined,
1608         reference sym with prefix.
1609         * testsuite/ld-elf/pr21562b.s: Likewise.
1610         * testsuite/ld-elf/sizeof.s: Likewise.
1611         * testsuite/ld-elf/startof.s: Likewise.
1612         * testsuite/ld-elf/pr14156a.d: Adjust for extra symbols.
1613         * testsuite/ld-elf/pr21562a.d: Remove underscore target from
1614         xfails, and match prefixed symbol.
1615         * testsuite/ld-elf/pr21562b.d: Likewise.
1616         * testsuite/ld-elf/pr21562c.d: Likewise.
1617         * testsuite/ld-elf/pr21562d.d: Likewise.
1618         * testsuite/ld-elf/pr21562e.d: Likewise.
1619         * testsuite/ld-elf/pr21562f.d: Likewise.
1620         * testsuite/ld-elf/pr21562g.d: Likewise.
1621         * testsuite/ld-elf/pr21562h.d: Likewise.
1622         * testsuite/ld-elf/pr21562i.d: Likewise.
1623         * testsuite/ld-elf/pr21562j.d: Likewise.
1624         * testsuite/ld-elf/pr21562k.d: Likewise.
1625         * testsuite/ld-elf/pr21562l.d: Likewise.
1626         * testsuite/ld-elf/pr21562m.d: Likewise.
1627         * testsuite/ld-elf/pr21562n.d: Likewise.
1628         * testsuite/ld-elf/sizeofa.d: Likewise.
1629         * testsuite/ld-elf/sizeofb.d: Likewise.
1630         * testsuite/ld-elf/sizeofc.d: Likewise.
1631         * testsuite/ld-elf/startofa.d: Likewise.
1632         * testsuite/ld-elf/startofb.d: Likewise.
1633         * testsuite/ld-elf/startofc.d: Likewise.
1634
1635 2017-06-16  Alan Modra  <amodra@gmail.com>
1636
1637         PR ld/20022
1638         PR ld/21557
1639         PR ld/21562
1640         PR ld/21571
1641         * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Don't set
1642         __start/__stop syms here.
1643         * ldlang.c (lang_set_startof): Delete.
1644         (start_stop_syms, start_stop_count, start_stop_alloc): New vars.
1645         (lang_define_start_stop, lang_init_start_stop, foreach_start_stop,
1646         undef_start_stop, lang_undef_start_stop, lang_init_startof_sizeof,
1647         set_start_stop, lang_finalize_start_stop): New functions.
1648         (lang_process): Call _start_stop functions.
1649         * testsuite/ld-elf/pr21562a.d: Use xfail rather than notarget.
1650         Correct typos and list of xfail targets.
1651         * testsuite/ld-elf/pr21562b.d: Likewise.
1652         * testsuite/ld-elf/pr21562c.d: Likewise.
1653         * testsuite/ld-elf/pr21562d.d: Likewise.
1654         * testsuite/ld-elf/pr21562e.d: Likewise.
1655         * testsuite/ld-elf/pr21562f.d: Likewise.
1656         * testsuite/ld-elf/pr21562g.d: Likewise.
1657         * testsuite/ld-elf/pr21562h.d: Likewise.
1658         * testsuite/ld-elf/pr21562i.d: Likewise.
1659         * testsuite/ld-elf/pr21562j.d: Likewise.
1660         * testsuite/ld-elf/pr21562k.d: Likewise.
1661         * testsuite/ld-elf/pr21562l.d: Likewise.
1662         * testsuite/ld-elf/pr21562m.d: Likewise.
1663         * testsuite/ld-elf/pr21562n.d: Likewise.
1664         * testsuite/ld-elf/sizeofa.d: Likewise.  Adjust to pass for generic ELF.
1665         * testsuite/ld-elf/sizeofb.d: Likewise.
1666         * testsuite/ld-elf/startofa.d: Likewise.
1667         * testsuite/ld-elf/startofb.d: Likewise.
1668
1669 2017-06-16  Jiong Wang  <jiong.wang@arm.com>
1670
1671         * testsuite/ld-aarch64/aarch64-elf.exp: Update test name
1672         * testsuite/ld-aarch64/pcrel.s: Add new testcases.
1673         * testsuite/ld-aarch64/pcrel_pic_undefined.d: Update the expected
1674         warnings.
1675         * testsuite/ld-aarch64/pcrel_pic_defined_local.d: Rename ...
1676         * testsuite/ld-aarch64/pcrel_pic_defined.d: ... to this.
1677         Update expected warnings.
1678
1679 2017-06-15  H.J. Lu  <hongjiu.lu@intel.com>
1680
1681         * exsup.c (elf_shlib_list_options): Display "-z stack-size=SIZE"
1682         instead of "-z stacksize=SIZE".
1683
1684 2017-06-15  Jiong Wang  <jiong.wang@arm.com>
1685
1686         * testsuite/ld-aarch64/copy-reloc-exe-2.s: New test source file.
1687         * testsuite/ld-aarch64/copy-reloc-2.d: New test.
1688         * testsuite/ld-aarch64/copy-reloc-exe-eliminate.s: New test source file.
1689         * testsuite/ld-aarch64/copy-reloc-eliminate.d: New test.
1690         * testsuite/ld-aarch64/copy-reloc-so.s: Define new global objects.
1691         * testsuite/ld-aarch64/aarch64-elf.exp: Run new tests.
1692
1693 2017-06-14  Nick Clifton  <nickc@redhat.com>
1694
1695         PR binutils/21580
1696         * testsuite/ld-nds32/diff.d: Adjust expected output.
1697
1698 2017-06-14  H.J. Lu  <hongjiu.lu@intel.com>
1699
1700         PR ld/20022
1701         * testsuite/ld-gc/pr20022.d: Skip on targets without dynamic
1702         relocations in .text section.
1703
1704 2017-06-14  H.J. Lu  <hongjiu.lu@intel.com>
1705
1706         * testsuite/ld-elf/pr21562a.d: Skip on targets with leading char
1707         in in symbol name or without --gc-sections.
1708         * testsuite/ld-elf/pr21562b.d: Likewise.
1709         * testsuite/ld-elf/pr21562c.d: Likewise.
1710         * testsuite/ld-elf/pr21562d.d: Likewise.
1711         * testsuite/ld-elf/pr21562i.d: Likewise.
1712         * testsuite/ld-elf/pr21562j.d: Likewise.
1713         * testsuite/ld-elf/pr21562k.d: Likewise.
1714         * testsuite/ld-elf/pr21562l.d: Likewise.
1715         * testsuite/ld-elf/pr21562m.d: Likewise.
1716         * testsuite/ld-elf/pr21562n.d: Likewise.
1717         * testsuite/ld-elf/pr21562e.d: Skip on targets with leading char
1718         in symbol name.
1719         * testsuite/ld-elf/pr21562f.d: Likewise.
1720         * testsuite/ld-elf/pr21562g.d: Likewise.
1721         * testsuite/ld-elf/pr21562h.d: Likewise.
1722
1723 2017-06-14  H.J. Lu  <hongjiu.lu@intel.com>
1724
1725         * testsuite/ld-gc/pr20022a.s: Add size to bar.
1726
1727 2017-06-14  H.J. Lu  <hongjiu.lu@intel.com>
1728
1729         * testsuite/ld-elf/sizeofa.d: Skip on targets with leading char
1730         in symbol name.
1731         * testsuite/ld-elf/sizeofb.d: Likewise.
1732         * testsuite/ld-elf/startofa.d: Likewise.
1733         * testsuite/ld-elf/startofb.d: Likewise.
1734
1735 2017-06-14  Georg-Johann Lay  <gjl@gcc.gnu.org>
1736
1737         PR ld/21583
1738         * scripttempl/avr.sc (.jumptables): Move down in text section.
1739         (.hightext): New in text.
1740
1741 2017-06-14  Sebastian Huber  <sebastian.huber@embedded-brains.de>
1742
1743         * configure.tgt (epiphany-*-elf): Accept epiphany-*-*.
1744
1745 2017-06-13  H.J. Lu  <hongjiu.lu@intel.com>
1746
1747         * ldlang.c (lang_set_startof): Skip if config.build_constructors
1748         is FALSE.
1749         * testsuite/ld-elf/sizeofc.d: New file.
1750         * testsuite/ld-elf/startofc.d: Likewise.
1751
1752 2017-06-13  H.J. Lu  <hongjiu.lu@intel.com>
1753
1754         * testsuite/ld-elf/sizeof.d: Renamed to ...
1755         * testsuite/ld-elf/sizeofa.d: This.  Updated.
1756         * testsuite/ld-elf/startof.d: Renamed to ...
1757         * testsuite/ld-elf/startofa.d: This.  Updated.
1758         * testsuite/ld-elf/sizeofb.d: New file.
1759         * testsuite/ld-elf/startofb.d: Likewise.
1760
1761 2017-06-13  H.J. Lu  <hongjiu.lu@intel.com>
1762
1763         PR ld/20022
1764         PR ld/21557
1765         PR ld/21562
1766         PR ld/21571
1767         * ld.texinfo: Update __start_SECNAME/__stop_SECNAME symbols.
1768         * ldlang.c (lang_insert_orphan): Move handling of __start_SECNAME
1769         and __stop_SECNAME symbols to ...
1770         (lang_set_startof): Here.  Also define __start_SECNAME and
1771         __stop_SECNAME for -Ur.
1772         * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Mark
1773         referenced __start_SECNAME and __stop_SECNAME symbols as hidden
1774         and set start_stop for garbage collection.
1775         * testsuite/ld-elf/pr21562a.d: New file.
1776         * testsuite/ld-elf/pr21562a.s: Likewise.
1777         * testsuite/ld-elf/pr21562a.t: Likewise.
1778         * testsuite/ld-elf/pr21562b.d: Likewise.
1779         * testsuite/ld-elf/pr21562b.s: Likewise.
1780         * testsuite/ld-elf/pr21562b.t: Likewise.
1781         * testsuite/ld-elf/pr21562c.d: Likewise.
1782         * testsuite/ld-elf/pr21562c.t: Likewise.
1783         * testsuite/ld-elf/pr21562d.d: Likewise.
1784         * testsuite/ld-elf/pr21562d.t: Likewise.
1785         * testsuite/ld-elf/pr21562e.d: Likewise.
1786         * testsuite/ld-elf/pr21562f.d: Likewise.
1787         * testsuite/ld-elf/pr21562g.d: Likewise.
1788         * testsuite/ld-elf/pr21562h.d: Likewise.
1789         * testsuite/ld-elf/pr21562i.d: Likewise.
1790         * testsuite/ld-elf/pr21562j.d: Likewise.
1791         * testsuite/ld-elf/pr21562k.d: Likewise.
1792         * testsuite/ld-elf/pr21562l.d: Likewise.
1793         * testsuite/ld-elf/pr21562m.d: Likewise.
1794         * testsuite/ld-elf/pr21562n.d: Likewise.
1795         * testsuite/ld-gc/pr20022.d: Likewise.
1796         * testsuite/ld-gc/pr20022a.s: Likewise.
1797         * testsuite/ld-gc/pr20022b.s: Likewise.
1798         * testsuite/ld-gc/gc.exp: Run PR ld/20022 tests.
1799         * testsuite/ld-gc/pr19161.d: Also accept local __start_SECNAME
1800         symbol.
1801         * testsuite/ld-gc/start.d: Likewise.
1802         * testsuite/ld-x86-64/lea1a.d: Updated.
1803         * testsuite/ld-x86-64/lea1b.d: Updated.
1804         * testsuite/ld-x86-64/lea1d.d: Updated.
1805         * testsuite/ld-x86-64/lea1e.d: Likewise.
1806
1807 2017-06-13  H.J. Lu  <hongjiu.lu@intel.com>
1808
1809         * testsuite/ld-elf/sizeof.d: New file.
1810         * testsuite/ld-elf/sizeof.s: Likewise.
1811         * testsuite/ld-elf/startof.d: Likewise.
1812         * testsuite/ld-elf/startof.s: Likewise.
1813
1814 2017-06-13  Renlin Li  <renlin.li@arm.com>
1815
1816         * testsuite/ld-elf/shared.exp (build_tests): Add --no-dynamic-linker
1817         option to rdynamic-1 and dynamic-1 tests.
1818
1819 2017-06-09  H.J. Lu  <hongjiu.lu@intel.com>
1820
1821         * testsuite/ld-x86-64/property-x86-3-x32.d: New file.
1822         * testsuite/ld-x86-64/property-x86-4a-x32.d: Likewise.
1823         * testsuite/ld-x86-64/property-x86-4b-x32.d: Likewise.
1824         * testsuite/ld-x86-64/property-x86-3.d: Also pass
1825         -defsym __64_bit__=1 to asssembler.
1826         * testsuite/ld-x86-64/property-x86-4a.d: Likewise.
1827         * testsuite/ld-x86-64/property-x86-4b.d: Likewise.
1828         * testsuite/ld-x86-64/property-x86-3.s: Align to 4 bytes if
1829         __64_bit__ isn't defined.
1830         * testsuite/ld-x86-64/property-x86-4a.s: Likewise.
1831         * testsuite/ld-x86-64/property-x86-4b.s: Likewise.
1832         * testsuite/ld-x86-64/x86-64.exp: Run property-x86-3-x32,
1833         property-x86-4a-x32 and property-x86-4b-x32.
1834
1835 2017-06-08  Cupertino Miranda  <cmiranda@synopsys.com>
1836
1837         * testsuite/ld-arc/tls_ie-01.d: Changed expected result.
1838
1839 2017-06-08  H.J. Lu  <hongjiu.lu@intel.com>
1840
1841         * testsuite/ld-ifunc/ifunc-1-local-x86.d: Pass
1842         "-Map tmpdir/ifunc-1-local-x86.map" to ld and check
1843         ifunc-1-local-x86.map.
1844         * testsuite/ld-ifunc/ifunc-1-x86.d: Pass
1845         "-Map tmpdir/ifunc-1-x86.map" to ld and check ifunc-1-x86.map.
1846         * testsuite/ld-ifunc/ifunc-1-local-x86.map: New file.
1847         * testsuite/ld-ifunc/ifunc-1-x86.map: Likewise.
1848
1849 2017-06-07  Alan Modra  <amodra@gmail.com>
1850
1851         * testsuite/ld-unique/pr21529.d: xfail aarch64, arm, hppa, ia64,
1852         nds32, and score.  Match any output.
1853
1854 2017-06-06  Andrew Burgess  <andrew.burgess@embecosm.com>
1855
1856         * ld.h (struct args_type): Fix typo in comment.
1857
1858 2017-06-06  Andrew Burgess  <andrew.burgess@embecosm.com>
1859
1860         * ld.h (struct args_type): Add force_group_allocation field.
1861         * ldgram.y: Add support for FORCE_GROUP_ALLOCATION.
1862         * ldlex.h: Likewise.
1863         * ldlex.l: Likewise.
1864         * lexsup.c: Likewise.
1865         * ldlang.c (unique_section_p): Check resolve_section_groups flag
1866         not the relaxable link flag.
1867         (lang_add_section): Discard section groups when we're resolving
1868         groups.  Clear the SEC_LINK_ONCE flag if we're resolving section
1869         groups.
1870         * ldmain.c (main): Initialise resolve_section_groups flag in
1871         link_info based on command line flags.
1872         * testsuite/ld-elf/group11.d: New file.
1873         * testsuite/ld-elf/group12.d: New file.
1874         * testsuite/ld-elf/group12.ld: New file.
1875         * NEWS: Mention new features.
1876         * ld.texinfo (Options): Document --force-group-allocation.
1877         (Miscellaneous Commands): Document FORCE_GROUP_ALLOCATION.
1878
1879 2017-06-05  H.J. Lu  <hongjiu.lu@intel.com>
1880
1881         PR ld/21529
1882         * testsuite/ld-unique/pr21529.d: New file.
1883         * testsuite/ld-unique/pr21529.s: Likewise.
1884         * testsuite/ld-unique/unique.exp: Run *.d.
1885
1886 2017-06-05  Alan Modra  <amodra@gmail.com>
1887
1888         * ldmain.c (main): Correct setting of link_indo.new_dtags.
1889         * testsuite/ld-elf/now-3.d: Pass --disable-new-dtags to ld
1890         * testsuite/ld-elf/now-4.d: Likewise.
1891         * testsuite/ld-elf/rpath-1.d: Likewise.
1892         * testsuite/ld-elf/rpath-2.d: Likewise.
1893
1894 2017-06-05  Slava Barinov  <v.barinov@samsung.com>
1895
1896         * configure.ac: Add --enable-new-dtags option.
1897         * ldmain.c (main): Set link_info.new_dtags to 1 if when
1898         --enable-new-dtags is switched on.
1899         * configure: Regenerate.
1900         * config.in: Regenerate.
1901
1902 2017-06-02  H.J. Lu  <hongjiu.lu@intel.com>
1903
1904         * emulparams/call_nop.sh: Remove -z prefix-nop.
1905         * ld.texinfo: Likewise.
1906         * testsuite/ld-i386/call3c.d: Check for linker error.
1907         * testsuite/ld-x86-64/call1c.d: Likewise.
1908
1909 2017-06-01  Alan Modra  <amodra@gmail.com>
1910
1911         * emultempl/ppc64elf.em (params): Init plt_localentry0 field.
1912         (enum ppc64_opt): New, replacing OPTION_* defines.  Add
1913         OPTION_PLT_LOCALENTRY, and OPTION_NO_PLT_LOCALENTRY.
1914         (PARSE_AND_LIST_*): Support --plt-localentry and --no-plt-localentry.
1915         * testsuite/ld-powerpc/elfv2so.d: Update.
1916         * testsuite/ld-powerpc/powerpc.exp (TLS opt 5): Use --no-plt-localentry.
1917         * testsuite/ld-powerpc/tlsopt5.d: Update.
1918
1919 2017-05-31  Alan Modra  <amodra@gmail.com>
1920
1921         * emultempl/ppc64elf.em (plt-static-chain help): Fix quoting.
1922
1923 2017-05-22  Jiong Wang  <jiong.wang@arm.com>
1924
1925         * configure.tgt: Set "targ_emul" to "aarch64linux32b" for
1926         aarch64_be-*-linux-gnu_ilp32.  Set "targ_emul" to "aarch64linux32" for
1927         aarch64-*-linux-gnu_ilp32.
1928
1929 2017-05-19  H.J. Lu  <hongjiu.lu@intel.com>
1930
1931         * testsuite/ld-i386/i386.exp: Run property-x86-4a and
1932         property-x86-4b.
1933         * testsuite/ld-x86-64/x86-64.exp: Likewise.
1934         * testsuite/ld-i386/property-x86-4a.d: New file.
1935         * testsuite/ld-i386/property-x86-4a.s: Likewise.
1936         * testsuite/ld-i386/property-x86-4b.d: Likewise.
1937         * testsuite/ld-i386/property-x86-4b.s: Likewise.
1938         * testsuite/ld-x86-64/property-x86-4a.d: Likewise.
1939         * testsuite/ld-x86-64/property-x86-4a.s: Likewise.
1940         * testsuite/ld-x86-64/property-x86-4b.d: Likewise.
1941         * testsuite/ld-x86-64/property-x86-4b.s: Likewise.
1942
1943 2017-05-19  Georg-Johann Lay  <avr@gjlay.de>
1944
1945         PR ld/21472
1946         * emulparams/avrxmega3.sh (RODATA_PM_OFFSET): Set to 0x8000.
1947         * scripttempl/avr.sc (__RODATA_PM_OFFSET__) [RODATA_PM_OFFSET]:
1948         Use RODATA_PM_OFFSET as default if not already defined.
1949         (.data) [!RODATA_PM_OFFSET]: Don't include .rodata and friends.
1950         (.rodata) [RODATA_PM_OFFSET]: Put at an offset of
1951         __RODATA_PM_OFFSET__.
1952
1953 2017-05-18  Nick Clifton  <nickc@redhat.com>
1954
1955         PR ld/21251
1956         * ldfile.c (ldfile_add_library_path): If the path starts with
1957         $SYSROOT then use the sysroot as the real prefix.
1958         * ldlang.c (lang_add_input_file): Treat $SYSROOT in the same
1959         way as =.
1960         * ldlex.l: Add $SYSROOT as allow prefix for a filename.
1961         * ld.texinfo (-L): Document that $SYSROOT acts like = when
1962         prefixing a library search path.
1963         (INPUT): Likewise.
1964         * testsuite/ld-scripts/sysroot-prefix.exp: Add $SYSROOT prefix
1965         tests.
1966
1967 2017-05-18  Alan Modra  <amodra@gmail.com>
1968
1969         * emultempl/elf32.em: Don't compare boolean values against TRUE or FALSE.
1970         * emultempl/pe.em: Likewise.
1971         * emultempl/pep.em: Likewise.
1972         * emultempl/xtensaelf.em (xtensa_wild_group_interleave_callback):
1973         Don't compare enum against TRUE.
1974
1975 2017-05-18  Alan Modra  <amodra@gmail.com>
1976
1977         PR ld/20882
1978         * testsuite/ld-gc/pr20882.d: Don't pass -gdwarf-sections to gas.
1979         Allow for 16-bit address targets and match expected data fully.
1980         * testsuite/ld-gc/pr20882a.s: Delete .debug_line section.
1981         * testsuite/ld-gc/pr20882b.s: Likewise.
1982         * testsuite/ld-gc/pr20882c.s: Likewise.
1983
1984 2017-05-17  H.J. Lu  <hongjiu.lu@intel.com>
1985
1986         PR ld/20882
1987         * testsuite/ld-gc/gc.exp: Run pr20882.
1988         * testsuite/ld-gc/pr20882.d: New file.
1989         * testsuite/ld-gc/pr20882a.s: Likewise.
1990         * testsuite/ld-gc/pr20882b.s: Likewise.
1991         * testsuite/ld-gc/pr20882c.s: Likewise.
1992
1993 2017-05-16  H.J. Lu  <hongjiu.lu@intel.com>
1994
1995         PR ld/21481
1996         * testsuite/ld-x86-64/x86-64.exp: Run PR ld/21481 tests only
1997         if IFUNC is supported by run-time.
1998
1999 2017-05-16  Alan Modra  <amodra@gmail.com>
2000
2001         * plugin.c: Rename occurrences of non_ir_ref.
2002
2003 2017-05-16  Alan Modra  <amodra@gmail.com>
2004
2005         * plugin.c (is_visible_from_outside): Use non_ir_ref_dynamic.
2006         (plugin_notice): Set non_ir_ref for references from regular
2007         objects, non_ir_ref_dynamic for references from dynamic objects.
2008
2009 2017-05-15  Maciej W. Rozycki  <macro@imgtec.com>
2010
2011         * testsuite/ld-mips-elf/mips16e2-pcrel-0.d: New test.
2012         * testsuite/ld-mips-elf/mips16e2-pcrel-1.d: New test.
2013         * testsuite/ld-mips-elf/mips16e2-pcrel-addend-2.d: New test.
2014         * testsuite/ld-mips-elf/mips16e2-pcrel-addend-6.d: New test.
2015         * testsuite/ld-mips-elf/mips16e2-pcrel-n32-0.d: New test.
2016         * testsuite/ld-mips-elf/mips16e2-pcrel-n32-1.d: New test.
2017         * testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-0.d: New test.
2018         * testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-1.d: New test.
2019         * testsuite/ld-mips-elf/mips-elf.exp: Run the new tests.
2020
2021 2017-05-15  Nick Clifton  <nickc@redhat.com>
2022
2023         PR ld/21459
2024         * scripttempl/pe.sc: Add .debug_gdb_scripts section.
2025         * scripttempl/pep.sc: Likewise.
2026
2027 2017-05-12  H.J. Lu  <hongjiu.lu@intel.com>
2028
2029         * testsuite/ld-i386/i386.exp: Run property-x86-3.
2030         * testsuite/ld-x86-64/x86-64.exp: Likewise.
2031         * testsuite/ld-i386/property-x86-3.d: New file.
2032         * testsuite/ld-i386/property-x86-3.s: Likewise.
2033         * testsuite/ld-x86-64/property-x86-3.d: Likewise.
2034         * testsuite/ld-x86-64/property-x86-3.s: Likewise.
2035
2036 2017-05-11  H.J. Lu  <hongjiu.lu@intel.com>
2037
2038         * emulparams/elf_x86_64.sh (TINY_READONLY_SECTION): Replace
2039         .plt.bnd with .plt.sec.
2040         * testsuite/ld-x86-64/bnd-ifunc-1-now.d: Likewise.
2041         * testsuite/ld-x86-64/bnd-ifunc-2-now.d: Likewise.
2042         * testsuite/ld-x86-64/bnd-ifunc-2.d: Likewise.
2043         * testsuite/ld-x86-64/bnd-plt-1-now.d: Likewise.
2044         * testsuite/ld-x86-64/bnd-plt-1.d: Likewise.
2045         * testsuite/ld-x86-64/mpx3.dd: Likewise.
2046         * testsuite/ld-x86-64/mpx3n.dd: Likewise.
2047         * testsuite/ld-x86-64/mpx4.dd: Likewise.
2048         * testsuite/ld-x86-64/mpx4n.dd: Likewise.
2049         * testsuite/ld-x86-64/plt-main-bnd-now.rd: Likewise.
2050         * testsuite/ld-x86-64/pr21038b-now.d: Likewise.
2051         * testsuite/ld-x86-64/pr21038b.d: Likewise.
2052         * testsuite/ld-x86-64/pr21038c-now.d: Likewise.
2053         * testsuite/ld-x86-64/pr21038c.d: Likewise.
2054
2055 2017-05-11  H.J. Lu  <hongjiu.lu@intel.com>
2056
2057         * testsuite/ld-i386/plt-pic2.dd: Updated.
2058         * testsuite/ld-i386/plt2.dd: Likewise.
2059         * testsuite/ld-i386/plt2.rd: Likewise.
2060         * testsuite/ld-i386/pr17689now.rd: Likewise.
2061         * testsuite/ld-ifunc/ifunc-16-i386-now.d: Likewise.
2062         * testsuite/ld-ifunc/ifunc-16-x86-64-now.d: Likewise.
2063         * testsuite/ld-ifunc/pr17154-i386-now.d: Likewise.
2064         * testsuite/ld-ifunc/pr17154-x86-64-now.d: Likewise.
2065         * testsuite/ld-x86-64/bnd-branch-1-now.d: Likewise.
2066         * testsuite/ld-x86-64/bnd-ifunc-2-now.d: Likewise.
2067         * testsuite/ld-x86-64/bnd-plt-1-now.d: Likewise.
2068         * testsuite/ld-x86-64/plt2.dd: Likewise.
2069         * testsuite/ld-x86-64/plt2.rd: Likewise.
2070         * testsuite/ld-x86-64/pr17689now.rd: Likewise.
2071         * testsuite/ld-x86-64/pr21038b-now.d: Likewise.
2072         * testsuite/ld-x86-64/pr21038c-now.d: Likewise.
2073
2074 2017-05-10  H.J. Lu  <hongjiu.lu@intel.com>
2075
2076         * emulparams/i386lynx.sh (CHECK_RELOCS_AFTER_OPEN_INPUT): Set
2077         to yes.
2078         * emulparams/i386moss.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
2079         Likewise.
2080         * emulparams/i386nw.sh (CHECK_RELOCS_AFTER_OPEN_INPUT): Likewise.
2081
2082 2017-05-10  H.J. Lu  <hongjiu.lu@intel.com>
2083
2084         PR ld/21481
2085         * testsuite/ld-x86-64/pr21481a.c: New file.
2086         * testsuite/ld-x86-64/pr21481b.S: Likewise.
2087         * testsuite/ld-x86-64/x86-64.exp: Run PR ld/21481 tests.
2088
2089 2017-05-10  Claudiu Zissulescu  <claziss@synopsys.com>
2090
2091         * testsuite/ld-arc/attr-merge-0.d: New file.
2092         * testsuite/ld-arc/attr-merge-0.s: Likewise.
2093         * testsuite/ld-arc/attr-merge-0e.s: Likewise.
2094         * testsuite/ld-arc/attr-merge-1.d: Likewise.
2095         * testsuite/ld-arc/attr-merge-1.s: Likewise.
2096         * testsuite/ld-arc/attr-merge-1e.s: Likewise.
2097         * testsuite/ld-arc/attr-merge-2.d: Likewise.
2098         * testsuite/ld-arc/attr-merge-2.s: Likewise.
2099         * testsuite/ld-arc/attr-merge-3.d: Likewise.
2100         * testsuite/ld-arc/attr-merge-3.s: Likewise.
2101         * testsuite/ld-arc/attr-merge-3e.s: Likewise.
2102         * testsuite/ld-arc/attr-merge-4.s: Likewise.
2103         * testsuite/ld-arc/attr-merge-5.d: Likewise.
2104         * testsuite/ld-arc/attr-merge-5a.s: Likewise.
2105         * testsuite/ld-arc/attr-merge-5b.s: Likewise.
2106         * testsuite/ld-arc/attr-merge-conflict-isa.d: Likewise.
2107         * testsuite/ld-arc/attr-merge-err-isa.d: Likewise.
2108         * testsuite/ld-arc/attr-merge-incompatible-cpu.d: Likewise.
2109         * testsuite/ld-arc/got-01.d: Update test.
2110         * testsuite/ld-arc/attr-merge-err-quarkse.d: New file.
2111         * testsuite/ld-arc/attr-quarkse.s: Likewise.
2112         * testsuite/ld-arc/attr-quarkse2.s: Likewise.
2113
2114 2017-05-09  Awson  <kyrab@mail.ru>
2115
2116         PR ld/21471
2117         * pe-dll.c (pe_detail_list): Add entry for pe-bigobj-x86-64.
2118
2119 2017-05-09  Benjamin Peterson  <bp@benjamin.pe>
2120
2121         * ld.texinfo (orphan sections): Grammar fix.
2122
2123 2017-05-08  H.J. Lu  <hongjiu.lu@intel.com>
2124
2125         * testsuite/ld-ifunc/ifunc-16-x86-64-now.d: New file.
2126         * testsuite/ld-ifunc/ifunc-2-local-x86-64-now.d: Likewise.
2127         * testsuite/ld-ifunc/ifunc-2-x86-64-now.d: Likewise.
2128         * testsuite/ld-ifunc/pr17154-x86-64-now.d: Likewise.
2129         * testsuite/ld-x86-64/bnd-branch-1-now.d: Likewise.
2130         * testsuite/ld-x86-64/bnd-ifunc-1-now.d: Likewise.
2131         * testsuite/ld-x86-64/bnd-ifunc-2-now.d: Likewise.
2132         * testsuite/ld-x86-64/bnd-plt-1-now.d: Likewise.
2133         * testsuite/ld-x86-64/mpx3n.dd: Likewise.
2134         * testsuite/ld-x86-64/mpx4n.dd: Likewise.
2135         * testsuite/ld-x86-64/plt-main-bnd-now.rd: Likewise.
2136         * testsuite/ld-x86-64/plt2.dd: Likewise.
2137         * testsuite/ld-x86-64/plt2.rd: Likewise.
2138         * testsuite/ld-x86-64/plt2.s: Likewise.
2139         * testsuite/ld-x86-64/pr20830a-now.d: Likewise.
2140         * testsuite/ld-x86-64/pr20830b-now.d: Likewise.
2141         * testsuite/ld-x86-64/pr21038a-now.d: Likewise.
2142         * testsuite/ld-x86-64/pr21038b-now.d: Likewise.
2143         * testsuite/ld-x86-64/pr21038c-now.d: Likewise.
2144         * testsuite/ld-x86-64/load1b-nacl.d: Updated.
2145         * testsuite/ld-x86-64/load1b.d: Likewise.
2146         * testsuite/ld-x86-64/plt-main-bnd.dd: Likewise.
2147         * testsuite/ld-x86-64/pr20253-1h.d: Likewise.
2148         * testsuite/ld-x86-64/pr20830a.d: Update the .plt.got section
2149         with func@plt.
2150         * testsuite/ld-x86-64/pr20830b.d: Likewise.
2151         * testsuite/ld-x86-64/pr21038a.d: Likewise.
2152         * testsuite/ld-x86-64/pr21038c.d: Likewise.
2153         * testsuite/ld-x86-64/mpx.exp: Add some -z now tests.
2154         * testsuite/ld-x86-64/x86-64.exp: Likewise.
2155
2156 2017-05-08  H.J. Lu  <hongjiu.lu@intel.com>
2157
2158         * testsuite/ld-i386/i386.exp: Add some -z now tests.
2159         * testsuite/ld-i386/plt-pic2.dd: New file.
2160         * testsuite/ld-i386/plt2.dd: Likewise.
2161         * testsuite/ld-i386/plt2.rd: Likewise.
2162         * testsuite/ld-i386/plt2.s: Likewise.
2163         * testsuite/ld-ifunc/ifunc-16-i386-now.d: Likewise.
2164         * testsuite/ld-ifunc/ifunc-2-i386-now.d: Likewise.
2165         * testsuite/ld-ifunc/ifunc-2-local-i386-now.d: Likewise.
2166         * testsuite/ld-ifunc/pr17154-i386-now.d: Likewise.
2167         * testsuite/ld-i386/pr20830.d: Update the .plt.got section
2168         with func@plt.
2169
2170 2017-05-08  Thomas Preud'homme  <thomas.preudhomme@arm.com>
2171
2172         * testsuite/ld-arm/arm-elf.exp
2173         (Secure gateway import library generation): Check e_type field
2174         of import library and executable produced.
2175         * testsuite/ld-arm/cmse-implib.type: Expectations for e_type field.
2176
2177 2017-04-28  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
2178
2179         PR ld/21404
2180         * testsuite/ld-avr/pr21404-1.d: New test.
2181         * testsuite/ld-avr/pr21404-1.s: New test.
2182         * testsuite/ld-avr/pr21404-2.d: New test.
2183         * testsuite/ld-avr/pr21404-2.s: New test.
2184         * testsuite/ld-avr/pr21404-3.d: New test.
2185         * testsuite/ld-avr/pr21404-3.s: New test.
2186         * testsuite/ld-avr/pr21404-4.d: New test.
2187         * testsuite/ld-avr/pr21404-4.s: New test.
2188         * testsuite/ld-avr/pr21404-5.d: New test.
2189         * testsuite/ld-avr/pr21404-5.s: New test.
2190         * testsuite/ld-avr/pr21404-6.d: New test.
2191         * testsuite/ld-avr/pr21404-6.s: New test.
2192         * testsuite/ld-avr/pr21404-7.d: New test.
2193         * testsuite/ld-avr/pr21404-7.s: New test.
2194         * testsuite/ld-avr/pr21404-8.d: New test.
2195         * testsuite/ld-avr/pr21404-8.s: New test.
2196
2197 2017-05-03  Maciej W. Rozycki  <macro@imgtec.com>
2198
2199         * testsuite/ld-mips-elf/mips16-pcrel-0.d: New test.
2200         * testsuite/ld-mips-elf/mips16-pcrel-1.d: New test.
2201         * testsuite/ld-mips-elf/mips16-pcrel-addend-2.d: New test.
2202         * testsuite/ld-mips-elf/mips16-pcrel-addend-6.d: New test.
2203         * testsuite/ld-mips-elf/mips16-pcrel-n32-0.d: New test.
2204         * testsuite/ld-mips-elf/mips16-pcrel-n32-1.d: New test.
2205         * testsuite/ld-mips-elf/mips16-pcrel-n64-sym32-0.d: New test.
2206         * testsuite/ld-mips-elf/mips16-pcrel-n64-sym32-1.d: New test.
2207         * testsuite/ld-mips-elf/mips-elf.exp: Run the new tests.
2208
2209 2017-05-03  H.J. Lu  <hongjiu.lu@intel.com>
2210
2211         * testsuite/ld-elf/pr21384.d: Adjusted to accommodate
2212         additional dynamic symbols on some targets.
2213
2214 2017-05-02  Maciej W. Rozycki  <macro@imgtec.com>
2215
2216         * testsuite/ld-mips-elf/mips16-branch-absolute-1.d: New test.
2217         * testsuite/ld-mips-elf/mips16-branch-absolute-2.d: New test.
2218         * testsuite/ld-mips-elf/mips16-branch-absolute-addend-1.d: New
2219         test.
2220         * testsuite/ld-mips-elf/mips16-branch-absolute-n32-1.d: New
2221         test.
2222         * testsuite/ld-mips-elf/mips16-branch-absolute-n32-2.d: New
2223         test.
2224         * testsuite/ld-mips-elf/mips16-branch-absolute-addend-n32-1.d:
2225         New test.
2226         * testsuite/ld-mips-elf/mips16-branch-absolute-n64-1.d: New
2227         test.
2228         * testsuite/ld-mips-elf/mips16-branch-absolute-n64-2.d: New
2229         test.
2230         * testsuite/ld-mips-elf/mips16-branch-absolute-addend-n64-1.d:
2231         New test.
2232         * testsuite/ld-mips-elf/mips-elf.exp: Run the new tests.
2233
2234 2017-05-02  H.J. Lu  <hongjiu.lu@intel.com>
2235
2236         * testsuite/ld-i386/tls.exp: Add -Wl,--no-as-needed to
2237         "TLS without PLT (1)" and "TLS without PLT (3)".
2238         * testsuite/ld-x86-64/tls.exp: Add -Wl,--no-as-needed to
2239         to "TLS without PLT (3)".
2240
2241 2017-05-02  H.J. Lu  <hongjiu.lu@intel.com>
2242
2243         PR ld/21384
2244         * testsuite/ld-elf/pr21384.d: New file.
2245         * testsuite/ld-elf/pr21384.dl: Likewise.
2246         * testsuite/ld-elf/pr21384.ld: Likewise.
2247         * testsuite/ld-elf/pr21384.s: Likewise.
2248
2249 2017-05-01  H.J. Lu  <hongjiu.lu@intel.com>
2250
2251         * testsuite/ld-i386/tls.exp: Run GNU2 TLS tests only if there
2252         is working GNU2 TLS support.
2253         * testsuite/ld-x86-64/tls.exp: Likewise.
2254         * testsuite/lib/ld-lib.exp (check_gnu2_tls_available): New proc.
2255
2256 2017-04-28  H.J. Lu  <hongjiu.lu@intel.com>
2257
2258         * testsuite/config/default.exp (GNU2_CFLAGS): New.  Set
2259         to -mtls-dialect=gnu2 if target compiler supports it.
2260         * testsuite/ld-i386/tls.exp: Run -mtls-dialect=gnu2 tests.
2261         * testsuite/ld-x86-64/tls.exp: Likewise.
2262         * testsuite/ld-i386/tlsdesc1a.c: New file.
2263         * testsuite/ld-i386/tlsdesc1b.c: Likewise.
2264         * testsuite/ld-x86-64/tlsdesc1a.c: Likewise.
2265         * testsuite/ld-x86-64/tlsdesc1b.c: Likewise.
2266
2267 2017-04-28  H.J. Lu  <hongjiu.lu@intel.com>
2268
2269         * testsuite/ld-elf/shared.exp: Add run-time tests for -z now.
2270         * testsuite/ld-i386/tls.exp: Likewise.
2271         * testsuite/ld-ifunc/ifunc.exp: Likewise.
2272         * testsuite/ld-x86-64/tls.exp: Likewise.
2273
2274 2017-04-27  H.J. Lu  <hongjiu.lu@intel.com>
2275
2276         * testsuite/ld-x86-64/pr21038a.d: Update DW_CFA_nop paddings
2277         in .eh_frame section.
2278         * testsuite/ld-x86-64/pr21038c.d: Update .eh_frame order.
2279
2280 2017-04-26  H.J. Lu  <hongjiu.lu@intel.com>
2281
2282         * testsuite/ld-i386/tlsdesc2.d: New test.
2283         * testsuite/ld-x86-64/tlsdesc2.d: Likewise.
2284
2285 2017-04-26  Maciej W. Rozycki  <macro@imgtec.com>
2286
2287         PR ld/21334
2288         * testsuite/ld-mips-elf/pr21334.dd: New test.
2289         * testsuite/ld-mips-elf/pr21334.gd: New test.
2290         * testsuite/ld-mips-elf/pr21334.ld: New test linker script.
2291         * testsuite/ld-mips-elf/pr21334.s: New test source.
2292         * testsuite/ld-mips-elf/mips-elf.exp: Run the new tests.
2293
2294 2017-04-24  H.J. Lu  <hongjiu.lu@intel.com>
2295
2296         * testsuite/ld-x86-64/no-plt.exp: Also check no-plt-1e.nd.
2297         * testsuite/ld-x86-64/no-plt-1e.nd: New file.
2298
2299 2017-04-24  H.J. Lu  <hongjiu.lu@intel.com>
2300
2301         * testsuite/ld-i386/pr12570a.d: Skip for nacl targets.
2302         * testsuite/ld-i386/pr12570b.d: Likewise.
2303
2304 2017-04-24  H.J. Lu  <hongjiu.lu@intel.com>
2305
2306         PR ld/20815
2307         * testsuite/ld-i386/vxworks2.sd: Add space for program headers.
2308
2309 2017-04-24  Jose E. Marchesi  <jose.marchesi@oracle.com>
2310
2311         * testsuite/ld-sparc/tlssunbin64.dd: Expect `return' instructions
2312         instead of `rett' in V9.
2313         * testsuite/ld-sparc/tlssunnopic64.dd: Likewise.
2314         * testsuite/ld-sparc/tlssunpic64.dd: Likewise.
2315
2316 2017-04-21  H.J. Lu  <hongjiu.lu@intel.com>
2317
2318         PR ld/21402
2319         * testsuite/ld-elf/indirect.exp: Don't skip PIE indirect5 and
2320         indirect6 tests on i386.
2321
2322 2017-04-21  H.J. Lu  <hongjiu.lu@intel.com>
2323
2324         PR ld/19617
2325         PR ld/21086
2326         * testsuite/ld-elf/pr19617a.d: Pass --no-dynamic-linker to ld.
2327         * testsuite/ld-elf/pr19617b.d: Likewise.
2328         * testsuite/ld-elf/pr19617c.d: Likewise.
2329         *testsuite/ld-i386/pr19636-4d.d: Likewise.
2330         * testsuite/ld-elf/readelf.exp: Pass --no-dynamic-linker to ld
2331         with --export-dynamic.
2332         * testsuite/ld-elf/shared.exp: Pass --no-dynamic-linker to ld
2333         with -E.
2334
2335 2017-04-20  H.J. Lu  <hongjiu.lu@intel.com>
2336
2337         PR ld/21402
2338         * testsuite/ld-elf/indirect.exp: Pass $NOPIE_LDFLAGS and
2339         $NOPIE_CFLAGS to non-PIE indirect5 and indirect6 tests.  Skip
2340         PIE indirect5 and indirect6 tests on i386.
2341
2342 2017-04-20  Maciej W. Rozycki  <macro@imgtec.com>
2343
2344         * testsuite/ld-mips-elf/mips-elf.exp: Join `__ehdr_start' tests.
2345
2346 2017-04-20  H.J. Lu  <hongjiu.lu@intel.com>
2347
2348         PR ld/21382
2349         * plugin.c (is_visible_from_outside): Symbol may be visible
2350         from outside if dynamic_ref_after_ir_def is set.
2351         (plugin_notice): Set dynamic_ref_after_ir_def if the symbol is
2352         defined in an IR object and referenced in a dynamic object.
2353         * testsuite/ld-plugin/lto.exp: Run PR ld/21382 tests.
2354         * testsuite/ld-plugin/pr21382a.c: New file.
2355         * testsuite/ld-plugin/pr21382b.c: Likewise.
2356
2357 2017-04-19  H.J. Lu  <hongjiu.lu@intel.com>
2358
2359         PR ld/21401
2360         * testsuite/ld-ifunc/ifunc.exp: Add a libtest-2-now.so test with
2361         -z now.
2362
2363 2017-04-19  Alan Modra  <amodra@gmail.com>
2364
2365         * ld.texinfo (dynamic-undefined-weak): Document.
2366         (nodynamic-undefined-weak): Document that this option now can
2367         be used with shared libs.
2368         * emulparams/dynamic_undefined_weak.sh: Support -z
2369         dynamic-undefined-weak.
2370         * emulparams/elf32ppccommon.sh: Include dynamic_undefined_weak.sh.
2371         * testsuite/ld-undefined/weak-undef.exp (undef_weak_so),
2372         (undef_weak_exe): New.  Use them.  Add -z dynamic-undefined-weak
2373         and -z nodynamic-undefined-weak tests.
2374         * Makefile.am: Update powerpc dependencies.
2375         * Makefile.in: Regenerate.
2376
2377 2017-04-17  H.J. Lu  <hongjiu.lu@intel.com>
2378
2379         PR ld/21389
2380         * testsuite/ld-elf/pr21389.map: New file.
2381         * testsuite/ld-elf/pr21389.s: Likewise.
2382         * testsuite/ld-elf/pr21389a.d: Likewise.
2383         * testsuite/ld-elf/pr21389b.d: Likewise.
2384         * testsuite/ld-elf/pr21389c.d: Likewise.
2385
2386 2017-04-17  Alan Modra  <amodra@gmail.com>
2387
2388         * testsuite/ld-elf/indirect5a.c,
2389         * testsuite/ld-elf/indirect5b.c,
2390         * testsuite/ld-elf/indirect5.map,
2391         * testsuite/ld-elf/indirect5.out: New test.
2392         * testsuite/ld-elf/indirect6a.c: Likewise.
2393         * testsuite/ld-elf/indirect.exp (check_dynamic_syms): New proc.
2394         Run new tests and check dynsyms.
2395
2396 2017-04-11  Alan Modra  <amodra@gmail.com>
2397
2398         PR 21274
2399         PR 18466
2400         * emultempl/pe.em (pe_find_data_imports): Don't use fixed size
2401         symbol buffer.  Instead, xmalloc max size needed with space for
2402         prefix.  Wrap overlong lines.  Formatting.  Pass symbol buffer
2403         copy of name to pe_walk_relocs_of_symbol.
2404         (make_inport_fixup): Add "name" param, pass to pe_create_import_fixup.
2405         * emultempl/pe.em (pep_find_data_imports): As for pe_find_data_imports.
2406         (make_import_fixup): Add "name" param, pass to pep_create_import_fixup.
2407         Use bfd_get_signed_* and remove unnecessary casts.  Formatting.
2408         * pe-dll.c (pe_walk_relocs_of_symbol): Add "name" param.  Pass to
2409         callback.
2410         (make_import_fixup_mark): Add "name" param.  Make use of prefix
2411         space rather than xmalloc here.
2412         (pe_create_import_fixup): Likewise.
2413         * pe-dll.h (pe_walk_relocs_of_symbol): Update prototype.
2414         (pe_create_import_fixup): Likewise.
2415         * pep-dll.h (pep_walk_relocs_of_symbol): Likewise.
2416         (pep_create_import_fixup): Likewise.
2417
2418 2017-04-10  Nick Clifton  <nickc@redhat.com>
2419
2420         * ld.texinfo (--strip-discarded): Document.
2421         (--embedded-relocs): Document.
2422         (--spare-dynamic-tags): Document.
2423         (--task-link): Document.
2424
2425 2017-04-10  Alan Modra  <amodra@gmail.com>
2426
2427         PR 21287
2428         * testsuite/ld-elf/init-fini-arrays.d: Match INIT_ARRAY and FINI_ARRAY.
2429         * testsuite/ld-elf/init-fini-arrays.s: Use %init_array and %fini_array
2430         section types.
2431         * testsuite/lib/ld-lib.exp (default_ld_compile): Trim assembler
2432         warnings about "ignoring incorrect section type".
2433         (run_ld_link_exec_tests, run_cc_link_tests): Delete old comment.
2434
2435 2017-04-10  Alan Modra  <amodra@gmail.com>
2436
2437         * testsuite/ld-elfvsb/elfvsb.exp (visibility_run): Delete
2438         sh1p.o, sh2p.o, sh1np.o and sh2np.o before compiling.  Use
2439         remote_file host exists rather than file exists.
2440
2441 2017-04-07  H.J. Lu  <hongjiu.lu@intel.com>
2442
2443         PR ld/21090
2444         * testsuite/ld-x86-64/x86-64.exp (undefined_weak): Use
2445         NOPIE_CFLAGS and NOPIE_LDFLAGS to disable PIE for the non-pie
2446         version of the test.
2447
2448 2017-04-07  H.J. Lu  <hongjiu.lu@intel.com>
2449
2450         PR ld/19579
2451         PR ld/21306
2452         * testsuite/ld-elf/pr19579a.c (main): Updated.
2453
2454 2017-04-07  Nick Clifton  <nickc@redhat.com>
2455
2456         PR 21090
2457         * testsuite/ld-x86-64/x86-64.exp (undefined_weak): Explicitly
2458         disable PIE for the non-pie version of the test.
2459
2460 2017-04-07  Alan Modra  <amodra@gmail.com>
2461
2462         * testsuite/ld-elf/mbind2a.s: Don't use @, the ARM comment char.
2463
2464 2017-04-07  gingold  <gingold@gingold-Precision-7510>
2465
2466         * testsuite/ld-pe/pe.exp: New test.
2467         * testsuite/ld-pe/weakdef-1.s: New test source.
2468         * testsuite/ld-pe/weakdef-1.d: New test.
2469
2470 2017-04-07  Alan Modra  <amodra@gmail.com>
2471
2472         * testsuite/ld-elf/mbind1a.d: Remove matches for PT_LOAD segments.
2473         * testsuite/ld-elf/mbind1b.d: Likewise.
2474         * testsuite/ld-elf/mbind1c.d: Likewise.
2475
2476 2017-04-05  Hans-Peter Nilsson  <hp@axis.com>
2477
2478         PR ld/21233
2479         * testsuite/ld-elf/shared.exp: Change xfails to kfails and fix
2480         indentation issue introduced with last commit.
2481
2482 2017-04-05  Hans-Peter Nilsson  <hp@axis.com>
2483
2484         PR ld/21233
2485         * testsuite/ld-elf/shared.exp: Xfail all PR21233 tests but the
2486         first test for cris*-*-*.
2487
2488 2017-04-04  Maciej W. Rozycki  <macro@imgtec.com>
2489
2490         PR ld/21233
2491         * ldlang.c (insert_undefined): Set `mark' for ELF symbols.
2492         * testsuite/ld-elf/pr21233.sd: New test.
2493         * testsuite/ld-elf/pr21233-l.sd: New test.
2494         * testsuite/ld-elf/pr21233.ld: New test linker script.
2495         * testsuite/ld-elf/pr21233-e.ld: New test linker script.
2496         * testsuite/ld-elf/pr21233.s: New test source.
2497         * testsuite/ld-elf/pr21233-l.s: New test source.
2498         * testsuite/ld-elf/shared.exp: Run the new tests.
2499
2500 2017-04-04  H.J. Lu  <hongjiu.lu@intel.com>
2501
2502         * NEWS: Mention support for ELF SHF_GNU_MBIND and
2503         PT_GNU_MBIND_XXX.
2504         * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Place
2505         input GNU_MBIND sections with the same type, attributes and
2506         sh_info field into a single output GNU_MBIND section.
2507         * testsuite/ld-elf/elf.exp: Run mbind2a and mbind2b.
2508         * testsuite/ld-elf/mbind1.s: New file.
2509         * testsuite/ld-elf/mbind1a.d: Likewise.
2510         * testsuite/ld-elf/mbind1b.d: Likewise.
2511         * testsuite/ld-elf/mbind1c.d: Likewise.
2512         * testsuite/ld-elf/mbind2a.s: Likewise.
2513         * testsuite/ld-elf/mbind2b.c: Likewise.
2514
2515 2017-04-03  H.J. Lu  <hongjiu.lu@intel.com>
2516
2517         * NEWS: Mention support for ELF GNU program properties.
2518         * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Call
2519         ELF setup_gnu_properties.
2520         * testsuite/ld-i386/i386.exp: Run property tests for Linux/i386.
2521         * testsuite/ld-i386/pass.c: New file.
2522         * testsuite/ld-i386/property-1.r: Likewise.
2523         * testsuite/ld-i386/property-2.r: Likewise.
2524         * testsuite/ld-i386/property-3.r: Likewise.
2525         * testsuite/ld-i386/property-4.r: Likewise.
2526         * testsuite/ld-i386/property-5.r: Likewise.
2527         * testsuite/ld-i386/property-6.r: Likewise.
2528         * testsuite/ld-i386/property-6a.c: Likewise.
2529         * testsuite/ld-i386/property-6b.c: Likewise.
2530         * testsuite/ld-i386/property-6c.S: Likewise.
2531         * testsuite/ld-i386/property-7.r: Likewise.
2532         * testsuite/ld-i386/property-no-copy.S: Likewise.
2533         * testsuite/ld-i386/property-stack.S: Likewise.
2534         * testsuite/ld-i386/property-unsorted-1.S: Likewise.
2535         * testsuite/ld-i386/property-unsorted-2.S: Likewise.
2536         * testsuite/ld-i386/property-x86-1.S: Likewise.
2537         * testsuite/ld-i386/property-x86-2.S: Likewise.
2538         * testsuite/ld-x86-64/pass.c: Likewise.
2539         * testsuite/ld-x86-64/property-1.r: Likewise.
2540         * testsuite/ld-x86-64/property-2.r: Likewise.
2541         * testsuite/ld-x86-64/property-3.r: Likewise.
2542         * testsuite/ld-x86-64/property-4.r: Likewise.
2543         * testsuite/ld-x86-64/property-5.r: Likewise.
2544         * testsuite/ld-x86-64/property-6.r: Likewise.
2545         * testsuite/ld-x86-64/property-6a.c: Likewise.
2546         * testsuite/ld-x86-64/property-6b.c: Likewise.
2547         * testsuite/ld-x86-64/property-6c.S: Likewise.
2548         * testsuite/ld-x86-64/property-7.r: Likewise.
2549         * testsuite/ld-x86-64/property-no-copy.S: Likewise.
2550         * testsuite/ld-x86-64/property-stack.S: Likewise.
2551         * testsuite/ld-x86-64/property-unsorted-1.S: Likewise.
2552         * testsuite/ld-x86-64/property-unsorted-2.S: Likewise.
2553         * testsuite/ld-x86-64/property-x86-1.S: Likewise.
2554         * testsuite/ld-x86-64/property-x86-2.S: Likewise.
2555         * testsuite/ld-x86-64/x86-64.exp: Run property tests for
2556         Linux/x86-64.
2557
2558 2017-03-28  Hans-Peter Nilsson  <hp@axis.com>
2559
2560         PR ld/16044
2561         * testsuite/ld-cris/pr16044.d, testsuite/ld-cris/dso-1c.s,
2562         testsuite/ld-cris/dso-2b.s, testsuite/ld-cris/dso-4.s: New test.
2563
2564 2017-03-21  Sandra Loosemore  <sandra@codesourcery.com>
2565
2566         * testsuite/lib/ld-lib.exp (check_shared_lib_support): Return
2567         false for nios2-*-elf.
2568
2569 2017-03-21  gingold  <gingold@gingold-Precision-7510>
2570
2571         * ldlang.c (lang_check_section_addresses): Check only for
2572         allocated sections.
2573
2574 2017-03-17  Alan Modra  <amodra@gmail.com>
2575
2576         * testsuite/ld-elf/sec64k.exp: Don't run on h8300 and ip2k.
2577
2578 2017-03-15  Tristan Gingold  <gingold@adacore.com>
2579
2580         * testsuite/ld-checks/checks.exp (overflow_check): Disable for
2581         non-elf targets.
2582
2583 2017-03-14  H.J. Lu  <hongjiu.lu@intel.com>
2584
2585         * ldlang.c (lang_check_section_addresses): Use addr_mask to
2586         check VMA and LMA.
2587
2588 2017-03-13  Nick Clifton  <nickc@redhat.com>
2589
2590         PR binutils/21202
2591         * testsuite/ld-aarch64/ifunc-5r-local.d: Update regexp.
2592
2593 2017-03-13  Tristan Gingold  <gingold@adacore.com>
2594
2595         * ldlang.c (lang_check_section_addresses): Check for address space
2596         overflow.
2597         * testsuite/ld-checks/checks.exp (overflow_check): New procedure
2598         * testsuite/ld-checks/over.s: New test source.
2599         * testsuite/ld-checks/over.d: New test.
2600         * testsuite/ld-checks/over2.s: New test source.
2601         * testsuite/ld-checks/over2.d: New test.
2602
2603 2017-03-13  Alexey Neyman  <stilor@att.net>
2604
2605         * emulparams/elf32ppccommon.sh (LIBPATH_SUFFIX): Set from target
2606         cpu, not host.
2607
2608 2017-03-11  Alan Modra  <amodra@gmail.com>
2609
2610         * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Add
2611         sysroot for -rpath search.
2612
2613 2017-03-11  Alan Modra  <amodra@gmail.com>
2614
2615         * emultempl/elf32.em (gld${EMULATION_NAME}_add_sysroot): Rewrite.
2616         Only prefix absolute paths with sysroot.  Handle DOS paths.
2617         (gld${EMULATION_NAME}_check_ld_elf_hints): Constify variable.
2618         (gld${EMULATION_NAME}_check_ld_so_conf): Likewise.
2619         (gld${EMULATION_NAME}_after_open): Short-circuit NULL path
2620         searches.  Rename variable.  Simplify get_runpath search.
2621
2622 2017-03-11  Alan Modra  <amodra@gmail.com>
2623
2624         * testsuite/ld-elf/shared.exp: Use -Wl,-export-dynamic rather
2625         than -rdynamic.
2626
2627 2017-03-11  Alan Modra  <amodra@gmail.com>
2628
2629         * ld.texinfo (Orphan Sections): Mention that not all targets
2630         handle orphans well.
2631         * testsuite/ld-elf/orphan-9.d: Don't run for i860 and i960.
2632         * testsuite/ld-elf/orphan-10.d: Likewise.
2633
2634 2017-03-09  Andrew Burgess  <andrew.burgess@embecosm.com>
2635
2636         * ldlang.c (lang_size_sections_1): Shortcut loop only after
2637         tracking changes to the default regions LMA.
2638         * testsuite/ld-elf/orphan-9.ld: Extend header comment.
2639         * testsuite/ld-elf/orphan-10.d: New file.
2640         * testsuite/ld-elf/orphan-10.s: New file.
2641         * NEWS: Mention change in behaviour.
2642
2643 2017-03-09  Andrew Burgess  <andrew.burgess@embecosm.com>
2644
2645         * ldlang.c (lang_leave_output_section_statement): Move lma_region
2646         logic to...
2647         (lang_propagate_lma_regions): ...this new function.
2648         (lang_process): Call new function.
2649         * testsuite/ld-elf/orphan-9.d: New file.
2650         * testsuite/ld-elf/orphan-9.ld: New file.
2651         * testsuite/ld-elf/orphan-9.s: New file.
2652         * NEWS: Mention change in behaviour.
2653
2654 2017-03-07  Alan Modra  <amodra@gmail.com>
2655
2656         * ldlang.c (open_input_bfds): Check that lang_assignment_statement
2657         is not an assert before referencing defsym.
2658
2659 2017-03-05  Alan Modra  <amodra@gmail.com>
2660
2661         * testsuite/ld-elf/eh3.d: Adjust for eh_frame alignment change.
2662         * testsuite/ld-elf/eh6.d: Likewise.
2663         * testsuite/ld-alpha/tlsbin.dd: Likewise.
2664         * testsuite/ld-alpha/tlsbin.td: Likewise.
2665         * testsuite/ld-alpha/tlsbinr.dd: Likewise.
2666         * testsuite/ld-alpha/tlspic.dd: Likewise.
2667         * testsuite/ld-alpha/tlspic.rd: Likewise.
2668         * testsuite/ld-alpha/tlspic.sd: Likewise.
2669         * testsuite/ld-alpha/tlspic.td: Likewise.
2670         * testsuite/ld-mips-elf/eh-frame1-n64.d: Likewise.
2671         * testsuite/ld-mips-elf/eh-frame2-n64.d: Likewise.
2672         * testsuite/ld-mips-elf/eh-frame3.d: Likewise.
2673         * testsuite/ld-x86-64/pr20830a.d: Likewise.
2674         * testsuite/ld-x86-64/pr21038a.d: Likewise.
2675         * testsuite/ld-x86-64/pr21038b.d: Likewise.
2676         * testsuite/ld-x86-64/pr21038c.d: Likewise.
2677
2678 2017-03-03  Max Bolingbroke  <batterseapower@hotmail.com>
2679
2680         PR 12969
2681         * pe-dll.c (generate_edata): Fail if the input file(s) require too
2682         many ordinals.
2683
2684 2017-03-02  Alan Modra  <amodra@gmail.com>
2685
2686         * testsuite/ld-elf/shared.exp: Pass -ansi when compiling new.cc
2687         and dl3.cc.
2688
2689 2017-02-28  Alan Modra  <amodra@gmail.com>
2690
2691         * testsuite/ld-elf/merge.d: xfail for nios.
2692
2693 2017-02-28  Alan Modra  <amodra@gmail.com>
2694
2695         * testsuite/ld-powerpc/addpcis.d: Define ext1 and ext2 at
2696         limits of addpcis range.
2697
2698 2017-02-28  Maciej W. Rozycki  <macro@imgtec.com>
2699
2700         * testsuite/ld-mips-elf/jalr4.dd: Adjust for `jalr $0, $25'
2701         instructions.
2702         * testsuite/ld-mips-elf/jalr4-r6.dd: New test.
2703         * testsuite/ld-mips-elf/mips-elf.exp: Run the new test.
2704
2705 2017-02-27   Georg-Johann Lay  <gjl@gcc.gnu.org>
2706
2707         PR target/20849
2708         * scripttempl/avrtiny.sc (__RODATA_PM_OFFSET__): New define.
2709         (.rodata): New section.
2710         (.data): Remove .rodata*.
2711
2712 2017-02-25  Alan Modra  <amodra@gmail.com>
2713
2714         * testsuite/ld-elf/elf.exp: Xfail pr20995 tests on hppa64-hpux.
2715         Set up HPUX defsym.  Run pr14170 tests and build symbol3 objects,
2716         defining HPUX where necessary.  Define HPUX for implib tests.
2717         * testsuite/ld-elf/comm-data4.d: Run for hpux.
2718         * testsuite/ld-elf/endsym.d: Likewise.
2719         * testsuite/ld-elf/linkoncerdiff.d: Likewise.
2720         * testsuite/ld-elf/comm-data4.s: Add alternate .comm when HPUX.
2721         * testsuite/ld-elf/comm-data5.s: Likewise.
2722         * testsuite/ld-elf/endsym.s: Likewise.
2723         * testsuite/ld-elf/pr14170c.s: Likewise.
2724         * testsuite/ld-elf/symbol3.s: Likewise.
2725         * testsuite/ld-elf/implib.s: Likewise.  Don't start directives
2726         in first column.
2727         * testsuite/ld-elf/linkoncerdiff2.s: Don't use numeric labels.
2728         * testsuite/ld-elf/warn3.d: Run for hpux.
2729         * testsuite/ld-scripts/rgn-at10.d: Xfail for hpux.
2730         * testsuite/ld-scripts/rgn-at11.d: Likewise.
2731         * testsuite/ld-scripts/size-2.d: Remove xfail for hpux.
2732
2733 2017-02-24  Maciej W. Rozycki  <macro@imgtec.com>
2734
2735         * testsuite/ld-elf/ver_def.vd: New test.
2736         * testsuite/ld-elf/ver_def-tic6x.vd: New test.
2737         * testsuite/ld-elf/ver_def.ld: New test linker script.
2738         * testsuite/ld-elf/ver_def.ver: New test version script.
2739         * testsuite/ld-elf/ver_def.s: New test source.
2740         * testsuite/ld-elf/readelf.exp: New test script.
2741
2742 2017-02-23  Maciej W. Rozycki  <macro@imgtec.com>
2743
2744         * testsuite/ld-mips-elf/relax-jalr-n32.d: Remove `--relax'
2745         option.
2746         * testsuite/ld-mips-elf/relax-jalr-n32-shared.d: Likewise.
2747         * testsuite/ld-mips-elf/relax-jalr-n64.d: Likewise.
2748         * testsuite/ld-mips-elf/relax-jalr-n64-shared.d: Likewise.
2749
2750 2017-02-23  Maciej W. Rozycki  <macro@imgtec.com>
2751
2752         * testsuite/ld-mips-elf/jalr4.dd: New test.
2753         * testsuite/ld-mips-elf/mips-elf.exp: Run the new test.
2754
2755 2017-02-23  Alan Modra  <amodra@gmail.com>
2756
2757         PR 20744
2758         * testsuite/ld-powerpc/vle-reloc-2.s: Use r6 for last insn of
2759         each group.
2760         * testsuite/ld-powerpc/vle-reloc-2.d: Update for above change
2761         and sdarel reloc fix.
2762
2763 2017-02-22  Maciej W. Rozycki  <macro@imgtec.com>
2764
2765         PR ld/20828
2766         * testsuite/ld-elf/pr20828-d.sd: New test.
2767         * testsuite/ld-elf/pr20828-e.sd: New test.
2768         * testsuite/ld-elf/pr20828-v.od: New test.
2769         * testsuite/ld-elf/pr20828-v.ver: New test version script.
2770         * testsuite/ld-elf/pr20828-v.ld: New test linker script.
2771         * testsuite/ld-elf/pr20828.ld: Add `.gnu.version' and
2772         `.gnu.version_d'.
2773         * testsuite/ld-elf/shared.exp: Run the new tests.
2774
2775 2017-02-21  Nick Clifton  <nickc@redhat.com>
2776
2777         * testsuite/ld-ifunc/pr18808b.c (bar): Fix compile time warning
2778         about non-void function returning without a result.
2779
2780 2017-02-17  Alan Modra  <amodra@gmail.com>
2781
2782         PR 15041
2783         * scripttempl/pe.sc: Don't combine sections for ld -r.
2784         * scripttempl/pep.sc: Likewise.
2785
2786 2017-02-17  Alan Modra  <amodra@gmail.com>
2787
2788         PR 21099
2789         * emulparams/elf32m32c.sh: Define STACK_ADDR and STACK_SENTINEL
2790         rather than using OTHER_SECTIONS.
2791         * emulparams/elf32mt.sh: Likewise.
2792         * emulparams/elf32rx.sh: Likewise.
2793         * emulparams/elf32rl78.sh: Likewise.  Use OTHER_SYMBOLS to
2794         define __rl78_abs__.
2795         * emulparams/shelf.sh: Define STACK_ADDR and STACK_SENTINEL
2796         rather than using OTHER_SECTIONS.
2797         * emulparams/shelf32.sh: Likewise.  Use OTHER_SECTIONS for .cranges.
2798         * emulparams/shelf64.sh: Unset OTHER_SECTIONS.
2799         * emulparams/shelf_nbsd.sh: Unset STACK_ADDR not OTHER_SECTIONS.
2800         * emulparams/shelf_uclinux.sh: Likewise.
2801         * emulparams/shlsymbian.sh: Unset STACK_ADDR.  Use OTHER_SYMBOLS
2802         to define _stack, not OTHER_SECTIONS.
2803         * scripttempl/elf.sc: Move STACK, TINY_DATA_SECTION, and
2804         TINY_BSS_SECTION before debug sections.  Add STACK_SENTINEL.
2805         * scripttempl/arclinux.sc: Likewise.
2806         * scripttempl/elf64hppa.sc: Likewise.
2807         * scripttempl/elfxtensa.sc: Likewise.
2808         * scripttempl/nds32elf.sc: Likewise.
2809         * scripttempl/armbpabi.sc: Move STACK before debug sections.
2810         * scripttempl/elf_chaos.sc: Likewise.
2811         * scripttempl/elfarc.sc: Delete STACK.
2812         * scripttempl/epiphany_4x4.sc: Delete STACK.  Move TINY_DATA_SECTION,
2813         TINY_BSS_SECTION, and .stack before debug sections.
2814
2815 2017-02-17  Nick Clifton  <nickc@redhat.com>
2816
2817         PR ld/20825
2818         * ld.texinfo (Options): Add missing @item entry for --pop-state.
2819
2820 2017-02-17  Alan Modra  <amodra@gmail.com>
2821
2822         * testsuite/ld-elf/dwarf2.err: Accept other errors between the
2823         multiple definition errors.
2824
2825 2017-02-17  Alan Modra  <amodra@gmail.com>
2826
2827         * testsuite/ld-elf/dwarf2.err: Add missing newline at end.
2828         * testsuite/ld-elf/dwarf3.err: Likewise.  Allow match without filename.
2829
2830 2017-02-16  Andrew Burgess  <andrew.burgess@embecosm.com>
2831
2832         * testsuite/ld-elf/shared.exp: Update expected results.
2833         * testsuite/ld-elf/dwarf2.err: Likewise
2834
2835 2017-02-16  Andrew Burgess  <andrew.burgess@embecosm.com>
2836
2837         * testsuite/ld-elf/dwarf.exp (build_tests): Add new tests.
2838         * testsuite/ld-elf/dwarf2.err: New file.
2839         * testsuite/ld-elf/dwarf2a.c: New file.
2840         * testsuite/ld-elf/dwarf2b.c: New file.
2841         * testsuite/ld-elf/dwarf3.c: New file.
2842         * testsuite/ld-elf/dwarf3.err: New file.
2843
2844 2017-02-16  Andrew Burgess  <andrew.burgess@embecosm.com>
2845
2846         * testsuite/lib/ld-lib.exp (run_cc_link_tests): Add warning,
2847         error, warning_output, and error_output actions.  Remove separate
2848         warnings parameter.
2849         * testsuite/ld-elf/shared.exp (build_tests): Updated to use
2850         'warning' action.
2851         * testsuite/ld-plugin/lto.exp (lto_link_tests): Likewise.
2852
2853 2017-02-16  Alan Modra  <amodra@gmail.com>
2854
2855         * testsuite/ld-elf/check-ptr-eq.c (check_ptr_eq): Change params
2856         from void pointers to function pointers.
2857         * testsuite/ld-elf/pr18718.c: Update to suit.
2858         * testsuite/ld-elf/pr18720a.c: Update to suit.
2859
2860 2017-02-16  Alan Modra  <amodra@gmail.com>
2861
2862         PR 21000
2863         * testsuite/ld-elf/loadaddr1.d: Adjust for hppa file offsets.
2864         * testsuite/ld-elf/loadaddr2.d: Likewise.
2865         * testsuite/ld-elf/loadaddr3a.d: Likewise.
2866         * testsuite/ld-scripts/rgn-at5.d: Likewise.
2867
2868 2017-02-16  Alan Modra  <amodra@gmail.com>
2869
2870         * testsuite/ld-powerpc/vxworks1-lib.s: Correct addi to addic.
2871         * testsuite/ld-powerpc/vxworks1-lib.dd: Adjust to suit.
2872
2873 2017-02-15  H.J. Lu  <hongjiu.lu@intel.com>
2874
2875         PR ld/21168
2876         * testsuite/ld-i386/i386.exp: Run pr21168.
2877         * testsuite/ld-i386/pr21168a.c: New file.
2878         * testsuite/ld-i386/pr21168b.S: Likewise.
2879
2880 2017-02-15  H.J. Lu  <hongjiu.lu@intel.com>
2881
2882         PR ld/20244
2883         * testsuite/ld-i386/i386.exp: Run pr20244-4a, pr20244-4b and
2884         pr20244-4c.
2885         * testsuite/ld-i386/pr20244-4.s: New file.
2886         * testsuite/ld-i386/pr20244-4a.d: Likewise.
2887         * testsuite/ld-i386/pr20244-4b.d: Likewise.
2888         * testsuite/ld-i386/pr20244-4c.d: Likewise.
2889
2890 2017-02-15  Maciej W. Rozycki  <macro@imgtec.com>
2891
2892         * ldmisc.c (vfinfo): Don't print the function name again either
2893         if no source file name has been found both now and previously.
2894         * testsuite/ld-cris/tls-err-20x.d: Adjust accordingly.
2895         * testsuite/ld-mips-elf/mode-change-error-1.d: Likewise.
2896         * testsuite/ld-mips-elf/unaligned-branch.d: Likewise.
2897         * testsuite/ld-mips-elf/unaligned-branch-mips16.d: Likewise.
2898         * testsuite/ld-mips-elf/unaligned-branch-micromips.d: Likewise.
2899         * testsuite/ld-mips-elf/unaligned-branch-r6-1.d: Likewise.
2900         * testsuite/ld-mips-elf/unaligned-branch-2.d: Likewise.
2901         * testsuite/ld-mips-elf/unaligned-branch-r6-2.d: Likewise.
2902         * testsuite/ld-mips-elf/unaligned-branch-ignore-2.d: Likewise.
2903         * testsuite/ld-mips-elf/unaligned-branch-ignore-mips16.d:
2904         Likewise.
2905         * testsuite/ld-mips-elf/unaligned-branch-ignore-micromips.d:
2906         Likewise.
2907         * testsuite/ld-mips-elf/unaligned-branch-ignore-r6-1.d:
2908         Likewise.
2909         * testsuite/ld-mips-elf/unaligned-jalx-addend-1.d: Likewise.
2910         * testsuite/ld-mips-elf/unaligned-jalx-addend-mips16-1.d:
2911         Likewise.
2912         * testsuite/ld-mips-elf/unaligned-jalx-addend-micromips-1.d:
2913         Likewise.
2914         * testsuite/ld-mips-elf/unaligned-jalx-addend-3.d: Likewise.
2915         * testsuite/ld-mips-elf/unaligned-jump.d: Likewise.
2916         * testsuite/ld-mips-elf/unaligned-jump-mips16.d: Likewise.
2917         * testsuite/ld-mips-elf/unaligned-jump-micromips.d: Likewise.
2918         * testsuite/ld-mips-elf/unaligned-lwpc-1.d: Likewise.
2919         * testsuite/ld-mips-elf/unaligned-ldpc-1.d: Likewise.
2920         * testsuite/ld-powerpc/tocopt.out: Likewise.
2921         * testsuite/ld-powerpc/tocopt7.out: Likewise.
2922
2923 2017-02-15  Maciej W. Rozycki  <macro@imgtec.com>
2924
2925         * ldmisc.c (vfinfo) <'H'>: Remove static NULL initializers.
2926
2927 2017-02-15  Igor Kudrin  <ikudrin@accesssoftek.com>
2928
2929         * testsuite/ld-scripts/sysroot-prefix.exp
2930         (get_base_dir_for_scripts): New function.
2931         (run_sysroot_prefix_test): Use get_base_dir_for_scripts.
2932
2933 2017-02-13  Palmer Dabbelt  <palmer@dabbelt.com>
2934
2935         * emulparams/elf32lriscv-defs.sh (SDATA_START_SYMBOLS): Change
2936         _gp to __global_pointer$
2937
2938 2017-02-08  Andrew Burgess  <andrew.burgess@embecosm.com>
2939
2940         * configure.tgt (arc*-*-linux*): Change the default linker
2941         emulation based on --with-cpu selection.
2942         * NEWS: Mention new configuration option.
2943
2944 2017-02-06  Jiong Wang  <jiong.wang@arm.com>
2945
2946         * testsuite/ld-elf/compress.exp: Don't print to stdout for all
2947         "readelf -w".
2948
2949 2017-02-02  Maciej W. Rozycki  <macro@imgtec.com>
2950
2951         * testsuite/ld-cris/tls-err-20x.d: Fix a typo, s/n/\n/.
2952
2953 2017-02-02  Maciej W. Rozycki  <macro@imgtec.com>
2954
2955         * ld/testsuite/lib/ld-lib.exp (run_dump_test): Fix a typo,
2956         s/regexp/regex/.
2957
2958 2017-02-02  Jiong Wang  <jiong.wang@arm.com>
2959
2960         * testsuite/lib/ld-lib.exp (check_libdl_available): New function.
2961         * testsuite/ld-elf/shared.exp (run_tests): Split tests which require
2962         dlopen support into "dlopen_run_tests".  These tests include dl1*main
2963         and dl6*main.
2964         (dlopen_run_tests): New and only run it when check_libdl_available
2965         returns true.  XFAIL on *-*-netbsdelf*.
2966
2967 2017-02-01  Maciej W. Rozycki  <macro@imgtec.com>
2968
2969         * testsuite/ld-mips-elf/vxworks-forced-local-1.d: Correct the
2970         presentation of relocation addends.
2971         * testsuite/ld-mips-elf/vxworks1-lib.rd: Likewise.
2972         * testsuite/ld-mips-elf/vxworks1.dd: Likewise.
2973         * testsuite/ld-mips-elf/vxworks1.rd: Likewise.
2974
2975 2017-02-01  Maciej W. Rozycki  <macro@imgtec.com>
2976
2977         * testsuite/ld-mips-elf/tls-multi-got-1-1.s: Place `tlsvar_ld'
2978         in `.tdata' section.
2979         * testsuite/ld-mips-elf/tls-multi-got-1.got: Adjust accordingly.
2980         * testsuite/ld-mips-elf/tls-multi-got-1.r: Likewise.
2981
2982 2017-02-01  Jiong Wang  <jiong.wang@arm.com>
2983
2984         * testsuite/ld-unique/unique.exp (Could not link a dynamic executable):
2985         Append $board_cflags to link commands.
2986
2987 2017-02-01  Senthil Kumar Selvaraj  <senthilkumar.selvaraj@microchip.com>
2988
2989         * testsuite/ld-scripts/print-memory-usage-1.l: Relax
2990         check for digit in second decimal place.
2991
2992 2017-02-01  Maciej W. Rozycki  <macro@imgtec.com>
2993
2994         PR ld/20828
2995         * testsuite/ld-elf/shared.exp: Correct PR ld/20828 test
2996         indentation.
2997
2998 2017-01-31  Nick Clifton  <nickc@redhat.com>
2999
3000         * ldmain.c (add_archive_element): Eliminate string buffer.
3001         * ldlang.c (lang_print_asneeded): Likewise.
3002
3003 2017-01-30  Maciej W. Rozycki  <macro@imgtec.com>
3004
3005         * emultempl/mipself.em (ignore_branch_isa): New variable.
3006         (mips_create_output_section_statements): Rename
3007         `_bfd_mips_elf_insn32' called to `_bfd_mips_elf_linker_flags',
3008         add `ignore_branch_isa' argument.
3009         (PARSE_AND_LIST_PROLOGUE): Add OPTION_IGNORE_BRANCH_ISA and
3010         OPTION_NO_IGNORE_BRANCH_ISA enum values.
3011         (PARSE_AND_LIST_LONGOPTS): Add "ignore-branch-isa" and
3012         "no-ignore-branch-isa" options.
3013         (PARSE_AND_LIST_OPTIONS): Add `--ignore-branch-isa' and
3014         `--no-ignore-branch-isa'.
3015         (PARSE_AND_LIST_ARGS_CASES): Handle OPTION_IGNORE_BRANCH_ISA and
3016         OPTION_NO_IGNORE_BRANCH_ISA.
3017
3018         * ld.texinfo (Options specific to MIPS targets): Add
3019         `--ignore-branch-isa' and `--no-ignore-branch-isa' options.
3020         (ld and the MIPS family): Likewise.
3021
3022         * testsuite/ld-mips-elf/bal-jalx-pic-ignore.d: New test.
3023         * testsuite/ld-mips-elf/bal-jalx-pic-ignore-n32.d: New test.
3024         * testsuite/ld-mips-elf/bal-jalx-pic-ignore-n64.d: New test.
3025         * testsuite/ld-mips-elf/unaligned-branch-ignore-2.d: New test.
3026         * testsuite/ld-mips-elf/unaligned-branch-ignore-r6-1: New test.
3027         * testsuite/ld-mips-elf/unaligned-branch-ignore-mips16: New
3028         test.
3029         * testsuite/ld-mips-elf/unaligned-branch-ignore-micromips: New
3030         test.
3031         * testsuite/ld-mips-elf/mips-elf.exp: Run the new tests.
3032
3033 2017-01-29  Hans-Peter Nilsson  <hp@axis.com>
3034
3035         PR binutils/19935
3036         Fix long-standing buglet and fallout from now-default initfini-array.
3037         * emulparams/criself.sh (USER_LABEL_PREFIX): Define.
3038         (OTHER_END_SYMBOLS, ENTRY): Delete now-redundant defines.
3039
3040 2017-01-27  Jiong Wang  <jiong.wang@arm.com>
3041
3042         * testsuite/ld-elf/elf.exp ("pr20995-2", "Build pr20995-2.so"): XFAIL on
3043         arm*-*-eabi*.
3044
3045 2017-01-27  Dilyan Palauzov  <dilyan.palauzov@aegee.org>
3046             Nick Clifton  <nickc@redhat.com>
3047
3048         PR 20343
3049         * ld.texinfo (Options): Extend documentation of the --plugin
3050         option.  Include a description of where the plugins should be
3051         located.
3052
3053 2017-01-27  Nick Clifton  <nickc@redhat.com>
3054
3055         * po/sr.po: New Serbian translation.
3056         * configure.ac (ALL_LINGUAS): Add sr.
3057         * configure: Regenerate.
3058
3059 2017-01-25  Sebastian Huber  <sebastian.huber@embedded-brains.de>
3060
3061         * configure.tgt (arm-*-rtems*): Move to (arm*-*-eabi*).
3062         (bfin-*-rtems*): Move to (bfin*-*-elf*).
3063         (i[3-7]86-*-rtems*): Move to (i[3-7]86*-*-elf*).
3064         (m68*-*-rtems*): Move to (m68*-*-elf*).
3065         (mips*-*-rtems*): Move to (mips*-*-elf*).
3066         (or1k*-*-rtems*): Move to (or1k*-*-elf*).
3067         (powerpc*-*-rtems*): Move to (powerpc*-*-elf*).
3068         (sparc*-*-rtems*): Move to (sparc*-*-elf*).
3069         (sparc64*-*-rtems*): Move to (sparc64*-*-elf*).
3070
3071 2017-01-25  Sebastian Huber  <sebastian.huber@embedded-brains.de>
3072
3073         * configure.tgt (h8300-*-rtemscoff*): Remove.
3074         (i960-*-rtems*): Likewise.
3075         (m68*-*-rtemscoff*): Likewise.
3076         (sh-*-rtemscoff*): Likewise.
3077
3078 2017-01-24  Maciej W. Rozycki  <macro@imgtec.com>
3079
3080         * emultempl/solaris2.em (elf_solaris2_before_allocation): Do not
3081         add implicit version nodes if an anonymous version tag is being
3082         used.
3083
3084 2017-01-24  Jiong Wang  <jiong.wang@arm.com>
3085
3086         * testsuite/ld-plugin/lto.exp (lto_link_elf_tests): Move "Compile 7",
3087         "Compile 8a", "Compile 8b"...
3088         (lto_compile_elf_tests): ...to here.  Always run these tests.
3089         (lto_run_elf_tests): Move "LTO 7"...
3090         (lto_run_elf_shared_tests): ...to here.  Restrict these tests on
3091         environment where share library is supported.
3092
3093 2017-01-24  Alan Modra  <amodra@gmail.com>
3094
3095         * testsuite/ld-powerpc/tlsexe.r: Update for fewer dynamic relocs
3096         and symbols.
3097         * testsuite/ld-powerpc/tlsexe.d: Likewise.
3098         * testsuite/ld-powerpc/tlsexe.g: Likewise.
3099
3100 2017-01-23  Yury Norov  <ynorov@caviumnetworks.com>
3101
3102         * testsuite/ld-aarch64/aarch64-elf.exp: Run new tests.
3103         * testsuite/ld-aarch64/tls-desc-ie-ilp32.d: New test.
3104         * testsuite/ld-aarch64/tls-relax-all-ilp32.d: New test.
3105         * testsuite/ld-aarch64/tls-relax-gd-le-ilp32.d: New test.
3106         * testsuite/ld-aarch64/tls-relax-gdesc-le-2-ilp32.d: New test.
3107         * testsuite/ld-aarch64/tls-relax-gdesc-le-ilp32.d: New test.
3108         * testsuite/ld-aarch64/tls-relax-ie-le-2-ilp32.d: New test.
3109         * testsuite/ld-aarch64/tls-relax-ie-le-3-ilp32.d: New test.
3110         * testsuite/ld-aarch64/tls-relax-ie-le-ilp32.d: New test.
3111         * testsuite/ld-aarch64/tls-tiny-desc-ie-ilp32.d: New test.
3112         * testsuite/ld-aarch64/tls-tiny-desc-le-ilp32.d: New test.
3113         * testsuite/ld-aarch64/tls-tiny-gd-ie-ilp32.d: New test.
3114         * testsuite/ld-aarch64/tls-tiny-gd-le-ilp32.d: New test.
3115
3116 2017-01-23  Nick Clifton  <nickc@redhat.com>
3117
3118         * po/ga.po: Updated Irish translation.
3119
3120 2017-01-23  Maciej W. Rozycki  <macro@imgtec.com>
3121
3122         PR ld/20828
3123         * testsuite/ld-elf/pr20828.ld: Add `.plt'.
3124
3125 2017-01-23  Maciej W. Rozycki  <macro@imgtec.com>
3126
3127         PR ld/20828
3128         * testsuite/ld-elf/pr20828.ld: Rename `_fdata' and `_edata' to
3129         `fdata' and `edata' respectively.
3130         * testsuite/ld-elf/pr20828.ver: Adjust accordingly.
3131         * testsuite/ld-elf/pr20828-a.sd: Likewise.
3132         * testsuite/ld-elf/pr20828-b.sd: Likewise.
3133         * testsuite/ld-elf/pr20828-c.sd: Likewise.
3134
3135 2017-01-23  Maciej W. Rozycki  <macro@imgtec.com>
3136
3137         PR ld/20828
3138         * testsuite/ld-elf/pr20828-1.sd: Remove test.
3139         * testsuite/ld-elf/pr20828-a.sd: New test.
3140         * testsuite/ld-elf/pr20828-2a.sd: Rename test to...
3141         * testsuite/ld-elf/pr20828-b.sd: ... this.
3142         * testsuite/ld-elf/pr20828-2b.sd: Rename test to...
3143         * testsuite/ld-elf/pr20828-c.sd: ... this.
3144         * testsuite/ld-elf/shared.exp: Adjust accordingly.
3145
3146 2017-01-23  Jiong Wang  <jiong.wang@arm.com>
3147
3148         * testsuite/lib/ld-lib.exp (run_ld_link_exec_tests): Append
3149         board_cflags as gcc is used as linker driver.
3150         * testsuite/ld-unique/unique.exp: Likewise
3151
3152 2017-01-20  Jiong Wang  <jiong.wang@arm.com>
3153
3154         * testsuite/ld-aarch64/aarch64-elf.exp (aarch64elflinktests): New tests.
3155         * testsuite/ld-aarch64/func-in-so.s: New test source file.
3156         * testsuite/ld-aarch64/func-sym-hash-opt.s: Likewise.
3157         * testsuite/ld-aarch64/func-sym-hash-opt.d: New expected test result.
3158
3159 2017-01-20  Andrew Burgess  <andrew.burgess@embecosm.com>
3160
3161         * testsuite/ld-elf/eh-frame-hdr.d: Update expected results.
3162
3163 2017-01-18  Maciej W. Rozycki  <macro@imgtec.com>
3164
3165         PR ld/20995
3166         * testsuite/ld-elf/elf.exp: Set GAS flags correctly for the
3167         `mips*-*-*' target and `pr20995' and `pr20995-2' tests.
3168
3169 2017-01-18  Maciej W. Rozycki  <macro@imgtec.com>
3170
3171         PR ld/20828
3172         * testsuite/ld-elf/pr20828-1.sd: New test.
3173         * testsuite/ld-elf/pr20828-2a.sd: New test.
3174         * testsuite/ld-elf/pr20828-2b.sd: New test.
3175         * testsuite/ld-elf/pr20828.ld: New test linker script.
3176         * testsuite/ld-elf/pr20828.ver: New test version script.
3177         * testsuite/ld-elf/pr20828.s: New test source.
3178         * testsuite/ld-elf/shared.exp: Run the new test.
3179
3180 2017-01-18  Maciej W. Rozycki  <macro@imgtec.com>
3181
3182         PR gas/20649
3183         * testsuite/ld-mips-elf/mips-elf.exp: Add PIC comdat GOT16/LO16
3184         relocation pairing link test.
3185
3186 2017-01-17  Dimitar Dimitrov  <dimitar@dinux.eu>
3187
3188         * testsuite/ld-unique/unique.exp: Filter shared lib cases in
3189         uniqeue.exp, as not all targets have such support.
3190
3191 2017-01-16  Nick Clifton  <nickc@redhat.com>
3192
3193         * po/sv.po: Updated Swedish translation.
3194
3195 2017-01-12  H.J. Lu  <hongjiu.lu@intel.com>
3196
3197         PR ld/21038
3198         * testsuite/ld-x86-64/pr21038b.d: Updated.
3199         * testsuite/ld-x86-64/pr21038c.d: New file.
3200         * testsuite/ld-x86-64/pr21038c.s: Likewise.
3201         * testsuite/ld-x86-64/x86-64.exp: Run pr21038c.
3202
3203 2017-01-11  H.J. Lu  <hongjiu.lu@intel.com>
3204
3205         PR ld/21038
3206         * testsuite/ld-x86-64/pr21038a.d: New file.
3207         * testsuite/ld-x86-64/pr21038a.s: Likewise.
3208         * testsuite/ld-x86-64/pr21038b.d: Likewise.
3209         * testsuite/ld-x86-64/pr21038b.s: Likewise.
3210         * testsuite/ld-x86-64/x86-64.exp: Run pr21038a and pr21038b.
3211
3212 2017-01-11  Jeremy Soller  <jackpot51@gmail.com>
3213
3214         * configure.tgt: Add entries for x86-redox and x86_64-redox.
3215
3216 2017-01-10  H.J. Lu  <hongjiu.lu@intel.com>
3217
3218         * testsuite/ld-x86-64/pr20830b.d: Updated.
3219
3220 2017-01-10  H.J. Lu  <hongjiu.lu@intel.com>
3221
3222         * emulparams/elf32_x86_64.sh (TINY_READONLY_SECTION): New.
3223         * testsuite/ld-x86-64/pr20830.d: Renamed to ...
3224         * testsuite/ld-x86-64/pr20830a.d: This.  Updated.
3225         * testsuite/ld-x86-64/pr20830b.d: New file.
3226         * testsuite/ld-x86-64/x86-64.exp: Rename pr20830 to pr20830a.
3227         Run pr20830b.
3228
3229 2017-01-10  H.J. Lu  <hongjiu.lu@intel.com>
3230
3231         PR ld/20830
3232         * testsuite/ld-i386/i386.exp: Run pr20830.
3233         * testsuite/ld-x86-64/x86-64.exp: Likewise.
3234         * testsuite/ld-i386/pr20830.d: New file.
3235         * testsuite/ld-i386/pr20830.s: Likewise.
3236         * testsuite/ld-x86-64/pr20830.d: Likewise.
3237         * testsuite/ld-x86-64/pr20830.s: Likewise.
3238
3239 2017-01-10  H.J. Lu  <hongjiu.lu@intel.com>
3240
3241         * testsuite/ld-i386/i386.exp: Pass -Wl,-R,tmpdir and
3242         -Wl,--as-needed to $CC.
3243         * testsuite/ld-i386/tls.exp: Likewise.
3244
3245 2017-01-10  Nick Clifton  <nickc@redhat.com>
3246
3247         * po/sv.po: Updated Swedish translation.
3248
3249 2016-12-09  Graham Markall  <graham.markall@embecosm.com>
3250             Andrew Burgess  <andrew.burgess@embecosm.com>
3251
3252         * Makefile.am: Add earclinux_nps.c target and add to
3253         ALL_EMULATION_SOURCES.
3254         * Makefile.in: Likewise, regenerated.
3255         * configure.tgt: Add arclinux_nps as an extra emulation for
3256         arc*-*-elf* and arc*-*-linux*.
3257         * emulparams/arc-nps.sh: New file.
3258         * emulparams/arclinux_nps.sh: New file.
3259         * testsuite/ld-arc/arclinux-nps.d,
3260         * testsuite/ld-arc/arclinux-nps.s: New test.
3261
3262 2017-01-04  Dilan Palauzov  <dilyan.palauzov@aegee.org>
3263
3264         PR 20958
3265         * ldlex.l (option): Add noyywrap
3266         (yywrap): Delete.
3267         * ldlex.h (yywrap): Delete prototype.
3268
3269 2017-01-04  Alan Modra  <amodra@gmail.com>
3270
3271         * testsuite/ld-elf/audit.exp: Check for shared lib support.
3272         * testsuite/ld-elf/compress.exp: Likewise.
3273         * testsuite/ld-elf/dwarf.exp: Likewise.
3274         * testsuite/ld-elf/shared.exp: Likewise.
3275         * testsuite/ld-elf/wrap.exp: Likewise.
3276         * testsuite/ld-ifunc/ifunc.exp: Likewise.
3277         * testsuite/ld-plugin/lto.exp: Check $CXX exists.
3278
3279 2017-01-03  Alan Modra  <amodra@gmail.com>
3280
3281         * testsuite/lib/ld-lib.exp (run_ld_link_exec_tests): Do not
3282         allow test to continue after compilation errors.
3283         (run_cc_link_tests): Likewise.
3284
3285 2017-01-03  Dimitar Dimitrov  <dimitar@dinux.eu>
3286
3287         * Makefile.am (ALL_EMULATION_SOURCES): Add epruelf.c.
3288         (epruelf.c): Remove unneeded dependencies.
3289         * Makefile.in: Regenerate
3290
3291 2017-01-03  Alan Modra  <amodra@gmail.com>
3292
3293         * testsuite/ld-elf/shared.exp: Add -rpath-link and -no-as-needed
3294         to various tests.
3295         * testsuite/ld-elfweak/elfweak.exp: Likewise.
3296         * testsuite/ld-elfvers/vers.exp (vers19): Fix -rpath-link option.
3297
3298 2017-01-03  Alan Modra  <amodra@gmail.com>
3299
3300         * testsuite/ld-elf/elf.exp: Check that $CC exists before C tests.
3301         * testsuite/ld-pie/pie.exp: Likewise.
3302         * testsuite/ld-plugin/lto.exp: Likewise.
3303
3304 2017-01-02  Alan Modra  <amodra@gmail.com>
3305
3306         * Makefile.am (bootstrap): Delete rule.
3307         (ld-partial, ld1, ld1-full, ld2, ld3): Likewise.
3308         (HOSTING_CRT0, HOSTING_SCRT0): Don't define.
3309         (HOSTING_LIBS, HOSTING_SLIBS, HOSTING_EMU): Likewise.
3310         * configure.ac (HOSTING_CRT0, HOSTING_SCRT0): Don't define.
3311         (HOSTING_LIBS, HOSTING_SLIBS): Likewise.
3312         * configure.host (HOSTING_CRT0, HOSTING_LIBS): Don't define.
3313         * Makefile.in: Regenerate.
3314         * configure: Regenerate.
3315         * testsuite/config/default.exp (get_link_files): Delete.
3316         (HOSTING_CRT0, HOSTING_SCRT0, HOSTING_LIBS, HOSTING_SLIBS): Don't
3317         define.
3318         (ld_simple_link): Delete.
3319         * testsuite/lib/ld-lib.exp (default_ld_link): Delete
3320         (default_ld_simple_link): Rename to default_ld_link.
3321         (ld_simple_link_defsyms): Rename to ld_link_defsyms.
3322         (run_ld_link_tests): Use ld_link, not ld_simple_link.
3323         (run_cc_link_tests): Likewise.
3324         (run_ld_link_exec_tests): Use $CC or $CXX to link, not $ld.
3325         Don't run exe when not native, and return unsupported.
3326         * testsuite/ld-bootstrap/bootstrap.exp: Create gccld1 etc. dirs.
3327         Link ld1 etc. using $CC.
3328         * testsuite/ld-cdtest/cdtest.exp: Link cdtest using $CC.
3329         * testsuite/ld-checks/checks.exp: Use ld_link, not ld_simple_link.
3330         * testsuite/ld-cygwin/exe-export.exp: Likewise.
3331         * testsuite/ld-elf/binutils.exp: Likewise.
3332         * testsuite/ld-elf/eh-group.exp: Likewise.
3333         * testsuite/ld-elf/exclude.exp: Likewise.
3334         * testsuite/ld-elf/frame.exp: Likewise.
3335         * testsuite/ld-elf/sec-to-seg.exp: Likewise.
3336         * testsuite/ld-elf/tls_common.exp: Likewise.
3337         * testsuite/ld-elfcomm/elfcomm.exp: Likewise.
3338         * testsuite/ld-fastcall/fastcall.exp: Likewise.
3339         * testsuite/ld-gc/gc.exp: Likewise.
3340         * testsuite/ld-ifunc/binutils.exp: Likewise.
3341         * testsuite/ld-mep/mep.exp: Likewise.
3342         * testsuite/ld-mips-elf/mips-elf-flags.exp: Likewise.
3343         * testsuite/ld-mn10300/mn10300.exp: Likewise.
3344         * testsuite/ld-nios2/nios2.exp: Likewise.
3345         * testsuite/ld-pe/pe-compile.exp: Likewise.
3346         * testsuite/ld-pe/pe-run.exp: Likewise.
3347         * testsuite/ld-pe/pe-run2.exp: Likewise.
3348         * testsuite/ld-plugin/plugin.exp: Likewise.
3349         * testsuite/ld-scripts/align.exp: Likewise.
3350         * testsuite/ld-scripts/alignof.exp: Likewise.
3351         * testsuite/ld-scripts/assert.exp: Likewise.
3352         * testsuite/ld-scripts/defined.exp: Likewise.
3353         * testsuite/ld-scripts/extern.exp: Likewise.
3354         * testsuite/ld-scripts/log2.exp: Likewise.
3355         * testsuite/ld-scripts/map-address.exp: Likewise.
3356         * testsuite/ld-scripts/phdrs.exp: Likewise.
3357         * testsuite/ld-scripts/phdrs2.exp: Likewise.
3358         * testsuite/ld-scripts/script.exp: Likewise.
3359         * testsuite/ld-scripts/section-flags.exp: Likewise.
3360         * testsuite/ld-scripts/sizeof.exp: Likewise.
3361         * testsuite/ld-scripts/sysroot-prefix.exp: Likewise.
3362         * testsuite/ld-scripts/weak.exp: Likewise.
3363         * testsuite/ld-selective/selective.exp: Likewise.
3364         * testsuite/ld-sh/sh.exp: Likewise.
3365         * testsuite/ld-sh/sh64/relax.exp: Likewise.
3366         * testsuite/ld-sh/sh64/relfail.exp: Likewise.
3367         * testsuite/ld-srec/srec.exp: Likewise.
3368         * testsuite/ld-tic6x/tic6x.exp: Likewise.
3369         * testsuite/ld-undefined/weak-undef.exp: Likewise.
3370         * testsuite/ld-versados/versados.exp: Likewise.
3371         * testsuite/ld-x86-64/dwarfreloc.exp: Likewise.
3372         * testsuite/ld-xtensa/coalesce.exp: Likewise.
3373         * testsuite/ld-xtensa/diff_overflow.exp: Likewise.
3374         * testsuite/ld-xtensa/lcall.exp: Likewise.
3375         * testsuite/ld-elf/audit.exp: Run non-native too.
3376         * testsuite/ld-elf/compress.exp: Likewise.  Replace ld options with
3377         gcc -Wl, options.
3378         * testsuite/ld-elf/dwarf.exp: Run non-native too.  Use ld_link,
3379         not ld_simple_link.  Add -Wl,--no-as-needed to some tests.
3380         * testsuite/ld-elf/elf.exp: Run non-native too.  Formatting.
3381         * testsuite/ld-elf/indirect.exp: Run non-native too.  Add
3382         -Wl,--no-as-needed to most tests.
3383         * testsuite/ld-elf/shared.exp: Run non-native too.  Use braces
3384         to simplify quoting.  Set run_tests using [list] rather than
3385         brace assignment to expand $extralibs.  Add -Wl,--no-as-needed
3386         to many test.  Prefix ld options with -Wl,.
3387         (mix_pic_and_non_pic): Don't run exe if not native.
3388         * testsuite/ld-elf/wrap.exp: Run non-native too.  Add
3389         -Wl,--no-as-needed and prefix ld options with -Wl,.
3390         * testsuite/ld-elfvers/vers.exp: Run non-native too.  Use ld_link,
3391         not ld_simple_link.
3392         * testsuite/ld-elfvsb/elfvsb.exp: Likewise.
3393         (visibility_test): Don't run exe if not native.
3394         * testsuite/ld-elfweak/elfweak.exp: Run non-native too.  Use ld_link,
3395         not ld_simple_link.
3396         (build_exec): Don't run exe if not native.
3397         * testsuite/ld-ifunc/ifunc.exp: Run non-native too.  Use ld_link,
3398         not ld_simple_link.  Link using $CC.  Add -Wl,--no-as-needed
3399         to some tests and prefix ld options with -Wl,.  Expect GNU
3400         for hppa-linux even when no ifuncs.  Delete cleanup.
3401         * testsuite/ld-pie/pie.exp: Run non-native too.
3402         * testsuite/ld-plugin/lto.exp: Likewise.
3403         * testsuite/ld-shared/shared.exp: Likewise.  Use ld_link,
3404         not ld_simple_link.
3405         (shared_test): Don't run exe if not native.
3406         * testsuite/ld-size/size.exp: Run non-native too.  Add
3407         -Wl,--no-as-needed to some tests.  Prefix ld options with -Wl,.
3408         * testsuite/ld-unique/unique.exp: Run non-native too.  Use ld_link,
3409         not ld_simple_link.  Link using $CC.  Add -Wl,--no-as-needed
3410         to some tests and prefix ld options with -Wl,.  Expect GNU
3411         for hppa-linux even when no unique syms.  Delete cleanup.
3412         * testsuite/ld-x86-64/tls.exp: Add -Wl,--no-as-needed to some
3413         tests and prefix ld options with -Wl,.
3414         * testsuite/ld-x86-64/x86-64.exp: Use ld_link, not ld_simple_link.
3415         Add -Wl,--no-as-needed to some tests.  Prefix ld options with -Wl,.
3416
3417 2017-01-02  Alan Modra  <amodra@gmail.com>
3418
3419         * emulparams/elf32metag.sh (COMMONPAGESIZE): Define.
3420
3421 2017-01-02  Alan Modra  <amodra@gmail.com>
3422
3423         PR ld/21000
3424         * emulparams/hppalinux.sh (DATA_ADDR, SHLIB_DATA_ADDR): Don't define.
3425         (DATA_SEGMENT_ALIGN, DATA_SEGMENT_END, DATA_SEGMENT_RELRO_END): Define.
3426         * scripttempl/elf.sc: Don't define the above if DATA_SEGMENT_ALIGN
3427         is already defined.
3428
3429 2017-01-02  Alan Modra  <amodra@gmail.com>
3430
3431         Update year range in copyright notice of all files.
3432
3433 For older changes see ChangeLog-2016
3434 \f
3435 Copyright (C) 2017 Free Software Foundation, Inc.
3436
3437 Copying and distribution of this file, with or without modification,
3438 are permitted in any medium without royalty provided the copyright
3439 notice and this notice are preserved.
3440
3441 Local Variables:
3442 mode: change-log
3443 left-margin: 8
3444 fill-column: 74
3445 version-control: never
3446 End: