|
15 | 15 | // See the License for the specific language governing permissions and |
16 | 16 | // limitations under the License. |
17 | 17 |
|
18 | | -// This Package.swift is a Work in Progress, primarily for CI at this point. |
19 | | -// Those interested in experimenting with Swift Package Manager should use the |
20 | | -// spm-master2020 branch for now. |
| 18 | +// This Package.swift is a Work in Progress. We intend to keep it functional |
| 19 | +// on the master branch, but it is rapidly evolving and may have occasional |
| 20 | +// breakages. Please report any issues at |
| 21 | +// https://github.com/firebase/firebase-ios-sdk/issues/new/choose. |
21 | 22 |
|
22 | 23 | import PackageDescription |
23 | 24 |
|
@@ -108,183 +109,6 @@ let package = Package( |
108 | 109 | // .package(url: "https://github.com/paulb777/nanopb.git", .revision("564392bd87bd093c308a3aaed3997466efb95f74")) |
109 | 110 | ], |
110 | 111 | targets: [ |
111 | | - .testTarget( |
112 | | - name: "swift-test", |
113 | | - dependencies: [ |
114 | | - "FirebaseAuth", |
115 | | - "FirebaseABTesting", |
116 | | - "FirebaseFunctions", |
117 | | - "Firebase", |
118 | | - "FirebaseCrashlytics", |
119 | | - "FirebaseCore", |
120 | | - "FirebaseDatabase", |
121 | | - "FirebaseFirestore", |
122 | | - "FirebaseFirestoreSwift", |
123 | | - "FirebaseInstallations", |
124 | | - // "FirebaseInstanceID", |
125 | | - "FirebaseRemoteConfig", |
126 | | - "FirebaseStorage", |
127 | | - "FirebaseStorageSwift", |
128 | | - "GoogleDataTransport", |
129 | | - "GoogleUtilities_AppDelegateSwizzler", |
130 | | - "GoogleUtilities_Environment", |
131 | | - // "GoogleUtilities_ISASwizzler", // Build needs to disable ARC. |
132 | | - "GoogleUtilities_Logger", |
133 | | - "GoogleUtilities_MethodSwizzler", |
134 | | - "GoogleUtilities_Network", |
135 | | - "GoogleUtilities_NSData", |
136 | | - "GoogleUtilities_Reachability", |
137 | | - "GoogleUtilities_UserDefaults", |
138 | | - .product(name: "nanopb", package: "nanopb"), |
139 | | - ], |
140 | | - path: "SwiftPMTests/swift-test" |
141 | | - ), |
142 | | - .testTarget( |
143 | | - name: "objc-import-test", |
144 | | - dependencies: [ |
145 | | - "FirebaseAuth", |
146 | | - "FirebaseABTesting", |
147 | | - "FirebaseFunctions", |
148 | | - "Firebase", |
149 | | - "FirebaseCrashlytics", |
150 | | - "FirebaseCore", |
151 | | - "FirebaseDatabase", |
152 | | - "FirebaseFirestore", |
153 | | - "FirebaseInstallations", |
154 | | - "FirebaseRemoteConfig", |
155 | | - "FirebaseStorage", |
156 | | - ], |
157 | | - path: "SwiftPMTests/objc-import-test" |
158 | | - ), |
159 | | - .target( |
160 | | - name: "GoogleUtilities_AppDelegateSwizzler", |
161 | | - dependencies: ["GoogleUtilities_Environment", "GoogleUtilities_Logger", |
162 | | - "GoogleUtilities_Network"], |
163 | | - path: "GoogleUtilities", |
164 | | - exclude: [ |
165 | | - "CHANGELOG.md", |
166 | | - "CMakeLists.txt", |
167 | | - "LICENSE", |
168 | | - "README.md", |
169 | | - "AppDelegateSwizzler/README.md", |
170 | | - "Environment/", |
171 | | - "Network/", |
172 | | - "ISASwizzler/", |
173 | | - "Logger/", |
174 | | - "MethodSwizzler/", |
175 | | - "NSData+zlib/", |
176 | | - "Reachability", |
177 | | - "SwizzlerTestHelpers/", |
178 | | - "Tests", |
179 | | - "UserDefaults/", |
180 | | - ], |
181 | | - sources: [ |
182 | | - "AppDelegateSwizzler/", |
183 | | - "SceneDelegateSwizzler/", |
184 | | - "Common/*.h", |
185 | | - ], |
186 | | - publicHeadersPath: "AppDelegateSwizzler/Public", |
187 | | - cSettings: [ |
188 | | - .headerSearchPath("../"), |
189 | | - ] |
190 | | - ), |
191 | | - .target( |
192 | | - name: "GoogleUtilities_Environment", |
193 | | - dependencies: [.product(name: "FBLPromises", package: "Promises")], |
194 | | - path: "GoogleUtilities/Environment", |
195 | | - exclude: ["third_party/LICENSE"], |
196 | | - publicHeadersPath: "Private", |
197 | | - cSettings: [ |
198 | | - .headerSearchPath("../../"), |
199 | | - ] |
200 | | - ), |
201 | | - |
202 | | - // Tests need OCMock and resource support. |
203 | | - |
204 | | - .target( |
205 | | - name: "GoogleUtilities_Logger", |
206 | | - dependencies: ["GoogleUtilities_Environment"], |
207 | | - path: "GoogleUtilities/Logger", |
208 | | - publicHeadersPath: "Public", |
209 | | - cSettings: [ |
210 | | - .headerSearchPath("../../"), |
211 | | - ] |
212 | | - ), |
213 | | - |
214 | | - // TODO: ISA_Swizzler requires building without ARC. |
215 | | - |
216 | | - .target( |
217 | | - name: "GoogleUtilities_MethodSwizzler", |
218 | | - dependencies: ["GoogleUtilities_Logger"], |
219 | | - path: "GoogleUtilities/MethodSwizzler", |
220 | | - publicHeadersPath: "Private", |
221 | | - cSettings: [ |
222 | | - .headerSearchPath("../../"), |
223 | | - ] |
224 | | - ), |
225 | | - .target( |
226 | | - name: "GoogleUtilities_Network", |
227 | | - dependencies: ["GoogleUtilities_Logger", "GoogleUtilities_NSData", |
228 | | - "GoogleUtilities_Reachability"], |
229 | | - path: "GoogleUtilities/Network", |
230 | | - publicHeadersPath: "Public", |
231 | | - cSettings: [ |
232 | | - .headerSearchPath("../.."), |
233 | | - ] |
234 | | - ), |
235 | | - .target( |
236 | | - name: "GoogleUtilities_NSData", |
237 | | - path: "GoogleUtilities/NSData+zlib", |
238 | | - publicHeadersPath: "Public", |
239 | | - cSettings: [ |
240 | | - .headerSearchPath("../.."), |
241 | | - ], |
242 | | - linkerSettings: [ |
243 | | - .linkedLibrary("z"), |
244 | | - ] |
245 | | - ), |
246 | | - .target( |
247 | | - name: "GoogleUtilities_Reachability", |
248 | | - dependencies: ["GoogleUtilities_Logger"], |
249 | | - path: "GoogleUtilities/Reachability", |
250 | | - publicHeadersPath: "Private", |
251 | | - cSettings: [ |
252 | | - .headerSearchPath("../../"), |
253 | | - ] |
254 | | - ), |
255 | | - .target( |
256 | | - name: "GoogleUtilities_UserDefaults", |
257 | | - dependencies: ["GoogleUtilities_Logger"], |
258 | | - path: "GoogleUtilities/UserDefaults", |
259 | | - publicHeadersPath: "Private", |
260 | | - cSettings: [ |
261 | | - .headerSearchPath("../../"), |
262 | | - ] |
263 | | - ), |
264 | | - // TODO: - need to port Network/third_party/GTMHTTPServer.m to ARC. |
265 | | - // .testTarget( |
266 | | - // name: "UtilitiesUnit", |
267 | | - // dependencies: [ |
268 | | - // "OCMock", |
269 | | - // "GoogleUtilities_AppDelegateSwizzler", |
270 | | - // "GoogleUtilities_Environment", |
271 | | - // // "GoogleUtilities_ISASwizzler", // Build needs to disable ARC. |
272 | | - // "GoogleUtilities_Logger", |
273 | | - // "GoogleUtilities_MethodSwizzler", |
274 | | - // "GoogleUtilities_Network", |
275 | | - // "GoogleUtilities_NSData", |
276 | | - // "GoogleUtilities_Reachability", |
277 | | - // "GoogleUtilities_UserDefaults", |
278 | | - // ], |
279 | | - // path: "GoogleUtilities/Tests/Unit", |
280 | | - // exclude: [ |
281 | | - // "Network/third_party/LICENSE", |
282 | | - // "Network/third_party/GTMHTTPServer.m", // Requires disabling ARC |
283 | | - // ], |
284 | | - // cSettings: [ |
285 | | - // .headerSearchPath("../../.."), |
286 | | - // ] |
287 | | - // ), |
288 | 112 | .target( |
289 | 113 | name: "Firebase", |
290 | 114 | path: "CoreOnly/Sources", |
@@ -646,6 +470,181 @@ let package = Package( |
646 | 470 | .define("PB_ENABLE_MALLOC", to: "1"), |
647 | 471 | ] |
648 | 472 | ), |
| 473 | + .testTarget( |
| 474 | + name: "swift-test", |
| 475 | + dependencies: [ |
| 476 | + "FirebaseAuth", |
| 477 | + "FirebaseABTesting", |
| 478 | + "FirebaseFunctions", |
| 479 | + "Firebase", |
| 480 | + "FirebaseCrashlytics", |
| 481 | + "FirebaseCore", |
| 482 | + "FirebaseDatabase", |
| 483 | + "FirebaseFirestore", |
| 484 | + "FirebaseFirestoreSwift", |
| 485 | + "FirebaseInstallations", |
| 486 | + // "FirebaseInstanceID", |
| 487 | + "FirebaseRemoteConfig", |
| 488 | + "FirebaseStorage", |
| 489 | + "FirebaseStorageSwift", |
| 490 | + "GoogleDataTransport", |
| 491 | + "GoogleUtilities_AppDelegateSwizzler", |
| 492 | + "GoogleUtilities_Environment", |
| 493 | + // "GoogleUtilities_ISASwizzler", // Build needs to disable ARC. |
| 494 | + "GoogleUtilities_Logger", |
| 495 | + "GoogleUtilities_MethodSwizzler", |
| 496 | + "GoogleUtilities_Network", |
| 497 | + "GoogleUtilities_NSData", |
| 498 | + "GoogleUtilities_Reachability", |
| 499 | + "GoogleUtilities_UserDefaults", |
| 500 | + .product(name: "nanopb", package: "nanopb"), |
| 501 | + ], |
| 502 | + path: "SwiftPMTests/swift-test" |
| 503 | + ), |
| 504 | + .testTarget( |
| 505 | + name: "objc-import-test", |
| 506 | + dependencies: [ |
| 507 | + "FirebaseAuth", |
| 508 | + "FirebaseABTesting", |
| 509 | + "FirebaseFunctions", |
| 510 | + "Firebase", |
| 511 | + "FirebaseCrashlytics", |
| 512 | + "FirebaseCore", |
| 513 | + "FirebaseDatabase", |
| 514 | + "FirebaseFirestore", |
| 515 | + "FirebaseInstallations", |
| 516 | + "FirebaseRemoteConfig", |
| 517 | + "FirebaseStorage", |
| 518 | + ], |
| 519 | + path: "SwiftPMTests/objc-import-test" |
| 520 | + ), |
| 521 | + .target( |
| 522 | + name: "GoogleUtilities_AppDelegateSwizzler", |
| 523 | + dependencies: ["GoogleUtilities_Environment", "GoogleUtilities_Logger", |
| 524 | + "GoogleUtilities_Network"], |
| 525 | + path: "GoogleUtilities", |
| 526 | + exclude: [ |
| 527 | + "CHANGELOG.md", |
| 528 | + "CMakeLists.txt", |
| 529 | + "LICENSE", |
| 530 | + "README.md", |
| 531 | + "AppDelegateSwizzler/README.md", |
| 532 | + "Environment/", |
| 533 | + "Network/", |
| 534 | + "ISASwizzler/", |
| 535 | + "Logger/", |
| 536 | + "MethodSwizzler/", |
| 537 | + "NSData+zlib/", |
| 538 | + "Reachability", |
| 539 | + "SwizzlerTestHelpers/", |
| 540 | + "Tests", |
| 541 | + "UserDefaults/", |
| 542 | + ], |
| 543 | + sources: [ |
| 544 | + "AppDelegateSwizzler/", |
| 545 | + "SceneDelegateSwizzler/", |
| 546 | + "Common/*.h", |
| 547 | + ], |
| 548 | + publicHeadersPath: "AppDelegateSwizzler/Public", |
| 549 | + cSettings: [ |
| 550 | + .headerSearchPath("../"), |
| 551 | + ] |
| 552 | + ), |
| 553 | + .target( |
| 554 | + name: "GoogleUtilities_Environment", |
| 555 | + dependencies: [.product(name: "FBLPromises", package: "Promises")], |
| 556 | + path: "GoogleUtilities/Environment", |
| 557 | + exclude: ["third_party/LICENSE"], |
| 558 | + publicHeadersPath: "Private", |
| 559 | + cSettings: [ |
| 560 | + .headerSearchPath("../../"), |
| 561 | + ] |
| 562 | + ), |
| 563 | + |
| 564 | + .target( |
| 565 | + name: "GoogleUtilities_Logger", |
| 566 | + dependencies: ["GoogleUtilities_Environment"], |
| 567 | + path: "GoogleUtilities/Logger", |
| 568 | + publicHeadersPath: "Public", |
| 569 | + cSettings: [ |
| 570 | + .headerSearchPath("../../"), |
| 571 | + ] |
| 572 | + ), |
| 573 | + |
| 574 | + // TODO: ISA_Swizzler requires building without ARC. |
| 575 | + |
| 576 | + .target( |
| 577 | + name: "GoogleUtilities_MethodSwizzler", |
| 578 | + dependencies: ["GoogleUtilities_Logger"], |
| 579 | + path: "GoogleUtilities/MethodSwizzler", |
| 580 | + publicHeadersPath: "Private", |
| 581 | + cSettings: [ |
| 582 | + .headerSearchPath("../../"), |
| 583 | + ] |
| 584 | + ), |
| 585 | + .target( |
| 586 | + name: "GoogleUtilities_Network", |
| 587 | + dependencies: ["GoogleUtilities_Logger", "GoogleUtilities_NSData", |
| 588 | + "GoogleUtilities_Reachability"], |
| 589 | + path: "GoogleUtilities/Network", |
| 590 | + publicHeadersPath: "Public", |
| 591 | + cSettings: [ |
| 592 | + .headerSearchPath("../.."), |
| 593 | + ] |
| 594 | + ), |
| 595 | + .target( |
| 596 | + name: "GoogleUtilities_NSData", |
| 597 | + path: "GoogleUtilities/NSData+zlib", |
| 598 | + publicHeadersPath: "Public", |
| 599 | + cSettings: [ |
| 600 | + .headerSearchPath("../.."), |
| 601 | + ], |
| 602 | + linkerSettings: [ |
| 603 | + .linkedLibrary("z"), |
| 604 | + ] |
| 605 | + ), |
| 606 | + .target( |
| 607 | + name: "GoogleUtilities_Reachability", |
| 608 | + dependencies: ["GoogleUtilities_Logger"], |
| 609 | + path: "GoogleUtilities/Reachability", |
| 610 | + publicHeadersPath: "Private", |
| 611 | + cSettings: [ |
| 612 | + .headerSearchPath("../../"), |
| 613 | + ] |
| 614 | + ), |
| 615 | + .target( |
| 616 | + name: "GoogleUtilities_UserDefaults", |
| 617 | + dependencies: ["GoogleUtilities_Logger"], |
| 618 | + path: "GoogleUtilities/UserDefaults", |
| 619 | + publicHeadersPath: "Private", |
| 620 | + cSettings: [ |
| 621 | + .headerSearchPath("../../"), |
| 622 | + ] |
| 623 | + ), |
| 624 | + // TODO: - need to port Network/third_party/GTMHTTPServer.m to ARC. |
| 625 | + // .testTarget( |
| 626 | + // name: "UtilitiesUnit", |
| 627 | + // dependencies: [ |
| 628 | + // "OCMock", |
| 629 | + // "GoogleUtilities_AppDelegateSwizzler", |
| 630 | + // "GoogleUtilities_Environment", |
| 631 | + // // "GoogleUtilities_ISASwizzler", // Build needs to disable ARC. |
| 632 | + // "GoogleUtilities_Logger", |
| 633 | + // "GoogleUtilities_MethodSwizzler", |
| 634 | + // "GoogleUtilities_Network", |
| 635 | + // "GoogleUtilities_NSData", |
| 636 | + // "GoogleUtilities_Reachability", |
| 637 | + // "GoogleUtilities_UserDefaults", |
| 638 | + // ], |
| 639 | + // path: "GoogleUtilities/Tests/Unit", |
| 640 | + // exclude: [ |
| 641 | + // "Network/third_party/LICENSE", |
| 642 | + // "Network/third_party/GTMHTTPServer.m", // Requires disabling ARC |
| 643 | + // ], |
| 644 | + // cSettings: [ |
| 645 | + // .headerSearchPath("../../.."), |
| 646 | + // ] |
| 647 | + // ), |
649 | 648 | ], |
650 | 649 | cLanguageStandard: .c99, |
651 | 650 | cxxLanguageStandard: CXXLanguageStandard.gnucxx14 |
|
0 commit comments