Lines Matching +full:default +full:- +full:build
10 * For Chromium and Chromium-based projects, there is a script in
15 * For Fuchsia in-tree development, run `fx gn ...` which will find the right
20 ## Setting up a build
22 Unlike some other build systems, with GN you set up your own build directories
26 Once you set up a build directory, the Ninja files will be automatically
27 regenerated if they're out of date when you build in that directory so you
28 should not have to re-run GN.
30 To make a build directory:
36 ## Passing build arguments
38 Set build arguments on your build directory by running:
44 This will bring up an editor. Type build args into that file like this:
51 The available variables will depend on your build (this example is from
52 Chromium). You can see the list of available arguments and their default values
56 gn args --list out/my_build
59 on the command line. Note that you have to specify the build directory
61 to the build.
63 Chrome developers can also read the [Chrome-specific build
64 configuration](http://www.chromium.org/developers/gn-build-configuration)
67 ## Cross-compiling to a target OS or architecture
69 Run `gn args out/Default` (substituting your build directory as needed) and
70 add one or more of the following lines for common cross-compiling options.
83 ## Step-by-step
85 ### Adding a build file
91 `tutorial.cc` file that's not hooked up to the build. Create a new `BUILD.gn`
102 Now we just need to tell the build about this new target. Open the `BUILD.gn`
108 the `simple_build/BUILD.gn` file, but it usually doesn't make a lot of sense to
129 ninja -C out tutorial
136 unique. To build one of these, you can pass the label with its path (but no leading
140 ninja -C out some/path/to/target:my_target
146 [examples/simple_build/BUILD.gn](../examples/simple_build/BUILD.gn). There is a
198 the current BUILD.gn file.
205 ninja -C out hello
209 Note that you **didn't** need to re-run GN. GN will automatically rebuild
210 the ninja files when any build file has changed. You know this happens
232 # Note "+=" here is usually required, see "default configs" below.
254 ### Default configs
256 The build configuration will set up some settings that apply to every target by
257 default. These will normally be set as a default list of configs. You can see
270 ["//build:compiler_defaults", "//build:executable_ldconfig"]
274 Targets can modify this list to change their defaults. For example, the build
275 setup might turn off exceptions by default by adding a `no_exceptions` config,
276 but a target might re-enable them by replacing it with a different one:
281 configs -= [ "//build:no_exceptions" ] # Remove global default.
282 configs += [ "//build:exceptions" ] # Replace with a different one.
294 ## Add a new build argument
296 You declare which arguments you accept and specify default values via
315 doing. Use `-v` for this.
323 gn desc out/Default //foo/bar:say_hello
331 > gn desc out/Default //foo/bar:say_hello defines --blame
334 (Added by //foo/bar/BUILD.gn:12)
341 gn desc out/Default //base:base_i18n deps --tree