Search code examples
swiftcocoapodsxcode7urbanairship.com

UrbanAirship Cocoapods not working with use_frameworks


So I have a bit of an issue here. I'm using SwiftyJSON which does not appear to work without the use_frameworks option, and I also have need of the UrbanAirship framework as well.

If I disable use_frameworks, I'm able to Import AirshipKit without incident in my AppDelegate. However SwiftyJSON then cacks and I'm not able to use that. The reverse is true however if I enable it.

Has anyone had any luck or found a solution how to have both a dynamic and static library with Cocoapods?

What should my bridging header look like for UrbanAirship -- if I'm even able to use one with use_frameworks enabled?

Thanks so much!

Current Podfile:

platform :ios, '8.0'
use_frameworks!

target 'MyProject' do
    pod 'UrbanAirship-iOS-SDK'
    pod 'SwiftyJSON', :git => 'https://github.com/SwiftyJSON/SwiftyJSON.git'
end

Solution

  • The documentation for the URbainAirship-iOS-SDK pod is very lacking. In fact it doesn't make any reference to the fact that the module name diverges from the official documentation (even though its in the official repo).

    You have to import `UrbanAirship_iOS_SDK' and all should be well.