开发者

Enable armv6 FFmpeg crashed under Android NDK

I compile the FFmpeg under the armv5, it can work well on Android NDK r5, but I compile the FFmpeg under the armv6, it can success, but when I call the function av_new_stream, it is crashed, and it is crashed on the libavutil.c/rational.c:

if(num<=max && den<=max){
    a1= (AVRatio开发者_如何学编程nal){num, den};
    den=0;
}

Dose anyone encounter this problem?

The LOCAL_FLAGS
include $(CLEAR_VARS)
LOCAL_ARM_MODE := arm
LOCAL_MODULE    := ffmpeg
LOCAL_CFLAGS := -DHAVE_AV_CONFIG_H  -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DPIC  -std=gnu99 -march=armv6

Is there something error here?


If you are running your code under the emulator, this is perfectly normal. The emulator only supports ARMv5. Not ARMv6 and certainly not ARMv7.

Update: This is not true anymore with the newer versions of the emulator. It fully supports ARMv7.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