gnu: guile-variant-package-name: Don’t rename ‘guile-bootstrap’.

Previously, ‘package-for-guile-2.2’ would sometimes create a variant
of (@ (gnu packages commencement) glibc-final) with a package called
“guile2.2-bootstrap” among its derivations, thereby causing an entirely
separate package graph to be built.

The reason ‘glibc-final’ would be modified despite the use of #:deep? #f is
because ‘texinfo’ depends on ‘libc-utf8-locales-for-target’, which depends on
‘glibc-final’.  This happened for ‘guile2.2-git’ because it depends on
‘texinfo’.

* gnu/packages/guile.scm (guile-variant-package-name): When ‘name’ is
“guile-bootstrap”, return it unchanged.

Change-Id: I6317927cf073085f36c4e07704469bb400b5a890
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
This commit is contained in:
Ludovic Courtès
2026-04-22 17:58:30 +02:00
parent fe89ae08c2
commit 0cbf963044

View File

@@ -653,7 +653,10 @@ GNU@tie{}Guile. Use the @code{(ice-9 readline)} module and call its
(define (guile-variant-package-name prefix)
(lambda (name)
"Return NAME with PREFIX instead of \"guile-\", when applicable."
(if (string-prefix? "guile-" name)
(if (and (string-prefix? "guile-" name)
;; Don't rename guile-bootstrap@2.0.
(not (string=? "guile-bootstrap" name)))
(string-append prefix "-"
(string-drop name
(string-length "guile-")))