Bug 1340627 - part 2 - update moz.build for Skia m59. r=jrmuizel
☠☠ backed out by ce2218406119 ☠ ☠
authorLee Salzman <lsalzman@mozilla.com>
Tue, 09 May 2017 22:31:06 -0400
changeset 407938 0d4ec7d38a0028cb193f68bae18e014b7df72dc1
parent 407937 af6f19870b2a00759ac1d83dedc3db57213abfee
child 407939 75fb0d9858a9a6853c922aa671e417a3d672e105
push id1490
push usermtabara@mozilla.com
push dateMon, 31 Jul 2017 14:08:16 +0000
treeherdermozilla-release@70e32e6bf15e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjrmuizel
bugs1340627
milestone55.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1340627 - part 2 - update moz.build for Skia m59. r=jrmuizel MozReview-Commit-ID: KdPvBio96Cw
gfx/skia/README_MOZILLA
gfx/skia/dump_mozbuild.py
gfx/skia/generate_mozbuild.py
gfx/skia/gyp_mozbuild
gfx/skia/moz.build
--- a/gfx/skia/README_MOZILLA
+++ b/gfx/skia/README_MOZILLA
@@ -1,12 +1,12 @@
 This is an import of Skia. See skia/include/core/SkMilestone.h for the milestone number.
 
 To update to a new version of Skia:
 
-- Clone Skia from upstream using the instructions here: https://sites.google.com/site/skiadocs/user-documentation/downloading
+- Clone Skia from upstream using the instructions here: https://skia.org/user/download
 - Copy the entire source tree from a Skia clone to mozilla-central/gfx/skia/skia
-- cd gfx/skia && ./gyp_mozbuild
+- cd gfx/skia && ./generate_mozbuild.py
 
 Once that's done, use git status to view the files that have changed. Keep an eye on GrUserConfig.h
 and SkUserConfig.h as those probably don't want to be overwritten by upstream versions.
 
 This process will be made more automatic in the future.
deleted file mode 100644
--- a/gfx/skia/dump_mozbuild.py
+++ /dev/null
@@ -1,92 +0,0 @@
-# Copyright (c) 2012 Google Inc. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-import collections
-import os
-import gyp
-import gyp.common
-import gyp.msvs_emulation
-import json
-import sys
-
-generator_supports_multiple_toolsets = True
-
-generator_wants_static_library_dependencies_adjusted = False
-
-generator_default_variables = {
-}
-for dirname in ['INTERMEDIATE_DIR', 'SHARED_INTERMEDIATE_DIR', 'PRODUCT_DIR',
-                'LIB_DIR', 'SHARED_LIB_DIR']:
-  # Some gyp steps fail if these are empty(!).
-  generator_default_variables[dirname] = 'dir'
-for unused in ['RULE_INPUT_PATH', 'RULE_INPUT_ROOT', 'RULE_INPUT_NAME',
-               'RULE_INPUT_DIRNAME', 'RULE_INPUT_EXT',
-               'EXECUTABLE_PREFIX', 'EXECUTABLE_SUFFIX',
-               'STATIC_LIB_PREFIX', 'STATIC_LIB_SUFFIX',
-               'SHARED_LIB_PREFIX', 'SHARED_LIB_SUFFIX',
-               'CONFIGURATION_NAME']:
-  generator_default_variables[unused] = ''
-
-
-def CalculateVariables(default_variables, params):
-  generator_flags = params.get('generator_flags', {})
-  for key, val in generator_flags.items():
-    default_variables.setdefault(key, val)
-  default_variables.setdefault('OS', gyp.common.GetFlavor(params))
-
-  flavor = gyp.common.GetFlavor(params)
-  if flavor =='win':
-    # Copy additional generator configuration data from VS, which is shared
-    # by the Windows Ninja generator.
-    import gyp.generator.msvs as msvs_generator
-    generator_additional_non_configuration_keys = getattr(msvs_generator,
-        'generator_additional_non_configuration_keys', [])
-    generator_additional_path_sections = getattr(msvs_generator,
-        'generator_additional_path_sections', [])
-
-    gyp.msvs_emulation.CalculateCommonVariables(default_variables, params)
-
-
-def CalculateGeneratorInputInfo(params):
-  """Calculate the generator specific info that gets fed to input (called by
-  gyp)."""
-  generator_flags = params.get('generator_flags', {})
-  if generator_flags.get('adjust_static_libraries', False):
-    global generator_wants_static_library_dependencies_adjusted
-    generator_wants_static_library_dependencies_adjusted = True
-
-def GetOS(params):
-  for d in params['defines']:
-    pass
-
-def GenerateOutput(target_list, target_dicts, data, params):
-  # Map of target -> list of targets it depends on.
-  edges = {}
-
-  # Queue of targets to visit.
-  targets_to_visit = target_list[:]
-
-  sources = [];
-
-  while len(targets_to_visit) > 0:
-    target = targets_to_visit.pop()
-    if target in edges:
-      continue
-    edges[target] = []
-
-    target_sources = target_dicts[target].get('sources')
-    if target_sources:
-      for source in target_sources:
-        if source.endswith('.cpp'):
-          sources.append(source)
-
-    for dep in target_dicts[target].get('dependencies', []):
-      edges[target].append(dep)
-      targets_to_visit.append(dep)
-
-  skia_os = data['gyp/core.gyp']['variables']['skia_os%']
-
-  f = open('sources.json', 'w')
-  json.dump(sources, f)
-  f.close()
\ No newline at end of file
--- a/gfx/skia/generate_mozbuild.py
+++ b/gfx/skia/generate_mozbuild.py
@@ -1,13 +1,12 @@
 #!/usr/bin/env python
 
-import os
-
 import locale
+import subprocess
 from collections import defaultdict
 locale.setlocale(locale.LC_ALL, 'en_US.UTF-8')
 
 header = """
 #
 #   #####   #######           #     #     #     #     #     #
 # ##     #  #     #          # #    #  #  #    # #     #   #
 # ##        #     #         #   #   #  #  #   #   #     # #
@@ -39,80 +38,69 @@ ALLOW_COMPILER_WARNINGS = True
 
 FINAL_LIBRARY = 'gkmedias'
 LOCAL_INCLUDES += [
     'skia/include/c',
     'skia/include/config',
     'skia/include/core',
     'skia/include/effects',
     'skia/include/gpu',
-    'skia/include/images',
     'skia/include/pathops',
     'skia/include/ports',
     'skia/include/private',
     'skia/include/utils',
     'skia/include/utils/mac',
     'skia/include/views',
     'skia/src/core',
     'skia/src/gpu',
     'skia/src/gpu/effects',
     'skia/src/gpu/gl',
+    'skia/src/gpu/glsl',
     'skia/src/image',
     'skia/src/lazy',
     'skia/src/opts',
     'skia/src/sfnt',
+    'skia/src/sksl',
     'skia/src/utils',
     'skia/src/utils/mac',
     'skia/src/utils/win',
 ]
 
-if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('android'):
-    DEFINES['SK_FONTHOST_CAIRO_STANDALONE'] = 0
-
-if CONFIG['MOZ_WIDGET_TOOLKIT'] in {
-    'android',
-    'cocoa',
-    'gtk2',
-    'gtk3',
-    'uikit',
-  }:
-    DEFINES['SK_FONTHOST_DOES_NOT_USE_FONTMGR'] = 1
-
 if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
     DEFINES['UNICODE'] = True
     DEFINES['_UNICODE'] = True
     UNIFIED_SOURCES += [
         'skia/src/fonts/SkFontMgr_indirect.cpp',
         'skia/src/fonts/SkRemotableFontMgr.cpp',
     ]
 
 # We should autogenerate these SSE related flags.
 
-if CONFIG['_MSC_VER']:
+if CONFIG['INTEL_ARCHITECTURE'] and (CONFIG['GNU_CC'] or CONFIG['CLANG_CL']):
+    SOURCES['skia/src/opts/SkBitmapProcState_opts_SSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
+    SOURCES['skia/src/opts/SkBitmapProcState_opts_SSSE3.cpp'].flags += ['-mssse3']
+    SOURCES['skia/src/opts/SkBlitRow_opts_SSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
+    SOURCES['skia/src/opts/SkOpts_ssse3.cpp'].flags += ['-mssse3']
+    SOURCES['skia/src/opts/SkOpts_sse41.cpp'].flags += ['-msse4.1']
+    SOURCES['skia/src/opts/SkOpts_sse42.cpp'].flags += ['-msse4.2']
+    SOURCES['skia/src/opts/SkOpts_avx.cpp'].flags += ['-mavx']
+    SOURCES['skia/src/opts/SkOpts_hsw.cpp'].flags += ['-mavx2']
+elif CONFIG['_MSC_VER']:
     # MSVC doesn't need special compiler flags, but Skia needs to be told that these files should
     # be built with the required SSE level or it will simply compile in stubs and cause runtime crashes
-    SOURCES['skia/src/opts/SkBitmapFilter_opts_SSE2.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=20']
     SOURCES['skia/src/opts/SkBitmapProcState_opts_SSE2.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=20']
     SOURCES['skia/src/opts/SkBitmapProcState_opts_SSSE3.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=31']
     SOURCES['skia/src/opts/SkBlitRow_opts_SSE2.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=20']
     SOURCES['skia/src/opts/SkOpts_ssse3.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=31']
     SOURCES['skia/src/opts/SkOpts_sse41.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=41']
     SOURCES['skia/src/opts/SkOpts_sse42.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=42']
     SOURCES['skia/src/opts/SkOpts_avx.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=51']
-if CONFIG['INTEL_ARCHITECTURE'] and (CONFIG['GNU_CC'] or CONFIG['CLANG_CL']):
-    SOURCES['skia/src/opts/SkBitmapFilter_opts_SSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
-    SOURCES['skia/src/opts/SkBitmapProcState_opts_SSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
-    SOURCES['skia/src/opts/SkBitmapProcState_opts_SSSE3.cpp'].flags += ['-mssse3']
-    SOURCES['skia/src/opts/SkBlitRow_opts_SSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
-    SOURCES['skia/src/opts/SkOpts_ssse3.cpp'].flags += ['-mssse3']
-    SOURCES['skia/src/opts/SkOpts_sse41.cpp'].flags += ['-msse4.1']
-    SOURCES['skia/src/opts/SkOpts_sse42.cpp'].flags += ['-msse4.2']
-    SOURCES['skia/src/opts/SkOpts_avx.cpp'].flags += ['-mavx']
-elif CONFIG['CPU_ARCH'] == 'arm' and CONFIG['GNU_CC'] and CONFIG['BUILD_ARM_NEON']:
-    DEFINES['SK_ARM_HAS_OPTIONAL_NEON'] = 1
+    SOURCES['skia/src/opts/SkOpts_hsw.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=52']
+elif CONFIG['CPU_ARCH'] == 'arm' and CONFIG['GNU_CC']:
+    CXXFLAGS += CONFIG['NEON_FLAGS']
 
 DEFINES['SKIA_IMPLEMENTATION'] = 1
 
 if CONFIG['MOZ_ENABLE_SKIA_PDF_SFNTLY'] and CONFIG['ENABLE_INTL_API']:
     DEFINES['SK_PDF_USE_SFNTLY'] = 1
 
 if not CONFIG['MOZ_ENABLE_SKIA_GPU']:
     DEFINES['SK_SUPPORT_GPU'] = 0
@@ -153,100 +141,95 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk
 if CONFIG['MOZ_ENABLE_SKIA_PDF_SFNTLY']:
     LOCAL_INCLUDES += CONFIG['SFNTLY_INCLUDES']
 """
 
 import json
 
 platforms = ['linux', 'mac', 'android', 'win']
 
