summaryrefslogtreecommitdiff
path: root/dev-lang/rust
diff options
context:
space:
mode:
Diffstat (limited to 'dev-lang/rust')
-rw-r--r--dev-lang/rust/Manifest4
-rw-r--r--dev-lang/rust/files/0012-Ignore-broken-and-non-applicable-tests.patch89
-rw-r--r--dev-lang/rust/files/1.40.0-add-soname.patch36
-rw-r--r--dev-lang/rust/files/1.42.0-fix-bootstrap.patch440
-rw-r--r--dev-lang/rust/files/1.44.0-libressl.patch (renamed from dev-lang/rust/files/1.42.0-libressl.patch)28
-rw-r--r--dev-lang/rust/rust-1.46.0-r10.ebuild (renamed from dev-lang/rust/rust-1.42.0-r10.ebuild)247
6 files changed, 306 insertions, 538 deletions
diff --git a/dev-lang/rust/Manifest b/dev-lang/rust/Manifest
index 1436c9f3..02ce39af 100644
--- a/dev-lang/rust/Manifest
+++ b/dev-lang/rust/Manifest
@@ -1,2 +1,2 @@
-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
+DIST rust-1.45.1-x86_64-unknown-linux-gnu.tar.xz 117764080 BLAKE2B cafe6e4f7c28112879089d75703a1b1ce7c0cf9b5ab5beeb4ddf343f7bc93e8704bc105ba0bd95f1df6d62439f206d8f4ae9090330af857ec0a249540eb63122 SHA512 13ee5ff7cae29440e32fb140404ff01414d66f0ea8d79777fb1586541de1ee6ef8e12f9249c35374501460a2352f7d0f6035b5bdc2f0daa91d772a157657ec0b
+DIST rustc-1.46.0-src.tar.xz 101868452 BLAKE2B da9798596b124a10d79c236a871228f05e5f571d22c2259328e7026c91e088c85f5de9c0536a16531e0cb10477bfcd16d3ac11467979f5561cb6199442b877ef SHA512 099857f1d295043587a4e2a65ef3e6a90e12c8b6958e98535a1656c113c553f9a9b621aba8a19cf21bd8d2c79d27cbfa4b8e6fabbcb3cbfee23b545be7b450b4
diff --git a/dev-lang/rust/files/0012-Ignore-broken-and-non-applicable-tests.patch b/dev-lang/rust/files/0012-Ignore-broken-and-non-applicable-tests.patch
new file mode 100644
index 00000000..45fda8ae
--- /dev/null
+++ b/dev-lang/rust/files/0012-Ignore-broken-and-non-applicable-tests.patch
@@ -0,0 +1,89 @@
+From 1879d1d1a284bf51c752e47db284ce22701ed5d0 Mon Sep 17 00:00:00 2001
+From: Samuel Holland <samuel@sholland.org>
+Date: Sun, 16 Sep 2018 16:38:48 +0000
+Subject: [PATCH 12/15] Ignore broken and non-applicable tests
+
+c-link-to-rust-va-list-fn: unstable feature, broken on aarch64, #56475
+env-funky-keys: can't handle LD_PRELOAD (e.g. sandbox)
+long-linker-command-lines: takes >10 minutes to run (but still passes)
+simd-intrinsic-generic-bitmask.rs: broken on BE, #59356
+sparc-struct-abi: no sparc target
+sysroot-crates-are-unstable: can't run rustc without RPATH
+---
+ src/test/codegen/sparc-struct-abi.rs | 1 +
+ src/test/run-make-fulldeps/c-link-to-rust-va-list-fn/Makefile | 2 ++
+ src/test/run-make-fulldeps/long-linker-command-lines/Makefile | 2 ++
+ src/test/run-make-fulldeps/sysroot-crates-are-unstable/Makefile | 2 ++
+ src/test/ui/env-funky-keys.rs | 1 +
+ src/test/ui/simd/simd-intrinsic-generic-bitmask.rs | 2 ++
+ 6 files changed, 10 insertions(+)
+
+diff --git a/src/test/codegen/sparc-struct-abi.rs b/src/test/codegen/sparc-struct-abi.rs
+index 78e5b14a212..6f93e93286b 100644
+--- a/src/test/codegen/sparc-struct-abi.rs
++++ b/src/test/codegen/sparc-struct-abi.rs
+@@ -4,6 +4,7 @@
+
+ // only-sparc64
+ // compile-flags: -O --target=sparc64-unknown-linux-gnu --crate-type=rlib
++// ignore-test
+ #![feature(no_core, lang_items)]
+ #![no_core]
+
+diff --git a/src/test/run-make-fulldeps/c-link-to-rust-va-list-fn/Makefile b/src/test/run-make-fulldeps/c-link-to-rust-va-list-fn/Makefile
+index f124ca2ab61..363b18f0985 100644
+--- a/src/test/run-make-fulldeps/c-link-to-rust-va-list-fn/Makefile
++++ b/src/test/run-make-fulldeps/c-link-to-rust-va-list-fn/Makefile
+@@ -1,3 +1,5 @@
++# ignore-aarch64
++
+ -include ../tools.mk
+
+ all:
+diff --git a/src/test/run-make-fulldeps/long-linker-command-lines/Makefile b/src/test/run-make-fulldeps/long-linker-command-lines/Makefile
+index 5876fbc94bc..5f167ece1a2 100644
+--- a/src/test/run-make-fulldeps/long-linker-command-lines/Makefile
++++ b/src/test/run-make-fulldeps/long-linker-command-lines/Makefile
+@@ -1,3 +1,5 @@
++# ignore-test
++
+ -include ../tools.mk
+
+ all:
+diff --git a/src/test/run-make-fulldeps/sysroot-crates-are-unstable/Makefile b/src/test/run-make-fulldeps/sysroot-crates-are-unstable/Makefile
+index 9e770706857..6d92ec5cec8 100644
+--- a/src/test/run-make-fulldeps/sysroot-crates-are-unstable/Makefile
++++ b/src/test/run-make-fulldeps/sysroot-crates-are-unstable/Makefile
+@@ -1,1 +1,3 @@
++# ignore-test
++
+ all:
+ python2.7 test.py
+diff --git a/src/test/ui/env-funky-keys.rs b/src/test/ui/env-funky-keys.rs
+index c5c824ac58d..f3fe047a79c 100644
+--- a/src/test/ui/env-funky-keys.rs
++++ b/src/test/ui/env-funky-keys.rs
+@@ -1,6 +1,7 @@
+ // run-pass
+ // Ignore this test on Android, because it segfaults there.
+
++// ignore-test
+ // ignore-android
+ // ignore-windows
+ // ignore-cloudabi no execve
+diff --git a/src/test/ui/simd/simd-intrinsic-generic-bitmask.rs b/src/test/ui/simd/simd-intrinsic-generic-bitmask.rs
+index b28f742a92e..3ee4ccce731 100644
+--- a/src/test/ui/simd/simd-intrinsic-generic-bitmask.rs
++++ b/src/test/ui/simd/simd-intrinsic-generic-bitmask.rs
+@@ -2,6 +2,8 @@
+ #![allow(non_camel_case_types)]
+
+ // ignore-emscripten
++// ignore-powerpc
++// ignore-powerpc64
+
+ // Test that the simd_bitmask intrinsic produces correct results.
+
+--
+2.24.1
+
diff --git a/dev-lang/rust/files/1.40.0-add-soname.patch b/dev-lang/rust/files/1.40.0-add-soname.patch
deleted file mode 100644
index 7a5c0189..00000000
--- a/dev-lang/rust/files/1.40.0-add-soname.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-Description: Set DT_SONAME when building dylibs
- In Rust, library filenames include a version-specific hash to help
- the run-time linker find the correct version. Unlike in C/C++, the
- compiler looks for all libraries matching a glob that ignores the
- hash and reads embedded metadata to work out versions, etc.
- .
- The upshot is that there is no need for the usual "libfoo.so ->
- libfoo-1.2.3.so" symlink common with C/C++ when building with Rust,
- and no need to communicate an alternate filename to use at run-time
- vs compile time. If linking to a Rust dylib from C/C++ however, a
- "libfoo.so -> libfoo-$hash.so" symlink may well be useful and in
- this case DT_SONAME=libfoo-$hash.so would be required. More
- mundanely, various tools (eg: dpkg-shlibdeps) complain if they don't
- find DT_SONAME on shared libraries in public directories.
- .
- This patch passes -Wl,-soname=$outfile when building dylibs (and
- using a GNU linker).
-Author: Angus Lees <gus@debian.org>
-Forwarded: no
-
---- a/src/librustc_codegen_ssa/back/link.rs
-+++ b/src/librustc_codegen_ssa/back/link.rs
-@@ -1034,6 +1034,13 @@
- cmd.args(&rpath::get_rpath_flags(&mut rpath_config));
- }
-
-+ if (crate_type == config::CrateType::Dylib || crate_type == config::CrateType::Cdylib)
-+ && t.options.linker_is_gnu {
-+ let filename = String::from(out_filename.file_name().unwrap().to_str().unwrap());
-+ let soname = [String::from("-Wl,-soname=") + &filename];
-+ cmd.args(&soname);
-+ }
-+
- // Finally add all the linker arguments provided on the command line along
- // with any #[link_args] attributes found inside the crate
- if let Some(ref args) = sess.opts.cg.link_args {
diff --git a/dev-lang/rust/files/1.42.0-fix-bootstrap.patch b/dev-lang/rust/files/1.42.0-fix-bootstrap.patch
deleted file mode 100644
index 16e4e6dc..00000000
--- a/dev-lang/rust/files/1.42.0-fix-bootstrap.patch
+++ /dev/null
@@ -1,440 +0,0 @@
-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.44.0-libressl.patch
index 2606b3bb..3bbae36e 100644
--- a/dev-lang/rust/files/1.42.0-libressl.patch
+++ b/dev-lang/rust/files/1.44.0-libressl.patch
@@ -1,43 +1,45 @@
-From aedf1cffc61878fdea9e59468dc44cdb56eb7cf5 Mon Sep 17 00:00:00 2001
+From 3d1be8d8981a0f847e935312a78bd2ba5129f90e 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
+Date: Fri, 5 Jun 2020 06:37:06 +0300
+Subject: [PATCH] Support LibreSSL 3.2.x
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(-)
+ vendor/openssl-sys/build/main.rs | 5 ++++-
+ 2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/vendor/openssl-sys/.cargo-checksum.json b/vendor/openssl-sys/.cargo-checksum.json
-index e0bfd3035..8e2f52217 100644
+index 7f63bae3d..76025fe7f 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"}
+-{"files":{"CHANGELOG.md":"ffd4bbaeec2740afbcab5a6828f9e65523aaff8638e3d5d13c93a3241fb8ed2f","Cargo.toml":"3eb2f65dda1aa74c8b47814878b56bf4999b4d01bc5864fc9f3c0ece9a5694a7","LICENSE-MIT":"378f5840b258e2779c39418f3f2d7b2ba96f1c7917dd6be0713f88305dbda397","README.md":"949fb3913ec7f94229242978dfeee5e19261b6d7506fc91dcd153bb0d2a84895","build/cfgs.rs":"56cee620b082d87b1c9cdeba7c6c022e6aa7d3a99e2b66ec18a534ceaf2e2bb7","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":"1f38a3ec4029511fecd7a51548965a265f3e7772891b5514e22bfb1d061b3a90","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":"5afdfc0ab87259b13a55375c178ae3af934b3281240aa24ca27afac7acccea42","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":"13bf789702e37dc4b9f74f3a0e61ae6e5602e4dedf45c05d884c41257b32d76c","src/pem.rs":"4427060f543ae9e6745d9a8f7f76cb72acfb06afacaf396b011afff6a221714b","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":"34ad7d5413d77f9052815cfd7344d5a21868b5ae0d38dadd6f4ed3b5c4b33760","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":"1024c0a59774200a555087a6da3f253a9095a5f344e353b212ac4c8b8e450986"}
\ 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"}
++{"files":{"CHANGELOG.md":"ffd4bbaeec2740afbcab5a6828f9e65523aaff8638e3d5d13c93a3241fb8ed2f","Cargo.toml":"3eb2f65dda1aa74c8b47814878b56bf4999b4d01bc5864fc9f3c0ece9a5694a7","LICENSE-MIT":"378f5840b258e2779c39418f3f2d7b2ba96f1c7917dd6be0713f88305dbda397","README.md":"949fb3913ec7f94229242978dfeee5e19261b6d7506fc91dcd153bb0d2a84895","build/cfgs.rs":"56cee620b082d87b1c9cdeba7c6c022e6aa7d3a99e2b66ec18a534ceaf2e2bb7","build/expando.c":"c4fa8a4424b2321f1857edfc5ce1ac1f03eda54440367d3142310c0eb5553004","build/find_normal.rs":"0a2dc417eace7fc72c27b9046ebaf53c75e418b27baa877434925a81fe6c23ed","build/find_vendored.rs":"7bf0e59c5646d72ee5a4392ad970fdf5c20288ddaf54dd86a8caff49583b38f5","build/main.rs":"049f7020b6a1f8bb831cb750054fbc0f408e048e34c0817644696ec9d0cfb06e","src/aes.rs":"822bf666db351fe6ef9607c918081d6ad378fc1cedb05290bb746f86980c6088","src/asn1.rs":"254025cb408dbeff73bee6d06325acba9042cb11db30bdad04eedfb789be84b3","src/bio.rs":"1f38a3ec4029511fecd7a51548965a265f3e7772891b5514e22bfb1d061b3a90","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":"5afdfc0ab87259b13a55375c178ae3af934b3281240aa24ca27afac7acccea42","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":"13bf789702e37dc4b9f74f3a0e61ae6e5602e4dedf45c05d884c41257b32d76c","src/pem.rs":"4427060f543ae9e6745d9a8f7f76cb72acfb06afacaf396b011afff6a221714b","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":"34ad7d5413d77f9052815cfd7344d5a21868b5ae0d38dadd6f4ed3b5c4b33760","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":"1024c0a59774200a555087a6da3f253a9095a5f344e353b212ac4c8b8e450986"}
diff --git a/vendor/openssl-sys/build/main.rs b/vendor/openssl-sys/build/main.rs
-index 162e11a66..d3f723bbe 100644
+index 162e11a66..6754ddeef 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:
+@@ -204,6 +204,9 @@ 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'),
++ (3, 1, _) => ('3', '1', 'x'),
++ (3, 2, _) => ('3', '2', 'x'),
_ => version_error(),
};
-@@ -244,7 +245,7 @@ fn version_error() -> ! {
+@@ -244,7 +247,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
++through 3.2.x, but a different version of OpenSSL was found. The build is now aborting
due to this version mismatch.
"
--
-2.26.0
+2.27.0
diff --git a/dev-lang/rust/rust-1.42.0-r10.ebuild b/dev-lang/rust/rust-1.46.0-r10.ebuild
index 0fa769b5..73df8838 100644
--- a/dev-lang/rust/rust-1.42.0-r10.ebuild
+++ b/dev-lang/rust/rust-1.46.0-r10.ebuild
@@ -3,7 +3,7 @@
EAPI=7
-PYTHON_COMPAT=( python3_{6,7} )
+PYTHON_COMPAT=( python3_{6,7,8} )
inherit bash-completion-r1 check-reqs estack flag-o-matic llvm multiprocessing multilib-build python-any-r1 rust-toolchain toolchain-funcs
@@ -14,7 +14,7 @@ if [[ ${PV} = *beta* ]]; then
SLOT="beta/${PV}"
SRC="${BETA_SNAPSHOT}/rustc-beta-src.tar.xz"
else
- ABI_VER="1.42"
+ ABI_VER="1.46"
SLOT="stable/${ABI_VER}"
MY_P="rustc-${PV}"
SRC="${MY_P}-src.tar.xz"
@@ -60,10 +60,24 @@ LLVM_MAX_SLOT=10
BOOTSTRAP_DEPEND="|| ( >=dev-lang/rust-1.$(($(ver_cut 2) - 1)) >=dev-lang/rust-bin-1.$(($(ver_cut 2) - 1)) )"
-COMMON_DEPEND="
+BDEPEND="${PYTHON_DEPS}
+ || (
+ >=sys-devel/gcc-4.7
+ >=sys-devel/clang-3.5
+ )
+ system-bootstrap? ( ${BOOTSTRAP_DEPEND} )
+ !system-llvm? (
+ dev-util/cmake
+ dev-util/ninja
+ )
+"
+
+# libgit2 should be at least same as bundled into libgit-sys #707746
+DEPEND="
+ >=dev-libs/libgit2-0.99:=
net-libs/libssh2:=
net-libs/http-parser:=
- net-misc/curl:=[ssl]
+ net-misc/curl:=[http2,ssl]
sys-libs/zlib:=
!libressl? ( dev-libs/openssl:0= )
libressl? ( dev-libs/libressl:0= )
@@ -73,21 +87,10 @@ COMMON_DEPEND="
)
"
-DEPEND="${COMMON_DEPEND}
- ${PYTHON_DEPS}
- || (
- >=sys-devel/gcc-4.7
- >=sys-devel/clang-3.5
- )
- system-bootstrap? ( ${BOOTSTRAP_DEPEND} )
- !system-llvm? (
- dev-util/cmake
- dev-util/ninja
- )
+RDEPEND="${DEPEND}
+ app-eselect/eselect-rust
"
-RDEPEND="${COMMON_DEPEND}"
-
REQUIRED_USE="|| ( ${ALL_LLVM_TARGETS[*]} )
miri? ( nightly )
parallel-compiler? ( nightly )
@@ -95,19 +98,28 @@ REQUIRED_USE="|| ( ${ALL_LLVM_TARGETS[*]} )
x86? ( cpu_flags_x86_sse2 )
"
+# we don't use cmake.eclass, but can get a warnin -l
+CMAKE_WARN_UNUSED_CLI=no
+
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/lib.*/${P}/lib.*.so.*
+ usr/lib.*/${P}/rustlib/.*/bin/.*
+ usr/lib.*/${P}/rustlib/.*/lib/lib.*.so.*
"
-QA_SONAME="usr/lib.*/librustc_macros.*.so"
+QA_SONAME="
+ usr/lib.*/${P}/lib.*.so.*
+ usr/lib.*/${P}/rustlib/.*/lib/lib.*.so.*
+"
+
+# tests need a bit more work, currently they are causing multiple
+# re-compilations and somewhat fragile.
+RESTRICT="test"
PATCHES=(
- "${FILESDIR}"/1.40.0-add-soname.patch
- "${FILESDIR}"/1.42.0-fix-bootstrap.patch
- "${FILESDIR}"/1.42.0-libressl.patch
+ "${FILESDIR}"/0012-Ignore-broken-and-non-applicable-tests.patch
+ "${FILESDIR}"/1.44.0-libressl.patch
)
S="${WORKDIR}/${MY_P}-src"
@@ -116,14 +128,41 @@ toml_usex() {
usex "$1" true false
}
+boostrap_rust_version_check() {
+ # never call from pkg_pretend. eselect-rust may be not installed yet.
+ local rustc_wanted="$(ver_cut 1).$(($(ver_cut 2) - 1))"
+ local rustc_version=( $(eselect --brief rust show 2>/dev/null) )
+ rustc_version=${rustc_version[0]#rust-bin-}
+ rustc_version=${rustc_version#rust-}
+
+ [[ -z "${rustc_version}" ]] && die "Failed to determine rustc version!"
+
+ if ver_test "${rustc_version}" -lt "${rustc_wanted}" ; then
+ eerror "Rust >=${rustc_wanted} is required"
+ eerror "please run \'eselect rust\' and set correct rust version"
+ die
+ else
+ einfo "Using rust ${rustc_version} to build"
+ fi
+}
+
pre_build_checks() {
- CHECKREQS_DISK_BUILD="9G"
+ local M=6144
+ M=$(( $(usex clippy 128 0) + ${M} ))
+ M=$(( $(usex miri 128 0) + ${M} ))
+ M=$(( $(usex rls 512 0) + ${M} ))
+ M=$(( $(usex rustfmt 256 0) + ${M} ))
+ M=$(( $(usex system-llvm 0 2048) + ${M} ))
+ M=$(( $(usex wasm 256 0) + ${M} ))
+ M=$(( $(usex debug 15 10) * ${M} / 10 ))
eshopts_push -s extglob
if is-flagq '-g?(gdb)?([1-9])'; then
- CHECKREQS_DISK_BUILD="15G"
+ M=$(( 15 * ${M} / 10 ))
fi
eshopts_pop
- check-reqs_pkg_setup
+ M=$(( $(usex system-bootstrap 0 1024) + ${M} ))
+ M=$(( $(usex doc 256 0) + ${M} ))
+ CHECKREQS_DISK_BUILD=${M}M check-reqs_pkg_${EBUILD_PHASE}
}
pkg_pretend() {
@@ -133,10 +172,11 @@ pkg_pretend() {
pkg_setup() {
pre_build_checks
python-any-r1_pkg_setup
+ use system-bootstrap && boostrap_rust_version_check
- # use bundled for now, #707746
- # will need dev-libs/libgit2 slotted dep if re-enabled
- #export LIBGIT2_SYS_USE_PKG_CONFIG=1
+ # required to link agains system libs, otherwise
+ # crates use bundled sources and compile own static version
+ export LIBGIT2_SYS_USE_PKG_CONFIG=1
export LIBSSH2_SYS_USE_PKG_CONFIG=1
export PKG_CONFIG_ALLOW_CROSS=1
@@ -171,10 +211,15 @@ src_configure() {
done
if use wasm; then
rust_targets="${rust_targets},\"wasm32-unknown-unknown\""
+ if use system-llvm; then
+ # un-hardcode rust-lld linker for this target
+ # https://bugs.gentoo.org/715348
+ sed -i '/linker:/ s/rust-lld/wasm-ld/' src/librustc_target/spec/wasm32_base.rs || die
+ fi
fi
rust_targets="${rust_targets#,}"
- local extended="true" tools="\"cargo\","
+ local tools="\"cargo\","
if use clippy; then
tools="\"clippy\",$tools"
fi
@@ -202,6 +247,7 @@ src_configure() {
optimize = $(toml_usex !debug)
release-debuginfo = $(toml_usex debug)
assertions = $(toml_usex debug)
+ ninja = true
targets = "${LLVM_TARGETS// /;}"
experimental-targets = ""
link-shared = $(toml_usex system-llvm)
@@ -217,24 +263,36 @@ src_configure() {
python = "${EPYTHON}"
locked-deps = true
vendor = true
- extended = ${extended}
+ extended = true
tools = [${tools}]
verbose = 2
+ sanitizers = false
+ profiler = false
+ cargo-native-static = false
[install]
prefix = "${EPREFIX}/usr"
- libdir = "lib"
+ libdir = "$(get_libdir)/${P}"
docdir = "share/doc/${PF}"
- mandir = "share/man"
+ mandir = "share/${P}/man"
[rust]
optimize = true
debug = $(toml_usex debug)
debug-assertions = $(toml_usex debug)
+ debuginfo-level-rustc = 0
+ backtrace = true
+ incremental = false
default-linker = "$(tc-getCC)"
parallel-compiler = $(toml_usex parallel-compiler)
channel = "$(usex nightly nightly stable)"
rpath = false
+ verbose-tests = true
+ optimize-tests = $(toml_usex !debug)
+ codegen-tests = true
+ dist-src = false
+ remap-debuginfo = true
lld = $(usex system-llvm false $(toml_usex wasm))
backtrace-on-ice = true
+ jemalloc = false
[dist]
src-tarball = false
EOF
@@ -273,15 +331,108 @@ src_configure() {
EOF
fi
+ if [[ -n ${I_KNOW_WHAT_I_AM_DOING_CROSS} ]]; then #whitespace intentionally shifted below
+ # experimental cross support
+ # discussion: https://bugs.gentoo.org/679878
+ # TODO: c*flags, clang, system-llvm, cargo.eclass target support
+ # it would be much better if we could split out stdlib
+ # complilation to separate ebuild and abuse CATEGORY to
+ # just install to /usr/lib/rustlib/<target>
+
+ # extra targets defined as a bash array
+ # spec format: <LLVM target>:<rust-target>:<CTARGET>
+ # best place would be /etc/portage/env/dev-lang/rust
+ # Example:
+ # RUST_CROSS_TARGETS=(
+ # "AArch64:aarch64-unknown-linux-gnu:aarch64-unknown-linux-gnu"
+ # )
+ # no extra hand holding is done, no target transformations, all
+ # values are passed as-is with just basic checks, so it's up to user to supply correct values
+ # valid rust targets can be obtained with
+ # rustc --print target-list
+ # matching cross toolchain has to be installed
+ # matching LLVM_TARGET has to be enabled for both rust and llvm (if using system one)
+ # only gcc toolchains installed with crossdev are checked for now.
+
+ # BUG: we can't pass host flags to cross compiler, so just filter for now
+ # BUG: this should be more fine-grained.
+ filter-flags '-mcpu=*' '-march=*' '-mtune=*'
+
+ local cross_target_spec
+ for cross_target_spec in "${RUST_CROSS_TARGETS[@]}";do
+ # extracts first element form <LLVM target>:<rust-target>:<CTARGET>
+ local cross_llvm_target="${cross_target_spec%%:*}"
+ # extracts toolchain triples, <rust-target>:<CTARGET>
+ local cross_triples="${cross_target_spec#*:}"
+ # extracts first element after before : separator
+ local cross_rust_target="${cross_triples%%:*}"
+ # extracts last element after : separator
+ local cross_toolchain="${cross_triples##*:}"
+ use llvm_targets_${cross_llvm_target} || die "need llvm_targets_${cross_llvm_target} target enabled"
+ command -v ${cross_toolchain}-gcc > /dev/null 2>&1 || die "need ${cross_toolchain} cross toolchain"
+
+ cat <<- EOF >> "${S}"/config.toml
+ [target.${cross_rust_target}]
+ cc = "${cross_toolchain}-gcc"
+ cxx = "${cross_toolchain}-g++"
+ linker = "${cross_toolchain}-gcc"
+ ar = "${cross_toolchain}-ar"
+ EOF
+ if use system-llvm; then
+ cat <<- EOF >> "${S}"/config.toml
+ llvm-config = "$(get_llvm_prefix "${LLVM_MAX_SLOT}")/bin/llvm-config"
+ EOF
+ fi
+
+ # append cross target to "normal" target list
+ # example 'target = ["powerpc64le-unknown-linux-gnu"]'
+ # becomes 'target = ["powerpc64le-unknown-linux-gnu","aarch64-unknown-linux-gnu"]'
+
+ rust_targets="${rust_targets},\"${cross_rust_target}\""
+ sed -i "/^target = \[/ s#\[.*\]#\[${rust_targets}\]#" config.toml || die
+
+ ewarn
+ ewarn "Enabled ${cross_rust_target} rust target"
+ ewarn "Using ${cross_toolchain} cross toolchain"
+ ewarn
+ if ! has_version -b 'sys-devel/binutils[multitarget]' ; then
+ ewarn "'sys-devel/binutils[multitarget]' is not installed"
+ ewarn "'strip' will be unable to strip cross libraries"
+ ewarn "cross targets will be installed with full debug information"
+ ewarn "enable 'multitarget' USE flag for binutils to be able to strip object files"
+ ewarn
+ ewarn "Alternatively llvm-strip can be used, it supports stripping any target"
+ ewarn "define STRIP=\"llvm-strip\" to use it (experimental)"
+ ewarn
+ fi
+ done
+ fi # I_KNOW_WHAT_I_AM_DOING_CROSS
+
einfo "Rust configured with the following settings:"
cat "${S}"/config.toml || die
}
src_compile() {
- env $(cat "${S}"/config.env)\
+ env $(cat "${S}"/config.env) RUST_BACKTRACE=1\
"${EPYTHON}" ./x.py build -vv --config="${S}"/config.toml -j$(makeopts_jobs) || die
}
+src_test() {
+ env $(cat "${S}"/config.env) RUST_BACKTRACE=1\
+ "${EPYTHON}" ./x.py test -vv --config="${S}"/config.toml -j$(makeopts_jobs) --no-doc --no-fail-fast \
+ src/test/codegen \
+ src/test/codegen-units \
+ src/test/compile-fail \
+ src/test/incremental \
+ src/test/mir-opt \
+ src/test/pretty \
+ src/test/run-fail \
+ src/test/run-make \
+ src/test/run-make-fulldeps \
+ src/test/ui \
+ src/test/ui-fulldeps || die
+}
+
src_install() {
env $(cat "${S}"/config.env) DESTDIR="${D}" \
"${EPYTHON}" ./x.py install -vv --config="${S}"/config.toml || die
@@ -291,25 +442,27 @@ src_install() {
rmdir "${D}"/etc{/bash_completion.d,} || die
dobashcomp build/tmp/dist/cargo-image/etc/bash_completion.d/cargo
- # Move public shared libs to abi specific libdir
- # Private and target specific libs MUST stay in /usr/lib/rustlib/${rust_target}/lib
- if [[ $(get_libdir) != lib ]]; then
- dodir /usr/$(get_libdir)
- mv "${ED}/usr/lib"/*.so "${ED}/usr/$(get_libdir)/" || die
- fi
-
- dodoc COPYRIGHT
+ # Copy shared library versions of standard libraries for all targets
+ # into the system's abi-dependent lib directories because the rust
+ # installer only does so for the native ABI.
+ local abi_libdir rust_target
+ for v in $(multilib_get_enabled_abi_pairs); do
+ if [ ${v##*.} = ${DEFAULT_ABI} ]; then
+ continue
+ fi
+ abi_libdir=$(get_abi_LIBDIR ${v##*.})
+ rust_target=$(rust_abi $(get_abi_CHOST ${v##*.}))
+ mkdir -p "${ED}/usr/${abi_libdir}/${P}"
+ cp "${ED}/usr/$(get_libdir)/${P}/rustlib/${rust_target}/lib"/*.so \
+ "${ED}/usr/${abi_libdir}/${P}" || die
+ done
}
pkg_postinst() {
elog "Rust installs a helper script for calling GDB and LLDB,"
elog "for your convenience it is installed under /usr/bin/rust-{gdb,lldb}-${PV}."
- ewarn "cargo is now installed from dev-lang/rust{,-bin} instead of dev-util/cargo."
- ewarn "This might have resulted in a dangling symlink for /usr/bin/cargo on some"
- ewarn "systems. This can be resolved by calling 'sudo eselect rust set ${P}'."
-
if has_version app-editors/emacs; then
elog "install app-emacs/rust-mode to get emacs support for rust."
fi