[MPlayer-cvslog] r38161 - trunk/configure

al subversion at mplayerhq.hu
Wed Jan 15 23:41:39 EET 2020


Author: al
Date: Wed Jan 15 23:41:39 2020
New Revision: 38161

Log:
configure: Detect libaom and enable the lavc libaom-av1 decoder

The codecs.conf entry was already added in SVN r38156 .

This change allows to autodetect/enable the libaom-av1 decoder for
internal FFmpeg.

Modified:
   trunk/configure

Modified: trunk/configure
==============================================================================
--- trunk/configure	Wed Jan 15 23:36:35 2020	(r38160)
+++ trunk/configure	Wed Jan 15 23:41:39 2020	(r38161)
@@ -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
@@ -1262,6 +1264,8 @@ for ac_option do
   --disable-libvpx-lavc)  _libvpx_lavc=no   ;;
   --enable-libdav1d-lavc)   _libdav1d_lavc=yes  ;;
   --disable-libdav1d-lavc)  _libdav1d_lavc=no   ;;
+  --enable-libaom-lavc)   _libaom_lavc=yes  ;;
+  --disable-libaom-lavc)  _libaom_lavc=no   ;;
   --enable-libnut)      _libnut=yes     ;;
   --disable-libnut)     _libnut=no      ;;
   --enable-libopencore_amrnb)   _libopencore_amrnb=yes  ;;
@@ -7527,6 +7531,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
@@ -9272,6 +9305,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-cvslog mailing list