media/libcubeb/src/moz.build

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/media/libcubeb/src/moz.build	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,70 @@
     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 +LIBRARY_NAME = 'cubeb'
    1.11 +
    1.12 +SOURCES += [
    1.13 +    'cubeb.c',
    1.14 +]
    1.15 +
    1.16 +if CONFIG['MOZ_ALSA']:
    1.17 +    SOURCES += [
    1.18 +        'cubeb_alsa.c',
    1.19 +    ]
    1.20 +    DEFINES['USE_ALSA'] = True
    1.21 +
    1.22 +if CONFIG['MOZ_PULSEAUDIO']:
    1.23 +    SOURCES += [
    1.24 +        'cubeb_pulse.c',
    1.25 +    ]
    1.26 +    DEFINES['USE_PULSE'] = True
    1.27 +    if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk':
    1.28 +        DEFINES['DISABLE_LIBPULSE_DLOPEN'] = True
    1.29 +
    1.30 +if CONFIG['OS_ARCH'] == 'OpenBSD':
    1.31 +    SOURCES += [
    1.32 +        'cubeb_sndio.c',
    1.33 +    ]
    1.34 +    DEFINES['USE_SNDIO'] = True
    1.35 +
    1.36 +if CONFIG['OS_TARGET'] == 'Darwin':
    1.37 +    SOURCES += [
    1.38 +        'cubeb_audiounit.c',
    1.39 +    ]
    1.40 +    DEFINES['USE_AUDIOUNIT'] = True
    1.41 +
    1.42 +if CONFIG['OS_TARGET'] == 'WINNT':
    1.43 +    SOURCES += [
    1.44 +        'cubeb_wasapi.cpp',
    1.45 +        'cubeb_winmm.c',
    1.46 +    ]
    1.47 +    DEFINES['USE_WINMM'] = True
    1.48 +    DEFINES['USE_WASAPI'] = True
    1.49 +
    1.50 +if CONFIG['OS_TARGET'] == 'Android':
    1.51 +    SOURCES += ['cubeb_opensl.c']
    1.52 +    SOURCES['cubeb_opensl.c'].flags += ['-Wno-declaration-after-statement']
    1.53 +    DEFINES['USE_OPENSL'] = True
    1.54 +    if CONFIG['MOZ_WIDGET_TOOLKIT'] != 'gonk':
    1.55 +        SOURCES += [
    1.56 +            'cubeb_audiotrack.c',
    1.57 +        ]
    1.58 +        DEFINES['USE_AUDIOTRACK'] = True
    1.59 +
    1.60 +MSVC_ENABLE_PGO = True
    1.61 +
    1.62 +if CONFIG['GKMEDIAS_SHARED_LIBRARY']:
    1.63 +    NO_VISIBILITY_FLAGS = True
    1.64 +
    1.65 +FINAL_LIBRARY = 'gkmedias'
    1.66 +
    1.67 +if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk':
    1.68 +    CFLAGS += [
    1.69 +        '-I%s/%s' % (CONFIG['ANDROID_SOURCE'], d) for d in [
    1.70 +            'frameworks/wilhelm/include',
    1.71 +            'system/media/wilhelm/include',
    1.72 +        ]
    1.73 +    ]

mercurial