Bug 1412558 - P2. Disable ffvp8 and ffvp9 decoders on Unixes 32 bits. r?Build
The system ffmpeg will be used instead or libvpx if not found.
MozReview-Commit-ID: GX5WWPOhPq9
--- a/media/ffvpx/config.h
+++ b/media/ffvpx/config.h
@@ -2,17 +2,17 @@
/* vim:set ts=2 sw=2 sts=2 et cindent: */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef MOZ_FFVPX_CONFIG_H
#define MOZ_FFVPX_CONFIG_H
#if defined(MOZ_FFVPX_FLACONLY)
-#if defined(MOZ_WIDGET_ANDROID) && !defined(HAVE_64BIT_BUILD)
+#if defined(MOZ_WIDGET_ANDROID) && defined(__arm__)
#include "config_android32.h"
#else
#include "config_flac.h"
#endif
#else // MOZ_FFVPX_FLACONLY
#if defined(XP_WIN)
// Avoid conflicts with mozilla-config.h
#if !defined(_MSC_VER)
--- a/old-configure.in
+++ b/old-configure.in
@@ -3214,17 +3214,24 @@ dnl = FFmpeg's ffvpx configuration
dnl ========================================================
MOZ_FFVPX=
MOZ_FFVPX_FLACONLY=
case "$CPU_ARCH" in
x86|x86_64)
MOZ_FFVPX=1
dnl Use same conditional as MOZ_LIBAV_FFT to enable FFmpeg's ffvpx assembly decoder.
- FFVPX_ASFLAGS=$LIBAV_FFT_ASFLAGS
+ if test -n "$LIBAV_FFT_ASFLAGS"; then
+ FFVPX_ASFLAGS=$LIBAV_FFT_ASFLAGS
+ else
+ dnl On x86 system with assembly optimizations disabled, the ffvp9 and
+ dnl ffvp8 decoders give worse performance than libvpx ones. So we only
+ dnl enable the FFmpeg FLAC decoder on those machines.
+ MOZ_FFVPX_FLACONLY=1
+ fi
;;
arm*|aarch64)
MOZ_FFVPX=1
MOZ_FFVPX_FLACONLY=1
dnl Use same conditional as MOZ_LIBVPX to enable FFmpeg's ffvpx assembly decoder.
dnl aarch 64 FLAC decoder for now will be C only.
FFVPX_ASFLAGS=$VPX_ASFLAGS
;;