fdk_aac版本:0.1.6魂迄,ndk版本:15,shell腳本如下:
NDK=/Users/admin/Desktop/xxx/e/ndks/android-ndk-r15c
SYSROOT=$NDK/platforms/android-14/arch-arm
TOOLCHAIN=$NDK/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64
export?PATH=$PATH:$TOOLCHAIN/bin:$SYSROOT/usr/include:
export?LDFLAGS="-L$SYSROOT/usr/lib?-L$TOOLCHAIN/arm-linux-androideabi/lib?-march=armv7-a"
export?CFLAGS="-I$SYSROOT/usr/include?-march=armv7-a?-mfloat-abi=softfp?-mfpu=vfp?-ffast-math?-O2"
export?CPPFLAGS="$CFLAGS"
export?CFLAGS="$CFLAGS"
export?CXXFLAGS="$CFLAGS"
export?LDFLAGS="$LDFLAGS"
export?AS=$TOOLCHAIN/bin/arm-linux-androideabi-as
export?LD=$TOOLCHAIN/bin/arm-linux-androideabi-ld
export?CXX="$TOOLCHAIN/bin/arm-linux-androideabi-g++?--sysroot=${SYSROOT}"
export?CC="$TOOLCHAIN/bin/arm-linux-androideabi-gcc?--sysroot=${SYSROOT}?-march=armv7-a"
export?NM=$TOOLCHAIN/bin/arm-linux-androideabi-nm
export?STRIP=$TOOLCHAIN/bin/arm-linux-androideabi-strip
export?RANLIB=$TOOLCHAIN/bin/arm-linux-androideabi-ranlib
export?AR=$TOOLCHAIN/bin/arm-linux-androideabi-ar
PREFIX=$(pwd)/armv7a
./configure?--host=armv7a?\
--disable-shared?\
--enable-static?\
--prefix=$PREFIX
make?clean
make?-j8
sudo?make?install