Commit Graph
138 Commits
Author SHA1 Message Date
Maksym Malyhin 13beb58fa1 Refactor GULSwizzledObject to ARC to unblock SwiftPM support (#5862)
* Refactor GULSwizzledObject to ARC to unblock SwiftPM transition.

* run ./scripts/style.sh

* Assert a single swizzler per swizzled object.

* testMultiSwizzling: fix iOS 10 tests

* Changelog

* Cleanup
2020-10-08 16:02:56 -04:00
Ryan Wilson 769fa7b446 Fixed CHANGELOG location. (#6698) 2020-10-08 13:02:08 -04:00
Ryan Wilson 19159a4b25 Fix tvOS storage issues. (#6658)
* Fix tvOS storage issues.

On tvOS devices, the ApplicationSupport directory cannot be used.
Unfortunately this doesn't come up in simulator testing, only on device.
This hasn't been fully tested on device but given that any writes to the
ApplicationSupport directory fail on tvOS, this change can't break much.

Fixes #6612

@defagos can you please give this a test?

* Fixed changed dir name for RC

* Fixed test naming, too.

* Fix the documentation comment for GoogleUtilities.

* Updated changelog.

* Review feedback
2020-10-08 11:28:41 -04:00
Paul Beusterien f2bcd5d82b Make all GoogleUtilities APIs public (#6588) 2020-09-29 07:26:10 -07:00
Maksym Malyhin a2546398c0 Revert "GULKeychainStorage: use dictionary instead of NSCache (#6224)" (#6227)
This reverts commit c59d75f740.
2020-08-07 12:08:49 -04:00
Maksym Malyhin c59d75f740 GULKeychainStorage: use dictionary instead of NSCache (#6224)
* GULKeychainStorage: use dictionary instead of NSCache

* Changelog
2020-08-07 10:42:53 -04:00
Paul Beusterien febada4e02 Reset debug mode on GGULResetLogger (#6195) 2020-08-03 14:51:15 -07:00
Paul Beusterien ec54ab71ed Add missing <TargetConditionals.h> before TARGET_OS_OSX test (#6186) 2020-08-03 09:08:33 -07:00
Maksym Malyhin 72ecea5bba GULAppDelegateSwizzlerTest: use OCMClassMock for application to avoid mock conflicts with KVO (#6145) 2020-07-28 13:36:16 -04:00
Paul Beusterien 25d856b6ad Cherry pick GoogleUtilities 6.7.1 fix to master (#6051) 2020-07-15 09:30:39 -07:00
Paul Beusterien 66f4afce0f Structural setup for SPM GoogleUtilities tests (#5999) 2020-07-08 08:30:03 -07:00
Nick Cooke f60162efc9 Access filesystem outside of GULHeartbeatDateStorage initializer (#5977)
* Lazily create fileURL

* Changelog

* Added setup check to verify init does not access file system

* Shortened constant name
2020-07-07 10:59:58 -04:00
Maksym Malyhin 5d29cfc2c2 Unreleased M74 changelog items updated with M75 (#5988) 2020-07-07 10:24:25 -04:00
Paul Beusterien 87a1b7de5e M74 changelogs (#5921) 2020-06-25 16:34:03 -07:00
Maksym Malyhin a0e250acab GoogleUtilities: cleanup iOS 6-7 compatibility conditions (#5841)
* GULAppDelegateSwizzler - remove pre iOS 8 compile conditions

* Remove outdated iOS 7 compile checks

* Fix Mac OS

* Fix incorrect macOS flag
2020-06-18 18:58:43 -04:00
Paul Beusterien 42e89d3e66 Initial check imports script (#5843) 2020-06-18 12:12:37 -07:00
Paul Beusterien 3f556ddb9e Update GoogleUtilities' clients with repo-relative imports (#5824) 2020-06-16 09:05:29 -07:00
Paul Beusterien 4c418e7fc3 GoogleUtilities repo-relative imports (#5810) 2020-06-16 06:19:00 -07:00
Maksym Malyhin 16bd413df9 M69 changelog for GUL and FIS (#5411)
* M69 changelog for GUL and FIS

* Punctuation
2020-04-20 09:44:47 -04:00
Maksym Malyhin f1e58ae013 GoogleUtilities: fix public headrer imports (#5369) 2020-04-14 15:28:17 -04:00
Gil 77f92cd2c6 Stop using built-in CMake Framework support (#5316)
* Fix previously unknown warnings

These become visible once flags are handled uniformly across all
Firestore targets in an upcoming build change.

* Stop using built-in CMake Framework support

CMake has built-in support for building Framework bundles (briefly:
bundles of libraries, associated headers, and resources) but this
doesn't work well for our needs.

1. In CMake 3.5.1 (our earliest supported CMake version) it doesn't copy
headers properly at build time.

2. Even up to CMake 3.15.5, CMake doesn't handle link-line multiplicity
correctly. CMake passes the static library location within the framework
and this seems to cause the linker to mishandle Objective-C metaclass
information resulting in duplicate symbols. Building with `-framework`
flags works correctly.

Previously we partially worked around the latter problem by building
some frameworks as shared instead of static frameworks, but this is
problematic because this mode of operation isn't actually intended and
is unsupported as far as the rest of Firebase is concerned. This turned
out to be fragile though and while refactoring libraries this workaround
broke.

Rather than piling on additional workarounds, this change converts the
frameworks to simple library targets and emulates framework imports
through include paths.

Additionally, this starts refactoring our cmake helper functions to make
them more like built-in functions. This makes it possible to freely use
different CMake features that were made difficult by trying to wrap
everything up in a single CMake command.

* style.sh generated changes

* Review feedback

* More review feedback
2020-04-14 08:40:33 -07:00
Maksym Malyhin 7bd8faaaa4 Move FIRSecureStorage to GoogleUtilities (#5329)
* FIRSecureStorage -> GULKeychainStorage: renamed and moved to GoogleUtilities

* FIS updated to GULKeychainStorage

* Run ./scripts/style.sh

* Headers order

* GULKeychainUtils API docs

* GULKeychainStorage: require Keychain service name
2020-04-09 17:06:41 -04:00
Paul Beusterien 956fb1b11b GoogleUtilities 6.5.2 (#5110) 2020-03-16 08:07:01 -07:00
Gil a568a96f7e Add iOS build support to the CMake build (#5052)
* Use early exit in objc_framework CMakeLists.txt

* Clean up objc_framework CMakeLists.txt

  * Use `version` consistently
  * Use `firebase_ios_version` for the repo-level version
  * Remove INCLUDE directories that are no longer needed
  * Sort dependencies

* Simplify Example/App/CMakeLists.txt

  * Add `OBJC_FLAGS` directly, avoiding a separate `sources` variable.
  * Add resources directly

* Rename test host app to firebase_firestore_example_app

* Add a firebase_ios prefix to functions and variables

This reduces the chance of collision with other projects.

* Simplify compiler_setup

Now that compiler_setup.cmake no longer has side-effects, fold
compiler_id.cmake and archive_options.cmake into it and move
the include of compiler_setup up to the top of the main build.

* Add support for building for iOS

* Make building benchmarks optional

* Disable protoc-based source generators when cross-compiling

* Make downloading googletest optional

* Add DISABLE_STRICT_WARNINGS mode to cc_rules

This makes it possible to build non-Firestore components in the CMake
build to a lower standard than that to which we hold ourselves without
sacrificing the utility of the various build rules that we have.
2020-03-13 08:22:11 -07:00
Gil e404054a9f Refactor and clean up the CMake build ahead of CMake/iOS support (#5051)
* Use early exit in objc_framework CMakeLists.txt

* Clean up objc_framework CMakeLists.txt

  * Use `version` consistently
  * Use `firebase_ios_version` for the repo-level version
  * Remove INCLUDE directories that are no longer needed
  * Sort dependencies

* Simplify Example/App/CMakeLists.txt

  * Add `OBJC_FLAGS` directly, avoiding a separate `sources` variable.
  * Add resources directly

* Rename test host app to firebase_firestore_example_app

* Add a firebase_ios prefix to functions and variables

This reduces the chance of collision with other projects.

* Simplify compiler_setup

Now that compiler_setup.cmake no longer has side-effects, fold
compiler_id.cmake and archive_options.cmake into it and move
the include of compiler_setup up to the top of the main build.
2020-03-10 20:50:13 -07:00
Morgan Chen 8fa6431ad5 Update environment checks (#5056)
* update environment checks

* replace deprecated macro

* update GoogleUtilities changelog
2020-03-10 15:39:03 -07:00
Chen Liang 1dad9c5c0e use secure coding and secure archiving for messaging (#4848) 2020-02-07 12:53:57 -08:00
Maksym Malyhin 32a114ccd4 GUL changelog 6.5.1 (#4759) 2020-01-28 13:32:17 -05:00
Paul Beusterien 0dd8dda165 GoogleUtilities - Standardize imports and add LICENSE (#4655) 2020-01-10 14:14:41 -08:00
Paul Beusterien 73c69236f7 Delete deprecated GoogleUtilities Podfile and project (#4653) 2020-01-10 09:00:21 -08:00
Chuan Ren 8843dbfd25 Add GULSceneDelegateSwizzler (#4524)
* Add GULSceneDelegateSwizzler

* Comments updated

* Fix build issue on xcode 10.*

* Remove empty methods

* Format

* Fix pr issues

* Format

* Fix build issue

* Fix build issue

* Fix build issue

* Reuse plist keys for scene delegate swizzler

* Add tests for the NSNotificationCenter related code

* Fix pr issues

* Make proxyOriginalSceneDelegate and isSceneDelegateProxyEnabled callable before ios 13

* Keep interceptors iOS 13+ only

* Revert "Make proxyOriginalSceneDelegate and isSceneDelegateProxyEnabled callable before ios 13"

This reverts commit 9927c06855.

* Fix a issue when the header is compiled but the implementation is not

This reverts commit a316673a69.

* Format

* Reuse [GULAppDelegateSwizzler isAppDelegateProxyEnabled]

* Fix build issue

* Revert to last green build

* Reuse [GULAppDelegateSwizzler isAppDelegateProxyEnabled] and fix other comments

* Make proxyOriginalSceneDelegate callable before ios 13

* Fix pr issues
2020-01-08 18:58:54 -05:00
Chen Liang e4456c011b Enables Firebase Messaging push notification function on watch only and independent watch app (#4016) 2019-12-23 16:45:19 -08:00
Maksym Malyhin 287ee0f051 GULAppDelegateSwizzler - comments updated (#4518)
* GULAppDelegateSwizzler - comments updated

* Changelog

* Revert changelog
2019-12-18 13:49:28 -05:00
Maksym Malyhin e78fb964b7 Scene delegate swizzling: don't crash when there is UIScene.delegate == nil (#4498) 2019-12-13 16:38:40 -05:00
Paul Beusterien 40045b8cd4 Consolidate SecureCoding to avoid a new subspec (#4462) 2019-12-09 13:42:46 -08:00
Paul Beusterien d1e06bce4b GoogleUtilities Changelog update (#4459) 2019-12-09 10:08:52 -08:00
Chuan Ren d6c117050e Handle UISceneDelegate changes in Auth (#4380)
* Handle UISceneDelegate changes in Auth

* Fix pr issue

* Update GULAppDelegateSwizzler.m

* Fix pr issue

* Update GULLoggerCodes.h

* Update GULLoggerCodes.h

* Update GULAppDelegateSwizzler_Private.h

* Update GULAppDelegateSwizzlerTest.m
2019-12-06 10:50:40 -08:00
Vinay Guthal be17ade458 add heartbeat feature for ios sdks (#4098)
* add heartbeat feature

* fix client logtype

* make class functions

* add subspec changes

* remove test file

* add heartbeat  tests

* use FileDataStorage instead of Storage

* add style

* use file data storage instead of storage

* fix test location

* add tests

* address comments

* update storage heartbeat with the new api

* update format

* update formatting and use correct enums

* rename

* update storage

* fix heartbeat

* update heartbeat tests

* fix styling

* Revert change

* heartbeat storage

* add comments

* update storage

* address comments

* add comments

* address comments

* fix style

* add style

* add style

* move heartbeat date storage

* move to environment

* update tests

* add tests

* small change

* add google utilities

* delete the header file

* update tests

* remove headers

* fix comment

* gul heartbeat date storage

* Update versions for heartbeat PR (#4311)

* update podfile

* Fix Firestore build under CMake

GoogleUtilities must now build SecureCoding
2019-11-14 15:22:20 -05:00
Vinay Guthal f529da0ef4 Add function to gul secure encoding to encode multiple calsses (#4282)
* style

* secure coding
2019-11-12 12:21:08 -05:00
Ryan Wilson 563854e81e Copy component container to GoogleUtilitiesComponents (#4113)
* Move component container to GoogleUtilities.

This will allow non-Firebase SDKs to take advantage of the component
system. Note: Firebase Core will eventually move over to use this, but
more investigation is needed about how this can be done with the least
amount of churn for other SDKs.

* Fix dependency on Logger.

* Add CHANGELOG entry.

* Fix selector name.

* Move ComponentContainer subspec to new pod.

* Rename to GoogleUtilitiesComponents.

* Style, make public headers.

* Update travis with new name.

* Add project to if_changed.sh

* Review comments.

* Enabled static framework, changed homepage.

* Fix missing quote.
2019-10-25 14:05:29 -04:00
Paul Beusterien eb413b3ba4 Delete unused commented asl tests (#3981) 2019-10-03 08:38:32 -07:00
Ryan Wilson 09f3f6c6a3 Fix unit testing crash with localization on (#3933) 2019-10-01 11:28:42 -07:00
Paul Beusterien 391271a807 Changelog and podspec for GoogleUtilities 6.3.1 (#3956) 2019-09-30 17:40:53 -07:00
Ryan Wilson c295991955 Fix Networking to receive data for POST requests (#3940)
* Fix Networking to receive data for POST requests

Currently,  GULNetworking doesn't receive the data when sending a POST request. 

Tracked internally at b/141712804

* Added unit tests.

* Update to handle the small data increments.
2019-09-27 16:45:27 -04:00
Paul Beusterien fb353c22d4 Merge 6.9.0 (#3907)
* Update versions for Release 6.9.0

* Fix unbalanced background task creation in GDTCCTUploader (#3838) (#3839)

* Add Manifest

* dependency version update

* Cherry picks for 6.9.0 (#3871)

* fixed "expiclitlySet" typo. (#3853)

* Mark unused variables (#3854)

* Mute FCM deprecated warnings with Xcode 11 and min iOS >= 10 (#3857)

* Add a third slash to make sure generated docs include these comments.b/13812238 (#3846)
2019-09-23 10:41:33 -07:00
Paul Beusterien 56f503b604 Fix GULMutableDictionary keyed subscript methods (#3882) 2019-09-19 14:54:01 -07:00
Paul Beusterien 6038d5a236 Mark unused variables (#3854) 2019-09-16 07:15:07 -07:00
Maksym Malyhin cd516bca5b GoogleUtilities: recover Xcode 8 compatibility. (#3713) 2019-08-28 11:11:51 -04:00
Maksym Malyhin 5cb58b881d GULSecureCoding introduced. (#3707)
* GULKeyedArchiver introduced.

* Bump GoogleUtilities version.

* Rename GULKeyedArchiver to GULSecureCodingTests. API cleanup.

* API notes.

* ./scripts/style.sh

* GoogleUtilities version 6.3.0
2019-08-27 17:59:27 -04:00
Paul Beusterien 96b828d9d9 Prep for GoogleUtilities 6.2.5 (#3548) 2019-08-12 06:59:15 -07:00