ios - Pod GoogleMaps无法运作

标签 ios cocoapods

我知道这是非常基本的,但无法调试问题。这是我的Podfile。

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.1'
pod 'GoogleMaps'

我是从here中挑选的。当我尝试pod install时,我得到
[!] Unable to find a specification for `GoogleMaps`

详细说:
  Preparing

Updating local specs repositories

Updating spec repo `master`
  $ /usr/bin/git pull --ff-only
  Already up-to-date.

Analyzing dependencies

Inspecting targets to integrate
  Using `ARCHS` setting to build architectures of target `Pods`: (``)

Finding Podfile changes
  - GoogleMaps

Resolving dependencies of `Podfile`
[!] Unable to find a specification for `GoogleMaps`

/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/resolver.rb:388:in `handle_resolver_error'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/resolver.rb:69:in `rescue in resolve'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/resolver.rb:56:in `resolve'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/installer/analyzer.rb:535:in `block in resolve_dependencies'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/user_interface.rb:59:in `section'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/installer/analyzer.rb:533:in `resolve_dependencies'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/installer/analyzer.rb:70:in `analyze'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/installer.rb:210:in `analyze'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/installer.rb:133:in `block in resolve_dependencies'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/user_interface.rb:59:in `section'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/installer.rb:132:in `resolve_dependencies'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/installer.rb:104:in `install!'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/command/project.rb:71:in `run_install_with_update'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/command/project.rb:101:in `run'
/Library/Ruby/Gems/2.0.0/gems/claide-0.9.1/lib/claide/command.rb:312:in `run'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/lib/cocoapods/command.rb:48:in `run'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.38.2/bin/pod:44:in `<top (required)>'
/usr/bin/pod:23:in `load'
/usr/bin/pod:23:in `<main>'

最佳答案

重新开始:

  • 创建一个新的干净的Xcode项目
  • pod init
  • Podfile中添加以下行
  • pod install

  • Podfile
    source 'https://github.com/CocoaPods/Specs.git'
    platform :ios, '8.1'
    
    target 'SO-32079263' do
    pod 'GoogleMaps'
    end
    

    pod安装
    用0.37.1测试
    Analyzing dependencies
    
    Downloading dependencies
    Installing GoogleMaps (1.10.1)
    Generating Pods project
    Integrating client project
    

    较不新鲜:(请参阅Jatin评论)

    备用步骤2:rm -rf Pods/ Podfile Podfile.lock ; pod init

    关于ios - Pod GoogleMaps无法运作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32079263/

    相关文章:

    ios - 让 MobileVLCKit 通过 Cocoapods 工作

    ios - Cocoapods - 指定源 repo 用户名

    ios - 未加载框架库 : 'Image not found'

    ios - Cocoapods 和 Xcode,ld : library not found for -lAFNetworking

    ios - 如何编译 Saurik 的 Veency?

    ios - 如何使用 UIAutomation 从 UIImagePickerController 选择图像

    ios - 将自定义坐标设置为函数,Waze Integration

    ios - 构建依赖于 GoogleAnalytics-iOS-SDK 的 Cocoapod 验证失败

    ios - 如何对齐 Right-Justify UILabel?

    ios - SCNNode 上的 CIFilter 仅适用于模拟器