PR ld/13254
[external/binutils.git] / ld / ChangeLog
1 2011-10-19  Alan Modra  <amodra@gmail.com>
2
3         PR ld/13254
4         * emultempl/elf32.em (gld${EMULATION_NAME}_handle_option): Add
5         -z text, -z notext, -z textoff options for all targets having
6         shared lib support.
7
8 2011-10-15  Alan Modra  <amodra@gmail.com>
9
10         * emultempl/ppc64elf.em (gld${EMULATION_NAME}_finish): Remove toc check.
11
12 2011-10-13  Dave Korn  <dave.korn.cygwin@gmail.com>
13
14         * pe-dll.c (generate_reloc): Don't emit a base reloc for an
15         underlying BFD reloc that will be discarded in eh_frame data.
16
17 2011-10-10  Nick Clifton  <nickc@redhat.com>
18
19         * po/bg.po: Updated Bulgarian translation.
20         * po/es.po: Updated Spanish translation.
21         * po/fi.po: Updated Finnish translation.
22         * po/fr.po: Updated French translation.
23
24 2011-10-10  Alan Modra  <amodra@gmail.com>
25
26         * ldmain.c (main): Move code twiddling various config and link_info
27         bits to..
28         * lexsup.c (parse_args): ..here.  Move plugin_load_plugins call
29         into main.
30         * plugin.c (set_tv_header): Test link_info.executable, not
31         link_info.shared.
32         (is_visible_from_outside): Likewise.  Delete redundant
33         is_ir_dummy_bfd check and "section" parameter.
34
35 2011-10-10  Alan Modra  <amodra@gmail.com>
36
37         * emultempl/ppc64elf.em (ppc_add_stub_section): Align to 32 bytes.
38
39 2011-10-09  Alan Modra  <amodra@gmail.com>
40
41         * emultempl/ppc64elf.em (ppc_create_output_section_statements): Add
42         missing colon to error message.
43         (ppc_before_allocation): Likewise.
44
45 2011-10-06  Alan Modra  <amodra@gmail.com>
46
47         PR ld/13229
48         * plugin.c (tv_header_tags): Add LDPT_GET_SYMBOLS_V2.
49         (set_tv_header): Handle it.  Adjust LDPT_GET_SYMBOLS.  Return void.
50         (get_symbols): Add def_ironly_exp param.  Return that value for
51         syms exported from shared libs.
52         (get_symbols_v1, get_symbols_v2): New wrapper functions.
53         * testplug.c: Update for above changes.
54
55 2011-09-27  Kai Tietz  <ktietz@redhat.com>
56
57         * scripttempl/pe.sc (.text): Add support for
58         .gnu.linkonce.t.* section.
59         (.debug_info): Only use .gnu.linkonce.wi.* for
60         relocating.
61         * scripttempl/pep.sc: Likewise.
62
63 2011-09-22  Tristan Gingold  <gingold@adacore.com>
64
65         * NEWS: Add marker for 2.22.
66
67 2011-09-20  Alan Modra  <amodra@gmail.com>
68
69         PR ld/13201
70         * ldlang.h (lang_input_statement_type): Add "reload" bitfield.
71         Clarify comments.
72         * ldlang.c (new_afile): Init new field.
73         (load_symbols): Don't call ldlang_add_file when reloading.
74         (open_input_bfds): Reload as-needed libs during plugin rescan.
75
76 2011-09-15  H.J. Lu  <hongjiu.lu@intel.com>
77
78         PR ld/12975
79         * ldlang.c (lang_elf_version_info): Removed.
80         (lang_register_vers_node): Replace lang_elf_version_info with
81         link_info.version_info.
82         (lang_add_vers_depend): Likewise.
83         * pe-dll.c (process_def_file_and_drectve): Likewise.
84         * emultempl/solaris2.em (elf_solaris2_before_allocation): Likewise.
85
86         * ldlang.h (lang_elf_version_info): Removed.
87
88         * plugin.c  (is_visible_from_outside): Check if symbol is hidden
89         by version script.
90
91         * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation):
92         Remove lang_elf_version_info.
93
94 2011-09-15  Dmitry Gorbachev  <d.g.gorbachev@gmail.com>
95
96         PR ld/13183
97         * ldmain.c (add_archive_element): Support thin archive member
98         for LTO.
99
100 2011-08-26  Nick Clifton  <nickc@redhat.com>
101
102         * po/es.po: Updated Spanish translation.
103
104 2011-08-26  Nick Clifton  <nickc@redhat.com>
105
106         * NEWS: Mention that --no-copy-dt-needed-entries is now the
107         default.
108
109 2011-08-22  Michael Matz  <matz@suse.de>
110
111         * ldmain.c (add_DT_NEEDED_for_dynamic): Default to FALSE.
112         * ld.texinfo (--copy-dt-needed-entries): Mention new default.
113
114 2011-08-17  Alan Modra  <amodra@gmail.com>
115
116         PR ld/12762
117         * ldlang.c (section_already_linked): Revert 2011-07-09 changes.
118         * plugin.c: Likewise.
119         (asymbol_from_plugin_symbol): Create linkonce section for syms
120         with comdat_key.
121
122 2011-08-09  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
123
124         * emultempl/armelf.em (fix_arm1176): New variable.
125         (arm_elf_create_output_section_statements): Pass
126         fix_arm1176 option to bfd backend.
127         (OPTION_FIX_ARM1176): New define.
128         (OPTION_NO_FIX_ARM1176): Likewise.
129         (PARSE_AND_LIST_LONGOPTS): Add new command line options.
130         (PARSE_AND_LIST_OPTIONS): Likewise.
131         (PARSE_AND_LIST_ARGS_CASES): Likewise.
132         * ld.texinfo: Document new command line options.
133
134 2011-08-09  Alan Modra  <amodra@gmail.com>
135
136         PR ld/13066
137         * plugin.c (add_symbols): Revert 2011-08-05.
138
139 2011-08-06  Kai Tietz  <ktietz@redhat.com>
140
141         * scripttempl/pep.sc: Add .debug_macro section.
142         * scripttempl/pe.sc: Likewise.
143
144 2011-08-05  Alan Modra  <amodra@gmail.com>
145
146         PR ld/12762
147         * plugin.c (add_symbols): Exclude comdat_key symbols from symbol
148         table if already seen.
149
150 2011-08-04  H.J. Lu  <hongjiu.lu@intel.com>
151
152         * ldmain.c (main): Replace remove_output with ld_cleanup in
153         comments.
154
155 2011-07-26  Alan Modra  <amodra@gmail.com>
156
157         * emulparams/elf32ppc.sh: Source plt_unwind.sh.
158         * emulparams/elf64ppc.sh: Likewise.
159         * emultempl/ppc32elf.em (OPTION_NO_TLS_OPT): Adjust.
160         (PARSE_AND_LIST_PROLOGUE, PARSE_AND_LIST_LONGOPTS,
161         PARSE_AND_LIST_OPTIONS, PARSE_AND_LIST_ARGS_CASES): Append to
162         existing values.
163         * emultempl/ppc64elf.em (OPTION_STUBGROUP_SIZE): Adjust.
164         (PARSE_AND_LIST_PROLOGUE, PARSE_AND_LIST_LONGOPTS,
165         PARSE_AND_LIST_OPTIONS, PARSE_AND_LIST_ARGS_CASES): Append to
166         existing values.
167
168 2011-07-22  H.J. Lu  <hongjiu.lu@intel.com>
169
170         * Makefile.am (ALL_64_EMULATIONS): Add eelf_k1om.o and
171         eelf_k1om_fbsd.o
172         (eelf_k1om.c): New.
173         (eelf_k1om_fbsd.c): Likewise.
174         * Makefile.in: Regenerated.
175
176         * configure.tgt (targ64_extra_emuls): Add elf_k1om if elf_x86_64
177         is supported.  Add elf_k1om_fbsd if elf_x86_64_fbsd is supported.
178         (targ_extra_emuls): Likewise.
179
180         * emulparams/elf_k1om.sh: New.
181         * emulparams/elf_k1om_fbsd.sh: Likewise.
182
183 2011-07-16  Roland McGrath  <roland@hack.frob.com>
184
185         * ld.h (args_type): New field print_output_format.
186         * lexsup.c (enum option_values, ld_options, parse_args):
187         Handle --print-output-format.
188         * ldmain.c (main): Implement --print-output-format.
189         * ld.texinfo (Options): Document it.
190
191         * ldlang.c (lang_get_output_target): Don't return current_target
192         when it's NULL.
193
194 2011-07-15  Alan Modra  <amodra@gmail.com>
195
196         * Makefile.am (e*.c): Sort.
197         * Makefile.in: Regenerate.
198
199 2011-07-14  Alan Modra  <amodra@gmail.com>
200
201         * emultempl/elf32.em (gld${EMULATION_NAME}_handle_option,
202         gld${EMULATION_NAME}_list_options): Don't condition -z relro
203         and -z norelro on COMMONPAGESIZE being defined.
204
205 2011-07-14  Alan Modra  <amodra@gmail.com>
206
207         * emultempl/ppc64elf.em (plt_static_chain): New var.
208         (gld${EMULATION_NAME}_after_allocation): Pass to ppc64_elf_size_stubs.
209         (PARSE_AND_LIST_PROLOGUE, PARSE_AND_LIST_LONGOPTS,
210         PARSE_AND_LIST_OPTIONS, PARSE_AND_LIST_ARGS_CASES): Handle
211         --plt-static-chain and --no-plt-static-chain.
212
213 2011-07-14  Alan Modra  <amodra@gmail.com>
214
215         * emultempl/elf32.em (gld${EMULATION_NAME}_add_options,
216         gld${EMULATION_NAME}_handle_option, gld${EMULATION_NAME}_list_options):
217         Provide --build-id, -z defs, -z muldefs, -z max-page-size,
218         -z common-page-size, -z execstack, -z noexecstack for all targets.
219         Add help for --exclude-libs.
220         (OPTION_LD_GENERATED_UNWIND_INFO,
221         OPTION_NO_LD_GENERATED_UNWIND_INFO): Move this..
222         (gld${EMULATION_NAME}_handle_option): ..and code handling
223         --ld-generated-unwind-info and --no-ld-generated-unwind-info..
224         * emulparams/plt_unwind.sh: ..to here.  New file.  Add help.
225         * emulparams/elf32_x86_64.sh: Include plt_unwind.sh.
226         * emulparams/elf_i386.sh: Likewise.
227         * emulparams/elf_i386_chaos.sh: Likewise.
228         * emulparams/elf_i386_ldso.sh: Likewise.
229         * emulparams/elf_l1om.sh: Likewise.
230         * emulparams/elf_x86_64.sh: Likewise.
231
232 2011-07-11  Catherine Moore  <clm@codesourcery.com>
233
234         * ld.h (section_flag_list): Add field to struct wildcard_spec.
235         * ld.texinfo (INPUT_SECTION_FLAGS): Document.
236         * ldgram.y (flag_info_list, flag_info): Add to union.
237         (INPUT_SECTION_FLAGS): New token.
238         (wildcard_spec): Initialize section_flag_list to NULL for
239         each alternative.
240         (sect_flag_list, sect_flags): New rules.
241         (input_section_spec_no_keep): Add alternatives to recognize
242         sect_flags.
243         * ldlang.c (walk_wild_consider_section): Initialize
244         section_flag_info field of the section struct.
245         (lang_add_section): Check input section flags.
246         (lang_add_wild): Initialize section_flag_list field of
247         the statement struct.
248         * ldlang.h (lang_input_statement_struct): Add section_flag_list field.
249         (lang_wild_statement_struct): Likewise.
250         * ldlex.l (INPUT_SECTION_FLAGS): New token.
251         * mri.c (mri_draw_tree): Initialize section_flag_list to NULL.
252         * NEWS: Announce INPUT_SECTION_FLAGS enhancement.
253
254 2011-07-09  H.J. Lu  <hongjiu.lu@intel.com>
255
256         PR ld/12942
257         * ldlang.c (section_already_linked): Pass "struct already_linked *"
258         to bfd_section_already_linked.
259         (lang_process): Set link_info.loading_lto_outputs before
260         loading LTO outputs.
261         * plugin.c: Include "libbfd.h".
262         (add_symbols): Call bfd_section_already_linked with comdat_key.
263
264 2011-06-20  H.J. Lu  <hongjiu.lu@intel.com>
265
266         * configure.tgt: Revert x32 change.
267
268 2011-06-20  Jakub Jelinek  <jakub@redhat.com>
269
270         PR ld/12570
271         * emultempl/elf32.em (OPTION_LD_GENERATED_UNWIND_INFO,
272         OPTION_NO_LD_GENERATED_UNWIND_INFO): Define.
273         (gld${EMULATION_NAME}_handle_option): Handle
274         --ld-generated-unwind-info and --no-ld-generated-unwind-info.
275         * ld.texinfo (--ld-generated-unwind-info,
276         --no-ld-generated-unwind-info): Document.
277
278 2011-06-19  H.J. Lu  <hongjiu.lu@intel.com>
279
280         * configure.tgt: Support x32.
281
282 2011-06-15  Nick Clifton  <nickc@redhat.com>
283
284         * NEWS: Mention addition of TILEPRO and TIKE-Gx support.
285
286 2011-06-13  Walter Lee  <walt@tilera.com>
287
288         * Makefile.am (ALL_EMULATION_SOURCES): Add eelf32tilegx.c and
289         eelf32tilepro.c.
290         (ALL_64_EMULATION_SOURCES): Add eelf64tilegx.c.
291         (eelf32tilegx.c): New target.
292         (eelf32tilepro.c): Likewise.
293         (eelf64tilegx.c): Likewise.
294         * Makefile.in: Regenerate.
295         * configure.tgt: Handle tilegx-*-* and tilepro-*-*.
296         * emulparams/elf32tilegx.sh: New file.
297         * emulparams/elf64tilegx.sh: New file.
298         * emulparams/elf32tilepro.sh: New file.
299
300 2011-06-13  Alan Modra  <amodra@gmail.com>
301
302         * ldlang.c (sort_def_symbol, lang_one_common): Don't handle
303         warning symbols here.
304         * emultempl/pe.em (pr_sym): Remove redundant test.
305         * emultempl/pep.em (pr_sym): Likewise.
306
307 2011-06-09  Nick Clifton  <nickc@redhat.com>
308
309         PR ld/12845
310         * emultempl/mipself.em (mips_add_stub_section): Do not add stubs
311         for sections that have been removed by garbage collection.
312
313 2011-06-08  Alan Modra  <amodra@gmail.com>
314
315         * ldlang.c (lang_one_common): Handle warning symbols.
316
317 2011-06-07  Nick Clifton  <nickc@redhat.com>
318
319         * configure.tgt: Accept any V850 architecture.
320
321 2011-06-03  Nick Clifton  <nickc@redhat.com>
322
323         * Makefile.am (ALL_EMULATION_SOURCES): Add eelf32am33lin.c
324         Add rule to build eelf32am33lin.c
325         * Makefile.in: Regenerate.
326
327 2011-06-02  Nick Clifton  <nickc@redhat.com>
328
329         * lexsup.c: Fix spelling mistake in comment.
330         * scripttempl/epocpe.sc: Likewise.
331         * scripttempl/i386beos.sc: Likewise.
332         * scripttempl/mcorepe.sc: Likewise.
333         * scripttempl/pe.sc: Likewise.
334         * scripttempl/pep.sc: Likewise.
335         * po/ld.pot: Regenerate.
336
337 2011-05-27  Nick Clifton  <nickc@redhat.com>
338
339         * scripttempl/v850.sc (_heap_start): Provide.
340
341 2011-05-23  Alan Modra  <amodra@gmail.com>
342
343         * ldmisc.c (vfinfo): Add %H.
344         * ldmain.c (reloc_overflow): Use %H rather than %C.
345         (reloc_dangerous, unattached_reloc): Likewise.
346
347 2011-05-23  Alan Modra  <amodra@gmail.com>
348
349         PR 12763
350         * ldlang.c (lang_output_section_find_by_flags): Match orphan .sdata2
351         like sections to existing .sdata2, and similarly for orphan TLS
352         sections.
353         * emultempl/elf32.em (place_orphan): Exclude .tbss from orphan_bss.
354
355 2011-05-17  Tomohiro Kashiwada  <kikairoya@gmail.com>
356
357         PR ld/12759
358         * emultempl/rxelf.em (ignore_lma): New variable.
359         (rx_elf_create_output_section_statements): Pass the setiing of
360         ignore_lma to bfd_elf32_rx_set_target_flags.
361         (OPTION_IGNORE_LMA): Define.
362         (OPTION_NO_IGNORE_LMA): Define.
363         (PARSE_AND_LIST_LONGOPTS): Add ignore lma.
364         (PARSE_AND_LIST_OPTIONS): Add ignore lma.
365         (PARSE_AND_LIST_ARGS_CASES): Add ignore lma.
366
367 2011-05-17  Alan Modra  <amodra@gmail.com>
368
369         PR ld/12760
370         * ldmain.c (notice): Add "flags" and "string" param.
371         * plugin.c (plugin_notice): Likewise.  Handle indirect, warning
372         and constructor syms.
373
374 2010-05-16  Daniel Jacobowitz  <dan@codesourcery.com>
375
376         * ldlang.c (print_assignment): Use the symbol's section if we
377         use its value.
378         * ldexp.c (exp_fold_tree_1): Skip self-assignment.  Expand
379         comment on copying symbol type.
380
381 2011-05-16  H.J. Lu  <hongjiu.lu@intel.com>
382
383         PR ld/12760
384         * plugin.c (plugin_notice): Set u.undef.abfd for symbols made
385         undefweak.
386
387 2011-05-16  Alan Modra  <amodra@gmail.com>
388
389         * ldlang.c (lang_leave_output_section_statement): Don't copy
390         previous lma_region if given address.
391
392 2011-05-13  Bernd Schmidt  <bernds@codesourcery.com>
393
394         (eelf32_tic6x_linux_be.c, eelf32_tic6x_linux_le.c,
395         eelf32_tic6x_elf_be.c, eelf32_tic6x_elf_le.c): New rules.
396         * Makefile.am (ALL_EMULATIONS): Add these files.
397         (eelf32_tic6x_be.c, eelf32_tic6x_le.c): Depend on tic6xdsbt.em.
398         * Makefile.in: Regenerated.
399         * emultempl/tic6xdsbt.em (is_tic6x_target): Allow more tic6x target
400         vectors.
401         * emulparams/elf32_tic6x_elf_be.sh: New file.
402         * emulparams/elf32_tic6x_elf_le.sh: New file.
403         * emulparams/elf32_tic6x_linux_be.sh: New file.
404         * emulparams/elf32_tic6x_linux_le.sh: New file.
405         * configure.tgt (tic6x-*-elf, tic6x-*-uclinux): New.
406         (tic6x-*-*): Replaced by these.
407
408 2011-05-13  Jan Beulich  <jbeulich@novell.com>
409
410         * configure.tgt: Add targets x86_64-*-pe and x86_64-*-pep.
411
412 2011-05-09  Paul Brook  <paul@codesourcery.com>
413
414         * emultempl/tic6xdsbt.em (merge_exidx_entries): New.
415         (compare_output_sec_vma): New function.
416         (gld${EMULATION_NAME}_after_allocation): New function.
417         (OPTION_NO_MERGE_EXIDX_ENTRIES): Define.
418         (PARSE_AND_LIST_OPTIONS): Add --no-merge-exidx-entries.
419         (PARSE_AND_LIST_ARGS_CASES): Add OPTION_NO_MERGE_EXIDX_ENTRIES.
420         (LDEMUL_AFTER_ALLOCATION): Set.
421         * ld.texinfo: Document c6x --no-merge-exidx-entries.
422
423 2011-05-07  Dave Korn  <dave.korn.cygwin@gmail.com>
424
425         PR ld/12365
426         * scripttempl/pe.sc (__rt_psrelocs_start): New symbol definition.
427         (__rt_psrelocs_end): Likewise.
428         (__rt_psrelocs_size): Likewise difference between the above.
429         (__RUNTIME_PSEUDO_RELOC_LIST_END__): Move outside .rdata section
430         immediately after end of pseudo-reloc data.
431         (___RUNTIME_PSEUDO_RELOC_LIST_END___): Likewise.
432         (__RUNTIME_PSEUDO_RELOC_LIST__): Move outside .rdata section and
433         calculate backward from list end.
434         (___RUNTIME_PSEUDO_RELOC_LIST___): Likewise.
435         * scripttempl/pep.sc: Likewise.
436
437 2011-05-06  Tristan Gingold  <gingold@adacore.com>
438
439         * scripttempl/alphavms.sc (CODE): Add *$CODE*.
440
441 2011-05-04  Tristan Gingold  <gingold@adacore.com>
442
443         * emultempl/generic.em (ld_${EMULATION_NAME}_emulation): Add
444         LDEMUL_ADD_OPTIONS and LDEMUL_HANDLE_OPTION.
445         * emultempl/vms.em (OPTION_IDENTIFICATION): New macro.
446         (gld${EMULATION_NAME}_add_options): New function.
447         (gld${EMULATION_NAME}_list_options): Ditto.
448         (gld${EMULATION_NAME}_handle_option): Ditto.
449         (LDEMUL_ADD_OPTIONS, LDEMUL_HANDLE_OPTION)
450         (LDEMUL_LIST_OPTIONS): Define.
451
452 2011-05-04  Alan Modra  <amodra@gmail.com>
453
454         PR ld/12726
455         * ldexp.h (lang_phase_type): Add lang_assigning_phase_enum.
456         * ldexp.c (exp_fold_tree_1): Correct assign to dot comment.  Don't
457         assign to dot when lang_assigning_phase_enum.
458         * ldlang.h (lang_do_assignments): Update prototype.
459         * ldlang.c (lang_do_assignments): Add phase parameter.  Update all
460         callers.
461         * pe-dll.c (pe_dll_fill_sections, pe_exe_fill_sections): Update
462         lang_do_assignments calls.
463
464 2011-04-28  Daniel C. Klauer  <daniel.c.klauer@web.de>
465
466         PR ld/12614
467         * emultempl/pe.em (_after_open): Correctly check whether symbol is
468         in undef list.
469
470 2011-04-26  Kai Tietz  <ktietz@redhat.com>
471
472         * scripttempl/pe.sc: Handle .eh_frame($|.)* sections.
473         * scripttempl/pep.sc: Likewise.
474
475 2011-04-24  Alan Modra  <amodra@gmail.com>
476
477         PR ld/12365
478         PR ld/12696
479         * ldmain.c (notice): Delete "name" param, add "h".
480         * plugin.c (plugin_notice): Likewise.  Set non_ir_ref.  Handle
481         redefinitions of IR symbols in real BFDs.
482         (plugin_multiple_definition, plugin_multiple_common): Delete.
483         (non_ironly_hash, init_non_ironly_hash): Delete.
484         (is_visible_from_outside): Traverse entry_symbol chain.
485         (get_symbols): Use non_ir_ref flag rather than hash lookup.
486
487 2011-04-21  Tristan Gingold  <gingold@adacore.com>
488
489         * scripttempl/alphavms.sc: Add dwarf2 embedding marks.
490
491 2011-04-20  Tristan Gingold  <gingold@adacore.com>
492
493         * emultempl/aix.em (_add_options): Ignore -bbigtoc switch.
494
495 2011-04-20  Alan Modra  <amodra@gmail.com>
496
497         * ld.h (ld_config_type <hash_table_size>): Make it an unsigned long.
498
499 2011-04-20  Alan Modra  <amodra@gmail.com>
500
501         PR ld/12365
502         * ldfile.c (ldfile_try_open_bfd): Move code creating and switching
503         to plugin IR BFD..
504         * ldmain.c (add_archive_element): ..and similar code here..
505         * plugin.c (plugin_maybe_claim): ..to here.  New function.
506         (plugin_call_claim_file): Make static.
507         (asymbol_from_plugin_symbol): Set ELF st_shndx for common syms.
508         (plugin_multiple_common): New function.
509         (plugin_call_all_symbols_read): Hook in plugin_multiple_common.
510         * plugin.h (plugin_call_claim_file): Don't declare.
511         (plugin_maybe_claim): Declare.
512
513 2011-04-20  Alan Modra  <amodra@gmail.com>
514
515         PR ld/12365
516         * ldmain.c (multiple_definition): Take a bfd_link_hash_entry
517         pointer arg rather than "name", "obfd", "osec", "oval".  Add code
518         removed from linker.c.  Hack around xcofflink.c oddity in
519         passing NULL nbfd.
520         (multiple_common): Similarly.
521         * plugin.c (orig_allow_multiple_defs): Delete.
522         (plugin_call_all_symbols_read): Don't twiddle allow_multiple_definition.
523         (plugin_multiple_definition): Update.
524
525 2011-04-18  Kai Tietz  <ktietz@redhat.com>
526
527         * deffilep.y (def_aligncomm): Avoid duplets.
528
529         * deffilep.y (def_pool_str): New type.
530         (pool_strs): Local static.
531         (def_pool_alloc): Local function.
532         (def_pool_strdup): Likewise.
533         (def_pool_free): Likewise.
534         (opt_name): Replace xmalloc/xstrdup by
535         def_pool_alloc/def_pool_strdup.
536         (dot_name): Likewise.
537         (anylang_id): Likewise.
538         (def_lex): Likewise.
539         (def_file_parse): Call def_pool_free on
540         exit and cleanup directives elements.
541         (def_file_add_directive): Call def_pool_free.
542
543 2011-04-18  Paul Brook  <paul@codesourcery.com>
544
545         * emulparams/elf32_tic6x_le.sh: Define OTHER_READONLY_SECTIONS
546         for unwinding tables.
547
548 2011-04-18  Alan Modra  <amodra@gmail.com>
549
550         PR ld/12365
551         PR ld/12672
552         * ldfile.c (ldfile_try_open_bfd): Don't attempt any plugin action
553         when no_more_claiming.
554         * ldmain.c (add_archive_element): Likewise.
555         (multiple_definition): Remove plugin_multiple_definition call.
556         (notice): Remove plugin_notice call.
557         * ldlang.c (lang_list_insert_after, void lang_list_remove_tail): Move.
558         Delete prototype.
559         (plugin_insert): New static var.
560         (open_input_bfds): Only rescan libs after plugin insert point.
561         (lang_gc_sections): Omit plugin claimed files.
562         (lang_process): Set plugin_insert.  Only rescan when plugin adds
563         objects.
564         * plugin.h (no_more_claiming): Declare.
565         (plugin_notice, plugin_multiple_definition): Don't declare.
566         * plugin.c: Formatting.
567         (orig_notice_all, orig_allow_multiple_defs, orig_callbacks,
568         plugin_callbacks): New static vars.
569         (no_more_claiming): Make global.
570         (plugin_cached_allow_multiple_defs): Delete.
571         (plugin_get_ir_dummy_bfd): Set SEC_EXCLUDE on dummy .text section,
572         use newer bfd_make_section variant.  Make COMMON section too.
573         Error handling.  Correct setting of gp size.
574         (asymbol_from_plugin_symbol): Properly cast last arg of concat.
575         (message): Likewise for ACONCAT.
576         (asymbol_from_plugin_symbol): Use our COMMON section.
577         (get_symbols): When report_plugin_symbols, show visibility too.
578         (init_non_ironly_hash): Move.  Don't test non_ironly_hash.
579         (plugin_load_plugins): Save state of linker callbacks, set up to
580         call plugin_notice instead.  Call init_non_ironly_hash here.
581         (plugin_call_all_symbols_read): Set plugin_multiple_definition in
582         plugin callbacks.
583         (plugin_notice): Rewrite.
584         (plugin_multiple_definition): Make static, call original callback.
585
586 2011-04-15  Alan Modra  <amodra@gmail.com>
587
588         PR ld/12672
589         * ldlang.c (enum open_bfd_mode): New.
590         (open_input_bfds): Replace "force" param with "mode".  Reload
591         archives for rescan.  Update all callers.
592         (lang_process): Make another open_input_bfds pass for plugins.
593
594 2011-04-13  Kai Tietz  <ktietz@redhat.com>
595
596         PR binutils/12658
597         * deffile.h (def_file_add_export): Add is_dup argument.
598         (def_file_add_import): Likewise.
599         * deffilep.y (are_names_equal): New helper.
600         (cmp_export_elem): New helper.
601         (find_export_in_list): Add search routine for exports.
602         (def_file_add_export): Check for duplicates.
603         (cmp_import_elem): New helper.
604         (find_import_in_list): Add search routine for imports.
605         (def_file_add_import): Check for duplicates.
606         (def_exports): Handle duplicates.
607         (def_imports): Likewise.
608         * pe-dll.c (process_def_file_and_drectve): Likewise.
609         (pe_implied_import_dll): Likewise.
610
611 2011-04-11  Chris Quenelle  <chris.quenelle@oracle.com>
612
613         * scripttempl/elf.sc (.exception_ranges): Add new section.
614
615 2011-04-08  Hector Oron  <hector.oron@gmail.com>
616
617         PR ld/12643
618         * configure.tgt: Add support for arm-*-gnueabihf targets.
619
620 2011-04-07  Eric B. Weddington  <eric.weddington@atmel.com>
621
622         * Makefile.in: Regenerate. Remove stray eavrtiny10 rules.
623
624 2011-04-07  Joseph Myers  <joseph@codesourcery.com>
625
626         * configure.tgt: Remove stray ;;.
627
628 2011-04-06  Joseph Myers  <joseph@codesourcery.com>
629
630         * configure.tgt (thumb-*-linux-* | thumb-*-uclinux*,
631         strongarm-*-coff, strongarm-*-elf, strongarm-*-kaos*,
632         thumb-*-coff, thumb-*-elf, thumb-epoc-pe, thumb-*-pe,
633         xscale-*-coff, xscale-*-elf): Remove targets.
634
635 2011-03-31  H.J. Lu  <hongjiu.lu@intel.com>
636
637         * configure.tgt: Add elf_l1om to targ_extra_libpath for
638         x86_64-*-linux-*.
639
640         * emulparams/elf_l1om.sh: Remove duplicates.
641
642 2011-03-31  Bernd Schmidt  <bernds@codesourcery.com>
643
644         * emulparams/elf32_tic6x_le.sh (BIG_OUTPUT_FORMAT, EXTRA_EM_FILE,
645         GENERATE_SHLIB_SCRIPT): New defines.
646         (TEXT_START_ADDR): Define differently depending on target.
647         (.got): Redefine to include "*(.dsbt)".
648         (SDATA_START_SYMBOLS): Remove, replace with
649         (OTHER_GOT_SYMBOLS): New.
650         (OTHER_BSS_SECTIONS): Define only for ELF targets.
651         * emultempl/tic6xdsbt.em: New file.
652         * gen-doc.texi: Set C6X.
653         * ld.texinfo: Likewise.
654         (Options specific to C6X uClinux targets): New section.
655
656 2011-03-29  Alan Modra  <amodra@gmail.com>
657
658         PR ld/12613
659         * ldlex.l (lex_warn_invalid): Don't assume char is unsigned.
660
661 2011-03-26  John Marino  <binutils@marino.st>
662
663         * configure.host: Update *-*-dragonfly* host entry.
664         * configure.tgt: Update *-*-dragonfly* target entry.
665         * ldlex.l: Prevent redefinition of YY_NO_UNPUT.
666
667 2011-03-28  Joseph Myers  <joseph@codesourcery.com>
668
669         * configure.in: Check for windows.h, not Windows.h.
670         * configure: Regenerate.
671         * plugin.c: Include windows.h, not Windows.h.
672
673 2011-03-25  Eric B. Weddington  <eric.weddington@atmel.com>
674
675         * Makefile.in: Regenerate.
676
677 2011-03-23  Joseph Myers  <joseph@codesourcery.com>
678
679         * lexsup.c (parse_args): Only set report_plugin_symbols if plugins
680         are enabled.  Mark level as possibly unused.
681
682 2011-03-22  Eric B. Weddington  <eric.weddington@atmel.com>
683
684         * Makefile.am (ALL_EMULATION_SOURCES): Add AVR XMEGA architectures.
685         (eavrxmega?.c): Likewise.
686         * configure.tgt (targ_extra_emuls): Likewise.
687         * emulparams/avrxmega1.sh: New file.
688         * emulparams/avrxmega2.sh: Likewise.
689         * emulparams/avrxmega3.sh: Likewise.
690         * emulparams/avrxmega4.sh: Likewise.
691         * emulparams/avrxmega5.sh: Likewise.
692         * emulparams/avrxmega6.sh: Likewise.
693         * emulparams/avrxmega7.sh: Likewise.
694         * emultempl/avrelf.em (avr_elf_${EMULATION_NAME}_before_allocation):
695         Add avrxmega6, avrxmega7 to list of architectures for no stubs.
696
697 2011-03-21  Eric B. Weddington  <eric.weddington@atmel.com>
698
699         * scripttempl/avr.sc: Add fuse, lock, and signature memory regions.
700
701 2011-03-14  Richard Sandiford  <richard.sandiford@linaro.org>
702
703         * emultempl/armelf.em (gld${EMULATION_NAME}_finish): Check
704         eh->target_internal.
705
706 2011-03-14  Richard Sandiford  <richard.sandiford@linaro.org>
707
708         * emultempl/armelf.em (arm_elf_before_allocation): Check dynobj
709         instead of dynamic_sections_created.
710
711 2011-03-10  Dave Korn  <dave.korn.cygwin@gmail.com>
712
713         * plugin.c (get_symbols): Use wrapped lookup for undefined symbols.
714
715 2011-03-10  Dave Korn  <dave.korn.cygwin@gmail.com>
716
717         * ldlang.c (lang_check): Don't run checks on dummy IR BFDs.
718
719 2011-03-10  Dave Korn  <dave.korn.cygwin@gmail.com>
720
721         * ldlang.h (lang_input_statement_type): Add new 'claim_archive' flag,
722         wrapping both it and 'claim' flag in #ifdef ENABLE_PLUGINS.
723         * ldmain.c (add_archive_element): Set it if the member is claimed.
724         * ldlang.c (new_afile): Initialise claim_archive and claimed members.
725         (find_replacements_insert_point): New helper function.
726         (lang_process): After adding and opening replacement files passed
727         from plugin, splice them into correct place in statement list and
728         file chains to preserve critical link order.
729         (lang_list_insert_after): New helper function.
730         (lang_list_remove_tail): Likewise.
731
732 2011-03-10  Dave Korn  <dave.korn.cygwin@gmail.com>
733
734         * plugin.c (IRONLY_SUFFIX): Revise to nicely human-readable form.
735         (IRONLY_SUFFIX_LEN): Delete.
736         (plugin_get_ir_dummy_bfd): Don't append IRONLY_SUFFIX.
737         (is_ir_dummy_bfd): Don't look for suffix; check claimed flag of
738         enclosing lang input statement instead.
739
740 2011-03-10  Dave Korn  <dave.korn.cygwin@gmail.com>
741
742         * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Preserve
743         alignment of input sections when creating orphan output sections
744         during relocatable link.
745         * emultempl/pep.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
746
747 2011-03-04  H.J. Lu  <hongjiu.lu@intel.com>
748
749         * ld.texinfo: Document --verbose[=NUMBER].
750
751         * lexsup.c (ld_options): Update --verbose.
752         (parse_args): Set report_plugin_symbols.
753
754         * plugin.c (report_plugin_symbols): New.
755         (get_symbols): Report plugin symbols if report_plugin_symbols
756         is TRUE.
757
758         * plugin.h (report_plugin_symbols): New.
759
760 2011-03-01  H.J. Lu  <hongjiu.lu@intel.com>
761
762         PR ld/12529
763         * testplug.c: Don't include "filenames.h".
764         (onclaim_file): Don't use filename_cmp.
765
766 2011-02-28  Kai Tietz  <kai.tietz@onevision.com>
767
768         * emultempl/beos.em (sort_by_file_name): Use filename_(n)cmp.
769         * emultempl/elf32.em (gld${EMULATION_NAME}_vercheck):
770         Likewise.
771         (gld${EMULATION_NAME}_stat_needed): Likewise.
772         (gld${EMULATION_NAME}_check_needed): Likewise.
773         * emultempl/pe.em (gld_${EMULATION_NAME}_after_open): Likewise.
774         (gld_${EMULATION_NAME}_unrecognized_file): Likewise.
775         * emultempl/pep.em (gld_${EMULATION_NAME}_after_open): Likewise.
776         (gld_${EMULATION_NAME}_unrecognized_file): Likewise.
777         * ldfile.c (ldfile_open_file): Likewise.
778         * ldlang.c (wild_sort): Likewise.
779         (lookup_name): Likewise.
780         (check_excluded_libs): Likewise.
781         * ldmisc.c (vfinfo): Likewise.
782         * pe-dll.c (libnamencmp): Likewise.
783         (auto_export): Likewise.
784         (pe_dll_generate_implib): Likewise.
785         * testplug.c (onclaim_file): Likewise.
786
787 2011-02-24  H.J. Lu  <hongjiu.lu@intel.com>
788
789         PR ld/12507
790         * plugin.c (get_symbols): Don't check entry symbol here.
791         (init_non_ironly_hash): Add entry_symbol chain into
792         non_ironly_hash.
793
794 2011-02-24  H.J. Lu  <hongjiu.lu@intel.com>
795
796         PR ld/12507
797         * plugin.c (get_symbols): Don't mark entry symbol IR only.
798
799 2011-02-18  John David Anglin  <dave.anglin@nrc-cnnrc.gc.ca>
800
801         PR ld/12376
802         emulparams/hppalinux.sh (DATA_ADDR): Define.
803         (SHLIB_DATA_ADDR): Likewise.
804
805 2011-02-16  H.J. Lu  <hongjiu.lu@intel.com>
806
807         * emulparams/elf32_x86_64.sh (LIBPATH_SUFFIX): Changed to
808         x32 for x32.
809
810 2011-02-15  Kai Tietz  <kai.tietz@onevision.com>
811
812         * pe-dll.c (process_def_file_and_drectve): Don't strip
813         leading underscore from symbol by calling bfd_find_version_for_sym.
814
815 2011-02-14  Mike Frysinger  <vapier@gentoo.org>
816
817         * ldlang.c (lang_vers_match): Declare a new c_sym, assign it to
818         the bfd_demangle of sym, change users of sym to c_sym when not
819         already demangling, and free when done.  Change callers of
820         cplus_demangle to bfd_demangle.
821
822 2011-02-14  Alan Modra  <amodra@gmail.com>
823
824         * plugin.c (plugin_get_ir_dummy_bfd): Set SEC_EXCLUDE on dummy
825         .text section, use newer bfd_make_section variant.  Error handling.
826         Correct setting of gp size.
827         (asymbol_from_plugin_symbol): Properly cast last arg of concat.
828         (message): Likewise for ACONCAT.
829         (get_symbols): Formatting.
830
831 2011-02-14  Alan Modra  <amodra@gmail.com>
832
833         * ldmain.c (remove_output): Rename to..
834         (ld_cleanup): ..this. Call bfd_cache_close_all and plugin_call_cleanup.
835         (main): Adjust.
836         * plugin.c (plugin_call_cleanup): Make global.
837         (plugin_load_plugins): Don't register plugin_call_cleanup with xatexit.
838         * plugin.h (plugin_call_cleanup): Declare.
839
840 2011-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
841
842         * configure: Regenerate.
843
844 2011-02-10  Alan Modra  <amodra@gmail.com>
845
846         * scripttempl/armbpabi.sc: Revert 2010-11-02  H.J. Lu.
847         * scripttempl/avr.sc: Likewise.
848         * scripttempl/elf32cr16.sc: Likewise.
849         * scripttempl/elf32crx.sc: Likewise.
850         * scripttempl/elf32msp430.sc: Likewise.
851         * scripttempl/elf32msp430_3.sc: Likewise.
852         * scripttempl/elf32sh-symbian.sc: Likewise.
853         * scripttempl/elf64hppa.sc: Likewise.
854         * scripttempl/elf_chaos.sc: Likewise.
855         * scripttempl/elfd10v.sc: Likewise.
856         * scripttempl/elfd30v.sc: Likewise.
857         * scripttempl/elfi370.sc: Likewise.
858         * scripttempl/elfm68hc11.sc: Likewise.
859         * scripttempl/elfm68hc12.sc: Likewise.
860         * scripttempl/elfxtensa.sc: Likewise.
861         * scripttempl/ip2k.sc: Likewise.
862         * scripttempl/iq2000.sc: Likewise.
863         * scripttempl/mep.sc: Likewise.
864         * scripttempl/mmo.sc: Likewise.
865         * scripttempl/v850.sc: Likewise.
866         * scripttempl/xstormy16.sc: Likewise.
867         * scripttempl/elf.sc: Revert 2010-10-29  H.J. Lu.
868
869 2011-01-22  H.J. Lu  <hongjiu.lu@intel.com>
870
871         * Makefile.am (CXX): Removed.
872
873         * configure.in: Add AC_PROG_CXX.
874
875         * Makefile.in: Regenerated.
876         * configure: Likewise.
877
878 2011-01-22  Richard Sandiford  <rdsandiford@googlemail.com>
879
880         * plugin.c (plugin_get_ir_dummy_bfd): Copy across the bfd's
881         private data and GP size.
882
883 2011-01-21  Alan Modra  <amodra@gmail.com>
884
885         * ldexp.c (fold_binary): Set result section for arithmetic and
886         logical operations to NULL when both operands are in same section.
887         * ld.texinfo (Expression Section): Describe this.
888
889 2011-01-14  Alan Modra  <amodra@gmail.com>
890
891         * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
892         attempt to put non-alloc orphans before debug sections, just place
893         them after .comment.
894
895 2011-01-14  J. Park  <grassman@gmail.com>
896
897         PR ld/12339
898         * ldlang.c (sort_def_symbol): Handle bfd_link_hash_warning symbols.
899
900 2011-01-14  Alan Modra  <amodra@gmail.com>
901
902         * Makefile.am: Sort emulation rules.
903         (eelf32am33lin.c): Delete.
904         (ALL_EMULATION_SOURCES): Sort, add missing entries.
905         (ALL_64_EMULATION_SOURCES): Likewise.
906         * Makefile.in: Regenerate.
907
908 2011-01-13  Alan Modra  <amodra@gmail.com>
909
910         PR ld/12356
911         * ld.texinfo (Miscellaneous Commands): Describe LD_FEATURE.
912         (Expression Section): Update.
913         * ld.h (ld_config_type): Add sane_expr.
914         * ldgram.y (ifile_p1): Add LD_FEATURE.
915         * ldlex.l (LD_FEATYRE): New.
916         * ldemul.c (after_parse_default): Delete code handling ld_compatibility.
917         * ldexp.h (struct ldexp_control): Delete uses_defined.
918         * ldexp.c: Remove all uses of uses_defined.
919         (fold_name): Test config.sane_expr rather than ld_compatibility.
920         (exp_fold_tree_1): Likewise.  Adjust handling of assignments
921         during first phase.
922         * ldlang.h (ld_compatibility): Delete.
923         (lang_ld_feature): Declare.
924         * ldlang.c (ld_compatibility): Delete.
925         (open_input_bfds): Only handle assignments for --defsym.
926         (lang_ld_feature): New function.
927
928         PR ld/12356
929         * ldexp.h (exp_assop): Delete.
930         (exp_assign, exp_defsym): Declare.
931         * ldexp.c (exp_assop): Make static, handle all assignment variations.
932         (exp_assign, exp_defsym): New functions.
933         (exp_provide): Use exp_assop.
934         * ldgram.y (defsym_expr): Use exp_defsym.
935         * ldctor.c, * ldgram.y, * ldlang.c, * mri.c, * emultempl/beos.em,
936         * emultempl/pe.em, * emultempl/pep.em, * emultempl/spuelf.em,
937         * emultempl/xtensaelf.em: Update exp_assop -> exp_assign.
938
939 2011-01-12  Alan Modra  <amodra@gmail.com>
940
941         PR ld/12380
942         * ldexp.h (enum phase_enum): Comment.  Add exp_dataseg_done.
943         * ldexp.c (fold_unary <DATA_SEGMENT_END>): Rearrange code.  Test
944         for exp_dataseg_done rather than expld.phase == lang_final_phase_enum
945         to detect when we've finished sizing sections.
946         (fold_binary <DATA_SEGMENT_ALIGN>): Likewise.
947         (fold_binary <DATA_SEGMENT_RELRO_END>): Likewise.  Also test
948         that we are not inside an output section statement.
949         * ldlang.c (lang_size_sections): Set exp_dataseg_done on exit if
950         not exp_dataseg_relro_adjust or exp_dataseg_adjust.  Don't set
951         lang_final_phase_enum here.
952         (lang_process): Set lang_final_phase_enum here.
953
954 2011-01-10  Nick Clifton  <nickc@redhat.com>
955
956         * po/da.po: Updated Danish translation.
957
958 2011-01-10  H.J. Lu  <hongjiu.lu@intel.com>
959
960         * ldlang.c (startup_file): Removed.
961         (lang_startup): Updated.
962
963 2011-01-05  H.J. Lu  <hongjiu.lu@intel.com>
964
965         PR ld/12364
966         * plugin.c (get_symbols): Check if owner_sec->owner is NULL
967         before accessing its flags field.
968
969 2011-01-01  H.J. Lu  <hongjiu.lu@intel.com>
970
971         * ldver.c (ldversion): Update copyright to 2011.
972
973 For older changes see ChangeLog-2010
974 \f
975 Local Variables:
976 mode: change-log
977 left-margin: 8
978 fill-column: 74
979 version-control: never
980 End: