[FFmpeg-cvslog] Merge commit 'f1248fae90b45501af4e8743d373e79191470331'

Clément Bœsch git at videolan.org
Mon Apr 17 14:43:54 EEST 2017


ffmpeg | branch: master | Clément Bœsch <u at pkh.me> | Mon Apr 17 13:42:33 2017 +0200| [d1c8b9660848589ce4f1ac6e8ab337d9de495fbc] | committer: Clément Bœsch

Merge commit 'f1248fae90b45501af4e8743d373e79191470331'

* commit 'f1248fae90b45501af4e8743d373e79191470331':
  configure: Handle dxva2 optional components in the standard way

Merged-by: Clément Bœsch <u at pkh.me>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=d1c8b9660848589ce4f1ac6e8ab337d9de495fbc
---

 configure | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/configure b/configure
index 017a83eb03..821dbcba25 100755
--- a/configure
+++ b/configure
@@ -5587,7 +5587,6 @@ check_func_headers lzo/lzo1x.h lzo1x_999_compress
 check_func_headers stdlib.h getenv
 check_func_headers sys/stat.h lstat
 
-check_func_headers windows.h CoTaskMemFree -lole32
 check_func_headers windows.h GetProcessAffinityMask
 check_func_headers windows.h GetProcessTimes
 check_func_headers windows.h GetSystemTimeAsFileTime
@@ -6031,6 +6030,10 @@ enabled dxva2api_h &&
 int main(void) { IDirectXVideoDecoder *o = NULL; IDirectXVideoDecoder_Release(o); return 0; }
 EOF
 
+enabled dxva2 &&
+    check_lib windows.h CoTaskMemFree -lole32 &&
+    enable dxva2_lib
+
 enabled vaapi &&
     check_lib va/va.h vaInitialize -lva ||
     disable vaapi
@@ -6371,10 +6374,6 @@ if test $target_os = "haiku"; then
     disable posix_memalign
 fi
 
-enabled_all dxva2 dxva2api_cobj CoTaskMemFree &&
-    prepend ffmpeg_extralibs $($ldflags_filter "-lole32") &&
-    enable dxva2_lib
-
 # add_dep lib dep
 # -> enable ${lib}_deps_${dep}
 # -> add $dep to ${lib}_deps only once


======================================================================

diff --cc configure
index 017a83eb03,6feaa64d78..821dbcba25
--- a/configure
+++ b/configure
@@@ -5581,13 -4515,9 +5581,12 @@@ check_func  syscon
  check_func  sysctl
  check_func  usleep
  
 +check_func_headers conio.h kbhit
  check_func_headers io.h setmode
 +check_func_headers lzo/lzo1x.h lzo1x_999_compress
  check_func_headers stdlib.h getenv
 +check_func_headers sys/stat.h lstat
  
- check_func_headers windows.h CoTaskMemFree -lole32
  check_func_headers windows.h GetProcessAffinityMask
  check_func_headers windows.h GetProcessTimes
  check_func_headers windows.h GetSystemTimeAsFileTime
