3 # ffmpeg configure script (c) 2000, 2001, 2002 Fabrice Bellard
5 # set temporary file name
6 if test ! -z "$TMPDIR" ; then
8 elif test ! -z "$TEMPDIR" ; then
14 TMPC="${TMPDIR1}/ffmpeg-conf-${RANDOM}-$$-${RANDOM}.c"
15 TMPO="${TMPDIR1}/ffmpeg-conf-${RANDOM}-$$-${RANDOM}.o"
16 TMPE="${TMPDIR1}/ffmpeg-conf-${RANDOM}-$$-${RANDOM}"
17 TMPS="${TMPDIR1}/ffmpeg-conf-${RANDOM}-$$-${RANDOM}.S"
18 TMPH="${TMPDIR1}/ffmpeg-conf-${RANDOM}-$$-${RANDOM}.h"
33 i386|i486|i586|i686|i86pc|BePC)
42 "Power Macintosh"|ppc)
86 LDFLAGS=-Wl,--warn-common
100 prefix="/boot/home/config"
101 # helps building libavcodec
102 CFLAGS="-O3 -DPIC -fomit-frame-pointer"
103 # 3 gcc releases known for BeOS, each with ugly bugs
104 gcc_version="$($cc -v 2>&1 | grep version | cut -d ' ' -f3-)"
105 case "$gcc_version" in
106 2.9-beos-991026*|2.9-beos-000224*) echo "R5/GG gcc"
109 *20010315*) echo "BeBits gcc"
110 CFLAGS="$CFLAGS -fno-expensive-optimizations"
114 # disable linux things
120 # no need for libm, but the inet stuff
122 if (echo $BEINCLUDES|grep 'headers/be/bone' >/dev/null); then
123 extralibs="-lbind -lsocket"
137 extralibs="$extralibs -lsocket -lnsl"
144 LDFLAGS="$LDFLAGS -export-dynamic"
150 extralibs="-lpoll -lgnugetopt -lm"
158 SHFLAGS="-dynamiclib"
163 FFSLDFLAGS=-Wl,-bind_at_load
164 gcc_version="$($cc -v 2>&1 | grep version | cut -d ' ' -f4-)"
165 case "$gcc_version" in
167 CFLAGS="-no-cpp-precomp -pipe -O3 -fomit-frame-pointer"
170 CFLAGS="-no-cpp-precomp -pipe -O3 -fomit-frame-pointer -mdynamic-no-pic"
188 test -f /usr/include/inttypes.h || \
189 test -f /usr/local/include/inttypes.h || \
190 echo "Missing inttypes.h, please copy cygwin_inttypes.h to" \
191 "/usr/include/inttypes.h !!!"
194 LDFLAGS="$LDFLAGS -rdynamic"
199 ranlib="echo ignoring ranlib"
200 strip="echo ignoring strip"
202 LDFLAGS="-Zomf -Zstack 16384 -s"
220 # From mplayer configure. We need TARGET_OS available
221 # to the Makefile, so it can distinguish between flavors
222 # of AltiVec on PowerPC
223 TARGET_OS=`( uname -s ) 2>&1`
225 Linux|FreeBSD|NetBSD|BSD/OS|OpenBSD|SunOS|QNX|Darwin|GNU)
233 [cC][yY][gG][wW][iI][nN]*)
237 TARGET_OS="$TARGET_OS-UNKNOWN"
242 # XXX: we assume an absolute path is given when launching configure,
243 # except in './configure' case.
244 source_path="`echo $0 | sed -e 's#/configure##'`"
245 source_path_used="yes"
246 if test -z "$source_path" -o "$source_path" = "." ; then
248 source_path_used="no"
253 --prefix=*) prefix=`echo $opt | cut -d '=' -f 2`
255 --source-path=*) source_path=`echo $opt | cut -d '=' -f 2`
257 --cross-prefix=*) cross_prefix=`echo $opt | cut -d '=' -f 2`
259 --cc=*) cc=`echo $opt | cut -d '=' -f 2`
261 --make=*) make=`echo $opt | cut -d '=' -f 2`
263 --extra-cflags=*) CFLAGS="${opt#--extra-cflags=}"
265 --extra-ldflags=*) LDFLAGS=${opt#--extra-ldflags=}
267 --extra-libs=*) extralibs=${opt#--extra-libs=}
269 --cpu=*) cpu=`echo $opt | cut -d '=' -f 2`
271 --disable-mmx) mmx="no"
273 --disable-altivec) altivec="no"
275 --enable-gprof) gprof="yes"
277 --disable-v4l) v4l="no"
279 --disable-audio-oss) audio_oss="no"
281 --disable-audio-beos) audio_beos="no"
283 --disable-dv1394) dv1394="no"
285 --disable-network) network="no"
287 --disable-zlib) zlib="no"
289 --disable-a52) a52="no"
291 --enable-a52bin) a52bin="yes" ; extralibs="$ldl $extralibs"
293 --disable-pp) pp="no"
295 --enable-shared-pp) shared_pp="yes"
297 --enable-mp3lame) mp3lame="yes"
299 --enable-vorbis) vorbis="yes"
301 --enable-faad) faad="yes"
303 --enable-faadbin) faadbin="yes"
305 --disable-vhook) vhook="no"
307 --disable-simple_idct) simpleidct="no"
309 --enable-win32) win32="yes"
311 --enable-mingw32) mingw32="yes"
313 --enable-shared) lshared="yes"
315 --disable-mpegaudio-hp) mpegaudio_hp="no"
317 --disable-ffserver) ffserver="no"
319 --disable-risky) risky="no"
321 --enable-small) small="yes"
323 --enable-amr_nb) amr_nb="yes"
329 if test $mmx = "default"; then
330 if test $cpu = "x86"; then
337 # Can only do AltiVec on PowerPC
338 if test $altivec = "default"; then
339 if test $cpu = "powerpc"; then
346 # See does our compiler support Motorola AltiVec C API
347 if test $altivec = "yes"; then
350 vector signed int v1, v2, v3;
355 $cc -o $TMPE $TMPC -faltivec 2> /dev/null || altivec="no"
358 # Can only do mmi on mips
359 if test $mmi = "default"; then
360 if test $cpu = "mips"; then
367 # See does our compiler support mmi
368 if test $mmi = "yes"; then
371 __asm__ ("lq \$2, 0(\$2)");
375 $cc -o $TMPE $TMPC 2> /dev/null || mmi="no"
378 # Checking for CFLAGS
379 if test -z "$CFLAGS"; then
383 if test "$win32" = "yes" ; then
384 cross_prefix="i386-mingw32msvc-"
391 if test "$mingw32" = "yes" ; then
399 cc="${cross_prefix}${cc}"
400 ar="${cross_prefix}${ar}"
401 ranlib="${cross_prefix}${ranlib}"
402 strip="${cross_prefix}${strip}"
404 if test -z "$cross_prefix" ; then
407 # big/little endian test
409 #include <inttypes.h>
410 int main(int argc, char ** argv){
411 volatile uint32_t i=0x01234567;
412 return (*((uint8_t*)(&i))) == 0x67;
416 if $cc -o $TMPE $TMPC 2>/dev/null ; then
417 $TMPE && bigendian="yes"
419 echo big/little test failed
424 # if cross compiling, cannot launch a program, so make a static guess
425 if test "$cpu" = "powerpc" -o "$cpu" = "mips" ; then
432 # check availability of some header files
436 int main( void ) { return 0; }
441 if $cc -o $TMPE $TMPC 2> /dev/null ; then
444 # check for memalign - atmos
449 string = memalign(64, sizeof(char));
453 $cc -o $TMPE $TMPC 2> /dev/null || _memalign=no
459 int main( void ) { return *strptime("", "", 0); }
463 if $cc -o $TMPE $TMPC 2> /dev/null ; then
467 if test "$zlib" = "yes"; then
468 # check for zlib - mmu_man
472 if (zlibVersion() != ZLIB_VERSION)
473 puts("zlib version differs !!!");
478 $cc -o $TMPE $TMPC -lz 2> /dev/null || zlib="no"
479 # $TMPE 2> /dev/null > /dev/null || zlib="no"
480 # XXX: more tests needed - runtime test
482 if test "$zlib" = "yes"; then
483 extralibs="$extralibs -lz"
486 # test for lrintf in math.h
488 #define _ISOC9X_SOURCE 1
490 int main( void ) { return (lrintf(3.999f) > 0)?0:1; }
494 if $cc $extralibs -o $TMPE $TMPC 2> /dev/null ; then
496 $TMPE 2> /dev/null > /dev/null || have_lrintf="no"
500 for restrict_keyword in restrict __restrict__ __restrict; do
501 echo "void foo(char * $restrict_keyword p);" > $TMPC
502 if $cc -c -o $TMPO $TMPC 2> /dev/null; then
503 _restrict=$restrict_keyword
508 # test gcc version to see if vector builtins can be used
509 # currently only used on i386 for MMX builtins
512 #if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 2)
515 #error no vector builtins
521 if $cc -o $TMPO $TMPC 2> /dev/null ; then
525 # dlopen/dlfcn.h probing
529 int main( void ) { return (int) dlopen("foo", 0); }
534 if $cc -o $TMPE $TMPC -ldl 2> /dev/null ; then
539 if $cc -o $TMPE $TMPC 2> /dev/null ; then
546 int main( void ) { return (int) dlopen("foo", 0); }
549 if $cc -o $TMPE $TMPC -ldl 2> /dev/null ; then
553 if $cc -o $TMPE $TMPC 2> /dev/null ; then
558 if test "$vhook" = "default" ; then
563 #include <X11/Xlib.h>
565 int main( void ) { return (int) imlib_load_font("foo"); }
569 if $cc -o $TMPE $TMPC -lImlib2 2> /dev/null ; then
574 #include <ft2build.h>
575 int main( void ) { return (int) FT_Init_FreeType(0); }
579 if test "x$targetos" != "xBeOS" && test "$os2" != "yes"; then
580 if test "`which freetype-config`" != ""; then
581 if $cc -o $TMPE $TMPC `freetype-config --cflags` `freetype-config --libs` 2> /dev/null ; then
587 if test "$small" = "yes"; then
588 # CFLAGS=${CFLAGS//-O3/-Os}
592 if test x"$1" = x"-h" -o x"$1" = x"--help" ; then
595 Usage: configure [options]
596 Options: [defaults in brackets after descriptions]
599 echo "Standard options:"
600 echo " --help print this message"
601 echo " --prefix=PREFIX install in PREFIX [$prefix]"
602 echo " --enable-mp3lame enable mp3 encoding via libmp3lame [default=no]"
603 echo " --enable-vorbis enable vorbis support via libvorbisenc [default=no]"
604 echo " --enable-faad enable faad support via libfaad [default=no]"
605 echo " --enable-faadbin build faad support with runtime linking [default=no]"
606 echo " --enable-win32 enable win32 cross compile"
607 echo " --enable-mingw32 enable mingw32 native windows compile"
608 echo " --disable-a52 disable GPL'ed A52 support [default=no]"
609 echo " --enable-a52bin open liba52.so.0 at runtime [default=no]"
610 echo " --disable-pp disable GPL'ed post processing support [default=no]"
611 echo " --enable-shared-pp use libpostproc.so [default=no]"
612 echo " --enable-shared build shared libraries [default=no]"
613 echo " --enable-amr_nb enable amr_nb audio codec"
615 echo "Advanced options (experts only):"
616 echo " --source-path=PATH path of source code [$source_path]"
617 echo " --cross-prefix=PREFIX use PREFIX for compile tools [$cross_prefix]"
618 echo " --cc=CC use C compiler CC [$cc]"
619 echo " --make=MAKE use specified make [$make]"
620 echo " --extra-cflags=ECFLAGS add ECFLAGS to CFLAGS [$CFLAGS]"
621 echo " --extra-ldflags=ELDFLAGS add ELDFLAGS to LDFLAGS [$LDFLAGS]"
622 echo " --extra-libs=ELIBS add ELIBS [$ELIBS]"
623 echo " --cpu=CPU force cpu to CPU [$cpu]"
624 echo " --disable-mmx disable mmx usage"
625 echo " --disable-altivec disable AltiVec usage"
626 echo " --disable-audio-oss disable OSS audio support [default=no]"
627 echo " --disable-audio-beos disable BeOS audio support [default=no]"
628 echo " --disable-v4l disable video4linux grabbing [default=no]"
629 echo " --disable-dv1394 disable DV1394 grabbing [default=no]"
630 echo " --disable-network disable network support [default=no]"
631 echo " --disable-zlib disable zlib [default=no]"
632 echo " --disable-simple_idct disable simple IDCT routines [default=no]"
633 echo " --disable-vhook disable video hooking support"
634 echo " --enable-gprof enable profiling with gprof [$gprof]"
635 echo " --disable-mpegaudio-hp faster (but less accurate)"
636 echo " mpegaudio decoding [default=no]"
637 echo " --disable-ffserver disable ffserver build"
638 echo " --disable-risky disables patent encumbered codecs"
639 echo " --enable-small optimize for size instead of speed"
641 echo "NOTE: The object files are build at the place where configure is launched"
645 echo "Install prefix $prefix"
646 echo "Source path $source_path"
647 echo "C compiler $cc"
650 echo "Big Endian $bigendian"
651 if test $cpu = "x86"; then
652 echo "MMX enabled $mmx"
653 echo "Vector Builtins $builtin_vector"
655 if test $cpu = "mips"; then
656 echo "MMI enabled $mmi"
658 if test $cpu = "powerpc"; then
659 echo "AltiVec enabled $altivec"
661 echo "gprof enabled $gprof"
662 echo "zlib enabled $zlib"
663 echo "mp3lame enabled $mp3lame"
664 echo "vorbis enabled $vorbis"
665 echo "faad enabled $faad"
666 echo "faadbin enabled $faadbin"
667 echo "a52 support $a52"
668 echo "a52 dlopened $a52bin"
669 echo "pp support $pp"
670 echo "shared pp $shared_pp"
671 echo "Video hooking $vhook"
672 echo "risky / patent encumbered codecs $risky"
673 echo "optimize for size $small"
675 if test "$vhook" = "yes" ; then
676 echo "Imlib2 support $imlib2"
677 echo "freetype support $freetype2"
679 echo "AMR-NB support" $amr_nb
681 echo "Creating config.mak and config.h"
683 echo "# Automatically generated by configure - do not modify" > config.mak
684 echo "/* Automatically generated by configure - do not modify */" > $TMPH
686 echo "prefix=$prefix" >> config.mak
687 echo "MAKE=$make" >> config.mak
688 echo "CC=$cc" >> config.mak
689 echo "AR=$ar" >> config.mak
690 echo "RANLIB=$ranlib" >> config.mak
691 echo "STRIP=$strip" >> config.mak
692 echo "OPTFLAGS=$CFLAGS" >> config.mak
693 echo "LDFLAGS=$LDFLAGS" >> config.mak
694 echo "FFSLDFLAGS=$FFSLDFLAGS" >> config.mak
695 echo "SHFLAGS=$SHFLAGS" >> config.mak
696 echo "LIBPREF=$LIBPREF" >> config.mak
697 echo "LIBSUF=$LIBSUF" >> config.mak
698 echo "SLIBPREF=$SLIBPREF" >> config.mak
699 echo "SLIBSUF=$SLIBSUF" >> config.mak
700 echo "TARGET_OS=$TARGET_OS" >> config.mak
701 if test "$cpu" = "x86" ; then
702 echo "TARGET_ARCH_X86=yes" >> config.mak
703 echo "#define ARCH_X86 1" >> $TMPH
704 elif test "$cpu" = "armv4l" ; then
705 echo "TARGET_ARCH_ARMV4L=yes" >> config.mak
706 echo "#define ARCH_ARMV4L 1" >> $TMPH
707 elif test "$cpu" = "alpha" ; then
708 echo "TARGET_ARCH_ALPHA=yes" >> config.mak
709 echo "#define ARCH_ALPHA 1" >> $TMPH
710 elif test "$cpu" = "sparc64" ; then
711 echo "TARGET_ARCH_SPARC64=yes" >> config.mak
712 echo "#define ARCH_SPARC64 1" >> $TMPH
713 elif test "$cpu" = "powerpc" ; then
714 echo "TARGET_ARCH_POWERPC=yes" >> config.mak
715 echo "#define ARCH_POWERPC 1" >> $TMPH
716 echo "// Enable the next line to get PowerPC performance report" >> $TMPH
717 echo "// #define POWERPC_TBL_PERFORMANCE_REPORT 1" >> $TMPH
718 echo "// Enable the next line to use PMC registers instead of TBL" >> $TMPH
719 echo "// #define POWERPC_PERF_USE_PMC 1" >> $TMPH
720 elif test "$cpu" = "mips" ; then
721 echo "TARGET_ARCH_MIPS=yes" >> config.mak
722 echo "#define ARCH_MIPS 1" >> $TMPH
724 if test "$bigendian" = "yes" ; then
725 echo "WORDS_BIGENDIAN=yes" >> config.mak
726 echo "#define WORDS_BIGENDIAN 1" >> $TMPH
728 if test "$mmx" = "yes" ; then
729 echo "TARGET_MMX=yes" >> config.mak
730 echo "#define HAVE_MMX 1" >> $TMPH
732 if test "$builtin_vector" = "yes" ; then
733 echo "TARGET_BUILTIN_VECTOR=yes" >> config.mak
734 echo "#define HAVE_BUILTIN_VECTOR 1" >> $TMPH
736 if test "$mmi" = "yes" ; then
737 echo "TARGET_MMI=yes" >> config.mak
738 echo "#define HAVE_MMI 1" >> $TMPH
740 if test "$altivec" = "yes" ; then
741 echo "TARGET_ALTIVEC=yes" >> config.mak
742 echo "#define HAVE_ALTIVEC 1" >> $TMPH
743 echo "// Enable the next line to use the reference C code instead of AltiVec" >> $TMPH
744 echo "// #define ALTIVEC_USE_REFERENCE_C_CODE 1" >> $TMPH
746 if test "$gprof" = "yes" ; then
747 echo "TARGET_GPROF=yes" >> config.mak
748 echo "#define HAVE_GPROF 1" >> $TMPH
750 if test "$strptime" = "yes" ; then
751 echo "#define HAVE_STRPTIME 1" >> $TMPH
753 echo "BUILD_STRPTIME=yes" >> config.mak
755 if test "$imlib2" = "yes" ; then
756 echo "HAVE_IMLIB2=yes" >> config.mak
758 if test "$freetype2" = "yes" ; then
759 echo "HAVE_FREETYPE2=yes" >> config.mak
761 if test "$have_lrintf" = "yes" ; then
762 echo "#define HAVE_LRINTF 1" >> $TMPH
764 if test "$vhook" = "yes" ; then
765 echo "BUILD_VHOOK=yes" >> config.mak
766 echo "#define HAVE_VHOOK 1" >> $TMPH
767 extralibs="$extralibs $ldl"
769 if test "$lshared" = "yes" ; then
770 echo "BUILD_SHARED=yes" >> config.mak
771 echo "PIC=-fPIC" >> config.mak
773 echo "EXTRALIBS=$extralibs" >> config.mak
774 echo "VERSION=`head $source_path/VERSION`" >>config.mak
776 # if you do not want to use encoders, disable that.
777 echo "#define CONFIG_ENCODERS 1" >> $TMPH
778 echo "CONFIG_ENCODERS=yes" >> config.mak
780 # if you do not want to use decoders, disable that.
781 echo "#define CONFIG_DECODERS 1" >> $TMPH
782 echo "CONFIG_DECODERS=yes" >> config.mak
785 if test "$a52" = "yes" ; then
786 echo "#define CONFIG_AC3 1" >> $TMPH
787 echo "CONFIG_AC3=yes" >> config.mak
789 if test "$a52bin" = "yes" ; then
790 echo "#define CONFIG_A52BIN 1" >> $TMPH
791 echo "CONFIG_A52BIN=yes" >> config.mak
796 if test "$pp" = "yes" ; then
797 echo "#define CONFIG_PP 1" >> $TMPH
798 echo "CONFIG_PP=yes" >> config.mak
800 if test "$shared_pp" = "yes" ; then
801 echo "#define SHARED_PP 1" >> $TMPH
802 echo "SHARED_PP=yes" >> config.mak
806 # mpeg audio high precision mode
807 if test "$mpegaudio_hp" = "yes" ; then
808 echo "#define CONFIG_MPEGAUDIO_HP 1" >> $TMPH
811 if test "$v4l" = "yes" ; then
812 echo "#define CONFIG_VIDEO4LINUX 1" >> $TMPH
813 echo "CONFIG_VIDEO4LINUX=yes" >> config.mak
816 if test "$dv1394" = "yes" ; then
817 echo "#define CONFIG_DV1394 1" >> $TMPH
818 echo "CONFIG_DV1394=yes" >> config.mak
821 if test "$dlopen" = "yes" ; then
822 echo "#define CONFIG_HAVE_DLOPEN 1" >> $TMPH
825 if test "$dlfcn" = "yes" ; then
826 echo "#define CONFIG_HAVE_DLFCN 1" >> $TMPH
829 if test "$audio_oss" = "yes" ; then
830 echo "#define CONFIG_AUDIO_OSS 1" >> $TMPH
831 echo "CONFIG_AUDIO_OSS=yes" >> config.mak
834 if test "$audio_beos" = "yes" ; then
835 echo "#define CONFIG_AUDIO_BEOS 1" >> $TMPH
836 echo "CONFIG_AUDIO_BEOS=yes" >> config.mak
839 if test "$network" = "yes" ; then
840 echo "#define CONFIG_NETWORK 1" >> $TMPH
841 echo "CONFIG_NETWORK=yes" >> config.mak
844 if test "$zlib" = "yes" ; then
845 echo "#define CONFIG_ZLIB 1" >> $TMPH
846 echo "CONFIG_ZLIB=yes" >> config.mak
849 if test "$mp3lame" = "yes" ; then
850 echo "#define CONFIG_MP3LAME 1" >> $TMPH
851 echo "CONFIG_MP3LAME=yes" >> config.mak
854 if test "$vorbis" = "yes" ; then
855 echo "#define CONFIG_VORBIS 1" >> $TMPH
856 echo "CONFIG_VORBIS=yes" >> config.mak
859 if test "$faad" = "yes" ; then
860 echo "#define CONFIG_FAAD 1" >> $TMPH
861 echo "CONFIG_FAAD=yes" >> config.mak
864 if test "$faadbin" = "yes" ; then
865 echo "#define CONFIG_FAADBIN 1" >> $TMPH
866 echo "CONFIG_FAADBIN=yes" >> config.mak
869 if test "$win32" = "yes" ; then
870 echo "#define CONFIG_WIN32 1" >> $TMPH
871 echo "CONFIG_WIN32=yes" >> config.mak
874 if test "$mingw32" = "yes" ; then
875 echo "#define CONFIG_WIN32 1" >> $TMPH
876 echo "CONFIG_WIN32=yes" >> config.mak
877 echo "#define __MINGW32__ 1" >> $TMPH
878 echo "__MINGW32__=1" >> config.mak
881 if test "$cygwin" = "yes" ; then
882 # setup correct exesuffix
883 echo "CONFIG_WIN32=yes" >> config.mak
886 if test "$os2" = "yes" ; then
887 echo "#define CONFIG_OS2 1" >> $TMPH
888 echo "CONFIG_OS2=yes" >> config.mak
891 if test "$TARGET_OS" = "SunOS" ; then
892 echo "#define CONFIG_SUNOS 1" >> $TMPH
895 if test "$darwin" = "yes"; then
896 echo "#define CONFIG_DARWIN 1" >> $TMPH
897 echo "CONFIG_DARWIN=yes" >> config.mak
900 if test "$_malloc_h" = "yes" ; then
901 echo "#define HAVE_MALLOC_H 1" >> $TMPH
903 echo "#undef HAVE_MALLOC_H" >> $TMPH
906 if test "$_memalign" = "yes" ; then
907 echo "#define HAVE_MEMALIGN 1" >> $TMPH
909 echo "#undef HAVE_MEMALIGN" >> $TMPH
912 if test "$netserver" = "yes" ; then
913 echo "#define CONFIG_BEOS_NETSERVER 1" >> $TMPH
914 echo "CONFIG_BEOS_NETSERVER=yes" >> config.mak
917 if test "$need_inet_aton" = "yes" ; then
918 echo "NEED_INET_ATON=yes" >> config.mak
921 if test "$simpleidct" = "yes" ; then
922 echo "#define SIMPLE_IDCT 1" >> $TMPH
925 if test "$ffserver" = "yes" ; then
926 echo "#define CONFIG_FFSERVER 1" >> $TMPH
927 echo "CONFIG_FFSERVER=yes" >> config.mak
930 if test "$risky" = "yes" ; then
931 echo "#define CONFIG_RISKY 1" >> $TMPH
932 echo "CONFIG_RISKY=yes" >> config.mak
935 echo "#define restrict $_restrict" >> $TMPH
937 # build tree in object directory if source path is different from current one
938 if test "$source_path_used" = "yes" ; then
939 DIRS="libavformat libavcodec libavcodec/alpha libavcodec/armv4l libavcodec/i386 \
940 libavcodec/ppc libavcodec/liba52 libavcodec/mlib libavcodec/libpostproc tests vhook"
941 FILES="Makefile libavformat/Makefile libavcodec/Makefile libavcodec/libpostproc/Makefile tests/Makefile vhook/Makefile"
942 for dir in $DIRS ; do
946 ln -sf $source_path/$f $f
949 echo "SRC_PATH=$source_path" >> config.mak
951 if test "$amr_nb" = "yes" ; then
952 echo "#define AMR_NB 1" >> $TMPH
953 echo "AMR_NB=yes" >> config.mak
955 echo "AMR NB NOTICE! Make sure you have downloaded TS26.073 from "
956 echo "http://www.3gpp.org/ftp/Specs/latest/Rel-5/26_series/26073-510.zip"
957 echo "and extracted src to libavcodec/amr"
958 echo "You must also add -DMMS_IO to CFLAGS in libavcodec/amr/makefile."
962 diff $TMPH config.h >/dev/null 2>&1
963 if test $? -ne 0 ; then
966 echo "config.h is unchanged"
969 rm -f $TMPO $TMPC $TMPE $TMPS $TMPH