File tree Expand file tree Collapse file tree 1 file changed +69
-0
lines changed Expand file tree Collapse file tree 1 file changed +69
-0
lines changed Original file line number Diff line number Diff line change
1
+ ; RUN: rm -rf %t
2
+ ; RUN: split-file %s %t
3
+ ; RUN: sed -e "s|DSTROOT|%/t|g" %t/inputs.json.in > %t/inputs.json
4
+
5
+ ; RUN: clang-installapi \
6
+ ; RUN: -target arm64-apple-macos26 -install_name @rpath/libfoo.dylib \
7
+ ; RUN: -current_version 1 -compatibility_version 1 \
8
+ ; RUN: -Xproject -fvisibility=hidden -I%t/usr/include \
9
+ ; RUN: -I%t -dynamiclib %t/inputs.json \
10
+ ; RUN: -o %t/output.tbd 2>&1 | FileCheck %s --allow-empty
11
+ ; RUN: llvm-readtapi --compare %t/output.tbd %t/expected.tbd 2>&1 | FileCheck %s --allow-empty
12
+
13
+ ; CHECK-NOT: error
14
+ ; CHECK-NOT: warning
15
+
16
+ //--- usr/include/public.h
17
+ int foo(void);
18
+
19
+ //--- project.h
20
+ int bar(void);
21
+
22
+ //--- expected.tbd
23
+ {
24
+ "main_library": {
25
+ "exported_symbols": [
26
+ {
27
+ "text": {
28
+ "global": [
29
+ "_foo"
30
+ ]
31
+ }
32
+ }
33
+ ],
34
+ "flags": [
35
+ {
36
+ "attributes": [
37
+ "not_app_extension_safe"
38
+ ]
39
+ }
40
+ ],
41
+ "install_names": [
42
+ {
43
+ "name": "@rpath/libfoo.dylib"
44
+ }
45
+ ],
46
+ "target_info": [
47
+ {
48
+ "min_deployment": "26",
49
+ "target": "arm64-macos"
50
+ }
51
+ ]
52
+ },
53
+ "tapi_tbd_version": 5
54
+ }
55
+
56
+ ;--- inputs.json.in
57
+ {
58
+ "headers": [
59
+ {
60
+ "path" : "DSTROOT/usr/include/public.h",
61
+ "type" : "public"
62
+ },
63
+ {
64
+ "path" : "DSTROOT/project.h",
65
+ "type" : "project"
66
+ }
67
+ ],
68
+ "version": "3"
69
+ }
You can’t perform that action at this time.
0 commit comments