Commit Graph

1427 Commits

Author SHA1 Message Date
Ian Lance Taylor deb2a14592 * ldlex.l (SYMBOLCHARN): Add $, _, and ~. 1996-09-13 19:50:50 +00:00
Ian Lance Taylor 8ae650ea07 * ldmain.c (get_emulation): Check for -mips4 like -mips1, et. al. 1996-09-12 03:34:28 +00:00
Ian Lance Taylor ee0523d5c3 * ldlang.c (section_already_linked): Accept a lang_input_statement
as the PTR argument.  If the file is symbols only, discard all
	input sections.
	(ldlang_add_file): Pass entry to bfd_map_over_sections.
PR 10555.
1996-09-05 19:26:12 +00:00
Ian Lance Taylor 31cadbf45f * configure.tgt (alpha-*-gnu*): New target. From Fila Kolodny
<fila@ibi.com>.
1996-09-04 19:54:48 +00:00
Jeff Law 7ab4a84a3a * emulparms/v850.sh: Entry symbol is "_start", tweak
ctor/dtor support.
1996-08-31 04:31:18 +00:00
Ian Lance Taylor efd48a6a97 * configure.tgt (sh-*-elf*): New target.
* emulparams/shelf.sh: New file.
	* emulparams/shlelf.sh: New file.
	* Makefile.in (ALL_EMULATIONS): Add eshelf.o and eshlelf.o.
	(eshelf.c, eshlelf.c): New targets.
	* scripttempl/elf.sc: If EMBEDDED is defined, then don't add
	SIZEOF_HEADERS to TEXT_START_ADDR.  Expand CTOR_START and CTOR_END
	around .ctors, and DTOR_START and DTOR_END around .dtors.  Expand
	OTHER_RELOCATING_SECTIONS if RELOCATING.
1996-08-30 22:36:45 +00:00
Ian Lance Taylor 2175d72592 remove extra incorrect check for sanitization 1996-08-26 17:34:46 +00:00
Ian Lance Taylor 4c6856fac4 * ldver.c (ldversion): Print GNU ld in the version message. 1996-08-26 17:02:00 +00:00
Jeff Law 04c17a7559 * Makefile.in (ev850.c): New target.
* configure.tgt (v850-*-*): New target.
        * emulparams/v850.sh: New file.
No, it doesn't work (gas doesn't even emit relocs yet), but having
a "ld" that at least creates an executable image greatly helps the
gcc testsuite.
1996-08-22 22:32:21 +00:00
Stan Shebs 8293952724 * mpw-make.sed: Add @DASH_C_FLAG@ to compiler edit. 1996-08-22 18:18:19 +00:00
Ian Lance Taylor 8387e11432 tweak last patch 1996-08-21 20:10:54 +00:00
Ian Lance Taylor 18f0961ed9 * scripttempl/elf.sc: Put .gnu.linkonce* sections in .text. 1996-08-21 18:27:28 +00:00
Ian Lance Taylor 8b5b6ebd1f * fnmatch.c: Include sysdep.h. 1996-08-19 20:02:42 +00:00
Michael Meissner 9099ec8fb4 Undo 8/16 change; explictly set MACHINE= for d10v 1996-08-19 15:31:29 +00:00
Jackie Smith Cashion 61e3ce7432 Fri Aug 16 14:15:41 1996 James G. Smith <jsmith@cygnus.co.uk>
* scripttempl/armcoff.sc (__bss_start__, __bss_end__,
 	__data_start__, __data_end__): Added to keep in sync. with the
 	default ARM crt0.s. Added __CTOR_LIST__ and __DTOR_LIST__ support.
1996-08-16 13:19:45 +00:00
Ian Lance Taylor 2d69131dab * lib/ld.exp: Use verbose -log instead of calling both verbose and
send_log.
1996-08-08 18:29:59 +00:00
Ian Lance Taylor 9c3f0306ac * ld-scripts/phdrs.exp: New test.
* ld-scripts/phdrs.s, ld-scripts/phdrs.t: New files.
1996-08-07 22:20:39 +00:00
Ian Lance Taylor 2792727822 Wed Aug 7 14:40:48 1996 Philippe De Muyter <phdm@info.ucl.ac.be>
* configure.in: Call BFD_NEED_DECLARATION on strstr and sbrk.
	* acconfig.h (NEED_DECLARATION_STRSTR): New macro.
	(NEED_DECLARATION_SBRK): New macro.
	* configure, config.in: Rebuild.
	* sysdep.h (strstr): Declare if NEED_DECLARATION_STRSTR.
	* ldmain.c (sbrk): Declare if HAVE_SBRK and
	NEED_DECLARATION_SBRK.
