all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Ludovic Courtès" <ludo@gnu.org>
To: 45102@debbugs.gnu.org
Cc: "Ludovic Courtès" <ludo@gnu.org>
Subject: [bug#45102] [PATCH 2/4] self: Move Guile early in the module search path.
Date: Mon,  7 Dec 2020 16:29:57 +0100	[thread overview]
Message-ID: <20201207152959.28864-2-ludo@gnu.org> (raw)
In-Reply-To: <20201207152959.28864-1-ludo@gnu.org>

Until now, Guile modules would first be searched for in
MODULE-DIRECTORY, then in each $GUILE_LOAD_PATH entry, and finally in
Guile itself.

* guix/self.scm (guix-command): Make GUILE the second entry in the
%LOAD-PATH and %LOAD-COMPILED-PATH.
---
 guix/self.scm | 23 ++++++++++++++---------
 1 file changed, 14 insertions(+), 9 deletions(-)

diff --git a/guix/self.scm b/guix/self.scm
index c0de14b79a..ca67f653fa 100644
--- a/guix/self.scm
+++ b/guix/self.scm
@@ -650,17 +650,22 @@ load path."
   (program-file "guix-command"
                 #~(begin
                     (set! %load-path
-                      (cons (string-append #$module-directory
-                                           "/share/guile/site/"
-                                           (effective-version))
-                            %load-path))
+                      (append (list (string-append #$module-directory
+                                                   "/share/guile/site/"
+                                                   (effective-version))
+                                    (string-append #$guile "/share/guile/"
+                                                   (effective-version)))
+                              %load-path))
 
                     (set! %load-compiled-path
-                      (cons (string-append #$module-directory
-                                           "/lib/guile/"
-                                           (effective-version)
-                                           "/site-ccache")
-                            %load-compiled-path))
+                      (append (list (string-append #$module-directory
+                                                   "/lib/guile/"
+                                                   (effective-version)
+                                                   "/site-ccache")
+                                    (string-append #$guile "/lib/guile/"
+                                                   (effective-version)
+                                                   "/ccache"))
+                              %load-compiled-path))
 
                     ;; To maximize the chances that locales are set up right
                     ;; out-of-the-box, bundle "common" UTF-8 locales.
-- 
2.29.2





  reply	other threads:[~2020-12-07 15:31 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-07 15:21 [bug#45102] [PATCH 0/4] Making fewer 'stat' calls during startup Ludovic Courtès
2020-12-07 15:29 ` [bug#45102] [PATCH 1/4] build: 'script/guix' uses our own 'guile' executable Ludovic Courtès
2020-12-07 15:29   ` Ludovic Courtès [this message]
2020-12-07 15:29   ` [bug#45102] [PATCH 3/4] guix: 'guile' executable ignores GUILE_LOAD_PATH during startup Ludovic Courtès
2020-12-07 15:29   ` [bug#45102] [PATCH 4/4] self: Remove the empty string from '%load-extensions' Ludovic Courtès
2020-12-08 13:50 ` [bug#45102] [PATCH 0/4] Making fewer 'stat' calls during startup Mathieu Othacehe
2020-12-08 20:24   ` Ludovic Courtès
2020-12-11 18:12     ` bug#45102: " Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20201207152959.28864-2-ludo@gnu.org \
    --to=ludo@gnu.org \
    --cc=45102@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.