[FFmpeg-cvslog] Merge commit 'be2d555c980220e65d0ca5c3d78e6cc1e24451a5'
Clément Bœsch
git at videolan.org
Mon Apr 17 11:26:20 EEST 2017
ffmpeg | branch: master | Clément Bœsch <u at pkh.me> | Mon Apr 17 10:22:52 2017 +0200| [9bf3d8408937e101921b3a0090cd6ae116b0c41f] | committer: Clément Bœsch
Merge commit 'be2d555c980220e65d0ca5c3d78e6cc1e24451a5'
* commit 'be2d555c980220e65d0ca5c3d78e6cc1e24451a5':
build: Use _extralibs variable names instead of _libs everywhere
Merged-by: Clément Bœsch <u at pkh.me>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=9bf3d8408937e101921b3a0090cd6ae116b0c41f
---
Makefile | 2 +-
configure | 44 ++++++++++++++++++++++----------------------
2 files changed, 23 insertions(+), 23 deletions(-)
diff --git a/Makefile b/Makefile
index d5b51de7e7..559c5b8d5f 100644
--- a/Makefile
+++ b/Makefile
@@ -123,7 +123,7 @@ OBJS-$(1) += $(1).o $(OBJS-$(1)-yes)
$(1)$(PROGSSUF)_g$(EXESUF): $$(OBJS-$(1))
$$(OBJS-$(1)): CFLAGS += $(CFLAGS-$(1))
$(1)$(PROGSSUF)_g$(EXESUF): LDFLAGS += $(LDFLAGS-$(1))
-$(1)$(PROGSSUF)_g$(EXESUF): FF_EXTRALIBS += $(LIBS-$(1))
+$(1)$(PROGSSUF)_g$(EXESUF): FF_EXTRALIBS += $(EXTRALIBS-$(1))
-include $$(OBJS-$(1):.o=.d)
endef
diff --git a/configure b/configure
index 1a8de90761..58990feb3e 100755
--- a/configure
+++ b/configure
@@ -1246,8 +1246,8 @@ check_pkg_config(){
pkg_cflags=$($pkg_config --cflags $pkg_config_flags $pkg)
pkg_libs=$($pkg_config --libs $pkg_config_flags $pkg)
check_func_headers "$headers" "$funcs" $pkg_cflags $pkg_libs "$@" &&
- set_safe "${pkg}_cflags" $pkg_cflags &&
- set_safe "${pkg}_libs" $pkg_libs
+ set_safe "${pkg}_cflags" $pkg_cflags &&
+ set_safe "${pkg}_extralibs" $pkg_libs
}
check_exec(){
@@ -1347,7 +1347,7 @@ use_pkg_config(){
pkg="$1"
check_pkg_config "$@" || return 1
add_cflags $(get_safe "${pkg}_cflags")
- add_extralibs $(get_safe "${pkg}_libs")
+ add_extralibs $(get_safe "${pkg}_extralibs")
}
require_pkg_config(){
@@ -3198,7 +3198,7 @@ ffmpeg_select="aformat_filter anull_filter atrim_filter format_filter
null_filter
trim_filter"
ffplay_deps="avcodec avformat swscale swresample sdl2"
-ffplay_libs='$sdl2_libs'
+ffplay_extralibs='$sdl2_extralibs'
ffplay_select="rdft crop_filter transpose_filter hflip_filter vflip_filter rotate_filter"
ffprobe_deps="avcodec avformat"
ffserver_deps="avformat fork sarestart"
@@ -5756,8 +5756,8 @@ enabled libdc1394 && require_pkg_config libdc1394-2 dc1394/dc1394.h dc13
enabled libfdk_aac && { use_pkg_config fdk-aac "fdk-aac/aacenc_lib.h" aacEncOpen ||
{ require libfdk_aac fdk-aac/aacenc_lib.h aacEncOpen -lfdk-aac &&
warn "using libfdk without pkg-config"; } }
-flite_libs="-lflite_cmu_time_awb -lflite_cmu_us_awb -lflite_cmu_us_kal -lflite_cmu_us_kal16 -lflite_cmu_us_rms -lflite_cmu_us_slt -lflite_usenglish -lflite_cmulex -lflite"
-enabled libflite && require libflite "flite/flite.h" flite_init $flite_libs
+flite_extralibs="-lflite_cmu_time_awb -lflite_cmu_us_awb -lflite_cmu_us_kal -lflite_cmu_us_kal16 -lflite_cmu_us_rms -lflite_cmu_us_slt -lflite_usenglish -lflite_cmulex -lflite"
+enabled libflite && require libflite "flite/flite.h" flite_init $flite_extralibs
enabled fontconfig && enable libfontconfig
enabled libfontconfig && require_pkg_config fontconfig "fontconfig/fontconfig.h" FcInit
enabled libfreetype && require_pkg_config freetype2 "ft2build.h FT_FREETYPE_H" FT_Init_FreeType
@@ -5865,8 +5865,8 @@ enabled mmal && { check_lib interface/mmal/mmal.h mmal_port_connect
die "ERROR: mmal not found" &&
check_func_headers interface/mmal/mmal.h "MMAL_PARAMETER_VIDEO_MAX_NUM_CALLBACKS"; }
enabled netcdf && require_pkg_config netcdf netcdf.h nc_inq_libvers
-enabled openal && { { for al_libs in "${OPENAL_LIBS}" "-lopenal" "-lOpenAL32"; do
- check_lib 'AL/al.h' alGetError "${al_libs}" && break; done } ||
+enabled openal && { { for al_extralibs in "${OPENAL_LIBS}" "-lopenal" "-lOpenAL32"; do
+ check_lib 'AL/al.h' alGetError "${al_extralibs}" && break; done } ||
die "ERROR: openal not found"; } &&
{ check_cpp_condition "AL/al.h" "defined(AL_VERSION_1_1)" ||
die "ERROR: openal must be installed and version must be 1.1 or compatible"; }
@@ -5898,10 +5898,10 @@ if enabled gcrypt; then
GCRYPT_CONFIG="${cross_prefix}libgcrypt-config"
if "${GCRYPT_CONFIG}" --version > /dev/null 2>&1; then
gcrypt_cflags=$("${GCRYPT_CONFIG}" --cflags)
- gcrypt_libs=$("${GCRYPT_CONFIG}" --libs)
- check_func_headers gcrypt.h gcry_mpi_new $gcrypt_cflags $gcrypt_libs ||
+ gcrypt_extralibs=$("${GCRYPT_CONFIG}" --libs)
+ check_func_headers gcrypt.h gcry_mpi_new $gcrypt_cflags $gcrypt_extralibs ||
die "ERROR: gcrypt not found"
- add_cflags $gcrypt_cflags && add_extralibs $gcrypt_libs
+ add_cflags $gcrypt_cflags && add_extralibs $gcrypt_extralibs
else
require gcrypt gcrypt.h gcry_mpi_new -lgcrypt
fi
@@ -5913,21 +5913,21 @@ if ! disabled sdl2; then
if check_pkg_config sdl2 SDL_events.h SDL_PollEvent; then
check_cpp_condition SDL.h "(SDL_MAJOR_VERSION<<16 | SDL_MINOR_VERSION<<8 | SDL_PATCHLEVEL) >= 0x020001" $sdl2_cflags &&
check_cpp_condition SDL.h "(SDL_MAJOR_VERSION<<16 | SDL_MINOR_VERSION<<8 | SDL_PATCHLEVEL) < 0x020100" $sdl2_cflags &&
- check_func SDL_Init $sdl2_libs $sdl2_cflags && enable sdl2
+ check_func SDL_Init $sdl2_extralibs $sdl2_cflags && enable sdl2
else
if "${SDL2_CONFIG}" --version > /dev/null 2>&1; then
sdl2_cflags=$("${SDL2_CONFIG}" --cflags)
- sdl2_libs=$("${SDL2_CONFIG}" --libs)
+ sdl2_extralibs=$("${SDL2_CONFIG}" --libs)
check_cpp_condition SDL.h "(SDL_MAJOR_VERSION<<16 | SDL_MINOR_VERSION<<8 | SDL_PATCHLEVEL) >= 0x020001" $sdl2_cflags &&
check_cpp_condition SDL.h "(SDL_MAJOR_VERSION<<16 | SDL_MINOR_VERSION<<8 | SDL_PATCHLEVEL) < 0x020100" $sdl2_cflags &&
- check_func SDL_Init $sdl2_libs $sdl2_cflags && enable sdl2
+ check_func SDL_Init $sdl2_extralibs $sdl2_cflags && enable sdl2
fi
fi
if test $target_os = "mingw32"; then
- sdl2_libs="$sdl2_libs -mconsole"
+ sdl2_extralibs="$sdl2_extralibs -mconsole"
fi
fi
-enabled sdl2 && enable sdl && add_cflags $sdl2_cflags && add_extralibs $sdl2_libs
+enabled sdl2 && enable sdl && add_cflags $sdl2_cflags && add_extralibs $sdl2_extralibs
disabled securetransport || { check_func SecIdentityCreate "-Wl,-framework,CoreFoundation -Wl,-framework,Security" &&
check_lib "Security/SecureTransport.h Security/Security.h" "SSLCreateContext SecItemImport" "-Wl,-framework,CoreFoundation -Wl,-framework,Security" &&
@@ -6015,7 +6015,7 @@ if enabled libxcb; then
} && enable libxcb_shape; }
add_cflags $xcb_cflags $xcb_shm_cflags $xcb_xfixes_cflags $xcb_shape_cflags
- add_extralibs $xcb_libs $xcb_shm_libs $xcb_xfixes_libs $xcb_shape_libs
+ add_extralibs $xcb_extralibs $xcb_shm_extralibs $xcb_xfixes_extralibs $xcb_shape_extralibs
fi
fi
@@ -6372,7 +6372,7 @@ if test $target_os = "haiku"; then
fi
enabled_all dxva2 dxva2api_cobj CoTaskMemFree &&
- prepend ffmpeg_libs $($ldflags_filter "-lole32") &&
+ prepend ffmpeg_extralibs $($ldflags_filter "-lole32") &&
enable dxva2_lib
# add_dep lib dep
@@ -6752,12 +6752,12 @@ map 'get_version $v' $LIBRARY_LIST
map 'eval echo "${v}_FFLIBS=\$${v}_deps" >> config.mak' $LIBRARY_LIST
-print_program_libs(){
- eval "program_libs=\$${1}_libs"
- eval echo "LIBS-${1}=${program_libs}" >> config.mak
+print_program_extralibs(){
+ eval "program_extralibs=\$${1}_extralibs"
+ eval echo "EXTRALIBS-${1}=${program_extralibs}" >> config.mak
}
-map 'print_program_libs $v' $PROGRAM_LIST
+map 'print_program_extralibs $v' $PROGRAM_LIST
cat > $TMPH <<EOF
/* Automatically generated by configure - do not modify! */
======================================================================
diff --cc Makefile
index d5b51de7e7,d4c2b8e7d7..559c5b8d5f
--- a/Makefile
+++ b/Makefile
@@@ -120,10 -161,10 +120,10 @@@ include $(SRC_PATH)/doc/Makefil
define DOPROG
OBJS-$(1) += $(1).o $(OBJS-$(1)-yes)
-$(1)$(EXESUF): $$(OBJS-$(1))
+$(1)$(PROGSSUF)_g$(EXESUF): $$(OBJS-$(1))
$$(OBJS-$(1)): CFLAGS += $(CFLAGS-$(1))
-$(1)$(EXESUF): LDFLAGS += $(LDFLAGS-$(1))
-$(1)$(EXESUF): FF_EXTRALIBS += $(EXTRALIBS-$(1))
+$(1)$(PROGSSUF)_g$(EXESUF): LDFLAGS += $(LDFLAGS-$(1))
- $(1)$(PROGSSUF)_g$(EXESUF): FF_EXTRALIBS += $(LIBS-$(1))
++$(1)$(PROGSSUF)_g$(EXESUF): FF_EXTRALIBS += $(EXTRALIBS-$(1))
-include $$(OBJS-$(1):.o=.d)
endef
diff --cc configure
index 1a8de90761,f5c0b11629..58990feb3e
--- a/configure
+++ b/configure
@@@ -1334,26 -1111,15 +1334,26 @@@ require()
check_lib "$headers" $func "$@" || die "ERROR: $name_version not found"
}
-require_pkg_config(){
- log require_pkg_config "$@"
- pkg_version="$1"
- pkg="${1%% *}"
- check_pkg_config "$@" || die "ERROR: $pkg_version not found"
+require_cpp(){
+ name="$1"
+ headers="$2"
+ classes="$3"
+ shift 3
+ check_lib_cpp "$headers" "$classes" "$@" || die "ERROR: $name not found"
+}
+
+use_pkg_config(){
+ log use_pkg_config "$@"
+ pkg="$1"
+ check_pkg_config "$@" || return 1
add_cflags $(get_safe "${pkg}_cflags")
- add_extralibs $(get_safe "${pkg}_libs")
+ add_extralibs $(get_safe "${pkg}_extralibs")
}
+require_pkg_config(){
+ use_pkg_config "$@" || die "ERROR: $pkg not found using pkg-config$pkg_config_fail_message"
+}
+
hostcc_e(){
eval printf '%s\\n' $HOSTCC_E
}
@@@ -3193,24 -2472,18 +3193,24 @@@ swresample_deps="avutil
swscale_deps="avutil"
# programs
-avconv_deps="avcodec avfilter avformat avresample swscale"
-avconv_select="aformat_filter anull_filter asyncts_filter atrim_filter format_filter
- fps_filter null_filter resample_filter scale_filter
+ffmpeg_deps="avcodec avfilter avformat swresample"
+ffmpeg_select="aformat_filter anull_filter atrim_filter format_filter
+ null_filter
trim_filter"
-avplay_deps="avcodec avfilter avformat avresample sdl"
-avplay_extralibs='$sdl_extralibs'
-avplay_select="rdft format_filter transpose_filter hflip_filter vflip_filter"
-avprobe_deps="avcodec avformat"
+ffplay_deps="avcodec avformat swscale swresample sdl2"
- ffplay_libs='$sdl2_libs'
++ffplay_extralibs='$sdl2_extralibs'
+ffplay_select="rdft crop_filter transpose_filter hflip_filter vflip_filter rotate_filter"
+ffprobe_deps="avcodec avformat"
+ffserver_deps="avformat fork sarestart"
+ffserver_select="ffm_muxer rtp_protocol rtsp_demuxer"
# documentation
-pod2man_deps="doc"
-texi2html_deps="doc"
+podpages_deps="perl"
+manpages_deps="perl pod2man"
+htmlpages_deps="perl"
+htmlpages_deps_any="makeinfo_html texi2html"
+txtpages_deps="perl makeinfo"
+doc_deps_any="manpages htmlpages podpages txtpages"
# default parameters
@@@ -5722,47 -4610,19 +5722,47 @@@ for func in $MATH_FUNCS; d
eval check_mathfunc $func \${${func}_args:-1} $LIBM
done
+for func in $COMPLEX_FUNCS; do
+ eval check_complexfunc $func \${${func}_args:-1}
+done
+
# these are off by default, so fail if requested and not available
-enabled avisynth && { check_header avisynth/avisynth_c.h || die "ERROR: avisynth/avisynth_c.h header not found"; }
-enabled avxsynth && require avxsynth "avxsynth/avxsynth_c.h dlfcn.h" dlopen -ldl
-enabled cuda && require cuda cuda.h cuInit -lcuda
+enabled avfoundation_indev && { check_header_objcc AVFoundation/AVFoundation.h || disable avfoundation_indev; }
+enabled avfoundation_indev && { check_lib CoreGraphics/CoreGraphics.h CGGetActiveDisplayList -framework CoreGraphics ||
+ check_lib ApplicationServices/ApplicationServices.h CGGetActiveDisplayList -framework ApplicationServices; }
+enabled cuda && check_header cuda.h # this is not a dependency
+enabled cuvid && { enabled cuda ||
+ die "ERROR: CUVID requires CUDA"; }
+enabled chromaprint && require chromaprint chromaprint.h chromaprint_get_version -lchromaprint
+enabled coreimage_filter && { check_header_objcc QuartzCore/CoreImage.h || disable coreimage_filter; }
+enabled coreimagesrc_filter && { check_header_objcc QuartzCore/CoreImage.h || disable coreimagesrc_filter; }
+enabled decklink && { { check_header DeckLinkAPI.h || die "ERROR: DeckLinkAPI.h header not found"; } &&
+ { check_cpp_condition DeckLinkAPIVersion.h "BLACKMAGIC_DECKLINK_API_VERSION >= 0x0a060100" || die "ERROR: Decklink API version must be >= 10.6.1."; } }
enabled frei0r && { check_header frei0r.h || die "ERROR: frei0r.h header not found"; }
+enabled gmp && require gmp gmp.h mpz_export -lgmp
enabled gnutls && require_pkg_config gnutls gnutls/gnutls.h gnutls_global_init
+enabled jni && { [ $target_os = "android" ] && check_header jni.h && enabled pthreads &&
+ check_lib "dlfcn.h" dlopen -ldl || die "ERROR: jni not found"; }
+enabled ladspa && { check_header ladspa.h || die "ERROR: ladspa.h header not found"; }
+enabled libiec61883 && require libiec61883 libiec61883/iec61883.h iec61883_cmp_connect -lraw1394 -lavc1394 -lrom1394 -liec61883
+enabled libass && require_pkg_config libass ass/ass.h ass_library_init
+enabled libbluray && require_pkg_config libbluray libbluray/bluray.h bd_open
enabled libbs2b && require_pkg_config libbs2b bs2b.h bs2b_open
+enabled libcelt && require libcelt celt/celt.h celt_decode -lcelt0 &&
+ { check_lib celt/celt.h celt_decoder_create_custom -lcelt0 ||
+ die "ERROR: libcelt must be installed and version must be >= 0.11.0."; }
+enabled libcaca && require_pkg_config caca caca.h caca_create_canvas
enabled libdc1394 && require_pkg_config libdc1394-2 dc1394/dc1394.h dc1394_new
-enabled libdcadec && require libdcadec libdcadec/dca_context.h dcadec_context_create -ldcadec
-enabled libfaac && require libfaac "stdint.h faac.h" faacEncGetVersion -lfaac
-enabled libfdk_aac && require_pkg_config fdk-aac "fdk-aac/aacenc_lib.h" aacEncOpen
+enabled libfdk_aac && { use_pkg_config fdk-aac "fdk-aac/aacenc_lib.h" aacEncOpen ||
+ { require libfdk_aac fdk-aac/aacenc_lib.h aacEncOpen -lfdk-aac &&
+ warn "using libfdk without pkg-config"; } }
- flite_libs="-lflite_cmu_time_awb -lflite_cmu_us_awb -lflite_cmu_us_kal -lflite_cmu_us_kal16 -lflite_cmu_us_rms -lflite_cmu_us_slt -lflite_usenglish -lflite_cmulex -lflite"
- enabled libflite && require libflite "flite/flite.h" flite_init $flite_libs
++flite_extralibs="-lflite_cmu_time_awb -lflite_cmu_us_awb -lflite_cmu_us_kal -lflite_cmu_us_kal16 -lflite_cmu_us_rms -lflite_cmu_us_slt -lflite_usenglish -lflite_cmulex -lflite"
++enabled libflite && require libflite "flite/flite.h" flite_init $flite_extralibs
+enabled fontconfig && enable libfontconfig
enabled libfontconfig && require_pkg_config fontconfig "fontconfig/fontconfig.h" FcInit
enabled libfreetype && require_pkg_config freetype2 "ft2build.h FT_FREETYPE_H" FT_Init_FreeType
+enabled libfribidi && require_pkg_config fribidi fribidi.h fribidi_version_info
+enabled libgme && require libgme gme/gme.h gme_new_emu -lgme -lstdc++
enabled libgsm && { for gsm_hdr in "gsm.h" "gsm/gsm.h"; do
check_lib "${gsm_hdr}" gsm_create -lgsm && break;
done || die "ERROR: libgsm not found"; }
@@@ -5864,24 -4689,6 +5864,24 @@@ enabled mmal && { check_li
check_lib interface/mmal/mmal.h mmal_port_connect -lmmal_core -lmmal_util -lmmal_vc_client -lbcm_host; } ||
die "ERROR: mmal not found" &&
check_func_headers interface/mmal/mmal.h "MMAL_PARAMETER_VIDEO_MAX_NUM_CALLBACKS"; }
+enabled netcdf && require_pkg_config netcdf netcdf.h nc_inq_libvers
- enabled openal && { { for al_libs in "${OPENAL_LIBS}" "-lopenal" "-lOpenAL32"; do
- check_lib 'AL/al.h' alGetError "${al_libs}" && break; done } ||
++enabled openal && { { for al_extralibs in "${OPENAL_LIBS}" "-lopenal" "-lOpenAL32"; do
++ check_lib 'AL/al.h' alGetError "${al_extralibs}" && break; done } ||
+ die "ERROR: openal not found"; } &&
+ { check_cpp_condition "AL/al.h" "defined(AL_VERSION_1_1)" ||
+ die "ERROR: openal must be installed and version must be 1.1 or compatible"; }
+enabled opencl && { check_lib OpenCL/cl.h clEnqueueNDRangeKernel -Wl,-framework,OpenCL ||
+ check_lib CL/cl.h clEnqueueNDRangeKernel -lOpenCL ||
+ die "ERROR: opencl not found"; } &&
+ { check_cpp_condition "OpenCL/cl.h" "defined(CL_VERSION_1_2)" ||
+ check_cpp_condition "CL/cl.h" "defined(CL_VERSION_1_2)" ||
+ die "ERROR: opencl must be installed and version must be 1.2 or compatible"; }
+enabled opengl && { check_lib GL/glx.h glXGetProcAddress "-lGL" ||
+ check_lib windows.h wglGetProcAddress "-lopengl32 -lgdi32" ||
+ check_lib OpenGL/gl3.h glGetError "-Wl,-framework,OpenGL" ||
+ check_lib ES2/gl.h glGetError "-isysroot=${sysroot} -Wl,-framework,OpenGLES" ||
+ die "ERROR: opengl not found."
+ }
enabled omx_rpi && { check_header OMX_Core.h ||
{ ! enabled cross_compile && add_cflags -isystem/opt/vc/include/IL && check_header OMX_Core.h ; } ||
die "ERROR: OpenMAX IL headers not found"; }
@@@ -5892,66 -4700,31 +5892,66 @@@ enabled openssl && { use_pkg_
check_lib openssl/ssl.h SSL_library_init -lssl32 -leay32 ||
check_lib openssl/ssl.h SSL_library_init -lssl -lcrypto -lws2_32 -lgdi32 ||
die "ERROR: openssl not found"; }
-
-enabled gnutls && check_lib gmp.h mpz_export -lgmp && enable gmp
-
-if enabled nvenc; then
- check_header nvEncodeAPI.h || die "ERROR: nvEncodeAPI.h not found."
- check_cpp_condition nvEncodeAPI.h "NVENCAPI_MAJOR_VERSION >= 6" ||
- die "ERROR: NVENC API version 5 or older is not supported"
+enabled qtkit_indev && { check_header_objcc QTKit/QTKit.h || disable qtkit_indev; }
+
+if enabled gcrypt; then
+ GCRYPT_CONFIG="${cross_prefix}libgcrypt-config"
+ if "${GCRYPT_CONFIG}" --version > /dev/null 2>&1; then
+ gcrypt_cflags=$("${GCRYPT_CONFIG}" --cflags)
- gcrypt_libs=$("${GCRYPT_CONFIG}" --libs)
- check_func_headers gcrypt.h gcry_mpi_new $gcrypt_cflags $gcrypt_libs ||
++ gcrypt_extralibs=$("${GCRYPT_CONFIG}" --libs)
++ check_func_headers gcrypt.h gcry_mpi_new $gcrypt_cflags $gcrypt_extralibs ||
+ die "ERROR: gcrypt not found"
- add_cflags $gcrypt_cflags && add_extralibs $gcrypt_libs
++ add_cflags $gcrypt_cflags && add_extralibs $gcrypt_extralibs
+ else
+ require gcrypt gcrypt.h gcry_mpi_new -lgcrypt
+ fi
fi
-if check_pkg_config sdl SDL_events.h SDL_PollEvent; then
- check_cpp_condition SDL.h "(SDL_MAJOR_VERSION<<16 | SDL_MINOR_VERSION<<8 | SDL_PATCHLEVEL) >= 0x010201" $sdl_cflags &&
- check_cpp_condition SDL.h "(SDL_MAJOR_VERSION<<16 | SDL_MINOR_VERSION<<8 | SDL_PATCHLEVEL) < 0x010300" $sdl_cflags &&
- enable sdl
+disabled sdl && disable sdl2
+if ! disabled sdl2; then
+ SDL2_CONFIG="${cross_prefix}sdl2-config"
+ if check_pkg_config sdl2 SDL_events.h SDL_PollEvent; then
+ check_cpp_condition SDL.h "(SDL_MAJOR_VERSION<<16 | SDL_MINOR_VERSION<<8 | SDL_PATCHLEVEL) >= 0x020001" $sdl2_cflags &&
+ check_cpp_condition SDL.h "(SDL_MAJOR_VERSION<<16 | SDL_MINOR_VERSION<<8 | SDL_PATCHLEVEL) < 0x020100" $sdl2_cflags &&
- check_func SDL_Init $sdl2_libs $sdl2_cflags && enable sdl2
++ check_func SDL_Init $sdl2_extralibs $sdl2_cflags && enable sdl2
+ else
+ if "${SDL2_CONFIG}" --version > /dev/null 2>&1; then
+ sdl2_cflags=$("${SDL2_CONFIG}" --cflags)
- sdl2_libs=$("${SDL2_CONFIG}" --libs)
++ sdl2_extralibs=$("${SDL2_CONFIG}" --libs)
+ check_cpp_condition SDL.h "(SDL_MAJOR_VERSION<<16 | SDL_MINOR_VERSION<<8 | SDL_PATCHLEVEL) >= 0x020001" $sdl2_cflags &&
+ check_cpp_condition SDL.h "(SDL_MAJOR_VERSION<<16 | SDL_MINOR_VERSION<<8 | SDL_PATCHLEVEL) < 0x020100" $sdl2_cflags &&
- check_func SDL_Init $sdl2_libs $sdl2_cflags && enable sdl2
++ check_func SDL_Init $sdl2_extralibs $sdl2_cflags && enable sdl2
+ fi
+ fi
+ if test $target_os = "mingw32"; then
- sdl2_libs="$sdl2_libs -mconsole"
++ sdl2_extralibs="$sdl2_extralibs -mconsole"
+ fi
fi
- enabled sdl2 && enable sdl && add_cflags $sdl2_cflags && add_extralibs $sdl2_libs
++enabled sdl2 && enable sdl && add_cflags $sdl2_cflags && add_extralibs $sdl2_extralibs
-! disabled pod2man && check_cmd pod2man --help && enable pod2man || disable pod2man
-! disabled texi2html && check_cmd texi2html -version && enable texi2html || disable texi2html
+disabled securetransport || { check_func SecIdentityCreate "-Wl,-framework,CoreFoundation -Wl,-framework,Security" &&
+ check_lib "Security/SecureTransport.h Security/Security.h" "SSLCreateContext SecItemImport" "-Wl,-framework,CoreFoundation -Wl,-framework,Security" &&
+ enable securetransport; }
+
+disabled schannel || { check_func_headers "windows.h security.h" InitializeSecurityContext -DSECURITY_WIN32 -lsecur32 &&
+ check_cpp_condition winerror.h "defined(SEC_I_CONTEXT_EXPIRED)" && enable schannel && add_extralibs -lsecur32; }
+
+makeinfo --version > /dev/null 2>&1 && enable makeinfo || disable makeinfo
+enabled makeinfo \
+ && [ 0$(makeinfo --version | grep "texinfo" | sed 's/.*texinfo[^0-9]*\([0-9]*\)\..*/\1/') -ge 5 ] \
+ && enable makeinfo_html || disable makeinfo_html
+disabled makeinfo_html && texi2html --help 2> /dev/null | grep -q 'init-file' && enable texi2html || disable texi2html
+perl -v > /dev/null 2>&1 && enable perl || disable perl
+pod2man --help > /dev/null 2>&1 && enable pod2man || disable pod2man
+rsync --help 2> /dev/null | grep -q 'contimeout' && enable rsync_contimeout || disable rsync_contimeout
check_header linux/fb.h
+check_header linux/videodev.h
check_header linux/videodev2.h
-check_struct linux/videodev2.h "struct v4l2_frmivalenum" discrete
-
-check_header AVFoundation/AVFoundation.h
+check_code cc linux/videodev2.h "struct v4l2_frmsizeenum vfse; vfse.discrete.width = 0;" && enable_safe struct_v4l2_frmivalenum_discrete
check_header sys/videoio.h
+check_code cc sys/videoio.h "struct v4l2_frmsizeenum vfse; vfse.discrete.width = 0;" && enable_safe struct_v4l2_frmivalenum_discrete
check_func_headers "windows.h vfw.h" capCreateCaptureWindow "$vfwcap_indev_extralibs"
# check that WM_CAP_DRIVER_CONNECT is defined to the proper value
@@@ -5993,47 -4757,26 +5993,47 @@@ 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_libs $xcb_shm_libs $xcb_xfixes_libs $xcb_shape_libs
++ 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 vaapi && require vaapi va/va.h vaInitialize -lva
+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 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 -5054,10 +6363,45 @@@ check_deps $CONFIG_LIST
$HAVE_LIST \
$ALL_COMPONENTS \
-enabled_all dxva2 CoTaskMemFree &&
- prepend avconv_libs $($ldflags_filter "-lole32") &&
+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_libs $($ldflags_filter "-lole32") &&
++ 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