-
Notifications
You must be signed in to change notification settings - Fork 222
/
Package.swift
144 lines (139 loc) · 6.02 KB
/
Package.swift
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
// swift-tools-version:5.3
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import PackageDescription
let projectHeaderSearchPaths = [
"**",
"../../AppCenter/AppCenter/Internals",
"../../AppCenter/AppCenter/Internals/Channel",
"../../AppCenter/AppCenter/Internals/Context/Device",
"../../AppCenter/AppCenter/Internals/Context/Session",
"../../AppCenter/AppCenter/Internals/Context/UserId",
"../../AppCenter/AppCenter/Internals/DelegateForwarder",
"../../AppCenter/AppCenter/Internals/HttpClient",
"../../AppCenter/AppCenter/Internals/HttpClient/Util",
"../../AppCenter/AppCenter/Internals/Ingestion",
"../../AppCenter/AppCenter/Internals/Ingestion/Util",
"../../AppCenter/AppCenter/Internals/Model",
"../../AppCenter/AppCenter/Internals/Model/CommonSchema",
"../../AppCenter/AppCenter/Internals/Model/Properties",
"../../AppCenter/AppCenter/Internals/Model/Util",
"../../AppCenter/AppCenter/Internals/Storage",
"../../AppCenter/AppCenter/Internals/Util",
"../../AppCenter/AppCenter/Internals/Vendor/Reachability",
"../../AppCenter/AppCenter/include",
"../../AppCenter/AppCenter/Model",
"../../AppCenterAnalytics/AppCenterAnalytics/include",
"../../AppCenterAnalytics/AppCenterAnalytics/Internals",
"../../AppCenterAnalytics/AppCenterAnalytics/Internals/Model",
"../../AppCenterAnalytics/AppCenterAnalytics/Internals/Session",
"../../AppCenterAnalytics/AppCenterAnalytics/Internals/Util",
"../../AppCenterAnalytics/AppCenterAnalytics/Model",
"../../AppCenterAnalytics/AppCenterAnalytics/TransmissionTarget",
"../../AppCenterCrashes/AppCenterCrashes/Internals",
"../../AppCenterCrashes/AppCenterCrashes/Internals/Model",
"../../AppCenterCrashes/AppCenterCrashes/Internals/Util",
"../../AppCenterCrashes/AppCenterCrashes/include",
"../../AppCenterCrashes/AppCenterCrashes/Model",
"../../AppCenterCrashes/AppCenterCrashes/WrapperSDKUtilities",
"../../AppCenterDistribute/AppCenterDistribute/Internals",
"../../AppCenterDistribute/AppCenterDistribute/Internals/Channel",
"../../AppCenterDistribute/AppCenterDistribute/Internals/Ingestion",
"../../AppCenterDistribute/AppCenterDistribute/Internals/Model",
"../../AppCenterDistribute/AppCenterDistribute/Internals/Version",
"../../AppCenterDistribute/AppCenterDistribute/Internals/Util",
"../../AppCenterDistribute/AppCenterDistribute/include",
"../../AppCenterDistribute/AppCenterDistribute/Model"
]
let cHeaderSearchPaths: [CSetting] = projectHeaderSearchPaths.map { .headerSearchPath($0) }
let package = Package(
name: "AppCenter",
defaultLocalization: "en",
platforms: [
.iOS(.v12),
.macOS(.v10_13),
.tvOS(.v12)
],
products: [
.library(
name: "AppCenterAnalytics",
targets: ["AppCenterAnalytics"]),
.library(
name: "AppCenterCrashes",
targets: ["AppCenterCrashes"]),
.library(
name: "AppCenterDistribute",
targets: ["AppCenterDistribute"]),
],
dependencies: [
.package(url: "https://github.com/microsoft/PLCrashReporter.git", .upToNextMinor(from: "1.11.2")),
],
targets: [
.target(
name: "AppCenter",
path: "AppCenter/AppCenter",
exclude: ["Support"],
resources: [.process("../PrivacyInfo.xcprivacy")],
cSettings: {
var settings: [CSetting] = [
.define("APP_CENTER_C_VERSION", to:"\"5.0.5\""),
.define("APP_CENTER_C_BUILD", to: "\"1\"")
]
settings.append(contentsOf: cHeaderSearchPaths)
return settings
}(),
linkerSettings: [
.linkedLibrary("z"),
.linkedLibrary("sqlite3"),
.linkedFramework("Foundation"),
.linkedFramework("SystemConfiguration"),
.linkedFramework("AppKit", .when(platforms: [.macOS])),
.linkedFramework("UIKit", .when(platforms: [.iOS, .tvOS])),
.linkedFramework("CoreTelephony", .when(platforms: [.iOS])),
]
),
.target(
name: "AppCenterAnalytics",
dependencies: ["AppCenter"],
path: "AppCenterAnalytics/AppCenterAnalytics",
exclude: ["Support"],
resources: [.process("../PrivacyInfo.xcprivacy")],
cSettings: cHeaderSearchPaths,
linkerSettings: [
.linkedFramework("Foundation"),
.linkedFramework("UIKit", .when(platforms: [.iOS, .tvOS])),
.linkedFramework("AppKit", .when(platforms: [.macOS])),
]
),
.target(
name: "AppCenterCrashes",
dependencies: [
"AppCenter",
.product(name: "CrashReporter", package: "PLCrashReporter"),
],
path: "AppCenterCrashes/AppCenterCrashes",
exclude: ["Support", "Internals/MSACCrashesBufferedLog.hpp"],
resources: [.process("../PrivacyInfo.xcprivacy")],
cSettings: cHeaderSearchPaths,
linkerSettings: [
.linkedFramework("Foundation"),
.linkedFramework("UIKit", .when(platforms: [.iOS, .tvOS])),
.linkedFramework("AppKit", .when(platforms: [.macOS])),
]
),
.target(
name: "AppCenterDistribute",
dependencies: ["AppCenter"],
path: "AppCenterDistribute/AppCenterDistribute",
exclude: ["Support"],
resources: [.process("../PrivacyInfo.xcprivacy")],
cSettings: cHeaderSearchPaths,
linkerSettings: [
.linkedFramework("Foundation"),
.linkedFramework("SafariServices", .when(platforms: [.iOS])),
.linkedFramework("AuthenticationServices", .when(platforms: [.iOS])),
.linkedFramework("UIKit", .when(platforms: [.iOS])),
]
)
]
)