From bfc9c339301ffe6dd15d156894dc27e05f6f081f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Mon, 11 Mar 2019 22:14:30 +0100 Subject: packages: Add the channel .go files to the search path. Until now %LOAD-COMPILED-PATH would wrongfully contain: CHANNEL/share/guile/site/X.Y for each channel, thereby ignoring all the .go files of channels. This fixes it so that %LOAD-COMPILED-PATH instead contains: CHANNEL/lib/guile/X.Y/site-ccache * guix/describe.scm (current-channel-entries): New procedure. (package-path-entries): Change to return the %LOAD-COMPILED-PATH entries as a second value. * gnu/packages.scm (%package-module-path): Expect two values from 'package-path-entries' and augment %LOAD-COMPILED-PATH accordingly. --- guix/describe.scm | 31 ++++++++++++++++++++----------- 1 file changed, 20 insertions(+), 11 deletions(-) (limited to 'guix') diff --git a/guix/describe.scm b/guix/describe.scm index c31199c9cd..8851bc46d1 100644 --- a/guix/describe.scm +++ b/guix/describe.scm @@ -65,19 +65,28 @@ lives in, or #f if this is not applicable." (let ((manifest (profile-manifest profile))) (manifest-entries manifest)))))) -(define package-path-entries +(define current-channel-entries (mlambda () - "Return a list of package path entries to be added to the package search -path. These entries are taken from the 'guix pull' profile the calling -process lives in, when applicable." - ;; Filter out Guix itself. - (filter-map (lambda (entry) - (and (not (string=? (manifest-entry-name entry) - "guix")) - (string-append (manifest-entry-item entry) + "Return manifest entries corresponding to extra channels--i.e., not the +'guix' channel." + (remove (lambda (entry) + (string=? (manifest-entry-name entry) "guix")) + (current-profile-entries)))) + +(define (package-path-entries) + "Return two values: the list of package path entries to be added to the +package search path, and the list to be added to %LOAD-COMPILED-PATH. These +entries are taken from the 'guix pull' profile the calling process lives in, +when applicable." + ;; Filter out Guix itself. + (unzip2 (map (lambda (entry) + (list (string-append (manifest-entry-item entry) "/share/guile/site/" - (effective-version)))) - (current-profile-entries)))) + (effective-version)) + (string-append (manifest-entry-item entry) + "/lib/guile/" (effective-version) + "/site-ccache"))) + (current-profile-entries)))) (define (package-provenance package) "Return the provenance of PACKAGE as an sexp for use as the 'provenance' -- cgit v1.2.3 From c9c51ac39aae7a4a49c8125916740f340fdfd4f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Tue, 12 Mar 2019 17:07:04 +0100 Subject: Revert "packages: 'package-input-rewriting' can take a promise." This reverts commit 7d2be1277b44de9d0528d9d3015443b40cb3b104, which turned out to be unhelpful for the problem at hand: https://lists.gnu.org/archive/html/guix-devel/2019-01/msg00486.html --- guix/packages.scm | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) (limited to 'guix') diff --git a/guix/packages.scm b/guix/packages.scm index 8515bb7c6f..f191327718 100644 --- a/guix/packages.scm +++ b/guix/packages.scm @@ -855,27 +855,19 @@ when CUT? returns true for a given package." #:optional (rewrite-name identity)) "Return a procedure that, when passed a package, replaces its direct and indirect dependencies (but not its implicit inputs) according to REPLACEMENTS. -REPLACEMENTS is a list of package pairs or a promise thereof; the first -element of each pair is the package to replace, and the second one is the -replacement. +REPLACEMENTS is a list of package pairs; the first element of each pair is the +package to replace, and the second one is the replacement. Optionally, REWRITE-NAME is a one-argument procedure that takes the name of a package and returns its new name after rewrite." (define (rewrite p) - (match (assq-ref (if (promise? replacements) - (force replacements) - replacements) - p) + (match (assq-ref replacements p) (#f (package (inherit p) (name (rewrite-name (package-name p))))) (new new))) - (package-mapping rewrite - (lambda (package) - (assq package (if (promise? replacements) - (force replacements) - replacements))))) + (package-mapping rewrite (cut assq <> replacements))) (define-syntax-rule (package/inherit p overrides ...) "Like (package (inherit P) OVERRIDES ...), except that the same -- cgit v1.2.3 From 3f4f2ee404d328cbfb846aa18aafa33ee6ae3cff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Tue, 12 Mar 2019 23:29:47 +0100 Subject: describe: 'package-path-entries' no longer includes the "guix" entry. Fixes Reported by mikadoZero . By returning the "guix" entry, we were then adding it to %PACKAGE-MODULE-PATH, causing the discovery code to scan the whole tree, including gnu/installer modules, which would in turn lead to warnings. Regression introduced in bfc9c339301ffe6dd15d156894dc27e05f6f081f. * guix/describe.scm (package-path-entries): Use 'current-channel-entries', not 'current-profile-entries'. --- guix/describe.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'guix') diff --git a/guix/describe.scm b/guix/describe.scm index 8851bc46d1..00372bbed7 100644 --- a/guix/describe.scm +++ b/guix/describe.scm @@ -86,7 +86,7 @@ when applicable." (string-append (manifest-entry-item entry) "/lib/guile/" (effective-version) "/site-ccache"))) - (current-profile-entries)))) + (current-channel-entries)))) (define (package-provenance package) "Return the provenance of PACKAGE as an sexp for use as the 'provenance' -- cgit v1.2.3 From 59e80445882f8b0379e54916f89510c0deda6698 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Wed, 13 Mar 2019 16:44:02 +0100 Subject: Remove traces of "GuixSD". * gnu/bootloader/extlinux.scm (extlinux-configuration-file): Remove mentions of "GuixSD". * gnu/bootloader/grub.scm (install-grub-efi): Likewise. * gnu/build/vm.scm (make-iso9660-image): Change default #:volume-id to "Guix_image". (initialize-hard-disk): Search for the "Guix_image" label. * gnu/ci.scm (system-test-jobs, tarball-jobs): Remove "GuixSD". * gnu/installer/newt/welcome.scm (run-welcome-page): Likewise. * gnu/packages/audio.scm (supercollider)[description]: Likewise. * gnu/packages/curl.scm (curl): Likewise. * gnu/packages/emacs.scm (emacs): Likewise. * gnu/packages/gnome.scm (network-manager): Likewise. * gnu/packages/julia.scm (julia): Likewise. * gnu/packages/linux.scm (alsa-plugins): Likewise. (powertop, wireless-regdb): Likewise. * gnu/packages/package-management.scm (guix): Likewise. * gnu/packages/polkit.scm (polkit): Likewise. * gnu/packages/tex.scm (texlive-bin): Likewise. * gnu/services/base.scm (file-systems->fstab): Likewise. * gnu/services/cups.scm (%cups-activation): Likewise. * gnu/services/mail.scm (%dovecot-activation): Likewise. * gnu/services/messaging.scm (prosody-configuration)[log]: Likewise. * gnu/system/examples/vm-image.tmpl (vm-image-motd): Likewise. * gnu/system/install.scm (installation-os)[file-systems]: Change root file system label to "Guix_image". * gnu/system/mapped-devices.scm (check-device-initrd-modules): Remove "GuixSD". * gnu/system/vm.scm (system-docker-image): Likewise. (system-disk-image)[root-label]: Change to "Guix_image". * gnu/tests/install.scm (run-install): Remove "GuixSD". * guix/modules.scm (guix-module-name?): Likewise. * nix/libstore/optimise-store.cc: Likewise. --- guix/modules.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'guix') diff --git a/guix/modules.scm b/guix/modules.scm index 65928f67f2..1a6fafe35b 100644 --- a/guix/modules.scm +++ b/guix/modules.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2016, 2017, 2018 Ludovic Courtès +;;; Copyright © 2016, 2017, 2018, 2019 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -112,7 +112,7 @@ depends on." ".scm")) (define (guix-module-name? name) - "Return true if NAME (a list of symbols) denotes a Guix or GuixSD module." + "Return true if NAME (a list of symbols) denotes a Guix module." (match name (('guix _ ...) #t) (('gnu _ ...) #t) -- cgit v1.2.3