* plugin.c (plugin_get_ir_dummy_bfd): Set bfd_use_reserved_id.
[binutils.git] / ld / ChangeLog
bloba82f4d78dc1d7d64801952d9162c63462064f5a4
1 2010-10-25  Alan Modra  <amodra@gmail.com>
3         * plugin.c (plugin_get_ir_dummy_bfd): Set bfd_use_reserved_id.
4         Formatting.
6 2010-10-22  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
8         * emulparams/elf32_sparc_sol2.sh (OUTPUT_FORMAT): Set to
9         elf32-sparc-sol2.
10         * emulparams/elf64_sparc_sol2.sh (OUTPUT_FORMAT): Set to
11         elf64-sparc-sol2.
13 2010-10-22  Alan Modra  <amodra@gmail.com>
15         * ldwrite.c (build_link_order <lang_data_statement_enum>): Don't
16         output when section has no contents.
17         (build_link_order <lang_reloc_statement_enum>): Likewise.
19 2010-10-21  Joseph Myers  <joseph@codesourcery.com>
21         * emulparams/elf32_tic6x_le.sh (ATTRS_SECTIONS): Use
22         .c6xabi.attributes, not __TI_build_attributes.
24 2010-10-20  Dave Korn  <dave.korn.cygwin@gmail.com>
26         * plugin.c (get_symbols): Check symbol type correctly.
28 2010-10-15  Dave Korn  <dave.korn.cygwin@gmail.com>
30         * configure.in: If <dlfcn.h> can't be found, try for <Windows.h>
31         * configure: Regenerate.
32         * config.in: Likewise.
33         * plugin.c [!HAVE_DLFCN_H && HAVE_WINDOWS_H] (dlopen): Provide
34         trival LoadLibrary-based replacement for Windows systems.
35         [!HAVE_DLFCN_H && HAVE_WINDOWS_H] (dlsym): Likewise trivial
36         replacement based on GetProcAddress.
37         [!HAVE_DLFCN_H && HAVE_WINDOWS_H] (dlsym): Likewise FreeLibrary.
38         * sysdep.h: Don't infer presence of <dlfcn.h> from ENABLE_PLUGINS
39         anymore, use its own guard.
41 2010-10-15  Dave Korn  <dave.korn.cygwin@gmail.com>
43         * plugin.c (add_input_file): Take copy of input string.
44         (add_input_library): Likewise.
45         (set_extra_library_path): Likewise.
47 2010-10-14  Dave Korn  <dave.korn.cygwin@gmail.com>
49         Apply LD plugin patch series (part 6/6).
50         * ldlang.c (load_symbols): Handle bfd subsitution when calling the
51         add_archive_element callback.
52         * ldmain.c (add_archive_element)[ENABLE_PLUGINS]: Offer the archive
53         member to the plugins and if claimed set "subsbfd" output parameter to
54         point to the dummy IR-only BFD.
56 2010-10-14  Dave Korn  <dave.korn.cygwin@gmail.com>
58         Apply LD plugin patch series (part 5/6).
59         * plugin.c (asymbol_from_plugin_symbol): If the bfd is an ELF bfd,
60         find the elf symbol data and set the visibility in the st_other field.
62 2010-10-14  Dave Korn  <dave.korn.cygwin@gmail.com>
64         Apply LD plugin patch series (part 4/6).
65         * ldlang.c (lang_process)[ENABLE_PLUGINS]: Move invocation of
66         plugin_call_all_symbols_read to before setting of gc_sym_list, and
67         open any new input files that may have been added during it.
68         * ldmain.c (multiple_definition)[ENABLE_PLUGINS]: Call out to
69         plugin_multiple_definition and let it have first say over what to do
70         with the clashing definitions.
71         * plugin.c (no_more_claiming): New boolean variable.
72         (plugin_cached_allow_multiple_defs): Likewise.
73         (add_input_file): Implement.
74         (add_input_library): Likewise.
75         (set_extra_library_path): Likewise.
76         (plugin_call_claim_file): Don't do anything when no_more_claiming set.
77         (plugin_call_all_symbols_read): Set it.  Disable link info
78         "allow_multiple_definition" flag, but cache its value.
79         (plugin_multiple_definition): New function.
80         * plugin.h (plugin_multiple_definition): Add prototype.
81         * testplug.c (addfile_enum_t): New enumerated typedef.
82         (add_file_t): New struct typedef.
83         (addfiles_list): New variable.
84         (addfiles_tail_chain_ptr): Likewise.
85         (record_add_file): New function.
86         (parse_option): Parse "add:", "lib:" and "dir:" options and call it.
87         (onall_symbols_read): Iterate the list of new files, libs and dirs,
88         adding them.
90 2010-10-14  Dave Korn  <dave.korn.cygwin@gmail.com>
92         Apply LD plugin patch series (part 3/6).
93         * ldmain.c (notice)[ENABLE_PLUGINS]: Call plugin_notice.
94         * plugin.c (non_ironly_hash): Add new bfd hash table.
95         (plugin_load_plugins): Exit early if no plugins to load.  If plugins
96         do load successfully, set notice_all flag in link info.
97         (get_symbols): Implement.
98         (plugin_load_plugins): Exit early if no plugins to load, else after
99         loading plugins successfully enable notice_all mode.
100         (init_non_ironly_hash): Lazily init non_ironly_hash table.
101         (plugin_notice): Record symbols referenced from non-IR files in the
102         non_ironly_hash.  Suppress tracing, cref generation and nocrossrefs
103         tracking for symbols from dummy IR bfds.
104         * plugin.h: Fix formatting.
105         (plugin_notice): Add prototype.
106         * testplug.c (dumpresolutions): New global var.
107         (parse_options): Accept "dumpresolutions".
108         (onall_symbols_read): Get syms and dump resolutions if it was given.
110 2010-10-14  Dave Korn  <dave.korn.cygwin@gmail.com>
112         Apply LD plugin patch series (part 2/6).
113         * ldfile.c (ldfile_try_open_bfd)[ENABLE_PLUGINS]: Don't return early
114         during compat checks if they pass, instead offer any successfully
115         opened and accepted file to the plugin claim file hooks chain.  Create
116         a dummy bfd to accept symbols added by the plugin, if the plugin
117         claims the file.
118         * ldlang.c (lang_process)[ENABLE_PLUGINS]: Call plugin all symbols
119         read hook chain before ldemul_after_open.
120         * ldlang.h (struct lang_input_statement_struct): Add new single-bit
121         'claimed' flag.
122         * plugin.c (IRONLY_SUFFIX): New macro for dummy bfd file suffix.
123         (IRONLY_SUFFIX_LEN): Length of the above string.
124         (plugin_get_ir_dummy_bfd): New function to create the dummy bfd used
125         to store symbols for ir-only files.
126         (is_ir_dummy_bfd): New function to check if a bfd is ir-only.
127         (asymbol_from_plugin_symbol): New function converts symbol formats.
128         (add_symbols): Call it to convert plugin syms to bfd syms and add
129         them to the dummy bfd.
130         * plugin.h: Add missing include guards.
131         (plugin_get_ir_dummy_bfd): Add prototype.
132         (is_ir_dummy_bfd): Likewise.
133         * testplug.c (TV_MESSAGE): New helper macro.
134         (struct claim_file): New struct.
135         (claim_file_t): New typedef.
136         (tag_names[]): Make static and const.
137         (claimfiles_list): New variable.
138         (claimfiles_tail_chain_ptr): Likewise.
139         (last_claimfile): Likewise.
140         (record_claim_file): Record a file to claim on a singly-linked list.
141         (parse_symdefstr): Parse an ASCII representation of a symbol from a
142         plugin option into the fields of a struct ld_plugin_symbol.
143         (record_claimed_file_symbol):  Use it to parse plugin option for
144         adding a symbol.
145         (parse_option): Parse claim file and add symbol options.
146         (dump_tv_tag): Use TV_MESSAGE.
147         (onload): Likewise.
148         (onclaim_file): Make static.  Use TV_MESSAGE.  Scan list of files to
149         claim and claim this file if required, adding any symbols specified.
150         (onall_symbols_read): Make static and use TV_MESSAGE.
151         (oncleanup): Likewise.
153 2010-10-14  Dave Korn  <dave.korn.cygwin@gmail.com>
155         Apply LD plugin patch series (part 1/6).
156         * configure.in: Add AC_CHECKs for file io and dlfcn headers and
157         functions and AC_SEARCH for -ldl.
158         (enable_plugins): New shell variable set if above tests find dlopen
159         functionality.
160         (ENABLE_PLUGINS): Add related automake conditional.
161         * configure: Regenerate.
162         * config.in: Likewise.
163         * Makefile.am (PLUGIN_C): Declare plugin C source file, conditional
164         on ENABLE_PLUGINS being defined.
165         (PLUGIN_H): Likewise for header file.
166         (PLUGIN_OBJECT): Likewise for object file.
167         (PLUGIN_CFLAGS): Likewise -D flag required to compile plugin support.
168         (AM_CPPFLAGS): Use PLUGIN_CFLAGS.
169         (CFILES): Use PLUGIN_C.
170         (HFILES): Use PLUGIN_H.
171         (OFILES): Use PLUGIN_OBJECT.
172         (ld_new_SOURCES): Use PLUGIN_C.
173         (noinst_LTLIBRARIES)[ENABLE_PLUGINS]: Declare test plugin.
174         (libldtestplug_la_SOURCES)[ENABLE_PLUGINS]: Add automake definition
175         for test plugin.
176         (libldtestplug_la_CFLAGS)[ENABLE_PLUGINS]: Likewise.
177         (libldtestplug_la_LDFLAGS)[ENABLE_PLUGINS]: Likewise.
178         * Makefile.in: Regenerate.
179         * sysdep.h: Include stdarg.h, unistd.h and one of fcntl.h or
180         sys/file.h where available.  Include dlfcn.h when ENABLE_PLUGINS.
181         (O_RDONLY): Supply default definition likewise to bfd's sysdep.h
182         (O_WRONLY): Likewise.
183         (O_RDWR): Likewise.
184         (O_ACCMODE): Likewise.
185         (O_BINARY): Likewise.
186         (SEEK_SET): Likewise.
187         (SEEK_CUR): Likewise.
188         (SEEK_END): Likewise.
189         * ldmisc.c (vfinfo): Make non-static.  Add %p format char.
190         * ldmisc.h (vfinfo): Declare extern prototype.
191         * lexsup.c (enum option_values)[ENABLE_PLUGINS]: Add new entries for
192         OPTION_PLUGIN and OPTION_PLUGIN_OPT.
193         (ld_options[])[ENABLE_PLUGINS]: Add option data for the above two.
194         (parse_args)[ENABLE_PLUGINS]: Handle them, and load all plugins once
195         option parsing is complete.
196         * ldmain.c (main)[ENABLE_PLUGINS]: Call plugin cleanup hooks just
197         after lang_finish.
198         * plugin.c: New source file.
199         * plugin.h: Likewise new header.
200         * testplug.c: New source file.
202 2010-10-12  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
204         * emultempl/solaris2.em (elf_solaris2_before_allocation): Renamed
205         basever_syms to global_syms.
206         Emit global_syms into .dynamic section for all executables and
207         shared objects.
208         (elf_solaris2_after_allocation): New function.
209         (LDEMUL_AFTER_ALLOCATION): Use it.
210         * emulparams/solaris2.sh: New file.
211         * emulparams/elf32_sparc_sol2.sh: Use it.
212         * emulparams/elf64_sparc_sol2.sh: Likewise.
213         * emulparams/elf_i386_sol2.sh: Likewise.
214         * emulparams/elf_x86_64_sol2.sh: Likewise.
215         * Makefile.am (eelf32_sparc_sol2.c): Depend on
216         $(srcdir)/emulparams/solaris2.sh.
217         (eelf64_sparc_sol2.c): Likewise.
218         (eelf_x86_64_sol2.c): Likewise.
219         (eelf_i386_sol2.c): Likewise.
220         * Makefile.in: Regenerate.
222 2010-10-06  Nick Clifton  <nickc@redhat.com>
224         * ld.texinfo: Update description of computation of VMA and LMA
225         addresses for output sections.
227 2010-10-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
229         * Makefile.am (ALL_64_EMULATIONS): Fix typo in last commit.
230         * Makefile.in: Regenerate.
232         * Makefile.am (ALL_EMULATIONS): Rewrite in terms of ...
233         (ALL_EMULATION_SOURCES): ... this new variable.
234         (ALL_64_EMULATIONS): Rewrite in terms of ...
235         (ALL_64_EMULATION_SOURCES): ... this new variable.
236         (EXTRA_ld_new_SOURCES): Rewrite in terms of the _SOURCES
237         variables.
238         (eelf32microblaze.c): Fix indentation.
239         * Makefile.in: Regenerate.
241 2010-10-04  Bernd Schmidt  <bernds@codesourcery.com>
243         * emultempl/xtensaelf.em (replace_insn_sec_with_prop_sec): Use
244         _bfd_elf_single_rel_hdr.
246 2010-10-01  Alan Modra  <amodra@gmail.com>
248         PR ld/12066
249         * ldexp.c (fold_name): Treat absolute symbols as plain numbers.
250         * ld.texinfo (Expression Section): Don't say absolute symbols
251         are addresses.
253 2010-09-29  Alan Modra  <amodra@gmail.com>
255         * ldlang.c (lang_place_orphans): Zero vma when relocatable or non-load
256         section for orphans handled here.
258 2010-09-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
260         * configure: Regenerate.
262 2010-09-23  Dave Korn  <dave.korn.cygwin@gmail.com>
264         * scripttempl/armcoff.sc: Revert 2010-09-22 change.
266 2010-09-23  Alan Modra  <amodra@gmail.com>
268         * ldlang.c (lang_add_section): Don't copy SEC_RELOC from input
269         to output section on a final link.
271 2010-09-22  Kai Tietz  <kai.tietz@onevision.com>
273         * ldlang.c (lang_add_section): Allow for debugging
274         section to be marked as noload but to keep content.
275         (IGNORE_SECTION): Likewise.
276         (lang_check_section_addresses): Likewise.
277         * ldwrite.c (build_link_order): Likewise.
279         * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Add
280         idata to orphan set.
281         * emultempl/pep.em: Likewise.
282         * scripttempl/armcoff.sc: Separate idata
283         and add __IAT_start__ and __IAT_end__ labels.
284         * scripttempl/pe.sc: Likewise.
285         * scripttempl/pep.sc: Likewise.
287 2010-09-20  David S. Miller  <davem@davemloft.net>
289         * emulparams/elf32_sparc.sh: Set NOP to 0x01000000
291 2010-09-16  Alan Modra  <amodra@gmail.com>
293         * ld.texinfo (NOLOAD): Do not erroneously state that contents will
294         appear in output file.
295         * ldlang.c (lang_add_section): Clear SEC_HAS_CONTENTS on noload
296         unless SEC_COFF_SHARED_LIBRARY.
297         (map_input_to_output_sections): Don't set SEC_HAS_CONTENTS for noload
298         output sections.
299         (lang_size_sections_1): Don't test SEC_NEVER_LOAD when deciding
300         to update dot in region.  Ditto when setting SEC_ALLOC if dot
301         advanced due to assignment.
302         * ldwrite.c (build_link_order): Don't test SEC_NEVER_LOAD.
304 2010-09-15  Kai Tietz  <kai.tietz@onevision.com>
306         * scripttempl/pep.sc: Add .xdata segment and
307         put into .pdata all segments beginning with .pdata.
309 2010-09-10  Alan Modra  <amodra@gmail.com>
311         PR ld/11931
312         * ldlang.h (lang_for_each_statement_worker): Declare.
313         * ldlang.c (lang_for_each_statement_worker): Make global.  Don't
314         recurse into children of output_section_statement with constraint
315         set to -1.
316         (print_assignment): Handle NULL output_section->bfd_section.
317         (lang_size_sections_1): Ignore output section statement address
318         when constraint is -1.
319         * emultempl/xtensaelf.em (lang_for_each_statement_worker): Delete.
321 2010-09-09  Tristan Gingold  <gingold@adacore.com>
323         * NEWS: Add a entry for alpha-vms.
325 2010-09-07  Andrew Burgess  <aburgess@broadcom.com>
327         * ldwrite.c (clone_section): Call bfd_copy_private_section_data on
328         newly cloned section.
330 2010-09-02  Richard Henderson  <rth@redhat.com>
332         * configure.tgt (x86_64-*-mingw*): Add 32-bit pe emulations too.
334 2010-08-31  Nick Clifton  <nickc@redhat.com>
336         * ldlex.l (WILDCHAR): Add the caret and exclamation point
337         characters, so that they can be used inside globs.
339 2010-08-31  Nick Clifton  <nickc@redhat.com>
341         * ld.texinfo (MEMORY): Clarify the behaviour of the ! character in
342         a region's attributes.
344 2010-08-31  Alan Modra  <amodra@gmail.com>
346         * scripttempl/mmo.sc: Move assignment to "Main" inside .text
347         output section statement.
349 2010-08-25  H.J. Lu  <hongjiu.lu@intel.com>
351         PR ld/11946
352         * emultempl/elf32.em (_before_allocation): Check audit entry
353         only on ELF input.
355 2010-08-22  H.J. Lu  <hongjiu.lu@intel.com>
357         PR ld/11937
358         * emultempl/elf32.em (_after_open): Find one .eh_frame section
359         for --eh-frame-hdr.
361 2010-08-22  H.J. Lu  <hongjiu.lu@intel.com>
363         PR ld/11937
364         * emultempl/elf32.em (_after_open): Find an ELF input for
365         --build-id and --eh-frame-hdr.
367 2010-08-20  Maciej W. Rozycki  <macro@codesourcery.com>
369         * Makefile.am (eshlelf_fd.c): Correct the name of the tool
370         directory.
371         * Makefile.in: Regenerate.
373 2010-08-20  Nick Clifton  <nickc@redhat.com>
375         * emultempl/elf32.em (_after_open): Check for get_elf_backend_data
376         returning NULL.
378 2010-08-19  Alan Modra  <amodra@gmail.com>
380         * NEWS: Mention change in linker script expression evaluation.
382 2010-08-19  Alan Modra  <amodra@gmail.com>
384         * ld.texinfo (Expression Section): Detail expression evaluation.
385         (Builtin Functions <ADDR>): Correct.
386         (Builtin Functions <LOADADDR>): Don't mention LOADADDR normally
387         the same as ADDR.
388         (Builtin Functions <SEGMENT_START>): Typo fix.
389         * ldexp.c (new_number): New function.
390         (make_abs, exp_get_abs_int): Cope with NULL expld.result.section.
391         (fold_unary <'~', '!', '-'>): Don't make_abs.
392         (fold_binary): Simplify result section logic.  Return NULL section
393         for logical ops.
394         (fold_binary <SEGMENT_START>): Use new_rel_from_abs to set value to
395         a consistent result.
396         (fold_name <SIZEOF_HEADERS>): Return new_number, not new_abs.
397         (fold_name <DEFINED, SIZEOF, ALIGNOF, LENGTH, CONSTANT>): Likewise.
398         (fold_name <NAME>): No need to handle absolute symbols differently
399         from relative ones.
400         (fold_name <ORIGIN>): Don't return valid result when
401         lang_first_phase_enum.  Return new_rel_from_abs, not new_abs.
402         (exp_fold_tree_1 <etree_value>): Return new_number, not new_rel.
403         (exp_fold_tree_1): Ajust for NULL expld.result.section.  When assigning
404         a plain number to dot, assume the value is relative to expld.section.
405         Make terms not in an output section, absolute.
406         * ldlang.c (print_assignment): Fix style nit.
407         (lang_size_sections_1): Cope with NULL expld.result.section.
408         (lang_do_assignments_1): Likewise.
410 2010-08-12  Alan Modra  <amodra@gmail.com>
412         * ldexp.c (new_rel): Remove "str".  Update all call sites.
413         (exp_fold_tree_1): When assigning to dot, calculate nextdot
414         using expld.result.section rather than expld.section.
416 2010-08-06  Alan Modra  <amodra@gmail.com>
418         PR ld/11887
419         * ldlang.c (lang_add_vers_depend): Don't leave version_needed
420         uninitialised.
422 2010-07-28  Alan Modra  <amodra@gmail.com>
424         * ldexp.c (exp_print_tree): Print function-like binary nodes as
425         functions rather than in-fix operators.  Use fputs and fputc
426         where appropriate.
428 2010-07-23  Naveen.H.S  <naveen.S@kpitcummins.com>
429             Ina Pandit  <ina.pandit@kpitcummins.com>
431         * configure.tgt: Match all v850 targets.
433 2010-07-20  Mike Frysinger  <vapier@gentoo.org>
435         * ld.texinfo (VERSION): Remove "int" from example script and add ";".
436         Declare the default language as C.
438 2010-07-17  Alan Modra  <amodra@gmail.com>
440         * ldlang.c (lang_check_section_addresses): Catch overlap for
441         sections that wrap around the address space.
443 2010-06-29  Nick Clifton  <nickc@redhat.com>
445         * scripttempl/xstormy16.sc (.gcc_except_table): Include sections
446         with the .gcc_except_table. prefix.
448 2010-06-29  Alan Modra  <amodra@gmail.com>
450         * emulparams/maxqcoff.sh: Delete file.
451         * scripttempl/maxqcoff.sc: Delete file.
452         * Makefile.am: Remove references to maxq.
453         * configure.tgt: Likewise.
454         * Makefile.in: Regenerate.
455         * configure: Regenerate.
456         * po/POTFILES.in: Regenerate.
458 2010-06-27  Alan Modra  <amodra@gmail.com>
460         * pe-dll.c (fill_edata): Avoid set but unused warning.
461         (pe_walk_relocs_of_symbol): Delete set but unused variables.
462         (generate_reloc, pe_implied_import_dll): Likewise.
463         * emultempl/aix.em (open_dynamic_archive): Likewise.
464         * emultempl/xtensaelf.em (replace_insn_sec_with_prop_sec): Likewise.
465         (xtensa_layout_wild): Likewise.
466         (xtensa_colocate_output_literals_callback): Likewise.
468 2010-06-25  Alan Modra  <amodra@gmail.com>
470         * emultempl/ppc64elf.em (prelim_size_sections): New function.
471         (ppc_before_allocation): Use it.  Size sections before toc edit too.
473 2010-06-25  Alan Modra  <amodra@gmail.com>
475         * emultempl/elf32.em (find_exp_assignment): Handle etree_provided.
477 2010-06-20  Danny Smith  <dannysmith@users.sourceforge.net>
479         * emultempl/pe.em (gld_${EMULATION_NAME}_before_parse): Make
480         auto-import and merge-rdata defaults same for i[3-7]86 and
481         x86_64 mingw.
483 2010-06-15  Joseph Myers  <joseph@codesourcery.com>
485         * emulparams/elf32_tic6x_le.sh (ATTRS_SECTIONS): Define.
487 2010-06-09  Dave Korn  <dave.korn.cygwin@gmail.com>
489         PR ld/11603
490         * pe-dll.c (process_def_file_and_drectve): Reorder check for
491         forwarded export name after check for ordinary export.
493 2010-06-08  Bernd Schmidt  <bernds@codesourcery.com>
495         * emulparams/elf32_tic6x_le.sh (OTHER_BSS_SECTIONS): New.
497 2010-06-08  Nick Clifton  <nickc@redhat.com>
499         * fdl.texi: Replace with v1.3 text.
500         * ld.texinfo: Replace abbreviated 20th century year numbers with
501         full versions.
502         * ldint.texinfo: Likewise.
503         Relicense under GFDL v1.3.  Replace text of v1.1 FDL with an
504         include of the fdl.texi file.
506 2010-06-01  Tristan Gingold  <gingold@adacore.com>
508         * scripttempl/alphavms.sc: Add comments. Move $LINK$ to the
509         readonly output-section. Handle LIB$INITIALIZE and sections
510         created by gcc.
511         * emultempl/vms.em (vms_place_orphan): Add comments.
513 2010-05-28  Nick Clifton  <nickc@redhat.com>
515         * Makefile.am (eshlelf_fd.c): Fix typo in rule.
516         * Makefile.in: Regenerate.
518 2010-05-26  H.J. Lu  <hongjiu.lu@intel.com>
520         PR ld/11628
521         * ldexp.c (fold_binary): Warn if value of SEGMENT_START isn't
522         multiple of maximum page size.
524 2010-05-25  Nick Clifton  <nickc@redhat.com>
526         * Makefile.am: Fix typo.
527         * Makefile.in: Regenerate.
529 2010-05-25  Daniel Jacobowitz  <dan@codesourcery.com>
530             Joseph Myers  <joseph@codesourcery.com>
531             Andrew Stubbs  <ams@codesourcery.com>
533         * Makefile.am (ALL_EMULATIONS): Add eshelf_fd.o and eshlelf_fd.o.
534         (eshelf_fd.c, eshlelf_fd.c): New rules.
535         * Makefile.in: Regenerate.
536         * configure.tgt (sh-*-uclinux*): Add shelf_fd and shlelf_fd
537         emulations.
538         * emulparams/shelf_fd.sh: New file.
539         * emulparams/shlelf_fd.sh: New file.
540         * emulparams/shlelf_linux.sh: Update comment.
542 2010-05-25  Jay Krell  <jay.krell@cornell.edu>
544         PR ld/11621
545         * Makefile.am: Replace all occurences of .o with .@OBJEXT@
546         * Makefile.in: Regenerate.
548 2010-05-25  Kai Tietz  <kai.tietz@onevision.com>
550         * deffilep.y (opt_name): Allow leading dot.
551         (dot_name): Likewise.
552         (anylang_id): Likewise.
553         * emultempl/pep.em (gld_${EMULATION_NAME}_before_parse): Enable by
554         default auto_import.
555         (gld${EMULATION_NAME}_handle_option): Warn about v1.
556         (pep_find_data_imports): Remove superflous warnings about
557         auto-import.
558         (gld_${EMULATION_NAME}_get_script): Don't merge for auto-import
559         and active pseudo-relocation-v2 rdata into data section.
560         * emultempl/pe.em (default_merge_rdata): New shell variable.
561         (MERGE_RDATA_V2): New macro.
562         (gld_${EMULATION_NAME}_get_script): Adjust rule for auto-import
563         selected script.
565 2010-05-15  Kai Tietz  <kai.tietz@onevision.com>
567         * emultempl/pe.em (is_underscoring): New helper function.
568         (gld_${EMULATION_NAME}_before_parse): Replace code
569         for pe(p)_leading_underscore detection by is_underscoring.
570         (U): Likewise.
571         (GET_INIT_SYMBOL_NAME): Likewise.
572         (U_SIZE): Likewise.
573         (set_pe_name):
574         (set_entry_point):
575         (gld_${EMULATION_NAME}_set_symbols):
576         * emultempl/pep.em: Likewise.
577         * pe-dll.c (pe_detail_list): Set default
578         underscoring for x64 target.
579         (pe_dll_id_target): Add initialization of
580         pe(p)_leading_underscore.
582 2010-05-15  Dave Korn  <dave.korn.cygwin@gmail.com>
584         * pe-dll.c: Removed trailing whitespaces.
586 2010-05-14  Alan Modra  <amodra@gmail.com>
588         PR ld/11583
589         * ldexp.c (exp_fold_tree_1): If assignment source expression is
590         invalid, make the destination symbol undefined.
592 2010-05-11  Kai Tietz  <kai.tietz@onevision.com>
594         * emultempl/pe.em (gld_${EMULATION_NAME}_before_parse):
595         Initialize pe(p)_leading_underscore variable.
596         (set_pe_name): Likewise.
597         * emultempl/pep.em: Likewise.
598         Additional change default to non-underscore for
599         pep_leading_underscore equal to -1.
601 2010-05-07  Tristan Gingold  <gingold@adacore.com>
603         * Makefile.in: Regenerate with automake 1.11.1.
604         * aclocal.m4: Ditto.
606 2010-05-05  Nick Clifton  <nickc@redhat.com>
608         * po/es.po: Updated Spanish translation.
610 2010-04-27  Kai Tietz  <kai.tietz@onevision.com>
612         * pe-dll.c (_nm_-symbols): Use always underscored variant
613         for symbols.
614         (__imp_-symbols): Likewise.
615         (___imp_-symbols): Likewise.
616         * NEWS: Mention ABI change for x64 PE-COFF.
618 2010-04-27  H.J. Lu  <hongjiu.lu@intel.com>
620         * Makefile.am (install-exec-local): Properly install ld as
621         default cross linker.
622         * Makefile.in: Regenerated.
624 2010-04-27  H.J. Lu  <hongjiu.lu@intel.com>
625             Nick Clifton  <nickc@redhat.com>
627         * configure.in (install_as_default): Define and set to true
628         unless --enable-gold=both/gold has been specified.
629         * configure: Regenerate.
631         * Makefile.am (transform): Use ld.bfd as the default name of
632         the linker.
633         (install-exec-local): Also install the executable as a binary
634         named 'ld' if install_as_default is true.
635         * Makefile.in: Regenerate.
637 2010-04-22  Nick Clifton  <nickc@redhat.com>
639         * po/ld.pot: Updated by the Translation project.
640         * po/vi.po: Updated Vietnamese translation.
641         * po/bg.po: Updated Bulgarian translation.
643 2010-04-15  Andrew Haley  <aph@redhat.com>
645         * emultempl/armelf.em (merge_exidx_entries): New variable.
646         (OPTION_NO_MERGE_EXIDX_ENTRIES): New definition.
647         ("no-merge-exidx-entries"): New option.
648         * ld.texinfo (merge-exidx-entries): Document this option.
650 2010-04-14  Tristan Gingold  <gingold@adacore.com>
652         * emulparams/alphavms.sh: New file.
653         * emultempl/vms.em: New file.
654         * scripttempl/alphavms.sc: New file.
655         * configure.tgt (alpha*-*-*vms*): Added.
656         * Makefile.am (ALL_EMULATIONS): Add ealphavms.o
657         (ealphavms.c): New target.
658         * Makefile.in: Regenerate.
660 2010-04-09  Nick Clifton  <nickc@redhat.com>
662         * ldlang.c (wild_sort): Remove unused variable section_name.
664 2010-04-07  Alan Modra  <amodra@gmail.com>
666         * configure: Regenerate.
668 2010-04-06  H.J. Lu  <hongjiu.lu@intel.com>
670         PR ld/11434
671         * ld/testsuite/ld-x86-64/unique1.d: New.
672         * ld/testsuite/ld-x86-64/unique1.s: Likewise.
674         * ld-x86-64/x86-64.exp: Run unique1.
676 2010-04-05  Kai Tietz  <kai.tietz@onevision.com>
678         * emultempl/pep.em (U): Macro modified.
679         (U_SIZE): New helper macro.
680         (GET_INIT_SYMBOL_NAME): Likewise.
681         (enum options): Add OPTION_NO_LEADING_UNDERSCORE
682         and OPTION_LEADING_UNDERSCORE enumerator-values.
683         (gld${EMULATION_NAME}_add_options): Add --(no-)leading-underscore
684         option.
685         (definfo): Add new member is_c_symbol.
686         (D): Add to macro underscore mode parameter.
687         (init): Add definition for is_c_symbol.
688         (gld_${EMULATION_NAME}_list_options): Display new options.
689         (set_pep_name): Adjust underscoring dependent fixed
690         symbol handling.
691         (gld_${EMULATION_NAME}_set_symbols): Likewise.
692         (saw_option): Likewise.
693         (gld_${EMULATION_NAME}_unrecognized_file): Likewise.
694         (set_entry_point): Initial initial_symbol_char dependent to
695         target's default and new option flag pep_leading_underscore.
696         * emultempl/pe.em (U): Macro modified.
697         (U_SIZE): New helper macro.
698         (GET_INIT_SYMBOL_NAME): Likewise.
699         (OPTION_LEADING_UNDERSCORE): Add new option define.
700         (OPTION_NO_LEADING_UNDERSCORE): Likewise.
701         (gld${EMULATION_NAME}_add_options): Add --(no-)leading-underscore
702         option.
703         (definfo): Add new member is_c_symbol.
704         (D): Add to macro underscore mode parameter.
705         (init): Add definition for is_c_symbol.
706         (gld_${EMULATION_NAME}_list_options): Display new options.
707         (set_pep_name): Adjust underscoring dependent fixed
708         symbol handling.
709         (gld_${EMULATION_NAME}_set_symbols): Likewise.
710         (saw_option): Likewise.
711         (gld_${EMULATION_NAME}_unrecognized_file): Likewise.
712         (set_entry_point): Initial initial_symbol_char dependent to
713         target's default and new option flag pep_leading_underscore.
714         * pe-dll.c (pe_leading_underscore): New flag variable.
715         (pe_detail_list): Remove const to allow modify of
716         member underscore.
717         (pe_dll_id_target): Initialize pe_details' underscore variable
718         dependent to target's default and flag pe_leading_underscore.
719         * pe-dll.h (pe_leading_underscore): Add extern declaration of
720         option flag.
721         * pep-dll.c (pe_leading_underscore): Add alias define for
722         pep_leading_underscore.
723         * pep-dll.h (pep_leading_underscore) Add extern declaration of
724         option flag.
725         * ld.texinfo: Add documentation for --(no-)leading-underscore
726         option.
728 2010-03-26  Alan Modra  <amodra@gmail.com>
730         PR ld/11426
731         * configure.host (many linux targets <HOSTING_CRT0>): Remove edits.
732         (m68*-motorola-sysv <HOSTING_LIBS>): Use here doc, not echo.
734 2010-03-25  Joseph Myers  <joseph@codesourcery.com>
736         * Makefile.am (ALL_EMULATIONS): Add eelf32_tic6x_be.o and
737         eelf32_tic6x_le.o.
738         (eelf32_tic6x_be.c, eelf32_tic6x_le.c): New.
739         * NEWS: Add news entry for TI C6X support.
740         * configure.tgt (tic6x-*-*): New.
741         * emulparams/elf32_tic6x_be.sh, emulparams/elf32_tic6x_le.sh: New.
743 2010-03-23  Joseph Myers  <joseph@codesourcery.com>
745         * scripttempl/elf.sc (RODATA_NAME, SDATA_NAME, SBSS_NAME,
746         BSS_NAME): Define if not already defined.  Use in place of some
747         hardcoded section names.
749 2010-03-18  H.J. Lu  <hongjiu.lu@intel.com>
751         * scripttempl/elf.sc (INIT_ARRAY): Re-indent.
753 2010-03-18  Aymeric Vincent  <vincent@labri.fr>
755         PR ld/11384
756         * emultempl/sh64elf.em: Add missing EOF.
758 2010-03-18  Doug Semler  <dougsemler@gmail.com>
760         * pe-dll.c (make_one): Make text section readonly.
761         (make_one): Add *ABS* symbol @feat.00 with value 1 to tag
762         the jump stub on X86 as /SAFESEH compatible for
763         native toolchains.
765 2010-03-17  Alan Modra  <amodra@gmail.com>
767         * ldlang.c (lang_size_sections_1): Remove "s" param.  Set "s" from
768         *prev instead.  Update all callers.
770 2010-03-15  Daniel Jacobowitz  <dan@codesourcery.com>
772         * ldlang.c (lang_insert_orphan): Place loadable orphans in the same
773         region and phdrs as their placement section.
775 2010-03-15  Alan Modra  <amodra@gmail.com>
777         * emultempl/ppc64elf.em (move_input_section, sort_toc_sections): New.
778         (ppc_before_allocation): Call sort_toc_sections.
779         (no_toc_sort, OPTION_NO_TOC_SORT): New.
780         (PARSE_AND_LIST_PROLOGUE, PARSE_AND_LIST_LONGOPTS,
781          PARSE_AND_LIST_OPTIONS): Handle --no-toc-sort.
783 2010-03-14  Alan Modra  <amodra@gmail.com>
785         PR ld/11378
786         * emultempl/ppc64elf.em (gld${EMULATION_NAME}_after_allocation): Call
787         ppc64_elf_check_init_fini and warn if .init/.fini use different TOCs.
789 2010-03-11  George Gensure  <werkt0@gmail.com>
791         PR ld/11367
792         * ldcref.c (handle_asneeded_cref): Correct copying of refs.
794 2010-03-05  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
796         * Makefile.am (ALL_EMULATIONS): Add eelf32_sparc_sol2.o,
797         eelf_i386_sol2.o.
798         (ALL_64_EMULATIONS): Add eelf_x86_64_sol2.o, eelf64_sparc_sol2.o.
799         (eelf32_sparc_sol2.c): New rule.
800         (eelf64_sparc_sol2.c): Likewise.
801         (eelf_x86_64_sol2.c): Likewise.
802         (eelf_i386_sol2.c): Likewise.
803         * Makefile.in: Regenerate.
804         * configure.tgt (i[3-7]86-*-solaris2*): Change targ_emul to
805         elf_i386_sol2.
806         Add elf_i386_ldso, elf_x86_64_sol2 to targ_extra_emuls.
807         (x86_64-*-solaris2*): Change targ_emul to elf_x86_64_sol2.
808         Add elf_x86_64, elf_i386_sol2, elf_i386 to targ_extra_emuls.
809         (sparc-*-solaris2.[0-6]*): Change targ_emul to elf32_sparc_sol2.
810         Add target_extra_emuls.
811         (sparc-*-solaris2*): Change targ_emul to elf32_sparc_sol2.
812         Add elf32_sparc, elf64_sparc_sol2 to targ_extra_emuls.
813         (sparcv9-*-solaris2*): Change targ_emul to elf64_sparc_sol2.
814         Add elf64_sparc, elf32_sparc_sol2 to target_extra_emuls.
815         * emulparams/elf32_sparc_sol2.sh: New file.
816         * emulparams/elf64_sparc_sol2.sh: New file.
817         * emulparams/elf_i386_sol2.sh: New file.
818         * emulparams/elf_x86_64_sol2.sh: New file.
819         * emultempl/solaris2.em: New file.
821 2010-02-27  H.J. Lu  <hongjiu.lu@intel.com>
823         PR ld/11330
824         * ld.texinfo: Replace explicitely with explicitly.
826 2010-02-27  Jie Zhang  <jie@codesourcery.com>
828         * scripttempl/armbpabi.sc: Don't combine .init_array.* or
829         .fini_array.* when do relocatable linking.
830         * scripttempl/elf.sc: Likewise.
831         * scripttempl/elf32sh-symbian.sc: Likewise.
832         * scripttempl/elf64hppa.sc: Likewise.
833         * scripttempl/elfxtensa.sc: Likewise.
835 2010-02-26  Alan Modra  <amodra@gmail.com>
837         * scripttempl/elf.sc (.fini_array): Place input .fini_array after
838         .fini_array.*.
839         * scripttempl/armbpabi.sc: Likewise.
840         * scripttempl/elf32sh-symbian.sc: Likewise.
841         * scripttempl/elf64hppa.sc: Likewise.
842         * scripttempl/elfxtensa.sc: Likewise.
844 2010-02-25  Alan Modra  <amodra@gmail.com>
846         PR ld/11304
847         * ldlang.c (init_os): Remove isec param.  Don't check for
848         bfd_section already set or call bfd_init_private_section_data
849         here.
850         (exp_init_os): Update init_os call.
851         (lang_add_section): Tidy.  Really don't set SEC_LINK_ONCE
852         flags.  Call bfd_init_private_section_data here.
853         (map_input_to_output_sections): Tidy.  Update init_os calls.
854         Use os->sectype to select sec flags for lang_data_statement.
856 2010-02-23  Alan Modra  <amodra@gmail.com>
858         PR ld/11304
859         * ldlang.c: Revert last patch.
861 2010-02-23  Nick Clifton  <nickc@redhat.com>
863         * po/bg.po: Updated Bulgarian translation.
865 2010-02-22  Alan Modra  <amodra@gmail.com>
867         PR ld/11304
868         * ldlang.c (exp_init_os): Delete forward declaration.
869         (init_os): Don't check for bfd_section already created and don't
870         init addr_tree and load_base expressions here.
871         (map_input_to_output_sections): Only map input to output sections
872         and set constraints here, and as an exception, create output
873         sections which have their address set.  Move all the other code to..
874         (create_other_output_sections): ..here.  New function.  Handle init
875         of addr_tree and load_base here too.
876         (lang_process): Call create_other_output_sections.
878 2010-02-19  Alan Modra  <amodra@gmail.com>
880         * Makefile.am (eelf32_i960.c): Depend on ELF_GEN_DEPS, not ELF_DEPS.
881         * Makefile.in: Regenerate.
883 2010-02-19  Alan Modra  <amodra@gmail.com>
885         * ldlang.c (unique_section_p): Add os param.  Allow group
886         sections to match /DISCARD/.  Update all callers.
887         * emultempl/genelf.em (gld${EMULATION_NAME}_before_allocation): New.
888         (LDEMUL_BEFORE_ALLOCATION): Define.
890 2010-02-15  Nick Clifton  <nickc@redhat.com>
892         * po/vi.po: Updated Vietnamese translation.
894 2010-02-10  Richard Sandiford  <r.sandiford@uk.ibm.com>
896         * Makefile.am (CFILES): Add ldlex-wrapper.c.
897         (OFILES): Replace ldlex.c with ldlex-wrapper.c.
898         (ldlex.o): Replace with...
899         (ldlex-wrapper.o): ...this new rule.
900         (EXTRA_ld_new_SOURCES): Add ldlex.l.
901         (ld_new_SOURCES): Replace ldlex.l with ldlex-wrapper.c.
902         * Makefile.in: Regenerate.
903         * ldlex.l (sysdep.h): Don't include here.
904         * ldlex-wrapper.c: New file.
906 2010-02-09  Alan Modra  <amodra@gmail.com>
908         * emultempl/ppc64elf.em (ppc_before_allocation): Update for changed
909         function parameters.
911 2010-02-05  Nick Clifton  <nickc@redhat.com>
913         * configure.in (ALL_LIBGUAS): Add bg.
914         * configure: Regenerate.
915         * po/bg.po: New Bulgarian translation.
917 2010-02-05  Ryan Mansfield  <rmansfield@qnx.com>
919         * emultempl/armelf.em (PARSE_AND_LIST_OPTIONS): Fix help for
920         --target1-abs and --target1-rel options.
922 2010-02-03  Nick Clifton  <nickc@redhat.com>
924         * emultempl/alphaelf.em: Update value expected from elf_object_id.
925         * emultempl/hppaelf.em: Likewise.
926         * emultempl/mipself.em: Likewise.
927         * emultempl/ppc32elf.em: Likewise.
928         * emultempl/ppc64elf.em: Likewise.
930 2010-02-03  Alan Modra  <amodra@gmail.com>
932         * emultempl/ppc64elf.em (build_toc_list): Report errors from
933         ppc64_elf_next_toc_section.
934         (after_allocation): Update for changed function names and params.
935         Run second pass of multitoc partitioning.
937 2010-01-21  Jon Grant  <jg@jguk.org>
938             Nick Clifton  <nickc@redhat.com>
940         PR 4437
941         * ldfile.c: (ldfile_open_file): Do not stop link upon encountering
942         a missing file or library.  Instead mark the entry as missing and
943         set the global flag to indicate that missing files were
944         encountered.
945         * ldlang.c (missing_files): New exported variable.
946         (load_symbols): Skip loading if the file is missing.
947         (open_input_bfds): Terminate link if any input files were
948         missing.
949         * ldlang.h (struct lang_input_statement_struct): Add missing_file
950         field.
951         Add export of missing_file variable.
953 2010-01-13  DJ Delorie  <dj@redhat.com>
955         * emultempl/elf32.em (_place_orphan): If an input section doesn't
956         match an existing output section, but an unused output section
957         statement does match, use it.
958         * emultempl/pe.em (_place_orphan): Likewise.
959         * emultempl/pep.em (_place_orphan): Likewise.
961 2010-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
963         * configure: Regenerate.
964         * Makefile.in: Regenerate.
966 2010-01-08  H.J. Lu  <hongjiu.lu@intel.com>
968         * ldver.c (ldversion): Change to "Copyright 2010".
970 2010-01-08  Alan Modra  <amodra@gmail.com>
972         PR 11107
973         * emultempl/vxworks.em: Expand tr arguments to suit non-GNU tr.
975 For older changes see ChangeLog-2009
977 Local Variables:
978 mode: change-log
979 left-margin: 8
980 fill-column: 74
981 version-control: never
982 End: