2013-04-01 11:36:59 -07:00
|
|
|
# -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
|
2013-02-25 12:47:21 -08:00
|
|
|
# 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/.
|
|
|
|
|
2013-06-16 19:05:14 -07:00
|
|
|
EXPORTS.mozilla += [
|
|
|
|
'GenericRefCounted.h',
|
|
|
|
]
|
|
|
|
|
2013-04-16 12:24:43 -07:00
|
|
|
EXPORTS.mozilla.gfx += [
|
|
|
|
'2D.h',
|
2014-08-19 10:08:16 -07:00
|
|
|
'BaseCoord.h',
|
2013-04-16 12:24:43 -07:00
|
|
|
'BaseMargin.h',
|
|
|
|
'BasePoint.h',
|
|
|
|
'BasePoint3D.h',
|
|
|
|
'BasePoint4D.h',
|
|
|
|
'BaseRect.h',
|
|
|
|
'BaseSize.h',
|
|
|
|
'Blur.h',
|
2013-09-22 20:28:16 -07:00
|
|
|
'BorrowedContext.h',
|
2014-08-19 10:08:16 -07:00
|
|
|
'Coord.h',
|
2015-09-28 04:49:54 -07:00
|
|
|
'CriticalSection.h',
|
2013-11-03 08:28:30 -08:00
|
|
|
'DataSurfaceHelpers.h',
|
2016-01-05 02:08:57 -08:00
|
|
|
'DrawEventRecorder.h',
|
2014-09-02 14:21:35 -07:00
|
|
|
'DrawTargetTiled.h',
|
2013-11-27 03:22:07 -08:00
|
|
|
'Filters.h',
|
2013-11-11 15:53:29 -08:00
|
|
|
'Helpers.h',
|
2015-05-20 09:48:31 -07:00
|
|
|
'HelpersCairo.h',
|
2015-09-28 04:49:33 -07:00
|
|
|
'IterableArena.h',
|
2015-09-28 04:49:43 -07:00
|
|
|
'JobScheduler.h',
|
|
|
|
'JobScheduler_posix.h',
|
|
|
|
'JobScheduler_win32.h',
|
2014-02-18 18:59:34 -08:00
|
|
|
'Logging.h',
|
2013-04-16 12:24:43 -07:00
|
|
|
'Matrix.h',
|
2015-12-02 15:52:00 -08:00
|
|
|
'MatrixFwd.h',
|
2015-04-09 12:49:25 -07:00
|
|
|
'NumericTools.h',
|
2013-04-16 12:24:43 -07:00
|
|
|
'PathHelpers.h',
|
2014-09-29 06:12:06 -07:00
|
|
|
'PatternHelpers.h',
|
2013-04-16 12:24:43 -07:00
|
|
|
'Point.h',
|
2016-01-05 02:08:58 -08:00
|
|
|
'Preferences.h',
|
2015-04-01 13:02:20 -07:00
|
|
|
'Quaternion.h',
|
2016-01-05 02:08:57 -08:00
|
|
|
'RecordedEvent.h',
|
2016-01-05 02:08:57 -08:00
|
|
|
'RecordingTypes.h',
|
2013-04-16 12:24:43 -07:00
|
|
|
'Rect.h',
|
|
|
|
'Scale.h',
|
2013-06-14 13:11:31 -07:00
|
|
|
'ScaleFactor.h',
|
2015-03-06 10:53:47 -08:00
|
|
|
'ScaleFactors2D.h',
|
2014-06-17 02:08:23 -07:00
|
|
|
'SourceSurfaceCairo.h',
|
2015-11-24 20:15:29 -08:00
|
|
|
'SourceSurfaceRawData.h',
|
2015-08-13 14:01:10 -07:00
|
|
|
'StackArray.h',
|
2013-04-16 12:24:43 -07:00
|
|
|
'Tools.h',
|
|
|
|
'Types.h',
|
|
|
|
'UserData.h',
|
|
|
|
]
|
|
|
|
|
2015-06-12 05:48:42 -07:00
|
|
|
if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('cocoa', 'uikit'):
|
2013-04-16 12:24:43 -07:00
|
|
|
EXPORTS.mozilla.gfx += [
|
|
|
|
'MacIOSurface.h',
|
|
|
|
]
|
2013-11-18 13:45:14 -08:00
|
|
|
UNIFIED_SOURCES += [
|
2013-04-23 14:54:15 -07:00
|
|
|
'DrawTargetCG.cpp',
|
|
|
|
'PathCG.cpp',
|
|
|
|
'ScaledFontMac.cpp',
|
2013-10-23 16:00:23 -07:00
|
|
|
'SourceSurfaceCG.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
]
|
|
|
|
elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
|
2013-10-24 16:23:05 -07:00
|
|
|
SOURCES += [
|
2013-04-23 14:54:15 -07:00
|
|
|
'DrawTargetD2D.cpp',
|
2015-01-07 08:32:07 -08:00
|
|
|
'DrawTargetD2D1.cpp',
|
2015-02-09 11:04:11 -08:00
|
|
|
'ExtendInputEffectD2D1.cpp',
|
2015-01-07 08:32:07 -08:00
|
|
|
'FilterNodeD2D1.cpp',
|
2015-09-28 04:49:52 -07:00
|
|
|
'JobScheduler_win32.cpp',
|
2016-01-05 02:08:58 -08:00
|
|
|
'NativeFontResourceDWrite.cpp',
|
|
|
|
'NativeFontResourceGDI.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'PathD2D.cpp',
|
2015-01-07 08:32:07 -08:00
|
|
|
'RadialGradientEffectD2D1.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'ScaledFontDWrite.cpp',
|
2014-05-03 01:13:00 -07:00
|
|
|
'ScaledFontWin.cpp',
|
2013-10-23 16:00:23 -07:00
|
|
|
'SourceSurfaceD2D.cpp',
|
2015-01-07 08:32:07 -08:00
|
|
|
'SourceSurfaceD2D1.cpp',
|
2013-10-23 16:00:23 -07:00
|
|
|
'SourceSurfaceD2DTarget.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
]
|
2013-11-27 05:55:07 -08:00
|
|
|
DEFINES['WIN32'] = True
|
2013-04-23 14:54:15 -07:00
|
|
|
|
2015-09-28 04:49:43 -07:00
|
|
|
if CONFIG['MOZ_WIDGET_TOOLKIT'] != 'windows':
|
|
|
|
SOURCES += [
|
|
|
|
'JobScheduler_posix.cpp',
|
|
|
|
]
|
|
|
|
|
2013-04-23 14:54:15 -07:00
|
|
|
if CONFIG['MOZ_ENABLE_SKIA']:
|
2013-11-18 13:45:14 -08:00
|
|
|
UNIFIED_SOURCES += [
|
2013-10-23 16:05:43 -07:00
|
|
|
'convolver.cpp',
|
2013-11-18 13:45:14 -08:00
|
|
|
]
|
2016-01-08 00:32:01 -08:00
|
|
|
SOURCES += [
|
2016-01-08 00:43:58 -08:00
|
|
|
'DrawTargetSkia.cpp',
|
2016-01-08 00:32:01 -08:00
|
|
|
'image_operations.cpp', # Uses _USE_MATH_DEFINES
|
2016-01-08 00:43:58 -08:00
|
|
|
'PathSkia.cpp',
|
|
|
|
'SourceSurfaceSkia.cpp',
|
2016-01-08 00:32:01 -08:00
|
|
|
]
|
2016-01-08 00:43:58 -08:00
|
|
|
if CONFIG['CLANG_CXX']:
|
|
|
|
# Suppress warnings from Skia header files.
|
|
|
|
SOURCES['DrawTargetSkia.cpp'].flags += ['-Wno-implicit-fallthrough']
|
|
|
|
SOURCES['PathSkia.cpp'].flags += ['-Wno-implicit-fallthrough']
|
|
|
|
SOURCES['SourceSurfaceSkia.cpp'].flags += ['-Wno-implicit-fallthrough']
|
2014-07-28 11:48:29 -07:00
|
|
|
EXPORTS.mozilla.gfx += [
|
|
|
|
'HelpersSkia.h',
|
2015-08-07 19:27:14 -07:00
|
|
|
'RefPtrSkia.h',
|
2014-07-28 11:48:29 -07:00
|
|
|
]
|
2013-04-23 14:54:15 -07:00
|
|
|
|
|
|
|
# Are we targeting x86 or x64? If so, build SSE2 files.
|
|
|
|
if CONFIG['INTEL_ARCHITECTURE']:
|
2014-12-16 09:53:13 -08:00
|
|
|
SOURCES += [
|
|
|
|
'BlurSSE2.cpp',
|
|
|
|
'FilterProcessingSSE2.cpp',
|
|
|
|
'ImageScalingSSE2.cpp',
|
|
|
|
]
|
|
|
|
if CONFIG['MOZ_ENABLE_SKIA']:
|
2013-10-24 16:23:05 -07:00
|
|
|
SOURCES += [
|
2014-12-16 09:53:13 -08:00
|
|
|
'convolverSSE2.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
]
|
2014-12-16 09:53:13 -08:00
|
|
|
DEFINES['USE_SSE2'] = True
|
|
|
|
# The file uses SSE2 intrinsics, so it needs special compile flags on some
|
|
|
|
# compilers.
|
|
|
|
SOURCES['BlurSSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
|
|
|
|
SOURCES['FilterProcessingSSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
|
|
|
|
SOURCES['ImageScalingSSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
|
|
|
|
if CONFIG['MOZ_ENABLE_SKIA']:
|
|
|
|
SOURCES['convolverSSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
|
2015-04-21 16:07:00 -07:00
|
|
|
elif CONFIG['CPU_ARCH'].startswith('mips'):
|
2015-04-21 16:08:00 -07:00
|
|
|
SOURCES += [
|
|
|
|
'BlurLS3.cpp',
|
|
|
|
]
|
2015-04-21 16:07:00 -07:00
|
|
|
if CONFIG['MOZ_ENABLE_SKIA']:
|
|
|
|
SOURCES += [
|
|
|
|
'convolverLS3.cpp',
|
|
|
|
]
|
2013-04-23 14:54:15 -07:00
|
|
|
|
2013-11-18 13:45:14 -08:00
|
|
|
UNIFIED_SOURCES += [
|
2013-04-23 14:54:15 -07:00
|
|
|
'Blur.cpp',
|
2013-11-27 03:21:21 -08:00
|
|
|
'DataSourceSurface.cpp',
|
2014-03-07 05:24:42 -08:00
|
|
|
'DataSurfaceHelpers.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'DrawEventRecorder.cpp',
|
2015-09-28 04:49:45 -07:00
|
|
|
'DrawingJob.cpp',
|
2014-08-01 09:01:47 -07:00
|
|
|
'DrawTarget.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'DrawTargetCairo.cpp',
|
2014-08-01 09:01:47 -07:00
|
|
|
'DrawTargetCapture.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'DrawTargetDual.cpp',
|
|
|
|
'DrawTargetRecording.cpp',
|
2015-02-23 13:20:35 -08:00
|
|
|
'DrawTargetTiled.cpp',
|
2013-11-27 03:22:46 -08:00
|
|
|
'FilterNodeSoftware.cpp',
|
2013-11-27 03:22:27 -08:00
|
|
|
'FilterProcessing.cpp',
|
|
|
|
'FilterProcessingScalar.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'ImageScaling.cpp',
|
2015-09-28 04:49:43 -07:00
|
|
|
'JobScheduler.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'Matrix.cpp',
|
2013-11-10 15:42:07 -08:00
|
|
|
'Path.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'PathCairo.cpp',
|
2015-11-27 20:49:55 -08:00
|
|
|
'PathHelpers.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'PathRecording.cpp',
|
2016-01-05 02:08:58 -08:00
|
|
|
'Preferences.cpp',
|
2015-04-01 13:02:20 -07:00
|
|
|
'Quaternion.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'RecordedEvent.cpp',
|
|
|
|
'Scale.cpp',
|
|
|
|
'ScaledFontBase.cpp',
|
2013-06-05 10:48:59 -07:00
|
|
|
'ScaledFontCairo.cpp',
|
2016-01-05 02:08:56 -08:00
|
|
|
'SFNTData.cpp',
|
|
|
|
'SFNTNameTable.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'SourceSurfaceCairo.cpp',
|
|
|
|
'SourceSurfaceRawData.cpp',
|
|
|
|
]
|
|
|
|
|
2016-01-08 00:43:58 -08:00
|
|
|
SOURCES += [
|
|
|
|
'Factory.cpp', # Need to suppress warnings in Skia header files.
|
|
|
|
]
|
|
|
|
|
|
|
|
if CONFIG['CLANG_CXX']:
|
|
|
|
SOURCES['Factory.cpp'].flags += ['-Wno-implicit-fallthrough']
|
|
|
|
|
2013-07-01 09:32:40 -07:00
|
|
|
if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
|
2015-06-12 05:48:42 -07:00
|
|
|
EXPORTS.mozilla.gfx += [
|
|
|
|
'QuartzSupport.h',
|
|
|
|
]
|
2013-10-24 16:23:05 -07:00
|
|
|
SOURCES += [
|
2013-11-07 19:53:54 -08:00
|
|
|
'MacIOSurface.cpp',
|
2013-07-01 09:32:40 -07:00
|
|
|
'QuartzSupport.mm',
|
|
|
|
]
|
2013-08-21 23:56:00 -07:00
|
|
|
|
2015-01-18 13:08:00 -08:00
|
|
|
if CONFIG['CPU_ARCH'] == 'arm' and CONFIG['BUILD_ARM_NEON']:
|
|
|
|
SOURCES += ['BlurNEON.cpp']
|
|
|
|
SOURCES['BlurNEON.cpp'].flags += ['-mfpu=neon']
|
|
|
|
|
2013-10-02 10:17:55 -07:00
|
|
|
include('/ipc/chromium/chromium-config.mozbuild')
|
|
|
|
|
2014-02-25 12:42:23 -08:00
|
|
|
FINAL_LIBRARY = 'xul'
|
2013-11-27 05:55:07 -08:00
|
|
|
|
2014-03-03 11:38:33 -08:00
|
|
|
for var in ('USE_CAIRO', 'MOZ2D_HAS_MOZ_CAIRO'):
|
2013-11-27 05:55:07 -08:00
|
|
|
DEFINES[var] = True
|
|
|
|
|
|
|
|
if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('android', 'gtk2', 'gtk3', 'gonk', 'qt'):
|
|
|
|
DEFINES['MOZ_ENABLE_FREETYPE'] = True
|
|
|
|
|
2014-07-24 08:55:33 -07:00
|
|
|
CXXFLAGS += CONFIG['MOZ_CAIRO_CFLAGS']
|
|
|
|
|
|
|
|
if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('android', 'gtk2', 'gtk3', 'gonk', 'qt'):
|
|
|
|
CXXFLAGS += CONFIG['CAIRO_FT_CFLAGS']
|
2015-02-23 09:46:55 -08:00
|
|
|
|
2015-07-30 09:05:22 -07:00
|
|
|
LOCAL_INCLUDES += CONFIG['SKIA_INCLUDES']
|