简体   繁体   中英

DJI iOS SDK 4.5 issue using Cocoapods

I have trying to install DJI iOS SDK 4.5 using cocoapods in sample code downloaded from DJI website.

Every-time I try pod install it throws error saying

CocoaPods could not find compatible versions for pod "DJI-SDK-iOS":
In Podfile:
DJI-SDK-iOS (~> 4.5)
None of your spec sources contain a spec satisfying the dependency: `DJI-SDK-iOS (~> 4.5)`

I even tried uninstalling cocoapods and reinstalling it again, but no luck.

Error appeared because your source repository is out of date. You can resolve the issue by running:

pod install --repo-update


If this does not solve your problem, check if your cocoa-pods version is updated one. You can follow the below link for the same.

update cocoapods version


Explanation:

When you will run pod install , you will found the possible reason of this error as:

None of your spec sources contain a spec satisfying the dependency: DJI-SDK-iOS (~> 4.5) .

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.

Note: as of CocoaPods 1.0, pod repo update does not happen on pod install by default.

I tried pod install --repo-update it was not able to update as it kept on throwing error

Updating spec repo master [!] Failed to connect to GitHub to update the CocoaPods/Specs specs repo - Please check if you are offline, or that GitHub is down

Finally I found the solution my prob in: https://stackoverflow.com/a/48962041/32140

After this I was able to install the new pod version

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM