summaryrefslogtreecommitdiff
path: root/guix/profiles.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2017-03-17 21:48:40 +0100
committerLudovic Courtès <ludo@gnu.org>2017-03-17 23:25:53 +0100
commit176febe3776b272dffbe757414225702d08c3bdf (patch)
treeb91d9240ae2cd46399aac5f2095dac7ebef111f4 /guix/profiles.scm
parent48b444304e206c35cf2c8e0d87a4711f1aac4fd4 (diff)
downloadgnu-guix-176febe3776b272dffbe757414225702d08c3bdf.tar
gnu-guix-176febe3776b272dffbe757414225702d08c3bdf.tar.gz
profiles: Packages in a profile can be cross-compiled.
* guix/profiles.scm (profile-derivation): Add #:target parameter; pass it to 'gexp->derivation'. * tests/profiles.scm ("profile-derivation, cross-compilation"): New test.
Diffstat (limited to 'guix/profiles.scm')
-rw-r--r--guix/profiles.scm10
1 files changed, 7 insertions, 3 deletions
diff --git a/guix/profiles.scm b/guix/profiles.scm
index de82eae348..a62a076f64 100644
--- a/guix/profiles.scm
+++ b/guix/profiles.scm
@@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright © 2013, 2014, 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
;;; Copyright © 2014, 2016 Alex Kost <alezost@gmail.com>
;;; Copyright © 2015 Mark H Weaver <mhw@netris.org>
@@ -933,13 +933,16 @@ files for the truetype fonts of the @var{manifest} entries."
#:key
(hooks %default-profile-hooks)
(locales? #t)
- system)
+ system target)
"Return a derivation that builds a profile (aka. 'user environment') with
the given MANIFEST. The profile includes additional derivations returned by
the monadic procedures listed in HOOKS--such as an Info 'dir' file, etc.
When LOCALES? is true, the build is performed under a UTF-8 locale; this adds
-a dependency on the 'glibc-utf8-locales' package."
+a dependency on the 'glibc-utf8-locales' package.
+
+When TARGET is true, it must be a GNU triplet, and the packages in MANIFEST
+are cross-built for TARGET."
(mlet %store-monad ((system (if system
(return system)
(current-system)))
@@ -1000,6 +1003,7 @@ a dependency on the 'glibc-utf8-locales' package."
(gexp->derivation "profile" builder
#:system system
+ #:target target
;; Not worth offloading.
#:local-build? #t