1 2014-05-28 Hans-Peter Nilsson <hp@axis.com>
3 * Makefile.am: Change all rules with ${GENSCRIPTS}
4 invocations to be just dependencies.
5 ($(ALL_EMULATION_SOURCES) $(ALL_64_EMULATION_SOURCES))
6 (run-genscripts): New rules.
7 * Makefile.in: Regenerate.
9 2014-05-27 DJ Delorie <dj@redhat.com>
11 * ld/ldemul.h (extra_map_file_text): New field.
12 (ldemul_extra_map_file_text): Declare.
13 * ld/ldemul.c (ldemul_extra_map_file_text): Define.
14 * ld/ldlang.c (lang_map): Call it.
16 * ld/emultempl/rxelf.em: Add extra_map_file_text hook.
17 * ld/emultempl/aix.em: Add NULL extra_map_file_text hook.
18 * ld/emultempl/armcoff.em: Likewise.
19 * ld/emultempl/beos.em: Likewise.
20 * ld/emultempl/elf32.em: Likewise.
21 * ld/emultempl/generic.em: Likewise.
22 * ld/emultempl/gld960.em: Likewise.
23 * ld/emultempl/gld960c.em: Likewise.
24 * ld/emultempl/linux.em: Likewise.
25 * ld/emultempl/lnk960.em: Likewise.
26 * ld/emultempl/m68kcoff.em: Likewise.
27 * ld/emultempl/pe.em: Likewise.
28 * ld/emultempl/pep.em: Likewise.
29 * ld/emultempl/sunos.em: Likewise.
30 * ld/emultempl/ticoff.em: Likewise.
31 * ld/emultempl/vanilla.em: Likewise.
33 2014-05-24 Alan Modra <amodra@gmail.com>
35 * ldlang.c (base): Move variable to..
36 * mri.c: ..here, and make static.
37 * ldlang.h (base): Delete declaration.
39 2014-05-20 Hans-Peter Nilsson <hp@axis.com>
41 * Makefile.am (ALL_EMULATION_SOURCES): Add missing eelf32mbel_linux.c.
42 * Makefile.in: Regenerate.
44 2014-05-20 Alan Modra <amodra@gmail.com>
47 * emulparams/elf32ppccommon.sh (_SDA_BASE_, _SDA2_BASE_): Delete.
48 * emultempl/ppc32elf.em (ppc_before_allocation): Call
49 ppc_elf_maybe_strip_sdata_syms.
50 * ldlang.c (size_input_section): Correct output_offset value
51 for excluded input sections.
53 2014-05-16 John Marino <binutils@marino.st>
55 * configure.tgt: Add /lib to dragonfly NATIVE_LIB_DIRS.
57 2014-05-11 Chung-Lin Tang <cltang@codesourcery.com>
59 * emulparams/nios2linux.sh (OTHER_GOT_SYMBOLS): Wrap _gp in HIDDEN(),
60 and gp in PROVIDE_HIDDEN.
62 2014-05-10 Hans-Peter Nilsson <hp@bitrange.com>
64 * ldlang.c (lang_finish): Don't call bfd_link_hash_table_free here.
65 (output_bfd_hash_table_free_fn): New variable.
66 (open_output): Save the _bfd_link_hash_table_free function for the
67 output_bfd into output_bfd_hash_table_free_fn.
68 * ldmain.c (ld_cleanup): If set, call output_bfd_hash_table_free_fn
70 * ldlang.h (output_bfd_hash_table_free_fn): Declare.
72 2014-05-02 Alan Modra <amodra@gmail.com>
74 * emultempl/metagelf.em: Update bfd target vector naming.
75 * emultempl/nios2elf.em: Likewise.
76 * emultempl/spuelf.em: Likewise.
77 * emultempl/tic6xdsbt.em: Likewise.
79 2014-04-22 Christian Svensson <blue@cmd.nu>
81 * Makefile.am: Remove openrisc and or32 support. Add support for or1k.
82 * configure.tgt: Likewise.
83 * emulparams/elf32or1k.sh: New file.
84 * emulparams/elf32or1k_linux.sh: New file.
85 * emulparams/elf32openrisc.sh: Delete.
86 * emulparams/or32.sh: Delete.
87 * emulparams/or32elf.sh: Delete.
88 * scripttempl/or32.sc: Delete.
89 * Makefile.in: Regenerate.
91 2014-04-21 Richard Henderson <rth@redhat.com>
93 * emultempl/alphaelf.em (alpha_after_parse): Enable 2 relax passes.
95 2014-04-16 Steve Ellcey <sellcey@mips.com>
97 * emultempl/elf32.em: Include safe-ctype.h.
99 2014-04-16 Steve Ellcey <sellcey@mips.com>
101 * ldbuildid.c (generate_build_id): Add ATTRIBUTE_UNUSED to size arg.
103 2014-04-09 Nick Clifton <nickc@redhat.com>
105 * Makefile.am (default-manifest.o): Remove rule.
106 (EMUL_EXTRA_BINARIES): Delete.
107 (ALL_EMUL_EXTRA_BINARIES): Delete.
108 (ld_new_DEPENDENCIES): Remove EMUL_EXTRA_BINARIES.
109 (install-data-local): Remove EMUL_EXTRA_BINARIES.
110 * Makefile.in: Regenerate.
111 * configure.in (all_emul_extra_binaries): Delete.
112 (EMUL_EXTRA_BINARIES): Remove.
113 * configure: Regenerate.
114 * configure.tgt (target_extra_binaries): Delete.
115 * emultempl/default-manifest.rc: Delete.
116 * ld.texinfo: Remove discussion of default manifest.
117 * emulparams/i386pe.sh (DEFAULT_MANIFEST): Delete.
118 * emulparams/i386pep.sh (DEFAULT_MANIFEST): Delete.
120 2014-04-09 Alan Modra <amodra@gmail.com>
122 * emultempl/spuelf.em: Include safe-ctype.h, remove duplicate errno.h.
123 * emultempl/nds32elf.em: Include bfd_stdint.h.
124 * po/POTFILES.in: Regenerate.
126 2014-04-09 Alan Modra <amodra@gmail.com>
128 * emultempl/ppc32elf.em (no_zero_padding, ppc_finish): New functions.
129 (LDEMUL_FINISH): Define.
131 2014-04-08 Nick Clifton <nickc@redhat.com>
133 * scripttempl/pe.sc (R_RSRC): Remove default manifest.
134 * scripttempl/pep.sc (R_RSRC): Remove default manifest.
136 2014-04-08 Jon TURNEY <jon.turney@dronecode.org.uk>
138 * emultempl/elf32.em (id_note_section_size, read_hex, write_build_id):
139 Move code for parsing build-id option and calculating the build-id to...
140 * ldbuildid.c: New file.
141 * ldbuildid.h: New file.
142 * Makefile.am (CFILES, HFILES, OFILES, ld_new_SOURCES): Add new
144 * Makefile.in: Regenerate.
145 * ld.texinfo: Update --build-id description to mention COFF
147 * NEWS: Mention support for COFF build ids.
148 * emultempl/pe.em (gld${EMULATION_NAME}_handle_option):
149 (pecoff_checksum_contents, write_build_id, setup_build_id)
150 (gld_${EMULATION_NAME}_after_open): Handle and implement
152 * emultempl/pep.em: Likewise.
154 2014-04-04 Cary Coutant <ccoutant@google.com>
157 * ld.texinfo: Document optional comma following output section
158 command and overlay command.
160 2014-04-04 Alan Modra <amodra@gmail.com>
162 * ldlang.c (lang_size_sections_1 <lang_input_section_enum>): Use
163 current "fill", not "output_section_statement->fill".
165 2014-03-31 Nick Clifton <nickc@redhat.com>
168 * emultempl/elf32.em (_after_open): Create a .note.GNU-stack
169 section when performing a relocatable link with -z [no]execstack
172 2014-03-27 H.J. Lu <hongjiu.lu@intel.com>
175 * ldmain.c (symbol_warning): New function.
176 (warning_callback): Use it. Scan all input files for a reference
179 2014-03-21 Christopher Faylor <me.cygwin2013@cgf.cx>
181 * ld.texinfo: Document change in handling of --enable-auto-image-base.
182 * emultempl/pe.em (pe_auto_image_base): Set to default base.
183 (gld_${EMULATION_NAME}_list_options): Change usage message to reflect
184 optional --enable-auto-image-base argument.
185 (gld${EMULATION_NAME}_handle_option): Handle optional
186 --enable-auto-image-base argument.
187 (compute_dll_image_base): Eliminate constant. Use pe_auto_image_base.
189 2014-03-19 Nick Clifton <nickc@redhat.com>
191 * Makefile.am (default-manifest.o): Use WINDRES_FOR_TARGET.
192 * Makefile.in: Regenerate.
193 * emultempl/default-manifest.rc: Fix typo.
194 * scripttempl/pe.sc (R_RSRC): Fix default-manifest exclusion.
195 (.rsrc): Add SUBALIGN(4). Remove SORT.
196 * scripttempl/pep.sc: Likewise.
198 2014-03-17 Christopher Faylor <me.cygwin2014@cgf.cx>
200 * Makefile.am: Use host version of windres.
201 * Makefile.in: Regenerate.
203 2014-03-14 Romain Geissler <romain.geissler@amadeus.com>
204 Alan Modra <amodra@gmail.com>
206 * ldlang.h (full_name_provided): New input flag.
207 * ldlang.c (new_afile): Don't use lang_input_file_is_search_file_enum
208 for -l:namespec. Instead use lang_input_file_is_l_enum with
209 full_name_provided flag.
210 * ldlfile.c (ldfile_open_file_search): Don't complete lib name if
211 full_name_provided flag is set.
212 * emultempl/elf32.em (gld${EMULATION_NAME}_open_dynamic_archive):
213 Handle full_name_provided libraries. Tidy EXTRA_SHLIB_EXTENSION
214 support. Set DT_NEEDED for -l:namespec as namespec.
215 * emultempl/aix.em (ppc_after_open_output): Handle full_name_provided.
216 * emultempl/linux.em (gld${EMULATION_NAME}_open_dynamic_archive):
217 Don't handle full_name_provided libraries.
218 * emultempl/pe.em (gld${EMULATION_NAME}_open_dynamic_archive): Ditto.
219 * emultempl/pep.em (gld${EMULATION_NAME}_open_dynamic_archive): Ditto.
220 * emultempl/vms.em (gld${EMULATION_NAME}_open_dynamic_archive): Ditto.
222 2014-03-12 Alan Modra <amodra@gmail.com>
224 * Makefile.in: Regenerate.
226 2014-03-05 Alan Modra <amodra@gmail.com>
228 Update copyright years.
230 2014-03-04 Nick Clifton <nickc@redhat.com>
232 * Makefile.am (ALL_EMUL_EXTRA_BINARIES): Remove default-manifest.
233 * Makefile.in: Regenerate.
235 2014-02-27 Yuri Gribov <y.gribov@samsung.com>
237 * emultempl/armelf.em (OPTION_LONG_PLT): Define.
238 (PARSE_AND_LIST_LONGOPTS): Add long-plt.
239 (PARSE_AND_LIST_OPTIONS): Likewise.
240 (PARSE_AND_LIST_ARGS_CASES): Handle long-plt.
241 * ld.texinfo: Document --long-plt.
243 2014-02-27 Alan Modra <amodra@gmail.com>
245 * emulparams/elf32ppcvxworks.sh: Source plt_unwind.sh and
247 * emultempl/ppc32elf.em (ppc_after_open): Don't compile for
249 (LDEMUL_AFTER_OPEN): Don't set for vxworks.
250 (PARSE_AND_LIST_LONGOPTS, PARSE_AND_LIST_OPTIONS): Exclude
251 -secure-plt, -bss-plt and -sdata-got when vxworks.
253 2014-02-27 Nick Clifton <nickc@redhat.com>
255 * configure.in (all_emul_extra_binaries): New variable. Populated
256 by invoking configure.tgt.
257 (EMUL_EXTRA_BINARIES): New substitution.
258 * configure: Regenerate.
259 * configure.tgt (target_extra_binaries): New variable. Set to
260 default-manifest.o for Cygwin and MinGW targets.
261 * Makefile.am (EMUL_EXTRA_BINARIES): New variable. Initialised
262 by the configure script.
263 (ALL_EMUL_EXTRA_BINARIES): New variable.
264 (default-manifest.o): New rule to build the default manifest.
265 (ld_new_DEPENDENCIES): Add EMUL_EXTRA_BINARIES.
266 (install-data-local): Add EMUL_EXTRA_BINARIES.
267 * Makefile.in: Regenerate.
268 * ld.texinfo: Document default manifest support.
269 * emulparams/i386pe.sh (DEFAULT_MANIFEST): Define.
270 * emulparams/i386pep.sh (DEFAULT_MANIFEST): Define.
271 * emultempl/default-manifest.rc: New file.
272 * scripttempl/pe.sc (R_RSRC): Include DEFAULT_MANIFEST, if defined.
273 * scripttempl/pep.sc (R_RSRC): Likewise.
275 2014-02-26 Dan Mick <dan.mick@inktank.com>
278 * ldcref.c (cref_sort_array): Compare unmangled names unless
279 demanglng has been requiested.
280 (output_one_cref): Output unmangled name unless demangling has
283 2014-02-19 Igor Zamyatin <igor.zamyatin@intel.com>
284 H.J. Lu <hongjiu.lu@intel.com>
286 * emulparams/elf_x86_64.sh (TINY_READONLY_SECTION): New.
288 2014-02-19 Alan Modra <amodra@gmail.com>
290 * emultempl/ppc64elf.em (params): Init new field.
291 (ppc_create_output_section_statements): Set params.save_restore_funcs
293 (PARSE_AND_LIST_*): Add support for --save-restore-funcs and
294 --no-save-restore-funcs.
296 2014-02-17 Alan Modra <amodra@gmail.com>
298 * emultemps/ppc64elf.em (params): New static struct replacing
299 various other static vars. Adjust code throughout file.
301 2014-02-17 Alan Modra <amodra@gmail.com>
303 * emultempl/ppc32elf.em (ppc_after_open_output): Really enable
304 ppc476 workaround for ld -r.
306 2014-02-12 Alan Modra <amodra@gmail.com>
308 * emultempl/ppc32elf.em (pagesize): New static var.
309 (ppc_after_open_output): Set params.pagesize_p2 from pagesize.
310 (PARSE_AND_LIST_ARGS_CASES): Adjust to use pagesize.
312 2014-02-11 Andrew Pinski <apinski@cavium.com>
314 * emulparams/aarch64linux32.sh (LIBPATH_SUFFIX): Change to ilp32.
315 (ELF_INTERPRETER_NAME): Define.
316 * emulparams/aarch64linux32b.sh (ELF_INTERPRETER_NAME): Define.
318 2014-02-10 Alan Modra <amodra@gmail.com>
320 * po/ld.pot: Regenerate.
322 2014-02-03 Alan Modra <amodra@gmail.com>
324 * emultempl/ppc32elf.em (no_tls_get_addr_opt, emit_stub_syms)
325 plt_style): Delete. Adjust all refs to instead use..
326 (params): ..this. New variable.
327 (ppc_after_open_output): New function. Tweak params and pass to
329 (ppc_after_open): Adjust ppc_elf_select_plt_layout call.
330 (ppc_before_allocation): Adjust ppc_elf_tls_setup call. Enable
331 relaxation for ppc476 workaround.
332 (PARSE_AND_LIST_*): Add --{no-,}ppc476-workaround support.
333 (LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS): Define.
335 2014-02-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
337 * ld/ld.texinfo: Change ALIGN_WITH_INPUT documentation.
338 * ld/ldlang.c (lang_size_sections_1): Add dotdelta
339 variable which reflects the VMA change due to alignment
340 requirements. Use dotdelta do change the LMA if
341 ALIGN_WITH_INPUT is requested.
343 2014-02-01 Hans-Peter Nilsson <hp@bitrange.com>
345 * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Fix typo in
346 call to bfd_set_section_vma exposed by recent bfd_set_section_vma
349 2014-01-30 Sandra Loosemore <sandra@codesourcery.com>
351 * Makefile.am (enios2elf.c, enios2linux.c): Update dependencies.
352 * Makefile.in: Regenerated.
353 * emulparams/nios2elf.sh (EXTRA_EM_FILE): Set.
354 * emulparams/nios2linux.sh (EXTRA_EM_FILE): Set.
355 * emultempl/nios2elf.em: New file.
356 * gen-doc.texi (NIOSII): Set.
357 * ld.texinfo (NIOSII): Set.
359 2014-01-28 Nick Clifton <nickc@redhat.com>
361 * Makefile.am: Remove obsolete MSP430 emulations.
362 * configure.tgt: Likewise.
363 * emulparams/msp430all.sh: Likewise.
364 * Makefile.in: Regenerate.
366 2014-01-24 H.J. Lu <hongjiu.lu@intel.com>
369 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Improve
370 orphaned TLS section handling.
372 2014-01-24 Alan Modra <amodra@gmail.com>
374 * ldlang.c (lang_output_section_find_by_flags): Be careful to
375 test look->bfd_section->flags if available rather than
376 look->flags. Separate SEC_THREAD_LOCAL handling from
377 SEC_READONLY loop, and rewrite.
379 2014-01-22 Alan Modra <amodra@gmail.com>
381 * ldlang.c (asneeded_list_head, asneeded_list_tail): New vars.
382 (lang_init): Initialise them.
383 (lang_print_asneeded): New function.
384 (lang_process): Call lang_print_asneeded.
385 * ldlang.h (struct asneeded_minfo): New.
386 (asneeded_list_tail): Declare.
387 * ldmain.c (add_archive_element): Improve archive map heading.
388 * ldmisc.c (minfo): Stash --as-needed info.
390 2014-01-22 Alan Modra <amodra@gmail.com>
392 * ld.h (struct map_symbol_def): Move to..
394 * ldlang.c (print_assignment): Don't set expld.assign_name to dot.
396 2014-01-22 Alan Modra <amodra@gmail.com>
398 * ld.texinfo (Output Section Discarding): Mention assigning to dot
399 as a way of keeping otherwise empty sections.
400 * ldexp.c (is_dot, is_value, is_sym_value, is_dot_ne_0,
401 is_dot_plus_0, is_align_conditional): New predicates.
402 (exp_fold_tree_1): Set SEC_KEEP when assigning to dot inside an
403 output section, except for some special cases.
404 * scripttempl/elfmicroblaze.sc: Use canonical form to align at
405 end of .heap and .stack.
407 2014-01-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
409 * emulparams/aarch64linuxb.sh (ELF_INTERPRETER_NAME): Define.
411 2014-01-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
413 * emulparams/aarch64linux.sh (ELF_INTERPRETER_NAME): Define.
415 2014-01-20 Alan Modra <amodra@gmail.com>
417 * ldlang.h (struct lang_definedness_hash_entry): Add by_object and
418 by_script. Make iteration a single bit field.
419 (lang_track_definedness, lang_symbol_definition_iteration): Delete.
420 (lang_symbol_defined): Declare.
421 * ldlang.c (lang_statement_iteration): Expand comment a little.
422 (lang_init <lang_definedness_table>): Make it bigger.
423 (lang_track_definedness, lang_symbol_definition): Delete.
424 (lang_definedness_newfunc): Update.
425 (lang_symbol_defined): New function.
426 (lang_update_definedness): Create entries here. Do track whether
427 script definition of symbol is valid, even when also defined in
429 * ldexp.c (fold_name <DEFINED>): Update.
430 (fold_name <NAME>): Allow self-assignment for absolute symbols
431 defined in a linker script.
433 2014-01-20 Guy Martin <gmsoft@tuxicoman.be>
434 Alan Modra <amodra@gmail.com>
436 * ldlang.h (lang_output_section_get): Define.
437 * ldlang.c (lang_output_section_get): Likewise.
438 (init_os): Set the output_section userdata to the output
440 * emultempl/hppaelf.em: Use lang_output_section_get instead of
441 lang_output_section_find where applicable.
442 * emultempl/aarch64elf.em: Likewise.
443 * emultempl/aix.em: Likewise.
444 * emultempl/armelf.em: Likewise.
445 * emultempl/m68hc1xelf.em: Likewise.
446 * emultempl/metagelf.em: Likewise.
447 * emultempl/mipself.em: Likewise.
448 * emultempl/ppc64elf.em: Likewise.
449 * emultempl/spuelf.em: Likewise.
451 2014-01-17 Alan Modra <amodra@gmail.com>
453 * genscripts.sh (COMPILE_IN): Don't set if already set.
454 * emulparams/nds32elf.sh: Don't clear EMULATION_LIBPATH, set
456 * emulparams/nds32elf16m.sh: Likewise.
457 * emulparams/nds32elf_linux.sh: Likewise.
458 * emultempl/aix.em: Test COMPILE_IN value is "yes".
459 * emultempl/armcoff.em: Likewise.
460 * emultempl/elf32.em: Likewise.
461 * emultempl/generic.em: Likewise.
462 * emultempl/gld960.em: Likewise.
463 * emultempl/gld960c.em: Likewise.
464 * emultempl/linux.em: Likewise.
465 * emultempl/lnk960.em: Likewise.
466 * emultempl/m68kcoff.em: Likewise.
467 * emultempl/sunos.em: Likewise.
468 * emultempl/ticoff.em: Likewise.
470 2014-01-16 H.J. Lu <hongjiu.lu@intel.com>
473 * genscripts.sh: Don't search directory with LIBPATH_SUFFIX_SKIP
475 * emulparams/elf32_x86_64.sh (LIBPATH_SUFFIX_SKIP): Set to 64
476 for elf32_x86_64 emulation.
477 * emulparams/elf_i386.sh (LIBPATH_SUFFIX_SKIP): Set to 64
478 for elf_i386 emulation.
480 2014-01-16 Alan Modra <amodra@gmail.com>
482 * ld.h (fat_section_userdata_type, get_userdata): Move to..
483 * ldlang.h (input_section_userdata_type, get_userdata): ..here.
484 * ldlang.c (init_map_userdata): Delete. Fold into..
485 (sort_def_symbol): ..here. Don't attach input section userdata
486 to output sections or global bfd sections.
487 (lang_map): Don't pre-allocate input section userdata.
488 (init_os): Don't allocate userdata for output sections.
489 (print_all_symbols): Update.
491 2014-01-15 H.J. Lu <hongjiu.lu@intel.com>
493 * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation):
494 Silence uninitialized warning on ehdr_start_save with older
497 2014-01-15 Alan Modra <amodra@gmail.com>
499 * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation): Define
500 __ehdr_start before size_dynamic_sections and restore afterwards.
502 2014-01-10 Alan Modra <amodra@gmail.com>
507 * ldlang.c (lang_size_sections): Remove unneeded RELRO base
508 adjust. Tidy comments.
509 * ld.texinfo (DATA_SEGMENT_RELRO_END): Correct description.
511 2014-01-10 Hans-Peter Nilsson <hp@axis.com>
513 * emulparams/crislinux.sh (COMMONPAGESIZE): Define.
515 2014-01-08 H.J. Lu <hongjiu.lu@intel.com>
520 * ldlang.c (lang_size_sections): Properly align RELRO base.
522 2014-01-08 H.J. Lu <hongjiu.lu@intel.com>
524 * ldver.c (ldversion): Update copyright year to 2014.
526 For older changes see ChangeLog-2013
528 Copyright (C) 2014 Free Software Foundation, Inc.
530 Copying and distribution of this file, with or without modification,
531 are permitted in any medium without royalty provided the copyright
532 notice and this notice are preserved.
538 version-control: never