ubuntu下使用脚本交叉编译windows下使用的ffmpeg

sh脚本下载于

http://ffmpeg.org/trac/ffmpeg/wiki/CrossCompilingForWindows

尝试编译 总是出点错误。

1. 执行./cross_compile_ffmpeg.sh 的时候,提示 git co 不可识别的命令。

原来是作者使用了alian。将Line 137 和Line 138 中git co替换成git checkout。

2.错误提示: Code:checking for /bin/bash... configure: error: cannot check for file existence when cross compiling

这里参考http://ffmpeg.zeranoe.com/forum/viewtopic.php?f=5&t=757

”It seems libaacplus won't co-exist with libfdk-aac or libvo-aacenc when compiling for Windows. 
But hey, libaacplus + libfaac is sufficient.“

几种aac编解码冲突,所以之选择一种才可以。

3.执行 do_git_checkout https://github.com/FFmpeg/FFmpeg.git ffmpeg_git 的时候

提示:Unable to find remote helper for 'https'

将 https 改成 git 。脚本中有几处do_git_checkout后面的http 或者 https 都可以换成git 。

原文地址:https://www.cnblogs.com/zzugyl/p/2878013.html