Index: configure =================================================================== RCS file: /cvsroot/mplayer/main/configure,v retrieving revision 1.797 diff -u -r1.797 configure --- configure 27 Oct 2003 01:06:35 -0000 1.797 +++ configure 28 Oct 2003 14:43:39 -0000 @@ -201,11 +201,11 @@ --enable-tremor build with integer-only OggVorbis support [disabled] --enable-theora build with OggTheora support [autodetect] --enable-matroska build with Matroska support [autodetect] - --enable-faad build with FAAD2 (MP4/AAC) support [autodetect] + --enable-faad build with external FAAD2 (AAC) support [autodetect] + --disable-internal-faad disable internal FAAD2 (AAC) support [enabled] --disable-libdv disable libdv 0.9.5 en/decoding support [autodetect] --disable-mad disable libmad (MPEG audio) support [autodetect] --enable-xmms build with XMMS inputplugin support [disabled] - --enable-external-faad build with external libfaad [disabled] --enable-flac build with FLAC support [autodetect] --enable-external-flac build with external libFLAC [disable] @@ -1112,7 +1112,7 @@ _matroska=auto _tremor=no _faad=auto -_faad_local=yes +_faad_internal=yes _xmms=no _flac=auto _external_flac=auto @@ -1278,8 +1278,8 @@ --disable-matroska) _matroska=no ;; --enable-faad) _faad=yes ;; --disable-faad) _faad=no ;; - --enable-external-faad) _faad_local=no ;; - --disable-external-faad) _faad_local=yes ;; + --enable-internal-faad) _faad_internal=yes ;; + --disable-internal-faad) _faad_internal=no ;; --enable-xmms) _xmms=yes ;; --enable-flac) _flac=yes ;; --disable-flac) _flac=no ;; @@ -4414,12 +4414,32 @@ fi echores "$_matroska" -echocheck "faad2 (AAC) support" + + +echocheck "internal FAAD2 (AAC) support" +if test "$_faad_internal" = yes ; then _def_faad_internal="#undef USE_INTERNAL_FAAD" -if test "$_faad" = no ; then - echores "no (disabled)" + _inc_faad="-I`pwd`/libfaad2" + # the faad check needs a config.h file + if not test -f "config.h" ; then + > config.h + fi + # internal faad: check if our dear gcc is able to compile it... + echo "$_cc -c -O4 $_march $_mcpu -pipe -ffast-math -fomit-frame-pointer $CFLAGS $_inc_faad $_inc_extra `pwd`/libfaad2/cfft.c -o $TMPO" >> "$TMPLOG" + if ( $_cc -c -O4 $_march $_mcpu -pipe -ffast-math -fomit-frame-pointer $CFLAGS $_inc_faad $_inc_extra "`pwd`/libfaad2/cfft.c" -o "$TMPO" ) >> "$TMPLOG" 2>&1 ; then + echores "$_faad_internal" + _def_faad_internal="#define USE_INTERNAL_FAAD 1" + _faad=no + else + _faad_internal=no + echores "no (broken gcc)" + fi else -if test "$_faad_local" = no ; then + echores "no" +fi + +echocheck "external FAAD2 (AAC) support" +if test "$_faad" = auto ; then _ld_faad='-lfaad' # external faad: check if it's really faad2 :) if test "$_faad" = auto ; then @@ -4430,36 +4450,13 @@ EOF cc_check $_inc_faad $_ld_faad -lm && _faad=yes fi - echores "$_faad (external)" + echores "$_faad" else - _inc_faad="-I`pwd`/libfaad2" - _faad=yes - # the faad check needs a config.h file - if test -f "config.h" ; then - _rm_config_h=no - else - _rm_config_h=yes - echo "" > config.h - fi - # internal faad: check if our dear gcc is able to compile it... - echo "$_cc -c -O4 $_march $_mcpu -pipe -ffast-math -fomit-frame-pointer $CFLAGS $_inc_faad $_inc_extra `pwd`/libfaad2/cfft.c -o $TMPO" >> "$TMPLOG" - if ( $_cc -c -O4 $_march $_mcpu -pipe -ffast-math -fomit-frame-pointer $CFLAGS $_inc_faad $_inc_extra "`pwd`/libfaad2/cfft.c" -o "$TMPO" ) >> "$TMPLOG" 2>&1 ; then - echores "$_faad (internal)" - _def_faad_internal="#define USE_INTERNAL_FAAD 1" - else - _faad=no - _faad_local=no - echores "no (broken gcc)" - fi - # remove a temporarily config.h, which was needed for the faad compile check - if test "$_rm_config_h" = yes; then - rm config.h - fi -fi + echores "no" fi -if test "$_faad" = yes; then -echocheck "faad2 version" +if test "$_faad" = yes -o "$_faad_internal" = yes; then +echocheck "FAAD2 version" cat > $TMPC < #ifndef FAAD_MIN_STREAMSIZE @@ -4481,11 +4478,12 @@ echores "$_faad_version" else _faad=no + _faad_internal=no echores "failed to get version" fi fi -if test "$_faad" = yes ; then +if test "$_faad" = yes -o "$_faad_internal" = yes; then _def_faad='#define HAVE_FAAD 1' _codecmodules="faad2 $_codecmodules" else @@ -5786,7 +5784,7 @@ VORBIS_LIB = $_ld_vorbis $_ld_libdv THEORA_LIB = $_ld_theora FAAD_LIB = $_ld_faad -INTERNAL_FAAD = $_faad_local +INTERNAL_FAAD = $_faad_internal SMBSUPPORT_LIB = $_ld_smb XMMS_PLUGINS = $_xmms XMMS_LIB = $_xmms_lib