1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/media/libtheora/lib/moz.build Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,84 @@ 1.4 +# -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*- 1.5 +# vim: set filetype=python: 1.6 +# This Source Code Form is subject to the terms of the Mozilla Public 1.7 +# License, v. 2.0. If a copy of the MPL was not distributed with this 1.8 +# file, You can obtain one at http://mozilla.org/MPL/2.0/. 1.9 + 1.10 +UNIFIED_SOURCES += [ 1.11 + 'apiwrapper.c', 1.12 + 'bitpack.c', 1.13 + 'decapiwrapper.c', 1.14 + 'decinfo.c', 1.15 + 'decode.c', 1.16 + 'dequant.c', 1.17 + 'fragment.c', 1.18 + 'huffdec.c', 1.19 + 'idct.c', 1.20 + 'info.c', 1.21 + 'internal.c', 1.22 + 'quant.c', 1.23 + 'state.c', 1.24 +] 1.25 + 1.26 +if CONFIG['CPU_ARCH'] == 'arm' and CONFIG['GNU_AS']: 1.27 + GENERATED_SOURCES += [ '%s.%s' % (f, CONFIG['ASM_SUFFIX']) for f in [ 1.28 + 'armbits-gnu', 1.29 + 'armfrag-gnu', 1.30 + 'armidct-gnu', 1.31 + 'armloop-gnu', 1.32 + ]] 1.33 + 1.34 +if '86' in CONFIG['OS_TEST']: 1.35 + if CONFIG['OS_ARCH'] != 'SunOS': 1.36 + if CONFIG['OS_ARCH'] != 'WINNT' or CONFIG['OS_TEST'] != 'x86_64': 1.37 + DEFINES['OC_X86_ASM'] = True 1.38 + if '64' in CONFIG['OS_TEST']: 1.39 + DEFINES['OC_X86_64_ASM'] = True 1.40 + if CONFIG['_MSC_VER']: 1.41 + if '64' not in CONFIG['OS_TEST']: 1.42 + SOURCES += [ 1.43 + 'x86_vc/mmxfrag.c', 1.44 + 'x86_vc/mmxidct.c', 1.45 + 'x86_vc/mmxstate.c', 1.46 + 'x86_vc/x86cpu.c', 1.47 + 'x86_vc/x86state.c', 1.48 + ] 1.49 + else: 1.50 + SOURCES += [ 1.51 + 'x86/mmxfrag.c', 1.52 + 'x86/mmxidct.c', 1.53 + 'x86/mmxstate.c', 1.54 + 'x86/sse2idct.c', 1.55 + 'x86/x86cpu.c', 1.56 + 'x86/x86state.c', 1.57 + ] 1.58 + 1.59 +if CONFIG['GNU_AS']: 1.60 + if 'arm' in CONFIG['OS_TEST']: 1.61 + SOURCES += [ 1.62 + 'arm/armcpu.c', 1.63 + 'arm/armstate.c', 1.64 + ] 1.65 + for var in ('OC_ARM_ASM', 'OC_ARM_ASM_EDSP', 'OC_ARM_ASM_MEDIA', 1.66 + 'OC_ARM_ASM_NEON'): 1.67 + DEFINES[var] = True 1.68 + # The Android NDK doesn't pre-define anything to indicate the OS it's 1.69 + # on, so do it for them. 1.70 + if CONFIG['OS_TARGET'] == 'Android': 1.71 + DEFINES['__linux__'] = True 1.72 + 1.73 +MSVC_ENABLE_PGO = True 1.74 + 1.75 +if CONFIG['GKMEDIAS_SHARED_LIBRARY']: 1.76 + NO_VISIBILITY_FLAGS = True 1.77 + 1.78 +FINAL_LIBRARY = 'gkmedias' 1.79 + 1.80 +# The encoder is currently not included. 1.81 +DEFINES['THEORA_DISABLE_ENCODE'] = True 1.82 + 1.83 +# Suppress warnings in third-party code. 1.84 +if CONFIG['GNU_CC']: 1.85 + CFLAGS += ['-Wno-type-limits'] 1.86 + if CONFIG['CLANG_CXX']: 1.87 + CFLAGS += ['-Wno-tautological-compare']