• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright 2018 Google Inc.
2#
3# Use of this source code is governed by a BSD-style license that can be
4# found in the LICENSE file.
5
6import("../../gn/skia.gni")
7import("skshaper.gni")
8
9if (skia_enable_skshaper) {
10  config("public_config") {
11    include_dirs = [ "include" ]
12    defines = []
13    if (is_component_build) {
14      defines += [ "SKSHAPER_DLL" ]
15    }
16    if (skia_use_fonthost_mac) {
17      defines += [ "SK_SHAPER_CORETEXT_AVAILABLE" ]
18    }
19    if (skia_use_icu && skia_use_harfbuzz) {
20      defines += [ "SK_SHAPER_HARFBUZZ_AVAILABLE" ]
21    }
22  }
23
24  component("skshaper") {
25    check_includes = false
26    public_configs = [ ":public_config" ]
27    public = skia_shaper_public
28    deps = [ "../..:skia" ]
29    defines = [ "SKSHAPER_IMPLEMENTATION=1" ]
30    sources = skia_shaper_primitive_sources
31    if (skia_use_fonthost_mac) {
32      sources += skia_shaper_coretext_sources
33      if (is_mac) {
34        frameworks = [ "ApplicationServices.framework" ]
35      }
36
37      if (is_ios) {
38        frameworks = [
39          "CoreFoundation.framework",
40          "CoreText.framework",
41        ]
42      }
43    }
44    if (skia_use_icu && skia_use_harfbuzz) {
45      sources += skia_shaper_harfbuzz_sources
46      deps += [
47        "../skunicode",
48        "${skia_third_party_dir}/harfbuzz",
49      ]
50    }
51    configs += [
52      "../../:skia_private",
53      "../../third_party/icu/config:no_cxx",
54    ]
55  }
56} else {
57  group("skshaper") {
58  }
59}
60