Skip to content

Commit aa3fd28

Browse files
committed
Fix building rustdoc and clippy with jemalloc feature
1 parent ba24be5 commit aa3fd28

File tree

3 files changed

+6
-2
lines changed

3 files changed

+6
-2
lines changed

Cargo.lock

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -600,6 +600,7 @@ dependencies = [
600600
"serde_json",
601601
"tempfile",
602602
"termize",
603+
"tikv-jemalloc-sys",
603604
"toml 0.9.7",
604605
"ui_test",
605606
"walkdir",
@@ -4806,6 +4807,7 @@ dependencies = [
48064807
"stringdex",
48074808
"tempfile",
48084809
"threadpool",
4810+
"tikv-jemalloc-sys",
48094811
"tracing",
48104812
"tracing-subscriber",
48114813
"tracing-tree",

src/librustdoc/Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ smallvec = "1.8.1"
2424
stringdex = "=0.0.2"
2525
tempfile = "3"
2626
threadpool = "1.8.1"
27+
tikv-jemalloc-sys = { version = "0.6.1", optional = true, features = ['override_allocator_on_supported_platforms'] }
2728
tracing = "0.1"
2829
tracing-tree = "0.3.0"
2930
unicode-segmentation = "1.9"
@@ -42,7 +43,7 @@ minifier = { version = "0.3.2", default-features = false }
4243
expect-test = "1.4.0"
4344

4445
[features]
45-
jemalloc = []
46+
jemalloc = ["dep:tikv-jemalloc-sys"]
4647

4748
[package.metadata.rust-analyzer]
4849
rustc_private = true

src/tools/clippy/Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ tempfile = { version = "3.20", optional = true }
3131
termize = "0.2"
3232
color-print = "0.3.4"
3333
anstream = "0.6.18"
34+
tikv-jemalloc-sys = { version = "0.6.1", optional = true, features = ['override_allocator_on_supported_platforms'] }
3435

3536
[dev-dependencies]
3637
cargo_metadata = "0.18.1"
@@ -56,7 +57,7 @@ rustc_tools_util = { path = "rustc_tools_util", version = "0.4.2" }
5657
[features]
5758
integration = ["dep:tempfile"]
5859
internal = ["dep:clippy_lints_internal", "dep:tempfile"]
59-
jemalloc = []
60+
jemalloc = ["dep:tikv-jemalloc-sys"]
6061

6162
[package.metadata.rust-analyzer]
6263
# This package uses #[feature(rustc_private)]

0 commit comments

Comments
 (0)