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

Side by Side Diff: BUILD.gn

Issue 953463003: Reland #317760 - add gn_all, gyp_all targets (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: do not try to remove views_unittests on android Created 5 years, 10 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
« no previous file with comments | « no previous file | build/all.gyp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 # This is the root build file for GN. GN will start processing by loading this 5 # This is the root build file for GN. GN will start processing by loading this
6 # file, and recursively load all dependencies until all dependencies are either 6 # file, and recursively load all dependencies until all dependencies are either
7 # resolved or known not to exist (which will cause the build to fail). So if 7 # resolved or known not to exist (which will cause the build to fail). So if
8 # you add a new build file, there must be some path of dependencies from this 8 # you add a new build file, there must be some path of dependencies from this
9 # file to your new one or GN won't know about it. 9 # file to your new one or GN won't know about it.
10 10
11 import("//build/config/features.gni") 11 import("//build/config/features.gni")
12 import("//build/config/ui.gni") 12 import("//build/config/ui.gni")
13
13 if (is_android) { 14 if (is_android) {
14 import("//build/config/android/config.gni") 15 import("//build/config/android/config.gni")
15 } 16 }
16 17
17 declare_args() { 18 declare_args() {
18 # A list of extra dependencies to add to the root target. This allows a 19 # A list of extra dependencies to add to the root target. This allows a
19 # checkout to add additional targets without explicitly changing any checked- 20 # checkout to add additional targets without explicitly changing any checked-
20 # in files. 21 # in files.
21 root_extra_deps = [] 22 root_extra_deps = []
22 } 23 }
23 24
24 # In GN, a "group" is a dummy target that just lists other targets. 25 group("gyp_all") {
25 group("root") {
26 # This should not be linked into production and depends on test targets.
27 testonly = true 26 testonly = true
28 27
29 # Note that some dependencies are commented out. These are things that are 28 # TODO(GYP): This target should describe everything that is built by a GYP
30 # currently written but not hooked up to the build yet. They may need to be 29 # build but not yet by a GN build, i.e., these are the targets that still
31 # completed or possibly just tested and then re-enabled. 30 # need to be ported to GN. Eventually this target should be identical to
31 # gn_all.
32
32 deps = [ 33 deps = [
33 "//apps", 34 ":gn_all",
34 "//ash", 35 # "//chrome/test:chromedriver_unittests", # TODO(GYP)
35 "//cc", 36 # "//components:components_browsertests", # TODO(GYP)
36 "//cc/blink", 37 # "//components/nacl:nacl_loader_unittests", # TODO(GYP)
37 "//chrome/browser", 38 # "//google_apis:google_apis_unittests", # TODO(GYP)
38 "//chrome/browser/devtools", 39 # "//ui/compositor:compositor_unittests", # TODO(GYP)
39 "//chrome/common", 40 # "//device:device_unittests", # TODO(GYP)
40 "//chrome/plugin", 41 # "//ppapi:ppapi_unittests", # TODO(GYP)
41 "//chrome/renderer", 42 # "//remoting:remoting_unittests", # TODO(GYP)
42 "//chrome/test", 43 ]
43 "//chrome/tools", 44 }
44 "//chrome/utility", 45
45 "//components:all_components", 46 # The "gn_all" target matches the "gn_all" target in build/all.gyp.
46 "//content", 47 # It is not (yet!) the same as building "all".
48 # TODO(GYP): Make it be basically the same as building all, or at least
49 # be sure that we don't want any of the stuff listed in gn_all to
50 # be built by default.
51
52 # In GN, a "group" is a dummy target that just lists other targets.
53 group("gn_all") {
54 testonly = true
55
56 deps = [
57 "//base:base_unittests",
58 "//cc:cc_unittests",
59 "//chrome",
60 "//chrome/test:browser_tests",
61 "//chrome/test:interactive_ui_tests",
62 "//chrome/test:sync_integration_tests",
63 "//chrome/test:unit_tests",
64 "//components:components_unittests",
47 "//content/shell:content_shell", 65 "//content/shell:content_shell",
48 "//content/test:test_support", 66 "//content/test:content_browsertests",
49 "//crypto", 67 "//content/test:content_perftests",
50 "//device/battery", 68 "//content/test:content_unittests",
51 "//device/bluetooth", 69 "//crypto:crypto_unittests",
52 "//device/nfc", 70 "//extensions:extensions_browsertests",
53 "//device/vibration", 71 "//extensions:extensions_unittests",
54 "//extensions/browser", 72 "//google_apis/gcm:gcm_unit_tests",
55 "//extensions/common", 73 "//gpu:gpu_unittests",
56 "//extensions/common/api", 74 "//ipc:ipc_tests",
57 "//extensions/renderer", 75 "//ipc/mojo:ipc_mojo_unittests",
58 "//gin", 76 "//jingle:jingle_unittests",
59 "//gpu", 77 "//media:media_unittests",
60 "//google_apis", 78 "//media/mojo", # only builds in mojo
61 "//google_apis/gcm", 79 "//media/cast:cast_unittests",
62 "//ipc",
63 "//ipc/mojo",
64 "//jingle:notifier",
65 "//media",
66 "//media/blink",
67 "//media/cast",
68 "//media/mojo",
69 "//mojo", 80 "//mojo",
70 "//net", 81 "//mojo/common:mojo_common_unittests",
71 "//pdf", 82
72 "//ppapi/examples", 83 # "//mojo/services/html_viewer:tests", # TODO(GYP): Do we need this?
73 "//printing", 84 "//net:net_unittests",
74 "//remoting/client/plugin", 85 "//ppapi/examples", # TODO(GYP): What's the GYP equivalent?
75 "//sandbox", 86 "//printing:printing_unittests",
76 "//sdch", 87 "//skia:skia_unittests",
77 "//skia", 88 "//sql:sql_unittests",
78 "//storage/browser", 89 "//sync:sync_unit_tests",
79 "//sql", 90
80 "//sync", 91 # TODO(GYP): the Blink test targets should be public, but
92 # currently aren't. all_blink pulls them in, though.
93 # "//third_party/WebKit/Source/platform:heap_unittests",
94 # "//third_party/WebKit/Source/platform:platform_unittests",
95 # "//third_party/WebKit/Source/wtf:wtf_unittests",
81 "//third_party/WebKit/public:all_blink", 96 "//third_party/WebKit/public:all_blink",
82 "//third_party/angle:translator", 97 "//third_party/cacheinvalidation:cacheinvalidation_unittests",
83 "//third_party/brotli", 98
84 "//third_party/cacheinvalidation", 99 # TODO(GYP): This is needed only w/ cld_version==1. What configs set that?
85 "//third_party/cld", 100 "//third_party/cld",
86 "//third_party/cld_2",
87 "//third_party/codesighs", 101 "//third_party/codesighs",
88 "//third_party/ffmpeg", 102
89 "//third_party/flac", 103 # TODO(GYP): This is needed only w/ use_system_fontconfig==0.
90 "//third_party/harfbuzz-ng", 104 # What configs set that?
91 "//third_party/hunspell", 105 # "//third_party/fontconfig",
92 "//third_party/iccjpeg", 106
93 "//third_party/icu", 107 # TODO(GYP): This will be pulled in automatically when enable_webrtc==true.
94 "//third_party/leveldatabase", 108 # For now pull it in manually so that it doesn't regress.
95 "//third_party/libphonenumber",
96 "//third_party/libjingle",
97 "//third_party/libpng",
98 "//third_party/libsrtp", 109 "//third_party/libsrtp",
99 "//third_party/libusb", 110 "//third_party/mojo/src/mojo/edk/system:mojo_system_unittests",
100 "//third_party/libwebp", 111 "//third_party/mojo/src/mojo/edk/test:mojo_public_bindings_unittests",
101 "//third_party/libxslt", 112 "//third_party/mojo/src/mojo/edk/test:mojo_public_environment_unittests",
102 "//third_party/libvpx", 113 "//third_party/mojo/src/mojo/edk/test:mojo_public_system_unittests",
103 "//third_party/libyuv", 114 "//third_party/mojo/src/mojo/edk/test:mojo_public_utility_unittests",
104 "//third_party/lzma_sdk", 115 "//third_party/pdfium/samples:pdfium_test",
105 "//third_party/mesa", 116
106 "//third_party/opus", 117 # TODO(GYP): Verify that this is no longer needed.
107 "//third_party/ots",
108 "//third_party/protobuf:protobuf_lite",
109 "//third_party/qcms",
110 "//third_party/re2",
111 "//third_party/smhasher:cityhash",
112 "//third_party/smhasher:murmurhash3",
113 "//third_party/smhasher:pmurhash", 118 "//third_party/smhasher:pmurhash",
114 "//third_party/snappy", 119
115 "//third_party/speex", 120 # TODO(GYP): This will be pulled in automatically when enable_webrtc==true.
121 # For now pull it in manually so that it doesn't regress.
116 "//third_party/usrsctp", 122 "//third_party/usrsctp",
117 "//third_party/widevine/cdm:version_h", 123 "//tools/imagediff($host_toolchain)",
118 "//third_party/webrtc",
119 "//third_party/zlib",
120 "//third_party:jpeg",
121 "//tools/gn", 124 "//tools/gn",
122 "//tools/imagediff($host_toolchain)", 125 "//tools/gn:gn_unittests",
123 "//tools/telemetry:bitmaptools", 126 "//tools/telemetry:bitmaptools($host_toolchain)",
124 "//ui/accessibility", 127 "//ui/accessibility:accessibility_unittests",
125 "//ui/app_list", 128 "//ui/app_list:app_list_unittests",
126 "//ui/aura", 129 "//ui/base:ui_base_unittests",
127 "//ui/base", 130 "//ui/display:display_unittests",
128 "//ui/display", 131 "//ui/events:events_unittests",
129 "//ui/events", 132 "//ui/gfx:gfx_unittests",
130 "//ui/gfx", 133 "//ui/touch_selection:ui_touch_selection_unittests",
131 "//ui/gl", 134 "//url:url_unittests",
132 "//ui/keyboard",
133 "//ui/native_theme",
134 "//ui/resources",
135 "//ui/snapshot",
136 "//ui/strings",
137 "//ui/surface",
138 "//ui/touch_selection",
139 "//ui/views",
140 "//ui/views/controls/webview",
141 "//ui/web_dialogs",
142 "//url",
143 "//v8:v8",
144 ] 135 ]
136
145 deps += root_extra_deps 137 deps += root_extra_deps
146 138
147 # TODO(GYP): Get this working on the mac? 139 # TODO(GYP): Get this working on the mac?
148 if (enable_extensions && !is_mac) { 140 if (enable_extensions && !is_mac) {
149 deps += [ "//extensions/shell:app_shell_unittests" ] 141 deps += [ "//extensions/shell:app_shell_unittests" ]
150 } 142 }
151 143
152 if (!is_win) { 144 if (!is_win) {
153 deps += [ "//breakpad:symupload" ] 145 deps += [ "//breakpad:symupload" ]
154 } 146 }
155 147
156 if (is_linux) {
157 deps += [
158 "//dbus",
159 "//third_party/fontconfig",
160 "//third_party/freetype2",
161 ]
162 }
163
164 if (use_x11) { 148 if (use_x11) {
165 deps += [ "//tools/xdisplaycheck" ] 149 deps += [ "//tools/xdisplaycheck" ]
166 } 150 }
167 151
168 if (use_aura) { 152 if (toolkit_views) {
169 deps += [ "//ui/wm" ] 153 deps += [ "//ui/views:views_unittests" ]
170 } 154 }
171 155
172 if (is_win) { 156 if (use_aura) {
173 deps += [ "//ui/metro_viewer" ] 157 deps += [ "//ui/wm:wm_unittests" ]
158 }
159
160 if (use_ozone) {
161 deps += [
162 "//ui/ozone",
163 "//ui/ozone/demo", # GN only
164 ]
174 } 165 }
175 166
176 if (is_win || is_mac || is_chromeos) { 167 if (is_win || is_mac || is_chromeos) {
177 # RLZ works on these platforms. 168 # RLZ works on these platforms.
169 # TODO(GYP): Is this target needed, or pulled in automatically?
178 deps += [ "//rlz:rlz_lib" ] 170 deps += [ "//rlz:rlz_lib" ]
179 } 171 }
180 172
181 if (current_cpu == "x86" || current_cpu == "x64") {
182 # YASM is x86/x64 only.
183 deps += [ "//third_party/yasm($host_toolchain)" ]
184 }
185
186 if (is_android) { 173 if (is_android) {
187 deps += [ 174 deps += [
188 "//base/android/linker:chromium_android_linker", 175 "//base/android/linker:chromium_android_linker",
189 "//build/android/gyp/test:hello_world", 176 "//build/android/gyp/test:hello_world",
190 "//build/android/rezip", 177 "//build/android/rezip",
191 "//third_party/openmax_dl/dl", 178 "//chrome/android:chrome_shell_apk",
179 "//chrome/test/chromedriver/test/webview_shell:chromedriver_webview_shell_ apk",
180 "//tools/imagediff($host_toolchain)",
181
182 # TODO(GYP): Remove these when the components_unittests work.
183 "//components/history/core/test:test",
184 "//components/policy:policy_component_test_support",
185 "//components/policy:test_support",
186 "//components/rappor:test_support",
187 "//components/signin/core/browser:test_support",
188 "//components/sync_driver:test_support",
189 "//components/user_manager",
190 "//components/wallpaper",
192 "//content/shell/android:content_shell_apk", 191 "//content/shell/android:content_shell_apk",
193 "//chrome/android:chrome_shell_apk", 192
194 "//chrome/test:test_support_unit", 193 # TODO(GYP): Are these needed, or will they be pulled in automatically?
195 "//chrome/test/chromedriver/test/webview_shell:chromedriver_webview_shell_ apk",
196 "//ui/android:ui_java",
197 "//third_party/android_tools:android_gcm_java", 194 "//third_party/android_tools:android_gcm_java",
198 "//third_party/android_tools:uiautomator_java", 195 "//third_party/android_tools:uiautomator_java",
199 "//third_party/android_tools:android_support_v13_java", 196 "//third_party/android_tools:android_support_v13_java",
200 "//third_party/android_tools:android_support_v7_appcompat_java", 197 "//third_party/android_tools:android_support_v7_appcompat_java",
201 "//third_party/android_tools:android_support_v7_mediarouter_java", 198 "//third_party/android_tools:android_support_v7_mediarouter_java",
199 "//third_party/mesa",
202 "//third_party/mockito:mockito_java", 200 "//third_party/mockito:mockito_java",
201 "//third_party/openmax_dl/dl",
202 "//third_party/speex",
203 "//ui/android:ui_java",
204
205 # TODO(GYP): Are these needed?
206 "//chrome/test:test_support_unit",
207 "//third_party/smhasher:murmurhash3",
208 "//ui/message_center:test_support",
209 ]
210 deps -= [
211 "//breakpad:symupload", # TODO(GYP) ??
212 "//chrome", # TODO(GYP) ??
213 "//chrome/test:browser_tests", # TODO(GYP) ??
214 "//chrome/test:interactive_ui_tests", # TODO(GYP) ??
215 "//chrome/test:sync_integration_tests", # TODO(GYP) ??
216 "//chrome/test:unit_tests", # TODO(GYP)
217 "//extensions:extensions_browsertests",
218 "//extensions:extensions_unittests",
219 "//google_apis/gcm:gcm_unit_tests",
220 "//ipc:ipc_tests", # TODO(GYP) ??
221 "//jingle:jingle_unittests", # TODO(GYP) ??
222 "//net:net_unittests",
223 "//ppapi/examples",
224 "//third_party/pdfium/samples:pdfium_test",
225 "//tools/gn",
226 "//tools/gn:gn_unittests",
227 "//ui/app_list:app_list_unittests",
228 "//url:url_unittests",
203 ] 229 ]
204 230
205 if (has_chrome_android_internal) { 231 if (has_chrome_android_internal) {
206 deps += [ "//clank" ] 232 deps += [ "//clank" ] # TODO(GYP) ??
207 } 233 }
208 234 } else if (is_linux) {
209 # TODO(GYP): Move the targets in the rest of this block that still 235 deps += [
210 # need to be made to work in the GN build to the bottom of the file 236 "//dbus:dbus_unittests",
211 # so that all the remaining work is located in one place in the file. 237 "//sandbox/linux:sandbox_linux_unittests",
212 # This block should contain only the targets that aren't actually
213 # needed on Android.
214
215 deps -= [
216 "//apps", # Needs testing.
217 "//chrome/browser",
218 "//chrome/browser/devtools",
219 "//chrome/common",
220 "//chrome/plugin",
221 "//chrome/renderer",
222 "//chrome/test",
223 "//chrome/tools",
224 "//chrome/utility",
225 "//content/shell:content_shell",
226 "//extensions/browser",
227 "//extensions/common",
228 "//extensions/common/api",
229 "//extensions/renderer",
230 "//pdf", # Not compiled on Android in GYP yet, either.
231 "//ppapi/examples",
232 "//third_party/libusb",
233 "//ui/keyboard", # Blocked on content.
234
235 # Seems to not be compiled on Android. Otherwise it will need a config.h.
236 "//third_party/libxslt",
237
238 # Not relevant to Android.
239 "//ash",
240 "//tools/gn",
241 "//ui/aura",
242 "//ui/display",
243 "//ui/views",
244 "//ui/views/controls/webview",
245
246 # Fails on Android for unknown reasons.
247 "//third_party/flac",
248 "//breakpad:symupload",
249
250 # Not tested on Android yet:
251 "//google_apis/gcm",
252 "//remoting/client/plugin",
253 "//storage/browser",
254 "//third_party/cld_2",
255 "//third_party/ffmpeg",
256 "//ui/app_list",
257 "//ui/web_dialogs",
258 ] 238 ]
259 } 239 } else if (is_mac) {
260
261 if (use_ozone) {
262 deps += [
263 "//ui/ozone",
264 "//ui/ozone/demo",
265 ]
266 }
267
268 # Non-mobile builds.
269 if (!is_android && !is_ios) {
270 deps += [
271 "//device/usb",
272 "//device:device_unittests",
273 "//third_party/pdfium/samples",
274 ]
275 }
276
277 #
278 # TODO(GYP): Make everything below this work in the GN build.
279 #
280
281 if (is_mac) {
282 deps += [ 240 deps += [
283 "//third_party/apple_sample_code", 241 "//third_party/apple_sample_code",
284 "//third_party/molokocacao", 242 "//third_party/molokocacao",
285 ] 243 ]
286 244
245 # TODO(GYP): Remove these when the targets below work and these
246 # are pulled in automatically.
247 deps += [
248 "//cc/blink",
249 "//components/ui/zoom:ui_zoom",
250 "//content",
251 "//content/test:test_support",
252 "//device/battery",
253 "//device/bluetooth",
254 "//device/nfc",
255 "//device/usb",
256 "//device/vibration",
257 "//media/blink",
258 "//pdf",
259 "//storage/browser",
260 "//third_party/brotli",
261 "//third_party/flac",
262 "//third_party/hunspell",
263 "//third_party/iccjpeg",
264 "//third_party/libphonenumber",
265 "//third_party/ots",
266 "//third_party/qcms",
267 "//third_party/smhasher:murmurhash3",
268 "//third_party/speex",
269 "//third_party/webrtc/system_wrappers",
270 "//ui/native_theme",
271 "//ui/snapshot",
272 "//ui/surface",
273 ]
274
287 # TODO(dpranke): These are as-yet untriaged but need at least the above. 275 # TODO(dpranke): These are as-yet untriaged but need at least the above.
288 deps -= [ 276 deps -= [
289 "//apps", 277 "//chrome", # TODO(GYP)
290 "//ash", 278 "//chrome/test:browser_tests", # TODO(GYP)
291 "//chrome/browser", 279 "//chrome/test:interactive_ui_tests", # TODO(GYP)
292 "//chrome/browser/devtools", 280 "//chrome/test:sync_integration_tests", # TODO(GYP)
293 "//chrome/common", 281 "//chrome/test:unit_tests", # TODO(GYP)
294 "//chrome/plugin", 282 "//components:components_unittests", # TODO(GYP)
295 "//chrome/renderer", 283 "//content/test:content_browsertests", # TODO(GYP)
296 "//chrome/test", 284 "//content/test:content_perftests", # TODO(GYP)
297 "//chrome/utility", 285 "//content/test:content_unittests", # TODO(GYP)
298 "//components:all_components", 286 "//extensions:extensions_browsertests", # TODO(GYP)
299 "//content/shell:content_shell", 287 "//extensions:extensions_unittests", # TODO(GYP)
300 "//extensions/browser", 288 "//net:net_unittests", # TODO(GYP)
301 "//extensions/common", 289 "//third_party/usrsctp", # TODO(GYP)
302 "//extensions/common/api", 290 "//ui/app_list:app_list_unittests", # TODO(GYP)
303 "//extensions/renderer", 291 "//ui/gfx:gfx_unittests", # TODO(GYP)
304 "//remoting/client/plugin", 292 ]
305 "//third_party/usrsctp", 293 } else if (is_win) {
306 "//ui/app_list", 294 deps += [ "//ui/metro_viewer" ]
307 "//ui/aura", 295 deps -= [
308 "//ui/keyboard", 296 "//crypto:crypto_unittests", # TODO(GYP)
309 "//ui/views", 297 "//net:net_unittests", # TODO(GYP)
310 "//ui/views/controls/webview",
311 "//ui/web_dialogs",
312 ] 298 ]
313 } 299 }
314
315 if (is_mac || is_ios) {
316 deps -= [ "//ui/touch_selection" ]
317 }
318 } 300 }
OLDNEW
« no previous file with comments | « no previous file | build/all.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698