Trouble using AWSiOSSDKv2 via cocoapods 0.36 beta2

190 Views Asked by At

Using a Podfile like so:

platform :ios, '8.1'
source 'https://github.com/CocoaPods/Specs.git'
pod 'AWSiOSSDKv2'

I am getting a bunch of "file not found" errors in my xcode project related to the #imports being used in the AWSSDK. E.g. in AWSMobileAnalyticsContext.h:

#import "configuration/AWSMobileAnalyticsConfiguring.h"

I suspect this has to do with the fact that the project hasn't been updated with a dynamic framework output in mind (which is what the beta of cocoapods is using). I've gone through and actually tried hand-updating the paths to these imports, and I can clear most of the file not found errors, but then it starts complaining about the Mantle.h import elsewhere.

Anybody successfully gotten the AWSiOSSDKv2 to work with an app by using the cocoapods beta (or even a forked version that uses dynamic frameworks)?

1

There are 1 best solutions below

0
John Beck On

I was able to get it to work today.

I deleted all traces of cocoapods since it had originally been installed using 0.35.

  1. [project].xcworkspace
  2. All mentions in [project].xcodeproj related to pods (yes, by hand with vim)
  3. Pods/
  4. Podfile and Podfile.lock

I then installed my swift pods using carthage instead. For me, this was Alamofire and SwiftyJSON.

I made a commit here, so I could easily go back to this point.

My podfile was just this, I could not get it to work with the use_frameworks! line.

target 'WhatsLegal' do
  pod 'AWSiOSSDKv2'
  pod 'Facebook-iOS-SDK'
end

I ran pod init and then pod install, and it started working from here!