iOS Firebase UI Gives many errors - ios

I get many errors when trying to build the project with (pod 'FirebaseUI', '~> 4.0') dependency.
My pod file looks something like this:
platform :ios, '9.0'
use_frameworks!
pod 'Firebase/Core'
pod 'Firebase/Database'
pod 'Firebase/Auth'
pod 'Firebase/Storage'
pod 'FirebaseUI', '~> 4.0' (This causes a lot of errors)
pod 'FirebaseUI/Google'
pod 'FirebaseUI/Facebook'
pod 'FirebaseUI/Twitter'
Some of the errors are:
/Users/Home/GoogleDrive/iOS/TheBolt/Pods/Target Support Files/nanopb/nanopb-umbrella.h:1:9: Could not build module 'UIKit'
and
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.2.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:505:9: Unknown type name 'NSString'
and
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.2.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:514:50: Missing '#include '; declaration of 'Protocol' must be imported from module 'ObjectiveC.runtime' before it is required
I'm using Xcode 9 with swift 4. I tried to use swift 3.2 in build settings but the same errors still there.

There was no need for (pod 'FirebaseUI', '~> 4.0') along with the others. Adding it alone or just the necessary login pods solved the problem

Related

After installing Firebase with CocoaPod, I can no longer build

I'm trying to build Javascript source code as an iOS app using Cordova.
I have introduced firebase with CocoaPods, and I am very troubled because I can not build.
this is wannings
Ignoring file /Users/MYNAME/Library/Developer/Xcode/DerivedData/ProductName/Build/Products/Debug-iphonesimulator/CocoaLumberjack/CocoaLumberjack.framework/CocoaLumberjack, building for iOS Simulator-i386 but attempting to link with file built for iOS Simulator-x86_64
This is Error
Undefined symbols occur in large numbers
This is my Cocoapod profile.
platform :ios, '10.0'
use_frameworks!
target 'product_name' do
use_frameworks!
project 'product_name.xcodeproj'
use_frameworks!
pod 'Firebase/Analytics'
pod 'Firebase/Core'
pod 'Firebase/Firestore'
pod 'FirebaseFirestoreSwift', '~> 0.2'
# ID Instance
pod 'Firebase/Messaging'
# config
pod 'CocoaLumberjack/Swift'
# Pods for PodTest
pod 'Fabric', '~> 1.10.2'
pod 'Crashlytics', '~> 3.14.0'
# Bluetooth
pod 'RxBluetoothKit'
# debug
pod 'SimulatorStatusMagic', :configurations => ['Debug']
# design pattern
pod 'Swinject'
# zip
pod 'Zip'
# Protect UI
pod 'iOSDFULibrary'
pod 'libb2s'
end
target 'shareExtension' do
use_frameworks!
pod 'Firebase/Analytics'
pod 'Firebase/Core'
pod 'Firebase/Firestore'
pod 'FirebaseFirestoreSwift', '~> 0.2'
# ID Instance
pod 'Firebase/Messaging'
# config
pod 'CocoaLumberjack/Swift'
# Pods for PodTest
pod 'Fabric', '~> 1.10.2'
pod 'Crashlytics', '~> 3.14.0'
# Bluetooth
pod 'RxBluetoothKit'
# debug
pod 'SimulatorStatusMagic', :configurations => ['Debug']
# design pattern
pod 'Swinject'
# zip
pod 'Zip'
# Protect UI
pod 'iOSDFULibrary'
pod 'libb2s'
end
My Enviroment:
XCode Version 11.5
CocoaPods Version 1.9.3
What I have done so far.
STEP 1 : Solved CocoaPods Warnnings.
STEP 2 : Error Id: library Not Found XXXX
→ I installed the Not Found framework with CocoaPod(And decided to install a lot)
STEP3 : Modify Library Search Paths
STEP4 : Set Build Active Architecture Only explicitly to No
If anyone has experienced a similar error, I would like some advice on the current error.
Thanks.
I solved my problem.
I found an explanation in the condition of the build using the simulator.
Premise:
Why does the iOS simulator require i386 and x86_64 symbols even though I'm on an x86_64 system only?
Implementation example:
Could not find module for target 'x86_64-apple-ios-simulator'
In my project, I have to cleat Cordiva - Firebase relationship.
After,question,I did two Implementation.
STEP1: Find out why I can't build
Refer to the above article or build on the our iPhone.
STEP2: Organize compatibility
Make CORDOVA a parent element and make other targets child elements
THANKS!!

'FirebaseCore/FirebaseCore.h' file not found in swift5 on ios

