I get errors of not finding the React/reactLog.h file and more files from various react native libraries.
Have tried cocapods and it says it is installing, but it seems as if it's not installed in any libraries.
The error is:
'FBSDKSharekit/FBSDKSharekit.h' file not found
Well, in any case you have to follow the instructions again from this link and double check everything:
https://github.com/facebook/react-native-fbsdk
However, in my opinion this error occurs if you don't download and put the FacebookSDK in your document folder and drag and drop it into your project. So check if you have downloaded it and put it there please. After Putting it there, you should go in your Xcode project in the Library -> RCTFBSDK.xcodeproj path and drag and drop FBSDKSharekit file from your facebook SDK folder(In your document folder) into the framework folder. You have to do the same thing with FBSDKCore and FBSDKLogin.
In addition you should check these two points:
1- FBSDK[Core, Login, Share]Kit.framework show up in the Link Binary with Libraries section of your build target's Build Phases.
2- Make sure that ~/Documents/FacebookSDK is in the Framework Search Path of your build target's Build Settings.
Then try to clean and compile the project. I hope it helps you.
Related
I have installed the facebook SDK properly. (This is different from the other not found error because it is specifically for react-native-fbsdk and none of the solutions worked.)
I have tested that I have the SDK installed by importing both the FBSDKCoreKit header and FBSDKShareKit header into AppDelegate.m and it compiled and ran with no issue.
However when I installed react-native-fbsdk and linked it and compiled, I get the error of 'FBSDKCoreKit/FBSDKCoreKit.h' not found. similarly with FBSDKShareKit.
The troubleshooting on the github page gives 3 options to check when this occurs:
Make sure that the Facebook SDK frameworks are installed in ~/Documents/FacebookSDK.
Make sure that FBSDK[Core, Login, Share]Kit.framework show up in the Link Binary with Libraries section of your build target's Build Phases.
Make sure that ~/Documents/FacebookSDK is in the Framework Search Path of your build target's Build Settings.
Which I have checked and verified that I had all of these there was no solution found. The strange thing is that I can import them in AppDelegate.m and it works fine.
You need to make sure you have the SDK frameworks saved under the folder ~/Documents/FacebookSDK
Because react-native-fbsdk iOS project have the value "~/Documents/FacebookSDK" hardcoded in its own definition of Framework Search Paths
If you are like me and don't want to do what Facebook tells you (or you don't want to put random stuff on your Documents folder):
Replace every instance of ~/Documents/FacebookSDK in the QuickStart tutorial with the place you do want to store the SDK, in my case ~/Library/FacebookSDK. That means, unzip the downloaded SDK there and add that route to your project's Framework Search Paths. *
In Xcode's file tree, expand the Libraries group and click on RCTFBSDK.xcodeproj. On that project click Build Settings and add your route to its Framework Search Paths.
And that's it. Just remember you did this when you update the node module, 'cause this change won't be versioned on your project.
*Note: If there are other people working on the project, do not remove ~/Documents/FacebookSDK from your project's Framework Search Paths. This is to be consistent with the module installation and the rest of the team can easily npm install and use the installation guide as documentation.
Drag & drop in Xcode the FacebookSDK files, for example try with FBSDKCoreKit.h
I am trying to use the FB SDK with an iOS app, and have added the .framework files to my Frameworks group. I also have added /Users/$(USER)/Documents/FacebookSDK to my search path.
I am getting an error when building: FBSDKCoreKit/FBSDKCoreKit.h file not found
This is accurate, because /Users/$(USER)/Documents/FacebookSDK/FBSDKCoreKit/FBSDKCoreKit.h does not exist.
Instead, the file is at: /Users/$(USER)/Documents/FacebookSDK/FBSDKCoreKit.framework/Headers/FBSDKCoreKit.h
What am I supposed to do about this? (Or what am I doing wrong?)
I followed the instructions at https://developers.facebook.com/docs/ios/getting-started/
Remove all facebook framework then after Add this to the Library Search Paths in Build Settings and make sure you select recursive, delete other library paths which might be absolute paths then add facebook framework
$(PROJECT_DIR)
May be it will help you.
OR
You have duplicate symbol method which means there are duplicate file in project
In your Target's Build Phase, under "Compile Sources" check if there are duplicate file and delete one if you have duplication.
Hope this will help you.
sometimes the libraries does not get grabbed by Xcode, Try cleaning the project
Try with $(inherited) and non-recursive in library search paths for project target in Build settings.
I have faced a problem where my game works fine but when I am trying to make it work with AdMob, it gives me error in Xcode.
The error is
ld: framework not found GoogleMobileAds
clang: error: linker command failed with exit code 1 (use -v to see
invocation)
But my point is that I have imported the GoogleMobileAds framework and all the other frameworks what google developer site said, but it still doesn't work.
and this:
In Xcode select your Target, go to Build Settings, search for Search Paths.
It should give you 3 lists of directories - Header Search Paths, Framework Search Paths and Libary Search paths. In Framework Search Paths Make sure non of the directories have quotation marks "like this" and make sure the directory of your GoogleMobileAds.framework is listed. If not than add it.
If there is no GoogleMobileAds.framework file in your entire project than try to look with Finder (it may still be in the project repository but not linked to the project). If you can't find it than just copy it from Unity project Assets/Plugins/iOS/GoogleStuffDirectoryOrSomething/GoogleMobileAds.framework and paste it in Xcode project using Finder, then from Finder manually drag and drop it in Xcode so that project gets the reference to that file.
Build.
1.You have to drag and drop "GoogleMobileAds.jar" in your Xcode.
2.Then you have to add 2 frameworks(AdSupport,Storekit), and also have to add "GoogleMobileAds" plugin to Build Phase.
For more discriptive steps for integrate AdMob with iOS and Android both, follow the belove link.http://www.theappguruz.com/blog/ads-implementation-in-unity-using-admob
I am newbie of IOS developer. I am facing some problems that is I want to use external libraries on my xcode project. These are libraries that i need to use..
I would like to know that How to add the external libraries on xcode. I put these libraries to the "include" folder under root folder of project. I facing this error.
but library files are already exist in that folder. please help me. Thanks.
You have to add the external library in your Build Phases further you can get easy help from this link or reply in comment
adding an external library to a project in XCode 4.3
Or go the project Choose Build Phases -> click the + sign to add one and then
Or in the above image click the button Add Other where you can tell the further path for the external library or click the link below for more help
https://developer.apple.com/library/ios/recipes/xcode_help-project_editor/Articles/AddingaLibrarytoaTarget.html
I'm so new to xcode, I have a speechkit framework with following files as shown in image below
Now When I add this framework to my xcode project the header files are shown empty as below
and I end up with build error 'Lexical preprocessor issue SpeechKit/SpeechKit.h' file not found'. What is the issue with it? How to solve this?
I had the same issue.
Your Header symbolic link is corrupted (others too), you must replace it by a valid Symlink.
You can use ln -s command on each Symlink of your framework or use my script available here :
https://gist.github.com/spawnrider/6088294#file-fix_symlinks_fmk_ios-sh
Another newbie in Xcode here. I also spent a lot of time with this problem.
My scenario is the framework was emailed to me by colleague as a zip file.
I unzipped it on windows and copied it to my Mac. Wrong move. I should have unzipped it on the Mac itself. If you are wondering why your "header" is not a folder, then this is your answer.
The right answer is, that you have to make sure that the files are compiled right. In my case i had to download the SDK/Framework of my choice again.
Delete all files of speechkit in the Project and from the disk
Download it again from your Source
Add it to your project
Make sure you link the Framework (Build Phases->Link Binary with Libraries)
That should make it. I donĀ“t know why it was not compiled proper. But as i followed the steps above, the Framework was compiled right and the Project was built.
Your framework wasn't compiled successfully. You need to add the framework to the "Compile Sources" build phase.
Go to your target's settings and select the 4th tab (Build Phase). Open the "Compile Sources" phase and click on the '+' symbol and add your framework. The lexical/preprocessor issue "'SpeechKit/SpeechKit.h' file not found" should now be solved.
What i found that if you unzip any downloaded sample code and you get any lexical/preprocessor issue then just simply add that framework again by follow these steps Go to your target's settings and select the 4th tab (Build Phase). Open the "Compile Sources" phase and click on the '+' symbol and add your framework by clicking on (add other from sample code folder) option.