blob: c780bc3ce8c8dc576cb5ed7f11eb00fd0921e846 [file] [log] [blame]
brettw2bafab42014-11-27 18:36:171# This file is used by the GN meta build system to find the root of the source
2# tree and to set startup options. For documentation on the values set in this
3# file, run "gn help dotfile" at the command line.
[email protected]96ea63d2013-07-30 10:17:074
dpranke1cfa5312016-11-22 03:07:475import("//build/dotfile_settings.gni")
6
[email protected]96ea63d2013-07-30 10:17:077# The location of the build configuration file.
8buildconfig = "//build/config/BUILDCONFIG.gn"
9
10# The secondary source root is a parallel directory tree where
scheibec4b3a42014-09-18 21:50:1311# GN build files are placed when they can not be placed directly
12# in the source tree, e.g. for third party source trees.
[email protected]26688b86e2014-06-19 13:14:2613secondary_source = "//build/secondary/"
brettw2bafab42014-11-27 18:36:1714
brettw04a0e482017-01-25 21:29:5915# These arguments override the default values for items in a declare_args
16# block. "gn args" in turn can override these.
17#
18# In general the value for a build arg in the declare_args block should be the
19# default. In some cases, a DEPS-ed in project will want different defaults for
20# being built as part of Chrome vs. being built standalone. In this case, the
21# Chrome defaults should go here. There should be no overrides here for
22# values declared in the main Chrome repository.
brettwd8a46d92017-02-08 06:03:4523#
24# Important note for defining defaults: This file is executed before the
25# BUILDCONFIG.gn file. That file sets up the global variables like "is_ios".
26# This means that the default_args can not depend on the platform,
27# architecture, or other build parameters. If you really need that, the other
28# repo should define a flag that toggles on a behavior that implements the
29# additional logic required by Chrome to set the variables.
brettw04a0e482017-01-25 21:29:5930default_args = {
31 v8_extra_library_files = [
32 # Dependencies used by the extra libraries. Putting them here causes them
33 # to be executed first during snapshot creation.
34 "//third_party/WebKit/Source/core/streams/CommonStrings.js",
35
36 # Extra libraries.
37 "//third_party/WebKit/Source/core/streams/ByteLengthQueuingStrategy.js",
38 "//third_party/WebKit/Source/core/streams/CountQueuingStrategy.js",
39 "//third_party/WebKit/Source/core/streams/ReadableStream.js",
40 ]
ricea9ba4a6432017-01-26 17:11:5741 v8_experimental_extra_library_files = [
42 "//third_party/WebKit/Source/core/streams/ReadableStreamExperimentalPipeTo.js",
43 "//third_party/WebKit/Source/core/streams/WritableStream.js",
44 ]
brettw04a0e482017-01-25 21:29:5945 v8_enable_inspector = true
46 v8_enable_gdbjit = false
47 v8_imminent_deprecation_warnings = false
48}
49
brettw2bafab42014-11-27 18:36:1750# These are the targets to check headers for by default. The files in targets
51# matching these patterns (see "gn help label_pattern" for format) will have
52# their includes checked for proper dependencies when you run either
53# "gn check" or "gn gen --check".
brettwe75311d2015-02-17 23:56:4654check_targets = [
brettwbc44c0a92015-02-20 22:30:3955 #"//apps/*", # Medium-hard.
mswafbb0c02016-02-11 01:54:1256 "//ash/*",
brettw29c2f892015-11-27 17:03:4957 "//base/*",
brettwbc44c0a92015-02-20 22:30:3958 "//blink/*",
59 "//breakpad/*",
60 "//build/*",
brettwe75311d2015-02-17 23:56:4661 "//cc/*",
brettwbc44c0a92015-02-20 22:30:3962
63 #"//chrome/*", # Epic number of errors.
tfarina8e584882016-01-09 00:50:1564 "//chrome/app/*",
brettwafa8f542016-08-24 05:16:2465 "//chrome/browser/extensions/*",
brettwb3e60142016-09-23 19:55:0166 "//chrome/browser/ui/*",
brettw0b9c96b12015-10-15 23:06:0467 "//chrome/common/*",
brettwf986f9572015-10-07 17:18:1568 "//chrome/installer/*",
brettw0b9c96b12015-10-15 23:06:0469 "//chrome/third_party/mozilla_security_manager/*",
tfarina961ad5d2016-01-06 22:27:1170 "//chrome/tools/*",
tfarina02f77a42015-12-17 22:38:2371 "//chrome/utility/*",
brettwbc44c0a92015-02-20 22:30:3972 "//chromecast/*",
oshima3f959fa82016-05-02 18:42:5773 "//chromeos/*",
brettwa219e922015-12-07 22:23:3974 "//chrome_elf/*",
75 "//cloud_print/*",
brettwb5440a92015-12-03 00:47:1276 "//components/*",
brettwd064ace4e2016-07-21 21:38:5377 "//content/*",
brettwbc44c0a92015-02-20 22:30:3978 "//courgette/*",
79 "//crypto/*",
80 "//data/*",
81 "//dbus/*",
brettwbda835b2015-12-04 22:12:3082 "//device/*",
brettwbc44c0a92015-02-20 22:30:3983
84 #"//extensions/*", # Lots of errors.
brettwdc1e6182016-08-30 20:52:1385 "//extensions:extensions_unittests",
86 "//extensions/browser:browser_tests",
87 "//extensions/browser:unit_tests",
88 "//extensions/common:unit_tests",
89 "//extensions/renderer:unit_tests",
90 "//extensions/shell:browser_tests",
91 "//extensions/shell:unit_tests",
92 "//extensions/utility:unit_tests",
jbromanb5e31792015-12-09 17:13:0293 "//gin/*",
tfarina9ee681962015-03-02 03:20:1394 "//google_apis/*",
brettwbc44c0a92015-02-20 22:30:3995 "//google_update/*",
brettw09039c12016-03-18 03:22:4696 "//gpu/*",
tfarinaf89722432015-05-15 19:30:1997
sdefresne5f39d8e62016-05-18 19:27:3798 "//ios/*",
99 "//ios_internal/*",
brettwe75311d2015-02-17 23:56:46100 "//ipc/*",
brettwbc44c0a92015-02-20 22:30:39101
102 #"//jingle/*",
skyb0446352015-11-18 00:43:56103 "//mash/*",
sky88d7709e2015-08-12 19:19:49104
brettwbc44c0a92015-02-20 22:30:39105 #"//media/*", # Lots of errors.
jrummell370e8f92016-06-02 19:16:27106 #"//media/base/*",
107 #"//media/capture/*",
weze25ca8402016-11-11 02:05:12108 "//media/cast/*",
jrummell370e8f92016-06-02 19:16:27109 "//media:media",
110 "//media:shared_memory_support",
111 "//media:media_unittests",
112 "//media:audio_unittests",
113 "//media:media_perftests",
114 "//media/audio/*",
115 "//media/blink/*",
116 "//media/cdm/*",
117 "//media/ffmpeg/*",
118 "//media/gpu/*",
119 "//media/midi/*",
120 "//media/mojo/*",
xhwang09f35d952016-11-11 18:12:18121 "//media/remoting/*",
jrummell5216c612016-10-06 01:30:30122 "//media/test/*",
jrummell370e8f92016-06-02 19:16:27123
sky343931432015-08-10 19:22:19124 "mojo/*",
skyd412f6e2015-07-22 17:22:13125
brettwbc44c0a92015-02-20 22:30:39126 #"//native_client/*",
brettw25ca8922016-03-18 22:59:58127 "//net/*",
brettwbc44c0a92015-02-20 22:30:39128
129 #"//pdf/*", # Medium-hard.
130 #"//ppapi/*", # Lots of errors.
jbroman86f78272015-12-31 00:00:51131 "//ppapi/examples/*",
brettwbc44c0a92015-02-20 22:30:39132 "//printing/*",
133
134 #"//remoting/*", # Medium-hard.
brettw09039c12016-03-18 03:22:46135 "//rlz/*",
136
brettwbc44c0a92015-02-20 22:30:39137 #"//sandbox/*", # Medium-hard.
138 "//sdch/*",
sky1e8f9f862016-05-19 22:34:43139 "//services/*",
brettwbc44c0a92015-02-20 22:30:39140 "//skia/*",
141 "//sql/*",
142 "//storage/*",
brettwbc44c0a92015-02-20 22:30:39143 "//testing/*",
144
145 #"//third_party/*", # May not ever want this.
rouslan30b18292016-03-31 18:05:10146 "//third_party/hunspell/*",
rouslan30b18292016-03-31 18:05:10147 "//third_party/libaddressinput/*",
148 "//third_party/libphonenumber/*",
jbroman626eecf2015-12-03 18:59:00149 "//third_party/WebKit/Source/*",
brettwbc44c0a92015-02-20 22:30:39150 "//tools/*",
151
brettwb7f2c302015-12-08 01:29:21152 #"//ui/*", # Work left on Chromeos w/ use_ozone. Some parts of UI that work:
153 "//ui/accessibility/*",
154 "//ui/android/*",
155 "//ui/app_list/*",
xiyuan369cf0c2016-06-30 16:34:15156 "//ui/arc/*",
brettwb7f2c302015-12-08 01:29:21157 "//ui/aura/*",
158 "//ui/aura_extra/*",
159 "//ui/base/*",
160 "//ui/chromeos/*",
161 "//ui/compositor/*",
kylechar3e6b9772016-04-15 18:55:27162 "//ui/content_accelerators/*",
brettwb7f2c302015-12-08 01:29:21163 "//ui/display/*",
kylechar3e6b9772016-04-15 18:55:27164 "//ui/events/*",
brettwb7f2c302015-12-08 01:29:21165 "//ui/file_manager/*",
166 "//ui/gfx/*",
167 "//ui/gl/*",
168 "//ui/keyboard/*",
kylechar3e6b9772016-04-15 18:55:27169 "//ui/latency_info/*",
brettwb7f2c302015-12-08 01:29:21170 "//ui/login/*",
171 "//ui/message_center/*",
brettwb7f2c302015-12-08 01:29:21172 "//ui/mojo/*",
173 "//ui/native_theme/*",
kylechare2b20222016-04-14 20:58:33174 "//ui/ozone/*",
brettwb7f2c302015-12-08 01:29:21175 "//ui/platform_window/*",
176 "//ui/resources/*",
177 "//ui/shell_dialogs/*",
178 "//ui/snapshot/*",
179 "//ui/strings/*",
180 "//ui/surface/*",
181 "//ui/touch_selection/*",
182 "//ui/views/*",
183 "//ui/views_content_client/*",
184 "//ui/web_dialogs/*",
185 "//ui/webui/*",
186 "//ui/wm/*",
brettwbc44c0a92015-02-20 22:30:39187 "//url/*",
188 "//v8/*",
brettw0ead9772015-11-23 23:12:08189 "//win8/*",
brettwe75311d2015-02-17 23:56:46190]
brettwed99f7b2015-04-07 00:22:50191
192# These are the list of GN files that run exec_script. This whitelist exists
193# to force additional review for new uses of exec_script, which is strongly
brettwd385ecf2016-04-19 22:53:23194# discouraged.
195#
196# GYPI_TO_GN
197#
198# Most of these entries are for gypi_to_gn calls. We should not be adding new
199# calls to this script in the build (see //build/gypi_to_gn.py for detailed
200# advice). The only time you should be editing this list for gypi_to_gn
201# purposes is when moving an existing call to a different place.
202#
203# PLEASE READ
204#
205# You should almost never need to add new exec_script calls. exec_script is
206# slow, especially on Windows, and can cause confusing effects. Although
207# individually each call isn't slow or necessarily very confusing, at the scale
208# of our repo things get out of hand quickly. By strongly pushing back on all
209# additions, we keep the build fast and clean. If you think you need to add a
210# new call, please consider:
211#
212# - Do not use a script to check for the existance of a file or directory to
213# enable a different mode. Instead, use GN build args to enable or disable
214# functionality and set options. An example is checking for a file in the
215# src-internal repo to see if the corresponding src-internal feature should
216# be enabled. There are several things that can go wrong with this:
217#
218# - It's mysterious what causes some things to happen. Although in many cases
219# such behavior can be conveniently automatic, GN optimizes for explicit
220# and obvious behavior so people can more easily diagnose problems.
221#
222# - The user can't enable a mode for one build and not another. With GN build
223# args, the user can choose the exact configuration of multiple builds
224# using one checkout. But implicitly basing flags on the state of the
225# checkout, this functionality is broken.
226#
227# - It's easy to get stale files. If for example the user edits the gclient
228# to stop checking out src-internal (or any other optional thing), it's
229# easy to end up with stale files still mysteriously triggering build
230# conditions that are no longer appropriate (yes, this happens in real
231# life).
232#
233# - Do not use a script to iterate files in a directory (glob):
234#
235# - This has the same "stale file" problem as the above discussion. Various
236# operations can leave untracked files in the source tree which can cause
237# surprising effects.
238#
239# - It becomes impossible to use "git grep" to find where a certain file is
240# referenced. This operation is very common and people really do get
241# confused when things aren't listed.
242#
243# - It's easy to screw up. One common case is a build-time script that packs
244# up a directory. The author notices that the script isn't re-run when the
245# directory is updated, so adds a glob so all the files are listed as
246# inputs. This seems to work great... until a file is deleted. When a
thakis3e861de2016-06-14 14:24:01247# file is deleted, all the inputs the glob lists will still be up to date
brettwd385ecf2016-04-19 22:53:23248# and no command-lines will have been changed. The action will not be
249# re-run and the build will be broken. It is possible to get this correct
250# using glob, and it's possible to mess it up without glob, but globs make
251# this situation much easier to create. if the build always lists the
252# files and passes them to a script, it will always be correct.
dgn470951712015-04-07 10:37:47253
dpranke1cfa5312016-11-22 03:07:47254exec_script_whitelist =
255 build_dotfile_settings.exec_script_whitelist + [
256 # Whitelist entries for //build should go into
257 # //build/dotfile_settings.gni instead, so that they can be shared
258 # with other repos. The entries in this list should be only for files
259 # in the Chromium repo outside of //build.
260 "//android_webview/BUILD.gn",
261 "//build_overrides/build.gni",
262 "//chromeos/BUILD.gn",
dgn470951712015-04-07 10:37:47263
dpranke1cfa5312016-11-22 03:07:47264 # TODO(dgn): Layer violation but breaks the build otherwise, see
265 # https://crbug.com/474506.
266 "//clank/java/BUILD.gn",
267 "//clank/native/BUILD.gn",
brettw46134cb2016-09-02 23:53:18268
dpranke1cfa5312016-11-22 03:07:47269 "//jingle/BUILD.gn",
270 "//net/BUILD.gn",
271 "//remoting/host/installer/linux/BUILD.gn",
272 "//remoting/remoting_version.gni",
273 "//remoting/host/installer/win/generate_clsids.gni",
brettwde7b2652016-09-09 23:25:05274
dpranke1cfa5312016-11-22 03:07:47275 # TODO(dpranke): Get these from the appropriate repos instead.
276 "//third_party/angle/BUILD.gn",
277 "//third_party/angle/src/tests/BUILD.gn",
278 "//third_party/angle/src/vulkan_support/BUILD.gn",
279 "//third_party/catapult/tracing/BUILD.gn",
280 "//third_party/google_input_tools/inputview.gni",
281
282 # CLD2 should be removed soon, delete this when we do.
283 "//third_party/cld_2/BUILD.gn",
284 "//tools/grit/grit_rule.gni",
285
286 # Not gypi-to-gn.
287 "//google_apis/BUILD.gn",
288 "//printing/BUILD.gn",
289 ]