1996-08-07 18:43:48 +00:00
Ian Lance Taylor d22ec3b090 * ldlex.l: Recognize OVERLAY.
* ldgram.y: Add section_phdr field to %union.
	(section): Handle phdr_opt result.  Add OVERLAY case.
	(opt_exp_without_type): New nonterminal.
	(phdr_opt): Return list of phdrs.
	(overlay_section): New nonterminal.
	* ldlang.c: Include <ctype.h>.
	(lang_leave_output_section_statement): Add phdrs parameter.
	Change all callers.
	(lang_section_in_phdr): Remove.
	(overlay_vma, overlay_lmn, overlay_max): New static variables.
	(struct overlay_list): Define.
	(overlay_list): New static variable.
	(lang_enter_overlay, lang_enter_overlay_section): New functions.
	(lang_leave_overlay_section, lang_leave_overlay): New functions.
	* ldlang.h (lang_leave_output_section_statement): Update
	declaration for new parameter.
	(lang_section_in_phdr): Don't declare.
	(lang_enter_overlay, lang_enter_overlay_section): Declare.
	(lang_leave_overlay_section, lang_leave_overlay): Declare.
	* ld.texinfo (Overlays): New node under SECTIONS, documenting
	overlays.

	* ldlex.l: Recognize MAX and MIN.
	* ldgram.y (MAX, MIN): New terminals.
	(exp): Recognize MAX and MIN.
	* ldexp.c (fold_binary): Handle MAX and MIN.
	* ld.texinfo (Arithmetic Functions): Document MAX and MIN.

	* ld.texinfo (PHDRS): Use @cindex, not @kindex, for program header
	index entries.

	* ldgram.y (SIZEOF, ADDR): Do not specify type.
1996-08-05 20:37:52 +00:00
Ian Lance Taylor 6bb21dd356 * ldcref.c (check_nocrossref): Skip symbols with no output
sections.
1996-08-05 20:28:39 +00:00
Ian Lance Taylor 52247dfd7f * ld-scripts/crossref.exp: On a29k targets, use --defsym to define
V_SPILL and V_FILL.
1996-08-05 02:29:34 +00:00
Ian Lance Taylor 5735ac9e57 * ldgram.y (LOADADDR): New terminal.
(exp): Handle LOADADDR.
	* ldlex.l: Recognize LOADADDR.
	* ldexp.c (exp_print_token): Add LOADADDR.
	(fold_name): Implement LOADADDR.
	* ldlang.c (exp_init_os): Treat LOADADDR like ADDR.
	* ld.texinfo (Arithmetic Functions): Document LOADADDR.
1996-08-02 19:01:58 +00:00
Ian Lance Taylor c1ebd1ce17 rework crossref test 1996-08-01 18:33:47 +00:00
Ian Lance Taylor bc4c9b927b * ld-scripts/crossref.exp: New test.
* ld-scripts/cross1.c, ld-scripts/cross2.c: New files.
	* ld-scripts/crossref.t: New file.
1996-08-01 18:12:22 +00:00
Ian Lance Taylor 582dd77f65 * ld.h (check_nocrossrefs): Declare.
* ldlang.h (struct lang_nocrossref): Define.
	(struct lang_nocrossrefs): Define.
	(nocrossref_list): Declare.
	(lang_add_nocrossref): Declare.
	* ldlex.l: Recognize NOCROSSREFS keyword.
	* ldgram.y (%union): Add nocrossref field.
	(NOCROSSREFS): New terminal.
	(ifile_p1): Recognize NOCROSSREFS.
	(nocrossref_list): New nonterminal.
	* ldlang.c (nocrossref_list): Define.
	(lang_add_nocrossref): New function.
	* ldmain.c (main): If nocrossref_list is not NULL, call
	check_nocrossrefs.
	(warning_callback): Free symbols if there is no place to store
	them.
	(notice): Call add_cref if nocrossref_list is not NULL.
	* ldcref.c: Include "ldexp.h" and "ldlang.h".
	(check_nocrossrefs): New function.
	(check_nocrossref): New static function.
	(struct check_refs_info): Define.
	(check_refs, check_reloc_refs): New static functions.
	* Makefile.in: Rebuild dependencies.
	* ld.texinfo (Option Commands): Document NOCROSSREFS.
