]> git.proxmox.com Git - rustc.git/blob - Cargo.toml
Merge tag 'debian/1.50.0+dfsg1-1_exp4' into debian/sid
[rustc.git] / Cargo.toml
1 [workspace]
2 members = [
3 "src/bootstrap",
4 "compiler/rustc",
5 "library/std",
6 "library/test",
7 "src/tools/cargotest",
8 "src/tools/clippy",
9 "src/tools/compiletest",
10 "src/tools/error_index_generator",
11 "src/tools/linkchecker",
12 "src/tools/lint-docs",
13 "src/tools/rustbook",
14 "src/tools/unstable-book-gen",
15 "src/tools/tidy",
16 "src/tools/tier-check",
17 "src/tools/build-manifest",
18 "src/tools/remote-test-client",
19 "src/tools/remote-test-server",
20 "src/tools/rust-installer",
21 "src/tools/rust-demangler",
22 "src/tools/cargo",
23 "src/tools/cargo/crates/credential/cargo-credential-1password",
24 "src/tools/cargo/crates/credential/cargo-credential-macos-keychain",
25 "src/tools/cargo/crates/credential/cargo-credential-wincred",
26 "src/tools/rustdoc",
27 "src/tools/rls",
28 "src/tools/rustfmt",
29 "src/tools/miri",
30 "src/tools/miri/cargo-miri",
31 "src/tools/rustdoc-themes",
32 "src/tools/unicode-table-generator",
33 "src/tools/expand-yaml-anchors",
34 ]
35
36 exclude = [
37 "build",
38 "compiler/rustc_codegen_cranelift",
39 # HACK(eddyb) This hardcodes the fact that our CI uses `/checkout/obj`.
40 "obj",
41 # The `x` binary is a thin wrapper that calls `x.py`, which initializes
42 # submodules, before which workspace members cannot be invoked because
43 # not all `Cargo.toml` files are available, so we exclude the `x` binary,
44 # so it can be invoked before the current checkout is set up.
45 "src/tools/x",
46 ]
47
48 [profile.release.package.compiler_builtins]
49 # The compiler-builtins crate cannot reference libcore, and it's own CI will
50 # verify that this is the case. This requires, however, that the crate is built
51 # without overflow checks and debug assertions. Forcefully disable debug
52 # assertions and overflow checks here which should ensure that even if these
53 # assertions are enabled for libstd we won't enable then for compiler_builtins
54 # which should ensure we still link everything correctly.
55 debug-assertions = false
56 overflow-checks = false
57
58 # For compiler-builtins we always use a high number of codegen units.
59 # The goal here is to place every single intrinsic into its own object
60 # file to avoid symbol clashes with the system libgcc if possible. Note
61 # that this number doesn't actually produce this many object files, we
62 # just don't create more than this number of object files.
63 #
64 # It's a bit of a bummer that we have to pass this here, unfortunately.
65 # Ideally this would be specified through an env var to Cargo so Cargo
66 # knows how many CGUs are for this specific crate, but for now
67 # per-crate configuration isn't specifiable in the environment.
68 codegen-units = 10000
69
70 # These dependencies of the standard library implement symbolication for
71 # backtraces on most platforms. Their debuginfo causes both linking to be slower
72 # (more data to chew through) and binaries to be larger without really all that
73 # much benefit. This section turns them all to down to have no debuginfo which
74 # helps to improve link times a little bit.
75 [profile.release.package]
76 addr2line.debug = 0
77 adler.debug = 0
78 gimli.debug = 0
79 miniz_oxide.debug = 0
80 object.debug = 0
81
82 # We want the RLS to use the version of Cargo that we've got vendored in this
83 # repository to ensure that the same exact version of Cargo is used by both the
84 # RLS and the Cargo binary itself. The RLS depends on Cargo as a git repository
85 # so we use a `[patch]` here to override the github repository with our local
86 # vendored copy.
87 [patch."https://github.com/rust-lang/cargo"]
88 cargo = { path = "src/tools/cargo" }
89
90 [patch."https://github.com/rust-lang/rustfmt"]
91 # Similar to Cargo above we want the RLS to use a vendored version of `rustfmt`
92 # that we're shipping as well (to ensure that the rustfmt in RLS and the
93 # `rustfmt` executable are the same exact version).
94 rustfmt-nightly = { path = "src/tools/rustfmt" }
95
96 [patch.crates-io]
97 # See comments in `src/tools/rustc-workspace-hack/README.md` for what's going on
98 # here
99 rustc-workspace-hack = { path = 'src/tools/rustc-workspace-hack' }
100
101 # See comments in `library/rustc-std-workspace-core/README.md` for what's going on
102 # here
103 rustc-std-workspace-core = { path = 'library/rustc-std-workspace-core' }
104 rustc-std-workspace-alloc = { path = 'library/rustc-std-workspace-alloc' }
105 rustc-std-workspace-std = { path = 'library/rustc-std-workspace-std' }
106
107 # This crate's integration with libstd is a bit wonky, so we use a submodule
108 # instead of a crates.io dependency. Make sure everything else in the repo is
109 # also using the submodule, however, so we can avoid duplicate copies of the
110 # source code for this crate.
111 backtrace = { path = "library/backtrace" }
112
113 [patch."https://github.com/rust-lang/rust-clippy"]
114 clippy_lints = { path = "src/tools/clippy/clippy_lints" }