1 /// Checks proper linker prefixing for PS4 and PS5.
2 // UNSUPPORTED: system-windows
5 // RUN: rm -f %t/orbis-ld
6 // RUN: touch %t/orbis-ld
7 // RUN: chmod +x %t/orbis-ld
8 // RUN: rm -f %t/prospero-lld
9 // RUN: touch %t/prospero-lld
10 // RUN: chmod +x %t/prospero-lld
12 // RUN: env "PATH=%t:%PATH%" %clang -### -target x86_64-scei-ps4 %s 2>&1 \
13 // RUN: | FileCheck --check-prefix=CHECK-PS4-LINKER %s
14 // RUN: env "PATH=%t:%PATH%" %clang -### -target x86_64-scei-ps4 %s -shared 2>&1 \
15 // RUN: | FileCheck --check-prefixes=CHECK-PS4-LINKER,SHARED %s
16 // RUN: env "PATH=%t:%PATH%" %clang -### -target x86_64-sie-ps5 %s 2>&1 \
17 // RUN: | FileCheck --check-prefix=CHECK-PS5-LINKER %s
18 // RUN: env "PATH=%t:%PATH%" %clang -### -target x86_64-sie-ps5 %s -shared 2>&1 \
19 // RUN: | FileCheck --check-prefixes=CHECK-PS5-LINKER,SHARED %s
21 // CHECK-PS4-LINKER: /orbis-ld
22 // CHECK-PS5-LINKER: /prospero-lld
25 // RUN: env "PATH=%t:%PATH%" %clang -### -target x86_64-scei-ps4 %s -fuse-ld=gold 2>&1 \
26 // RUN: | FileCheck --check-prefix=ERROR %s
27 // RUN: env "PATH=%t:%PATH%" %clang -### -target x86_64-sie-ps5 %s -fuse-ld=gold 2>&1 \
28 // RUN: | FileCheck --check-prefix=ERROR %s
30 // ERROR: error: unsupported option '-fuse-ld' for target 'x86_64-{{(scei|sie)}}-ps{{[45]}}'