Commit graph

957 commits

Author SHA1 Message Date
Jeff Law
831d7ac47c * scripttempl/hppaelf.sc (.text): Place unwind descriptors in the
text segment.
1994-11-16 17:06:20 +00:00
Ken Raeburn
8e0e09f600 keep riscix, pc532mach files 1994-11-15 09:15:56 +00:00
Ian Lance Taylor
fee3930ea4 Keep ld-shared. 1994-11-14 16:57:14 +00:00
Ian Lance Taylor
0632d303d1 Keep i386lynx.mh. 1994-11-14 16:54:44 +00:00
Ian Lance Taylor
fd41732af2 * scripttempl/elf.sc: Add ENTRY(${ENTRY}), and default ${ENTRY} to
_start.
1994-11-12 20:59:18 +00:00
Ian Lance Taylor
5efddb2e7c * ld.h (args_type): Add field export_dynamic.
* lexsup.c (parse_args): Recognize --export-dynamic.
	* emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation):
	Pass export_dynamic argument to bfd_elf32_size_dynamic_sections.
1994-11-12 20:54:09 +00:00
Ian Lance Taylor
809391bd0a * ldlang.c (lang_one_common): Set SEC_ALLOC in any section where
we allocate common symbols.
1994-11-09 17:48:24 +00:00
Ian Lance Taylor
cd1d4f83e7 Tue Nov 8 17:50:43 1994 Eric Youngdale (eric@aib.com)
* scripttempl/elf.sc: Add .rel.init, .rela.init, .rel.fini, and
	.rela.fini to the list of .rel* sections.
1994-11-08 22:57:13 +00:00
Ian Lance Taylor
6a02a973c4 * ldlang.c (load_symbols): Add new argument place. Only accept
linker scripts if place is not NULL.  Put commands found in an
	assumed linker script into place.
	(lookup_name): Pass NULL as place argument to load_symbols.
	(open_input_bfds): In lang_input_statement_enum case, pass a place
	argument to load_symbols, and store any new statements after the
	current one.
PR 5917.
1994-11-08 22:54:07 +00:00
Ken Raeburn
ca8f2f0d74 Makefile.in: fix tipo in e*nbsd.c dependencies 1994-11-04 20:14:03 +00:00
Ken Raeburn
0128cbae50 * Makefile.in (check): Add missing "else true" clause.
* emulparams/vax.sh (OUTPUT_FORMAT): Use "a.out".

* scripttempl/go32coff.sc: Changes from DJ Delorie: Change default entry point
to "start".  Align at end of each section to 0x200.  Start .text section 0x1000
later.  Add _etext, _edata, _end symbols.
1994-11-04 00:39:49 +00:00
Ian Lance Taylor
52329a29a2 * ldctor.c (ldctor_add_set_entry): Don't permit a set to be
composed of different object file formats.
	(ldctor_build_sets): If the output format does not support the
	reloc, and we are not generating a relocateable link, try getting
	the reloc from the input format.
1994-11-02 17:22:28 +00:00
J.T. Conklin
e574ddd43a * Makefile.in (ALL_EMULATIONS): Added em68knbsd.o.
(em68knbsd.c): New target.

* config/m68k-nbsd.mt: New file.
* emulparams/m68knbsd.sh: New file.
* configure.in (m68*-*-netbsd*): Use above configs.
1994-11-01 18:33:35 +00:00
Ian Lance Taylor
fbf967b0da * emultempl/sunos.em (gld${EMULATION_NAME}_find_so): If we find an
appropriately named static library, stop the search at that
	directory.
1994-11-01 00:37:05 +00:00
Ian Lance Taylor
0d29b6cc9d * lib/ld.exp (default_ld_compile): Remove the output file before
compiling.
1994-10-31 00:05:09 +00:00
Ian Lance Taylor
f9c3e5871e * ld-shared: New directory, with new files to test generating ELF
shared libraries.
1994-10-27 21:33:10 +00:00
Ian Lance Taylor
b5bd927ce5 * lib/ld.exp (default_ld_compile): If the compilation worked, but
no object file was created, check to see if the compiler foolishly
	ignored the -o switch when compiling, and move the resulting
	object if it did.
1994-10-27 21:31:50 +00:00
J.T. Conklin
32286e08a5 * Makefile.in (ALL_EMULATIONS): Added ei386nbsd.o, ens32knbsd.o
and esparcnbsd.o; sorted entries.
  (ei386nbsd.c,ens32knbsd.c,esparcnbsd.c): New targets.

* config/netbsd532.mt: Removed.
* emulparams/netbsd532.sh: Removed.

* config/{i386-nbsd.mt,ns32k-nbsd.mt,sparc-nbsd.mt}: New files.
* emulparams/{i386nbsd.sh,ns32knbsd.sh,sparcnbsd.sh}: New files.
* configure.in (i[345]86-*-netbsd*, ns32k-pc532-netbsd*,
  sparc*-*-netbsd*): Use above configs.
1994-10-26 21:02:02 +00:00
Ian Lance Taylor
fdfe873a8a * ldmain.c (multiple_common): One of the types may now be
bfd_link_hash_indirect.  The old BFD argument may be NULL.
1994-10-25 15:48:09 +00:00
Ian Lance Taylor
3286598fca * configure.in: Add * at the end of m68k-hp-hpux. 1994-10-21 02:02:54 +00:00
Ian Lance Taylor
81100e78a3 * ldlex.l: Cast assignment to yy_ch_buf field to char *, not to
YY_CHAR *.
1994-10-18 19:59:52 +00:00
J.T. Conklin
51bdfd9b22 * scripttempl/nw.sc: Gather constructors and destructors and
define __CTOR__LIST__ and __DTOR_LIST__ appropriately.
1994-10-17 22:03:09 +00:00
Ken Raeburn
0a1e63c4b5 updated version 1994-10-17 20:33:46 +00:00
J.T. Conklin
9ff30f20cd * Makefile.in (ALL_EMULATIONS): Add ei386nw.o and eppcnw.o.
(ei386nw.c, eppcnw.c): New targets.

* config/{i386,ppc}-nw.mt, emulparams/{i386,ppc}nw.sh,
  scripttmpl/nw.sc: New files, for i386 and powerpc netware.

* configure.in: Changed netware ld_target name to be {i386,ppc}-nw
  instead of {i386,ppc}-elf.

* configure.in (sparc*-*-netware): Removed.  There is no such
  thing anymore.
1994-10-14 22:57:12 +00:00
J.T. Conklin
54d6484691 * ldint.texinfo: Move misplaced `@end iftex'. 1994-10-14 21:38:10 +00:00
Ian Lance Taylor
81d191be79 Fri Oct 14 12:02:18 1994 Eric Youngdale (eric@aib.com)
* scripttempl/elf.sc: Add .rel.ctors, .rela.ctors, .rel.dtors, and
	.rela.dtors to the list of .rel* sections.
1994-10-14 16:04:27 +00:00
Ken Raeburn
f608f62e26 configure.in: handle i[345]86-*-linux*, not just -linux 1994-10-13 18:17:11 +00:00
Ian Lance Taylor
243f6d0d67 * scripttempl/aout.sc: Set _etext and __etext to ., not
${DATA_ALIGNMENT}.  This is compatible with SunOS, and, with luck,
	will not break any other system.  From Eric Valette
	<ev@chorus.fr>.
1994-10-13 15:26:35 +00:00
Ian Lance Taylor
a82ae15d4b * lexsup.c (parse_args): Change -V to be a synonym for -v. Add
--verbose to get the old -V behaviour.
	* ld.1, ld.texinfo: Document this change.
1994-10-12 20:26:35 +00:00
Ian Lance Taylor
f2b38b9848 missed this file 1994-09-29 16:42:43 +00:00
Ian Lance Taylor
d2c0200413 * VMS does not permits `.' in directory names. Renamed
ld.bootstrap to ld-bootstrap, ld.cdtest to ld-cdtest, and
	ld.scripts to ld-scripts.
