Skip to content

Commit 05cb29e

Browse files
committed
Auto merge of #54051 - kennytm:rollup, r=kennytm
Rollup of 10 pull requests Successful merges: - #53315 (use `NonZeroU32` in `newtype_index!`macro, change syntax) - #53932 ([NLL] Remove base_place) - #53942 (Rewrite `precompute_borrows_out_of_scope` for fewer hash table lookups.) - #53973 (Have rust-lldb look for the rust-enabled lldb) - #53981 (Implement initializer() for FileDesc) - #53987 (rustbuild: allow configuring llvm version suffix) - #53993 (rustc_resolve: don't record uniform_paths canaries as reexports.) - #54007 (crates that provide a `panic_handler` are exempt from the `unused_extern_crates` lint) - #54040 (update books for next release) - #54050 (Update `petgraph` dependency to 0.4.13 to fix build with nightly)
2 parents ff59ab1 + 51c3879 commit 05cb29e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

78 files changed

+553
-342
lines changed

config.toml.example

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,10 @@
8282
# passed to prefer linking to shared libraries.
8383
#link-shared = false
8484

85+
# When building llvm, this configures what is being appended to the version.
86+
# If absent, we let the version as-is.
87+
#version-suffix = "-rust"
88+
8589
# On MSVC you can compile LLVM with clang-cl, but the test suite doesn't pass
8690
# with clang-cl, so this is special in that it only compiles LLVM with clang-cl
8791
#clang-cl = '/path/to/clang-cl.exe'

src/Cargo.lock

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ dependencies = [
138138
"lazy_static 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
139139
"libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
140140
"num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
141-
"petgraph 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)",
141+
"petgraph 0.4.13 (registry+https://github.com/rust-lang/crates.io-index)",
142142
"pretty_assertions 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
143143
"serde 1.0.75 (registry+https://github.com/rust-lang/crates.io-index)",
144144
"serde_derive 1.0.75 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1471,7 +1471,7 @@ dependencies = [
14711471

14721472
[[package]]
14731473
name = "petgraph"
1474-
version = "0.4.12"
1474+
version = "0.4.13"
14751475
source = "registry+https://github.com/rust-lang/crates.io-index"
14761476
dependencies = [
14771477
"fixedbitset 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -3243,7 +3243,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
32433243
"checksum percent-encoding 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "31010dd2e1ac33d5b46a5b413495239882813e0369f8ed8a5e266f173602f831"
32443244
"checksum pest 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)" = "0fce5d8b5cc33983fc74f78ad552b5522ab41442c4ca91606e4236eb4b5ceefc"
32453245
"checksum pest_derive 1.0.7 (registry+https://github.com/rust-lang/crates.io-index)" = "ab94faafeb93f4c5e3ce81ca0e5a779529a602ad5d09ae6d21996bfb8b6a52bf"
3246-
"checksum petgraph 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)" = "8b30dc85588cd02b9b76f5e386535db546d21dc68506cff2abebee0b6445e8e4"
3246+
"checksum petgraph 0.4.13 (registry+https://github.com/rust-lang/crates.io-index)" = "9c3659d1ee90221741f65dd128d9998311b0e40c5d3c23a62445938214abce4f"
32473247
"checksum phf 0.7.22 (registry+https://github.com/rust-lang/crates.io-index)" = "7d37a244c75a9748e049225155f56dbcb98fe71b192fd25fd23cb914b5ad62f2"
32483248
"checksum phf_codegen 0.7.22 (registry+https://github.com/rust-lang/crates.io-index)" = "4e4048fe7dd7a06b8127ecd6d3803149126e9b33c7558879846da3a63f734f2b"
32493249
"checksum phf_generator 0.7.22 (registry+https://github.com/rust-lang/crates.io-index)" = "05a079dd052e7b674d21cb31cbb6c05efd56a2cd2827db7692e2f1a507ebd998"

src/bootstrap/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ serde_json = "1.0.2"
4747
toml = "0.4"
4848
lazy_static = "0.2"
4949
time = "0.1"
50-
petgraph = "0.4.12"
50+
petgraph = "0.4.13"
5151

5252
[dev-dependencies]
5353
pretty_assertions = "0.5"

src/bootstrap/config.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@ pub struct Config {
8686
pub llvm_targets: Option<String>,
8787
pub llvm_experimental_targets: String,
8888
pub llvm_link_jobs: Option<u32>,
89+
pub llvm_version_suffix: Option<String>,
8990

9091
pub lld_enabled: bool,
9192
pub lldb_enabled: bool,
@@ -256,6 +257,7 @@ struct Llvm {
256257
experimental_targets: Option<String>,
257258
link_jobs: Option<u32>,
258259
link_shared: Option<bool>,
260+
version_suffix: Option<String>,
259261
clang_cl: Option<String>
260262
}
261263

@@ -516,6 +518,7 @@ impl Config {
516518
config.llvm_experimental_targets = llvm.experimental_targets.clone()
517519
.unwrap_or("WebAssembly;RISCV".to_string());
518520
config.llvm_link_jobs = llvm.link_jobs;
521+
config.llvm_version_suffix = llvm.version_suffix.clone();
519522
config.llvm_clang_cl = llvm.clang_cl.clone();
520523
}
521524

src/bootstrap/dist.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2056,7 +2056,8 @@ impl Step for Lldb {
20562056
drop(fs::remove_dir_all(&image));
20572057

20582058
// Prepare the image directory
2059-
let dst = image.join("bin");
2059+
let root = image.join("lib/rustlib").join(&*target);
2060+
let dst = root.join("bin");
20602061
t!(fs::create_dir_all(&dst));
20612062
for program in &["lldb", "lldb-argdumper", "lldb-mi", "lldb-server"] {
20622063
let exe = bindir.join(exe(program, &target));
@@ -2065,7 +2066,7 @@ impl Step for Lldb {
20652066

20662067
// The libraries.
20672068
let libdir = builder.llvm_out(target).join("lib");
2068-
let dst = image.join("lib");
2069+
let dst = root.join("lib");
20692070
t!(fs::create_dir_all(&dst));
20702071
for entry in t!(fs::read_dir(&libdir)) {
20712072
let entry = entry.unwrap();
@@ -2093,7 +2094,7 @@ impl Step for Lldb {
20932094
let entry = t!(entry);
20942095
if let Ok(name) = entry.file_name().into_string() {
20952096
if name.starts_with("python") {
2096-
let dst = image.join(libdir_name)
2097+
let dst = root.join(libdir_name)
20972098
.join(entry.file_name());
20982099
t!(fs::create_dir_all(&dst));
20992100
builder.cp_r(&entry.path(), &dst);

src/bootstrap/native.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -239,6 +239,10 @@ impl Step for Llvm {
239239
cfg.define("LLVM_NATIVE_BUILD", builder.llvm_out(builder.config.build).join("build"));
240240
}
241241

242+
if let Some(ref suffix) = builder.config.llvm_version_suffix {
243+
cfg.define("LLVM_VERSION_SUFFIX", suffix);
244+
}
245+
242246
if let Some(ref python) = builder.config.python {
243247
cfg.define("PYTHON_EXECUTABLE", python);
244248
}

src/doc/nomicon

src/doc/reference

0 commit comments

Comments
 (0)