From 4eb82de9971c13323e7b0195f9f178282039ba35 Mon Sep 17 00:00:00 2001 From: Nikolai Merinov Date: Tue, 16 Oct 2018 02:37:41 +0500 Subject: [PATCH 2/2] gnu: rust: add rust 1.28 and rust 1.29 packages To: guix-patches@gnu.org * gnu/packages/rust.scm (rust-1.27): rename "rust" to "rust-1.27" (rust-1.28): Use llvm-6.0 finally. Disable test that broken on x86_64 machines without "avx". Enable codegen tests. Enable cargo test for thinlto. (rust): Package for rust 1.29.2. --- gnu/packages/rust.scm | 46 ++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 45 insertions(+), 1 deletion(-) diff --git a/gnu/packages/rust.scm b/gnu/packages/rust.scm index cd2a8fb9a..aafa3704b 100644 --- a/gnu/packages/rust.scm +++ b/gnu/packages/rust.scm @@ -776,7 +776,7 @@ jemalloc = \"" jemalloc "/lib/libjemalloc_pic.a" "\" (("fn no_index_update") "#[ignore]\nfn no_index_update")) #t))))))))) -(define-public rust +(define-public rust-1.27 (let ((base-rust (rust-bootstrapped-package rust-1.26 "1.27.2" "0pg1s37bhx9zqbynxyydq5j6q7kij9vxkcv8maz0m25prm88r0cs" @@ -804,3 +804,47 @@ jemalloc = \"" jemalloc "/lib/libjemalloc_pic.a" "\" (substitute* "src/tools/cargo/tests/testsuite/path.rs" (("fn thin_lto_works") "#[ignore]\nfn thin_lto_works")) #t))))))))) + +(define-public rust-1.28 + (let ((base-rust + (rust-bootstrapped-package rust-1.27 "1.28.0" + "11k4rn77bca2rikykkk9fmprrgjswd4x4kaq7fia08vgkir82nhx" + #:patches + '("rust-coresimd-doctest.patch" + "rust-bootstrap-stage0-test.patch" + "rust-1.25-accept-more-detailed-gdb-lines.patch" + "rust-mdbook-support-reproducible-builds-by-forcing-window.search.patch")))) + (package + (inherit base-rust) + (inputs + ;; Use LLVM 6.0 + (alist-replace "llvm" (list llvm) + (package-inputs base-rust))) + (arguments + (substitute-keyword-arguments (package-arguments base-rust) + ((#:phases phases) + `(modify-phases ,phases + (add-after 'configure 'enable-codegen-tests + ;; codegen tests should pass with llvm 6 + (lambda* _ + (substitute* "config.toml" + (("codegen-tests = false") "")) + #t)) + (add-after 'patch-tests 'disable-amd64-avx-test + ;; This test will fail on x86_64 machines without avx + (lambda* _ + (substitute* "src/test/run-pass/issue-44056.rs" + (("only-x86_64") "ignore-test")) + #t)) + ;; thinlto test should pass with llvm 6 + (delete 'disable-thinlto-test)))))))) + +(define-public rust + (let ((base-rust + (rust-bootstrapped-package rust-1.28 "1.29.2" + "1jb787080z754caa2w3w1amsygs4qlzj9rs1vy64firfmabfg22h" + #:patches + '("rust-1.25-accept-more-detailed-gdb-lines.patch" + "rust-mdbook-support-reproducible-builds-by-forcing-window.search.patch")))) + (package + (inherit base-rust)))) -- 2.19.0