Pushwoosh/pushwoosh-ios-sdk

Adding support to Swift Package Manager

Closed this issue · 16 comments

With XCode 12 binary frameworks can be embedded in packages distributed with SPM (https://developer.apple.com/videos/play/wwdc2020/10147/) .
Could you please consider adding support for Swift Package Manager?

Hi @wfhm, is this something you guys are working on and if so, is there a time frame?

wfhm commented

@gameaccount,

We will definitely do it in future, however, right now we do not have any ETA on it, so it will most likely not be added in 2020. I will update this thread when there is any news on the ETA.

@wfhm, hmm okay, instead of that then would it be possible to just provide the framework binaries (https://github.com/Pushwoosh/pushwoosh-ios-sdk/tree/master/Framework) as .xcframework files? If not we have no way of adding them to our Swift packages.

wfhm commented

@gameaccount,

We are not going to release .xcframework files publicly until SPM is officially supported. As a temporary solution you can try the ones attached to this response.
XCPushwooshInboxUI.xcframework.zip
XCPushwoosh.xcframework.zip

dungi commented

I would also like to see spm support for out project

dungi commented

Is this xcframework always up to date?

wfhm commented

@dungi no, it was never updated since it was posted. Below are the new versions with the latest Pushwoosh iOS SDK:

PushwooshInboxUi.xcframework.zip
Pushwoosh.xcframework.zip

dungi commented

I guess the xcframework was build wrong. If I run it on real device it works. But for simulator the following error

symbol(s) not found for architecture arm64

wfhm commented

@dungi sorry, you are right. Please try these ones:

Pushwoosh.xcframework.zip
PushwooshInboxUI.xcframework.zip

Hello, is there any update on this issue? Pushwoosh is the last remaining dependency in my project I have to be fully on Swift Package Manager.
Thanks.

Any update on this?

wfhm commented

@rextremotabaresDtt

We are still working on supporting SPM, I will check with the team and provide an ETA once there is any. Meanwhile, as a temporary workaround, .xcframework files are available for all new releases already - you can find them the Pushwoosh.framework.zip in assets for every release:

https://github.com/Pushwoosh/pushwoosh-ios-sdk/releases/tag/6.2.5

dungi commented

Seems like the XCFramework I downloaded from this section is missing support for Mac Catalyst.

dungi commented

6.3.0 doesn't work with SPM:
/Package.swift has no Package.swift manifest for version 6.3.0 in https://github.com/Pushwoosh/pushwoosh-ios-sdk

wfhm commented

@dungi yes, we are aware of this issue - something went wrong during the release process. We are working on it now.

UPD: Fixed.

wfhm commented

@dungi @gameaccount @rextremotabaresDtt @murillotomas Swift Package Manager is now supported! You'll need to update SDK to the 6.3.0 version, and you can find the integration guide by the link below:

https://docs.pushwoosh.com/platform-docs/pushwoosh-sdk/ios-push-notifications/setting-up-pushwoosh-ios-sdk/swift-package-manager-setup

Please let us know if you experience any issues with the SPM integration, or if you have any additional questions!