1996-08-01 17:35:49 +00:00
Ian Lance Taylor c2ba368448 * ld.texinfo (Section Placement): Improve the wording of the
wildcard documentation.  Mention that wildcards are only searched
	for on the command line, not in the file system.
1996-08-01 17:10:52 +00:00
Ian Lance Taylor b947ed2d06 * emultempl/sunos.em (gld${EMULATION_NAME}_after_open): Move
definition of lib_path inside condition where it is used.
1996-08-01 17:00:24 +00:00
Martin Hunt ed4820d72b Wed Jul 31 13:17:10 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
* emulparams/d10velf.sh: Now works with elf.sc.
1996-07-31 20:19:08 +00:00
Martin Hunt 212ac7897b Wed Jul 31 11:52:03 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
* d10velf.sh (SCRIPT_NAME): Change to vanilla.
1996-07-31 18:53:46 +00:00
Martin Hunt 364ffcf523 Wed Jul 31 11:52:03 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
* emulparams/d10velf.sh (SCRIPT_NAME): Change to vanilla.
1996-07-31 18:53:31 +00:00
Ian Lance Taylor 72df7117d7 * ldlang.c (lang_size_sections): Add the section VMA to the result
value when computing the address of a section.
1996-07-30 22:56:46 +00:00
Ian Lance Taylor 2ed9fe477a update copyright 1996-07-30 20:05:42 +00:00
Ian Lance Taylor cd09553a9b * ld.h (args_type): Add cref field.
* lexsup.c (parse_args): Set command_line.cref.
	* ldmain.c (main): Check command_line.cref rather than
	link_info.notice_all.
	(notice): Likewise.
1996-07-30 18:49:54 +00:00
Ian Lance Taylor 2c310d1af6 * ldcref.c (output_one_cref): Don't crash if a symbol is defined
in a section without an owner.
1996-07-30 18:48:25 +00:00
Ian Lance Taylor 86bc0974cb * fnmatch.h, fnmatch.c: New files.
* ldlex.l: Remove unused definition of FILENAME.  Add definition
	of WILDCHAR.  In SCRIPT mode, accept any sequence of WILDCHAR as a
	NAME.
	* ldgram.y (file_NAME_list): Accept '*' and '?' specially.
	(input_section_spec): Accept '?' specially.
	(statement): Change exp to mustbe_exp in length and FILL cases.
	(section): Call ldlex_script before section statements, and call
	ldlex_popstate after them.
	* ldlang.c: Include "fnmatch.h".
	(wildcardp): New static function.
	(wild_section): Permit the section name to be a wildcard.
	(wild_file): New static function, broken out of wild.
	(wild): Call wild_file.  Permit the file name to be a wildcard.
	(open_input_bfds): Don't call lookup_name for a wildcard pattern.
	* Makefile.in: Rebuild dependencies.
 	(CFILES): Add fnmatch.c.
	(HFILES): Add fnmatch.h.
	(OFILES): Add fnmatch.o.
	* ld.texinfo: Document that file and section names can now be
	wildcard patterns.

	* ldlang.c (lang_place_orphans): Correct condition: place a common
	section if not relocateable or if common definitions are forced.
1996-07-29 21:33:26 +00:00
Martin Hunt 30ba912ccf start-sanitize-d10v
Wed Jul 24 12:16:38 1996  Martin M. Hunt  <hunt@pizza.cygnus.com>
        * d10velf.sh (SCRIPT_NAME): Change to elf.
end-sanitize-d10v
1996-07-24 19:19:26 +00:00
Martin Hunt ebaf63702d start-sanitize-d10v
Wed Jul 24 12:16:38 1996  Martin M. Hunt  <hunt@pizza.cygnus.com>
        * emulparams/d10velf.sh (SCRIPT_NAME): Change to elf.
