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