FBSDKCoreKit/FBSDKCoreKit.h not found error

后端 未结 27 1712
伪装坚强ぢ
伪装坚强ぢ 2020-12-04 11:07

I am implementing FB Login so i Downloaded the SDK from https://developers.facebook.com/docs/ios. then i drag n down FBSDKCoreKit, FBSDKLoginKit a

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

    I ran into this issue last night, and wanted to post my solution just in case someone else has the same problem. My problem was my app was building and running fine in the sim and on my device, however the build would fail because of FBSDKCoreKit whenever I tried to run my unit tests. It took my about 30 minutes to find the problem, and I felt like a dummy when I did.

    Make sure that the FBSDKCoreKit bundle is targeted for your tests as well, and not just your regular application build.

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

    ->Builds Configuration.

         -> Framework Search paths.
    

    put the FacebookSDK directory in my case ~/Documents/FacebookSDK in :

    Debugging,

    Any architecture I Any Sdk,

    Release.

    especially this error because there no path in Any architecture I Any Sdk in my case

    ~ / Documents / FacebookSDK and it should be noted that the FacebookSDK folder must be in Domuments

    Example

    https://photos.app.goo.gl/5bD4d39a11AalYsx1

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

    FB developers say don't select copy files. Which creates problem. But I did opposite.

    1. I selected copy items if needed. It copied Frameworks in my project. Also automatically Search Path was added by xcode 7.2.

    2. Also double check if there is nothing in Framework Search Pathsunder Search Paths under Build Settings fields, then just add $(PROJECT_DIR) which is equal to /Users/user/Documents/....PROJECT..DIR...

    Compiled in 2 projects successfully.

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

    Using CocoaPods, the only thing that worked for me was:

    1. Update Header Search Paths ( NOT Framework Search Paths ) under Build Settings in Xcode:

      - "\"${PODS_ROOT}/Headers/Public/Facebook-iOS-SDK\"",

      - "\"${PODS_ROOT}/Headers/Public/Facebook-iOS-SDK/FacebookSDK\"",

      + "\"${PODS_ROOT}/Headers/Public/FBSDKCoreKit\"",

      + "\"${PODS_ROOT}/Headers/Public/FBSDKCoreKit/FBSDKCoreKit\"",

    2. Add the missing header(s?):

      cd Pods/Headers/Public/FBSDKCoreKit/FBSDKCoreKit/ && ln -s ../../../../FBSDKCoreKit/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKCoreKit+Internal.h FBSDKCoreKit+Internal.h

    Edit: point 2. needs apparently to be repeated after each following call to pod install.

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

    Personally I had trouble with spaces in various paths, including app name. Removing spaces (or adding "" everywhere to secure paths) solved the problem.

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

    I had the same problem. I fixed it by using quotes around my framework search path value i.e. "/Users/.....". Obviously, I have some spaces in my file paths.

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