diff options
| author | Christopher Baines <mail@cbaines.net> | 2026-03-02 12:45:00 +0000 |
|---|---|---|
| committer | Christopher Baines <mail@cbaines.net> | 2026-03-11 15:31:06 +0000 |
| commit | 991c410bcff9e03761cc164896e44f0d1db8480a (patch) | |
| tree | a2218d238045b9e22b8895e1018a17e5db23fc78 /build-aux | |
| parent | c56f19efc66c8970e23c4cc4778fe6fcd2574994 (diff) | |
build-aux: Disable file port name canonicalization in a few places.
I'm assuming this doesn't have any meaningful effect, and it seems to reduce
the number of readlink calls by a lot.
* build-aux/build-self.scm (build-program): Set
%file-port-name-canonicalization to #f.
(build): Ditto.
* build-aux/compile-as-derivation.scm: Ditto.
Change-Id: If43415c46c3911e84c76d1a9828b9c417a140a1b
Diffstat (limited to 'build-aux')
| -rw-r--r-- | build-aux/build-self.scm | 6 | ||||
| -rw-r--r-- | build-aux/compile-as-derivation.scm | 3 |
2 files changed, 9 insertions, 0 deletions
diff --git a/build-aux/build-self.scm b/build-aux/build-self.scm index b0a427698fa..942cf5f5346 100644 --- a/build-aux/build-self.scm +++ b/build-aux/build-self.scm @@ -111,6 +111,9 @@ build daemon, from within the generated build program." #~(begin (use-modules (ice-9 match)) + ;; To avoid lots of readlink calls + (fluid-set! %file-port-name-canonicalization #f) + (eval-when (expand load eval) ;; (gnu packages …) modules are going to be looked up ;; under SOURCE. (guix config) is looked up in FRONT. @@ -246,6 +249,9 @@ Display a spinner when nothing happens." #:rest rest) "Return a derivation that unpacks SOURCE into STORE and compiles Scheme files." + ;; Avoid lots of readlink calls + (fluid-set! %file-port-name-canonicalization #f) + ;; Build the build program and then use it as a trampoline to build from ;; SOURCE. (mlet %store-monad ((build (build-program source version guile-version diff --git a/build-aux/compile-as-derivation.scm b/build-aux/compile-as-derivation.scm index 9da13893b51..c0b80e091f5 100644 --- a/build-aux/compile-as-derivation.scm +++ b/build-aux/compile-as-derivation.scm @@ -20,6 +20,9 @@ (use-modules (srfi srfi-26)) +;; Avoid lots of readlink calls +(fluid-set! %file-port-name-canonicalization #f) + ;; Add ~/.config/guix/current to the search path. (eval-when (expand load eval) (and=> (or (getenv "XDG_CONFIG_HOME") |
