]> git.lizzy.rs Git - rust.git/blob - config.toml.example
incr.comp.: Remove default serialization implementations for things in rustc::hir...
[rust.git] / config.toml.example
1 # Sample TOML configuration file for building Rust.
2 #
3 # To configure rustbuild, copy this file to the directory from which you will be
4 # running the build, and name it config.toml.
5 #
6 # All options are commented out by default in this file, and they're commented
7 # out with their default values. The build system by default looks for
8 # `config.toml` in the current directory of a build for build configuration, but
9 # a custom configuration file can also be specified with `--config` to the build
10 # system.
11
12 # =============================================================================
13 # Tweaking how LLVM is compiled
14 # =============================================================================
15 [llvm]
16
17 # Indicates whether rustc will support compilation with LLVM
18 # note: rustc does not compile without LLVM at the moment
19 #enabled = true
20
21 # Indicates whether the LLVM build is a Release or Debug build
22 #optimize = true
23
24 # Indicates whether an LLVM Release build should include debug info
25 #release-debuginfo = false
26
27 # Indicates whether the LLVM assertions are enabled or not
28 #assertions = false
29
30 # Indicates whether ccache is used when building LLVM
31 #ccache = false
32 # or alternatively ...
33 #ccache = "/path/to/ccache"
34
35 # If an external LLVM root is specified, we automatically check the version by
36 # default to make sure it's within the range that we're expecting, but setting
37 # this flag will indicate that this version check should not be done.
38 #version-check = true
39
40 # Link libstdc++ statically into the librustc_llvm instead of relying on a
41 # dynamic version to be available.
42 #static-libstdcpp = false
43
44 # Tell the LLVM build system to use Ninja instead of the platform default for
45 # the generated build system. This can sometimes be faster than make, for
46 # example.
47 #ninja = false
48
49 # LLVM targets to build support for.
50 # Note: this is NOT related to Rust compilation targets. However, as Rust is
51 # dependent on LLVM for code generation, turning targets off here WILL lead to
52 # the resulting rustc being unable to compile for the disabled architectures.
53 # Also worth pointing out is that, in case support for new targets are added to
54 # LLVM, enabling them here doesn't mean Rust is automatically gaining said
55 # support. You'll need to write a target specification at least, and most
56 # likely, teach rustc about the C ABI of the target. Get in touch with the
57 # Rust team and file an issue if you need assistance in porting!
58 #targets = "X86;ARM;AArch64;Mips;PowerPC;SystemZ;JSBackend;MSP430;Sparc;NVPTX;Hexagon"
59
60 # LLVM experimental targets to build support for. These targets are specified in
61 # the same format as above, but since these targets are experimental, they are
62 # not built by default and the experimental Rust compilation targets that depend
63 # on them will not work unless the user opts in to building them. Possible
64 # experimental LLVM targets include WebAssembly for the
65 # wasm32-experimental-emscripten Rust target.
66 #experimental-targets = ""
67
68 # Cap the number of parallel linker invocations when compiling LLVM.
69 # This can be useful when building LLVM with debug info, which significantly
70 # increases the size of binaries and consequently the memory required by
71 # each linker process.
72 # If absent or 0, linker invocations are treated like any other job and
73 # controlled by rustbuild's -j parameter.
74 #link-jobs = 0
75
76 # When invoking `llvm-config` this configures whether the `--shared` argument is
77 # passed to prefer linking to shared libraries.
78 #link-shared = false
79
80 # =============================================================================
81 # General build configuration options
82 # =============================================================================
83 [build]
84
85 # Build triple for the original snapshot compiler. This must be a compiler that
86 # nightlies are already produced for. The current platform must be able to run
87 # binaries of this build triple and the nightly will be used to bootstrap the
88 # first compiler.
89 #build = "x86_64-unknown-linux-gnu"    # defaults to your host platform
90
91 # In addition to the build triple, other triples to produce full compiler
92 # toolchains for. Each of these triples will be bootstrapped from the build
93 # triple and then will continue to bootstrap themselves. This platform must
94 # currently be able to run all of the triples provided here.
95 #host = ["x86_64-unknown-linux-gnu"]   # defaults to just the build triple
96
97 # In addition to all host triples, other triples to produce the standard library
98 # for. Each host triple will be used to produce a copy of the standard library
99 # for each target triple.
100 #target = ["x86_64-unknown-linux-gnu"] # defaults to just the build triple
101
102 # Instead of downloading the src/stage0.txt version of Cargo specified, use
103 # this Cargo binary instead to build all Rust code
104 #cargo = "/path/to/bin/cargo"
105
106 # Instead of downloading the src/stage0.txt version of the compiler
107 # specified, use this rustc binary instead as the stage0 snapshot compiler.
108 #rustc = "/path/to/bin/rustc"
109
110 # Flag to specify whether any documentation is built. If false, rustdoc and
111 # friends will still be compiled but they will not be used to generate any
112 # documentation.
113 #docs = true
114
115 # Indicate whether the compiler should be documented in addition to the standard
116 # library and facade crates.
117 #compiler-docs = false
118
119 # Indicate whether submodules are managed and updated automatically.
120 #submodules = true
121
122 # The path to (or name of) the GDB executable to use. This is only used for
123 # executing the debuginfo test suite.
124 #gdb = "gdb"
125
126 # The node.js executable to use. Note that this is only used for the emscripten
127 # target when running tests, otherwise this can be omitted.
128 #nodejs = "node"
129
130 # Python interpreter to use for various tasks throughout the build, notably
131 # rustdoc tests, the lldb python interpreter, and some dist bits and pieces.
132 # Note that Python 2 is currently required.
133 #python = "python2.7"
134
135 # Force Cargo to check that Cargo.lock describes the precise dependency
136 # set that all the Cargo.toml files create, instead of updating it.
137 #locked-deps = false
138
139 # Indicate whether the vendored sources are used for Rust dependencies or not
140 #vendor = false
141
142 # Typically the build system will build the rust compiler twice. The second
143 # compiler, however, will simply use its own libraries to link against. If you
144 # would rather to perform a full bootstrap, compiling the compiler three times,
145 # then you can set this option to true. You shouldn't ever need to set this
146 # option to true.
147 #full-bootstrap = false
148
149 # Enable a build of the extended rust tool set which is not only the compiler
150 # but also tools such as Cargo. This will also produce "combined installers"
151 # which are used to install Rust and Cargo together. This is disabled by
152 # default.
153 #extended = false
154
155 # Verbosity level: 0 == not verbose, 1 == verbose, 2 == very verbose
156 #verbose = 0
157
158 # Build the sanitizer runtimes
159 #sanitizers = false
160
161 # Build the profiler runtime
162 #profiler = false
163
164 # Indicates whether the OpenSSL linked into Cargo will be statically linked or
165 # not. If static linkage is specified then the build system will download a
166 # known-good version of OpenSSL, compile it, and link it to Cargo.
167 #openssl-static = false
168
169 # Run the build with low priority, by setting the process group's "nice" value
170 # to +10 on Unix platforms, and by using a "low priority" job object on Windows.
171 #low-priority = false
172
173 # Arguments passed to the `./configure` script, used during distcheck. You
174 # probably won't fill this in but rather it's filled in by the `./configure`
175 # script.
176 #configure-args = []
177
178 # Indicates that a local rebuild is occurring instead of a full bootstrap,
179 # essentially skipping stage0 as the local compiler is recompiling itself again.
180 #local-rebuild = false
181
182 # =============================================================================
183 # General install configuration options
184 # =============================================================================
185 [install]
186
187 # Instead of installing to /usr/local, install to this path instead.
188 #prefix = "/usr/local"
189
190 # Where to install system configuration files
191 # If this is a relative path, it will get installed in `prefix` above
192 #sysconfdir = "/etc"
193
194 # Where to install documentation in `prefix` above
195 #docdir = "share/doc/rust"
196
197 # Where to install binaries in `prefix` above
198 #bindir = "bin"
199
200 # Where to install libraries in `prefix` above
201 #libdir = "lib"
202
203 # Where to install man pages in `prefix` above
204 #mandir = "share/man"
205
206 # Where to install data in `prefix` above (currently unused)
207 #datadir = "share"
208
209 # Where to install additional info in `prefix` above (currently unused)
210 #infodir = "share/info"
211
212 # Where to install local state (currently unused)
213 # If this is a relative path, it will get installed in `prefix` above
214 #localstatedir = "/var/lib"
215
216 # =============================================================================
217 # Options for compiling Rust code itself
218 # =============================================================================
219 [rust]
220
221 # Indicates that the build should be optimized for debugging Rust. Note that
222 # this is typically not what you want as it takes an incredibly large amount of
223 # time to have a debug-mode rustc compile any code (notably libstd). If this
224 # value is set to `true` it will affect a number of configuration options below
225 # as well, if unconfigured.
226 #debug = false
227
228 # Whether or not to optimize the compiler and standard library
229 # Note: the slowness of the non optimized compiler compiling itself usually
230 #       outweighs the time gains in not doing optimizations, therefore a
231 #       full bootstrap takes much more time with optimize set to false.
232 #optimize = true
233
234 # Number of codegen units to use for each compiler invocation. A value of 0
235 # means "the number of cores on this machine", and 1+ is passed through to the
236 # compiler.
237 #codegen-units = 1
238
239 # Whether or not debug assertions are enabled for the compiler and standard
240 # library. Also enables compilation of debug! and trace! logging macros.
241 #debug-assertions = false
242
243 # Whether or not debuginfo is emitted
244 #debuginfo = false
245
246 # Whether or not line number debug information is emitted
247 #debuginfo-lines = false
248
249 # Whether or not to only build debuginfo for the standard library if enabled.
250 # If enabled, this will not compile the compiler with debuginfo, just the
251 # standard library.
252 #debuginfo-only-std = false
253
254 # Whether or not jemalloc is built and enabled
255 #use-jemalloc = true
256
257 # Whether or not jemalloc is built with its debug option set
258 #debug-jemalloc = false
259
260 # Whether or not `panic!`s generate backtraces (RUST_BACKTRACE)
261 #backtrace = true
262
263 # The default linker that will be hard-coded into the generated compiler for
264 # targets that don't specify linker explicitly in their target specifications.
265 # Note that this is not the linker used to link said compiler.
266 #default-linker = "cc"
267
268 # The "channel" for the Rust build to produce. The stable/beta channels only
269 # allow using stable features, whereas the nightly and dev channels allow using
270 # nightly features
271 #channel = "dev"
272
273 # By default the `rustc` executable is built with `-Wl,-rpath` flags on Unix
274 # platforms to ensure that the compiler is usable by default from the build
275 # directory (as it links to a number of dynamic libraries). This may not be
276 # desired in distributions, for example.
277 #rpath = true
278
279 # Suppresses extraneous output from tests to ensure the output of the test
280 # harness is relatively clean.
281 #quiet-tests = false
282
283 # Flag indicating whether tests are compiled with optimizations (the -O flag) or
284 # with debuginfo (the -g flag)
285 #optimize-tests = true
286 #debuginfo-tests = true
287
288 # Flag indicating whether codegen tests will be run or not. If you get an error
289 # saying that the FileCheck executable is missing, you may want to disable this.
290 #codegen-tests = true
291
292 # Flag indicating whether git info will be retrieved from .git automatically.
293 # Having the git information can cause a lot of rebuilds during development.
294 # Note: If this attribute is not explicity set (e.g. if left commented out) it
295 # will default to true if channel = "dev", but will default to false otherwise.
296 #ignore-git = true
297
298 # When creating source tarballs whether or not to create a source tarball.
299 #dist-src = false
300
301 # Whether to also run the Miri tests suite when running tests.
302 # As a side-effect also generates MIR for all libraries.
303 #test-miri = false
304
305 # =============================================================================
306 # Options for specific targets
307 #
308 # Each of the following options is scoped to the specific target triple in
309 # question and is used for determining how to compile each target.
310 # =============================================================================
311 [target.x86_64-unknown-linux-gnu]
312
313 # C compiler to be used to compiler C code. Note that the
314 # default value is platform specific, and if not specified it may also depend on
315 # what platform is crossing to what platform.
316 #cc = "cc"
317
318 # C++ compiler to be used to compiler C++ code (e.g. LLVM and our LLVM shims).
319 # This is only used for host targets.
320 #cxx = "c++"
321
322 # Archiver to be used to assemble static libraries compiled from C/C++ code.
323 # Note: an absolute path should be used, otherwise LLVM build will break.
324 #ar = "ar"
325
326 # Linker to be used to link Rust code. Note that the
327 # default value is platform specific, and if not specified it may also depend on
328 # what platform is crossing to what platform.
329 #linker = "cc"
330
331 # Path to the `llvm-config` binary of the installation of a custom LLVM to link
332 # against. Note that if this is specifed we don't compile LLVM at all for this
333 # target.
334 #llvm-config = "../path/to/llvm/root/bin/llvm-config"
335
336 # Path to the custom jemalloc static library to link into the standard library
337 # by default. This is only used if jemalloc is still enabled above
338 #jemalloc = "/path/to/jemalloc/libjemalloc_pic.a"
339
340 # If this target is for Android, this option will be required to specify where
341 # the NDK for the target lives. This is used to find the C compiler to link and
342 # build native code.
343 #android-ndk = "/path/to/ndk"
344
345 # Force static or dynamic linkage of the standard library for this target. If
346 # this target is a host for rustc, this will also affect the linkage of the
347 # compiler itself. This is useful for building rustc on targets that normally
348 # only use static libraries. If unset, the target's default linkage is used.
349 #crt-static = false
350
351 # The root location of the MUSL installation directory. The library directory
352 # will also need to contain libunwind.a for an unwinding implementation. Note
353 # that this option only makes sense for MUSL targets that produce statically
354 # linked binaries
355 #musl-root = "..."
356
357 # Used in testing for configuring where the QEMU images are located, you
358 # probably don't want to use this.
359 #qemu-rootfs = "..."
360
361 # =============================================================================
362 # Distribution options
363 #
364 # These options are related to distribution, mostly for the Rust project itself.
365 # You probably won't need to concern yourself with any of these options
366 # =============================================================================
367 [dist]
368
369 # This is the folder of artifacts that the build system will sign. All files in
370 # this directory will be signed with the default gpg key using the system `gpg`
371 # binary. The `asc` and `sha256` files will all be output into the standard dist
372 # output folder (currently `build/dist`)
373 #
374 # This folder should be populated ahead of time before the build system is
375 # invoked.
376 #sign-folder = "path/to/folder/to/sign"
377
378 # This is a file which contains the password of the default gpg key. This will
379 # be passed to `gpg` down the road when signing all files in `sign-folder`
380 # above. This should be stored in plaintext.
381 #gpg-password-file = "path/to/gpg/password"
382
383 # The remote address that all artifacts will eventually be uploaded to. The
384 # build system generates manifests which will point to these urls, and for the
385 # manifests to be correct they'll have to have the right URLs encoded.
386 #
387 # Note that this address should not contain a trailing slash as file names will
388 # be appended to it.
389 #upload-addr = "https://example.com/folder"
390
391 # Whether to build a plain source tarball to upload
392 # We disable that on Windows not to override the one already uploaded on S3
393 # as the one built on Windows will contain backslashes in paths causing problems
394 # on linux
395 #src-tarball = true