0
votes

I have a problem with CocoaPods, I get this error:

ld: framework not found Pods clang: error: linker command failed with exit code 1 (use -v to see invocation)

I'm trying to install Google Analytics, what I did ?:

  • I installed CococaPods
  • Edited PodFile
  • Installed the librairies

Podfile:

platform :ios, "9.0"

use_frameworks!

pod 'Google/Analytics'

target 'Solutis' do

end

target 'SolutisTests' do

end

Google Analytics code:

        var tracker = GAI.sharedInstance().defaultTracker
        tracker.set(kGAIScreenName, value: "test")

        var builder = GAIDictionaryBuilder.createScreenView().build() as! [NSObject : AnyObject]
        tracker.send(builder)
//        tracker.send(GAIDictionaryBuilder.createEventWithCategory("test", action: "test", label: "test", value: nil).build())

        let eventTracker: NSObject = GAIDictionaryBuilder.createEventWithCategory(
            "SomeCategory",
            action: "SomeAction",
            label: "SomeLabel",
            value: nil).build()
        tracker.send(eventTracker as! [NSObject : AnyObject])

Solutis-Bridging-Header.h:

//
//  Solutis-Bridging-Header.h
//  Solutis
//
//  Created by informatique Responis on 07/01/2016.
//  Copyright © 2016 Solutis. All rights reserved.
//

#ifndef Solutis_Bridging_Header_h
#define Solutis_Bridging_Header_h

#import <Google/Analytics.h>


#endif /* Solutis_Bridging_Header_h */

Added this file in Build Setting

I did :

pod install command

But I get the error, I think I did a mistake on the folder installation of pod, I'm in the root of my project: I think I have to go in the folder where they're the swift files no ? I don't wan't to do anymore wrong things... If I did this mistake how to delete back the pod installations and librairies in the root ?

Manage Schemes:

enter image description here

1

1 Answers

0
votes

Go in manage schemes there tick mark on pods-your project name, select that scheme, build the project once, that should solve it.