236
|
1 // RUN: %clang --target=x86_64-unknown-ananas -static %s \
|
150
|
2 // RUN: --sysroot=%S/Inputs/ananas-tree -### 2>&1 \
|
|
3 // RUN: | FileCheck --check-prefix=CHECK-STATIC %s
|
|
4 // CHECK-STATIC: ld{{.*}}" "-Bstatic"
|
|
5 // CHECK-STATIC: crt0.o
|
|
6 // CHECK-STATIC: crti.o
|
|
7 // CHECK-STATIC: crtbegin.o
|
|
8 // CHECK-STATIC: crtend.o
|
|
9 // CHECK-STATIC: crtn.o
|
|
10
|
236
|
11 // RUN: %clang --target=x86_64-unknown-ananas -shared %s \
|
150
|
12 // RUN: --sysroot=%S/Inputs/ananas-tree -### 2>&1 \
|
|
13 // RUN: | FileCheck --check-prefix=CHECK-SHARED %s
|
|
14 // CHECK-SHARED: crti.o
|
|
15 // CHECK-SHARED: crtbeginS.o
|
|
16 // CHECK-SHARED: crtendS.o
|
|
17 // CHECK-SHARED: crtn.o
|
236
|
18
|
|
19 // -r suppresses -dynamic-linker, default -l and crt*.o like -nostdlib.
|
|
20 // RUN: %clang %s -### -o %t.o --target=x86_64-unknown-ananas -r 2>&1 \
|
|
21 // RUN: | FileCheck %s --check-prefix=CHECK-RELOCATABLE
|
|
22 // CHECK-RELOCATABLE: "-r"
|
|
23 // CHECK-RELOCATABLE-NOT: "-pie"
|
|
24 // CHECK-RELOCATABLE-NOT: "-dynamic-linker"
|
|
25 // CHECK-RELOCATABLE-NOT: "-l
|
|
26 // CHECK-RELOCATABLE-NOT: /crt{{[^.]+}}.o
|