3 * ldemul.c (ldemul_add_options, ldemul_handle_option): New functions.
4 (ldemul_parse_args): Return bfd_boolean. Formatting.
5 * ldemul.h (ldemul_add_options, ldemul_handle_option): Declare.
6 (ldemul_parse_args): Adjust.
7 (struct ld_emulation_xfer_struct): Add add_options and handle_option.
8 Return bfd_boolean from parse_args.
9 * lexsup.c (parse_args): Malloc shortopts, longopts and
10 really_longopts. Call ldemul_add_options and ldemul_handle_option.
11 * emultempl/aix.em (gld${EMULATION_NAME}_add_options): Split out from
12 gld${EMULATION_NAME}_parse_args.
13 (gld${EMULATION_NAME}_handle_option): Likewise.
14 (ld_${EMULATION_NAME}_emulation): Adjust initializer.
15 * emultempl/armcoff.em: As for aix.em, but remove parse_args.
16 * emultempl/beos.em: Likewise.
17 * emultempl/pe.em: Likewise.
18 * emultempl/ticoff.em: Likewise.
19 * emultempl/elf32.em: Likewise. Don't duplicate long options either.
20 (gld${EMULATION_NAME}_add_sysroot): Prototype.
21 * emultempl/armelf.em (PARSE_AND_LIST_LONGOPTS): Don't duplicate
23 * emultempl/hppaelf.em (PARSE_AND_LIST_LONGOPTS): Likewise.
24 * emultempl/ppc32elf.em (PARSE_AND_LIST_LONGOPTS): Likewise.
25 * emultempl/ppc64elf.em (PARSE_AND_LIST_LONGOPTS): Likewise.
26 * emultempl/armelf_oabi.em (ld_${EMULATION_NAME}_emulation): Adjust
28 * emultempl/generic.em: Likewise.
29 * emultempl/gld960.em: Likewise.
30 * emultempl/gld960c.em: Likewise.
31 * emultempl/linux.em: Likewise.
32 * emultempl/lnk960.em: Likewise.
33 * emultempl/m68kcoff.em: Likewise.
34 * emultempl/mipsecoff.em: Likewise.
35 * emultempl/sunos.em: Likewise.
36 * emultempl/vanilla.em: Likewise.
37 * emultempl/netbsd.em (gldnetbsd_before_parse): Prototype.
41 * emultempl/elf32.em (gld${EMULATION_NAME}_add_sysroot): Fix
42 memory allocation error.
44 * Makefile.am (ldmain.o): Define TOOLBINDIR.
45 * Makefile.in: Rebuilt.
46 * ldmain.c (ld_sysroot): Try to set from TOOLBINDIR too.
50 * ldlang.c (lang_size_sections_1): Add CHECK_REGIONS argument and only
51 call os_region_check when it is set.
52 (lang_size_sections): Add CHECK_REGIONS argument and pass it through to
54 (lang_process): Change lang_size_sections calls to set CHECK_REGIONS
55 only for the last call, not on every relaxation iteration.
56 * ldlang.h (lang_size_sections): Update prototype.
57 * pe-dll.c (pe_dll_fill_sections): Set CHECK_REGIONS argument in calls
58 to lang_size_sections.
59 (pe_exe_fill_sections): Likewise.
60 * emultempl/elf32.em (gld${EMULATION_NAME}_finish): Likewise.
61 * emultempl/hppaelf.em (hppaelf_layout_sections_again): Likewise.
62 * emultempl/ppc64elf.em (ppc_before_allocation): Likewise.
63 (ppc_layout_sections_again): Likewise.
67 * gen-doc.texi: Set ARM and HPPA variables.
68 * ld.texinfo: Fix typos and obvious texinfo mistakes. Make section
69 title capitalization more consistent. Add missing menu entries for
70 machine-specific sections and conditionalize them consistently.
71 Conditionalize text that is irrelevant when SingleFormat is set.
72 Add @group divisions to improve page breaks in long examples.
73 Use @iftex/@ifnottex instead of @iftex/@ifinfo so that HTML output
74 is correct. Remove "FIXME" comment about not using
75 @raisesections/@lowersections. Use @raisesections/@lowersections
76 consistently for machine-specific sections. Change to be more polite
77 about poor bug reports. Replace FDL appendix with include of fdl.texi.
78 Move WIN32 node to match its order in the menus.
83 * configure.in (TARGET_SYSTEM_ROOT): Set default to
84 ${exec_prefix}/${target_alias}/sys-root. Match explicit
85 '${exec_prefix}' (in addition to the expansion thereof) as
91 * ldgram.y (vers_defns): Also recurse with 'EXTERN NAME' patterns.
95 * ldgram.y (vers_defns): Allow optional trailing semicolon in
100 * emultempl/ppc32elf.em: New file.
101 * emulparams/elf32ppc.sh (EXTRA_EM_FILE): Define.
102 * Makefile.am (eelf32lppc.c): Depend on emultempl/ppc32elf.em.
103 (eelf32lppcnto.c): Likewise.
104 (eelf32lppcsim.c): Likewise.
105 (eelf32ppcnto.c): Likewise.
106 (eelf32ppc.c): Likewise.
107 (eelf32ppc_fbsd.c): Likewise.
108 (eelf32ppcsim.c): Likewise.
109 (eelf32ppclinux.c): Likewise.
110 * Makefile.in: Regenerate.
114 * ld.texinfo: Remove spaces between @samp and opening brace.
118 * emultempl/ppc64elf.em (ppc_create_output_section_statements): Check
120 (ppc_before_allocation): Don't do optimizations if wrong hash table.
121 (gld${EMULATION_NAME}_finish): Ditto.
125 * ldmain.c (main) Default allow_shlib_undefined to true.
126 * lexsup.c (ld_options): Add --no-allow-shlib-undefined.
127 (parse_args): Parse the new switch.
128 * ld.texinfo: Document new switch and default behaviour of
129 allowing undefined symbols in shared libraries.
133 * scripttempl/elf32msp430.sc: Add new data anchors definitions.
134 * scripttempl/elf32msp430_3.sc: Likewise.
138 * configure.tgt: Add support for kaOS as cross build target
143 * hppaelf.em (group_size): Change default back to 1.
147 * emultempl/ppc64elf.em: Add "no-tls-optimize" option and support code.
151 * hppaelf.em (group_size): Change default to -1.
155 * emultempl/armelf.em (PARSE_AND_LIST_SHORTOPTS): Remove 'n' short
157 (PARSE_AND_LIST_LONGOPTS): Add duplicate entry for
158 no-pipeline-knowledge. This will prevent the getopt package from
159 thinking that there are any shorter abbreviations for
160 --no-pipeline-knowledge.
164 * genscripts.sh (LIB_PATH): Don't append LIBPATH_SUFFIX to paths
165 which already have it. Avoid duplicates.
169 * emulparams/elf64_s390.sh (LIBPATH_SUFFIX): Set to 64.
170 * emulparams/elf_x86_64.sh (LIBPATH_SUFFIX): Likewise.
171 * emulparams/elf64_sparc.sh (LIBPATH_SUFFIX): Set instead of suffix.
175 * emultempl/ppc64elf.em (ppc_before_allocation): Size sections then
176 call ppc64_elf_tls_optimize.
180 * emultempl/elf32.em: Move gld${EMULATION_NAME}_add_sysroot
181 outside of GNU/Linux conditional.
185 * deffilep.y (def_get_module): New function: locate an already
187 * deffile.h (def_get_module): New prototype.
188 * pe-dll.c (pe_implied_import_dll): Add code to prevent importing
189 a dll multiple times.
193 * emultempl/sh64elf.em: Include elf32-sh64.h.
194 (sh64_elf_${EMULATION_NAME}_before_allocation): Adjust for changed
195 sh64_elf_section_data.
196 (sh64_elf_${EMULATION_NAME}_after_allocation): Likewise.
200 * ld.texinfo: Remove an extra "i" in --dll-search-prefix.
201 * emultempl/pe.em (gld_${EMULATION_NAME}_list_options): Move a
202 cross-80th-column-margin "an" to the next line.
206 * emulparams/tic3xcoff-onchip.sh: Rename to ...z
207 * emulparams/tic3xcoff_onchip.sh: ...this.
208 * Makefile.am (etic3xcoff_onchip.c): Fix name of generated C file.
209 * Makefile.in: Regenerate.
213 * configure.tgt: Handle i[3456]86-*-aros*
217 * Makefile.am: Added etic3xcoff.o and etic4xcoff_onchip.o
218 * Makefile.in: Regenerate
219 * configure.tgt: Added extra target emulations
220 * emulparams/tic3xcoff.sh: Remove old settings
221 * emulparams/tic4xcoff.sh: Ditto
222 * emulparams/tic3xcoff-onchip.sh: Added new
223 * scripttempl/tic4xcoff.sc: Revise and combine both c3x and c4x
224 * scripttempl/tic3xcoff.sc: Remove
228 * emultempl/elf32.em (gld${EMULATION_NAME}_add_sysroot): Do not
233 * Makefile.in: Regenerate.
237 * ld/ld.texinfo (node WIN32): Some clarifications
238 and formatting fixups.
242 * ldmain.c (get_emulation): Sort -mipsNN checks in the usual
243 order, and handle (ignore) -mips32r2.
247 * ldmain.c (main): Make sure ld_sysroot is initialized.
251 * Makefile.am (eelf32iq10.c): Fix tab/whitespace mixup.
253 * Makefile.am (ldmain.o): Add @TARGET_SYSTEM_ROOT_DEFINE@.
254 (GENSCRIPTS): Add @use_sysroot@.
255 * Makefile.in: Regenerated.
256 * configure.host: Move setting of NATIVE_LIB_DIRS to...
257 * configure.tgt: ... here. Use ${target} instead of ${host}
259 * configure.in: Add --with-sysroot.
260 * configure: Regenerated.
261 * genscripts.sh: Accept use_sysroot option. Set new variables
262 NATIVE and USE_LIBPATH. Prepend "=" to directory names if
263 $use_sysroot. Don't search $tool_lib if $use_sysroot.
264 * ldfile.c (ldfile_add_library_path): Handle leading '='.
265 * ldmain.c (TARGET_SYSTEM_ROOT): Define if not defined.
266 (ld_sysroot): New variable.
267 (main): Initialize ld_sysroot.
268 * ldmain.h (ld_sysroot): New extern.
269 * emultempl/elf32.em: Use NATIVE and USE_LIBPATH instead of
270 searching $EMULATION_LIBPATH.
271 (gld${EMULATION_NAME}_add_sysroot): New function.
272 (gld${EMULATION_NAME}_check_ld_so_conf): Use it. Honor ld_sysroot.
273 (gld${EMULATION_NAME}_after_open): Likewise. Only search
274 environment variables if $NATIVE.
275 * ld.texinfo (Options): Mention "=" prefix in the description of -L.
276 * NEWS: Mention --with-sysroot.
278 * emulparams/elf32bmipn32-defs.sh: Set NATIVE and LIBPATH_SUFFIX
279 instead of setting LIB_PATH.
280 * emulparams/elf32ppc.sh: Likewise.
281 * emulparams/elf64_s390.sh: Likewise.
282 * emulparams/elf64_sparc.sh: Likewise.
283 * emulparams/elf64ppc.sh: Likewise.
284 * emulparams/elf_x86_64.sh: Likewise.
286 * emulparams/elf64_aix.sh: Add "=" prefixes to LIB_PATH.
287 * emulparams/elf64hppa.sh: Add "=" prefixes to LIB_PATH.
291 * ld/pe-dll.c (autofilter_symbollist): Add cygwin_crt0.
295 * Makefile.am (ldmain.o): Pass BINDIR.
296 * Makefile.in: Regenerated.
297 * ldmain.c (set_scripts_dir): Use make_relative_prefix for the first
302 * Makefile.am (ALL_EMULATIONS): Add eelf32iq2000.o.
303 (eelf32iq2000.c): New target.
304 * Makefile.in: Regenerate.
305 * configure.tgt: Handle iq2000-*-elf.
306 * emulparams/elf32iq10.sh: New file.
307 * emulparams/elf32iq2000.sh: New file.
308 * scripttempl/iq2000.sc: New file.
312 * pe-dll.c (autofilter_symbollist): Add do_pseudo_reloc
313 and _pei386_runtime_relocator to the exclude list.
317 * ldfile.c: Fix comment typos.
318 * ldlang.c: Likewise.
320 * pe-dll.c: Likewise.
325 * Makefile.am (ld.1): Depend on configdoc.texi
327 * Makefile.in: Regenerated.
331 * Makefile.am: Add msp430 target.
332 * configure.tgt: Likewise.
333 * Makefile.in: Regenerate.
334 * emulparams/msp430x???.sh: New files. Linker script parameters
335 for various msp430 configurations.
336 * gen-doc.texi: Enable msp430 documenation.
337 * ld.texinfo: Document msp430 sections.
338 * scripttempl/elf32msp430.sc: New file. Linker script for msp430.
339 * scripttempl/elf32msp430_3.sc: New file. Linker script for msp430.
344 * ld/config.in (HAVE_REALPATH): New entry.
345 (HAVE_SYS_STAT_H, HAVE_SYS_TYPES_H): Removed: obsolete.
349 * ld.texinfo: New win32 topics: 'symbol aliasing' and 'export dll
354 * ldmain.c (main): Init "strip_discarded".
355 * lexsup.c (OPTION_STRIP_DISCARDED): Define.
356 (OPTION_NO_STRIP_DISCARDED): Define.
357 (ld_options): Add "strip-discarded" and "no-strip-discarded".
358 (parse_args): Handle them.
362 * ld.h (struct args_type): Add new field
363 'accept_unknown_input_architecture'.
364 * ldmain.c (main): Initialise 'accept_unknown_input_architecture'
366 * ldlang.c (lang_check): Pass accept_unknown_input_architecture to
367 bfd_arch_get_compatible.
368 * ldfile.c (ldfile_try_open_bfd): Likewise.
369 * lexsup.c (ld_options): Add new command line switch
370 --accept-unknown-input-architecture and its inverse.
371 (parse_args): Handle --accept-unknown-input-architecture.
372 * ld.texinfo: Document new linker option.
373 * NEWS: Mention new linker option.
377 * ldmain.c (main): Re-order link_info initialization. Init all
382 * ld.texinfo: Clarify and extend the documentation
383 in the Machine Dependent, WIN32 section.
387 * ld.texinfo: Add win32 machine depending section.
388 * gen-doc.texi: Enable win32 machine depending section.
390 * configure.host: Add win32 library search path.
394 * ld/emultempl/pe.em (pe_find_data_imports): Don't search for data
395 import when auto-import is disabled.
399 * emultempl/pe.em (..._recognized_file): Use LD_PATHMAX+1 to
400 account for trailing '\0'.
404 * emultempl/pe.em (longopts): Duplicate entry for --compact-implib
405 so that it is not confused with -c.
410 * configure.in: Add check for realpath function.
411 * configure: Regenerate.
412 * config.in: Regenerate.
413 * aclocal.m4: Regenerate.
414 * deffile.h: Add .data field to def_file_import
416 * pe-dll.c (pe_proces_import_defs): Use .data field of
417 def_file_import structure to initialize flag_data field of
418 def_file_export structure.
419 (pe_implied_import_dll): New variables exp_funcbase and
420 [data|bss]_[start|end]. Use DLL's internal name to set dll_name,
421 not filename (which may be a symlink). Scan the sections and
422 initialize [data|bss]_[start|end]. When scanning the export
423 table, skip _nm_ symbols, and mark any symbols whose rva indicates
424 that it is in the .bss or .data sections as data.
425 * sysdep.h: Include limits.h and sys/param.h, and define
426 LD_PATHMAX as appropriate. Also define REALPATH as realpath if it
427 exists, NULL otherwise.
428 * emultempl/pe.em (gld_${EMULATION_NAME}_after_open): Call
429 pe_process_import_defs before pe_find_data_imports, so that
430 auto-import will check the virtual implib as well as "real"
432 (gld_${EMULATION_NAME}_recognized_file): Use REALPATH to follow
433 symlinks to their target; check that the target's extension is
434 .dll before calling pe_implied_import_dll(), not the filename
435 itself (which may be a symlink).
439 * emultempl/elf32.em (struct orphan_save): Add os_tail field.
440 (gld${EMULATION_NAME}_place_orphan): Re-order output_section_statement
445 * ldlang.h: Formatting.
449 * ldlang.c (init_os): Ensure sections mentioned in load_base
454 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Set
455 load_base for orphans that follow a section with load_base set.
459 * ld.texinfo: Remove the extra `;' in sample version script.
463 * configure.host: Correct dynamic-linker for powerpc64 hosts.
465 * Makefile.am (eelf32ppcwindiss.c): Correct dependencies.
466 * Makefile.in: Regenerate.
468 * ld.h, ldcref.c, ldctor.c, ldctor.h, ldemul.c, ldemul.h, ldexp.c,
469 ldexp.h, ldfile.c, ldfile.h, ldgram.y, ldlang.c, ldlang.h, ldmain.c,
470 ldmain.h, ldmisc.c, ldwrite.c, lexsup.c, mri.c, pe-dll.c, pe-dll.h,
471 emulparams/elf32b4300.sh, emultempl/aix.em, emultempl/armcoff.em,
472 emultempl/armelf.em, emultempl/armelf_oabi.em, emultempl/beos.em,
473 emultempl/elf32.em, emultempl/generic.em, emultempl/gld960.em,
474 emultempl/gld960c.em, emultempl/hppaelf.em, emultempl/linux.em,
475 emultempl/lnk960.em, emultempl/m68kcoff.em, emultempl/mipsecoff.em,
476 emultempl/mmix-elfnmmo.em, emultempl/mmixelf.em, emultempl/mmo.em,
477 emultempl/needrelax.em, emultempl/pe.em, emultempl/ppc64elf.em,
478 emultempl/sh64elf.em, emultempl/sunos.em, emultempl/ticoff.em: Replace
479 boolean with bfd_boolean, true with TRUE, false with FALSE. Simplify
480 comparisons of bfd_boolean vars with TRUE/FALSE. Formatting.
484 * configure.host: Fix generic FreeBSD configuration entry.
488 * ld.texinfo: Add the missing `;' to sample version scripts.
492 * emulparams/elf64ppc.sh (SEGMENT_SIZE): Don't define.
496 * ldmain.c (main): Make runtime relocs disabled by default. Remove
497 assignment which has no effect.
498 * pe-dll.h (pe_create_import_fixup): Change prototype.
499 * pe-dll.c (make_runtime_pseudo_reloc): New function.
500 (pe_create_runtime_relocator_reference): Ditto.
501 (pe_create_import_fixup): Handle relocations with non-zero addends.
502 * emultempl/pe.em: Add options --enable-runtime-pseudo-reloc and
503 --disable-runtime-pseudo-reloc.
504 (make_import_fixup): Handle relocations with non-zero addends. Create
505 an external reference to _pei386_runtime_relocator symbol if at least
506 one pseudo reloc was created.
507 * ld.texinfo: Document --enable-runtime-pseudo-reloc and
508 --disable-runtime-pseudo-reloc options.
512 * ldlang.c (lang_add_section): Discard debugging sections that have
513 been marked SEC_EXCLUDE.
517 * configure.in (ALL_LINGUAS): Add da.
518 * configure: Regenerate.
519 * po/da.po: New Danish translation.
523 * emultempl/ppc64elf.em (ppc_before_allocation): New function.
524 (LDEMUL_BEFORE_ALLOCATION): Define.
525 (gld${EMULATION_NAME}_finish): Run discard_info for relocatable
527 * emultemp/hppaelf.em ((gld${EMULATION_NAME}_finish): Likewise.
531 * configure.tgt (LIB_PATH): Default to searching w32api directory under
536 * pe-dll.c (autofilter_liblist): add libmingwex and libgcj to the list
537 of restricted auto-export libs.
541 * pe-dll.c (autofilter_liblist): Generalize library names to catch more
542 creative library naming instances like, e.g., libstdc++-2.a.
546 * emulparams/elf32btsmipn32.sh (TEXT_DYNAMIC): Define.
547 * emulparams/elf64btsmip.sh (TEXT_DYNAMIC): Likewise.
551 * deffilep.y (def_lex): Handle '@' as first character of an ID.
552 * pe-dll.c (auto-export): Filter on "_imp_" prefix, not "_imp__".
553 (make_one): Don't prefix decorated fastcall symbols with '_'.
554 (pe_process_import_defs): Likewise.
555 * emultempl/pe.em (pe_fixup_stdcalls): Don't fixup fastcall
556 symbols to cdecl names or vise-versa.
560 * pe-dll.c (process_def_file): Handle fastcall symbols when
561 generating undecorated aliases. Don't prefix decorated fastcall
563 (fill_exported_offsets): Don't prefix decorated fastcall symbols
568 * emultempl/aix.em: Use include <> for generated headers.
569 * emultempl/beos.em: Likewise.
570 * emultempl/elf32.em: Likewise.
571 * emultempl/pe.em: Likewise.
572 * ldctor.c: Likewise.
574 * ldfile.c: Likewise.
575 * ldlang.c: Likewise.
578 * ldmain.c: Likewise.
579 * ldmisc.c: Likewise.
580 * ldwrite.c: Likewise.
581 * lexsup.c: Likewise.
583 * pe-dll.c: Likewise.
587 * emultempl/elf32.em (place_orphan): Don't put non-allocated .rel*
588 sections into .rel{,a}.dyn.
592 * lexsup.c (OPTION_NO_OMAGIC): Define.
593 (ld_options): Add "no-omagic" option.
594 (parse_args): Parse --no-omagic.
595 * ld.texinfo: Document --no-omagic.
596 * NEWS: Mention new option.
600 * scripttempl/pe.sc (__RUNTIME_PSEUDO_RELOC_LIST__,
601 __RUNTIME_PSEUDO_RELOC_LIST_END__): Add only when relocating.
605 * emulparams/elf32bmipn32-defs.sh: Set ELFSIZE according to
606 emulation name. Set LIB_PATH only for native tools, and
607 search the ABI-specific versions of NATIVE_LIB_DIRS before the
608 .../lib variants, not instead of them. Mostly copied from...
609 * emulparams/elf32ppc.sh: ... here. Fixed typo.
610 * emulparams/elf64bmip-defs.sh: Backed out.
611 * emulparams/elf64bmip.sh: Import elf32bmipn32-defs.sh again.
612 * emulparams/elf64btsmip.sh: Likewise.
613 (DATA_ADDR, NONPAGED_TEXT_START_ADDR, SHLIB_TEXT_START_ADDR,
614 TEXT_DYNAMIC): Removed.
618 * emulparams/elf32bmipn32-defs.sh (LIB_PATH): Set to /usr/lib32.
619 (GENERATE_SHLIB_SCRIPT): Set to yes.
620 (EXECUTABLE_SYMBOLS, WRITABLE_RODATA): Moved to...
621 * emulparams/elf32bmipn32.sh: here.
622 (GENERATE_SHLIB_SCRIPT): Deleted as redundant.
623 * emulparams/elf32btsmipn32.sh: Delete redundant unsets.
624 * emulparams/elf64bmip-defs.sh: New file. Extend
625 elf32bmipn32-defs.sh by overiding ELFSIZE and LIB_PATH.
626 * emulparams/elf64bmip.sh: Bring in definitions from
628 (ELFSIZE, GENERATE_SHLIB_SCRIPT, LIB_PATH): Delete redundant
630 (WRITABLE_RODATA): Moved from elf32bmipn32-defs.sh.
631 * emulparams/elf64btsmip.sh: Bring in definitions from
633 (ELFSIZE, GENERATE_SHLIB_SCRIPT): Delete, redundant.
634 (EXECUTABLE_SYMBOLS, WRITABLE_RODATA): Delete redundant unsets.
638 * configure.tgt (s390x-*-linux*): Add elf_s390 emulation.
639 (s390-*-linux*): Add elf64_s390 emulation if want64.
640 * emulparams/elf64_sparc.sh (LIB_PATH): Update to match 2002-05-22
641 genscript.sh changes.
642 * emulparams/elf_x86_64.sh (LIB_PATH): Likewise.
643 * emulparams/elf64_s390.sh (LIB_PATH): Set up native 64 bit dirs.
647 * ldlang.c (load_symbols): Revert last change.
651 * ldlang.c (load_symbols): Don't call bfd_link_add_symbols when
653 (lang_reasonable_defaults): Don't compare against false.
654 (size_input_section): Likewise.
655 (lang_size_sections_1): Likewise.
656 (lang_do_assignments): Likewise.
657 (lang_add_output): Likewise.
659 * Makefile.am: Run "make dep-am".
660 * Makefile.in: Regenerate.
661 * ldver.c: #include "bfdver.h".
665 * scripttempl/elfm68hc11.sc: Use KEEP for .vectors, .installN,
667 * scripttempl/elfm68hc12.sc: Likewise.
671 * pe-dll.c (make_import_fixup_mark): Avoid type-punned pointer.
673 * ldgram.y (memory_spec): Provide empty action.
674 (section <NAME>): Likewise.
678 * ldfile.c (ldfile_try_open_bfd): When searching skip linker scripts if
679 they have OUTPUT_FORMAT not matching actual output format.
680 * ldlang.c (lang_get_output_target): New function.
681 (open_output): Use it.
682 * ldlang.h (lang_get_output_target): New prototype.
686 * emultempl/elf32.em (output_rel_find): Prefer .rel script sections
687 when orphan is .rel, .rela when orphan is .rela.
688 (gld${EMULATION_NAME}_place_orphan): Handle combreloc .rel* case
689 first. Remove outsecname var.
694 * Makefile.am: Add eshelf32_linux.o and
695 eshlelf32_linux.o, new emulations for sh64 Linux.
696 * Makefile.in: Regenerate.
697 * configure.tgt: Add sh64eb-*-linux* and sh64-*-linux* emulations.
698 * emulparams/shelf32_linux.sh: New file.
699 * emulparams/shlelf32_linux.sh: New file.
703 * ldlang.c (lang_file_exist): Removed.
704 (new_afile): Revert the last change.
705 * ldlang.h (lang_file_exist): Removed.
706 * lexsup.c (parse_args): Revert the last change.
710 * pe-dll.cc (autofilter_symbolprefixlist): Don't re-export
712 (make_one): Create _nm_<symbol> for data only.
716 * ldlang.c (lang_file_exist): New function.
717 (new_afile): Abort if the filename to be added matches the linker
719 * ldlang.h: Add prototype for lang_file_exist.
720 * lexsup.c (parse_args): Abort if the output filename matches
721 one of the input filenames.
725 * emulparams/elf64ppc.sh (MAXPAGESIZE): Set to 0x10000.
729 * scripttempl/elfd30v.sc: Order reloc sections placing .plt last.
730 * scripttempl/elfm68hc11.sc: Likewise.
731 * scripttempl/elfm68hc12.sc: Likewise.
733 * emultempl/elf32.em (output_rel_find): Always place orphan loadable
734 reloc sections just before .rel.plt/.rela.plt.
735 (gld${EMULATION_NAME}_place_orphan <.rel>): Remove combreloc code.
736 Only put loadable reloc sections in hold_rel.
740 * emulparams/elf32ppc.sh (OTHER_GOT_RELOC_SECTIONS): New.
745 * scripttempl/sh.sc: Handle .eh_frame* and .gcc_exc*
750 * genscripts.sh (SEGMENT_SIZE): Use MAXPAGESIZE before
752 * scripttempl/elf.sc (DATA_SEGMENT_ALIGN): Incorporate
753 SEGMENT_SIZE alignment.
754 * emulparams/elf64ppc.sh (DATA_ADDR): Delete.
755 (SEGMENT_SIZE): Define.
757 * ldexp.c (fold_unary): New. Split out from exp_fold_tree.
758 (fold_binary): Correct abs - non-abs case.
759 (fold_trinary): New. Split out from exp_fold_tree.
763 * emulparams/elf64ppc.sh (DATA_ADDR): Define.
764 * emulparams/elf64_aix.sh (DATA_ADDR): Don't use a fixed address
765 for start of .data, instead align up to 256M boundary.
766 * scripttempl/aix.sc: Likewise.
770 * scripttempl/i386go32.sc: Handle bss unique sections.
774 * ldmisc.c (vfinfo <%C,%D,%G>): Always output bfd, section and offset.
778 * emulparams/elf32bmipn32-defs.sh: New file.
779 * emulparams/elf32bmipn32.sh: Use elf32bmipn32-defs.sh.
780 * emulparams/elf32btsmipn32.sh: Likewise.
781 * emulparams/elf64bmip.sh: Likewise.
782 * emulparams/elf64btsmip.sh: Likewise.
786 * emulparams/elf_i386_fbsd.sh: Set OUTPUT_FORMAT to
788 * emulparams/elf64alpha_fbsd.sh: Set OUTPUT_FORMAT to
793 * NEWS: New TI port supports both C4x and C3x series of DSPs.
795 * po/tr.po: Updated Turkish translation.
799 * configure.tgt (h8300-*-hms*, h8500-*-hms*): Restore.
803 * scripttempl/v850.sc: Add EXTERN references to __ctbpm __gp and
805 * emulparams/v850.sh (TEMPLATE_NAME): Define.
809 * scripttempl/elfd10v.sc (MEMORY): Remove UNIFIED, it is not
810 used. Change INSN to start at 0x01000000 and extend for
811 256K (ignoring holes). Start the STACK on a word aligned
813 (.rodata): Start it at the READONLY_START_ADDR.
817 * emulparams/elf32ppc.sh (ARCH): Set to "powerpc:common".
821 * Makefile.am: Add etic4xcoff.o in ALL_EMULATIONS list and
822 added makefile targets for this file.
823 * Makefile.in: Regenerate.
824 * configure.tgt: Added tic4x-coff and c4x-coff emulations.
825 * NEWS: Mention new port.
829 * emulparams/tic3xcoff.sh: New file.
830 * emulparams/tic4xcoff.sh: New file.
831 * scripttempl/tic3xcoff.sc: New file.
832 * scripttempl/tic4xcoff.sc: New file.
836 * emultempl/aix.em (gld${EMULATION_NAME}_parse_args): Replace strtoll,
837 strtoul and strtoull with bfd_scan_vma.
838 (gld${EMULATION_NAME}_read_file): Likewise.
842 * configure.tgt: Remove h8[35]00-*-hms*. Add h8500-*-rtems*.
846 * scripttempl/pe.sc: Handle .rdata_runtime_pseudo_reloc sections.
847 Add symbols for application to access them.
851 * emultempl/armelf.em: Revert this patch, it is not needed.
857 * configure.in: added --with-lib-path argument to ld's configure
859 * ld/NEWS: Document new switch.
860 * ld/README: Mention new switch.
861 * configure: Regenerate.
862 * Makefile.in: Regenerate.
867 * Makefile.in (LIB_PATH): Make configurable.
868 (GENSCRIPTS): Set LIB_PATH in environment.
869 * configure.in: Substitute LIB_PATH.
873 * emultempl/armelf.em: Include elf-bfd.h and elf/arm.h.
874 (arm_elf_finish): Set the last bit of DT_INIT and DT_FINI
875 depending on the type of the function.
876 (arm_elf_convert_thumb_symbol_to_address): New function.
880 * Makefile.am: Add esh{l}elf_nto.o files.
881 * Makefile.in: Regenerate.
882 * configure.tgt: Add support for sh-**-nto* targets.
883 * emulparams/shelf_nto.sh: New file.
884 * emulparams/shlelf_nto.sh: New file.
888 * ldlang.c (offsetof): Define if not defined.
892 * configure.tgt: Always enable 64bit emulations for 32bit
897 * emulparams/elf32_dlx.sh (TARGET_PAGE_SIZE): Set to 1.
898 (MAXPAGESIZE): Set to 1.
900 * ld.h (ALIGN_N): Delete.
901 * ldexp.h (align_n): Declare.
902 * ldexp.c (align_n): New function.
903 (fold_binary): Use align_n instead of ALIGN_N.
904 (exp_fold_tree): Likewise.
905 * ldlang.c (lang_size_sections_1): Likewise.
906 (lang_one_common): Likewise.
907 * ld.texinfo (ALIGN): Remove power of 2 restriction.
911 * configure.tgt: Add support for powerpc{le}-*-nto* targets.
912 * Makefile.am: Add eelf32{l}ppcnto.o files.
913 * Makefile.in: Regenerate.
914 * emulparams/elf32lppcnto.sh: New file.
915 * emulparams/elf32ppcnto.sh: New file.
919 * ld.texinfo: Document --no-undefined-version.
921 * ldlang.c (lang_new_vers_pattern): Set the `symver' and
922 `script.' fields to 0.
924 * ldmain.c (main): Initialize the allow_undefined_version to
927 * lexsup.c (OPTION_NO_UNDEFINED_VERSION): New.
928 (ld_options): Add --no-undefined-version.
929 (parse_args): Support OPTION_NO_UNDEFINED_VERSION.
933 * emultempl/armelf.em (arm_elf_before_allocation): Only search for
934 an interworking bfd if there are input bfds. (107501)
938 * emultempl/aix.em (gld*_before_parse): Set default arch. Reverts
943 * emulparams/armelf.sh: Revert previous delta.
944 * scripttempl/elf.sc: Revert previous delta.
948 * configure.tgt (powerpc*-*-linux*): Enable elf64ppc for
953 * configure.tgt: Enable x86-64 emulation for Linux/i386 if
954 64bit BFD is selected.
958 * configure.tgt: Enable 64bit emulations for 32bit Linux/mips
959 if 64bit BFD is selected.
963 * emultempl/netbsd.em (LDEMUL_BEFORE_PARSE): New file to custom set
964 link_info.common_skip_ar_aymbols.
965 * emulparams/ns32knbsd.sh (EXTRA_EM_FILE): Refer to extra file.
967 * ldmain.c (main): Initialize new field
968 link_info.common_skip_ar_aymbols.
972 * emulparams/armelf.sh (OTHER_PLT_SECTIONS): New variable. Set it
974 * scripttempl/elf.sc: Comment it. Use the same way as ${PLT} is
979 * NEWS: Retroactively add entry for Lars Brinkhoff's contribution
980 of the PDP-11 and 2.11BSD a.out support.
984 * Makefile.am (eelf32btsmipn32.o, eelf32ltsmipn32.o): New emulations
986 * Makefile.in: Regenerate.
987 * configure.tgt (mips64*el-*-linux-gnu*,mips64*-*-linux-gnu*): Add
988 n32 ABI emulations for these 64 bit targets.
989 * emulparams/elf32bmipn32.sh: Expand comment.
990 * emulparams/elf32btsmipn32.sh: New file, for traditional big endian
992 * emulparams/elf32ltsmipn32.sh: Likewise for little endian.
996 * configure.tgt: Add support for arm-*-nto target.
997 * Makefile.am: Add earmnto.o file.
998 * Makefile.in: Regenerate.
999 * NEWS: Mention port of ARM support to QNX.
1000 * emulparams/armnto.sh: New file.
1004 * ldlang.c (lang_add_section): Don't turn .tbss into normal sections
1005 for relocatable link.
1006 (lang_size_sections_1): Don't make .tbss zero size for relocatable
1011 * emulparams/elf32frv.sh (OTHER_RELOCATING_SECTIONS): Delete.
1016 * po/sv.po: Updated Swedish translation.
1017 * po/es.po: Updated Spanish translation.
1018 * po/fr.po: Updated French translation.
1022 * po/sv.po: Updated Swedish translation.
1023 * po/es.po: Updated Spanish translation.
1027 * po/fr.po: Updated French translation.
1031 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
1032 bomb on /DISCARD/ input section.
1033 * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
1034 * emultempl/mmo.em (mmo_place_orphan): Likewise.
1038 * emultempl/mmo.em (mmo_place_orphan): Handle case of no .text
1046 * configure.tgt: Add support for ip2k-elf.
1047 * Makefile.am: Add support for ip2k-elf.
1048 * Makefile.in: Regenerate.
1049 * emulparams/elf32ip2k.sh: New file.
1050 * scripttempl/ip2k.sc: New file
1051 * NEWS: Mention support for new port.
1055 * NEWS: Add 'Changes in 2.13'.
1059 * ld.texinfo: Document a .symver takes precedence over a
1064 * emulparams/elf64ppc.sh (ARCH): Set to powerpc:common64.
1065 (COMMONPAGESIZE): Define.
1069 * emulparams/hppanbsd.sh: Remark that hppaobsd.sh references this file.
1073 * configure.tgt: Add support for alpha-*-openbsd*, hppa-*-openbsd*,
1074 powerpc-*-openbsd* and sparc64-*-openbsd*.
1075 * Makefile.am (ALL_EMULATIONS): Add ehppaobsd.o.
1076 * Makefile.in: Regenerate.
1077 * emulparams/hppaobsd.sh: New file.
1081 * ldlang.c (print_wild_statement): Fix output formatting.
1085 * ldlang.c: (strip_excluded_output_sections): New function.
1086 (lang_process): Call it.
1087 (lang_size_sections_1): Revert 2002-06-10 change.
1091 * Makefile.am (check-DEJAGNU): Revert 2002-06-25 change.
1093 * Makefile.in: Regenerate.
1097 * ldfile.c (ldfile_try_open_bfd): Formatting.
1099 * ldmisc.c (demangle): Move so that it doesn't intrude between
1100 vfinfo comment and body. Add comment.
1104 * emulparams/vax.sh (OUTPUT_FORMAT): Use a.out-vax-bsd format.
1108 * ldlang.h (entry_sym): Make it a struct bfd_sym_chain.
1109 * ldlang.c (entry_sym): Likewise.
1110 (ldlang_undef_chain_list_type): Likewise.
1111 (lang_finish): Adjust references to entry_symbol.
1112 (lang_add_entry): Likewise.
1113 (lang_gc_sections): Use link_info.gc_sym_list.
1114 (lang_process): Set link_info.gc_sym_list.
1115 * ldlex.l: Include bfdlink.h.
1116 * ldmain.c (main): Init link_info.gc_sym_list.
1117 * emultempl/aix.em: Adjust references to entry_symbol.
1118 * emultempl/armcoff.em: Likewise.
1119 * emultempl/armelf.em: Likewise.
1120 * emultempl/pe.em: Likewise.
1121 * emultempl/ppc64elf.em (ppc_after_open): New function.
1122 (LDEMUL_AFTER_OPEN): Define.
1123 * emulparams/elf64ppc.sh: KEEP .opd sections.
1127 * emulparams/m68hc12elfb.sh (EEPROM_MEMORY): Define.
1128 * emulparams/m68hc11elfb.sh (EEPROM_MEMORY): Define.
1129 * emulparams/m68hc11elf.sh (EEPROM_SIZE): Define.
1130 (EEPROM_START_ADDR): Define.
1131 (EEPROM_MEMORY): Define.
1132 * emulparams/m68hc12elf.sh: Likewise.
1133 * scripttempl/elfm68hc11.sc: Handle .eeprom section; handle .softregs
1134 section to put soft registers in .page0.
1135 * scripttempl/elfm68hc12.sc: Likewise but put soft registers in bss.
1139 * emulparams/hppa64linux.sh (OTHER_GOT_RELOC_SECTIONS): Add rela.opd
1140 section. Add ${RELOCATING-0}.
1144 * emulparams/shelf.sh (STACK_ADDR): Don't define.
1145 (OTHER_SECTIONS): Define.
1146 * emulparams/shelf_nbsd.sh ((STACK_ADDR): Don't undef.
1147 (OTHER_SECTIONS): Undef.
1151 * ldmisc.c (demangle): Restore dots stripped from sym name.
1155 * Makefile.am (check-DEJAGNU): Set LC_ALL=C and export it.
1156 * Makefile.in: Regenerated.
1160 * ld.texinfo (Bug Reporting): Update text to suggest a limit on
1161 the size of attached object files, to allow make the object files
1162 available via FTP or HTTP and to mention that the mail will be
1163 sent to a mailing list.
1167 * ld/configure.host (romp): Drop support.
1171 * emultempl/mipself.em (mips_elf${ELFSIZE}_check_sections): Check
1172 section flags for SEC_DATA, rather than for SEC_CODE being unset.
1176 * emultempl/mipself.em (mips_elf${ELFSIZE}_check_sections): Fix
1177 format specifier used to print BFD name.
1181 From Catherine Moore, Michael Meissner, Jim Blandy:
1182 * emulparams/elf32frv.sh: New file.
1183 * configure.tgt: Support frv-*-*.
1184 * Makefile.am (ALL_EMULATIONS): Add eelf32frv.o.
1185 (eelf32frv.c): New target.
1189 * emultempl/elf32.em: gld*_get_script: Check for
1190 GENERATE_COMBRELOC_SCRIPT.
1191 * scripttempl/elfd10v.sc : Fix STACK and INSN.
1192 * emulparams/d10velf.sh : Fix TEXT_START_ADDR.
1196 * configure.tgt: Add support for sh[1234]*le*-*-elf, sh[1234]*-*-elf.
1200 * emultempl/elf32.em (gld${EMULATION_NAME}_try_needed): Return
1201 false if xvec doesn't match.
1205 * ldlang.c (lang_size_sections_1): Skip removed output sections.
1209 * ldexp.c: Replace CONST with const.
1210 * ldfile.c: Likewise.
1211 * ldfile.h: Likewise.
1212 * ldlex.l: Likewise.
1214 * pe-dll.h: Likewise.
1218 * emultempl/ppc64elf.em (new_vers_pattern): Warning fix.
1222 * ld/ldmain.c (main): initialize link_info.pei386_auto_import
1223 to -1 == implicit enable.
1224 * ld/emultempl/pe.em (gld_${EMULATION_NAME}_before_parse):
1225 initialize link_info.pei386_auto_import to -1 == implicit
1227 (gld_${EMULATION_NAME}_parse_args): When processing
1228 --enable-auto-import and --disable-auto-import options, use
1229 '1' and '0' instead of 'true' and 'false'.
1230 (pe_find_data_imports): Only issue message about auto-import
1231 when the feature is implicitly enabled. Downgrade message to
1232 informational instead of warning.
1236 * scripttempl/elf.sc (.tbss): Fix mismatched parentheses/braces.
1240 * configure.host (hppa*64*-*-hpux11*): Define NATIVE_LIB_DIRS,
1241 HOSTING_CRT0 and HOSTING_LIBS.
1245 * configure.tgt (shle*-*-elf*, sh64le-*-elf*): New configurations.
1249 * emulparams/ns32knbsd.sh (EXECUTABLE_SYMBOLS): Set _DYNAMIC to 0.
1250 (NONPAGED_TEXT_START_ADDR): Set to 0x1000.
1254 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Place
1255 SEC_EXCLUDE sections when doing a relocatable link.
1259 * Makefile.am (ALL_EMULATIONS): Add eshelf32_nbsd.o,
1260 eshlelf32_nbsd.o, eshelf64_nbsd.o, and eshlelf64_nbsd.o.
1261 (eshelf32_nbsd.c, eshelf64_nbsd.c, eshlelf32_nbsd.c)
1262 (eshlelf64_nbsd.c): New rules.
1263 * Makefile.in: Regenerate.
1264 * configure.tgt (sh5le-*-netbsd*, sh5-*-netbsd*, sh64le-*-netbsd*)
1265 (sh64-*-netbsd*): New targets.
1266 * emulparams/shelf32_nbsd.sh: New file.
1267 * emulparams/shelf64_nbsd.sh: New file.
1268 * emulparams/shlelf32_nbsd.sh: New file.
1269 * emulparams/shlelf64_nbsd.sh: New file.
1273 * ldlang.c (section_already_linked): Call bfd_discard_group. Typo fix.
1277 * scripttempl/avr.sc: Changes to support current GCC and avr-libc,
1278 C++ constructors/destructors, loosely based on the m68hc11 port.
1282 * Makefile.in: Regenerate.
1283 * aclocal.m4: Regenerate.
1284 * config.in: Regenerate.
1285 * configure: Regenerate.
1289 * Makefile.am (ALL_EMULATIONS): Add ei386nto.o.
1290 (ei386nto.c): Add rule.
1291 * Makefile.in: Regenerate.
1292 * configure.tgt: Add i[3456]86-*-nto-qnx*.
1293 * emulparams/i386nto.sh: New file.
1297 * NEWS: Add entry for VAX ELF support.
1302 * Makefile.am (ALL_EMULATIONS): Add eelf32vax.o and evaxnbsd.o.
1304 (evaxnbsd.c): New rules.
1305 * Makefile.in: Regenerate.
1306 * configure.tgt (vax-*-netbsdelf*)
1308 (vax-*-netbsd*): New targets.
1309 * emulparams/elf32vax.sh: New file.
1310 * emulparams/vaxnbsd.sh: New file.
1314 * emultempl/armelf.em (arm_elf_after_open): Don't determine
1315 bfd_for_interwork, instead add glue sections to each input bfd.
1316 (bfd_for_interwork): New global.
1317 (arm_elf_set_bfd_for_interworking): New function.
1318 (arm_elf_before_allocation): Use it.
1322 * Makefile.am: Add DLX make target.
1323 * configure.tgt: Add DLX configuration.
1324 * Makefile.in: Regenerate.
1325 * emulparams/elf32_dlx.sh: New file
1326 * scripttempl/dlx.sc: New file
1330 * Makefile.am (eelf_i386_chaos): Use elf_chaos.sc script.
1331 * Makefile.in: Regenerate.
1332 * emulparams/elf_chaos.sh: Use elf_chaos script.
1333 * scripttempl/elf_chaos.sc: New file.
1337 * ldlang.c (lang_size_sections_1): Move check for conflicting load
1338 addresses and regions from here...
1339 (lang_get_regions): ...to this new function.
1340 (lang_leave_output_section_statement): Use lang_get_regions.
1341 (lang_leave_overlay): Likewise.
1342 * mri.c (mri_draw_tree): Pass null as last argument to
1343 lang_leave_output_section_statement.
1344 * emultempl/elf32.em (gld*_place_orphan): Likewise.
1345 * emultempl/mmo.em (mmo_place_orphan): Likewise.
1346 * emultempl/pe.em (gld*_place_orphan): Likewise.
1350 * configure.tgt: Use ns32k-*-netbsd* instead of ns32k-pc532-netbsd*.
1354 * ldemul.c: Fix formatting.
1355 * ldfile.c: Likewise.
1356 * pe-dll.c: Likewise.
1357 * pe-dll.h: Likewise.
1361 * ldlang.c (lang_process): Formatting, grammar.
1363 * ldlex.l: Use #include "" instead of <> for local header files.
1367 * configure.tgt: Add a target for i386-netbsdpe.
1371 * scripttempl/elf.sc: Add .rel{,a}.t{bss,data}, .tdata and .tbss.
1372 * ldlang.c (lang_add_section): Set SEC_THREAD_LOCAL for
1373 output section if necessary. Handle .tbss.
1374 (lang_size_sections): Clear _raw_size for .tbss section
1375 (it allocates space in PT_TLS segment only).
1376 * ldwrite.c (build_link_order): Build link order for .tbss too.
1380 * configure.in: Correct spelling of AC_PREREQ.
1384 * pe-dll.c (autofilter_liblist): Add more system libs excluded by
1386 (autofilter_objlist): Add crtbegin.o, crtend.o.
1390 * emultempl/pe.em (OPTION_EXCLUDE_LIBS): Add new define.
1391 (longopts): Add new option --exclude-libs.
1392 (gld_${EMULATION_NAME}_list_options): Give quick help about it.
1393 (gld_${EMULATION_NAME}_parse_args): Use it.
1394 * pe-dll.h (pe_dll_add_excludes): Add second param to prototype.
1395 * pe-dll.c (exclude_list_struct): Add field type to distinguish symbols
1396 from whole archives.
1397 (pe_dll_add_excludes): Set excludes->type.
1398 (auto_export): Add new variable libname and set to archive basename if
1399 abfd. Use it when filtering default and user-specified libarary
1400 excludes. Let string "ALL" mean all libs when filtering user-specified
1402 * ld.texinfo: Document --exclude-libs.
1406 * ldemul.c (ldemul_new_vers_pattern): New function.
1407 * ldemul.h (ldemul_new_vers_pattern): Declare.
1408 (struct ld_emulation_xfer_struct): Add new_vers_pattern.
1409 * ldlang.c (lang_new_vers_pattern): Call ldemul_new_vers_pattern.
1410 * emultempl/ppc64elf.em (dotsyms): New static var.
1411 (gld${EMULATION_NAME}_new_vers_pattern): New function.
1412 (LDEMUL_NEW_VERS_PATTERN): Define.
1413 (PARSE_AND_LIST_PROLOGUE): Add OPTION_DOTSYMS, OPTION_NO_DOTSYMS.
1414 (PARSE_AND_LIST_LONGOPTS): Likewise.
1415 (PARSE_AND_LIST_ARGS_CASES): Handle them.
1416 * emultempl/aix.em (ld_${EMULATION_NAME}_emulation): Update
1418 * emultempl/armcoff.em: Likewise.
1419 * emultempl/armelf_oabi.em: Likewise.
1420 * emultempl/beos.em: Likewise.
1421 * emultempl/elf32.em: Likewise.
1422 * emultempl/generic.em: Likewise.
1423 * emultempl/gld960.em: Likewise.
1424 * emultempl/gld960c.em: Likewise.
1425 * emultempl/linux.em: Likewise.
1426 * emultempl/lnk960.em: Likewise.
1427 * emultempl/m68kcoff.em: Likewise.
1428 * emultempl/mipsecoff.em: Likewise.
1429 * emultempl/pe.em: Likewise.
1430 * emultempl/sunos.em: Likewise.
1431 * emultempl/ticoff.em: Likewise.
1432 * emultempl/vanilla.em: Likewise.
1436 * genscripts.sh (LIB_PATH): For native targets, concatenate $libdir
1437 and $NATIVE_LIB_DIRS. Add $tool_lib before other libs.
1438 (LIB_SEARCH_DIRS): No need to use "tr".
1439 (COMPILE_IN): Only set for native targets.
1440 * configure.host (NATIVE_LIB_DIRS): Specify all native search dirs
1441 here, rather than adding lib:/usr/lib:/usr/local/lib in genscripts.sh.
1442 * configure.tgt (powerpc*): Set tdir_*.
1443 (powerpcle*): Correct targ_extra_emuls.
1444 * emulparams/elf32ppc.sh (LIB_PATH): Set up native 64 bit dirs.
1445 * emulparams/elf64ppc.sh (LIB_PATH): Likewise.
1449 * emultempl/pe.em (set_pe_subsystem): Don't set "cmdline" when
1450 calling lang_add_entry.
1454 * emultempl/elf32.em (gld${EMULATION_NAME}_parse_args): Handle
1456 (gld${EMULATION_NAME}_list_options): Add "-z muldefs".
1458 * ld.texinfo: Updated for --allow-multiple-definition and
1461 * ldmain.c (main): Initialize the allow_multiple_definition
1464 * lexsup.c (OPTION_ALLOW_MULTIPLE_DEFINITION): New.
1465 (ld_options): Add --allow-multiple-definition.
1466 (parse_args): Support OPTION_ALLOW_MULTIPLE_DEFINITION.
1470 * Makefile.am (ALL_EMULATIONS): Add earmelfb_nbsd.o.
1471 (earmelfb_nbsd.c): New rule.
1472 * Makefile.in: Regenerate.
1473 * configure.tgt (armeb-*-netbsdelf*): New target.
1474 (arm-*-netbsdelf*): Add armelfb_nbsd to targ_extra_emuls.
1475 (arm-*-netbsd*): Likewise.
1476 * emulparams/armelfb_nbsd.sh: New file.
1480 * emultempl/aix.em (gld*_parse_args): Add -bnortl and -bnortllib
1485 * Makefile.am: Add new emulations avr1, avr2, avr3, avr4, avr5.
1486 * Makefile.in: Regenerate.
1487 * configure.tgt (avr-*-*): Add avr[1-5] to targ_extra_emuls.
1491 * emulparams/avr1.sh: New file.
1492 * emulparams/avr2.sh: New file.
1493 * emulparams/avr3.sh: New file.
1494 * emulparams/avr4.sh: New file.
1495 * emulparams/avr5.sh: New file.
1496 * scripttempl/avr.sc: New file.
1500 * ldlang.c (section_already_linked): Call bfd_link_just_syms.
1501 (lang_place_orphans): Abort if just_syms_flag.
1505 * emultempl/aix.em: (gld*_set_output_arch): New function. Use
1506 architecture and machine information in the output bfd.
1507 (gld*_before_parse): Remove old arch and machine code.
1508 (choose_target): Rename to gld*_choose_target.
1509 (rtld): Change type to int.
1510 * ldfile.c (ldfile_try_open_bfd): Disable compatiblity check for
1511 objects in XCOFF archives.
1512 * ldfile.h: Update copyright date.
1516 * ldmain.c (main): Enable -z combreloc by default.
1520 * Makefile.am: Honour DESTDIR.
1521 * Makefile.in: Regenerate.
1525 * ldlang.h (lang_output_section_statement_type): Add update_dot_tree.
1526 (lang_enter_overlay): Remove the last two parameters.
1527 (lang_leave_overlay): Take them here instead.
1528 * ldgram.y (memspec_at_opt): Set $$ to null if no region is given.
1529 (section): Pass LMA and crossref flag to lang_leave_overlay rather
1530 than lang_enter_overlay.
1531 * ldlang.c (lang_memory_region_lookup): Return null for null names.
1532 (lang_output_section_statement_lookup): Initialize update_dot_tree.
1533 (lang_size_sections_1): Evaluate it.
1534 (lang_leave_output_section_statement): Rework LMA lookup.
1535 (overlay_lma, overlay_nocrossrefs): Remove.
1536 (lang_enter_overlay): Remove LMA and crossref arguments.
1537 (lang_enter_overlay_section): Don't set the LMA here.
1538 (lang_leave_overlay): Take LMA and crossref arguments. Move the '.'
1539 assignment to the last section's update_dot_tree. Unconditionally
1540 use the load and run-time regions specified in the OVERLAY statement.
1541 Likewise the first section's LMA. Only set the other sections' LMAs
1542 when no load region is given.
1546 * po/sv.po: New translation.
1550 * emultempl/hppaelf.em (build_section_lists): New function.
1551 (gld${EMULATION_NAME}_finish): Call elf32_hppa_setup_section_lists
1552 and build_section_lists.
1556 * ld.h: Fix formatting.
1557 * ldexp.c: Likewise.
1558 * ldfile.c: Likewise.
1559 * ldlang.c: Likewise.
1560 * ldmain.c: Likewise.
1561 * lexsup.c: Likewise.
1562 * pe-dll.c: Likewise.
1566 * emultempl/ppc64elf.em (gld${EMULATION_NAME}_after_allocation):
1567 Adjust for ppc64_elf_set_toc change. #include libbfd.h.
1568 (build_section_lists): Do output_section tests here.
1572 * emultempl/aix.em : (gld*_parse_arge): Formatting changes.
1576 Long branch stubs, multiple stub sections.
1577 * emultempl/ppc64elf.em: Include ldctor.h.
1578 (stub_file): New var.
1579 (group_size): New var.
1580 (ppc_create_output_section_statements): New function.
1581 (struct hook_stub_info): New.
1582 (hook_in_stub): New function.
1583 (ppc_add_stub_section): New function.
1584 (ppc_layout_sections_again): New function.
1585 (build_section_lists): New function.
1586 (gld${EMULATION_NAME}_finish): Rewrite.
1587 (real_func): New var.
1588 (ppc_for_each_input_file_wrapper): New function.
1589 (ppc_lang_for_each_input_file): New function.
1590 (lang_for_each_input_file): Define.
1591 (PARSE_AND_LIST_PROLOGUE): Define.
1592 (PARSE_AND_LIST_LONGOPTS): Define.
1593 (PARSE_AND_LIST_OPTIONS): Define.
1594 (PARSE_AND_LIST_ARGS_CASES): Define.
1595 (LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS): Define.
1599 * emultempl/aix.em (gld*_parse_arge, gld*_before_allocation): Add
1600 -blibpath, -bnolibpath support.
1604 * Makefile.am (ALL_EMULATIONS): Add elf32ppcwindiss.o.
1605 (eelf32ppcwindiss.c): New target.
1606 * Makefile.in: Regenerated.
1607 * configure.tgt: Add support for powerpc-*-windiss.
1608 * emulparams/elf32ppcwindiss.sh: New file.
1612 * ldlang.c (print_assignment): Update print_dot for assignments to ".".
1613 * ldexp.c (exp_print_token): Add "infix_p" argument.
1614 (exp_print_tree): Update accordingly.
1618 * Makefile.am (mpw): New maintainer mode rule to make mpw-*.c files.
1619 * Makefile.in: Regenerate.
1620 * mpw-elfmips.c: Delete.
1621 * mpw-eppcmac.c: Delete.
1622 * mpw-esh.c: Delete.
1623 * mpw-idtmips.c: Delete.
1627 * emulparams/shelf32.sh (MACHINE): Now sh5.
1631 * ldgram.y: Fix syntax warning.
1635 * emultempl/armelf.em (PARSE_AND_LIST_SHORTOPTS): Add 'n' in order
1636 to prevent "-n" from being taken as an abbreviation for
1637 "--no-pipeline-knowledge".
1641 * ldlang.c (lang_size_sections_1): Don't complain about
1642 SEC_NEVER_LOAD sections having no memory region specified.
1644 * ld.texinfo (Format Commands <OUTPUT_FORMAT>): Typo fix.
1648 * ld/configure.host (*-*-netbsd*): Add support for NetBSD/ELF.
1652 * dep-in.sed: Cope with absolute paths.
1653 * Makefile.am (dep.sed): Subst TOPDIR and BFDDIR.
1655 * Makefile.in: Regenerate.
1659 * emulparams/elf64btsmip.sh: n64 replaces .reginfo with .MIPS.options.
1663 * ldexp.c (fold_binary) [DATA_SEGMENT_ALIGN]: If common page size
1664 is smaller than maximum, round dot up to common page boundary.
1668 * configure.host: Set up for generic hosts first, then tweak as
1669 necessary in more specific targets.
1670 (HOSTING_LIBS): Include libgcc_eh.a if found.
1674 * emulparams/elf_x86_64.sh (COMMONPAGESIZE): Set it.
1678 * Makefile.am: Run "make dep-am".
1679 * Makefile.in: Regenerate.
1683 * genscripts.sh (LIB_SEARCH_DIRS): Quote path.
1687 * ldlang.c (ldlang_add_undef): If the output bfd has been opened,
1688 add the symbol to the linker hash table immediately.
1689 (lang_place_undefineds): Split symbol creation out..
1690 (insert_undefined): ..to here.
1694 * emultempl/elf32.em: Use lbasename vs. basename to fix problem where
1695 the contents of the buffer returned from basename function will are
1696 getting overwritten while still being used.
1702 * configure.tgt (x86_64-*-linux-gnu*): Configure i386 as native.
1703 * elf_x86_64.sh (ARCH): Set to i386:x86-64
1704 set libraries to default to lib64 paths.
1708 * Makefile.am : Add eaix5ppc and eaix5rs6, AIX 5 support.
1709 * configure.tgt : Same.
1710 * emulparms/aix5ppc.sh : New file. For eaix5ppc.
1711 * emulparms/aix5rs6.sh : New file. For eaix5rs6.
1712 * emulparms/aixppc.sh : OUPUT_FORMAT_32BIT and OUTPUT_FORMAT_64BIT
1713 emulation parameters for better -b32, -b64 support.
1714 * emulparms/aixrs6.sh : Same.
1715 * emulparms/ppcmacos.sh : Same.
1716 * emultempl/aix.em (choose_target) : Use new emulation parameters
1717 OUTPUT_FORMAT_32BIT and OUTPUT_FORMAT_64BIT.
1718 * Makefile.in : Regenerate.
1722 * po/fr.po: Updated version.
1726 * ldmain.c (main): Move .text readonly flag fudges from here..
1727 * ldlang.c (lang_process): ..to here.
1731 * ldlang.c (lang_check): Remove the word size check added in last
1732 change. Treat emitrelocations case as for relocatable links.
1736 * po/fr.po: Updated version.
1740 * ldlang.c (lang_check): Do relocatable link checks first, so that
1741 warn_mismatch can't override. Check compatible and word size too.
1745 * ld.texinfo: Wrap @menu in @ifnottex, not @ifinfo.
1749 * scripttempl/elf.sc: Only use DATA_SEGMENT_END() together with
1754 * scripttempl/elf.sc: Put .preinit_array, .init_array and
1755 .fini_array in the data segment.
1759 * scripttempl/elf.sc: Correct syntax errors in 2002-03-01 commit.
1763 * scripttempl/elf.sc (SECTIONS): Add entries for .preinit_array,
1764 .init_array, and .fini_array.
1768 * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Don't fold
1769 .IA64_unwind* in a relocatable link.
1773 * NEWS: Mark 2.12 branch.
1777 * emulparams/elf64_s390.sh (ARCH): Change to "s390:64-bit".
1778 * emulparams/elf_s390.sh (ARCH): Change to "s390:31-bit".
1782 * emultempl/aix.em (gld*_parse_args): Add -brtl support.
1783 (gld*_before_allocation): Same.
1784 (gld*_create_output_section_statements): Generate
1785 __rtinit if run time linking. Add librtl.a to the link.
1786 (gld*_read_file): Clean.
1790 * emulparams/elf64ppc.sh (OTHER_TEXT_SECTIONS): Define.
1794 * Makefile.am: Add new files earmelf_fbsd, eelf32ppc_fbsd,
1795 eelf_i386_fbsd, eelf64_ia64_fbsd, eelf_x86_64_fbsd, eelf64_sparc_fbsd,
1796 and eelf64alpha_fbsd.
1797 * Makefile.in: Regenerate.
1798 * configure.tgt(sparc64-*-freebsd, ia64-*-freebsd, i[3456]86-*-freebsd,
1799 x86_64-*-freebsd, arm-*-freebsd, alpha*-*-freebsd, powerpc-*-freebsd):
1800 use a FreeBSD-specific emulation rather than the psABI one.
1801 * emulparams/elf_fbsd.sh (ELF_INTERPRETER_NAME): Set appropriate value
1802 for all FreeBSD ELF systems.
1803 * emulparams/armelf_fbsd.sh: Bridge elf_fbsd.sh and the "native" psABI
1805 * emulparams/elf32ppc_fbsd.sh: Likewise.
1806 * emulparams/elf64_ia64_fbsd.sh: Likewise.
1807 * emulparams/elf64_sparc_fbsd.sh: Likewise.
1808 * emulparams/elf64alpha_fbsd.sh: Likewise.
1809 * emulparams/elf_i386_fbsd.sh: Likewise.
1810 * emulparams/elf_x86_64_fbsd.sh: Likewise.
1814 * po/tr.po: Updated version.
1818 * ld.texinfo (Output Section Fill): Fix amateur texinfo.
1823 * emultempl/mmo.em (mmo_after_open): Don't call
1824 _bfd_mmix_check_all_relocs when producing ELF output.
1828 * emulparams/elf64alpha.sh (NOP): Adjust for big-endian
1829 definition. Emit a unop+nop pair.
1833 * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Also check
1834 for presence of .MMIX.reg_contents.linker_allocated before early
1837 * NEWS: Mention support for MMIX.
1841 Support arbitrary length fill patterns.
1842 * ld.texinfo (Output Section Fill): Describe fill expressions.
1843 (FILL): Refer to the above.
1844 * ldexp.h (etree_value_type): Add "str" field.
1845 (union etree_union): Add "str" to "value" struct.
1846 (exp_bigintop): Declare.
1847 (exp_get_fill): Declare.
1848 * ldexp.c: Include "safe-ctype.h".
1849 (exp_intop): Set value.str to NULL.
1850 (exp_bigintop): New function.
1851 (new_rel): Pass in "str", and set new.str from it.
1852 (new_rel_from_section): Set new.str to NULL.
1853 (fold_name): Adjust calls to new_rel.
1854 (exp_fold_tree): Likewise.
1855 (exp_get_fill): New function.
1856 * ldgram.y (struct big_int bigint, fill_type *fill): New.
1857 (INT): Returns a "bigint". Adjust all code handling INTs.
1858 (fill_opt): Returns a "fill".
1859 (fill_exp): Split out of fill_opt, use for FILL.
1860 * ldlang.h (struct _fill_type): New.
1861 (fill_type): Move typedef to ldexp.h.
1862 (lang_output_section_statement_type): "fill" is now a pointer.
1863 (lang_fill_statement_type): Likewise.
1864 (lang_padding_statement_type): Likewise.
1865 (lang_add_fill): Now takes a "fill_type *" param.
1866 (lang_leave_output_section_statement): Likewise.
1867 (lang_do_assignments): Likewise.
1868 (lang_size_sections): Likewise.
1869 (lang_leave_overlay_section): Likewise.
1870 (lang_leave_overlay): Likewise.
1871 * ldlang.c: Include ldgram.h after ldexp.h.
1872 (lang_output_section_statement_lookup): Adjust for fill_type change.
1873 (print_fill_statement): Likewise.
1874 (print_padding_statement): Likewise.
1875 (insert_pad): Now takes a "fill_type *" arg.
1876 (size_input_section): Likewise.
1877 (lang_size_sections_1): Likewise.
1878 (lang_size_sections): Likewise.
1879 (lang_do_assignments): Likewise.
1880 (lang_add_fill): Likewise.
1881 (lang_leave_output_section_statement): Likewise.
1882 (lang_leave_overlay_section): Likewise.
1883 (lang_leave_overlay): Likewise.
1884 Adjust all callers of the above function.
1885 * ldlex.l: Include ldgram.h after ldexp.h. Allow hex numbers
1886 starting with "0X" as well as "0x". Return bigint.str for hex
1887 numbers starting with "0x" or "0X", zero bigint.str otherwise.
1888 Always use base 16 for numbers starting with "$".
1889 * ldmain.c: Include ldgram.h after ldexp.h.
1890 * ldwrite.c (build_link_order): Use bfd_data_link_order in place
1891 of bfd_fill_link_order.
1892 * pe-dll.c: Adjust lang_do_assignments calls.
1893 * emultempl/elf32.em: Likewise.
1894 * emultempl/hppaelf.em: Likewise.
1895 * emultempl/ppc64elf.em: Likewise.
1896 * emultempl/beos.em: Include ldgram.h after ldexp.h, adjust
1897 lang_add_assignment call.
1898 * emultempl/pe.em: Likewise.
1902 * ld.texinfo (VERSION scripts): Symbol names are globbing patterns.
1903 * ldgram.y (lang_new_vers_regex): Rename to lang_new_vers_pattern;
1904 the pattern in question is not a regexp.
1905 * ldlang.c: Likewise.
1906 * ldlang.h: Likewise.
1907 * ldlex.l (V_IDENTIFIER): Allow '[', ']', '-', '!', and '^' also.
1911 * ldlex.l (DATA_SEGMENT_ALIGN, DATA_SEGMENT_END): New tokens.
1912 * ldgram.y (DATA_SEGMENT_ALIGN, DATA_SEGMENT_END): New tokens.
1913 (exp): Add DATA_SEGMENT_ALIGN (exp, exp) and DATA_SEGMENT_END (exp).
1914 * ldexp.c (exp_data_seg): New variable.
1915 (exp_print_token): Handle DATA_SEGMENT_ALIGN and DATA_SEGMENT_END.
1916 (fold_binary): Handle DATA_SEGMENT_ALIGN.
1917 (exp_fold_tree): Handle DATA_SEGMENT_END.
1918 Pass allocation_done when recursing instead of hardcoding
1919 lang_allocating_phase_enum.
1920 * ldexp.h (exp_data_seg): New.
1921 * ldlang.c (lang_size_sections_1): Renamed from lang_size_sections.
1922 (lang_size_sections): New.
1923 * ld.texinfo (DATA_SEGMENT_ALIGN, DATA_SEGMENT_END): Document.
1924 * scripttempl/elf.sc: Use DATA_SEGMENT_ALIGN and DATA_SEGMENT_END
1925 if COMMONPAGESIZE is defined.
1926 * emulparams/elf_i386.sh (COMMONPAGESIZE): Set to 4K.
1927 * emulparams/elf32_sparc.sh (COMMONPAGESIZE): Set to 8K.
1928 * emulparams/elf64_sparc.sh (COMMONPAGESIZE): Set to 8K.
1929 * emulparams/elf64alpha.sh (COMMONPAGESIZE): Set to 8K.
1930 * emulparams/elf64_ia64.sh (COMMONPAGESIZE): Set to 16K for shared
1935 * Makefile.in: Regenerate.
1939 * lexsup.c: Remove strtoul declaration.
1943 * ldmain.c: Add prototype for main ().
1944 * lexsup.c: Guard declaration of strtoul with HAVE_STDLIB_H.
1945 * emultempl/lnk960.em (lnk960_choose_target): Function should
1950 * ldlang.c (entry_section): New initialised variable.
1951 (lang_finish): Use it.
1952 * ldlang.h (entry_section): Declare.
1953 * emultempl/ppc64elf.em (gld${EMULATION_NAME}_finish): Set
1954 entry_section to ".opd".
1958 * ld.texinfo (Options): Add back in -nostdlib documentation,
1959 which had been inadvertently removed.
1963 * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Adjust
1964 register section vma to a sane value after emitting error. Make
1965 fatal conditions cause program exit when emitting message.
1969 * configure.tgt: Add or32-*-rtems target.
1973 Contribute sh64-elf.
1975 * emulparams/shelf32.sh (STACK_ADDR): Define as formerly defined
1976 in OTHER_RELOCATABLE_SECTIONS.
1978 * emulparams/shelf32.sh (STACK_ADDR): Define.
1979 (OTHER_RELOCATABLE_SECTIONS): Renamed to...
1980 (OTHER_SECTIONS): this. Removed stack settings.
1981 * emulparams/shelf64.sh (OTHER_RELOCATABLE_SECTIONS): Do not set.
1982 (OTHER_SECTIONS): Reset after sourcing shelf32.sh.
1984 * emultempl/sh64elf.em (sh64_elf_$_before_allocation): Disable
1985 relaxing if any shmedia or mixed sections are found.
1987 * emultempl/sh64elf.em (sh64_elf_before_allocation): Pass f to
1988 einfo. Gracefully decline to output to non-elf formats.
1990 * emulparams/shelf64.sh (OTHER_RELOCATING_SECTIONS) <.stack>:
1991 Default to _end aligned to next multiple of 0x40000, plus 0x40000.
1992 * emulparams/shelf32.sh: Ditto.
1994 * emulparams/shelf32.sh (OTHER_RELOCATING_SECTIONS): Tweak
1997 * emulparams/shelf32.sh (OTHER_RELOCATING_SECTIONS): Avoid
1998 non-portable shell constructs. From Hans-Peter Nilsson.
2000 * emulparams/shelf64.sh (EXTRA_EM_FILE): Define empty.
2001 * Makefile.am (eshelf64.c, eshlelf64.c, eshlelf32.c): Adjust
2002 dependencies to the shell script include chain.
2003 * Makefile.in: Regenerate.
2005 * emultempl/sh64elf.em: Update and tweak comments.
2006 (sh64_elf_${EMULATION_NAME}_after_allocation): Always allocate and
2007 make a .cranges section SEC_IN_MEMORY.
2009 * emultempl/sh64elf.em
2010 (sh64_elf_${EMULATION_NAME}_before_allocation): Don't stop when
2011 .cranges section found to be necessary; continue and set stored
2012 section contents flags for sections with non-mixed contents.
2013 Use a struct sh64_section_data container and sh64_elf_section_data
2014 to store contents-type flags.
2015 Remove unused update of "isec".
2016 (sh64_elf_${EMULATION_NAME}_after_allocation): Only process
2017 sections marked SHF_SH5_ISA32_MIXED. Use sh64_elf_section_data to
2018 access contents-type flags. Assert that the associated container
2019 is initialized. Use that container, not elf_gp_size, to hold size
2020 of linker-generated cranges contents.
2022 * emultempl/sh64elf.em
2023 (sh64_elf_${EMULATION_NAME}_before_allocation): Exit early if
2024 there's already a .cranges section. When section flag difference
2025 is found, don't NULL-check cranges a second time. Tweak comments.
2026 (sh64_elf_${EMULATION_NAME}_after_allocation): Use size after
2027 merging, not max size, as size of ld-generated .cranges contents.
2028 Don't set ELF section flags in output section. When checking for
2029 needed .cranges descriptors, don't use a variable; compare
2030 incoming ELF section flags directly to SHF_SH5_ISA32_MIXED. Tweak
2033 * emultempl/sh64elf.em: New file.
2034 * Makefile.am (eshelf32.c, eshlelf32.c): Adjust dependencies.
2035 * Makefile.in: Regenerate.
2036 * emulparams/shelf32.sh (OUTPUT_FORMAT): Only set if not set.
2037 (OTHER_RELOCATING_SECTIONS): Ditto.
2038 (EXTRA_EM_FILE): New, set to sh64elf if not set.
2039 * emulparams/shlelf32.sh: Stub out all settings except
2040 OUTPUT_FORMAT. Source shelf32.sh.
2041 * emulparams/shelf64.sh: Similar, but also keep ELF_SIZE and
2042 OTHER_RELOCATING_SECTIONS.
2043 (OTHER_RELOCATING_SECTIONS): Remove .cranges.
2044 * emulparams/shlelf64.sh: Stub out all settings except
2045 OUTPUT_FORMAT. Source shelf64.sh.
2047 * emulparams/shelf64.sh (OTHER_RELOCATING_SECTIONS): Include
2049 (DATA_START_SYMBOLS): Define, provide ___data.
2050 (OTHER_READONLY_SYMBOLS): Define, provide ___rodata and align to 8
2051 for consecutive .data section.
2052 (OTHER_GOT_SECTIONS): Define, align to 8 for consecutive .bss
2053 section after .data section.
2054 * emulparams/shlelf64.sh: Ditto.
2055 * emulparams/shelf32.sh: Ditto.
2056 (ALIGNMENT): Define to 8.
2057 * emulparams/shelf32.sh: Ditto.
2059 * configure.tgt (sh64-*-elf*): Assign targ_extra_libpath to get
2060 built-in linker scripts.
2062 * emulparams/shlelf64.sh: New.
2063 * emulparams/shelf64.sh: New.
2064 * configure.tgt (sh64-*-elf*): Add shelf64 and shlelf64 to
2066 * Makefile.am: Add support for shlelf64 and shelf64.
2067 * Makefile.in: Regenerate.
2069 * configure.tgt (sh64-*-elf*): Add shelf as default.
2070 Add shlelf to targ_extra_emuls.
2072 * emulparams/shelf32.sh: New file.
2073 * emulparams/shlelf32.sh: New file.
2074 * Makefile.am: Add support for shlelf32 and shelf32.
2075 * configure.tgt: Map sh64-*-elf* to shlelf32 and shelf32.
2076 * Makefile.in: Regenerate.
2080 * ldlang.c (lang_reset_memory_regions): Rename from
2081 reset_memory_regions. Change all callers. Make public.
2082 * ldlang.h (lang_reset_memory_regions): Prototype.
2083 * emultempl/elf32.em (gld${EMULATION_NAME}_finish): Call
2084 lang_reset_memory_regions before lang_size_sections.
2085 * emultempl/hppaelf.em (hppaelf_layout_sections_again): Likewise.
2086 * emultempl/ppc64elf.em (gld${EMULATION_NAME}_finish): Likewise.
2090 * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Use signed
2091 arithmetic when checking for too many global registers.
2095 * Makefile.am (ALL_EMULATIONS): Add ehppanbsd.o.
2096 (ehppanbsd.c): New rule.
2097 * Makefile.in: Regenerate.
2098 * configure.tgt (hppa*-*-netbsd*): New target.
2099 * emulparams/hppalinux.sh: Add comment to check other files
2100 that source this file it is modified, and list which
2102 * emulparams/hppanbsd.sh: New file.
2106 * scripttempl/xstormy16.sc: Don't allocate extra space for the
2111 Support on-demand global register allocation from
2112 R_MMIX_BASE_PLUS_OFFSET relocs.
2113 * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Rename from
2114 mmix_set_reg_section_vma. Call
2115 _bfd_mmix_finalize_linker_allocated_gregs.
2116 (mmix_before_allocation): New function.
2117 (LDEMUL_AFTER_ALLOCATION): Set to mmix_after_allocation.
2118 (LDEMUL_BEFORE_ALLOCATION): Define to mmix_before_allocation.
2119 * scripttempl/mmo.sc (.text): Mark .init, .fini as KEEP.
2120 (.MMIX.reg_contents): Add .MMIX.reg_contents.linker_allocated
2121 before .MMIX.reg_contents.
2122 * emultempl/mmo.em (gldmmo_before_allocation): Define to default.
2123 (mmo_after_open): New function.
2124 (LDEMUL_AFTER_OPEN): Define to mmo_after_open.
2125 * emulparams/elf64mmix.sh (OTHER_SECTIONS): Tweak formatting. Add
2126 .MMIX.reg_contents.linker_allocated before .MMIX.reg_contents.
2130 * emulparams/or32.sh: New file.
2131 * emulparams/or32elf.sh: New file.
2132 * scripttempl/or32.sc: New file.
2133 * configure.tgt : Add support for or32.
2134 * configure: Regenerate
2135 * Makefile.am: Add support for or32.
2136 * Makefile.in: Regenerate.
2137 * NEWS: Mention support for or32.
2138 * po/ld.pot: Regenerate.
2143 * emulparams/elf32bmip.sh (EXTRA_EM_FILE): Define to be mipself.
2144 * emultempl/mipself.em: New file to handle MIPS ELF embedded
2145 reloc creation (ld --embedded-relocs).
2149 * configure: Regenerated.
2153 * Makefile.am (install): Depend on install-info.
2154 * Makefile.in: Regenerate.
2158 * ldmain.c (main): Use full sentences to ease translation.
2162 * po/fr.po: Updated version.
2166 * po/es.po: Updated version.
2170 * ldlex.l (yy_input): Correct error check.
2174 * ldmisc.c (demangle): Put back dots when string not demangled.
2178 * emulparams/elf64alpha.sh (NOP): Use unop.
2182 * ldlex.l: Use fread instead of read.
2186 * configure.tgt (ia64-*-netbsd*): New target.
2190 * emulparams/elf32btsmip.sh (SHLIB_TEXT_START_ADDR): Change to
2192 * emulparams/elf64btsmip.sh (SHLIB_TEXT_START_ADDR): Likewise.
2196 * ldver.c (ldversion): Update year.
2200 * po/ld.pot: Regenerate.
2204 * Makefile.am (eelf64ppc.c, eelf64lppc.c): Depend on ppc64elf.em.
2205 * Makefile.in: Regenerate.
2206 * emulparams/elf64ppc.sh (EXTRA_EM_FILE): Define.
2207 * emultempl/ppc64elf.em: New file.
2211 * scripttempl/pe.sc: Add support for constructor priorities.
2215 * emulparams/avr1200.sh (DATA_START): Define as 0x60.
2216 * emulparams/avr23xx.sh: Likewise.
2217 * emulparams/avr4433.sh: Likewise.
2218 * emulparams/avr44x4.sh: Likewise.
2219 * emulparams/avr85xx.sh: Likewise.
2220 * emulparams/avrmega103.sh: Likewise.
2221 * emulparams/avrmega161.sh: Likewise.
2222 * emulparams/avrmega603.sh: Likewise.
2223 * scripttempl/elf32avr.sc: Use DATA_START instead of 0x60.
2227 * ldlang.c (walk_wild_section): Exclude object file if enclosing
2228 archive is excluded.
2232 * Makefile.am (ALL_EMULATIONS): Add eshelf_nbsd.o and eshlelf_nbsd.o.
2233 (eshelf_nbsd.c): New rule.
2234 (eshlelf_nbsd.c): New rule.
2235 * Makefile.in: Regenerate.
2236 * configure.tgt (sh*le-*-netbsdelf*): New target.
2237 (sh*-*-netbsdelf*): New target.
2238 * emulparams/shelf.sh: Document that shelf_nbsd.sh sources this file.
2239 * ld/emulparams/shelf_nbsd.sh: New emulation.
2240 * ld/emulparams/shlelf_nbsd.sh: New emulation.
2244 * po/es.po: New file: Spanish translation.
2245 * configure.in (ALL_LINGUAS): Add es.
2246 * configure: Regenerate.
2250 * ld.texinfo: Note that --emit-relocs is currently only
2251 implemented for ELF.
2255 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Make use
2256 of bfd_section_list_remove and bfd_section_list_insert macros.
2257 * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
2258 * emultempl/mmo.em (mmo_place_orphan): Likewise.
2262 * configure.tgt (x86_64-*-netbsd*): New target.
2266 (gld*_create_output_section_statements): New function.
2267 For -binitfini support.
2268 * emultempl/aix.em (gld*_before_parse): Fix comment.
2269 * emultempl/aix.em (gld*_parse_args): Fix comment.
2273 * configure.tgt (mips*-dec-netbsd*): Delete alias for
2275 (sparc64-*-netbsd*): Add elf32_sparc to targ_extra_emuls.
2277 * configure.tgt (arm-*-netbsdelf*): Add target.
2278 (arm-*-netbsd*): Add armelf and armelf_nbsd to targ_extra_emuls.
2279 * emulparams/armelf_nbsd.sh: Added.
2280 * Makefile.am: Add rules for earmelf_nbsd.
2281 * Makefile.in: Regenerate.
2286 * configure.host: Add rules for x86_64-*linux-gnu. Change
2287 s390x-linux entry to use gcc to report configuration, replace gcc
2288 with $CC in s390-linux
2292 * ld.texinfo (VERSION): Fix markup.
2296 * Makefile.am (ALL_EMULATIONS): Add m68kelfnbsd.o.
2297 (m68kelfnbsd.c): New rule.
2298 * Makefile.in: Regenerate.
2299 * configure.tgt (m68*-hp-netbsd*): Renamed to ..
2300 (m68*-*-netbsd*4k*): .. this.
2301 (m68*-*-netbsdelf*): New target.
2302 (m68*-*-netbsd*): Also include ELF support.
2303 (m68*-*-netbsdaout*): New alias for m68*-*-netbsd*.
2304 * emulparams/m68kelfnbsd.sh: New emulation.
2308 * ldgram.y (vers_node): Support anonymous version tags.
2309 * ldlang.c (lang_register_vers_node): Ensure anonymous version
2310 tag is not defined together with non-anonymous versions.
2311 * ld.texinfo: Document it.
2315 * po/tr.po: New file: Turkish translation.
2316 * configure.in (ALL_LINGUAS): Add tr.
2317 * configure: Regenerate.
2321 * Makefile.am: Add rules for eelf64alpha_nbsd.
2322 * Makefile.in: Regenerate.
2323 * configure.tgt (alpha*-*-netbsd*): Set
2324 targ_emul to elf64alpha_nbsd.
2325 * emulparams/elf64alpha_nbsd.sh: Added.
2329 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Adjust
2330 section_tail when fiddling with section list.
2331 (gld${EMULATION_NAME}_list_options): Ensure sentences aren't
2332 broken into separate strings to make translation easier.
2333 * emultempl/mmo.em (mmo_place_orphan): Adjust section_tail when
2334 fiddling with section list.
2335 * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
2339 * scripttempl/mmo.sc: Add .debug_ranges to listed sections.
2343 * ldmain.c (main): Initialise link_info.eh_frame_hdr.
2347 * emultempl/elf32.em (finish): Supply output_bfd
2348 to bfd_elf*_discard_info.
2349 (OPTION_EH_FRAME_HDR): Define.
2350 (longopts): Add --eh-frame-hdr.
2351 (parse_args): Handle it.
2352 (list_options): Add --eh-frame-hdr to help.
2353 * emultempl/hppaelf.em (finish): Supply output_bfd
2354 to bfd_elf*_discard_info.
2355 * scripttempl/elf.sc (.eh_frame_hdr): Add.
2359 * lexsup.c (parse_args): Don't pass shortopts to second call to
2360 getopt functions. Restore optind rather than decrementing before
2361 second call. Remove errind as it now duplicates last_optind.
2365 * emultempl/pe.em (gld_${EMULATION_NAME}_list_options): Fix typo.
2370 * Makefile.am: Add support for xstormy16.
2371 * configure.tgt: Add support for xstormy16.
2372 * Makefile.in: Regenerate.
2373 * emulparams/elf32xstormy16.sh: New file.
2374 * scripttempl/xstormy16.sc: New file.
2378 * Makefile.in (LIB_PATH): Make configurable.
2379 (GENSCRIPTS): Set LIB_PATH in environment.
2380 * configure.in: Substitute LIB_PATH.
2381 * configure: Regenerate.
2382 * configure.tgt (*cygwin): Set LIB_PATH for cross build.
2383 * configure.host (*cygwin): Add /usr/lib/w32api to NATIVE_LIB_DIRS.
2387 * lexsup.c (ld_options): Insert 'PROGRAM' into the text string
2388 describing the -N option so that it is easier to translate into
2393 * emultempl/pe.em (..._list_options): Replace multiple fprintf
2394 statements describing a single option with a single, newline
2395 escaped fprintf. This allows better translation into other
2398 * ldmain.c (add_archive_element): Combine multiple strings
2399 into a single string to permit better translation into other
2404 * Makefile.am: Remove eaixppc64.
2405 * Makefile.in: Regenerate.
2409 * emultempl/aix.em (choose_target): Change default target to
2410 OUTPUT_FORMAT for ppcmacos. Add braces to remove compiler
2412 (gld*_read_file): Fix typo.
2413 (change_symbol_mode): Add prototype.
2416 * emulparams/aixppc.sh (SYSCALL_MASK, SYMBOL_MODE_MASK): Delete.
2417 * emulparams/aixrs6.sh : Same.
2418 * emulparams/ppcmacos.sh : Same.
2419 * emulparams/aixppc64.sh : Delete file.
2420 * emultempl/aix.em : Formatting changes.
2424 * emulparams/criself.sh (NO_SMALL_DATA): Set, to yes.
2425 (OTHER_BSS_END_SYMBOLS): Don't refer to .sbss when setting
2427 (OTHER_END_SYMBOLS): Fix formatting.
2428 * emulparams/crislinux.sh (NO_SMALL_DATA): Set, to yes.
2429 (OTHER_END_SYMBOLS): Fix formatting.
2433 * ldexp.c (exp_print_token): Correct "table" entry for RSHIFT.
2437 * configure.tgt : Remove eaixppc64 emulations.
2438 * Makefile.in : Remove eaixppc64.c
2439 * ldemul.c (ldemul_choose_target): New parameters argc, argv.
2440 (ldemul_default_target): Same.
2441 * emultempl/gld960.em (gld960_choose_target): Same.
2442 * emultempl/gld960c.em (gld960_choose_target): Same.
2443 * scripttempl/aix.sc: Remove OUTPUT_FORMAT.
2444 * emultempl/aix.em (is_syscall): syscall_mask now a variable.
2445 * emultempl/aix.em (gld*_read_file): symbol_mode_mask now a variable.
2446 * emultempl/aix.em (gld*_parse_args): Handle -b32 -b64 emulation.
2447 * emultempl/aix.em (choose_target): New function. Handle emulation of
2452 * emulparams/elf_i386.sh (NO_SMALL_DATA): Set to yes.
2453 * emulparams/elf_i386_be.sh (NO_SMALL_DATA): Likewise.
2454 * emulparams/elf_i386_chaos.sh (NO_SMALL_DATA): Likewise.
2455 * emulparams/elf_i386_ldso.sh (NO_SMALL_DATA): Likewise.
2456 * emulparams/elf_x86_64.sh (NO_SMALL_DATA): Likewise.
2457 * emulparams/m68kelf.sh (NO_SMALL_DATA): Likewise.
2458 * emulparams/elf32_sparc.sh (NO_SMALL_DATA): Likewise.
2459 * emulparams/elf64_sparc.sh (NO_SMALL_DATA): Likewise.
2461 * scripttempl/elf.sc (SBSS): New. Define if ${NO_SMALL_DATA}
2464 (REL_SDATA): Likewise.
2465 (REL_SBSS): Likewise.
2466 (REL_SDATA2): Likewise.
2467 (REL_SBSS2): Likewise.
2468 (SBSS2): Define if ${NO_SMALL_DATA} is not empty.
2473 * scripttempl/elfm68hc11.sc (CTOR, DTOR): Put constructor and
2475 * scripttempl/elfm68hc12.sc (CTOR, DTOR): Likewise.
2479 * Makefile.in: Regenerated with automake based on automake
2480 1.4-8 in RedHat 7.1.
2484 * Makefile.am (CONFIG_STATUS_DEPENDENCIES): Define.
2485 (config.status): Delete rule.
2486 Add extra dependencies to cover sourced emulparams files.
2487 * Makefile.in: Regenerate.
2489 * scripttempl/elf.sc: Order <section>, <section>.* and
2490 corresponding linkonce sections as seen in input files.
2491 Formatting fixes. Zero vma of all sections if not relocating.
2492 (STACK): Define and insert if STACK_ADDR defined.
2493 (OTHER_RELOCATING_SECTIONS): Delete.
2494 (OTHER_END_SYMBOLS): Define.
2495 (OTHER_READONLY_SECTIONS): Always insert, not just when relocating.
2496 (OTHER_READWRITE_SECTIONS): Likewise.
2497 (OTHER_GOT_SECTIONS): Likewise.
2498 (OTHER_SDATA_SECTIONS): Likewise.
2499 (OTHER_BSS_SECTIONS): Likewise.
2500 * scripttempl/elfi370.sc (OTHER_READONLY_SECTIONS): Likewise.
2501 (OTHER_READWRITE_SECTIONS): Likewise.
2502 * scripttempl/nw.sc (OTHER_READONLY_SECTIONS): Likewise.
2503 (OTHER_READWRITE_SECTIONS): Likewise
2505 * emulparams/armelf.sh (OTHER_RELOCATING_SECTIONS): Delete.
2506 (STACK_ADDR): Define.
2507 * emulparams/armelf_oabi.sh: As for armelf.sh.
2508 * emulparams/elf32mcore.sh: As for armelf.sh.
2509 * emulparams/h8300elf.sh: As for armelf.sh.
2510 * emulparams/mn10200.sh: As for armelf.sh.
2511 * emulparams/shelf.sh: As for armelf.sh.
2513 * emulparams/elf32fr30.sh (OTHER_RELOCATING_SECTIONS): Delete.
2514 (OTHER_END_SYMBOLS): Define.
2515 * emulparams/m32relf.sh: As for elf32fr30.sh.
2516 * emulparams/h8300helf.sh: As for elf32fr30.sh.
2517 * emulparams/h8300self.sh: As for elf32fr30.sh.
2519 * emulparams/criself.sh (OTHER_READONLY_SECTIONS): Protect symbol
2520 defines with RELOCATING test.
2521 (OTHER_SDATA_SECTIONS): Likewise.
2522 (OTHER_RELOCATING_SECTIONS): Delete, replacing with..
2523 (OTHER_END_SYMBOLS): ..this.
2524 * emulparams/crislinux.sh: As for criself.sh.
2526 * emulparams/elf32bmipn32.sh (OTHER_SDATA_SECTIONS): Zero vma
2528 (OTHER_RELOCATING_SECTIONS): Delete, replacing with..
2529 (OTHER_SECTIONS): ..this. Zero vma if not relocating. Order
2530 normal and linkonce sections as seen in input files.
2531 * emulparams/elf32bmip.sh (DATA_ADDR): Don't define if EMBEDDED.
2532 (TEXT_DYNAMIC): Likewise.
2533 (INITIAL_READONLY_SECTIONS): Zero vma if not relocating.
2534 (OTHER_SDATA_SECTIONS): Likewise.
2535 * emulparams/elf32ppc.sh (OTHER_READWRITE_SECTIONS): Likewise.
2536 * emulparams/shlelf_linux.sh (OTHER_READWRITE_SECTIONS): Likewise.
2537 * emulparams/elf64alpha.sh (OTHER_READONLY_SECTIONS): Likewise.
2538 * emulparams/hppalinux.sh (OTHER_READONLY_SECTIONS): Likewise.
2539 * emulparams/elf64_aix.sh (OTHER_GOT_SECTIONS): Likewise.
2540 (OTHER_PLT_RELOC_SECTIONS): Likewise.
2541 (OTHER_READONLY_SECTIONS): Likewise. Order normal and linkonce
2542 sections as seen in input files.
2543 * emulparams/elf64_ia64.sh: As for emulparams/elf64_aix.sh.
2544 * emulparams/hppa64linux.sh (OTHER_READONLY_SECTIONS): Zero vma
2546 (OTHER_READWRITE_SECTIONS, OTHER_BSS_SECTIONS): Likewise.
2547 (OTHER_BSS_END_SYMBOLS): Merge from elf64hppa.sh.
2548 * emulparams/elf64mmix.sh (OTHER_RELOCATING_SECTIONS): Delete.
2549 (OTHER_SECTIONS): Instead, use this..
2550 (OTHER_END_SYMBOLS): ..and this.
2552 * emulparams/elf32b4300.sh: Source elf32bmip.sh, remove duplicates.
2553 * emulparams/elf32bsmip.sh: Likewise.
2554 * emulparams/elf32btsmip.sh: Likewise.
2555 * emulparams/elf32ebmip.sh: Likewise.
2556 * emulparams/elf32lmip.sh: Likewise.
2557 * emulparams/elf32elmip.sh: Source elf32lmip.sh, remove duplicates.
2558 * emulparams/elf32lsmip.sh: Likewise.
2559 * emulparams/elf32ltsmip.sh: Source elf32btsmip.sh, remove duplicates.
2560 * emulparams/elf32l4300.sh: Source elf32b4300.sh, remove duplicates.
2561 * emulparams/elf64bmip.sh: Source elf32bmipn32.sh, remove duplicates.
2562 * emulparams/elf64btsmip.sh: Likewise.
2563 * emulparams/elf64ltsmip.sh: Source elf64btsmip.sh, remove duplicates.
2564 * emulparams/elf32lppc.sh: Source elf32ppc.sh, remove duplicates.
2565 * emulparams/elf32ppclinux.sh: Likewise.
2566 * emulparams/elf32ppcsim.sh: Likewise.
2567 * emulparams/elf32lppcsim.sh: Source elf32lppc.sh, remove duplicates.
2568 * emulparams/elf64hppa.sh: Source hppa64linux.sh, remove duplicates.
2569 * emulparams/h8300helf.sh: Source h8300elf.sh, remove duplicates.
2570 * emulparams/h8300self.sh: Likewise.
2571 * emulparams/mn10300.sh: Source mn10200.sh, remove duplicates.
2572 * emulparams/sh.sh: Comment.
2573 * emulparams/shl.sh: Source sh.sh, remove duplicates.
2574 * emulparams/shlelf.sh: Source shelf.sh, remove duplicates.
2575 * emulparams/shelf_linux.sh: Source shlelf_linux.sh, remove duplicates.
2580 * ldlang.c (map_input_to_output_sections): Replace "break"
2581 accidentally removed with 2001-08-03 change.
2582 (lang_gc_sections_1): Likewise.
2586 * ldlang.c (walk_wild_section): Move sec == NULL case out of loop.
2590 * emultempl/elf32.em (gld${EMULATION_NAME}_finish): Use NULL instead
2591 of false when calling lang_size_sections.
2592 * emultempl/hppaelf.em (hppaelf_layout_sections_again): Likewise.
2596 * emultempl/elf32.em (gld${EMULATION_NAME}_finish): Only emit this
2597 function when LDEMUL_FINISH isn't set to the same name. Don't
2598 call ${LDEMUL_FINISH}.
2599 (ld_${EMULATION_NAME}_emulation): Call $LDEMUL_FINISH if defined.
2600 * emultempl/armelf.em (arm_elf_finish): Call
2601 gld${EMULATION_NAME}_finish.
2602 * emultempl/hppaelf.em (hppaelf_finish): Rename to
2603 gld${EMULATION_NAME}_finish. Call bfd_elf32_discard_info and
2604 hppaelf_layout_sections_again if necessary.
2605 (need_laying_out): New var.
2606 (hppaelf_layaout_sections_again): Rename to
2607 hppaelf_layout_sections_again. Clear need_laying_out.
2608 (PARSE_AND_LIST_OPTIONS): Format text.
2612 * emultempl/armelf.em (arm_elf_finish): Renamed from
2613 gld${EMULATION_NAME}_finish.
2614 (LDEMUL_FINISH): Set to arm_elf_finish.
2618 * emultempl/elf32.em (gld${EMULATION_NAME}_finish): New.
2619 (struct ld_emulation_xfer_struct): Use it.
2623 * emulparams/elf64hppa.sh (OTHER_BSS_END_SYMBOLS): Add
2624 additional symbols referenced by newer crt0.o files from HP.
2628 * emulparams/armelf.sh (DATA_START_SYMBOLS): New symbol.
2632 * Makefile.am (GENSCRIPTS): Quote ${exec_prefix}.
2633 * Makefile.in: Regenerate.
2637 * ld.texinfo: Use @command for commands, @option for options.
2638 * Makefile.am (POD2MAN): Use 'GNU Development Tools' for
2640 * Makefile.in: Rebuild.
2644 * configure.tgt (mips*el-*-netbsd*, mips*-*-netbsd*):
2645 Add support for targets.
2649 * configure.in (ALL_LINGUAS): Add "fr" and "sv"
2650 * configure: Regernate.
2651 * po/fr.po: New file.
2652 * po/sv.po: New file.
2656 * configure.tgt (sh-*-linux): Set targ_emul, targ_extra_emuls
2657 as little endian default and to support big endian.
2661 * ld.texinfo (Options): Document new option, -nostdlib.
2662 * lexsup.c (OPTION_NOSTDLIB): New definition.
2663 (ld_options): Add entry for "nostdlib".
2664 (parse_args): Handle OPTIONS_NOSTDLIB.
2665 * ldfile.c (ldfile_add_library_path): Don't add directories
2666 to the search path if they weren't specified on the command line
2667 and -nostdlib was specified.
2668 * ld.h (ld_config_type): New member only_cmd_line_lib_dirs.
2672 * lexsup.c (parse_args): Prevent infinite parsing loop when
2673 "-rpath.a" is specified on the command line.
2674 Replace calls to fprintf with calls to einfo.
2678 * ld.texinfo: A historical requirement that MEMORY and SECTIONS
2679 appear only once across all the linker scripts involved in a link
2680 invocation no longer applies. Make the documentation reflect
2685 * configure.tgt: Supports sh3/sh4/sh3eb/sh4eb-unknown-linux-gnu
2687 (sh-*-linux*): Added targ_extra_libpath.
2691 * ldlang.c (lang_size_sections): Keep a valid output_offset field
2692 for padding statements.
2696 * configure.tgt (mmix-*-*): New target.
2697 * Makefile.am (ALL_EMULATIONS): Add eelf64mmix.o and emmo.o.
2698 Add dependencies to match.
2699 * emulparams/mmo.sh, emulparams/elf64mmix.sh, emultempl/mmo.em,
2700 emultempl/mmix-elfnmmo.em, emultempl/mmixelf.em,
2701 scripttempl/mmo.sc: New files.
2702 * gen-doc.texi: @set MMIX.
2703 * ld.texinfo: Ditto.
2704 [MMIX] Add MMIX node.
2705 * Makefile.in: Regenerate.
2709 * ldlang.c: Fix a comment typo.
2713 * configure.host: Move alpha*-*-linux-gnu* entry to generic
2714 entries, and match *-*-linux*.
2718 * ldgram.y (mri_script_command): Surround processing of INCLUDE
2719 with ldlex_script, ldlex_popstate.
2720 (ifile_p1): Likewise.
2721 * ldlex.l (EOF): Don't BEGIN(SCRIPT). Restore lineno from the
2723 (lex_push_file): Save current lineno to lineno_stack. Set lineno
2724 to 1. Don't BEGIN(SCRIPT).
2725 (lex_redirect): Similarly.
2726 * ldmain.c (main): Set yydebug non-zero if YYDEBUG.
2730 * scripttempl/armcoff.sc: Define __EH_FRAME_BEGIN__ and
2731 __EH_FRAME_END__ and accept eh frames into data section.
2732 Add ctor and dtor sections.
2736 * pe-dll.c (autofilter_objectlist): Add gcrt0.o.
2737 (auto-export): Fix indentation.
2741 * pe-dll.c (autofilter_objectlist): Add startup objects
2743 (auto-export): Constify char * p.
2744 Extract file basename and use strcmp rather than ststr
2749 * ldmain.c (get_emulation): Improve comment about the handling
2754 * po/POTFILES.in: Regenerate.
2758 * emultempl/elf32.em (gld*_list_options): Remove extra '\t' from
2759 -z nocopyreloc and -z nocombreloc usage strings.
2763 * emultempl/elf32.em (gld*_list_options): Include -z nocopyreloc
2768 * scripttempl/armaout.sc: Place .bss section after end of aligned
2769 data section to match behaviour of aout code in constructrion of
2774 * pe-dll.c (autofilter_entry_type autofilter_liblist: Add
2775 startup files for mingw32 dlls to list.
2779 * emultempl/elf32.em: Fix shell 'if' usage for portability.
2783 * configure.tgt (targ): Add arm9e-*-elf.
2787 * genscripts.sh: Fix a typo in the last change.
2791 * emultempl/elf32.em (gld_*_list_options): Include -z combreloc and
2792 -z nocombreloc in usage.
2796 * genscripts.sh: Include a comment at the top of each generated
2797 script, explaining its purpose.
2801 * emultempl/elf32.em (parse_args): Handle -z nocopyreloc.
2802 * NEWS: Mention -z nocopyreloc.
2803 * ld.texinfo (Options): Describe nocopyreloc.
2807 * configure: Regenerate.
2811 * ldver.h (ld_program_version): Remove declaration.
2812 * lexsup.c (parse_args): Move printing of copyright message..
2813 * ldver.c (ldversion): .. to here.
2814 Use BFD_VERSION_STRING in place of BFD_VERSION.
2815 (ld_program_version): Remove.
2816 * Makefile.am (Makefile): Depend on bfd/configure.in.
2818 * Makefile.in: Regenerate.
2822 * Makefile.am: Update dependencies with "make dep-am".
2823 * Makefile.in: Regenerate.
2827 * ldlang.c (lang_common): Conditionally inhibit Common allocation.
2828 * lexsup.c: Add --no-define-common commandline option.
2829 * ldgram.y: Add INHIBIT_COMMON_ALLOCATION script command.
2830 * ldlex.l: Likewise.
2831 * ld.h: Add command_line.inhibit_common_definition.
2832 * ldmain.c (main): Initialize.
2833 * ld.texinfo: Document.
2837 * ldlang.c (section_already_linked): Remove assignment to kept_section.
2841 * ldmisc.c (USE_STDARG): Remove.
2842 (info_msg): Define using VPARAMS, VA_OPEN, VA_FIXEDARG, VA_CLOSE.
2847 * ldmisc.h: Remove #ifdef ANSI_PROTOTYPES and non-ansi
2848 declarations. Update copyright.
2852 * pe-dll.c: Remove obsoleted declaration of
2853 pe_get_data_import_dll_name.
2854 (pe_create_import_fixup): Fix thinko.
2856 * ld.texinfo(enable-auto-import): Clarify the explanation.
2860 * pe-dll.c (pe_create_import_fixup): Revert previous patch.
2861 * emultemp/pe.em (pe_data_import_dll): Move definition outside of
2862 DLL_SUPPORT controlled code.
2866 * emultempl/pe.em(pe_data_import_dll): Make static.
2867 (pe_get_data_import_dll_name): New accessor function.
2868 * pe-dll.c(pe_create_import_fixup): call
2869 pe_get_data_import_dll_name() from pe.em, instead of
2870 directly accessing pe_data_import_dll variable from pe.em.
2874 * deffilep.y: Include "safe-ctype.h" instead of <ctype.h>.
2875 (def_file_add_directive): Use ISSPACE instead of isspace.
2876 (def_lex): Use ISDIGIT/ISXDIGIT/ISALPHA/ISALNUM instead of
2877 isdigit/isxdigit/isalpha/isalnum.
2878 * emultempl/aix.em: Include "safe-ctype.h" instead of <ctype.h>.
2879 (gld${EMULATION_NAME}_read_file): Use ISSPACE instead of isspace.
2880 * emultempl/elf32.em: Include "safe-ctype.h" instead of <ctype.h>.
2881 (gld${EMULATION_NAME}_place_orphan): Use ISALNUM instead of
2883 * emultempl/gld960c.em: Include "safe-ctype.h" instead of <ctype.h>.
2884 (gld960_set_output_arch): Use ISUPPER/TOLOWER instead of
2886 * emultempl/sunos.em: Include "safe-ctype.h" instead of <ctype.h>.
2887 (gld${EMULATION_NAME}_search_dir): Use ISDIGIT instead of isdigit.
2888 * ldctor.c: Include "safe-ctype.h" instead of <ctype.h>.
2889 (ctor_prio): Use ISDIGIT instead of isdigit.
2890 * ldfile.c: Include "safe-ctype.h" instead of <ctype.h>.
2891 (ldfile_open_file_search): Use ISALPHA instead of isalpha.
2892 (ldfile_add_arch): Use ISUPPER/TOLOWER instead of
2894 * ldlang.c: Include "safe-ctype.h" instead of <ctype.h>.
2895 (stricpy): Use TOLOWER instead of isupper/tolower.
2896 (lang_leave_overlay_section): Use ISALNUM instead of isalnum.
2897 * ldlex.l: Include "safe-ctype.h" instead of <ctype.h>.
2898 (lex_warn_invalid): Use ISPRINT instead of isprint.
2899 * ldmain.c: Include "safe-ctype.h" instead of <ctype.h>.
2900 (main): For gettext, also set the LC_CTYPE locate facet.
2901 (add_keepsyms_file): Use ISSPACE instead of isspace.
2902 * lexsup.c: Include "safe-ctype.h" instead of <ctype.h>.
2903 (is_num, parse_args): Use ISDIGIT instead of isdigit.
2904 * mpw-elfmips.c: Include "safe-ctype.h" instead of <ctype.h>.
2905 (gldelf32ebmip_place_orphan): Use ISALNUM instead of isalnum.
2906 * mpw-eppcmac.c: Include "safe-ctype.h" instead of <ctype.h>.
2907 (gldppcmacos_read_file): Use ISSPACE instead of isspace.
2908 * pe-dll.c: Include "safe-ctype.h" instead of <ctype.h>.
2909 (quoteput): Use ISSPACE instead of isspace.
2910 (pe_dll_generate_implib, pe_process_import_defs): Use ISALNUM
2915 * deffilep.y (def_stash_module): Constify "name" param.
2917 * pe-dll.c: Replace CONST with const throughout.
2918 (quick_symbol): Constify "n1", "n2", "n3" params.
2919 (make_singleton_name_thunk): Constify "import" param. Make
2920 "buffer_len" a size_t.
2921 (make_import_fixup_entry): Constify "name", "fixup_name",
2922 "dll_symname" params.
2923 (pe_get16): Cast args of bfd_seek. Replace bfd_read with bfd_bread.
2924 (pe_get32): Likewise.
2925 (pe_implied_import_dll): Likewise.
2927 * emultempl/beos.em (sort_by_file_name): Constify "ra", "rb".
2928 (sort_by_section_name): Likewise.
2930 * emultempl/pe.em: Move defines for arm_epoc_pe before bfd.h included.
2931 (make_import_fixup): Cast printf arg, rel->address to long rather
2933 (gld_${EMULATION_NAME}_after_open): Don't compare NULL against int.
2937 * ldmain.c (main): Rename BufferSize to ld_bufsz because HPUX
2938 defines BufferSize. Increase buffer size by one.
2942 * pe-dll.c (pe_walk_relocs_of_symbol): Fix memory leak.
2946 * configure.tgt: Add arm-openbsd target.
2950 * Makefile.am (ALL_EMULATIONS): Move eelf64ppc.o and
2952 (ALL_64_EMULATIONS): Here.
2953 * Makefile.in: Regenerated.
2957 * emultempl/pe.em(make_import_fixup): change signature to
2958 take asection as well as arelec; we need this for proper
2959 error reporting. Only call pe_create_import_fixup() if
2960 there is no attempt to add a constant addend to the reloc;
2961 otherwise, report error condition.
2962 * pe-dll.c(pe_walk_relocs_of_symbol): change signature,
2963 since final argument is a pointer to make_import_fixup().
2964 Change call to cb() to match make_import_fixup() signature.
2965 (make_import_fixup_mark): make buffer_len unsigned.
2966 * pe-dll.h: change signature of pe_walk_relocs_of_symbol.
2970 * ld.texinfo: add verbose documentation for auto-import
2971 direct-addressing workaround, to compliment the terse
2976 * scripttempl/v850.sc: Add gcc_except_table sections.
2980 * emulparams/h8300helf.sh: Move stack to a much higher memory address.
2981 * emulparams/h8300self.sh: Similarly.
2985 * ld.texinfo (Options, --stack): Correct default value for stack
2990 * emultempl/aix.em : Handle import file XMC_XO and syscall symbols.
2994 * emultempl/beos.em: Declare prototypes for comparions functions,
2999 * emultempl/aix.em: Add missing prototype.
3000 * emultempl/lnk960.em: Likewise.
3001 * emultempl/vanilla.em: Likewise.
3002 * emultempl/armcoff.em: Likewise.
3003 * emultempl/armelf_oabi.em: Likewise.
3004 * emultempl/beos.em: Likewise.
3005 * emultempl/gld960c.em: Likewise.
3006 * emultempl/gld960.em: Likewise.
3008 * emulparams/elf64alpha.sh (PARSE_AND_LIST_PROLOGUE): Add parameter
3009 for prototype declaration.
3014 * ldmain.c (get_emulation): Add support for -mips32 and -mips64.
3018 * emultempl/pe.em: Add missing prototypes.
3019 (gld_${EMULATION_NAME}_after_open): Remove extra args to
3020 pe_find_data_imports.
3021 (pr_sym): Add unused attribute.
3025 * configure.tgt (i[3456]86-*-rtems*, m68*-*-rtems*): Change
3026 default from coff to elf.
3030 * emulparams/h8300helf.sh: Resync with h8300elf.sh. Update
3032 * emulparams/h8300self.sh: Similarly.
3036 * Makefile.am (ALL_EMULATIONS): Add eh8300elf.o, eh8300elf.o and
3038 (eh8300elf.c, eh8300helf.c, eh8300self.c): New targets.
3039 * configure.tgt (h8300-*-elf*): New case.
3040 * emulparams/h8300elf.sh, emulparams/h8300helf.sh: New files.
3041 * emulparams/h8300self.sh: New file.
3042 * Makefile.in: Regenerated.
3046 * ldmain.c (main): Rename BSIZE to BufferSize to avoid collision
3052 * Makefile.am (ALL_EMULATIONS): Add eelf64ppc.o and eelf64lppc.o.
3053 (eelf64ppc.c, eelf64lppc.c): Add make targets.
3055 * Makefile.in: Regenerate.
3056 * configure.tgt: Add powerpc64 support. Move pdp11, pjl, pj
3057 entries to correct alphabetical position.
3058 * emulparams/elf64ppc.sh: New.
3059 * emulparams/elf64lppc.sh: New.
3063 * ldmain.c (main): Declare BSIZE as static.
3067 * emultempl/elf32.em (place_orphan): Place orphan .rel* sections
3068 into .rel.dyn resp. .rela.dyn if combreloc.
3069 (get_script): If .x linker script is equal to .xn, only put it
3070 once into the binary.
3071 Add .xc and .xsc scripts.
3072 (parse_args): Handle -z combreloc and -z nocombreloc.
3073 * scripttempl/elf.sc (.rela.sbss): Fix a typo.
3074 For .xc and .xsc scripts put all .rel* or .rela* input sections
3075 but .rel*.plt and PLT-like sections into .rel.dyn resp. .rela.dyn.
3076 * genscripts.sh (GENERATE_COMBRELOC_SCRIPT): Set if SCRIPT_NAME
3078 Strip trailing whitespace from script.
3079 Generate .xc and .xsc scripts if requested.
3080 * ldmain.c (main): Initialize link_info.combreloc and
3081 link_info.spare_dynamic_tags.
3082 * lexsup.c (OPTION_SPARE_DYNAMIC_TAGS): Define.
3083 (ld_options): Add --spare-dynamic-tags option.
3084 (parse_args): Likewise.
3085 * ld.texinfo: Document -z combreloc and -z nocombreloc.
3086 * ldint.texinfo: Document .xc and .xsc linker scripts.
3087 * NEWS: Add notes about -z combreloc and SHF_MERGE.
3091 * emulparams/elf32fr30.sh: Add a newline.
3095 * deffilep.y: Add missing prototypes.
3096 * pe-dll.c: Likewise.
3100 * ldlang.c (insert_pad): Fix typos in last patch.
3102 * ldlang.c: When traversing lang_statement_union_type lists,
3103 consistently use "header.next" rather than "next".
3104 * mpw-eppcmac.c: Likewise.
3105 * emultempl/beos.em: Likewise.
3106 * emultempl/hppaelf.em: Likewise.
3107 * emultempl/pe.em: Likewise.
3108 * ldlang.h (union lang_statement_union): Remove "next" field.
3110 * ldlang.c (insert_pad): Use offsetof macro.
3111 (lang_size_sections): Always neuter padding statements.
3112 * emultempl/hppaelf.em (hppaelf_delete_padding_statements): Delete.
3114 * pe-dll.c (pe_dll_fill_sections): Correct type of "relax" param
3115 passed to lang_size_sections.
3116 (pe_exe_fill_sections): Likewise.
3117 * emultempl/pe.em (output_prev_sec_find): Copied from elf32.em.
3118 (gld_${EMULATION_NAME}_place_orphan): Merge from elf32.em.
3122 * emultempl/aix.em: Formatting fixes.
3126 * ldlang.c (insert_pad): Make use of an existing pad statement if
3127 available. Move code calculating alignment, adjusting section
3128 alignment power, and adjusting dot to ..
3129 (size_input_section): .. here. Remove unused relax param.
3130 (lang_size_sections): Change boolean `relax' param to boolean *.
3131 Adjust call to size_input_section. Make use of insert_pad to
3132 place pad after the assignment statement. If relaxing, zap
3134 (reset_memory_regions): Reset output_bfd section sizes too.
3135 (relax_again): Move to..
3136 (lang_process): ..here. Adjust call to lang_size_sections, and
3137 remove duplicated code.
3138 * ldlang.h (lang_size_sections): Change `relax' param to boolean *.
3142 * ld.texinfo: Document that fill values now use the four least
3144 * emulparams/elf32fr30.sh (NOP): Update.
3145 * emulparams/elf32mcore.sh: Likewise.
3146 * emulparams/elf64_s390.sh: Likewise.
3147 * emulparams/elf_i386.sh: Likewise.
3148 * emulparams/elf_i386_be.sh: Likewise.
3149 * emulparams/elf_i386_chaos.sh: Likewise.
3150 * emulparams/elf_i386_ldso.sh: Likewise.
3151 * emulparams/elf_s390.sh: Likewise.
3152 * emulparams/elf_x86_64.sh: Likewise.
3153 * emulparams/i386moss.sh: Likewise.
3154 * emulparams/i386nw.sh: Likewise.
3155 * emulparams/m68kelf.sh: Likewise.
3156 * scripttempl/elf.sc: Update NOP comment.
3157 * scripttempl/elfi370.sc: Likewise.
3158 * scripttempl/elfm68hc11.sc: Likewise.
3159 * scripttempl/elfm68hc12.sc: Likewise.
3160 * scripttempl/nw.sc: Likewise.
3164 * ldgram.y (saved_script_handle): Initialize to NULL.
3165 * ldmain.c (main): Change check on saved_script_handle.
3169 * emultempl/elf32.em: Formatting fixes.
3170 (output_prev_sec_find): Test for bfd_ind_section too; do so by
3171 looking at sec->owner.
3172 (output_rel_find): Move function inside LDEMUL_PLACE_ORPHAN test.
3173 (gld${EMULATION_NAME}_place_orphan): Add a few comments. Remove
3174 unused code, and reorganize orphan section placement code.
3176 * ldlang.c (wild_doit): Rename to lang_add_section.
3177 * ldlang.h: Here too.
3178 * mpw-elfmips.c: And here.
3179 * emultempl/beos.em: And here.
3180 * emultempl/elf32.em: And here.
3181 * emultempl/hppaelf.em: And here.
3182 * emultempl/pe.em: And here.
3186 * emultempl/needrelax.em: New file.
3187 * emulparams/elf64_ia64.sh (EXTRA_EM_FILE): Reference it.
3188 * Makefile.am (eelf64_ia64.c): Depend on it.
3189 * Makefile.in: Rebuild.
3193 * emultempl/elf32.em: For SEC_EXCLUDE sections, ensure that
3194 output_section is set non-NULL.
3196 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Return
3197 `true' for SEC_EXCLUDE sections so that the generic code doesn't
3198 needlessly create an output_section_statement. Treat a correctly
3199 named output_section_statement with NULL bfd_section as compatible.
3203 * emultempl/generic.em: Support EXTRA_EM_FILE.
3204 (ld_${EMULATION_NAME}_emulation): Support emulation parameters
3205 LDEMUL_BEFORE_PARSE, LDEMUL_SYSLIB, LDEMUL_HLL,
3206 LDEMUL_AFTER_PARSE, LDEMUL_AFTER_OPEN, LDEMUL_AFTER_ALLOCATION,
3207 LDEMUL_SET_OUTPUT_ARCH, LDEMUL_CHOOSE_TARGET,
3208 LDEMUL_BEFORE_ALLOCATION, LDEMUL_GET_SCRIPT, LDEMUL_FINISH,
3209 LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS,
3210 LDEMUL_OPEN_DYNAMIC_ARCHIVE, LDEMUL_PLACE_ORPHAN,
3211 LDEMUL_SET_SYMBOLS, LDEMUL_PARSE_ARGS, LDEMUL_UNRECOGNIZED_FILE,
3212 LDEMUL_LIST_OPTIONS, LDEMUL_RECOGNIZED_FILE,
3213 LDEMUL_FIND_POTENTIAL_LIBRARIES.
3217 * scripttempl/elf.sc, scripttempl/elfd30v.sc,
3218 scripttempl/elfm68hc11.sc, scripttempl/elfm68hc12.sc,
3219 scripttempl/v850.sc: Keep .jcr data.
3225 * ldgram.y (had_script): Change name to saved_script_handle.
3226 Change type to file handle.
3227 * ld.h (had_script): Rename and retype.
3228 * ldfile.c (ldfile_open_command_file): Save the file handle
3229 used in saved_script_handle.
3230 * lexsup.c (parse_args): Do not allow -c option to alter
3231 saved_script_handle.
3232 * ldmain.c (main): Print out the linker script used if
3233 --verbose is given. Check saved_script_handle to obtain the
3234 external linker script used, or if NULL, dump the builtin
3236 * ld.texinfo: Document that --verbose now dumps the linker
3237 script used, regardless of whether it was an internal or an
3242 * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
3244 * configure: Regenerate.
3248 * emultempl/elf32.em (output_prev_sec_find): Add missing prototype.
3250 * scripttempl/elf.sc: Move non-text .dynamic section before
3251 .plt/.got/.sdata* group.
3252 (OTHER_GOT_SECTIONS): Move to immediately after .got.
3253 (OTHER_SDATA_SECTIONS): Add.
3254 * emulparams/criself.sh: Use OTHER_SDATA_SECTIONS rather than
3256 * emulparams/crislinux.sh: Likewise.
3257 * emulparams/elf32b4300.sh: Likewise.
3258 * emulparams/elf32bmip.sh: Likewise.
3259 * emulparams/elf32bmipn32.sh: Likewise.
3260 * emulparams/elf32bsmip.sh: Likewise.
3261 * emulparams/elf32btsmip.sh: Likewise.
3262 * emulparams/elf32ebmip.sh: Likewise.
3263 * emulparams/elf32elmip.sh: Likewise.
3264 * emulparams/elf32l4300.sh: Likewise.
3265 * emulparams/elf32lmip.sh: Likewise.
3266 * emulparams/elf32lsmip.sh: Likewise.
3267 * emulparams/elf32ltsmip.sh: Likewise.
3268 * emulparams/elf64bmip.sh: Likewise.
3269 * emulparams/elf64btsmip.sh: Likewise.
3270 * emulparams/elf64ltsmip.sh: Likewise.
3274 * genscripts.sh: Source the emulparams script before each output
3275 script is generated so that variables like `RELOCATING' may affect
3276 variables defined in the emulparams script.
3280 * emultempl/aix.em: ldexp.h,ldlang.h,ldfile.h,ldemul.h go in this
3283 * emultempl/beos.em (sort_sections): Modify for 2001-08-03 change,
3284 ie. iterate over wild_statement.section_list.
3285 (gld${EMULATION_NAME}_place_orphan): Likewise.
3289 * scripttempl/elfm68hc12.sc (FINISH_CODE, FINISH_RELOC): New to handle
3290 .fini[0-4] sections used by _exit
3291 (CTOR, DTOR): Export ctor/dtor symbols; move them to ROM.
3292 (*.text,*.data,*.bss): Take into account .text.*, .data.*, .bss.*.
3293 * scripttempl/elfm68hc11.sc: Likewise.
3297 * emultempl/beos.em (init): Add the missing initialization.
3301 * ld.texinfo (Input Section Basics): Clarify ordering of output
3303 * ldlang.c (callback_t): Add wildcard_list param.
3304 (walk_wild_section): Remove "section" param. Rewrite for
3305 lang_wild_statement_type change. Remove unique_section_p test.
3306 (walk_wild_file): Remove "section" param.
3307 (walk_wild): Remove "section" and "file" params.
3308 (lang_gc_wild): Likewise.
3309 (wild): Likewise. Modify for lang_wild_statement_type change.
3310 (wild_sort): Likewise. Add "sec" param.
3311 (gc_section_callback): Likewise.
3312 (output_section_callback): Likewise. Do unique_section_p test.
3313 (map_input_to_output_sections): Modify call to wild.
3314 (lang_gc_sections_1): Likewise.
3315 (print_wild_statement): Modify for lang_wild_statement_type
3317 (lang_add_wild): Replace filename, filenames_sorted param with
3318 filespec. Replace section_name, sections_sorted,
3319 exclude_filename_list with section_list.
3320 * ldlang.h (lang_add_wild): Here too.
3321 (lang_wild_statement_type): Replace section_name, sections_sorted,
3322 and exclude_filename_list with section_list.
3323 * ldgram.y (current_file): Delete.
3324 (%union): Add wildcard_list.
3325 (file_NAME_list): Set type to wildcard_list. Build a linked list
3326 rather than calling lang_add_wild for each entry.
3327 (input_section_spec_no_keep): Call lang_add_wild here instead.
3328 * ld.h (struct wildcard_list): Declare.
3329 * mri.c (mri_draw_tree): Modify to suit new lang_add_wild.
3333 * ldmain.c (main): initialize link_info.pei386_auto_import
3334 * pe-dll.c: new tables for auto-export filtering
3335 (auto_export): change API, pass abfd for contextual filtering.
3336 Loop thru tables of excluded symbols instead of comparing
3341 * pe-dll.c: new variable pe_dll_enable_extra_debug. New
3342 static variable current_sec (static struct sec *). Add
3343 forward declaration for add_bfd_to_link.
3344 (process_def_file): Don't export undefined symbols. Do not
3345 export symbols starting with "_imp__". Call auto_export()
3347 (pe_walk_relocs_of_symbol): New function.
3348 (generate_reloc): add optional extra debugging
3349 (pe_dll_generate_def_file): eliminate extraneous initial blank
3351 (make_one): enlarge symtab to make room for __nm__ symbols
3352 (DATA auto-import support).
3353 (make_singleton_name_thunk): New function.
3354 (make_import_fixup_mark): New function.
3355 (make_import_fixup_entry): New function.
3356 (pe_create_import_fixup): New function.
3357 (add_bfd_to_link): Specify that 'name' argument is a CONST
3359 * pe-dll.h: declare new variable pe_dll_extra_pe_debug;
3360 declare new functions pe_walk_relocs_of_symbol and
3361 pe_create_import_fixup.
3362 * emultempl/pe.em: add new options --enable-auto-import,
3363 --disable-auto-import, and --enable-extra-pe-debug.
3364 (make_import_fixup): New function.
3365 (pe_find_data_imports): New function.
3366 (pr_sym): New function.
3367 (gld_${EMULATION_NAME}_after_open): Add optional extra pe
3368 debugging. Call pe_find_data_imports. Mark .idata as DATA, not
3373 * ld.texinfo: add additional documentation for
3374 --export-all-symbols. Document --out-implib,
3375 --enable-auto-image-base, --disable-auto-image-base,
3376 --dll-search-prefix, --enable-auto-import, and
3377 --disable-auto-import.
3378 * ldint.texinfo: Add detailed documentation on auto-import
3383 * ld.texinfo (Simple Assignments): Fix computation in SECTIONS
3388 * Makefile.am: Update dependencies with "make dep-am".
3389 * Makefile.in: Regenerate
3393 * ldcref.c (check_section_sym_xref): New function.
3394 (check_nocrossrefs): Call it.
3395 (check_nocrossref): Interate over h->refs here instead of..
3396 (check_refs): ..here. Pass in the symbol name, section, and bfd
3397 rather than hash_entry pointers.
3398 (struct check_refs_info): Keep symbol name rather than hash entry.
3400 (check_reloc_refs): Tweak for above changes in check_refs_info.
3401 Only report references to section syms when symname is NULL to
3402 prevent duplicate messages for the same reloc.
3406 * ldexp.c (exp_print_tree): Use stderr if config.map_file is not
3407 available. Do not print NULL trees.
3408 (exp_print_token): Print unknown tokens with values > 126 as
3409 decimal values not ASCII characters.
3411 * ldlang.c (lang_leave_overlay): If a region is specified assign
3412 it to all sections inside the overlay unless they have been
3413 assigned to the own, non-default, memory region.
3415 * README: Add header for consistency with other README files.
3419 * emultempl/elf32.em (output_prev_sec_find): Never return
3420 bfd_abs_section_ptr, bfd_com_section_ptr nor
3421 bfd_und_section_ptr.
3425 * Makefile.am (em32relf.c): Change dependency from generic.em to
3427 * Makefile.in: Regenerate.
3431 * configure.tgt (i386-*-netbsdelf*): New target.
3432 (i386-*-netbsd*): Set targ_extra_emuls to `elf_i386'
3436 * emultempl/elf32.em (output_prev_sec_find): New.
3437 (place_orphan): Use it.
3441 * ldmain.c (main): Fix typos in the last change.
3445 * ldmain.c (main): Disallow -F and -f without -shared.
3449 * emultempl/pe.em (after_open): Check for the output_bfd not
3450 having any coff_data structure allocated to it.
3454 * emultempl/elf32.em: Do not assuming that contents of the buffer
3455 returned from basename function will remain unchanged accross other
3460 * scripttempl/elf.sc (DYNAMIC_PAD): Revert the change made on
3461 2001-07-03. It creates dynamic entries even for static binaries.
3465 * scripttempl/elf.sc (DYNAMIC_PAD): New variable.
3466 (DYNAMIC): Use it to reserve few dynamic entries for
3471 * emulparams/hppa64linux.sh: New file.
3472 * configure.tgt: hppa*64*-*-linux* uses hppa64linux.sh
3473 * Makefile.am (ALL_64_EMULATIONS): Add ehppa64linux.o
3474 (ehppa64linux.c): Add rule to make it.
3476 * Makefile.in: Regenerate.
3480 * ld.texinfo (Options, -r): Mention restrictions when using
3481 different object formats.
3485 * ldlang.c (lang_check): Emit fatal error if relocatable link
3486 between different object flavours with relocations in input.
3490 * ld.texinfo (-E, --export-dynamic): Mention --version-script.
3491 (--version-script): Mention the language support.
3495 * ldlang.c (lang_check): Revert the change mode on 2001-06-15.
3499 * Makefile.am (ld.1): Remove the prefix `$(srcdir)/'.
3500 (diststuff): Add $(MANS).
3501 * Makefile.in: Regenerated.
3507 * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation):
3508 Update for API change in bfd_elf${ELFSIZE}_size_dynamic_sections.
3509 * mpw-elfmips.c (gldelf32ebmip_before_allocation): Ditto.
3510 * ld.h (args_type): Remove member export_dynamic. All users
3511 changed to use struct bfd_link_info member.
3513 * Makefile.am (ecriself.c, ed10velf.c, ei386moss.c): Depend on
3514 $(srcdir)/emultempl/elf32.em, not $(srcdir)/emultempl/generic.em.
3515 * Makefile.in: Regenerate.
3519 * ldlang.c (init_os): Add the newline to the einfo call.
3520 (lang_check): Likewise.
3521 (lang_do_version_exports_section): Likewise.
3525 * lexsup.c (parse_args); Save optind to report unrecognized
3530 * ldlang.c (lang_check): Emit fatal error if relocatable link
3531 between different object flavours.
3533 * lexsup.c (parse_args) <case OPTION_EXPORT_DYNAMIC, case 'E'>:
3534 Set new link_info member export_dynamic.
3535 * ldmain.c (main): Initialize new link_info member export_dynamic.
3539 * ldlang.c (walk_wild): Only call walk_wild_file if
3540 lookup_name returns something.
3541 (lookup_name): If load_symbols fails, return NULL.
3542 (load_symbols): Change to a boolean function.
3543 (open_input_bfds): If load_symbols fails then do not make the
3548 * ldlang.c (record_bfd_errors): Remove.
3550 * emultempl/aix.em: Fix copyright dates.
3554 * elf_x86_64.sh (NONPAGED_TEXT_START_ADDR): Increase.
3555 (TEXT_START_ADDR): Likewise.
3559 * configure.host: Set HOSTING_CRT0/HOSTING_LIBS correctly for s/390.
3563 * emultempl/pe.em (init): Reduce default stack reserve to 0x200000.
3567 * ldlang.c (open_input_bfds): Don't change the bfd error
3568 handler whilst loading symbols.
3572 * configure.tgt: Remove i370-mvs architecture, it is not currently
3577 * emulparams/ppcmacos.sh: Add SYSCALL_MASK and SYMBOL_MODE_MASK
3578 like emulparams/aixppc.sh.
3582 * emultempl/beos.em (gld${EMULATION_NAME}_before_parse): Move
3583 setting of output_filename after bfd_scan_arch.
3584 * emultempl/pe.em: Likewise.
3588 * emulparams/aixrs6.sh: Add SYSCALL_MASK and SYMBOL_MODE_MASK
3589 like emulparams/aixppc.sh.
3591 * emultempl/aix.em (sc): Use ${srcdir}/emultempl/ostring.sed
3592 instead of ${srcdir}/emultempl/stringify.sed.
3596 * emulparams/elf64_aix.sh: Change settings to match IBM linker
3601 * configure.host: Replace linuxoldld with linux*oldld.
3602 * configure.tgt: Likewise.
3606 * emultempl/stringify.sed: Removed again.
3610 * emultempl/aix.em (OUTPUT_ARCH): Defined.
3611 (gld${EMULATION_NAME}_before_parse): Initialize
3612 ldfile_output_architecture, ldfile_output_machine and
3613 ldfile_output_machine_name from ${OUTPUT_ARCH} if possible.
3614 * emultempl/beos.em: Likewise.
3615 * emultempl/elf32.em: Likewise.
3616 * emultempl/linux.em: Likewise.
3617 * emultempl/mipsecoff.em: Likewise.
3618 * emultempl/pe.em: Likewise.
3619 * emultempl/sunos.em: Likewise.
3623 * emultempl/aix.em : (gld${EMULATION_NAME}_read_file)
3624 udate import file format.
3625 (change_symbol_mode) New, same
3626 (is_syscall) New, same
3627 * emulparams/aixppc.sh : add SYSCALL_MASK and SYMBOL_MODE_MASK
3628 * emulparams/aixppc64.sh : same
3629 * emulparams/aixrs6.sh : same
3630 * emulparams/ppcmacos.sh : same
3631 * emultempl/aix.em : use strtoull to parse options
3632 * Makefile.am : add eaixppc64 emulation for xcoff64
3633 * Makefile.in : same
3634 * configure.tgt : same
3636 * scripttempl/aix.sc : default text section offset to 0x10000000
3637 default data section offset to 0x20000000
3638 add .sv3264 and .sv64 pseudo sections
3639 loader and debug sections use the currect section offset.
3641 * emultempl/aix.em : Add xcoff64 support
3642 Add -binitfini support
3643 (gld${EMULATION_NAME}_before_parse) -binitfini
3644 (gld${EMULATION_NAME}_parse_args) same
3645 (gld${EMULATION_NAME}_before_allocation) format change for special
3648 * emulparams/aixppc64.sh : New file for xcoff64 support
3652 * emultempl/elf32.em (ELF_INTERPRETER_SET_DEFAULT): Use this new
3653 variable to avoid non-portable shell construct.
3657 * ldmain.c (get_emulation): Add -mips5 command line argument.
3661 * emulparams/elf_i386_ldso.sh: New, copied from elf_i386.sh.
3662 (ELF_INTERPRETER_NAME): Define it.
3663 * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation): Use
3665 * configure.tgt (targ_emul, targ_extra_emuls)
3666 [i[3456]86-*-solaris2*, i[3456]86-*-solaris*]: Use elf_i386_ldso
3667 as primary, elf_i386 as extra.
3668 * Makefile.am (ALL_EMULATIONS): Added eelf_i386_ldso.o.
3669 (eelf_i386_ldso.c): New rule.
3670 * Makefile.in: Rebuilt.
3674 * lexsup.c (ld_options): Allow -I to be an alias for
3675 --dynamic-linker. This is for Solaris compatability.
3676 * ld.texinfo: Document that -I can be used.
3681 * ldlang.c (wild_doit): Use linker_has_input to reliably determine
3682 whether an input section is the first one assigned to an output
3684 Assorted formatting fixes.
3688 * Makefile.am (ld.dvi): Search bfd/doc for texinfo files.
3689 * Makefile.in: Ditto.
3693 * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Put
3694 .gnu.linkonce.ia64unw{,i} sections into corresponding .IA_64.unwind*
3696 * emulparams/elf64_aix.sh (OTHER_READONLY_SECTIONS): Likewise.
3700 * ldlang.c (lang_process): Call bfd_merge_sections.
3704 * ldgram.y: Fix typo.
3708 * emultempl/elf32.em: Include "libiberty.h".
3709 (gld${EMULATION_NAME}_vercheck): Call basename () to get the
3710 basename of the bfd filename.
3711 (gld${EMULATION_NAME}_stat_needed): Likewise.
3712 (gld${EMULATION_NAME}_try_needed): Likewise.
3713 (gld${EMULATION_NAME}_open_dynamic_archive): Likewise.
3717 * emultempl/pe.em: Include <ctype.h>.
3721 * emulparams/elf32openrisc.sh: New file.
3723 * Makefile.am: Add OpenRISC target.
3724 * Makefile.in: Regenerated.
3726 * configure.tgt: Add openrisc-*-* mapping.
3730 * emultempl/aix.em: Replace buystring with xstrdup.
3731 * emultempl/beos.em: Replace buystring with xstrdup.
3735 * ldfile.c: Include "libiberty.h".
3736 * ldlex.l: Likewise.
3738 * ldmisc.c (buystring): Removed.
3739 * ldmisc.h: Likewise.
3741 * ldfile.c: Replace buystring with xstrdup.
3742 * ldlang.c: Likewise.
3743 * ldlex.l: Likewise.
3744 * ldmain.c: Likewise.
3745 * ldmisc.c: Likewise.
3746 * lexsup.c: Likewise.
3747 * mpw-eppcmac.c: Likewise.
3751 * emulparms/elf_x86_64.sh (MAXPAGESIZE): Fix value.
3755 * ldlang.c (load_symbols): Give emulation a chance
3756 to process unrecognized file before fatal error is
3757 reported, not after.
3761 * configure.tgt: Add arm-vxworks target.
3762 * scripttempl/armcoff.sc: Support .text or .data as a section name
3768 * ld.texinfo: Document --fatal-warnings.
3771 * ldmisc.c (vfinfo): Set flag to inhibit making executable if
3772 warnings have been turned into errors.
3773 * lexsup.c (OPTION_WARN_FATAL): Define.
3774 (ld_options): Entry for --fatal-warnings.
3775 (parse_args): Handle OPTION_WARN_FATAL.
3776 * ld.h (ld_config_type): Add fatal_warnings field.
3780 * ldmain.c (main): Default to discard_sec_merge.
3781 * lexsup.c (OPTION_DISCARD_NONE): Define.
3782 (ld_options): Add --discard-none.
3783 (parse_args): Handle OPTION_DISCARD_NONE.
3784 * ldlang.c (wild_doit): SEC_MERGE should be set in the output
3785 section only if SEC_MERGE and SEC_STRINGS flags and entsize of
3786 all its input sections match.
3790 * Makefile.am (ALL_EMULATIONS): Add eelf32ltsmip.o.
3791 (ALL_64_EMULATIONS): Add eelf64btsmip.o and eelf64ltsmip.o.
3792 (eelf32ltsmip.c): New target.
3793 (eelf64btsmip.c): Likewise.
3794 (eelf64ltsmip.c): Likewise.
3795 * Makefile.in: Regenerated.
3797 * configure.tgt (mips*el-*-linux-gnu): Uses traditional MIPS
3799 (mips*-*-linux-gnu*): Likewise.
3801 * emulparams/elf32ltsmip.sh: New. Traditional little endian
3803 * emulparams/elf64btsmip.sh: New. Traditional 64bit big endian
3805 * emulparams/elf64ltsmip.sh: New. Traditional 64bit little
3810 * emulparams/criself.sh (EXECUTABLE_SYMBOLS): Cannot provide
3811 correct value of __Stext here.
3812 (TEXT_START_SYMBOLS): Define; always define __Stext, to start of
3815 * emulparams/crislinux.sh: Remove FIXME.
3819 * emulparams/hppalinux.sh (MAXPAGESIZE): Set to 64k.
3820 (TEXT_START_ADDR, TARGET_PAGE_SIZE): Likewise.
3824 * configure.tgt (cris-*-*): Change default emulation to criself.
3825 (cris-*-*aout*): New rule.
3829 * emulparams/hppalinux.sh (MAXPAGESIZE): Set to 0x4000.
3830 (TEXT_START_ADDR, TARGET_PAGE_SIZE): Ditto.
3834 * ld.texinfo (Overview): Fix syntax in texi code.
3838 * ld.texinfo: Put @c man indications to generate the ld man page.
3839 When generating man, define all the variables. Define SEEALSO
3840 and SYNOPSIS. Re-organize some lines to avoid the cross references.
3841 * Makefile.am (MANCONF, TEXI2POD, POD2MAN): New variables.
3842 (ld.1): Generate from ld.texinfo.
3843 * Makefile.in: Regenerate.
3847 * scripttempl/i386go32.sc: Support the GCC flags '-ffunction-sections'
3848 and '-fdata-sections'. Set the VMA of STABS sections to zero.
3852 * emultmpl/elf32.em (gld${EMULATION_NAME}_search_needed): If NAME
3853 is an absolute path look only for this file and not along the path.
3857 * emultempl/elf32.em (OPTION_GROUP): New macro.
3858 Add new option Bgroup to longopts.
3859 (gld*_parse_args): Handle GROUP_OPTION and recognize -z defs.
3860 (gld*_list_options): Add -Bgroup and -z defs.
3861 * ld.1: Document -Bgroup and -z defs.
3862 * ld.texinfo: Likewise.
3866 * scripttempl/elfd10v.sc (.rodata,.rodata1,.data1,.sdata): Deal
3867 with sections created by -fdata-sections.
3868 (.dynbss,.bss): Ditto.
3872 * emultempl/m68kelf.em (m68k_elf_after_allocation): Call
3873 after_allocation_default, not gld..._before_allocation.
3877 * configure.in (BFD_VERSION): New.
3878 (AM_INIT_AUTOMAKE): Use $BFD_VERSION.
3879 * configure: Regenerate.
3880 * Makefile.am: Run "make dep-am"
3881 * Makefile.in: Regenerate.
3885 * emulparams/elf64_aix.sh: Add additional read-only sections;
3886 uncomment lines which are now required.
3890 * ldlang.c (open_input_bfds): Set the bfd error handler so
3891 that problems can be caught whilst loading symbols.
3892 (record_bfd_errors): New function: Report BFD errors and mark
3893 the executable output as being invalid.
3897 * configure.host: Add configuration for ia64-*-aix*.
3898 * Makefile.am (ALL_64_EMULATIONS): Add emulation for ia64-*-aix*.
3899 Add dependencies for eelf64_aix.c.
3900 * Makefile.in: Regenerate.
3901 * configure.tgt: Add ia64-*-aix* mapping.
3902 * emulparams/elf64_aix.sh: Add settings for elf64 on aix5.
3906 * ldfile.c (ldfile_open_file): Set entry->search_dirs_flag to
3907 false if we found the file.
3911 * configure.tgt: Add FreeBSD/Alpha, FreeBSD/x86-64, FreeBSD/ia64,
3912 FreeBSD/PowerPC, FreeBSD/arm, and FreeBSD/sparc64 entries.
3916 * Makefile.am: Add PDP-11 target.
3917 * configure.tgt: Likewise.
3918 * emulparams/pdp11.sh: New file.
3922 * configure.host: Add a generic FreeBSD configuration entry such that
3923 all [modern] FreeBSD systems on all platforms will look the same.
3927 * configure.tgt: Remove mention of earmelf_linux26.
3931 * emulparams/elf64_ia64.sh (OTHER_GOT_SYMBOLS): Remove.
3935 * ldexp.h (node_type): Add etree_provided.
3936 * ldexp.c (exp_fold_tree): Handle etree_provided. Set the node
3937 type to etree_provided if defined by PROVIDE. Allow updating
3939 (exp_print_tree): Handle etree_provided.
3940 * mpw-elfmips.c (gldelf32ebmip_find_exp_assignment): Handle
3945 * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Add
3946 .IA_64.unwind.* pattern to unwind table section and
3947 .IA_64.unwind_info* pattern to unwind info section.
3951 * Makefile.am: Add linux target for S/390.
3952 * Makefile.in: Likewise.
3953 * configure.host: Likewise.
3954 * configure.tgt: Likewise.
3955 * emulparams/elf64_s390.sh: New file.
3956 * emulparams/elf_s390.sh: New file.
3960 * configure.tgt (sparc64-*-linux-gnu*): Add elf32_sparc into
3962 (sparc-*-linux-gnu*): Add elf64_sparc into targ_extra_libpath.
3966 * Makefile.am: Remove mention of earmelf_linux26.
3967 * Makefile.in: Regenerate.
3971 * emulparams/armelf_linux.sh (TEXT_START_ADDR): Set to 0x8000.
3972 * emulparams/armelf_linux26.sh: Delete.
3973 * configure.tgt: Remove mention of armelf_linux26 emulation.
3977 * ld.1: Replace occurances of -oformat with --oformat.
3981 * ldlang.c (lang_leave_overlay): Don't set lma_region when
3982 load_base is specified.
3986 * emultempl/elf32.em: Correct spelling in comments and listed
3991 * ldlang.c (lang_leave_overlay): Only set lma_region from the
3992 default for the first section of a group of overlay sections.
3996 * Makefile.am (GENSCRIPTS): Pass exec_prefix.
3997 * Makefile.in: Regenerate.
3998 * genscripts.sh: Use exec_prefix parameter to specify tool lib.
3999 Check for null tool_dir.
4003 * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Add IA_64.unwind
4004 and IA_64.unwind.info.
4008 * ldlang.c (lang_check): Merge the private data only if the
4009 input file has contents.
4013 * emulparams/hppalinux.sh (OUTPUT_FORMAT): Set to elf32-hppa-linux.
4015 * emultempl/hppaelf.em (hppaelf_after_parse): New function,
4016 enabling search for libmilli. On a relocatable link, make .text
4018 (LDEMUL_AFTER_PARSE): Define.
4019 (hppaelf_finish): Correct spelling of relocatable in comments.
4021 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
4022 rummage through the script for sections on the unique list.
4023 Correct length of strncmp for ".note".
4024 (gld${EMULATION_NAME}_check_needed): Rearrange function.
4026 * ldlang.c (unique_section_list): New var.
4027 (unique_section_p): New function.
4028 (walk_wild_section): Don't match sections on unique_section_list.
4029 (lang_add_unique): New function.
4030 Correct spelling of relocatable in comments.
4032 * ldlang.h (struct unique_sections): Declare.
4033 (unique_section_list): Declare.
4034 (unique_section_p): Declare.
4035 (lang_add_unique): Declare.
4037 * lexsup.c (ld_options): Allow --unique to take an optional arg.
4038 (parse_args [OPTION_UNIQUE]): Call lang_add_unique.
4040 * ld.texinfo (--unique): Update.
4044 * lexsup.c (parse_args): Remove spurious white space.
4048 * lexsup.c (parse_args): Update copyright date.
4052 * configure.host: Set HOSTING_LIBS appropriately for ix86-cygwin.
4056 * scripttempl/h8300.sc: Fix formatting. Fix a comment typo.
4057 * scripttempl/h8300h.sc: Fix formatting.
4058 * scripttempl/h8300s.sc: Likewise.
4059 * scripttempl/h8500.sc: Likewise.
4060 * scripttempl/h8500b.sc: Likewise.
4061 * scripttempl/h8500c.sc: Likewise.
4062 * scripttempl/h8500m.sc: Likewise.
4063 * scripttempl/h8500s.sc: Likewise.
4067 * emultempl/elf32.em: Only perform Linux ld hints processing when
4072 * ld.texinfo (Bug Reporting): Update email address for reports.
4076 * lexsup.c (parse_args): Set opterr to 0 and detect unparsed long
4077 options by checking for a return value of '?' not -1.
4081 * lexsup.c (struct ld_option): Add new enum value:
4083 (ld_options[]): Change -omagic, -output and -oformat options
4084 to be EXACTLY_TWO_DASHES.
4085 (OUTPUT_COUNT): Use ARRAY_SIZE.
4086 (parse_args): Change parameter 'argc' to unsigned.
4087 Place EXACTLY_TWO_DASHES options into new really_longopts
4089 If getopt_long_only fails, try calling getopt_long using the
4090 really_longopts array.
4091 (help): Print a double dash for both EXACTLY_TWO_DASHES and
4094 * ldlex.h: Fix prototype of parse_args.
4096 * ld.texinfo: Document that long options starting with 'o'
4097 must be preceeded by two dashes. Change example of a single
4098 dashed long option from -oformat to -trace-symbol.
4102 * emultempl/pe.em (OPTION_NO_DEFAULT_EXCLUDES): Define.
4103 (longopts[]): New --no-default-excludes option.
4104 (gld_${EMULATION_NAME}_list_options): Document.
4105 (gld_${EMULATION_NAME}_parse_args): Handle.
4109 * ldlang.c (new_stat): Revert the last beautification with "innocent"
4110 whitespace, it breaks the K&R C preprocessor.
4114 * ld.texinfo: Add notes about --whole-archive and gcc.
4118 * lexsup.c (OPTION_ALLOW_SHLIB_UNDEFINED): Define.
4119 (ld_options): Entry for --allow-shlib-undefined.
4120 (parse_args): Handle OPTION_ALLOW_SHLIB_UNDEFINED.
4121 * ldmain.c (main): Initialize link_info.allow_shlib_undefined
4123 * ld.texinfo: Document new command line switch.
4127 * emulparams/elf32ppc.sh (OTHER_READWRITE_SECTIONS):
4128 .fixup is actually read/write.
4129 * emulparams/elf32lppc.sh (OTHER_READWRITE_SECTIONS): Likewise.
4130 * emulparams/elf32ppcsim.sh (OTHER_READWRITE_SECTIONS): Likewise.
4131 * emulparams/elf32lppcsim.sh (OTHER_READWRITE_SECTIONS): Likewise.
4135 * NEWS: Add note about x86_64 architecture.
4139 * scripttempl/i386go32.sc: Use PROVIDE with _etext, _edata, _end.
4140 Set DWARF2 sections to a VMA of zero.
4144 * configure.tgt (arm-*-rtems*, a29k-*rtems*, h8300-*-rtems*):
4146 (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
4147 (sparc*-*-rtems*): Switched from a.out to ELF.
4151 * Makefile.am (ALL_EMULATIONS): Add eelf_x86_64.o
4152 (eelf_x86_64.c): New.
4153 * Makefile.in: Regenerate.
4154 * configure.tgt: Add support for x86_64-*-linux-gnu*.
4155 * emulparams/elf_x86_64.sh: New.
4159 * emulparams/crislinux.sh (ENTRY): Change back to _start.
4160 (TEXT_START_SYMBOLS): Remove conditional setting of __start.
4162 * scripttempl/crisaout.sc: Change all RELOCATING not related to
4163 merging non-a.out sections into CONSTRUCTING.
4167 * ld.1 (COPYING): Mention that the GNU Free Documentation
4168 License is present in the sources, but not the output, and
4169 also available from the GNU website.
4170 (GNU Free Documentation License): Comment out this section.
4174 * emulparams/elf64alpha.sh (ENTRY): Remove leading underscore as ELF
4179 * ld.1: Remove old date so it does not give the impression the manpage
4184 * configure.tgt (xscale-coff): Add target.
4185 (xscale-elf): Add target.
4189 * ldmain.c (main): Remove redundant init of config.make_executable
4194 * emulparams/elf64alpha.sh (MAXPAGESIZE): Typo -- 64k, not 1M.
4198 * scripttempl/h8300.sc: Fix formatting.
4199 * scripttempl/h8300h.sc: Likewise.
4200 * scripttempl/h8300s.sc: Likewise.
4204 * scripttempl/elf32avr.sc: Fix bug in .eeprom segment.
4208 * emultempl/pe.em: Define ___start_SECNAME and ___stop_SECNAME
4209 around orphan sections whose names can be represented in C.
4213 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): New local
4214 hold_sdata. If SEC_SMALL_DATA set, set place to hold_sdata.
4218 * ld.texinfo: Add GNU Free Documentation License.
4219 * ldint.texinfo: Add GNU Free Documentation License.
4220 * ld.1: Add GNU Free Documentation License.
4224 * ldlex.l (yy_create_string_buffer): Init yy_is_our_buffer,
4225 yy_is_interactive, yy_at_bol, and yy_fill_buffer.
4227 * Makefile.am (DISTCLEANFILES): Add stringify.sed.
4228 Move 2000-11-02 Makefile.in changes to this file.
4229 * Makefile.in: Regenerate.
4233 * scripttempl/h8300.sc: Use ${CONSTRUCTING...} to enclose
4234 constructors and destructors.
4235 * scripttempl/h8300h.sc: Ditto.
4236 * scripttempl/h8300s.sc: Ditto.
4237 * scripttempl/h8500.sc: Ditto.
4238 * scripttempl/h8500b.sc: Ditto.
4239 * scripttempl/h8500c.sc: Ditto.
4240 * scripttempl/h8500m.sc: Ditto.
4241 * scripttempl/h8500s.sc: Ditto.
4242 * scripttempl/v850.sc: Ditto.
4243 * scripttempl/w65.sc: Ditto.
4244 * scripttempl/z8000.sc: Ditto.
4248 * Makefile.in (e_i386_chaos.c): New rule.
4249 (ALL_EMULATIONS): Added e_i386_chaos.o.
4250 * emulparams/elf_i386_chaos.sh: New file.
4251 * configure.tgt: Recognise i[3456]86-chaosdev-storm-chaos.
4255 * emulparams/elf64_sparc.sh (TEXT_START_ADDR,
4256 NONPAGED_TEXT_START_ADDR): Set to 4GB for Solaris targets.
4257 Fix sed invocation, so that it coped with '/' in Solaris 64bit
4258 library path suffix.
4263 * scripttempl/crisaout.sc (.text, .data): Pad, with ALIGN (32),
4264 for consecutive sections.
4268 * lexsup.c: New option OPTION_TARGET_HELP. Prints all target specific
4270 * ld.texinfo: Added notes about this new option.
4274 * emultempl/pe.em (_after_open): Add tests of return values from
4275 bfd functions. Emit appropriate error messages if necessary.
4279 * emultempl/pe.em (_after_open): Delete 'is2' and 'nsyms'
4280 local variables - they are not used, but leave in the call to
4281 bfd_canonicalize_symtab.
4282 (_open_dynamic_archive): Add #ifdef DLL_SUPPORT around use of
4283 pe_dll_search_prefix.
4287 * emultempl/pe.em (pe_dll_search_prefix): New variable,
4288 (longopts): New --dll-search-prefix option.
4289 (gld_${EMULATION_NAME}_list_options): Document.
4290 (gld_${EMULATION_NAME}_parse_args): Handle.
4291 (gld_${EMULATION_NAME}_open_dynamic_archive): When linking
4292 dynamically, search for a dll named '<prefix><basename>.dll'
4293 in preference to 'lib<basename>.dll' if --dll-search-prefix
4298 * ldlang.c (section_already_linked): Set kept_section instead of
4303 * deffile.h: Fix formatting.
4304 * lexsup.c: Likewise.
4309 * pe-dll.c (make_one): Do not generate code thunk for DATA
4311 (process_def_file): deduce DATA flag for auto-export sumbols.
4315 * ld.h: Fix formatting.
4316 * ldcref.c: Likewise.
4317 * ldctor.h: Likewise.
4318 * ldemul.c: Likewise.
4319 * ldemul.h: Likewise.
4320 * ldexp.c: Likewise.
4321 * ldexp.h: Likewise.
4322 * ldfile.c: Likewise.
4323 * ldfile.h: Likewise.
4324 * ldlang.c: Likewise.
4325 * ldlang.h: Likewise.
4326 * ldmain.c: Likewise.
4327 * pe-dll.c: Likewise.
4329 * pe-dll.c: Revert some formatting fixes.
4333 * pe-dll.c: Fix formatting.
4337 * ldlang.c: Fix formatting.
4341 * pe-dll.c (fill_edata): initialize entire block
4342 (make_one): fill in correct section.
4346 * ldexp.c: Fix formatting.
4350 * emultempl/pe.em (gld_*_after_open): detect case where there two
4351 import libraries for same dll; rename one to ensure proper link
4354 * pe-dll.c (process_def_file): compare ordinals to -1, not 0; fix
4356 (generate_edata): fix typo
4360 * scripttempl/crisaout.sc (ENTRY): Now __start.
4361 (.text): Add default setting for __start.
4362 Remove CONSTRUCTORS handling.
4363 (/DISCARD/): Add .gnu.warning.*.
4364 * emulparams/crislinux.sh (ENTRY): Now __start.
4365 (TEXT_START_SYMBOLS): New; provide __Stext and __start default.
4366 * emulparams/criself.sh (OUTPUT_FORMAT): Now elf32-us-cris.
4367 (ENTRY): Now __start.
4368 (INITIAL_READONLY_SECTIONS): Add KEEP for .startup.
4369 (EXECUTABLE_SYMBOLS): Add default setting for __start.
4373 * deffile.h: Fix formatting.
4375 * ldcref.c: Likewise.
4376 * ldctor.c: Likewise.
4377 * ldctor.h: Likewise.
4378 * ldemul.c: Likewise.
4379 * ldemul.h: Likewise.
4380 * ldexp.c: Likewise.
4381 * ldexp.h: Likewise.
4382 * ldfile.c: Likewise.
4383 * ldfile.h: Likewise.
4384 * ldlang.c: Likewise.
4385 * ldlang.h: Likewise.
4386 * lexsup.c: Likewise.
4388 * pe-dll.c: Likewise.
4392 * pe-dll.c (process_def_file): Uninitialized data wasn't
4393 exported with --export-all-symbols switch.
4397 * pe-dll.c (fill_edata): rearrange the data so that ordinals and
4398 noname work properly.
4402 * ld.texinfo (HPPA ELF32): New section.
4404 * emultempl/hppaelf.em (group_size): New.
4405 (hppaelf_finish): Pass group_size to elf32_hppa_size_stubs.
4406 (PARSE_AND_LIST_PROLOGUE): Add OPTION_STUBGROUP_SIZE.
4407 (PARSE_AND_LIST_LONGOPTS): Add --stub-group-size. Duplicate
4408 options to prevent abbreviations matching.
4409 (PARSE_AND_LIST_OPTIONS): Describe the above. Reformat.
4410 (PARSE_AND_LIST_ARGS_CASES): Handle it.
4414 * emultempl/m68kelf.em: Conditionalise the embedded relocs feature
4415 on the m68*-*-elf target. Make it support COFF input objects.
4419 * ldmain.c: Fix formatting.
4420 * ldmisc.c: Likewise.
4421 * ldver.c: Likewise.
4422 * ldwrite.c: Likewise.
4426 * ldwrite.c (clone_section): Silence gcc warnings.
4430 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Handle
4431 out of memory failure.
4433 * ldwrite.c (ldwrite): Remove unnecessary einfo arg.
4434 (clone_section): Handle out of memory failures. Rename var to
4435 avoid c++ reserved word.
4439 * emultempl/hppaelf.em (hppaelf_add_stub_section): Rename
4440 stub_name param to stub_sec_name.
4441 (hppaelf_finish): Modify call to elf32_hppa_size_stubs.
4445 * emultempl/m68kelf.em: New file.
4446 * emulparams/m68kelf.sh (EXTRA_EM_FILE): Use it.
4447 * Makefile.am (em68kelf.c): Add dependency on m68kelf.em.
4448 * Makefile.in: Regenerate.
4452 * emulparams/hppalinux.sh (DATA_START_SYMBOLS): Provide $global$
4457 * ldmain.c (multiple_definition): Disable relaxation if
4458 multiple symbol definitions are encountered - otherwise the
4459 linker could abort with an assertion failure.
4463 * mri.c: Fix formatting.
4467 * configure.in (AC_ISC_POSIX): Put after AC_CANONICAL_SYSTEM.
4468 * configure: Rebuild.
4472 * Makefile.am (lexsup.o): Also depend on $(INCDIR)/demangle.h.
4473 * Makefile.in: Rebuild.
4477 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Fix
4478 broken list handling. Create __start_SECNAME and __stop_SECNAME
4479 when no place-holder. Add some comments. Test both SEC_CODE and
4480 SEC_READONLY for hold_text to prevent .rodata orphan poisoning.
4481 Handle case where no output section statement created.
4485 * configure.tgt (sh-*-linux*): Added.
4486 * Makefile.am: Added eshelf_linux and eshlelf_linux.
4487 * Makefile.in: Rebuilt.
4488 * emulparams/shelf_linux.sh: New file.
4489 * emulparams/shlelf_linux.sh: New file.
4493 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
4494 try shuffling sections when the orphan happens to be the place
4495 holder. Keep count of unique section names generated so we speed
4496 the search for a new name.
4500 * configure: Rebuilt with new libtool.m4.
4504 * Makefile.in: Regenerate.
4505 * aclocal.m4: Regenerate.
4506 * configure: Regenerate.
4507 * config.in: Regenerate.
4508 * po/ld.pot: Regenerate.
4510 * ldint.texinfo: Remove CVS revision marker - it foils local
4513 * emultempl/ticoff.em: Remove extraneous comma.
4517 * emultempl/hppaelf.em (hppaelf_add_stub_section): Add SEC_RELOC
4518 to stub section flags.
4519 (hppa_for_each_input_file_wrapper): New.
4520 (hppa_lang_for_each_input_file): New.
4521 (lang_for_each_input_file): Define to call above.
4522 (multi_subspace): New.
4523 (hppaelf_finish): Pass multi_subspace to elf32_hppa_size_stubs.
4524 (PARSE_AND_LIST_PROLOGUE): Define.
4525 (PARSE_AND_LIST_LONGOPTS): Define.
4526 (PARSE_AND_LIST_OPTIONS): Define.
4527 (PARSE_AND_LIST_ARGS_CASES): Define.
4528 (hppaelf_finish): Call elf32_hppa_set_gp.
4529 (hppaelf_set_output_arch): Remove.
4530 (LDEMUL_SET_OUTPUT_ARCH): Remove.
4532 * emulparams/hppalinux.sh (ELFSIZE): Define.
4534 (OTHER_READONLY_SECTIONS): Define.
4536 (GENERATE_SHLIB_SCRIPT): Define.
4538 * ldlang.c: Add missing prototypes, and tidy others. Change CONST
4539 to const throughout. Change `void *' to `PTR' throughout.
4540 (lang_memory_default): Function is local to file, add `static'.
4542 * Makefile.am (ehppaelf.c): Depend on emultempl/elf32.em.
4543 (ehppalinux.c): Likewise.
4544 (earmelf.c): Likewise.
4545 (earmelf_linux.c): Likewise.
4546 (earmelf_linux26.c): Likewise.
4547 * Makefile.in: Regenerate.
4549 * ld.h (ld_config_type): Add unique_orphan_sections.
4550 * lexsup.c (OPTION_UNIQUE): Define.
4551 (ld_options): Add "--unique".
4552 (parse_args): Handle it.
4553 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
4554 search for an existing output section if unique_orphan_sections is
4555 set. Make use of bfd_get_unique_section_name rather than
4556 duplicating code here.
4557 * ld.texinfo: Describe --unique.
4559 * lexsup.c (ld_options): Make split-by-reloc arg optional. Add
4560 optional arg to split-by-file.
4561 (parse_args): Handle them.
4562 * ld.texinfo: Update description of these options.
4563 * ldwrite.c (clone_section): Pass in the section name. Replace
4564 local code with bfd_get_unique_section_name.
4565 (split_sections): Tidy code and comments. Use a list traversal
4566 more appropriate to the list construction. Handle cooked section
4567 sizes. Split when split_by_reloc reached rather than exceeded.
4568 Track section size and split when split_by_file reached. Fix
4569 link_order_tail (even though it's not used).
4570 (ldwrite): Modify condition for calling split_sections to suit
4571 changed split_by_reloc and split_by_file.
4572 * ldmain.c (main): Init config.split_by_reloc and
4573 config.split_by_file to -1.
4574 * ld.h (ld_config_type): Change split_by_reloc to unsigned.
4575 Change split_by_file to bfd_size_type.
4579 * configure.in: Increase version number to 2.10.91.
4580 * NEWS: Mention new ability to support removal of duplicate DWARF2
4582 * configure: Regenerate.
4583 * aclocal.m4: Regenerate.
4584 * config.in: Regenerate.
4588 * scripttempl/elf.sc: Add .gnu.linkonce.wi.* to .debug_info
4590 * scripttempl/elf32avr.sc: Ditto.
4591 * scripttempl/elfd10v.sc: Ditto.
4592 * scripttempl/elfd30v.sc: Ditto.
4593 * scripttempl/elfi370.sc: Ditto.
4594 * scripttempl/elfm68hc11.sc: Ditto.
4595 * scripttempl/elfm68hc12.sc: Ditto.
4596 * scripttempl/elfi386beos.sc: Ditto.
4597 * scripttempl/v850.sc: Ditto.
4601 * acinclude.m4: Include libtool and gettext macros from the
4603 * aclocal.m4, configure: Rebuilt.
4607 * ldlang.c (open_output): When choosing the target for a
4608 particular endianness, do nothing if the target is not
4613 * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Don't
4614 check -rpath nor LD_RUN_PATH for cross link.
4615 * ld.texinfo: Document the change.
4619 * NEWS: Mention support for CRIS.
4623 * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Get
4624 the current runpath list from bfd_elf_get_runpath_list ()
4629 * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Search
4630 the DT_RPATH/DT_RUNPATH entries for DT_NEEDED after
4631 LD_LIBRARY_PATH for native linker. Display the needed DSO if
4632 trace_file_tries is non-zero.
4633 (gld${EMULATION_NAME}_try_needed): Report the needed DSO found
4634 if trace_file_tries is non-zero.
4636 * ld.texinfo: Document the usage of DT_RPATH/DT_RUNPATH.
4641 * NEWS: Mention i860 support.
4645 * scripttempl/elf.sc: Fix last change to use correct comment
4650 * scripttempl/elf.sc: Add a comment giving the correspondence
4651 between sections, per-datum sections, and linkonce sections. Make
4652 the comment true even for .bss, .sdata, .sdata2, .sbss, and
4657 * emulparams/elf32_i860.sh: New file.
4658 * configure.tgt: Recognize new target i860-stardent-{sysv4*|elf*}.
4659 * Makefile.am (ALL_EMULATIONS): Add eelf32_i860.o.
4660 (eelf32_i860.c): New rule.
4661 * Makefile.in: Regenerate.
4665 * emulparams/mipspe.sh (ENTRY): Add definition.
4669 * emultempl/elf32.em (_after_close): Refer to -rpath not --rpath
4674 * scripttempl/elfm68hc11.sc: Define __bss_size symbol to indicate
4675 the final size of .bss section.
4676 * scripttempl/elfm68hc12.sc: Likewise.
4680 * emultempl/elf32.em (gld_${EMULATION_NAME}_parse_args): Rename to
4681 gld${EMULATION_NAME}_parse_args for consistency. Combine
4682 lastoptind and prevoptind vars, and keep track of last optind.
4683 (gld_${EMULATION_NAME}_list_options): Rename to
4684 gld${EMULATION_NAME}_list_options.
4688 * configure.tgt: Select targ_emul=elf_i386 for Unixware 7
4689 (i586-sco-sysv5uw7.1.0).
4693 * emulparams/elf64alpha.sh (PARSE_AND_LIST_ARGS): Removed.
4694 (PARSE_AND_LIST_PROLOGUE): New.
4695 (PARSE_AND_LIST_LONGOPTS): Likewise.
4696 (PARSE_AND_LIST_OPTIONS): Likewise.
4697 (PARSE_AND_LIST_ARGS_CASES): Likewise.
4698 (PARSE_AND_LIST_EPILOGUE): Likewise.
4702 * emultempl/armelf.em: Elide functions common to elf32.em,
4703 ie. most of the file.
4704 (arm_elf_after_open): New. Do arm specific things then call
4705 gld${EMULATION_NAME}_after_open.
4706 (arm_elf_before_allocation): New. Call
4707 gld${EMULATION_NAME}_before_allocation then do arm specifics.
4708 (PARSE_AND_LIST_PROLOGUE): Define.
4709 (PARSE_AND_LIST_SHORTOPTS): Define.
4710 (PARSE_AND_LIST_LONGOPTS): Define.
4711 (PARSE_AND_LIST_OPTIONS): Define.
4712 (PARSE_AND_LIST_ARGS_CASES): Define.
4713 (LDEMUL_AFTER_OPEN): Define.
4714 (LDEMUL_BEFORE_ALLOCATION): Define.
4715 (LDEMUL_BEFORE_PARSE): Define.
4716 (LDEMUL_FINISH): Define.
4718 * emultempl/hppaelf.em: Similarly zap most of this file.
4719 (hppaelf_add_stub_section): Prototype.
4720 (hppaelf_layaout_sections_again): Prototype.
4721 (hook_in_stub): Prototype.
4722 (LDEMUL_SET_OUTPUT_ARCH): Define.
4723 (LDEMUL_FINISH): Define.
4724 (LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS): Define.
4726 * emulparams/armelf.sh (TEMPLATE_NAME): Use elf32.
4727 (EXTRA_EM_FILE): New.
4728 * emulparams/armelf_linux.sh: Likewise.
4729 * emulparams/armelf_linux26.sh: Likewise.
4730 * emulparams/hppalinux.sh: Likewise.
4731 * emulparams/hppaelf.sh: Likewise.
4734 * emultempl/elf32.em: Fix formatting.
4735 (EXTRA_EM_FILE): Source it.
4736 (LDEMUL_BEFORE_PARSE, LDEMUL_SYSLIB, LDEMUL_HLL,
4737 LDEMUL_AFTER_PARSE, LDEMUL_AFTER_OPEN, LDEMUL_AFTER_ALLOCATION,
4738 LDEMUL_SET_OUTPUT_ARCH, LDEMUL_CHOOSE_TARGET,
4739 LDEMUL_BEFORE_ALLOCATION, LDEMUL_GET_SCRIPT, LDEMUL_FINISH,
4740 LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS,
4741 LDEMUL_OPEN_DYNAMIC_ARCHIVE, LDEMUL_PLACE_ORPHAN,
4742 LDEMUL_SET_SYMBOLS, LDEMUL_PARSE_ARGS, LDEMUL_UNRECOGNIZED_FILE,
4743 LDEMUL_LIST_OPTIONS, LDEMUL_RECOGNIZED_FILE,
4744 LDEMUL_FIND_POTENTIAL_LIBRARIES): New shell vars. Add code to
4745 allow functions in this file to be overridden.
4746 (PARSE_AND_LIST_SHORTOPTS): Handle it.
4748 * emultempl/m68kcoff.em: Include ldfile.h before ldemul.h.
4750 * emultempl/elf32.em: Reorganize file.
4754 * emulparams/elf64alpha.sh: Implement "-taso" emulation
4755 specific option to fit 64-bit executable in the lower
4756 31-bit address range. This is done by changing start
4757 address of .interp (the very first section of executable)
4758 and then setting EF_ALPHA_32BIT elf header flag.
4762 * emultempl/m68kcoff.em: New file.
4763 * emulparams/m68kcoff.sh (TEMPLATE_NAME): Use m68kcoff template.
4764 * Makefile.am (em68kcoff.c): Depend on m68kcoff.em rather than
4766 * Makefile.in: Regenerate.
4770 * emultempl/elf32.em (longopts): Duplicate "disable-new-dtags"
4771 and "disable-new-dtags" to stop getopt from treating -d/-e as
4772 abbreviations for these options.
4776 * ld.texinfo: Add documentation for --disable-new-dtags and
4779 * ldmain.c (main): Initialize link_info.new_dtags to false.
4781 * emultempl/elf32.em (gld_${EMULATION_NAME}_parse_args): Add
4782 --disable-new-dtags and --enable-new-dtags.
4783 (gld_${EMULATION_NAME}_list_options): Likewise.
4787 * lexsup.c: Add optional style to demangle switch
4788 * ld.texinfo: Document optional style to demangle switch.
4792 * Makefile.am (ALL_EMULATIONS): Add ecrisaout.o, ecriself.o,
4794 (ecrisaout.c, ecriself.c, ecrislinux.c): New rules.
4795 Regenerate dependencies.
4796 * Makefile.in: Rebuild.
4797 * configure.tgt (cris-*-*): New target.
4798 * emulparams/crisaout.sh, emulparams/criself.sh,
4799 emulparams/crislinux.sh, scripttempl/crisaout.sc: New files.
4800 * po/POTFILES.in, po/ld.pot: Regenerate.
4804 * emultempl/elf32.em (gld_${EMULATION_NAME}_list_options):
4805 Print out ignored -z options.
4809 * emulparams/elf32mcore.sh (PARSE_AND_LIST_ARGS): Removed.
4810 (PARSE_AND_LIST_PROLOGUE): New.
4811 (PARSE_AND_LIST_LONGOPTS): Likewise.
4812 (PARSE_AND_LIST_OPTIONS): Likewise.
4813 (PARSE_AND_LIST_ARGS_CASES): Likewise.
4815 * ldmain.c (main): Clear link_info.flags and link_info.flags_1.
4817 * lexsup.c (ld_options): Comment out 'z'.
4818 (parse_args): Likewise.
4820 * emultempl/elf32.em: Include "elf/common.h".
4821 (gld_${EMULATION_NAME}_parse_args): Defined. Handle some -z
4823 (gld_${EMULATION_NAME}_list_options): Likewise.
4825 * ld.texinfo: Add documentation for the recognized -z options.
4829 * emultempl/elf32.em (gld${EMULATION_NAME}_try_needed): Call
4830 bfd_elf_set_dt_needed_soname ().
4834 * pe-dll.c (pe_dll_id_target): check object target name also
4838 * scripttempl/elf.sc (.init): Only do ${INIT_START} and
4839 ${INIT_END} if relocating.
4840 (.fini): Likewise ${FINI_START} and ${FINI_END}.
4844 * emultempl/pe.em (gld_*_open_dynamic_archive): New search
4845 order for dynamic library '-lfoo' on pei386: libfoo.dll.a,
4846 foo.dll.a, libfoo.a, libfoo.dll, foo.dll. This fixes compatibility
4847 errors introduced by the old dynamic lib search order.
4851 * pe-dll.c (process_def_file): auto-export data items also
4852 (pe_process_import_defs): also see if _imp_ form needed
4856 * pe-dll.c (make_one): fix a typo in the __imp_ name decoration
4857 for dll import libraries
4861 * scripttempl/i386go32.sc: Support the g++ attribute init_priority in
4862 gcc 2.95.2 and later.
4866 * ldfile.c (ldfile_try_open_bfd): Output '\n' after an error
4871 * ldemul.h (struct lang_input_statement_struct): Remove forward
4873 (struct search_dirs): Likewise.
4874 * ldfile.h (struct lang_input_statement_struct): Likewise.
4875 Protect file from multiple inclusion.
4876 * ldlang.h (LANG_FOR_EACH_INPUT_STATEMENT): Move file_chain
4877 declaration from macro to file scope.
4879 * ldemul.c: ldexp.h,ldlang.h,ldfile.h,ldemul.h go in this order.
4880 * ldgram.y: Likewise here.
4881 * ldlang.c: And here.
4882 * ldmain.c: And here.
4883 * mpw-elfmips.c: And here.
4884 * mpw-eppcmac.c: And here.
4885 * emultempl/aix.em: And here.
4886 * emultempl/armcoff.em: And here.
4887 * emultempl/armelf.em: And here.
4888 * emultempl/armelf_oabi.em: And here.
4889 * emultempl/beos.em: And here.
4890 * emultempl/elf32.em: And here.
4891 * emultempl/hppaelf.em: And here.
4892 * emultempl/linux.em: And here.
4893 * emultempl/lnk960.em: And here.
4894 * emultempl/pe.em: And here.
4895 * emultempl/sunos.em: And here.
4896 * mpw-esh.c: And here. Include ldexp.h and ldlang.h too.
4897 * mpw-idtmips.c: Ditto.
4898 * emultempl/generic.em: Ditto.
4899 * emultempl/gld960.em: Ditto.
4900 * emultempl/gld960c.em: Ditto.
4901 * emultempl/mipsecoff.em: Ditto.
4902 * emultempl/ticoff.em: Ditto.
4903 * emultempl/vanilla.em: Ditto.
4905 * pe-dll.c: Include ldfile.h
4906 * ldver.c: Include ldexp.h, ldlang.h, ldfile.h
4908 * mpw-elfmips.c: (gldelf32ebmip_before_allocation): Add missing
4909 arguments to bfd_elf32_size_dynamic_sections call.
4910 (gldelf32ebmip_place_orphan): Add missing arguments to
4911 lang_leave_output_section_statement call.
4915 * emultempl/pe.em (pe_enable_stdcall_fixup): Protect with
4917 (strhash): Likewise.
4918 (compute_dll_image_base): Likewise.
4919 (pe_undef_found_sym): Likewise.
4920 (pe_undef_cdecl_match): Likewise.
4921 (gld_${EMULATION_NAME}_open_dynamic_archive): Mark the
4922 argument "arch" with ATTRIBUTE_UNUSED.
4926 * configure.tgt: Remove extraneous hppa*-*-linux-gnu*.
4929 * ldwrite.c (SSIZE): Remove to cure macro redefinition warning.
4933 Changes to create multiple linker stubs, positioned immediately
4934 before the section where they are required.
4935 * emultempl/hppaelf.em: Include elf32-hppa.h.
4936 (stub_sec, file_chain): Delete.
4937 (hppaelf_create_output_section_statements): Don't make a stub
4939 (hook_stub_info): New struct.
4940 (hook_in_stub): New function.
4941 (hppaelf_add_stub_section): New function.
4942 (hppaelf_finish): Do nothing for relocateable links. Modify the
4943 call to elf32_hppa_size_stubs. Move code for updating section
4945 (hppaelf_layaout_sections_again): ..to here, a new function.
4947 * emultempl/hppaelf.em (hppaelf_delete_padding_statements): Fix
4948 broken list handling. Pass in a pointer to the list.
4949 (hppaelf_finish): Update call to hppaelf_delete_padding_statements
4951 (hppaelf_before_parse): Prototype.
4952 (hppaelf_set_output_arch): Prototype.
4953 (hppaelf_create_output_section_statements): Prototype.
4954 (hppaelf_delete_padding_statements): Prototype.
4955 (hppaelf_finish): Prototype.
4958 * emultempl/hppaelf.em: Include ctype.h.
4959 (struct orphan_save): New.
4960 (gld${EMULATION_NAME}_place_orphan): New.
4961 (output_rel_find): New.
4962 (hppaelf_get_script): Update from elf32.em.
4963 (ld_hppaelf_emulation): Rename to ld_${EMULATION_NAME}_emulation.
4964 Change emulation_name field to "${EMULATION_NAME}". Add
4965 gld${EMULATION_NAME}_place_orphan.
4967 * Makefile.am (ALL_EMULATIONS): Reinstate ehppaelf.o, add
4968 ehppalinux.o, sort it. Regenerate dependencies.
4969 (ehppalinux.c): Depend on hppaelf.em
4970 * Makefile.in: Regenerate.
4972 * configure.tgt: targ_emul=hppalinux for hppa*linux
4974 * emulparams/hppalinux.sh: New.
4975 * emulparams/hppaelf.sh (TARGET_PAGE_SIZE): Write in hex.
4979 * lexsup.c (parse_args): Copy section name.
4983 * emultempl/pe.em: institute the following search order for
4984 dynamic libraries on pei386: libfoo.dll.a, foo.dll.a (import
4985 libs), libfoo.dll, foo.dll (link direct to dll). Fall back to
4986 static lib (libfoo.a) if none of the above are found.
4990 * emultempl/pe.em (pe_enable_auto_image_base): New variable.
4991 (longopts): New --{enable,disable}-auto-image-base options.
4992 (gld_${EMULATION_NAME}_list_options): Document.
4993 (gld_${EMULATION_NAME}_parse): Handle.
4994 (strhash): New static function.
4995 (compute_dll_image_base): New static function.
4996 (gld_${EMULATION_NAME}_set_symbols): Use.
5004 * configure.tgt: Add traditional mips (mips*-*-sysv4*) target.
5005 * emulparams/elf32btsmip.sh: New file.
5006 * Makefile.am: Add traditional mips target.
5007 * Makefile.in: Rebuild.
5011 * Makefile.am (EXTRA_ld_new_SOURCES): Set to deffilep.y for
5012 automake to use YLWRAP.
5013 * Makefile.in: Rebuild.
5017 * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
5018 (CLEANFILES): Add DEPA.
5019 * Makefile.in: Regenerate.
5021 2000-06-30 Timothy Wall <twall@ppc>
5023 * scripttempl/tic54xcoff.sc: PAGE N is not implemented, so encode
5024 the page in the upper octet of the address.
5028 * emulparams/avrmega161.sh (ARCH): Change to avr:5.
5032 * NEWS: arm-elf does --gc-sections too.
5036 * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
5038 * Makefile.in: Regenerate.
5042 * Makefile.am: Rebuild dependency.
5043 * Makefile.in: Rebuild.
5047 * Makefile.am: Rebuild dependency.
5048 * Makefile.in: Rebuild.
5052 * scripttempl/tic54xcoff.sc: New.
5053 * ldlang.c (wild_doit): Propagate SEC_BLOCK flag.
5054 * gen-doc.texi: Add flag for TI COFF.
5055 * ld.texinfo: Add documentation for TI COFF handling switches.
5056 * emultempl/ticoff.em: New. TI COFF handling.
5057 * configure.tgt: Add tic54x target.
5058 * Makefile.am: Add tic54x target.
5059 * Makefile.in: Ditto.
5063 * ldmain.c (set_scripts_dir): Correct pointer comparison when
5064 checking for backslashes.
5068 * NEWS: Move entries not in 2.10 above "Changes in version 2.10".
5072 * NEWS: Update list of targets supporting --gc-sections.
5074 * scripttempl/elf.sc: KEEP .eh_frame contents.
5075 * scripttempl/elfd30v.sc: Same here.
5079 * Makefile.am (ALL_EMULATIONS): Added new emulation for m68hc12
5081 * Makefile.in: Rebuild.
5082 * configure.tgt: Recognize m68hc12 and m68hc11.
5083 * scripttempl/elfm68hc12.sc: New file.
5084 * emulparams/m68hc12elfb: New emulation.
5085 * emulparams/m68hc12elf: New emulation.
5086 * emulparams/m68hc11elfb.sh: New file. User configurable emulation
5087 (includes a memory.x script to define the ROM and RAM banks).
5088 * scripttempl/elfm68hc11.sc, emulparams/m68hc11elf.sh:
5089 New configuration files for support of Motorola 68hc11
5093 * ldmain.c (main): Only change SEC_READONLY for final link.
5097 * configure: Regenerate.
5101 * configure.in (VERSION): Update to show this is the CVS mainline.
5105 * emultempl/mipsecoff.em (gld{EMULATION_NAME}_after_open): Require all
5106 input objects to be ECOFF.
5107 (check_sections): einfo takes %B, not %P, to print a BFD name.
5111 * ldgram.y (vers_defns): Handle 'extern "C++" { ... }' in
5114 * ldlex.l (V_IDENTIFIER): Accept `::' in symbols.
5118 * emulparams/avr1200.sh (STACK): Define as 0.
5119 * emulparams/avr23xx.sh (STACK): Define as last internal SRAM address.
5120 * emulparams/avr4433.sh (STACK): Likewise.
5121 * emulparams/avr44x4.sh (STACK): Likewise.
5122 * emulparams/avr85xx.sh (STACK): Likewise.
5123 * emulparams/avrmega103.sh (STACK): Likewise.
5124 * emulparams/avrmega161.sh (STACK): Likewise.
5125 * emulparams/avrmega603.sh (STACK): Likewise.
5126 * scripttempl/elf32avr.sc (__data_start): Define for gcrt1.
5127 (__stack): Define from ${STACK} for main().
5131 * Makefile.am: Update dependencies with "make dep-am"
5132 * Makefile.in: Regenerate.
5136 * ldmain.c: Include filenames.h.
5137 (set_scripts_dir): Support backslashes in program name.
5141 * ldmain.c (main): When deciding if ".text" section should be
5142 read-only, don't forget to reset SEC_READONLY because it
5143 could be already set.
5147 * ld.1: Add documentation for new command line option:
5148 --section-start <sectionname>=<sectionorg>
5149 This is a generic version of -Ttext etc. which accepts
5150 any section name as a parameter instead of just text/data/
5152 * ld.texinfo: More docs.
5154 * lexsup.c: (parse_args): Recognize new command line option.
5155 (ld_options): Add new option.
5159 * lexsup.c (parse_args): `i' == `r', not `q'.
5163 * configure.tgt (hppa*64*-*-*): Enable PA64 target.
5168 Add support for '-q' == '--emit-relocs' switch.
5169 * ldmain.c (main): Default to false.
5170 * lexsup.c (parse_args): Turn on emitrelocations flag if set.
5171 * NEWS: Describe the emitrelocations switch.
5172 * ld.texinfo: Describe the emitrelocations switch.
5176 * emultempl/pe.em (_open_dynamic_archive): New function: Search
5177 the library path for "foo.dll" and "libfoo.dll" dynamic libraries
5178 before searching for 'libfoo.a' in response to a '-Bdynamic -lfoo'
5183 * lexsup.c (parse_args): Update the year in the copyright notice.
5187 * ld.h (gettext, dgettext, dcgettext, textdomain, bindtextdomain):
5188 Replace defines with those from intl/libgettext.h to quieten gcc
5193 * ldlang.c (open_input_bfds): Don't load the same file within
5194 a group again if the whole archive has been loaded already.
5199 * lexsup.c (set_section_start): Use bfd_scan_vma rather than
5204 * configure.host (ia64-*-linux-gnu*): Change gcc to ${CC}.
5206 * configure.host: Added HOSTING_CRT0, HOSTING_LIBS for
5207 host "ia64-*-linux-gnu*".
5211 * ld.h: Correctly check GCC version.
5215 * Makefile.am: Add PA64 support. Add missing dependencies for
5217 * Makefile.in: Rebuilt.
5218 * configure.tgt: Add PA64 support (currently disabled).
5222 * emultempl/elf32.em (gld${EMULATION_NAME}_place_section): Delete.
5223 (output_rel_find): New function.
5224 (hold_section, hold_use): Delete.
5225 (hold_text, hold_rodata, hold_data, hold_bss, hold_rel,
5226 hold_interp): Make local to place_orphan.
5227 (gld${EMULATION_NAME}_place_orphan): Use lang_output_section_find
5228 rather than place_section to find possible previous use of orphan.
5229 Similarly find the place-holder output sections. Use returned
5230 value from lang_enter_output_section_statement rather than calling
5231 lang_output_section_statement_lookup.
5232 * emultempl/armelf.em: Same here.
5233 * emultempl/pe.em: Similar to above, but no need for output_rel_find.
5235 * ldlang.c (lang_enter_output_section_statement): Return output
5237 * ldlang.h (lang_enter_output_section_statement): Change
5240 * ldlang.h (lang_output_section_statement): Export it.
5241 * ldlang.c (lang_output_section_statement): Ditto.
5245 * ld.texinfo (Output Section Data): Add note that section data
5246 commands cannot appear outside of section directives.
5250 * configure.tgt: Add NetBSD/sparc ELF, and NetBSD/sparc64 support.
5255 * Makefile.am (ALL_64_EMULATIONS): Add eelf64_ia64.o.
5256 (eelf64_ia64.c): New rule.
5257 * Makefile.in: Rebuild.
5258 * configure.tgt (ia64-*-elf*, ia64-*-linux*): New targets.
5259 * emulparams/elf64_ia64.sh: New file.
5263 * scripttempl/elfd30v.sc: Place .gcc_except_table.
5267 * dep-in.sed: Match space at start of file name, not at end.
5271 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Call
5272 lang_leave_output_section_statement () after calling
5273 lang_enter_output_section_statement ().
5274 * emultempl/armelf.em: Likewise.
5278 * emultempl/elf32.em (struct orphan_save): Add section field.
5279 (gld${EMULATION_NAME}_place_orphan): Use above to keep sections in
5280 better order, and place first orphan section as we did before the
5281 2000-04-12 patch. Ignore ~SEC_ALLOC sections when choosing place.
5282 Don't call make_bfd_section here, let wild_doit do the job for us.
5283 Don't build a statement list when we'll only throw it away.
5284 * emultempl/armelf.em: Ditto.
5285 * emultempl/pe.em: Similarly.
5289 * scripttempl/elfppc.sc: Remove.
5290 * emulparams/elf32ppc.sh: Use elf.sc.
5291 * emulparams/elf32lppc.sh: Use elf.sc.
5292 * emulparams/elf32ppclinux.sh: Use elf.sc.
5293 * emulparams/elf32ppcsim.sh: New file.
5294 * emulparams/elf32lppcsim.sh: New file.
5295 * Makefile.am: Update dependencies. Add elf32ppcsim ad elf32lppcsim.
5296 (ALL_EMULATIONS): Add elf32ppcsim ad elf32lppcsim.
5297 * Makefile.in: Regenerate.
5298 * configure.tgt (powerpc-*): Add elf32ppcsim and elf32lppcsim.
5302 * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Process
5303 ~SEC_ALLOC sections too. Init start address of debug sections.
5304 * emultempl/armelf.em (gld${EMULATION_NAME}_place_orphan): Ditto.
5305 * emultempl/pe.em (gld${EMULATION_NAME}_place_orphan): Ditto.
5306 Also set all relocateable section start addresses.
5310 * scripttempl/elf.sc: Add support for .sbss2 and .sdata2 sections.
5311 Add new BSS_PLT variable for when .plt need not be contained in
5312 the file. Move _etext so that it is also after .fini, and provide
5313 both etext and _etext with a leading underscore. Mark the start
5318 * emultempl/elf32.em (struct orphan_save): New.
5319 (hold_text, hold_rodata, hold_data, hold_bss, hold_rel,
5320 hold_interp): Make them struct orphan_save.
5321 (gld${EMULATION_NAME}_place_section): Modify for new hold_*.
5322 (gld${EMULATION_NAME}_place_orphan): Add new orphan sections to
5323 the end of the relevant section list. Also add associated section
5324 statements to the end of any previous orphan statements.
5325 * emultempl/armelf.em: Similarly.
5326 * emultempl/pe.em: Similarly.
5330 * ld.texinfo (Simple Example): Remove extraneous paragraph.
5334 * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
5335 --enable-build-warnings option.
5336 * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
5337 * Makefile.in, configure: Re-generate.
5341 * po/ld.pot: Regenerate.
5343 * lexsup.c (help): Restore translated part of bug string.
5345 * Makefile.am (MKDEP): Use gcc -MM rather than mkdep.
5346 (DEP): Quote when passing vars to sub-make. Add warning message
5348 (DEP1): Rewrite for "gcc -MM".
5349 (CLEANFILES): Add DEP2.
5350 Update dependencies.
5351 * Makefile.in: Regenerate.
5355 * ld.h: #include "bin-bugs.h"
5356 * lexsup.c (help): Use REPORT_BUGS_TO.
5360 * configure.tgt (avr-*-*): New target support.
5361 * Makefile.am: Likewise.
5362 * scripttempl/elf32avr.sc: New script file.
5363 * emulparams/avr1200.sh: New file.
5364 * emulparams/avr23xx.sh: New file.
5365 * emulparams/avr4433.sh New file.
5366 * emulparams/avr44x4.sh New file.
5367 * emulparams/avr85xx.sh New file.
5368 * emulparams/avrmega103.sh New file.
5369 * emulparams/avrmega161.sh New file.
5370 * emulparams/avrmega603.sh New file.
5371 * Makefile.in: Regenerate.
5375 * Makefile.am (check-DEJAGNU): Also unset LANG.
5376 * Makefile.in: Rebuild.
5380 * ldfile.c (ldfile_try_open_bfd): Don't crash if we see an empty
5385 * emulparams/elf32mcore.sh: Include "getopt.h".
5389 * configure.tgt: Remove *-*-aout, *-*-coff, and *-*-netware.
5393 * emulparams/mipspe.sh: Add SUBSYSTEM and INITIAL_SYMBOL_CHAR.
5394 * emulparams/shpe.sh: Likewise.
5398 * pe-dll.c: Remove unused variables and add ATTRIBUTE_UNUSED
5399 to unused parameters.
5401 * emultempl/pe.em: Add "#ifdef DLL_SUPPORT" around static
5402 functions only used by DLL code.
5403 (_place_orphan): Initialise 'dollar'.
5407 * ldmain.c (undefined_symbol): Take one more arg, fatal, to
5408 indicate if the undefined symbol is a fatal error or not.
5409 Don't delete the output file if "fatal" is false.
5413 * Makefile.am (check-DEJAGNU): Also pass LIBS="$(LIBS)".
5414 Set LC_COLLATE and LC_ALL to null and export them. It is for
5415 sort which expects the C locale.
5416 Add $(LIBS) to all $(HOSTING_LIBS).
5417 * Makefile.in: Rebuild.
5421 * emultempl/{aix.em, armcoff.em, armelf.em, armelf_oabi.em,
5422 beos.em, elf32.em, generic.em, gld960.em, gld960c.em, hppaelf.em,
5423 linux.em, lnk960.em, mipsecoff.em, sunos.em, vanilla.em}
5424 (ld_emulation_xfer_struct): Add missing NULL initialiser for
5425 find_potential_libraries.
5429 * ldgram.y (exclude_name_list): Don't require a comma to separate
5430 list entries; the lexer considers commas to be valid part of a
5431 filename, so in something like `foo, bar' the comma is considered
5432 part of the first filename, `foo,'.
5433 * ld.texinfo: Update section on EXCLUDE_FILE lists.
5437 * configure.host: Added HOSTING_CRT0, HOSTING_LIBS for
5438 host "i[3456]86-*-freebsdelf*".
5442 * scripttempl/i386go32.sc: Move misplaced semicolons.
5446 * Makefile.am (ALL_EMULATIONS): Remove ehppaelf.o.
5447 (ALL_64_EMULATIONS): Remove eelf64hppa.o.
5448 (eelf64hppa.c, ehppaelf.c): Remove targets.
5449 * Makefile.in: Rebuild.
5453 * configure.tgt (targ_extra_ofiles): Enable elf64_sparc on
5454 GNU/Linux/sparc, but keep the default as 32.
5456 * configure.tgt: Enable elf64_sparc on Solaris7+/sparc. And make
5457 it default if sparcv9 or sparc64.
5461 * Makefile.am: Add rules to build emipspe.o and earmpe.o.
5462 * Makefile.in: Regenerate.
5463 * configure.tgt: Add targets for arm-wince, sh-pe and mips-pe.
5465 * ldemul.h (ld_emulation_xfer_struct): Add new field:
5466 find_potential_libraries.
5467 * ldemul.c (ldemul_find_potential_libraries): New function.
5469 * ldfile.c (ldfile_open_file_search): Allow function to be
5471 (ldfile_open_file): Call ldemul_find_potential_libraries.
5472 * ldfile.h: Add prototype for ldfile_open_file_search.
5474 * pe-dll.c: Add support for ARM, MIPS and SH targets.
5476 * emulparams/mipspe.sh: New file. Parameters for mips-pe target.
5477 * emulparams/shpe.sh: New file. Parameters for sh-pe target.
5479 * emultempl/pe.em: Add support for ARM, MIPS and SH DLLs.
5480 (gld_X_find_potential_libraries): New function. Search for
5481 libraries called "*.lib".
5483 * scripttempl/pe.sc: Add .pdata section.
5487 * scripttempl/elfd10v.sc: Remove dynamic linking hooks.
5488 Add and use memory regions.
5492 * emulparams/elf32i370.sh, scripttempl/elfi370.sc: New.
5494 * Makefile.am: Add support for Linux/IBM 370.
5495 * configure.tgt: Likewise.
5497 * Makefile.in: Regenerate.
5501 * ldlang.c (print_input_section, print_data_statement,
5502 print_reloc_statement, print_padding_statement, insert_pad,
5503 size_input_section, lang_check_section_addresses,
5504 lang_size_sections, lang_do_assignments, lang_set_startof,
5505 lang_one_common): Change `opb' to unsigned.
5506 (lang_do_assignments): Also change `size' to unsigned.
5510 * scripttempl/elf.sc: Place OTHER_PLT_RELOC_SECTION.
5514 * mri.c (mri_draw_tree): Add default LMA region argument to call
5515 to lang_leave_output_section_statement.
5516 * ldlang.h: Update prototypes with LMA region arguments.
5517 * ldlang.c (lang_size_sections): Encapsulate region bounds
5518 checking in os_check_region call.
5519 (os_check_region): New function.
5520 (lang_output_section_statement_lookup): Initialize lma_region.
5521 (lang_leave_output_section_statement): Add LMA region argument.
5522 (lang_leave_overlay): Ditto.
5523 * ldgram.y: Handle LMA region syntax.
5524 * ld.texinfo (Output Section Description): Describe LMA region usage.
5525 * emultempl/armelf.em (gld$place_orphan): Add default value for
5526 lma region in call to lang_leave_output_section_statement.
5527 * emultempl/elf32.em (gld$place_orphan): Add default value for
5528 lma region in call to lang_leave_output_section_statement.
5529 * emultempl/pe.em (gld$place_orphan): Add default value for
5530 lma region in call to lang_leave_output_section_statement.
5535 * ldlang.c (lang_check_section_addresses): Use bytes instead of
5536 octets when calculating section end addresses.
5540 * ldlang.c (lang_size_sections): Fix typo in ALIGN_N invocation.
5544 * ldexp.c (fold_name): Make SIZEOF operator return byte count, not
5546 * ldlang.c (print_input_section, print_data_statement,
5547 print_reloc_statement, print_padding_statement): Print target
5548 address values and section sizes as bytes, not octets.
5549 (insert_pad) Calculate padding size in octets, and adjust "dot"
5551 (size_input_section) Always adjust "dot" by bytes, not octets.
5552 (lang_check_section_addresses, lang_do_assignments) Adjust
5553 "dot" by bytes, not octets. Use the larger of the directive size
5554 or octets_per_byte for the number of octets actually allocated in
5556 (lang_set_startof) Make sure STARTOF returns a target address.
5557 (lang_one_common) Record size changes in octets.
5558 (lang_abs_symbol_at_end_of) Section end symbol's value is
5559 recorded in target bytes.
5560 * ld.texinfo: Updated description of BYTE, SHORT, LONG, etc.
5561 to be clear about behavior when an octet is smaller than one byte.
5565 * ldcref.c (output_cref): Don't pass message strings to printf
5569 * ldmisc.c (vfinfo): Same here.
5574 * emultempl/{armcoff.em,armelf.em,armelf_oabi.em,beos.em,
5575 generic.em,gld960.em,gld960c.em,hppaelf.em,linux.em,lnk960.em,
5576 mipsecoff.em,sunos.em,vanilla.em} (ld_emulation_xfer_struct):
5577 Add missing NULL initialisers, and comments.
5581 * ldlang.c (lang_size_sections): Fix typo in comment.
5585 * ldlang.c (lang_size_sections): Also update the current
5586 address of a region if the SEC_NEVER_LOAD bit is not set.
5590 * configure.tgt (arm*-*-conix*): New target.
5594 * ld.texinfo (Options): Remind users to preceed linker command
5595 line switches with -Wl, (or whatever is appropriate) if it is
5596 being invoked by a comnpiler driver program.
5597 Fix description of the behaviour of the -n command line switch.
5601 * ld.h (wildcard_spec): Change exclude_name to exclude_name_list.
5603 * ld.texinfo (EXCLUDE_FILE): Update documentation.
5604 * ldgram.y (wildcard_spec): Support a list of excluded_files.
5605 (exclude_name_list): New.
5606 ldlang.c (walk_wild_section): Support list of excluded files.
5607 (print_wild_statement): Likewise.
5608 (lang_add_wild): Likewise.
5609 * ldlang.h (lang_wild_statement_type): Likewise.
5610 * scripttempl/elf.sc (OTHER_EXCLUDE_FILES): Support.
5614 * pe-dll.c (pe_dll_warn_dup_exports): New variable.
5615 (process_def_file): Use.
5616 (pe_dll_compat_implib): New variable.
5619 * pe-dll.h: Add exports of pe_dll_warn_dup_exports and
5620 pe_dll_compat_implib.
5622 * emultempl/pe.em (longopts): Add warn-duplicate-exports and
5623 compat-implib options.
5624 (gld_${EMULATION_NAME}_list_options): List new options.
5625 (gld_${EMULATION_NAME}_parse_args): Handle.
5627 * pe-dll.c (pe_dll_generate_implib): Use the correct name for output
5630 * deffilep.y (opt_name): Allow "." in name.
5632 For older changes see ChangeLog-9899
5638 version-control: never