[Mips] Recognize MIPS emulation name 'elf32ltsmip'.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@207687 91177308-0d34-0410-b5e6-96231b3b80d8
[Driver] Remove the redundant cast.

No functional changes.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@207688 91177308-0d34-0410-b5e6-96231b3b80d8
[ELF] Factor out the code builds a library search directory path
into the separate function.

No functional changes.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@207689 91177308-0d34-0410-b5e6-96231b3b80d8
[ELF] Return result from the function ASAP.

No functional changes.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@207690 91177308-0d34-0410-b5e6-96231b3b80d8
[Driver] Check type of InputElement before request a error message. If the
element is a FileNode, request error description. If the element is Group,
print hard coded error message. We need to implement a better diagnostics
here but even current solution is better than a segmentation fault output.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@207691 91177308-0d34-0410-b5e6-96231b3b80d8
[PECOFF] Add a test for lib.exe subcommand.

Previously the input file for the lib.exe command would be removed
as soon as the command exits, so we couldn't write a test to check
the file contents are correct.

This patch adds /lldmoduledeffile: option to retain a copy of the
temporary file at the given file path, so that you can see the file
if you want.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@207727 91177308-0d34-0410-b5e6-96231b3b80d8
[PECOFF] Fix exported symbol name.

When creating a .lib file, we should strip the leading underscore,
but should not strip stdcall atsign suffix. Otherwise produced .lib
files cannot be linked.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@207729 91177308-0d34-0410-b5e6-96231b3b80d8