ffmpeg类库本地下载

一、下载ffmpeg脚本得到如下图文件夹(说明:此文章集成的ffmpeg版本为4.0.3)

image.png

二、下载ffmpeg类库

  • 打开终端cd到刚才下载的文件夹下(这个文件夹FFmpeg-iOS-build-script)(如果你要是不知道什么是cd请私聊我)
  • 执行脚本文件,在终端输入一下指令

$ ./build-ffmpeg.sh

说明:如果你的git版本不是最新的话会报错(下图)解决办法点击查看

image.png

报错内容
building arm64...
xcrun -sdk iphoneos clang is unable to create an executable file.
C compiler test failed.
If you think configure made a mistake, make sure you are using the latest
version from Git. If the latest version fails, report the problem to the
ffmpeg-user@ffmpeg.org mailing list or IRC #ffmpeg on irc.freenode.net.
Include the log file "ffbuild/config.log" produced by configure as this will help
solve the problem.

执行完上面操作后不着急,很有可能还是报这个错误,所以我们需要再执行一个命令
$ sudo xcode-select --switch /Applications/Xcode.app

执行完上面的命令后再一次执行
$ ./build-ffmpeg.sh

是不是很神奇已经开始下载了,待下载完成后打开文件夹会看到下图的文件,那么恭喜下载完成,里面的 FFmpeg-iOS 便是我们需要的文件夹,其他不需要的那就不管了,😆比如 ffmpeg-3.0文件是全平台下载的编译文件里面包含了TVOS、Mac OS、iOS ...。

image.png
最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容