1994-09-29 16:39:01 +00:00
Ian Lance Taylor
f81eadb499 * config/default.exp: Set variables as and nm. Create tmpdir if
it does not already exist.
	* ld.bootstrap/bootstrap.exp: Don't create tmpdir here.
	* ld.cdtest/cdtest.exp: Likewise.
	* ld.scripts/defined.exp: Likewise.  Also, don't set as and nm
	here.  Change perror for no variables found to fail.
	* ld.scripts/script.exp: New test.
	* ld.scripts/script.t, ld.scripts/script.s: New files.
1994-09-28 16:21:32 +00:00
Ian Lance Taylor
9de5523bb6 * ld.scripts: New directory.
* ld.scripts/defined.exp, ld.scripts/defined.s: New files.
	* ld.scripts/defined.t: New file.
	* lib/ld.exp (default_ld_simple_link): New function.
	(default_ld_assemble, default_ld_nm): New functions.
	* config/default.exp: Rename from unix-ld.exp.
	(ld_simple_link, ld_assemble, ld_nm): New functions.
1994-09-28 00:06:27 +00:00
Ian Lance Taylor
aa61b92302 * ldexp.c (fold_name): For DEFINED case, don't try to look up the
name in the hash table during the first phase--the hash table does
	not even exist at that point, much less have the right value.
PR 5699.
1994-09-27 22:41:51 +00:00
Ian Lance Taylor
262c876349 * Makefile.in (CC): Define.
(CXX): Move definition, change from g++ to gcc.
	(EXPECT, RUNTEST): Copy definitions from top level Makefile.in.
	(RUNTEST_CC, RUNTEST_CFLAGS): Remove.
	(RUNTEST_CXX, RUNTEST_CXXFLAGS): Remove.
	(CC_FOR_TARGET, CXX_FOR_TARGET): Copy from top level Makefile.in.
	(.cc.o): Comment out.
	(testdir): Remove.
	(site.exp): Don't create testdir or set tmpdir.
	(check): Run checks even if not running native.  Use CC_FOR_TARGET
	instead of RUNTEST_CC, and likewise for CXX.
	(cdtest targets): Comment out.
	* config/solaris2.mh (HOSTING_LIBS): Only mention crtend.o once.
	* cdtest-bar.cc, cdtest-foo.cc, cdtest-foo.h: Remove.
	* cdtest-main.cc, cdtest.exp: Remove.
1994-09-27 22:25:04 +00:00
Ian Lance Taylor
5c680d3f29 * config/unix-ld.exp: Set ld using findfile.
* lib/ld.exp (default_ld_relocate): Return a value.  Change format
	of log messages.
	(default_ld_compile): Likewise.
	(default_ld_link): Likewise.  Also, don't include $BFDLIB and
	$LIBIBERTY in link.
	* ld.bootstrap/bootstrap.exp: Rewrite.
	* ld.cdtest/cdtest.exp: Rewrite.
	* ld.cdtest/cdtest-foo.cc: Update from top level ld directory.
	* ld.cdtest/cdtest-foo.h: Likewise.
	* ld.cdtest/cdtest-main.cc: Likewise.
1994-09-27 22:23:51 +00:00
Ian Lance Taylor
1eadd162c4 * emulparams/elf32bmip.sh: Rename from elf32mipb.sh to avoid DOS
file naming problems.
	* emulparams/elf32lmip.sh: Rename from elf32mipl.sh.
	* Makefile.in (ALL_EMULATIONS): Rename eelf32mipb.o to
	eelf32bmip.o and eelf32mipl.o to eelf32lmip.o.
	(eelf32bmip.c): Rename from eelf32mipb.c.  Use elf32bmip.sh.
	(eelf32lmip.c): Rename from eelf32mipl.c.  Use elf32lmip.sh.
	* config/mipsb-elf32.mt (EMUL): Use elf32bmip, not elf32mipb.
	* config/mipsl-elf32.mt (EMUL): Use elf32lmip, not elf32mipl.
