dom/camera/moz.build
author Chris H-C <chutten@mozilla.com>
Mon, 04 Jul 2016 11:16:05 -0400
changeset 312997 df28918fe2361f0b54ca9ce4773a29c4c0675d06
parent 306127 3ec6380fca8207fa199693206a3ca24975bf9833
child 318046 d3e988b1b4808ff99b8174805324edc143df0bfd
permissions -rw-r--r--
bug 1218576 - Support remote accumulation via JS histograms. r=gfritzsche The JS histograms, too, need to dispatch their accumulations from child to parent. JSHistograms_Add now only supports histograms that are in gHistogramsMap or that were created in the parent process. After bug 1288745, maybe we'll be able to change this to be less convoluted. MozReview-Commit-ID: 3qTH89YKbGP

# -*- 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/.

if CONFIG['MOZ_B2G_CAMERA']:
    MOCHITEST_MANIFESTS += ['test/mochitest.ini']

EXPORTS += [
    'CameraCommon.h',
    'CameraPreferences.h',
    'DOMCameraManager.h',
]

UNIFIED_SOURCES += [
    'CameraControlImpl.cpp',
    'CameraPreferences.cpp',
    'CameraPreviewMediaStream.cpp',
    'DOMCameraCapabilities.cpp',
    'DOMCameraControl.cpp',
    'DOMCameraControlListener.cpp',
    'DOMCameraDetectedFace.cpp',
    'DOMCameraManager.cpp',
]

if CONFIG['MOZ_B2G_CAMERA']:
    XPIDL_SOURCES += [
        'nsICameraTestHardware.idl',
    ]

    XPIDL_MODULE = 'dom_camera'

    UNIFIED_SOURCES += [
        'GonkCameraControl.cpp',
        'GonkCameraHwMgr.cpp',
        'GonkCameraManager.cpp',
        'GonkCameraParameters.cpp',
        'GonkRecorderProfiles.cpp',
        'TestGonkCameraControl.cpp',
        'TestGonkCameraHardware.cpp',
    ]

    if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk':
        UNIFIED_SOURCES += [
            'GonkCameraSource.cpp',
            'GonkRecorder.cpp',
        ]
    else:
        UNIFIED_SOURCES += [
            'FallbackCameraPlatform.cpp',
        ]

    EXTRA_COMPONENTS += [
        'CameraTestHardware.js',
        'CameraTestHardware.manifest',
    ]
else:
    UNIFIED_SOURCES += [
        'FallbackCameraControl.cpp',
        'FallbackCameraManager.cpp',
    ]

LOCAL_INCLUDES += [
    '../base',
    '/media/libyuv/include',
]

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

# Suppress some GCC warnings being treated as errors:
#  - about attributes on forward declarations for types that are already
#    defined, which complains about an important MOZ_EXPORT for android::AString
if CONFIG['GNU_CC']:
    CXXFLAGS += [
        '-Wno-error=attributes',
        '-Wno-error=shadow',
    ]

FINAL_LIBRARY = 'xul'