No such module 'FBSDKCoreKit' XCODE 7.4

前端 未结 12 1950
北海茫月
北海茫月 2020-12-11 03:54

I am trying to add the Facebook login feature using FBSDKCoreKit and FBSDKLogin. When I try to import these two framework to my AppDelegate

相关标签:
12条回答
  • 2020-12-11 04:33

    I have solved this problem by typing import FBSDKLoginKit Dont copy!! just write. Hope it Helps

    0 讨论(0)
  • 2020-12-11 04:33

    In AppDelegate import:

    import FacebookCore
    import FacebookLogin
    

    and add:

    func application(_ application: UIApplication, didFinishLaunchingWithOptions 
    launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {        
    SDKApplicationDelegate.shared.application(application, 
    didFinishLaunchingWithOptions: launchOptions)
    
        return true
    }
    
    func application(_ app: UIApplication, open url: URL, options: 
    [UIApplicationOpenURLOptionsKey : Any] = [:]) -> Bool {
        return SDKApplicationDelegate.shared.application(app, open: url, 
                options: options)
    }
    
    0 讨论(0)
  • 2020-12-11 04:34

    I resolved No such module 'FrameworkName' issue with following steps:

    1) Create a group, call it Framework (optional, best practice)

    2) Drag desired SDK(s) from Original SDK path to Framework, in your case FBSDKCoreKit and FBSDKLoginKit

    3) When the dialog pops 'Choose options for adding these files:', choose following:

    options for adding these files

    Additional step for Facebook SDK version 4.0:

    4) Select the target in the project editor and click Build Settings, change Framework Search Paths to: ~/Documents/FacebookSDKDirectoryName

    0 讨论(0)
  • 2020-12-11 04:34

    I'd like to suggest one of the easiest way.

    1. put your mouse on your project ( in xcode)
    2. and right click > Add Files to...
    3. Add your framework files.
    4. you also need to change Allow Non-modular Includes In Framework Modules setting from NO to YES,

    Dada! Works like a charm!

    0 讨论(0)
  • 2020-12-11 04:39

    I resolved this problem by adding FacebookSDK Directory path to the "Framework Search Paths"

    Go to Build Settings and search for "framework search"

    0 讨论(0)
  • It's the usual suspects. Check your Frameworks folder. Check Project -> Build Phases -> Link Binary with Libraries, and make sure FBSDKCoreKit and FBSDKLoginKit are included.

    If they're there, and the error still exists, tap on each framework, and make sure Target Membership is checked under File inspector.

    0 讨论(0)
提交回复
热议问题