On xcode, I'm trying to use a pod to implement a mail API in Swift. When I try to build the framework, I get this error:
Compiling for iOS 8.0, but module 'Alamofire' has a minimum deployment target of iOS 10.0
How do I change the pod so it builds for iOS 10.0 or above?
The problem occurs due to the Alamofire has updated its library. While Evreflection has not updated for the Alamofires updated version. You need to specify the Version of Alamofire here.
Use this line in podfile to specify the version
pod 'EVReflection/Alamofire','~> 5.10.1'
pod 'Alamofire','~> 4.9.1'
Then deintegrate the pods from project and install it again.
This would solve the problem you are facing
You should up Deployment Target of your app to 10.0 in your project's settings because you can't use pods with highest iOS version than you use in the project.:
Related
Well This is a very common error by xcode and it has so [many] 2 answer on StackOverflow still I am facing this in a particular situation.
My project is running fine on iOS 11 Deployment target but when I try to downgrade my deployment target to iOS 10, it start to throw Module map file not found for every pod library.
What Have I tried:
Updated Podfile platform :ios, '10.0'
pod deintegrate then 'pod cleanand after that runpod install`
Clean DerivedData folder
Clean project couple of times using the combination cmd+opt+shift+k & cmd+shift+k
Check Objective-C Bridging Header.
Revert back deployment target to iOS 11 and it works on iOS 11
Removing pod which showing Module map file not found and then it's throwing build error where I have used those library.
How can I get out from this error?
P.S.:
It's a mixed project of obj-c and swift 4.2.
Xcode version 11.2.1(11B53).
Cocoapods version 1.8.4
model Map file not found
faild to emit precompiled header
From given set of information, it seems you are using color as an asset in your asset catalog like following screenshot
It requires min deployment target ios 11 to work. Stop using this feature if you want to run in ios 10.
Hope it helps.
I am attempting to use the MetaWear cocoapod to connect to BLE sensors from my IOS application. Before adding this pod, I created a basic Single View Application in Xcode. I tried to compile and run it on my iPhone, and it showed up as expected.
Having done this, I did a pod init, and updated my Podfile to look as follows, as recommended in the above MetaWear cocoapod link:
platform :ios, '12.2'
target 'myProj' do
use_frameworks!
pod 'MetaWear', '~> 3.2'
end
Once I run "pod install", I get the following output:
Analyzing dependencies
Downloading dependencies
Using Bolts-Swift (1.4.0)
Using MetaWear (3.2.0)
Generating Pods project
Integrating client project
Sending stats
Pod installation complete! There is 1 dependency from the Podfile and 2 total pods installed.
I then open my Xcode project ( myApp.xcworkspace ), and when I try to re-build the project, I keep getting this error:
Could not build Objective-C module 'BoltsSwift'
This is also shown in the following image:
As a result, I was under the impression that maybe I should downgrade the BoltsSwift version, but specifying something lower than 1.4, seems to be ignored. For example, I added this pod:
pod 'Bolts-Swift', '~> 1.3'
And my output after running pod install, still yielded "Using Bolts-Swift (1.4.0)". So I am not too sure how to get rid of this compilation failure. Maybe downgrading BoltsSwift is not the correct course of action. What can I try? (I am using Xcode Version 10.2.1 (10E1001))
Ok, turns out that by default, XCode set my Swift compilation to 5.0 for the BoltsSwift and MetaWear pod. I changed it to Swift 4, and I was able to build.
Updating the pods compilation level might also be a good idea, as described here :
How to set the Legacy Swift Version for each Pod in Podfile Xcode 9.0 Swift 3.2 / Swift 4.0
I am implementing log in with Microsoft in my swift project and using MSAL for this. https://github.com/AzureAD/microsoft-authentication-library-for-objc
This is my pod file.
target 'TestMSL' do
# Comment the next line if you're not using Swift and don't want to use dynamic frameworks
use_frameworks!
# Pods for TestMSL
pod 'MSAL', :git => 'https://github.com/AzureAD/microsoft-authentication-library-for-objc', :tag => '0.1.3'
end
For pod install it gives me error like CocoaPods could not find compatible versions for pod "MSAL"
Here strange is if i change my deployment target to 10 then pod installation works well.
Please help me how can i solve this. I want minimum deployment target 9.0.
Here is the answer from the microsoft authority on github
Current iOS deployment target supported by MSAL is 9.3. They haven't tested MSAL on iOS 9.0, so it's not officially supported.
Also, we'll be shortly dropping iOS 9.3 support around the time when iOS 12 gets released.
Original Answer
I implement the https://github.com/TakeScoop/SwiftyRSA in my project using pods but it give me error
how to solve this? Any other pod please suggest me too.
Pod file
Version 8.0 of iOS has some serious issues. I would suggest that you target iOS 8.3 as a minimum. If you change your platform line in your Podfile to iOS 8.3 and run pod update then you will get SwiftyRSA 1.2.0 which will resolve your issue.
I am starting a project by creating a blank Single-View app for Swift. Using Cocoapods, I am adding Alamofire as follows:
platform :ios, "8.0"
use_frameworks!
target 'TestGauge' do
pod 'Alamofire', '~> 3.0'
end
target 'TestGaugeTests' do
end
Then, in Terminal I run pod install
When returning to XCode, the project fails to build with 1000+ errors generated from Alamofire.
I am running XCode from the workspace file and NOT the project file.
XCode version 6.4
Has anyone had this behavior, or can anyone offer a solution? Have I missed a critical step?
Thanks!
Alamofire 3.0 is written in Swift 2.0. Xcode 6.4 does not support Swift 2.0. Change Alamofire version or update your Xcode.