forked from OSchip/llvm-project
Revert "[Driver][Fuchsia] Add default linker flags"
This reverts commit 5dfc8ebee5
.
This commit is contained in:
parent
40f5c634bc
commit
9ec7272fc5
|
@ -65,12 +65,6 @@ void fuchsia::Linker::ConstructJob(Compilation &C, const JobAction &JA,
|
|||
CmdArgs.push_back("-z");
|
||||
CmdArgs.push_back("rel");
|
||||
CmdArgs.push_back("--pack-dyn-relocs=relr");
|
||||
} else {
|
||||
// The following are already the default in lld
|
||||
CmdArgs.push_back("-z");
|
||||
CmdArgs.push_back("combreloc");
|
||||
CmdArgs.push_back("-z");
|
||||
CmdArgs.push_back("text");
|
||||
}
|
||||
|
||||
if (!D.SysRoot.empty())
|
||||
|
|
|
@ -1,35 +1,27 @@
|
|||
// RUN: %clang -### %s --target=x86_64-unknown-fuchsia \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=lld 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-X86_64 %s
|
||||
// RUN: %clang -### %s --target=x86_64-unknown-fuchsia \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-X86_64 %s
|
||||
// RUN: %clang -### %s --target=x86_64-unknown-fuchsia \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=gold 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LD,CHECK-X86_64 %s
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-X86_64 %s
|
||||
// RUN: %clang -### %s --target=aarch64-unknown-fuchsia \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=lld 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-AARCH64 %s
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-AARCH64 %s
|
||||
// RUN: %clang -### %s --target=riscv64-unknown-fuchsia \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=lld 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-RISCV64 %s
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-RISCV64 %s
|
||||
// RUN: %clang -### %s --target=x86_64-fuchsia \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=lld 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-X86_64 %s
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-X86_64 %s
|
||||
// RUN: %clang -### %s --target=aarch64-fuchsia \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=lld 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-AARCH64 %s
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-AARCH64 %s
|
||||
// RUN: %clang -### %s --target=riscv64-fuchsia \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=lld 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-RISCV64 %s
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-RISCV64 %s
|
||||
// CHECK: "-cc1"
|
||||
// CHECK-X86_64: "-triple" "x86_64-unknown-fuchsia"
|
||||
// CHECK-AARCH64: "-triple" "aarch64-unknown-fuchsia"
|
||||
|
@ -44,8 +36,7 @@
|
|||
// CHECK: "-stack-protector" "2"
|
||||
// CHECK-AARCH64: "-target-feature" "+outline-atomics"
|
||||
// CHECK-NOT: "-fcommon"
|
||||
// CHECK-LLD: {{.*}}ld.lld{{.*}}" "-z" "max-page-size=4096" "-z" "now" "-z" "rodynamic" "-z" "separate-loadable-segments" "-z" "rel" "--pack-dyn-relocs=relr"
|
||||
// CHECK-LD: {{.*}}ld.gold{{.*}}" "-z" "max-page-size=4096" "-z" "now" "-z" "combreloc" "-z" "text"
|
||||
// CHECK: {{.*}}ld.lld{{.*}}" "-z" "max-page-size=4096" "-z" "now" "-z" "rodynamic" "-z" "separate-loadable-segments" "-z" "rel" "--pack-dyn-relocs=relr"
|
||||
// CHECK: "--sysroot=[[SYSROOT]]"
|
||||
// CHECK: "-pie"
|
||||
// CHECK: "--build-id"
|
||||
|
|
|
@ -2,42 +2,32 @@
|
|||
// RUN: -ccc-install-dir %S/Inputs/basic_fuchsia_tree/bin \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=lld 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-X86_64 %s
|
||||
// RUN: %clangxx -### %s --target=x86_64-unknown-fuchsia \
|
||||
// RUN: -ccc-install-dir %S/Inputs/basic_fuchsia_tree/bin \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-X86_64 %s
|
||||
// RUN: %clangxx -### %s --target=x86_64-unknown-fuchsia \
|
||||
// RUN: -ccc-install-dir %S/Inputs/basic_fuchsia_tree/bin \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=gold 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LD,CHECK-X86_64 %s
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-X86_64 %s
|
||||
// RUN: %clangxx -### %s --target=aarch64-unknown-fuchsia \
|
||||
// RUN: -ccc-install-dir %S/Inputs/basic_fuchsia_tree/bin \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=lld 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-AARCH64 %s
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-AARCH64 %s
|
||||
// RUN: %clangxx -### %s --target=riscv64-unknown-fuchsia \
|
||||
// RUN: -ccc-install-dir %S/Inputs/basic_fuchsia_tree/bin \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=lld 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-RISCV64 %s
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-RISCV64 %s
|
||||
// RUN: %clangxx -### %s --target=x86_64-fuchsia \
|
||||
// RUN: -ccc-install-dir %S/Inputs/basic_fuchsia_tree/bin \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=lld 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-X86_64 %s
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-X86_64 %s
|
||||
// RUN: %clangxx -### %s --target=aarch64-fuchsia \
|
||||
// RUN: -ccc-install-dir %S/Inputs/basic_fuchsia_tree/bin \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=lld 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-AARCH64 %s
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-AARCH64 %s
|
||||
// RUN: %clangxx -### %s --target=riscv64-fuchsia \
|
||||
// RUN: -ccc-install-dir %S/Inputs/basic_fuchsia_tree/bin \
|
||||
// RUN: -resource-dir=%S/Inputs/resource_dir_with_per_target_subdir \
|
||||
// RUN: --sysroot=%S/platform -fuse-ld=lld 2>&1 \
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-LLD,CHECK-RISCV64 %s
|
||||
// RUN: | FileCheck -check-prefixes=CHECK,CHECK-RISCV64 %s
|
||||
// CHECK: "-cc1"
|
||||
// CHECK-X86_64: "-triple" "x86_64-unknown-fuchsia"
|
||||
// CHECK-AARCH64: "-triple" "aarch64-unknown-fuchsia"
|
||||
|
@ -50,8 +40,7 @@
|
|||
// CHECK-RISCV64: "-internal-isystem" "{{.*[/\\]}}include{{/|\\\\}}riscv64-unknown-fuchsia{{/|\\\\}}c++{{/|\\\\}}v1"
|
||||
// CHECK: "-internal-isystem" "{{.*[/\\]}}include{{/|\\\\}}c++{{/|\\\\}}v1"
|
||||
// CHECK: "-internal-externc-isystem" "[[SYSROOT]]{{/|\\\\}}include"
|
||||
// CHECK-LLD: {{.*}}ld.lld{{.*}}" "-z" "max-page-size=4096" "-z" "now" "-z" "rodynamic" "-z" "separate-loadable-segments" "-z" "rel" "--pack-dyn-relocs=relr"
|
||||
// CHECK-LD: {{.*}}ld.gold{{.*}}" "-z" "max-page-size=4096" "-z" "now" "-z" "combreloc" "-z" "text"
|
||||
// CHECK: {{.*}}ld.lld{{.*}}" "-z" "now" "-z" "rodynamic" "-z" "separate-loadable-segments"
|
||||
// CHECK: "--sysroot=[[SYSROOT]]"
|
||||
// CHECK: "-pie"
|
||||
// CHECK: "--build-id"
|
||||
|
|
Loading…
Reference in New Issue