4
我想在OpenH264中爲不同的CPU架構構建.so文件。 OpenH264的建立.so文件爲OpenH264 android
README.md建議
add "ARCH=mips" or "ARCH=x86". To build for the older armeabi ABI (which has
armv5te as baseline), add "APP_ABI=armeabi" (ARCH=arm is implicit).
所以我解僱以下命令
對於x86
make os=android NDKROOT=/home/neosoft/android-ndk-r10d/ ARCH=x86 TARGET=android-12
我得到類似
/usr/bin/ld: cannot find crti.o: No such file or directory
/usr/bin/ld: cannot find -lpthread
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.8/libstdc++.so when searching for -lstdc++
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.8/libstdc++.a when searching for -lstdc++
/usr/bin/ld: cannot find -lstdc++
/usr/bin/ld: cannot find -lm
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.8/libgcc_s.so when searching for -lgcc_s
/usr/bin/ld: cannot find -lgcc_s
/usr/bin/ld: cannot find -lc
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.8/libgcc_s.so when searching for -lgcc_s
/usr/bin/ld: cannot find -lgcc_s
/usr/bin/ld: cannot find crtn.o: No such file or directory
collect2: error: ld returned 1 exit status
make: *** [libopenh264.so] Error 1
,當我嘗試至 與armeabi
make os=android NDKROOT=/home/neosoft/android-ndk-r10d/ ARCH=armeabi TARGET=android-12
構建它,我得到
cc -O3 -DHAVE_NEON -Wall -fno-strict-aliasing -fPIC -DLINUX -MMD -MP -Icodec/common/arm/ -march=armv7-a -mfpu=neon -Icodec/api/svc -Icodec/common/inc -c -o codec/common/arm/copy_mb_neon.o codec/common/arm/copy_mb_neon.S
cc: error: unrecognized command line option ‘-mfpu=neon’
make: *** [codec/common/arm/copy_mb_neon.o] Error 1
有人能指出我如何編譯這個LIB針對不同的CPU架構。
Thansk man ..你救了我的時間:D – RajibTheKing