I'm trying to integrate my project from Google Analytics to Firebase Analytics. I was using Google Analytics SDK installed with Cococapods. After I do below steps;
Remove 'GoogleAnalytics' from Pod file
Run 'pod install'
Remove bridging header file from the project
Remove bridging header from build settings
I got build error with like average 300 error. Like
Value of type 'CATransition' has no member 'fadeTransition'
I can successfully build when not uninstall Google Analytics SDK so there is no problem with my code. What can cause this problem?
EDIT: I found that deleting bridging header causes the problem, not the Google Analytics SDK.
I found that most of my classes doesn't have import UIKit and somehow, when project has objective-c header, It doesn't need it. However, after I delete it, all of these classes need it. Therefore, implementing
import UIKit
fixed my problem.
Related
I am working on project which use Firebase.
I have added all Pod files in my project. I have also added Flags but it shows me error. I have also link all libraries of Firebase Podfile. I followed all instruction provided by Google Firebase Doc but it is not solving my error. Please help me into this.
I have Solved it successfully.
As per in my question Add framework related too firebase
Add this Linker flags too for firebase configuration
I have integrating Apple purchased videokit in a separate project and it was working fine, but when I am integrating in am old project which already have lot of stuff then it is throwing an error while compiling.
The error is: Image
import "VKPlayerViewController.h"
import "VKDecodeManager.h"
import "VKPlayerController.h"
While importing these headers in my bridging header file it is giving the following error:
Failed to import bridging header '/Users/iOS2/.../SVN/../my-Bridging-Header.h'
I have also integrated 3rd party sdk Linphone before integrating ios videokit in my project. The problem could be due to multiple header paths for both the sdks which i'm not able to find out.
Please help!
I'm building a Firebase app in swift, I installed the cocoa pod correctly then created an Objective-C file so it would make me a bridging header. When I try to import Firebase elsewhere in the app it says no such module found. I tried to build anyway because sometimes the error will go away but it failed.
Should I do something with my build settings? I've created bridging headers before and never had too (I thought Xcode did that automatically). I'm using version 7.2.1 (the latest) by the way.
Thanks for the help!
#ifndef FirebaseNetwork_Bridging_Header_h
#define FirebaseNetwork_Bridging_Header_h
#import <Firebase/Firebase.h>
#endif
The documentation from firebase says to use import Firebase when in swift. This however causes errors at compile time. After adding the bridging header and importing Firebase.h inside of it, you will be able to access the Firebase api in your swift files.
Make sure to insert the following line in your Podfile:
use_frameworks!
Then open the .xcworkspace file. Clean the build. Compile it.
I follow all the steps in This Tutorial and/or Facebook SDK Documentation to install Facebook Login on my App, but when I run the code I get an error. although Facebook mention I can just use import (Swift) to include the framework, I try to do it the old fashion as well with Objective-C Bridge Header.
Error:
'FBSDKLoginKit/FBSDKLoginKit.h' file not found
ScreenshotAs you can see the bridge.h is being read by the compiler, but due to internal file error it will throw error.
Bridge.h In Xcode 6 you don't require bridge header file, I could just do it with import
#import <FBSDKLoginKit/FBSDKLoginKit.h>
This problem is due to Xcode 7 Beta, I have tried to do it on Xcode 6 and it worked perfectly with just an import FBSDKLoginKit. Can anyone tell me a hack around this? or if there is a way to convert my Swift 2 code back to 1.4 and work on Xcode 6.
I had the same problem.
Managed to sort the directory by adding the Facebook SDK in "Framework Search Path".
Target -> Build Settings -> Framework Search Paths -> + /Users//Documents/FacebookSDK
it works!
=]
For those using cocoapods the solution for me was actually adding FBSDKCoreKit to podfile:
pod 'FBSDKCoreKit'
pod 'FBSDKLoginKit'
The facebook documentation is incomplete, they dont mention anything about including FBSDKCoreKit pod reference.
For [login,sharekit,corekit].h file not found error , My solution was:
changing framework searchpath of RCTFBSDK (inside library of the project)
~/Documents/FacebookSDK
to
$(HOME)/Documents/FacebookSDK
I have the same issue and recognized, that my old XCode 6 projects worked with the Facebook frameworks.
So i try the following workaround and that fixed the problem. however i don't know why:
Facebook iOS SDK 4.2
Create a fresh project in XCode 6
Link the Facebook Frameworks to your project as described in the docs
Close the project and reopen it in XCode 7
The "To Swift 2 Converter" should open within the project - Convert the project to Swift 2
Run the project - in my case everything works fine.
After that i copied my "old" Swift 2 Files into the new project. The app starts without any issues.
I observed the changes by the converter, but can't recognized any change depending the Facebook frameworks.
Had the same issue, instead of updating the search path
I solved it by removing the Frameworks from the project and then adding them checking the Copy items if needed box
My header files looks this
#import <FBSDKCoreKit/FBSDKCoreKit.h>
#import <FBSDKLoginKit/FBSDKLoginKit.h>
You can simply put ~/Documents/FacebookSDK in Framework Search Paths and it will work for any user
this is a known bug: https://developers.facebook.com/bugs/362995353893156/
Check out this solution: Facebook iOS8 SDK build module error for FBSDKCoreKit
I am coding an iOS 8 app in swift using the FBSDK to allow users to log in to my app. So far I have successfully implemented the login feature using the FBSDK v3.25 in swift using a Bridging-Header.h file and updating the info.plist accordingly to the instructions given on the FB developers website. Now I want to make an app (or update my current one) to FBSDK v4.01 but when I follow the same process of integrating it into my app I get the following errors:
-> FBSDKAppLinkResolver.h
/Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FacebookSDK/FBSDKCoreKit.framework/Headers/FBSDKAppLinkResolver.h:21:9: Include of non-modular header inside framework module 'FBSDKCoreKit.FBSDKAppLinkResolver'
/Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FacebookSDK/FBSDKCoreKit.framework/Headers/FBSDKAppLinkResolver.h:21:9: Include of non-modular header inside framework module 'FBSDKCoreKit.FBSDKAppLinkResolver'
-> Bridging-Header.h
/Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FBLoginUsingSDK4/Bridging-Header.h:12:9: Could not build module 'FBSDKCoreKit'
/Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FBLoginUsingSDK4/Bridging-Header.h:13:9: Could not build module 'FBSDKLoginKit'
/Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FBLoginUsingSDK4/Bridging-Header.h:12:9: Could not build module 'FBSDKCoreKit'
->FBSDKLoginButton.h
/Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FacebookSDK/FBSDKLoginKit.framework/Headers/FBSDKLoginButton.h:21:9: Could not build module 'FBSDKCoreKit'
Failed to import bridging header '/Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FBLoginUsingSDK4/Bridging-Header.h'
The most obvious thing to note is the last error which says the bridging header cannot be found but it is in the same place as it was for when I was using FBSDK 3.25?
Also, all of the documentation and tutorials on the FaceBook developers website are all in obj-c so finding a solution has been a very frustrating process. Can anyone help diagnose what i am doing wrong? Any help is appreciated!
update
for the time being I have managed to compile my app by following the instructions in the Facebook developers portal and removing all modules from the FBSDK by running the following in terminal
rm -r ~/Documents/FacebookSDK/FBSDKCoreKit.framework/Modules/
rm -r ~/Documents/FacebookSDK/FBSDKLoginKit.framework/Modules/
rm -r ~/Documents/FacebookSDK/FBSDKShareKit.framework/Modules/
this is my workaround until a proper fix is released.
This is a bug and Facebook is currently "assigning this to the appropriate team".
To get updates to this issue follow this link:
https://developers.facebook.com/bugs/362995353893156/
and hit subscribe.
Some people have found success using the answers on this link (none have worked for me):
Facebook iOS8 SDK build module error for FBSDKCoreKit
For those of you trying to compile a swift project with FB cocoaPods.
*BTW, it worked once, only in xCode 7.1 it stopped
Only after playing with everything, I did 2 things:
Added the following code at the end of the pod:
post_install do |installer|
installer.pods_project.build_configuration_list.build_configurations.each do |configuration|
configuration.build_settings['CLANG_ALLOW_NON_MODULAR_INCLUDES_IN_FRAMEWORK_MODULES'] = 'YES'
end
end
Remove the 'new and improved' swift imports, and add FB into the obj-C bridging header:
A small screenshot of my bridging header
Try with build settings. Set Allow Non-modular Includes in Framework modules to YES.