2012-05-07 Tristan Gingold <gingold@adacore.com>
[external/binutils.git] / ld / ChangeLog
1 2012-05-07  Tristan Gingold  <gingold@adacore.com>
2
3         * pe-dll.c (udef_table): Make it static.
4
5 2012-05-05  Alan Modra  <amodra@gmail.com>
6
7         * pe-dll.c (process_def_file_and_drectve): Use bfd_und_section_ptr.
8         (generate_reloc): Use bfd_abs_section_ptr.
9
10 2012-05-04  H.J. Lu  <hongjiu.lu@intel.com>
11
12         * configure.tgt: Support x86_64-*-linux-gnux32.
13
14 2012-05-03  Sean Keys  <skeys@ipdatasys.com>
15
16         * Makefile.am (ALL_EMULATIONS): Added new emulation for XGATE
17         and XGATE (elf).
18         * Makefile.in: Rebuild.
19         * configure.tgt: Recognize XGATE.
20         * scripttempl/elfxgate.sc: New file, mostly cloned from m68hc12.
21         * emulparams/xgateelf: New emulation, mostly cloned from m68hc12.
22         * NEWS: Mention new support.
23
24 2012-04-26  Hans-Peter Nilsson  <hp@axis.com>
25
26         Make bfd asserts cause linker errors.
27         * ldmain.c (default_bfd_assert_handler): New variable.
28         (ld_bfd_assert_handler): New function.
29         (main): Call bfd_set_assert_handler.
30
31 2012-04-24  Alan Modra  <amodra@gmail.com>
32
33         * ld/ldlang.c (size_input_section): Use sec_info_type rather than
34         usrdata->flags.just_syms.
35         * ld/ldwrite.c (build_link_order): Likewise.
36         * ld/emultempl/hppaelf.em (build_section_lists): Likewise.
37         * ld/emultempl/ppc64elf.em (build_toc_list): Likewise.
38         * ld/emultempl/armelf.em (build_section_lists): Likewise.
39         (after_allocation): Update for renamed sec_info_type value.
40         * ld/emultempl/tic6xdsbt.em: Likewise.
41
42 2012-04-12  Roland McGrath  <mcgrathr@google.com>
43
44         * configure.tgt (arm*-*-nacl*, arm*b-*-nacl*): Handle them.
45         * emulparams/armelf_nacl.sh: New file.
46         * emulparams/armelfb_nacl.sh: New file.
47         * Makefile.am (ALL_EMULATION_SOURCES): Add earmelf_nacl.c
48         and earmelfb_nacl.c here.
49         (earmelf_nacl.c, earmelfb_nacl.c): New targets.
50         * Makefile.in: Regenerated.
51
52 2012-04-11  Tristan Gingold  <gingold@adacore.com>
53
54         * scripttempl/ia64vms.sc: New file.
55         * emultempl/vms.em (_before_parse): Support for ia64.
56         (elf64-ia64-vms): New fragment for ia64.
57         * emulparams/elf64_ia64_vms.sh: New file.
58         * configure.tgt (ia64-*-*vms*): Add.
59         * Makefile.am (ALL_64_EMULATION_SOURCES): Add eelf64_ia64_vms.c
60         (eelf64_ia64_vms.c): New rule.
61         * Makefile.in: Regenerate.
62
63 2012-04-06  Roland McGrath  <mcgrathr@google.com>
64
65         * configure.in (AC_CHECK_HEADERS): Add locale.h.
66         * config.in: Regenerate.
67         * configure: Regenerate.
68
69 2012-04-05  Nick Clifton  <nickc@redhat.com>
70
71         * configure.in (AC_CHECK_FUNCS): Add setlocale.
72         (AM_LC_MESSAGES): Add.
73         * aclocal.m4: Regenerate.
74         * config.in: Regenerate.
75         * configure: Regenerate.
76
77 2012-04-03  Roland McGrath  <mcgrathr@google.com>
78
79         * configure.tgt (i[3-7]86-*-nacl*, x86_64-*-nacl*): Handle them.
80         * emulparams/elf_nacl.sh: New file.
81         * emulparams/elf_i386_nacl.sh: New file.
82         * emulparams/elf32_x86_64_nacl.sh: New file.
83         * emulparams/elf_x86_64_nacl.sh: New file.
84         * Makefile.am (ALL_EMULATION_SOURCES): Add eelf_i386_nacl.c here.
85         (ALL_64_EMULATION_SOURCES): Add eelf32_x86_64_nacl.c and
86         eelf_x86_64_nacl.c here.
87         (eelf_i386_nacl.c, eelf32_x86_64_nacl.c, eelf_x86_64_nacl.c):
88         New targets.
89         * Makefile.in: Regenerated.
90
91         * scripttempl/elf.sc: Handle SEPARATE_CODE cases.
92
93 2012-04-02  Mike Frysinger  <vapier@gentoo.org>
94
95         * ldmisc.c (vfinfo): Assign new local str to fmt.  Delete
96         putc call.  If str and fmt are different, call fwrite on
97         the difference.
98
99 2012-03-30  Nick Clifton  <nickc@redhat.com>
100
101         * po/vi.po: Updated Vietnamese translation.
102
103 2012-03-27  Roland McGrath  <mcgrathr@google.com>
104
105         * configure.in: Set want64 on a 64-bit host regardless of
106         --enable-targets=all.
107         * configure: Regenerated.
108
109 2012-03-26  Tristan Gingold  <gingold@adacore.com>
110
111         * lexsup.c (parse_args): Add a missing '\n'.
112
113 2012-03-25  Alan Modra  <amodra@gmail.com>
114
115         * ldemul.c (before_allocation_default): Revert last change.
116         ldlang.c (lang_add_section): Likewise.
117         (strip_excluded_output_sections): Don't strip output sections with
118         user input sections when emitrelocations, unless all are SEC_EXCLUDE.
119
120 2012-03-23  Alan Modra  <amodra@gmail.com>
121
122         * ldemul.c (before_allocation_default): When emitrelocations,
123         don't strip sections..
124         * ldlang.c (lang_add_section): ..and don't set up map_head, map_tail.
125
126 2012-03-14  Kai Tietz  <ktietz@redhat.com>
127             Pascal Obry  <pascal@obry.net>
128
129         * pe-dll.c (found_sym): New static variable.
130         (undef_count): Likewise.
131         (key_value): New structure.
132         (undef_sort_cmp): Compare routine for qsort/bsearch.
133         (pe_find_cdecl_alias_match): Add new argument.
134         (pe_undef_alias_cdecl_match): Removed.
135         (pe_undef_count): New helper routine.
136         (pe_create_undef_table): Likewise.
137         (pe_process_import_defs): Use pe_create_undef_table and
138         new pe_undef_alias_cdecl_match function.
139
140 2012-03-14  Alan Modra  <amodra@gmail.com>
141
142         PR ld/13839
143         * ldexp.c (fold_name): Ignore undefined symbols when assigning to
144         dot in mark phase.
145         (exp_fold_tree_1): Evaluate assignment to dot expressions even when
146         discarding result, for side effects.  Fix typo in error message.
147
148 2012-03-08  Tristan Gingold  <gingold@adacore.com>
149
150         * ldexp.c (exp_print_tree): Special case for SEGMENT_START.
151         (exp_print_token): Constify.
152
153 2012-03-08  Alan Modra  <amodra@gmail.com>
154
155         PR ld/10340
156         * ldfile.c (is_sysrooted_pathname): Remove notsame param.
157         (ldfile_add_library_path): Don't set sysrooted flag.
158         (ldfile_open_file_search): Likewise, and don't copy them.
159         (try_open): Delete exten and code handling such.  Add sysrooted
160         param and return whether path is in sysroot.
161         (ldfile_find_command_file): Delete extend param.  Add sysrooted
162         param.  Rename local var.  Update try_open calls.
163         (ldfile_open_command_file_1): Pass sysrooted to lex_push_file.
164         * ldfile.h (search_dirs_type): Remove sysrooted field.
165         * ldlang.c (new_afile): Always set sysrooted from input_flags.
166         (load_symbols): Don't set input_flags.sysrooted.
167         * ldlang.h (struct lang_input_statement_flags): Revise sysrooted
168         comment.
169         * ldlex.h (lex_push_file): Update prototype.
170         * ldlex.l (sysrooted_stack): New array.
171         (EOF): Pop input_flags.sysrooted.
172         (lex_push_file): Add sysrooted param.  Save and set
173         input_flags.sysrooted.
174
175 2012-03-06  Alan Modra  <amodra@gmail.com>
176
177         * ldlang.h (struct lang_input_statement_flags): New, extract from..
178         (lang_input_statement_type): ..here.  New field "flags".
179         (input_flags): Declare.
180         (missing_file): Delete.
181         * ldmain.h (whole_archive): Delete.
182         (add_DT_NEEDED_for_regular, add_DT_NEEDED_for_dynamic): Delete.
183         * ld.h (ld_config_type <dynamic_link>): Delete.
184         * ldmain.c (whole_archive): Delete.
185         (add_DT_NEEDED_for_regular, add_DT_NEEDED_for_dynamic): Delete.
186         * ldlang.c (missing_file, ldlang_sysrooted_script): Delete.
187         (input_flags): New variable.  Replace all uses of config.dynamic_link,
188         missing_file, ldlang_sysrooted_script, whole_archive,
189         add_DT_NEEDED_for_regular and add_DT_NEEDED_for_dynamic with fields
190         from here.
191         * ldfile.c: Likewise.
192         * ldgram.y: Likewise.
193         * ldmain.c: Likewise.
194         * ldwrite.c: Likewise.
195         * lexsup.c: Likewise.
196         * plugin.c: Likewise.
197         * emultempl/aix.em: Likewise.
198         * emultempl/armelf.em: Likewise.
199         * emultempl/elf32.em: Likewise.
200         * emultempl/hppaelf.em: Likewise.
201         * emultempl/linux.em: Likewise.
202         * emultempl/pe.em: Likewise.
203         * emultempl/pep.em: Likewise.
204         * emultempl/ppc64elf.em: Likewise.
205         * emultempl/scoreelf.em: Likewise.
206         * emultempl/spuelf.em: Likewise.
207         * emultempl/sunos.em: Likewise.
208         * emultempl/vms.em: Likewise.
209         * ldlang.c (new_afile): Use memset to init zero fields.
210         (load_symbols): Simplify save and restore of flags around command
211         file processing.
212         * ldfile.c (is_sysrooted_pathname): Tidy.
213
214 2012-03-05  Hans-Peter Nilsson  <hp@axis.com>
215
216         * configure.tgt (mips64*el-*-freebsd*, mips64*-*-freebsd*)
217         (mips*el-*-freebsd*, mips*-*-freebsd*): Correct triplets by
218         replacing trailing "-*" with "*".
219
220 2012-02-25  Walter Lee  <walt@tilera.com>
221
222         * Makefile.am (ALL_EMULATION_SOURCES): Add eelf32tilegx_be.c.
223         (ALL_64_EMULATION_SOURCES): Add eelf64tilegx_be.c.
224         (eelf32tilegx_be.c): Add rule to build this file.
225         (eelf64tilegx_be.c): Ditto.
226         * Makefile.in: Regenerate.
227         * configure.tgt (tilegx-*-*): Support big endian.
228         (tilegxbe-*-*): New.
229         * emulparams/elf32tilegx.sh (OUTPUT_FORMAT): Rename.
230         (BIG_OUTPUT_FORMAT): Define.
231         (LITTLE_OUTPUT_FORMAT): Define.
232         * emulparams/elf32tilegx_be.sh: New.
233         * emulparams/elf64tilegx.sh (OUTPUT_FORMAT): Rename.
234         (BIG_OUTPUT_FORMAT): Define.
235         (LITTLE_OUTPUT_FORMAT): Define.
236         * emulparams/elf64tilegx_be.sh: New.
237
238 2012-02-24  Kai Tietz  <ktietz@redhat.com>
239
240         PR binutils/13710
241         * deffilep.y (keyword_as_name): Disable LIBRARY
242         keyword.
243
244 2012-02-22  Alan Modra  <amodra@gmail.com>
245
246         PR ld/13683
247         * ldlang.c (lang_process): Rerun lang_do_assignments before
248         starting garbage collection.
249         * ldexp.c (fold_name): Generate a reloc for defined symbols
250         found without an associated output section during the mark phase.
251         (exp_fold_tree_1): Continue processing an expression, even if we
252         are unable to fold it, if we are in the first two evaluation
253         phases.
254         * ldexp.h (enum lang_phase_type): Add descriptions of the phases.
255
256 2012-02-19  Kai Tietz  <ktietz@redhat.com>
257
258         * deffilep.y (cmp_import_elem): Sort first by module name.
259         * pe-dll.c (process_def_file_and_drectve): Free strings
260         from removed export-element.
261         (add_bfd_to_link): Optimize loop on import-elements and lower
262         allocated memory.
263         (pe_implied_import_dll): Pass NULL instead of 0 for pointer
264         argument.
265
266 2012-02-18  Hans-Peter Nilsson  <hp@axis.com>
267
268         * ldmisc.c (vfinfo <%S>): Use same type and avoid cast for
269         temporary variable node used for NULL argument.
270
271 2012-02-18  Alan Modra  <amodra@gmail.com>
272
273         PR ld/13343
274         * ld.h (parsing_defsym): Delete.
275         * ldexp.c (exp_intop, exp_bigintop, exp_relop): Set type.filename.
276         (fold_binary, fold_name, exp_fold_tree_1, exp_get_vma, exp_get_fill,
277         exp_get_abs_int): Add tree arg for %S in error messages.  Don't
278         fudge lineno.
279         (exp_binop, exp_unop, exp_nameop, exp_assop, exp_assert): Copy
280         type.filename from sub-tree.
281         (exp_trinop): Likewise, and use "cond" rather than "lhs".
282         * ldexp.h (node_type): Add filename field to struct.
283         * ldfile.c (ldfile_input_filename): Delete.  Remove all refs.
284         * ldfile.h (ldfile_input_filename): Delete.
285         * ldgram.y (phdr_type, phdr_qualifiers, yyerror): Add NULL arg for
286         %S in error messages.
287         * ldemul.c (syslib_default, hll_default): Likewise.
288         * ldlang.c (lang_memory_region_lookup, lang_memory_region_alias,
289         lang_get_regions, lang_new_phdr): Likewise.
290         (lang_size_sections_1): Pass addr_tree for %S.
291         * ldlex.h (lex_redirect): Update prototype.
292         (ldlex_filename): Declare.
293         * ldlex.l (<EOF>): Don't set ldfile_input_filename.
294         (lex_redirect): Add fake_filename and count params.  Push
295         fake_filename to file_name_stack and init lineno from count.
296         (ldlex_filename): New function.
297         (lex_warn_invalid): Use above.
298         * ldmain.c (main): Update lex_redirect call.
299         * ldmisc.c (vfinfo <%S>): Take file name and line number from
300         etree_type arg, or use current if arg is NULL.
301         * lexsup.c (parsing_defsym): Delete.
302         (parse_args <OPTION_DEFSYM>): Update lex_redirect call.
303
304 2012-02-13  Kai Tietz  <ktietz@redhat.com>
305
306         * deffilep.y (find_export_in_list): Set is_indent for
307         first or last element, if identical.
308         (find_import_in_list): Likewise.
309
310 2012-02-11  Kai Tietz  <ktietz@redhat.com>
311
312         * deffilep.y (%union): New type id_const.
313         (opt_name2): New rule.
314         (keyword_as_name): New rule.
315         (dot_name): Replaced by opt_name2 rule.
316         (opt_name): Adjust rule.
317         (opt_equal_name): Likewise.
318
319 2012-02-11  Pascal Obry  <pascal@obry.net>
320
321         * pe-dll.c (auto_export): Use bsearch to speed up scan of exports
322         table.
323         (process_def_file_and_drectve): Maintain sorting of exports table
324         after stripping leading @ signs.
325
326 2012-02-09  Alan Modra  <amodra@gmail.com>
327
328         * ldgram.y (input_section_spec_no_keep): Don't ignore sect_flags.
329
330 2012-01-31  H.J. Lu  <hongjiu.lu@intel.com>
331
332         PR ld/13616
333         * emulparams/elf32_x86_64.sh: Remove NOP.
334         * emulparams/elf_i386.sh: Likewise.
335         * emulparams/elf_i386_be.sh: Likewise.
336         * emulparams/elf_i386_ldso.sh: Likewise.
337         * emulparams/elf_i386_vxworks.sh: Likewise.
338         * emulparams/elf_k1om.sh: Likewise.
339         * emulparams/elf_l1om.sh: Likewise.
340         * emulparams/elf_x86_64.sh: Likewise.
341
342         * ldlang.c (zero_fill): Initialized to 0.
343
344         * ldwrite.c (build_link_order): Set data size to linker odrder
345         size when they are the same.
346
347         * scripttempl/elf.sc: Don't specify fill if NOP is undefined.
348
349 2012-01-17  Alan Modra  <amodra@gmail.com>
350
351         * ldver.c (ldversion): Update copyright message year.
352
353 2012-01-15  Alan Modra  <amodra@gmail.com>
354
355         PR ld/12758
356         * ldlang.c (lang_process): Don't reopen all files, just those
357         newly added by plugin.
358
359 2012-01-11  Alan Modra  <amodra@gmail.com>
360
361         * emultempl/ppc64elf.em (PARSE_AND_LIST_PROLOGUE,
362         PARSE_AND_LIST_LONGOPTS, PARSE_AND_LIST_OPTIONS,
363         PARSE_AND_LIST_ARGS_CASES): Handle --{no-,}plt-thread-safe and
364         --{no-,}plt-align.
365         (plt_thread_safe, plt_stub_align): New vars.
366         (gld${EMULATION_NAME}_after_allocation): Pass them to
367         ppc64_elf_size_stubs.  Align stub sections according to plt_stub_align.
368         * ld.texinfo: Document new command line options, and an old
369         undocumented option.
370
371 2012-01-09  Roland McGrath  <mcgrathr@google.com>
372
373         * configure.in: Use AM_ZLIB.
374         * configure: Regenerated.
375
376 For older changes see ChangeLog-2011
377 \f
378 Local Variables:
379 mode: change-log
380 left-margin: 8
381 fill-column: 74
382 version-control: never
383 End: