Handle versioned undefined symbols.

In order to keep symbol lookup a simple name lookup this patch adds
versioned symbols with an explicit @ to the symbol table.

llvm-svn: 291293
diff --git a/lld/ELF/Symbols.cpp b/lld/ELF/Symbols.cpp
index 72bcff4..f3edafa 100644
--- a/lld/ELF/Symbols.cpp
+++ b/lld/ELF/Symbols.cpp
@@ -202,6 +202,10 @@
   // Truncate the symbol name so that it doesn't include the version string.
   Name = {S.data(), Pos};
 
+  // If this is an undefined or shared symbol it is not a definition.
+  if (isUndefined() || isShared())
+    return;
+
   // '@@' in a symbol name means the default version.
   // It is usually the most recent one.
   bool IsDefault = (Verstr[0] == '@');