无法使用远程框架创建 Cocoapod 依赖项

时间:2021-04-23 06:03:34

标签: ios swift objective-c dependencies cocoapods

我想使用位于远程位置(例如 git 和 drop box)的现有框架(用于内部使用的编译框架,我想通过 cocoapods 在内部共享)创建 Cocoapod 依赖项。

我正在关注Tutorial

下面是podspec文件的代码

Pod::Spec.new do |s|
  s.name             = 'SDK101'
  s.version          = '0.1.0'
  s.summary          = 'A Awesomeness of SDK101.'
  s.description      = <<-DESC
  Add long description of the pod here.Awesomeness!!!
                       DESC

  s.homepage         = 'https://github.com/'
  s.license          = { :type => 'MIT', :file => 'LICENSE' }
  s.author           = { 'Sourabh' => 'sourabh.gajbhiye@gmail.com' }
  
  s.source           = { :http => 'https://app.box.com/s/ipwollwlh675fkg3oy87rr7nneafafv0', :type => 'zip' }

  s.ios.deployment_target = '12.0'
  s.platform          = :ios
  s.ios.vendored_frameworks = 'SDK101.framework'
  s.exclude_files = "Classes/Exclude"    
end

对于此文件,当我在终端中执行以下命令以验证 pod 时,出现如下所示的错误

pod spec lint --verbose


[!] Error installing SDK101
 -> SDK101 (0.1.0)
    - ERROR | [iOS] unknown: Encountered an unknown error ([!] /usr/bin/unzip /var/folders/gq/xrq80ysd50nd5frn2zhb89dc0000gn/T/d20210422-75411-1bv4xo/file.zip -d /var/folders/gq/xrq80ysd50nd5frn2zhb89dc0000gn/T/d20210422-75411-1bv4xo

Archive:  /var/folders/gq/xrq80ysd50nd5frn2zhb89dc0000gn/T/d20210422-75411-1bv4xo/file.zip
  End-of-central-directory signature not found.  Either this file is not
  a zipfile, or it constitutes one disk of a multi-part archive.  In the
  latter case the central directory and zipfile comment will be found on
  the last disk(s) of this archive.
unzip:  cannot find zipfile directory in one of /var/folders/gq/xrq80ysd50nd5frn2zhb89dc0000gn/T/d20210422-75411-1bv4xo/file.zip or
        /var/folders/gq/xrq80ysd50nd5frn2zhb89dc0000gn/T/d20210422-75411-1bv4xo/file.zip.zip, and cannot find /var/folders/gq/xrq80ysd50nd5frn2zhb89dc0000gn/T/d20210422-75411-1bv4xo/file.zip.ZIP, period.

Analyzed 1 podspec.

[!] The spec did not pass validation, due to 1 error.

此后我关注了 Cocoapods error installing libopencv-contrib 但它没有帮助我。

请帮我看看我做错了什么?

0 个答案:

没有答案