diff --git a/.gitignore b/.gitignore index 7d871ac..3441262 100644 --- a/.gitignore +++ b/.gitignore @@ -134,3 +134,11 @@ /rust-1.26.0-x86_64-unknown-linux-gnu.tar.xz /rustc-1.27.1-src.tar.xz /rustc-1.27.2-src.tar.xz +/rustc-1.28.0-src.tar.xz +/rust-1.27.2-aarch64-unknown-linux-gnu.tar.xz +/rust-1.27.2-armv7-unknown-linux-gnueabihf.tar.xz +/rust-1.27.2-i686-unknown-linux-gnu.tar.xz +/rust-1.27.2-powerpc64le-unknown-linux-gnu.tar.xz +/rust-1.27.2-powerpc64-unknown-linux-gnu.tar.xz +/rust-1.27.2-s390x-unknown-linux-gnu.tar.xz +/rust-1.27.2-x86_64-unknown-linux-gnu.tar.xz diff --git a/0001-Ensure-libraries-built-in-stage0-have-unique-metadat.patch b/0001-Ensure-libraries-built-in-stage0-have-unique-metadat.patch deleted file mode 100644 index 38a4402..0000000 --- a/0001-Ensure-libraries-built-in-stage0-have-unique-metadat.patch +++ /dev/null @@ -1,40 +0,0 @@ -From e8e5eb58c0d6890f73ea01354e18f51b1a6697f8 Mon Sep 17 00:00:00 2001 -From: Josh Stone -Date: Tue, 15 May 2018 17:48:02 -0700 -Subject: [PATCH] Ensure libraries built in stage0 have unique metadata - -Issue #50786 shows a case with local rebuild where the libraries built -by stage0 had the same suffix as stage0's own, and were accidentally -loaded by that stage0 rustc when compiling `librustc_trans`. - -Now we set `__CARGO_DEFAULT_LIB_METADATA` to "bootstrap" during stage0, -rather than the release channel like usual, so the library suffix will -always be completely distinct from the stage0 compiler. ---- - src/bootstrap/builder.rs | 10 +++++++++- - 1 file changed, 9 insertions(+), 1 deletion(-) - -diff --git a/src/bootstrap/builder.rs b/src/bootstrap/builder.rs -index 17f19222e6ea..e5824010ef2c 100644 ---- a/src/bootstrap/builder.rs -+++ b/src/bootstrap/builder.rs -@@ -592,7 +592,15 @@ impl<'a> Builder<'a> { - - // FIXME: Temporary fix for https://github.com/rust-lang/cargo/issues/3005 - // Force cargo to output binaries with disambiguating hashes in the name -- cargo.env("__CARGO_DEFAULT_LIB_METADATA", &self.config.channel); -+ let metadata = if compiler.stage == 0 { -+ // Treat stage0 like special channel, whether it's a normal prior- -+ // release rustc or a local rebuild with the same version, so we -+ // never mix these libraries by accident. -+ "bootstrap" -+ } else { -+ &self.config.channel -+ }; -+ cargo.env("__CARGO_DEFAULT_LIB_METADATA", &metadata); - - let stage; - if compiler.stage == 0 && self.local_rebuild { --- -2.17.0 - diff --git a/0001-Fix-new-renamed_and_removed_lints-warning-247.patch b/0001-Fix-new-renamed_and_removed_lints-warning-247.patch deleted file mode 100644 index 3270fb0..0000000 --- a/0001-Fix-new-renamed_and_removed_lints-warning-247.patch +++ /dev/null @@ -1,70 +0,0 @@ -From ab80da4ea9ea88cdd802f80955e7382bd9368247 Mon Sep 17 00:00:00 2001 -From: Benjamin Gill -Date: Sat, 16 Jun 2018 12:59:44 +0100 -Subject: [PATCH] Fix new renamed_and_removed_lints warning (#247) - -I've verified that this now produces no warnings with Rust 1.26.1 and -1.28.0-nightly (c3b09c968 2018-05-27) ---- - src/error_chain.rs | 4 ++-- - src/impl_error_chain_kind.rs | 4 ++-- - src/lib.rs | 1 - - 3 files changed, 4 insertions(+), 5 deletions(-) - -diff --git a/src/error_chain.rs b/src/error_chain.rs -index cbd42cd67eaf..0926c8889278 100644 ---- a/src/error_chain.rs -+++ b/src/error_chain.rs -@@ -173,7 +173,7 @@ macro_rules! impl_error_chain_processed { - self.0.description() - } - -- #[allow(unknown_lints, unused_doc_comment)] -+ #[allow(unknown_lints, renamed_and_removed_lints, unused_doc_comment, unused_doc_comments)] - fn cause(&self) -> Option<&::std::error::Error> { - match self.1.next_error { - Some(ref c) => Some(&**c), -@@ -424,7 +424,7 @@ macro_rules! impl_extract_backtrace { - ($error_name: ident - $error_kind_name: ident - $([$link_error_path: path, $(#[$meta_links: meta])*])*) => { -- #[allow(unknown_lints, unused_doc_comment)] -+ #[allow(unknown_lints, renamed_and_removed_lints, unused_doc_comment, unused_doc_comments)] - fn extract_backtrace(e: &(::std::error::Error + Send + 'static)) - -> Option<::std::sync::Arc<$crate::Backtrace>> { - if let Some(e) = e.downcast_ref::<$error_name>() { -diff --git a/src/impl_error_chain_kind.rs b/src/impl_error_chain_kind.rs -index d6c05c8a882b..d5e266389cd6 100644 ---- a/src/impl_error_chain_kind.rs -+++ b/src/impl_error_chain_kind.rs -@@ -264,7 +264,7 @@ macro_rules! impl_error_chain_kind { - $item:ident: $imode:tt [$(#[$imeta:meta])*] [$( $var:ident: $typ:ty ),*] {$( $funcs:tt )*} - )*} - ) => { -- #[allow(unknown_lints, unused, unused_doc_comment)] -+ #[allow(unknown_lints, unused, renamed_and_removed_lints, unused_doc_comment, unused_doc_comments)] - impl ::std::fmt::Display for $name { - fn fmt(&self, fmt: &mut ::std::fmt::Formatter) - -> ::std::fmt::Result -@@ -316,7 +316,7 @@ macro_rules! impl_error_chain_kind { - } - } - }*/ -- #[allow(unknown_lints, unused, unused_doc_comment)] -+ #[allow(unknown_lints, unused, renamed_and_removed_lints, unused_doc_comment, unused_doc_comments)] - impl $name { - /// A string describing the error kind. - pub fn description(&self) -> &str { -diff --git a/src/lib.rs b/src/lib.rs -index d0881fcef1c1..6421194f8ca8 100644 ---- a/src/lib.rs -+++ b/src/lib.rs -@@ -1,5 +1,4 @@ - #![deny(missing_docs)] --#![allow(unknown_lints)] // to be removed when unused_doc_comments lints is merged - #![doc(html_root_url = "https://docs.rs/error-chain/0.11.0")] - - //! A library for consistent and reliable error handling --- -2.17.1 - diff --git a/rust-52760-test_loading_atoi.patch b/rust-52760-test_loading_atoi.patch new file mode 100644 index 0000000..77ddf13 --- /dev/null +++ b/rust-52760-test_loading_atoi.patch @@ -0,0 +1,62 @@ +From efa11da26a882aaf57f7eae747e48d128c474bf3 Mon Sep 17 00:00:00 2001 +From: Josh Stone +Date: Thu, 26 Jul 2018 17:20:02 -0700 +Subject: [PATCH] rustc_metadata: test loading atoi instead of cos + +Some platforms don't actually have `libm` already linked in the test +infrastructure, and then `dynamic_lib::tests::test_loading_cosine` would +fail to find the "cos" symbol. Every platform running this test should +have `libc` and "atoi" though, so try to use that symbol instead. + +Fixes #45410. +--- + src/librustc_metadata/dynamic_lib.rs | 25 ++++++++++++------------- + 1 file changed, 12 insertions(+), 13 deletions(-) + +diff --git a/src/librustc_metadata/dynamic_lib.rs b/src/librustc_metadata/dynamic_lib.rs +index d7da0d00012e..182a071277ec 100644 +--- a/src/librustc_metadata/dynamic_lib.rs ++++ b/src/librustc_metadata/dynamic_lib.rs +@@ -90,30 +90,29 @@ mod tests { + use std::mem; + + #[test] +- fn test_loading_cosine() { ++ fn test_loading_atoi() { + if cfg!(windows) { + return + } + +- // The math library does not need to be loaded since it is already +- // statically linked in +- let libm = match DynamicLibrary::open(None) { ++ // The C library does not need to be loaded since it is already linked in ++ let lib = match DynamicLibrary::open(None) { + Err(error) => panic!("Could not load self as module: {}", error), +- Ok(libm) => libm ++ Ok(lib) => lib + }; + +- let cosine: extern fn(libc::c_double) -> libc::c_double = unsafe { +- match libm.symbol("cos") { +- Err(error) => panic!("Could not load function cos: {}", error), +- Ok(cosine) => mem::transmute::<*mut u8, _>(cosine) ++ let atoi: extern fn(*const libc::c_char) -> libc::c_int = unsafe { ++ match lib.symbol("atoi") { ++ Err(error) => panic!("Could not load function atoi: {}", error), ++ Ok(atoi) => mem::transmute::<*mut u8, _>(atoi) + } + }; + +- let argument = 0.0; +- let expected_result = 1.0; +- let result = cosine(argument); ++ let argument = CString::new("1383428980").unwrap(); ++ let expected_result = 0x52757374; ++ let result = atoi(argument.as_ptr()); + if result != expected_result { +- panic!("cos({}) != {} but equaled {} instead", argument, ++ panic!("atoi({:?}) != {} but equaled {} instead", argument, + expected_result, result) + } + } diff --git a/rust-52876-const-endianess.patch b/rust-52876-const-endianess.patch new file mode 100644 index 0000000..1e844e8 --- /dev/null +++ b/rust-52876-const-endianess.patch @@ -0,0 +1,26 @@ +From 1ea2765918d1212a07e1359537470c477d82a681 Mon Sep 17 00:00:00 2001 +From: Josh Stone +Date: Mon, 30 Jul 2018 13:08:56 -0700 +Subject: [PATCH] run-pass/const-endianness: negate before to_le() + +`const LE_I128` needs parentheses to negate the value *before* calling +`to_le()`, otherwise it doesn't match the operations performed in the +black-boxed part of the test. This only makes a tangible difference on +big-endian targets. +--- + src/test/run-pass/const-endianess.rs | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/test/run-pass/const-endianess.rs b/src/test/run-pass/const-endianess.rs +index fa34b49210a6..95c738d3ec49 100644 +--- a/src/test/run-pass/const-endianess.rs ++++ b/src/test/run-pass/const-endianess.rs +@@ -25,7 +25,7 @@ fn main() { + #[cfg(not(target_arch = "asmjs"))] + { + const BE_U128: u128 = 999999u128.to_be(); +- const LE_I128: i128 = -999999i128.to_le(); ++ const LE_I128: i128 = (-999999i128).to_le(); + assert_eq!(BE_U128, b(999999u128).to_be()); + assert_eq!(LE_I128, b(-999999i128).to_le()); + } diff --git a/rust.spec b/rust.spec index 4c1f55a..702cbb7 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.26.0 -%global bootstrap_cargo 1.26.0 +%global bootstrap_rust 1.27.2 +%global bootstrap_cargo 1.27.0 %global bootstrap_channel %{bootstrap_rust} -%global bootstrap_date 2018-05-10 +%global bootstrap_date 2018-07-20 # Only the specified arches will use bootstrap binaries. #global bootstrap_arches %%{rust_arches} @@ -49,14 +49,14 @@ # Some sub-packages are versioned independently of the rust compiler and runtime itself. # Also beware that if any of these are not changed in a version bump, then the release # number should still increase, not be reset to 1! -%global rustc_version 1.27.2 -%global cargo_version 1.27.0 -%global rustfmt_version 0.6.1 -%global rls_version 0.127.0 +%global rustc_version 1.28.0 +%global cargo_version 1.28.0 +%global rustfmt_version 0.8.2 +%global rls_version 0.128.0 Name: rust Version: %{rustc_version} -Release: 4%{?dist} +Release: 1%{?dist} Summary: The Rust Programming Language License: (ASL 2.0 or MIT) and (BSD and MIT) # ^ written as: (rust itself) and (bundled libraries) @@ -70,12 +70,11 @@ ExclusiveArch: %{rust_arches} %endif Source0: https://static.rust-lang.org/dist/%{rustc_package}.tar.xz -# https://github.com/rust-lang/rust/pull/50789/ -Patch1: 0001-Ensure-libraries-built-in-stage0-have-unique-metadat.patch +# https://github.com/rust-lang/rust/pull/52760 +Patch1: rust-52760-test_loading_atoi.patch -# https://github.com/rust-lang/rust/issues/51650 -# https://github.com/rust-lang-nursery/error-chain/pull/247 -Patch2: 0001-Fix-new-renamed_and_removed_lints-warning-247.patch +# https://github.com/rust-lang/rust/pull/52876 +Patch2: rust-52876-const-endianess.patch # Get the Rust triple for any arch. %{lua: function rust_triple(arch) @@ -175,7 +174,7 @@ BuildRequires: procps-ng BuildRequires: gdb # TODO: work on unbundling these! -Provides: bundled(libbacktrace) = 6.1.0 +Provides: bundled(libbacktrace) = 8.1.0 Provides: bundled(miniz) = 1.16~beta+r1 # Virtual provides for folks who attempt "dnf install rustc" @@ -376,10 +375,7 @@ test -f '%{local_rust_root}/bin/rustc' %setup -q -n %{rustc_package} %patch1 -p1 - -pushd src/vendor/error-chain %patch2 -p1 -popd %if "%{python}" == "python3" sed -i.try-py3 -e '/try python2.7/i try python3 "$@"' ./configure @@ -459,6 +455,7 @@ export LIBGIT2_SYS_USE_PKG_CONFIG=1 %{enable_debuginfo} \ --enable-extended \ --enable-vendor \ + --enable-verbose-tests \ --release-channel=%{channel} %{python} ./x.py build @@ -650,6 +647,9 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %changelog +* Thu Aug 02 2018 Josh Stone - 1.28.0-1 +- Update to 1.28.0. + * Tue Jul 24 2018 Josh Stone - 1.27.2-4 - Update to 1.27.2. diff --git a/sources b/sources index a832ad6..d8ca02f 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (rustc-1.27.2-src.tar.xz) = 3a54d5d04512a454bb6ccc1e05e513ba36051555c4acfb3b99e072cd3a113f66533c5d39410eb3ababd6e79fb2f16b0e569a45597e82ec2158b585e8aec60407 +SHA512 (rustc-1.28.0-src.tar.xz) = a4885cd42a1006738cca2f0d8c0d5e4fd4014fc4629cbf691935bd36ffb896c553717022e67532359b5f1bd8e5050fc38b9dffed7c45cc76f7089ec134dfb980 diff --git a/sources-bootstrap b/sources-bootstrap index 8336a9d..7540dd1 100644 --- a/sources-bootstrap +++ b/sources-bootstrap @@ -1,8 +1,8 @@ -SHA512 (rustc-1.27.2-src.tar.xz) = 3a54d5d04512a454bb6ccc1e05e513ba36051555c4acfb3b99e072cd3a113f66533c5d39410eb3ababd6e79fb2f16b0e569a45597e82ec2158b585e8aec60407 -SHA512 (rust-1.26.0-aarch64-unknown-linux-gnu.tar.xz) = 731e1db2e39d412997cee3d8d51a9d45a84e7092f1c66524f311f4967f7638964581a8c71a5937a7f80a8e0bae153298a6a806e56e525015ab7caf7b040b14b7 -SHA512 (rust-1.26.0-armv7-unknown-linux-gnueabihf.tar.xz) = 5766dbba6f4faae3e8dfd1d98ea948e3835d5b1c28b8daf6c734afd7f27301aa857147eb28762462f77c9da539aae2a81319f194154245abd5cdae7067f24d6c -SHA512 (rust-1.26.0-i686-unknown-linux-gnu.tar.xz) = 1257f9edefc49ee1742c3acd666d15f077c4d999a82dfe0d574df5c41981c3f716adf86b23d96cf9a6757508aea92abcbe06ad9e3bec2cb4ac19512d60ebba31 -SHA512 (rust-1.26.0-powerpc64le-unknown-linux-gnu.tar.xz) = 9b856967cb94e3d930877d9b28bd9ae2e223a15a15231315f02bfd9c47ad488461b1a55458a6e3f1c9c9a8367c0c3af5ff1dc19d29f3b3debe9baaf2e1b64701 -SHA512 (rust-1.26.0-powerpc64-unknown-linux-gnu.tar.xz) = 62e8acd65b9e56e3d3cc46c5d9984b9c80ef83d7204c3f87dbce9a1229ef19db39ed14154fda4416c1656103f82e106b19ba709943d94d408e11283470a94908 -SHA512 (rust-1.26.0-s390x-unknown-linux-gnu.tar.xz) = f78b8be5c7a2c1c07527959c4c57cfb0fc43ef79fa313eb8c1afd1fc024753fac17f0001f930b651035c1e704ee391d822ddf588a242dc75cc476b3f20dea682 -SHA512 (rust-1.26.0-x86_64-unknown-linux-gnu.tar.xz) = 457503fea324251a92f25d0d45f1e2ac7d342a6a8f52d1abe93a579c7ae9b7f453a707d353e82614b37790747e8551f9762188ee25ff883495598cbf17b3f97e +SHA512 (rustc-1.28.0-src.tar.xz) = a4885cd42a1006738cca2f0d8c0d5e4fd4014fc4629cbf691935bd36ffb896c553717022e67532359b5f1bd8e5050fc38b9dffed7c45cc76f7089ec134dfb980 +SHA512 (rust-1.27.2-aarch64-unknown-linux-gnu.tar.xz) = 84022350f1e8fc34a353a09848333424a557ddea3b9445a1a5fc9d2f2abced942154e80888ab4091174d6d83c6766f583ef240ab2e2233de5d536633d2765040 +SHA512 (rust-1.27.2-armv7-unknown-linux-gnueabihf.tar.xz) = afa6469ebc851b1c4f3911434504c52d6fb0e2f9779048fa6217cce65cbf8fdd9f3ba990dc8f0e99371040b32ee304e88bfbf27604385c6d3216e0ca44f200a1 +SHA512 (rust-1.27.2-i686-unknown-linux-gnu.tar.xz) = e17960120bdd18a527c0783ce8ca8d76cdc9b436f36a73a82fd2ea709b253f33feeb88310fab7a86305bad403eb5dad7ea43d0e5bc5ad1e3847f29e85040303a +SHA512 (rust-1.27.2-powerpc64le-unknown-linux-gnu.tar.xz) = 4993430b97f348620338524dbd5f64c6b662cfca51ce1616902e48e08babc0287f6b0db73e13b0ce478a60c98b17f3878c35a33823692fa0e37e265797bb661f +SHA512 (rust-1.27.2-powerpc64-unknown-linux-gnu.tar.xz) = 21d90f1e71f99e2bf11ba795e76eb428e88d6ac2cb0197f7111e3a4923fa2896b9f41bd54cac5c43329a3d03484d5441e3b8aad599164c69a0c99e08a7ecac15 +SHA512 (rust-1.27.2-s390x-unknown-linux-gnu.tar.xz) = f6ee1e3c41c2602064377262fe74b39b0908a3fb8995c71a7b02ea8c8f0fe6909ffc7ee953e6b0865793d3a8e577096c85d9d9ce51388bb52d7fdc11fcb9db46 +SHA512 (rust-1.27.2-x86_64-unknown-linux-gnu.tar.xz) = 14861392dad81d2c040d0deb64d5dd34652d5cc2875e404609a0f13c8fb6bdc38f9bc7b1e309829365a00c42b610f2b7a73cffa232ecfdf0618b5508a8667198