summaryrefslogtreecommitdiff
path: root/gold/options.cc
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>2009-06-24 05:01:17 +0000
committerIan Lance Taylor <ian@airs.com>2009-06-24 05:01:17 +0000
commit459c9f1c5f4e19a4fdf39ccd9289f0fde532a21b (patch)
treecd3535671fa5e3a04044dd9da0a07b8c83c4f5e4 /gold/options.cc
parentdab97f2471e9939e4ddd126a5cab730c5f6831b5 (diff)
PR 10237
* options.cc (General_options::parse_V): Set printed_version_. (General_options::General_options): Initialize printed_version_. * options.h (class General_options): Add printed_version_ field. * gold.cc (queue_initial_tasks): If there are no input files, don't give a fatal error if we printed the version information. (queue_middle_tasks): If using -r with a shared object, give a fatal error rather than an ordinary error.
Diffstat (limited to 'gold/options.cc')
-rw-r--r--gold/options.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/gold/options.cc b/gold/options.cc
index ef2aa7163f..f09dccb936 100644
--- a/gold/options.cc
+++ b/gold/options.cc
@@ -273,6 +273,7 @@ void
General_options::parse_V(const char*, const char*, Command_line*)
{
gold::print_version(true);
+ this->printed_version_ = true;
printf(_(" Supported targets:\n"));
std::vector<const char*> supported_names;
gold::supported_target_names(&supported_names);
@@ -708,7 +709,8 @@ namespace gold
{
General_options::General_options()
- : execstack_status_(General_options::EXECSTACK_FROM_INPUT), static_(false),
+ : printed_version_(false),
+ execstack_status_(General_options::EXECSTACK_FROM_INPUT), static_(false),
do_demangle_(false), plugins_(),
incremental_disposition_(INCREMENTAL_CHECK), implicit_incremental_(false)
{