end-sanitize-d10v
1996-07-24 19:19:09 +00:00
Michael Meissner c5b8962080 Allow plain d10v as a target 1996-07-24 17:48:31 +00:00
Martin Hunt bc8ea3f7ce start-sanitize-d10v
Tue Jul 23 10:36:19 1996  Martin M. Hunt  <hunt@pizza.cygnus.com>

	* emulparams/d10velf.sh: New file.

end-sanitize-d10v
1996-07-23 18:11:24 +00:00
Martin Hunt 683b242643 start-sanitize-d10v
Tue Jul 23 10:36:19 1996  Martin M. Hunt  <hunt@pizza.cygnus.com>

	* emulparams/d10velf.sh: New file.

end-sanitize-d10v
1996-07-23 18:01:42 +00:00
Martin Hunt e9525d9673 start-sanitize-d10v
Tue Jul 23 10:36:19 1996  Martin M. Hunt  <hunt@pizza.cygnus.com>

	* Makefile.in (ed10velf.c): New target.
	* configure.tgt (d10v-*-elf*): New target.
	* emulparams/d10velf.sh: New file.

end-sanitize-d10v
1996-07-23 18:00:39 +00:00
Ian Lance Taylor 73a66e7ade * configure.tgt (sparc*-*-sysv4*): New target. From Andrew Gierth
<ANDREWG@microlise.co.uk>.
1996-07-18 21:40:06 +00:00
Ian Lance Taylor 71cd1bb6ee * configure.host: Change irix5 to irix[56]*.
* configure.tgt: Likewise.
1996-07-18 20:35:34 +00:00
Kim Knuttila 2154656e3d Pay attention to return code 1996-07-18 00:04:58 +00:00
Kim Knuttila 611a763fe5 Strip prefix '.'s from name 1996-07-17 17:55:38 +00:00
Ian Lance Taylor 888b0b2fa0 Mon Jul 15 11:49:49 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Round
 	the value of __start_SECNAME to the alignment required by the
 	section to be placed.
1996-07-15 15:58:00 +00:00
Ian Lance Taylor 719de0ea8c * configure.tgt (mips*el-*-elf*): Use elf32elmip.
(mips*-*-elf*): Use elf32ebmip.
	* emulparams/elf32bmip.sh (EMBEDDED): Don't define.
	* emulparams/elf32lmip.sh (EMBEDDED): Don't define.
	* emulparams/elf32elmip.sh: New file; copy of elf32lmip.sh with
	EMBEDDED defined.
	* emulparams/elf32ebmip.sh: New file; copy of elf32bmip.sh with
	EMBEDDED defined.
	* emulparams/elf32b4300.sh (EMBEDDED): Define.
	* emulparams/elf32l4300.sh (EMBEDDED): Define.
	* Makefile.in (ALL_EMULATIONS): Add eelf32ebmip.o eelf32elmip.o.
	(eelf32ebmip.c, eelf32elmip.c): New targets.
Irix 5 is not an embedded system.
1996-07-09 16:13:56 +00:00
Jeff Law cce8528df9 No longer sanitize away h8s stuff. 1996-07-05 18:54:28 +00:00
Ian Lance Taylor e44c2b1c06 * ldver.c (ldversion): Set version to cygnus-2.7.1. 1996-07-04 19:40:37 +00:00
Ian Lance Taylor 1ab4cd57ed * emulparams/pc532macha.sh: Rename from pc532machaout.sh to avoid
System V file name limitations.
	* configure.tgt (nc32k-pc532-mach*, ns32k-pc532-ux*): Use
	pc532macha rather than pc532machaout.
	* Makefile.in (ALL_EMULATIONS): Change epc532machaout.o to
	epc532macha.o.
	(epc532macha.c): Rename target from epc532machaout.c.
1996-07-04 18:50:13 +00:00
Ian Lance Taylor 45c85bcb34 x 1996-07-04 16:03:09 +00:00
Ian Lance Taylor 4702444f69 * ldlang.c (print_padding_statement): Use %u, not %x, to print
fill value.
1996-07-03 15:46:26 +00:00
Stan Shebs bfac208d92 * mpw-eppcmac.c: Update to reflect May 23 change to aix.em. 1996-06-30 18:19:34 +00:00
Ian Lance Taylor 2ea93eb9d8 * configure.host: Use -print-file-name=FILE rather than piping
-print-libgcc-file-name through sed.
	(i[345]86*-*-sco*, i[345]86-*-isc*): Create crtbegin.o and
	crtend.o files, in case gcc doesn't use them.
	* Makefile.in (mostlyclean): Remove crtbegin.o and crtend.o.
