【问题标题】:Error installing Google-Mobile-Ads-SDK安装 Google-Mobile-Ads-SDK 时出错
【发布时间】:2016-12-13 06:26:00
【问题描述】:

您好,有人在安装 Admob 时遇到此错误。

[!] /usr/bin/curl -f -L -o /var/folders/_r/thfyvgfn1f19wtmqttvwfpxh0000gn/T/d20161213-1890-nik74x/file.tgz https://dl.google.com/dl/cpdc/b8337da55c97ec54-Google-Mobile-Ads-SDK-7.14.0.tar.gz --create-dirs --netrc-可选

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:03:02 --:--:--     0curl: (56) SSLRead() return error -9806

这是我的 podfile。

# Pods for admobintegration

pod 'Firebase/Core'
pod 'Firebase/AdMob'

【问题讨论】:

  • 嗨,Mad,我遇到了与 pod 'Firebase/Core' 相同的问题
  • 这里有同样的错误。

标签: ios objective-c cocoapods google-admob


【解决方案1】:

花了 5 个小时才找到解决方案。现在在我的 XCode 项目中它工作正常。 问题是因为以太网网络代理或防火墙之类的东西阻止了 firebase 下载 url。

当我的 macbook 与移动网络连接时,它就可以工作了,最后“pod install”命令成功了。

我已通知我的 Office 网络管理员修复并允许来自终端的 firebase url https://dl.google.com/dl/cpdc/bf4dd8c5ac4d8ac9/Firebase-3.10.0.tar.gz。希望他们能尽快解决这个问题。

但目前我已经在移动网络上成功安装了 firebase pod。希望这也能解决您的问题。

【讨论】:

    【解决方案2】:

    我在安装 FCM pods 时也面临同样的问题。尝试像下面这样在顶部添加你的 pod 文件。这是我的 pod 文件

     # Uncomment the next line to define a global platform for your project
     # platform :ios, '9.0'
    
     target 'ChkdIn' do
      # Uncomment the next line if you're using Swift or would like to use  dynamic frameworks
     # use_frameworks!
    
     # Pods for ChkdIn
     pod 'Firebase/Core'
     pod 'Firebase/Messaging'
     pod 'CarbonKit'
     pod 'SDWebImage', '~>3.8'
     pod 'RKCardView'
     pod 'HTHorizontalSelectionList', '~> 0.7.4'
     pod 'DGActivityIndicatorView'
    pod 'ASJTagsView'
    
    
    target 'ChkdInTests' do
    inherit! :search_paths
    # Pods for testing
    end
    
    target 'ChkdInUITests' do
    inherit! :search_paths
    # Pods for testing
    end
    
     end
    

    【讨论】:

    • 嗨 Siva,你有没有找到任何解决方案,我面临同样的问题
    • 刚才我遇到了同样的问题,只需在顶部添加您的 pod 文件,例如
    • 在我这边,我在下面添加了文件,但它不起作用,然后在我在顶部添加 pod 文件后,它正在工作。
    • 但我这边它正在工作,好的,你可以在这里发布你的 pod 文件吗?
    • ok Siva,我将 pod 'Firebase/Core' 设置为 top ,但同样的问题对我来说仍然存在。我是第一次这样做,我只将 pod 文件中的库设置为 pod 'Firebase/Core'
    【解决方案3】:

    而不仅仅是添加

    <key>GADApplicationIdentifier</key>
    <string>ca-app-pub-3940256099942544~1458002511</string>
    

    添加这个

    <key>GADApplicationIdentifier</key>
    <string>ca-app-pub-3940256099942544~1458002511</string>
    <key>SKAdNetworkItems</key>
      <array>
        <dict>
          <key>SKAdNetworkIdentifier</key>
          <string>cstr6suwn9.skadnetwork</string>
        </dict>
      </array>
    

    为我解决了这个问题。

    参考:https://developers.google.com/admob/ios/quick-start#update%5C_your%5C_infoplist

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2021-11-14
      • 2015-07-14
      • 1970-01-01
      • 2020-08-21
      • 1970-01-01
      • 1970-01-01
      • 2017-08-16
      • 2017-04-16
      相关资源
      最近更新 更多