Skip to content

Commit 37c29b8

Browse files
committed
Use sysroot crates maximally in rustc_codegen_gcc.
This shrinks `compiler/rustc_codegen_gcc/Cargo.lock` quite a bit. The only remaining dependencies in `compiler/rustc_codegen_gcc/Cargo.lock` are `gccjit`, `lang_tester`, and `boml`, all of which aren't used in any other compiler crates. The commit also reorders and adds comments to the `extern crate` items so they match those in miri.
1 parent f1d136b commit 37c29b8

File tree

3 files changed

+8
-188
lines changed

3 files changed

+8
-188
lines changed

Cargo.lock

Lines changed: 0 additions & 176 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -23,21 +23,11 @@ default = ["master"]
2323

2424
[dependencies]
2525
gccjit = "2.1"
26-
2726
# Local copy.
2827
#gccjit = { path = "../gccjit.rs" }
2928

30-
object = { version = "0.30.1", default-features = false, features = [
31-
"std",
32-
"read",
33-
] }
34-
smallvec = { version = "1.6.1", features = ["union", "may_dangle"] }
35-
# TODO(antoyo): make tempfile optional.
36-
tempfile = "3.7.1"
37-
3829
[dev-dependencies]
3930
lang_tester = "0.8.0"
40-
tempfile = "3.1.0"
4131
boml = "0.3.1"
4232

4333
[profile.dev]

src/lib.rs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,14 @@
2424
#![deny(clippy::pattern_type_mismatch)]
2525
#![allow(clippy::needless_lifetimes)]
2626

27+
// Some "regular" crates we want to share with rustc
28+
extern crate object;
29+
extern crate smallvec;
30+
extern crate tempfile;
31+
#[macro_use]
32+
extern crate tracing;
33+
34+
// The rustc crates we need
2735
extern crate rustc_apfloat;
2836
extern crate rustc_ast;
2937
extern crate rustc_attr;
@@ -42,8 +50,6 @@ extern crate rustc_middle;
4250
extern crate rustc_session;
4351
extern crate rustc_span;
4452
extern crate rustc_target;
45-
#[macro_use]
46-
extern crate tracing;
4753

4854
// This prevents duplicating functions and statics that are already part of the host rustc process.
4955
#[allow(unused_extern_crates)]

0 commit comments

Comments
 (0)