1996-06-27 18:07:47 +00:00
Ian Lance Taylor 90c1d8f7e4 * configure.tgt (mips*-dec-osf*): New target. 1996-06-26 19:58:40 +00:00
Jason Molenda f14a5192ce * Makefile.in (bindir, libdir, datadir, mandir, infodir, includedir,
INSTALL_PROGRAM, INSTALL_DATA): Use autoconf-set values.
        (docdir): Removed.
        * configure.in (AC_PREREQ): autoconf 2.5 or higher.
        (AC_PROG_INSTALL): Added.
        * configure: Rebuilt.
1996-06-25 13:23:22 +00:00
Michael Meissner edcfb9db65 Do not do PROVIDE of _GLOBAL_OFFSET_TABLE_ 1996-06-24 22:57:16 +00:00
Ian Lance Taylor d7b5386f2b Mon Jun 24 17:55:31 1996 Jouke Numan <jnuman@bazis.nl>
* ldlang.h (enum section_type): Define.
	(lang_output_section_statement_type): Remove loadable field.  Add
	sectype field.
	(lang_enter_output_section_statement): Change flags parameter in
	prototype to sectype.
	* ldgram.y (typebits): Remove.
	(sectype): New static variable.
	(opt_at): Use sectype rather than typebits.
	(type): Set sectype rather than typebits.
	(atype): Likewise.
	* ldlex.l: Recognize DSECT, COPY, INFO, and OVERLAY in
	EXPRESSION mode.
	* ldlang.c (lang_output_section_statement_lookup): Set sectype
	field rather than loadable field.
	(wild_doit): Check sectype rather than loadable.
	(lang_record_phdrs): Likewise.
	(lang_enter_output_section_statement): Rename flags parameter to
	sectype.  Set sectype field rather than loadable field.  Set flags
	field based on sectype.
1996-06-24 22:01:01 +00:00
Ian Lance Taylor 8530ae8eed * configure.in: On alpha*-*-osf*, link against libbfd.a if not
using shared libraries.
	* configure: Rebuild with autoconf 2.10.
1996-06-24 16:04:19 +00:00
Ian Lance Taylor 817ef33811 Fri Jun 21 17:40:56 1996 Joel Sherrill <joel@merlin.gcs.redstone.army.mil>
* configure.tgt: Add support for *-*-rtems* configurations.
1996-06-21 22:12:01 +00:00
Ian Lance Taylor 539ae61d9c Fri Jun 21 13:05:51 1996 Richard Henderson <rth@tamu.edu>
* configure.tgt (alpha-*-linuxecoff*): New target.
	(alpha-*-linux*): Use elf64alpha.
	* emulparams/elf64alpha.sh: New file.
	* emultempl/elf32.em: If ELFSIZE is not set, set it to 32.  Use
	${ELFSIZE} rather than 32 when calling BFD routines.
	(hold_rodata): New static variable.
	(gld${EMULATION_NAME}_place_orphan): Use hold_rodata for a
	readonly section that is not code.
	(gld${EMULATION_NAME}_place_section): Set hold_rodata.  Don't use
	a .rel section unless its bfd_section field is not NULL.
	* Makefile.in (ALL_EMULATIONS): Add eelf64alpha.o.
	(eelf64alpha.c): New target.
1996-06-21 17:10:14 +00:00
Ian Lance Taylor a475297cf1 * ldmisc.c (vfinfo): Correct handling of 0 in %W case. 1996-06-21 16:46:10 +00:00
Ian Lance Taylor 55745b34b0 Add enough support to understand the gcc svr3.ifile script:
* ldlex.l: Recognize BLOCK and GROUP in EXPRESSION context.  Add
	BIND keyword.
	* ldgram.y: Add BIND token.
	(section): Recognize GROUP.
	(opt_ext_with_type): Recognize a couple of cases of BIND.
	* ldlang.c (init_os): Don't do anything if section is already
	initialized.  Call exp_init_os on addr_tree field.
	(exp_init_os): New static function.
	(map_input_to_output_sections): Call exp_init_os on assignment
	expression.
	(lang_place_orphans): Check for common sections by name COMMON
	rather than by common_section field.  Don't warn about absence of
	[COMMON] command.
