Build fails after updating cocoapods to 1.0.1 - ios

I updated cocoapods today, deleted the Pods folder entirely and executed pod install.
When i am trying to build now, i receive the error in the attached image.
My podfile looks the following:
source 'https://github.com/CocoaPods/Specs.git'
source 'https://github.com/artsy/Specs.git'
platform :ios, '9.0'
inhibit_all_warnings!
use_frameworks!
target 'MyTarget' do
pod '....'
end
I tried adding #define LOG_OBJC_MAYBE(...) to my pch file but it did not help. What might be the issue?

Related

Cocoapods install error- Unable to find a specification for pod

I am trying to install two pods to my Xcode project from terminal. I initially had installed a pod called PRAugmentedReality, and it worked fine. Then I tried adding the pod BFTransmitter, and started getting the following error message:
[!] Unable to find a specification for 'PRAugmentedReality'
If I remove the PRAugmentedReality pod and install with just BFTransmitter, it also works fine. So basically I am able to install either on their own, but not together.
My podfile looks like this:
#source for BFTransmitter
source 'https://bitbucket.org/bridgefy/bridgefypods.git'
target 'FWF' do
pod 'BFTransmitter'
pod 'PRAugmentedReality'
target 'FWFTests' do
inherit! :search_paths
end
end
I have tried repo remove master pod setup and then pod install, still no luck.
just add source to install both pods together check my podFile and add sourced before your target as I did
# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'
source 'https://github.com/CocoaPods/Specs.git'
source 'https://bitbucket.org/bridgefy/bridgefypods.git'
target 'pod' do
# Uncomment the next line if you're using Swift or would like to use dynamic frameworks
# use_frameworks!
pod 'BFTransmitter'
pod 'PRAugmentedReality'
# Pods for pod
end
Result
I encounter the same problem in my project.
When I was editing pod file, I changed pod 'SCSoftKycSolutionSdkSource' to pod 'MyprojectName'.
I fixed the below, issue fixed.
pod 'SCSoftKycSolutionSdkSource'

IOS COCOAPOD with sources

I am trying to update the CocoaPods in my Xcode project, but when I try to run pod update, it doesn't work.
My podfile:
source 'https://github.com/MapQuest/podspecs-ios.git'
target 'FireBaseFixed' do
pod 'Firebase', '3.11.0'
pod 'MOCA'
pod 'MapQuestMaps'
end
And the response
daortiz:FireBaseFixed dortiz$ pod update
Update all pods
Updating local specs repositories
Analyzing dependencies
[!] Unable to find a specification for `Firebase (= 3.11.0)`
[!] Your Podfile has had smart quotes sanitised. To avoid issues in the future, you should not use TextEdit for editing it. If you are not using TextEdit, you should turn off smart quotes in your editor of choice.
What I doing wrong?
Any reason you require Firebase 3.11.0 exactly?
To get the latest framework, use
pod 'Firebase'
Anyways, your problem is not the version, rather the sources, you seem to have omitted cocoapods main source and included only MapQuestMaps.
You also need to specify the version of MapQuestMaps as the are all pre-release versions and cocoapods will cry foul.
The code below fixes that.
source 'https://github.com/MapQuest/podspecs-ios.git'
source 'https://github.com/CocoaPods/Specs.git'
target 'FireBaseFixed' do
pod 'Firebase', '3.11.0'
pod 'MOCA'
pod 'MapQuestMaps', '3.4.1-1.1'
end
If the above doesn't work, sync your repo by running the following
pod repo update --verbose
Then run
pod install
Below is the working version of your podfile
# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'
source 'https://github.com/MapQuest/podspecs-ios.git'
source 'https://github.com/CocoaPods/Specs.git'
target 'FireBaseFixed' do
pod 'Firebase'
pod 'MOCA'
pod 'MapQuestMaps’, '~>3.4.1-1.1'
end

Error on terminal while adding pod - [!] Invalid Podfile file: The target Pods-MyApp already has a platform set

In my app i have integrated Googlemap using CocoaPod.
Now I want to integrate CitrusPay using CocoaPod but when i have execute pod install command on terminal then i am getting error -
[!] Invalid Podfile file:
The target Pods-MyApp already has a platform set..
from /Users/NewFolder/Desktop/xyz.app.MyApp.ios/Podfile:10
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.1'
pod 'GoogleMaps'
Does anyone knows how to solve this error?
i have the same question with you,and than search answer in the internet,but nothing ,so i solve question myself,
step:
first : sure you 'Podfile' file only have "platform:ios,'version'" one time;
second : add "target 'yourtarget'do" in the file top;
third : add "end" in the file bottom.
you must maintain your "Podfile" file have formatter:
enter image description here
you will solve this question, wish can help you.thanks.
Add target to your podfile
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.1'
target 'YourTarget' do
pod 'GoogleMaps'
end
I had the same issue and eventually I solved it, now my Podfile looks like this
#Alamofire - lib for HTTP requests
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '10.0'
use_frameworks!
target 'Fitzz' do
pod 'Alamofire', '~> 4.0'
#XCGLogger - lib for loggin output
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.0'
use_frameworks!
pod 'XCGLogger', '~> 4.0.0'
end
I am a rookie in iOS, but this works for me

Compilation error since updating cocoapods to 1.0.0

I updated cocoapods to version 1.0.0. My podfile look like that:
source 'https://github.com/CocoaPods/Specs.git'
source 'https://github.com/artsy/Specs.git'
platform :ios, '9.0'
inhibit_all_warnings!
use_frameworks!
target “my_target” do
...
pod 'MagicalRecord/CocoaLumberjack'
...
end
Since the update i get compilation errors when trying to compile the pod CocoaHTTPServer, used by CocoaLumberjack. Attached is a screenshot of the error
Issue did not happen before updating CocoaPods.
What might be the problem?

How to add one pod to multiple targets in Cocoapods?

Right now I need to add LiveSDK to multiple targets. Please see below:
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '7.0'
target :CalDoKit do
pod 'LiveSDK'
end
pod 'Google-API-Client/Calendar'
pod 'LiveSDK'
As you can see the LiveSDK pod added twice. And I am getting warning from the console output when I run the application: One of the two will be used. Which one is undefined.
What's the correct way to add one pod to multiple targets?
New code:
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '7.0'
link_with 'CalDo', 'CalDoKit'
pod 'LiveSDK'
target :CalDo do
pod 'SVProgressHUD'
end
But I am getting warning:
[!] CocoaPods did not set the base configuration of your project because your project already has a custom config set. In order for CocoaPods integration to work at all, please either set the base configurations of the target `TestKit` to `Pods/Target Support Files/Pods/Pods.debug.xcconfig` or include the `Pods/Target Support Files/Pods/Pods.debug.xcconfig` in your build configuration.
Solution 1:
Remove that 'target :xx do ... end' and add pod without defining targets. It will add the pod for all targets.
Solution 2:
Delete that podfile and run pod init command from terminal. this will make a new podfile with all the targets used in the project and then you can add pods separately for each target
Add this to the Podfile
target :AnotherTarget do
pod 'LiveSDK'
end
EDIT
This is the final Podfile source
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '7.0'
target :CalDoKit do
pod 'LiveSDK'
end
target :OtherTarget do
pod 'LiveSDK'
end
If you execute pod init console command on your project folder, it will create the Podfile with built in code.
See here: http://guides.cocoapods.org/syntax/podfile.html#target

Resources