diff --git a/.gitignore b/.gitignore index 1dc9ca7..22752a2 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1 @@ -SOURCES/rustc-1.45.2-src.tar.xz +SOURCES/rustc-1.53.0-src.tar.xz diff --git a/.rust.metadata b/.rust.metadata index 9082dca..f756636 100644 --- a/.rust.metadata +++ b/.rust.metadata @@ -1 +1 @@ -ef2e4d6a728918cc78dd535a3d6d842fa485e8c7 SOURCES/rustc-1.45.2-src.tar.xz +ae467484f1e961f15bb521a6b5305377ec61f039 SOURCES/rustc-1.53.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/rustc-1.42.0-disable-libssh2.patch b/SOURCES/rustc-1.42.0-disable-libssh2.patch deleted file mode 100644 index 770ad34..0000000 --- a/SOURCES/rustc-1.42.0-disable-libssh2.patch +++ /dev/null @@ -1,42 +0,0 @@ ---- 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 @@ - dependencies = [ - "cc", - "libc", -- "libssh2-sys", - "libz-sys", - "openssl-sys", - "pkg-config", -@@ -1813,20 +1812,6 @@ - ] - - [[package]] --name = "libssh2-sys" --version = "0.2.14" --source = "registry+https://github.com/rust-lang/crates.io-index" --checksum = "36aa6e813339d3a063292b77091dfbbb6152ff9006a459895fa5bebed7d34f10" --dependencies = [ -- "cc", -- "libc", -- "libz-sys", -- "openssl-sys", -- "pkg-config", -- "vcpkg", --] -- --[[package]] - name = "libz-sys" - version = "1.0.25" - 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 @@ - version = "0.1.39" - - [features] --default = ["ssh", "https", "ssh_key_from_memory"] -+default = ["https"] - https = ["libgit2-sys/https", "openssl-sys", "openssl-probe"] - ssh = ["libgit2-sys/ssh"] - ssh_key_from_memory = ["libgit2-sys/ssh_key_from_memory"] diff --git a/SPECS/rust.spec b/SPECS/rust.spec index 0e38b83..b7f9a4d 100644 --- a/SPECS/rust.spec +++ b/SPECS/rust.spec @@ -1,7 +1,7 @@ # Only x86_64 and i686 are Tier 1 platforms at this time. -# https://forge.rust-lang.org/platform-support.html -%global rust_arches x86_64 i686 armv7hl aarch64 ppc64 ppc64le s390x -#global rust_arches x86_64 i686 aarch64 ppc64le s390x +# https://doc.rust-lang.org/nightly/rustc/platform-support.html +#global rust_arches x86_64 i686 armv7hl aarch64 ppc64 ppc64le s390x +%global rust_arches x86_64 i686 aarch64 ppc64le s390x # The channel can be stable, beta, or nightly %{!?channel: %global channel stable} @@ -10,47 +10,60 @@ # 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.52.0 +%global bootstrap_cargo 1.52.0 +%global bootstrap_channel 1.52.0 +%global bootstrap_date 2021-05-06 # Only the specified arches will use bootstrap binaries. #global bootstrap_arches %%{rust_arches} +# Define a space-separated list of targets to ship rust-std-static-$triple for +# cross-compilation. The packages are noarch, but they're not fully +# reproducible between hosts, so only x86_64 actually builds it. +%ifarch x86_64 +%if 0%{?fedora} || 0%{?rhel} >= 8 +%global cross_targets wasm32-unknown-unknown +%endif +%endif + # Using llvm-static may be helpful as an opt-in, e.g. to aid LLVM rebases. %bcond_with llvm_static # 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 +# is insufficient. Rust currently requires LLVM 10.0+. %bcond_with bundled_llvm -%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... +# Requires stable libgit2 1.1 +%if 0%{?fedora} >= 34 +%bcond_with bundled_libgit2 +%else %bcond_without bundled_libgit2 +%endif %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 -# LLDB isn't available everywhere... -%if !0%{?rhel} || 0%{?rhel} > 7 -%bcond_without lldb +%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} < 8 %bcond_with lldb +%else +%bcond_without lldb %endif Name: rust -Version: 1.45.2 -Release: 1%{?dist} +Version: 1.53.0 +Release: 2%{?dist} Summary: The Rust Programming Language License: (ASL 2.0 or MIT) and (BSD and MIT) # ^ written as: (rust itself) and (bundled libraries) @@ -64,11 +77,26 @@ 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 +# This internal rust-abi change broke s390x -- revert for now. +# https://github.com/rust-lang/rust/issues/80810#issuecomment-781784032 +Patch1: 0001-Revert-Auto-merge-of-79547.patch + +# By default, rust tries to use "rust-lld" as a linker for WebAssembly. +Patch2: 0001-Use-lld-provided-by-system-for-wasm.patch + +### RHEL-specific patches below ### + +# Disable cargo->libgit2->libssh2 on RHEL, as it's not approved for FIPS (rhbz1732949) +Patch100: rustc-1.48.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.53.0-disable-http2.patch + +# kernel rh1410097 causes too-small stacks for PIE. +# (affects RHEL6 kernels when building for RHEL7) +Patch102: rustc-1.51.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 +108,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 +143,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,38 +157,32 @@ 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) BuildRequires: pkgconfig(zlib) %if %without bundled_libgit2 -BuildRequires: pkgconfig(libgit2) >= 1.0.0 +BuildRequires: pkgconfig(libgit2) >= 1.1.0 %endif -%if %{without disabled_libssh2} && %{without bundled_libssh2} +%if %{without disabled_libssh2} # needs libssh2_userauth_publickey_frommemory 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 +BuildRequires: cmake3 >= 3.13.4 +Provides: bundled(llvm) = 12.0.0 %else BuildRequires: cmake >= 2.8.11 -%if 0%{?epel} -%global llvm llvm9.0 +%if 0%{?epel} == 7 +%global llvm llvm11 %endif %if %defined llvm %global llvm_root %{_libdir}/%{llvm} @@ -166,7 +190,7 @@ BuildRequires: cmake >= 2.8.11 %global llvm llvm %global llvm_root %{_prefix} %endif -BuildRequires: %{llvm}-devel >= 8.0 +BuildRequires: %{llvm}-devel >= 10.0 %if %with llvm_static BuildRequires: %{llvm}-static BuildRequires: libffi-devel @@ -179,9 +203,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} @@ -194,6 +215,14 @@ Requires: %{name}-std-static%{?_isa} = %{version}-%{release} # https://github.com/rust-lang/rust/issues/11937 Requires: /usr/bin/cc +%if 0%{?epel} == 7 +%global devtoolset_name devtoolset-9 +BuildRequires: %{devtoolset_name}-gcc +BuildRequires: %{devtoolset_name}-gcc-c++ +%global __cc /opt/rh/%{devtoolset_name}/root/usr/bin/gcc +%global __cxx /opt/rh/%{devtoolset_name}/root/usr/bin/g++ +%endif + # ALL Rust libraries are private, because they don't keep an ABI. %global _privatelibs lib(.*-[[:xdigit:]]{16}*|rustc.*)[.]so.* %global __provides_exclude ^(%{_privatelibs})$ @@ -203,14 +232,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. @@ -222,6 +251,19 @@ Requires: /usr/bin/cc %endif %endif +# We're going to override --libdir when configuring to get rustlib into a +# common path, but we'll fix the shared libraries during install. +%global common_libdir %{_prefix}/lib +%global rustlibdir %{common_libdir}/rustlib + +%if %defined cross_targets +# brp-strip-static-archive breaks the archive index for wasm +%global __os_install_post \ +%__os_install_post \ +find %{buildroot}%{rustlibdir} -type f -path '*/wasm*/lib/*.rlib' -exec llvm-ranlib '{}' ';' \ +%{nil} +%endif + %description Rust is a systems programming language that runs blazingly fast, prevents segfaults, and guarantees thread safety. @@ -236,6 +278,32 @@ Summary: Standard library for Rust This package includes the standard libraries for building applications written in Rust. +%if %defined cross_targets +%{lua: do + for triple in string.gmatch(rpm.expand("%{cross_targets}"), "%S+") do + local requires = rpm.expand("Requires: rust = %{version}-%{release}") + if string.sub(triple, 1, 4) == "wasm" then + requires = requires .. "\nRequires: lld >= 8.0" + end + local subs = { + triple = triple, + requires = requires, + } + local s = string.gsub([[ +%package std-static-{{triple}} +Summary: Standard library for Rust +BuildArch: noarch +{{requires}} + +%description std-static-{{triple}} +This package includes the standard libraries for building applications +written in Rust for the {{triple}} target. +]], "{{(%w+)}}", subs) + print(s) + end +end} +%endif + %package debugger-common Summary: Common debugger pretty printers for Rust @@ -262,11 +330,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 @@ -291,10 +355,7 @@ its standard library. %package -n cargo Summary: Rust's package manager and build tool %if %with bundled_libgit2 -Provides: bundled(libgit2) = 1.0.0 -%endif -%if %with bundled_libssh2 -Provides: bundled(libssh2) = 1.9.0~dev +Provides: bundled(libgit2) = 1.1.0 %endif # For tests: BuildRequires: git @@ -337,10 +398,7 @@ A tool for formatting Rust code according to style guidelines. %package -n rls Summary: Rust Language Server for IDE integration %if %with bundled_libgit2 -Provides: bundled(libgit2) = 1.0.0 -%endif -%if %with bundled_libssh2 -Provides: bundled(libssh2) = 1.9.0~dev +Provides: bundled(libgit2) = 1.1.0 %endif Requires: rust-analysis # /usr/bin/rls is dynamically linked against internal rustc libs @@ -402,24 +460,38 @@ test -f '%{local_rust_root}/bin/rustc' %setup -q -n %{rustc_package} -%patch1 -p1 -d src/tools/cargo +%patch1 -p1 +%patch2 -p1 %if %with disabled_libssh2 -%patch10 -p1 +%patch100 -p1 +%endif + +%if %without curl_http2 +%patch101 -p1 +rm -rf vendor/libnghttp2-sys/ +%endif + +%if 0%{?rhel} && 0%{?rhel} < 8 +%patch102 -p1 %endif -%if "%{python}" != "python2" -sed -i.try-py3 -e '/try python2.7/i try %{python} "$@"' ./configure +%if "%{python}" != "python3" +# Use our preferred python first +sed -i.try-python -e '/^try python3 /i try "%{python}" "$@"' ./configure %endif %if %without bundled_llvm rm -rf src/llvm-project/ +mkdir -p src/llvm-project/libunwind/ %endif # Remove other unused vendored libraries rm -rf vendor/curl-sys/curl/ rm -rf vendor/jemalloc-sys/jemalloc/ +rm -rf vendor/libssh2-sys/libssh2/ rm -rf vendor/libz-sys/src/zlib/ +rm -rf vendor/libz-sys/src/zlib-ng/ rm -rf vendor/lzma-sys/xz-*/ rm -rf vendor/openssl-src/openssl/ @@ -427,9 +499,6 @@ rm -rf vendor/openssl-src/openssl/ rm -rf vendor/libgit2-sys/libgit2/ %endif -%if %without bundled_libssh2 -rm -rf vendor/libssh2-sys/libssh2/ -%endif %if %with disabled_libssh2 rm -rf vendor/libssh2-sys/ %endif @@ -437,10 +506,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,36 +529,28 @@ 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 +%if %without disabled_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}"} -# We're going to override --libdir when configuring to get rustlib into a -# common path, but we'll fix the shared libraries during install. -%global common_libdir %{_prefix}/lib -%global rustlibdir %{common_libdir}/rustlib +%build +export %{rust_env} %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 @@ -503,13 +561,6 @@ export LIBSSH2_SYS_USE_PKG_CONFIG=1 %define enable_debuginfo --debuginfo-level=2 %endif -# We want the best optimization for std, but it caused problems for rpm-ostree -# on ppc64le to have all of the compiler_builtins in a single object: -# https://bugzilla.redhat.com/show_bug.cgi?id=1713090 -%ifnarch %{power64} -%define codegen_units_std --set rust.codegen-units-std=1 -%endif - # Some builders have relatively little memory for their CPU count. # At least 2GB per CPU is a good rule of thumb for building rustc. ncpus=$(/usr/bin/getconf _NPROCESSORS_ONLN) @@ -521,6 +572,9 @@ fi %configure --disable-option-checking \ --libdir=%{common_libdir} \ --build=%{rust_triple} --host=%{rust_triple} --target=%{rust_triple} \ + --set target.%{rust_triple}.linker=%{__cc} \ + --set target.%{rust_triple}.cc=%{__cc} \ + --set target.%{rust_triple}.cxx=%{__cxx} \ --python=%{python} \ --local-rust-root=%{local_rust_root} \ %{!?with_bundled_llvm: --llvm-root=%{llvm_root} \ @@ -528,23 +582,35 @@ fi %{!?with_llvm_static: --enable-llvm-link-shared } } \ --disable-rpath \ %{enable_debuginfo} \ + --set rust.codegen-units-std=1 \ --enable-extended \ --tools=analysis,cargo,clippy,rls,rustfmt,src \ --enable-vendor \ --enable-verbose-tests \ %{?codegen_units_std} \ - --release-channel=%{channel} + --release-channel=%{channel} \ + --release-description="%{?fedora:Fedora }%{?rhel:Red Hat }%{version}-%{release}" -%{python} ./x.py build -j "$ncpus" -%{python} ./x.py doc +%{python} ./x.py build -j "$ncpus" --stage 2 +%{python} ./x.py doc --stage 2 +%if %defined cross_targets +for triple in %{cross_targets}; do + %{python} ./x.py build --stage 2 --target=$triple std +done +%endif %install -%{?cmake_path:export PATH=%{cmake_path}:$PATH} -%{?rustflags:export RUSTFLAGS="%{rustflags}"} +export %{rust_env} DESTDIR=%{buildroot} %{python} ./x.py install +%if %defined cross_targets +for triple in %{cross_targets}; do + DESTDIR=%{buildroot} %{python} ./x.py install --target=$triple std +done +%endif + # Make sure the shared libraries are in the proper libdir %if "%{_libdir}" != "%{common_libdir}" mkdir -p %{buildroot}%{_libdir} @@ -605,20 +671,22 @@ 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 +# We don't want Rust copies of LLVM tools (rust-lld, rust-llvm-dwp) +rm -f %{buildroot}%{rustlibdir}/%{rust_triple}/bin/rust-ll* + %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 +694,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 @@ -646,22 +713,42 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %{rustlibdir}/%{rust_triple}/lib/*.rlib +%if %defined cross_targets +%{lua: do + for triple in string.gmatch(rpm.expand("%{cross_targets}"), "%S+") do + local subs = { + triple = triple, + rustlibdir = rpm.expand("%{rustlibdir}"), + } + local s = string.gsub([[ +%files std-static-{{triple}} +%dir {{rustlibdir}} +%dir {{rustlibdir}}/{{triple}} +%dir {{rustlibdir}}/{{triple}}/lib +{{rustlibdir}}/{{triple}}/lib/*.rlib +]], "{{(%w+)}}", subs) + print(s) + end +end} +%endif + + %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 @@ -672,11 +759,11 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %{_docdir}/%{name}/html/*/ %{_docdir}/%{name}/html/*.html %{_docdir}/%{name}/html/*.css -%{_docdir}/%{name}/html/*.ico %{_docdir}/%{name}/html/*.js %{_docdir}/%{name}/html/*.png %{_docdir}/%{name}/html/*.svg %{_docdir}/%{name}/html/*.woff +%{_docdir}/%{name}/html/*.woff2 %license %{_docdir}/%{name}/html/*.txt %license %{_docdir}/%{name}/html/*.md @@ -685,6 +772,7 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %license src/tools/cargo/LICENSE-APACHE src/tools/cargo/LICENSE-MIT src/tools/cargo/LICENSE-THIRD-PARTY %doc src/tools/cargo/README.md %{_bindir}/cargo +%{_libexecdir}/cargo* %{_mandir}/man1/cargo*.1* %{_sysconfdir}/bash_completion.d/cargo %{_datadir}/zsh/site-functions/_cargo @@ -728,6 +816,39 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py* %changelog +* Tue Jul 20 2021 Josh Stone - 1.53.0-2 +- Use llvm-ranlib to fix wasm archives. + +* Mon Jun 21 2021 Josh Stone - 1.53.0-1 +- Update to 1.53.0. + +* Tue Jun 15 2021 Josh Stone - 1.52.1-2 +- Set rust.codegen-units-std=1 for all targets again. +- Add rust-std-static-wasm32-unknown-unknown. + +* Tue May 25 2021 Josh Stone - 1.52.1-1 +- Update to 1.52.1. Includes security fixes for CVE-2020-36323, + CVE-2021-28876, CVE-2021-28878, CVE-2021-28879, and CVE-2021-31162. + +* Mon May 24 2021 Josh Stone - 1.51.0-1 +- Update to 1.51.0. Update to 1.51.0. Includes security fixes for + CVE-2021-28875 and CVE-2021-28877. + +* Mon May 24 2021 Josh Stone - 1.50.0-1 +- Update to 1.50.0. + +* Wed Jan 13 2021 Josh Stone - 1.49.0-1 +- Update to 1.49.0. + +* Tue Jan 12 2021 Josh Stone - 1.48.0-1 +- Update to 1.48.0. + +* 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.