~ruther/guix-local

cbe9eb7c1536d2144eaf8e7310e6de00d45ebc14 — Romain GARBAGE 1 year, 1 month ago 6cf105e
profiles: Allow modification of package properties in packages->manifest.

* guix/profiles.scm (packages->manifest): Allow modification of package properties.

Change-Id: Ie666290f49ed72b74833c503e6f41b0a0404bb43
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Modified-by: Ludovic Courtès <ludo@gnu.org>
1 files changed, 8 insertions(+), 4 deletions(-)

M guix/profiles.scm
M guix/profiles.scm => guix/profiles.scm +8 -4
@@ 422,10 422,12 @@ explicit and implicit inputs of PACKAGE."
                  #f))
               (package-development-inputs package system #:target target))))

(define (packages->manifest packages)
(define* (packages->manifest packages #:key
                             (properties default-package-properties))
  "Return a list of manifest entries, one for each item listed in PACKAGES.
Elements of PACKAGES can be either package objects or package/string tuples
denoting a specific output of a package."
denoting a specific output of a package.  PROPERTIES is a procedure taking one
argument and returning an alist."
  (define inferiors-loaded?
    ;; This hack allows us to provide seamless integration for inferior
    ;; packages while not having a hard dependency on (guix inferior).


@@ 439,9 441,11 @@ denoting a specific output of a package."
   (delete-duplicates
    (map (match-lambda
           (((? package? package) output)
            (package->manifest-entry package output))
            (package->manifest-entry package output
                                     #:properties (properties package)))
           ((? package? package)
            (package->manifest-entry package))
            (package->manifest-entry package
                                     #:properties (properties package)))
           ((thing output)
            (if inferiors-loaded?
                ((inferior->entry) thing output)