mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-27 19:07:31 +09:00
Issue #2332 - Update to libvpx 1.6.1
Backport of Bugzilla 1223692 and 1331498
This commit is contained in:
parent
6fdb3ac961
commit
b860c5fe95
1338 changed files with 350431 additions and 155085 deletions
|
|
@ -1,4 +1,5 @@
|
|||
# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
|
||||
# vim: set filetype=python:
|
||||
# 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/.
|
||||
|
|
@ -8,35 +9,47 @@ with Files('*'):
|
|||
|
||||
include('sources.mozbuild')
|
||||
|
||||
EXPORTS.vpx += files['EXPORTS']
|
||||
|
||||
SOURCES += files['SOURCES']
|
||||
|
||||
if CONFIG['MOZ_VPX_ERROR_CONCEALMENT']:
|
||||
SOURCES += files['ERROR_CONCEALMENT']
|
||||
|
||||
if CONFIG['VPX_USE_YASM']:
|
||||
USE_YASM = True
|
||||
|
||||
if CONFIG['VPX_X86_ASM']:
|
||||
SOURCES += files['X86_ASM']
|
||||
# Linux, Mac and Win share file lists for x86* but not configurations.
|
||||
if CONFIG['CPU_ARCH'] == 'x86_64':
|
||||
EXPORTS.vpx += files['X64_EXPORTS']
|
||||
SOURCES += files['X64_SOURCES']
|
||||
if CONFIG['OS_TARGET'] == 'WINNT':
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/win/x64/' % TOPSRCDIR ]
|
||||
CFLAGS += [ '-I%s/media/libvpx/config/win/x64/' % TOPSRCDIR ]
|
||||
elif CONFIG['OS_TARGET'] == 'Darwin':
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/mac/x64/' % TOPSRCDIR ]
|
||||
CFLAGS += [ '-I%s/media/libvpx/config/mac/x64/' % TOPSRCDIR ]
|
||||
else: # Android, Linux, BSDs, etc.
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/linux/x64/' % TOPSRCDIR ]
|
||||
CFLAGS += [ '-I%s/media/libvpx/config/linux/x64/' % TOPSRCDIR ]
|
||||
elif CONFIG['CPU_ARCH'] == 'x86':
|
||||
EXPORTS.vpx += files['IA32_EXPORTS']
|
||||
SOURCES += files['IA32_SOURCES']
|
||||
if CONFIG['OS_TARGET'] == 'WINNT':
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/win/ia32/' % TOPSRCDIR ]
|
||||
CFLAGS += [ '-I%s/media/libvpx/config/win/ia32/' % TOPSRCDIR ]
|
||||
elif CONFIG['OS_TARGET'] == 'Darwin':
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/mac/ia32/' % TOPSRCDIR ]
|
||||
CFLAGS += [ '-I%s/media/libvpx/config/mac/ia32/' % TOPSRCDIR ]
|
||||
else: # Android, Linux, BSDs, etc.
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/linux/ia32/' % TOPSRCDIR ]
|
||||
CFLAGS += [ '-I%s/media/libvpx/config/linux/ia32/' % TOPSRCDIR ]
|
||||
elif CONFIG['CPU_ARCH'] == 'arm':
|
||||
EXPORTS.vpx += files['ARM_EXPORTS']
|
||||
ASFLAGS += [
|
||||
'-I%s/media/libvpx/config/linux/arm/' % TOPSRCDIR,
|
||||
'-I%s/libvpx' % OBJDIR,
|
||||
]
|
||||
CFLAGS += [ '-I%s/media/libvpx/config/linux/arm/' % TOPSRCDIR ]
|
||||
|
||||
if '64' in CONFIG['OS_TEST']:
|
||||
SOURCES += files['X86-64_ASM']
|
||||
|
||||
#avx2 can be enabled on all supported compilters
|
||||
SOURCES += files['AVX2']
|
||||
|
||||
#postproc is only enabled on x86 with asm
|
||||
SOURCES += files['VP8_POSTPROC']
|
||||
|
||||
arm_asm_files = []
|
||||
if CONFIG['VPX_ARM_ASM']:
|
||||
arm_asm_files += files['ARM_ASM']
|
||||
arm_asm_files = files['ARM_SOURCES']
|
||||
|
||||
if CONFIG['VPX_AS_CONVERSION']:
|
||||
SOURCES += sorted([
|
||||
"!%s.s" % f if f.endswith('.asm') else f for f in arm_asm_files
|
||||
"!%s.S" % f if f.endswith('.asm') else f for f in arm_asm_files
|
||||
])
|
||||
else:
|
||||
SOURCES += sorted(arm_asm_files)
|
||||
|
|
@ -54,16 +67,12 @@ if CONFIG['VPX_ARM_ASM']:
|
|||
ASFLAGS += [
|
||||
'-no-integrated-as',
|
||||
]
|
||||
|
||||
# boolhuff_armv5te.asm defines the same functions as boolhuff.c instead of
|
||||
# using RTCD, so we have to make sure we only add one of the two.
|
||||
if 'vp8/encoder/arm/armv5te/boolhuff_armv5te.asm' not in arm_asm_files:
|
||||
SOURCES += [
|
||||
'vp8/encoder/boolhuff.c',
|
||||
]
|
||||
|
||||
if CONFIG['GKMEDIAS_SHARED_LIBRARY']:
|
||||
NO_VISIBILITY_FLAGS = True
|
||||
else:
|
||||
# Generic C-only configuration
|
||||
EXPORTS.vpx += files['GENERIC_EXPORTS']
|
||||
SOURCES += files['GENERIC_SOURCES']
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/generic/' % TOPSRCDIR ]
|
||||
CFLAGS += [ '-I%s/media/libvpx/config/generic/' % TOPSRCDIR ]
|
||||
|
||||
# We allow warnings for third-party code that can be updated from upstream.
|
||||
ALLOW_COMPILER_WARNINGS = True
|
||||
|
|
@ -85,13 +94,15 @@ if CONFIG['OS_TARGET'] == 'Android':
|
|||
if CONFIG['CLANG_CL'] or not CONFIG['_MSC_VER']:
|
||||
for f in SOURCES:
|
||||
if f.endswith('.c'):
|
||||
if 'sse2' in f:
|
||||
if 'sse2.c' in f:
|
||||
SOURCES[f].flags += CONFIG['SSE2_FLAGS']
|
||||
if 'ssse3' in f:
|
||||
if 'ssse3.c' in f:
|
||||
SOURCES[f].flags += ['-mssse3']
|
||||
if 'sse4' in f:
|
||||
if 'sse4.c' in f:
|
||||
SOURCES[f].flags += ['-msse4.1']
|
||||
if 'avx2' in f:
|
||||
if 'avx.c' in f:
|
||||
SOURCES[f].flags += ['-mavx']
|
||||
if 'avx2.c' in f:
|
||||
SOURCES[f].flags += ['-mavx2']
|
||||
|
||||
# Suppress warnings in third-party code.
|
||||
|
|
@ -109,8 +120,12 @@ if CONFIG['CLANG_CXX'] or CONFIG['CLANG_CL']:
|
|||
ASFLAGS += CONFIG['VPX_ASFLAGS']
|
||||
ASFLAGS += [
|
||||
'-I.',
|
||||
'-I%s/media/libvpx/' % TOPSRCDIR,
|
||||
'-I%s/media/libvpx/vpx_ports/' % TOPSRCDIR,
|
||||
'-I%s/media/libvpx/libvpx' % TOPSRCDIR,
|
||||
]
|
||||
|
||||
CFLAGS += [
|
||||
'-I%s/media/libvpx/libvpx' % TOPSRCDIR,
|
||||
'-I%s/media/libvpx/config' % TOPSRCDIR, # vpx_version.h
|
||||
]
|
||||
|
||||
if CONFIG['OS_TARGET'] == 'Android':
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue