I've just downloaded Xcode 12 beta 6. I've installed firebase into the project and I get this error. When I correct it with the suggestion it then tells me to correct again with the original. This error is repeated for all 'GoogleDataTransport'. Can you use Firebase with Xcode 12 beta 6? What am I doing wrong? Thanks
Update to CocoaPods 1.10, run pod deintegrate and pod install.
To work around in earlier CocoaPods versions, disable the CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER option in the generate Pods project Build Settings:
More details in https://github.com/firebase/firebase-ios-sdk/issues/5987 and https://github.com/CocoaPods/CocoaPods/issues/9902.
I fixed it by using the pre-release of cocoapods
sudo gem install cocoapods --pre
and then doing an update
pod install --repo-update
My team didn't want to use cocoapods 1.10 before it's released, and didn't want to re-edit the Pods project's build settings every time a pod install regenerates it. This Podfile post_install step did the trick, credit to Léo-Paul JULIE:
post_install do |installer|
installer.pods_project.build_configurations.each do |config|
config.build_settings['CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER'] = 'NO'
end
end
Edit: As snakeoil points out below, you can also silence annoying warnings about irrelevant iOS versions which you are not supporting. But that setting should probably be edited for each target's configuration's build settings, so in a nested loop. All together, I'm going with something like this for now:
post_install do |installer|
installer.pods_project.build_configurations.each do |config|
# Can be removed when moving to cocoapods 1.10
config.build_settings['CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER'] = 'NO'
end
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
# Inherit the deployment target defined in this Podfile instead, e.g. platform :ios, '11.0' at the top of this file
config.build_settings.delete 'IPHONEOS_DEPLOYMENT_TARGET'
end
end
end
First, check for command line tools and install.
sudo xcode-select --switch /Applications/Xcode-beta.app
sudo xcode-select --install
Install cocoapods pre - beta version
sudo gem install cocoapods --pre
Switch to your xCode Project.
pod deintegrate
pod install --repo-update
In my case, Performance Monitoring Pod was causing this issue. When I was trying to install Performance Monitoring.
pod 'Firebase/Performance'
It somehow got conflict with Firebase Core Pod. To resolve it.
Comment Out all Firebase Pods in Podfile
Run Pod Install
Uncomment Firebase Performance Monitor in Podfile
Run Pod Install
Uncomment all other Firebase Pods in Podfile
Run Pod Install
This issue CAN be the result of developing iOS on an M1 (Apple Silicon) machine. In this case, the only way to fix the problem is to download a Ruby extension called "ffi" which you can read about here (for extra information): https://rubygems.org/gems/ffi/versions/1.0.9
To do this:
In Terminal, install ffi onto your machine using this command:
sudo arch -x86_64 gem install ffi
Then in your project file, install your podfile with this command:
arch -x86_64 pod install
This should allow you to install your pods (especially if you were getting a "zsh: abort pod install" problem. Notice Terminal will warn you "a bug in the Ruby interpreter or extension libraries".
After this, if your pod was FireStore/FireBase you may have to get another GoogleService-Info.plist file in your project.
Related
[!] CocoaPods could not find compatible versions for pod "Flipper-Glog":
In Podfile:
Flipper-Glog (= 0.5.0.4)
None of your spec sources contain a spec satisfying the dependency: Flipper-Glog (= 0.5.0.4).
You have either:
out-of-date source repos which you can update with pod repo update or with pod install --repo-update.
mistyped the name or version.
not added the source repo that hosts the Podspec to your Podfile.
Disable everything related to flipper in Podfile and then cd ios && pod install
# use_flipper!()
Worked after using this command:
pod install --repo-update
If you are building from a fresh Reach Native Project, there should be no need to edit any files in the project to get it to run.
Try the solutions here:
React native ios - error when running pod install (installing Flipper-Glog)
I encountered this problem after deleting all my iOS caches and setting some Virtual Env. Opening Xcode and simulator once then try "pod install" should work.
Remove or comment this line from your ios/Podfile in react native.
# use_flipper!()
For M1 chip Mac, run
"arch -x86_64 pod install"
solved it.
My podfile is this.
# Uncomment the next line to define a global platform for your project
platform :ios, '13.0'
target 'Task Tracker' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
# Pods for Task Tracker
pod 'RealmSwift', '~> 10'
end
I am trying to run pod install
It gives me error LoadError - dlopen(/Library/Ruby/Gems/2.6.0/gems/ffi-1.15.3/lib/ffi_c.bundle, 0x0009): dependent dylib '#rpath/libffi.7.dylib' not found for '/Library/Ruby/Gems/2.6.0/gems/ffi-1.15.3/lib/ffi_c.bundle' - /Library/Ruby/Gems/2.6.0/gems/ffi-1.15.3/lib/ffi_c.bundle
What I tried
gem install ffi
arch -x86_64 pod install
Still same error. What am I missing?
If you're using Intel chip Mac and getting this error after trying the above command also, it's because of the cocoa pods installed on your Mac (Not installed properly). Completely remove the cocoapods and install it again from the beginning. This solution will work.
Jump to /usr/local/opt/libffi/lib, and ln -s libffi.8.dylib libffi.7.dylib
tips: libffi.8.dylib is your current ffi lib
My project shows me the below error in the storyboard. My project is build successfully and also run successfully in the simulator, but still the error exists when I open the storyboard.
Error:
Failed to render and update auto layout status for previewController (80C-7j-jFY): dlopen(GoogleMobileAds.framework, 1): no suitable image found.
Did find:
GoogleMobileAds.framework: no matching architecture in universal wrapper
How can I avoid it?
For Xcode version 9 and later, you have to downgrade your pod repository to remove this problem.
For this what you have to do:
Step 1
Steps which you have to follow:
sudo gem list cocoapods
sudo gem uninstall cocoapods
sudo gem install cocoapods -v 1.4.0
Step 3
Go to your project Directory and update your pod like
pod update
Step 3
Clear your project as well as derived data. Build and run your project. This error will be removed after this.
Add this script on your POD file:
post_install do |installer|
installer.pods_project.build_configurations.each do |config|
config.build_settings.delete('CODE_SIGNING_ALLOWED')
config.build_settings.delete('CODE_SIGNING_REQUIRED')
end
end
Note: if you are facing this issues on Xcode 10 and later, follow all the steps with sudo gem install cocoapods instead of sudo gem install cocoapods -v 1.4.0. It works for me.
Try pod install. It temporarily solves this problem.
I'm trying to install Firebase via CocoaPods for my Objective-C iOS Application. My Podfile is as follows:
target 'RandomName' do
pod 'Firebase/Core'
pod 'Firebase/AdMob'
end
When I run pod install, I get the following error:
[!] Unable to satisfy the following requirements:
- `Firebase/Core` required by `Podfile`
None of your spec sources contain a spec satisfying the dependency: `Firebase/Core`.
You have either:
* out-of-date source repos which you can update with `pod repo update`.
* mistyped the name or version.
* not added the source repo that hosts the Podspec to your Podfile.
Note: as of CocoaPods 1.0, `pod repo update` does not happen on `pod install` by default.
The latest version of CocoaPods is installed, and I have tried running pod repo update. Having a Podfile of the following works fine, but when I try to #import Firebase; in my AppDelegate.m file, Xcode cannot find the module.
target 'RandomName' do
pod 'Firebase'
end
However, the following combination does not install:
target 'RandomName' do
pod 'Firebase'
pod 'Firebase/AdMob'
end
Any help would be appreciated!
Check what version of Firebase is installed when you use pod 'Firebase'. For me it installs 2.4.3 which is an old version. The docs say that the pod should install 3.2 using that pod. It explains why the other pods don't work as they are part of Firebase 3. Pod update doesn't update Firebase to the latest version either. Even forcing a version doesn't work. It can't seem to find the new Firebase versions even though they are in the same podspec.
Here is how I solved it:
make sure you have the latest version of git installed
make sure you have cocoapods >= 1.0.0 installed
delete your pods repo (run pod repo remove master) and use pod setup to make a new one
use the following in your pod file
pod 'Firebase/Auth'
pod 'Firebase/Database'
pod 'Firebase/Core'
(use whatever you want, just don't use 'Firebase')
pod install
everything should install properly
Running 'pod repo remove master' to remove the Pods repo //removes the library
Running 'pod setup' //clones the updated git repo for specs which takes long time as its size is beyond 300K (Be patient!)
Running 'pod install' //problem is solved
have you tried to add
frameworks
use_frameworks!
after target 'RandomName' line
and adding
platform :ios, '9.0'
before target ....
A couple of items to try. From your question, you did try the first two items, but leaving here for completeness of my answer.
The error response you get is helpful. Follow the steps for pod repo update
Make sure your pod is up to date.
pwd> pod --version
1.0.0
Make certain that your git is up to date. I had a build machine that had an outdated git (1.7), and I had the same exact error
-
When I updated to this version from git 1.7 it worked fine.
pwd> git --version
git version 2.8.1
My Podfile for using Firebase Dynamic Links
run pod init from the folder where your .xcodeproj is
Be sure to only launch the .xcworkspace instead of the .xcodeproj from here out.
platform :ios, '8.0'
use_frameworks!
target 'the-name-of-target' do
pod 'Firebase/DynamicLinks'
end
The Same problem occurred while on pod install command.
Please relaunch terminal and navigate to your Xcode project then
simply fire same pod install command. 'Firebase/Database' will installed successfully :)
I just doing following step to fix this error:
$pod setup -- verbose
Then do $pod install
that works for me and my pod file is:
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.0'
use_frameworks!
target 'the-name-of-target' do
pod 'Eureka', '~> 1.6'
end
UPDATE:
Then you can remove your master and re-install cocoapods using following code:
cd ~/.cocoapods/repos
rm -rf master
pod setup
I had the same error, and my solution was to downgrade Cocoapods to 1.0.0, because Cocoapods 1.0.1 didn't work as I expected. Everything works great now!
sudo gem uninstall cocoapods -v 1.0.1
sudo gem install cocoapods -v 1.0.0
My Podfile:
platform :ios, '8.0'
target 'XXX' do
pod 'Firebase/Auth'
pod 'Firebase/Database'
end
For people still having problems with this. When directly coping the firebase walkthourgh website, the install string is:
pod `Firebase/Core`
While it should have been:
pod 'Firebase/Core'
No need for pod setup if this applies to you too.
Update Git and Cocoapods to the last version:
Git: $ brew update && brew upgrade
Cocoapods: $ pod repo update
I am trying set up Stripe in my IOS app, but i have no clue what these instructions mean?
Is cocoapods an application i install?
Step 1: Install Stripe Cocapod(s)
CocoaPods is a common library dependency management tool for iOS
development. To use the Stripe CocoaPods, simply add the following to
your Podfile and run pod install:
pod 'Stripe'
pod 'PaymentKit'
Note: be sure to use the .xcworkspace to
open your project in Xcode instead of the .xcproject.
Here is the guide i am using to set up Stripe... Guide
CocoaPods is a dependency manager.
Install CocoaPods. sudo gem install cocoapods. You may need to pod setup afterwards.
Go into your project directory and pod init. This will generate a Podfile.
Go ahead and edit the Podfile with your favourite editor (vim, emacs, flame wars...). Enter pod 'Stripe' in one line under your target, and also enter pod 'PaymentKit' in a second line. This will install these two frameworks and their dependencies.
Run pod install for CocoaPods to magically install the required dependencies.
Open your $project.xcworkspace. The workspace includes your project as well as your pods target which generates the necessary frameworks.
You're done! Enjoy Stripe and PaymentKit!
cocoa pod installation step :
Open Your Terminal :
sudo gem update --system
sudo gem install cocoapods
pod setup
Then Go To Your Project Directory
pod init
open -a Xcode Podfile
[Edit POD file with pod ‘libname’ ]
pod install