Mercurial > mplayer.hg
changeset 34044:563038925442
Set up HAVE_VFP_ARGS and CONFIG_THUMB correctly to fix compilation for ARM.
author | reimar |
---|---|
date | Sun, 25 Sep 2011 13:28:25 +0000 |
parents | 94106ed224b3 |
children | 4831a5fa1d78 |
files | configure |
diffstat | 1 files changed, 38 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/configure Sun Sep 25 09:58:58 2011 +0000 +++ b/configure Sun Sep 25 13:28:25 2011 +0000 @@ -89,6 +89,15 @@ compile_check $TMPCPP $@ -lstdc++ } +cpp_condition_check() { + cat > $TMPC << EOF +#if !($1) +#error condition not true: $1 +#endif +EOF + compile_check $TMPC $@ +} + cflag_check() { cat > $TMPC << EOF int main(void) { return 0; } @@ -560,6 +569,7 @@ --enable-armvfp enable ARM VFP (ARM) [autodetect] --enable-vfpv3 enable ARM VFPV3 (ARM) [autodetect] --enable-neon enable NEON (ARM) [autodetect] + --enable-thumb enable THUMB (ARM) [autodetect] --enable-iwmmxt enable iWMMXt (ARM) [autodetect] --disable-fastmemcpy disable 3DNow!/SSE/MMX optimized memcpy [enable] --enable-hardcoded-tables put tables in binary instead of calculating them at startup [disable] @@ -612,6 +622,7 @@ _armvfp=auto vfpv3=auto neon=auto +armthumb=auto _iwmmxt=auto _mtrr=auto _altivec=auto @@ -1409,6 +1420,8 @@ --disable-vfpv3) vfpv3=no ;; --enable-neon) neon=yes ;; --disable-neon) neon=no ;; + --enable-thumb) armthumb=yes ;; + --disable-thumb) armthumb=no ;; --enable-iwmmxt) _iwmmxt=yes ;; --disable-iwmmxt) _iwmmxt=no ;; --enable-mmx) _mmx=yes ;; @@ -2865,6 +2878,16 @@ fi echores "$vfpv3" + echocheck "softfloat ABI" + softfloat=yes + cpp_condition_check 'defined(__ARM_PCS_VFP) || (!defined(__ARM_PCS) && !defined(__SOFTFP__))' && softfloat=no + if test $softfloat = "yes" ; then + def_vfp_args='#define HAVE_VFP_ARGS 0' + else + def_vfp_args='#define HAVE_VFP_ARGS 1' + fi + echores "$softfloat" + echocheck "ARM NEON" if test $neon = "auto" ; then neon=no @@ -2872,6 +2895,19 @@ fi echores "$neon" + echocheck "ARM THUMB" + if test $armthumb = "auto" ; then + armthumb=no + fi + if test $armthumb = "yes" ; then + extra_cflags="$extra_cflags -mthumb" + def_armthumb='#define CONFIG_THUMB 1' + else + extra_cflags="$extra_cflags -marm" + def_armthumb='#define CONFIG_THUMB 0' + fi + echores "$armthumb" + echocheck "iWMMXt (Intel XScale SIMD instructions)" if test $_iwmmxt = "auto" ; then _iwmmxt=no @@ -8280,6 +8316,8 @@ $(ff_config_enable "$arch_all" "$arch" "#" "ARCH") $(ff_config_enable "$subarch_all" "$subarch" "#" "ARCH") $(ff_config_enable "$cpuexts_all" "$cpuexts" "#" "HAVE") +$def_armthumb +$def_vfp_args /* Blu-ray/DVD/VCD/CD */ @@ -8579,7 +8617,6 @@ #define HAVE_SYMVER_ASM_LABEL 0 #define HAVE_SYMVER_GNU_ASM 0 #define HAVE_SYS_SELECT_H 0 -#define HAVE_VFP_ARGS 1 #define HAVE_VIRTUALALLOC 0 /* Some FFmpeg codecs depend on these. Enable them unconditionally for now. */