On Tue, Aug 20, 2013 at 11:51:51AM +0800, Chih-Wei Huang wrote:
Michael Niedermayer said:
Is it possible to merge it in the ffmpeg upstream?
i see lots of hardcoded config.mak/h files
Consider that new options could be added to configure and would then be missing from this, also a user might want to build with different codecs / (de)muxers than the ones hardcoded in these files
That's right. This is the easier way to create a compatible makefile for android build system. Considering the target (android) is well-known, there is no real benefit to configure codecs/(de)muxers dynamically.
it can make sense to disable code that is very rarely used to reduce the size of the resulting binary.
I also considered to generate the android config.* from configure script on the fly. However, the output config.mak of configure is not friendly to android build system. It exports some variables like CC, CFLAGS that will conflict with the android build system. (Note Android doesn't use sub-make -- all sub-makefiles are included in from the main makefile and all vars in sub-makefiles are exported)
If you can modify the output of configure, say, splitting it into two files to let ARCH_*, HAVE_*, CONFIG_* vars in one file and others in another file, that would be more friendly to android build system. Then I could generate the android config.* on the fly.
You should be able to change CFLAGS / CC in the "# OS specific" section of configure if they have incorrect values configure is using the set cc/cflags to test various things like compiler features so they should be set correctly. But if i misunderstand and theres a real need to omit fields from the config files that can be done as well or they could be placed under ifdef [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB Good people do not need laws to tell them to act responsibly, while bad people will find a way around the laws. -- Plato