From 24d47b3460c983e3b01d8230a46b1ea19828bde1 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Wed, 6 Jul 2011 04:43:39 +0000 Subject: PR gold/12952 * resolve.cc (Symbol::override_base_with_special): Simply override version with special symbol version, ignoring previous version. --- gold/resolve.cc | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'gold/resolve.cc') diff --git a/gold/resolve.cc b/gold/resolve.cc index 8850a3d46aa..720b350b327 100644 --- a/gold/resolve.cc +++ b/gold/resolve.cc @@ -911,7 +911,15 @@ Symbol::override_base_with_special(const Symbol* from) } if (same_name) - this->override_version(from->version_); + { + // When overriding a versioned symbol with a special symbol, we + // may be changing the version. This will happen if we see a + // special symbol such as "_end" defined in a shared object with + // one version (from a version script), but we want to define it + // here with a different version (from a different version + // script). + this->version_ = from->version_; + } this->type_ = from->type_; this->binding_ = from->binding_; this->override_visibility(from->visibility_); -- cgit v1.2.1