1994-09-26 22:08:57 +00:00
Ian Lance Taylor
381897782a * genscripts.sh: Always search /usr/local/TARGET/lib. 1994-09-26 18:00:10 +00:00
Ian Lance Taylor
2150c3eea6 * scripttempl/elf.sc: If -N is set, force DATA_ADDR to be ".". 1994-09-26 15:41:20 +00:00
Ian Lance Taylor
a2eea82333 * lexsup.c (parse_args): Add support for -a for HP/UX
compatibility.
1994-09-23 16:31:32 +00:00
Ian Lance Taylor
8603728123 * ld.h (args_type): Add new field endian.
* lexsup.c (parse_args): Handle -EB and -EL by setting
	command_line.endian.
	* ldgram.y (ifile_p1): Accept OUTPUT_FORMAT with three arguments.
	* ldlang.c (lang_add_output_format): Add arguments big and little.
	If command_line.endian is set, use it to select big or little
	rather than the default.  Changed all callers.
	* ldlang.h (lang_add_output_format): Update declaration.
	* emulparams/elf32mipb.sh: Define BIG_OUTPUT_FORMAT and
	LITTLE_OUTPUT_FORMAT.
	* emulparams/elf32mipl.sh: Likewise.
	* emulparams/mipsbig.sh: Likewise.
	* emulparams/mipsbsd.sh: Likewise.
	* emulparams/mipsidt.sh: Likewise.
	* emulparams/mipsidtl.sh: Likewise.
	* emulparams/mipslit.sh: Likewise.
	* scripttempl/elf.sc: Define BIG_OUTPUT_FORMAT and
	LITTLE_OUTPUT_FORMAT if not already defined.  Pass them to
	OUTPUT_FORMAT.
	* scripttempl/mips.sc: Pass BIG_OUTPUT_FORMAT and
	LITTLE_OUTPUT_FORMAT to OUTPUT_FORMAT.
	* scripttempl/mipsbsd.sc: Likewise.
1994-09-20 21:16:11 +00:00
Ian Lance Taylor
5ccef1803e * Makefile.in (ALL_EMULATIONS): Add eelf32mipb.o and eelf32mipl.o.
(eelf32mipl.c): New target.
1994-09-20 19:07:36 +00:00
Ian Lance Taylor
f1781adcf3 * configure.in (mips*el-elf*): New target.
* config/mipsl-elf32.mt: New file.
	* emulparams/elf32mipl.sh: New file.
1994-09-20 18:41:27 +00:00
Ian Lance Taylor
006ae0e478 * ldmain.c (main): Rather than prohibiting ld -r -s, treat it as
ld -r -S -x.
PR 5596.
1994-09-16 16:17:26 +00:00
Ian Lance Taylor
7aa8f49656 * ldmisc.c (vfinfo): Print BFD file name as well as file name
returned by find_nearest_line, in case the file name is something
	unhelpful such as a .h file.  Handle %u.
1994-09-15 17:07:02 +00:00
Ian Lance Taylor
8150b20a18 Add some news. 1994-09-15 17:05:24 +00:00
Ian Lance Taylor
809ee7e036 * ld.h (ld_config_type): Add new field warn_once.
* ldmain.c (undefined_symbol): Handle -warn-once.
	* lexsup.c (parse_args): Recognize -warn-once.
	* ld.texinfo (Options): Document -warn-once.
	* ld.1: Likewise.
PR 4456.
1994-09-14 22:27:16 +00:00
Steve Chamberlain
467a038026 Wed Sep 14 12:49:12 1994 Steve Chamberlain (sac@jonny.cygnus.com)
* ldlang.c (lang_do_assignments): Make sure output statement
	has an attached bfd_section before trying to dereference it.
1994-09-14 20:45:43 +00:00
Ian Lance Taylor
31c271643b Tweak the new handling of function names. 1994-09-14 18:29:06 +00:00
Ian Lance Taylor
cc23cc69c5 * ldmisc.c (vfinfo): Handle %D as %C, but never print the function
name.  For %C, print the function name on a separate line, to keep
	the length of error messages under control.
	* ldmain.c (multiple_definition): Use %D for ``first defined
	here.''
	(undefined_symbol): Use %D for ``more undefined references
	follow''.
PR 3770.
1994-09-14 17:08:37 +00:00
Ian Lance Taylor
8bff41c1b7 * ldmisc.c (multiple_warn): Remove; no longer used.
* ldmisc.h (multiple_warn): Don't declare.
1994-09-14 16:50:19 +00:00
Steve Chamberlain
3deb20fbc1 * ldlang.c (print_output_section_statement): Print all lines
to the map file.
1994-09-14 04:55:00 +00:00
Ian Lance Taylor
0b3499f672 * ldlang.c (load_symbols): Check for archive before object. Use
bfd_check_format_matches, and, if ambiguous, print a list of
	matching formats.  If file format is not recognized, treat file as
	a linker script.
	* ldgram.y (yyerror): If assuming an object file is a script,
	mention that.  Tweak the format of the error messages.
	* ldlex.l (lex_warn_invalid): If assuming an object is a script,
	guess that this is not actually a script, and just report that the
	file format was not recognized.
	* ld.texinfo (Options): Admit that -( may be used more than once.
	Add note that unrecognized object files are now treated as linker
	scripts.

	* ldfile.c (ldfile_input_filename): Make const.
	(ldfile_assumed_script): New variable.
	(try_open): Change arguments types to const.
	(ldfile_find_command_file): Likewise.
	(ldfile_open_command_file): Likewise.  Also, set lineno to 1.
	* ldfile.h: Update declarations for ldfile.c changes.
	* ldlex.l: Include <ctype.h>.
	(file_name_stack): Change to be const char *.
	(lineno_stack): New static variable.
	(<<EOF>>): Set lineno as well as ldfile_input_filename.
	(lex_push_file): Make name argument const.  Initialize
	lineno_stack entry.
	(lex_redirect): Initialize lineno_stack entry.
	(lex_warn_invalid): Handle non printable characters nicely.
	* ldlex.h (lex_push_file): Declare second argument as const.

	* ldgram.y (ifile_p1): Recognize GROUP.
	* ldlex.l: Recognize GROUP.
	* ld.texinfo (Option Commands): Document GROUP.
1994-09-13 20:42:47 +00:00
Stan Shebs
177941a1c9 Merge in former supposed GM-specific bits 1994-09-13 00:20:31 +00:00
Stan Shebs
2b51073813 Remove supposedly (but not really) GM-specific bits 1994-09-13 00:18:55 +00:00
Ian Lance Taylor
2fd87dbc90 * config/m68klynx.mh: New file. 1994-09-12 21:06:35 +00:00
Jeff Law
cb2af5cfec * emultempl/hppaelf.em: Add newlines to the error messages. 1994-09-12 07:51:14 +00:00
Ian Lance Taylor
7b63ff7683 * config/i386lynx.mh: New file.
* scripttempl/i386lynx.sc: Don't put .ctors and .dtors in .text
	unless CONSTRUCTING.
1994-09-12 02:42:49 +00:00
Ian Lance Taylor
dd37f21531 * emulparams/elf32mipb.sh (TEMPLATE_NAME): Define as elf32.
(GENERATE_SHLIB_SCRIPT): Define as yes.
	(DYNAMIC_LINK): Define as false.
	* emultempl/elf32.em (gld${EMULATION_NAME}_before_parse):
	Initialize config.dynamic_link to DYNAMIC_LINK if it is defined.
	(gld${EMULATION_NAME}_place_orphan): Reset stat_ptr at end.
	* Makefile.in (eelf32mipb.c): Depend upon elf32.em rather than
	generic.em.
1994-09-10 20:04:17 +00:00
Steve Chamberlain
fa3539fe77 * scripttempl/h8500b.sc: Put rdata stuff into own segment. 1994-09-08 23:36:17 +00:00
Ian Lance Taylor
a864a26ecc * emulparams/elf32ppc.sh (OTHER_READWRITE_SECTIONS): Don't define;
.got section is now explicitly handled in elf.sc.
1994-09-08 17:26:27 +00:00
Ian Lance Taylor
82950a806a x 1994-09-07 03:57:59 +00:00
Ian Lance Taylor
1822664fe4 * scripttempl/m68kcoff.sc: Put .bss in data segment.
* scripttempl/h8300.sc: Change .stab and .stabstr to use a VMA of
	0, and to only be marked as NOLOAD if relocating.
	* scripttempl/h8500.sc, scripttempl/h8500b.sc: Likewise.
	* scripttempl/h8500c.sc, scripttempl/h8500m.sc: Likewise.
	* scripttempl/h8500s.sc, scripttempl/i386coff.sc: Likewise.
	* scripttempl/i386go32.sc, scripttempl/i386lynx.sc: Likewise.
	* scripttempl/m68kcoff.sc, scripttempl/m68klynx.sc: Likewise.
	* scripttempl/sh.sc, scripttempl/sparccoff.sc: Likewise.
	* scripttempl/sparclynx.sc: Likewise.
1994-09-07 03:57:09 +00:00
Ken Raeburn
318b02b6b9 ARM Acorn/RISCiX target and host patches from Richard Earnshaw 1994-09-05 10:53:00 +00:00
Ian Lance Taylor
3b21918aa6 * ld.h (args_type): Add field soname.
* lexsup.c (parse_args): Handle -soname argument.
	* emultempl/elf32.em: In call to bfd_elf32_size_dynamic_sections,
	pass soname.
	* ld.texinfo: Document -soname.
1994-08-30 16:04:19 +00:00
Ian Lance Taylor
69927008de * ldlang.c (lang_check): Don't try to set the architecture if the
input and output files are incompatible.  Just warn.
For Synoptics.
1994-08-29 19:24:48 +00:00
Ian Lance Taylor
6d4454364b * configure.in: Change i[34]86 to i[345]86. 1994-08-24 16:53:39 +00:00
Ian Lance Taylor
b400f56dbb Make the ELF linker handle orphaned sections reasonably. Also,
define __start_SECNAME and __stop_SECNAME around sections whose
	names can be represented in C, for the benefit of symbol sets in
	glibc.
	* ldemul.h (ldemul_place_orphan): Declare.
	(ld_emulation_xfer_type): Add place_orphan field.
	* ldemul.c (ldemul_place_orphan): New function.
	* ldlang.h (wild_doit): Declare.
	* ldlang.c (wild_doit): Make nonstatic.
	(lang_place_orphans): Call ldemul_place_orphan.
	* emultempl/elf32.em: Include <ctype.h> and "ldgram.h".
	(hold_section, hold_use, hold_text, hold_data, hold_bss): New
	static variables.
	(gld${EMULATION_NAME}_place_orphan): New static function.
	(gld${EMULATION_NAME}_place_section): New static function.
	(ld_${EMULATION_NAME}_emulation): Initialize place_orphan field.
1994-08-18 20:10:54 +00:00
Ian Lance Taylor
9e5a036f28 * scripttempl/aout.sc: Add .linux-dynamic after .data. 1994-08-16 04:19:32 +00:00
Ian Lance Taylor
c1a9aaa316 * Treat --dll-verbose as --version, for Linux compatibility. From
hjl@nynexst.com (H.J. Lu).
1994-08-16 04:10:03 +00:00
Ian Lance Taylor
1fee94ece0 * ldexp.h (exp_get_abs_int): Declare. 1994-08-15 21:18:48 +00:00
Jason Molenda
28d1c6ec8c Fri Aug 5 20:55:55 1994 Jason Molenda (crash@phydeaux.cygnus.com)
* configure.in: add i960-nindy-coff support.
1994-08-06 03:57:19 +00:00
Jean Marie Diaz
63936abc32 * ldlex.l (yy_create_string_buffer): Handle change to internal
interface in flex 2.4.7.
1994-08-04 18:56:04 +00:00
Jean Marie Diaz
bb329c2009 Tue Aug 2 11:52:06 1994 Eric Youngdale (ericy@cais.cais.com)
* emultempl/linux.em (gld${EMULATION_NAME}_find_address_statement):
	New function; add 0x20 to any use of -Ttext.
	(gld${EMULATION_NAME}_create_output_section_statements): New
	function.
	(ld_${EMULATION_NAME}_emulation): Use the new function
	gld${EMULATION_NAME}_create_output_section_statements.
1994-08-02 16:01:56 +00:00
Ian Lance Taylor
a1ed243577 * scripttempl/mips.sc: Redo script to set . outside of sections
and not bother to explicitly specify section addresses.
1994-08-01 19:55:21 +00:00
Ian Lance Taylor
b019d460d1 * scripttempl/elf.sc: Copy several more relocation sections into
the output.  Put .got.plt sections into .got.
1994-07-26 15:04:40 +00:00
Ian Lance Taylor
31ddb15694 * scripttempl/elf.sc: Use PROVIDE to define etext, edata, and end.
Add a new script operator, PROVIDE, to define a symbol only if it
	is needed.
	* ldgram.y (PROVIDE): New token.
	(assignment): Accept PROVIDE.
	* ldlex.l (PROVIDE): New token.
	* ldexp.h (node_type): Add etree_provide to node_class enum.
	(exp_provide): Declare.
	* ldexp.c (exp_fold_tree): Handle etree_provide.
	(exp_provide): New function.
	(exp_print_tree): Handle etree_provide.
	* ld.texinfo: Document PROVIDE.
1994-07-22 20:55:45 +00:00
Ian Lance Taylor
36c6e8c37f * ldlang.c (lang_common): Pass desired alignment to
lang_one_common as power of two.
	(lang_one_common): Get common symbol alignment from linker hash
	table entry.  Treat desired alignment as a power of two.
1994-07-22 18:46:28 +00:00
Ian Lance Taylor
309c8153fa * ldlang.c (wild_section): Attach all section with the given name,
not just the first one.  If there is no name, attach all sections
	even if the SEC_IS_COMMON flag is set.
1994-07-22 16:23:35 +00:00
Ian Lance Taylor
a1ad915dc4 * ld.h (args_type): Add field rpath.
* lexsup.c (S_ISDIR): Define if not already defined.
	(parse_args): Add support for -rpath.  If -R is used to name a
	directory, treat it as -rpath for Solaris compatibility.
	* emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation):
	Pass command_line.rpath to bfd_elf32_size_dynamic_sections.
	* ldmain.c (main): Initialize command_line.rpath to NULL.
	* ld.texinfo: Document -rpath option.
1994-07-20 19:55:36 +00:00
Ken Raeburn
cdf7137776 ns32k port from Ian Dall 1994-07-14 19:20:53 +00:00
Ian Lance Taylor
db770dfa72 * lexsup.c (parse_args): Changed "retain-symbols-file" from
no_argument to required_argument.  From djm.
1994-07-08 15:06:29 +00:00
Jeff Law
aee611f53c * scripttempl/hppaelf.sc (__stack_zero): Don't define this name,
it was for the HPUX dynamic loader's use and it creates problems
	with ELF GDB.
1994-07-05 01:38:32 +00:00
Stan Shebs
10f1b5978b Elim dup of file names 1994-06-30 23:19:26 +00:00
Stan Shebs
8b50a709e9 Fix typo 1994-06-30 00:08:11 +00:00
Jean Marie Diaz
0373062441 * config/solaris2.mh (NATIVE_LIB_DIRS): Define as /usr/ccs/lib. 1994-06-29 21:18:47 +00:00
Jean Marie Diaz
111b24d572 * lexsup.c (parse_args): Accept -Bstatic and -Bdynamic. Do not
accept plain -B.
	* ld.texinfo: -Bstatic is not ignored.
1994-06-29 20:59:53 +00:00
Stan Shebs
22691fe7be * mpw-config.in (emulname): Set based on target.
(ldemul-list.h): Construct.
	* mpw-make.in (install-only): New target.
	(install): Depend on install-only.
