--enable-opengl enable OpenGL rendering [no]
--enable-openssl enable openssl [no]
--enable-x11grab enable X11 grabbing [no]
+ --disable-xlib disable xlib [autodetect]
--disable-zlib disable zlib [autodetect]
-Advanced options (experts only):
+Toolchain options:
+ --arch=ARCH select architecture [$arch]
+ --cpu=CPU select the minimum required CPU (affects
+ instruction selection, may crash on older CPUs)
--cross-prefix=PREFIX use PREFIX for compilation tools [$cross_prefix]
+ --progs-suffix=SUFFIX program name suffix []
--enable-cross-compile assume a cross-compiler is used
--sysroot=PATH root of cross-build tree
--sysinclude=PATH location of cross-build system headers
--target-samples=DIR path to samples directory on target
--tempprefix=PATH force fixed dir/prefix instead of mktemp for checks
--toolchain=NAME set tool defaults according to NAME
+ --pkg-config=PKGCONFIG use pkg-config tool PKGCONFIG [$pkg_config_default]
--nm=NM use nm tool NM [$nm_default]
--ar=AR use archive tool AR [$ar_default]
--as=AS use assembler AS [$as_default]
--cxx=CXX use C compiler CXX [$cxx_default]
--dep-cc=DEPCC use dependency generator DEPCC [$cc_default]
--ld=LD use linker LD [$ld_default]
+ --pkg-config=PKGCONF use pkg-config PKGCONF [$pkg_config_default]
+ --pkg-config-flags=FLAGS pass additional flags to pkgconf []
--host-cc=HOSTCC use host C compiler HOSTCC
--host-cflags=HCFLAGS use HCFLAGS when compiling for host
--host-cppflags=HCPPFLAGS use HCPPFLAGS when compiling for host
--extra-version=STRING version string suffix []
--optflags=OPTFLAGS override optimization-related compiler flags
--build-suffix=SUFFIX library name suffix []
- --malloc-prefix=PREFIX prefix malloc and related names with PREFIX
- --progs-suffix=SUFFIX program name suffix []
- --arch=ARCH select architecture [$arch]
- --cpu=CPU select the minimum required CPU (affects
- instruction selection, may crash on older CPUs)
--enable-pic build position-independent code
- --enable-sram allow use of on-chip SRAM
--enable-thumb compile for Thumb instruction set
+ --enable-lto use link-time optimization
+
+Advanced options (experts only):
+ --malloc-prefix=PREFIX prefix malloc and related names with PREFIX
--disable-symver disable symbol versioning
--enable-hardcoded-tables use hardcoded tables instead of runtime generation
--disable-safe-bitstream-reader
disable buffer boundary checking in bitreaders
(faster, but may crash)
--enable-memalign-hack emulate memalign, interferes with memory debuggers
- --enable-lto use link-time optimization
+ --enable-sram allow use of on-chip SRAM
Optimization options (experts only):
--disable-asm disable all assembler optimizations
--disable-armv6t2 disable armv6t2 optimizations
--disable-vfp disable VFP optimizations
--disable-neon disable NEON optimizations
- --disable-vis disable VIS optimizations
--disable-inline-asm disable use of inline assembler
--disable-yasm disable use of yasm assembler
--disable-mips32r2 disable MIPS32R2 optimizations
funcs="$3"
shift 3
check_cmd $pkg_config --exists --print-errors $pkgandversion || return
- pkg_cflags=$($pkg_config --cflags $pkg)
- pkg_libs=$($pkg_config --libs $pkg)
+ 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
check_code ld "$headers" "$builtin" "cc" "$@" && enable "$name"
}
+check_compile_assert(){
+ log check_compile_assert "$@"
+ name=$1
+ headers=$2
+ condition=$3
+ shift 3
+ disable "$name"
+ check_code cc "$headers" "char c[2 * !!($condition) - 1]" "$@" && enable "$name"
+}
+
require(){
name="$1"
header="$2"
opengl
openssl
x11grab
+ xlib
zlib
"
network
nonfree
pic
+ pod2man
raise_major
rdft
runtime_cpudetect
xmm_clobber_test
"
-THREADS_LIST='
+THREADS_LIST="
pthreads
- w32threads
os2threads
-'
+ w32threads
+"
-ATOMICS_LIST='
+ATOMICS_LIST="
atomics_gcc
atomics_suncc
atomics_win32
-'
+"
-ARCH_LIST='
+ARCH_LIST="
aarch64
alpha
arm
x86
x86_32
x86_64
-'
+"
-ARCH_EXT_LIST_ARM='
+ARCH_EXT_LIST_ARM="
armv5te
armv6
armv6t2
neon
vfp
vfpv3
-'
+"
-ARCH_EXT_LIST_X86_SIMD='
+ARCH_EXT_LIST_X86_SIMD="
amd3dnow
amd3dnowext
avx
sse42
ssse3
xop
-'
+"
ARCH_EXT_LIST_X86="
$ARCH_EXT_LIST_X86_SIMD
$ARCH_EXT_LIST_X86
altivec
ppc4xx
- vis
mipsfpu
mips32r2
mipsdspr1
mipsdspr2
"
-HAVE_LIST_CMDLINE='
+HAVE_LIST_CMDLINE="
inline_asm
symver
yasm
-'
+"
-HAVE_LIST_PUB='
+HAVE_LIST_PUB="
bigendian
fast_unaligned
incompatible_libav_abi
incompatible_fork_abi
-'
+"
MATH_FUNCS="
atanf
$ARCH_EXT_LIST
$(add_suffix _external $ARCH_EXT_LIST)
$(add_suffix _inline $ARCH_EXT_LIST)
+ $ATOMICS_LIST
$HAVE_LIST_CMDLINE
$HAVE_LIST_PUB
- $THREADS_LIST
- $ATOMICS_LIST
$MATH_FUNCS
+ $THREADS_LIST
access
aligned_malloc
aligned_stack
fast_clz
fast_cmov
fcntl
+ flt_lim
fork
getaddrinfo
gethrtime
GetProcessAffinityMask
GetProcessMemoryInfo
GetProcessTimes
- GetSystemTimeAsFileTime
getrusage
getservbyport
+ GetSystemTimeAsFileTime
gettimeofday
glob
glXGetProcAddress
gsm_h
ibm_asm
inet_aton
- io_h
inline_asm_labels
+ io_h
isatty
jack_port_get_latency_range
kbhit
localtime_r
loongson
lzo1x_999_compress
+ mach_absolute_time
+ mach_mach_time_h
machine_ioctl_bt848_h
machine_ioctl_meteor_h
machine_rw_barrier
symver_asm_label
symver_gnu_asm
sync_val_compare_and_swap
- sysconf
- sysctl
sys_mman_h
sys_param_h
sys_resource_h
sys_time_h
sys_un_h
sys_videoio_h
+ sysconf
+ sysctl
termios_h
texi2html
threads
stripping
"
-PATHS_LIST='
+PATHS_LIST="
bindir
datadir
docdir
mandir
prefix
shlibdir
-'
+"
CMDLINE_SET="
$PATHS_LIST
nm
optflags
pkg_config
+ pkg_config_flags
progs_suffix
random_seed
samples
altivec_deps="ppc"
ppc4xx_deps="ppc"
-vis_deps="sparc"
-
cpunop_deps="i686"
x86_64_select="i686"
x86_64_suggest="fast_cmov"
dct_select="rdft"
error_resilience_select="dsputil"
frame_thread_encoder_deps="encoders threads"
-lpc_select="dsputil"
mdct_select="fft"
rdft_select="fft"
mpegaudio_select="mpegaudiodsp"
mpegaudiodsp_select="dct"
mpegvideo_select="dsputil h264chroma hpeldsp videodsp"
-mpegvideoenc_select="mpegvideo"
+mpegvideoenc_select="dsputil mpegvideo"
# decoders / encoders
aac_decoder_select="mdct sinewin"
eac3_encoder_select="ac3_encoder"
eamad_decoder_select="aandcttables dsputil mpegvideo"
eatgq_decoder_select="aandcttables"
-eatqi_decoder_select="aandcttables error_resilience mpegvideo"
+eatqi_decoder_select="aandcttables dsputil error_resilience mpegvideo"
exr_decoder_select="zlib"
-ffv1_decoder_select="dsputil golomb rangecoder"
-ffv1_encoder_select="dsputil rangecoder"
+ffv1_decoder_select="golomb rangecoder"
+ffv1_encoder_select="rangecoder"
ffvhuff_decoder_select="huffyuv_decoder"
ffvhuff_encoder_select="huffyuv_encoder"
fic_decoder_select="dsputil golomb"
metasound_decoder_select="lsp mdct sinewin"
mimic_decoder_select="dsputil hpeldsp"
mjpeg_decoder_select="dsputil hpeldsp exif"
+mjpeg_encoder_select="aandcttables mpegvideoenc"
mjpegb_decoder_select="mjpeg_decoder"
-mjpeg_encoder_select="aandcttables dsputil mpegvideoenc"
-mlp_decoder_select="dsputil mlp_parser"
+mlp_decoder_select="mlp_parser"
motionpixels_decoder_select="dsputil"
mp1_decoder_select="mpegaudio"
mp1float_decoder_select="mpegaudio"
mp3on4_decoder_select="mpegaudio"
mp3on4float_decoder_select="mpegaudio"
mpc7_decoder_select="dsputil mpegaudiodsp"
-mpc8_decoder_select="dsputil mpegaudiodsp"
+mpc8_decoder_select="mpegaudiodsp"
mpeg_xvmc_decoder_deps="X11_extensions_XvMClib_h"
mpeg_xvmc_decoder_select="mpeg2video_decoder"
mpeg1video_decoder_select="error_resilience mpegvideo"
svq3_decoder_suggest="zlib"
tak_decoder_select="dsputil"
theora_decoder_select="vp3_decoder"
+thp_decoder_select="mjpeg_decoder"
tiff_decoder_suggest="zlib"
tiff_encoder_suggest="zlib"
-thp_decoder_select="mjpeg_decoder"
truehd_decoder_select="mlp_parser"
truemotion2_decoder_select="dsputil"
truespeech_decoder_select="dsputil"
ffrtmphttp_protocol_select="http_protocol"
ftp_protocol_select="tcp_protocol"
gopher_protocol_select="network"
-httpproxy_protocol_select="tcp_protocol"
http_protocol_select="tcp_protocol"
+httpproxy_protocol_select="tcp_protocol"
https_protocol_select="tls_protocol"
librtmp_protocol_deps="librtmp"
librtmpe_protocol_deps="librtmp"
mptestsrc_filter_deps="gpl"
negate_filter_deps="lut_filter"
perspective_filter_deps="gpl"
-resample_filter_deps="avresample"
ocv_filter_deps="libopencv"
owdenoise_filter_deps="gpl"
pan_filter_deps="swresample"
pp_filter_deps="gpl postproc"
pullup_filter_deps="gpl"
removelogo_filter_deps="avcodec avformat swscale"
+resample_filter_deps="avresample"
sab_filter_deps="gpl swscale"
scale_filter_deps="swscale"
smartblur_filter_deps="gpl swscale"
nogas=":"
-# machine
-arch_default=$(uname -m)
-cpu="generic"
-
# OS
target_os_default=$(tolower $(uname -s))
host_os=$target_os_default
+# machine
+if test "$target_os_default" = aix; then
+ arch_default=$(uname -p)
+else
+ arch_default=$(uname -m)
+fi
+cpu="generic"
+
# configurable options
enable $PROGRAM_LIST
enable $DOCUMENT_LIST
# Enable hwaccels by default.
enable dxva2 vaapi vdpau xvmc
+enable xlib
# build settings
SHFLAGS='-shared -Wl,-soname,$$(@F)'
add_ldflags -fprofile-arcs -ftest-coverage
;;
hardened)
- add_cflags -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fno-strict-overflow -fstack-protector-all
+ add_cflags -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fno-strict-overflow -fstack-protector-all
add_ldflags -Wl,-z,relro -Wl,-z,now
;;
?*)
case $cpu in
cypress|f93[04]|tsc701|sparcl*|supersparc|hypersparc|niagara|v[789])
cpuflags="-mcpu=$cpu"
- disable vis
;;
ultrasparc*|niagara[234])
cpuflags="-mcpu=$cpu"
add_ldflags -Wl,-z,now # calls to libots crash without this
fi
+check_compile_assert flt_lim "float.h limits.h" "DBL_MAX == (double)DBL_MAX" ||
+ add_cppflags '-I\$(SRC_PATH)/compat/float'
+
esc(){
echo "$*" | sed 's/%/%25/g;s/:/%3a/g'
}
enabled altivec || warn "Altivec disabled, possibly missing --cpu flag"
fi
-elif enabled sparc; then
-
- enabled vis && check_inline_asm vis '"pdist %f0, %f0, %f0"'
-
elif enabled x86; then
check_builtin rdtsc intrin.h "__rdtsc()"
check_func gettimeofday
check_func isatty
check_func localtime_r
+check_func mach_absolute_time
check_func ${malloc_prefix}memalign && enable memalign
check_func mkstemp
check_func mmap
check_func_headers windows.h Sleep
check_func_headers windows.h VirtualAlloc
check_func_headers glob.h glob
-check_func_headers "X11/Xlib.h X11/extensions/Xvlib.h" XvGetPortAttribute -lXv -lX11 -lXext
+enabled xlib &&
+ check_func_headers "X11/Xlib.h X11/extensions/Xvlib.h" XvGetPortAttribute -lXv -lX11 -lXext
check_header cl/cl.h
check_header direct.h
check_header dxva2api.h -D_WIN32_WINNT=0x0600
check_header io.h
check_header libcrystalhd/libcrystalhd_if.h
+check_header mach/mach_time.h
check_header malloc.h
check_header poll.h
check_header sys/mman.h
die "ERROR: libcdio-paranoia not found"
fi
-check_lib X11/Xlib.h XOpenDisplay -lX11 && enable xlib
+enabled xlib &&
+ check_lib X11/Xlib.h XOpenDisplay -lX11 || disable xlib
enabled x11grab &&
require Xext X11/extensions/XShm.h XShmCreateImage -lXext &&
echo "PPC 4xx optimizations ${ppc4xx-no}"
echo "dcbzl available ${dcbzl-no}"
fi
-if enabled sparc; then
- echo "VIS enabled ${vis-no}"
-fi
echo "debug symbols ${debug-no}"
echo "strip symbols ${stripping-no}"
echo "optimize for size ${small-no}"