Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to build FFMPEG for all architecture of android device?

I am trying to build ffmpeg for android in windows 8.1 using CYGWIN

I am following This question & How to compile FFMPEG under Cygwin . I succsessfully compile but it is not generate FFMPEG.so but it generate ffmpeg.exe file

I don't want any prebuild ffmpeg library . I want to build it for my requirement.

I perform this steps In CYGWIN BASE

  1. git clone git://source.ffmpeg.org/ffmpeg.git ffmpeg
  2. dos2unix configure
  3. dos2unix build_ffmpeg.sh
  4. make distclean
  5. ./configure –enable-static –disable-shared
  6. make
  7. make install

my build_ffmpeg.sh is

#!/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-cross-compile \ --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 clean make -j5 make -j5 install

popd

My LOG file is here

My question is how to build ffmpeg for all architecture of android device?

like image 742
prakash ubhadiya Avatar asked Nov 05 '16 06:11

prakash ubhadiya


1 Answers

Have a look at these links

  • https://github.com/hiteshsondhi88/ffmpeg-android
  • https://github.com/cine-io/android-ffmpeg-with-rtmp
  • https://sourceforge.net/projects/ffmpeg4android/
  • http://www.roman10.net/2011/07/17/how-to-build-ffmpeg-for-android/

You might find out that you've missed something!

like image 138
Mohammad Abbas Avatar answered Oct 13 '22 00:10

Mohammad Abbas