Auto merge of #112282 - matthiaskrgr:rollup-1g9w02p, r=matthiaskrgr
Rollup of 3 pull requests Successful merges: - #112247 (rust-lld: add rpath entry to the correct `lib` folder) - #112274 (Migrate GUI colors test to original CSS color format) - #112277 (Don't require the output from libtest to be valid UTF-8) Failed merges: - #112251 (rustdoc: convert `if let Some()` that always matches to variable) r? `@ghost` `@rustbot` modify labels: rollup
This commit is contained in:
commit
101fa903bb
@ -834,6 +834,31 @@ impl Step for Lld {
|
||||
}
|
||||
}
|
||||
|
||||
// LLD is built as an LLVM tool, but is distributed outside of the `llvm-tools` component,
|
||||
// which impacts where it expects to find LLVM's shared library. This causes #80703.
|
||||
//
|
||||
// LLD is distributed at "$root/lib/rustlib/$host/bin/rust-lld", but the `libLLVM-*.so` it
|
||||
// needs is distributed at "$root/lib". The default rpath of "$ORIGIN/../lib" points at the
|
||||
// lib path for LLVM tools, not the one for rust binaries.
|
||||
//
|
||||
// (The `llvm-tools` component copies the .so there for the other tools, and with that
|
||||
// component installed, one can successfully invoke `rust-lld` directly without rustup's
|
||||
// `LD_LIBRARY_PATH` overrides)
|
||||
//
|
||||
if builder.config.rpath_enabled(target)
|
||||
&& util::use_host_linker(target)
|
||||
&& builder.config.llvm_link_shared()
|
||||
&& target.contains("linux")
|
||||
{
|
||||
// So we inform LLD where it can find LLVM's libraries by adding an rpath entry to the
|
||||
// expected parent `lib` directory.
|
||||
//
|
||||
// Be careful when changing this path, we need to ensure it's quoted or escaped:
|
||||
// `$ORIGIN` would otherwise be expanded when the `LdFlags` are passed verbatim to
|
||||
// cmake.
|
||||
ldflags.push_all("-Wl,-rpath,'$ORIGIN/../../../'");
|
||||
}
|
||||
|
||||
configure_cmake(builder, target, &mut cfg, true, ldflags, &[]);
|
||||
configure_llvm(builder, target, &mut cfg);
|
||||
|
||||
|
@ -88,10 +88,10 @@ impl<'a> Renderer<'a> {
|
||||
}
|
||||
|
||||
fn render_all(mut self) {
|
||||
let mut line = String::new();
|
||||
let mut line = Vec::new();
|
||||
loop {
|
||||
line.clear();
|
||||
match self.stdout.read_line(&mut line) {
|
||||
match self.stdout.read_until(b'\n', &mut line) {
|
||||
Ok(_) => {}
|
||||
Err(err) if err.kind() == std::io::ErrorKind::UnexpectedEof => break,
|
||||
Err(err) => panic!("failed to read output of test runner: {err}"),
|
||||
@ -100,12 +100,13 @@ impl<'a> Renderer<'a> {
|
||||
break;
|
||||
}
|
||||
|
||||
match serde_json::from_str(&line) {
|
||||
match serde_json::from_slice(&line) {
|
||||
Ok(parsed) => self.render_message(parsed),
|
||||
Err(_err) => {
|
||||
// Handle non-JSON output, for example when --nocapture is passed.
|
||||
print!("{line}");
|
||||
let _ = std::io::stdout().flush();
|
||||
let mut stdout = std::io::stdout();
|
||||
stdout.write_all(&line).unwrap();
|
||||
let _ = stdout.flush();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1 +1 @@
|
||||
0.16.5
|
||||
0.16.6
|
@ -73,16 +73,16 @@ define-function: (
|
||||
|
||||
call-function: ("check-colors", {
|
||||
"theme": "ayu",
|
||||
"color": "rgb(197, 197, 197)",
|
||||
"background": "rgb(20, 25, 31)",
|
||||
"color": "#c5c5c5",
|
||||
"background": "#14191f",
|
||||
})
|
||||
call-function: ("check-colors", {
|
||||
"theme": "dark",
|
||||
"color": "rgb(221, 221, 221)",
|
||||
"background": "rgb(80, 80, 80)",
|
||||
"color": "#ddd",
|
||||
"background": "#505050",
|
||||
})
|
||||
call-function: ("check-colors", {
|
||||
"theme": "light",
|
||||
"color": "rgb(0, 0, 0)",
|
||||
"background": "rgb(245, 245, 245)",
|
||||
"color": "black",
|
||||
"background": "#F5F5F5",
|
||||
})
|
||||
|
Loading…
x
Reference in New Issue
Block a user