[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
471/475: gnu: rust: Re-enable aarch64-linux support.
From: |
guix-commits |
Subject: |
471/475: gnu: rust: Re-enable aarch64-linux support. |
Date: |
Sun, 7 May 2023 12:48:51 -0400 (EDT) |
efraim pushed a commit to branch rust-team
in repository guix.
commit 956672129235b8d6f44a9bb4e284f58ddb44d4e9
Author: Efraim Flashner <efraim@flashner.co.il>
AuthorDate: Wed May 3 16:13:38 2023 +0300
gnu: rust: Re-enable aarch64-linux support.
* gnu/packages/rust.scm (rust)[arguments]: Only enable parallel-builds
on x86_64-linux. Add a make-flag to adjust CFLAGS. In the custom 'build
phase remove an unneeded environment variable.
[supported-architectures]: Add aarch64-linux.
---
gnu/packages/rust.scm | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/gnu/packages/rust.scm b/gnu/packages/rust.scm
index f564133ecd..8e106a9927 100644
--- a/gnu/packages/rust.scm
+++ b/gnu/packages/rust.scm
@@ -197,6 +197,9 @@
;; Rust's own .so library files are not found in any RUNPATH, but
;; that doesn't seem to cause issues.
#:validate-runpath? #f
+ ;; Most of the build is single-threaded. This also improves the
+ ;; build time on machines with "only" 8GB of RAM.
+ #:parallel-build? ,(target-x86-64?)
#:make-flags
(list ,(string-append "RUSTC_TARGET="
(or (%current-target-system)
@@ -204,6 +207,10 @@
,(string-append "RUSTC_VERSION=" version)
,(string-append "MRUSTC_TARGET_VER="
(version-major+minor version))
+ ;; mrustc expects a C11 compatible compiler. Use the default
+ ;; C language dialect from the GCC-10 compiler.
+ ;; This is necessary for some architectures.
+ "CFLAGS=-std=gnu11"
"OUTDIR_SUF=") ;do not add version suffix to output dir
#:phases
(modify-phases %standard-phases
@@ -302,7 +309,6 @@
;; Use PARLEVEL since both minicargo and mrustc use it
;; to set the level of parallelism.
(setenv "PARLEVEL" (number->string job-count))
- (setenv "CARGO_BUILD_JOBS" (number->string job-count))
(display "Building mrustc...\n")
(apply invoke "make" make-flags)
@@ -354,9 +360,9 @@ safety and thread safety guarantees.")
;; therefore the build process needs 8GB of RAM while building.
;; It may support i686 soon:
;; <https://github.com/thepowersgang/mrustc/issues/78>.
- ;; XXX: The rust bootstrap is currently broken on aarch64 and riscv64,
- ;; remove them until this is fixed.
- (supported-systems '("x86_64-linux"))
+ ;; XXX: The rust bootstrap is currently broken on riscv64,
+ ;; remove it until this is fixed.
+ (supported-systems '("x86_64-linux" "aarch64-linux"))
;; Dual licensed.
(license (list license:asl2.0 license:expat))))
- 440/475: gnu: Add rust-ttf-parser-0.19., (continued)
- 440/475: gnu: Add rust-ttf-parser-0.19., guix-commits, 2023/05/07
- 450/475: gnu: rust-bindgen-0.59: Add missing inputs., guix-commits, 2023/05/07
- 457/475: gnu: rust-webpki-roots-0.22: Add missing input., guix-commits, 2023/05/07
- 446/475: gnu: Add rust-tiny-skia-path-0.8., guix-commits, 2023/05/07
- 464/475: gnu: rust-sct-0.5: Fix build., guix-commits, 2023/05/07
- 462/475: gnu: rust-tokio-rustls-0.23: Add missing input., guix-commits, 2023/05/07
- 458/475: gnu: rust-criterion-0.3: Update to 0.3.6., guix-commits, 2023/05/07
- 455/475: gnu: rust-selectors-0.21: Fix cargo inputs., guix-commits, 2023/05/07
- 472/475: gnu: librsvg-for-system: Choose librsvg based on package support., guix-commits, 2023/05/07
- 453/475: gnu: rust-rustls-0.17: Skip the tests., guix-commits, 2023/05/07
- 471/475: gnu: rust: Re-enable aarch64-linux support.,
guix-commits <=
- 468/475: gnu: rust-hashbrown-0.8: Update to 0.8.2., guix-commits, 2023/05/07
- 340/475: gnu: Add rust-syn-2., guix-commits, 2023/05/07
- 378/475: gnu: Add rust-objc-sys-0.3., guix-commits, 2023/05/07
- 405/475: gnu: rust-alacritty-config-derive-0.1: Update to 0.2.1., guix-commits, 2023/05/07
- 403/475: gnu: Add rust-x11rb-0.10., guix-commits, 2023/05/07
- 366/475: gnu: Add rust-nom-derive-impl-0.10., guix-commits, 2023/05/07
- 344/475: gnu: rust-syn-1: Update to 1.0.109., guix-commits, 2023/05/07
- 402/475: gnu: Add rust-x11-clipboard-0.7., guix-commits, 2023/05/07
- 387/475: gnu: rust-wayland-egl-0.29: Update to 0.29.5., guix-commits, 2023/05/07
- 351/475: gnu: Add rust-windows-0.46., guix-commits, 2023/05/07