2

I have a new Swift project I started on and the first thing I did was create my podfile and bring in two cocoapods.

target 'Life Stream' do
pod 'SSKeychain'
pod 'LiveSDK'
end

target 'Life StreamTests' do
pod 'SSKeychain'
pod 'LiveSDK'
end

I then ran pod setup to ensure my cocoapods were installed, then ran pod install to install my pods. The new workspace project was created and I opened Xcode in it. Everything builds.

I then added my bridge header, and started using the SSKeychain pod. Things continued to build.

Bridge:

#ifndef Lifestream_Bridging_Header_h
#define Lifestream_Bridging_Header_h

#import "AFNetworking/AFNetworking.h"
#import "SSKeyChain.h"
#import "LiveConnectClient.h"
#endif /* Lifestream_Bridging_Header_h */


class UserService {
    init() {
        SSKeychain.setPassword("test", forService: "service", account: "blah")
    }
}

I then try to use the LiveSDK

class HttpOperation : NSOperation, LiveAuthDelegate {
    let baseUl = NSURL(string: "https://api.onedrive.com/v1.0")

    override func main() {
        let client = LiveConnectClient(clientId: "000000004C1549C8", delegate: self)
    }

    func authCompleted(status: LiveConnectSessionStatus, session: LiveConnectSession!, userState: AnyObject!) {
    
    }
}

The project built a couple of times, but now it no longer builds. I've not changed a line of code (CMD+tabbed to Safari for research). It doesn't matter if I clean the project, rebuild, or delete all of my pods and reinstall them, I can't get the project to build.

The compiler error I receive

Command failed due to signal: Segmentation fault: 11

I've seen people say this can be caused by the compiler not being able to find linked stuff. I then looked and noticed that my /frameworks folder contains all of the .a files in red (linked files?)

enter image description here

enter image description here

I assume that's because the files are missing, but why would that be? If I installed the pods via cocoapods and they were building fine, why now would those files go missing and the build stop (if that is the cause)?

I've been trouble shooting this for the last few hours and have not been able to figure it out. Any help would be appreciated.

My full compiler error log dump can be found on github

Edit

There are additional build errors associated with the unit test project, but I assume those are due to the project the unit tests depend on not building.

Use of undeclared type 'LiveAuthDelegate'

Use of undeclared type 'LiveConnectSessionStatus'

Use of undeclared type 'LiveConnectSession'

Use of unresolved identifier 'LiveConnectClient'

These errors point to the NSOperation subclass I show above. I'm not sure if that helps or not.

Community
  • 1
  • 1
Johnathon Sullinger
  • 7,097
  • 5
  • 37
  • 102
  • Hi @Brian. Just so you know, the OP here asked a [Meta question](http://meta.stackoverflow.com/q/297955/472495) about your edit. You're most welcome to add an answer on that post, or to comment, if you wish. – halfer Jun 27 '15 at 13:25
  • 1
    @halfer Thanks for the heads-up. I have replied in meta. Had to work extra hours today otherwise I would have been in meta earlier. Sorry Johnathon if the change was a problem for you. Would have been happy to discuss. – Brian Tompsett - 汤莱恩 Jun 27 '15 at 14:55
  • 1
    Hi Brian, I don't know how to send people private messages to discuss on SO or I would have pinged you for clarification. – Johnathon Sullinger Jun 27 '15 at 15:01
  • 2
    @Johnathon: it's a bit of a hidden feature, but as above you can just use the at symbol to talk to an editor directly. – halfer Jun 27 '15 at 15:28

0 Answers0