1996-06-20 18:23:24 +00:00
Jeff Law 71415be57c * scripttempl/h8300s.sc: New file for H8/S.
* emulpararms/h8300s.sh: New file for H8/S.
        * Makefile.in (ALL_EMULATIONS): Add H8/S.
        (e_h8300s.c): Add dependencies.
        * configure.tgt: Add H8/S to targ_extra_emuls.
H8/S linker stuff.  Sanitized until status of this code is known.
1996-06-18 22:55:30 +00:00
Ian Lance Taylor 2e71dfc02c * configure.tgt (i[345]86*-*-isc*): New target. From
<uddeborg@carmen.se>.
1996-06-18 21:58:52 +00:00
Jim Wilson f98286385f Kill r16/rce/acp stuff. 1996-06-08 03:52:13 +00:00
Jim Wilson ed381b6719 Kill r16/rce/acp stuff. 1996-06-08 03:18:15 +00:00
Ian Lance Taylor b72b1a0c52 * emultempl/sunos.em: Include libiberty.h.
(gld${EMULATION_NAME}_set_symbols): New static function to add
	LD_LIBRARY_PATH to the list of search directories.
	(ld_${EMULATION_NAME}_emulation): Add new set_symbols routine.
1996-06-07 15:29:36 +00:00
Ian Lance Taylor 1760b4aeab * emulparams/elf32bmip.sh (OTHER_GOT_SYMBOLS): Use ALIGN(16)
rather than . when computing _gp value.  From Per Fogelstrom.
	* emulparams/elf32lmip.sh (OTHER_GOT_SYMBOLS): Likewise.
1996-06-06 16:23:04 +00:00
Ian Lance Taylor 39e6bc339f * ldmain.c (main): Don't close and unlink the file on error, since
remove_output will do it anyhow.
	* ldlang.c (open_output): Set boolean variable to true, not 1.
1996-06-06 16:07:23 +00:00
Ian Lance Taylor 07acd23b77 * ldcref.c: New file.
* ld.h (add_cref, output_cref): Declare.
	* ldmain.c (main): Initialize notice_all field.  If it is set at
	end of link, call output_cref.
	(notice): Rename from notice_ysym.  Check notice_all.
	* ldmisc.c (finfo): Make globally visible.
	* ldmisc.h (finfo): Declare.
	* lexsup.c (OPTION_CREF): Define.
	(ld_options): Add "cref".
	(parse_args): Handle OPTION_CREF.
	* Makefile.in: Rebuild dependencies.
	(CFILES): Add ldcref.c.
	(OFILES): Add ldcref.o.
	* ld.texinfo, ld.1: Document --cref.
1996-06-04 23:37:13 +00:00
Tom Tromey 2c7aeec634 * Makefile.in (install): Don't check to see if tooldir exists.
Make $(tooldir) and $(tooldir)/bin.
1996-06-04 22:16:01 +00:00
Ian Lance Taylor e5ca07bfae * emultempl/pe.em (sort_sections): Don't assume that a
wild_statement has a section name.
1996-05-31 16:43:12 +00:00
Ian Lance Taylor 90557a6aea * scripttempl/elfmips.sc: Quote test -z argument. 1996-05-29 20:10:22 +00:00
Ian Lance Taylor a1d393cfb9 * ld.texinfo: Clarify the CONSTRUCTORS command. 1996-05-29 17:14:24 +00:00
Ian Lance Taylor 64a37d3cfc * emultempl/aix.em (gld${EMULATION_NAME}_read_file): Initialize
file, not impfile.
PR 9759.
1996-05-23 23:09:44 +00:00
David Edelsohn fe6e29571a * ldlang.c (wild_doit): Don't copy over SEC_LINK_{ONCE,DUPLICATES}
if final link.
	* emultempl/pe.em (sfunc): Renamed to sort_by_file_name.
	(sort_by_section_name, sort_sections_1): New functions.
	(sort_sections): Only sort by file name sections in .idata.
	Add "Grouped Sections" support.
	(gld${EMULATION_NAME}_place_orphan): Rewrite to support Grouped
	Sections.
	(gld${EMULATION_NAME}_place_section): Delete.
	* scripttempl/pe.sc (.text,.data,.rdata): Add *(.foo\$).
	(.CRT,.rsrc): Rewrite to use Grouped Section support.
