Cocoapods 安装 libopencv-contrib 时出错 [英] Cocoapods error installing libopencv-contrib

查看:101
本文介绍了Cocoapods 安装 libopencv-contrib 时出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用这个 opencv3 库进行本机反应,但是当我尝试使用 pod install 安装 IOS 依赖项我收到此错误,有人可以帮助我吗?

I am using this opencv3 library for react native, but when I try to install IOS dependencies using pod install i recieve this error, can someone help me?

    [!] Error installing libopencv-contrib
    [!] /usr/bin/unzip /var/folders/hj/5y2w85bn64n0t7mmzcc9rtbc0000gn/T/d20200815-25128-1yye817/file.zip -d /var/folders/hj/5y2w85bn64n0t7mmzcc9rtbc0000gn/T/d20200815-25128-1yye817
    
    Archive:  /var/folders/hj/5y2w85bn64n0t7mmzcc9rtbc0000gn/T/d20200815-25128-1yye817/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/hj/5y2w85bn64n0t7mmzcc9rtbc0000gn/T/d20200815-25128-1yye817/file.zip or
            /var/folders/hj/5y2w85bn64n0t7mmzcc9rtbc0000gn/T/d20200815-25128-1yye817/file.zip.zip, and cannot find /var/folders/hj/5y2w85bn64n0t7mmzcc9rtbc0000gn/T/d20200815-25128-1yye817/file.zip.ZIP, period.

推荐答案

以下愚蠢的修复为我解决了这个问题:

The following silly fix solved the issue for me:

  • 运行pod spec edit libopencv-contrib
  • 找到 url(一个保管箱链接)
  • ?dl=0 替换为 ?dl=1
  • 保存文件&&运行 pod install现在安装应该没有错误地完成.
  • run pod spec edit libopencv-contrib
  • locate the source url (a dropbox link)
  • replace ?dl=0 with ?dl=1
  • save the file && run pod install Now the installation should complete without errors.

这篇关于Cocoapods 安装 libopencv-contrib 时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