mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-26 04:09:50 +00:00
Bug 1864008 - Build libvpx with platform-specific vpx_config.c r=media-playback-reviewers,glandium,karlt
This patch brings the platform-specific `vpx_codec_build_config` implementation into libvpx since it will be used and exposed in the following patches. Differential Revision: https://phabricator.services.mozilla.com/D193598
This commit is contained in:
parent
e4f23c61b3
commit
80d285c480
@ -77,6 +77,7 @@ function convert_srcs_to_project_files {
|
||||
local source_list=$(grep -E '(\.c|\.h|\.S|\.s|\.asm)$' $1)
|
||||
|
||||
# Remove vpx_config.c.
|
||||
# The platform-specific vpx_config.c will be added into in moz.build later.
|
||||
source_list=$(echo "$source_list" | grep -v 'vpx_config\.c')
|
||||
|
||||
# Remove include-only asm files (no object code emitted)
|
||||
|
@ -19,24 +19,30 @@ if CONFIG['CPU_ARCH'] == 'x86_64':
|
||||
if CONFIG['OS_TARGET'] == 'WINNT':
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/win/x64/' % TOPSRCDIR ]
|
||||
LOCAL_INCLUDES += [ '/media/libvpx/config/win/x64/' ]
|
||||
SOURCES += [ '/media/libvpx/config/win/x64/vpx_config.c' ]
|
||||
elif CONFIG['OS_TARGET'] == 'Darwin':
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/mac/x64/' % TOPSRCDIR ]
|
||||
LOCAL_INCLUDES += [ '/media/libvpx/config/mac/x64/' ]
|
||||
SOURCES += [ '/media/libvpx/config/mac/x64/vpx_config.c' ]
|
||||
else: # Android, Linux, BSDs, etc.
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/linux/x64/' % TOPSRCDIR ]
|
||||
LOCAL_INCLUDES += [ '/media/libvpx/config/linux/x64/' ]
|
||||
SOURCES += [ '/media/libvpx/config/linux/x64/vpx_config.c' ]
|
||||
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 ]
|
||||
LOCAL_INCLUDES += [ '/media/libvpx/config/win/ia32/' ]
|
||||
SOURCES += [ '/media/libvpx/config/win/ia32/vpx_config.c' ]
|
||||
elif CONFIG['OS_TARGET'] == 'Darwin':
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/mac/ia32/' % TOPSRCDIR ]
|
||||
LOCAL_INCLUDES += [ '/media/libvpx/config/mac/ia32/' ]
|
||||
SOURCES += [ '/media/libvpx/config/mac/ia32/vpx_config.c' ]
|
||||
else: # Android, Linux, BSDs, etc.
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/linux/ia32/' % TOPSRCDIR ]
|
||||
LOCAL_INCLUDES += [ '/media/libvpx/config/linux/ia32/' ]
|
||||
SOURCES += [ '/media/libvpx/config/linux/ia32/vpx_config.c' ]
|
||||
elif CONFIG['CPU_ARCH'] == 'arm':
|
||||
EXPORTS.vpx += files['ARM_EXPORTS']
|
||||
ASFLAGS += [
|
||||
@ -44,6 +50,7 @@ elif CONFIG['CPU_ARCH'] == 'arm':
|
||||
'-I%s/libvpx' % OBJDIR,
|
||||
]
|
||||
LOCAL_INCLUDES += [ '/media/libvpx/config/linux/arm/' ]
|
||||
SOURCES += [ '/media/libvpx/config/linux/arm/vpx_config.c' ]
|
||||
|
||||
arm_asm_files = files['ARM_SOURCES']
|
||||
|
||||
@ -68,17 +75,20 @@ elif CONFIG['CPU_ARCH'] == 'aarch64' and CONFIG['OS_TARGET'] == 'WINNT':
|
||||
SOURCES += files['ARM64_SOURCES']
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/win/aarch64/' % TOPSRCDIR ]
|
||||
LOCAL_INCLUDES += [ '/media/libvpx/config/win/aarch64/' ]
|
||||
SOURCES += [ '/media/libvpx/config/win/aarch64/vpx_config.c' ]
|
||||
elif CONFIG['CPU_ARCH'] == 'aarch64':
|
||||
EXPORTS.vpx += files['ARM64_EXPORTS']
|
||||
SOURCES += files['ARM64_SOURCES']
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/linux/arm64/' % TOPSRCDIR ]
|
||||
LOCAL_INCLUDES += [ '/media/libvpx/config/linux/arm64/' ]
|
||||
SOURCES += [ '/media/libvpx/config/linux/arm64/vpx_config.c' ]
|
||||
else:
|
||||
# Generic C-only configuration
|
||||
EXPORTS.vpx += files['GENERIC_EXPORTS']
|
||||
SOURCES += files['GENERIC_SOURCES']
|
||||
ASFLAGS += [ '-I%s/media/libvpx/config/generic/' % TOPSRCDIR ]
|
||||
LOCAL_INCLUDES += [ '/media/libvpx/config/generic/' ]
|
||||
SOURCES += [ '/media/libvpx/config/generic/vpx_config.c' ]
|
||||
|
||||
# We allow warnings for third-party code that can be updated from upstream.
|
||||
AllowCompilerWarnings()
|
||||
|
Loading…
x
Reference in New Issue
Block a user