1994-06-28 20:20:35 +00:00
Stan Shebs
83896c8b2b * mpw-xconfig.in: Remove ldemul-list.h construction, now in
generic config.
1994-06-28 20:16:32 +00:00
Stan Shebs
1c883f34fc * ldlex.l: Recognize \r the same as \n. 1994-06-28 19:16:24 +00:00
David MacKenzie
1f8b3b5746 Change --with-targets to --enable-targets, per GNU coding standards. 1994-06-23 20:08:57 +00:00
Ian Lance Taylor
cf4245afad * lexsup.c (parse_args): Add support for new options -( -) with
synonyms --start-group --end-group.
	* ldlang.h (enum statement_enum): Add lang_group_statement_enum.
	(lang_group_statement_type): Define new struct.
	(lang_statement_union_type): Add group_statement field.
	(lang_enter_group, lang_leave_group): Declare.
	* ldlang.c (lang_for_each_statement_worker): Handle
	lang_group_statement_enum.
	(map_input_to_output_sections, print_statement): Likewise.
	(lang_size_sections, lang_do_assignments): Likewise.
	(open_input_bfds): Completely rewrite.  Now does its own looping,
	rather than using lang_for_each_statement.  Handle groups.
	(lang_process): Update call to open_input_bfds.
	(print_group): New static function.
	(lang_enter_group, lang_leave_group): New static functions.
	* ldfile.c (ldfile_open_file): If the file has already been
	opened, just return rather than taking an assertion failure.
	* ldver.c (help): Mention new options.
	* ld.texinfo: Document new options.
