1 // NO-PIE-NOT: "-pie" 2 // PIE: "-pie" 3 4 // RUN: %clang %s -### -o %t.o 2>&1 --target=arm-linux-androideabi \ 5 // RUN: | FileCheck --check-prefix=PIE %s 6 // RUN: %clang %s -### -o %t.o 2>&1 --target=arm-linux-android \ 7 // RUN: | FileCheck --check-prefix=PIE %s 8 // RUN: %clang %s -### -o %t.o 2>&1 --target=arm-linux-android24 \ 9 // RUN: | FileCheck --check-prefix=PIE %s 10 11 // RUN: %clang %s -### -o %t.o 2>&1 --target=mipsel-linux-android \ 12 // RUN: | FileCheck --check-prefix=PIE %s 13 // RUN: %clang %s -### -o %t.o 2>&1 --target=mipsel-linux-android24 \ 14 // RUN: | FileCheck --check-prefix=PIE %s 15 16 // RUN: %clang %s -### -o %t.o 2>&1 --target=i686-linux-android \ 17 // RUN: | FileCheck --check-prefix=PIE %s 18 // RUN: %clang %s -### -o %t.o 2>&1 --target=i686-linux-android24 \ 19 // RUN: | FileCheck --check-prefix=PIE %s 20 21 // RUN: %clang %s -### -o %t.o 2>&1 --target=aarch64-linux-android \ 22 // RUN: | FileCheck --check-prefix=PIE %s 23 // RUN: %clang %s -### -o %t.o 2>&1 --target=aarch64-linux-android24 \ 24 // RUN: | FileCheck --check-prefix=PIE %s 25 26 // RUN: %clang %s -### -o %t.o 2>&1 --target=arm64-linux-android \ 27 // RUN: | FileCheck --check-prefix=PIE %s 28 // RUN: %clang %s -### -o %t.o 2>&1 --target=arm64-linux-android24 \ 29 // RUN: | FileCheck --check-prefix=PIE %s 30 31 // RUN: %clang %s -### -o %t.o 2>&1 --target=mips64el-linux-android \ 32 // RUN: | FileCheck --check-prefix=PIE %s 33 // RUN: %clang %s -### -o %t.o 2>&1 --target=mips64el-linux-android24 \ 34 // RUN: | FileCheck --check-prefix=PIE %s 35 36 // RUN: %clang %s -### -o %t.o 2>&1 --target=x86_64-linux-android \ 37 // RUN: | FileCheck --check-prefix=PIE %s 38 // RUN: %clang %s -### -o %t.o 2>&1 --target=x86_64-linux-android24 \ 39 // RUN: | FileCheck --check-prefix=PIE %s 40 41 // Override toolchain default setting. 42 // RUN: %clang %s -### -o %t.o 2>&1 -pie --target=arm-linux-androideabi \ 43 // RUN: | FileCheck --check-prefix=PIE %s 44 // RUN: %clang %s -### -o %t.o 2>&1 -no-pie -pie --target=arm-linux-androideabi24 \ 45 // RUN: | FileCheck --check-prefix=PIE %s 46 47 // RUN: %clang %s -### -o %t.o 2>&1 -no-pie --target=arm-linux-androideabi24 \ 48 // RUN: | FileCheck --check-prefix=NO-PIE %s 49 // RUN: %clang %s -### -o %t.o 2>&1 -nopie --target=arm-linux-androideabi24 \ 50 // RUN: | FileCheck --check-prefix=NO-PIE %s 51 // RUN: %clang %s -### -o %t.o 2>&1 -pie -no-pie --target=arm-linux-androideabi24 \ 52 // RUN: | FileCheck --check-prefix=NO-PIE %s 53 54 // Static/shared/relocatable disable -pie 55 56 // RUN: %clang %s -### --target=aarch64-linux-android -static 2>&1 \ 57 // RUN: | FileCheck %s -check-prefix=CHECK-STATIC 58 // CHECK-STATIC-NOT: "-pie" 59 // CHECK-STATIC: -static 60 61 // RUN: %clang %s -### --target=aarch64-linux-android -shared 2>&1 \ 62 // RUN: | FileCheck %s -check-prefix=CHECK-SHARED 63 // CHECK-SHARED-NOT: "-pie" 64 // CHECK-SHARED: "-shared" 65 66 // RUN: %clang %s -### --target=aarch64-linux-android -r 2>&1 \ 67 // RUN: | FileCheck %s -check-prefix=CHECK-RELOCATABLE 68 // CHECK-RELOCATABLE-NOT: "-pie" 69 // CHECK-RELOCATABLE: "-r" 70