guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

02/03: profiles: Add #:system argument to profile-derivation.


From: Ludovic Courtès
Subject: 02/03: profiles: Add #:system argument to profile-derivation.
Date: Fri, 12 Feb 2016 21:05:11 +0000

civodul pushed a commit to branch master
in repository guix.

commit e5f04c2dde258c14e714e748d17b1137fe0bf4f3
Author: Ludovic Courtès <address@hidden>
Date:   Fri Feb 12 19:12:18 2016 +0100

    profiles: Add #:system argument to profile-derivation.
    
    Suggested by David Thompson <address@hidden>.
    
    * guix/profiles.scm (profile-derivation): Add #:system parameter and
    honor it.
---
 guix/profiles.scm |   10 +++++++---
 1 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/guix/profiles.scm b/guix/profiles.scm
index ce86ff8..1c53c80 100644
--- a/guix/profiles.scm
+++ b/guix/profiles.scm
@@ -1,5 +1,5 @@
 ;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2013, 2014, 2015 Ludovic Courtès <address@hidden>
+;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <address@hidden>
 ;;; Copyright © 2013 Nikita Karetnikov <address@hidden>
 ;;; Copyright © 2014 Alex Kost <address@hidden>
 ;;; Copyright © 2015 Mark H Weaver <address@hidden>
@@ -694,11 +694,15 @@ creates the GTK+ 'icon-theme.cache' file for each theme."
 
 (define* (profile-derivation manifest
                              #:key
-                             (hooks %default-profile-hooks))
+                             (hooks %default-profile-hooks)
+                             system)
   "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."
-  (mlet %store-monad ((extras (if (null? (manifest-entries manifest))
+  (mlet %store-monad ((system (if system
+                                  (return system)
+                                  (current-system)))
+                      (extras (if (null? (manifest-entries manifest))
                                   (return '())
                                   (sequence %store-monad
                                             (map (lambda (hook)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]