首页 文章

如何为Android设备的所有架构构建FFMPEG?

提问于
浏览
7

我正在尝试使用CYGWIN在Windows 8.1中为android构建ffmpeg

我正在关注这个questionHow to compile FFMPEG under Cygwin . 我succsessfully编译,但它不生成 FFMPEG.so 但它生成ffmpeg.exe文件

我不想要任何预建ffmpeg library . 我想根据我的要求构建它 .

I perform this steps In CYGWIN BASE

  • git clone git://source.ffmpeg.org/ffmpeg.git ffmpeg

  • dos2unix配置

  • dos2unix build_ffmpeg.sh

  • make distclean

  • ./configure-enable-static -disable-shared

  • 制作

  • make install

build_ffmpeg.sh

#!/ bin / bash NDK = / cygdrive / e / android / sdk / ndk-bundle PLATFORM = $ NDK / platforms / android-24 / arch-arm TOOLCHAIN = $ NDK / toolchains / arm-linux-androideabi-4.9 / prebuilt / windows CPU = arm PREFIX = $(pwd)/ android / $ CPU ADDI_CFLAGS =“ - marm”pushd ffmpeg #configure ./configure \ --target-os = android \ --prefix = $ PREFIX \ --enable-交叉编译\ --enable-runtime -cpudetect \ --disable-asm \ --arch = arm \ --cc = $ TOOLCHAIN / bin / arm-linux-androideabi-gcc \ --cross-prefix = $ TOOLCHAIN / bin / arm-linux-androideabi- \ --disable-stripping \ --nm = $ TOOLCHAIN / bin / arm-linux-androideabi-nm \ --sysroot = $ PLATFORM \ --disable-programs \ --disable-doc \ --enable-protocol = file \ --disable-avresample \ --enable-gpl \ --enable-version3 \ --enable-nonfree \ --disable-ffplay \ --disable-ffserver \ --disable-ffmpeg \ --disable-ffprobe \ --extra-cflags =“ - fPIC -DANDROID -D__thumb__ -mthumb -Wfatal-errors -Wno-deprecated $ ADDI_CFLAGS”\ --extra-libs =“ - lgcc”\ --extra-ldflags =“ - L $ PLATFORM / usr / lib -nostdlib -lc -lm -ldl -llog”#Make make cle make -j5 make -j5 install popd

我的LOG文件是here

我的问题是如何为Android设备的所有架构构建ffmpeg?

2 回答

相关问题