+def parse_sources(output):
+  return set(v.replace('//', 'skia/') for v in output.split() if v.endswith('.cpp') or v.endswith('.S'))
+
 def generate_opt_sources():
-  opt_sources = {'opts': {''}}
-  for root, dirs, files in os.walk('skia/src/opts'):
-    for name in files:
-      if name.endswith('.cpp'):
-        opt_sources['opts'].add(os.path.join(root, name))
+  cpus = [('intel', 'x86', [':sse2', ':ssse3', ':sse41', ':sse42', ':avx', ':hsw']),
+          ('arm', 'arm', [':armv7']),
+          ('none', 'none', [':none'])]
+
+  opt_sources = {}
+  for key, cpu, deps in cpus:
+    subprocess.check_output('cd skia && bin/gn gen out/{0} --args=\'target_cpu="{1}"\''.format(key, cpu), shell=True)
+    opt_sources[key] = set()
+    for dep in deps:
+        output = subprocess.check_output('cd skia && bin/gn desc out/{0} {1} sources'.format(key, dep), shell=True)
+        if output:
+            opt_sources[key].update(parse_sources(output))
 
   return opt_sources
 
 def generate_platform_sources():
   sources = {}
 
   for plat in platforms:
-    if os.system("cd skia && GYP_GENERATORS=dump_mozbuild ./gyp_skia -D OS=%s -D host_os=linux gyp/skia_lib.gyp" % plat) != 0:
-      print 'Failed to generate sources for ' + plat
-      continue
+    output = subprocess.check_output('cd skia && bin/gn gen out/{0} --args=\'target_os="{0}"\' > /dev/null && bin/gn desc out/{0} :skia sources'.format(plat), shell=True)
+    if output:
+      sources[plat] = parse_sources(output)
 
-
-    f = open('skia/sources.json');
-    sources[plat] = set(v.replace('../', 'skia/') for v in json.load(f));
-    f.close()
+  deps = {':effects' : 'common', ':gpu' : 'gpu', ':pdf' : 'pdf'}
+  for dep, key in deps.items():
+    output = subprocess.check_output('cd skia && bin/gn desc out/linux {} sources'.format(dep), shell=True)
+    if output:
+      sources[key] = parse_sources(output)
 
   return dict(sources.items() + generate_opt_sources().items())
 
 
 def generate_separated_sources(platform_sources):
   blacklist = [
-    'experimental',
-    'SkXML',
     'GrGLCreateNativeInterface',
     'GrGLCreateNullInterface',
     'GrGLAssembleInterface',
     'GrGLTestInterface',
-    'fontconfig',
-    'FontConfig',
-    'SkThreadUtils_pthread_',
-    'SkFontMgr_android',
-    'SkFontMgr_custom',
-    'SkFontHost_FreeType.cpp',
-    'Movie',
     'ImageEncoder',
     'skia/src/c/',
     'skia/src/effects/Gr',
     'skia/src/effects/Sk',
     'skia/src/fonts/',
     'skia/src/images/',
     'skia/src/ports/SkImageGenerator',
-    'skia/src/sksl/',
     'skia/src/gpu/vk/',
     'SkBitmapRegion',
     'SkLight',
     'SkRadialShadow',
     'SkShadow',
     'SkNormal',
     'SkLite',
     'codec',
     'SkWGL',
     'SkMemory_malloc',
-    'SkOpts_',
-    'opts_check_x86',
     'third_party',
-    # unused in skia/src/utils
-    'SkBoundaryPatch',
     'SkCamera',
     'SkCanvasStack',
     'SkCanvasStateUtils',
     'SkCurveMeasure',
     'SkDeferredCanvas',
     'SkDumpCanvas',
     'SkFrontBufferedStream',
     'SkInterpolator',
-    'SkLayer',
-    'SkMeshUtils',
     'SkMD5',
     'SkMultiPictureDocument',
-    'SkNinePatch',
     'SkNullCanvas',
     'SkNWayCanvas',
+    'SkOverdrawCanvas',
     'SkPaintFilterCanvas',
     'SkParseColor',
-    'SkPatchGrid',
-    'SkRTConf',
     'SkTextBox',
     'SkWhitelistTypefaces',
+    'SkXPS',
+    'SkCreateCGImageRef',
   ]
 
   def isblacklisted(value):
     for item in blacklist:
       if value.find(item) >= 0:
         return True
 
     return False
@@ -263,77 +246,49 @@ def generate_separated_sources(platform_
       'skia/src/ports/SkMemory_mozalloc.cpp',
       'skia/src/ports/SkImageEncoder_none.cpp',
       'skia/src/ports/SkImageGenerator_none.cpp',
     },
     'android': {
       # 'skia/src/ports/SkDebug_android.cpp',
       'skia/src/ports/SkFontHost_cairo.cpp',
       # 'skia/src/ports/SkFontHost_FreeType.cpp',
-      # 'skia/src/ports/SkFontHost_FreeType_common.cpp',
+      'skia/src/ports/SkFontHost_FreeType_common.cpp',
       # 'skia/src/ports/SkTime_Unix.cpp',
       # 'skia/src/utils/SkThreadUtils_pthread.cpp',
     },
     'linux': {
       'skia/src/ports/SkFontHost_cairo.cpp',
+      'skia/src/ports/SkFontHost_FreeType_common.cpp',
     },
-    'intel': {
-      # There is currently no x86-specific opt for SkTextureCompression
-      'skia/src/opts/opts_check_x86.cpp',
-      'skia/src/opts/SkOpts_ssse3.cpp',
-      'skia/src/opts/SkOpts_sse41.cpp',
-      'skia/src/opts/SkOpts_sse42.cpp',
-      'skia/src/opts/SkOpts_avx.cpp',
-      'skia/src/opts/SkOpts_hsw.cpp',
+    'intel': set(),
+    'arm': set(),
+    'none': set(),
+    'pdf': {
+      'skia/src/core/SkMD5.cpp',
     },
-    'arm': {
-      'skia/src/core/SkUtilsArm.cpp',
-    },
-    'neon': {
-      'skia/src/opts/SkOpts_neon.cpp',
-    },
-    'none': set(),
-    'pdf': set(),
     'gpu': set()
   })
 
   for plat in platform_sources.keys():
     for value in platform_sources[plat]:
       if isblacklisted(value):
         continue
 
       if value in separated['common']:
         continue
 
       key = plat
 
