Skip to content

Commit 8f9ce82

Browse files
committed
Reorg
1 parent fe4ec87 commit 8f9ce82

File tree

2 files changed

+23
-22
lines changed

2 files changed

+23
-22
lines changed

Firestore/Swift/Source/AsyncAwait/CollectionReference+AsyncAwait.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
*/
1616

1717
#if SWIFT_PACKAGE
18-
@_exported import FirebaseFirestoreInternalWrapper
18+
@_exported import FirebaseFirestoreCpp
1919
#else
2020
@_exported import FirebaseFirestoreInternal
2121
#endif // SWIFT_PACKAGE

Package.swift

Lines changed: 22 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1353,7 +1353,7 @@ func abseilDependency() -> Package.Dependency {
13531353
if ProcessInfo.processInfo.environment["FIREBASE_SOURCE_FIRESTORE"] != nil {
13541354
packageInfo = (
13551355
"https://github.com/firebase/abseil-cpp-SwiftPM.git",
1356-
"0.20240116.1" ..< "0.20240117.0"
1356+
"0.20240722.0" ..< "0.20240723.0"
13571357
)
13581358
} else {
13591359
packageInfo = (
@@ -1371,7 +1371,7 @@ func grpcDependency() -> Package.Dependency {
13711371
// If building Firestore from source, abseil will need to be built as source
13721372
// as the headers in the binary version of abseil are unusable.
13731373
if ProcessInfo.processInfo.environment["FIREBASE_SOURCE_FIRESTORE"] != nil {
1374-
packageInfo = ("https://github.com/grpc/grpc-ios.git", "1.65.0" ..< "1.66.0")
1374+
packageInfo = ("https://github.com/grpc/grpc-ios.git", "1.69.0" ..< "1.70.0")
13751375
} else {
13761376
packageInfo = ("https://github.com/google/grpc-binary.git", "1.65.1" ..< "1.66.0")
13771377
}
@@ -1398,24 +1398,21 @@ func firestoreWrapperTarget() -> Target {
13981398
)
13991399
}
14001400

1401-
func firebaseFirestoreCppTarget() -> Target {
1401+
func firebaseFirestoreObjCppTarget() -> Target {
14021402
if ProcessInfo.processInfo.environment["FIREBASE_SOURCE_FIRESTORE"] != nil {
14031403
return .target(
1404-
name: "FirebaseFirestoreCpp",
1404+
name: "FirebaseFirestoreObjCpp",
14051405
dependencies: [
14061406
"FirebaseAppCheckInterop",
14071407
"FirebaseCore",
1408-
"leveldb",
1409-
"FirebaseFirestoreInternalWrapper",
1410-
.product(name: "nanopb", package: "nanopb"),
1411-
.product(name: "gRPC-cpp", package: "grpc-ios"),
1408+
"FirebaseFirestoreCpp",
14121409
],
1413-
path: "Firestore/core/interfaceForSwift",
1414-
publicHeadersPath: "api", // Path to the public headers
1410+
path: "Firestore/Source",
1411+
publicHeadersPath: "Public", // Path to the public headers
14151412
cxxSettings: [
1416-
.headerSearchPath("../../../"),
1417-
.headerSearchPath("../../Protos/nanopb"),
1418-
.headerSearchPath("api"), // Ensure the header search path is correct
1413+
.headerSearchPath("../../"),
1414+
.headerSearchPath("Public/FirebaseFirestore/"),
1415+
.headerSearchPath("../Protos/nanopb"),
14191416
]
14201417
)
14211418
} else {
@@ -1448,7 +1445,7 @@ func firestoreTargets() -> [Target] {
14481445
if ProcessInfo.processInfo.environment["FIREBASE_SOURCE_FIRESTORE"] != nil {
14491446
return [
14501447
.target(
1451-
name: "FirebaseFirestoreInternalWrapper",
1448+
name: "FirebaseFirestoreCpp",
14521449
dependencies: [
14531450
"FirebaseAppCheckInterop",
14541451
"FirebaseCore",
@@ -1459,6 +1456,8 @@ func firestoreTargets() -> [Target] {
14591456
],
14601457
path: "Firestore",
14611458
exclude: [
1459+
// Exclude legacy objc layer
1460+
"Source/",
14621461
"CHANGELOG.md",
14631462
"CMakeLists.txt",
14641463
"Example/",
@@ -1491,15 +1490,13 @@ func firestoreTargets() -> [Target] {
14911490
"core/src/util/secure_random_openssl.cc",
14921491
],
14931492
sources: [
1494-
"Source/",
14951493
"Protos/nanopb/",
14961494
"core/include/",
14971495
"core/src",
14981496
],
1499-
publicHeadersPath: "Source/Public",
1497+
publicHeadersPath: "core/src/api",
15001498
cSettings: [
15011499
.headerSearchPath("../"),
1502-
.headerSearchPath("Source/Public/FirebaseFirestore"),
15031500
.headerSearchPath("Protos/nanopb"),
15041501
.define("PB_FIELD_32BIT", to: "1"),
15051502
.define("PB_NO_PACKED_STRUCTS", to: "1"),
@@ -1515,15 +1512,15 @@ func firestoreTargets() -> [Target] {
15151512
.linkedLibrary("c++"),
15161513
]
15171514
),
1518-
firebaseFirestoreCppTarget(),
1515+
firebaseFirestoreObjCppTarget(),
15191516
.target(
15201517
name: "FirebaseFirestore",
15211518
dependencies: [
15221519
"FirebaseCore",
15231520
"FirebaseCoreExtension",
1524-
"FirebaseFirestoreInternalWrapper",
1525-
"FirebaseSharedSwift",
15261521
"FirebaseFirestoreCpp",
1522+
"FirebaseFirestoreObjCpp",
1523+
"FirebaseSharedSwift",
15271524
],
15281525
path: "Firestore",
15291526
exclude: [
@@ -1545,6 +1542,10 @@ func firestoreTargets() -> [Target] {
15451542
"Swift/Source/",
15461543
],
15471544
resources: [.process("Source/Resources/PrivacyInfo.xcprivacy")],
1545+
cxxSettings: [
1546+
.headerSearchPath("../"),
1547+
.headerSearchPath("Protos/nanopb"),
1548+
],
15481549
swiftSettings: [
15491550
.interoperabilityMode(.Cxx), // C++ interoperability setting
15501551
]
@@ -1616,6 +1617,6 @@ func firestoreTargets() -> [Target] {
16161617
publicHeadersPath: "."
16171618
),
16181619
firestoreInternalTarget,
1619-
firebaseFirestoreCppTarget(),
1620+
firebaseFirestoreObjCppTarget(),
16201621
]
16211622
}

0 commit comments

Comments
 (0)