aboutsummaryrefslogtreecommitdiff
path: root/gold/options.cc
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>2011-07-03 04:46:56 +0000
committerIan Lance Taylor <ian@airs.com>2011-07-03 04:46:56 +0000
commit886288f10bd9d10fb446191e5266154c38f0cbad (patch)
tree26e8bfbc8ec2337e1c3f4212b8a1aa54f46c88d7 /gold/options.cc
parentae3a6d4fa3cfdf9daa38946945b2a6aa0c0e9fa8 (diff)
downloadgdb-886288f10bd9d10fb446191e5266154c38f0cbad.zip
gdb-886288f10bd9d10fb446191e5266154c38f0cbad.tar.gz
gdb-886288f10bd9d10fb446191e5266154c38f0cbad.tar.bz2
PR gold/12957
* options.h (class General_options): Add -f and -F. * options.cc (General_options::finalize): Fatal error if -f/-F are used without -shared. * layout.cc (Layout::finish_dynamic_section): Implement -f/-F.
Diffstat (limited to 'gold/options.cc')
-rw-r--r--gold/options.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/gold/options.cc b/gold/options.cc
index 50fc557..f1dc1cb 100644
--- a/gold/options.cc
+++ b/gold/options.cc
@@ -1166,6 +1166,14 @@ General_options::finalize()
if (this->pie() && this->relocatable())
gold_fatal(_("-pie and -r are incompatible"));
+ if (!this->shared())
+ {
+ if (this->filter() != NULL)
+ gold_fatal(_("-F/--filter may not used without -shared"));
+ if (this->any_auxiliary())
+ gold_fatal(_("-f/--auxiliary may not be used without -shared"));
+ }
+
// TODO: implement support for -retain-symbols-file with -r, if needed.
if (this->relocatable() && this->retain_symbols_file())
gold_fatal(_("-retain-symbols-file does not yet work with -r"));