1996-05-22 19:09:32 +00:00
Stan Shebs 3d6ee1b961 * mpw-eppcmac.c: Update to reflect changes to aix.em. 1996-05-21 21:36:46 +00:00
David Edelsohn 4242ac27a5 * ldlang.c (dprint_statement): Stop printing at end of list. 1996-05-20 00:01:03 +00:00
Steve Chamberlain de7c7482b1 Support for --force-exe-suffix
* ld.h (args_type): Add force_exe_suffix.
	* ld.texinfo: Add documentation.
	* ldmain.c (main):  Add support for option.
	* lexsup.c (OPTION_FORCE_EXE_SUFFIX): New.
	(ld_options, parse_args):  Add support for option.
1996-05-18 20:28:30 +00:00
Jim Wilson b3319029ac * emultempl/pe.em (set_pe_value): Pass 0 not 16 to strtoul call. 1996-05-15 19:53:31 +00:00
Michael Meissner fb2a7661fb Set __stack = 0 if it is referenced and not defined. 1996-05-10 20:32:07 +00:00
Rob Savoye 01d8a35928 * emulparams/{elf32bmip.sh,elf32lmip.sh,mipsidt.sh,mipsidtl.sh}:
Set a new variable to signify if the final target is an embedded
	system.
	* scripttempl/{mips.sc,elfmips.sc}: Don't add SIZEOF_HEADERS to
	.text for an embedded system.
1996-05-09 15:56:58 +00:00
Jeff Law 00e6a1b14d * scripttempl/h8300.sc: Place ".tiny" sections right
after ".data" sections.
        * scripttempl/h8300h.sc: Place ".tiny" sections into
        the "tiny" memory region, 0xff8000 through 0xffff00.
HMSE.
1996-05-07 21:26:58 +00:00
Jeff Law 12688490b2 * scripttempl/h8300.sc: Set the entry point to the value of
"_start" rather than the start of the text segment.
        * scripttempl/h8300h.sc: Likewise.
So we can have data at the start of the text space.
1996-05-07 19:36:38 +00:00
David Edelsohn 67afbceace Document semicolon usage. 1996-05-07 18:29:22 +00:00
David Edelsohn 7248b4e2d2 * scripttempl/pe.em (gld${EMULATION_NAME}_place_orphan): New function.
(gld${EMULATION_NAME}_place_section): New function.
	(hold_{section,use,text,rdata,data}): New static locals.
	(ld_${EMULATION_NAME}_emulation): Update orphan field.
	* scripttempl/pe.sc: Whitespace cleanup.  Semicolon usage cleanup.
	(INIT,FINI): Delete, unused.
	(.text): Document orphan .text.foo sections.
	(.rdata): Document orphan .rdata.foo sections.
	(.data): Document orphan .data.foo sections.
1996-05-07 18:04:07 +00:00
David Edelsohn a1613b5f35 * scripttempl/pe.em (gld${EMULATION_NAME}_place_orphan): New function.
(gld${EMULATION_NAME}_place_section): New function.
	(hold_{section,use,text,rdata,data}): New static locals.
	(ld_${EMULATION_NAME}_emulation): Update orphan field.