I have a problem using FireBase. I had no problem with the build, but there was an error with the Firebase in iOS10.3 and I tried the suggested solution.
rm -rf ~/Library/Developer/Xcode/DerivedData/
And then I erased the cache and rebuilt it. However, the error has been changed.
'FirebaseCore/FirebaseCore.h' file not found Could not build // firebase.h
Objective-C module 'Firebase' // Appdelegate.swift
my podfile
# Uncomment the next line to define a global platform for your project
platform :ios, '12.0'
target 'testtest' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
# Pods for DeleteMe
pod 'SwiftSVG', '~> 2.0'
pod 'Toaster'
pod 'BigInt', '~> 4.0'
pod 'CryptoSwift'
pod 'RealmSwift'
pod 'web3.swift.pod', '~> 2.2.0'
pod 'Firebase'
pod 'Firebase/Messaging'
pod 'Firebase/Auth'
pod 'Firebase/Core'
end
I erased Pod and tried to rebuild it, but the error was the same.
$ pod deintegrate
$ pod clean
$ pod install
How can you solve this problem?
Xcode : Version 11.0
realDevice : iphone5 10.3
I just built my other test iPhone 6 version 12.4, but there was no error. There seems to be a problem in version 10.3.

Cocoapods use_frameworks with Objective C and Swift mixed project causes issues

I have just started working on Swift 4.0 with my current Objective C project. Everything went fine until I wished to use pods for ALCameraViewController which is built in swift and my previous pods are in Objective C, so I can't enable "use_frameworks!".
Even if I enable it my project builds successfully but app crashes right away at launch with error message saying
dyld: Library not loaded: #rpath/Amplitude_iOS.framework/Amplitude_iOS
Referenced from: /var/containers/Bundle/Application/44F47AE7-3928-450C-A8F4-5C708C996E43/RydeDev.app/RydeDev
Reason: image not found
This Amplitude_iOS is one of my Objective C pods.
I referred to so many posts on SO and GitHub but nothing is works out for me.
I thought of a way to use Swift libraries by manual installation and without pods but I think it'll not a good approach considering I might use some other libraries as well for Swift.
My pods
use_frameworks!
target '<My App>' do
pod 'FBSDKCoreKit'
pod 'FBSDKLoginKit'
pod 'FBSDKShareKit'
pod 'JSONModel', '~> 1.2'
pod 'RSKImageCropper'
pod 'Firebase/Core'
pod 'Firebase/Messaging'
pod 'Fabric'
pod 'Crashlytics'
pod 'Analytics', '~> 3.0'
pod 'LGSideMenuController', '~> 1.0.0'
pod 'CCBottomRefreshControl'
pod 'GoogleMaps'
pod 'Amplitude-iOS', '~> 3.11.1'
pod 'JDFTooltips'
pod 'Branch'
pod 'Stripe’
pod 'YYModel'
pod 'ALCameraViewController'
end
So please help me fix this issue.
Any help would be much appreciated.
Thanks

CleverTapSDK module not found

I am using various Swift and Objective-C libraries in my (Swift) project. My Podfile looks as follows:
platform :ios, '8.0'
use_frameworks!
pod 'Alamofire', '~> 3.0'
pod 'SwiftyJSON', :git => 'https://github.com/SwiftyJSON/SwiftyJSON.git'
pod 'FBSDKCoreKit'
pod 'FBSDKShareKit'
pod 'FBSDKLoginKit'
pod 'Fabric'
pod 'TwitterKit'
pod 'SimpleAuth/Instagram'
pod 'AFNetworking', '~> 3.0'
pod 'Parse'
To have support for using both (Swift and Objective-C) libraries, I use use_framework! directive in Podfile to install and use them. If we use directive use_framework! for Objective-C libraries, we are not required to create any kind of bridging-header.h and we can use it directly by import ModuleName. I am having no issues with any of the above mentioned pods/frameworks while installing or using them.
But there is this one framework which is written in Objective-C and I install it by adding its entry in Podfile as pod 'CleverTap-iOS-SDK'. The installations goes well but when I try to import CleverTapSDK or import CleverTap to use the library, it is giving me no such module error.
Just in case: My Xcode version is - 7.3 (7D175)

FBSDKs installed via Pods - No such module on Swift

I installed the following pods to my Swift project:
platform :ios, '8.0'
pod 'ParseUI', '~> 1.1.4'
pod 'Parse', '~> 1.7.5'
pod 'FBSDKCoreKit', '4.3.0'
pod 'FBSDKLoginKit', '4.3.0'
pod 'FBSDKShareKit', '4.3.0'
pod 'ParseFacebookUtilsV4', '~>1.7.5'
pod 'AFNetworking', '~> 2.5.4'
I added a Bridging Header for all the pods except the 3 FBSDKs. On https://developers.facebook.com/docs/ios/getting-started , it says...
"Swift
v4.1 of the SDK supports modules natively so no bridging headers are required. Simply import the appropriate kit module in your .swift files"
Problem is when I try to import those 3 frameworks to AppDelegate, I get the error message "No such module 'FBSDKCoreKit'"
Anyone encounter this issue before?
Thanks in advance.
Try adding use_frameworks! to the top of your podfile. It solved my problem. Initialy it is shown as #use_frameworks! in podfile . Remove the # infront of use_frameworks!. This blog explains about it.

Resources