diff options
Diffstat (limited to 'media/libtheora/moz.build')
-rw-r--r-- | media/libtheora/moz.build | 52 |
1 files changed, 25 insertions, 27 deletions
diff --git a/media/libtheora/moz.build b/media/libtheora/moz.build index 8bcdb5fd47..aaec4c2ad8 100644 --- a/media/libtheora/moz.build +++ b/media/libtheora/moz.build @@ -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/. @@ -9,7 +10,6 @@ with Files('*'): EXPORTS.theora += [ 'include/theora/codec.h', 'include/theora/theoradec.h', - 'include/theora/theoraenc.h', ] # We allow warnings for third-party code that can be updated from upstream. @@ -24,20 +24,20 @@ if CONFIG['GKMEDIAS_SHARED_LIBRARY']: DEFINES['THEORA_DISABLE_ENCODE'] = True # Suppress warnings in third-party code. -if CONFIG['GNU_CC'] or CONFIG['CLANG_CL']: - CFLAGS += ['-Wno-type-limits'] -if CONFIG['CLANG_CXX'] or CONFIG['CLANG_CL']: - CFLAGS += ['-Wno-tautological-compare'] -if CONFIG['CLANG_CL']: +CFLAGS += ['-Wno-type-limits'] +if CONFIG['CC_TYPE'] in ('clang', 'clang-cl'): CFLAGS += [ + '-Wno-shift-negative-value', + '-Wno-tautological-compare', + ] +if CONFIG['CC_TYPE'] == 'clang-cl': + CFLAGS += [ + '-Wno-parentheses', '-Wno-pointer-sign', - '-Wno-shift-op-parentheses', ] UNIFIED_SOURCES += [ - 'lib/apiwrapper.c', 'lib/bitpack.c', - 'lib/decapiwrapper.c', 'lib/decinfo.c', 'lib/decode.c', 'lib/dequant.c', @@ -52,27 +52,25 @@ UNIFIED_SOURCES += [ LOCAL_INCLUDES += ['include'] -if '86' in CONFIG['OS_TEST']: +if CONFIG['INTEL_ARCHITECTURE']: if CONFIG['OS_ARCH'] != 'SunOS': - if CONFIG['CLANG_CL']: + if CONFIG['CC_TYPE'] == 'clang-cl': # clang-cl can't handle libtheora's inline asm. pass - elif CONFIG['OS_ARCH'] != 'WINNT' or CONFIG['OS_TEST'] != 'x86_64': + elif CONFIG['OS_ARCH'] != 'WINNT' or CONFIG['CPU_ARCH'] != 'x86_64': DEFINES['OC_X86_ASM'] = True - if '64' in CONFIG['OS_TEST']: + if CONFIG['CPU_ARCH'] == 'x86_64': DEFINES['OC_X86_64_ASM'] = True - if CONFIG['_MSC_VER']: - if CONFIG['CLANG_CL']: - # clang-cl can't handle libtheora's inline asm. - pass - elif '64' not in CONFIG['OS_TEST']: - SOURCES += [ - 'lib/x86_vc/mmxfrag.c', - 'lib/x86_vc/mmxidct.c', - 'lib/x86_vc/mmxstate.c', - 'lib/x86_vc/x86cpu.c', - 'lib/x86_vc/x86state.c', - ] + if CONFIG['CC_TYPE'] == 'clang-cl': + # clang-cl can't handle libtheora's inline asm. + pass + #SOURCES += [ + # 'lib/x86_vc/mmxfrag.c', + # 'lib/x86_vc/mmxidct.c', + # 'lib/x86_vc/mmxstate.c', + # 'lib/x86_vc/x86cpu.c', + # 'lib/x86_vc/x86state.c', + #] else: SOURCES += [ 'lib/x86/mmxfrag.c', @@ -84,7 +82,7 @@ if '86' in CONFIG['OS_TEST']: ] if CONFIG['GNU_AS']: - if 'arm' in CONFIG['OS_TEST']: + if CONFIG['CPU_ARCH'] == 'arm': SOURCES += [ 'lib/arm/armcpu.c', 'lib/arm/armstate.c', @@ -109,7 +107,7 @@ if CONFIG['GNU_AS']: ] ASFLAGS += CONFIG['NEON_FLAGS'] - if CONFIG['CLANG_CXX']: + if CONFIG['CC_TYPE'] == 'clang': ASFLAGS += [ '-no-integrated-as', ] |