⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 configure

📁 ffmpeg源码分析
💻
📖 第 1 页 / 共 4 页
字号:
fiif test "$lzo" = "yes" -a "$gpl" = "yes"; then# check for liblzocat > $TMPC << EOF#include <lzo1x.h>int main ( void ) {lzo_init();return 0;}EOF$cc $CFLAGS $LDFLAGS -o $TMPE $TMPC -llzo 2> /dev/null || lzo="no"elselzo="no"fiif test "$lzo" = "yes"; thenextralibs="$extralibs -llzo"fi# test for lrintf in math.hcat > $TMPC << EOF#define _ISOC9X_SOURCE  1#include <math.h>int main( void ) { return (lrintf(3.999f) > 0)?0:1; }EOFhave_lrintf="no"if $cc $CFLAGS $LDFLAGS -o $TMPE $TMPC $extralibs 2> /dev/null ; then  have_lrintf="yes"  # allanc@chickenandporn.com: cannot execute cross-compiled  # code on the host.  Only execute if not cross-compiling.  if test -z "$cross_prefix" ; then    $TMPE 2> /dev/null > /dev/null || have_lrintf="no"  fifi_restrict=for restrict_keyword in restrict __restrict__ __restrict; do  echo "void foo(char * $restrict_keyword p);" > $TMPC  if $cc -c -o $TMPO $TMPC 2> /dev/null; then    _restrict=$restrict_keyword    break;  fidone# test gcc version to see if vector builtins can be used# currently only used on i386 for MMX builtinscat > $TMPC << EOF#include <xmmintrin.h>int main(void) {#if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 2)return 0;#else#error no vector builtins#endif}EOFbuiltin_vector=noif $cc -msse -o $TMPO $TMPC 2> /dev/null ; then  builtin_vector=yesfi# test for mm3dnow.hcat > $TMPC << EOF#include <mm3dnow.h>int main(void) {return 0;}EOFmm3dnow=noif $cc -march=athlon -o $TMPO $TMPC 2> /dev/null ; then  mm3dnow=yesfi# Probe for -Wdeclaration-after-statementif test "$cc" = "gcc"; then  cat > $TMPC << EOF  int main( void ) { return 0; }EOF  if $cc -Wdeclaration-after-statement -Werror -o $TMPE $TMPC 2> /dev/null ; then    CFLAGS="$CFLAGS -Wdeclaration-after-statement"  fifi# dlopen/dlfcn.h probingcat > $TMPC << EOF#include <dlfcn.h>int main( void ) { return (int) dlopen("foo", 0); }EOFldl=-ldlif $cc $CFLAGS $LDFLAGS -o $TMPE $TMPC -ldl > /dev/null 2>&1 ; thendlfcn=yesdlopen=yesfiif $cc $CFLAGS $LDFLAGS -o $TMPE $TMPC > /dev/null 2>&1 ; thendlfcn=yesdlopen=yesldl=""ficat > $TMPC << EOFint main( void ) { return (int) dlopen("foo", 0); }EOFif $cc $CFLAGS $LDFLAGS -o $TMPE $TMPC -ldl > /dev/null 2>&1  ; thendlopen=yesfiif $cc $CFLAGS $LDFLAGS -o $TMPE $TMPC > /dev/null 2>&1  ; thendlopen=yesldl=""fiif test "$vhook" = "default" ; then  vhook="$dlopen"fiif test "$vhook" = "yes" -o "$a52bin" = "yes" -o "$faadbin" = "yes"; then  extralibs="$extralibs $ldl"fi########################################### imlib checkcat > $TMPC << EOF#include <X11/Xlib.h>#include <Imlib2.h>int main( void ) { return (int) imlib_load_font("foo"); }EOFimlib2=noif $cc $CFLAGS $LDFLAGS -o $TMPE $TMPC -lImlib2 -lm > /dev/null 2>&1  ; thenimlib2=yesfi########################################### FreeType checkcat > $TMPC << EOF#include <ft2build.h>int main( void ) { return (int) FT_Init_FreeType(0); }EOFfreetype2=noif test "x$targetos" != "xBeOS"; then  if (freetype-config --version) >/dev/null 2>&1 ; then    if $cc -o $TMPE $TMPC `freetype-config --cflags` `freetype-config --libs`  > /dev/null 2>&1 ; then      freetype2=yes    fi  fifi########################################### SDL checkcat > $TMPC << EOF#include <SDL.h>#undef main /* We don't want SDL to override our main() */int main( void ) { return SDL_Init (SDL_INIT_VIDEO); }EOFsdl_too_old=nosdl=noSDL_CONFIG="${cross_prefix}sdl-config"if ("${SDL_CONFIG}" --version) >/dev/null 2>&1 ; thenif $cc -o $TMPE `"${SDL_CONFIG}" --cflags` $TMPC `"${SDL_CONFIG}" --libs`  > /dev/null 2>&1  ; then_sdlversion=`"${SDL_CONFIG}" --version | sed 's/[^0-9]//g'`if test "$_sdlversion" -lt 121 ; thensdl_too_old=yeselsesdl=yesfififi########################################### texi2html checktexi2html=noif (texi2html -version) >/dev/null 2>&1; thentexi2html=yesfiif test "$network" = "yes" ; then########################################### IPv6 checkcat > $TMPC << EOF#include <sys/types.h>#include <sys/socket.h>#include <netinet/in.h>#include <netdb.h>int main( void ) {  struct sockaddr_storage saddr;  struct ipv6_mreq mreq6;  getaddrinfo(0,0,0,0);  getnameinfo(0,0,0,0,0,0,0);  IN6_IS_ADDR_MULTICAST((const struct in6_addr *)0);}EOFipv6=noif $cc -o $TMPE $TMPC > /dev/null 2>&1  ; thenipv6=yesfifiif test "$v4l2" = "yes"; then# check for video4linux2 --- V4L2_PIX_FMT_YUV420cat > $TMPC << EOF#include <sys/time.h>#include <linux/videodev.h>int dummy = V4L2_PIX_FMT_YUV420;EOF$cc -c -o $TMPE $TMPC 2> /dev/null || v4l2="no"ficase "`$cc -v 2>&1 | grep version`" in    *gcc*)        CFLAGS="-Wall -Wno-switch $CFLAGS"        ;;    *)        ;;esacif test "$sdl" = "no" ; then   ffplay=nofiif test "$debug" = "yes"; then        CFLAGS="-g $CFLAGS"fiif test "$optimize" = "small"; then#  CFLAGS=${CFLAGS//-O3/-Os}  CFLAGS="$CFLAGS -Os"fiif test "$optimize" = "yes"; then    if test -n "`$cc -v 2>&1 | grep xlc`"; then        CFLAGS="$CFLAGS -O5"        LDFLAGS="$LDFLAGS -O5"    else        CFLAGS="-O3 $CFLAGS"    fifi# PIC flags for shared library objects where they are neededif test "$lshared" = "yes" ; then  # LIBOBJFLAGS may have already been set in the OS configuration  if test -z "$LIBOBJFLAGS" ; then    if test "$cpu" = "x86_64" -o "$cpu" = "ia64" -o "$cpu" = "alpha" ; then      LIBOBJFLAGS="\$(PIC)"    fi  fifiif test x"$bindir" = x""; thenbindir="${prefix}/bin"fiif test x"$libdir" = x""; thenlibdir="${prefix}/lib"fiif test x"$incdir" = x""; thenincdir="${prefix}/include/ffmpeg"fiif test x"$mandir" = x""; thenmandir="${prefix}/man"fiecho "install prefix   $prefix"echo "source path      $source_path"echo "C compiler       $cc"echo "make             $make"echo "CPU              $cpu ($tune)"if test "$BUILDSUF" != ""; thenecho "build suffix     $BUILDSUF"fiecho "big-endian       $bigendian"echo "inttypes.h       $inttypes"echo "broken inttypes.h $emu_fast_int"if test $cpu = "x86" -o $cpu = "x86_64"; thenecho "MMX enabled      $mmx"echo "Vector Builtins  $builtin_vector"echo "3DNow! Builtins  $mm3dnow"fiif test $cpu = "armv4l"; thenecho "IWMMXT enabled   $iwmmxt"fiif test $cpu = "mips"; thenecho "MMI enabled      $mmi"fiif test $cpu = "powerpc"; thenecho "AltiVec enabled  $altivec"fiecho "gprof enabled    $gprof"echo "zlib enabled     $zlib"echo "lzo enabled      $lzo"echo "libgsm enabled   $libgsm"echo "mp3lame enabled  $mp3lame"echo "libogg enabled   $libogg"echo "Vorbis enabled   $vorbis"echo "Theora enabled   $theora"echo "FAAD enabled     $faad"echo "faadbin enabled  $faadbin"echo "FAAC enabled     $faac"echo "XviD enabled     $xvid"echo "x264 enabled     $x264"echo "a52 support      $a52"echo "a52 dlopened     $a52bin"echo "DTS support      $dts"echo "pp support       $pp"echo "debug symbols    $debug"echo "strip symbols    $dostrip"echo "optimize         $optimize"echo "static           $lstatic"echo "shared           $lshared"echo "video hooking    $vhook"echo "SDL support      $sdl"if test $sdl_too_old = "yes"; thenecho "-> Your SDL version is too old - please upgrade to have FFplay/SDL support."fiif test "$vhook" = "yes" ; thenecho "Imlib2 support   $imlib2"echo "FreeType support $freetype2"fiecho "Sun medialib support"  $sunmlibecho "pthreads support"      $pthreadsecho "AMR-NB float support"  $amr_nbecho "AMR-NB fixed support"  $amr_nb_fixedecho "AMR-WB float support"  $amr_wbecho "AMR-WB IF2 support"    $amr_if2echo "network support      $network"if test "$network" = "yes" ; thenecho "IPv6 support         $ipv6"fiif test "$gpl" = "no" ; thenecho "License: LGPL"elseecho "License: GPL"fiecho "Creating config.mak and config.h..."date >> config.logecho "   $0 $FFMPEG_CONFIGURATION" >> config.logecho "# Automatically generated by configure - do not modify!" > config.makecho "/* Automatically generated by configure - do not modify! */" > $TMPHecho "#define FFMPEG_CONFIGURATION "'"'"$FFMPEG_CONFIGURATION"'"' >> $TMPHecho "prefix=\$(DESTDIR)$prefix" >> config.makecho "libdir=\$(DESTDIR)$libdir" >> config.makecho "incdir=\$(DESTDIR)$incdir" >> config.makecho "bindir=\$(DESTDIR)$bindir" >> config.makecho "mandir=\$(DESTDIR)$mandir" >> config.makecho "MAKE=$make" >> config.makecho "CC=$cc" >> config.makecho "AR=$ar" >> config.makecho "RANLIB=$ranlib" >> config.makif test "$dostrip" = "yes" ; thenecho "STRIP=$strip" >> config.makecho "INSTALLSTRIP=$installstrip" >> config.makelseecho "STRIP=echo ignoring strip" >> config.makecho "INSTALLSTRIP=" >> config.makfi# SHCFLAGS is a copy of CFLAGS without -mdynamic-no-pic, used when building# shared modules on OS/X (vhook/Makefile).SHCFLAGS=$CFLAGSif test "$needmdynamicnopic" = yes; then   CFLAGS="$CFLAGS -mdynamic-no-pic"fiecho "OPTFLAGS=$CFLAGS" >> config.makecho "SHCFLAGS=$SHCFLAGS">>config.makecho "LDFLAGS=$LDFLAGS" >> config.makecho "LDCONFIG=$LDCONFIG" >> config.makecho "FFSLDFLAGS=$FFSLDFLAGS" >> config.makecho "SHFLAGS=$SHFLAGS" >> config.makecho "LIBOBJFLAGS=$LIBOBJFLAGS" >> config.makecho "BUILD_STATIC=$lstatic" >> config.makecho "BUILDSUF=$BUILDSUF" >> config.makecho "LIBPREF=$LIBPREF" >> config.makecho "LIBSUF=\${BUILDSUF}$LIBSUF" >> config.makif test "$lstatic" = "yes" ; then  echo "LIB=$LIB" >> config.makelse # Some Make complain if this variable does not exist.  echo "LIB=" >> config.makfiecho "SLIBPREF=$SLIBPREF" >> config.makecho "SLIBSUF=\${BUILDSUF}$SLIBSUF" >> config.makecho "EXESUF=\${BUILDSUF}$EXESUF" >> config.makecho "TARGET_OS=$TARGET_OS" >> config.makif test "$cpu" = "x86" ; then  echo "TARGET_ARCH_X86=yes" >> config.mak  echo "#define ARCH_X86 1" >> $TMPHelif test "$cpu" = "x86_64" ; then  echo "TARGET_ARCH_X86_64=yes" >> config.mak  echo "#define ARCH_X86_64 1" >> $TMPHelif test "$cpu" = "armv4l" ; then  echo "TARGET_ARCH_ARMV4L=yes" >> config.mak  echo "#define ARCH_ARMV4L 1" >> $TMPHelif test "$cpu" = "alpha" ; then  echo "TARGET_ARCH_ALPHA=yes" >> config.mak  echo "#define ARCH_ALPHA 1" >> $TMPHelif test "$cpu" = "sparc64" ; then  echo "TARGET_ARCH_SPARC64=yes" >> config.mak  echo "#define ARCH_SPARC64 1" >> $TMPH  echo "TARGET_ARCH_SPARC=yes" >> config.mak  echo "#define ARCH_SPARC 1" >> $TMPHelif test "$cpu" = "sparc" ; then  echo "TARGET_ARCH_SPARC=yes" >> config.mak  echo "#define ARCH_SPARC 1" >> $TMPHelif test "$cpu" = "powerpc" ; then  echo "TARGET_ARCH_POWERPC=yes" >> config.mak  echo "#define ARCH_POWERPC 1" >> $TMPH  if test $POWERPCMODE = "32bits"; then    echo "#define POWERPC_MODE_32BITS 1" >> $TMPH  else    echo "#define POWERPC_MODE_64BITS 1" >> $TMPH  fi  if test "$powerpc_perf" = "yes"; then    echo "#define POWERPC_PERFORMANCE_REPORT 1" >> $TMPH  fielif test "$cpu" = "mips" ; then  echo "TARGET_ARCH_MIPS=yes" >> config.mak  echo "#define ARCH_MIPS 1" >> $TMPHelif test "$cpu" = "sh4" ; then  echo "TARGET_ARCH_SH4=yes" >> config.mak  echo "#define ARCH_SH4 1" >> $TMPHelif test "$cpu" = "parisc" ; then  echo "TARGET_ARCH_PARISC=yes" >> config.mak  echo "#define ARCH_PARISC 1" >> $TMPHelif test "$cpu" = "s390" ; then  echo "TARGET_ARCH_S390=yes" >> config.mak  echo "#define ARCH_S390 1" >> $TMPHelif test "$cpu" = "m68k" ; then  echo "TARGET_ARCH_M68K=yes" >> config.mak  echo "#define ARCH_M68K 1" >> $TMPHelif test "$cpu" = "ia64" ; then  echo "TARGET_ARCH_IA64=yes" >> config.mak  echo "#define ARCH_IA64 1" >> $TMPHfiecho "#define TUNECPU $TUNECPU" >> $TMPHif test "$bigendian" = "yes" ; then  echo "WORDS_BIGENDIAN=yes" >> config.mak  echo "#define WORDS_BIGENDIAN 1" >> $TMPHfiif test "$inttypes" != "yes" ; then  echo "#define EMULATE_INTTYPES 1" >> $TMPHfiif test "$emu_fast_int" = "yes" ; then  echo "#define EMULATE_FAST_INT 1" >> $TMPHfiif test "$mmx" = "yes" ; then  echo "TARGET_MMX=yes" >> config.mak  echo "#define HAVE_MMX 1" >> $TMPH  echo "#define __CPU__ 586" >> $TMPHfiif test "$builtin_vector" = "yes" ; then  echo "TARGET_BUILTIN_VECTOR=yes" >> config.mak  echo "#define HAVE_BUILTIN_VECTOR 1" >> $TMPHfiif test "$mm3dnow" = "yes" ; then  echo "TARGET_BUILTIN_3DNOW=yes" >> config.mak  echo "#define HAVE_MM3DNOW 1" >> $TMPHfiif test "$iwmmxt" = "yes" ; then  echo "TARGET_IWMMXT=yes" >> config.mak  echo "#define HAVE_IWMMXT 1" >> $TMPHfiif test "$mmi" = "yes" ; then  echo "TARGET_MMI=yes" >> config.mak  echo "#define HAVE_MMI 1" >> $TMPHfiif test "$altivec" = "yes" ; then  echo "TARGET_ALTIVEC=yes" >> config.mak  echo "#define HAVE_ALTIVEC 1" >> $TMPH  echo "// Enable the next line to use the reference C code instead of AltiVec" >> $TMPH  echo "// #define ALTIVEC_USE_REFERENCE_C_CODE 1" >> $TMPH  if test "$_altivec_h" = "yes" ; then    echo "#define HAVE_ALTIVEC_H 1" >> $TMPH  else    echo "#undef HAVE_ALTIVEC_H" >> $TMPH  fifiif test "$gprof" = "yes" ; then  echo "TARGET_GPROF=yes" >> config.mak  echo "#define HAVE_GPROF 1" >> $TMPHfiif test "$localtime_r" = "yes" ; then  echo "#define HAVE_LOCALTIME_R 1" >> $TMPHfiif test "$imlib2" = "yes" ; then  echo "HAVE_IMLIB2=yes" >> config.makfiif test "$freetype2" = "yes" ; then  echo "HAVE_FREETYPE2=yes" >> config.makfiif test "$sunmlib" = "yes" ; then  echo "HAVE_MLIB=yes" >> config.mak  echo "#define HAVE_MLIB 1" >> $TMPH  extralibs="$extralibs -lmlib"fiif test "$pthreads" = "yes" ; then  echo "HAVE_PTHREADS=yes" >> config.mak  echo "#define HAVE_PTHREADS 1" >> $TMPH  echo "#define HAVE_THREADS 1" >> $TMPH  if test $targetos != FreeBSD -a $targetos != OpenBSD ; then     extralibs="$extralibs -lpthread"  fi

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -