Using SVProgressHUD fails to build in Xcode - ios

I have installed SVProgressHud to my Xcode project via cocoa pods but I am getting an error during build time. I have posted an image of the error I am getting. I am using swift 3 and Xcode 8. I have searched everywhere for a solution but can't find anything. The only issue I can think of is the SVProgressHud cocoa pod that I have installed is not compatible with swift 3 and Xcode 8. I tried to install an earlier version of SVProgressHud but it automatically updates to the latest. I really don't know where to go from here. Help would be very much appreciated! Thanks in advance
Edited:

If you would like to try an older version of the pod, you can visit here for list of versions/changelogs: https://cocoapods.org/pods/SVProgressHUD#changelog
and then in your podfile you can set the version like so:
pod 'SVProgressHUD', '2.2.1'
I was able to install the pod and build without issues on Xcode 9.2, so not sure if its and issue with xcode 8 or something else. If its an option, why not update to 9.2?

Related

Cannot find type 'SKAdImpression' in scope

I'm trying to implement MoPub into my Swift app, but in some of the files that are provided by the MoPub pod there are errors saying Cannot find type 'SKAdImpression' in scope. I also cannot import MoPub in my own documents. I tried running pod update restarting xcode, and making sure I am using the .xcworkspace file
Edit: I just re-read the apple documentation, and noticed that it says SKAdImpression is an iOS 14.5+ feature. The version of Xcode I have is for iOS 14.4, so it makes sense as to why it cannot be found. My only concern is, does this mean that my app will only work on iOS 14.5+?
Edit 2: My mac does not support the latest MacOS which is required for the latest Xcode for 14.5. Is there anything I can do to get MoPub working anyway?
The version of Xcode I have is for iOS 14.4
My mac does not support the latest MacOS
Bad news is that is there is no other way around this error, as far as I can see.
What did not help:
Removing the version, pod 'mopub-ios-sdk' and running pod install of pod update again.
Cleaning Build Folder.
Cleaning the /DerivedData folder.
What did help:
Updating Xcode to the 12.5 version.
Take the version out.
pod 'mopub-ios-sdk'
run pod install
Alternatively you can follow this from their guide:
simply import MoPubSDK/MoPub-Bridging-Header.h to your project and
ensure that the Objective-C Bridging Header build setting under Swift
Compiler - Code Generation has a path to the header.
They also have a sample program, take a look at that as well. You can find it here:
https://github.com/mopub/mopub-ios-sdk/tree/master/Canary
Also, make sure you have the project closed out before you run pod install. I have seen issues in the past when this happens.

CocoaPods not Installing properly

my project was working fine until I installed the pushNotifications pod. It gave me an error that it is compatible with only ios 10.0 so I forced my pods version from global 9.0 to 10.0. After that I am unable to get my app to work. I have tried clean pods and reinstalling. I even tried by cleaning pod cache.
I don't know how to explain this error. So, any help will be appreciated. thnx
Looks like 'pushNotifications' pod needs iOS 10+ to run and I think your project supports lower versions of iOS(i.e iOS 9). Because a pod global version specifies a minimum version to your pod to run which means, in your case, that the pods you add must support iOS 10+ otherwise your cocoapods won't be able to compile. And looks like you're using some pod that doesn't support iOS 10+(i.e AppAuth) that's why you're having this issue.
I don't know which framework you're using but I really recommend you to take a look on it and find which one doesn't support iOS 10+ replace or update it because they need to support iOS 10+ otherwise it will be a huge problem for you in the future.

JonkyKong's SideMenu 'No Such Module' error

I'm working on a fairly large iOS project using Swift 4.0 for which I require a side menu and JonkyKong's implementation of it seems ideal.
I tried install it via cocoapods but I always get :
'No Such Module' on the Import SideMenu line of code.
Cleaned the build using
Option+Command+Shift+K
Still no luck.
Deintegrated the pod install and re-installed.
Still wont work, so I decided to go for a Carthage install to find myself in the same situation, even after cleaning the build and re-starting the whole project several times.
I've gone through the README and found no answers there.
Before raising this as an Issue I'd like to know if anyone out there knows of an answer for this.
Thanks in advance!
I've met this problem aswell when i build on iOS 10.
Then i found that it cause by a wrong configuration in build setting.
The project's deployment target i set to 10.0
but pod SideMenu's deployment target is 12.0.
Change the pod SideMenu's deployment target to 10.0 resolve my problem.
Hope that it's help U.

Module compiled with Swift 4.0 cannot be imported in Swift 3.2.2: AudioKit

I have just updated xCode to the latest version, and am getting the error when trying to build.
"Module compiled with Swift 4.0 cannot be imported in Swift 3.2.2: /Users/james/Documents/MyApp/Pods/AudioKit/iOS/AudioKit.framework/Modules/AudioKit.swiftmodule/x86_64.swiftmodule"
It was working before I upgraded the latest xCode.
The error message is telling you that Xcode 9.1 is using Swift 3.2.2, while the Swift framework you're building against was built for Swift 4.0 (using Xcode 9.0). You need to update your frameworks to versions built for the version of Swift that you're using.
First If you update the Xcode the Xcode-> preferences-> LocationsTab and change the command line tolls Xcode version.. Now check here
AudioKitReleases
pod 'AudioKit', '~> 4.0.3'
AudioKit V4.0.3 for Xcode 9.1 Pod version according to your Swift language, and update your AudioKit pod by command pod update AudioKit
If you're using AudioKit with CocoaPods, you can run 'pod install' to pull the Swift 4/Xcode 9.1 ver of AK. Then clean (Shift + CMD + K), and clear the derived data. If still having issues, an Xcode restart should fix that.
Or, you can:
(1) Pull the latest AudioKit
(2) Re-compile the framework:
$ cd AudioKit/Frameworks
$ ./build_frameworks.sh
(3) Delete the Derived Data, Clean (Shift+CMD+K), and Restart Xcode
Best of luck,
Best way to get rid of this is, go to https://github.com/AudioKit/AudioKit/releases
find the version compatible with the Xcode that you are using and change you pod file version.
I was using Xcode 10.1 so I changed my file pod 'AudioKit', '4.5'
it solved my problem.

CocoaPods error on building project

I have a running project which is working fine with pods. I had to copy this project to develop version-2. Now when I try to build project, I encounter following issue in pod's code. I tried removing this specific pod but same type of errors were shown in different pod.
tried all of this: https://guides.cocoapods.org/using/troubleshooting.html ,but it didn't help at all.
Being new to iOS development, I can't figure out, what I am doing wrong.
It seems like you are using the newer version of pod in older Xcode. So either you need to update your Xcode or downgrade your pod to the relevant version supporting Xcode. From image i can guess you might be using Xcode 7.2 or down and pod is in swift 2.3 or 3

Resources