]> git.sesse.net Git - ffmpeg/blobdiff - configure
Replace every usage of -lvfw32 with what is particularly necessary for
[ffmpeg] / configure
index efd16bbe033141c1e534fb4b6783e5e8701c1522..708cab030eca5817619b494bae1f63ac8e3048b7 100755 (executable)
--- a/configure
+++ b/configure
@@ -92,13 +92,13 @@ Configuration options:
   --enable-w32threads      use Win32 threads [no]
   --enable-x11grab         enable X11 grabbing [no]
   --disable-network        disable network support [no]
-  --disable-ipv6           disable IPv6 support [no]
   --disable-mpegaudio-hp   faster (but less accurate) MPEG audio decoding [no]
   --enable-gray            enable full grayscale support (slower color)
   --disable-swscale-alpha  disable alpha channel support in swscale
   --disable-fastdiv        disable table-based division
   --enable-small           optimize for size instead of speed
   --disable-aandct         disable AAN DCT code
+  --disable-dct            disable DCT code
   --disable-fft            disable FFT code
   --disable-golomb         disable Golomb code
   --disable-lpc            disable LPC code
@@ -106,6 +106,7 @@ Configuration options:
   --disable-rdft           disable RDFT code
   --disable-vaapi          disable VAAPI code
   --disable-vdpau          disable VDPAU code
+  --disable-dxva2          disable DXVA2 code
   --enable-runtime-cpudetect detect cpu capabilities at runtime (bigger binary)
   --enable-hardcoded-tables use hardcoded tables instead of runtime generation
   --enable-memalign-hack   emulate memalign, interferes with memory debuggers
@@ -862,7 +863,9 @@ CONFIG_LIST="
     avisynth
     beos_netserver
     bzlib
+    dct
     doc
+    dxva2
     fastdiv
     ffmpeg
     ffplay
@@ -873,7 +876,6 @@ CONFIG_LIST="
     gprof
     gray
     hardcoded_tables
-    ipv6
     libdc1394
     libdirac
     libfaac
@@ -1030,6 +1032,9 @@ HAVE_LIST="
     soundcard_h
     poll_h
     struct_addrinfo
+    struct_ipv6_mreq
+    struct_sockaddr_in6
+    struct_sockaddr_sa_len
     struct_sockaddr_storage
     sys_mman_h
     sys_resource_h
@@ -1171,6 +1176,8 @@ h263_vaapi_hwaccel_select="vaapi h263_decoder"
 h263i_decoder_select="h263_decoder"
 h263p_encoder_select="h263_encoder"
 h264_decoder_select="golomb"
+h264_dxva2_hwaccel_deps="dxva2api_h"
+h264_dxva2_hwaccel_select="dxva2 h264_decoder"
 h264_vaapi_hwaccel_deps="va_va_h"
 h264_vaapi_hwaccel_select="vaapi"
 h264_vdpau_decoder_deps="vdpau_vdpau_h vdpau_vdpau_x11_h"
@@ -1324,7 +1331,7 @@ oss_outdev_deps_any="soundcard_h sys_soundcard_h"
 v4l_indev_deps="linux_videodev_h"
 v4l2_indev_deps_any="linux_videodev2_h sys_videoio_h"
 vfwcap_indev_deps="capCreateCaptureWindow"
-vfwcap_indev_extralibs="-lvfw32"
+vfwcap_indev_extralibs="-lavicap32"
 x11_grab_device_indev_deps="x11grab XShmCreateImage"
 x11_grab_device_indev_extralibs="-lX11 -lXext -lXfixes"
 
@@ -1371,6 +1378,8 @@ ranlib="ranlib"
 strip="strip"
 yasmexe="yasm"
 
+nm_opts='-g'
+
 # machine
 arch=$(uname -m)
 cpu="generic"
@@ -1387,7 +1396,6 @@ enable fastdiv
 enable ffmpeg
 enable ffplay
 enable ffserver
-enable ipv6
 enable mpegaudio_hp
 enable network
 enable optimizations
@@ -1484,7 +1492,7 @@ die_unknown(){
 show_list() {
     suffix=_$1
     shift
-    echo $* | sed s/$suffix//g | tr ' ' '\n' | sort
+    echo $* | sed s/$suffix//g | tr ' ' '\n' | sort | pr -3 -t
     exit 0
 }
 
@@ -1683,10 +1691,12 @@ elif $cc -version 2>/dev/null | grep -q TMS470; then
                     ;;
                 -mfpu=neon)     echo --float_support=vfpv3 --neon ;;
                 -mfpu=vfp)      echo --float_support=vfpv2        ;;
+                -mfpu=vfpv3)    echo --float_support=vfpv3        ;;
                 -msoft-float)   echo --float_support=vfplib       ;;
                 -Os)            echo -O3 -mf=2                    ;;
                 -O[0-3])        echo $flag -mf=5                  ;;
                 -g)             echo -g -mn                       ;;
+                -pds=*)         echo $flag                        ;;
             esac
         done
     }
@@ -1774,7 +1784,11 @@ if test "$cpu" = host; then
         gcc)
             check_native(){
                 $cc $1=native -v -c -o $TMPO $TMPC >$TMPE 2>&1 || return
-                awk "/$1=/{ match(\$0, /$1=(\\w+)/, a);print a[1];exit }" $TMPE
+                sed -n "/$1=/{
+                            s/.*$1=\\([^ ]*\\).*/\\1/
+                            p
+                            q
+                        }" $TMPE
             }
             cpu=$(check_native -march || check_native -mcpu)
         ;;