@@@ -5993,47 -4757,30 +5992,51 @@@ if enabled libcdio; the
      die "ERROR: No usable libcdio/cdparanoia found"
  fi
  
 -if enabled libxcb; then
 -    check_pkg_config xcb-shape xcb/shape.h xcb_shape_rectangles || {
 -        enabled libxcb && die "ERROR: libxcb not found";
 +if ! disabled libxcb; then
 +    check_pkg_config "xcb >= 1.4" xcb/xcb.h xcb_connect || {
 +        enabled libxcb && die "ERROR: libxcb >= 1.4 not found";
      } && enable libxcb
  
 -    disabled libxcb_shm ||
 +if enabled libxcb; then
 +    disabled libxcb_shm || {
          check_pkg_config xcb-shm xcb/shm.h xcb_shm_attach || {
              enabled libxcb_shm && die "ERROR: libxcb_shm not found";
 -        } && check_header sys/shm.h && enable libxcb_shm
 +        } && check_header sys/shm.h && enable libxcb_shm; }
  
 -    disabled libxcb_xfixes ||
 +    disabled libxcb_xfixes || {
          check_pkg_config xcb-xfixes xcb/xfixes.h xcb_xfixes_get_cursor_image || {
              enabled libxcb_xfixes && die "ERROR: libxcb_xfixes not found";
 -        } && enable libxcb_xfixes
 +        } && enable libxcb_xfixes; }
 +
 +    disabled libxcb_shape || {
 +        check_pkg_config xcb-shape xcb/shape.h xcb_shape_get_rectangles || {
 +            enabled libxcb_shape && die "ERROR: libxcb_shape not found";
 +        } && enable libxcb_shape; }
  
 -    add_cflags "$xcb_shape_cflags $xcb_shm_cflags $xcb_xfixes_cflags"
 -    add_extralibs "$xcb_shape_extralibs $xcb_shm_extralibs $xcb_xfixes_extralibs"
 +    add_cflags $xcb_cflags $xcb_shm_cflags $xcb_xfixes_cflags $xcb_shape_cflags
 +    add_extralibs $xcb_extralibs $xcb_shm_extralibs $xcb_xfixes_extralibs $xcb_shape_extralibs
  fi
 +fi
 +
 +check_func_headers "windows.h" CreateDIBSection "$gdigrab_indev_extralibs"
 +
 +enabled dxva2api_h &&
 +    check_cc <<EOF && enable dxva2api_cobj
 +#define _WIN32_WINNT 0x0600
 +#define COBJMACROS
 +#include <windows.h>
 +#include <d3d9.h>
 +#include <dxva2api.h>
 +int main(void) { IDirectXVideoDecoder *o = NULL; IDirectXVideoDecoder_Release(o); return 0; }
 +EOF
  
+ enabled dxva2 &&
+     check_lib windows.h CoTaskMemFree -lole32 &&
+     enable dxva2_lib
+ 
 -enabled vaapi && require vaapi va/va.h vaInitialize -lva
 +enabled vaapi &&
 +    check_lib va/va.h vaInitialize -lva ||
 +    disable vaapi
  
  enabled vaapi &&
      check_code cc "va/va.h" "vaCreateSurfaces(0, 0, 0, 0, 0, 0, 0, 0)" ||
@@@ -6363,45 -5058,6 +6366,41 @@@ check_deps $CONFIG_LIST       
             $HAVE_LIST         \
             $ALL_COMPONENTS    \
  
 +enabled threads && ! enabled pthreads && ! enabled atomics_native && die "non pthread threading without atomics not supported, try adding --enable-pthreads or --cpu=i486 or higher if you are on x86"
 +
 +
 +if test $target_os = "haiku"; then
 +    disable memalign
 +    disable posix_memalign
 +fi
 +
- enabled_all dxva2 dxva2api_cobj CoTaskMemFree &&
-     prepend ffmpeg_extralibs $($ldflags_filter "-lole32") &&
-     enable dxva2_lib
- 
 +# add_dep lib dep
 +# -> enable ${lib}_deps_${dep}
 +# -> add $dep to ${lib}_deps only once
 +add_dep() {
 +    lib=$1
 +    dep=$2
 +    enabled "${lib}_deps_${dep}" && return 0
 +    enable  "${lib}_deps_${dep}"
 +    prepend "${lib}_deps" $dep
 +}
 +
 +# merge deps lib components
 +# merge all ${component}_deps into ${lib}_deps and ${lib}_deps_*
 +merge_deps() {
 +    lib=$1
 +    shift
 +    for comp in $*; do
 +        enabled $comp || continue
 +        eval "dep=\"\$${comp}_deps\""
 +        for d in $dep; do
 +            add_dep $lib $d
 +        done
 +    done
 +}
 +
 +merge_deps libavfilter $FILTER_LIST
 +
  map 'enabled $v && intrinsics=${v#intrinsics_}' $INTRINSICS_LIST
  
  for thread in $THREADS_LIST; do



More information about the ffmpeg-cvslog mailing list