Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / public / BUILD.gn
blob73aefaf25e6ae02af0e5d09015ba64db418f7c21
1 # Copyright 2014 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
5 import("//third_party/WebKit/Source/config.gni")
6 import("//tools/grit/grit_rule.gni")
8 blink_headers_values = exec_script("//build/gypi_to_gn.py",
9                                   [ rebase_path("blink_headers.gypi") ],
10                                    "scope",
11                                   [ "blink_headers.gypi" ])
14 if (is_android) {
15   import("//build/config/android/rules.gni")
18 # GYP version: WebKit/public/blink.gyp:blink
19 group("blink") {
20   public_deps = [
21     ":blink_headers",
22     ":blink_minimal",
23     "//third_party/WebKit/Source/web",
24     "//third_party/WebKit/Source/platform",
25   ]
28 # This target provides a minimal set of Blink APIs such as WebString to use in
29 # places that cannot link against the full Blink library.  FIXME: We really
30 # shouldn't have this at all and should instead remove all uses of Blink's API
31 # types from places that can't link against Blink. crbug.com/248653
33 # GYP version: WebKit/public/blink.gyp:blink_minimal
34 group("blink_minimal") {
35   public_deps = [
36     "//third_party/WebKit/Source/platform:blink_common",
37   ]
40 # GYP version: WebKit/public/blink.gyp:blink_test_support
41 group("test_support") {
42   public_deps = [
43     "//third_party/WebKit/Source/web:test_support",
44   ]
47 # GYP version: WebKit/public/all.gyp:all_blink
48 group("all_blink") {
49   # This includes some test targets. Don't link into production!
50   testonly = true
52   public_deps = [
53     "//third_party/WebKit/Source/core",
54     "//third_party/WebKit/Source/modules",
55     "//third_party/WebKit/Source/platform:heap_unittests",
56     "//third_party/WebKit/Source/platform:platform_unittests",
57     "//third_party/WebKit/Source/web",
58     "//third_party/WebKit/Source/web:webkit_unit_tests",
59     "//third_party/WebKit/Source/wtf:wtf_unittests",
60   ]
62   if (is_mac) {
63     # TODO(GYP): Re-enable this as soon as we can link Blink binaries on mac.
64     public_deps -= [
65       "//third_party/WebKit/Source/platform:heap_unittests",
66       "//third_party/WebKit/Source/platform:platform_unittests",
67       "//third_party/WebKit/Source/web:webkit_unit_tests",
68     ]
69   }
72 config("blink_headers_config") {
73   include_dirs = [ ".." ]
76 config("debug_devtools") {
77   if (debug_devtools) {
78     defines = [ "DEBUG_DEVTOOLS=1" ]
79   }
82 if (is_android) {
83   # GYP version: WebKit/public/blink_headers.gyp:web_input_event_java
84   # GYP version: WebKit/public/blink_headers.gyp:web_text_input_type
85   java_cpp_enum("blink_headers_java_enums_srcjar") {
86     sources = [
87       "./web/WebInputEvent.h",
88       "./web/WebTextInputType.h",
89       "./platform/WebDisplayMode.h",
90     ]
91     outputs = [
92       "org/chromium/blink_public/platform/WebDisplayMode.java",
93       "org/chromium/blink_public/web/WebInputEventModifier.java",
94       "org/chromium/blink_public/web/WebInputEventType.java",
95       "org/chromium/blink_public/web/WebTextInputFlags.java",
96     ]
97   }
99   # GYP version: WebKit/public/blink_headers.gyp:blink_headers_java
100   android_library("blink_headers_java") {
101     srcjar_deps = [
102       ":blink_headers_java_enums_srcjar",
103     ]
104   }
107 # Depend on this target to use public blink API headers for things like enums
108 # and public structures without actually linking against any Blink libraries.
109 source_set("blink_headers") {
110   public_configs = [
111     ":blink_headers_config",
112     # Blink exposes icu headers in the public API.
113     "//third_party/icu:icu_config",
114     # Blink exposes NPAPI headers in the public API.
115     "//third_party/npapi:npapi_config",
116   ]
117   sources = blink_headers_values.blink_public_sources
120 # GYP version: WebKit/public/blink_devtools.gyp:blink_devtools_frontend_resources
121 group("blink_devtools_frontend_resources") {
122   public_deps = [
123     "//third_party/WebKit/Source/devtools:devtools_frontend_resources",
124   ]
127 # GYP version: WebKit/public/blink_devtools.gyp:blink_generate_devtools_grd
128 group("blink_generate_devtools_grd") {
129   public_deps = [
130     "//third_party/WebKit/Source/devtools:generate_devtools_grd",
131   ]
134 # GYP version: WebKit/public/blink_resources.gyp:blink_resources
135 grit("resources") {
136   output_dir = "$root_gen_dir/blink/public/resources"
137   use_qualified_include = true
138   source = "blink_resources.grd"
139   outputs = [
140     "grit/blink_resources.h",
141     "blink_resources.pak",
142   ]
143   if (use_concatenated_impulse_responses) {
144     grit_flags = [
145       "-D",
146       "use_concatenated_impulse_responses",
147     ]
148   }
151 # GYP version: WebKit/public/blink_resources.gyp:blink_image_resources
152 grit("image_resources") {
153   output_dir = "$root_gen_dir/blink/public/resources"
154   use_qualified_include = true
155   source = "blink_image_resources.grd"
156   outputs = [
157     "grit/blink_image_resources.h",
158     "blink_image_resources_100_percent.pak",
159     "blink_image_resources_200_percent.pak",
160   ]