# -*- 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/. EXPORTS += [ 'basic/BasicCanvasLayer.h', 'basic/BasicImplData.h', 'basic/BasicLayers.h', 'basic/BasicLayersImpl.h', 'basic/BasicThebesLayer.h', 'client/ClientCanvasLayer.h', 'client/ClientContainerLayer.h', 'client/ClientLayerManager.h', 'client/ClientThebesLayer.h', 'client/ClientTiledThebesLayer.h', 'composite/CompositableHost.h', 'composite/ImageHost.h', 'CopyableCanvasLayer.h', 'D3D9SurfaceImage.h', 'FrameMetrics.h', 'GrallocImages.h', 'ImageContainer.h', 'ImageLayers.h', 'ImageTypes.h', 'ipc/CompositorChild.h', 'ipc/CompositorParent.h', 'ipc/ShadowLayersManager.h', 'Layers.h', 'LayerScope.h', 'LayersLogging.h', 'LayerSorter.h', 'LayerTreeInvalidation.h', 'opengl/Composer2D.h', 'opengl/OGLShaderProgram.h', 'opengl/OGLShaders.h', 'opengl/TexturePoolOGL.h', 'ReadbackLayer.h', 'SharedTextureImage.h', 'TiledLayerBuffer.h', ] if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows': UNIFIED_SOURCES += [ 'D3D9SurfaceImage.cpp', ] if CONFIG['MOZ_ENABLE_D3D9_LAYER']: EXPORTS += [ 'd3d9/DeviceManagerD3D9.h', 'd3d9/LayerManagerD3D9.h', ] EXPORTS.mozilla.layers += [ 'd3d9/CompositorD3D9.h', 'd3d9/TextureD3D9.h', ] UNIFIED_SOURCES += [ 'd3d9/CanvasLayerD3D9.cpp', 'd3d9/ColorLayerD3D9.cpp', 'd3d9/ContainerLayerD3D9.cpp', 'd3d9/ImageLayerD3D9.cpp', 'd3d9/LayerManagerD3D9.cpp', 'd3d9/Nv3DVUtils.cpp', 'd3d9/TextureD3D9.cpp', 'd3d9/ThebesLayerD3D9.cpp', ] SOURCES += [ 'd3d9/CompositorD3D9.cpp', 'd3d9/DeviceManagerD3D9.cpp', ] if CONFIG['MOZ_ENABLE_D3D10_LAYER']: EXPORTS += [ 'd3d10/LayerManagerD3D10.h', 'd3d10/ReadbackManagerD3D10.h', ] EXPORTS.mozilla.layers += [ 'd3d11/CompositorD3D11.h', 'd3d11/TextureD3D11.h', 'ipc/ShadowLayerUtilsD3D10.h', ] UNIFIED_SOURCES += [ 'd3d10/CanvasLayerD3D10.cpp', 'd3d10/ColorLayerD3D10.cpp', 'd3d10/ContainerLayerD3D10.cpp', 'd3d10/ImageLayerD3D10.cpp', 'd3d10/LayerManagerD3D10.cpp', 'd3d10/ReadbackManagerD3D10.cpp', 'd3d10/ThebesLayerD3D10.cpp', 'd3d11/TextureD3D11.cpp', 'ipc/ShadowLayerUtilsD3D10.cpp', ] SOURCES += [ 'd3d11/CompositorD3D11.cpp', ] EXPORTS.gfxipc += [ 'ipc/ShadowLayerUtils.h', ] EXPORTS.mozilla.layers += [ 'AtomicRefCountedWithFinalize.h', 'basic/BasicCompositor.h', 'basic/MacIOSurfaceTextureHostBasic.h', 'basic/TextureHostBasic.h', 'client/CanvasClient.h', 'client/CompositableClient.h', 'client/ContentClient.h', 'client/ImageClient.h', 'client/TextureClient.h', 'client/TiledContentClient.h', 'composite/APZCTreeManager.h', 'composite/AsyncCompositionManager.h', 'composite/CanvasLayerComposite.h', 'composite/ColorLayerComposite.h', 'composite/ContainerLayerComposite.h', 'composite/ContentHost.h', 'composite/ImageHost.h', 'composite/ImageLayerComposite.h', 'composite/LayerManagerComposite.h', 'composite/TextureHost.h', 'composite/ThebesLayerComposite.h', 'Compositor.h', 'CompositorTypes.h', 'D3D9SurfaceImage.h', 'Effects.h', 'ImageDataSerializer.h', 'ipc/AsyncPanZoomController.h', 'ipc/Axis.h', 'ipc/CompositableForwarder.h', 'ipc/CompositableTransactionParent.h', 'ipc/CompositorChild.h', 'ipc/CompositorParent.h', 'ipc/GeckoContentController.h', 'ipc/GestureEventListener.h', 'ipc/ImageBridgeChild.h', 'ipc/ImageBridgeParent.h', 'ipc/ISurfaceAllocator.h', 'ipc/LayerTransactionChild.h', 'ipc/LayerTransactionParent.h', 'ipc/ShadowLayers.h', 'ipc/ShadowLayersManager.h', 'ipc/SharedPlanarYCbCrImage.h', 'ipc/SharedRGBImage.h', 'ipc/TaskThrottler.h', 'LayersTypes.h', 'opengl/CompositingRenderTargetOGL.h', 'opengl/CompositorOGL.h', 'opengl/GrallocTextureClient.h', 'opengl/GrallocTextureHost.h', 'opengl/MacIOSurfaceTextureClientOGL.h', 'opengl/MacIOSurfaceTextureHostOGL.h', 'opengl/TextureClientOGL.h', 'opengl/TextureHostOGL.h', 'RenderTrace.h', 'YCbCrImageDataSerializer.h', ] if CONFIG['MOZ_X11']: EXPORTS.mozilla.layers += [ 'ipc/ShadowLayerUtilsX11.h', ] SOURCES += [ 'ipc/ShadowLayerUtilsX11.cpp' ] if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa': EXPORTS.mozilla.layers += [ 'opengl/GLManager.h', ] EXPORTS += [ 'MacIOSurfaceImage.h', ] UNIFIED_SOURCES += [ 'opengl/GLManager.cpp', ] SOURCES += [ 'ipc/ShadowLayerUtilsMac.cpp', 'MacIOSurfaceImage.cpp', ] # NB: Gralloc is available on other platforms that use the android GL # libraries, but only Gonk is able to use it reliably because Gecko # has full system permissions there. if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk': EXPORTS.mozilla.layers += [ 'ipc/ShadowLayerUtilsGralloc.h', ] UNIFIED_SOURCES += [ 'GrallocImages.cpp', 'opengl/EGLImageHelpers.cpp', 'opengl/GrallocTextureClient.cpp', 'opengl/GrallocTextureHost.cpp', ] SOURCES += [ 'ipc/ShadowLayerUtilsGralloc.cpp', ] UNIFIED_SOURCES += [ 'basic/BasicCanvasLayer.cpp', 'basic/BasicColorLayer.cpp', 'basic/BasicCompositor.cpp', 'basic/BasicContainerLayer.cpp', 'basic/BasicImages.cpp', 'basic/BasicLayerManager.cpp', 'basic/BasicLayersImpl.cpp', 'basic/BasicThebesLayer.cpp', 'basic/TextureHostBasic.cpp', 'BufferUnrotate.cpp', 'client/CanvasClient.cpp', 'client/ClientCanvasLayer.cpp', 'client/ClientColorLayer.cpp', 'client/ClientContainerLayer.cpp', 'client/ClientImageLayer.cpp', 'client/ClientLayerManager.cpp', 'client/ClientThebesLayer.cpp', 'client/ClientTiledThebesLayer.cpp', 'client/CompositableClient.cpp', 'client/ContentClient.cpp', 'client/ImageClient.cpp', 'client/TextureClient.cpp', 'client/TiledContentClient.cpp', 'composite/APZCTreeManager.cpp', 'composite/AsyncCompositionManager.cpp', 'composite/CanvasLayerComposite.cpp', 'composite/ColorLayerComposite.cpp', 'composite/CompositableHost.cpp', 'composite/ContainerLayerComposite.cpp', 'composite/ContentHost.cpp', 'composite/ImageHost.cpp', 'composite/ImageLayerComposite.cpp', 'composite/LayerManagerComposite.cpp', 'composite/TextureHost.cpp', 'composite/ThebesLayerComposite.cpp', 'composite/TiledContentHost.cpp', 'Compositor.cpp', 'CopyableCanvasLayer.cpp', 'Effects.cpp', 'ImageDataSerializer.cpp', 'ImageLayers.cpp', 'ipc/AsyncPanZoomController.cpp', 'ipc/Axis.cpp', 'ipc/CompositableTransactionParent.cpp', 'ipc/CompositorChild.cpp', 'ipc/CompositorParent.cpp', 'ipc/GestureEventListener.cpp', 'ipc/ImageBridgeChild.cpp', 'ipc/ImageBridgeParent.cpp', 'ipc/ISurfaceAllocator.cpp', 'ipc/LayerTransactionChild.cpp', 'ipc/LayerTransactionParent.cpp', 'ipc/ShadowLayerChild.cpp', 'ipc/ShadowLayerParent.cpp', 'ipc/ShadowLayers.cpp', 'ipc/SharedPlanarYCbCrImage.cpp', 'ipc/SharedRGBImage.cpp', 'ipc/TaskThrottler.cpp', 'LayerScope.cpp', 'LayersLogging.cpp', 'LayerSorter.cpp', 'opengl/CompositingRenderTargetOGL.cpp', 'opengl/CompositorOGL.cpp', 'opengl/OGLShaderProgram.cpp', 'opengl/TextureClientOGL.cpp', 'opengl/TextureHostOGL.cpp', 'opengl/TexturePoolOGL.cpp', 'ReadbackProcessor.cpp', 'RenderTrace.cpp', 'RotatedBuffer.cpp', 'YCbCrImageDataSerializer.cpp', ] SOURCES += [ 'basic/BasicImageLayer.cpp', 'ImageContainer.cpp', 'Layers.cpp', 'LayerTreeInvalidation.cpp', ] # Workaround compiler bug (Bug 795594) if CONFIG['_MSC_VER'] and CONFIG['CPU_ARCH'] == 'x86_64': for src in [ 'Layers.cpp', 'LayerTreeInvalidation.cpp', ]: SOURCES[src].no_pgo = True if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa': SOURCES += [ 'basic/MacIOSurfaceTextureHostBasic.cpp', 'opengl/MacIOSurfaceTextureClientOGL.cpp', 'opengl/MacIOSurfaceTextureHostOGL.cpp', ] IPDL_SOURCES = [ 'ipc/LayersMessages.ipdlh', 'ipc/LayersSurfaces.ipdlh', 'ipc/PCompositable.ipdl', 'ipc/PCompositor.ipdl', 'ipc/PGrallocBuffer.ipdl', 'ipc/PImageBridge.ipdl', 'ipc/PLayer.ipdl', 'ipc/PLayerTransaction.ipdl', 'ipc/PTexture.ipdl', ] FAIL_ON_WARNINGS = True MSVC_ENABLE_PGO = True include('/ipc/chromium/chromium-config.mozbuild') FINAL_LIBRARY = 'thebes' LOCAL_INCLUDES += [ '/content/events/src', ] if CONFIG['MOZ_DEBUG']: DEFINES['D3D_DEBUG_INFO'] = True if CONFIG['MOZ_ENABLE_D3D10_LAYER']: DEFINES['MOZ_ENABLE_D3D10_LAYER'] = True