Fixes for a small number of compiler warnings
[external/binutils.git] / ld / ChangeLog
1 2015-04-01  Ed Schouten  <ed@nuxi.nl>
2
3         * emultempl/elf32.em (gld*_before_allocation): Zero-initialize
4         the ehdr_start_save variable.
5
6 2015-03-31  Ed Schouten  <ed@nuxi.nl>
7
8         * Makefile.am (ALL_64_EMULATION_SOURCES): Add
9         eelf_x86_64_cloudabi.c.
10         (eelf_x86_64_cloudabi.c): New.
11         * configure.tgt (targ_emul): Set to elf_x86_64_cloudabi for
12         x86_64-*-cloudabi*.
13         * Makefile.in: Regenerated.
14         * emulparams/elf_x86_64_cloudabi.sh: New file.
15
16 2015-03-31  H.J. Lu  <hongjiu.lu@intel.com>
17
18         * configure.ac (AM_ZLIB): Removed.
19         * Makefile.in: Regenerated.
20         * config.in: Likewise.
21         * configure: Likewise.
22
23 2015-03-24  Marcus Shawcroft  <marcus.shawcroft@arm.com>
24
25         * emultempl/aarch64elf.em (_aarch64_add_stub_section): Set section
26         alignment to 2.
27
28 2015-03-23  Marcus Shawcroft  <marcus.shawcroft@arm.com>
29
30         * emultempl/aarch64elf.em
31         (elf${ELFSIZE}_aarch64_add_stub_section): Adjust layout.
32
33 2015-03-18  Chen Gang  <gang.chen.5i5j@gmail.com>
34
35         * ldmain.c (main): Use %F instead of %X for einfo.
36
37 2015-03-02  Alan Modra  <amodra@gmail.com>
38
39         * ld.texinfo (Options <-z nocopyreloc>): Rewrite.
40
41 2015-02-27  Nick Clifton  <nickc@redhat.com>
42
43         PR ld/17900
44         * ldlang.c (lang_set_flags): Allow exclamation mark to reverse the
45         sense of the following memory region attribute characters.
46
47 2015-02-27  Alan Modra  <amodra@gmail.com>
48
49         * Makefile.am (ALL_EMULATION_SOURCES): Sort new h8300 entries.
50         (eh8300elf_linux.c, eh8300helf_linux.c, eh8300self_linux.c,
51         eh8300sxelf_linux.c): Do not invoke genscripts here.
52         * Makefile.in: Regenerate.
53
54 2015-02-24  Nick Clifton  <nickc@redhat.com>
55
56         * Makefile.am (ev850.c): Add dependency upon
57         $(srcdir)/emultempl/v850elf.em.
58         (ev850_rh850.c): Likewise.
59         * Makefile.in: Regenerate.
60         * emultempl/v850elf.em: New file.
61         * emulparams/v850.sh (EXTRA_EM_FILE): Define.
62         * emulparams/v850_rh850.sh (EXTRA_EM_FILE): Define.
63         * scripttempl/v850.sc: Add .note.renesas section.
64         * scripttempl/v850_rh850.sc: Likewise.
65
66 2015-02-24  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
67
68         * scripttempl/avr.sc: Add new user_signatures region.  Define and
69         use symbols for all region lengths.
70         * scripttempl/avrtiny.sc: Define and use symbols for all region
71         lengths.
72
73 2015-01-21  Yoshinori Sato <ysato@users.sourceforge.jp>
74
75         * Makefile.am: (ALL_EMULATION_SOURCES): Add new emulations.
76         * Makefile.in: Regenerate.
77         * configure.tgt: Add h8300-*-linux
78         * emulparams/h8300elf_linux.sh: Add new emulation.
79         * emulparams/h8300helf_linux.sh: Likewise.
80         * emulparams/h8300self_linux.sh: Likewise.
81         * emulparams/h8300sxelf_linux.sh: Likewise.
82
83 2015-02-23  Nick Clifton  <nickc@redhat.com>
84
85         * lexsup.c (parse_args): Produce a more reasonable error message
86         when -ixxx or -rxxx is the last option on the linker command line.
87
88 2015-02-14  H.J. Lu  <hongjiu.lu@intel.com>
89
90         PR ld/17973
91         * testplug2.c (allsymbolsread_silent): New.
92         (set_register_hook): Handle allsymbolsreadsilent.
93         (onall_symbols_read): Skip a message if allsymbolsread_silent is
94         TRUE.
95
96 2015-02-14  Alan Modra  <amodra@gmail.com>
97
98         PR ld/17973
99         * ldlang.h (struct lang_input_statement_flags): Add lto_output.
100         * ldlang.c (lang_process): Don't set loading_lto_outputs.
101         * ldfile.c (ldfile_try_open_bfd): Transfer entry flags.lto_output
102         to bfd.
103         * plugin.c (add_input_file, add_input_library): Set flags.lto_output.
104
105 2015-02-13  H.J. Lu  <hongjiu.lu@intel.com>
106
107         * NEWS: Mention support for LLVM plugin.
108
109 2015-02-13  Alan Modra  <amodra@gmail.com>
110
111         * ld.texinfo (Options <--defsym>): Correct cross reference.
112
113 2015-02-11  H.J. Lu  <hongjiu.lu@intel.com>
114
115         * lexsup.c (ld_options): Add --[no-]map-whole-files for gold
116         option compatibility.
117
118 2015-02-11  H.J. Lu  <hongjiu.lu@intel.com>
119
120         * plugin.c (message): Output "warning:" for LDPL_WARNING. Output
121         "error:" for LDPL_FATAL and LDPL_ERROR.
122         * testplug2.c (parse_option): Handle fatal, error and warning.
123
124 2015-02-11  H.J. Lu  <hongjiu.lu@intel.com>
125
126         * testplug2.c (dump_tv_tag): Removed.
127         (onall_symbols_read): Return LDPS_ERR if the file descriptor isn't
128         closed.
129         * testplug3.c (dump_tv_tag): Removed.
130         (onclaim_file): Fix typo.
131
132 2015-02-11  H.J. Lu  <hongjiu.lu@intel.com>
133
134         PR ld/17878
135         * Makefile.am (noinst_LTLIBRARIES): Add libldtestplug2.la and
136         libldtestplug3.la.
137         (libldtestplug2_la_SOURCES): New.
138         (libldtestplug2_la_CFLAGS): Likewise.
139         (libldtestplug2_la_LDFLAGS): Likewise.
140         (libldtestplug3_la_SOURCES): New.
141         (libldtestplug3_la_CFLAGS): Likewise.
142         (libldtestplug3_la_LDFLAGS): Likewise.
143         * Makefile.in: Regenerated.
144         * testplug2.c: New file.
145         * testplug3.c: Likewise.
146
147 2015-02-11  H.J. Lu  <hongjiu.lu@intel.com>
148
149         PR ld/17878
150         * plugin.c: Include ../bfd/plugin.h.
151         (plugin_get_ir_dummy_bfd): Call bfd_create with
152         link_info.output_bfd instead of srctemplate.  Copy BFD info
153         from srctemplate only if it doesn't use BFD plugin target
154         vector.
155         (plugin_load_plugins): Call register_ld_plugin_object_p with
156         (plugin_object_p)
157         (plugin_maybe_claim): Renamed to ...
158         (plugin_object_p): This.  Return dummy BFD target vector if
159         input is calimed by plugin library, otherwise return NULL.
160         Update plugin_format and plugin_dummy_bfd.
161         (plugin_maybe_claim): New.  Use plugin_object_p.
162
163 2015-02-10  H.J. Lu  <hongjiu.lu@intel.com>
164
165         * plugin.c (plugin_maybe_claim): Initialize use_mmap.
166
167 2015-02-10  H.J. Lu  <hongjiu.lu@intel.com>
168
169         * plugin.c (plugin_input_file_t): Add use_mmap.
170         (plugin_pagesize): New.
171         (get_view): Use plugin_pagesize.  Set use_mmap if mmap is used.
172         (plugin_load_plugins): Initialize plugin_pagesize.
173         (plugin_maybe_claim): Unmap the buffer if plugin didn't claim the
174         file.
175
176 2015-02-10  H.J. Lu  <hongjiu.lu@intel.com>
177
178         * plugin.c (get_view): Align offset passed to mmap.
179
180 2015-02-08  H.J. Lu  <hongjiu.lu@intel.com>
181
182         * ldfile.c (ldfile_try_open_bfd): Don't call bfd_check_format
183         if plugin isn't active or there is no thing more to claim.
184
185 2015-02-08  H.J. Lu  <hongjiu.lu@intel.com>
186
187         * plugin.c (plugin_maybe_claim): Check format against bfd_object
188         directly.
189
190 2015-02-07  H.J. Lu  <hongjiu.lu@intel.com>
191
192         * plugin.c (plugin_maybe_claim): Replace entry->the_bfd with
193         ibfd.
194
195 2015-02-07  H.J. Lu  <hongjiu.lu@intel.com>
196
197         * plugin.c: Include "libbfd.h".
198         (plugin_strdup): New.
199         (plugin_maybe_claim): Remove the argument of pointer to struct
200         ld_plugin_input_file.  Open and handle input entry.
201         * plugin.h (plugin_maybe_claim): Updated.
202         * ldfile.c (ldfile_try_open_bfd): Call plugin_maybe_claim directly
203         without passing a pointer to struct ld_plugin_input_file.
204         * ldmain.c: Don't include "libbfd.h".
205         (add_archive_element): Call plugin_maybe_claim directly without
206         passing a pointer to struct ld_plugin_input_file.
207
208 2015-02-06  H.J. Lu  <hongjiu.lu@intel.com>
209
210         * ld.texinfo: Document -z text, -z notext and -z textoff.
211         * emultempl/elf32.em (gld${EMULATION_NAME}_list_options): Add
212         -z text, -z notext and -z textoff.
213
214 2015-02-06  H.J. Lu  <hongjiu.lu@intel.com>
215
216         * configure.ac: Add AC_FUNC_MMAP.
217         * config.in: Regenerated.
218         * configure: Likewise.
219         * plugin.c: Include <sys/mman.h>.
220         (MAP_FAILED): New.  Defined if not defined.
221         (PROT_READ): Likewise.
222         (MAP_PRIVATE): Likewise.
223         (view_buffer_t): New.
224         (plugin_input_file_t): Add view_buffer.
225         (get_view): Try mmap and cache the view buffer.
226         (plugin_maybe_claim): Initialize view_buffer.
227
228 2015-02-05  H.J. Lu  <hongjiu.lu@intel.com>
229
230         * plugin.c (release_input_file): Set fd to -1 after closing it.
231         (plugin_maybe_claim): Close fd only if fd != -1.
232
233 2015-02-05  H.J. Lu  <hongjiu.lu@intel.com>
234
235         PR ld/17878
236         * plugin.c: Include <errno.h>.
237         (errno): New.  Declare if needed.
238         (plugin_input_file_t): New.
239         (get_input_file): Implemented.
240         (get_view): Likewise.
241         (release_input_file): Likewise.
242         (add_symbols): Updated.
243         (get_symbols): Likewise.
244         (plugin_maybe_claim): Allocate a plugin_input_file_t.  Close fd
245         only for a bfd_object input.
246
247 2015-02-02  Alan Modra  <amodra@gmail.com>
248
249         * emultempl/ppc64elf.em (toc_section_name): New var.
250         (ppc_after_open): Set it.
251         (ppc_before_allocation): Use it.
252         (gld${EMULATION_NAME}_after_allocation): Here too.
253
254 2015-01-29  H.J. Lu  <hongjiu.lu@intel.com>
255
256         * ldfile.c (ldfile_try_open_bfd): Replace plugin_active_plugins_p()
257         with link_info.lto_plugin_active.
258         * ldlang.c (lang_process): Likewise.
259         * ldmain.c (add_archive_element): Likewise.
260         * plugin.c (plugin_active_plugins_p): Removed.
261         * plugin.h (plugin_active_plugins_p): Likewise.
262
263 2015-01-28  H.J. Lu  <hongjiu.lu@intel.com>
264
265         * plugin.h (plugin_get_ir_dummy_bfd): Removed.  Move comments to
266         ...
267         * plugin.c (plugin_get_ir_dummy_bfd): Here.  Make it static.
268
269 2015-01-28  H.J. Lu  <hongjiu.lu@intel.com>
270
271         PR ld/17878
272         * plugin.c (tv_header_tags(): Add LDPT_GET_VIEW.
273         (get_view): New function.
274         (set_tv_header): Handle LDPT_GET_VIEW.
275         * testplug.c (tag_names): Add LDPT_GET_VIEW.
276         (tv_get_view): New.
277         (dump_tv_tag): Handle LDPT_GET_VIEW.
278         (parse_tv_tag): Likewise.
279
280 2015-01-28  Alan Modra  <amodra@gmail.com>
281
282         * emulparams/elf64ppc.sh (INITIAL_READWRITE_SECTIONS): Define.
283         * emultempl/ppc64elf.em (params): Init new field.
284         (ppc_after_open): New function.
285         (LDEMUL_AFTER_OPEN): Define.
286         * ldlang.c (lang_final): Whitespace fix.
287
288 2015-01-28  James Bowman  <james.bowman@ftdichip.com>
289
290         * Makefile.am: Add FT32 files.
291         * configure.tgt: Handle FT32 target.
292         * emulparams/elf32ft32.sh: New file.
293         * scripttempl/ft32.sc: New file.
294         * Makefile.in: Regenerate.
295
296 2015-01-28  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
297
298         PR 4643
299         * ldexp.c (fold_name): Fold LENGTH only after
300         lang_first_phase_enum.
301         * ldgram.y (memory_spec): Don't evaluate ORIGIN and LENGTH
302         rightaway.
303         * ldlang.h (struct memory_region_struct): Add origin_exp and
304         length_exp fields.
305         * ldlang.c (lang_do_memory_regions): New.
306         (lang_memory_region_lookup): Initialize origin_exp and
307         length_exp fields.
308         (lang_process): Call lang_do_memory_regions.
309
310 2015-01-20  Andrew Burgess  <andrew.burgess@embecosm.com>
311
312         * ldlang.c (print_assignment): Only evaluate the expression for a
313         PROVIDE'd assignment when the destination is being defined.
314         Display a special message for PROVIDE'd symbols that are not being
315         provided.
316
317 2015-01-20  Alan Modra  <amodra@gmail.com>
318
319         * emulparams/elf64ppc.sh (OTHER_SDATA_SECTIONS): Use in place of..
320         (OTHER_BSS_SYMBOLS): ..this.
321         (OTHER_PLT_RELOC_SECTIONS): Don't define.
322         (OTHER_GOT_RELOC_SECTIONS): Add rela.toc1 and rela.tocbss.
323         (OTHER_READWRITE_SECTIONS): Don't define.  Move .toc1 to..
324         (OTHER_RELRO_SECTIONS_2): ..here.
325         * scripttempl/elf.sc: Move SBSS too when DATA_SDATA.
326
327 2015-01-20  Alan Modra  <amodra@gmail.com>
328
329         * emulparams/elf64ppc.sh (BSS_PLT): Don't define.
330         (OTHER_READWRITE_SECTIONS): Move .branch_lt to..
331         (OTHER_RELRO_SECTIONS_2): ..here.
332         (DATA_GOT, SEPARATE_GOTPLT, DATA_SDATA, DATA_PLT,
333         PLT_BEFORE_GOT): Define.
334         * scripttempl/elf.sc: Handle DATA_SDATA and DATA_GOT/DATA_PLT/
335         PLT_BEFORE_GOT combination.
336         (DATA_GOT, SDATA_GOT): Don't define if either is already defined.
337
338 2015-01-20  Alan Modra  <amodra@gmail.com>
339
340         * emulparams/elf64ppc.sh (OTHER_READWRITE_SECTIONS): Move .opd to..
341         (OTHER_RELRO_SECTIONS_2): ..here, new define.
342         * scripttempl/elf.sc: Add OTHER_RELRO_SECTIONS_2.
343
344 2015-01-19  Alan Modra  <amodra@gmail.com>
345
346         PR ld/17615
347         * ldlang.c (lang_process): Run lang_common before lang_gc_sections.
348
349 2015-01-14  Jiong Wang  <jiong.wang@arm.com>
350
351         * ld-arm/elf32-reject.s: New testcase.
352         * ld-arm/elf32-reject.d: Likewise.
353         * ld-arm/elf32-reject-pie.s: Likewise.
354         * ld-arm/elf32-reject-pie.d: Likewise.
355         * ld-arm/arm-elf.exp: Run new testcases.
356         * ld-arm/ifunc-7.s: Delete f2/f4 test items.
357         * ld-arm/ifunc-7.rd: Likewise.
358         * ld-arm/ifunc-7.gd: Likewise.
359         * ld-arm/ifunc-7.dd: Likewise.
360         * ld-arm/ifunc-8.s: Likewise.
361         * ld-arm/ifunc-8.rd: Likewise.
362         * ld-arm/ifunc-8.gd: Likewise.
363         * ld-arm/ifunc-8.dd: Likewise.
364
365 2015-01-01  Alan Modra  <amodra@gmail.com>
366
367         * ldver.c (ldversion): Just print current year.
368
369 2015-01-01  Alan Modra  <amodra@gmail.com>
370
371         Update year range in copyright notice of all files.
372
373 For older changes see ChangeLog-2014
374 \f
375 Copyright (C) 2015 Free Software Foundation, Inc.
376
377 Copying and distribution of this file, with or without modification,
378 are permitted in any medium without royalty provided the copyright
379 notice and this notice are preserved.
380
381 Local Variables:
382 mode: change-log
383 left-margin: 8
384 fill-column: 74
385 version-control: never
386 End: