[MPlayer-dev-eng] [PATCH 2/2] configure: Detect libaom and enable the lavc libaom-av1 decoder
Alexander Strasser
eclipse7 at gmx.net
Tue Jan 7 09:28:09 EET 2020
The codecs.conf entry was already added in SVN r38156 .
This change allows to autodetect/enable the libaom-av1 decoder for
internal FFmpeg.
Signed-off-by: Alexander Strasser <eclipse7 at gmx.net>
---
configure | 32 ++++++++++++++++++++++++++++++++
1 file changed, 32 insertions(+)
diff --git a/configure b/configure
index bd24b0649..6e08b5760 100755
--- a/configure
+++ b/configure
@@ -413,6 +413,7 @@ Codecs:
--disable-x264-lavc disable x264 in libavcodec [autodetect]
--disable-libvpx-lavc disable libvpx in libavcodec [autodetect]
--disable-libdav1d-lavc disable libdav1d in libavcodec [autodetect]
+ --disable-libaom-lavc disable libaom in libavcodec [autodetect]
--disable-libnut disable libnut [autodetect]
--disable-ffmpeg_a disable static FFmpeg [autodetect]
--disable-ffmpeg_so disable shared FFmpeg [autodetect]
@@ -808,6 +809,7 @@ _x264=auto
_x264_lavc=auto
_libvpx_lavc=auto
_libdav1d_lavc=auto
+_libaom_lavc=auto
_libnut=auto
_lirc=auto
_lircc=auto
@@ -7525,6 +7527,35 @@ fi
echores "$_libdav1d_lavc"
+echocheck "libaom"
+if test "$_libaom_lavc" = auto; then
+ _libaom_lavc=no
+ if test "$ffmpeg_a" != yes; then
+ res_comment="dynamic linking to libaom is irrelevant when using dynamic FFmpeg"
+ else
+ cat > $TMPC << EOF
+#include <aom/aom_decoder.h>
+int main(void) {
+ const char *version_lib = aom_codec_version_str();
+ return version_lib[0];
+}
+EOF
+ for ld_tmp in "-laom" "-laom $ld_pthread" ; do
+ cc_check $ld_tmp && _libaom_lavc=yes && extra_ldflags="$extra_ldflags $ld_tmp" && break
+ done
+ fi
+fi
+if test "$_libaom_lavc" = yes ; then
+ def_libaom_lavc='#define CONFIG_LIBAOM 1'
+ libavdecoders="$libavdecoders LIBAOM_AV1_DECODER"
+ codecmodules="libaom $codecmodules"
+else
+ def_libaom_lavc='#define CONFIG_LIBAOM 0'
+ nocodecmodules="libaom $nocodecmodules"
+fi
+echores "$_libaom_lavc"
+
+
echocheck "libnut"
if test "$_libnut" = auto ; then
_libnut=no
@@ -9270,6 +9301,7 @@ $def_emmintrin_h
/* external libraries */
$def_bzlib
$def_crystalhd
+$def_libaom_lavc
$def_libdav1d_lavc
$def_libgsm
$def_libopencore_amrnb
--
More information about the MPlayer-dev-eng
mailing list