如何在github上为android-ffmpeg项目构建最新的ffmpeg



我正在做https://github.com/guardianproject/android-ffmpeg项目。在这个项目中,它使用ffmpeg 0.11.1版本。我如何用最新的ffmpeg版本构建这个项目?

我尝试在这个项目中删除ffmpeg文件夹。在url: [git://git.videolan.org/ffmpeg.git]中查看最新的ffmpeg版本。之后,我运行命令。/configure_make_everything.sh正常,但我得到错误:

    File to patch: 
Skip this patch? [y] 
Skipping patch.
3 out of 3 hunks ignored
patching file libavutil/arm/intmath.h
Reversed (or previously applied) patch detected!  Skipping patch.
3 out of 3 hunks ignored
patching file configure
Reversed (or previously applied) patch detected!  Skipping patch.
1 out of 1 hunk ignored
~/workspace/android-ffmpeg/ffmpeg ~/workspace/android-ffmpeg ~/workspace/android-ffmpeg
**ERROR: freetype2 not found**
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 "config.log" produced by configure as this will help
solving the problem.
~/workspace/android-ffmpeg ~/workspace/android-ffmpeg
~/workspace/android-ffmpeg
~/workspace/android-ffmpeg ~/workspace/android-ffmpeg
~/workspace/android-ffmpeg/ffmpeg ~/workspace/android-ffmpeg ~/workspace/android-ffmpeg
Makefile:2: config.mak: No such file or directory
Makefile:53: /common.mak: No such file or directory
Makefile:93: /libavutil/Makefile: No such file or directory
Makefile:93: /library.mak: No such file or directory
Makefile:95: /doc/Makefile: No such file or directory
Makefile:178: /tests/Makefile: No such file or directory
make: *** No rule to make target `/tests/Makefile'.  Stop.
Makefile:2: config.mak: No such file or directory
Makefile:53: /common.mak: No such file or directory
Makefile:93: /libavutil/Makefile: No such file or directory
Makefile:93: /library.mak: No such file or directory
Makefile:95: /doc/Makefile: No such file or directory
Makefile:178: /tests/Makefile: No such file or directory
make: *** No rule to make target `/tests/Makefile'.  Stop.
~/workspace/android-ffmpeg ~/workspace/android-ffmpeg
~/workspace/android-ffmpeg
admin@ubuntu:~/workspace/android-ffmpeg$

我得到错误:Freetype2没有找到,但如果我用这个项目中包含的原始ffmpeg构建,则不会发生此错误。

我该如何修复它?请帮助

我在为桌面构建ffmpeg时遇到了同样的问题。在我的情况下,ffmpeg正在寻找/usr/include/freetype中的freetype2头文件,而不是/usr/include/freetype2

这个解决方案很难看,但是我创建了一个符号链接

sudo ln -s /usr/include/freetype2/ /usr/include/freetype

Then ./configure was success .

您可以通过修补ffmpeg来替换

的所有实例来实现相同的目的。

#include <freetype/config/ftheader.h>

#include <freetype2/config/ftheader.h>

看起来这只是在libavfilter/vf_drawtext.c

由于您似乎是在为不同的CPU构建,因此您可能需要为您的体系结构修改路径,使其具有正确的位置。

这几乎是一年前的事了,所以我猜你不会在等答案,但我有一个。我分叉了guardian项目并更新了子模块条目。

https://github.com/touchlab/android-ffmpeg

您需要根据顶部的注释手工编辑ffmpeg/configure。忽略关于ffmpeg/libavutil/arm/intmath.h的部分。

我是用ndk r10c构建的

最新更新