Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

No such module 'FBSDKCoreKit' XCODE 7.4

I am trying to add the Facebook login feature using FBSDKCoreKit and FBSDKLogin. When I try to import these two framework to my AppDelegate file, it shows error which is

"No such module 'FBSDKCoreKit'".

I changed Allow Non-modular Includes In Framework Modules from NO to YES, but the error is still there.

I need help with coming up with a solution to resolve the error.

like image 642
sekaisan Avatar asked Aug 18 '15 17:08

sekaisan


5 Answers

if you are using pods then just delete all pod file and related folders and start from the first step

init pod.

then open that pod file and add following framework   

pod 'FBSDKCoreKit'
pod 'FBSDKShareKit'
pod 'FBSDKLoginKit'

then pod install

and import it to the swift file and enjoy :)

and if you are directly add folder to your project then make sure that 'copy if needed' is marked

like image 81
Priyanka Avatar answered Sep 20 '22 20:09

Priyanka


Please try opening the project using .xcworkspce not with .xcodeproj As workspace load all the depencies.

like image 36
Mandeep Singh Avatar answered Sep 21 '22 20:09

Mandeep Singh


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

Go to Build Settings and search for "framework search"

like image 13
user3288414 Avatar answered Nov 19 '22 02:11

user3288414


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

like image 8
AamirR Avatar answered Nov 19 '22 04:11

AamirR


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!

like image 2
Jiwoo Choi Avatar answered Nov 19 '22 02:11

Jiwoo Choi