Skip to content

Commit 4b3a9aa

Browse files
committed
Reorg
1 parent 72430e8 commit 4b3a9aa

File tree

2 files changed

+23
-22
lines changed

2 files changed

+23
-22
lines changed

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

+1-1
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

+22-21
Original file line numberDiff line numberDiff line change
@@ -1356,7 +1356,7 @@ func abseilDependency() -> Package.Dependency {
13561356
if ProcessInfo.processInfo.environment["FIREBASE_SOURCE_FIRESTORE"] != nil {
13571357
packageInfo = (
13581358
"https://github.com/firebase/abseil-cpp-SwiftPM.git",
1359-
"0.20240116.1" ..< "0.20240117.0"
1359+
"0.20240722.0" ..< "0.20240723.0"
13601360
)
13611361
} else {
13621362
packageInfo = (
@@ -1374,7 +1374,7 @@ func grpcDependency() -> Package.Dependency {
13741374
// If building Firestore from source, abseil will need to be built as source
13751375
// as the headers in the binary version of abseil are unusable.
13761376
if ProcessInfo.processInfo.environment["FIREBASE_SOURCE_FIRESTORE"] != nil {
1377-
packageInfo = ("https://github.com/grpc/grpc-ios.git", "1.65.0" ..< "1.66.0")
1377+
packageInfo = ("https://github.com/grpc/grpc-ios.git", "1.69.0" ..< "1.70.0")
13781378
} else {
13791379
packageInfo = ("https://github.com/google/grpc-binary.git", "1.65.1" ..< "1.66.0")
13801380
}
@@ -1401,24 +1401,21 @@ func firestoreWrapperTarget() -> Target {
14011401
)
14021402
}
14031403

1404-
func firebaseFirestoreCppTarget() -> Target {
1404+
func firebaseFirestoreObjCppTarget() -> Target {
14051405
if ProcessInfo.processInfo.environment["FIREBASE_SOURCE_FIRESTORE"] != nil {
14061406
return .target(
1407-
name: "FirebaseFirestoreCpp",
1407+
name: "FirebaseFirestoreObjCpp",
14081408
dependencies: [
14091409
"FirebaseAppCheckInterop",
14101410
"FirebaseCore",
1411-
"leveldb",
1412-
"FirebaseFirestoreInternalWrapper",
1413-
.product(name: "nanopb", package: "nanopb"),
1414-
.product(name: "gRPC-cpp", package: "grpc-ios"),
1411+
"FirebaseFirestoreCpp",
14151412
],
1416-
path: "Firestore/core/interfaceForSwift",
1417-
publicHeadersPath: "api", // Path to the public headers
1413+
path: "Firestore/Source",
1414+
publicHeadersPath: "Public", // Path to the public headers
14181415
cxxSettings: [
1419-
.headerSearchPath("../../../"),
1420-
.headerSearchPath("../../Protos/nanopb"),
1421-
.headerSearchPath("api"), // Ensure the header search path is correct
1416+
.headerSearchPath("../../"),
1417+
.headerSearchPath("Public/FirebaseFirestore/"),
1418+
.headerSearchPath("../Protos/nanopb"),
14221419
]
14231420
)
14241421
} else {
@@ -1451,7 +1448,7 @@ func firestoreTargets() -> [Target] {
14511448
if ProcessInfo.processInfo.environment["FIREBASE_SOURCE_FIRESTORE"] != nil {
14521449
return [
14531450
.target(
1454-
name: "FirebaseFirestoreInternalWrapper",
1451+
name: "FirebaseFirestoreCpp",
14551452
dependencies: [
14561453
"FirebaseAppCheckInterop",
14571454
"FirebaseCore",
@@ -1462,6 +1459,8 @@ func firestoreTargets() -> [Target] {
14621459
],
14631460
path: "Firestore",
14641461
exclude: [
1462+
// Exclude legacy objc layer
1463+
"Source/",
14651464
"CHANGELOG.md",
14661465
"CMakeLists.txt",
14671466
"Example/",
@@ -1494,15 +1493,13 @@ func firestoreTargets() -> [Target] {
14941493
"core/src/util/secure_random_openssl.cc",
14951494
],
14961495
sources: [
1497-
"Source/",
14981496
"Protos/nanopb/",
14991497
"core/include/",
15001498
"core/src",
15011499
],
1502-
publicHeadersPath: "Source/Public",
1500+
publicHeadersPath: "core/src/api",
15031501
cSettings: [
15041502
.headerSearchPath("../"),
1505-
.headerSearchPath("Source/Public/FirebaseFirestore"),
15061503
.headerSearchPath("Protos/nanopb"),
15071504
.define("PB_FIELD_32BIT", to: "1"),
15081505
.define("PB_NO_PACKED_STRUCTS", to: "1"),
@@ -1518,15 +1515,15 @@ func firestoreTargets() -> [Target] {
15181515
.linkedLibrary("c++"),
15191516
]
15201517
),
1521-
firebaseFirestoreCppTarget(),
1518+
firebaseFirestoreObjCppTarget(),
15221519
.target(
15231520
name: "FirebaseFirestore",
15241521
dependencies: [
15251522
"FirebaseCore",
15261523
"FirebaseCoreExtension",
1527-
"FirebaseFirestoreInternalWrapper",
1528-
"FirebaseSharedSwift",
15291524
"FirebaseFirestoreCpp",
1525+
"FirebaseFirestoreObjCpp",
1526+
"FirebaseSharedSwift",
15301527
],
15311528
path: "Firestore",
15321529
exclude: [
@@ -1548,6 +1545,10 @@ func firestoreTargets() -> [Target] {
15481545
"Swift/Source/",
15491546
],
15501547
resources: [.process("Source/Resources/PrivacyInfo.xcprivacy")],
1548+
cxxSettings: [
1549+
.headerSearchPath("../"),
1550+
.headerSearchPath("Protos/nanopb"),
1551+
],
15511552
swiftSettings: [
15521553
.interoperabilityMode(.Cxx), // C++ interoperability setting
15531554
]
@@ -1619,6 +1620,6 @@ func firestoreTargets() -> [Target] {
16191620
publicHeadersPath: "."
16201621
),
16211622
firestoreInternalTarget,
1622-
firebaseFirestoreCppTarget(),
1623+
firebaseFirestoreObjCppTarget(),
16231624
]
16241625
}

0 commit comments

Comments
 (0)