-      if '_SSE' in value or '_SSSE' in value:
-        key = 'intel'
-      elif '_neon' in value:
-        key = 'neon'
-      elif '_arm' in value:
-        key = 'arm'
-      elif '_none' in value:
-        key = 'none'
-      elif 'gpu' in value or 'Gpu' in value:
-        key = 'gpu'
-      elif all(value in platform_sources.get(p, {})
-               for p in platforms if p != plat):
+      if all(value in platform_sources.get(p, {})
+             for p in platforms if p != plat):
         key = 'common'
 
       separated[key].add(value)
 
-  if os.system("cd skia && GYP_GENERATORS=dump_mozbuild ./gyp_skia -D OS=linux -D host_os=linux -R pdf gyp/pdf.gyp") != 0:
-    print 'Failed to generate sources for Skia PDF'
-  else:
-    f = open('skia/sources.json');
-    separated['pdf'].add('skia/src/core/SkMD5.cpp');
-    separated['pdf'].update(filter(lambda x: 'pdf' in x, set(v.replace('../', 'skia/') for v in json.load(f))));
-    f.close()
-
   return separated
 
 def uniq(seq):
   seen = set()
   seen_add = seen.add
   return [ x for x in seq if x not in seen and not seen_add(x)]
 
 def write_cflags(f, values, subsearch, cflag, indent):
@@ -378,34 +333,40 @@ unified_blacklist = [
   'FontHost',
   'SkAdvancedTypefaceMetrics',
   'SkBitmapProcState_matrixProcs.cpp',
   'SkBlitter_A8.cpp',
   'SkBlitter_ARGB32.cpp',
   'SkBlitter_RGB16.cpp',
   'SkBlitter_Sprite.cpp',
   'SkScan_Antihair.cpp',
+  'SkScan_AntiPath.cpp',
   'SkParse.cpp',
   'SkPDFFont.cpp',
   'SkPictureData.cpp',
-  'GrDrawContext',
   'GrResourceCache',
+  'GrResourceProvider',
   'GrAA',
   'GrGL',
-  'GrBatchAtlas.cpp',
   'GrMSAAPathRenderer.cpp',
   'GrNonAAFillRect',
+  'GrPathUtils',
+  'GrShadowRRectOp',
   'SkColorSpace',
   'SkImage_Gpu.cpp',
   'SkPathOpsDebug.cpp',
   'SkParsePath.cpp',
   'SkRecorder.cpp',
   'SkMiniRecorder.cpp',
   'SkXfermode',
   'SkMatrix44.cpp',
+  'SkRTree.cpp',
+  'SkVertices.cpp',
+  'SkJumper',
+  'lex.layout.cpp',
 ] + opt_whitelist
 
 def write_sources(f, values, indent):
   def isblacklisted(value):
     for item in unified_blacklist:
       if value.find(item) >= 0:
         return True
 
@@ -453,46 +414,37 @@ def write_mozbuild(sources):
   write_cflags(f, sources['common'], opt_whitelist, 'skia_opt_flags', 0)
 
   f.write("if CONFIG['MOZ_ENABLE_SKIA_PDF']:\n")
   write_sources(f, sources['pdf'], 4)
 
   f.write("if CONFIG['MOZ_ENABLE_SKIA_GPU']:\n")
   write_sources(f, sources['gpu'], 4)
 
-  f.write("if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('android'):\n")
+  f.write("if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'android':\n")
   write_sources(f, sources['android'], 4)
 
-  f.write("if CONFIG['MOZ_WIDGET_TOOLKIT'] in {'cocoa', 'uikit'}:\n")
+  f.write("if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('cocoa', 'uikit'):\n")
   write_sources(f, sources['mac'], 4)
 
-  f.write("if 'gtk' in CONFIG['MOZ_WIDGET_TOOLKIT']:\n")
+  f.write("if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3'):\n")
   write_sources(f, sources['linux'], 4)
 
   f.write("if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':\n")
   # Windows-specific files don't get unification because of nasty headers.
   # Luckily there are not many files in this.
   write_list(f, "SOURCES", sources['win'], 4)
 
   f.write("if CONFIG['INTEL_ARCHITECTURE']:\n")
   write_sources(f, sources['intel'], 4)
   write_cflags(f, sources['intel'], opt_whitelist, 'skia_opt_flags', 4)
 
   f.write("elif CONFIG['CPU_ARCH'] in ('arm', 'aarch64') and CONFIG['GNU_CC']:\n")
   write_sources(f, sources['arm'], 4)
   write_cflags(f, sources['arm'], opt_whitelist, 'skia_opt_flags', 4)
-
-  f.write("    if CONFIG['CPU_ARCH'] == 'aarch64':\n")
-  write_sources(f, sources['neon'], 8)
-  f.write("    elif CONFIG['BUILD_ARM_NEON']:\n")
-  write_list(f, 'SOURCES', sources['neon'], 8)
-  write_cflags(f, sources['neon'], 'neon', "CONFIG['NEON_FLAGS']", 8)
-
-  f.write("    if CONFIG['CPU_ARCH'] == 'aarch64' or CONFIG['BUILD_ARM_NEON']:\n")
-  write_cflags(f, sources['neon'], opt_whitelist, 'skia_opt_flags', 8)
  
   f.write("else:\n")
   write_sources(f, sources['none'], 4)
 
   f.write(footer)
 
   f.close()
 
