Add support for Fuchsia
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2152273002

[mtklein edit from here down]
No public API changes.
TBR=reed@google.com

Review-Url: https://codereview.chromium.org/2152273002
diff --git a/BUILD.gn b/BUILD.gn
index b28edd0..61a8e98 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -70,13 +70,17 @@
   ":skia_library",
 ]
 
-# Chrome's GN environment is mostly helpful, but a couple default configs tend to get in the way.
-unwanted_configs = [
-  "//build/config/clang:find_bad_constructs",  # Chrome style checks.
-  "//build/config:feature_flags",  # A bunch of #defines we don't care about.
-]
+unwanted_configs = []
 
-core_gypi = exec_script("build/gypi_to_gn.py",
+if (!is_fuchsia) {
+  # Chrome's GN environment is mostly helpful, but a couple default configs tend to get in the way.
+  unwanted_configs += [
+    "//build/config/clang:find_bad_constructs",  # Chrome style checks.
+    "//build/config:feature_flags",  # A bunch of #defines we don't care about.
+  ]
+}
+
+core_gypi = exec_script("//build/gypi_to_gn.py",
                         [
                           rebase_path("gyp/core.gypi"),
                           "--replace=<(skia_include_path)=include",
@@ -85,7 +89,7 @@
                         "scope",
                         [ "gyp/core.gypi" ])
 
-effects_gypi = exec_script("build/gypi_to_gn.py",
+effects_gypi = exec_script("//build/gypi_to_gn.py",
                            [
                              rebase_path("gyp/effects.gypi"),
                              "--replace=<(skia_include_path)=include",
@@ -94,7 +98,7 @@
                            "scope",
                            [ "gyp/effects.gypi" ])
 
-gpu_gypi = exec_script("build/gypi_to_gn.py",
+gpu_gypi = exec_script("//build/gypi_to_gn.py",
                        [
                          rebase_path("gyp/gpu.gypi"),
                          "--replace=<(skia_include_path)=include",
@@ -103,7 +107,7 @@
                        "scope",
                        [ "gyp/gpu.gypi" ])
 
-opts_gypi = exec_script("build/gypi_to_gn.py",
+opts_gypi = exec_script("//build/gypi_to_gn.py",
                         [
                           rebase_path("gyp/opts.gypi"),
                           "--replace=<(skia_include_path)=include",
@@ -112,7 +116,7 @@
                         "scope",
                         [ "gyp/opts.gypi" ])
 
-pdf_gypi = exec_script("build/gypi_to_gn.py",
+pdf_gypi = exec_script("//build/gypi_to_gn.py",
                        [
                          rebase_path("gyp/pdf.gypi"),
                          "--replace=<(skia_include_path)=include",
@@ -121,7 +125,7 @@
                        "scope",
                        [ "gyp/pdf.gypi" ])
 
-utils_gypi = exec_script("build/gypi_to_gn.py",
+utils_gypi = exec_script("//build/gypi_to_gn.py",
                          [
                            rebase_path("gyp/utils.gypi"),
                            "--replace=<(skia_include_path)=include",
@@ -163,7 +167,7 @@
     ":opts_avx",
     ":opts_sse41",
     ":opts_ssse3",
-    "third_party:zlib",
+    "//third_party/zlib",
   ]
 
   libs = []
@@ -239,6 +243,12 @@
     ]
     libs += [ "ApplicationServices.framework" ]
   }
+
+  if (is_fuchsia) {
+    sources += [
+      "src/ports/SkFontMgr_empty_factory.cpp",
+    ]
+  }
 }
 
 executable("example") {