Skip to content

Commit 992dd55

Browse files
authored
[Firestore] Consolidate Firestore and FirestoreSwift (Post-Rollback) (#11954)
1 parent f73ca95 commit 992dd55

File tree

66 files changed

+927
-253
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+927
-253
lines changed

.github/workflows/firestore.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,9 @@ jobs:
4848
- 'FirebaseCore/Sources/Public'
4949
5050
# Podspec
51+
- 'FirebaseFirestoreInternal.podspec'
5152
- 'FirebaseFirestore.podspec'
53+
- 'FirebaseFirestoreSwift.podspec'
5254
5355
# CMake
5456
- '**CMakeLists.txt'
@@ -261,6 +263,7 @@ jobs:
261263
strategy:
262264
matrix:
263265
podspec: [
266+
'FirebaseFirestoreInternal.podspec',
264267
'FirebaseFirestore.podspec',
265268
'FirebaseFirestoreSwift.podspec',
266269
]
@@ -288,6 +291,7 @@ jobs:
288291
strategy:
289292
matrix:
290293
podspec: [
294+
'FirebaseFirestoreInternal.podspec',
291295
'FirebaseFirestore.podspec',
292296
'FirebaseFirestoreSwift.podspec',
293297
]

.github/workflows/zip.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -465,7 +465,7 @@ jobs:
465465
run: |
466466
scripts/check_firestore_symbols.sh \
467467
$(pwd) \
468-
"${HOME}"/ios_frameworks/Firebase/FirebaseFirestore/FirebaseFirestore.xcframework
468+
"${HOME}"/ios_frameworks/Firebase/FirebaseFirestore/FirebaseFirestoreInternal.xcframework
469469
470470
quickstart_framework_inappmessaging:
471471
# Don't run on private repo.

FirebaseFirestore.podspec

Lines changed: 7 additions & 98 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,12 @@ Pod::Spec.new do |s|
22
s.name = 'FirebaseFirestore'
33
s.version = '10.17.0'
44
s.summary = 'Google Cloud Firestore'
5-
65
s.description = <<-DESC
76
Google Cloud Firestore is a NoSQL document database built for automatic scaling, high performance, and ease of application development.
87
DESC
9-
108
s.homepage = 'https://developers.google.com/'
119
s.license = { :type => 'Apache-2.0', :file => 'Firestore/LICENSE' }
1210
s.authors = 'Google, Inc.'
13-
1411
s.source = {
1512
:git => 'https://github.com/firebase/firebase-ios-sdk.git',
1613
:tag => 'CocoaPods-' + s.version.to_s
@@ -25,105 +22,17 @@ Google Cloud Firestore is a NoSQL document database built for automatic scaling,
2522
s.cocoapods_version = '>= 1.4.0'
2623
s.prefix_header_file = false
2724

28-
# Header files that constitute the interface to this module. Only Objective-C
29-
# headers belong here, since FirebaseFirestore is primarily an Objective-C
30-
# framework.
31-
s.public_header_files = 'Firestore/Source/Public/FirebaseFirestore/*.h'
25+
s.public_header_files = 'FirebaseFirestoreInternal/**/*.h'
3226

33-
# source_files contains most of the header and source files for the project.
34-
# This includes files named in `public_header_files`.
35-
#
36-
# Each header in this list must be globally unique, even within customer
37-
# projects. This generally means that only Objective-C Headers with a `FIR`
38-
# or `FST` prefix can be in `source_files`. Non-public C++ headers that have
39-
# no filename prefix must be in `preserve_paths`. See
40-
# https://github.com/firebase/firebase-ios-sdk/issues/4035 for more details.
41-
#
42-
# Note: headers from FirebaseCore can be in this list because while they're
43-
# not globally unique, each copy will be the same. It doesn't matter which
44-
# version wins in the global header map. The benefit of keeping them here is
45-
# that "quick open" by filename in Xcode will continue to work.
27+
s.requires_arc = true
4628
s.source_files = [
47-
'FirebaseCore/Extension/*.h',
48-
'Firestore/Source/Public/FirebaseFirestore/*.h',
49-
'Firestore/Source/**/*.{m,mm}',
50-
'Firestore/Protos/nanopb/**/*.cc',
51-
'Firestore/core/include/**/*.{cc,mm}',
52-
'Firestore/core/src/**/*.{cc,mm}',
53-
'FirebaseAuth/Interop/*.h',
29+
'FirebaseFirestoreInternal/**/*.[mh]',
30+
'Firestore/Swift/Source/**/*.swift',
5431
]
5532

56-
# Internal headers that aren't necessarily globally unique. Most C++ internal
57-
# headers should be here to avoid polluting the global header map with
58-
# unprefixed filenames.
59-
#
60-
# These filenames won't be available in Xcode's "quick open" but the types
61-
# inside these files will be available.
62-
s.preserve_paths = [
63-
'Firestore/Source/API/*.h',
64-
'Firestore/Source/Core/*.h',
65-
'Firestore/Source/Local/*.h',
66-
'Firestore/Source/Remote/*.h',
67-
'Firestore/Source/Util/*.h',
68-
'Firestore/Protos/nanopb/**/*.h',
69-
'Firestore/core/include/**/*.h',
70-
'Firestore/core/src/**/*.h',
71-
'Firestore/third_party/nlohmann_json/json.hpp',
72-
]
73-
s.requires_arc = [
74-
'Firestore/Source/**/*',
75-
'Firestore/core/src/**/*.mm',
76-
]
77-
78-
# Exclude alternate implementations for other platforms. These types depend
79-
# upon link-time substitution, and there's no provision within CocoaPods for
80-
# selecting files dynamically.
81-
s.exclude_files = [
82-
'Firestore/core/src/api/input_validation_std.cc',
83-
'Firestore/core/src/remote/connectivity_monitor_noop.cc',
84-
'Firestore/core/src/util/filesystem_win.cc',
85-
'Firestore/core/src/util/hard_assert_stdio.cc',
86-
'Firestore/core/src/util/log_stdio.cc',
87-
'Firestore/core/src/util/secure_random_openssl.cc'
88-
]
89-
90-
s.dependency 'FirebaseAppCheckInterop', '~> 10.17'
9133
s.dependency 'FirebaseCore', '~> 10.0'
34+
s.dependency 'FirebaseCoreExtension', '~> 10.0'
35+
s.dependency 'FirebaseFirestoreInternal', '~> 10.17'
36+
s.dependency 'FirebaseSharedSwift', '~> 10.0'
9237

93-
abseil_version = '~> 1.20220623.0'
94-
s.dependency 'abseil/algorithm', abseil_version
95-
s.dependency 'abseil/base', abseil_version
96-
s.dependency 'abseil/container/flat_hash_map', abseil_version
97-
s.dependency 'abseil/memory', abseil_version
98-
s.dependency 'abseil/meta', abseil_version
99-
s.dependency 'abseil/strings/strings', abseil_version
100-
s.dependency 'abseil/time', abseil_version
101-
s.dependency 'abseil/types', abseil_version
102-
103-
s.dependency 'gRPC-C++', '~> 1.49.1'
104-
s.dependency 'leveldb-library', '~> 1.22'
105-
s.dependency 'nanopb', '>= 2.30908.0', '< 2.30910.0'
106-
107-
s.ios.frameworks = 'SystemConfiguration', 'UIKit'
108-
s.osx.frameworks = 'SystemConfiguration'
109-
s.tvos.frameworks = 'SystemConfiguration', 'UIKit'
110-
111-
s.library = 'c++'
112-
s.pod_target_xcconfig = {
113-
'CLANG_CXX_LANGUAGE_STANDARD' => 'c++14',
114-
'GCC_C_LANGUAGE_STANDARD' => 'c99',
115-
'GCC_PREPROCESSOR_DEFINITIONS' =>
116-
"FIRFirestore_VERSION=#{s.version} " +
117-
# The nanopb pod sets these defs, so we must too. (We *do* require 16bit
118-
# (or larger) fields, so we'd have to set at least PB_FIELD_16BIT
119-
# anyways.)
120-
'PB_FIELD_32BIT=1 PB_NO_PACKED_STRUCTS=1 PB_ENABLE_MALLOC=1',
121-
'HEADER_SEARCH_PATHS' =>
122-
'"${PODS_TARGET_SRCROOT}" ' +
123-
'"${PODS_TARGET_SRCROOT}/Firestore/Source/Public/FirebaseFirestore" ' +
124-
'"${PODS_ROOT}/nanopb" ' +
125-
'"${PODS_TARGET_SRCROOT}/Firestore/Protos/nanopb"'
126-
}
127-
128-
s.compiler_flags = '$(inherited) -Wreorder -Werror=reorder -Wno-comma'
12938
end

FirebaseFirestoreInternal.podspec

Lines changed: 130 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,130 @@
1+
Pod::Spec.new do |s|
2+
s.name = 'FirebaseFirestoreInternal'
3+
s.version = '10.17.0'
4+
s.summary = 'Google Cloud Firestore'
5+
6+
s.description = <<-DESC
7+
Google Cloud Firestore is a NoSQL document database built for automatic scaling, high performance, and ease of application development.
8+
DESC
9+
10+
s.homepage = 'https://developers.google.com/'
11+
s.license = { :type => 'Apache-2.0', :file => 'Firestore/LICENSE' }
12+
s.authors = 'Google, Inc.'
13+
14+
s.source = {
15+
:git => 'https://github.com/firebase/firebase-ios-sdk.git',
16+
:tag => 'CocoaPods-' + s.version.to_s
17+
}
18+
19+
s.ios.deployment_target = '11.0'
20+
s.osx.deployment_target = '10.13'
21+
s.tvos.deployment_target = '12.0'
22+
23+
s.swift_version = '5.3'
24+
25+
s.cocoapods_version = '>= 1.4.0'
26+
s.prefix_header_file = false
27+
28+
# Header files that constitute the interface to this module. Only Objective-C
29+
# headers belong here, since FirebaseFirestore is primarily an Objective-C
30+
# framework.
31+
s.public_header_files = 'Firestore/Source/Public/FirebaseFirestore/*.h'
32+
33+
# source_files contains most of the header and source files for the project.
34+
# This includes files named in `public_header_files`.
35+
#
36+
# Each header in this list must be globally unique, even within customer
37+
# projects. This generally means that only Objective-C Headers with a `FIR`
38+
# or `FST` prefix can be in `source_files`. Non-public C++ headers that have
39+
# no filename prefix must be in `preserve_paths`. See
40+
# https://github.com/firebase/firebase-ios-sdk/issues/4035 for more details.
41+
#
42+
# Note: headers from FirebaseCore can be in this list because while they're
43+
# not globally unique, each copy will be the same. It doesn't matter which
44+
# version wins in the global header map. The benefit of keeping them here is
45+
# that "quick open" by filename in Xcode will continue to work.
46+
s.source_files = [
47+
'FirebaseCore/Extension/*.h',
48+
'Firestore/Source/Public/FirebaseFirestore/*.h',
49+
'Firestore/Source/**/*.{m,mm}',
50+
'Firestore/Protos/nanopb/**/*.cc',
51+
'Firestore/core/include/**/*.{cc,mm}',
52+
'Firestore/core/src/**/*.{cc,mm}',
53+
'FirebaseAuth/Interop/*.h',
54+
]
55+
56+
# Internal headers that aren't necessarily globally unique. Most C++ internal
57+
# headers should be here to avoid polluting the global header map with
58+
# unprefixed filenames.
59+
#
60+
# These filenames won't be available in Xcode's "quick open" but the types
61+
# inside these files will be available.
62+
s.preserve_paths = [
63+
'Firestore/Source/API/*.h',
64+
'Firestore/Source/Core/*.h',
65+
'Firestore/Source/Local/*.h',
66+
'Firestore/Source/Remote/*.h',
67+
'Firestore/Source/Util/*.h',
68+
'Firestore/Protos/nanopb/**/*.h',
69+
'Firestore/core/include/**/*.h',
70+
'Firestore/core/src/**/*.h',
71+
'Firestore/third_party/nlohmann_json/json.hpp',
72+
]
73+
s.requires_arc = [
74+
'Firestore/Source/**/*',
75+
'Firestore/core/src/**/*.mm',
76+
]
77+
78+
# Exclude alternate implementations for other platforms. These types depend
79+
# upon link-time substitution, and there's no provision within CocoaPods for
80+
# selecting files dynamically.
81+
s.exclude_files = [
82+
'Firestore/core/src/api/input_validation_std.cc',
83+
'Firestore/core/src/remote/connectivity_monitor_noop.cc',
84+
'Firestore/core/src/util/filesystem_win.cc',
85+
'Firestore/core/src/util/hard_assert_stdio.cc',
86+
'Firestore/core/src/util/log_stdio.cc',
87+
'Firestore/core/src/util/secure_random_openssl.cc'
88+
]
89+
90+
s.dependency 'FirebaseAppCheckInterop', '~> 10.17'
91+
s.dependency 'FirebaseCore', '~> 10.0'
92+
93+
abseil_version = '~> 1.20220623.0'
94+
s.dependency 'abseil/algorithm', abseil_version
95+
s.dependency 'abseil/base', abseil_version
96+
s.dependency 'abseil/container/flat_hash_map', abseil_version
97+
s.dependency 'abseil/memory', abseil_version
98+
s.dependency 'abseil/meta', abseil_version
99+
s.dependency 'abseil/strings/strings', abseil_version
100+
s.dependency 'abseil/time', abseil_version
101+
s.dependency 'abseil/types', abseil_version
102+
103+
s.dependency 'gRPC-C++', '~> 1.49.1'
104+
s.dependency 'leveldb-library', '~> 1.22'
105+
s.dependency 'nanopb', '>= 2.30908.0', '< 2.30910.0'
106+
107+
s.ios.frameworks = 'SystemConfiguration', 'UIKit'
108+
s.osx.frameworks = 'SystemConfiguration'
109+
s.tvos.frameworks = 'SystemConfiguration', 'UIKit'
110+
111+
s.library = 'c++'
112+
s.pod_target_xcconfig = {
113+
'CLANG_CXX_LANGUAGE_STANDARD' => 'c++14',
114+
'CLANG_CXX_LIBRARY' => 'libc++',
115+
'GCC_C_LANGUAGE_STANDARD' => 'c99',
116+
'GCC_PREPROCESSOR_DEFINITIONS' =>
117+
"FIRFirestore_VERSION=#{s.version} " +
118+
# The nanopb pod sets these defs, so we must too. (We *do* require 16bit
119+
# (or larger) fields, so we'd have to set at least PB_FIELD_16BIT
120+
# anyways.)
121+
'PB_FIELD_32BIT=1 PB_NO_PACKED_STRUCTS=1 PB_ENABLE_MALLOC=1',
122+
'HEADER_SEARCH_PATHS' =>
123+
'"${PODS_TARGET_SRCROOT}" ' +
124+
'"${PODS_TARGET_SRCROOT}/Firestore/Source/Public" ' +
125+
'"${PODS_ROOT}/nanopb" ' +
126+
'"${PODS_TARGET_SRCROOT}/Firestore/Protos/nanopb"'
127+
}
128+
129+
s.compiler_flags = '$(inherited) -Wreorder -Werror=reorder -Wno-comma'
130+
end
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
// Copyright 2023 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
#import <FirebaseFirestoreInternal/FIRAggregateField.h>
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
// Copyright 2023 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
#import <FirebaseFirestoreInternal/FIRAggregateQuery.h>
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
// Copyright 2023 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
#import <FirebaseFirestoreInternal/FIRAggregateQuerySnapshot.h>
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
// Copyright 2023 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
#import <FirebaseFirestoreInternal/FIRAggregateSource.h>
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
// Copyright 2023 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
#import <FirebaseFirestoreInternal/FIRCollectionReference.h>
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
// Copyright 2023 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
#import <FirebaseFirestoreInternal/FIRDocumentChange.h>

0 commit comments

Comments
 (0)