--enable-libspeex enable Speex de/encoding via libspeex [no]
--enable-libssh enable SFTP protocol via libssh [no]
--enable-libstagefright-h264 enable H.264 decoding via libstagefright [no]
+ --enable-libtesseract enable Tesseract, needed for ocr filter [no]
--enable-libtheora enable Theora encoding via libtheora [no]
--enable-libtwolame enable MP2 encoding via libtwolame [no]
--enable-libutvideo enable Ut Video encoding and decoding via libutvideo [no]
}
quotes='""'
+if test -t 1 && which tput >/dev/null; then
+ ncolors=$(tput colors)
+ if test -n "$ncolors" && test $ncolors -ge 8; then
+ bold_color=$(tput bold)
+ warn_color=$(tput setaf 3)
+ error_color=$(tput setaf 1)
+ reset_color=$(tput sgr0)
+ fi
+ # 72 used instead of 80 since that's the default of pr
+ ncols=$(tput cols)
+fi
+: ${ncols:=72}
log(){
echo "$@" >> $logfile
log END $1
}
-echolog(){
- log "$@"
- echo "$@"
-}
-
warn(){
log "WARNING: $*"
WARNINGS="${WARNINGS}WARNING: $*\n"
}
die(){
- echolog "$@"
+ log "$@"
+ echo "$error_color$bold_color$@$reset_color"
cat <<EOF
If you think configure made a mistake, make sure you are using the latest
}
enabled(){
- test "${1#!}" = "$1" && op== || op=!=
+ test "${1#!}" = "$1" && op='=' || op=!=
eval test "x\$${1#!}" $op "xyes"
}
disabled(){
- test "${1#!}" = "$1" && op== || op=!=
+ test "${1#!}" = "$1" && op='=' || op=!=
eval test "x\$${1#!}" $op "xno"
}
libspeex
libssh
libstagefright_h264
+ libtesseract
libtheora
libtwolame
libutvideo
llauddsp
llviddsp
lpc
+ lzf
me_cmp
mpeg_er
mpegaudio
dvvideo_decoder_select="dvprofile idctdsp"
dvvideo_encoder_select="dvprofile fdctdsp me_cmp pixblockdsp"
dxa_decoder_select="zlib"
+dxv_decoder_select="lzf texturedsp"
eac3_decoder_select="ac3_decoder"
eac3_encoder_select="ac3_encoder"
eamad_decoder_select="aandcttables blockdsp bswapdsp idctdsp mpegvideo"
# hardware accelerators
crystalhd_deps="libcrystalhd_libcrystalhd_if_h"
-d3d11va_deps="d3d11_h dxva_h ID3D11VideoDecoder"
+d3d11va_deps="d3d11_h dxva_h ID3D11VideoDecoder ID3D11VideoContext"
dxva2_deps="dxva2api_h DXVA2_ConfigPictureDecode"
vaapi_deps="va_va_h"
vda_deps="VideoDecodeAcceleration_VDADecoder_h pthreads CoreServices_CoreServices_h"
negate_filter_deps="lut_filter"
perspective_filter_deps="gpl"
pp7_filter_deps="gpl"
+ocr_filter_deps="libtesseract"
ocv_filter_deps="libopencv"
owdenoise_filter_deps="gpl"
pan_filter_deps="swresample"
exit 1
}
-print_3_columns() {
- cat | tr ' ' '\n' | sort | pr -r -3 -t
+print_in_columns() {
+ cols=$(expr $ncols / 24)
+ cat | tr ' ' '\n' | sort | pr -r "-$cols" -w $ncols -t
}
show_list() {
suffix=_$1
shift
- echo $* | sed s/$suffix//g | print_3_columns
+ echo $* | sed s/$suffix//g | print_in_columns
exit 0
}
exesuf() {
case $1 in
- mingw32*|win32|win64|cygwin*|*-dos|freedos|opendos|os/2*|symbian) echo .exe ;;
+ mingw32*|mingw64*|win32|win64|cygwin*|*-dos|freedos|opendos|os/2*|symbian) echo .exe ;;
esac
}
enabled_any pic shared x86_64 ||
{ check_cflags -mdynamic-no-pic && add_asflags -mdynamic-no-pic; }
;;
- mingw32*)
+ mingw32*|mingw64*)
if test $target_os = "mingw32ce"; then
disable network
else
check_type "windows.h dxva.h" "DXVA_PicParams_HEVC" -DWINAPI_FAMILY=WINAPI_FAMILY_DESKTOP_APP -D_CRT_BUILD_DESKTOP_APP=0
check_type "windows.h d3d11.h" "ID3D11VideoDecoder"
+check_type "windows.h d3d11.h" "ID3D11VideoContext"
check_type "d3d9.h dxva2api.h" DXVA2_ConfigPictureDecode -D_WIN32_WINNT=0x0602
check_type "va/va.h" "VAPictureParameterBufferHEVC"
enabled libsmbclient && { use_pkg_config smbclient libsmbclient.h smbc_init ||
require smbclient libsmbclient.h smbc_init -lsmbclient; }
enabled libsnappy && require snappy snappy-c.h snappy_compress -lsnappy
-enabled libsoxr && require libsoxr soxr.h soxr_create -lsoxr
+enabled libsoxr && require libsoxr soxr.h soxr_create -lsoxr && LIBSOXR="-lsoxr"
enabled libssh && require_pkg_config libssh libssh/sftp.h sftp_init
enabled libspeex && require_pkg_config speex speex/speex.h speex_decoder_init -lspeex
enabled libstagefright_h264 && require_cpp libstagefright_h264 "binder/ProcessState.h media/stagefright/MetaData.h
media/stagefright/MediaBufferGroup.h media/stagefright/MediaDebug.h media/stagefright/MediaDefs.h
media/stagefright/OMXClient.h media/stagefright/OMXCodec.h" android::OMXClient -lstagefright -lmedia -lutils -lbinder -lgnustl_static
+enabled libtesseract && require_pkg_config tesseract tesseract/capi.h TessBaseAPICreate
enabled libtheora && require libtheora theora/theoraenc.h th_info_init -ltheoraenc -ltheoradec -logg
enabled libtwolame && require libtwolame twolame.h twolame_init -ltwolame &&
{ check_lib twolame.h twolame_encode_buffer_float32_interleaved -ltwolame ||
echo
echo "Enabled programs:"
-print_enabled '' $PROGRAM_LIST | print_3_columns
+print_enabled '' $PROGRAM_LIST | print_in_columns
echo
echo "External libraries:"
-print_enabled '' $EXTERNAL_LIBRARY_LIST | print_3_columns
+print_enabled '' $EXTERNAL_LIBRARY_LIST | print_in_columns
echo
for type in decoder encoder hwaccel parser demuxer muxer protocol filter bsf indev outdev; do
echo "Enabled ${type}s:"
eval list=\$$(toupper $type)_LIST
- print_enabled '_*' $list | print_3_columns
+ print_enabled '_*' $list | print_in_columns
echo
done
cp_if_changed $TMPH libavutil/avconfig.h
if test -n "$WARNINGS"; then
- printf "\n$WARNINGS"
+ printf "\n%s%s$WARNINGS%s" "$warn_color" "$bold_color" "$reset_color"
enabled fatal_warnings && exit 1
fi
pkgconfig_generate libpostproc "FFmpeg postprocessing library" "$LIBPOSTPROC_VERSION" ""
pkgconfig_generate libavresample "Libav audio resampling library" "$LIBAVRESAMPLE_VERSION" "$LIBM"
pkgconfig_generate libswscale "FFmpeg image rescaling library" "$LIBSWSCALE_VERSION" "$LIBM"
-pkgconfig_generate libswresample "FFmpeg audio resampling library" "$LIBSWRESAMPLE_VERSION" "$LIBM"
+pkgconfig_generate libswresample "FFmpeg audio resampling library" "$LIBSWRESAMPLE_VERSION" "$LIBM $LIBSOXR"