交叉编译ffmpeg(arm32)
准备工作:
如果要启用x264,请看前一篇文章https://vbox.top/2647.html
步骤如下:
➜ git clone https://git.ffmpeg.org/ffmpeg.git ffmpeg
➜ cd ffmpeg
➜ mkdir -p build/arm32 && cd build/arm32
➜ ../../configure --enable-cross-compile --cross-prefix=arm-linux-gnueabihf- --arch=arm-linux --target-os=linux --extra-ldflags=-L/opt/arm-libs/arm32/lib --enable-libx264 --enable-shared --disable-static --enable-swscale --enable-pthreads --enable-nonfree --enable-gpl --cc=arm-linux-gnueabihf-gcc --cxx=arm-linux-gnueabihf-g++ --prefix=/opt/arm-libs/arm32/lib
➜ make clean && make -j4
➜ sudo make install