Florin Malita | b341810 | 2020-10-15 18:10:29 -0400 | [diff] [blame] | 1 | # Copyright 2020 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 | |
| 6 | import("../../gn/skia.gni") |
| 7 | |
| 8 | if (skia_enable_svg) { |
| 9 | config("public_config") { |
| 10 | defines = [ "SK_ENABLE_SVG" ] |
| 11 | include_dirs = [ "include" ] |
| 12 | } |
| 13 | |
| 14 | component("svg") { |
| 15 | check_includes = false |
| 16 | import("svg.gni") |
| 17 | public_configs = [ ":public_config" ] |
| 18 | public = skia_svg_public |
| 19 | sources = skia_svg_sources |
| 20 | configs += [ "../../:skia_private" ] |
Florin Malita | 7dc984a | 2020-12-08 11:37:15 -0500 | [diff] [blame] | 21 | deps = [ |
| 22 | "../..:skia", |
| 23 | "../skshaper", |
| 24 | ] |
Florin Malita | b341810 | 2020-10-15 18:10:29 -0400 | [diff] [blame] | 25 | } |
| 26 | |
Florin Malita | dec7802 | 2020-12-17 16:36:54 -0500 | [diff] [blame^] | 27 | if (skia_enable_tools) { |
| 28 | if (defined(is_skia_standalone)) { |
| 29 | source_set("tool") { |
| 30 | check_includes = false |
| 31 | testonly = true |
| 32 | |
| 33 | configs += [ "../..:skia_private" ] |
| 34 | sources = [ "utils/SvgTool.cpp" ] |
| 35 | |
| 36 | deps = [ |
| 37 | "../..:flags", |
| 38 | "../..:skia", |
| 39 | ] |
| 40 | |
| 41 | public_deps = [ ":svg" ] |
| 42 | } |
| 43 | } |
| 44 | |
| 45 | source_set("tests") { |
Florin Malita | b341810 | 2020-10-15 18:10:29 -0400 | [diff] [blame] | 46 | testonly = true |
| 47 | |
Florin Malita | dec7802 | 2020-12-17 16:36:54 -0500 | [diff] [blame^] | 48 | configs += [ |
| 49 | "../..:skia_private", |
| 50 | "../..:tests_config", |
| 51 | ] |
| 52 | sources = [ "tests/Text.cpp" ] |
Florin Malita | b341810 | 2020-10-15 18:10:29 -0400 | [diff] [blame] | 53 | |
| 54 | deps = [ |
Florin Malita | dec7802 | 2020-12-17 16:36:54 -0500 | [diff] [blame^] | 55 | ":svg", |
| 56 | "../..:gpu_tool_utils", |
Derek Sollenberger | e2f6245 | 2020-12-17 19:21:28 +0000 | [diff] [blame] | 57 | "../..:skia", |
Florin Malita | b341810 | 2020-10-15 18:10:29 -0400 | [diff] [blame] | 58 | ] |
Florin Malita | b341810 | 2020-10-15 18:10:29 -0400 | [diff] [blame] | 59 | } |
| 60 | } |
| 61 | } else { |
| 62 | group("svg") { |
| 63 | } |
Florin Malita | dec7802 | 2020-12-17 16:36:54 -0500 | [diff] [blame^] | 64 | group("tests") { |
| 65 | } |
Florin Malita | b341810 | 2020-10-15 18:10:29 -0400 | [diff] [blame] | 66 | } |