diff mbox series

[bug#57317,1/2] build: profiles: Always set GUIX_EXTENSIONS_PATH.

Message ID 20220821131628.12592-1-paren@disroot.org
State Accepted
Headers show
Series Implicitly set GUIX_EXTENSIONS_PATH in profiles. | expand

Checks

Context Check Description
cbaines/comparison success View comparision
cbaines/git-branch success View Git branch
cbaines/applying patch success View Laminar job
cbaines/issue success View issue

Commit Message

\( Aug. 21, 2022, 1:16 p.m. UTC
* guix/build/profiles.scm (build-etc/profile): Implicitly set
  GUIX_EXTENSIONS_PATH to ${GUIX_PROFILE}/share/guix/extensions.

This allows Guix to find extensions without any need for users to
set GUIX_EXTENSIONS_PATH manually.
---
 guix/build/profiles.scm | 4 ++++
 1 file changed, 4 insertions(+)
diff mbox series

Patch

diff --git a/guix/build/profiles.scm b/guix/build/profiles.scm
index 0c92f222b4..f8b2e72d9c 100644
--- a/guix/build/profiles.scm
+++ b/guix/build/profiles.scm
@@ -97,6 +97,10 @@  (define file
 # When GUIX_PROFILE is undefined, the various environment variables refer
 # to this specific profile generation.
 \n" port)
+      (format port "~a~%" (environment-variable-definition
+                           "GUIX_EXTENSIONS_PATH"
+                           (string-append output "/share/guix/extensions")
+                           #:kind 'prefix))
       (let ((variables (evaluate-search-paths search-paths
                                               (list output))))
         (for-each (write-environment-variable-definition port)