[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
02/276: gnu: Add rust-1.70.
From: |
guix-commits |
Subject: |
02/276: gnu: Add rust-1.70. |
Date: |
Wed, 18 Oct 2023 04:48:46 -0400 (EDT) |
efraim pushed a commit to branch rust-team
in repository guix.
commit 299a223835f875c9fcb526a76bbe0b7f32cbefaf
Author: Fries <fries1234@protonmail.com>
AuthorDate: Mon Sep 18 15:19:49 2023 +0300
gnu: Add rust-1.70.
* gnu/packages/rust.scm (rust-1.70): New variable.
* gnu/packages/patches/rust-1.70-fix-rustix-build.patch: New file.
* gnu/local.mk (dist_patch_DATA): Register file.
Signed-off-by: Efraim Flashner <efraim@flashner.co.il>
---
gnu/local.mk | 1 +
.../patches/rust-1.70-fix-rustix-build.patch | 21 +++++++++++++++++++++
gnu/packages/rust.scm | 17 +++++++++++++++++
3 files changed, 39 insertions(+)
diff --git a/gnu/local.mk b/gnu/local.mk
index daacd786a7..bf7cfbf8bd 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1947,6 +1947,7 @@ dist_patch_DATA =
\
%D%/packages/patches/ruby-nokogiri.patch \
%D%/packages/patches/rustc-1.54.0-src.patch \
%D%/packages/patches/rust-1.64-fix-riscv64-bootstrap.patch \
+ %D%/packages/patches/rust-1.70-fix-rustix-build.patch \
%D%/packages/patches/rust-ring-0.16-missing-files.patch \
%D%/packages/patches/rust-ring-0.16-test-files.patch \
%D%/packages/patches/i3status-rust-enable-unstable-features.patch \
diff --git a/gnu/packages/patches/rust-1.70-fix-rustix-build.patch
b/gnu/packages/patches/rust-1.70-fix-rustix-build.patch
new file mode 100644
index 0000000000..d72a8fb07a
--- /dev/null
+++ b/gnu/packages/patches/rust-1.70-fix-rustix-build.patch
@@ -0,0 +1,21 @@
+@@ -0,0 +1,20 @@
+--- a/vendor/fd-lock/Cargo.toml 2023-05-31 14:44:48.000000000 -0700
++++ b/vendor/fd-lock/Cargo.toml 2023-07-14 21:19:34.637702319 -0700
+@@ -45,7 +45,7 @@
+
+ [target."cfg(unix)".dependencies.rustix]
+ version = "0.37.0"
+-features = ["fs"]
++features = ["fs", "cc"]
+
+ [target."cfg(windows)".dependencies.windows-sys]
+ version = "0.45.0"
+--- a/src/bootstrap/Cargo.lock 2023-07-11 20:32:40.000000000 -0700
++++ b/src/bootstrap/Cargo.lock 2023-07-14 22:41:53.269284713 -0700
+@@ -618,6 +618,7 @@
+ dependencies = [
+ "bitflags",
++ "cc",
+ "errno",
+ "io-lifetimes",
+ "libc",
diff --git a/gnu/packages/rust.scm b/gnu/packages/rust.scm
index ca34231803..f0e921375b 100644
--- a/gnu/packages/rust.scm
+++ b/gnu/packages/rust.scm
@@ -726,6 +726,23 @@ safety and thread safety guarantees.")
(for-each delete-file
(find-files "vendor" "\\.(a|dll|exe|lib)$")))))))))
+(define rust-1.70
+ (let ((base-rust
+ (rust-bootstrapped-package
+ rust-1.69 "1.70.0"
+ "0z6j7d0ni0rmfznv0w3mrf882m11kyh51g2bxkj40l3s1c0axgxj")))
+ (package
+ (inherit base-rust)
+ (source
+ (origin
+ (inherit (package-source base-rust))
+ ;; Rust 1.70 adds the rustix library which depends on the vendored
+ ;; fd-lock crate. The fd-lock crate uses Outline assembly which
expects
+ ;; a precompiled static library. Enabling the "cc" feature tells the
+ ;; build.rs script to compile the assembly files instead of searching
+ ;; for a precompiled library.
+ (patches (search-patches "rust-1.70-fix-rustix-build.patch")))))))
+
;;; Note: Only the latest version of Rust is supported and tested. The
;;; intermediate rusts are built for bootstrapping purposes and should not
;;; be relied upon. This is to ease maintenance and reduce the time
- 03/276: gnu: rust: Add make-ignore-test-list function., (continued)
- 03/276: gnu: rust: Add make-ignore-test-list function., guix-commits, 2023/10/18
- 06/276: build: cargo-build-system: Check for pregenerated files., guix-commits, 2023/10/18
- 07/276: gnu: rust-fd-lock-3: Update to 3.0.12., guix-commits, 2023/10/18
- 13/276: gnu: Add rust-gio-0.17., guix-commits, 2023/10/18
- 09/276: gnu: Add rust-cairo-rs-0.17., guix-commits, 2023/10/18
- 15/276: gnu: Add rust-pango-sys-0.17., guix-commits, 2023/10/18
- 16/276: gnu: Add rust-pangocairo-sys-0.17., guix-commits, 2023/10/18
- 17/276: gnu: Add rust-pangocairo-0.17., guix-commits, 2023/10/18
- 26/276: gnu: Add rust-float-eq-derive-1., guix-commits, 2023/10/18
- 28/276: gnu: Add rust-freetype-sys-0.17., guix-commits, 2023/10/18
- 02/276: gnu: Add rust-1.70.,
guix-commits <=
- 22/276: gnu: Add rust-cust-core-0.1., guix-commits, 2023/10/18
- 23/276: gnu: Add rust-dashmap-5., guix-commits, 2023/10/18
- 24/276: gnu: Add rust-data-url-0.2., guix-commits, 2023/10/18
- 14/276: gnu: Add rust-pango-0.17., guix-commits, 2023/10/18
- 19/276: gnu: Add rust-cuda-std-macros-0.2., guix-commits, 2023/10/18
- 35/276: gnu: Add rust-glam-0.20., guix-commits, 2023/10/18
- 38/276: gnu: rust-half-1: Update to 1.8.2., guix-commits, 2023/10/18
- 27/276: gnu: Add rust-float-eq-1., guix-commits, 2023/10/18
- 42/276: gnu: Add rust-nalgebra-0.32., guix-commits, 2023/10/18
- 43/276: gnu: Add rust-nalgebra-macros-0.2., guix-commits, 2023/10/18