deleted file mode 100755
--- a/gfx/skia/gyp_mozbuild
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/bin/bash
-
-# Install our generator
-cp dump_mozbuild.py skia/third_party/externals/gyp/pylib/gyp/generator
-
-# pushd skia
-# for OS in win linux mac; do
-#     GYP_GENERATORS=dump_mozbuild ./gyp_skia -D OS=$OS -D arm_neon=0 gyp/effects.gyp
-# done
-# popd
-
-./generate_mozbuild.py
-
--- a/gfx/skia/moz.build
+++ b/gfx/skia/moz.build
@@ -20,41 +20,45 @@ if CONFIG['MOZ_OPTIMIZE']:
     if CONFIG['_MSC_VER']:
         skia_opt_flags += ['-O2']
     elif CONFIG['GNU_CC']:
         skia_opt_flags += ['-O3']
 
 UNIFIED_SOURCES += [
     'skia/src/core/SkAAClip.cpp',
     'skia/src/core/SkAlphaRuns.cpp',
+    'skia/src/core/SkAnalyticEdge.cpp',
     'skia/src/core/SkAnnotation.cpp',
+    'skia/src/core/SkArenaAlloc.cpp',
+    'skia/src/core/SkATrace.cpp',
     'skia/src/core/SkAutoPixmapStorage.cpp',
     'skia/src/core/SkBBHFactory.cpp',
     'skia/src/core/SkBigPicture.cpp',
     'skia/src/core/SkBitmap.cpp',
     'skia/src/core/SkBitmapCache.cpp',
     'skia/src/core/SkBitmapController.cpp',
     'skia/src/core/SkBitmapDevice.cpp',
     'skia/src/core/SkBitmapProcShader.cpp',
     'skia/src/core/SkBitmapProvider.cpp',
     'skia/src/core/SkBitmapScaler.cpp',
     'skia/src/core/SkBlurImageFilter.cpp',
     'skia/src/core/SkBuffer.cpp',
     'skia/src/core/SkCachedData.cpp',
     'skia/src/core/SkCanvas.cpp',
-    'skia/src/core/SkChunkAlloc.cpp',
     'skia/src/core/SkClipStack.cpp',
+    'skia/src/core/SkClipStackDevice.cpp',
     'skia/src/core/SkColor.cpp',
     'skia/src/core/SkColorFilter.cpp',
     'skia/src/core/SkColorFilterShader.cpp',
+    'skia/src/core/SkColorLookUpTable.cpp',
     'skia/src/core/SkColorMatrixFilterRowMajor255.cpp',
     'skia/src/core/SkColorShader.cpp',
     'skia/src/core/SkColorTable.cpp',
     'skia/src/core/SkComposeShader.cpp',
-    'skia/src/core/SkConfig8888.cpp',
+    'skia/src/core/SkConvertPixels.cpp',
     'skia/src/core/SkConvolver.cpp',
     'skia/src/core/SkCpu.cpp',
     'skia/src/core/SkCubicClipper.cpp',
     'skia/src/core/SkData.cpp',
     'skia/src/core/SkDataTable.cpp',
     'skia/src/core/SkDebug.cpp',
     'skia/src/core/SkDeque.cpp',
     'skia/src/core/SkDevice.cpp',
@@ -64,33 +68,33 @@ UNIFIED_SOURCES += [
     'skia/src/core/SkDither.cpp',
     'skia/src/core/SkDocument.cpp',
     'skia/src/core/SkDraw.cpp',
     'skia/src/core/SkDrawable.cpp',
     'skia/src/core/SkDrawLooper.cpp',
     'skia/src/core/SkEdge.cpp',
     'skia/src/core/SkEdgeBuilder.cpp',
     'skia/src/core/SkEdgeClipper.cpp',
-    'skia/src/core/SkError.cpp',
+    'skia/src/core/SkExecutor.cpp',
     'skia/src/core/SkFilterProc.cpp',
     'skia/src/core/SkFlattenable.cpp',
     'skia/src/core/SkFlattenableSerialization.cpp',
     'skia/src/core/SkFont.cpp',
     'skia/src/core/SkFontDescriptor.cpp',
     'skia/src/core/SkFontLCDConfig.cpp',
     'skia/src/core/SkFontMgr.cpp',
     'skia/src/core/SkFontStream.cpp',
     'skia/src/core/SkFontStyle.cpp',
-    'skia/src/core/SkForceCPlusPlusLinking.cpp',
     'skia/src/core/SkGeometry.cpp',
     'skia/src/core/SkGlobalInitialization_core.cpp',
     'skia/src/core/SkGlyphCache.cpp',
     'skia/src/core/SkGpuBlurUtils.cpp',
     'skia/src/core/SkGraphics.cpp',
     'skia/src/core/SkHalf.cpp',
+    'skia/src/core/SkICC.cpp',
     'skia/src/core/SkImageCacherator.cpp',
     'skia/src/core/SkImageFilter.cpp',
     'skia/src/core/SkImageFilterCache.cpp',
     'skia/src/core/SkImageGenerator.cpp',
     'skia/src/core/SkImageInfo.cpp',
     'skia/src/core/SkLatticeIter.cpp',
     'skia/src/core/SkLinearBitmapPipeline.cpp',
     'skia/src/core/SkLineClipper.cpp',
@@ -139,22 +143,21 @@ UNIFIED_SOURCES += [
     'skia/src/core/SkRecordOpts.cpp',
     'skia/src/core/SkRecords.cpp',
     'skia/src/core/SkRect.cpp',
     'skia/src/core/SkRefDict.cpp',
     'skia/src/core/SkRegion.cpp',
     'skia/src/core/SkRegion_path.cpp',
     'skia/src/core/SkResourceCache.cpp',
     'skia/src/core/SkRRect.cpp',
-    'skia/src/core/SkRTree.cpp',
     'skia/src/core/SkRWBuffer.cpp',
     'skia/src/core/SkScalar.cpp',
     'skia/src/core/SkScalerContext.cpp',
     'skia/src/core/SkScan.cpp',
-    'skia/src/core/SkScan_AntiPath.cpp',
+    'skia/src/core/SkScan_AAAPath.cpp',
     'skia/src/core/SkScan_Hairline.cpp',
     'skia/src/core/SkScan_Path.cpp',
     'skia/src/core/SkSemaphore.cpp',
     'skia/src/core/SkShader.cpp',
     'skia/src/core/SkSharedMutex.cpp',
     'skia/src/core/SkSpanProcs.cpp',
     'skia/src/core/SkSpecialImage.cpp',
     'skia/src/core/SkSpecialSurface.cpp',
@@ -164,16 +167,17 @@ UNIFIED_SOURCES += [
     'skia/src/core/SkString.cpp',
     'skia/src/core/SkStringUtils.cpp',
     'skia/src/core/SkStroke.cpp',
     'skia/src/core/SkStrokeRec.cpp',
     'skia/src/core/SkStrokerPriv.cpp',
     'skia/src/core/SkSwizzle.cpp',
     'skia/src/core/SkTaskGroup.cpp',
     'skia/src/core/SkTextBlob.cpp',
+    'skia/src/core/SkThreadedBMPDevice.cpp',
     'skia/src/core/SkThreadID.cpp',
     'skia/src/core/SkTime.cpp',
     'skia/src/core/SkTLS.cpp',
     'skia/src/core/SkTSearch.cpp',
     'skia/src/core/SkTypeface.cpp',
     'skia/src/core/SkTypefaceCache.cpp',
     'skia/src/core/SkUnPreMultiply.cpp',
     'skia/src/core/SkUtils.cpp',
@@ -187,27 +191,29 @@ UNIFIED_SOURCES += [
     'skia/src/effects/gradients/Sk4fLinearGradient.cpp',
     'skia/src/effects/gradients/SkClampRange.cpp',
     'skia/src/effects/gradients/SkGradientBitmapCache.cpp',
     'skia/src/effects/gradients/SkGradientShader.cpp',
     'skia/src/effects/gradients/SkLinearGradient.cpp',
     'skia/src/effects/gradients/SkRadialGradient.cpp',
     'skia/src/effects/gradients/SkSweepGradient.cpp',
     'skia/src/effects/gradients/SkTwoPointConicalGradient.cpp',
+    'skia/src/effects/gradients/SkTwoPointConicalGradient_gpu.cpp',
+    'skia/src/effects/shadows/SkAmbientShadowMaskFilter.cpp',
+    'skia/src/effects/shadows/SkSpotShadowMaskFilter.cpp',
     'skia/src/effects/SkDashPathEffect.cpp',
     'skia/src/effects/SkImageSource.cpp',
     'skia/src/effects/SkLayerRasterizer.cpp',
     'skia/src/image/SkImage.cpp',
     'skia/src/image/SkImage_Generator.cpp',
     'skia/src/image/SkImage_Raster.cpp',
     'skia/src/image/SkImageShader.cpp',
     'skia/src/image/SkSurface.cpp',
     'skia/src/image/SkSurface_Raster.cpp',
     'skia/src/lazy/SkDiscardableMemoryPool.cpp',
-    'skia/src/lazy/SkDiscardablePixelRef.cpp',
     'skia/src/pathops/SkAddIntersections.cpp',
     'skia/src/pathops/SkDConicLineIntersection.cpp',
     'skia/src/pathops/SkDCubicLineIntersection.cpp',
     'skia/src/pathops/SkDCubicToQuads.cpp',
     'skia/src/pathops/SkDLineIntersection.cpp',
     'skia/src/pathops/SkDQuadLineIntersection.cpp',
     'skia/src/pathops/SkIntersections.cpp',
     'skia/src/pathops/SkOpAngle.cpp',
@@ -239,59 +245,74 @@ UNIFIED_SOURCES += [
     'skia/src/ports/SkDiscardableMemory_none.cpp',
     'skia/src/ports/SkGlobalInitialization_default.cpp',
     'skia/src/ports/SkImageEncoder_none.cpp',
     'skia/src/ports/SkImageGenerator_none.cpp',
     'skia/src/ports/SkMemory_mozalloc.cpp',
     'skia/src/ports/SkOSFile_stdio.cpp',
     'skia/src/sfnt/SkOTTable_name.cpp',
     'skia/src/sfnt/SkOTUtils.cpp',
+    'skia/src/utils/mac/SkStream_mac.cpp',
     'skia/src/utils/SkBase64.cpp',
     'skia/src/utils/SkBitmapSourceDeserializer.cpp',
     'skia/src/utils/SkDashPath.cpp',
     'skia/src/utils/SkEventTracer.cpp',
+    'skia/src/utils/SkInsetConvexPolygon.cpp',
     'skia/src/utils/SkMatrix22.cpp',
-    'skia/src/utils/SkOSFile.cpp',
+    'skia/src/utils/SkOSPath.cpp',
     'skia/src/utils/SkPatchUtils.cpp',
     'skia/src/utils/SkRGBAToYUV.cpp',
-    'skia/src/utils/SkTextureCompressor.cpp',
-    'skia/src/utils/SkTextureCompressor_ASTC.cpp',
-    'skia/src/utils/SkTextureCompressor_LATC.cpp',
-    'skia/src/utils/SkTextureCompressor_R11EAC.cpp',
+    'skia/src/utils/SkThreadUtils_win.cpp',
+    'skia/src/utils/win/SkAutoCoInitialize.cpp',
+    'skia/src/utils/win/SkDWrite.cpp',
+    'skia/src/utils/win/SkDWriteFontFileStream.cpp',
+    'skia/src/utils/win/SkDWriteGeometrySink.cpp',
+    'skia/src/utils/win/SkHRESULT.cpp',
+    'skia/src/utils/win/SkIStream.cpp',
 ]
 SOURCES += [
     'skia/src/core/SkBitmapProcState.cpp',
     'skia/src/core/SkBitmapProcState_matrixProcs.cpp',
     'skia/src/core/SkBlitMask_D32.cpp',
     'skia/src/core/SkBlitRow_D16.cpp',
     'skia/src/core/SkBlitRow_D32.cpp',
     'skia/src/core/SkBlitter.cpp',
     'skia/src/core/SkBlitter_A8.cpp',
     'skia/src/core/SkBlitter_ARGB32.cpp',
     'skia/src/core/SkBlitter_PM4f.cpp',
     'skia/src/core/SkBlitter_RGB16.cpp',
     'skia/src/core/SkBlitter_Sprite.cpp',
     'skia/src/core/SkColorSpace.cpp',
+    'skia/src/core/SkColorSpace_A2B.cpp',
     'skia/src/core/SkColorSpace_ICC.cpp',
+    'skia/src/core/SkColorSpace_XYZ.cpp',
     'skia/src/core/SkColorSpaceXform.cpp',
+    'skia/src/core/SkColorSpaceXform_A2B.cpp',
+    'skia/src/core/SkColorSpaceXformCanvas.cpp',
+    'skia/src/core/SkColorSpaceXformer.cpp',
     'skia/src/core/SkMatrix.cpp',
     'skia/src/core/SkMatrix44.cpp',
     'skia/src/core/SkMiniRecorder.cpp',
     'skia/src/core/SkOpts.cpp',
     'skia/src/core/SkPictureData.cpp',
     'skia/src/core/SkRecorder.cpp',
+    'skia/src/core/SkRTree.cpp',
     'skia/src/core/SkScan_Antihair.cpp',
+    'skia/src/core/SkScan_AntiPath.cpp',
     'skia/src/core/SkSpriteBlitter4f.cpp',
     'skia/src/core/SkSpriteBlitter_ARGB32.cpp',
     'skia/src/core/SkSpriteBlitter_RGB16.cpp',
+    'skia/src/core/SkVertices.cpp',
     'skia/src/core/SkXfermode.cpp',
     'skia/src/core/SkXfermode4f.cpp',
     'skia/src/core/SkXfermodeF16.cpp',
     'skia/src/core/SkXfermodeInterpretation.cpp',
     'skia/src/gpu/gl/GrGLCreateNativeInterface_none.cpp',
+    'skia/src/jumper/SkJumper.cpp',
+    'skia/src/jumper/SkJumper_stages.cpp',
     'skia/src/pathops/SkPathOpsDebug.cpp',
     'skia/src/utils/SkParse.cpp',
     'skia/src/utils/SkParsePath.cpp',
 ]
 SOURCES['skia/src/core/SkBitmapProcState.cpp'].flags += skia_opt_flags
 SOURCES['skia/src/core/SkBitmapProcState_matrixProcs.cpp'].flags += skia_opt_flags
 SOURCES['skia/src/core/SkBlitMask_D32.cpp'].flags += skia_opt_flags
 SOURCES['skia/src/core/SkBlitRow_D16.cpp'].flags += skia_opt_flags
@@ -328,162 +349,173 @@ if CONFIG['MOZ_ENABLE_SKIA_PDF']:
         'skia/src/pdf/SkPDFTypes.cpp',
         'skia/src/pdf/SkPDFUtils.cpp',
     ]
     SOURCES += [
         'skia/src/pdf/SkPDFFont.cpp',
     ]
 if CONFIG['MOZ_ENABLE_SKIA_GPU']:
     UNIFIED_SOURCES += [
-        'skia/src/effects/gradients/SkTwoPointConicalGradient_gpu.cpp',
-        'skia/src/gpu/batches/GrAnalyticRectBatch.cpp',
-        'skia/src/gpu/batches/GrAtlasTextBatch.cpp',
-        'skia/src/gpu/batches/GrBatch.cpp',
-        'skia/src/gpu/batches/GrCopySurfaceBatch.cpp',
-        'skia/src/gpu/batches/GrDashLinePathRenderer.cpp',
-        'skia/src/gpu/batches/GrDefaultPathRenderer.cpp',
-        'skia/src/gpu/batches/GrDrawAtlasBatch.cpp',
-        'skia/src/gpu/batches/GrDrawBatch.cpp',
-        'skia/src/gpu/batches/GrDrawPathBatch.cpp',
-        'skia/src/gpu/batches/GrDrawVerticesBatch.cpp',
-        'skia/src/gpu/batches/GrNinePatch.cpp',
-        'skia/src/gpu/batches/GrNonAAStrokeRectBatch.cpp',
-        'skia/src/gpu/batches/GrPLSPathRenderer.cpp',
-        'skia/src/gpu/batches/GrRectBatchFactory.cpp',
-        'skia/src/gpu/batches/GrRegionBatch.cpp',
-        'skia/src/gpu/batches/GrStencilAndCoverPathRenderer.cpp',
-        'skia/src/gpu/batches/GrTessellatingPathRenderer.cpp',
-        'skia/src/gpu/batches/GrVertexBatch.cpp',
         'skia/src/gpu/effects/GrBezierEffect.cpp',
         'skia/src/gpu/effects/GrBicubicEffect.cpp',
         'skia/src/gpu/effects/GrBitmapTextGeoProc.cpp',
+        'skia/src/gpu/effects/GrBlurredEdgeFragmentProcessor.cpp',
         'skia/src/gpu/effects/GrConfigConversionEffect.cpp',
         'skia/src/gpu/effects/GrConstColorProcessor.cpp',
         'skia/src/gpu/effects/GrConvexPolyEffect.cpp',
-        'skia/src/gpu/effects/GrConvolutionEffect.cpp',
         'skia/src/gpu/effects/GrCoverageSetOpXP.cpp',
         'skia/src/gpu/effects/GrCustomXfermode.cpp',
-        'skia/src/gpu/effects/GrDashingEffect.cpp',
         'skia/src/gpu/effects/GrDisableColorXP.cpp',
         'skia/src/gpu/effects/GrDistanceFieldGeoProc.cpp',
         'skia/src/gpu/effects/GrDitherEffect.cpp',
-        'skia/src/gpu/effects/GrGammaEffect.cpp',
+        'skia/src/gpu/effects/GrGaussianConvolutionFragmentProcessor.cpp',
         'skia/src/gpu/effects/GrMatrixConvolutionEffect.cpp',
+        'skia/src/gpu/effects/GrNonlinearColorSpaceXformEffect.cpp',
         'skia/src/gpu/effects/GrOvalEffect.cpp',
         'skia/src/gpu/effects/GrPorterDuffXferProcessor.cpp',
         'skia/src/gpu/effects/GrRRectEffect.cpp',
+        'skia/src/gpu/effects/GrShadowGeoProc.cpp',
         'skia/src/gpu/effects/GrSimpleTextureEffect.cpp',
         'skia/src/gpu/effects/GrSingleTextureEffect.cpp',
+        'skia/src/gpu/effects/GrSRGBEffect.cpp',
         'skia/src/gpu/effects/GrTextureDomain.cpp',
         'skia/src/gpu/effects/GrTextureStripAtlas.cpp',
         'skia/src/gpu/effects/GrXfermodeFragmentProcessor.cpp',
         'skia/src/gpu/effects/GrYUVEffect.cpp',
         'skia/src/gpu/GrAuditTrail.cpp',
-        'skia/src/gpu/GrBatchFlushState.cpp',
-        'skia/src/gpu/GrBatchTest.cpp',
+        'skia/src/gpu/GrBitmapTextureMaker.cpp',
         'skia/src/gpu/GrBlend.cpp',
         'skia/src/gpu/GrBlurUtils.cpp',
         'skia/src/gpu/GrBuffer.cpp',
         'skia/src/gpu/GrBufferAllocPool.cpp',
         'skia/src/gpu/GrCaps.cpp',
         'skia/src/gpu/GrClipStackClip.cpp',
         'skia/src/gpu/GrColorSpaceXform.cpp',
         'skia/src/gpu/GrContext.cpp',
         'skia/src/gpu/GrCoordTransform.cpp',
         'skia/src/gpu/GrDefaultGeoProcFactory.cpp',
+        'skia/src/gpu/GrDistanceFieldGenFromVector.cpp',
         'skia/src/gpu/GrDrawingManager.cpp',
-        'skia/src/gpu/GrDrawTarget.cpp',
+        'skia/src/gpu/GrDrawOpAtlas.cpp',
+        'skia/src/gpu/GrDrawOpTest.cpp',
         'skia/src/gpu/GrFixedClip.cpp',
         'skia/src/gpu/GrFragmentProcessor.cpp',
         'skia/src/gpu/GrGpu.cpp',
         'skia/src/gpu/GrGpuCommandBuffer.cpp',
         'skia/src/gpu/GrGpuFactory.cpp',
         'skia/src/gpu/GrGpuResource.cpp',
         'skia/src/gpu/GrGpuResourceRef.cpp',
-        'skia/src/gpu/GrImageIDTextureAdjuster.cpp',
-        'skia/src/gpu/GrInvariantOutput.cpp',
+        'skia/src/gpu/GrImageTextureMaker.cpp',
         'skia/src/gpu/GrMemoryPool.cpp',
-        'skia/src/gpu/GrOvalRenderer.cpp',
+        'skia/src/gpu/GrOpFlushState.cpp',
+        'skia/src/gpu/GrOpList.cpp',
         'skia/src/gpu/GrPaint.cpp',
         'skia/src/gpu/GrPath.cpp',
         'skia/src/gpu/GrPathProcessor.cpp',
         'skia/src/gpu/GrPathRange.cpp',
         'skia/src/gpu/GrPathRenderer.cpp',
         'skia/src/gpu/GrPathRendererChain.cpp',
         'skia/src/gpu/GrPathRendering.cpp',
-        'skia/src/gpu/GrPathRenderingDrawContext.cpp',
-        'skia/src/gpu/GrPathUtils.cpp',
+        'skia/src/gpu/GrPathRenderingRenderTargetContext.cpp',
         'skia/src/gpu/GrPipeline.cpp',
-        'skia/src/gpu/GrPipelineBuilder.cpp',
+        'skia/src/gpu/GrPreFlushResourceProvider.cpp',
         'skia/src/gpu/GrPrimitiveProcessor.cpp',
         'skia/src/gpu/GrProcessor.cpp',
+        'skia/src/gpu/GrProcessorAnalysis.cpp',
+        'skia/src/gpu/GrProcessorSet.cpp',
         'skia/src/gpu/GrProcessorUnitTest.cpp',
-        'skia/src/gpu/GrProcOptInfo.cpp',
         'skia/src/gpu/GrProgramDesc.cpp',
-        'skia/src/gpu/GrProgramElement.cpp',
         'skia/src/gpu/GrRectanizer_pow2.cpp',
         'skia/src/gpu/GrRectanizer_skyline.cpp',
         'skia/src/gpu/GrReducedClip.cpp',
         'skia/src/gpu/GrRenderTarget.cpp',
+        'skia/src/gpu/GrRenderTargetContext.cpp',
+        'skia/src/gpu/GrRenderTargetOpList.cpp',
         'skia/src/gpu/GrRenderTargetProxy.cpp',
-        'skia/src/gpu/GrResourceProvider.cpp',
+        'skia/src/gpu/GrShaderCaps.cpp',
+        'skia/src/gpu/GrShaderVar.cpp',
         'skia/src/gpu/GrShape.cpp',
         'skia/src/gpu/GrSoftwarePathRenderer.cpp',
         'skia/src/gpu/GrStencilAttachment.cpp',
         'skia/src/gpu/GrStencilSettings.cpp',
         'skia/src/gpu/GrStyle.cpp',
         'skia/src/gpu/GrSurface.cpp',
+        'skia/src/gpu/GrSurfaceContext.cpp',
         'skia/src/gpu/GrSurfaceProxy.cpp',
         'skia/src/gpu/GrSWMaskHelper.cpp',
         'skia/src/gpu/GrTessellator.cpp',
         'skia/src/gpu/GrTestUtils.cpp',
         'skia/src/gpu/GrTexture.cpp',
-        'skia/src/gpu/GrTextureAccess.cpp',
-        'skia/src/gpu/GrTextureParamsAdjuster.cpp',
-        'skia/src/gpu/GrTextureProvider.cpp',
+        'skia/src/gpu/GrTextureAdjuster.cpp',
+        'skia/src/gpu/GrTextureContext.cpp',
+        'skia/src/gpu/GrTextureMaker.cpp',
+        'skia/src/gpu/GrTextureOpList.cpp',
+        'skia/src/gpu/GrTextureProducer.cpp',
         'skia/src/gpu/GrTextureProxy.cpp',
+        'skia/src/gpu/GrTextureRenderTargetProxy.cpp',
         'skia/src/gpu/GrTextureToYUVPlanes.cpp',
         'skia/src/gpu/GrTraceMarker.cpp',
         'skia/src/gpu/GrXferProcessor.cpp',
         'skia/src/gpu/GrYUVProvider.cpp',
         'skia/src/gpu/instanced/GLInstancedRendering.cpp',
         'skia/src/gpu/instanced/InstancedRendering.cpp',
         'skia/src/gpu/instanced/InstanceProcessor.cpp',
+        'skia/src/gpu/ops/GrAnalyticRectOp.cpp',
+        'skia/src/gpu/ops/GrAtlasTextOp.cpp',
+        'skia/src/gpu/ops/GrCopySurfaceOp.cpp',
+        'skia/src/gpu/ops/GrDashLinePathRenderer.cpp',
+        'skia/src/gpu/ops/GrDashOp.cpp',
+        'skia/src/gpu/ops/GrDefaultPathRenderer.cpp',
+        'skia/src/gpu/ops/GrDrawAtlasOp.cpp',
+        'skia/src/gpu/ops/GrDrawPathOp.cpp',
+        'skia/src/gpu/ops/GrDrawVerticesOp.cpp',
+        'skia/src/gpu/ops/GrLatticeOp.cpp',
+        'skia/src/gpu/ops/GrMeshDrawOp.cpp',
+        'skia/src/gpu/ops/GrNonAAStrokeRectOp.cpp',
+        'skia/src/gpu/ops/GrOp.cpp',
+        'skia/src/gpu/ops/GrOvalOpFactory.cpp',
+        'skia/src/gpu/ops/GrRectOpFactory.cpp',
+        'skia/src/gpu/ops/GrRegionOp.cpp',
+        'skia/src/gpu/ops/GrSemaphoreOp.cpp',
+        'skia/src/gpu/ops/GrSmallPathRenderer.cpp',
+        'skia/src/gpu/ops/GrStencilAndCoverPathRenderer.cpp',
+        'skia/src/gpu/ops/GrTessellatingPathRenderer.cpp',
         'skia/src/gpu/SkGpuDevice.cpp',
         'skia/src/gpu/SkGpuDevice_drawTexture.cpp',
         'skia/src/gpu/SkGr.cpp',
+        'skia/src/gpu/text/GrAtlasGlyphCache.cpp',
         'skia/src/gpu/text/GrAtlasTextBlob.cpp',
-        'skia/src/gpu/text/GrAtlasTextBlob_regenInBatch.cpp',
+        'skia/src/gpu/text/GrAtlasTextBlob_regenInOp.cpp',
         'skia/src/gpu/text/GrAtlasTextContext.cpp',
-        'skia/src/gpu/text/GrBatchFontCache.cpp',
         'skia/src/gpu/text/GrDistanceFieldAdjustTable.cpp',
         'skia/src/gpu/text/GrStencilAndCoverTextContext.cpp',
         'skia/src/gpu/text/GrTextBlobCache.cpp',
         'skia/src/gpu/text/GrTextUtils.cpp',
         'skia/src/image/SkSurface_Gpu.cpp',
+        'skia/src/sksl/ir/SkSLSymbolTable.cpp',
+        'skia/src/sksl/ir/SkSLType.cpp',
+        'skia/src/sksl/SkSLCFGGenerator.cpp',
+        'skia/src/sksl/SkSLCompiler.cpp',
+        'skia/src/sksl/SkSLGLSLCodeGenerator.cpp',
+        'skia/src/sksl/SkSLIRGenerator.cpp',
+        'skia/src/sksl/SkSLParser.cpp',
+        'skia/src/sksl/SkSLSPIRVCodeGenerator.cpp',
+        'skia/src/sksl/SkSLString.cpp',
+        'skia/src/sksl/SkSLUtil.cpp',
     ]
     SOURCES += [
-        'skia/src/gpu/batches/GrAAConvexPathRenderer.cpp',
-        'skia/src/gpu/batches/GrAAConvexTessellator.cpp',
-        'skia/src/gpu/batches/GrAADistanceFieldPathRenderer.cpp',
-        'skia/src/gpu/batches/GrAAFillRectBatch.cpp',
-        'skia/src/gpu/batches/GrAAHairLinePathRenderer.cpp',
-        'skia/src/gpu/batches/GrAALinearizingConvexPathRenderer.cpp',
-        'skia/src/gpu/batches/GrAAStrokeRectBatch.cpp',
-        'skia/src/gpu/batches/GrMSAAPathRenderer.cpp',
-        'skia/src/gpu/batches/GrNonAAFillRectBatch.cpp',
-        'skia/src/gpu/batches/GrNonAAFillRectPerspectiveBatch.cpp',
         'skia/src/gpu/gl/builders/GrGLProgramBuilder.cpp',
         'skia/src/gpu/gl/builders/GrGLShaderStringBuilder.cpp',
         'skia/src/gpu/gl/builders/GrGLSLPrettyPrint.cpp',
         'skia/src/gpu/gl/GrGLBuffer.cpp',
         'skia/src/gpu/gl/GrGLCaps.cpp',
         'skia/src/gpu/gl/GrGLContext.cpp',
         'skia/src/gpu/gl/GrGLDefaultInterface_native.cpp',
         'skia/src/gpu/gl/GrGLExtensions.cpp',
+        'skia/src/gpu/gl/GrGLExternalTextureData.cpp',
         'skia/src/gpu/gl/GrGLGLSL.cpp',
         'skia/src/gpu/gl/GrGLGpu.cpp',
         'skia/src/gpu/gl/GrGLGpuProgramCache.cpp',
         'skia/src/gpu/gl/GrGLInterface.cpp',
         'skia/src/gpu/gl/GrGLPath.cpp',
         'skia/src/gpu/gl/GrGLPathRange.cpp',
         'skia/src/gpu/gl/GrGLPathRendering.cpp',
         'skia/src/gpu/gl/GrGLProgram.cpp',
@@ -493,154 +525,134 @@ if CONFIG['MOZ_ENABLE_SKIA_GPU']:
         'skia/src/gpu/gl/GrGLTexture.cpp',
         'skia/src/gpu/gl/GrGLTextureRenderTarget.cpp',
         'skia/src/gpu/gl/GrGLUniformHandler.cpp',
         'skia/src/gpu/gl/GrGLUtil.cpp',
         'skia/src/gpu/gl/GrGLVaryingHandler.cpp',
         'skia/src/gpu/gl/GrGLVertexArray.cpp',
         'skia/src/gpu/glsl/GrGLSL.cpp',
         'skia/src/gpu/glsl/GrGLSLBlend.cpp',
-        'skia/src/gpu/glsl/GrGLSLCaps.cpp',
         'skia/src/gpu/glsl/GrGLSLFragmentProcessor.cpp',
         'skia/src/gpu/glsl/GrGLSLFragmentShaderBuilder.cpp',
         'skia/src/gpu/glsl/GrGLSLGeometryProcessor.cpp',
         'skia/src/gpu/glsl/GrGLSLGeometryShaderBuilder.cpp',
         'skia/src/gpu/glsl/GrGLSLPrimitiveProcessor.cpp',
         'skia/src/gpu/glsl/GrGLSLProgramBuilder.cpp',
         'skia/src/gpu/glsl/GrGLSLProgramDataManager.cpp',
         'skia/src/gpu/glsl/GrGLSLShaderBuilder.cpp',
         'skia/src/gpu/glsl/GrGLSLUtil.cpp',
         'skia/src/gpu/glsl/GrGLSLVarying.cpp',
         'skia/src/gpu/glsl/GrGLSLVertexShaderBuilder.cpp',
         'skia/src/gpu/glsl/GrGLSLXferProcessor.cpp',
-        'skia/src/gpu/GrBatchAtlas.cpp',
-        'skia/src/gpu/GrDrawContext.cpp',
+        'skia/src/gpu/GrPathUtils.cpp',
         'skia/src/gpu/GrResourceCache.cpp',
+        'skia/src/gpu/GrResourceProvider.cpp',
+        'skia/src/gpu/ops/GrAAConvexPathRenderer.cpp',
+        'skia/src/gpu/ops/GrAAConvexTessellator.cpp',
+        'skia/src/gpu/ops/GrAAFillRectOp.cpp',
+        'skia/src/gpu/ops/GrAAHairLinePathRenderer.cpp',
+        'skia/src/gpu/ops/GrAALinearizingConvexPathRenderer.cpp',
+        'skia/src/gpu/ops/GrAAStrokeRectOp.cpp',
+        'skia/src/gpu/ops/GrMSAAPathRenderer.cpp',
+        'skia/src/gpu/ops/GrNonAAFillRectOp.cpp',
+        'skia/src/gpu/ops/GrNonAAFillRectPerspectiveOp.cpp',
+        'skia/src/gpu/ops/GrShadowRRectOp.cpp',
         'skia/src/image/SkImage_Gpu.cpp',
+        'skia/src/sksl/lex.layout.cpp',
     ]
-if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('android'):
+if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'android':
     UNIFIED_SOURCES += [
         'skia/src/ports/SkDebug_android.cpp',
         'skia/src/ports/SkOSFile_posix.cpp',
         'skia/src/ports/SkOSLibrary_posix.cpp',
         'skia/src/ports/SkTLS_pthread.cpp',
         'skia/src/utils/SkThreadUtils_pthread.cpp',
     ]
     SOURCES += [
+        'skia/src/jumper/SkJumper_generated.S',
         'skia/src/ports/SkFontHost_cairo.cpp',
         'skia/src/ports/SkFontHost_FreeType_common.cpp',
     ]
-if CONFIG['MOZ_WIDGET_TOOLKIT'] in {'cocoa', 'uikit'}:
-    UNIFIED_SOURCES += [
-        'skia/src/ports/SkDebug_stdio.cpp',
-        'skia/src/ports/SkOSFile_posix.cpp',
-        'skia/src/ports/SkOSLibrary_posix.cpp',
-        'skia/src/ports/SkTLS_pthread.cpp',
-        'skia/src/utils/mac/SkCreateCGImageRef.cpp',
-        'skia/src/utils/mac/SkStream_mac.cpp',
-        'skia/src/utils/SkThreadUtils_pthread.cpp',
-    ]
-    SOURCES += [
-        'skia/src/ports/SkFontHost_mac.cpp',
-    ]
-if 'gtk' in CONFIG['MOZ_WIDGET_TOOLKIT']:
+if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('cocoa', 'uikit'):
     UNIFIED_SOURCES += [
         'skia/src/ports/SkDebug_stdio.cpp',
         'skia/src/ports/SkOSFile_posix.cpp',
         'skia/src/ports/SkOSLibrary_posix.cpp',
         'skia/src/ports/SkTLS_pthread.cpp',
         'skia/src/utils/SkThreadUtils_pthread.cpp',
     ]
     SOURCES += [
+        'skia/src/jumper/SkJumper_generated.S',
+        'skia/src/ports/SkFontHost_mac.cpp',
+    ]
+if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3'):
+    UNIFIED_SOURCES += [
+        'skia/src/ports/SkDebug_stdio.cpp',
+        'skia/src/ports/SkOSFile_posix.cpp',
+        'skia/src/ports/SkOSLibrary_posix.cpp',
+        'skia/src/ports/SkTLS_pthread.cpp',
+        'skia/src/utils/SkThreadUtils_pthread.cpp',
+    ]
+    SOURCES += [
+        'skia/src/jumper/SkJumper_generated.S',
         'skia/src/ports/SkFontHost_cairo.cpp',
         'skia/src/ports/SkFontHost_FreeType_common.cpp',
     ]
 if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
     SOURCES += [
+        'skia/src/jumper/SkJumper_generated_win.S',
         'skia/src/ports/SkDebug_win.cpp',
         'skia/src/ports/SkFontHost_win.cpp',
         'skia/src/ports/SkFontMgr_win_dw.cpp',
         'skia/src/ports/SkFontMgr_win_dw_factory.cpp',
         'skia/src/ports/SkOSFile_win.cpp',
         'skia/src/ports/SkOSLibrary_win.cpp',
-        'skia/src/ports/SkRemotableFontMgr_win_dw.cpp',
         'skia/src/ports/SkScalerContext_win_dw.cpp',
         'skia/src/ports/SkTLS_win.cpp',
         'skia/src/ports/SkTypeface_win_dw.cpp',
-        'skia/src/utils/SkThreadUtils_win.cpp',
-        'skia/src/utils/win/SkAutoCoInitialize.cpp',
-        'skia/src/utils/win/SkDWrite.cpp',
-        'skia/src/utils/win/SkDWriteFontFileStream.cpp',
-        'skia/src/utils/win/SkDWriteGeometrySink.cpp',
-        'skia/src/utils/win/SkHRESULT.cpp',
-        'skia/src/utils/win/SkIStream.cpp',
     ]
 if CONFIG['INTEL_ARCHITECTURE']:
     UNIFIED_SOURCES += [
         'skia/src/opts/opts_check_x86.cpp',
     ]
     SOURCES += [
-        'skia/src/opts/SkBitmapFilter_opts_SSE2.cpp',
         'skia/src/opts/SkBitmapProcState_opts_SSE2.cpp',
         'skia/src/opts/SkBitmapProcState_opts_SSSE3.cpp',
         'skia/src/opts/SkBlitRow_opts_SSE2.cpp',
         'skia/src/opts/SkOpts_avx.cpp',
         'skia/src/opts/SkOpts_hsw.cpp',
         'skia/src/opts/SkOpts_sse41.cpp',
         'skia/src/opts/SkOpts_sse42.cpp',
         'skia/src/opts/SkOpts_ssse3.cpp',
     ]
-    SOURCES['skia/src/opts/SkBitmapFilter_opts_SSE2.cpp'].flags += skia_opt_flags
     SOURCES['skia/src/opts/SkBitmapProcState_opts_SSE2.cpp'].flags += skia_opt_flags
     SOURCES['skia/src/opts/SkBitmapProcState_opts_SSSE3.cpp'].flags += skia_opt_flags
     SOURCES['skia/src/opts/SkBlitRow_opts_SSE2.cpp'].flags += skia_opt_flags
     SOURCES['skia/src/opts/SkOpts_avx.cpp'].flags += skia_opt_flags
     SOURCES['skia/src/opts/SkOpts_hsw.cpp'].flags += skia_opt_flags
     SOURCES['skia/src/opts/SkOpts_sse41.cpp'].flags += skia_opt_flags
     SOURCES['skia/src/opts/SkOpts_sse42.cpp'].flags += skia_opt_flags
     SOURCES['skia/src/opts/SkOpts_ssse3.cpp'].flags += skia_opt_flags
 elif CONFIG['CPU_ARCH'] in ('arm', 'aarch64') and CONFIG['GNU_CC']:
-    UNIFIED_SOURCES += [
-        'skia/src/core/SkUtilsArm.cpp',
+    SOURCES += [
+        'skia/src/opts/SkBitmapProcState_arm_neon.cpp',
+        'skia/src/opts/SkBitmapProcState_matrixProcs_neon.cpp',
+        'skia/src/opts/SkBitmapProcState_opts_none.cpp',
+        'skia/src/opts/SkBlitMask_opts_arm.cpp',
+        'skia/src/opts/SkBlitMask_opts_arm_neon.cpp',
+        'skia/src/opts/SkBlitRow_opts_arm.cpp',
+        'skia/src/opts/SkBlitRow_opts_arm_neon.cpp',
     ]
-    SOURCES += [
-        'skia/src/opts/SkBitmapProcState_opts_arm.cpp',
-        'skia/src/opts/SkBlitMask_opts_arm.cpp',
-        'skia/src/opts/SkBlitRow_opts_arm.cpp',
-    ]
-    SOURCES['skia/src/opts/SkBitmapProcState_opts_arm.cpp'].flags += skia_opt_flags
+    SOURCES['skia/src/opts/SkBitmapProcState_arm_neon.cpp'].flags += skia_opt_flags
+    SOURCES['skia/src/opts/SkBitmapProcState_matrixProcs_neon.cpp'].flags += skia_opt_flags
+    SOURCES['skia/src/opts/SkBitmapProcState_opts_none.cpp'].flags += skia_opt_flags
     SOURCES['skia/src/opts/SkBlitMask_opts_arm.cpp'].flags += skia_opt_flags
+    SOURCES['skia/src/opts/SkBlitMask_opts_arm_neon.cpp'].flags += skia_opt_flags
     SOURCES['skia/src/opts/SkBlitRow_opts_arm.cpp'].flags += skia_opt_flags
-    if CONFIG['CPU_ARCH'] == 'aarch64':
-        SOURCES += [
-            'skia/src/opts/SkBitmapProcState_arm_neon.cpp',
-            'skia/src/opts/SkBitmapProcState_matrixProcs_neon.cpp',
-            'skia/src/opts/SkBlitMask_opts_arm_neon.cpp',
-            'skia/src/opts/SkBlitRow_opts_arm_neon.cpp',
-            'skia/src/opts/SkOpts_neon.cpp',
-        ]
-    elif CONFIG['BUILD_ARM_NEON']:
-        SOURCES += [
-            'skia/src/opts/SkBitmapProcState_arm_neon.cpp',
-            'skia/src/opts/SkBitmapProcState_matrixProcs_neon.cpp',
-            'skia/src/opts/SkBlitMask_opts_arm_neon.cpp',
-            'skia/src/opts/SkBlitRow_opts_arm_neon.cpp',
-            'skia/src/opts/SkOpts_neon.cpp',
-        ]
-        SOURCES['skia/src/opts/SkBitmapProcState_arm_neon.cpp'].flags += CONFIG['NEON_FLAGS']
-        SOURCES['skia/src/opts/SkBitmapProcState_matrixProcs_neon.cpp'].flags += CONFIG['NEON_FLAGS']
-        SOURCES['skia/src/opts/SkBlitMask_opts_arm_neon.cpp'].flags += CONFIG['NEON_FLAGS']
-        SOURCES['skia/src/opts/SkBlitRow_opts_arm_neon.cpp'].flags += CONFIG['NEON_FLAGS']
-        SOURCES['skia/src/opts/SkOpts_neon.cpp'].flags += CONFIG['NEON_FLAGS']
-    if CONFIG['CPU_ARCH'] == 'aarch64' or CONFIG['BUILD_ARM_NEON']:
-        SOURCES['skia/src/opts/SkBitmapProcState_arm_neon.cpp'].flags += skia_opt_flags
-        SOURCES['skia/src/opts/SkBitmapProcState_matrixProcs_neon.cpp'].flags += skia_opt_flags
-        SOURCES['skia/src/opts/SkBlitMask_opts_arm_neon.cpp'].flags += skia_opt_flags
-        SOURCES['skia/src/opts/SkBlitRow_opts_arm_neon.cpp'].flags += skia_opt_flags
-        SOURCES['skia/src/opts/SkOpts_neon.cpp'].flags += skia_opt_flags
+    SOURCES['skia/src/opts/SkBlitRow_opts_arm_neon.cpp'].flags += skia_opt_flags
 else:
     SOURCES += [
         'skia/src/opts/SkBitmapProcState_opts_none.cpp',
         'skia/src/opts/SkBlitMask_opts_none.cpp',
         'skia/src/opts/SkBlitRow_opts_none.cpp',
     ]
 
 
@@ -649,80 +661,69 @@ ALLOW_COMPILER_WARNINGS = True
 
 FINAL_LIBRARY = 'gkmedias'
 LOCAL_INCLUDES += [
     'skia/include/c',
     'skia/include/config',
     'skia/include/core',
     'skia/include/effects',
     'skia/include/gpu',
-    'skia/include/images',
     'skia/include/pathops',
     'skia/include/ports',
     'skia/include/private',
     'skia/include/utils',
     'skia/include/utils/mac',
     'skia/include/views',
     'skia/src/core',
     'skia/src/gpu',
     'skia/src/gpu/effects',
     'skia/src/gpu/gl',
+    'skia/src/gpu/glsl',
     'skia/src/image',
     'skia/src/lazy',
     'skia/src/opts',
     'skia/src/sfnt',
+    'skia/src/sksl',
     'skia/src/utils',
     'skia/src/utils/mac',
     'skia/src/utils/win',
 ]
 
-if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('android'):
-    DEFINES['SK_FONTHOST_CAIRO_STANDALONE'] = 0
-
-if CONFIG['MOZ_WIDGET_TOOLKIT'] in {
-    'android',
-    'cocoa',
-    'gtk2',
-    'gtk3',
-    'uikit',
-  }:
-    DEFINES['SK_FONTHOST_DOES_NOT_USE_FONTMGR'] = 1
-
 if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
     DEFINES['UNICODE'] = True
     DEFINES['_UNICODE'] = True
     UNIFIED_SOURCES += [
         'skia/src/fonts/SkFontMgr_indirect.cpp',
         'skia/src/fonts/SkRemotableFontMgr.cpp',
     ]
 
 # We should autogenerate these SSE related flags.
 
-if CONFIG['_MSC_VER']:
+if CONFIG['INTEL_ARCHITECTURE'] and (CONFIG['GNU_CC'] or CONFIG['CLANG_CL']):
+    SOURCES['skia/src/opts/SkBitmapProcState_opts_SSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
+    SOURCES['skia/src/opts/SkBitmapProcState_opts_SSSE3.cpp'].flags += ['-mssse3']
+    SOURCES['skia/src/opts/SkBlitRow_opts_SSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
+    SOURCES['skia/src/opts/SkOpts_ssse3.cpp'].flags += ['-mssse3']
+    SOURCES['skia/src/opts/SkOpts_sse41.cpp'].flags += ['-msse4.1']
+    SOURCES['skia/src/opts/SkOpts_sse42.cpp'].flags += ['-msse4.2']
+    SOURCES['skia/src/opts/SkOpts_avx.cpp'].flags += ['-mavx']
+    SOURCES['skia/src/opts/SkOpts_hsw.cpp'].flags += ['-mavx2']
+elif CONFIG['_MSC_VER']:
     # MSVC doesn't need special compiler flags, but Skia needs to be told that these files should
     # be built with the required SSE level or it will simply compile in stubs and cause runtime crashes
-    SOURCES['skia/src/opts/SkBitmapFilter_opts_SSE2.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=20']
     SOURCES['skia/src/opts/SkBitmapProcState_opts_SSE2.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=20']
     SOURCES['skia/src/opts/SkBitmapProcState_opts_SSSE3.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=31']
     SOURCES['skia/src/opts/SkBlitRow_opts_SSE2.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=20']
     SOURCES['skia/src/opts/SkOpts_ssse3.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=31']
     SOURCES['skia/src/opts/SkOpts_sse41.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=41']
     SOURCES['skia/src/opts/SkOpts_sse42.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=42']
     SOURCES['skia/src/opts/SkOpts_avx.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=51']
-if CONFIG['INTEL_ARCHITECTURE'] and (CONFIG['GNU_CC'] or CONFIG['CLANG_CL']):
-    SOURCES['skia/src/opts/SkBitmapFilter_opts_SSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
-    SOURCES['skia/src/opts/SkBitmapProcState_opts_SSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
-    SOURCES['skia/src/opts/SkBitmapProcState_opts_SSSE3.cpp'].flags += ['-mssse3']
-    SOURCES['skia/src/opts/SkBlitRow_opts_SSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
-    SOURCES['skia/src/opts/SkOpts_ssse3.cpp'].flags += ['-mssse3']
-    SOURCES['skia/src/opts/SkOpts_sse41.cpp'].flags += ['-msse4.1']
-    SOURCES['skia/src/opts/SkOpts_sse42.cpp'].flags += ['-msse4.2']
-    SOURCES['skia/src/opts/SkOpts_avx.cpp'].flags += ['-mavx']
-elif CONFIG['CPU_ARCH'] == 'arm' and CONFIG['GNU_CC'] and CONFIG['BUILD_ARM_NEON']:
-    DEFINES['SK_ARM_HAS_OPTIONAL_NEON'] = 1
+    SOURCES['skia/src/opts/SkOpts_hsw.cpp'].flags += ['-DSK_CPU_SSE_LEVEL=52']
+elif CONFIG['CPU_ARCH'] == 'arm' and CONFIG['GNU_CC']:
+    CXXFLAGS += CONFIG['NEON_FLAGS']
 
 DEFINES['SKIA_IMPLEMENTATION'] = 1
 
 if CONFIG['MOZ_ENABLE_SKIA_PDF_SFNTLY'] and CONFIG['ENABLE_INTL_API']:
     DEFINES['SK_PDF_USE_SFNTLY'] = 1
 
 if not CONFIG['MOZ_ENABLE_SKIA_GPU']:
     DEFINES['SK_SUPPORT_GPU'] = 0