[clang] [PS5][Driver] Link main components with -pie by default (PR #102901)
Fangrui Song via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 20 23:04:25 PDT 2024
================
@@ -1,3 +1,18 @@
+// Test that PIE is the default for main components
+
+// RUN: %clang --target=x86_64-scei-ps5 %s -### 2>&1 | FileCheck --check-prefixes=CHECK-PIE %s
+
+// CHECK-PIE: {{ld(\.exe)?}}"
+// CHECK-PIE-SAME: "-pie"
+
+// RUN: %clang --target=x86_64-scei-ps5 -no-pie %s -### 2>&1 | FileCheck --check-prefixes=CHECK-NO-PIE %s
+// RUN: %clang --target=x86_64-scei-ps5 -r %s -### 2>&1 | FileCheck --check-prefixes=CHECK-NO-PIE %s
+// RUN: %clang --target=x86_64-scei-ps5 -shared %s -### 2>&1 | FileCheck --check-prefixes=CHECK-NO-PIE %s
----------------
MaskRay wrote:
Suggest that the `-shared` RUN line additionally checks `-shared`.
(I'm starting a 3-week vacation this Friday and will have limited availability.)
https://github.com/llvm/llvm-project/pull/102901
More information about the cfe-commits
mailing list