From dd62b3568394ee83ca9b47089b30489e46af6cf2 Mon Sep 17 00:00:00 2001 From: Josh Stone Date: Thu, 23 Apr 2020 10:51:59 -0700 Subject: [PATCH 1/5] Update to 1.43.0. --- .gitignore | 8 + 0001-Drop-cfg-bootstrap-code.patch | 25 --- ...0123-ensure-llvm-is-in-the-link-path.patch | 210 ++++++++++++++++++ ...-pr70163-prepare-for-llvm-10-upgrade.patch | 175 +++++++++++++++ ...0591-ensure-llvm-is-in-the-link-path.patch | 40 ++++ rust.spec | 41 ++-- sources | 2 +- sources-bootstrap | 16 +- 8 files changed, 463 insertions(+), 54 deletions(-) delete mode 100644 0001-Drop-cfg-bootstrap-code.patch create mode 100644 rust-pr70123-ensure-llvm-is-in-the-link-path.patch create mode 100644 rust-pr70163-prepare-for-llvm-10-upgrade.patch create mode 100644 rust-pr70591-ensure-llvm-is-in-the-link-path.patch diff --git a/.gitignore b/.gitignore index 8c01968..2e5822a 100644 --- a/.gitignore +++ b/.gitignore @@ -261,3 +261,11 @@ /rust-1.41.1-powerpc64-unknown-linux-gnu.tar.xz /rust-1.41.1-s390x-unknown-linux-gnu.tar.xz /rust-1.41.1-x86_64-unknown-linux-gnu.tar.xz +/rustc-1.43.0-src.tar.xz +/rust-1.42.0-aarch64-unknown-linux-gnu.tar.xz +/rust-1.42.0-armv7-unknown-linux-gnueabihf.tar.xz +/rust-1.42.0-i686-unknown-linux-gnu.tar.xz +/rust-1.42.0-powerpc64le-unknown-linux-gnu.tar.xz +/rust-1.42.0-powerpc64-unknown-linux-gnu.tar.xz +/rust-1.42.0-s390x-unknown-linux-gnu.tar.xz +/rust-1.42.0-x86_64-unknown-linux-gnu.tar.xz diff --git a/0001-Drop-cfg-bootstrap-code.patch b/0001-Drop-cfg-bootstrap-code.patch deleted file mode 100644 index 3d8f202..0000000 --- a/0001-Drop-cfg-bootstrap-code.patch +++ /dev/null @@ -1,25 +0,0 @@ -From 31dcdc9e13c324d33a18db3aed7f4b3208ff3744 Mon Sep 17 00:00:00 2001 -From: Mark Rousskov -Date: Fri, 31 Jan 2020 12:30:17 -0500 -Subject: [PATCH] Drop cfg(bootstrap) code - ---- - src/bootstrap/lib.rs | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/bootstrap/lib.rs b/src/bootstrap/lib.rs -index 1fee3fd9ac1d..637323331f58 100644 ---- a/src/bootstrap/lib.rs -+++ b/src/bootstrap/lib.rs -@@ -1026,7 +1026,7 @@ impl Build { - } - - fn llvm_link_tools_dynamically(&self, target: Interned) -> bool { -- (target.contains("linux-gnu") || target.contains("apple-darwin")) -+ target.contains("linux-gnu") || target.contains("apple-darwin") - } - - /// Returns the `version` string associated with this compiler for Rust --- -2.24.1 - diff --git a/rust-pr70123-ensure-llvm-is-in-the-link-path.patch b/rust-pr70123-ensure-llvm-is-in-the-link-path.patch new file mode 100644 index 0000000..d076d35 --- /dev/null +++ b/rust-pr70123-ensure-llvm-is-in-the-link-path.patch @@ -0,0 +1,210 @@ +commit 9423c4f0dda638ec2a925140850b85e8d3e6d455 (from bee074f032970fd1b59650c04a70e75eeee9c63b) +Merge: bee074f03297 3a2a4429a288 +Author: Mazdak Farrokhzad +Date: Mon Mar 23 10:29:13 2020 +0100 + + Rollup merge of #70123 - cuviper:library-path, r=Mark-Simulacrum + + Ensure LLVM is in the link path for rustc tools + + The build script for `rustc_llvm` outputs LLVM information in `cargo:rustc-link-lib` and `cargo:rustc-link-search` so the compiler can be linked correctly. However, while the lib is carried along in metadata, the search paths are not. So when cargo is invoked again later for rustc _tools_, they'll also try to link with LLVM, but the necessary paths may be left out. + + Rustbuild can use the environment to set the LLVM link path for tools -- `LIB` for MSVC toolchains and `LIBRARY_PATH` for everyone else. + + Fixes #68714. + +diff --git a/src/bootstrap/builder.rs b/src/bootstrap/builder.rs +index 602e4511ea58..dd519506d42a 100644 +--- a/src/bootstrap/builder.rs ++++ b/src/bootstrap/builder.rs +@@ -11,7 +11,7 @@ use std::path::{Path, PathBuf}; + use std::process::Command; + use std::time::{Duration, Instant}; + +-use build_helper::t; ++use build_helper::{output, t}; + + use crate::cache::{Cache, Interned, INTERNER}; + use crate::check; +@@ -23,7 +23,7 @@ use crate::install; + use crate::native; + use crate::test; + use crate::tool; +-use crate::util::{self, add_lib_path, exe, libdir}; ++use crate::util::{self, add_dylib_path, add_link_lib_path, exe, libdir}; + use crate::{Build, DocTests, GitRepo, Mode}; + + pub use crate::Compiler; +@@ -660,7 +660,7 @@ impl<'a> Builder<'a> { + return; + } + +- add_lib_path(vec![self.rustc_libdir(compiler)], &mut cmd.command); ++ add_dylib_path(vec![self.rustc_libdir(compiler)], &mut cmd.command); + } + + /// Gets a path to the compiler specified. +@@ -698,6 +698,20 @@ impl<'a> Builder<'a> { + cmd + } + ++ /// Return the path to `llvm-config` for the target, if it exists. ++ /// ++ /// Note that this returns `None` if LLVM is disabled, or if we're in a ++ /// check build or dry-run, where there's no need to build all of LLVM. ++ fn llvm_config(&self, target: Interned) -> Option { ++ if self.config.llvm_enabled() && self.kind != Kind::Check && !self.config.dry_run { ++ let llvm_config = self.ensure(native::Llvm { target }); ++ if llvm_config.is_file() { ++ return Some(llvm_config); ++ } ++ } ++ None ++ } ++ + /// Prepares an invocation of `cargo` to be run. + /// + /// This will create a `Command` that represents a pending execution of +@@ -1034,6 +1048,17 @@ impl<'a> Builder<'a> { + .env("RUSTC_SNAPSHOT_LIBDIR", self.rustc_libdir(compiler)); + } + ++ // Tools that use compiler libraries may inherit the `-lLLVM` link ++ // requirement, but the `-L` library path is not propagated across ++ // separate Cargo projects. We can add LLVM's library path to the ++ // platform-specific environment variable as a workaround. ++ if mode == Mode::ToolRustc { ++ if let Some(llvm_config) = self.llvm_config(target) { ++ let llvm_libdir = output(Command::new(&llvm_config).arg("--libdir")); ++ add_link_lib_path(vec![llvm_libdir.trim().into()], &mut cargo); ++ } ++ } ++ + if self.config.incremental { + cargo.env("CARGO_INCREMENTAL", "1"); + } else { +diff --git a/src/bootstrap/compile.rs b/src/bootstrap/compile.rs +index 65a00db33949..ad494b88b3af 100644 +--- a/src/bootstrap/compile.rs ++++ b/src/bootstrap/compile.rs +@@ -451,44 +451,6 @@ impl Step for Rustc { + false, + ); + +- // We used to build librustc_codegen_llvm as a separate step, +- // which produced a dylib that the compiler would dlopen() at runtime. +- // This meant that we only needed to make sure that libLLVM.so was +- // installed by the time we went to run a tool using it - since +- // librustc_codegen_llvm was effectively a standalone artifact, +- // other crates were completely oblivious to its dependency +- // on `libLLVM.so` during build time. +- // +- // However, librustc_codegen_llvm is now built as an ordinary +- // crate during the same step as the rest of the compiler crates. +- // This means that any crates depending on it will see the fact +- // that it uses `libLLVM.so` as a native library, and will +- // cause us to pass `-llibLLVM.so` to the linker when we link +- // a binary. +- // +- // For `rustc` itself, this works out fine. +- // During the `Assemble` step, we call `dist::maybe_install_llvm_dylib` +- // to copy libLLVM.so into the `stage` directory. We then link +- // the compiler binary, which will find `libLLVM.so` in the correct place. +- // +- // However, this is insufficient for tools that are build against stage0 +- // (e.g. stage1 rustdoc). Since `Assemble` for stage0 doesn't actually do anything, +- // we won't have `libLLVM.so` in the stage0 sysroot. In the past, this wasn't +- // a problem - we would copy the tool binary into its correct stage directory +- // (e.g. stage1 for a stage1 rustdoc built against a stage0 compiler). +- // Since libLLVM.so wasn't resolved until runtime, it was fine for it to +- // not exist while we were building it. +- // +- // To ensure that we can still build stage1 tools against a stage0 compiler, +- // we explicitly copy libLLVM.so into the stage0 sysroot when building +- // the stage0 compiler. This ensures that tools built against stage0 +- // will see libLLVM.so at build time, making the linker happy. +- if compiler.stage == 0 { +- builder.info(&format!("Installing libLLVM.so to stage 0 ({})", compiler.host)); +- let sysroot = builder.sysroot(compiler); +- dist::maybe_install_llvm_dylib(builder, compiler.host, &sysroot); +- } +- + builder.ensure(RustcLink { + compiler: builder.compiler(compiler.stage, builder.config.build), + target_compiler: compiler, +diff --git a/src/bootstrap/tool.rs b/src/bootstrap/tool.rs +index 67e0ed5c5802..c8ccba467e50 100644 +--- a/src/bootstrap/tool.rs ++++ b/src/bootstrap/tool.rs +@@ -12,7 +12,7 @@ use crate::channel; + use crate::channel::GitInfo; + use crate::compile; + use crate::toolstate::ToolState; +-use crate::util::{add_lib_path, exe, CiEnv}; ++use crate::util::{add_dylib_path, exe, CiEnv}; + use crate::Compiler; + use crate::Mode; + +@@ -388,7 +388,7 @@ pub struct ErrorIndex { + impl ErrorIndex { + pub fn command(builder: &Builder<'_>, compiler: Compiler) -> Command { + let mut cmd = Command::new(builder.ensure(ErrorIndex { compiler })); +- add_lib_path( ++ add_dylib_path( + vec![PathBuf::from(&builder.sysroot_libdir(compiler, compiler.host))], + &mut cmd, + ); +@@ -689,7 +689,7 @@ impl<'a> Builder<'a> { + } + } + +- add_lib_path(lib_paths, &mut cmd); ++ add_dylib_path(lib_paths, &mut cmd); + cmd + } + } +diff --git a/src/bootstrap/util.rs b/src/bootstrap/util.rs +index eac790fe504b..2bc6f1939d97 100644 +--- a/src/bootstrap/util.rs ++++ b/src/bootstrap/util.rs +@@ -40,7 +40,7 @@ pub fn libdir(target: &str) -> &'static str { + } + + /// Adds a list of lookup paths to `cmd`'s dynamic library lookup path. +-pub fn add_lib_path(path: Vec, cmd: &mut Command) { ++pub fn add_dylib_path(path: Vec, cmd: &mut Command) { + let mut list = dylib_path(); + for path in path { + list.insert(0, path); +@@ -72,6 +72,31 @@ pub fn dylib_path() -> Vec { + env::split_paths(&var).collect() + } + ++/// Adds a list of lookup paths to `cmd`'s link library lookup path. ++pub fn add_link_lib_path(path: Vec, cmd: &mut Command) { ++ let mut list = link_lib_path(); ++ for path in path { ++ list.insert(0, path); ++ } ++ cmd.env(link_lib_path_var(), t!(env::join_paths(list))); ++} ++ ++/// Returns the environment variable which the link library lookup path ++/// resides in for this platform. ++fn link_lib_path_var() -> &'static str { ++ if cfg!(target_env = "msvc") { "LIB" } else { "LIBRARY_PATH" } ++} ++ ++/// Parses the `link_lib_path_var()` environment variable, returning a list of ++/// paths that are members of this lookup path. ++fn link_lib_path() -> Vec { ++ let var = match env::var_os(link_lib_path_var()) { ++ Some(v) => v, ++ None => return vec![], ++ }; ++ env::split_paths(&var).collect() ++} ++ + /// `push` all components to `buf`. On windows, append `.exe` to the last component. + pub fn push_exe_path(mut buf: PathBuf, components: &[&str]) -> PathBuf { + let (&file, components) = components.split_last().expect("at least one component required"); diff --git a/rust-pr70163-prepare-for-llvm-10-upgrade.patch b/rust-pr70163-prepare-for-llvm-10-upgrade.patch new file mode 100644 index 0000000..765c2e9 --- /dev/null +++ b/rust-pr70163-prepare-for-llvm-10-upgrade.patch @@ -0,0 +1,175 @@ +commit 374ab25585f0a817fe7bd6986737f12347b12d0b (from 1add455ec6f81045e7651c6225902823f5d4fbfa) +Merge: 1add455ec6f8 497f879b1e24 +Author: bors +Date: Tue Mar 24 12:42:54 2020 +0000 + + Auto merge of #70163 - nikic:llvm-10-preparation, r=cuviper + + Prepare for LLVM 10 upgrade + + This is #67759 minus the submodule update. + + * Fix two compatibility issues in the rustllvm wrapper. + * Update data layout strings in tests. + * Fix LLVM version comparison (this become a problem because the major version has two digits now). + + r? @cuviper + +diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs +index aa1d1b7c4241..b52fbe4666eb 100644 +--- a/src/bootstrap/test.rs ++++ b/src/bootstrap/test.rs +@@ -1141,6 +1141,8 @@ impl Step for Compiletest { + let llvm_config = builder.ensure(native::Llvm { target: builder.config.build }); + if !builder.config.dry_run { + let llvm_version = output(Command::new(&llvm_config).arg("--version")); ++ // Remove trailing newline from llvm-config output. ++ let llvm_version = llvm_version.trim_end(); + cmd.arg("--llvm-version").arg(llvm_version); + } + if !builder.is_rust_llvm(target) { +diff --git a/src/rustllvm/PassWrapper.cpp b/src/rustllvm/PassWrapper.cpp +index 90d24d20737d..9e8614e3b6d3 100644 +--- a/src/rustllvm/PassWrapper.cpp ++++ b/src/rustllvm/PassWrapper.cpp +@@ -67,7 +67,11 @@ extern "C" void LLVMInitializePasses() { + } + + extern "C" void LLVMTimeTraceProfilerInitialize() { +-#if LLVM_VERSION_GE(9, 0) ++#if LLVM_VERSION_GE(10, 0) ++ timeTraceProfilerInitialize( ++ /* TimeTraceGranularity */ 0, ++ /* ProcName */ "rustc"); ++#elif LLVM_VERSION_GE(9, 0) + timeTraceProfilerInitialize(); + #endif + } +diff --git a/src/rustllvm/RustWrapper.cpp b/src/rustllvm/RustWrapper.cpp +index 25cfee3373dc..799adb418822 100644 +--- a/src/rustllvm/RustWrapper.cpp ++++ b/src/rustllvm/RustWrapper.cpp +@@ -1333,8 +1333,13 @@ extern "C" LLVMValueRef LLVMRustBuildMemSet(LLVMBuilderRef B, + LLVMValueRef Dst, unsigned DstAlign, + LLVMValueRef Val, + LLVMValueRef Size, bool IsVolatile) { ++#if LLVM_VERSION_GE(10, 0) ++ return wrap(unwrap(B)->CreateMemSet( ++ unwrap(Dst), unwrap(Val), unwrap(Size), MaybeAlign(DstAlign), IsVolatile)); ++#else + return wrap(unwrap(B)->CreateMemSet( + unwrap(Dst), unwrap(Val), unwrap(Size), DstAlign, IsVolatile)); ++#endif + } + + extern "C" LLVMValueRef +diff --git a/src/test/run-make-fulldeps/target-specs/my-awesome-platform.json b/src/test/run-make-fulldeps/target-specs/my-awesome-platform.json +index 8d028280a8da..00de3de05f07 100644 +--- a/src/test/run-make-fulldeps/target-specs/my-awesome-platform.json ++++ b/src/test/run-make-fulldeps/target-specs/my-awesome-platform.json +@@ -1,5 +1,5 @@ + { +- "data-layout": "e-m:e-p:32:32-f64:32:64-f80:32-n8:16:32-S128", ++ "data-layout": "e-m:e-p:32:32-p270:32:32-p271:32:32-p272:64:64-f64:32:64-f80:32-n8:16:32-S128", + "linker-flavor": "gcc", + "llvm-target": "i686-unknown-linux-gnu", + "target-endian": "little", +diff --git a/src/test/run-make-fulldeps/target-specs/my-x86_64-unknown-linux-gnu-platform.json b/src/test/run-make-fulldeps/target-specs/my-x86_64-unknown-linux-gnu-platform.json +index 48040ae3da0e..6d5e964ed4fe 100644 +--- a/src/test/run-make-fulldeps/target-specs/my-x86_64-unknown-linux-gnu-platform.json ++++ b/src/test/run-make-fulldeps/target-specs/my-x86_64-unknown-linux-gnu-platform.json +@@ -1,6 +1,6 @@ + { + "pre-link-args": {"gcc": ["-m64"]}, +- "data-layout": "e-m:e-i64:64-f80:128-n8:16:32:64-S128", ++ "data-layout": "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128", + "linker-flavor": "gcc", + "llvm-target": "x86_64-unknown-linux-gnu", + "target-endian": "little", +diff --git a/src/tools/compiletest/src/header.rs b/src/tools/compiletest/src/header.rs +index 2a24a8c3c948..cb648db8830e 100644 +--- a/src/tools/compiletest/src/header.rs ++++ b/src/tools/compiletest/src/header.rs +@@ -191,6 +191,7 @@ impl EarlyProps { + return true; + } + if let Some(ref actual_version) = config.llvm_version { ++ let actual_version = version_to_int(actual_version); + if line.starts_with("min-llvm-version") { + let min_version = line + .trim_end() +@@ -199,7 +200,7 @@ impl EarlyProps { + .expect("Malformed llvm version directive"); + // Ignore if actual version is smaller the minimum required + // version +- &actual_version[..] < min_version ++ actual_version < version_to_int(min_version) + } else if line.starts_with("min-system-llvm-version") { + let min_version = line + .trim_end() +@@ -208,7 +209,7 @@ impl EarlyProps { + .expect("Malformed llvm version directive"); + // Ignore if using system LLVM and actual version + // is smaller the minimum required version +- config.system_llvm && &actual_version[..] < min_version ++ config.system_llvm && actual_version < version_to_int(min_version) + } else if line.starts_with("ignore-llvm-version") { + // Syntax is: "ignore-llvm-version [- ]" + let range_components = line +@@ -219,15 +220,15 @@ impl EarlyProps { + .take(3) // 3 or more = invalid, so take at most 3. + .collect::>(); + match range_components.len() { +- 1 => &actual_version[..] == range_components[0], ++ 1 => actual_version == version_to_int(range_components[0]), + 2 => { +- let v_min = range_components[0]; +- let v_max = range_components[1]; ++ let v_min = version_to_int(range_components[0]); ++ let v_max = version_to_int(range_components[1]); + if v_max < v_min { + panic!("Malformed LLVM version range: max < min") + } + // Ignore if version lies inside of range. +- &actual_version[..] >= v_min && &actual_version[..] <= v_max ++ actual_version >= v_min && actual_version <= v_max + } + _ => panic!("Malformed LLVM version directive"), + } +@@ -238,6 +239,20 @@ impl EarlyProps { + false + } + } ++ ++ fn version_to_int(version: &str) -> u32 { ++ let version_without_suffix = version.split('-').next().unwrap(); ++ let components: Vec = version_without_suffix ++ .split('.') ++ .map(|s| s.parse().expect("Malformed version component")) ++ .collect(); ++ match components.len() { ++ 1 => components[0] * 10000, ++ 2 => components[0] * 10000 + components[1] * 100, ++ 3 => components[0] * 10000 + components[1] * 100 + components[2], ++ _ => panic!("Malformed version"), ++ } ++ } + } + } + +diff --git a/src/tools/compiletest/src/header/tests.rs b/src/tools/compiletest/src/header/tests.rs +index 6c478f7e29da..31d991e0c2f8 100644 +--- a/src/tools/compiletest/src/header/tests.rs ++++ b/src/tools/compiletest/src/header/tests.rs +@@ -122,9 +122,8 @@ fn llvm_version() { + config.llvm_version = Some("9.3.1-rust-1.43.0-dev".to_owned()); + assert!(!parse_rs(&config, "// min-llvm-version 9.2").ignore); + +- // FIXME. +- // config.llvm_version = Some("10.0.0-rust".to_owned()); +- // assert!(!parse_rs(&config, "// min-llvm-version 9.0").ignore); ++ config.llvm_version = Some("10.0.0-rust".to_owned()); ++ assert!(!parse_rs(&config, "// min-llvm-version 9.0").ignore); + } + + #[test] diff --git a/rust-pr70591-ensure-llvm-is-in-the-link-path.patch b/rust-pr70591-ensure-llvm-is-in-the-link-path.patch new file mode 100644 index 0000000..9f5722b --- /dev/null +++ b/rust-pr70591-ensure-llvm-is-in-the-link-path.patch @@ -0,0 +1,40 @@ +commit 6067315d58ff3d49b305ae3c99810656856c8e21 +Author: Josh Stone +Date: Mon Mar 30 14:03:39 2020 -0700 + + Ensure LLVM is in the link path for "fulldeps" tests + + This is a follow-up to #70123, which added `llvm-config --libdir` to the + `LIBRARY_PATH` for rustc tools. We need the same for "run-make-fulldeps" + and "ui-fulldeps" tests which depend on compiler libraries, implicitly + needing to link to `-lLLVM` as well. + +diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs +index 5b946b05735d..2499856235f1 100644 +--- a/src/bootstrap/test.rs ++++ b/src/bootstrap/test.rs +@@ -21,7 +21,7 @@ use crate::flags::Subcommand; + use crate::native; + use crate::tool::{self, SourceType, Tool}; + use crate::toolstate::ToolState; +-use crate::util::{self, dylib_path, dylib_path_var}; ++use crate::util::{self, add_link_lib_path, dylib_path, dylib_path_var}; + use crate::Crate as CargoCrate; + use crate::{envify, DocTests, GitRepo, Mode}; + +@@ -1178,6 +1178,15 @@ impl Step for Compiletest { + cmd.arg("--system-llvm"); + } + ++ // Tests that use compiler libraries may inherit the `-lLLVM` link ++ // requirement, but the `-L` library path is not propagated across ++ // separate compilations. We can add LLVM's library path to the ++ // platform-specific environment variable as a workaround. ++ if !builder.config.dry_run && suite.ends_with("fulldeps") { ++ let llvm_libdir = output(Command::new(&llvm_config).arg("--libdir")); ++ add_link_lib_path(vec![llvm_libdir.trim().into()], &mut cmd); ++ } ++ + // Only pass correct values for these flags for the `run-make` suite as it + // requires that a C++ compiler was configured which isn't always the case. + if !builder.config.dry_run && suite == "run-make-fulldeps" { diff --git a/rust.spec b/rust.spec index f0875a3..83ee5a9 100644 --- a/rust.spec +++ b/rust.spec @@ -9,10 +9,10 @@ # e.g. 1.10.0 wants rustc: 1.9.0-2016-05-24 # or nightly wants some beta-YYYY-MM-DD # Note that cargo matches the program version here, not its crate version. -%global bootstrap_rust 1.41.0 -%global bootstrap_cargo 1.41.0 -%global bootstrap_channel 1.41.1 -%global bootstrap_date 2020-02-27 +%global bootstrap_rust 1.42.0 +%global bootstrap_cargo 1.42.0 +%global bootstrap_channel 1.42.0 +%global bootstrap_date 2020-03-12 # Only the specified arches will use bootstrap binaries. #global bootstrap_arches %%{rust_arches} @@ -48,7 +48,7 @@ %endif Name: rust -Version: 1.42.0 +Version: 1.43.0 Release: 1%{?dist} Summary: The Rust Programming Language License: (ASL 2.0 or MIT) and (BSD and MIT) @@ -67,9 +67,15 @@ Source0: https://static.rust-lang.org/dist/%{rustc_package}.tar.xz # We do have the necessary fix in our LLVM 7. Patch1: rust-pr57840-llvm7-debuginfo-variants.patch -# Fix 1.42 bootstrapping itself -# https://github.com/rust-lang/rust/issues/69953 -Patch2: 0001-Drop-cfg-bootstrap-code.patch +# Ensure LLVM is in the link path for rustc tools and "fulldeps" tests +# https://github.com/rust-lang/rust/pull/70123 +# https://github.com/rust-lang/rust/pull/70591 +Patch2: rust-pr70123-ensure-llvm-is-in-the-link-path.patch +Patch3: rust-pr70591-ensure-llvm-is-in-the-link-path.patch + +# Prepare for LLVM 10 upgrade +# https://github.com/rust-lang/rust/pull/70163 +Patch4: rust-pr70163-prepare-for-llvm-10-upgrade.patch # Get the Rust triple for any arch. %{lua: function rust_triple(arch) @@ -157,9 +163,6 @@ BuildRequires: cmake >= 2.8.11 %if 0%{?epel} %global llvm llvm7.0 %endif -%if 0%{?fedora} >= 32 -%global llvm llvm9.0 -%endif %if %defined llvm %global llvm_root %{_libdir}/%{llvm} %else @@ -220,10 +223,6 @@ Requires: /usr/bin/cc %if "%{llvm_root}" == "%{_prefix}" || 0%{?scl:1} %global llvm_has_filecheck 1 %endif -%if "%{llvm_root}" != "%{_prefix}" -# https://github.com/rust-lang/rust/issues/68714 -%global library_path $(%{llvm_root}/bin/llvm-config --libdir) -%endif %endif %description @@ -295,7 +294,7 @@ its standard library. %package -n cargo Summary: Rust's package manager and build tool %if %with bundled_libgit2 -Provides: bundled(libgit2) = 0.28.2 +Provides: bundled(libgit2) = 0.99.0 %endif %if %with bundled_libssh2 Provides: bundled(libssh2) = 1.9.0~dev @@ -341,7 +340,7 @@ A tool for formatting Rust code according to style guidelines. %package -n rls Summary: Rust Language Server for IDE integration %if %with bundled_libgit2 -Provides: bundled(libgit2) = 0.28.2 +Provides: bundled(libgit2) = 0.99.0 %endif %if %with bundled_libssh2 Provides: bundled(libssh2) = 1.9.0~dev @@ -408,6 +407,8 @@ test -f '%{local_rust_root}/bin/rustc' %patch1 -p1 -R %patch2 -p1 +%patch3 -p1 +%patch4 -p1 %if "%{python}" == "python3" sed -i.try-py3 -e '/try python2.7/i try python3 "$@"' ./configure @@ -475,7 +476,6 @@ export LIBSSH2_SYS_USE_PKG_CONFIG=1 %endif %{?cmake_path:export PATH=%{cmake_path}:$PATH} -%{?library_path:export LIBRARY_PATH="%{library_path}"} %{?rustflags:export RUSTFLAGS="%{rustflags}"} # We're going to override --libdir when configuring to get rustlib into a @@ -526,7 +526,6 @@ export LIBSSH2_SYS_USE_PKG_CONFIG=1 %install %{?cmake_path:export PATH=%{cmake_path}:$PATH} -%{?library_path:export LIBRARY_PATH="%{library_path}"} %{?rustflags:export RUSTFLAGS="%{rustflags}"} DESTDIR=%{buildroot} %{python} ./x.py install @@ -597,7 +596,6 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %check %{?cmake_path:export PATH=%{cmake_path}:$PATH} -%{?library_path:export LIBRARY_PATH="%{library_path}"} %{?rustflags:export RUSTFLAGS="%{rustflags}"} # The results are not stable on koji, so mask errors and just log it. @@ -716,6 +714,9 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %changelog +* Thu Apr 23 2020 Josh Stone - 1.43.0-1 +- Update to 1.43.0. + * Thu Mar 12 2020 Josh Stone - 1.42.0-1 - Update to 1.42.0. diff --git a/sources b/sources index 63fa9dd..2a8be05 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (rustc-1.42.0-src.tar.xz) = 589bfdc92deedd33b8ea0df7f7c64c2a9a085fbea64936eff92f81e812309c060ed7a7adc96f6010d7adf62a68434a230da0f6c5b3540df4e0a5c6de05a31b16 +SHA512 (rustc-1.43.0-src.tar.xz) = dbff18567f2971da4eb13c670c30b136757692df1bc5024cdc0406f3c30574d3485fd616724987bcc765bc5f64c8ed5026f0e96f11eacb035e00256ed190b4f3 diff --git a/sources-bootstrap b/sources-bootstrap index 4a4c06d..741fae5 100644 --- a/sources-bootstrap +++ b/sources-bootstrap @@ -1,8 +1,8 @@ -SHA512 (rustc-1.42.0-src.tar.xz) = 589bfdc92deedd33b8ea0df7f7c64c2a9a085fbea64936eff92f81e812309c060ed7a7adc96f6010d7adf62a68434a230da0f6c5b3540df4e0a5c6de05a31b16 -SHA512 (rust-1.41.1-aarch64-unknown-linux-gnu.tar.xz) = 54eac5c380b418c1714931ead7d6284b225bb427fcc501e147240000b71d31b667e308aea7f38f3299b1311ab04f19011b914d37a4581c7a64028965569cd58e -SHA512 (rust-1.41.1-armv7-unknown-linux-gnueabihf.tar.xz) = 400bf8d013fe5030243bc0ccb7066ea3d03a2c10727e04b6830ab91dfe9b04f78cfef10794a1c7bb6276fb00c86f1e1c42a74faba19f3125859b3464726d01c2 -SHA512 (rust-1.41.1-i686-unknown-linux-gnu.tar.xz) = c6d74b2653c537043eb2ea721095ff053def592b4c330bdc104690cfb51d648f515288cc0451743d94260f18a55d6757bcb8eb1e6c0217da3498d08b681ca6af -SHA512 (rust-1.41.1-powerpc64le-unknown-linux-gnu.tar.xz) = 1b2bf6d35321dd0a0fc9735005317f09f8b9a81b520612484530e29156ea254d5cada583e44f7e4a840edde09d70c34f7ead1208d8aa6037c652540dfa38cede -SHA512 (rust-1.41.1-powerpc64-unknown-linux-gnu.tar.xz) = 50367685783085cc384be944d4321dfde850f3a0e94de0625a08f17160af2c0b795276f96574d1bea84092cbc1cd3cde619d97fe2e37b07ead17f49164e1c995 -SHA512 (rust-1.41.1-s390x-unknown-linux-gnu.tar.xz) = f809adc626876df5c6e050362d59189ede5e3991ac41fd129922540abeb728f618e1a3f3925cee34895de5e037141aabb1f8c2b94d4069945d174e38446e8153 -SHA512 (rust-1.41.1-x86_64-unknown-linux-gnu.tar.xz) = c75d4a18cf9300c6ab480d34c5e4b41be971535931455239330cb2a0e927bcf9cf102498cad5dd1d5d802fd1d9c9d214b80e8ff15aa6be68d3e7f41420cad666 +SHA512 (rustc-1.43.0-src.tar.xz) = dbff18567f2971da4eb13c670c30b136757692df1bc5024cdc0406f3c30574d3485fd616724987bcc765bc5f64c8ed5026f0e96f11eacb035e00256ed190b4f3 +SHA512 (rust-1.42.0-aarch64-unknown-linux-gnu.tar.xz) = 691a11e279efdcafa6bdafacb7fb48ccf653e180e0e85909b6031105a297d47538efb36d63216f6185427f818483a51aa827f351ca2123840d72caf60079fe13 +SHA512 (rust-1.42.0-armv7-unknown-linux-gnueabihf.tar.xz) = 26768ec530506e20fed8f9ef2c1ca85eec155fc90949f2063836b6109b296a976c8430a698971a8b1c11e8f6ad043d854a36e9f0e849417178411dc5cbd30e59 +SHA512 (rust-1.42.0-i686-unknown-linux-gnu.tar.xz) = 7376be5abed573bbf68f73ed5609fa8e22dfa3ead19a3f3d78d553347e3ae01604ab9906f5317f1687a8ab3f9ad9c38cde44ef6f56d7da65a788a74aee9df057 +SHA512 (rust-1.42.0-powerpc64le-unknown-linux-gnu.tar.xz) = e1db9bbef45e88e7d1d5b905379c04786a015c90d0d9de6a6c16276a3e91c342a8231dda7a4d46ecc7adc969d07fd7dd8595975647b9ab69f8997fee74401219 +SHA512 (rust-1.42.0-powerpc64-unknown-linux-gnu.tar.xz) = 668d1d353bdaf676043ab7f4baad464b202e8ae1be7713e3481b8e9fb5fabd1020e10e178d69d099541cb1b23362b50b826790740156f1c96efa3d2a7457e404 +SHA512 (rust-1.42.0-s390x-unknown-linux-gnu.tar.xz) = 85b1331a9a71cc43a2fa628b8510590ff072e409c2c38ebfd9089ab7a245182e23b52f6221b25c63f6048e1bf4ada0f561dd8f3f810680c9727040bc8a0d8d46 +SHA512 (rust-1.42.0-x86_64-unknown-linux-gnu.tar.xz) = 87c06d4503e7ba12bd3dfc8dd279a3bdf33a24d2c22eec1378b79b2c17ccdad9b4c8dbd0d4704eae1f3476aec5639d3ba143e8c74a296d631b17b57da7447e70 From 52b63674b5f83aa949aacf44bcbeb27d7d7c691b Mon Sep 17 00:00:00 2001 From: Josh Stone Date: Thu, 7 May 2020 11:29:23 -0700 Subject: [PATCH 2/5] Update to 1.43.1. --- .gitignore | 1 + ...pr71782-Use-a-non-existent-test-path.patch | 56 +++++++++++++++++++ rust.spec | 9 ++- sources | 2 +- sources-bootstrap | 2 +- 5 files changed, 67 insertions(+), 3 deletions(-) create mode 100644 rust-pr71782-Use-a-non-existent-test-path.patch diff --git a/.gitignore b/.gitignore index 2e5822a..e06b217 100644 --- a/.gitignore +++ b/.gitignore @@ -269,3 +269,4 @@ /rust-1.42.0-powerpc64-unknown-linux-gnu.tar.xz /rust-1.42.0-s390x-unknown-linux-gnu.tar.xz /rust-1.42.0-x86_64-unknown-linux-gnu.tar.xz +/rustc-1.43.1-src.tar.xz diff --git a/rust-pr71782-Use-a-non-existent-test-path.patch b/rust-pr71782-Use-a-non-existent-test-path.patch new file mode 100644 index 0000000..df02449 --- /dev/null +++ b/rust-pr71782-Use-a-non-existent-test-path.patch @@ -0,0 +1,56 @@ +From fbd3fbdb24563a9d8fd3651f6bdc90bbbbd81d3e Mon Sep 17 00:00:00 2001 +From: Josh Stone +Date: Fri, 1 May 2020 16:50:10 -0700 +Subject: [PATCH] Use a non-existent test path instead of clobbering /dev/null + +--- + src/test/ui/non-ice-error-on-worker-io-fail.rs | 10 +++++++--- + src/test/ui/non-ice-error-on-worker-io-fail.stderr | 2 +- + 2 files changed, 8 insertions(+), 4 deletions(-) + +diff --git a/src/test/ui/non-ice-error-on-worker-io-fail.rs b/src/test/ui/non-ice-error-on-worker-io-fail.rs +index 8af17742850d..30779fc65c0f 100644 +--- a/src/test/ui/non-ice-error-on-worker-io-fail.rs ++++ b/src/test/ui/non-ice-error-on-worker-io-fail.rs +@@ -4,8 +4,12 @@ + // + // An attempt to `-o` into a directory we cannot write into should indeed + // be an error; but not an ICE. ++// ++// However, some folks run tests as root, which can write `/dev/` and end ++// up clobbering `/dev/null`. Instead we'll use a non-existent path, which ++// also used to ICE, but even root can't magically write there. + +-// compile-flags: -o /dev/null ++// compile-flags: -o /does-not-exist/output + + // The error-pattern check occurs *before* normalization, and the error patterns + // are wildly different between build environments. So this is a cop-out (and we +@@ -15,10 +19,10 @@ + // error-pattern: error + + // On Mac OS X, we get an error like the below +-// normalize-stderr-test "failed to write bytecode to /dev/null.non_ice_error_on_worker_io_fail.*" -> "io error modifying /dev/" ++// normalize-stderr-test "failed to write bytecode to /does-not-exist/output.non_ice_error_on_worker_io_fail.*" -> "io error modifying /does-not-exist/" + + // On Linux, we get an error like the below +-// normalize-stderr-test "couldn't create a temp dir.*" -> "io error modifying /dev/" ++// normalize-stderr-test "couldn't create a temp dir.*" -> "io error modifying /does-not-exist/" + + // ignore-tidy-linelength + // ignore-windows - this is a unix-specific test +diff --git a/src/test/ui/non-ice-error-on-worker-io-fail.stderr b/src/test/ui/non-ice-error-on-worker-io-fail.stderr +index f732abc52b71..edadecf273a7 100644 +--- a/src/test/ui/non-ice-error-on-worker-io-fail.stderr ++++ b/src/test/ui/non-ice-error-on-worker-io-fail.stderr +@@ -1,6 +1,6 @@ + warning: ignoring --out-dir flag due to -o flag + +-error: io error modifying /dev/ ++error: io error modifying /does-not-exist/ + + error: aborting due to previous error + +-- +2.26.2 + diff --git a/rust.spec b/rust.spec index 83ee5a9..05ea3f7 100644 --- a/rust.spec +++ b/rust.spec @@ -48,7 +48,7 @@ %endif Name: rust -Version: 1.43.0 +Version: 1.43.1 Release: 1%{?dist} Summary: The Rust Programming Language License: (ASL 2.0 or MIT) and (BSD and MIT) @@ -77,6 +77,9 @@ Patch3: rust-pr70591-ensure-llvm-is-in-the-link-path.patch # https://github.com/rust-lang/rust/pull/70163 Patch4: rust-pr70163-prepare-for-llvm-10-upgrade.patch +# https://github.com/rust-lang/rust/pull/71782 +Patch5: rust-pr71782-Use-a-non-existent-test-path.patch + # Get the Rust triple for any arch. %{lua: function rust_triple(arch) local abi = "gnu" @@ -409,6 +412,7 @@ test -f '%{local_rust_root}/bin/rustc' %patch2 -p1 %patch3 -p1 %patch4 -p1 +%patch5 -p1 %if "%{python}" == "python3" sed -i.try-py3 -e '/try python2.7/i try python3 "$@"' ./configure @@ -714,6 +718,9 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %changelog +* Thu May 07 2020 Josh Stone - 1.43.1-1 +- Update to 1.43.1. + * Thu Apr 23 2020 Josh Stone - 1.43.0-1 - Update to 1.43.0. diff --git a/sources b/sources index 2a8be05..fb9b958 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (rustc-1.43.0-src.tar.xz) = dbff18567f2971da4eb13c670c30b136757692df1bc5024cdc0406f3c30574d3485fd616724987bcc765bc5f64c8ed5026f0e96f11eacb035e00256ed190b4f3 +SHA512 (rustc-1.43.1-src.tar.xz) = 24bb01237b1f3f5412109290bb4406b9742cf8956162f4090a98ed3a59a6e2e8dda399452bec1c93c8afdcf5effd98e4825e7f218238e0e88735c1ff4a5b385f diff --git a/sources-bootstrap b/sources-bootstrap index 741fae5..f2aa62c 100644 --- a/sources-bootstrap +++ b/sources-bootstrap @@ -1,4 +1,4 @@ -SHA512 (rustc-1.43.0-src.tar.xz) = dbff18567f2971da4eb13c670c30b136757692df1bc5024cdc0406f3c30574d3485fd616724987bcc765bc5f64c8ed5026f0e96f11eacb035e00256ed190b4f3 +SHA512 (rustc-1.43.1-src.tar.xz) = 24bb01237b1f3f5412109290bb4406b9742cf8956162f4090a98ed3a59a6e2e8dda399452bec1c93c8afdcf5effd98e4825e7f218238e0e88735c1ff4a5b385f SHA512 (rust-1.42.0-aarch64-unknown-linux-gnu.tar.xz) = 691a11e279efdcafa6bdafacb7fb48ccf653e180e0e85909b6031105a297d47538efb36d63216f6185427f818483a51aa827f351ca2123840d72caf60079fe13 SHA512 (rust-1.42.0-armv7-unknown-linux-gnueabihf.tar.xz) = 26768ec530506e20fed8f9ef2c1ca85eec155fc90949f2063836b6109b296a976c8430a698971a8b1c11e8f6ad043d854a36e9f0e849417178411dc5cbd30e59 SHA512 (rust-1.42.0-i686-unknown-linux-gnu.tar.xz) = 7376be5abed573bbf68f73ed5609fa8e22dfa3ead19a3f3d78d553347e3ae01604ab9906f5317f1687a8ab3f9ad9c38cde44ef6f56d7da65a788a74aee9df057 From d921e9b0a9460392526492a83cd25c0d76130524 Mon Sep 17 00:00:00 2001 From: Josh Stone Date: Thu, 4 Jun 2020 11:59:31 -0700 Subject: [PATCH 3/5] Update to 1.44.0. --- .gitignore | 8 + rust-pr57840-llvm7-debuginfo-variants.patch | 32 --- ...0123-ensure-llvm-is-in-the-link-path.patch | 210 ------------------ ...-pr70163-prepare-for-llvm-10-upgrade.patch | 175 --------------- ...0591-ensure-llvm-is-in-the-link-path.patch | 40 ---- ...pr71782-Use-a-non-existent-test-path.patch | 2 +- rust.spec | 49 ++-- sources | 2 +- sources-bootstrap | 16 +- 9 files changed, 35 insertions(+), 499 deletions(-) delete mode 100644 rust-pr57840-llvm7-debuginfo-variants.patch delete mode 100644 rust-pr70123-ensure-llvm-is-in-the-link-path.patch delete mode 100644 rust-pr70163-prepare-for-llvm-10-upgrade.patch delete mode 100644 rust-pr70591-ensure-llvm-is-in-the-link-path.patch diff --git a/.gitignore b/.gitignore index e06b217..5d48bd7 100644 --- a/.gitignore +++ b/.gitignore @@ -270,3 +270,11 @@ /rust-1.42.0-s390x-unknown-linux-gnu.tar.xz /rust-1.42.0-x86_64-unknown-linux-gnu.tar.xz /rustc-1.43.1-src.tar.xz +/rustc-1.44.0-src.tar.xz +/rust-1.43.1-aarch64-unknown-linux-gnu.tar.xz +/rust-1.43.1-armv7-unknown-linux-gnueabihf.tar.xz +/rust-1.43.1-i686-unknown-linux-gnu.tar.xz +/rust-1.43.1-powerpc64le-unknown-linux-gnu.tar.xz +/rust-1.43.1-powerpc64-unknown-linux-gnu.tar.xz +/rust-1.43.1-s390x-unknown-linux-gnu.tar.xz +/rust-1.43.1-x86_64-unknown-linux-gnu.tar.xz diff --git a/rust-pr57840-llvm7-debuginfo-variants.patch b/rust-pr57840-llvm7-debuginfo-variants.patch deleted file mode 100644 index b1fd427..0000000 --- a/rust-pr57840-llvm7-debuginfo-variants.patch +++ /dev/null @@ -1,32 +0,0 @@ -commit ab998a2eeb2bcdc69ce70c814af97f0d1302a404 (from d17f62d857c70508efbf60be41135880bcd2e062) -Merge: d17f62d857c7 9452a8dfa3ba -Author: Mazdak Farrokhzad -Date: Thu Jan 24 00:20:00 2019 +0100 - - Rollup merge of #57840 - tromey:fix-issue-57762, r=nikic - - Fix issue 57762 - - against a stock LLVM 7. LLVM 7 was released without a necessary fix - for a bug in the DWARF discriminant code. - - This patch changes rustc to use the fallback mode on (non-Rust) LLVM 7. - - Closes #57762 - -diff --git a/src/librustc_codegen_llvm/debuginfo/metadata.rs b/src/librustc_codegen_llvm/debuginfo/metadata.rs -index 6deedd0b5ea3..9f63038c3623 100644 ---- a/src/librustc_codegen_llvm/debuginfo/metadata.rs -+++ b/src/librustc_codegen_llvm/debuginfo/metadata.rs -@@ -1164,7 +1164,10 @@ fn use_enum_fallback(cx: &CodegenCx) -> bool { - // On MSVC we have to use the fallback mode, because LLVM doesn't - // lower variant parts to PDB. - return cx.sess().target.target.options.is_like_msvc -- || llvm_util::get_major_version() < 7; -+ // LLVM version 7 did not release with an important bug fix; -+ // but the required patch is in the LLVM 8. Rust LLVM reports -+ // 8 as well. -+ || llvm_util::get_major_version() < 8; - } - - // FIXME(eddyb) maybe precompute this? Right now it's computed once diff --git a/rust-pr70123-ensure-llvm-is-in-the-link-path.patch b/rust-pr70123-ensure-llvm-is-in-the-link-path.patch deleted file mode 100644 index d076d35..0000000 --- a/rust-pr70123-ensure-llvm-is-in-the-link-path.patch +++ /dev/null @@ -1,210 +0,0 @@ -commit 9423c4f0dda638ec2a925140850b85e8d3e6d455 (from bee074f032970fd1b59650c04a70e75eeee9c63b) -Merge: bee074f03297 3a2a4429a288 -Author: Mazdak Farrokhzad -Date: Mon Mar 23 10:29:13 2020 +0100 - - Rollup merge of #70123 - cuviper:library-path, r=Mark-Simulacrum - - Ensure LLVM is in the link path for rustc tools - - The build script for `rustc_llvm` outputs LLVM information in `cargo:rustc-link-lib` and `cargo:rustc-link-search` so the compiler can be linked correctly. However, while the lib is carried along in metadata, the search paths are not. So when cargo is invoked again later for rustc _tools_, they'll also try to link with LLVM, but the necessary paths may be left out. - - Rustbuild can use the environment to set the LLVM link path for tools -- `LIB` for MSVC toolchains and `LIBRARY_PATH` for everyone else. - - Fixes #68714. - -diff --git a/src/bootstrap/builder.rs b/src/bootstrap/builder.rs -index 602e4511ea58..dd519506d42a 100644 ---- a/src/bootstrap/builder.rs -+++ b/src/bootstrap/builder.rs -@@ -11,7 +11,7 @@ use std::path::{Path, PathBuf}; - use std::process::Command; - use std::time::{Duration, Instant}; - --use build_helper::t; -+use build_helper::{output, t}; - - use crate::cache::{Cache, Interned, INTERNER}; - use crate::check; -@@ -23,7 +23,7 @@ use crate::install; - use crate::native; - use crate::test; - use crate::tool; --use crate::util::{self, add_lib_path, exe, libdir}; -+use crate::util::{self, add_dylib_path, add_link_lib_path, exe, libdir}; - use crate::{Build, DocTests, GitRepo, Mode}; - - pub use crate::Compiler; -@@ -660,7 +660,7 @@ impl<'a> Builder<'a> { - return; - } - -- add_lib_path(vec![self.rustc_libdir(compiler)], &mut cmd.command); -+ add_dylib_path(vec![self.rustc_libdir(compiler)], &mut cmd.command); - } - - /// Gets a path to the compiler specified. -@@ -698,6 +698,20 @@ impl<'a> Builder<'a> { - cmd - } - -+ /// Return the path to `llvm-config` for the target, if it exists. -+ /// -+ /// Note that this returns `None` if LLVM is disabled, or if we're in a -+ /// check build or dry-run, where there's no need to build all of LLVM. -+ fn llvm_config(&self, target: Interned) -> Option { -+ if self.config.llvm_enabled() && self.kind != Kind::Check && !self.config.dry_run { -+ let llvm_config = self.ensure(native::Llvm { target }); -+ if llvm_config.is_file() { -+ return Some(llvm_config); -+ } -+ } -+ None -+ } -+ - /// Prepares an invocation of `cargo` to be run. - /// - /// This will create a `Command` that represents a pending execution of -@@ -1034,6 +1048,17 @@ impl<'a> Builder<'a> { - .env("RUSTC_SNAPSHOT_LIBDIR", self.rustc_libdir(compiler)); - } - -+ // Tools that use compiler libraries may inherit the `-lLLVM` link -+ // requirement, but the `-L` library path is not propagated across -+ // separate Cargo projects. We can add LLVM's library path to the -+ // platform-specific environment variable as a workaround. -+ if mode == Mode::ToolRustc { -+ if let Some(llvm_config) = self.llvm_config(target) { -+ let llvm_libdir = output(Command::new(&llvm_config).arg("--libdir")); -+ add_link_lib_path(vec![llvm_libdir.trim().into()], &mut cargo); -+ } -+ } -+ - if self.config.incremental { - cargo.env("CARGO_INCREMENTAL", "1"); - } else { -diff --git a/src/bootstrap/compile.rs b/src/bootstrap/compile.rs -index 65a00db33949..ad494b88b3af 100644 ---- a/src/bootstrap/compile.rs -+++ b/src/bootstrap/compile.rs -@@ -451,44 +451,6 @@ impl Step for Rustc { - false, - ); - -- // We used to build librustc_codegen_llvm as a separate step, -- // which produced a dylib that the compiler would dlopen() at runtime. -- // This meant that we only needed to make sure that libLLVM.so was -- // installed by the time we went to run a tool using it - since -- // librustc_codegen_llvm was effectively a standalone artifact, -- // other crates were completely oblivious to its dependency -- // on `libLLVM.so` during build time. -- // -- // However, librustc_codegen_llvm is now built as an ordinary -- // crate during the same step as the rest of the compiler crates. -- // This means that any crates depending on it will see the fact -- // that it uses `libLLVM.so` as a native library, and will -- // cause us to pass `-llibLLVM.so` to the linker when we link -- // a binary. -- // -- // For `rustc` itself, this works out fine. -- // During the `Assemble` step, we call `dist::maybe_install_llvm_dylib` -- // to copy libLLVM.so into the `stage` directory. We then link -- // the compiler binary, which will find `libLLVM.so` in the correct place. -- // -- // However, this is insufficient for tools that are build against stage0 -- // (e.g. stage1 rustdoc). Since `Assemble` for stage0 doesn't actually do anything, -- // we won't have `libLLVM.so` in the stage0 sysroot. In the past, this wasn't -- // a problem - we would copy the tool binary into its correct stage directory -- // (e.g. stage1 for a stage1 rustdoc built against a stage0 compiler). -- // Since libLLVM.so wasn't resolved until runtime, it was fine for it to -- // not exist while we were building it. -- // -- // To ensure that we can still build stage1 tools against a stage0 compiler, -- // we explicitly copy libLLVM.so into the stage0 sysroot when building -- // the stage0 compiler. This ensures that tools built against stage0 -- // will see libLLVM.so at build time, making the linker happy. -- if compiler.stage == 0 { -- builder.info(&format!("Installing libLLVM.so to stage 0 ({})", compiler.host)); -- let sysroot = builder.sysroot(compiler); -- dist::maybe_install_llvm_dylib(builder, compiler.host, &sysroot); -- } -- - builder.ensure(RustcLink { - compiler: builder.compiler(compiler.stage, builder.config.build), - target_compiler: compiler, -diff --git a/src/bootstrap/tool.rs b/src/bootstrap/tool.rs -index 67e0ed5c5802..c8ccba467e50 100644 ---- a/src/bootstrap/tool.rs -+++ b/src/bootstrap/tool.rs -@@ -12,7 +12,7 @@ use crate::channel; - use crate::channel::GitInfo; - use crate::compile; - use crate::toolstate::ToolState; --use crate::util::{add_lib_path, exe, CiEnv}; -+use crate::util::{add_dylib_path, exe, CiEnv}; - use crate::Compiler; - use crate::Mode; - -@@ -388,7 +388,7 @@ pub struct ErrorIndex { - impl ErrorIndex { - pub fn command(builder: &Builder<'_>, compiler: Compiler) -> Command { - let mut cmd = Command::new(builder.ensure(ErrorIndex { compiler })); -- add_lib_path( -+ add_dylib_path( - vec![PathBuf::from(&builder.sysroot_libdir(compiler, compiler.host))], - &mut cmd, - ); -@@ -689,7 +689,7 @@ impl<'a> Builder<'a> { - } - } - -- add_lib_path(lib_paths, &mut cmd); -+ add_dylib_path(lib_paths, &mut cmd); - cmd - } - } -diff --git a/src/bootstrap/util.rs b/src/bootstrap/util.rs -index eac790fe504b..2bc6f1939d97 100644 ---- a/src/bootstrap/util.rs -+++ b/src/bootstrap/util.rs -@@ -40,7 +40,7 @@ pub fn libdir(target: &str) -> &'static str { - } - - /// Adds a list of lookup paths to `cmd`'s dynamic library lookup path. --pub fn add_lib_path(path: Vec, cmd: &mut Command) { -+pub fn add_dylib_path(path: Vec, cmd: &mut Command) { - let mut list = dylib_path(); - for path in path { - list.insert(0, path); -@@ -72,6 +72,31 @@ pub fn dylib_path() -> Vec { - env::split_paths(&var).collect() - } - -+/// Adds a list of lookup paths to `cmd`'s link library lookup path. -+pub fn add_link_lib_path(path: Vec, cmd: &mut Command) { -+ let mut list = link_lib_path(); -+ for path in path { -+ list.insert(0, path); -+ } -+ cmd.env(link_lib_path_var(), t!(env::join_paths(list))); -+} -+ -+/// Returns the environment variable which the link library lookup path -+/// resides in for this platform. -+fn link_lib_path_var() -> &'static str { -+ if cfg!(target_env = "msvc") { "LIB" } else { "LIBRARY_PATH" } -+} -+ -+/// Parses the `link_lib_path_var()` environment variable, returning a list of -+/// paths that are members of this lookup path. -+fn link_lib_path() -> Vec { -+ let var = match env::var_os(link_lib_path_var()) { -+ Some(v) => v, -+ None => return vec![], -+ }; -+ env::split_paths(&var).collect() -+} -+ - /// `push` all components to `buf`. On windows, append `.exe` to the last component. - pub fn push_exe_path(mut buf: PathBuf, components: &[&str]) -> PathBuf { - let (&file, components) = components.split_last().expect("at least one component required"); diff --git a/rust-pr70163-prepare-for-llvm-10-upgrade.patch b/rust-pr70163-prepare-for-llvm-10-upgrade.patch deleted file mode 100644 index 765c2e9..0000000 --- a/rust-pr70163-prepare-for-llvm-10-upgrade.patch +++ /dev/null @@ -1,175 +0,0 @@ -commit 374ab25585f0a817fe7bd6986737f12347b12d0b (from 1add455ec6f81045e7651c6225902823f5d4fbfa) -Merge: 1add455ec6f8 497f879b1e24 -Author: bors -Date: Tue Mar 24 12:42:54 2020 +0000 - - Auto merge of #70163 - nikic:llvm-10-preparation, r=cuviper - - Prepare for LLVM 10 upgrade - - This is #67759 minus the submodule update. - - * Fix two compatibility issues in the rustllvm wrapper. - * Update data layout strings in tests. - * Fix LLVM version comparison (this become a problem because the major version has two digits now). - - r? @cuviper - -diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs -index aa1d1b7c4241..b52fbe4666eb 100644 ---- a/src/bootstrap/test.rs -+++ b/src/bootstrap/test.rs -@@ -1141,6 +1141,8 @@ impl Step for Compiletest { - let llvm_config = builder.ensure(native::Llvm { target: builder.config.build }); - if !builder.config.dry_run { - let llvm_version = output(Command::new(&llvm_config).arg("--version")); -+ // Remove trailing newline from llvm-config output. -+ let llvm_version = llvm_version.trim_end(); - cmd.arg("--llvm-version").arg(llvm_version); - } - if !builder.is_rust_llvm(target) { -diff --git a/src/rustllvm/PassWrapper.cpp b/src/rustllvm/PassWrapper.cpp -index 90d24d20737d..9e8614e3b6d3 100644 ---- a/src/rustllvm/PassWrapper.cpp -+++ b/src/rustllvm/PassWrapper.cpp -@@ -67,7 +67,11 @@ extern "C" void LLVMInitializePasses() { - } - - extern "C" void LLVMTimeTraceProfilerInitialize() { --#if LLVM_VERSION_GE(9, 0) -+#if LLVM_VERSION_GE(10, 0) -+ timeTraceProfilerInitialize( -+ /* TimeTraceGranularity */ 0, -+ /* ProcName */ "rustc"); -+#elif LLVM_VERSION_GE(9, 0) - timeTraceProfilerInitialize(); - #endif - } -diff --git a/src/rustllvm/RustWrapper.cpp b/src/rustllvm/RustWrapper.cpp -index 25cfee3373dc..799adb418822 100644 ---- a/src/rustllvm/RustWrapper.cpp -+++ b/src/rustllvm/RustWrapper.cpp -@@ -1333,8 +1333,13 @@ extern "C" LLVMValueRef LLVMRustBuildMemSet(LLVMBuilderRef B, - LLVMValueRef Dst, unsigned DstAlign, - LLVMValueRef Val, - LLVMValueRef Size, bool IsVolatile) { -+#if LLVM_VERSION_GE(10, 0) -+ return wrap(unwrap(B)->CreateMemSet( -+ unwrap(Dst), unwrap(Val), unwrap(Size), MaybeAlign(DstAlign), IsVolatile)); -+#else - return wrap(unwrap(B)->CreateMemSet( - unwrap(Dst), unwrap(Val), unwrap(Size), DstAlign, IsVolatile)); -+#endif - } - - extern "C" LLVMValueRef -diff --git a/src/test/run-make-fulldeps/target-specs/my-awesome-platform.json b/src/test/run-make-fulldeps/target-specs/my-awesome-platform.json -index 8d028280a8da..00de3de05f07 100644 ---- a/src/test/run-make-fulldeps/target-specs/my-awesome-platform.json -+++ b/src/test/run-make-fulldeps/target-specs/my-awesome-platform.json -@@ -1,5 +1,5 @@ - { -- "data-layout": "e-m:e-p:32:32-f64:32:64-f80:32-n8:16:32-S128", -+ "data-layout": "e-m:e-p:32:32-p270:32:32-p271:32:32-p272:64:64-f64:32:64-f80:32-n8:16:32-S128", - "linker-flavor": "gcc", - "llvm-target": "i686-unknown-linux-gnu", - "target-endian": "little", -diff --git a/src/test/run-make-fulldeps/target-specs/my-x86_64-unknown-linux-gnu-platform.json b/src/test/run-make-fulldeps/target-specs/my-x86_64-unknown-linux-gnu-platform.json -index 48040ae3da0e..6d5e964ed4fe 100644 ---- a/src/test/run-make-fulldeps/target-specs/my-x86_64-unknown-linux-gnu-platform.json -+++ b/src/test/run-make-fulldeps/target-specs/my-x86_64-unknown-linux-gnu-platform.json -@@ -1,6 +1,6 @@ - { - "pre-link-args": {"gcc": ["-m64"]}, -- "data-layout": "e-m:e-i64:64-f80:128-n8:16:32:64-S128", -+ "data-layout": "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128", - "linker-flavor": "gcc", - "llvm-target": "x86_64-unknown-linux-gnu", - "target-endian": "little", -diff --git a/src/tools/compiletest/src/header.rs b/src/tools/compiletest/src/header.rs -index 2a24a8c3c948..cb648db8830e 100644 ---- a/src/tools/compiletest/src/header.rs -+++ b/src/tools/compiletest/src/header.rs -@@ -191,6 +191,7 @@ impl EarlyProps { - return true; - } - if let Some(ref actual_version) = config.llvm_version { -+ let actual_version = version_to_int(actual_version); - if line.starts_with("min-llvm-version") { - let min_version = line - .trim_end() -@@ -199,7 +200,7 @@ impl EarlyProps { - .expect("Malformed llvm version directive"); - // Ignore if actual version is smaller the minimum required - // version -- &actual_version[..] < min_version -+ actual_version < version_to_int(min_version) - } else if line.starts_with("min-system-llvm-version") { - let min_version = line - .trim_end() -@@ -208,7 +209,7 @@ impl EarlyProps { - .expect("Malformed llvm version directive"); - // Ignore if using system LLVM and actual version - // is smaller the minimum required version -- config.system_llvm && &actual_version[..] < min_version -+ config.system_llvm && actual_version < version_to_int(min_version) - } else if line.starts_with("ignore-llvm-version") { - // Syntax is: "ignore-llvm-version [- ]" - let range_components = line -@@ -219,15 +220,15 @@ impl EarlyProps { - .take(3) // 3 or more = invalid, so take at most 3. - .collect::>(); - match range_components.len() { -- 1 => &actual_version[..] == range_components[0], -+ 1 => actual_version == version_to_int(range_components[0]), - 2 => { -- let v_min = range_components[0]; -- let v_max = range_components[1]; -+ let v_min = version_to_int(range_components[0]); -+ let v_max = version_to_int(range_components[1]); - if v_max < v_min { - panic!("Malformed LLVM version range: max < min") - } - // Ignore if version lies inside of range. -- &actual_version[..] >= v_min && &actual_version[..] <= v_max -+ actual_version >= v_min && actual_version <= v_max - } - _ => panic!("Malformed LLVM version directive"), - } -@@ -238,6 +239,20 @@ impl EarlyProps { - false - } - } -+ -+ fn version_to_int(version: &str) -> u32 { -+ let version_without_suffix = version.split('-').next().unwrap(); -+ let components: Vec = version_without_suffix -+ .split('.') -+ .map(|s| s.parse().expect("Malformed version component")) -+ .collect(); -+ match components.len() { -+ 1 => components[0] * 10000, -+ 2 => components[0] * 10000 + components[1] * 100, -+ 3 => components[0] * 10000 + components[1] * 100 + components[2], -+ _ => panic!("Malformed version"), -+ } -+ } - } - } - -diff --git a/src/tools/compiletest/src/header/tests.rs b/src/tools/compiletest/src/header/tests.rs -index 6c478f7e29da..31d991e0c2f8 100644 ---- a/src/tools/compiletest/src/header/tests.rs -+++ b/src/tools/compiletest/src/header/tests.rs -@@ -122,9 +122,8 @@ fn llvm_version() { - config.llvm_version = Some("9.3.1-rust-1.43.0-dev".to_owned()); - assert!(!parse_rs(&config, "// min-llvm-version 9.2").ignore); - -- // FIXME. -- // config.llvm_version = Some("10.0.0-rust".to_owned()); -- // assert!(!parse_rs(&config, "// min-llvm-version 9.0").ignore); -+ config.llvm_version = Some("10.0.0-rust".to_owned()); -+ assert!(!parse_rs(&config, "// min-llvm-version 9.0").ignore); - } - - #[test] diff --git a/rust-pr70591-ensure-llvm-is-in-the-link-path.patch b/rust-pr70591-ensure-llvm-is-in-the-link-path.patch deleted file mode 100644 index 9f5722b..0000000 --- a/rust-pr70591-ensure-llvm-is-in-the-link-path.patch +++ /dev/null @@ -1,40 +0,0 @@ -commit 6067315d58ff3d49b305ae3c99810656856c8e21 -Author: Josh Stone -Date: Mon Mar 30 14:03:39 2020 -0700 - - Ensure LLVM is in the link path for "fulldeps" tests - - This is a follow-up to #70123, which added `llvm-config --libdir` to the - `LIBRARY_PATH` for rustc tools. We need the same for "run-make-fulldeps" - and "ui-fulldeps" tests which depend on compiler libraries, implicitly - needing to link to `-lLLVM` as well. - -diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs -index 5b946b05735d..2499856235f1 100644 ---- a/src/bootstrap/test.rs -+++ b/src/bootstrap/test.rs -@@ -21,7 +21,7 @@ use crate::flags::Subcommand; - use crate::native; - use crate::tool::{self, SourceType, Tool}; - use crate::toolstate::ToolState; --use crate::util::{self, dylib_path, dylib_path_var}; -+use crate::util::{self, add_link_lib_path, dylib_path, dylib_path_var}; - use crate::Crate as CargoCrate; - use crate::{envify, DocTests, GitRepo, Mode}; - -@@ -1178,6 +1178,15 @@ impl Step for Compiletest { - cmd.arg("--system-llvm"); - } - -+ // Tests that use compiler libraries may inherit the `-lLLVM` link -+ // requirement, but the `-L` library path is not propagated across -+ // separate compilations. We can add LLVM's library path to the -+ // platform-specific environment variable as a workaround. -+ if !builder.config.dry_run && suite.ends_with("fulldeps") { -+ let llvm_libdir = output(Command::new(&llvm_config).arg("--libdir")); -+ add_link_lib_path(vec![llvm_libdir.trim().into()], &mut cmd); -+ } -+ - // Only pass correct values for these flags for the `run-make` suite as it - // requires that a C++ compiler was configured which isn't always the case. - if !builder.config.dry_run && suite == "run-make-fulldeps" { diff --git a/rust-pr71782-Use-a-non-existent-test-path.patch b/rust-pr71782-Use-a-non-existent-test-path.patch index df02449..463cb61 100644 --- a/rust-pr71782-Use-a-non-existent-test-path.patch +++ b/rust-pr71782-Use-a-non-existent-test-path.patch @@ -49,7 +49,7 @@ index f732abc52b71..edadecf273a7 100644 -error: io error modifying /dev/ +error: io error modifying /does-not-exist/ - error: aborting due to previous error + error: aborting due to previous error; 1 warning emitted -- 2.26.2 diff --git a/rust.spec b/rust.spec index 05ea3f7..be67f20 100644 --- a/rust.spec +++ b/rust.spec @@ -9,10 +9,10 @@ # e.g. 1.10.0 wants rustc: 1.9.0-2016-05-24 # or nightly wants some beta-YYYY-MM-DD # Note that cargo matches the program version here, not its crate version. -%global bootstrap_rust 1.42.0 -%global bootstrap_cargo 1.42.0 -%global bootstrap_channel 1.42.0 -%global bootstrap_date 2020-03-12 +%global bootstrap_rust 1.43.1 +%global bootstrap_cargo 1.43.1 +%global bootstrap_channel 1.43.1 +%global bootstrap_date 2020-05-07 # Only the specified arches will use bootstrap binaries. #global bootstrap_arches %%{rust_arches} @@ -48,7 +48,7 @@ %endif Name: rust -Version: 1.43.1 +Version: 1.44.0 Release: 1%{?dist} Summary: The Rust Programming Language License: (ASL 2.0 or MIT) and (BSD and MIT) @@ -63,22 +63,8 @@ ExclusiveArch: %{rust_arches} %endif Source0: https://static.rust-lang.org/dist/%{rustc_package}.tar.xz -# Revert https://github.com/rust-lang/rust/pull/57840 -# We do have the necessary fix in our LLVM 7. -Patch1: rust-pr57840-llvm7-debuginfo-variants.patch - -# Ensure LLVM is in the link path for rustc tools and "fulldeps" tests -# https://github.com/rust-lang/rust/pull/70123 -# https://github.com/rust-lang/rust/pull/70591 -Patch2: rust-pr70123-ensure-llvm-is-in-the-link-path.patch -Patch3: rust-pr70591-ensure-llvm-is-in-the-link-path.patch - -# Prepare for LLVM 10 upgrade -# https://github.com/rust-lang/rust/pull/70163 -Patch4: rust-pr70163-prepare-for-llvm-10-upgrade.patch - # https://github.com/rust-lang/rust/pull/71782 -Patch5: rust-pr71782-Use-a-non-existent-test-path.patch +Patch1: rust-pr71782-Use-a-non-existent-test-path.patch # Get the Rust triple for any arch. %{lua: function rust_triple(arch) @@ -143,7 +129,7 @@ BuildRequires: pkgconfig(openssl) BuildRequires: pkgconfig(zlib) %if %without bundled_libgit2 -BuildRequires: pkgconfig(libgit2) >= 0.27 +BuildRequires: pkgconfig(libgit2) >= 1.0.0 %endif %if %without bundled_libssh2 @@ -160,11 +146,11 @@ BuildRequires: %{python} %if %with bundled_llvm BuildRequires: cmake3 >= 3.4.3 -Provides: bundled(llvm) = 9.0.0 +Provides: bundled(llvm) = 9.0.1 %else BuildRequires: cmake >= 2.8.11 %if 0%{?epel} -%global llvm llvm7.0 +%global llvm llvm9.0 %endif %if %defined llvm %global llvm_root %{_libdir}/%{llvm} @@ -172,7 +158,7 @@ BuildRequires: cmake >= 2.8.11 %global llvm llvm %global llvm_root %{_prefix} %endif -BuildRequires: %{llvm}-devel >= 7.0 +BuildRequires: %{llvm}-devel >= 8.0 %if %with llvm_static BuildRequires: %{llvm}-static BuildRequires: libffi-devel @@ -186,7 +172,7 @@ BuildRequires: procps-ng BuildRequires: gdb # TODO: work on unbundling these! -Provides: bundled(libbacktrace) = 8.1.0 +Provides: bundled(libbacktrace) = 1.0.20200219 # Virtual provides for folks who attempt "dnf install rustc" Provides: rustc = %{version}-%{release} @@ -297,7 +283,7 @@ its standard library. %package -n cargo Summary: Rust's package manager and build tool %if %with bundled_libgit2 -Provides: bundled(libgit2) = 0.99.0 +Provides: bundled(libgit2) = 1.0.0 %endif %if %with bundled_libssh2 Provides: bundled(libssh2) = 1.9.0~dev @@ -343,7 +329,7 @@ A tool for formatting Rust code according to style guidelines. %package -n rls Summary: Rust Language Server for IDE integration %if %with bundled_libgit2 -Provides: bundled(libgit2) = 0.99.0 +Provides: bundled(libgit2) = 1.0.0 %endif %if %with bundled_libssh2 Provides: bundled(libssh2) = 1.9.0~dev @@ -408,11 +394,7 @@ test -f '%{local_rust_root}/bin/rustc' %setup -q -n %{rustc_package} -%patch1 -p1 -R -%patch2 -p1 -%patch3 -p1 -%patch4 -p1 -%patch5 -p1 +%patch1 -p1 %if "%{python}" == "python3" sed -i.try-py3 -e '/try python2.7/i try python3 "$@"' ./configure @@ -718,6 +700,9 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %changelog +* Thu Jun 04 2020 Josh Stone - 1.44.0-1 +- Update to 1.44.0. + * Thu May 07 2020 Josh Stone - 1.43.1-1 - Update to 1.43.1. diff --git a/sources b/sources index fb9b958..f09abf1 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (rustc-1.43.1-src.tar.xz) = 24bb01237b1f3f5412109290bb4406b9742cf8956162f4090a98ed3a59a6e2e8dda399452bec1c93c8afdcf5effd98e4825e7f218238e0e88735c1ff4a5b385f +SHA512 (rustc-1.44.0-src.tar.xz) = 03d6a2ec4c80eb436b278677080f360912c60aacffb98b79c91d5a79967ef988b2e62ccff9ab26993f852cebd62cdad48e149c4498f6dcdeb3699cbed19790e4 diff --git a/sources-bootstrap b/sources-bootstrap index f2aa62c..2f70374 100644 --- a/sources-bootstrap +++ b/sources-bootstrap @@ -1,8 +1,8 @@ -SHA512 (rustc-1.43.1-src.tar.xz) = 24bb01237b1f3f5412109290bb4406b9742cf8956162f4090a98ed3a59a6e2e8dda399452bec1c93c8afdcf5effd98e4825e7f218238e0e88735c1ff4a5b385f -SHA512 (rust-1.42.0-aarch64-unknown-linux-gnu.tar.xz) = 691a11e279efdcafa6bdafacb7fb48ccf653e180e0e85909b6031105a297d47538efb36d63216f6185427f818483a51aa827f351ca2123840d72caf60079fe13 -SHA512 (rust-1.42.0-armv7-unknown-linux-gnueabihf.tar.xz) = 26768ec530506e20fed8f9ef2c1ca85eec155fc90949f2063836b6109b296a976c8430a698971a8b1c11e8f6ad043d854a36e9f0e849417178411dc5cbd30e59 -SHA512 (rust-1.42.0-i686-unknown-linux-gnu.tar.xz) = 7376be5abed573bbf68f73ed5609fa8e22dfa3ead19a3f3d78d553347e3ae01604ab9906f5317f1687a8ab3f9ad9c38cde44ef6f56d7da65a788a74aee9df057 -SHA512 (rust-1.42.0-powerpc64le-unknown-linux-gnu.tar.xz) = e1db9bbef45e88e7d1d5b905379c04786a015c90d0d9de6a6c16276a3e91c342a8231dda7a4d46ecc7adc969d07fd7dd8595975647b9ab69f8997fee74401219 -SHA512 (rust-1.42.0-powerpc64-unknown-linux-gnu.tar.xz) = 668d1d353bdaf676043ab7f4baad464b202e8ae1be7713e3481b8e9fb5fabd1020e10e178d69d099541cb1b23362b50b826790740156f1c96efa3d2a7457e404 -SHA512 (rust-1.42.0-s390x-unknown-linux-gnu.tar.xz) = 85b1331a9a71cc43a2fa628b8510590ff072e409c2c38ebfd9089ab7a245182e23b52f6221b25c63f6048e1bf4ada0f561dd8f3f810680c9727040bc8a0d8d46 -SHA512 (rust-1.42.0-x86_64-unknown-linux-gnu.tar.xz) = 87c06d4503e7ba12bd3dfc8dd279a3bdf33a24d2c22eec1378b79b2c17ccdad9b4c8dbd0d4704eae1f3476aec5639d3ba143e8c74a296d631b17b57da7447e70 +SHA512 (rustc-1.44.0-src.tar.xz) = 03d6a2ec4c80eb436b278677080f360912c60aacffb98b79c91d5a79967ef988b2e62ccff9ab26993f852cebd62cdad48e149c4498f6dcdeb3699cbed19790e4 +SHA512 (rust-1.43.1-aarch64-unknown-linux-gnu.tar.xz) = b54fad5493344d2370bd77110f0ffb0231f41ab8aa9707e9303304957c5d9067dc83089432eb175605b78dc771dfcf7abfcce63d7fecdbb759dd224c17d12da0 +SHA512 (rust-1.43.1-armv7-unknown-linux-gnueabihf.tar.xz) = 0812b3229dd47f1b5cadb49020e68d28b4267ac0489d0c2e448f21e3b0b6519bbf216ac9b20b747e035033842a6eb3b13a98706f2eddca2c088d9396dcb2c21e +SHA512 (rust-1.43.1-i686-unknown-linux-gnu.tar.xz) = c7423bccfb15f3df6043ec1d81203c9db9b3229dedd347cab09d3cc3b183f53aa0707f59964efccd63418e1c6ad21e7ee7dcc1495eda8c4ecb55ee8e6b3ac034 +SHA512 (rust-1.43.1-powerpc64le-unknown-linux-gnu.tar.xz) = da447ec44ebf998290a73420437c8d434a6c196cfe1c3331a9adf40abf7acd97a231e352a8626bbfa961da8e0c4f450aa59d573254257f72cce4068eeb8112a1 +SHA512 (rust-1.43.1-powerpc64-unknown-linux-gnu.tar.xz) = 695591807892c8f08801cd145ebc6a91ee4222000210baaaa0d6c8acf1ac6a96f4bf2566871def04d15a9965b7e3ea4287e37d7851fb14010518694d8ede75e6 +SHA512 (rust-1.43.1-s390x-unknown-linux-gnu.tar.xz) = f087e50a91b1cc4a12bf15aea1cefbda9b89518febcecc0d56ea7d0a6a682be06cff7777d0a0b4812e96f3fb3295e7799bf200c1599c88cb7083a78d5002f14a +SHA512 (rust-1.43.1-x86_64-unknown-linux-gnu.tar.xz) = 2fc573ca2826d9f03044f746ae4d7715b4e31b9ac933289607aa3449a538bb4dfd519540576a1d0d286c0d754a7ba6ce38beef6aded1090d3af3091b6ba2a9ee From 560777dfc7cdaaeab49b31414cefbbd9ace9b844 Mon Sep 17 00:00:00 2001 From: Josh Stone Date: Thu, 18 Jun 2020 09:47:06 -0700 Subject: [PATCH 4/5] Update to 1.44.1. --- .gitignore | 1 + rust.spec | 5 ++++- sources | 2 +- sources-bootstrap | 2 +- 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 5d48bd7..e840b80 100644 --- a/.gitignore +++ b/.gitignore @@ -278,3 +278,4 @@ /rust-1.43.1-powerpc64-unknown-linux-gnu.tar.xz /rust-1.43.1-s390x-unknown-linux-gnu.tar.xz /rust-1.43.1-x86_64-unknown-linux-gnu.tar.xz +/rustc-1.44.1-src.tar.xz diff --git a/rust.spec b/rust.spec index be67f20..288b310 100644 --- a/rust.spec +++ b/rust.spec @@ -48,7 +48,7 @@ %endif Name: rust -Version: 1.44.0 +Version: 1.44.1 Release: 1%{?dist} Summary: The Rust Programming Language License: (ASL 2.0 or MIT) and (BSD and MIT) @@ -700,6 +700,9 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %changelog +* Thu Jun 18 2020 Josh Stone - 1.44.1-1 +- Update to 1.44.1. + * Thu Jun 04 2020 Josh Stone - 1.44.0-1 - Update to 1.44.0. diff --git a/sources b/sources index f09abf1..381d691 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (rustc-1.44.0-src.tar.xz) = 03d6a2ec4c80eb436b278677080f360912c60aacffb98b79c91d5a79967ef988b2e62ccff9ab26993f852cebd62cdad48e149c4498f6dcdeb3699cbed19790e4 +SHA512 (rustc-1.44.1-src.tar.xz) = 1c17002edae844a710db9b144c17171416330dc565343c65af8a6e112fb61555e2025bb4cf33cac1229d7df689e6ff8858b91ae00552400ccacafaf1de11849b diff --git a/sources-bootstrap b/sources-bootstrap index 2f70374..82332cc 100644 --- a/sources-bootstrap +++ b/sources-bootstrap @@ -1,4 +1,4 @@ -SHA512 (rustc-1.44.0-src.tar.xz) = 03d6a2ec4c80eb436b278677080f360912c60aacffb98b79c91d5a79967ef988b2e62ccff9ab26993f852cebd62cdad48e149c4498f6dcdeb3699cbed19790e4 +SHA512 (rustc-1.44.1-src.tar.xz) = 1c17002edae844a710db9b144c17171416330dc565343c65af8a6e112fb61555e2025bb4cf33cac1229d7df689e6ff8858b91ae00552400ccacafaf1de11849b SHA512 (rust-1.43.1-aarch64-unknown-linux-gnu.tar.xz) = b54fad5493344d2370bd77110f0ffb0231f41ab8aa9707e9303304957c5d9067dc83089432eb175605b78dc771dfcf7abfcce63d7fecdbb759dd224c17d12da0 SHA512 (rust-1.43.1-armv7-unknown-linux-gnueabihf.tar.xz) = 0812b3229dd47f1b5cadb49020e68d28b4267ac0489d0c2e448f21e3b0b6519bbf216ac9b20b747e035033842a6eb3b13a98706f2eddca2c088d9396dcb2c21e SHA512 (rust-1.43.1-i686-unknown-linux-gnu.tar.xz) = c7423bccfb15f3df6043ec1d81203c9db9b3229dedd347cab09d3cc3b183f53aa0707f59964efccd63418e1c6ad21e7ee7dcc1495eda8c4ecb55ee8e6b3ac034 From bd38d989dcc7f2a05c8f54a14e55d161f151e0ee Mon Sep 17 00:00:00 2001 From: Jeff Law Date: Wed, 1 Jul 2020 15:31:23 -0600 Subject: [PATCH 5/5] Disable LTO --- rust.spec | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/rust.spec b/rust.spec index 288b310..df8f12e 100644 --- a/rust.spec +++ b/rust.spec @@ -49,7 +49,7 @@ Name: rust Version: 1.44.1 -Release: 1%{?dist} +Release: 2%{?dist} Summary: The Rust Programming Language License: (ASL 2.0 or MIT) and (BSD and MIT) # ^ written as: (rust itself) and (bundled libraries) @@ -450,6 +450,11 @@ find -name '*.rs' -type f -perm /111 -exec chmod -v -x '{}' '+' %build +# This package fails to build with LTO due to undefined symbols. LTO +# was disabled in OpenSuSE as well, but with no real explanation why +# beyond the undefined symbols. It really should be investigated further. +# Disable LTO +%define _lto_cflags %{nil} %if %without bundled_libgit2 # convince libgit2-sys to use the distro libgit2 @@ -700,6 +705,9 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %changelog +* Wed Jul 01 2020 Josh Stone - 1.44.1-2 +- Disable LTO + * Thu Jun 18 2020 Josh Stone - 1.44.1-1 - Update to 1.44.1.