From 29fce8b6ebaaeff593d65e157ff6fd90de3c416b Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Mon, 11 Aug 2014 22:18:33 +0200 Subject: system: Use (guix profiles) to build the system profile. * gnu/system.scm (union): Remove. (operating-system-profile): Use 'profile-derivation' and related procedures instead of 'union'. --- gnu/system.scm | 31 ++++--------------------------- 1 file changed, 4 insertions(+), 27 deletions(-) (limited to 'gnu/system.scm') diff --git a/gnu/system.scm b/gnu/system.scm index 68f9438693..2894df8235 100644 --- a/gnu/system.scm +++ b/gnu/system.scm @@ -23,6 +23,7 @@ (define-module (gnu system) #:use-module (guix records) #:use-module (guix packages) #:use-module (guix derivations) + #:use-module (guix profiles) #:use-module (gnu packages base) #:use-module (gnu packages bash) #:use-module (gnu packages which) @@ -125,29 +126,6 @@ (define-record-type* operating-system ;;; Derivation. ;;; -(define* (union inputs - #:key (guile (%guile-for-build)) - (name "union")) - "Return a derivation that builds the union of INPUTS. INPUTS is a list of -input tuples." - (define builder - #~(begin - (use-modules (guix build union)) - - (define inputs '#$inputs) - - (setvbuf (current-output-port) _IOLBF) - (setvbuf (current-error-port) _IOLBF) - - (format #t "building union `~a' with ~a packages...~%" - #$output (length inputs)) - (union-build #$output inputs))) - - (gexp->derivation name builder - #:modules '((guix build union)) - #:guile-for-build guile - #:local-build? #t)) - (define* (file-union name files) "Return a derivation that builds a directory containing all of FILES. Each item in FILES must be a list where the first element is the file name to use @@ -294,10 +272,9 @@ (define* (etc-directory #:key ("sudoers" ,#~#$sudoers))))) (define (operating-system-profile os) - "Return a derivation that builds the default profile of OS." - ;; TODO: Replace with a real profile with a manifest. - (union (operating-system-packages os) - #:name "default-profile")) + "Return a derivation that builds the system profile of OS." + (profile-derivation (manifest (map package->manifest-entry + (operating-system-packages os))))) (define %root-account ;; Default root account. -- cgit v1.2.3