content/media/moz.build
author Mike Hommey <mh+mozilla@glandium.org>
Thu, 26 Jun 2014 15:26:16 +0900
changeset 211787 29bbf1aba13a4ebf800dd26810697cf4d25abc4b
parent 211681 b559ec64da05e8ba4127dc52e64cd7604c220a5a
child 212961 b191be106cae30ec2477531fc53531cb53c35a64
permissions -rw-r--r--
Bug 1030598 - Fix make export race condition after bug 1028563. r=gps

# -*- Mode: python; c-basic-offset: 4; 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/.

PARALLEL_DIRS += [
  'encoder',
  'gmp',
  'mediasource',
  'ogg',
  'webaudio',
  'webvtt'
]

TEST_TOOL_DIRS += ['compiledtest']

if CONFIG['MOZ_RAW']:
    PARALLEL_DIRS += ['raw']

if CONFIG['MOZ_WAVE']:
    PARALLEL_DIRS += ['wave']

if CONFIG['MOZ_WEBM']:
    PARALLEL_DIRS += ['webm']

if CONFIG['MOZ_GSTREAMER']:
    PARALLEL_DIRS += ['gstreamer']

if CONFIG['MOZ_DIRECTSHOW']:
    PARALLEL_DIRS += ['directshow']

if CONFIG['MOZ_MEDIA_PLUGINS']:
    PARALLEL_DIRS += ['plugins']

if CONFIG['MOZ_WMF']:
    PARALLEL_DIRS += ['wmf']

if CONFIG['MOZ_FMP4']:
    PARALLEL_DIRS += ['fmp4']

if CONFIG['MOZ_APPLEMEDIA']:
    PARALLEL_DIRS += ['apple']

PARALLEL_DIRS += ['webrtc']

if CONFIG['MOZ_OMX_DECODER']:
    PARALLEL_DIRS += ['omx']
    PARALLEL_DIRS += ['omx/mediaresourcemanager']

PARALLEL_DIRS += ['webspeech']

PARALLEL_DIRS += ['eme']

TEST_DIRS += [
    'test',
    'gtest',
]

EXPORTS += [
    'AbstractMediaDecoder.h',
    'AudioChannelFormat.h',
    'AudioCompactor.h',
    'AudioEventTimeline.h',
    'AudioMixer.h',
    'AudioNodeEngine.h',
    'AudioNodeExternalInputStream.h',
    'AudioNodeStream.h',
    'AudioSampleFormat.h',
    'AudioSegment.h',
    'AudioStream.h',
    'BufferDecoder.h',
    'BufferMediaResource.h',
    'DecoderTraits.h',
    'DOMMediaStream.h',
    'EncodedBufferCache.h',
    'FileBlockCache.h',
    'Latency.h',
    'MediaCache.h',
    'MediaData.h',
    'MediaDataDecodedListener.h',
    'MediaDecoder.h',
    'MediaDecoderOwner.h',
    'MediaDecoderReader.h',
    'MediaDecoderStateMachine.h',
    'MediaInfo.h',
    'MediaMetadataManager.h',
    'MediaQueue.h',
    'MediaRecorder.h',
    'MediaResource.h',
    'MediaSegment.h',
    'MediaStreamGraph.h',
    'MediaTaskQueue.h',
    'MP3FrameParser.h',
    'nsIDocumentActivity.h',
    'RtspMediaResource.h',
    'SharedBuffer.h',
    'SharedThreadPool.h',
    'StreamBuffer.h',
    'TimeVarying.h',
    'TrackUnionStream.h',
    'VideoFrameContainer.h',
    'VideoSegment.h',
    'VideoUtils.h',
    'VorbisUtils.h',
]

EXPORTS.mozilla.dom += [
    'AudioStreamTrack.h',
    'MediaStreamTrack.h',
    'TextTrack.h',
    'TextTrackCue.h',
    'TextTrackCueList.h',
    'TextTrackList.h',
    'TextTrackRegion.h',
    'VideoPlaybackQuality.h',
    'VideoStreamTrack.h',
]

UNIFIED_SOURCES += [
    'AudioChannelFormat.cpp',
    'AudioCompactor.cpp',
    'AudioNodeEngine.cpp',
    'AudioNodeExternalInputStream.cpp',
    'AudioNodeStream.cpp',
    'AudioSegment.cpp',
    'AudioSink.cpp',
    'AudioStream.cpp',
    'AudioStreamTrack.cpp',
    'BufferDecoder.cpp',
    'DOMMediaStream.cpp',
    'EncodedBufferCache.cpp',
    'FileBlockCache.cpp',
    'MediaCache.cpp',
    'MediaData.cpp',
    'MediaDecoder.cpp',
    'MediaDecoderReader.cpp',
    'MediaDecoderStateMachine.cpp',
    'MediaRecorder.cpp',
    'MediaResource.cpp',
    'MediaShutdownManager.cpp',
    'MediaStreamGraph.cpp',
    'MediaStreamTrack.cpp',
    'MediaTaskQueue.cpp',
    'MP3FrameParser.cpp',
    'RtspMediaResource.cpp',
    'SharedThreadPool.cpp',
    'StreamBuffer.cpp',
    'TextTrack.cpp',
    'TextTrackCue.cpp',
    'TextTrackCueList.cpp',
    'TextTrackList.cpp',
    'TextTrackRegion.cpp',
    'VideoFrameContainer.cpp',
    'VideoPlaybackQuality.cpp',
    'VideoSegment.cpp',
    'VideoStreamTrack.cpp',
    'VideoUtils.cpp',
    'WebVTTListener.cpp',
]

# DecoderTraits.cpp needs to be built separately because of Mac OS X headers.
# Latency.cpp needs to be built separately because it forces NSPR logging.
SOURCES += [
    'DecoderTraits.cpp',
    'Latency.cpp',
]

FAIL_ON_WARNINGS = True

if CONFIG['CPU_ARCH'] == 'arm' and CONFIG['BUILD_ARM_NEON']:
    SOURCES += ['AudioNodeEngineNEON.cpp']
    SOURCES['AudioNodeEngineNEON.cpp'].flags += ['-mfpu=neon']

MSVC_ENABLE_PGO = True

include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'gklayout'
LOCAL_INCLUDES += [
    '/content/base/src',
    '/layout/generic',
    '/layout/xul',
    '/netwerk/base/src',
]

if CONFIG['MOZ_DIRECTSHOW']:
    LOCAL_INCLUDES += [
        '/media/webrtc/trunk/webrtc/modules/video_capture/windows',
    ]

DEFINES['MOZILLA_INTERNAL_API'] = True

if CONFIG['MOZ_OMX_DECODER']:
    DEFINES['MOZ_OMX_DECODER'] = True

if CONFIG['ANDROID_VERSION'] > '15':
    DEFINES['MOZ_OMX_WEBM_DECODER'] = True