Prefer local builds for "small" derivations.

* gnu/system.scm (union, file-union, links): Pass #:local-build? #t to
  'derivation-expression'.
* guix/derivations.scm (imported-files, compiled-modules): Likewise.
* guix/profiles.scm (profile-derivation): Likewise.
This commit is contained in:
Ludovic Courtès 2014-01-25 17:22:53 +01:00
parent 200a97e64f
commit 6ce206cb92
3 changed files with 13 additions and 7 deletions

View File

@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2013 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2013, 2014 Ludovic Courtès <ludo@gnu.org>
;;;
;;; This file is part of GNU Guix.
;;;
@ -152,7 +152,8 @@ input tuples."
#:system system
#:inputs inputs
#:modules '((guix build union))
#:guile-for-build guile)))
#:guile-for-build guile
#:local-build? #t)))
(define* (file-union files
#:key (inputs '()) (name "file-union"))
@ -190,7 +191,8 @@ as an inputs; additional inputs, such as derivations, are taken from INPUTS."
`(symlink ,target ,name)))
files))
#:inputs inputs))))
#:inputs inputs
#:local-build? #t))))
(define (links inputs)
"Return a directory with symbolic links to all of INPUTS. This is
@ -212,7 +214,8 @@ directories or regular files."
(mlet %store-monad ((inputs (lower-inputs inputs)))
(derivation-expression "links" builder
#:inputs inputs)))
#:inputs inputs
#:local-build? #t)))
(define* (etc-directory #:key
(locale "C") (timezone "Europe/Paris")

View File

@ -836,7 +836,8 @@ system, imported, and appears under FINAL-PATH in the resulting store path."
(build-expression->derivation store name builder
#:system system
#:inputs files
#:guile-for-build guile)))
#:guile-for-build guile
#:local-build? #t)))
(define* (imported-modules store modules
#:key (name "module-import")
@ -902,7 +903,8 @@ they can refer to each other."
(build-expression->derivation store name builder
#:inputs `(("modules" ,module-drv))
#:system system
#:guile-for-build guile)))
#:guile-for-build guile
#:local-build? #t)))
(define* (build-expression->derivation store name exp
#:key

View File

@ -257,7 +257,8 @@ the given MANIFEST."
;; already valid.
`((,name ,path) ,@deps)))
(manifest-entries manifest))
#:modules '((guix build union))))
#:modules '((guix build union))
#:local-build? #t))
(define (profile-regexp profile)
"Return a regular expression that matches PROFILE's name and number."