more config options

Originally committed as revision 586 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
Fabrice Bellard 2002-05-25 22:24:08 +00:00
parent 17048ca88f
commit 5cbcf02cf1
1 changed files with 46 additions and 23 deletions

69
configure vendored
View File

@ -1,6 +1,6 @@
#!/bin/sh #!/bin/sh
# #
# ffmpeg configure script (c) 2000, 2001, 2002 Gerard Lantau # ffmpeg configure script (c) 2000, 2001, 2002 Fabrice Bellard
# #
# set temporary file name # set temporary file name
if test ! -z "$TMPDIR" ; then if test ! -z "$TMPDIR" ; then
@ -40,8 +40,11 @@ case "$cpu" in
;; ;;
esac esac
gprof="no" gprof="no"
grab="yes" v4l="yes"
audio_oss="yes"
network="yes"
mp3lame="no" mp3lame="no"
a52="yes"
a52bin="no" a52bin="no"
win32="no" win32="no"
lshared="no" lshared="no"
@ -55,8 +58,8 @@ case $targetos in
BeOS) BeOS)
prefix="/boot/home/config" prefix="/boot/home/config"
# helps building libavcodec # helps building libavcodec
grab="no"
CFLAGS="-O2 -DPIC" CFLAGS="-O2 -DPIC"
v4l="no"
# no need for libm, but the inet stuff # no need for libm, but the inet stuff
# Check for BONE # Check for BONE
if (echo $BEINCLUDES|grep 'headers/be/bone' >/dev/null); then if (echo $BEINCLUDES|grep 'headers/be/bone' >/dev/null); then
@ -66,7 +69,8 @@ echo "Not sure building for net_server will succeed... good luck."
extralibs="-lsocket" extralibs="-lsocket"
fi ;; fi ;;
BSD/OS) BSD/OS)
grab="no" v4l="no"
audio_oss="no"
extralibs="-lpoll -lgnugetopt -lm" extralibs="-lpoll -lgnugetopt -lm"
make="gmake" make="gmake"
;; ;;
@ -108,7 +112,13 @@ for opt do
;; ;;
--enable-gprof) gprof="yes" --enable-gprof) gprof="yes"
;; ;;
--disable-grab) grab="no" --disable-v4l) v4l="no"
;;
--disable-audio-oss) audio_oss="no"
;;
--disable-network) network="no"
;;
--disable-a52) a52="no"
;; ;;
--enable-a52bin) a52bin="yes" ; extralibs="-ldl $extralibs" --enable-a52bin) a52bin="yes" ; extralibs="-ldl $extralibs"
;; ;;
@ -139,7 +149,9 @@ fi
if test "$win32" = "yes" ; then if test "$win32" = "yes" ; then
cross_prefix="i386-mingw32msvc-" cross_prefix="i386-mingw32msvc-"
grab="no" v4l="no"
audio_oss="no"
network="no"
fi fi
# endianness : guess with cpu type. Should also use prefix # endianness : guess with cpu type. Should also use prefix
@ -186,10 +198,9 @@ EOF
echo "Standard options:" echo "Standard options:"
echo " --help print this message" echo " --help print this message"
echo " --prefix=PREFIX install in PREFIX [$prefix]" echo " --prefix=PREFIX install in PREFIX [$prefix]"
echo " --disable-grab disable audio/video grabbing code"
echo " --disable-simple_idct disable simple IDCT routines [default=no]"
echo " --enable-mp3lame enable mp3 encoding via libmp3lame [default=no]" echo " --enable-mp3lame enable mp3 encoding via libmp3lame [default=no]"
echo " --enable-win32 enable win32 cross compile" echo " --enable-win32 enable win32 cross compile"
echo " --disable-a52 disable GPL'ed A52 support [default=no]"
echo " --enable-a52bin open liba52.so.0 at runtime [default=no]" echo " --enable-a52bin open liba52.so.0 at runtime [default=no]"
echo " --enable-shared build shared libraries [default=no]" echo " --enable-shared build shared libraries [default=no]"
echo "" echo ""
@ -203,6 +214,10 @@ echo " --extra-ldflags=ELDFLAGS add ELDFLAGS to LDFLAGS [$LDFLAGS]"
echo " --extra-libs=ELIBS add ELIBS [$ELIBS]" echo " --extra-libs=ELIBS add ELIBS [$ELIBS]"
echo " --cpu=CPU force cpu to CPU [$cpu]" echo " --cpu=CPU force cpu to CPU [$cpu]"
echo " --disable-mmx disable mmx usage" echo " --disable-mmx disable mmx usage"
echo " --disable-audio-oss disable OSS audio support [default=no]"
echo " --disable-v4l video4linux grabbing [default=no]"
echo " --disable-network disable network support [default=no]"
echo " --disable-simple_idct disable simple IDCT routines [default=no]"
echo " --enable-gprof enable profiling with gprof [$gprof]" echo " --enable-gprof enable profiling with gprof [$gprof]"
echo "" echo ""
echo "NOTE: The object files are build at the place where configure is launched" echo "NOTE: The object files are build at the place where configure is launched"
@ -217,8 +232,8 @@ echo "CPU $cpu"
echo "Big Endian $bigendian" echo "Big Endian $bigendian"
echo "MMX enabled $mmx" echo "MMX enabled $mmx"
echo "gprof enabled $gprof" echo "gprof enabled $gprof"
echo "grab enabled $grab"
echo "mp3lame enabled $mp3lame" echo "mp3lame enabled $mp3lame"
echo "a52 support $a52"
echo "a52 dlopened $a52bin" echo "a52 dlopened $a52bin"
echo "Creating config.mak and config.h" echo "Creating config.mak and config.h"
@ -260,8 +275,7 @@ if test "$gprof" = "yes" ; then
fi fi
if test "$lshared" = "yes" ; then if test "$lshared" = "yes" ; then
echo "BUILD_SHARED=yes" >> config.mak echo "BUILD_SHARED=yes" >> config.mak
else echo "PIC=-fPIC" >> config.mak
echo "BUILD_SHARED=no" >> config.mak
fi fi
echo "EXTRALIBS=$extralibs" >> config.mak echo "EXTRALIBS=$extralibs" >> config.mak
echo -n "VERSION=" >>config.mak echo -n "VERSION=" >>config.mak
@ -275,21 +289,30 @@ echo "CONFIG_ENCODERS=yes" >> config.mak
echo "#define CONFIG_DECODERS 1" >> $TMPH echo "#define CONFIG_DECODERS 1" >> $TMPH
echo "CONFIG_DECODERS=yes" >> config.mak echo "CONFIG_DECODERS=yes" >> config.mak
# special AC3 stuff in case you already have it # AC3
# without libavcodec. if test "$a52" = "yes" ; then
echo "#define CONFIG_AC3 1" >> $TMPH echo "#define CONFIG_AC3 1" >> $TMPH
echo "CONFIG_AC3=yes" >> config.mak echo "CONFIG_AC3=yes" >> config.mak
if test "$a52bin" = "yes" ; then if test "$a52bin" = "yes" ; then
echo "#define CONFIG_A52BIN 1" >> $TMPH echo "#define CONFIG_A52BIN 1" >> $TMPH
echo "CONFIG_A52BIN=yes" >> config.mak echo "CONFIG_A52BIN=yes" >> config.mak
else fi
echo "CONFIG_A52BIN=no" >> config.mak
fi fi
if test "$grab" = "yes" ; then if test "$v4l" = "yes" ; then
echo "#define CONFIG_GRAB 1" >> $TMPH echo "#define CONFIG_VIDEO4LINUX 1" >> $TMPH
echo "CONFIG_GRAB=yes" >> config.mak echo "CONFIG_VIDEO4LINUX=yes" >> config.mak
fi
if test "$audio_oss" = "yes" ; then
echo "#define CONFIG_AUDIO_OSS 1" >> $TMPH
echo "CONFIG_AUDIO_OSS=yes" >> config.mak
fi
if test "$network" = "yes" ; then
echo "#define CONFIG_NETWORK 1" >> $TMPH
echo "CONFIG_NETWORK=yes" >> config.mak
fi fi
if test "$mp3lame" = "yes" ; then if test "$mp3lame" = "yes" ; then