diff --git a/.gitignore b/.gitignore index 1dc9ca7..001fa18 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1 @@ -SOURCES/rustc-1.45.2-src.tar.xz +SOURCES/rustc-1.47.0-src.tar.xz diff --git a/.rust.metadata b/.rust.metadata index 9082dca..e032f6a 100644 --- a/.rust.metadata +++ b/.rust.metadata @@ -1 +1 @@ -ef2e4d6a728918cc78dd535a3d6d842fa485e8c7 SOURCES/rustc-1.45.2-src.tar.xz +7c74bea0e1db296aa0cf8c6e0b6fb1d392b62c0c SOURCES/rustc-1.47.0-src.tar.xz diff --git a/SOURCES/0001-Fix-jobserver_exists-test-on-single-cpu-systems.patch b/SOURCES/0001-Fix-jobserver_exists-test-on-single-cpu-systems.patch deleted file mode 100644 index 1650679..0000000 --- a/SOURCES/0001-Fix-jobserver_exists-test-on-single-cpu-systems.patch +++ /dev/null @@ -1,29 +0,0 @@ -From 02fc16aece46abcd23d2ade2d969497f07fe26ab Mon Sep 17 00:00:00 2001 -From: Alex Crichton -Date: Fri, 7 Aug 2020 12:50:25 -0700 -Subject: [PATCH] Fix jobserver_exists test on single-cpu systems - -Closes #8595 ---- - tests/testsuite/jobserver.rs | 5 ++++- - 1 file changed, 4 insertions(+), 1 deletion(-) - -diff --git a/tests/testsuite/jobserver.rs b/tests/testsuite/jobserver.rs -index 9e91c956cd75..16518ee2c614 100644 ---- a/tests/testsuite/jobserver.rs -+++ b/tests/testsuite/jobserver.rs -@@ -51,7 +51,10 @@ fn jobserver_exists() { - .file("src/lib.rs", "") - .build(); - -- p.cargo("build").run(); -+ // Explicitly use `-j2` to ensure that there's eventually going to be a -+ // token to read from `valdiate` above, since running the build script -+ // itself consumes a token. -+ p.cargo("build -j2").run(); - } - - #[cargo_test] --- -2.26.2 - diff --git a/SOURCES/0001-doc-disambiguate-stat-in-MetadataExt-as_raw_stat.patch b/SOURCES/0001-doc-disambiguate-stat-in-MetadataExt-as_raw_stat.patch new file mode 100644 index 0000000..bf6ef9c --- /dev/null +++ b/SOURCES/0001-doc-disambiguate-stat-in-MetadataExt-as_raw_stat.patch @@ -0,0 +1,46 @@ +From f200c1e7afdd04b42c01c0108735e5b14ca07d93 Mon Sep 17 00:00:00 2001 +From: Josh Stone +Date: Fri, 9 Oct 2020 20:12:26 -0700 +Subject: [PATCH] doc: disambiguate stat in MetadataExt::as_raw_stat + +A few architectures in `os::linux::raw` import `libc::stat`, rather than +defining that type directly. However, that also imports the _function_ +called `stat`, which makes this doc link ambiguous: + + error: `crate::os::linux::raw::stat` is both a struct and a function + --> library/std/src/os/linux/fs.rs:21:19 + | + 21 | /// [`stat`]: crate::os::linux::raw::stat + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ ambiguous link + | + = note: `-D broken-intra-doc-links` implied by `-D warnings` + help: to link to the struct, prefix with the item type + | + 21 | /// [`stat`]: struct@crate::os::linux::raw::stat + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + help: to link to the function, add parentheses + | + 21 | /// [`stat`]: crate::os::linux::raw::stat() + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +We want the `struct`, so it's now prefixed accordingly. +--- + library/std/src/os/linux/fs.rs | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/library/std/src/os/linux/fs.rs b/library/std/src/os/linux/fs.rs +index ff23c3d67e3b..9b7af97616c9 100644 +--- a/library/std/src/os/linux/fs.rs ++++ b/library/std/src/os/linux/fs.rs +@@ -20,7 +20,7 @@ pub trait MetadataExt { + /// Unix platforms. The `os::unix::fs::MetadataExt` trait contains the + /// cross-Unix abstractions contained within the raw stat. + /// +- /// [`stat`]: crate::os::linux::raw::stat ++ /// [`stat`]: struct@crate::os::linux::raw::stat + /// + /// # Examples + /// +-- +2.26.2 + diff --git a/SOURCES/0001-use-NativeEndian-in-symbolize-gimli-Context.patch b/SOURCES/0001-use-NativeEndian-in-symbolize-gimli-Context.patch new file mode 100644 index 0000000..81b7a63 --- /dev/null +++ b/SOURCES/0001-use-NativeEndian-in-symbolize-gimli-Context.patch @@ -0,0 +1,28 @@ +From 6f8efee8c936de65bc31610eea30abd5461a5dd1 Mon Sep 17 00:00:00 2001 +From: Josh Stone +Date: Thu, 8 Oct 2020 15:53:49 -0700 +Subject: [PATCH] use NativeEndian in symbolize::gimli::Context + +`Object` uses `NativeEndian`, so the `Context` should too. + +Cc: https://github.com/rust-lang/rust/issues/77410 +--- + src/symbolize/gimli.rs | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/symbolize/gimli.rs b/src/symbolize/gimli.rs +index 58ed8bafca3d..273ff43f1c8c 100644 +--- a/src/symbolize/gimli.rs ++++ b/src/symbolize/gimli.rs +@@ -5,7 +5,7 @@ + //! intended to wholesale replace the `libbacktrace.rs` implementation. + + use self::gimli::read::EndianSlice; +-use self::gimli::LittleEndian as Endian; ++use self::gimli::NativeEndian as Endian; + use self::mmap::Mmap; + use self::stash::Stash; + use super::BytesOrWideString; +-- +2.26.2 + diff --git a/SOURCES/rustc-1.45.0-no-default-pie.patch b/SOURCES/rustc-1.45.0-no-default-pie.patch new file mode 100644 index 0000000..726df24 --- /dev/null +++ b/SOURCES/rustc-1.45.0-no-default-pie.patch @@ -0,0 +1,20 @@ +diff --git a/src/librustc_codegen_ssa/back/link.rs b/src/librustc_codegen_ssa/back/link.rs +index dcce1d45298c..5c11f7276f26 100644 +--- a/src/librustc_codegen_ssa/back/link.rs ++++ b/src/librustc_codegen_ssa/back/link.rs +@@ -1184,10 +1184,12 @@ fn exec_linker( + } + + fn link_output_kind(sess: &Session, crate_type: CrateType) -> LinkOutputKind { +- let kind = match (crate_type, sess.crt_static(Some(crate_type)), sess.relocation_model()) { +- (CrateType::Executable, false, RelocModel::Pic) => LinkOutputKind::DynamicPicExe, ++ // Only use PIE if explicity specified. ++ let explicit_pic = matches!(sess.opts.cg.relocation_model, Some(RelocModel::Pic)); ++ let kind = match (crate_type, sess.crt_static(Some(crate_type)), explicit_pic) { ++ (CrateType::Executable, false, true) => LinkOutputKind::DynamicPicExe, + (CrateType::Executable, false, _) => LinkOutputKind::DynamicNoPicExe, +- (CrateType::Executable, true, RelocModel::Pic) => LinkOutputKind::StaticPicExe, ++ (CrateType::Executable, true, true) => LinkOutputKind::StaticPicExe, + (CrateType::Executable, true, _) => LinkOutputKind::StaticNoPicExe, + (_, true, _) => LinkOutputKind::StaticDylib, + (_, false, _) => LinkOutputKind::DynamicDylib, diff --git a/SOURCES/rustc-1.47.0-disable-http2.patch b/SOURCES/rustc-1.47.0-disable-http2.patch new file mode 100644 index 0000000..e59c892 --- /dev/null +++ b/SOURCES/rustc-1.47.0-disable-http2.patch @@ -0,0 +1,66 @@ +--- rustc-1.47.0-src/Cargo.lock.orig 2020-10-08 12:21:40.516837553 -0700 ++++ rustc-1.47.0-src/Cargo.lock 2020-10-08 12:23:25.327581933 -0700 +@@ -837,7 +837,6 @@ + dependencies = [ + "cc", + "libc", +- "libnghttp2-sys", + "libz-sys", + "openssl-sys", + "pkg-config", +@@ -1642,16 +1641,6 @@ + ] + + [[package]] +-name = "libnghttp2-sys" +-version = "0.1.4+1.41.0" +-source = "registry+https://github.com/rust-lang/crates.io-index" +-checksum = "03624ec6df166e79e139a2310ca213283d6b3c30810c54844f307086d4488df1" +-dependencies = [ +- "cc", +- "libc", +-] +- +-[[package]] + name = "libz-sys" + version = "1.0.27" + source = "registry+https://github.com/rust-lang/crates.io-index" +--- rustc-1.47.0-src/src/tools/cargo/Cargo.toml.orig 2020-10-07 01:04:03.000000000 -0700 ++++ rustc-1.47.0-src/src/tools/cargo/Cargo.toml 2020-10-08 12:22:17.830034534 -0700 +@@ -25,7 +25,7 @@ + crates-io = { path = "crates/crates-io", version = "0.31.1" } + crossbeam-utils = "0.7" + crypto-hash = "0.3.1" +-curl = { version = "0.4.23", features = ["http2"] } ++curl = { version = "0.4.23", features = [] } + curl-sys = "0.4.22" + env_logger = "0.7.0" + pretty_env_logger = { version = "0.4", optional = true } +--- rustc-1.47.0-src/src/tools/cargo/src/cargo/core/package.rs.orig 2020-10-07 01:04:03.000000000 -0700 ++++ rustc-1.47.0-src/src/tools/cargo/src/cargo/core/package.rs 2020-10-08 12:23:11.246884961 -0700 +@@ -396,14 +396,8 @@ + // Also note that pipelining is disabled as curl authors have indicated + // that it's buggy, and we've empirically seen that it's buggy with HTTP + // proxies. +- let mut multi = Multi::new(); +- let multiplexing = config.http_config()?.multiplexing.unwrap_or(true); +- multi +- .pipelining(false, multiplexing) +- .chain_err(|| "failed to enable multiplexing/pipelining in curl")?; +- +- // let's not flood crates.io with connections +- multi.set_max_host_connections(2)?; ++ let multi = Multi::new(); ++ let multiplexing = false; + + Ok(PackageSet { + packages: package_ids +@@ -566,7 +560,7 @@ + macro_rules! try_old_curl { + ($e:expr, $msg:expr) => { + let result = $e; +- if cfg!(target_os = "macos") { ++ if cfg!(any(target_os = "linux", target_os = "macos")) { + if let Err(e) = result { + warn!("ignoring libcurl {} error: {}", $msg, e); + } diff --git a/SOURCES/rustc-1.42.0-disable-libssh2.patch b/SOURCES/rustc-1.47.0-disable-libssh2.patch similarity index 58% rename from SOURCES/rustc-1.42.0-disable-libssh2.patch rename to SOURCES/rustc-1.47.0-disable-libssh2.patch index 770ad34..5a03b13 100644 --- a/SOURCES/rustc-1.42.0-disable-libssh2.patch +++ b/SOURCES/rustc-1.47.0-disable-libssh2.patch @@ -1,6 +1,6 @@ ---- rustc-1.42.0-src/Cargo.lock.orig 2020-03-09 15:11:17.000000000 -0700 -+++ rustc-1.42.0-src/Cargo.lock 2020-04-02 16:39:22.268896227 -0700 -@@ -1796,7 +1796,6 @@ +--- rustc-1.47.0-src/Cargo.lock.orig 2020-10-07 00:53:22.000000000 -0700 ++++ rustc-1.47.0-src/Cargo.lock 2020-10-08 12:15:07.361298619 -0700 +@@ -1636,7 +1636,6 @@ dependencies = [ "cc", "libc", @@ -8,14 +8,14 @@ "libz-sys", "openssl-sys", "pkg-config", -@@ -1813,20 +1812,6 @@ +@@ -1653,20 +1652,6 @@ ] [[package]] -name = "libssh2-sys" --version = "0.2.14" +-version = "0.2.18" -source = "registry+https://github.com/rust-lang/crates.io-index" --checksum = "36aa6e813339d3a063292b77091dfbbb6152ff9006a459895fa5bebed7d34f10" +-checksum = "eafa907407504b0e683786d4aba47acf250f114d37357d56608333fd167dd0fc" -dependencies = [ - "cc", - "libc", @@ -27,11 +27,11 @@ - -[[package]] name = "libz-sys" - version = "1.0.25" + version = "1.0.27" source = "registry+https://github.com/rust-lang/crates.io-index" ---- rustc-1.42.0-src/vendor/git2/Cargo.toml.orig 2020-03-09 17:00:19.000000000 -0700 -+++ rustc-1.42.0-src/vendor/git2/Cargo.toml 2020-04-02 16:38:46.163664007 -0700 -@@ -55,7 +55,7 @@ +--- rustc-1.47.0-src/vendor/git2/Cargo.toml.orig 2020-10-07 02:33:31.000000000 -0700 ++++ rustc-1.47.0-src/vendor/git2/Cargo.toml 2020-10-08 12:13:37.697228272 -0700 +@@ -49,7 +49,7 @@ version = "0.1.39" [features] diff --git a/SPECS/rust.spec b/SPECS/rust.spec index 0b2cfe1..eff4ff2 100644 --- a/SPECS/rust.spec +++ b/SPECS/rust.spec @@ -10,10 +10,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.44.0 -%global bootstrap_cargo 1.44.0 -%global bootstrap_channel 1.44.0 -%global bootstrap_date 2020-06-04 +%global bootstrap_rust 1.46.0 +%global bootstrap_cargo 1.46.0 +%global bootstrap_channel 1.46.0 +%global bootstrap_date 2020-08-27 # Only the specified arches will use bootstrap binaries. #global bootstrap_arches %%{rust_arches} @@ -23,33 +23,37 @@ # We can also choose to just use Rust's bundled LLVM, in case the system LLVM # is insufficient. Rust currently requires LLVM 8.0+. -%if 0%{?rhel} && 0%{?rhel} <= 6 && !0%{?epel} -%bcond_without bundled_llvm -%else %bcond_with bundled_llvm + +# Requires stable libgit2 1.0 +%if 0%{?fedora} >= 32 +%bcond_with bundled_libgit2 +%else +%bcond_without bundled_libgit2 %endif -# libgit2-sys expects to use its bundled library, which is sometimes just a -# snapshot of libgit2's master branch. This can mean the FFI declarations -# won't match our released libgit2.so, e.g. having changed struct fields. -# So, tread carefully if you toggle this... -%bcond_without bundled_libgit2 - %if 0%{?rhel} +# Disable cargo->libgit2->libssh2 on RHEL, as it's not approved for FIPS (rhbz1732949) %bcond_without disabled_libssh2 %else -%bcond_with bundled_libssh2 +%bcond_with disabled_libssh2 +%endif + +%if 0%{?rhel} && 0%{?rhel} < 8 +%bcond_with curl_http2 +%else +%bcond_without curl_http2 %endif # LLDB isn't available everywhere... -%if !0%{?rhel} || 0%{?rhel} > 7 -%bcond_without lldb -%else +%if 0%{?rhel} && 0%{?rhel} < 8 %bcond_with lldb +%else +%bcond_without lldb %endif Name: rust -Version: 1.45.2 +Version: 1.47.0 Release: 1%{?dist} Summary: The Rust Programming Language License: (ASL 2.0 or MIT) and (BSD and MIT) @@ -64,11 +68,25 @@ ExclusiveArch: %{rust_arches} %endif Source0: https://static.rust-lang.org/dist/%{rustc_package}.tar.xz -# https://github.com/rust-lang/cargo/pull/8598 -Patch1: 0001-Fix-jobserver_exists-test-on-single-cpu-systems.patch +# https://github.com/rust-lang/backtrace-rs/pull/373 +Patch1: 0001-use-NativeEndian-in-symbolize-gimli-Context.patch + +# https://github.com/rust-lang/rust/pull/77777 +Patch2: 0001-doc-disambiguate-stat-in-MetadataExt-as_raw_stat.patch + +### RHEL-specific patches below ### + +# Disable cargo->libgit2->libssh2 on RHEL, as it's not approved for FIPS (rhbz1732949) +Patch100: rustc-1.47.0-disable-libssh2.patch + +# libcurl on RHEL7 doesn't have http2, but since cargo requests it, curl-sys +# will try to build it statically -- instead we turn off the feature. +Patch101: rustc-1.47.0-disable-http2.patch + +# kernel rh1410097 causes too-small stacks for PIE. +# (affects RHEL6 kernels when building for RHEL7) +Patch102: rustc-1.45.0-no-default-pie.patch -# Disable cargo->libgit2->libssh2, as it's not approved for FIPS (rhbz1732949) -Patch10: rustc-1.42.0-disable-libssh2.patch # Get the Rust triple for any arch. %{lua: function rust_triple(arch) @@ -80,6 +98,8 @@ Patch10: rustc-1.42.0-disable-libssh2.patch arch = "powerpc64" elseif arch == "ppc64le" then arch = "powerpc64le" + elseif arch == "riscv64" then + arch = "riscv64gc" end return arch.."-unknown-linux-"..abi end} @@ -113,11 +133,11 @@ end} Provides: bundled(%{name}-bootstrap) = %{bootstrap_rust} %else BuildRequires: cargo >= %{bootstrap_cargo} -%if 0%{?fedora} >= 27 || 0%{?rhel} > 7 -BuildRequires: (%{name} >= %{bootstrap_rust} with %{name} <= %{version}) -%else +%if 0%{?rhel} && 0%{?rhel} < 8 BuildRequires: %{name} >= %{bootstrap_rust} BuildConflicts: %{name} > %{version} +%else +BuildRequires: (%{name} >= %{bootstrap_rust} with %{name} <= %{version}) %endif %global local_rust_root %{_prefix} %endif @@ -127,6 +147,8 @@ BuildRequires: gcc BuildRequires: gcc-c++ BuildRequires: ncurses-devel BuildRequires: curl +# explicit curl-devel to avoid httpd24-curl (rhbz1540167) +BuildRequires: curl-devel BuildRequires: pkgconfig(libcurl) BuildRequires: pkgconfig(liblzma) BuildRequires: pkgconfig(openssl) @@ -141,23 +163,15 @@ BuildRequires: pkgconfig(libgit2) >= 1.0.0 BuildRequires: pkgconfig(libssh2) >= 1.6.0 %endif -%if 0%{?rhel} -%if 0%{?rhel} <= 7 -%global python python2 -%else -%global python /usr/libexec/platform-python -%endif -%else %global python python3 -%endif BuildRequires: %{python} %if %with bundled_llvm BuildRequires: cmake3 >= 3.4.3 -Provides: bundled(llvm) = 10.0.1 +Provides: bundled(llvm) = 11.0.0 %else BuildRequires: cmake >= 2.8.11 -%if 0%{?epel} +%if 0%{?epel} == 7 %global llvm llvm9.0 %endif %if %defined llvm @@ -179,9 +193,6 @@ BuildRequires: procps-ng # debuginfo-gdb tests need gdb BuildRequires: gdb -# TODO: work on unbundling these! -Provides: bundled(libbacktrace) = 1.0.20200219 - # Virtual provides for folks who attempt "dnf install rustc" Provides: rustc = %{version}-%{release} Provides: rustc%{?_isa} = %{version}-%{release} @@ -203,14 +214,14 @@ Requires: /usr/bin/cc # While we don't want to encourage dynamic linking to Rust shared libraries, as # there's no stable ABI, we still need the unallocated metadata (.rustc) to -# support custom-derive plugins like #[proc_macro_derive(Foo)]. But eu-strip is -# very eager by default, so we have to limit it to -g, only debugging symbols. -%if 0%{?fedora} >= 27 || 0%{?rhel} > 7 -# Newer find-debuginfo.sh supports --keep-section, which is preferable. rhbz1465997 -%global _find_debuginfo_opts --keep-section .rustc -%else +# support custom-derive plugins like #[proc_macro_derive(Foo)]. +%if 0%{?rhel} && 0%{?rhel} < 8 +# eu-strip is very eager by default, so we have to limit it to -g, only debugging symbols. %global _find_debuginfo_opts -g %undefine _include_minidebuginfo +%else +# Newer find-debuginfo.sh supports --keep-section, which is preferable. rhbz1465997 +%global _find_debuginfo_opts --keep-section .rustc %endif # Use hardening ldflags. @@ -262,11 +273,7 @@ programs. Summary: LLDB pretty printers for Rust BuildArch: noarch Requires: lldb -%if 0%{?fedora} >= 31 || 0%{?rhel} > 7 -Requires: python3-lldb -%else -Requires: python2-lldb -%endif +Requires: %{python}-lldb Requires: %{name}-debugger-common = %{version}-%{release} %description lldb @@ -402,14 +409,25 @@ test -f '%{local_rust_root}/bin/rustc' %setup -q -n %{rustc_package} -%patch1 -p1 -d src/tools/cargo +%patch1 -p1 -d library/backtrace +%patch2 -p1 %if %with disabled_libssh2 -%patch10 -p1 +%patch100 -p1 %endif -%if "%{python}" != "python2" -sed -i.try-py3 -e '/try python2.7/i try %{python} "$@"' ./configure +%if %without curl_http2 +%patch101 -p1 +rm -rf vendor/libnghttp2-sys/ +%endif + +%if 0%{?rhel} && 0%{?rhel} < 8 +%patch102 -p1 -b .no-pie +%endif + +%if "%{python}" != "python3" +# Use our preferred python first +sed -i.try-python -e '/^try python3 /i try "%{python}" "$@"' ./configure %endif %if %without bundled_llvm @@ -437,10 +455,7 @@ rm -rf vendor/libssh2-sys/ # This only affects the transient rust-installer, but let it use our dynamic xz-libs sed -i.lzma -e '/LZMA_API_STATIC/d' src/bootstrap/tool.rs -# rename bundled license for packaging -cp -a vendor/backtrace-sys/src/libbacktrace/LICENSE{,-libbacktrace} - -%if %{with bundled_llvm} && 0%{?epel} +%if %{with bundled_llvm} && 0%{?epel} == 7 mkdir -p cmake-bin ln -s /usr/bin/cmake3 cmake-bin/cmake %global cmake_path $PWD/cmake-bin @@ -463,26 +478,23 @@ find vendor -name .cargo-checksum.json \ # it's a shebang and make them executable. Then brp-mangle-shebangs gets upset... find -name '*.rs' -type f -perm /111 -exec chmod -v -x '{}' '+' - -%build -# This package fails to build with LTO due to undefined symbols. LTO -# was disabled in OpenSuSE as well, but with no real explanation why -# beyond the undefined symbols. It really should be investigated further. -# Disable LTO -%define _lto_cflags %{nil} - +# Set up shared environment variables for build/install/check +%global rust_env RUSTFLAGS="%{rustflags}" +%if 0%{?cmake_path:1} +%global rust_env %{rust_env} PATH="%{cmake_path}:$PATH" +%endif %if %without bundled_libgit2 # convince libgit2-sys to use the distro libgit2 -export LIBGIT2_SYS_USE_PKG_CONFIG=1 +%global rust_env %{rust_env} LIBGIT2_SYS_USE_PKG_CONFIG=1 %endif - %if %without bundled_libssh2 # convince libssh2-sys to use the distro libssh2 -export LIBSSH2_SYS_USE_PKG_CONFIG=1 +%global rust_env %{rust_env} LIBSSH2_SYS_USE_PKG_CONFIG=1 %endif -%{?cmake_path:export PATH=%{cmake_path}:$PATH} -%{?rustflags:export RUSTFLAGS="%{rustflags}"} + +%build +export %{rust_env} # We're going to override --libdir when configuring to get rustlib into a # common path, but we'll fix the shared libraries during install. @@ -492,7 +504,7 @@ export LIBSSH2_SYS_USE_PKG_CONFIG=1 %ifarch %{arm} %{ix86} s390x # full debuginfo is exhausting memory; just do libstd for now # https://github.com/rust-lang/rust/issues/45854 -%if (0%{?fedora} && 0%{?fedora} < 27) || (0%{?rhel} && 0%{?rhel} <= 7) +%if 0%{?rhel} && 0%{?rhel} < 8 # Older rpmbuild didn't work with partial debuginfo coverage. %global debug_package %{nil} %define enable_debuginfo --debuginfo-level=0 @@ -535,13 +547,12 @@ fi %{?codegen_units_std} \ --release-channel=%{channel} -%{python} ./x.py build -j "$ncpus" -%{python} ./x.py doc +%{python} ./x.py build -j "$ncpus" --stage 2 +%{python} ./x.py doc --stage 2 %install -%{?cmake_path:export PATH=%{cmake_path}:$PATH} -%{?rustflags:export RUSTFLAGS="%{rustflags}"} +export %{rust_env} DESTDIR=%{buildroot} %{python} ./x.py install @@ -605,20 +616,19 @@ ln -sT ../rust/html/cargo/ %{buildroot}%{_docdir}/cargo/html %if %without lldb rm -f %{buildroot}%{_bindir}/rust-lldb -rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* +rm -f %{buildroot}%{rustlibdir}/etc/lldb_* %endif %check -%{?cmake_path:export PATH=%{cmake_path}:$PATH} -%{?rustflags:export RUSTFLAGS="%{rustflags}"} +export %{rust_env} # The results are not stable on koji, so mask errors and just log it. -%{python} ./x.py test --no-fail-fast || : -%{python} ./x.py test --no-fail-fast cargo || : -%{python} ./x.py test --no-fail-fast clippy || : -%{python} ./x.py test --no-fail-fast rls || : -%{python} ./x.py test --no-fail-fast rustfmt || : +%{python} ./x.py test --no-fail-fast --stage 2 || : +%{python} ./x.py test --no-fail-fast --stage 2 cargo || : +%{python} ./x.py test --no-fail-fast --stage 2 clippy || : +%{python} ./x.py test --no-fail-fast --stage 2 rls || : +%{python} ./x.py test --no-fail-fast --stage 2 rustfmt || : %ldconfig_scriptlets @@ -626,7 +636,6 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %files %license COPYRIGHT LICENSE-APACHE LICENSE-MIT -%license vendor/backtrace-sys/src/libbacktrace/LICENSE-libbacktrace %doc README.md %{_bindir}/rustc %{_bindir}/rustdoc @@ -649,19 +658,19 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %files debugger-common %dir %{rustlibdir} %dir %{rustlibdir}/etc -%{rustlibdir}/etc/debugger_*.py* +%{rustlibdir}/etc/rust_*.py* %files gdb %{_bindir}/rust-gdb -%{rustlibdir}/etc/gdb_*.py* +%{rustlibdir}/etc/gdb_* %exclude %{_bindir}/rust-gdbgui %if %with lldb %files lldb %{_bindir}/rust-lldb -%{rustlibdir}/etc/lldb_*.py* +%{rustlibdir}/etc/lldb_* %endif @@ -728,6 +737,12 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %changelog +* Thu Oct 22 2020 Josh Stone - 1.47.0-1 +- Update to 1.47.0. + +* Wed Oct 14 2020 Josh Stone - 1.46.0-1 +- Update to 1.46.0. + * Tue Aug 04 2020 Josh Stone - 1.45.2-1 - Update to 1.45.2.