Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(160)

Side by Side Diff: ui/views/BUILD.gn

Issue 388393002: Add ui/views to GN build. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ui/events/platform/x11/x11_events_platform.gyp ('k') | ui/views/views.gyp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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.
4
5 import("//build/config/features.gni")
6 import("//build/config/ui.gni")
7
8 gypi_values = exec_script(
9 "//build/gypi_to_gn.py",
10 [ rebase_path("views.gyp") ],
11 "scope",
12 [ "views.gyp" ])
13
14 component("views") {
15 sources = gypi_values.views_sources
16
17 defines = [ "VIEWS_IMPLEMENTATION" ]
18
19 deps = [
20 "//base",
21 "//base:i18n",
22 "//base/third_party/dynamic_annotations",
23 "//skia",
24 "//third_party/icu",
25 "//third_party/wtl",
26 "//ui/accessibility",
27 "//ui/accessibility:ax_gen",
28 "//ui/aura",
29 "//ui/base",
30 "//ui/compositor",
31 "//ui/events",
32 "//ui/events:events_base",
33 "//ui/events/platform",
34 "//ui/gfx",
35 "//ui/gfx/geometry",
36 "//ui/native_theme",
37 "//ui/resources",
38 "//ui/strings",
39 "//ui/wm",
40 "//url",
41 ]
42
43 forward_dependent_configs_from = [ "//ui/accessibility:ax_gen" ]
44
45 if (!use_ash) {
46 sources -= [
47 "bubble/tray_bubble_view.cc",
48 "bubble/tray_bubble_view.h",
49 ]
50 }
51 if (use_x11 && !is_chromeos) {
52 #deps += [ '../display/display.gyp:display_util' ] TODO(GYP)
53 }
54 if (is_linux && !is_chromeos) {
55 sources -= [ "window/window_button_order_provider.cc" ]
56 #deps += [ '../shell_dialogs/shell_dialogs.gyp:shell_dialogs' ] TODO(GYP)
57 } else {
58 sources -= [
59 "linux_ui/linux_ui.h",
60 "linux_ui/linux_ui.cc",
61 "linux_ui/status_icon_linux.h",
62 "linux_ui/status_icon_linux.cc",
63 "linux_ui/window_button_order_observer.h",
64 "linux_ui/window_button_order_provider.cc",
65 ]
66 }
67
68 if (is_win) {
69 sources += gypi_values.views_win_sources
70 cflags = [ "/wd4267" ] # TODO(jschuh): crbug.com/167187 fix size_t to int t runcations.
71 libs = [ "/imm32.lib", "oleacc.lib" ]
72 ldflags = [ "/DELAYLOAD:user32.dll" ]
73 deps += [
74 "//third_party/iaccessible2",
75 "//third_party/wtl",
76 ]
77 }
78
79 if (use_ozone) {
80 deps += [ "//ui/ozone" ]
81 }
82 if (use_x11) {
83 configs += [
84 "//build/config/linux:x11",
85 "//build/config/linux:xrandr",
86 ]
87 deps += [
88 "//ui/events/platform/x11",
89 ]
90 }
91
92 if (use_aura) {
93 sources += gypi_values.views_aura_sources
94 if (!is_chromeos) {
95 if (use_x11) {
96 sources += gypi_values.views_desktop_aura_x11_sources
97 } else if (is_win) {
98 sources += gypi_values.views_desktop_aura_win_sources
99 } else if (use_ozone) {
100 sources += gypi_values.views_desktop_aura_ozone_sources
101 }
102 }
103 }
104 }
105
106 static_library("test_support") {
107 sources = gypi_values.views_test_support_sources
108
109 deps = [
110 ":views",
111 "//base",
112 "//ipc",
113 "//skia",
114 "//testing/gtest",
115 "//ui/aura",
116 "//ui/base",
117 "//ui/compositor",
118 "//ui/events",
119 "//ui/events/platform",
120 "//ui/gfx",
121 "//ui/gfx/geometry",
122 "//ui/wm",
123 ]
124
125 if (is_chromeos) {
126 sources -= [
127 "test/ui_controls_factory_desktop_aurax11.cc",
128 "test/ui_controls_factory_desktop_aurax11.h",
129 ]
130 }
131 if (use_aura) {
132 sources += gypi_values.views_test_support_aura_sources
133 deps += [ "//ui/aura:test_support" ]
134 }
135 }
136
137 if (false) { # TODO(GYP) enable once this links
138
139 test("views_unittests") {
140 sources = gypi_values.views_unittests_sources
141
142 deps = [
143 ":test_support",
144 ":views",
145 "//base",
146 "//base:i18n",
147 "//base/allocator",
148 "//base/test:test_support",
149 "//skia",
150 "//testing/gtest",
151 "//third_party/icu",
152 "//ui/accessibility",
153 "//ui/aura",
154 "//ui/base",
155 "//ui/base:test_support",
156 "//ui/compositor",
157 "//ui/compositor:test_support",
158 "//ui/events",
159 "//ui/events:events_base",
160 "//ui/events/platform",
161 "//ui/gfx",
162 "//ui/gfx/geometry",
163 "//ui/wm",
164 "//url",
165 ]
166
167 if (is_chromeos) {
168 sources -= [
169 "ime/input_method_bridge_unittest.cc",
170 "widget/desktop_aura",
171 ]
172 }
173
174 if (is_win) {
175 deps += [
176 "//third_party/iaccessible2",
177 "//third_party/wtl",
178 ]
179 libs = [
180 "imm32.lib",
181 "oleacc.lib",
182 "comctl32.lib",
183 ]
184 # TOOD(GYP)
185 #'msvs_settings': {
186 # 'VCManifestTool': {
187 # 'AdditionalManifestFiles': [
188 # '$(ProjectDir)\\test\\views_unittest.manifest',
189 # ],
190 # },
191 #},
192 }
193
194 if (use_x11) {
195 configs += [
196 "//build/config/linux:x11",
197 "//build/config/linux:xext",
198 ]
199 deps += [
200 "//ui/events/platform/x11",
201 ]
202 }
203
204 if (use_ozone) {
205 sources -= [
206 "corewm/capture_controller_unittest.cc",
207 ]
208 }
209 if (use_aura) {
210 sources += gypi_values.views_unittests_aura_sources
211 deps = [ "//ui/aura:test_support" ]
212 if (!is_chromeos) {
213 sources += gypi_values.views_unittests_desktop_aura_sources
214 }
215 }
216 if (use_x11) {
217 deps += [ "//ui/events/platform/x11" ]
218 }
219
220 if (is_mac) {
221 # views_unittests not yet compiling on Mac. http://crbug.com/378134
222 sources -= [
223 "bubble/bubble_window_targeter_unittest.cc",
224 "controls/button/custom_button_unittest.cc",
225 "controls/button/menu_button_unittest.cc",
226 "controls/native/native_view_host_unittest.cc",
227 "controls/menu/menu_controller_unittest.cc",
228 "ime/input_method_bridge_unittest.cc",
229 "focus/focus_manager_unittest.cc",
230 "widget/window_reorderer_unittest.cc",
231 "widget/widget_unittest.cc",
232 ]
233 }
234 }
235
236 if (is_mac) {
237 test("macviews_interactive_ui_tests") {
238 sources = [
239 "run_all_unittests.cc",
240 "widget/native_widget_mac_interactive_uitest.mm",
241 ]
242 deps = [
243 ":test_support",
244 ":views",
245 "//base",
246 "//base/test:test_support",
247 "//skia",
248 "//testing/gtest",
249 "//ui/aura",
250 "//ui/compositor",
251 "//ui/resources",
252 "//ui/resources:ui_test_pak",
253 "//ui/string",
254 "//ui/wm",
255 ]
256 }
257 }
258
259 } # if false
OLDNEW
« no previous file with comments | « ui/events/platform/x11/x11_events_platform.gyp ('k') | ui/views/views.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698