all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#71618] [PATCH] guix: gnu-build-system: Add %gnu-build-system-default-modules.
@ 2024-06-17 19:10 Tomas Volf
  2024-06-18 19:30 ` Bruno Victal
  0 siblings, 1 reply; 3+ messages in thread
From: Tomas Volf @ 2024-06-17 19:10 UTC (permalink / raw)
  To: 71618; +Cc: Tomas Volf, Ludovic Courtès

Since there is no exported variable containing the list of default modules,
every place that needs it (in #:modules for example) needs to copy&paste it
and pray it never changes.

This commit provides new variable exposing the default list, allowing
constructs like this:

    #:modules
    `((srfi srfi-34)
      ,@%gnu-build-system-default-modules)

* guix/build-system/gnu.scm (%gnu-build-system-default-modules): New variable.
(define-module)[#:export]: Export it.

Change-Id: I1da392019a95aea5edeac0301db26266efbeee9e
---
 guix/build-system/gnu.scm | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/guix/build-system/gnu.scm b/guix/build-system/gnu.scm
index cdbb547773..53ac2f8cbd 100644
--- a/guix/build-system/gnu.scm
+++ b/guix/build-system/gnu.scm
@@ -28,6 +28,7 @@ (define-module (guix build-system gnu)
   #:use-module (srfi srfi-1)
   #:use-module (ice-9 match)
   #:export (%gnu-build-system-modules
+            %gnu-build-system-default-modules
             %strip-flags
             %strip-directories
             gnu-build
@@ -60,6 +61,8 @@ (define %default-modules
   '((guix build gnu-build-system)
     (guix build utils)))
 
+(define %gnu-build-system-default-modules %default-modules)
+
 (define* (package-with-explicit-inputs/deprecated p inputs
                                                   #:optional
                                                   (loc (current-source-location))
-- 
2.45.1





^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-06-19  1:06 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-17 19:10 [bug#71618] [PATCH] guix: gnu-build-system: Add %gnu-build-system-default-modules Tomas Volf
2024-06-18 19:30 ` Bruno Victal
2024-06-19  1:04   ` bug#71618: " Maxim Cournoyer

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.