• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Ensure that a nonexistent path is ignored with a syslibroot
2
3RUN: lld -flavor darwinnew -v -syslibroot /var/empty | FileCheck %s -check-prefix CHECK-NONEXISTENT-SYSLIBROOT
4
5CHECK-NONEXISTENT-SYSLIBROOT: Library search paths:
6CHECK-NONEXISTENT-SYSLIBROOT-NEXT: Framework search paths:
7
8RUN: mkdir -p %t/usr/lib
9RUN: lld -flavor darwinnew -v -syslibroot %t 2>&1 | FileCheck %s -check-prefix CHECK-SYSLIBROOT -DROOT=%t
10
11CHECK-SYSLIBROOT-NOT: directory not found{{.*}}usr/local/lib
12CHECK-SYSLIBROOT: Library search paths:
13CHECK-SYSLIBROOT-NEXT: [[ROOT]]/usr/lib
14
15RUN: mkdir -p %t/Library/libxml2-development
16RUN: lld -flavor darwinnew -v -syslibroot %t -L /Library/libxml2-development | FileCheck %s -check-prefix CHECK-ABSOLUTE-PATH-REROOTED -DROOT=%t
17
18CHECK-ABSOLUTE-PATH-REROOTED: Library search paths:
19CHECK-ABSOLUTE-PATH-REROOTED: [[ROOT]]/Library/libxml2-development
20CHECK-ABSOLUTE-PATH-REROOTED: [[ROOT]]/usr/lib
21
22RUN: lld -flavor darwinnew -v -syslibroot %t -L %t/Library/libxml2-development | FileCheck %s -check-prefix CHECK-PATH-WITHOUT-REROOT -DPATH=%t/Library/libxml2-development
23CHECK-PATH-WITHOUT-REROOT:      Library search paths:
24CHECK-PATH-WITHOUT-REROOT-NEXT: [[PATH]]
25
26RUN: mkdir -p %t.2/usr/lib
27RUN: lld -flavor darwinnew -v -syslibroot %t -syslibroot %t.2 | FileCheck %s -check-prefix CHECK-SYSLIBROOT-MATRIX -DROOT=%t
28
29CHECK-SYSLIBROOT-MATRIX: Library search paths:
30CHECK-SYSLIBROOT-MATRIX: [[ROOT]]/usr/lib
31CHECK-SYSLIBROOT-MATRIX: [[ROOT]].2/usr/lib
32
33RUN: lld -flavor darwinnew -v -syslibroot %t -syslibroot %t.2 -syslibroot / | FileCheck %s -check-prefix CHECK-SYSLIBROOT-IGNORED -DROOT=%t
34
35CHECK-SYSLIBROOT-IGNORED: Library search paths:
36CHECK-SYSLIBROOT-IGNORED-NOT: [[ROOT]]/usr/lib
37CHECK-SYSLIBROOT-IGNORED-NOT: [[ROOT]].2/usr/lib
38
39RUN: mkdir -p %t/System/Library/Frameworks
40RUN: lld -flavor darwinnew -v -syslibroot %t | FileCheck %s -check-prefix CHECK-SYSLIBROOT-FRAMEWORK -DROOT=%t
41
42CHECK-SYSLIBROOT-FRAMEWORK: Framework search paths:
43CHECK-SYSLIBROOT-FRAMEWORK: [[ROOT]]/System/Library/Frameworks
44
45RUN: mkdir -p %t/Library/Frameworks
46RUN: mkdir -p %t.2/Library/Frameworks
47RUN: lld -flavor darwinnew -v -syslibroot %t -syslibroot %t.2 -F /Library/Frameworks | FileCheck %s -check-prefix CHECK-SYSLIBROOT-FRAMEWORK-MATRIX -DROOT=%t
48
49CHECK-SYSLIBROOT-FRAMEWORK-MATRIX: Framework search paths:
50CHECK-SYSLIBROOT-FRAMEWORK-MATRIX: [[ROOT]]/Library/Frameworks
51CHECK-SYSLIBROOT-FRAMEWORK-MATRIX: [[ROOT]].2/Library/Frameworks
52
53RUN: lld -flavor darwinnew -v -syslibroot %t -syslibroot %t.2 -syslibroot / -F /Library/Frameworks | FileCheck %s -check-prefix CHECK-SYSLIBROOT-FRAMEWORK-IGNORED -DROOT=%t
54
55CHECK-SYSLIBROOT-FRAMEWORK-IGNORED: Framework search paths:
56CHECK-SYSLIBROOT-FRAMEWORK-IGNORED-NOT: [[ROOT]]/Library/Frameworks
57CHECK-SYSLIBROOT-FRAMEWORK-IGNORED-NOT: [[ROOT]].2/Library/Frameworks
58