Skip to content

Commit f4d9c99

Browse files
committed
Merge branch 'master' into firestore-master
2 parents a3adb63 + 89cc53e commit f4d9c99

File tree

10 files changed

+122
-11
lines changed

10 files changed

+122
-11
lines changed

Firebase/Core/FIRLogger.m

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
FIRLoggerService kFIRLoggerAdMob = @"[Firebase/AdMob]";
2828
FIRLoggerService kFIRLoggerAnalytics = @"[Firebase/Analytics]";
2929
FIRLoggerService kFIRLoggerAuth = @"[Firebase/Auth]";
30+
FIRLoggerService kFIRLoggerCrash = @"[Firebase/Crash]";
3031
FIRLoggerService kFIRLoggerMLKit = @"[Firebase/MLKit]";
3132
FIRLoggerService kFIRLoggerPerf = @"[Firebase/Performance]";
3233
FIRLoggerService kFIRLoggerRemoteConfig = @"[Firebase/RemoteConfig]";

Firebase/Core/Private/FIRLogger.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ extern FIRLoggerService kFIRLoggerABTesting;
2929
extern FIRLoggerService kFIRLoggerAdMob;
3030
extern FIRLoggerService kFIRLoggerAnalytics;
3131
extern FIRLoggerService kFIRLoggerAuth;
32+
extern FIRLoggerService kFIRLoggerCrash;
3233
extern FIRLoggerService kFIRLoggerCore;
3334
extern FIRLoggerService kFIRLoggerMLKit;
3435
extern FIRLoggerService kFIRLoggerPerf;

FirebaseAuth.podspec

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ supports email and password accounts, as well as several 3rd party authenticatio
6363
s.ios.framework = 'SafariServices'
6464
s.dependency 'FirebaseAuthInterop', '~> 1.0'
6565
s.dependency 'FirebaseCore', '~> 6.0'
66-
s.dependency 'GoogleUtilities/AppDelegateSwizzler', '~> 5.6'
67-
s.dependency 'GoogleUtilities/Environment', '~> 5.6'
66+
s.dependency 'GoogleUtilities/AppDelegateSwizzler', '~> 5.8'
67+
s.dependency 'GoogleUtilities/Environment', '~> 5.8'
6868
s.dependency 'GTMSessionFetcher/Core', '~> 1.1'
6969
end

FirebaseMessaging.podspec

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,9 @@ device, and it is completely free.
4141
s.dependency 'FirebaseAnalyticsInterop', '~> 1.1'
4242
s.dependency 'FirebaseCore', '~> 6.0'
4343
s.dependency 'FirebaseInstanceID', '~> 4.0'
44-
s.dependency 'GoogleUtilities/AppDelegateSwizzler', '~> 5.6'
45-
s.dependency 'GoogleUtilities/Reachability', '~> 5.6'
46-
s.dependency 'GoogleUtilities/Environment', '~> 5.6'
47-
s.dependency 'GoogleUtilities/UserDefaults', '~> 5.6'
44+
s.dependency 'GoogleUtilities/AppDelegateSwizzler', '~> 5.8'
45+
s.dependency 'GoogleUtilities/Reachability', '~> 5.8'
46+
s.dependency 'GoogleUtilities/Environment', '~> 5.8'
47+
s.dependency 'GoogleUtilities/UserDefaults', '~> 5.8'
4848
s.dependency 'Protobuf', '~> 3.1'
4949
end

GoogleUtilities.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Pod::Spec.new do |s|
22
s.name = 'GoogleUtilities'
3-
s.version = '5.6.0'
3+
s.version = '5.8.0'
44
s.summary = 'Google Utilities for iOS (plus community support for macOS and tvOS)'
55

66
s.description = <<-DESC