@@ -2018,6 +2032,7 @@ case $target_os in
         enabled x86 && SHFLAGS="-mimpure-text $SHFLAGS"
         network_extralibs="-lsocket -lnsl"
         add_cppflags -D__EXTENSIONS__
+        nm_opts='-P -g'
         ;;
     netbsd)
         oss_indev_extralibs="-lossaudio"
@@ -2093,7 +2108,7 @@ case $target_os in
             enabled_any avisynth vfwcap_indev &&
                 { check_cpp_condition w32api.h "(__W32API_MAJOR_VERSION > 3) || (__W32API_MAJOR_VERSION == 3 && __W32API_MINOR_VERSION >= 13)" ||
                   die "ERROR: avisynth and vfwcap_indev require w32api version 3.13 or later."; }
-            fi
+        fi
         ;;
     cygwin*)
         target_os=cygwin
@@ -2223,7 +2238,7 @@ enabled pic && enable_pic
 check_cc <<EOF || die "Symbol mangling check failed."
 int ff_extern;
 EOF
-sym=$($nm -g $TMPO | awk '/ff_extern/{ print substr($0, match($0, /[^[:blank:]]*ff_extern/)) }')
+sym=$($nm $nm_opts $TMPO | awk '/ff_extern/{ print substr($0, match($0, /[^ \t]*ff_extern/)) }')
 extern_prefix=${sym%%ff_extern*}
 
 check_cc <<EOF && enable inline_asm
@@ -2393,6 +2408,7 @@ check_func_headers windows.h VirtualAlloc
 
 check_header conio.h
 check_header dlfcn.h
+check_header dxva2api.h
 check_header malloc.h
 check_header poll.h
 check_header sys/mman.h
@@ -2452,7 +2468,7 @@ check_func roundf
 check_func truncf
 
 # these are off by default, so fail if requested and not available
-enabled avisynth   && require2 vfw32 "windows.h vfw.h" AVIFileInit -lvfw32
+enabled avisynth   && require2 vfw32 "windows.h vfw.h" AVIFileInit -lavifil32
 enabled libdirac   && add_cflags $(pkg-config --cflags dirac) &&
                       require  libdirac libdirac_decoder/dirac_parser.h dirac_decoder_init $(pkg-config --libs dirac) &&
                       require  libdirac libdirac_encoder/dirac_encoder.h dirac_encoder_init $(pkg-config --libs dirac)
@@ -2499,7 +2515,10 @@ texi2html -version > /dev/null 2>&1 && enable texi2html || disable texi2html
 if enabled network; then
     check_type "sys/types.h sys/socket.h" socklen_t
     check_type netdb.h "struct addrinfo"
+    check_type netinet/in.h "struct ipv6_mreq"
+    check_type netinet/in.h "struct sockaddr_in6"
     check_type "sys/types.h sys/socket.h" "struct sockaddr_storage"
+    check_struct "sys/types.h sys/socket.h" "struct sockaddr" sa_len
     # Prefer arpa/inet.h over winsock2
     if check_header arpa/inet.h ; then
         check_func closesocket
@@ -2510,31 +2529,20 @@ if enabled network; then
             network_extralibs="-lws2_32"; }
         check_type ws2tcpip.h socklen_t
         check_type ws2tcpip.h "struct addrinfo"
+        check_type ws2tcpip.h "struct ipv6_mreq"
+        check_type ws2tcpip.h "struct sockaddr_in6"
         check_type ws2tcpip.h "struct sockaddr_storage"
+        check_struct winsock2.h "struct sockaddr" sa_len
     else
         disable network
     fi
 fi
 
-enabled_all network ipv6 && check_ld <<EOF || disable ipv6
-#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);
-}
-EOF
-
 check_header linux/videodev.h
 check_header linux/videodev2.h
 check_header sys/videoio.h
 
-check_func_headers "windows.h vfw.h" capCreateCaptureWindow -lvfw32
+check_func_headers "windows.h vfw.h" capCreateCaptureWindow "$vfwcap_indev_extralibs"
 
 # check for ioctl_meteor.h, ioctl_bt848.h and alternatives
 { check_header dev/bktr/ioctl_meteor.h &&
@@ -2638,6 +2646,11 @@ elif enabled gcc; then
     check_cflags -fno-tree-vectorize
 elif enabled clang; then
     check_cflags -Qunused-arguments
+elif enabled armcc; then
+    # 2523: use of inline assembler is deprecated
+    add_cflags -Wrvct,--diag_suppress=2523
+elif enabled tms470; then
+    add_cflags -pds=824 -pds=837
 fi
 
 if enabled gprof; then
@@ -2735,9 +2748,6 @@ echo "postprocessing support    ${postproc-no}"
 echo "new filter support        ${avfilter-no}"
 echo "filters using lavformat   ${avfilter_lavf-no}"
 echo "network support           ${network-no}"
-if enabled network; then
-    echo "IPv6 support              ${ipv6-no}"
-fi
 echo "threading support         ${thread_type-no}"
 echo "SDL support               ${sdl-no}"
 echo "Sun medialib support      ${mlib-no}"