summaryrefslogtreecommitdiff
path: root/guix/build-system
diff options
context:
space:
mode:
authorEfraim Flashner <efraim@flashner.co.il>2021-02-09 12:04:48 +0200
committerEfraim Flashner <efraim@flashner.co.il>2021-03-14 19:52:44 +0200
commit4d00185d66c9bd047dfe3077ed89a6a6129429ee (patch)
treeb712627e9be1d6da67d99c98dca050b72aa4a536 /guix/build-system
parent61a1165340a8bcc45550259edca25275d899fe09 (diff)
build-system/cargo: Propagate crates across builds.
* guix/build-system/cargo.scm (cargo-build): Add cargo-package-flags, install-source flags. * guix/build/cargo-build-system.scm (unpack-rust-crates, package): New procedures. (install): Also install crate sources. (%standard-phases): Add new phases. * doc/guix.texi (Packaging-guidelines)[Rust Crates]: Adjust to changes in the cargo-build-system.
Diffstat (limited to 'guix/build-system')
-rw-r--r--guix/build-system/cargo.scm5
1 files changed, 5 insertions, 0 deletions
diff --git a/guix/build-system/cargo.scm b/guix/build-system/cargo.scm
index 6c8edf6bac..e53d2a7523 100644
--- a/guix/build-system/cargo.scm
+++ b/guix/build-system/cargo.scm
@@ -5,6 +5,7 @@
;;; Copyright © 2016 David Craven <david@craven.ch>
;;; Copyright © 2019 Ivan Petkov <ivanppetkov@gmail.com>
;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
+;;; Copyright © 2021 Efraim Flashner <efraim@flashner.co.il>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -77,8 +78,10 @@ to NAME and VERSION."
(vendor-dir "guix-vendor")
(cargo-build-flags ''("--release"))
(cargo-test-flags ''("--release"))
+ (cargo-package-flags ''("--no-metadata" "--no-verify"))
(features ''())
(skip-build? #f)
+ (install-source? #t)
(phases '(@ (guix build cargo-build-system)
%standard-phases))
(outputs '("out"))
@@ -106,8 +109,10 @@ to NAME and VERSION."
#:vendor-dir ,vendor-dir
#:cargo-build-flags ,cargo-build-flags
#:cargo-test-flags ,cargo-test-flags
+ #:cargo-package-flags ,cargo-package-flags
#:features ,features
#:skip-build? ,skip-build?
+ #:install-source? ,install-source?
#:tests? ,(and tests? (not skip-build?))
#:phases ,phases
#:outputs %outputs