gpt4 book ai didi

android - FFMPEG android编译错误

转载 作者:行者123 更新时间:2023-11-30 03:01:35 27 4
gpt4 key购买 nike

我正在尝试使用 ndk 为 android 编译 ffmpeg。操作系统:ubuntu 13.10。我关注了this教程。但是当我运行 build_android.sh 它给了我以下错误-

sujith@Vaio:~$ cd /home/sujith/ndk9d/sources/ffmpeg
sujith@Vaio:~/ndk9d/sources/ffmpeg$ sudo chmod +x build_android.sh
[sudo] password for sujith:
sujith@Vaio:~/ndk9d/sources/ffmpeg$ ./build_android.sh
/home/sujith/sujith/ndk9d/toolchains/arm-linux-androideabi-4.8/prebuilt/linux- x86_64/bin/arm-linux-androideabi-gcc 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 "config.log" produced by configure as this will help
solving the problem.
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.
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.

这是我的 build_android.sh

#!/bin/bash
NDK=$HOME/sujith/ndk9d
SYSROOT=$NDK/platforms/android-9/arch-arm/
TOOLCHAIN=$NDK/toolchains/arm-linux-androideabi-4.8/prebuilt/linux-x86_64
function build_one
{
./configure \
--prefix=$PREFIX \
--enable-shared \
--disable-static \
--disable-doc \
--disable-ffmpeg \
--disable-ffplay \
--disable-ffprobe \
--disable-ffserver \
--disable-avdevice \
--disable-doc \
--disable-symver \
--cross-prefix=$TOOLCHAIN/bin/arm-linux-androideabi- \
--target-os=linux \
--arch=arm \
--enable-cross-compile \
--sysroot=$SYSROOT \
--extra-cflags="-Os -fpic $ADDI_CFLAGS" \
--extra-ldflags="$ADDI_LDFLAGS" \
$ADDITIONAL_CONFIGURE_FLAG
make clean
make
make install
}
CPU=arm
PREFIX=$(pwd)/android/$CPU
ADDI_CFLAGS="-marm"
build_one

我的 build_android.sh 位于 ffmpeg 源代码根目录中。如何解决这个问题?请帮助我..

最佳答案

看起来,NDK=$HOME/sujith/ndk9d 是错误的。它应该,可能,阅读

NDK=$HOME/ndk9d

关于android - FFMPEG android编译错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22433205/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com