ld: improve linker script section
[binutils-gdb.git] / ld / ChangeLog
1 2010-07-20 Mike Frysinger <vapier@gentoo.org>
2
3 * ld.texinfo (VERSION): Remove "int" from example script and add ";".
4 Declare the default language as C.
5
6 2010-07-17 Alan Modra <amodra@gmail.com>
7
8 * ldlang.c (lang_check_section_addresses): Catch overlap for
9 sections that wrap around the address space.
10
11 2010-06-29 Nick Clifton <nickc@redhat.com>
12
13 * scripttempl/xstormy16.sc (.gcc_except_table): Include sections
14 with the .gcc_except_table. prefix.
15
16 2010-06-29 Alan Modra <amodra@gmail.com>
17
18 * emulparams/maxqcoff.sh: Delete file.
19 * scripttempl/maxqcoff.sc: Delete file.
20 * Makefile.am: Remove references to maxq.
21 * configure.tgt: Likewise.
22 * Makefile.in: Regenerate.
23 * configure: Regenerate.
24 * po/POTFILES.in: Regenerate.
25
26 2010-06-27 Alan Modra <amodra@gmail.com>
27
28 * pe-dll.c (fill_edata): Avoid set but unused warning.
29 (pe_walk_relocs_of_symbol): Delete set but unused variables.
30 (generate_reloc, pe_implied_import_dll): Likewise.
31 * emultempl/aix.em (open_dynamic_archive): Likewise.
32 * emultempl/xtensaelf.em (replace_insn_sec_with_prop_sec): Likewise.
33 (xtensa_layout_wild): Likewise.
34 (xtensa_colocate_output_literals_callback): Likewise.
35
36 2010-06-25 Alan Modra <amodra@gmail.com>
37
38 * emultempl/ppc64elf.em (prelim_size_sections): New function.
39 (ppc_before_allocation): Use it. Size sections before toc edit too.
40
41 2010-06-25 Alan Modra <amodra@gmail.com>
42
43 * emultempl/elf32.em (find_exp_assignment): Handle etree_provided.
44
45 2010-06-20 Danny Smith <dannysmith@users.sourceforge.net>
46
47 * emultempl/pe.em (gld_${EMULATION_NAME}_before_parse): Make
48 auto-import and merge-rdata defaults same for i[3-7]86 and
49 x86_64 mingw.
50
51 2010-06-15 Joseph Myers <joseph@codesourcery.com>
52
53 * emulparams/elf32_tic6x_le.sh (ATTRS_SECTIONS): Define.
54
55 2010-06-09 Dave Korn <dave.korn.cygwin@gmail.com>
56
57 PR ld/11603
58 * pe-dll.c (process_def_file_and_drectve): Reorder check for
59 forwarded export name after check for ordinary export.
60
61 2010-06-08 Bernd Schmidt <bernds@codesourcery.com>
62
63 * emulparams/elf32_tic6x_le.sh (OTHER_BSS_SECTIONS): New.
64
65 2010-06-08 Nick Clifton <nickc@redhat.com>
66
67 * fdl.texi: Replace with v1.3 text.
68 * ld.texinfo: Replace abbreviated 20th century year numbers with
69 full versions.
70 * ldint.texinfo: Likewise.
71 Relicense under GFDL v1.3. Replace text of v1.1 FDL with an
72 include of the fdl.texi file.
73
74 2010-06-01 Tristan Gingold <gingold@adacore.com>
75
76 * scripttempl/alphavms.sc: Add comments. Move $LINK$ to the
77 readonly output-section. Handle LIB$INITIALIZE and sections
78 created by gcc.
79 * emultempl/vms.em (vms_place_orphan): Add comments.
80
81 2010-05-28 Nick Clifton <nickc@redhat.com>
82
83 * Makefile.am (eshlelf_fd.c): Fix typo in rule.
84 * Makefile.in: Regenerate.
85
86 2010-05-26 H.J. Lu <hongjiu.lu@intel.com>
87
88 PR ld/11628
89 * ldexp.c (fold_binary): Warn if value of SEGMENT_START isn't
90 multiple of maximum page size.
91
92 2010-05-25 Nick Clifton <nickc@redhat.com>
93
94 * Makefile.am: Fix typo.
95 * Makefile.in: Regenerate.
96
97 2010-05-25 Daniel Jacobowitz <dan@codesourcery.com>
98 Joseph Myers <joseph@codesourcery.com>
99 Andrew Stubbs <ams@codesourcery.com>
100
101 * Makefile.am (ALL_EMULATIONS): Add eshelf_fd.o and eshlelf_fd.o.
102 (eshelf_fd.c, eshlelf_fd.c): New rules.
103 * Makefile.in: Regenerate.
104 * configure.tgt (sh-*-uclinux*): Add shelf_fd and shlelf_fd
105 emulations.
106 * emulparams/shelf_fd.sh: New file.
107 * emulparams/shlelf_fd.sh: New file.
108 * emulparams/shlelf_linux.sh: Update comment.
109
110 2010-05-25 Jay Krell <jay.krell@cornell.edu>
111
112 PR ld/11621
113 * Makefile.am: Replace all occurences of .o with .@OBJEXT@
114 * Makefile.in: Regenerate.
115
116 2010-05-25 Kai Tietz <kai.tietz@onevision.com>
117
118 * deffilep.y (opt_name): Allow leading dot.
119 (dot_name): Likewise.
120 (anylang_id): Likewise.
121 * emultempl/pep.em (gld_${EMULATION_NAME}_before_parse): Enable by
122 default auto_import.
123 (gld${EMULATION_NAME}_handle_option): Warn about v1.
124 (pep_find_data_imports): Remove superflous warnings about
125 auto-import.
126 (gld_${EMULATION_NAME}_get_script): Don't merge for auto-import
127 and active pseudo-relocation-v2 rdata into data section.
128 * emultempl/pe.em (default_merge_rdata): New shell variable.
129 (MERGE_RDATA_V2): New macro.
130 (gld_${EMULATION_NAME}_get_script): Adjust rule for auto-import
131 selected script.
132
133 2010-05-15 Kai Tietz <kai.tietz@onevision.com>
134
135 * emultempl/pe.em (is_underscoring): New helper function.
136 (gld_${EMULATION_NAME}_before_parse): Replace code
137 for pe(p)_leading_underscore detection by is_underscoring.
138 (U): Likewise.
139 (GET_INIT_SYMBOL_NAME): Likewise.
140 (U_SIZE): Likewise.
141 (set_pe_name):
142 (set_entry_point):
143 (gld_${EMULATION_NAME}_set_symbols):
144 * emultempl/pep.em: Likewise.
145 * pe-dll.c (pe_detail_list): Set default
146 underscoring for x64 target.
147 (pe_dll_id_target): Add initialization of
148 pe(p)_leading_underscore.
149
150 2010-05-15 Dave Korn <dave.korn.cygwin@gmail.com>
151
152 * pe-dll.c: Removed trailing whitespaces.
153
154 2010-05-14 Alan Modra <amodra@gmail.com>
155
156 PR ld/11583
157 * ldexp.c (exp_fold_tree_1): If assignment source expression is
158 invalid, make the destination symbol undefined.
159
160 2010-05-11 Kai Tietz <kai.tietz@onevision.com>
161
162 * emultempl/pe.em (gld_${EMULATION_NAME}_before_parse):
163 Initialize pe(p)_leading_underscore variable.
164 (set_pe_name): Likewise.
165 * emultempl/pep.em: Likewise.
166 Additional change default to non-underscore for
167 pep_leading_underscore equal to -1.
168
169 2010-05-07 Tristan Gingold <gingold@adacore.com>
170
171 * Makefile.in: Regenerate with automake 1.11.1.
172 * aclocal.m4: Ditto.
173
174 2010-05-05 Nick Clifton <nickc@redhat.com>
175
176 * po/es.po: Updated Spanish translation.
177
178 2010-04-27 Kai Tietz <kai.tietz@onevision.com>
179
180 * pe-dll.c (_nm_-symbols): Use always underscored variant
181 for symbols.
182 (__imp_-symbols): Likewise.
183 (___imp_-symbols): Likewise.
184 * NEWS: Mention ABI change for x64 PE-COFF.
185
186 2010-04-27 H.J. Lu <hongjiu.lu@intel.com>
187
188 * Makefile.am (install-exec-local): Properly install ld as
189 default cross linker.
190 * Makefile.in: Regenerated.
191
192 2010-04-27 H.J. Lu <hongjiu.lu@intel.com>
193 Nick Clifton <nickc@redhat.com>
194
195 * configure.in (install_as_default): Define and set to true
196 unless --enable-gold=both/gold has been specified.
197 * configure: Regenerate.
198
199 * Makefile.am (transform): Use ld.bfd as the default name of
200 the linker.
201 (install-exec-local): Also install the executable as a binary
202 named 'ld' if install_as_default is true.
203 * Makefile.in: Regenerate.
204
205 2010-04-22 Nick Clifton <nickc@redhat.com>
206
207 * po/ld.pot: Updated by the Translation project.
208 * po/vi.po: Updated Vietnamese translation.
209 * po/bg.po: Updated Bulgarian translation.
210
211 2010-04-15 Andrew Haley <aph@redhat.com>
212
213 * emultempl/armelf.em (merge_exidx_entries): New variable.
214 (OPTION_NO_MERGE_EXIDX_ENTRIES): New definition.
215 ("no-merge-exidx-entries"): New option.
216 * ld.texinfo (merge-exidx-entries): Document this option.
217
218 2010-04-14 Tristan Gingold <gingold@adacore.com>
219
220 * emulparams/alphavms.sh: New file.
221 * emultempl/vms.em: New file.
222 * scripttempl/alphavms.sc: New file.
223 * configure.tgt (alpha*-*-*vms*): Added.
224 * Makefile.am (ALL_EMULATIONS): Add ealphavms.o
225 (ealphavms.c): New target.
226 * Makefile.in: Regenerate.
227
228 2010-04-09 Nick Clifton <nickc@redhat.com>
229
230 * ldlang.c (wild_sort): Remove unused variable section_name.
231
232 2010-04-07 Alan Modra <amodra@gmail.com>
233
234 * configure: Regenerate.
235
236 2010-04-06 H.J. Lu <hongjiu.lu@intel.com>
237
238 PR ld/11434
239 * ld/testsuite/ld-x86-64/unique1.d: New.
240 * ld/testsuite/ld-x86-64/unique1.s: Likewise.
241
242 * ld-x86-64/x86-64.exp: Run unique1.
243
244 2010-04-05 Kai Tietz <kai.tietz@onevision.com>
245
246 * emultempl/pep.em (U): Macro modified.
247 (U_SIZE): New helper macro.
248 (GET_INIT_SYMBOL_NAME): Likewise.
249 (enum options): Add OPTION_NO_LEADING_UNDERSCORE
250 and OPTION_LEADING_UNDERSCORE enumerator-values.
251 (gld${EMULATION_NAME}_add_options): Add --(no-)leading-underscore
252 option.
253 (definfo): Add new member is_c_symbol.
254 (D): Add to macro underscore mode parameter.
255 (init): Add definition for is_c_symbol.
256 (gld_${EMULATION_NAME}_list_options): Display new options.
257 (set_pep_name): Adjust underscoring dependent fixed
258 symbol handling.
259 (gld_${EMULATION_NAME}_set_symbols): Likewise.
260 (saw_option): Likewise.
261 (gld_${EMULATION_NAME}_unrecognized_file): Likewise.
262 (set_entry_point): Initial initial_symbol_char dependent to
263 target's default and new option flag pep_leading_underscore.
264 * emultempl/pe.em (U): Macro modified.
265 (U_SIZE): New helper macro.
266 (GET_INIT_SYMBOL_NAME): Likewise.
267 (OPTION_LEADING_UNDERSCORE): Add new option define.
268 (OPTION_NO_LEADING_UNDERSCORE): Likewise.
269 (gld${EMULATION_NAME}_add_options): Add --(no-)leading-underscore
270 option.
271 (definfo): Add new member is_c_symbol.
272 (D): Add to macro underscore mode parameter.
273 (init): Add definition for is_c_symbol.
274 (gld_${EMULATION_NAME}_list_options): Display new options.
275 (set_pep_name): Adjust underscoring dependent fixed
276 symbol handling.
277 (gld_${EMULATION_NAME}_set_symbols): Likewise.
278 (saw_option): Likewise.
279 (gld_${EMULATION_NAME}_unrecognized_file): Likewise.
280 (set_entry_point): Initial initial_symbol_char dependent to
281 target's default and new option flag pep_leading_underscore.
282 * pe-dll.c (pe_leading_underscore): New flag variable.
283 (pe_detail_list): Remove const to allow modify of
284 member underscore.
285 (pe_dll_id_target): Initialize pe_details' underscore variable
286 dependent to target's default and flag pe_leading_underscore.
287 * pe-dll.h (pe_leading_underscore): Add extern declaration of
288 option flag.
289 * pep-dll.c (pe_leading_underscore): Add alias define for
290 pep_leading_underscore.
291 * pep-dll.h (pep_leading_underscore) Add extern declaration of
292 option flag.
293 * ld.texinfo: Add documentation for --(no-)leading-underscore
294 option.
295
296 2010-03-26 Alan Modra <amodra@gmail.com>
297
298 PR ld/11426
299 * configure.host (many linux targets <HOSTING_CRT0>): Remove edits.
300 (m68*-motorola-sysv <HOSTING_LIBS>): Use here doc, not echo.
301
302 2010-03-25 Joseph Myers <joseph@codesourcery.com>
303
304 * Makefile.am (ALL_EMULATIONS): Add eelf32_tic6x_be.o and
305 eelf32_tic6x_le.o.
306 (eelf32_tic6x_be.c, eelf32_tic6x_le.c): New.
307 * NEWS: Add news entry for TI C6X support.
308 * configure.tgt (tic6x-*-*): New.
309 * emulparams/elf32_tic6x_be.sh, emulparams/elf32_tic6x_le.sh: New.
310
311 2010-03-23 Joseph Myers <joseph@codesourcery.com>
312
313 * scripttempl/elf.sc (RODATA_NAME, SDATA_NAME, SBSS_NAME,
314 BSS_NAME): Define if not already defined. Use in place of some
315 hardcoded section names.
316
317 2010-03-18 H.J. Lu <hongjiu.lu@intel.com>
318
319 * scripttempl/elf.sc (INIT_ARRAY): Re-indent.
320
321 2010-03-18 Aymeric Vincent <vincent@labri.fr>
322
323 PR ld/11384
324 * emultempl/sh64elf.em: Add missing EOF.
325
326 2010-03-18 Doug Semler <dougsemler@gmail.com>
327
328 * pe-dll.c (make_one): Make text section readonly.
329 (make_one): Add *ABS* symbol @feat.00 with value 1 to tag
330 the jump stub on X86 as /SAFESEH compatible for
331 native toolchains.
332
333 2010-03-17 Alan Modra <amodra@gmail.com>
334
335 * ldlang.c (lang_size_sections_1): Remove "s" param. Set "s" from
336 *prev instead. Update all callers.
337
338 2010-03-15 Daniel Jacobowitz <dan@codesourcery.com>
339
340 * ldlang.c (lang_insert_orphan): Place loadable orphans in the same
341 region and phdrs as their placement section.
342
343 2010-03-15 Alan Modra <amodra@gmail.com>
344
345 * emultempl/ppc64elf.em (move_input_section, sort_toc_sections): New.
346 (ppc_before_allocation): Call sort_toc_sections.
347 (no_toc_sort, OPTION_NO_TOC_SORT): New.
348 (PARSE_AND_LIST_PROLOGUE, PARSE_AND_LIST_LONGOPTS,
349 PARSE_AND_LIST_OPTIONS): Handle --no-toc-sort.
350
351 2010-03-14 Alan Modra <amodra@gmail.com>
352
353 PR ld/11378
354 * emultempl/ppc64elf.em (gld${EMULATION_NAME}_after_allocation): Call
355 ppc64_elf_check_init_fini and warn if .init/.fini use different TOCs.
356
357 2010-03-11 George Gensure <werkt0@gmail.com>
358
359 PR ld/11367
360 * ldcref.c (handle_asneeded_cref): Correct copying of refs.
361
362 2010-03-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
363
364 * Makefile.am (ALL_EMULATIONS): Add eelf32_sparc_sol2.o,
365 eelf_i386_sol2.o.
366 (ALL_64_EMULATIONS): Add eelf_x86_64_sol2.o, eelf64_sparc_sol2.o.
367 (eelf32_sparc_sol2.c): New rule.
368 (eelf64_sparc_sol2.c): Likewise.
369 (eelf_x86_64_sol2.c): Likewise.
370 (eelf_i386_sol2.c): Likewise.
371 * Makefile.in: Regenerate.
372 * configure.tgt (i[3-7]86-*-solaris2*): Change targ_emul to
373 elf_i386_sol2.
374 Add elf_i386_ldso, elf_x86_64_sol2 to targ_extra_emuls.
375 (x86_64-*-solaris2*): Change targ_emul to elf_x86_64_sol2.
376 Add elf_x86_64, elf_i386_sol2, elf_i386 to targ_extra_emuls.
377 (sparc-*-solaris2.[0-6]*): Change targ_emul to elf32_sparc_sol2.
378 Add target_extra_emuls.
379 (sparc-*-solaris2*): Change targ_emul to elf32_sparc_sol2.
380 Add elf32_sparc, elf64_sparc_sol2 to targ_extra_emuls.
381 (sparcv9-*-solaris2*): Change targ_emul to elf64_sparc_sol2.
382 Add elf64_sparc, elf32_sparc_sol2 to target_extra_emuls.
383 * emulparams/elf32_sparc_sol2.sh: New file.
384 * emulparams/elf64_sparc_sol2.sh: New file.
385 * emulparams/elf_i386_sol2.sh: New file.
386 * emulparams/elf_x86_64_sol2.sh: New file.
387 * emultempl/solaris2.em: New file.
388
389 2010-02-27 H.J. Lu <hongjiu.lu@intel.com>
390
391 PR ld/11330
392 * ld.texinfo: Replace explicitely with explicitly.
393
394 2010-02-27 Jie Zhang <jie@codesourcery.com>
395
396 * scripttempl/armbpabi.sc: Don't combine .init_array.* or
397 .fini_array.* when do relocatable linking.
398 * scripttempl/elf.sc: Likewise.
399 * scripttempl/elf32sh-symbian.sc: Likewise.
400 * scripttempl/elf64hppa.sc: Likewise.
401 * scripttempl/elfxtensa.sc: Likewise.
402
403 2010-02-26 Alan Modra <amodra@gmail.com>
404
405 * scripttempl/elf.sc (.fini_array): Place input .fini_array after
406 .fini_array.*.
407 * scripttempl/armbpabi.sc: Likewise.
408 * scripttempl/elf32sh-symbian.sc: Likewise.
409 * scripttempl/elf64hppa.sc: Likewise.
410 * scripttempl/elfxtensa.sc: Likewise.
411
412 2010-02-25 Alan Modra <amodra@gmail.com>
413
414 PR ld/11304
415 * ldlang.c (init_os): Remove isec param. Don't check for
416 bfd_section already set or call bfd_init_private_section_data
417 here.
418 (exp_init_os): Update init_os call.
419 (lang_add_section): Tidy. Really don't set SEC_LINK_ONCE
420 flags. Call bfd_init_private_section_data here.
421 (map_input_to_output_sections): Tidy. Update init_os calls.
422 Use os->sectype to select sec flags for lang_data_statement.
423
424 2010-02-23 Alan Modra <amodra@gmail.com>
425
426 PR ld/11304
427 * ldlang.c: Revert last patch.
428
429 2010-02-23 Nick Clifton <nickc@redhat.com>
430
431 * po/bg.po: Updated Bulgarian translation.
432
433 2010-02-22 Alan Modra <amodra@gmail.com>
434
435 PR ld/11304
436 * ldlang.c (exp_init_os): Delete forward declaration.
437 (init_os): Don't check for bfd_section already created and don't
438 init addr_tree and load_base expressions here.
439 (map_input_to_output_sections): Only map input to output sections
440 and set constraints here, and as an exception, create output
441 sections which have their address set. Move all the other code to..
442 (create_other_output_sections): ..here. New function. Handle init
443 of addr_tree and load_base here too.
444 (lang_process): Call create_other_output_sections.
445
446 2010-02-19 Alan Modra <amodra@gmail.com>
447
448 * Makefile.am (eelf32_i960.c): Depend on ELF_GEN_DEPS, not ELF_DEPS.
449 * Makefile.in: Regenerate.
450
451 2010-02-19 Alan Modra <amodra@gmail.com>
452
453 * ldlang.c (unique_section_p): Add os param. Allow group
454 sections to match /DISCARD/. Update all callers.
455 * emultempl/genelf.em (gld${EMULATION_NAME}_before_allocation): New.
456 (LDEMUL_BEFORE_ALLOCATION): Define.
457
458 2010-02-15 Nick Clifton <nickc@redhat.com>
459
460 * po/vi.po: Updated Vietnamese translation.
461
462 2010-02-10 Richard Sandiford <r.sandiford@uk.ibm.com>
463
464 * Makefile.am (CFILES): Add ldlex-wrapper.c.
465 (OFILES): Replace ldlex.c with ldlex-wrapper.c.
466 (ldlex.o): Replace with...
467 (ldlex-wrapper.o): ...this new rule.
468 (EXTRA_ld_new_SOURCES): Add ldlex.l.
469 (ld_new_SOURCES): Replace ldlex.l with ldlex-wrapper.c.
470 * Makefile.in: Regenerate.
471 * ldlex.l (sysdep.h): Don't include here.
472 * ldlex-wrapper.c: New file.
473
474 2010-02-09 Alan Modra <amodra@gmail.com>
475
476 * emultempl/ppc64elf.em (ppc_before_allocation): Update for changed
477 function parameters.
478
479 2010-02-05 Nick Clifton <nickc@redhat.com>
480
481 * configure.in (ALL_LIBGUAS): Add bg.
482 * configure: Regenerate.
483 * po/bg.po: New Bulgarian translation.
484
485 2010-02-05 Ryan Mansfield <rmansfield@qnx.com>
486
487 * emultempl/armelf.em (PARSE_AND_LIST_OPTIONS): Fix help for
488 --target1-abs and --target1-rel options.
489
490 2010-02-03 Nick Clifton <nickc@redhat.com>
491
492 * emultempl/alphaelf.em: Update value expected from elf_object_id.
493 * emultempl/hppaelf.em: Likewise.
494 * emultempl/mipself.em: Likewise.
495 * emultempl/ppc32elf.em: Likewise.
496 * emultempl/ppc64elf.em: Likewise.
497
498 2010-02-03 Alan Modra <amodra@gmail.com>
499
500 * emultempl/ppc64elf.em (build_toc_list): Report errors from
501 ppc64_elf_next_toc_section.
502 (after_allocation): Update for changed function names and params.
503 Run second pass of multitoc partitioning.
504
505 2010-01-21 Jon Grant <jg@jguk.org>
506 Nick Clifton <nickc@redhat.com>
507
508 PR 4437
509 * ldfile.c: (ldfile_open_file): Do not stop link upon encountering
510 a missing file or library. Instead mark the entry as missing and
511 set the global flag to indicate that missing files were
512 encountered.
513 * ldlang.c (missing_files): New exported variable.
514 (load_symbols): Skip loading if the file is missing.
515 (open_input_bfds): Terminate link if any input files were
516 missing.
517 * ldlang.h (struct lang_input_statement_struct): Add missing_file
518 field.
519 Add export of missing_file variable.
520
521 2010-01-13 DJ Delorie <dj@redhat.com>
522
523 * emultempl/elf32.em (_place_orphan): If an input section doesn't
524 match an existing output section, but an unused output section
525 statement does match, use it.
526 * emultempl/pe.em (_place_orphan): Likewise.
527 * emultempl/pep.em (_place_orphan): Likewise.
528
529 2010-01-09 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
530
531 * configure: Regenerate.
532 * Makefile.in: Regenerate.
533
534 2010-01-08 H.J. Lu <hongjiu.lu@intel.com>
535
536 * ldver.c (ldversion): Change to "Copyright 2010".
537
538 2010-01-08 Alan Modra <amodra@gmail.com>
539
540 PR 11107
541 * emultempl/vxworks.em: Expand tr arguments to suit non-GNU tr.
542
543 For older changes see ChangeLog-2009
544 \f
545 Local Variables:
546 mode: change-log
547 left-margin: 8
548 fill-column: 74
549 version-control: never
550 End: