From ed9d7cb4d95f8f4776e6fee2778ab52bc2852969 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Thu, 11 Oct 2018 18:27:21 +0200 Subject: gnu: guix-daemon: Run 'guix' from /var/guix/profiles/per-user/root. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixes . Reported by Pjotr Prins and Konrad Hinsen . * gnu/packages/package-management.scm (guix-daemon)[arguments]: Execute /var/guix/profiles/per-user/root/current-guix/bin/guix instead of ~root/…. --- gnu/packages/package-management.scm | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'gnu') diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index 500abd5125..9a0023233f 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -347,12 +347,14 @@ (define-public guix-daemon "install-nodist_pkglibexecSCRIPTS") ;; We need to tell 'guix-daemon' which 'guix' command to use. - ;; Here we use a questionable hack where we hard-code - ;; "~root/.config", which could be wrong (XXX). + ;; Here we use a questionable hack where we hard-code root's + ;; current guix, which could be wrong (XXX). Note that scripts + ;; like 'guix perform-download' do not run as root so we assume + ;; that they have access to /var/guix/profiles/per-user/root. (let ((out (assoc-ref outputs "out"))) (substitute* (find-files (string-append out "/libexec")) (("exec \".*/bin/guix\"") - "exec ~root/.config/guix/current/bin/guix")) + "exec /var/guix/profiles/per-user/root/current-guix/bin/guix")) #t))) (delete 'wrap-program))))))) -- cgit v1.2.3