From da093c388fc9a559295faa6265cb8b1643ce9eeb Mon Sep 17 00:00:00 2001 From: Dan Albert Date: Wed, 29 Apr 2020 12:18:45 -0700 Subject: [PATCH] [lld] Remove special cases from default ld driver mode. Summary: Use the Gnu driver mode by default for all platforms when ld is invoked. Other names for the program (such as link or ld64) continue working as before. Reviewers: MaskRay, int3, srhines, smeenai, ruiu Reviewed By: MaskRay, srhines, smeenai, ruiu Subscribers: smeenai, srhines, nickdesaulniers, llvm-commits Tags: #lld, #llvm Differential Revision: https://reviews.llvm.org/D78837 --- lld/tools/lld/lld.cpp | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/lld/tools/lld/lld.cpp b/lld/tools/lld/lld.cpp index 58a291d..8a8f8d0 100644 --- a/lld/tools/lld/lld.cpp +++ b/lld/tools/lld/lld.cpp @@ -96,17 +96,9 @@ static bool isPETarget(std::vector &v) { } static Flavor parseProgname(StringRef progname) { -#if __APPLE__ - // Use Darwin driver for "ld" on Darwin. - if (progname == "ld") - return Darwin; -#endif - -#if LLVM_ON_UNIX - // Use GNU driver for "ld" on other Unix-like system. + // Use GNU driver for "ld" by default. if (progname == "ld") return Gnu; -#endif // Progname may be something like "lld-gnu". Parse it. SmallVector v; -- 2.7.4