summaryrefslogtreecommitdiff
path: root/ld/lexsup.c
Commit message (Collapse)AuthorAgeFilesLines
* * ldmain.c (main): Remove PE stuff.Steve Chamberlain1995-08-221-88/+152
| | | | | * lexsup.c (options): Load more PE options. (set_pe_value): New function.
* * lexsup.c (parse_args): Accept -h as a synonym for --soname, forIan Lance Taylor1995-08-161-3/+9
| | | | Solaris compatibility.
* * ld.texinfo, ld.1: Document -Bstatic, -Bdynamic, -Bshared, andIan Lance Taylor1995-07-101-1/+6
| | | | | | | | | -shared. Mon Jul 10 13:29:43 1995 Eric Youngdale <eric@aib.com> * ldmain.c (main): Set link_info.symbolic to false. * lexsup.c (parse_args): Handle -Bsymbolic.
* fsf address update, but not in COPYING filesKen Raeburn1995-07-071-1/+1
|
* * lexsup.c (parse_args): Let -G either set the small data size orIan Lance Taylor1995-07-031-1/+25
| | | | | | be equivalent to --shared, depending on the next argument. Accept and ignore -z for Solaris compatibility. PR 7118.
* * lexsup.c (parse_args): Cast fopen result to PTR before storingIan Lance Taylor1995-07-021-6/+7
| | | | it in link_info.base_file. Fix indentation.
* Wed Jun 28 17:11:25 1995 Steve Chamberlain <sac@slash.cygnus.com>Steve Chamberlain1995-06-291-7/+156
| | | | | | | | | | * ldmain.c (main): Always initialize PE info in link_info. * lexsup.c (OPTION_BASE_FILE): New option. (parse_args): Handle new option. * emulparams/armpe.sh: Output pei. * emultempl/i386pe.em: Add newline to end. * scripttempl/armpe.sc: Change output and quote the $s. * scripttempl/i386pe.sc: Change output and quote the $s.
* * ld.h (args_type): Add new field endian.Ian Lance Taylor1994-09-201-7/+3
| | | | | | | | | | | | | | | | | | | | | | | | * 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.
* * ld.h (ld_config_type): Add new field warn_once.Ian Lance Taylor1994-09-141-5/+54
| | | | | | | | * 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.
* * lexsup.c (parse_args): Changed "retain-symbols-file" fromIan Lance Taylor1994-07-081-6/+40
| | | | no_argument to required_argument. From djm.
* * lexsup.c (parse_args): Accept -static as a synonym forIan Lance Taylor1994-06-151-0/+1
| | | | -non_shared.
* * ldmain.c (get_emulation): Ignore -m486 for Linux compatibility.Ian Lance Taylor1994-06-151-0/+1
| | | | * lexsup.c (parse_args): Ignore -qmagic for Linux compatibility.
* Let the user change the dynamic linker used by ELF code.Ian Lance Taylor1994-06-151-1/+6
| | | | | | | | | | | | * ld.h (args_type): Add new field interpreter. * lexsup.c (parse_args): Add dynamic-linker to longopts, and handle it. * ldmain.c (main): Initialize command_line.interpreter to NULL. * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation): Get the ELF backend to return the .interp section. If command_line.interpreter is not NULL, set the contents of .interp to it. * ld.texinfo: Mention -dynamic-linker.
* * lexsup.c (parse_args): Sort out the option macros and change theIan Lance Taylor1994-06-151-22/+23
| | | | definitions to make it easier to add a new option.
* * ld.h (ld_config_type): Add new field traditional_format.Ian Lance Taylor1994-06-151-3/+8
| | | | | | | | | * lexsup.c (parse_args): Add traditional_format to longopts, and handle it. * ldmain.c (main): Initialize config.traditional_format to false. * ldlang.c (ldlang_open_output): Set BFD_TRADITIONAL_FORMAT in BFD flags of output_bfd according to config.traditional_format. * ld.texinfo: Document -traditional-format.
* * lexsup.c (parse_args): Treat -i as a synonym for -r.Ian Lance Taylor1994-06-131-0/+1
|
* * ldfile.h (search_dirs_type): Move from ldfile.c, and add cmdlineIan Lance Taylor1994-06-021-2/+2
| | | | | | | | | | | | | | | field. (search_head): Declare. (ldfile_add_library_path): Add new cmdline argument in prototype. * ldfile.c (search_head): Make non-static. (search_dirs_type): Move to ldfile.h. (ldfile_add_library_path): Accept cmdline argument, and save it. * lexsup.c (parse_args): Pass true for new cmdline argument of ldfile_add_library_path. (set_default_dirlist): Likewise. * ldmain.c (check_for_scripts_dir): Pass false for new cmdline argument of ldfile_add_library_path. * ldgram.y (ifile_p1): Likewise.
* * ldlang.c (entry_symbol): Make static.Ian Lance Taylor1994-05-271-1/+1
| | | | | | | (lang_add_entry): Add cmdline argument. * ldlang.h (lang_add_entry): Change prototype. * ldgram.y (statement_anywhere): Change lang_add_entry call. * lexsup.c (parse_args): Likewise.
* Add support for ELF shared libraries.Ian Lance Taylor1994-05-191-23/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | * ld.h (ld_config_type): Add field dynamic_link. * ldmain.c (main): Initialize config.dynamic_link to false. Warn on attempts to use -r with -relax, -call_shared or -s. * lexsup.c (longopts): Separate OPTION_CALL_SHARED from OPTION_NON_SHARED. Add OPTION_IGNORE. Adjust macro values accordingly. Add "dy" and "non_shared" options. Change "Qy" to OPTION_IGNORE for now. Handle OPTION_CALL_SHARED and OPTION_NON_SHARED by setting dynamic_link field accordingly. Handle OPTION_IGNORE by ignoring it. Clear dynamic_link field for -r and -Ur. * ldfile.c (ldfile_open_file): If config.dynamic_link is true, try opening a file with a .so extension first. * emultempl/elf32.em: New file. * emulparams/elf32_sparc.sh (TEXT_START_ADDR): Change to 0x10000. (NONPAGED_TEXT_START_ADDR): Likewise. (TEMPLATE_NAME): Define as elf32. (DATA_PLT): Define. * emulparams/elf_i386.sh (TEMPLATE_NAME): Define as elf32. * scripttempl/elf.sc: Add placement for new dynamic sections. Don't use CREATE_OBJECT_SYMBOLS. Define _etext, _edata and _end outside of any section. Don't use ALIGN(8); just let one section VMA follow another. Put .dynbss in .bss. Don't mention debugging sections; they'll be handled correctly anyhow. * Makefile.in (eelf_i386.c): Depend upon elf32.em, not generic.em.
* * ldgram.y (dirlist_ptr): Removed; not used.Ian Lance Taylor1994-02-261-0/+1
| | | | | * lexsup.c: Include ldver.h. * Makefile.in: Rebuilt dependencies.
* Add missing newline in einfo message.David MacKenzie1994-02-251-1/+1
|
* * lexsup.c (parse_args): Use symbolic numbers for long options.David MacKenzie1994-02-251-51/+74
| | | | Fix misunderstanding in -Y and -call_shared et al.
* Use getopt instead of lex and yacc to parse the command line.David MacKenzie1994-02-251-0/+322
* ld.texinfo (Options): Document changes to option syntax. * Makefile.in: Update dependencies. * ldver.c (help): Tweak dashes in usage message. * ldgram.y (%union): Remove unused members. Remove %tokens for command line options; add ones for input types. (command_line): Rules removed. (file): Instead of command line, recognize an input type indicator, then use the nonterminal for that type. (defsym_expr): New nonterminal from code formerly in command_line. * ldlex.h: Declare parser input type enum and variable. Don't declare parse_line. * ldlex.l: Remove unused variables. Make some used ones static and comment them. (COMMAND): Start state and its rules removed. At start of yylex, return input state token if at start of input. (lex_redirect): Don't need to set yyout. (ldlex_command): Function removed. * ldmain.c (main): Instead of calling parse_line, set up the redirections and call yyparse directly. * ldmisc.c (vfinfo): If there's no input filename, print nothing, not "command line". * lexsup.c: Remove #if 0'd code. (parse_line): Function removed. (parse_args): Rewrite to use getopt_long_only. (set_default_dirlist): New function from code formerly in ldgram.y:command_line. (set_section_start): New function. * emultempl/generic.em, emultempl/gld960.em, emultempl/hppaelf.em, emultempl/lnk960.em, emultempl/m88kbcs.em: Don't enclose compiled-in link scripts in "{" and "}", as the grammar no longer wants them to be.