Ian Lance Taylor
706e1f5e80
* options.h (General_options): Add entries for '-Y' and
...
'-relax'.
* options.cc (General_options:finalize): If -Y was used, add those
entries to the library path instead of the default "/lib" and
"/usr/lib".
2008-04-11 20:28:34 +00:00
Ian Lance Taylor
0864d55193
* options.h (class General_options): Define --wrap as a special
...
option. Add wrap_symbols_ field.
(General_options::any_wrap_symbols): New function.
(General_options::is_wrap_symbol): New function.
* options.cc (General_options::parse_wrap): New function.
(General_options::General_options): Initialize wrap_symbols_.
* symtab.cc (Symbol_table::wrap_symbol): New function.
(Symbol_table::add_from_object): Handle --wrap.
* symtab.h (class Symbol_table): Declare wrap_symbol.
* target.h (Target::wrap_char): New function.
(Target::Target_info): Add wrap_char field.
* i386.cc (Target_i386::i386_info): Initialize wrap_char.
* x86_64.cc (Target_x86_64::x86_64_info): Likewise.
* testsuite/testfile.cc (Target_test::test_target_info):
Likewise.
2008-04-09 00:48:13 +00:00
Ian Lance Taylor
04bf70729d
PR gold/5986
...
Fix problems building gold with gcc 4.3.0.
* gold.h (TEMPLATE_ATTRIBUTE_PRINTF_4): Define.
(gold_error_at_location, gold_warning_at_location): Use it.
* configure.ac: Check whether we can compile and use a template
function with a printf attribute.
* x86_64.cc (Target_x86_64::do_code_fill): Swap out a 32-bit value
when jumping over bytes.
* object.cc: Instantiate Object::read_section_data.
* debug.h: Include <cstring>
* dwarf_reader.cc: Include <algorithm>
* main.cc: Include <cstring>.
* options.cc: Include <cstring>.
* output.cc: Include <cstring>.
* script.cc: Include <cstring>.
* script.h: Include <string>.
* symtab.cc: Include <cstring> and <algorithm>.
* target-select.cc: Include <cstring>.
* version.cc: Include <string>.
* testsuite/testmain.cc: Include <cstdlib>.
* configure, config.in: Rebuild.
2008-03-26 23:36:46 +00:00
Ian Lance Taylor
819d6c3aea
* options.cc: Include "../bfd/bfdver.h".
...
(options::help): Print bug reporting address.
2008-03-25 23:48:25 +00:00
Ian Lance Taylor
e96caa7910
* options.cc (options::help): Print list of supported targets.
...
* target-select.h: Include <vector>.
(class Target_selector): Make machine_, size_, and is_big_endian_
fields const. Add bfd_name_ and instantiated_target_ fields.
(Target_selector::Target_selector): Add bfd_name parameter.
(Target_selector::recognize): Make non-virtual, call
do_recognize.
(Target_selector::recognize_by_name): Make non-virtual, call
do_recognize_by_name.
(Target_selector::supported_names): New function.
(Target_selector::bfd_name): New function.
(Target_selector::do_instantiate_target): New pure virtual
function.
(Target_selector::do_recognize): New virtual function.
(Target_selector::do_recognize_by_name): New virtual function.
(Target_selector::instantiate_target): New private function.
(supported_target_names): Declare.
* target-select.cc (Target_selector::Target_selector): Update for
new parameter and fields.
(select_target_by_name): Check that the name matches before
calling recognize_by_name.
(supported_target_names): New function.
* i386.cc (class Target_selector_i386): Update Target_selector
constructor call. Remove recognize and recognize_by_name. Add
do_instantiate_target.
* x86_64.cc (class Target_selector_x86_64): Likewise.
* testsuite/testfile.cc (class Target_selector_test): Update for
changes to Target_selector.
2008-03-25 21:39:01 +00:00
Ian Lance Taylor
086a18414a
* options.cc: Include "demangle.h".
...
(parse_optional_string): New function.
(parse_long_option): Handle takes_optional_argument.
(parse_short_option): Update dash_z initializer. Handle
takes_optional_argument.
(General_options::General_options): Initialize do_demangle_.
(General_options::finalize): Set do_demangle_. Handle demangling
style.
* options.h (parse_optional_string): Declare.
(struct One_option): Add optional_arg field. Update constructor.
Update call constructor calls. Add takes_optional_argument
function.
(DEFINE_var): Add optional_arg__ parameter. Change all callers.
(DEFINE_optional_string): Define.
(General_options::demangle): Change from DEFINE_bool to
DEFINE_optional_string.
(General_options::no_demangle): New function.
(General_options::do_demangle): New function.
(General_options::set_do_demangle): New function.
(General_options::execstack_status_): Move definition to end of
class definition.
(General_options::static_): Likewise.
(General_options::do_demangle_): New field.
* object.cc (big_endian>::get_symbol_location_info): Call
Options::do_demangle, not Options::demangle.
* symtab.cc (demangle): Likewise.
2008-03-24 03:48:29 +00:00
Ian Lance Taylor
c18476e7f1
Recognize --hash-bucket-empty-fraction.
2008-03-07 07:00:48 +00:00
Ian Lance Taylor
a4d4b13f68
Use N_ for option help strings, and call gettext when printing them.
2008-03-06 05:51:42 +00:00
Ian Lance Taylor
09ffbbe0d4
From Craig Silverstein: accept any string for input format, warn if
...
thread options when not supported.
2008-03-06 00:53:37 +00:00
Ian Lance Taylor
ee1fe73e11
From Craig Silverstein: rework option handling to make it easier to
...
add a new option.
2008-03-04 23:10:38 +00:00
Ian Lance Taylor
7cc619c3b1
From Craig Silverstein: rename some option functions in preparation
...
for reworking option handling.
2008-03-04 18:21:43 +00:00
Ian Lance Taylor
0dfbdef4c4
Support -d/--define-common.
2008-02-28 20:35:39 +00:00
Ian Lance Taylor
8851eccaec
From Craig Silverstein: Have Parameters point to General_options.
2008-02-28 00:18:24 +00:00
Ian Lance Taylor
7019cd2565
Implement -q/--emit-relocs.
2008-02-27 22:38:18 +00:00
Ian Lance Taylor
a5dc070655
From Craig Silverstein: rework handling of Script_options.
2008-02-26 22:48:08 +00:00
Ian Lance Taylor
cd72c29180
From Craig Silverstein: implement -z max-page-size and -z
...
common-page-size.
2008-02-26 22:10:32 +00:00
Ian Lance Taylor
45aa233bdc
From Craig Silverstein: rename option functions for future option
...
handling rewrite.
2008-02-26 21:45:30 +00:00
Ian Lance Taylor
756ac4a80d
Implement -Tdata and -Tbss.
2008-02-13 22:47:28 +00:00
Ian Lance Taylor
0daa6f62c8
Support selecting target by name.
2008-02-13 02:44:50 +00:00
Ian Lance Taylor
bc644c6cfc
Add support for --format binary for input files.
2008-02-08 07:06:58 +00:00
Ian Lance Taylor
516cb3d01e
Support --oformat binary.
2008-02-07 07:33:46 +00:00
Ian Lance Taylor
88dd47ac00
Implement --just-symbols, including -R FILE. Fix symbol values when
...
doing a relocatable link.
2008-02-07 01:51:25 +00:00
Ian Lance Taylor
6a74a71947
Initial -r support.
2008-02-06 08:13:50 +00:00
Ian Lance Taylor
494e05f440
Parse a SECTIONS clause in a linker script.
2008-01-23 01:31:13 +00:00
Ian Lance Taylor
091244672e
From Andrew Chatham and Craig Silverstein: Add support for version
...
scripts.
2008-01-15 23:41:28 +00:00
Ian Lance Taylor
e5756efb6d
Support assignments and expressions in linker scripts.
2008-01-09 19:57:45 +00:00
Ian Lance Taylor
2dd3e587bd
Report linker script errors with line numbers. Ignore OUTPUT_FORMAT
...
with three arguments, and ignore OUTPUT_ARCH.
2008-01-07 05:19:02 +00:00
Ian Lance Taylor
d391083d3c
Add support for -e and for ENTRY in linker scripts.
2008-01-06 00:47:10 +00:00
Ian Lance Taylor
fced7afdce
Add -h/-soname option.
2008-01-04 05:35:24 +00:00
Ian Lance Taylor
bc2c67ffde
From Craig Silverstein: Fix error message, add this->.
2007-12-08 03:05:27 +00:00
Ian Lance Taylor
9a0910c33e
From Craig Silverstein: Add support for compressing .debug_str section.
2007-11-30 00:35:27 +00:00
Ian Lance Taylor
c79126688f
Add threading support.
2007-11-22 00:05:51 +00:00
Ian Lance Taylor
02d2ba7402
From Craig Silverstein: Add --strip-debug-gdb.
2007-11-15 23:03:45 +00:00
Ian Lance Taylor
a2b1aa12f7
From Craig Silverstein: Add support for --demangle.
2007-11-15 01:12:55 +00:00
Ian Lance Taylor
9a2d698415
Add heuristics for undefined symbol warnings.
2007-11-14 16:53:25 +00:00
Ian Lance Taylor
1ce71f59c7
Default to --allow-shlib-undefined for now.
2007-11-14 09:39:13 +00:00
Ian Lance Taylor
e2827e5f52
Warn about undefined references in shared libraries if we have seen
...
all the DT_NEEDED entries for that library.
2007-11-14 07:34:53 +00:00
Ian Lance Taylor
a55ce7febf
From Craig Silverstein: Rework debug info code a bit, add option for
...
ODR violations, add test case.
2007-11-14 01:03:01 +00:00
Ian Lance Taylor
a0451b389c
From Craig Silverstein: Implement OPTION in linker scripts.
2007-10-30 06:27:03 +00:00
Ian Lance Taylor
3c2fafa531
From Craig Silverstein and Ian Lance Taylor: Process --script option.
2007-10-27 00:29:34 +00:00
Ian Lance Taylor
5d57def3b3
From Craig Silverstein: Minimal --script implementation.
2007-10-26 18:03:24 +00:00
Ian Lance Taylor
35cdfc9a87
Add support for PT_GNU_STACK.
2007-10-23 05:05:48 +00:00
Ian Lance Taylor
6161122258
Implement -Bstatic/-Bdynamic.
2007-10-22 18:04:43 +00:00
Ian Lance Taylor
51b08ebe94
Add support for -Bsymbolic.
2007-10-18 23:20:53 +00:00
Ian Lance Taylor
fe9a4c1201
Add infrastructure for threading support.
2007-10-17 06:24:50 +00:00
Ian Lance Taylor
0c5e9c22aa
From Craig Silverstein: implement -Ttext.
2007-10-16 22:38:36 +00:00
Ian Lance Taylor
cd4662c7e4
Fix exit status.
2007-10-15 03:33:03 +00:00
Ian Lance Taylor
75f2446ec3
Run all error handling through an Errors object. Delete output file
...
on error.
2007-10-14 06:49:14 +00:00
Ian Lance Taylor
e44fcf3bcf
Add --stats option to print runtime and memory usage statistics.
2007-10-12 05:51:25 +00:00
Ian Lance Taylor
46738c9aeb
From Craig Silverstein: don't permit -s and -r.
2007-10-10 19:30:39 +00:00