-
Notifications
You must be signed in to change notification settings - Fork 263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OneSignalLiveActivities framework included for mac catalyst #1446
Conversation
628df93
to
c20ec2c
Compare
1b1678a
to
c20ec2c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! I recommend that we also test Swift PM before releasing though. It is a bit janky because we need to have the correct zips pulled.
You should be able to do the following though:
- Change the URL in the Package.swift file for each zip to point to the OneSignalXCFramework repo and pick an existing release. Then edit that release and attach the zips.
- Have your test app point at this branch when adding SwiftPM
- Revert those changes once we have finished testing
There's some weird behavior I am still investigating. Going to focus on building just Live Activities, I think related to its scheme. Making Live Activities use the normal build script from Build logs are also so verbose it is hard to parse, no obvious errors either. |
Is it just the zipping that is failing or are the XCFrameworks corrupted/out of date. You can try dragging in the XCFrameworks to a test app directly to see if they build/have the expected changes. |
I haven't run yet the 2nd script that generates the zips. Still looking at this. |
* To build the SDK as is for Mac Catalyst (without ripping out Live Activities or making more complicated changes), Mac Catalyst is added as a platform for the OneSignalLiveActivities framework
* Effectively empty any file referencing ActivityKit in order to support Mac Catalyst builds * See #1446 for details
8cab614
to
83f790c
Compare
* This change is needed to build the SDK for distribution or else fail to archive
This is not working for me. Are there new deployment steps specific to Catalyst that I'm missing? |
I see you followed up at #1445. I will continue the conversation there. |
Description
One Line Summary
Add mac catalyst to supported destinations in the
OneSignalLiveActivities
framework, make ActivityKit-depending files blank, with no change to the umbrella OneSignalFramework.Details
What's Changed
Solutions Investigated
The errors developers encountered was that the umbrella framework couldn't find
OneSignalLiveActivities
. So, initially, we considered just addingOneSignalLiveActivities
to theOneSignalFramework
for mac catalyst.However, this does not work when building the frameworks with our build script. Tried some other modifications to no avail.
Back to the drawing board... can we continue to exclude Mac Catalyst and make changes elsewhere? Mac catalyst really should not include OneSignalLiveActivities. The problem next is with our Podspec that names it as a dependency of OneSignalFramework.
I investigated how to modify our Podspec to only include Live Activities for ios and not mac catalyst. However, it is tricky. A key problem is that Mac Catalyst is an ios sdk and not a macOS sdk, and not easily differentiable so we cannot use
ios
vsosx
specifications for a Podspec.What I landed on finally was including Mac Catalyst for OneSignalLiveActivities and removing functionality related to ActivityKit. It did not appear any changes to OneSignalFramework was needed.
Motivation
Scope
Mac Catalyst support
Testing
Unit testing
None
Manual testing
Reproduction of Original Issue
How the changes in this PR were tested
Cocoapods
Swift Package Manager
Affected code checklist
Checklist
Overview
Testing
Final pass
This change is