1994-06-23 00:36:00 +00:00
Ian Lance Taylor
02b5798089 * ldlang.c (end_of_data_section_statement_list): Don't define.
(lang_leave_output_section_statement): Don't set obsolete variable
	end_of_data_section_statement_list.
1994-06-22 23:07:14 +00:00
Ian Lance Taylor
62a4b36c6b * scripttempl/go32coff.sc: Don't put ${DATA_ALIGNMENT} inside an
ALIGN.
1994-06-22 20:11:07 +00:00
Ian Lance Taylor
686739e2c6 * ldlang.c (lang_size_sections): Adjust current region address
even for sections with an explicit address.  From
	ralphc@pyramid.com (Ralph Campbell).
1994-06-22 20:04:29 +00:00
Ian Lance Taylor
7d56d4f1c6 * emulparams/i386linux.sh (NONPAGED_TEXT_START_ADDR): Set to 0.
From jrs@world.std.com (Rick Sladkey).
1994-06-22 18:07:32 +00:00
Ian Lance Taylor
3b7553e793 * scripttempl/mipsbsd.sc: Let sections align to their natural
boundaries.
1994-06-22 17:47:11 +00:00
Jeff Law
c4aa82c196 * scripttempl/hppaelf.sc: Place .data and .bss at 0x40000000
when generating relocatable objects.
1994-06-17 04:50:29 +00:00
Ken Raeburn
8e3b100c24 deleted code for keep-v9 that does nothing useful 1994-06-17 00:52:10 +00:00
Ian Lance Taylor
64887de2ee * lexsup.c (parse_args): Add -shared to longopts, and handle it.
* ldmain.c (main): Initialize link_info.shared to false.  Give
	error if link_info.relocateable and link_info.shared are both set.
1994-06-16 19:32:07 +00:00