From 77b0ac905d461cee8585d00a0b82caacc99780ad Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Tue, 28 Oct 2014 10:17:13 +0100 Subject: build-system/gnu: Add #:substitutable? parameter. * guix/build-system/gnu.scm (gnu-build): Add #:substitutable? parameter. Pass #:local-build? to 'build-expression->derivation'. (gnu-cross-build): Likewise. --- guix/build-system/gnu.scm | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'guix/build-system') diff --git a/guix/build-system/gnu.scm b/guix/build-system/gnu.scm index d2c29d44b5..3cb9f6ae94 100644 --- a/guix/build-system/gnu.scm +++ b/guix/build-system/gnu.scm @@ -268,6 +268,7 @@ standard packages used as implicit inputs of the GNU build system." (system (%current-system)) (imported-modules %default-modules) (modules %default-modules) + (substitutable? #t) allowed-references) "Return a derivation called NAME that builds from tarball SOURCE, with input derivation INPUTS, using the usual procedure of the GNU Build @@ -281,6 +282,9 @@ between both, because for Guile's own modules like (ice-9 foo), we want to use GUILE's own version of it, rather than import the user's one, which could lead to gratuitous input divergence. +SUBSTITUTABLE? determines whether users may be able to use substitutes of the +returned derivations, or whether they should always build it locally. + ALLOWED-REFERENCES can be either #f, or a list of packages that the outputs are allowed to refer to." (define canonicalize-reference @@ -335,6 +339,11 @@ are allowed to refer to." #:inputs input-drvs #:outputs outputs #:modules imported-modules + + ;; XXX: Update when + ;; is fixed. + #:local-build? (not substitutable?) + #:allowed-references (and allowed-references (map canonicalize-reference @@ -390,6 +399,7 @@ is one of `host' or `target'." (guix build utils))) (modules '((guix build gnu-build-system) (guix build utils))) + (substitutable? #t) allowed-references) "Cross-build NAME for TARGET, where TARGET is a GNU triplet. INPUTS are cross-built inputs, and NATIVE-INPUTS are inputs that run on the build @@ -473,6 +483,11 @@ platform." #:inputs (append native-drvs target-drvs) #:outputs outputs #:modules imported-modules + + ;; XXX: Update when + ;; is fixed. + #:local-build? (not substitutable?) + #:allowed-references (and allowed-references (map canonicalize-reference -- cgit v1.2.3