GoogleUtilities/CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11
# Unreleased
2+
3+
# 5.7.0
4+
- Restore to 5.5.0 tag after increased App Store warnings. (#2807)
5+
6+
# 5.6.0
27
- `GULAppDelegateSwizzler`: support of remote notification methods. (#2698)
38
- `GULAppDelegateSwizzler`: tvOS support. (#2698)
49

Releases/update-versions.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,7 @@ def UpdateTags(version_data, firebase_version, first=False):
163163
LogOrRun("git push --delete origin '{}'".format(firebase_version))
164164
LogOrRun("git tag --delete '{}'".format(firebase_version))
165165
LogOrRun("git tag '{}'".format(firebase_version))
166+
LogOrRun("git push origin '{}'".format(firebase_version))
166167
for pod, version in version_data.items():
167168
name = pod[len('Firebase'):]
168169
tag = '{}-{}'.format(name, version)
@@ -204,9 +205,9 @@ def PushPodspecs(version_data):
204205

205206
podspec = '{}.podspec'.format(pod)
206207
json = os.path.join(tmp_dir, '{}.json'.format(podspec))
207-
os.system('pod ipc spec {} > {}'.format(podspec, json))
208-
LogOrRun('pod repo push {} {}{}'.format(GetCpdcInternal(), json,
209-
warnings_ok))
208+
LogOrRun('pod ipc spec {} > {}'.format(podspec, json))
209+
LogOrRun('pod repo push --skip-tests {} {}{}'.format(GetCpdcInternal(),
210+
json, warnings_ok))
210211
os.system('rm -rf {}'.format(tmp_dir))
211212

212213

ZipBuilder/FirebaseSDKs.proto

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,13 @@ message SDK {
3232

3333
// Whether or not to strip the i386 architecture from the build.
3434
bool strip_i386 = 8;
35+
36+
// List of build targets. For internal use only.
37+
repeated string build_target = 9;
38+
39+
// Whether or not to strip both the i386 and armv7 architectures from the
40+
// build. All SDKs that use this flag are built internally so this should be ignored.
41+
bool strip_32bits = 10;
3542
}
3643

3744
// Any extra build flags needed to build the SDK. For internal use only.

ZipBuilder/README.md

Lines changed: 68 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,74 @@
11
# Firebase Zip File Builder
22

33
This project builds the Firebase iOS Zip file for distribution.
4-
More instructions to come.
4+
5+
## Overview
6+
7+
This is a small Swift Package Manager project that allows users to package a Firebase iOS Zip file. With no launch
8+
arguments, it will use the most recent public versions of all SDKs included in the zip file.
9+
10+
It was designed to fail fast with an explanation of what went wrong, so you can fix issues or dig in without having to dig
11+
too deep into the code.
12+
13+
## Requirements
14+
15+
In order to build the Zip file, you will need:
16+
17+
- Xcode 10.1
18+
- CocoaPods
19+
- An internet connection to fetch CocoaPods
20+
21+
## Running the Tool
22+
23+
You can run the tool with `swift run ZipBuilder [ARGS]` or generate an Xcode project with
24+
`swift package generate-xcodeproj` and run within Xcode.
25+
26+
In the near future, releases will be built via a builder server instead of on the release engineer's machine, making these
27+
instructions more of a reference to understand what's going on instead of how to build it yourself.
28+
29+
## Launch Arguments
30+
31+
See `main.swift` and the `LaunchArgs` struct for information on specific launch arguments.
32+
33+
You can pass in launch arguments with Xcode by clicking "ZipBuilder" beside the Run/Stop buttons, clicking "Edit
34+
Scheme" and adding them in the "Arguments Passed On Launch" section.
35+
36+
### Common Arguments
37+
38+
These arguments assume you're running the command from the `ZipBuilder` directory.
39+
40+
**Required** arguments:
41+
- `-templateDir $(pwd)/Template`
42+
- This should always be the same.
43+
- `-coreDiagnosticsDir <PATH_TO_FirebaseCoreDiagnostics.framework>`
44+
- Needed to overwrite the existing Core Diagnostics framework.
45+
46+
Optional comon arguments:
47+
- `-updatePodRepo false`
48+
- This is for speedups when `pod repo update` has already been run recently.
49+
50+
For release engineers (Googlers packaging an upcoming Firebase release) these commands should also be used:
51+
- `-customSpecRepos sso://cpdc-internal/firebase`
52+
- This pulls the latest podspecs from the CocoaPods staging area.
53+
- `-releasingSDKs <PATH_TO_current.textproto>` and
54+
- `-existingVersions <PATH_TO_all_firebase_ios_sdks.textproto>`
55+
- Validates the version numbers fetched from CocoaPods staging against the expected released versions from these
56+
textprotos.
57+
58+
Putting them all together, here's a common command to build a releaseable Zip file:
59+
60+
```
61+
swift run ZipBuilder -templateDir $(pwd)/Template -updatePodRepo false \
62+
-coreDiagnosticsDir /private/tmp/tmpUqBxKN/FirebaseCoreDiagnostics.framework \
63+
-releasingSDKs <PATH_TO_current.textproto> \
64+
-existingVersions <PATH_TO_all_firebase_ios_sdks.textproto> \
65+
-customSpecRepos sso://cpdc-internal/firebase
66+
```
67+
68+
## Debugging
69+
70+
You can generate an Xcode project for the tool by running `swift package generate-xcodeproj` in this directory.
71+
See the above instructions for adding Launch Arguments to the Xcode build.
572

673
## Priorities
774

ZipBuilder/Sources/ZipBuilder/FirebaseSDKs.pb.swift

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,19 @@ struct ZipBuilder_SDK {
106106
set {_uniqueStorage()._stripI386 = newValue}
107107
}
108108

109+
/// List of build targets. For internal use only.
110+
var buildTarget: [String] {
111+
get {return _storage._buildTarget}
112+
set {_uniqueStorage()._buildTarget = newValue}
113+
}
114+
115+
/// Whether or not to strip both the i386 and armv7 architectures from the
116+
/// build. For internal use only.
117+
var strip32Bits: Bool {
118+
get {return _storage._strip32Bits}
119+
set {_uniqueStorage()._strip32Bits = newValue}
120+
}
121+
109122
var unknownFields = SwiftProtobuf.UnknownStorage()
110123

111124
init() {}
@@ -171,6 +184,8 @@ extension ZipBuilder_SDK: SwiftProtobuf.Message, SwiftProtobuf._MessageImplement
171184
6: .standard(proto: "nightly_mpm_pattern"),
172185
7: .standard(proto: "open_source"),
173186
8: .standard(proto: "strip_i386"),
187+
9: .standard(proto: "build_target"),
188+
10: .standard(proto: "strip_32bits"),
174189
]
175190

176191
fileprivate class _StorageClass {
@@ -182,6 +197,8 @@ extension ZipBuilder_SDK: SwiftProtobuf.Message, SwiftProtobuf._MessageImplement
182197
var _nightlyMpmPattern: [String] = []
183198
var _openSource: Bool = false
184199
var _stripI386: Bool = false
200+
var _buildTarget: [String] = []
201+
var _strip32Bits: Bool = false
185202

186203
static let defaultInstance = _StorageClass()
187204

@@ -196,6 +213,8 @@ extension ZipBuilder_SDK: SwiftProtobuf.Message, SwiftProtobuf._MessageImplement
196213
_nightlyMpmPattern = source._nightlyMpmPattern
197214
_openSource = source._openSource
198215
_stripI386 = source._stripI386
216+
_buildTarget = source._buildTarget
217+
_strip32Bits = source._strip32Bits
199218
}
200219
}
201220

@@ -219,6 +238,8 @@ extension ZipBuilder_SDK: SwiftProtobuf.Message, SwiftProtobuf._MessageImplement
219238
case 6: try decoder.decodeRepeatedStringField(value: &_storage._nightlyMpmPattern)
220239
case 7: try decoder.decodeSingularBoolField(value: &_storage._openSource)
221240
case 8: try decoder.decodeSingularBoolField(value: &_storage._stripI386)
241+
case 9: try decoder.decodeRepeatedStringField(value: &_storage._buildTarget)
242+
case 10: try decoder.decodeSingularBoolField(value: &_storage._strip32Bits)
222243
default: break
223244
}
224245
}
@@ -251,6 +272,12 @@ extension ZipBuilder_SDK: SwiftProtobuf.Message, SwiftProtobuf._MessageImplement
251272
if _storage._stripI386 != false {
252273
try visitor.visitSingularBoolField(value: _storage._stripI386, fieldNumber: 8)
253274
}
275+
if !_storage._buildTarget.isEmpty {
276+
try visitor.visitRepeatedStringField(value: _storage._buildTarget, fieldNumber: 9)
277+
}
278+
if _storage._strip32Bits != false {
279+
try visitor.visitSingularBoolField(value: _storage._strip32Bits, fieldNumber: 10)
280+
}
254281
}
255282
try unknownFields.traverse(visitor: &visitor)
256283
}
@@ -268,6 +295,8 @@ extension ZipBuilder_SDK: SwiftProtobuf.Message, SwiftProtobuf._MessageImplement
268295
if _storage._nightlyMpmPattern != rhs_storage._nightlyMpmPattern {return false}
269296
if _storage._openSource != rhs_storage._openSource {return false}
270297
if _storage._stripI386 != rhs_storage._stripI386 {return false}
298+
if _storage._buildTarget != rhs_storage._buildTarget {return false}
299+
if _storage._strip32Bits != rhs_storage._strip32Bits {return false}
271300
return true
272301
}
273302
if !storagesAreEqual {return false}

0 commit comments

Comments
 (0)