summaryrefslogtreecommitdiff
path: root/dev-lang/rust
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-04-17 21:43:14 +0100
committerV3n3RiX <venerix@redcorelinux.org>2020-04-17 21:43:14 +0100
commit7a7ff7921b4584e327f5773c27352eeaedb34108 (patch)
treee21358e0ba85e1d0ba8a693c14ce8b678f338e93 /dev-lang/rust
parent6550b9c252ae2176fd491c0826aa1755f2a1d8d1 (diff)
dev-lang/rust : version bump
Diffstat (limited to 'dev-lang/rust')
-rw-r--r--dev-lang/rust/Manifest4
-rw-r--r--dev-lang/rust/files/1.42.0-fix-bootstrap.patch440
-rw-r--r--dev-lang/rust/files/1.42.0-libressl.patch43
-rw-r--r--dev-lang/rust/files/llvm-gcc10.patch34
-rw-r--r--dev-lang/rust/rust-1.42.0-r10.ebuild (renamed from dev-lang/rust/rust-1.41.0-r10.ebuild)54
5 files changed, 516 insertions, 59 deletions
diff --git a/dev-lang/rust/Manifest b/dev-lang/rust/Manifest
index 75923239..1436c9f3 100644
--- a/dev-lang/rust/Manifest
+++ b/dev-lang/rust/Manifest
@@ -1,2 +1,2 @@
-DIST rust-1.40.0-x86_64-unknown-linux-gnu.tar.xz 110186516 BLAKE2B ad89d8cecbd565b23c98ec095bad218de971cb4bb89924bbcb012df6c9ecf0db2b50d624abdf6b050fe1f5067aea9311dc01852950a5ca5e993e99f913fc5dbc SHA512 11a2ad1d8b9e91cbe9ee6a1954d46ac75eeaa83f0c2425a8ad70d191727b02e86ead33d6464222effca6f5134c31a165801a854aa57bdb5f12944d605de3c1d1
-DIST rustc-1.41.0-src.tar.xz 93763052 BLAKE2B a68524fb6e3abb43d52ae6676a1e9de1c5d33606eaea6e93bb518f10b196d620f2f370c631c32e39a624af71a3bf6911662a9df7eecb8dde78a20c8054a349fc SHA512 0e30fe53b77860085bea0f1f60315eb835b00dd796c5d1b98ed44fe6fc27336dfb064908c86e1669a9cbe81c9ca1495e1c259a8a268bef23b23805a719cef0dd
+DIST rust-1.41.1-x86_64-unknown-linux-gnu.tar.xz 111202140 BLAKE2B 226c68b1e97cc9be82e81f6c9e065e08514166a65a57159c2f63527063ae5f514650afc2591e0c4854ecd0239dc82cbc9a97b99412608645aca879a71354d857 SHA512 c75d4a18cf9300c6ab480d34c5e4b41be971535931455239330cb2a0e927bcf9cf102498cad5dd1d5d802fd1d9c9d214b80e8ff15aa6be68d3e7f41420cad666
+DIST rustc-1.42.0-src.tar.xz 94186592 BLAKE2B 82298ef3da44188546bb945bcbfc1af630e6a4466b643667da08a04a33c6417afd68fc86302bdd22ab36c208fdb13cbc479e762d1217c05507bbfeb13bfbef7e SHA512 589bfdc92deedd33b8ea0df7f7c64c2a9a085fbea64936eff92f81e812309c060ed7a7adc96f6010d7adf62a68434a230da0f6c5b3540df4e0a5c6de05a31b16
diff --git a/dev-lang/rust/files/1.42.0-fix-bootstrap.patch b/dev-lang/rust/files/1.42.0-fix-bootstrap.patch
new file mode 100644
index 00000000..16e4e6dc
--- /dev/null
+++ b/dev-lang/rust/files/1.42.0-fix-bootstrap.patch
@@ -0,0 +1,440 @@
+From 5f979e9afab42dd7536ca93994de66169880361e Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Matthias=20Kr=C3=BCger?= <matthias.krueger@famsik.de>
+Date: Mon, 3 Feb 2020 20:13:30 +0100
+Subject: [PATCH] bootstrap: fix clippy warnings
+
+---
+ src/bootstrap/bin/rustc.rs | 6 +++---
+ src/bootstrap/bin/rustdoc.rs | 2 +-
+ src/bootstrap/builder.rs | 24 ++++++++----------------
+ src/bootstrap/builder/tests.rs | 1 -
+ src/bootstrap/compile.rs | 20 ++++++++++----------
+ src/bootstrap/config.rs | 7 +++----
+ src/bootstrap/dist.rs | 4 ++--
+ src/bootstrap/doc.rs | 2 +-
+ src/bootstrap/flags.rs | 2 +-
+ src/bootstrap/install.rs | 5 ++---
+ src/bootstrap/lib.rs | 6 +++---
+ src/bootstrap/metadata.rs | 1 -
+ src/bootstrap/native.rs | 4 +---
+ src/bootstrap/test.rs | 9 +++------
+ src/bootstrap/tool.rs | 2 +-
+ src/bootstrap/toolstate.rs | 2 +-
+ src/bootstrap/util.rs | 2 +-
+ 17 files changed, 41 insertions(+), 58 deletions(-)
+
+diff --git a/src/bootstrap/bin/rustc.rs b/src/bootstrap/bin/rustc.rs
+index a34ec44566bc..a8c00c8c3ca8 100644
+--- a/src/bootstrap/bin/rustc.rs
++++ b/src/bootstrap/bin/rustc.rs
+@@ -47,7 +47,7 @@ fn main() {
+ };
+ let stage = env::var("RUSTC_STAGE").expect("RUSTC_STAGE was not set");
+ let sysroot = env::var_os("RUSTC_SYSROOT").expect("RUSTC_SYSROOT was not set");
+- let on_fail = env::var_os("RUSTC_ON_FAIL").map(|of| Command::new(of));
++ let on_fail = env::var_os("RUSTC_ON_FAIL").map(Command::new);
+
+ let rustc = env::var_os(rustc).unwrap_or_else(|| panic!("{:?} was not set", rustc));
+ let libdir = env::var_os(libdir).unwrap_or_else(|| panic!("{:?} was not set", libdir));
+@@ -64,7 +64,7 @@ fn main() {
+ if let Some(crate_name) = crate_name {
+ if let Some(target) = env::var_os("RUSTC_TIME") {
+ if target == "all"
+- || target.into_string().unwrap().split(",").any(|c| c.trim() == crate_name)
++ || target.into_string().unwrap().split(',').any(|c| c.trim() == crate_name)
+ {
+ cmd.arg("-Ztime");
+ }
+@@ -189,7 +189,7 @@ fn main() {
+ crate_name,
+ is_test,
+ dur.as_secs(),
+- dur.subsec_nanos() / 1_000_000
++ dur.subsec_millis()
+ );
+
+ match status.code() {
+diff --git a/src/bootstrap/bin/rustdoc.rs b/src/bootstrap/bin/rustdoc.rs
+index 8c8b33a4e4e0..04345867bf5c 100644
+--- a/src/bootstrap/bin/rustdoc.rs
++++ b/src/bootstrap/bin/rustdoc.rs
+@@ -61,7 +61,7 @@ fn main() {
+ }
+
+ // Needed to be able to run all rustdoc tests.
+- if let Some(_) = env::var_os("RUSTDOC_GENERATE_REDIRECT_PAGES") {
++ if env::var_os("RUSTDOC_GENERATE_REDIRECT_PAGES").is_some() {
+ // This "unstable-options" can be removed when `--generate-redirect-pages` is stabilized
+ if !has_unstable {
+ cmd.arg("-Z").arg("unstable-options");
+diff --git a/src/bootstrap/builder.rs b/src/bootstrap/builder.rs
+index d9c894aa9c6b..18f6fda76084 100644
+--- a/src/bootstrap/builder.rs
++++ b/src/bootstrap/builder.rs
+@@ -510,7 +510,7 @@ impl<'a> Builder<'a> {
+ Subcommand::Format { .. } | Subcommand::Clean { .. } => panic!(),
+ };
+
+- let builder = Builder {
++ Builder {
+ build,
+ top_stage: build.config.stage.unwrap_or(2),
+ kind,
+@@ -518,9 +518,7 @@ impl<'a> Builder<'a> {
+ stack: RefCell::new(Vec::new()),
+ time_spent_on_dependencies: Cell::new(Duration::new(0, 0)),
+ paths: paths.to_owned(),
+- };
+-
+- builder
++ }
+ }
+
+ pub fn execute_cli(&self) {
+@@ -753,13 +751,12 @@ impl<'a> Builder<'a> {
+ cargo.env("RUST_CHECK", "1");
+ }
+
+- let stage;
+- if compiler.stage == 0 && self.local_rebuild {
++ let stage = if compiler.stage == 0 && self.local_rebuild {
+ // Assume the local-rebuild rustc already has stage1 features.
+- stage = 1;
++ 1
+ } else {
+- stage = compiler.stage;
+- }
++ compiler.stage
++ };
+
+ let mut rustflags = Rustflags::new(&target);
+ if stage != 0 {
+@@ -1252,12 +1249,7 @@ impl<'a> Builder<'a> {
+ };
+
+ if self.config.print_step_timings && dur > Duration::from_millis(100) {
+- println!(
+- "[TIMING] {:?} -- {}.{:03}",
+- step,
+- dur.as_secs(),
+- dur.subsec_nanos() / 1_000_000
+- );
++ println!("[TIMING] {:?} -- {}.{:03}", step, dur.as_secs(), dur.subsec_millis());
+ }
+
+ {
+@@ -1302,7 +1294,7 @@ impl Rustflags {
+
+ fn arg(&mut self, arg: &str) -> &mut Self {
+ assert_eq!(arg.split_whitespace().count(), 1);
+- if self.0.len() > 0 {
++ if !self.0.is_empty() {
+ self.0.push_str(" ");
+ }
+ self.0.push_str(arg);
+diff --git a/src/bootstrap/builder/tests.rs b/src/bootstrap/builder/tests.rs
+index 5fefb972866a..cca8ab80c93b 100644
+--- a/src/bootstrap/builder/tests.rs
++++ b/src/bootstrap/builder/tests.rs
+@@ -19,7 +19,6 @@ fn configure(host: &[&str], target: &[&str]) -> Config {
+ config.out = dir;
+ config.build = INTERNER.intern_str("A");
+ config.hosts = vec![config.build]
+- .clone()
+ .into_iter()
+ .chain(host.iter().map(|s| INTERNER.intern_str(s)))
+ .collect::<Vec<_>>();
+diff --git a/src/bootstrap/compile.rs b/src/bootstrap/compile.rs
+index eced03506ab9..7dded96e18ef 100644
+--- a/src/bootstrap/compile.rs
++++ b/src/bootstrap/compile.rs
+@@ -18,7 +18,6 @@ use std::str;
+ use build_helper::{output, t, up_to_date};
+ use filetime::FileTime;
+ use serde::Deserialize;
+-use serde_json;
+
+ use crate::builder::Cargo;
+ use crate::dist;
+@@ -149,7 +148,8 @@ fn copy_third_party_objects(
+ // which is provided by std for this target.
+ if target == "x86_64-fortanix-unknown-sgx" {
+ let src_path_env = "X86_FORTANIX_SGX_LIBS";
+- let src = env::var(src_path_env).expect(&format!("{} not found in env", src_path_env));
++ let src =
++ env::var(src_path_env).unwrap_or_else(|_| panic!("{} not found in env", src_path_env));
+ copy_and_stamp(Path::new(&src), "libunwind.a");
+ }
+
+@@ -361,7 +361,7 @@ impl Step for StartupObjects {
+ );
+ }
+
+- let target = sysroot_dir.join(file.to_string() + ".o");
++ let target = sysroot_dir.join((*file).to_string() + ".o");
+ builder.copy(dst_file, &target);
+ target_deps.push(target);
+ }
+@@ -515,7 +515,7 @@ pub fn rustc_cargo_env(builder: &Builder<'_>, cargo: &mut Cargo, target: Interne
+ .env("CFG_VERSION", builder.rust_version())
+ .env("CFG_PREFIX", builder.config.prefix.clone().unwrap_or_default());
+
+- let libdir_relative = builder.config.libdir_relative().unwrap_or(Path::new("lib"));
++ let libdir_relative = builder.config.libdir_relative().unwrap_or_else(|| Path::new("lib"));
+ cargo.env("CFG_LIBDIR_RELATIVE", libdir_relative);
+
+ if let Some(ref ver_date) = builder.rust_info.commit_date() {
+@@ -843,11 +843,11 @@ pub fn run_cargo(
+ };
+ for filename in filenames {
+ // Skip files like executables
+- if !filename.ends_with(".rlib")
+- && !filename.ends_with(".lib")
+- && !filename.ends_with(".a")
+- && !is_dylib(&filename)
+- && !(is_check && filename.ends_with(".rmeta"))
++ if !(filename.ends_with(".rlib")
++ || filename.ends_with(".lib")
++ || filename.ends_with(".a")
++ || is_dylib(&filename)
++ || (is_check && filename.ends_with(".rmeta")))
+ {
+ continue;
+ }
+@@ -905,7 +905,7 @@ pub fn run_cargo(
+ for (prefix, extension, expected_len) in toplevel {
+ let candidates = contents.iter().filter(|&&(_, ref filename, ref meta)| {
+ filename.starts_with(&prefix[..])
+- && filename[prefix.len()..].starts_with("-")
++ && filename[prefix.len()..].starts_with('-')
+ && filename.ends_with(&extension[..])
+ && meta.len() == expected_len
+ });
+diff --git a/src/bootstrap/config.rs b/src/bootstrap/config.rs
+index 110c8b844d54..709cf2908ead 100644
+--- a/src/bootstrap/config.rs
++++ b/src/bootstrap/config.rs
+@@ -16,7 +16,6 @@ use crate::flags::Flags;
+ pub use crate::flags::Subcommand;
+ use build_helper::t;
+ use serde::Deserialize;
+-use toml;
+
+ /// Global configuration for the entire build and/or bootstrap.
+ ///
+@@ -440,7 +439,7 @@ impl Config {
+ }
+ }
+ })
+- .unwrap_or_else(|| TomlConfig::default());
++ .unwrap_or_else(TomlConfig::default);
+
+ let build = toml.build.clone().unwrap_or_default();
+ // set by bootstrap.py
+@@ -539,7 +538,7 @@ impl Config {
+ config.llvm_ldflags = llvm.ldflags.clone();
+ set(&mut config.llvm_use_libcxx, llvm.use_libcxx);
+ config.llvm_use_linker = llvm.use_linker.clone();
+- config.llvm_allow_old_toolchain = llvm.allow_old_toolchain.clone();
++ config.llvm_allow_old_toolchain = llvm.allow_old_toolchain;
+ }
+
+ if let Some(ref rust) = toml.rust {
+@@ -606,7 +605,7 @@ impl Config {
+ target.ar = cfg.ar.clone().map(PathBuf::from);
+ target.ranlib = cfg.ranlib.clone().map(PathBuf::from);
+ target.linker = cfg.linker.clone().map(PathBuf::from);
+- target.crt_static = cfg.crt_static.clone();
++ target.crt_static = cfg.crt_static;
+ target.musl_root = cfg.musl_root.clone().map(PathBuf::from);
+ target.wasi_root = cfg.wasi_root.clone().map(PathBuf::from);
+ target.qemu_rootfs = cfg.qemu_rootfs.clone().map(PathBuf::from);
+diff --git a/src/bootstrap/dist.rs b/src/bootstrap/dist.rs
+index 8d13df3ee21a..651506dbaa8a 100644
+--- a/src/bootstrap/dist.rs
++++ b/src/bootstrap/dist.rs
+@@ -827,7 +827,7 @@ impl Step for Analysis {
+ assert!(builder.config.extended);
+ let name = pkgname(builder, "rust-analysis");
+
+- if &compiler.host != builder.config.build {
++ if compiler.host != builder.config.build {
+ return distdir(builder).join(format!("{}-{}.tar.gz", name, target));
+ }
+
+@@ -876,7 +876,7 @@ fn copy_src_dirs(builder: &Builder<'_>, src_dirs: &[&str], exclude_dirs: &[&str]
+ Some(path) => path,
+ None => return false,
+ };
+- if spath.ends_with("~") || spath.ends_with(".pyc") {
++ if spath.ends_with('~') || spath.ends_with(".pyc") {
+ return false;
+ }
+
+diff --git a/src/bootstrap/doc.rs b/src/bootstrap/doc.rs
+index 204056598d90..b0d9a5b94641 100644
+--- a/src/bootstrap/doc.rs
++++ b/src/bootstrap/doc.rs
+@@ -560,7 +560,7 @@ impl Step for Rustdoc {
+ builder.ensure(Rustc { stage, target });
+
+ // Build rustdoc.
+- builder.ensure(tool::Rustdoc { compiler: compiler });
++ builder.ensure(tool::Rustdoc { compiler });
+
+ // Symlink compiler docs to the output directory of rustdoc documentation.
+ let out_dir = builder.stage_out(compiler, Mode::ToolRustc).join(target).join("doc");
+diff --git a/src/bootstrap/flags.rs b/src/bootstrap/flags.rs
+index 2101ef27f9d4..516be6a30c23 100644
+--- a/src/bootstrap/flags.rs
++++ b/src/bootstrap/flags.rs
+@@ -571,7 +571,7 @@ fn split(s: &[String]) -> Vec<String> {
+ }
+
+ fn parse_deny_warnings(matches: &getopts::Matches) -> Option<bool> {
+- match matches.opt_str("warnings").as_ref().map(|v| v.as_str()) {
++ match matches.opt_str("warnings").as_deref() {
+ Some("deny") => Some(true),
+ Some("warn") => Some(false),
+ Some(value) => {
+diff --git a/src/bootstrap/install.rs b/src/bootstrap/install.rs
+index f8734ebdf425..6549262811b9 100644
+--- a/src/bootstrap/install.rs
++++ b/src/bootstrap/install.rs
+@@ -126,9 +126,8 @@ fn add_destdir(path: &Path, destdir: &Option<PathBuf>) -> PathBuf {
+ None => return path.to_path_buf(),
+ };
+ for part in path.components() {
+- match part {
+- Component::Normal(s) => ret.push(s),
+- _ => {}
++ if let Component::Normal(s) = part {
++ ret.push(s)
+ }
+ }
+ ret
+diff --git a/src/bootstrap/lib.rs b/src/bootstrap/lib.rs
+index 1fee3fd9ac1d..0db4fb389010 100644
+--- a/src/bootstrap/lib.rs
++++ b/src/bootstrap/lib.rs
+@@ -444,7 +444,7 @@ impl Build {
+ builder.execute_cli();
+ } else {
+ let builder = builder::Builder::new(&self);
+- let _ = builder.execute_cli();
++ builder.execute_cli();
+ }
+
+ // Check for postponed failures from `test --no-fail-fast`.
+@@ -839,7 +839,7 @@ impl Build {
+ .target_config
+ .get(&target)
+ .and_then(|t| t.musl_root.as_ref())
+- .or(self.config.musl_root.as_ref())
++ .or_else(|| self.config.musl_root.as_ref())
+ .map(|p| &**p)
+ }
+
+@@ -1026,7 +1026,7 @@ impl Build {
+ }
+
+ fn llvm_link_tools_dynamically(&self, target: Interned<String>) -> 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
+diff --git a/src/bootstrap/metadata.rs b/src/bootstrap/metadata.rs
+index 8a26adc7ed50..292aa3b1e24a 100644
+--- a/src/bootstrap/metadata.rs
++++ b/src/bootstrap/metadata.rs
+@@ -5,7 +5,6 @@ use std::process::Command;
+
+ use build_helper::output;
+ use serde::Deserialize;
+-use serde_json;
+
+ use crate::cache::INTERNER;
+ use crate::{Build, Crate};
+diff --git a/src/bootstrap/native.rs b/src/bootstrap/native.rs
+index 5bbd9f47fc90..1cfb4b2f63b5 100644
+--- a/src/bootstrap/native.rs
++++ b/src/bootstrap/native.rs
+@@ -15,8 +15,6 @@ use std::path::{Path, PathBuf};
+ use std::process::Command;
+
+ use build_helper::{output, t};
+-use cc;
+-use cmake;
+
+ use crate::builder::{Builder, RunConfig, ShouldRun, Step};
+ use crate::cache::Interned;
+@@ -205,7 +203,7 @@ impl Step for Llvm {
+ cfg.define("LLVM_ENABLE_LIBXML2", "OFF");
+ }
+
+- if enabled_llvm_projects.len() > 0 {
++ if !enabled_llvm_projects.is_empty() {
+ enabled_llvm_projects.sort();
+ enabled_llvm_projects.dedup();
+ cfg.define("LLVM_ENABLE_PROJECTS", enabled_llvm_projects.join(";"));
+diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs
+index 6adf9ddaf343..8d9e62010015 100644
+--- a/src/bootstrap/test.rs
++++ b/src/bootstrap/test.rs
+@@ -1424,13 +1424,10 @@ impl Step for ErrorIndex {
+ }
+
+ fn markdown_test(builder: &Builder<'_>, compiler: Compiler, markdown: &Path) -> bool {
+- match fs::read_to_string(markdown) {
+- Ok(contents) => {
+- if !contents.contains("```") {
+- return true;
+- }
++ if let Ok(contents) = fs::read_to_string(markdown) {
++ if !contents.contains("```") {
++ return true;
+ }
+- Err(_) => {}
+ }
+
+ builder.info(&format!("doc tests for: {}", markdown.display()));
+diff --git a/src/bootstrap/tool.rs b/src/bootstrap/tool.rs
+index 7f24768a4f10..67e0ed5c5802 100644
+--- a/src/bootstrap/tool.rs
++++ b/src/bootstrap/tool.rs
+@@ -234,7 +234,7 @@ pub fn prepare_tool_cargo(
+ cargo.env("RUSTC_EXTERNAL_TOOL", "1");
+ }
+
+- let mut features = extra_features.iter().cloned().collect::<Vec<_>>();
++ let mut features = extra_features.to_vec();
+ if builder.build.config.cargo_native_static {
+ if path.ends_with("cargo")
+ || path.ends_with("rls")
+diff --git a/src/bootstrap/toolstate.rs b/src/bootstrap/toolstate.rs
+index b068c8200ace..bb012a388551 100644
+--- a/src/bootstrap/toolstate.rs
++++ b/src/bootstrap/toolstate.rs
+@@ -124,7 +124,7 @@ fn check_changed_files(toolstates: &HashMap<Box<str>, ToolState>) {
+ let output = t!(String::from_utf8(output.stdout));
+
+ for (tool, submodule) in STABLE_TOOLS.iter().chain(NIGHTLY_TOOLS.iter()) {
+- let changed = output.lines().any(|l| l.starts_with("M") && l.ends_with(submodule));
++ let changed = output.lines().any(|l| l.starts_with('M') && l.ends_with(submodule));
+ eprintln!("Verifying status of {}...", tool);
+ if !changed {
+ continue;
+diff --git a/src/bootstrap/util.rs b/src/bootstrap/util.rs
+index 7d1efe4610f9..eac790fe504b 100644
+--- a/src/bootstrap/util.rs
++++ b/src/bootstrap/util.rs
+@@ -98,7 +98,7 @@ impl Drop for TimeIt {
+ fn drop(&mut self) {
+ let time = self.1.elapsed();
+ if !self.0 {
+- println!("\tfinished in {}.{:03}", time.as_secs(), time.subsec_nanos() / 1_000_000);
++ println!("\tfinished in {}.{:03}", time.as_secs(), time.subsec_millis());
+ }
+ }
+ }
diff --git a/dev-lang/rust/files/1.42.0-libressl.patch b/dev-lang/rust/files/1.42.0-libressl.patch
new file mode 100644
index 00000000..2606b3bb
--- /dev/null
+++ b/dev-lang/rust/files/1.42.0-libressl.patch
@@ -0,0 +1,43 @@
+From aedf1cffc61878fdea9e59468dc44cdb56eb7cf5 Mon Sep 17 00:00:00 2001
+From: Stefan Strogin <steils@gentoo.org>
+Date: Fri, 10 Apr 2020 09:18:41 +0300
+Subject: [PATCH] Support LibreSSL 3.1.0
+
+Signed-off-by: Stefan Strogin <steils@gentoo.org>
+---
+ vendor/openssl-sys/.cargo-checksum.json | 2 +-
+ vendor/openssl-sys/build/main.rs | 3 ++-
+ 2 files changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/vendor/openssl-sys/.cargo-checksum.json b/vendor/openssl-sys/.cargo-checksum.json
+index e0bfd3035..8e2f52217 100644
+--- a/vendor/openssl-sys/.cargo-checksum.json
++++ b/vendor/openssl-sys/.cargo-checksum.json
+@@ -1 +1 @@
+-{"files":{"CHANGELOG.md":"736f0ad8717294a2ccb82065547f7161aa979eaad38c08c16d74954ece406dde","Cargo.toml":"4dbed0ba08fc7676bf7f6350eaaef6e6edb21b350718c218aae1d6372ec5918c","LICENSE-MIT":"378f5840b258e2779c39418f3f2d7b2ba96f1c7917dd6be0713f88305dbda397","README.md":"949fb3913ec7f94229242978dfeee5e19261b6d7506fc91dcd153bb0d2a84895","build/cfgs.rs":"4f39735ff73e6a13ff6ad34b9c046546a5887d705a86f68d1a8866fb305f728f","build/expando.c":"c4fa8a4424b2321f1857edfc5ce1ac1f03eda54440367d3142310c0eb5553004","build/find_normal.rs":"0a2dc417eace7fc72c27b9046ebaf53c75e418b27baa877434925a81fe6c23ed","build/find_vendored.rs":"7bf0e59c5646d72ee5a4392ad970fdf5c20288ddaf54dd86a8caff49583b38f5","build/main.rs":"6e800f4dc5c2cbbd54d1b1b995a2915ff941e17e11300d7091858210d3ce788d","src/aes.rs":"822bf666db351fe6ef9607c918081d6ad378fc1cedb05290bb746f86980c6088","src/asn1.rs":"254025cb408dbeff73bee6d06325acba9042cb11db30bdad04eedfb789be84b3","src/bio.rs":"5c6f394a78f258af3babb68330fa3571610476c4c3ba3404359db928f2f706ee","src/bn.rs":"c71b9c79f704a94a889d27bf75e7e5b1f9f10b0df0aeb485aef509cf05d7467f","src/cms.rs":"f21a403fea95e7b7efe0539a429831cfa51c8818adb79c7ebf73ae2a6f2dc87e","src/conf.rs":"511e008c18039f54d856d70b80009426fc7f4ce34fe4304e2c58ebf465031de0","src/crypto.rs":"a1279719ade9704be3d9af55ff679abbe918d525f332ca15810146d45e9080cf","src/dh.rs":"7cc334e86d16b3eae165dfa3a6c8e488bc0fe590c17beda38893d2e9d784d5a6","src/dsa.rs":"ae79baf231681900ea76304285b3ffacf5298c90b8c04d371269cf4adbb5b9fa","src/dtls1.rs":"45e1dbf94a42d587fd948d553dc30187aa6aa2b5b82d554cf725ff36df768aa0","src/ec.rs":"81372dfe497db2fc90457a470a3b8ccb249828b3ce2bf4fd2da8ec42afd6a6b3","src/err.rs":"f6641be5df397086a9db80667e191fb1d92972c29151e617df86672c1a16d3ad","src/evp.rs":"ddd25891a630f4676b16bd63ed3071f1b036722c7cdf1a72ca0a54cd3bf91898","src/hmac.rs":"fa3976d94a1383f300bdec228270afb8b47c97bb019d727c7d59ba783be3c42e","src/lib.rs":"c464eca1beb33844718044946f6ffb1bc27356d65b5b70ebcd2d4082520e7235","src/macros.rs":"638fb9098f6024e82b331eeee50c64cefdb58456dba28ee42560be655a0c2bf6","src/obj_mac.rs":"7203d356f7654c5805600b823eccf8e1d9d9cbce9a01859938612a3f0aae4cdc","src/object.rs":"7539eb2164c3fe2162a339ef5b45f1c835010a1522307803815779a01825eed7","src/ocsp.rs":"1db59566d2f072f7ae981f0c07e1604fcdf60e66845afe0689d588f8e4272115","src/ossl_typ.rs":"fc7366e75c78707650c8667593ed183eca6a8ce8dd6b911e342f644d1bcf98bd","src/pem.rs":"fbe95faaeb5b13ce44eb6574b4e21aa384d60fad079e895acaa61390887240d1","src/pkcs12.rs":"93aab2820008ad90dc346a7dcc02f9201d94bff0bb7d1d71031c097850287c50","src/pkcs7.rs":"5370c8d4bfbf1502fa33aff635cb730e7c87814580f1df9bdb1412a492377813","src/rand.rs":"469601b4fbb56d4dbf5cf5d7bb8483e3bde411edea18601e7d1ed6ef27180fd3","src/rsa.rs":"0e8c1f0bc37620a9208175542143bfd411ae88188974d2d5b37a2b8b77d0e2c8","src/safestack.rs":"6c39e28565d34efad707d77561d4caa99e3f028fcac3a2ef6fd403a78de1190c","src/sha.rs":"1a6b028a63654d2419417a9a8af790cd22409a4643682a0686ecdb9441264eba","src/srtp.rs":"306047f3f31828fe7d15de154b375f071ae07012a94c0b5c909f5fe57962a11b","src/ssl.rs":"215a27daa698c73fa909159a9e88a4302b075c33ebd17699f7f3423de60f5d68","src/ssl3.rs":"9336c816e00847d552dea22587d4ac72ff3cbd469fa5ff750423a19ea11e68eb","src/stack.rs":"1a509907283e5a2bf88cf193ce607f49ce7d2d95547c2ce2abc0fd4567aad334","src/tls1.rs":"60ca3dea1bbfda645bde563b4a878dac129c3f760e3ad572381000fc7a8ef522","src/x509.rs":"20e221731587221aab00aef21b4e4bebb7635603d265d424f3dd3c60d4c511e2","src/x509_vfy.rs":"5609f6300ab37a4d4755c81f7af1e6bb93a2f1a6f333c6e42f1e73ebf83ddc05","src/x509v3.rs":"30c58ce7d80670cc597d041e0f59862c1100e38743fc9dde2aec6dc811a4a558"},"package":"465d16ae7fc0e313318f7de5cecf57b2fbe7511fd213978b457e1c96ff46736f"}
+\ No newline at end of file
++{"files":{"CHANGELOG.md":"736f0ad8717294a2ccb82065547f7161aa979eaad38c08c16d74954ece406dde","Cargo.toml":"4dbed0ba08fc7676bf7f6350eaaef6e6edb21b350718c218aae1d6372ec5918c","LICENSE-MIT":"378f5840b258e2779c39418f3f2d7b2ba96f1c7917dd6be0713f88305dbda397","README.md":"949fb3913ec7f94229242978dfeee5e19261b6d7506fc91dcd153bb0d2a84895","build/cfgs.rs":"4f39735ff73e6a13ff6ad34b9c046546a5887d705a86f68d1a8866fb305f728f","build/expando.c":"c4fa8a4424b2321f1857edfc5ce1ac1f03eda54440367d3142310c0eb5553004","build/find_normal.rs":"0a2dc417eace7fc72c27b9046ebaf53c75e418b27baa877434925a81fe6c23ed","build/find_vendored.rs":"7bf0e59c5646d72ee5a4392ad970fdf5c20288ddaf54dd86a8caff49583b38f5","build/main.rs":"90bdf5c8d11678455cd65d29d5fd0969d248ff9be2b2a93c6e5decb71b514871","src/aes.rs":"822bf666db351fe6ef9607c918081d6ad378fc1cedb05290bb746f86980c6088","src/asn1.rs":"254025cb408dbeff73bee6d06325acba9042cb11db30bdad04eedfb789be84b3","src/bio.rs":"5c6f394a78f258af3babb68330fa3571610476c4c3ba3404359db928f2f706ee","src/bn.rs":"c71b9c79f704a94a889d27bf75e7e5b1f9f10b0df0aeb485aef509cf05d7467f","src/cms.rs":"f21a403fea95e7b7efe0539a429831cfa51c8818adb79c7ebf73ae2a6f2dc87e","src/conf.rs":"511e008c18039f54d856d70b80009426fc7f4ce34fe4304e2c58ebf465031de0","src/crypto.rs":"a1279719ade9704be3d9af55ff679abbe918d525f332ca15810146d45e9080cf","src/dh.rs":"7cc334e86d16b3eae165dfa3a6c8e488bc0fe590c17beda38893d2e9d784d5a6","src/dsa.rs":"ae79baf231681900ea76304285b3ffacf5298c90b8c04d371269cf4adbb5b9fa","src/dtls1.rs":"45e1dbf94a42d587fd948d553dc30187aa6aa2b5b82d554cf725ff36df768aa0","src/ec.rs":"81372dfe497db2fc90457a470a3b8ccb249828b3ce2bf4fd2da8ec42afd6a6b3","src/err.rs":"f6641be5df397086a9db80667e191fb1d92972c29151e617df86672c1a16d3ad","src/evp.rs":"ddd25891a630f4676b16bd63ed3071f1b036722c7cdf1a72ca0a54cd3bf91898","src/hmac.rs":"fa3976d94a1383f300bdec228270afb8b47c97bb019d727c7d59ba783be3c42e","src/lib.rs":"c464eca1beb33844718044946f6ffb1bc27356d65b5b70ebcd2d4082520e7235","src/macros.rs":"638fb9098f6024e82b331eeee50c64cefdb58456dba28ee42560be655a0c2bf6","src/obj_mac.rs":"7203d356f7654c5805600b823eccf8e1d9d9cbce9a01859938612a3f0aae4cdc","src/object.rs":"7539eb2164c3fe2162a339ef5b45f1c835010a1522307803815779a01825eed7","src/ocsp.rs":"1db59566d2f072f7ae981f0c07e1604fcdf60e66845afe0689d588f8e4272115","src/ossl_typ.rs":"fc7366e75c78707650c8667593ed183eca6a8ce8dd6b911e342f644d1bcf98bd","src/pem.rs":"fbe95faaeb5b13ce44eb6574b4e21aa384d60fad079e895acaa61390887240d1","src/pkcs12.rs":"93aab2820008ad90dc346a7dcc02f9201d94bff0bb7d1d71031c097850287c50","src/pkcs7.rs":"5370c8d4bfbf1502fa33aff635cb730e7c87814580f1df9bdb1412a492377813","src/rand.rs":"469601b4fbb56d4dbf5cf5d7bb8483e3bde411edea18601e7d1ed6ef27180fd3","src/rsa.rs":"0e8c1f0bc37620a9208175542143bfd411ae88188974d2d5b37a2b8b77d0e2c8","src/safestack.rs":"6c39e28565d34efad707d77561d4caa99e3f028fcac3a2ef6fd403a78de1190c","src/sha.rs":"1a6b028a63654d2419417a9a8af790cd22409a4643682a0686ecdb9441264eba","src/srtp.rs":"306047f3f31828fe7d15de154b375f071ae07012a94c0b5c909f5fe57962a11b","src/ssl.rs":"215a27daa698c73fa909159a9e88a4302b075c33ebd17699f7f3423de60f5d68","src/ssl3.rs":"9336c816e00847d552dea22587d4ac72ff3cbd469fa5ff750423a19ea11e68eb","src/stack.rs":"1a509907283e5a2bf88cf193ce607f49ce7d2d95547c2ce2abc0fd4567aad334","src/tls1.rs":"60ca3dea1bbfda645bde563b4a878dac129c3f760e3ad572381000fc7a8ef522","src/x509.rs":"20e221731587221aab00aef21b4e4bebb7635603d265d424f3dd3c60d4c511e2","src/x509_vfy.rs":"5609f6300ab37a4d4755c81f7af1e6bb93a2f1a6f333c6e42f1e73ebf83ddc05","src/x509v3.rs":"30c58ce7d80670cc597d041e0f59862c1100e38743fc9dde2aec6dc811a4a558"},"package":"465d16ae7fc0e313318f7de5cecf57b2fbe7511fd213978b457e1c96ff46736f"}
+diff --git a/vendor/openssl-sys/build/main.rs b/vendor/openssl-sys/build/main.rs
+index 162e11a66..d3f723bbe 100644
+--- a/vendor/openssl-sys/build/main.rs
++++ b/vendor/openssl-sys/build/main.rs
+@@ -204,6 +204,7 @@ See rust-openssl README for more information:
+ (3, 0, 0) => ('3', '0', '0'),
+ (3, 0, 1) => ('3', '0', '1'),
+ (3, 0, _) => ('3', '0', 'x'),
++ (3, 1, 0) => ('3', '1', '0'),
+ _ => version_error(),
+ };
+
+@@ -244,7 +245,7 @@ fn version_error() -> ! {
+ "
+
+ This crate is only compatible with OpenSSL 1.0.1 through 1.1.1, or LibreSSL 2.5
+-through 3.0.x, but a different version of OpenSSL was found. The build is now aborting
++through 3.1.0, but a different version of OpenSSL was found. The build is now aborting
+ due to this version mismatch.
+
+ "
+--
+2.26.0
+
diff --git a/dev-lang/rust/files/llvm-gcc10.patch b/dev-lang/rust/files/llvm-gcc10.patch
deleted file mode 100644
index 8fbaa923..00000000
--- a/dev-lang/rust/files/llvm-gcc10.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From b288d90b39f4b905c02092a9bfcfd6d78f99b191 Mon Sep 17 00:00:00 2001
-From: Than McIntosh <thanm@google.com>
-Date: Fri, 19 Jul 2019 13:13:54 +0000
-Subject: [PATCH] [NFC] include cstdint/string prior to using uint8_t/string
-
-Summary: include proper header prior to use of uint8_t typedef
-and std::string.
-
-Subscribers: llvm-commits
-
-Reviewers: cherry
-
-Tags: #llvm
-
-Differential Revision: https://reviews.llvm.org/D64937
-
-llvm-svn: 366572
----
- llvm/include/llvm/Demangle/MicrosoftDemangleNodes.h | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/src/llbm-project/llvm/include/llvm/Demangle/MicrosoftDemangleNodes.h b/src/llvm-project/llvm/include/llvm/Demangle/MicrosoftDemangleNodes.h
-index da9d9d5bfdc0..3d47471f0ef0 100644
---- a/src/llvm-project/llvm/include/llvm/Demangle/MicrosoftDemangleNodes.h
-+++ b/src/llvm-project/llvm/include/llvm/Demangle/MicrosoftDemangleNodes.h
-@@ -16,6 +16,8 @@
- #include "llvm/Demangle/DemangleConfig.h"
- #include "llvm/Demangle/StringView.h"
- #include <array>
-+#include <cstdint>
-+#include <string>
-
- namespace llvm {
- namespace itanium_demangle {
diff --git a/dev-lang/rust/rust-1.41.0-r10.ebuild b/dev-lang/rust/rust-1.42.0-r10.ebuild
index 139a0558..0fa769b5 100644
--- a/dev-lang/rust/rust-1.41.0-r10.ebuild
+++ b/dev-lang/rust/rust-1.42.0-r10.ebuild
@@ -14,14 +14,14 @@ if [[ ${PV} = *beta* ]]; then
SLOT="beta/${PV}"
SRC="${BETA_SNAPSHOT}/rustc-beta-src.tar.xz"
else
- ABI_VER="1.41"
+ ABI_VER="1.42"
SLOT="stable/${ABI_VER}"
MY_P="rustc-${PV}"
SRC="${MY_P}-src.tar.xz"
KEYWORDS="~amd64"
fi
-RUST_STAGE0_VERSION="1.$(($(ver_cut 2) - 1)).0"
+RUST_STAGE0_VERSION="1.$(($(ver_cut 2) - 1)).1"
DESCRIPTION="Systems programming language from Mozilla"
HOMEPAGE="https://www.rust-lang.org/"
@@ -38,7 +38,7 @@ LLVM_TARGET_USEDEPS=${ALL_LLVM_TARGETS[@]/%/?}
LICENSE="|| ( MIT Apache-2.0 ) BSD-1 BSD-2 BSD-4 UoI-NCSA"
-IUSE="clippy cpu_flags_x86_sse2 debug doc libressl nightly parallel-compiler rls rustfmt system-bootstrap system-llvm wasm ${ALL_LLVM_TARGETS[*]}"
+IUSE="clippy cpu_flags_x86_sse2 debug doc libressl miri nightly parallel-compiler rls rustfmt system-bootstrap system-llvm wasm ${ALL_LLVM_TARGETS[*]}"
# Please keep the LLVM dependency block separate. Since LLVM is slotted,
# we need to *really* make sure we're not pulling more than one slot
@@ -46,18 +46,19 @@ IUSE="clippy cpu_flags_x86_sse2 debug doc libressl nightly parallel-compiler rls
# How to use it:
# 1. List all the working slots (with min versions) in ||, newest first.
-# 2. Update the := to specify *max* version, e.g. < 10.
-# 3. Specify LLVM_MAX_SLOT, e.g. 9.
+# 2. Update the := to specify *max* version, e.g. < 11.
+# 3. Specify LLVM_MAX_SLOT, e.g. 10.
LLVM_DEPEND="
|| (
- sys-devel/llvm:9[llvm_targets_WebAssembly?]
- wasm? ( =sys-devel/lld-9* )
+ sys-devel/llvm:10[${LLVM_TARGET_USEDEPS// /,}]
+ sys-devel/llvm:9[${LLVM_TARGET_USEDEPS// /,}]
)
- <sys-devel/llvm-10:=
+ <sys-devel/llvm-11:=
+ wasm? ( sys-devel/lld )
"
-LLVM_MAX_SLOT=9
+LLVM_MAX_SLOT=10
-BOOTSTRAP_DEPEND="|| ( >=dev-lang/rust-1.$(($(ver_cut 2) - 1)).0-r1 >=dev-lang/rust-bin-1.$(($(ver_cut 2) - 1)) )"
+BOOTSTRAP_DEPEND="|| ( >=dev-lang/rust-1.$(($(ver_cut 2) - 1)) >=dev-lang/rust-bin-1.$(($(ver_cut 2) - 1)) )"
COMMON_DEPEND="
net-libs/libssh2:=
@@ -79,7 +80,7 @@ DEPEND="${COMMON_DEPEND}
>=sys-devel/clang-3.5
)
system-bootstrap? ( ${BOOTSTRAP_DEPEND} )
- system-llvm? (
+ !system-llvm? (
dev-util/cmake
dev-util/ninja
)
@@ -88,23 +89,25 @@ DEPEND="${COMMON_DEPEND}
RDEPEND="${COMMON_DEPEND}"
REQUIRED_USE="|| ( ${ALL_LLVM_TARGETS[*]} )
+ miri? ( nightly )
parallel-compiler? ( nightly )
wasm? ( llvm_targets_WebAssembly )
x86? ( cpu_flags_x86_sse2 )
"
QA_FLAGS_IGNORED="
- usr/bin/*-${PV}
- usr/lib*/lib*.so
- usr/lib/rustlib/*/codegen-backends/librustc_codegen_llvm-llvm.so
- usr/lib/rustlib/*/lib/lib*.so
+ usr/bin/.*-${PV}
+ usr/lib.*/lib.*.so
+ usr/lib/rustlib/.*/codegen-backends/librustc_codegen_llvm-llvm.so
+ usr/lib/rustlib/.*/lib/lib.*.so
"
QA_SONAME="usr/lib.*/librustc_macros.*.so"
PATCHES=(
"${FILESDIR}"/1.40.0-add-soname.patch
- "${FILESDIR}"/llvm-gcc10.patch
+ "${FILESDIR}"/1.42.0-fix-bootstrap.patch
+ "${FILESDIR}"/1.42.0-libressl.patch
)
S="${WORKDIR}/${MY_P}-src"
@@ -114,7 +117,7 @@ toml_usex() {
}
pre_build_checks() {
- CHECKREQS_DISK_BUILD="10G"
+ CHECKREQS_DISK_BUILD="9G"
eshopts_push -s extglob
if is-flagq '-g?(gdb)?([1-9])'; then
CHECKREQS_DISK_BUILD="15G"
@@ -175,6 +178,9 @@ src_configure() {
if use clippy; then
tools="\"clippy\",$tools"
fi
+ if use miri; then
+ tools="\"miri\",$tools"
+ fi
if use rls; then
tools="\"rls\",\"analysis\",\"src\",$tools"
fi
@@ -220,7 +226,7 @@ src_configure() {
docdir = "share/doc/${PF}"
mandir = "share/man"
[rust]
- optimize = $(toml_usex !debug)
+ optimize = true
debug = $(toml_usex debug)
debug-assertions = $(toml_usex debug)
default-linker = "$(tc-getCC)"
@@ -228,6 +234,7 @@ src_configure() {
channel = "$(usex nightly nightly stable)"
rpath = false
lld = $(usex system-llvm false $(toml_usex wasm))
+ backtrace-on-ice = true
[dist]
src-tarball = false
EOF
@@ -259,24 +266,25 @@ src_configure() {
EOF
fi
done
-
if use wasm; then
cat <<- EOF >> "${S}"/config.toml
[target.wasm32-unknown-unknown]
linker = "$(usex system-llvm lld rust-lld)"
EOF
fi
+
+ einfo "Rust configured with the following settings:"
+ cat "${S}"/config.toml || die
}
src_compile() {
env $(cat "${S}"/config.env)\
- "${EPYTHON}" ./x.py build -vv --config="${S}"/config.toml -j$(makeopts_jobs) \
- --exclude src/tools/miri || die # https://github.com/rust-lang/rust/issues/52305
+ "${EPYTHON}" ./x.py build -vv --config="${S}"/config.toml -j$(makeopts_jobs) || die
}
src_install() {
- env DESTDIR="${D}" "${EPYTHON}" ./x.py install -vv --config="${S}"/config.toml \
- --exclude src/tools/miri || die
+ env $(cat "${S}"/config.env) DESTDIR="${D}" \
+ "${EPYTHON}" ./x.py install -vv --config="${S}"/config.toml || die
# bug #689562, #689160
rm "${D}/etc/bash_completion.d/cargo" || die