gfx/2d/moz.build

Sat, 03 Jan 2015 20:18:00 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Sat, 03 Jan 2015 20:18:00 +0100
branch
TOR_BUG_3246
changeset 7
129ffea94266
permissions
-rw-r--r--

Conditionally enable double key logic according to:
private browsing mode or privacy.thirdparty.isolate preference and
implement in GetCookieStringCommon and FindCookie where it counts...
With some reservations of how to convince FindCookie users to test
condition and pass a nullptr when disabling double key logic.

     1 # -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
     2 # vim: set filetype=python:
     3 # This Source Code Form is subject to the terms of the Mozilla Public
     4 # License, v. 2.0. If a copy of the MPL was not distributed with this
     5 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
     7 EXPORTS.mozilla += [
     8     'GenericRefCounted.h',
     9 ]
    11 EXPORTS.mozilla.gfx += [
    12     '2D.h',
    13     'BaseMargin.h',
    14     'BasePoint.h',
    15     'BasePoint3D.h',
    16     'BasePoint4D.h',
    17     'BaseRect.h',
    18     'BaseSize.h',
    19     'Blur.h',
    20     'BorrowedContext.h',
    21     'DataSurfaceHelpers.h',
    22     'Filters.h',
    23     'Helpers.h',
    24     'Logging.h',
    25     'Matrix.h',
    26     'PathHelpers.h',
    27     'Point.h',
    28     'Rect.h',
    29     'Scale.h',
    30     'ScaleFactor.h',
    31     'Tools.h',
    32     'Types.h',
    33     'UserData.h',
    34 ]
    36 if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
    37     EXPORTS.mozilla.gfx += [
    38         'MacIOSurface.h',
    39         'QuartzSupport.h',
    40     ]
    41     UNIFIED_SOURCES += [
    42         'DrawTargetCG.cpp',
    43         'PathCG.cpp',
    44         'ScaledFontMac.cpp',
    45         'SourceSurfaceCG.cpp',
    46     ]
    47 elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
    48     SOURCES += [
    49         'DrawTargetD2D.cpp',
    50         'PathD2D.cpp',
    51         'ScaledFontDWrite.cpp',
    52         'SourceSurfaceD2D.cpp',
    53         'SourceSurfaceD2DTarget.cpp',
    54     ]
    55     DEFINES['WIN32'] = True
    56     # For Direct2D 1.1 we require WINSDK_MAXVER 0x06020000 or higher.
    57     if CONFIG['MOZ_ENABLE_DIRECT2D1_1']:
    58         SOURCES += [
    59             'DrawTargetD2D1.cpp',
    60             'FilterNodeD2D1.cpp',
    61             'RadialGradientEffectD2D1.cpp',
    62             'SourceSurfaceD2D1.cpp'
    63         ]
    64         DEFINES['USE_D2D1_1'] = True
    65     if CONFIG['MOZ_ENABLE_SKIA']:
    66         SOURCES += [
    67             'ScaledFontWin.cpp',
    68         ]
    70 if CONFIG['MOZ_ENABLE_SKIA']:
    71     UNIFIED_SOURCES += [
    72         'convolver.cpp',
    73         'DrawTargetSkia.cpp',
    74         'PathSkia.cpp',
    75         'SourceSurfaceSkia.cpp',
    76     ]
    77     SOURCES += [
    78         'image_operations.cpp', # Uses _USE_MATH_DEFINES
    79     ]
    81 # Are we targeting x86 or x64?  If so, build SSE2 files.
    82 if CONFIG['INTEL_ARCHITECTURE']:
    83     # VC2005 doesn't support _mm_castsi128_ps, so SSE2 is turned off
    84     if CONFIG['_MSC_VER'] != '1400':
    85         SOURCES += [
    86             'BlurSSE2.cpp',
    87             'FilterProcessingSSE2.cpp',
    88             'ImageScalingSSE2.cpp',
    89         ]
    90         DEFINES['USE_SSE2'] = True
    91         # The file uses SSE2 intrinsics, so it needs special compile flags on some
    92         # compilers.
    93         SOURCES['BlurSSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
    94         SOURCES['FilterProcessingSSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
    95         SOURCES['ImageScalingSSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
    97 UNIFIED_SOURCES += [
    98     'Blur.cpp',
    99     'DataSourceSurface.cpp',
   100     'DataSurfaceHelpers.cpp',
   101     'DrawEventRecorder.cpp',
   102     'DrawTargetCairo.cpp',
   103     'DrawTargetDual.cpp',
   104     'DrawTargetRecording.cpp',
   105     'Factory.cpp',
   106     'FilterNodeSoftware.cpp',
   107     'FilterProcessing.cpp',
   108     'FilterProcessingScalar.cpp',
   109     'ImageScaling.cpp',
   110     'Matrix.cpp',
   111     'Path.cpp',
   112     'PathCairo.cpp',
   113     'PathHelpers.cpp',
   114     'PathRecording.cpp',
   115     'RecordedEvent.cpp',
   116     'Scale.cpp',
   117     'ScaledFontBase.cpp',
   118     'ScaledFontCairo.cpp',
   119     'SourceSurfaceCairo.cpp',
   120     'SourceSurfaceRawData.cpp',
   121 ]
   123 if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
   124     SOURCES += [
   125         'MacIOSurface.cpp',
   126         'QuartzSupport.mm',
   127     ]
   129 FAIL_ON_WARNINGS = True
   131 MSVC_ENABLE_PGO = True
   133 include('/ipc/chromium/chromium-config.mozbuild')
   135 FINAL_LIBRARY = 'xul'
   137 for var in ('USE_CAIRO', 'MOZ2D_HAS_MOZ_CAIRO'):
   138     DEFINES[var] = True
   140 if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('android', 'gtk2', 'gtk3', 'gonk', 'qt'):
   141     DEFINES['MOZ_ENABLE_FREETYPE'] = True
   143 DEFINES['SK_A32_SHIFT'] = 24
   144 DEFINES['SK_R32_SHIFT'] = 16
   145 DEFINES['SK_G32_SHIFT'] = 8
   146 DEFINES['SK_B32_SHIFT'] = 0
   148 if CONFIG['MOZ_DEBUG']:
   149     DEFINES['GFX_LOG_DEBUG'] = True
   150     DEFINES['GFX_LOG_WARNING'] = True

mercurial