From 9b5d404cbb0876f71848848379608711101f79c4 Mon Sep 17 00:00:00 2001 From: Johannes Date: Tue, 9 Jun 2020 18:56:29 +0200 Subject: [PATCH] rust: upddate to 1.44.1. --- ...ative-libraries-when-linking-static-.patch | 2 +- ...tes-are-unstable-Fix-test-when-rpath.patch | 5 ++-- ...e-debugger-scripts-to-usr-share-rust.patch | 5 ++-- ...879b1e24c369362bcd821959ffabc50a8a31.patch | 28 ------------------- ...a896cc92d5e0678376cf5aa8b64af0899732.patch | 28 ------------------- srcpkgs/rust/patches/need-ssp_nonshared.patch | 12 ++++++++ srcpkgs/rust/template | 8 ++---- 7 files changed, 19 insertions(+), 69 deletions(-) delete mode 100644 srcpkgs/rust/patches/497f879b1e24c369362bcd821959ffabc50a8a31.patch delete mode 100644 srcpkgs/rust/patches/a94fa896cc92d5e0678376cf5aa8b64af0899732.patch diff --git a/srcpkgs/rust/patches/0003-Require-static-native-libraries-when-linking-static-.patch b/srcpkgs/rust/patches/0003-Require-static-native-libraries-when-linking-static-.patch index fe69b763f3..54cc27cded 100644 --- a/srcpkgs/rust/patches/0003-Require-static-native-libraries-when-linking-static-.patch +++ b/srcpkgs/rust/patches/0003-Require-static-native-libraries-when-linking-static-.patch @@ -40,7 +40,7 @@ index 0dd2f029..f22b4277 100644 + // dylibs at all. Force native libraries to be static, even if for example + // an upstream rlib was originally linked against a native shared library. + if crate_type == config::CrateType::Executable -+ && sess.crt_static() ++ && sess.crt_static(Some(crate_type)) + && !sess.target.target.options.crt_static_allows_dylibs + { + cmd.link_staticlib(name) diff --git a/srcpkgs/rust/patches/0007-test-sysroot-crates-are-unstable-Fix-test-when-rpath.patch b/srcpkgs/rust/patches/0007-test-sysroot-crates-are-unstable-Fix-test-when-rpath.patch index 8a9986f641..612f527a53 100644 --- a/srcpkgs/rust/patches/0007-test-sysroot-crates-are-unstable-Fix-test-when-rpath.patch +++ b/srcpkgs/rust/patches/0007-test-sysroot-crates-are-unstable-Fix-test-when-rpath.patch @@ -18,8 +18,7 @@ index a35174b3..9e770706 100644 +-include ../tools.mk + all: -- python2.7 test.py -+ env '$(HOST_RPATH_ENV)' python2.7 test.py +- '$(PYTHON)' test.py ++ env '$(HOST_RPATH_ENV)' '$(PYTHON)' test.py -- 2.26.2 - diff --git a/srcpkgs/rust/patches/0010-Move-debugger-scripts-to-usr-share-rust.patch b/srcpkgs/rust/patches/0010-Move-debugger-scripts-to-usr-share-rust.patch index a48c6ff1c4..92705d977c 100644 --- a/srcpkgs/rust/patches/0010-Move-debugger-scripts-to-usr-share-rust.patch +++ b/srcpkgs/rust/patches/0010-Move-debugger-scripts-to-usr-share-rust.patch @@ -26,10 +26,10 @@ diff --git a/src/etc/rust-gdb b/src/etc/rust-gdb index 23ba93da..dc51b16c 100755 --- a/src/etc/rust-gdb +++ b/src/etc/rust-gdb -@@ -4,7 +4,7 @@ set -e +@@ -12,7 +12,7 @@ # Find out where the pretty printer Python module is - RUSTC_SYSROOT=`rustc --print=sysroot` + RUSTC_SYSROOT="$("$RUSTC" --print=sysroot)" -GDB_PYTHON_MODULE_DIRECTORY="$RUSTC_SYSROOT/lib/rustlib/etc" +GDB_PYTHON_MODULE_DIRECTORY="$RUSTC_SYSROOT/share/rust" @@ -50,4 +50,3 @@ index 7b9b40e6..e471db36 100755 -- 2.26.2 - diff --git a/srcpkgs/rust/patches/497f879b1e24c369362bcd821959ffabc50a8a31.patch b/srcpkgs/rust/patches/497f879b1e24c369362bcd821959ffabc50a8a31.patch deleted file mode 100644 index 7432cd705d..0000000000 --- a/srcpkgs/rust/patches/497f879b1e24c369362bcd821959ffabc50a8a31.patch +++ /dev/null @@ -1,28 +0,0 @@ -Upstream: Yes -From 497f879b1e24c369362bcd821959ffabc50a8a31 Mon Sep 17 00:00:00 2001 -From: Nikita Popov -Date: Mon, 2 Mar 2020 22:37:55 +0100 -Subject: [PATCH] Update CreateMemSet() usage for LLVM 10 - ---- - src/rustllvm/RustWrapper.cpp | 5 +++++ - 1 file changed, 5 insertions(+) - -diff --git a/src/rustllvm/RustWrapper.cpp b/src/rustllvm/RustWrapper.cpp -index 25cfee3373dc4..799adb418822d 100644 ---- a/src/rustllvm/RustWrapper.cpp -+++ b/src/rustllvm/RustWrapper.cpp -@@ -1333,8 +1333,13 @@ extern "C" LLVMValueRef LLVMRustBuildMemSet(LLVMBuilderRef B, - LLVMValueRef Dst, unsigned DstAlign, - LLVMValueRef Val, - LLVMValueRef Size, bool IsVolatile) { -+#if LLVM_VERSION_GE(10, 0) -+ return wrap(unwrap(B)->CreateMemSet( -+ unwrap(Dst), unwrap(Val), unwrap(Size), MaybeAlign(DstAlign), IsVolatile)); -+#else - return wrap(unwrap(B)->CreateMemSet( - unwrap(Dst), unwrap(Val), unwrap(Size), DstAlign, IsVolatile)); -+#endif - } - - extern "C" LLVMValueRef diff --git a/srcpkgs/rust/patches/a94fa896cc92d5e0678376cf5aa8b64af0899732.patch b/srcpkgs/rust/patches/a94fa896cc92d5e0678376cf5aa8b64af0899732.patch deleted file mode 100644 index 16f05f5fb8..0000000000 --- a/srcpkgs/rust/patches/a94fa896cc92d5e0678376cf5aa8b64af0899732.patch +++ /dev/null @@ -1,28 +0,0 @@ -Reason: Fixes LLVM10 -Upstream: Yes -From a94fa896cc92d5e0678376cf5aa8b64af0899732 Mon Sep 17 00:00:00 2001 -From: Nikita Popov -Date: Tue, 4 Feb 2020 20:35:50 +0100 -Subject: [PATCH] Fix timeTraceProfilerInitialize for LLVM 10 - ---- - src/rustllvm/PassWrapper.cpp | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) - -diff --git a/src/rustllvm/PassWrapper.cpp b/src/rustllvm/PassWrapper.cpp -index 90d24d20737db..9e8614e3b6d34 100644 ---- a/src/rustllvm/PassWrapper.cpp -+++ b/src/rustllvm/PassWrapper.cpp -@@ -67,7 +67,11 @@ extern "C" void LLVMInitializePasses() { - } - - extern "C" void LLVMTimeTraceProfilerInitialize() { --#if LLVM_VERSION_GE(9, 0) -+#if LLVM_VERSION_GE(10, 0) -+ timeTraceProfilerInitialize( -+ /* TimeTraceGranularity */ 0, -+ /* ProcName */ "rustc"); -+#elif LLVM_VERSION_GE(9, 0) - timeTraceProfilerInitialize(); - #endif - } diff --git a/srcpkgs/rust/patches/need-ssp_nonshared.patch b/srcpkgs/rust/patches/need-ssp_nonshared.patch index 2a852400ab..0795dfaf3b 100644 --- a/srcpkgs/rust/patches/need-ssp_nonshared.patch +++ b/srcpkgs/rust/patches/need-ssp_nonshared.patch @@ -9,3 +9,15 @@ } } else if target.contains("freebsd") { println!("cargo:rustc-link-lib=execinfo"); +--- rustc-1.44.0-src/src/libunwind/build.rs ++++ rustc-1.44.0-src/src/libunwind/build.rs +@@ -12,6 +12,9 @@ fn main() { + } else if target.contains("linux") { + if !target.contains("android") { + println!("cargo:rustc-link-lib=gcc_s"); ++ if target.contains("musl") { ++ println!("cargo:rustc-link-lib=ssp_nonshared"); ++ } + } + } else if target.contains("freebsd") { + println!("cargo:rustc-link-lib=gcc_s"); diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template index c9d72f57d9..cba2feba4d 100644 --- a/srcpkgs/rust/template +++ b/srcpkgs/rust/template @@ -4,7 +4,7 @@ # Permission to use rust and cargo trademark is granted. # See: https://github.com/rust-lang/core-team/issues/4 pkgname=rust -version=1.43.1 +version=1.44.1 revision=1 _rust_dist_version=1.43.1 _cargo_dist_version=0.44.0 @@ -19,7 +19,7 @@ maintainer="Enno Boland " license="MIT, Apache-2.0" homepage="https://www.rust-lang.org/" distfiles="https://static.rust-lang.org/dist/rustc-${version}-src.tar.gz" -checksum=cde177b4a8c687da96f20de27630a1eb55c9d146a15e4c900d5c31cd3c3ac41d +checksum="7e2e64cb298dd5d5aea52eafe943ba0458fa82f2987fdcda1ff6f537b6f88473" lib32disabled=yes patch_args="-Np1" @@ -264,10 +264,6 @@ do_check() { src/test/run-fail/pretty \ src/test/run-make \ src/test/run-make-fulldeps \ - src/test/run-pass \ - src/test/run-pass/pretty \ - src/test/run-pass-fulldeps \ - src/test/run-pass-fulldeps/pretty \ src/test/ui \ src/test/ui-fulldeps }