[Driver] Don't pass --dynamic-linker to ld on Solaris
authorRainer Orth <ro@gcc.gnu.org>
Tue, 16 Jul 2019 11:06:43 +0000 (11:06 +0000)
committerRainer Orth <ro@gcc.gnu.org>
Tue, 16 Jul 2019 11:06:43 +0000 (11:06 +0000)
commita5dc9c98352c396c0114403486fbd47e092d084a
treea0e8cfc421386e4b36208bfab8ed94037181a411
parent971ac4ca2cb8172a1c8f59c7703680b41aa7a5f5
[Driver] Don't pass --dynamic-linker to ld on Solaris

I noticed that clang currently passes --dynamic-linker to ld.  This has been the case
since Solaris 11 support was added initially back in 2012 by David Chisnall (r150580).
I couldn't find any patch submission, let alone a justification, for this, and it seems
completely useless: --dynamic-linker is a gld compatibility form of the option, the
native option being -I.  First of all, however, the dynamic linker passed is simply the
default, so there's no reason at all to specify it in the first place.

This patch removes passing the option and adjusts the affected testcase accordingly.

Tested on x86_64-pc-solaris2.11 and sparcv9-sun-solaris2.11.

Differential Revision: https://reviews.llvm.org/D64493

llvm-svn: 366202
clang/lib/Driver/ToolChains/Solaris.cpp
clang/test/Driver/Inputs/solaris_sparc_tree/usr/lib/ld.so.1 [deleted file]
clang/test/Driver/Inputs/solaris_sparc_tree/usr/lib/sparcv9/ld.so.1 [deleted file]
clang/test/Driver/Inputs/solaris_x86_tree/usr/lib/amd64/ld.so.1 [deleted file]
clang/test/Driver/Inputs/solaris_x86_tree/usr/lib/ld.so.1 [deleted file]
clang/test/Driver/solaris-ld.c