I have successfully compiled ffmpeg as a static library for my project with android-platform 19 which specified in Application.xml as below:
APP_PLATFORM := android-19
I test my project on a device(4.4),it runs well. But it will crash on 4.0 devices.
So I would like to changed the APP_PLATFORM to a lower version like:
APP_PLATFORM := android-17
But the ide comes out an error like this.
libavcodec/ffv1enc.c:631: error: undefined reference to 'log2'
And when I changed it to a more lower version:
APP_PLATFORM := android-8
More errors occured:
libavcodec/ffv1enc.c:631: error: undefined reference to 'log2'
libavutil/mem.c:94: error: undefined reference to 'posix_memalign'
I know the log2 reference is undefined because of missing libm, but as far as I see Android will automatic link to libm when building.http://mobilepearls.com/labs/native-android-api/ndk/docs/STABLE-APIS.html
So how can I keep compatibility when compiling ffmpeg in order to run my project well on lower version devices.