1996-05-07 17:58:43 +00:00
Jeff Law d38d6b7a85 * scripttempl (h8300.sc, h8300h.sc): Place .rodata sections
before .text sections in main ram.
Gets "read only" data out of the instruction stream -- improves
relaxing linker.  HMSE.
1996-05-07 17:33:17 +00:00
Jeff Law 4015337ec7 * scripttempl/h8300h.sc: Use "eight", not "eightbit" for the
8-bit region and 8-bit sections.
HMSE.
1996-05-07 05:30:14 +00:00
David Edelsohn 0a0d1bdd6e * ldlang.c (section_already_linked): Fix typos. 1996-05-02 00:51:15 +00:00
David Edelsohn f2618f8252 * scripttempl/pe.sc (.endjunk): Define __end__. 1996-04-30 03:33:23 +00:00
Ian Lance Taylor 0cacbcbe6e * ldlang.c (longest_section_name): Remove.
(SECTION_NAME_MAP_LENGTH): Define.
	(print_size, print_alignment, print_fill, print_section): Remove.
	(print_flags): Remove.
	(lang_map): Rewrite.
	(print_output_section_statement): Rewrite.
	(print_assignment): Rewrite.
	(print_one_symbol): Rewrite.
	(print_input_section): Rewrite.
	(print_fill_statement): Rewrite.
	(print_data_statement): Rewrite.
	(print_address_statement): New static function.
	(print_reloc_statement): Rewrite.
	(print_padding_statement): Rewrite.
	(print_wild_statement): Rewrite.
	(print_statement_list): Clean up.
	(print_statement): Clean up.  Some minor output changes.
	(print_statements): Clean up.
	(load_symbols): Put another - before -whole-archive.
	* ldexp.c (exp_print_tree): Change etree_value and etree_rel to
	print 0x and to omit leading zeroes.  For etree_rel, use %B to
	print the BFD.  For etree_assign, remove the space after the
	destination name.
	* ldwrite.c: Include "libiberty.h".
	(clone_section): Call xstrdup, not strdup.
	(ldwrite): Don't print any map information.
	(print_symbol_table, print_file_stuff, print_symbol): Remove.
	* ldmain.c (main): Call lang_map when appropriate.
	* ldmisc.c (vfinfo): Add support for %W.
	(print_address): Remove.
	* ldmisc.h (print_address): Don't declare.
	* Makefile.in: Rebuild dependencies.
1996-04-29 21:12:49 +00:00
Ian Lance Taylor ec7d9f3d3c Mon Apr 29 10:33:10 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* ld-shared/shared.exp: Run the shared library tests on
 	Linux/m68k.
1996-04-29 14:34:44 +00:00
Ian Lance Taylor df872c9ea4 Mon Apr 29 10:29:07 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* configure.host (m68*-*-linux*): Add -dynamic-linker to
 	HOSTING_CRT0.  Search -lgcc both before and after -lc in
 	HOSTING_LIBS.  Look for crt{begin,end}.o in the compiler directory
 	at first.
	(i[345]86-*-linux*): Look for crt{begin,end}.o in the compiler
	directory at first.
1996-04-29 14:34:14 +00:00
Ian Lance Taylor efa6c49704 * ldmisc.h (demangle): Declare.
* ldmisc.c: Include "libiberty.h".  Include demangle.h with "",
 	not <>.
	(demangle): Make non-static.  Remove remove_underscore paramter.
	Always return an allocated string.
	(vfinfo): Free result of demangle.  Add case 'G'.  Use %T to print
	functionname, rather than calling demangle.  Print a colon between
	the BFD(section+offset) and the line number.
	* ldmain.c (add_archive_element): Improve format of archive
	information in map file.
	(constructor_callback): Don't print anything to the map file.
	* ldlang.c (lang_one_common): Improve format of common symbol
	information in map file.
	* ldctor.c (ldctor_build_sets): If producing a map file, print set
	information.
	* ldwrite.c (print_symbol_table): Print a newline before the
	header in the map file.
	* Makefile.in: Rebuild dependencies.
1996-04-26 22:15:10 +00:00
Ian Lance Taylor f0f80b13f8 * ldmisc.c (vfinfo): Reindent. 1996-04-26 18:42:55 +00:00
Ian Lance Taylor 6799c638e5 * ldlang.c (lang_size_sections): If _cooked_size is not 0, then
don't clobber it when not relaxing.

	* ld.h (ld_config_type): Remove traditional_format field.
	* ldmain.c (main): Use link_info.traditional_format rather than
	config.traditional_format.
	* ldlang.c (ldlang_open_output): Likewise.
	* lexsup.c (parse_args): Likewise.
	* emultempl/aix.em (gld${EMULATION_NAME}_parse_args): Likewise.
	* mpw-eppcmac.c (gldppcmacos_parse_args): Likewise.
1996-04-22 21:32:58 +00:00
Ian Lance Taylor 6429ad7e58 * ldlang.c (wild_doit): Discard debugging sections if we are
stripping debugging information.
1996-04-22 16:22:52 +00:00
Ian Lance Taylor 14706a96af * emulparams/z8002.sh (ARCH): Set to z8002, not z8k. 1996-04-22 16:08:18 +00:00