зеркало из https://github.com/mozilla/gecko-dev.git
124 строки
5.7 KiB
Diff
124 строки
5.7 KiB
Diff
diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
|
|
index c9360fc67165..b9451bde3dd8 100644
|
|
--- a/clang/lib/Driver/ToolChains/Linux.cpp
|
|
+++ b/clang/lib/Driver/ToolChains/Linux.cpp
|
|
@@ -310,12 +310,6 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
|
|
addPathIfExists(D, SysRoot + "/usr/lib", Paths);
|
|
}
|
|
|
|
-ToolChain::RuntimeLibType Linux::GetDefaultRuntimeLibType() const {
|
|
- if (getTriple().isAndroid())
|
|
- return ToolChain::RLT_CompilerRT;
|
|
- return Generic_ELF::GetDefaultRuntimeLibType();
|
|
-}
|
|
-
|
|
ToolChain::CXXStdlibType Linux::GetDefaultCXXStdlibType() const {
|
|
if (getTriple().isAndroid())
|
|
return ToolChain::CST_Libcxx;
|
|
diff --git a/clang/lib/Driver/ToolChains/Linux.h b/clang/lib/Driver/ToolChains/Linux.h
|
|
index 169a37c44072..65897631715a 100644
|
|
--- a/clang/lib/Driver/ToolChains/Linux.h
|
|
+++ b/clang/lib/Driver/ToolChains/Linux.h
|
|
@@ -39,7 +39,6 @@ public:
|
|
llvm::opt::ArgStringList &CC1Args) const override;
|
|
void AddIAMCUIncludeArgs(const llvm::opt::ArgList &DriverArgs,
|
|
llvm::opt::ArgStringList &CC1Args) const override;
|
|
- RuntimeLibType GetDefaultRuntimeLibType() const override;
|
|
CXXStdlibType GetDefaultCXXStdlibType() const override;
|
|
bool
|
|
IsAArch64OutlineAtomicsDefault(const llvm::opt::ArgList &Args) const override;
|
|
diff --git a/clang/test/Driver/linux-ld.c b/clang/test/Driver/linux-ld.c
|
|
index cc505588331b..fc43acd07644 100644
|
|
--- a/clang/test/Driver/linux-ld.c
|
|
+++ b/clang/test/Driver/linux-ld.c
|
|
@@ -283,7 +283,7 @@
|
|
// RUN: --sysroot=%S/Inputs/basic_linux_tree \
|
|
// RUN: | FileCheck --check-prefix=CHECK-CLANG-ANDROID-NONE %s
|
|
// CHECK-CLANG-ANDROID-NONE: "{{.*}}ld{{(.exe)?}}" "--sysroot=[[SYSROOT:[^"]+]]"
|
|
-// CHECK-CLANG-ANDROID-NONE: "-l:libunwind.a" "-ldl" "-lc"
|
|
+// CHECK-CLANG-ANDROID-NONE: "-lgcc" "-ldl" "-lc"
|
|
//
|
|
// RUN: %clang -shared -no-canonical-prefixes %s -### -o %t.o 2>&1 \
|
|
// RUN: --target=aarch64-linux-android -rtlib=platform --unwindlib=platform \
|
|
@@ -291,7 +291,7 @@
|
|
// RUN: --sysroot=%S/Inputs/basic_linux_tree \
|
|
// RUN: | FileCheck --check-prefix=CHECK-CLANG-ANDROID-SHARED %s
|
|
// CHECK-CLANG-ANDROID-SHARED: "{{.*}}ld{{(.exe)?}}" "--sysroot=[[SYSROOT:[^"]+]]"
|
|
-// CHECK-CLANG-ANDROID-SHARED: "-l:libunwind.a" "-ldl" "-lc"
|
|
+// CHECK-CLANG-ANDROID-SHARED: "-lgcc" "-ldl" "-lc"
|
|
//
|
|
// RUN: %clang -static -no-canonical-prefixes %s -### -o %t.o 2>&1 \
|
|
// RUN: --target=aarch64-linux-android -rtlib=platform --unwindlib=platform \
|
|
@@ -299,7 +299,7 @@
|
|
// RUN: --sysroot=%S/Inputs/basic_linux_tree \
|
|
// RUN: | FileCheck --check-prefix=CHECK-CLANG-ANDROID-STATIC %s
|
|
// CHECK-CLANG-ANDROID-STATIC: "{{.*}}ld{{(.exe)?}}" "--sysroot=[[SYSROOT:[^"]+]]"
|
|
-// CHECK-CLANG-ANDROID-STATIC: "--start-group" "{{[^"]*}}{{/|\\\\}}libclang_rt.builtins-aarch64-android.a" "-l:libunwind.a" "-lc" "--end-group"
|
|
+// CHECK-CLANG-ANDROID-STATIC: "--start-group" "-lgcc" "-lc" "--end-group"
|
|
//
|
|
// RUN: %clang -no-canonical-prefixes %s -### -o %t.o 2>&1 \
|
|
// RUN: --target=x86_64-unknown-linux -rtlib=platform --unwindlib=platform \
|
|
@@ -1081,12 +1081,10 @@
|
|
// CHECK-ANDROID: "--enable-new-dtags"
|
|
// CHECK-ANDROID: "{{.*}}{{/|\\\\}}crtbegin_dynamic.o"
|
|
// CHECK-ANDROID: "-L[[SYSROOT]]/usr/lib"
|
|
-// CHECK-ANDROID-NOT: "-lgcc_s"
|
|
-// CHECK-ANDROID-NOT: "-lgcc"
|
|
-// CHECK-ANDROID: "-l:libunwind.a"
|
|
+// CHECK-ANDROID-NOT: "gcc_s"
|
|
+// CHECK-ANDROID: "-lgcc"
|
|
// CHECK-ANDROID: "-ldl"
|
|
-// CHECK-ANDROID-NOT: "-lgcc_s"
|
|
-// CHECK-ANDROID-NOT: "-lgcc"
|
|
+// CHECK-ANDROID-NOT: "gcc_s"
|
|
// CHECK-ANDROID: "{{.*}}{{/|\\\\}}crtend_android.o"
|
|
// RUN: %clang -no-canonical-prefixes %s -### -o %t.o 2>&1 \
|
|
// RUN: --target=arm-linux-androideabi -rtlib=platform --unwindlib=platform \
|
|
@@ -1139,12 +1137,10 @@
|
|
// CHECK-ANDROID-SO-NOT: "-Bsymbolic"
|
|
// CHECK-ANDROID-SO: "{{.*}}{{/|\\\\}}crtbegin_so.o"
|
|
// CHECK-ANDROID-SO: "-L[[SYSROOT]]/usr/lib"
|
|
-// CHECK-ANDROID-SO-NOT: "-lgcc_s"
|
|
-// CHECK-ANDROID-SO-NOT: "-lgcc"
|
|
-// CHECK-ANDROID-SO: "-l:libunwind.a"
|
|
+// CHECK-ANDROID-SO-NOT: "gcc_s"
|
|
+// CHECK-ANDROID-SO: "-lgcc"
|
|
// CHECK-ANDROID-SO: "-ldl"
|
|
-// CHECK-ANDROID-SO-NOT: "-lgcc_s"
|
|
-// CHECK-ANDROID-SO-NOT: "-lgcc"
|
|
+// CHECK-ANDROID-SO-NOT: "gcc_s"
|
|
// CHECK-ANDROID-SO: "{{.*}}{{/|\\\\}}crtend_so.o"
|
|
// RUN: %clang -no-canonical-prefixes %s -### -o %t.o 2>&1 \
|
|
// RUN: --target=arm-linux-androideabi -rtlib=platform --unwindlib=platform \
|
|
@@ -1195,12 +1191,10 @@
|
|
// CHECK-ANDROID-STATIC: "{{.*}}ld{{(.exe)?}}" "--sysroot=[[SYSROOT:[^"]+]]"
|
|
// CHECK-ANDROID-STATIC: "{{.*}}{{/|\\\\}}crtbegin_static.o"
|
|
// CHECK-ANDROID-STATIC: "-L[[SYSROOT]]/usr/lib"
|
|
-// CHECK-ANDROID-STATIC-NOT: "-lgcc_eh"
|
|
-// CHECK-ANDROID-STATIC-NOT: "-lgcc"
|
|
-// CHECK-ANDROID-STATIC: "-l:libunwind.a"
|
|
+// CHECK-ANDROID-STATIC-NOT: "gcc_s"
|
|
+// CHECK-ANDROID-STATIC: "-lgcc"
|
|
// CHECK-ANDROID-STATIC-NOT: "-ldl"
|
|
-// CHECK-ANDROID-STATIC-NOT: "-lgcc_eh"
|
|
-// CHECK-ANDROID-STATIC-NOT: "-lgcc"
|
|
+// CHECK-ANDROID-STATIC-NOT: "gcc_s"
|
|
// CHECK-ANDROID-STATIC: "{{.*}}{{/|\\\\}}crtend_android.o"
|
|
// RUN: %clang -no-canonical-prefixes %s -### -o %t.o 2>&1 \
|
|
// RUN: --target=arm-linux-androideabi -rtlib=platform --unwindlib=platform \
|
|
@@ -1253,11 +1247,9 @@
|
|
// CHECK-ANDROID-PIE: "{{.*}}ld{{(.exe)?}}" "--sysroot=[[SYSROOT:[^"]+]]"
|
|
// CHECK-ANDROID-PIE: "{{.*}}{{/|\\\\}}crtbegin_dynamic.o"
|
|
// CHECK-ANDROID-PIE: "-L[[SYSROOT]]/usr/lib"
|
|
-// CHECK-ANDROID-PIE-NOT: "-lgcc_s"
|
|
-// CHECK-ANDROID-PIE-NOT: "-lgcc"
|
|
-// CHECK-ANDROID-PIE: "-l:libunwind.a"
|
|
-// CHECK-ANDROID-PIE-NOT: "-lgcc_s"
|
|
-// CHECK-ANDROID-PIE-NOT: "-lgcc"
|
|
+// CHECK-ANDROID-PIE-NOT: "gcc_s"
|
|
+// CHECK-ANDROID-PIE: "-lgcc"
|
|
+// CHECK-ANDROID-PIE-NOT: "gcc_s"
|
|
// CHECK-ANDROID-PIE: "{{.*}}{{/|\\\\}}crtend_android.o"
|
|
// RUN: %clang -no-canonical-prefixes %s -### -o %t.o 2>&1 \
|
|
// RUN: --target=arm-linux-androideabi \
|